DWARF-5: .debug_names index producer
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
437afbb8
JK
12017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
2 Pedro Alves <palves@redhat.com>
3
4 * contrib/gdb-add-index.sh (index): Rename to ...
5 (index4): ... here.
6 (index5, debugstr, debugstrmerge, debugstrerr): New variables.
7 Support also .debug_names and .debug_str.
8 * dwarf2read.c: Include cmath, set, list.
9 (INDEX_SUFFIX): Rename to ...
10 (INDEX4_SUFFIX): ... here.
11 (INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
12 (file_write(FILE *, const void *, size_t)): New.
13 (file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
14 (data_buf::append_unsigned_leb128, data_buf::empty): New.
15 (data_buf::file_write): Use ::file_write.
16 (data_buf::c_str, dwarf5_djb_hash, debug_names)
17 (check_dwarf64_offsets): New.
18 (psyms_seen_size, write_gdbindex): New from
19 write_psymtabs_to_index code.
20 (dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
21 (enum dw_index_kind): New.
22 (write_psymtabs_to_index): New parameter index_kind. Support
23 filename_str and out_file_str. Move code to write_gdbindex,
24 possibly call write_debug_names.
25 (save_gdb_index_command): New parameter -dwarf-5.
26 (_initialize_dwarf2_read): Document the new parameter -dwarf-5.
27
6432ec65
JK
282017-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
29 Pedro Alves <palves@redhat.com>
30
31 * contrib/cc-with-tweaks.sh: Change interpreter to bash, incl. initial
32 comment.
33 (GDB_ADD_INDEX): New variable.
34 <$want_index>: Call $GDB_ADD_INDEX.
35
92469284
SDJ
362017-12-08 Sergio Durigan Junior <sergiodj@redhat.com>
37
38 * dtrace-probe.c (dtrace_process_dof_probe): Do not declare a new
39 "expression_up" inside the TRY block.
40
f17d9474
YQ
412017-12-08 Yao Qi <yao.qi@linaro.org>
42
43 * breakpoint.c (update_watchpoint): Call
44 address_significant.
45
a0de8c21
YQ
462017-12-08 Yao Qi <yao.qi@linaro.org>
47
48 * breakpoint.c (adjust_breakpoint_address): Call
49 address_significant.
50
a738ea1d
YQ
512017-12-08 Yao Qi <yao.qi@linaro.org>
52
53 * aarch64-tdep.c (aarch64_gdbarch_init): Install gdbarch
54 significant_addr_bit.
55 * gdbarch.sh (significant_addr_bit): New.
56 * gdbarch.c, gdbarch.h: Re-generated.
57 * target.c (memory_xfer_partial): Call address_significant.
58 * utils.c (address_significant): New function.
59 * utils.h (address_significant): Declare.
60
8e481c3b
TT
612017-12-08 Tom Tromey <tom@tromey.com>
62
63 * printcmd.c (ui_printf): Update. Use std::vector.
64 * common/format.h (struct format_piece): Add constructor.
65 <string>: Now const.
66 (class format_pieces): New class.
67 (parse_format_string, free_format_pieces)
68 (free_format_pieces_cleanup): Remove.
69 * common/format.c (format_pieces::format_pieces): Rename from
70 parse_format_string. Update.
71 (free_format_pieces, free_format_pieces_cleanup): Remove.
72 * breakpoint.c (parse_cmd_to_aexpr): Update. Use std::vector.
73 * ax-gdb.h (gen_printf): Remove argument.
74 * ax-gdb.c (gen_printf): Remove "frags" argument.
75 (maint_agent_printf_command): Update. Use std::vector.
76
6b05c8bd
YQ
772017-12-08 Yao Qi <yao.qi@linaro.org>
78
79 PR breakpionts/22567
80 * linespec.c (minsym_found): Set sal.section.
81
336ef6d2
AA
822017-12-08 Andreas Arnez <arnez@linux.vnet.ibm.com>
83
84 * configure.tgt (s390*-*-linux*): Add symfile-mem.o.
85
fa6eb693
KS
862017-12-07 Keith Seitz <keiths@redhat.com>
87
88 PR breakpoints/22569
89 * location.c (string_to_explicit_location): When terminating
90 parsing early, break out of enclosing loop instead of returning.
91
883fd55a
KS
922017-12-07 Keith Seitz <keiths@redhat.com>
93
94 * NEWS (New commands): Mention set/show print type nested-type-limit.
95 * c-typeprint.c (c_type_print_base): Print out nested types.
96 * dwarf2read.c (struct typedef_field_list): Rename to ...
97 (struct decl_field_list): ... this. Change all uses.
98 (struct field_info) <nested_types_list, nested_types_list_count>:
99 New fields.
100 (add_partial_symbol): Look for nested type definitions in C++, too.
101 (dwarf2_add_typedef): Rename to ...
102 (dwarf2_add_type_defn): ... this.
103 (type_can_define_types): New function.
104 Update assertion to use type_can_define_types.
105 Permit NULL for a field's name.
106 (process_structure_scope): Handle child DIEs of types that can
107 define types.
108 Copy the list of nested types into the type struct.
109 * gdbtypes.h (struct typedef_field): Rename to ...
110 (struct decl_field): ... this. Change all uses.
111 [is_protected, is_private]: New fields.
112 (struct cplus_struct_type) <nested_types, nested_types_count>: New
113 fields.
114 (TYPE_NESTED_TYPES_ARRAY, TYPE_NESTED_TYPES_FIELD)
115 (TYPE_NESTED_TYPES_FIELD_NAME, TYPE_NESTED_TYPES_FIELD_TYPE)
116 (TYPE_NESTED_TYPES_COUNT, TYPE_NESTED_TYPES_FIELD_PROTECTED)
117 (TYPE_NESTED_TYPES_FIELD_PRIVATE): New macros.
118 * typeprint.c (type_print_raw_options, default_ptype_flags): Add
119 default value for print_nested_type_limit.
120 (print_nested_type_limit): New static variable.
121 (set_print_type_nested_types, show_print_type_nested_types): New
122 functions.
123 (_initialize_typeprint): Register new commands for set/show
124 `print-nested-type-limit'.
125 * typeprint.h (struct type_print_options) [print_nested_type_limit]:
126 New field.
127
99598d71
TT
1282017-12-07 Tom Tromey <tom@tromey.com>
129
130 PR breakpoints/22511:
131 * breakpoint.c (commands_command_1): Don't throw an exception when
132 no commands have been read.
133
23a8d186
AS
1342017-12-07 Adam Stylinski <adam.stylinski@etegent.com>
135
136 PR c++/21222
137 * target-descriptions.c (print_c_tdesc::visit_pre): Change type of
138 range-for variable.
139
30970df7
SM
1402017-12-07 Simon Marchi <simon.marchi@ericsson.com>
141
142 * common/selftest.h (struct selftest): Add virtual destructor.
143
824cc835
PM
1442017-12-07 Phil Muldoon <pmuldoon@redhat.com>
145
146 * python/py-breakpoint.c (bppy_init): Use string_to_event_location
147 over basic location code. Implement explicit location keywords.
148 (bppy_init_validate_args): New function.
149 * NEWS: Document Python explicit breakpoint locations.
150
9c226a86
JB
1512017-12-07 Joel Brobecker <brobecker@adacore.com>
152
153 * MAINTAINERS: Restore target entries for m68hc11-elf,
154 score-elf and xstormy16-elf, incorrectly removed in a previous
155 patch meant to only update the list of active maintainers.
156
649a140c
PA
1572017-12-06 Pedro Alves <palves@redhat.com>
158
159 * break-catch-syscall.c (insert_catch_syscall)
160 (remove_catch_syscall): Adjust to pass reference to
161 inf_data->syscalls_counts directly via gdb::array_view.
162 * fbsd-nat.c (fbsd_set_syscall_catchpoint): Adjust to use bool
163 and gdb::array_view.
164 * linux-nat.c (linux_child_set_syscall_catchpoint): Likewise.
165 * remote.c (remote_set_syscall_catchpoint): Likewise.
166 * target-debug.h (target_debug_print_bool): New.
167 (define target_debug_print_gdb_array_view_const_int): New.
168 * target-delegates.c: Regenerate.
169 * target.h (target_ops) <to_set_syscall_catchpoint>: Use
170 gdb::array_view and bool.
171 (target_set_syscall_catchpoint): Likewise.
172
9a93831c
SM
1732017-12-06 Simon Marchi <simon.marchi@ericsson.com>
174
175 * break-catch-syscall.c (catch_syscall_completer): Get pointers
176 to syscall group strings after building the string vector.
177
7cc244de
PA
1782017-12-06 Pedro Alves <palves@redhat.com>
179
180 * remote.c (remote_query_supported): Don't send "xmlRegisters=" if
181 "qXfer:features:read"" is disabled.
182 (remote_write_qxfer, remote_read_qxfer, remote_search_memory):
183 Check packet_config_support instead of packet->support directly.
184
858c9d13
SM
1852017-12-05 Simon Marchi <simon.marchi@ericsson.com>
186
187 * target-descriptions.c (struct tdesc_feature) <registers>: Use
188 tdesc_reg_up typedef.
189 (struct target_desc) <features>: Use tdesc_feature_up typedef.
190
d4a0e8b5
SM
1912017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
192
193 * target-descriptions.c (struct tdesc_type): Use default
194 destructor.
195 <u>: Remove.
196 <accept>: Remove.
197 (struct tdesc_type_builtin): New.
198 (struct tdesc_type_vector): New.
199 (struct tdesc_type_with_fields): New.
200 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
201 (tdesc_gdb_type): Remove.
202 (tdesc_register_type): Adjust.
203 (tdesc_create_vector): Create tdesc_type_vector.
204 (tdesc_create_struct): Create tdesc_type_with_fields.
205 (tdesc_set_struct_size): Change parameter type.
206 (tdesc_create_union): Create tdesc_type_with_fields.
207 (tdesc_create_flags): Likewise.
208 (tdesc_create_enum): Likewise.
209 (tdesc_add_field): Change parameter type.
210 (tdesc_add_typed_bitfield): Likewise.
211 (tdesc_add_bitfield): Likewise.
212 (tdesc_add_flag): Likewise.
213 (tdesc_add_enum_value): Likewise.
214 (print_c_tdesc) <visit>: Remove overload with tdesc_type
215 parameter, add overloads for tdesc_type_builtin,
216 tdesc_type_with_fields and tdesc_type_vector.
217 <m_printed_type>: Remove.
218 <m_printed_element_type, m_printed_type_with_fields>: Add.
219 * target-descriptions.h (tdesc_create_enum): Change return type.
220 (tdesc_add_typed_bitfield): Change parameter type.
221 (tdesc_add_enum_value): Change parameter type.
222 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
223 type to tdesc_type_with_fields.
224 (tdesc_start_struct): Adjust.
225 (tdesc_start_flags): Adjust.
226 (tdesc_start_enum): Adjust.
227 (tdesc_start_field): Adjust.
228 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
229 (struct tdesc_type_vector): Forward-declare.
230 (struct tdesc_type_with_fields): Forward-declare.
231 (tdesc_create_struct): Change return type.
232 (tdesc_create_union): Likewise.
233 (tdesc_create_flags): Likewise.
234 (tdesc_add_field): Change parameter type.
235 (tdesc_set_struct_size): Likewise.
236 (tdesc_add_bitfield): Likewise.
237 (tdesc_add_flag): Likewise.
238 * features: Re-generate C files.
239
f0cddbef
SM
2402017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
241
242 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
243 (struct tdesc_arch_reg): Add constructor.
244 (DEF_VEC_O (tdesc_arch_reg)): Remove.
245 (struct tdesc_arch_data): Initialize fields.
246 <arch_regs>: Change type to std::vector.
247 (target_find_description): Adjust.
248 (tdesc_find_type): Adjust.
249 (tdesc_data_init): Call tdesc_arch_data constructor.
250 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
251 (tdesc_data_cleanup): Free data with delete.
252 (tdesc_numbered_register): Adjust.
253 (tdesc_find_arch_register): Adjust.
254 (tdesc_use_registers): Adjust.
255
d05200d1
SM
2562017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
257
258 * target-descriptions.c (tdesc_type_field): Remove typedef.
259 (DEF_VEC_O (tdesc_type_field)): Remove.
260 (struct tdesc_type_field): Add constructor.
261 <name>: Change type to std::string.
262 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
263 kind uses it.
264 <~tdesc_type>: Destroy vector if the type kind uses it.
265 <u::u::fields>: Change type to std::vector.
266 (tdesc_gdb_type): Adjust.
267 (tdesc_add_field): Adjust.
268 (tdesc_add_typed_bitfield): Adjust.
269 (tdesc_add_field): Adjust.
270 (tdesc_add_enum_value): Adjust.
271 (class print_c_tdesc) <visit>: Adjust.
272
082b9140
SM
2732017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
274
275 * target-descriptions.c (struct tdesc_type) <name>: Change type
276 to std::string.
277 <~tdesc_type>: Don't manually free name.
278 <operator==>: Adjust.
279 (tdesc_named_type): Adjust.
280 (tdesc_find_type): Adjust.
281 (tdesc_gdb_type): Adjust.
282 (class print_c_tdesc) <visit>: Adjust.
283
53c934e9
SM
2842017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
285
286 * target-descriptions.c (tdesc_type_p): Remove typedef.
287 (DEF_VEC_P (tdesc_type_p)): Remove.
288 (struct tdesc_feature) <types>: Change type to std::vector.
289 <~tdesc_feature>: Replace with default implementation.
290 <accept>: Adjust.
291 (tdesc_named_type): Adjust.
292 (tdesc_create_vector): Adjust.
293 (tdesc_create_struct): Adjust.
294 (tdesc_create_union): Adjust.
295 (tdesc_create_flags): Adjust.
296 (tdesc_create_enum): Adjust.
297
a8142ee1
SM
2982017-12-05 Simon Marchi <simon.marchi@ericsson.com>
299
300 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
301 type of name_ parameter, adjust to std::string change.
302 <name, group, type>: Change type to std::string.
303 <~tdesc_reg>: Replace with default implementation.
304 <operator==>: Adjust.
305 (tdesc_find_register_early): Adjust.
306 (tdesc_register_name): Adjust.
307 (tdesc_register_type): Adjust.
308 (tdesc_register_in_reggroup_p): Adjust.
309 (class print_c_tdesc) <visit>: Adjust.
310 (class print_c_feature) <visit>: Adjust.
858c9d13
SM
311 * features/arc-arcompact.c: Re-generate.
312 * features/arc-v2.c: Re-generate.
a8142ee1 313
c9c895b9
SM
3142017-12-05 Simon Marchi <simon.marchi@ericsson.com>
315
316 * target-descriptions.c (tdesc_reg_p): Remove typedef.
317 (DEF_VEC_P (tdesc_reg_p)): Remove.
318 (struct tdesc_feature) <registers>: Change type to std::vector.
319 <~tdesc_feature>: Don't manually free registers.
320 <accept>: Adjust.
321 <operator==>: Adjust.
322 (tdesc_has_registers): Adjust.
323 (tdesc_find_register_early): Adjust.
324 (tdesc_use_registers): Adjust.
325 (tdesc_create_reg): Adjust.
326
f65ff9f9
SM
3272017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
328
329 * target-descriptions.c (tdesc_feature) <name>: Change type to
330 std::string.
331 <~tdesc_feature>: Don't manually free name.
332 <operator==>: Adjust.
333 (tdesc_find_feature): Adjust.
334 (tdesc_feature_name): Adjust.
335 (class print_c_tdesc) <visit_pre>: Adjust.
336 (class print_c_feature) <visit_pre>: Adjust.
337
3eea796c
SM
3382017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
339
340 * target-descriptions.c (tdesc_feature_p): Remove typedef.
341 (DEF_VEC_P (tdesc_feature_p)): Remove.
342 (struct target_desc) <features>: Change type to std::vector.
343 <~target_desc>: Replace with default implementation.
344 <accept>: Adjust.
345 <operator==>: Adjust.
346 (tdesc_has_registers): Adjust.
347 (tdesc_find_feature): Adjust.
348 (tdesc_use_registers): Adjust.
349 (tdesc_create_feature): Adjust.
350
40e2a983
SM
3512017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
352
353 * target-descriptions.c (arch_p): Remove typedef.
354 (DEF_VEC_P (arch_p)): Remove.
355 (struct target_desc) <compatible>: Change type to std::vector.
356 <~target_desc>: Don't manually free compatible.
357 (tdesc_compatible_p): Adjust.
358 (tdesc_add_compatible): Adjust.
359 (class print_c_tdesc) <visit_pre>: Adjust.
360
129c10bc
SM
3612017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
362
363 * target-descriptions.c (property_s): Remove typedef.
364 (DEF_VEC_O (property_s)): Remove.
365 (struct target_desc) <properties>: Make an std::vector.
366 <~target_desc>: Don't manually free properties.
367 (tdesc_property): Adjust.
368 (set_tdesc_property): Adjust.
369 (class print_c_tdesc) <visit_pre>: Adjust.
370
ed9376bd
SM
3712017-12-05 Simon Marchi <simon.marchi@ericsson.com>
372
373 * common/gdb_assert.h (gdb_static_assert): Redefine using
374 static_assert.
375
798a7429
SM
3762017-12-05 Simon Marchi <simon.marchi@ericsson.com>
377
378 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
379 unused variables.
380 (ada_is_redundant_range_encoding): Likewise.
381 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
382 Likewise.
383 * alpha-tdep.c (alpha_software_single_step): Likewise.
384 * arm-tdep.c (_initialize_arm_tdep): Likewise.
385 * auto-load.c (info_auto_load_cmd): Likewise.
386 * break-catch-syscall.c (insert_catch_syscall): Likewise.
387 (remove_catch_syscall): Likewise.
388 * breakpoint.c (condition_completer): Likewise.
389 (clear_command): Likewise.
390 (update_breakpoint_locations): Likewise.
391 * btrace.c (btrace_disable): Likewise.
392 (btrace_teardown): Likewise.
393 (btrace_maint_update_pt_packets): Likewise.
394 (maint_btrace_clear_cmd): Likewise.
395 * cli/cli-decode.c (lookup_cmd_1): Likewise.
396 (lookup_cmd_composition): Likewise.
397 * cli/cli-dump.c (scan_filename): Likewise.
398 (restore_command): Likewise.
399 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
400 * compile/compile-object-load.c (compile_object_load): Likewise.
401 * compile/compile-object-run.c (compile_object_run): Likewise.
402 * compile/compile.c (compile_to_object): Likewise.
403 * completer.c (filename_completer): Likewise.
404 (complete_files_symbols): Likewise.
405 (complete_expression): Likewise.
406 * corelow.c (core_open): Likewise.
407 * ctf.c (ctf_start): Likewise.
408 (ctf_write_status): Likewise.
409 (ctf_write_uploaded_tsv): Likewise.
410 (ctf_write_definition_end): Likewise.
411 (ctf_open_dir): Likewise.
412 (ctf_xfer_partial): Likewise.
413 (ctf_trace_find): Likewise.
414 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
415 Likewise.
416 * dwarf2loc.c (allocate_piece_closure): Likewise.
417 (indirect_pieced_value): Likewise.
418 (dwarf2_evaluate_loc_desc_full): Likewise.
419 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
420 (dw2_expand_symtabs_matching): Likewise.
421 (dw2_map_symbol_filenames): Likewise.
422 (read_and_check_comp_unit_head): Likewise.
423 (read_cutu_die_from_dwo): Likewise.
424 (lookup_dwo_unit): Likewise.
425 (read_comp_units_from_section): Likewise.
426 (dwarf2_compute_name): Likewise.
427 (handle_DW_AT_stmt_list): Likewise.
428 (create_cus_hash_table): Likewise.
429 (create_dwp_v2_section): Likewise.
430 (dwarf2_rnglists_process): Likewise.
431 (dwarf2_ranges_process): Likewise.
432 (dwarf2_record_block_ranges): Likewise.
433 (is_vtable_name): Likewise.
434 (read_formatted_entries): Likewise.
435 (skip_form_bytes): Likewise.
436 * elfread.c (elf_symtab_read): Likewise.
437 * exec.c (exec_file_command): Likewise.
438 * f-valprint.c (f_val_print): Likewise.
439 (info_common_command_for_block): Likewise.
440 * guile/guile.c (initialize_scheme_side): Likewise.
441 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
442 * guile/scm-cmd.c (cmdscm_completer): Likewise.
443 (gdbscm_register_command_x): Likewise.
444 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
445 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
446 * guile/scm-ports.c (file_port_magic): Likewise.
447 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
448 (ppscm_pretty_print_one_value): Likewise.
449 (ppscm_print_children): Likewise.
450 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
451 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
452 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
453 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
454 * i386-tdep.c (i386_register_reggroup_p): Likewise.
455 * infcmd.c (run_command_1): Likewise.
456 (until_next_fsm_clean_up): Likewise.
457 * linespec.c (linespec_complete): Likewise.
458 (find_label_symbols): Likewise.
459 * m2-valprint.c (m2_val_print): Likewise.
460 * memattr.c (require_user_regions): Likewise.
461 (lookup_mem_region): Likewise.
462 (disable_mem_command): Likewise.
463 (mem_delete): Likewise.
464 * mep-tdep.c (mep_register_name): Likewise.
465 (mep_analyze_prologue): Likewise.
466 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
467 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
468 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
469 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
470 * minidebug.c (lzma_open): Likewise.
471 * minsyms.c (lookup_minimal_symbol): Likewise.
472 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
473 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
474 (mips_o64_return_value): Likewise.
475 (mips_single_step_through_delay): Likewise.
476 (_initialize_mips_tdep): Likewise.
477 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
478 (nios2_software_single_step): Likewise.
479 * parse.c (find_minsym_type_and_address): Likewise.
480 * psymtab.c (psym_relocate): Likewise.
481 * python/py-breakpoint.c (bppy_get_commands): Likewise.
482 (gdbpy_breakpoint_modified): Likewise.
483 * python/py-infevents.c (create_inferior_call_event_object):
484 Likewise.
485 * python/py-record-btrace.c (btpy_list_item): Likewise.
486 * python/py-type.c (typy_str): Likewise.
487 * python/py-value.c (valpy_call): Likewise.
488 * python/python.c (do_start_initialization): Likewise.
489 * record-btrace.c (record_btrace_insn_history_range): Likewise.
490 (record_btrace_call_history_range): Likewise.
491 (record_btrace_record_method): Likewise.
492 (record_btrace_xfer_partial): Likewise.
493 (btrace_get_frame_function): Likewise.
494 * record-full.c (record_full_open): Likewise.
495 * record.c (get_context_size): Likewise.
496 * registry.h (DEFINE_REGISTRY): Likewise.
497 * remote-fileio.c (remote_fileio_request): Likewise.
498 * remote.c (remote_update_thread_list): Likewise.
499 (remote_check_symbols): Likewise.
500 (remote_commit_resume): Likewise.
501 (remote_interrupt): Likewise.
502 (remote_insert_breakpoint): Likewise.
503 (compare_sections_command): Likewise.
504 * rust-exp.y (super_name): Likewise.
505 (lex_string): Likewise.
506 (convert_ast_to_type): Likewise.
507 (convert_ast_to_expression): Likewise.
508 * rust-lang.c (rust_print_struct_def): Likewise.
509 (rust_print_type): Likewise.
510 (rust_evaluate_subexp): Likewise.
511 * rx-tdep.c (rx_register_type): Likewise.
512 * ser-event.c (serial_event_clear): Likewise.
513 * serial.c (serial_open): Likewise.
514 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
515 * symfile.c (section_is_overlay): Likewise.
516 (overlay_unmapped_address): Likewise.
517 (overlay_mapped_address): Likewise.
518 (simple_overlay_update_1): Likewise.
519 (simple_overlay_update): Likewise.
520 * symtab.c (symbol_find_demangled_name): Likewise.
521 (search_symbols): Likewise.
522 * target-descriptions.c (tdesc_predefined_type): Likewise.
523 * target.c (target_commit_resume): Likewise.
524 * thread.c (print_selected_thread_frame): Likewise.
525 * top.c (new_ui_command): Likewise.
526 (gdb_readline_no_editing): Likewise.
527 * tracefile-tfile.c (tfile_open): Likewise.
528 * tracepoint.c (create_tsv_from_upload): Likewise.
529 * utils.c (quit): Likewise.
530 (defaulted_query): Likewise.
531 * valarith.c (value_concat): Likewise.
532 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
533 * xml-tdesc.c (target_fetch_description_xml): Likewise.
534 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
535 (xtensa_pseudo_register_write): Likewise.
536
7403715e
TT
5372017-12-04 Tom Tromey <tom@tromey.com>
538
539 * NEWS: Mention Rust trait object inspection.
540
50a1fdd5
PA
5412017-12-04 Pedro Alves <palves@redhat.com>
542
543 PR gdb/22499
544 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
545 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
546 (vex2_prefix_p, vex3_prefix_p): New functions.
547 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
548 VEX3 prefixes.
549 (fixup_riprel): Set VEX3.!B.
550
1e97a227
SM
5512017-12-03 Simon Marchi <simon.marchi@ericsson.com>
552
553 * target.h (mem_region_vector): Remove.
554 (struct target_ops) <to_memory_map>: Change return type to
555 std::vector<mem_region>.
556 * target-debug.h (target_debug_print_mem_region_vector): Rename
557 to ...
558 (target_debug_print_std_vector_mem_region): ... this.
559 * target-delegates.c: Re-generate.
560
10f64178
PA
5612017-12-03 Pedro Alves <palves@redhat.com>
562
563 * make-target-delegates (munge_type): Also munge '<', '>', and
564 ':'. Avoid double underscores in identifiers, and trailing
565 underscores.
566 * target-debug.h
567 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
568 ...
569 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
570 * target-delegates.c: Regenerate.
571
6d83e819
SM
5722017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
573
574 * common/poison.h (XDELETE): Fix typo.
575
97cbe998
SDJ
5762017-12-01 Andrew Cagney <cagney@redhat.com>
577 Joel Brobecker <brobecker@adacore.com>
578 Sergio Durigan Junior <sergiodj@redhat.com>
579
580 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
581 feature.
582 * coffread.c (coff_symfile_read): Do not map over sections with
583 'coff_locate_sections' if readnever is on.
584 * dwarf2read.c (dwarf2_has_info): Return 0 if
585 readnever is on.
586 * elfread.c (elf_symfile_read): Do not map over sections with
587 'elf_locate_sections' if readnever is on.
588 * main.c (validate_readnow_readnever): New function.
589 (captured_main_1): Add support for --readnever.
590 (print_gdb_help): Document --readnever.
591 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
592 flag.
593 * symfile.c (readnever_symbol_files): New global.
594 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
595 'READNEVER_SYMBOL_FILES' is set.
596 (validate_readnow_readnever): New function.
597 (symbol_file_command): Handle '-readnever' option.
598 Call 'validate_readnow_readnever'.
599 (add_symbol_file_command): Handle '-readnever' option.
600 Call 'validate_readnow_readnever'.
601 (_initialize_symfile): Document new '-readnever' option for
602 both 'symbol-file' and 'add-symbol-file' commands.
603 * top.h (readnever_symbol_files): New extern global.
604 * xcoffread.c (xcoff_initial_scan): Do not read debug
605 information if readnever is on.
606
40fc416f
SDJ
6072017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
608
609 * symfile.c (symbol_file_command): Call
610 'symbol_file_add_main_1' only after processing all command
611 line options.
612 (add_symbol_file_command): Modify logic to make arguments
613 position-independent.
614
ec6a20c2
JB
6152017-12-01 Joel Brobecker <brobecker@adacore.com>
616
617 * ada-lang.c (symbol_list_obstack): Delete.
618 (resolve_subexp): Make sure "candidates" gets xfree'ed.
619 (ada_lookup_symbol_list_worker): Remove the limitation that
620 the result is only good until the next call, now making it
621 the responsibility of the caller to free the result when no
622 longer needed. Adjust the function's intro comment accordingly.
623 (ada_lookup_symbol_list): Adjust the function's intro comment.
624 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
625 (ada_lookup_encoded_symbol, get_var_value): Likewise.
626 (_initialize_ada_language): Remove symbol_list_obstack
627 initialization.
628 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
629 (write_var_or_type, write_name_assoc): Likewise.
630
d0df06af
TT
6312017-12-01 Tom Tromey <tom@tromey.com>
632
633 * Makefile.in (all_deps_files): New variable.
634 Include .Po files using all_deps_files.
635
2ee0c9b3
JB
6362017-12-01 Joel Brobecker <brobecker@adacore.com>
637
638 * MAINTAINERS: Update list of maintainers, moving those who
639 stepped down or became inactive to the "Past Maintainers"
640 section.
641
44122162
RO
6422017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
643
644 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
645 sys/proc.h.
646 (NEW_PROC_API): Remove.
647 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
648 Likewise.
649 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
650 * configure: Regenerate.
651 * config.in: Regenerate.
652 * gdbserver/configure: Regenerate.
653 * gdbserver/config.in: Regenerate.
654
655 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
656 NEW_PROC_API test.
657 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
658
659 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
660
661 * proc-api.c: Remove !NEW_PROC_API support.
662 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
663 Remove tests for macros always defined on Solaris.
664 * proc-events.c: Remove !NEW_PROC_API support.
665 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
666 HAVE_SYS_USER_H tests.
667 (init_syscall_table): Remove non-Solaris syscalls.
668 Remove tests for syscalls present on all Solaris versions.
669 Add missing Solaris 10+ syscalls.
670 (signal_table): Remove non-Solaris signals.
671 Remove tests for signals present on all Solaris versions.
672 (fault_table): Remove non-Solaris faults.
673 Remove tests for faults present on all Solaris versions.
674 * proc-flags.c: Remove !NEW_PROC_API support.
675 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
676 Remove non-Solaris flags.
677 * proc-why.c: Remove !NEW_PROC_API support.
678 (pr_why_table): Remove meaningless comments.
679 Remove tests for reasons present on all Solaris versions.
680 Remove OSF/1 cases.
681 (proc_prettyfprint_why): Likewise.
682
683 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
684 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
685 Remove WA_READ test, IRIX watchpoint support.
686 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
687 types. Change users.
688 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
689 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
690 Change callers.
691 Remove CTL_PROC_NAME_FMT tests.
692 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
693 users.
694 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
695 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
696 (proc_modify_flag): Replace GDBRESET by PCUNSET.
697 Remove PR_ASYNC, PR_KLC tests.
698 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
699 (proc_parent_pid): Remove PCWATCH etc. tests.
700 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
701 Remove PCAGENT test.
702 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
703 Remove SYS_lwpcreate || SYS_lwp_create test.
704 (proc_get_current_thread): Likewise.
705 [PIOCNTHR && PIOCTLIST]: Remove.
706 [PIOCLSTATUS]: Remove.
707 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
708 [PRFS_STOPEXEC]: Remove.
709 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
710 (syscall_is_exit): Likewise.
711 (syscall_is_exec): Likewise.
712 (syscall_is_lwp_create): Likewise.
713 Remove SYS_syssgi support.
714 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
715 [SYS_syssgi]: Remove.
716 Remove non-Solaris cases, conditionals.
717 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
718 Remove.
719 (procfs_init_inferior) [SYS_syssgi]: Remove.
720 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
721 (procfs_inferior_created) [SYS_syssgi]: Remove.
722 (procfs_set_watchpoint): Remove !AIX5 test.
723 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
724 case.
725 (mappingflags) [MA_PHYS]: Remove.
726 (info_mappings_callback): Remove PCAGENT test.
727 Remove PIOCOPENLWP || PCAGENT test.
728
e8020e54
RO
7292017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
730
731 * sol-thread.c (info_solthreads): Constify args.
732 Cast args to void *.
733
75059544
JB
7342017-11-29 John Baldwin <jhb@FreeBSD.org>
735
736 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
737
f5a91472
JB
7382017-11-29 Joel Brobecker <brobecker@adacore.com>
739
740 * ada-lang.c (to_fixed_range_type): Make sure that the size
741 of the range type being returned is the same as the size
742 of the range type being fixed.
743
bd69330d
PA
7442017-11-29 Pedro Alves <palves@redhat.com>
745
746 PR c++/19436
747 * NEWS: Mention setting breakpoints on functions with C++ ABI
748 tags.
749 * completer.h (completion_match_for_lcd) <match,
750 mark_ignored_range>: New methods.
751 <finish>: Consider ignored ranges.
752 <clear>: Clear ignored ranges.
753 <m_ignored_ranges, m_finished_storage>: New fields.
754 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
755 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
756 completion_match_for_lcd pointer to strncmp_iw_with_mode.
757 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
758 * language.c (default_symbol_name_matcher): Pass the
759 completion_match_for_lcd pointer to strncmp_iw_with_mode.
760 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
761 * utils.c (skip_abi_tag): New function.
762 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
763 Handle ABI tags.
764 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
765 parameter.
766
7672017-11-29 Pedro Alves <palves@redhat.com>
768
769 PR c++/19436
770 * NEWS: Mention setting breakpoints on functions with C++ ABI
771 tags.
772 * completer.h (completion_match_for_lcd) <match,
773 mark_ignored_range>: New methods.
774 <finish>: Consider ignored ranges.
775 <clear>: Clear ignored ranges.
776 <m_ignored_ranges, m_finished_storage>: New fields.
777 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
778 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
779 completion_match_for_lcd pointer to strncmp_iw_with_mode.
780 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
781 * language.c (default_symbol_name_matcher): Pass the
782 completion_match_for_lcd pointer to strncmp_iw_with_mode.
783 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
784 * utils.c (skip_abi_tag): New function.
785 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
786 Handle ABI tags.
787 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
788 parameter.
789
a20714ff
PA
7902017-11-29 Pedro Alves <palves@redhat.com>
791
792 * NEWS: Mention that breakpoints on C++ functions are now set on
793 on all namespaces/classes by default, and mention "break
794 -qualified".
795 * ax-gdb.c (agent_command_1): Adjust to pass a
796 symbol_name_match_type to new_linespec_location.
797 * breakpoint.c (parse_breakpoint_sals): Adjust to
798 get_linespec_location's return type change.
799 (strace_marker_create_sals_from_location): Adjust to pass a
800 symbol_name_match_type to new_linespec_location.
801 (strace_marker_decode_location): Adjust to get_linespec_location's
802 return type change.
803 (strace_command): Adjust to pass a symbol_name_match_type to
804 new_linespec_location.
805 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
806 mention "-qualified".
807 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
808 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
809 enumerator.
810 (complete_address_and_linespec_locations): New parameter
811 'match_type'. Pass it down.
812 (explicit_options): Add "-qualified".
813 (collect_explicit_location_matches): Pass the requested match type
814 to the linespec completers. Handle MATCH_QUALIFIED.
815 (location_completer): Handle "-qualified" combined with linespecs.
816 * cp-support.c (cp_search_name_hash): New.
817 (cp_symbol_name_matches_1): Implement wild matching for C++.
818 (cp_fq_symbol_name_matches): Reimplement.
819 (cp_get_symbol_name_matcher): Return different matchers depending
820 on the lookup name's match type.
821 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
822 * cp-support.h (cp_search_name_hash): New declaration.
823 * dwarf2read.c
824 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
825 symbols.
826 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
827 tests.
828 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
829 pass a symbol_name_match_type to new_linespec_location.
830 * linespec.c (linespec_parse_basic): Lookup function symbols using
831 the parser's symbol name match type.
832 (convert_explicit_location_to_linespec): New
833 symbol_name_match_type parameter. Pass it down to
834 find_linespec_symbols.
835 (convert_explicit_location_to_sals): Pass the location's name
836 match type to convert_explicit_location_to_linespec.
837 (parse_linespec): New match_type parameter. Save it in the
838 parser.
839 (linespec_parser_new): Default to symbol_name_match_type::WILD.
840 (linespec_complete_function): New symbol_name_match_type
841 parameter. Use it.
842 (complete_linespec_component): Pass down the parser's recorded
843 name match type.
844 (linespec_complete_label): New symbol_name_match_type parameter.
845 Use it.
846 (linespec_complete): New symbol_name_match_type parameter. Save
847 it in the parser and pass it down. Adjust to
848 get_linespec_location's prototype change.
849 (find_function_symbols, find_linespec_symbols): New
850 symbol_name_match_type parameter. Pass it down instead of
851 assuming symbol_name_match_type::WILD.
852 * linespec.h (linespec_complete, linespec_complete_function)
853 (linespec_complete_label): New symbol_name_match_type parameter.
854 * location.c (event_location::linespec_location): Now a struct
855 linespec_location.
856 (EL_LINESPEC): Adjust.
857 (initialize_explicit_location): Default to
858 symbol_name_match_type::WILD.
859 (new_linespec_location): New symbol_name_match_type parameter.
860 Record it in the location.
861 (get_linespec_location): Now returns a struct linespec_location.
862 (new_explicit_location): Also copy func_name_match_type.
863 (explicit_to_string_internal)
864 (string_to_explicit_location): Handle "-qualified".
865 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
866 Copy symbol_name_match_type fields.
867 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
868 type change.
869 (event_location_to_string): Adjust to LINESPEC_LOCATION type
870 change. Handle "-qualfied".
871 (string_to_explicit_location): Handle "-qualified".
872 (string_to_event_location_basic): New symbol_name_match_type
873 parameter. Pass it down.
874 (string_to_event_location): Handle "-qualified".
875 * location.h (struct linespec_location): New.
876 (explicit_location::func_name_match_type): New field.
877 (new_linespec_location): Now returns a const linespec_location *.
878 (string_to_event_location_basic): New symbol_name_match_type
879 parameter.
880 (explicit_completion_info::saw_explicit_location_option): New
881 field.
882 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
883 symbol_name_match_type to new_linespec_location.
884 * python/py-breakpoint.c (bppy_init): Likewise.
885 * python/python.c (gdbpy_decode_line): Likewise.
886
a207cff2
PA
8872017-11-29 Pedro Alves <palves@redhat.com>
888
889 * ada-lang.c (ada_lookup_name_info::matches): Change type of
890 parameter from completion_match to completion_match_result.
891 Adjust.
892 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
893 * completer.c (completion_tracker::maybe_add_completion): Add
894 match_for_lcd parameter and use it.
895 (completion_tracker::add_completion): Likewise.
896 * completer.h (class completion_match_for_lcd): New class.
897 (completion_match_result::match_for_lcd): New field.
898 (completion_match_result::set_match): New method.
899 (completion_tracker): Add comments.
900 (completion_tracker::add_completion): Add match_for_lcd parameter.
901 (completion_tracker::reset_completion_match_result): Reset
902 match_for_lcd too.
903 (completion_tracker::maybe_add_completion): Add match_for_lcd
904 parameter.
905 (completion_tracker::m_lowest_common_denominator_unique): Extend
906 comments.
907 * cp-support.c (cp_symbol_name_matches_1)
908 (cp_fq_symbol_name_matches): Change type of parameter from
909 completion_match to completion_match_result. Adjust.
910 * language.c (default_symbol_name_matcher): Change type of
911 parameter from completion_match to completion_match_result.
912 Adjust.
913 * language.h (completion_match_for_lcd): Forward declare.
914 (default_symbol_name_matcher): Change type of parameter from
915 completion_match to completion_match_result.
916 * symtab.c (compare_symbol_name): Adjust.
917 (completion_list_add_name): Pass the match_for_lcd to the tracker.
918 * symtab.h (ada_lookup_name_info::matches): Change type of
919 parameter from completion_match to completion_match_result.
920 (symbol_name_matcher_ftype): Likewise, and update comments.
921
4024cf2b
PA
9222017-11-29 Pedro Alves <palves@redhat.com>
923
924 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
925 * minsyms.c (msymbol_is_text): Delete.
926 (msymbol_is_function): New function.
927 * minsyms.h (msymbol_is_text): Delete.
928 (msymbol_is_function): New declaration.
929 * symtab.c (find_function_alias_target): Use msymbol_is_function.
930
5dcf52c1
TT
9312017-11-29 Tom Tromey <tom@tromey.com>
932
933 * Makefile.in (distclean): Handle the case where rmdir fails.
934
8ca2f0b9
TT
9352017-11-29 Tom Tromey <tom@tromey.com>
936
937 * symfile.c (_initialize_symfile): Update usage text for
938 add-symbol-file, symbol-file, load.
939
02ca603a
TT
9402017-11-29 Tom Tromey <tom@tromey.com>
941
942 * symfile.c (add_symbol_file_command): Error if some arguments to
943 -s are missing. Change unrecognized-argument error message.
944 (_initialize_symfile): Fix usage text for add-symbol-file.
945
18ca7347
TT
9462017-11-27 Tom Tromey <tom@tromey.com>
947
948 * Makefile.in (REMOTE_OBS): Remove.
949 (SFILES): Remove remote sources.
950 (COMMON_SFILES): Add remote sources.
951 (ALLDEPFILES): Remove dcache.c.
952
66599a7d
TT
9532017-11-27 Tom Tromey <tom@tromey.com>
954
955 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
956 variables.
957 (SFILES): Use SUBDIR_TARGET_SRCS.
958 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
959 (CONFIG_SRC_SUBDIR): Add target.
960 (%.o): Remove target rule.
961
4f04fba8
TT
9622017-11-27 Tom Tromey <tom@tromey.com>
963
964 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
965 registry.o, thread-fsm.o, debug.o.
966 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
967 thread-fsm.c, debug.c.
968
b5adff3b
TT
9692017-11-27 Tom Tromey <tom@tromey.com>
970
971 * Makefile.in (COMMON_SFILES): New.
972 (SFILES): Move some entries to COMMON_SFILES.
973 (COMMON_OBS): Use COMMON_SFILES.
974
afa0a411
TT
9752017-11-27 Tom Tromey <tom@tromey.com>
976
977 * Makefile.in (YYFILES): Update comment.
978 (YYOBJ): Redefine.
979
8fd8d003
TT
9802017-11-27 Tom Tromey <tom@tromey.com>
981
982 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
983 (CONFIG_SRC_SUBDIR): Add python.
984 (%.o): Remove python rule.
985 (python/%.o): New rule.
986 * configure: Rebuild.
987 * configure.ac (CONFIG_OBS): Refer to python/python.o
988
bd810fff
TT
9892017-11-27 Tom Tromey <tom@tromey.com>
990
991 * configure: Rebuild.
992 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
993 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
994 (CONFIG_SRC_SUBDIR): Add guile.
995 (%.o): Remove guile rule.
996
75787ac1
TT
9972017-11-27 Tom Tromey <tom@tromey.com>
998
999 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
1000 (%.o): Remove unittests rule.
1001 (CONFIG_SRC_SUBDIR): Add unittests.
1002
5c8a9431
TT
10032017-11-27 Tom Tromey <tom@tromey.com>
1004
1005 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
1006 (CONFIG_SRC_SUBDIR): Add tui.
1007 (%.o): Remove tui rule.
1008
a26aa30c
TT
10092017-11-27 Tom Tromey <tom@tromey.com>
1010
1011 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
1012 (%.o): Remove compile rule.
1013 (CONFIG_SRC_SUBDIR): Add compile.
1014
6f3cdf9a
TT
10152017-11-27 Tom Tromey <tom@tromey.com>
1016
1017 * Makefile.in (SUBDIR_MI_OBS): Redefine.
1018 (%.o): Remove mi rule.
1019 (CONFIG_SRC_SUBDIR): Add mi.
1020 (COMMON_OBS): Use mi/mi-common.o
1021
f06afa53
TT
10222017-11-27 Tom Tromey <tom@tromey.com>
1023
1024 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
1025 (%.o): Remove cli rule.
1026 (CONFIG_SRC_SUBDIR): Add cli.
1027
b22c88c2
TT
10282017-11-27 Tom Tromey <tom@tromey.com>
1029
1030 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
1031 * configure: Rebuild.
1032 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
1033 (CONFIG_DEP_SUBDIR): New variable.
1034 (%.o): Add order-only dependency.
1035 ($(CONFIG_DEP_SUBDIR)): New target.
1036
ee9a09e9
DC
10372017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
1038
1039 PR gdb/21945
1040 * findcmd.c (_initialize_mem_search): Update find command help
1041 text.
1042
e8e7d10c
SM
10432017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
1044
1045 * python/python.c (do_start_initialization): Change progname
1046 type to gdb::unique_xmalloc_ptr. Release the pointer when using
1047 Python 2.
1048
6a997029
TT
10492017-11-26 Tom Tromey <tom@tromey.com>
1050
1051 * common/format.h: Add include guards.
1052
41272101
TT
10532017-11-26 Tom Tromey <tom@tromey.com>
1054
1055 * nat/linux-personality.h (class
1056 maybe_disable_address_space_randomization): New class.
1057 (maybe_disable_address_space_randomization): Don't declare
1058 function.
1059 * nat/linux-personality.c (restore_personality)
1060 (make_disable_asr_cleanup): Remove.
1061 (maybe_disable_address_space_randomization): Now a constructor.
1062 (~maybe_disable_address_space_randomization): New destructor.
1063 * linux-nat.c (linux_nat_create_inferior): Update.
1064
44287fd8
TT
10652017-11-26 Tom Tromey <tom@tromey.com>
1066
1067 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
1068
5ffd2cb7
UW
10692017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
1070
1071 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
1072 "cooked" register. Access only first four bytes of branch target
1073 registers.
1074
0e5457dc
SDJ
10752017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
1076
1077 PR gdb/22491
1078 * stap-probe.c (relocate_address): New function.
1079 (stap_probe::get_relocated_address): Use 'relocate_address'.
1080 (stap_probe::set_semaphore): Use 'relocate_address' and pass
1081 'm_sem_addr'.
1082 (stap_probe::clear_semaphore): Likewise.
1083
deeeba55
PA
10842017-11-25 Pedro Alves <palves@redhat.com>
1085
1086 * dictionary.c: Include "safe-ctype.h".
1087 * minsyms.c: Include "safe-ctype.h".
1088 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
1089
a81aaca0
PA
10902017-11-25 Pedro Alves <palves@redhat.com>
1091
1092 * completer.c (complete_line_internal_1): Skip spaces until the
1093 start of the command.
1094
0662b6a7
PA
10952017-11-24 Pedro Alves <palves@redhat.com>
1096
1097 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
1098 cp_fq_symbol_name_matches. Pass language_cplus to
1099 strncmp_with_mode.
1100 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
1101 (selftests::test_cp_symbol_name_cmp): New.
1102 (_initialize_cp_support): Register "cp_symbol_name_matches"
1103 selftests.
1104 * language.c (default_symbol_name_matcher): Pass language_minimal
1105 to strncmp_iw_with_mode.
1106 * utils.c: Include "cp-support.h" and <algorithm>.
1107 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
1108 (cp_is_operator): New functions.
1109 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
1110 skip whitespace in the symbol name when the lookup name doesn't
1111 have spaces, and vice versa.
1112 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
1113 * utils.h (strncmp_iw_with_mode): Add language parameter.
1114
e547c119
JB
11152017-11-24 Joel Brobecker <brobecker@adacore.com>
1116
1117 * ada-lang.c (ada_exception_message_1, ada_exception_message):
1118 New functions.
1119 (print_it_exception): If available, display the exception
1120 message as well.
1121 * NEWS: Document new feature.
1122
d7fcdff9
UW
11232017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1124
1125 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
1126
30649c14
PR
11272017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
1128
1129 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
1130 (dtrace_probe::is_enabled, dtrace_probe::enable)
1131 (dtrace_probe::disable): Remove keyword 'struct' at for-range
1132 variable
1133 * probe.c (gen_ui_out_table_header_info)
1134 (print_ui_out_not_applicables): Remove keyword 'struct' at
1135 for-range variable
1136
7696f5c9
AH
11372017-11-24 Alan Hayward <alan.hayward@arm.com>
1138
1139 * configure.tgt: Add arch/aarch64.o
1140
8172f16b
SM
11412017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1142
1143 * common/common-utils.h: Include poison.h.
1144 (xfree): Remove declaration, add definition with static_assert.
1145 * common/common-utils.c (xfree): Remove.
1146 * common/poison.h (IsMallocatable): Define.
1147 (IsFreeable): Define.
1148 (free): Delete for non-freeable types.
1149 (xnew): New.
1150 (XNEW): Undef and redefine.
1151 (xcnew): New.
1152 (XCNEW): Undef and redefine.
1153 (xdelete): New.
1154 (XDELETE): Undef and redefine.
1155 (xnewvec): New.
1156 (XNEWVEC): Undef and redefine.
1157 (xcnewvec): New.
1158 (XCNEWVEC): Undef and redefine.
1159 (xresizevec): New.
1160 (XRESIZEVEC): Undef and redefine.
1161 (xdeletevec): New.
1162 (XDELETEVEC): Undef and redefine.
1163 (xnewvar): New.
1164 (XNEWVAR): Undef and redefine.
1165 (xcnewvar): New.
1166 (XCNEWVAR): Undef and redefine.
1167 (xresizevar): New.
1168 (XRESIZEVAR): Undef and redefine.
1169
7aabaf9d
SM
11702017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1171
1172 * gdbthread.h (private_thread_info): Define structure type, add
1173 virtual pure destructor.
1174 (thread_info) <priv>: Change type to unique_ptr.
1175 <private_dtor>: Remove.
1176 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
1177 (private_thread_info::~private_thread_info): Provide default
1178 implementation.
1179 (thread_info::~thread_info): Don't call private_dtor nor
1180 manually free priv.
1181 * aix-thread.c (private_thread_info): Rename to ...
1182 (aix_thread_info): ... this.
1183 (get_aix_thread_info): New.
1184 (sync_threadlists): Adjust.
1185 (iter_tid): Adjust.
1186 (aix_thread_resume): Adjust.
1187 (aix_thread_fetch_registers): Adjust.
1188 (aix_thread_store_registers): Adjust.
1189 (aix_thread_extra_thread_info): Adjust.
1190 * darwin-nat.h (private_thread_info): Rename to ...
1191 (darwin_thread_info): ... this.
1192 (get_darwin_thread_info): New.
1193 * darwin-nat.c (darwin_init_thread_list): Adjust.
1194 (darwin_check_new_threads): Adjust.
1195 (thread_info_from_private_thread_info): Adjust.
1196 * linux-thread-db.c (private_thread_info): Rename to ...
1197 (thread_db_thread_info): ... this, initialize fields.
1198 (get_thread_db_thread_info): New.
1199 <dying>: Change type to bool.
1200 (update_thread_state): Adjust to type rename.
1201 (record_thread): Adjust to type rename an use of unique_ptr.
1202 (thread_db_pid_to_str): Likewise.
1203 (thread_db_extra_thread_info): Likewise.
1204 (thread_db_thread_handle_to_thread_info): Likewise.
1205 (thread_db_get_thread_local_address): Likewise.
1206 * nto-tdep.h (private_thread_info): Rename to ...
1207 (nto_thread_info): ... this, initialize fields.
1208 (get_nto_thread_info): New.
1209 <name>: Change type to std::string.
1210 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1211 use of unique_ptr.
1212 * nto-procfs.c (update_thread_private_data_name): Adjust to
1213 std::string change, allocate nto_private_thread_info with new.
1214 (update_thread_private_data): Adjust to unique_ptr.
1215 * remote.c (private_thread_info): Rename to ...
1216 (remote_thread_info): ... this, initialize data members with
1217 default values.
1218 <extra, name>: Change type to std::string.
1219 <thread_handle>: Change type to non-pointer.
1220 (free_private_thread_info): Remove.
1221 (get_private_info_thread): Rename to...
1222 (get_remote_thread_info): ... this, change return type, adjust to
1223 use of unique_ptr, use remote_thread_info constructor.
1224 (remote_add_thread): Adjust.
1225 (get_private_info_ptid): Rename to...
1226 (get_remote_thread_info): ...this, change return type.
1227 (remote_thread_name): Use get_remote_thread_info, adjust to
1228 change to std::string.
1229 (struct thread_item) <~thread_item>: Remove.
1230 <thread_handle>: Make non pointer.
1231 (start_thread): Adjust to thread_item::thread_handle type
1232 change.
1233 (remote_update_thread_list): Adjust to type name change, move
1234 strings from temporary to long-lived object instead of
1235 duplicating.
1236 (remote_threads_extra_info): Use get_remote_thread_info.
1237 (process_initial_stop_replies): Likewise.
1238 (resume_clear_thread_private_info): Likewise.
1239 (remote_resume): Adjust to type name change.
1240 (remote_commit_resume): Use get_remote_thread_info.
1241 (process_stop_reply): Adjust to type name change.
1242 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1243 (remote_stopped_by_hw_breakpoint): Likewise.
1244 (remote_stopped_by_watchpoint): Likewise.
1245 (remote_stopped_data_address): Likewise.
1246 (remote_core_of_thread): Likewise.
1247 (remote_thread_handle_to_thread_info): Use
1248 get_private_info_thread, adjust to thread_handle field type
1249 change.
1250
21fe1c75
SM
12512017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1252
1253 * remote.c (struct thread_item): Add constructor, disable copy
1254 construction and copy assignment, define default move
1255 construction and move assignment.
1256 <extra, name>: Change type to std::string.
1257 <core>: Initialize.
1258 <thread_handle>: Make non-pointer.
1259 (thread_item_t): Remove typedef.
1260 (DEF_VEC_O(thread_item_t)): Remove.
1261 (threads_listing_context) <contains_thread>: New method.
1262 <remove_thread>: New method.
1263 <items>: Change type to std::vector.
1264 (clear_threads_listing_context): Remove.
1265 (threads_listing_context_remove): Remove.
1266 (remote_newthread_step): Use thread_item constructor, adjust to
1267 change to std::vector.
1268 (start_thread): Use thread_item constructor, adjust to change to
1269 std::vector.
1270 (end_thread): Adjust to change to std::vector and std::string.
1271 (remote_get_threads_with_qthreadinfo): Use thread_item
1272 constructor, adjust to std::vector.
1273 (remote_update_thread_list): Adjust to change to std::vector and
1274 std::string, use threads_listing_context methods.
1275 (remove_child_of_pending_fork): Adjust.
1276 (remove_new_fork_children): Adjust.
1277 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1278 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1279 * unittests/rsp-low-selftests.c: New file.
1280 * common/rsp-low.h: Include common/byte-vector.h.
1281 (hex2bin): New overload.
1282 * common/rsp-low.c (hex2bin): New overload.
1283
089354bb
SM
12842017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1285
1286 * inferior.h (private_inferior): Define structure type, add
1287 virtual pure destructor.
1288 (inferior) <priv>: Change type to unique_ptr.
1289 * inferior.c (private_inferior::~private_inferior): Provide
1290 default implementation.
1291 (inferior::~inferior): Don't free priv field.
1292 (exit_inferior_1): Likewise.
1293 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1294 (darwin_exception_info): Remove typedef.
1295 (DEF_VEC_O (darwin_thread_t)); Remove.
1296 (private_inferior): Rename to ...
1297 (darwin_private_inferior): ... this, extend private_inferior.
1298 (get_darwin_inferior): New.
1299 <threads>: Change type to std::vector of darwin_thread_t pointers.
1300 * darwin-nat.c (darwin_check_new_threads): Adjust.
1301 (find_inferior_task_it): Adjust.
1302 (darwin_find_thread); Adjust.
1303 (darwin_suspend_inferior): Adjust.
1304 (darwin_resume_inferior): Adjust.
1305 (darwin_find_new_inferior): Adjust.
1306 (darwin_decode_notify_message): Adjust.
1307 (darwin_send_reply): Adjust.
1308 (darwin_resume_inferior_threads): Adjust.
1309 (darwin_suspend_inferior_threads): Adjust.
1310 (darwin_decode_message): Adjust.
1311 (darwin_wait): Adjust.
1312 (darwin_interrupt): Adjust.
1313 (darwin_deallocate_threads): Adjust.
1314 (darwin_mourn_inferior): Adjust, don't free private data.
1315 (darwin_reply_to_all_pending_messages): Adjust.
1316 (darwin_stop_inferior): Adjust.
1317 (darwin_setup_exceptions): Adjust.
1318 (darwin_kill_inferior): Adjust.
1319 (darwin_setup_request_notification): Adjust.
1320 (darwin_attach_pid): Adjust.
1321 (darwin_init_thread_list): Adjust.
1322 (darwin_setup_fake_stop_event): Adjust.
1323 (darwin_attach): Adjust.
1324 (darwin_detach): Adjust.
1325 (darwin_xfer_partial): Adjust.
1326 (set_enable_mach_exceptions): Adjust.
1327 (darwin_pid_to_exec_file): Adjust.
1328 (darwin_get_ada_task_ptid): Adjust.
1329 * darwin-nat-info.c (get_task_from_args): Adjust.
1330 (info_mach_ports_command): Adjust.
1331 (info_mach_region_command): Adjust.
1332 (info_mach_exceptions_command): Adjust.
1333 * remote.c (private_inferior): Rename to ...
1334 (remote_private_inferior): ... this, initialize fields.
1335 (get_remote_inferior); New.
1336 (remote_commit_resume): Use get_remote_inferior.
1337 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1338
d044bac8
PA
13392017-11-24 Pedro Alves <palves@redhat.com>
1340
1341 * NEWS: Mention linespecs and explicit locations, and completion
1342 improvements.
1343
e8d58cba
YQ
13442017-11-24 Yao Qi <yao.qi@linaro.org>
1345
1346 * regcache.c (regcache::dump): Remove footnote_register_size.
1347
a63f2d2f
YQ
13482017-11-24 Yao Qi <yao.qi@linaro.org>
1349
1350 * regcache.c (cooked_read_test): Add more test for readonly
1351 regcache.
1352
1b30aaa5
YQ
13532017-11-24 Yao Qi <yao.qi@linaro.org>
1354
1355 * gdbarch-selftests.c (test_target_has_registers): Move it to
1356 target.c.
1357 (test_target_has_stack): Likewise.
1358 (test_target_has_memory): Likewise.
1359 (test_target_prepare_to_store): Likewise.
1360 (test_target_store_registers): Likewise.
1361 (test_target_ops): Likewise.
1362 * regcache.c: Include selftest-arch.h and gdbthread.h.
1363 (target_ops_no_register): New class.
1364 (test_target_fetch_registers): New.
1365 (test_target_store_registers): New.
1366 (test_target_xfer_partial): New.
1367 (readwrite_regcache): New.
1368 (cooked_read_test): New.
1369 (_initialize_regcache): Register the test.
1370 * target.c: (test_target_has_registers): Moved from
1371 gdbarch-selftests.c.
1372 (test_target_has_stack): Likewise.
1373 (test_target_has_memory): Likewise.
1374 (test_target_prepare_to_store): Likewise.
1375 (test_target_store_registers): Likewise.
1376 * target.h (test_target_ops): New class.
1377
6654d750
AH
13782017-11-24 Alan Hayward <alan.hayward@arm.com>
1379
1380 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1381 selftest.
1382
49bdb7ee
AH
13832017-11-24 Alan Hayward <alan.hayward@arm.com>
1384
1385 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1386 * arch/aarch64.c (aarch64_create_target_description): Create
1387 new target description.
1388 * features/Makefile: Add new files.
1389 * features/aarch64.c: Remove file.
1390 * features/aarch64-core.c: New autogenerated file.
1391 * features/aarch64-fpu.c: New autogenerated file.
1392 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
da434ccb
AH
1393
13942017-11-24 Alan Hayward <alan.hayward@arm.com>
1395
1396 * Makefile.in: Add new files.
1397 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1398 aarch64_read_description.
1399 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1400 Call aarch64_read_description.
1401 * aarch64-tdep.c (aarch64_read_description): New function.
1402 (aarch64_gdbarch_init): Call aarch64_read_description.
1403 * aarch64-tdep.h (aarch64_read_description): New function.
1404 * arch/aarch64.c: New file.
1405 * configure.tgt: Add new files.
1406
98ead37e
YQ
14072017-11-24 Yao Qi <yao.qi@linaro.org>
1408
1409 * mi/mi-main.c (register_changed_p): Update.
1410 * value.c (value_contents_bits_eq): Change return type.
1411 (value_contents_eq): Likewise.
1412 * value.h: Update comments.
1413
62ad7ce7
YQ
14142017-11-24 Yao Qi <yao.qi@linaro.org>
1415
1416 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1417 local 'changed'. Remove error.
1418 (register_changed_p): Change return type to bool.
1419
506fe5f4
YQ
14202017-11-24 Yao Qi <yao.qi@linaro.org>
1421
1422 * arch/tic6x.c: New file.
1423 * arch/tic6x.h: New file.
1424 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1425 tic6x-core.xml and tic6x-gp.xml.
1426 * features/tic6x-c6xp.c: Generated.
1427 * features/tic6x-core.c: Generated.
1428 * features/tic6x-gp.c: Generated.
1429 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1430 "tic6x-".
1431
00ea2e2a
SM
14322017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1433
1434 * mi/mi-main.c (list_available_thread_groups): Change map value
1435 type to std::vector.
1436
f45e2a77
SM
14372017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1438
1439 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1440
bd046f64
SM
14412017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1442
1443 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1444 back to...
1445 <children_requested>: ... this.
1446 (varobj_get_num_children, varobj_update): Adjust.
1447
4c37490d
SM
14482017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1449
1450 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1451 (ada_value_has_mutated): Likewise.
1452 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1453 (c_is_path_expr_parent): Likewise.
1454 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1455 (mi_cmd_var_set_frozen): Likewise.
1456 (mi_cmd_var_update_iter): Likewise.
1457 (mi_cmd_var_update): Likewise.
1458 * varobj.c (pretty_printing): Likewise.
1459 (varobj_enable_pretty_printing): Likewise.
1460 (struct varobj_root) <floating, is_valid>: Likewise.
1461 (struct varobj_dynamic) <children_requested>: Likewise.
1462 (delete_variable): Likewise.
1463 (delete_variable_1): Likewise.
1464 (install_variable): Likewise.
1465 (update_type_if_necessary): Likewise.
1466 (install_new_value): Likewise.
1467 (value_of_root): Likewise.
1468 (is_root_p): Likewise.
1469 (varobj_create): Likewise.
1470 (varobj_delete): Likewise.
1471 (varobj_has_more): Likewise.
1472 (varobj_set_frozen): Likewise.
1473 (varobj_get_frozen): Likewise.
1474 (install_dynamic_child): Likewise.
1475 (dynamic_varobj_has_child_method): Likewise.
1476 (update_dynamic_varobj_children): Likewise.
1477 (varobj_get_num_children): Likewise.
1478 (varobj_list_children): Likewise.
1479 (is_path_expr_parent): Likewise.
1480 (varobj_default_is_path_expr_parent): Likewise.
1481 (varobj_is_dynamic_p): Likewise.
1482 (varobj_set_value): Likewise.
1483 (varobj_value_has_mutated): Likewise.
1484 (varobj_update): Likewise.
1485 (check_scope): Likewise.
1486 (value_of_root_1): Likewise.
1487 (varobj_value_get_print_value): Likewise.
1488 (varobj_editable_p): Likewise.
1489 (varobj_value_is_changeable_p): Likewise.
1490 (varobj_floating_p): Likewise.
1491 (varobj_default_value_is_changeable_p): Likewise.
1492 (varobj_invalidate_iter): Likewise.
1493 * varobj.h (struct varobj_update_result) <type_changed,
1494 children_changed, changed, value_installed>: Likewise.
1495 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1496 (struct lang_varobj_ops) <value_is_changeable_p,
1497 value_has_mutated, is_path_expr_parent>: Likewise.
1498 (varobj_delete): Likewise.
1499 (varobj_set_frozen): Likewise.
1500 (varobj_get_frozen): Likewise.
1501 (varobj_set_value): Likewise.
1502 (varobj_update): Likewise.
1503 (varobj_editable_p): Likewise.
1504 (varobj_floating_p): Likewise.
1505 (varobj_has_more): Likewise.
1506 (varobj_is_dynamic_p): Likewise.
1507 (varobj_default_value_is_changeable_p): Likewise.
1508 (varobj_value_is_changeable_p): Likewise.
1509 (varobj_is_anonymous_child): Likewise.
1510 (varobj_default_is_path_expr_parent): Likewise.
1511
9c23b42f
SDJ
15122017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1513
1514 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1515 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1516 <type_str>: Convert to 'std::string'.
1517 <expr>: Convert to 'expression_up'.
1518 (dtrace_probe_arg_s): Delete type and VEC.
1519 (dtrace_probe_enabler_s): Likewise.
1520 (struct dtrace_probe): Replace by...
1521 (class dtrace_static_probe_ops): ...this and...
1522 (class dtrace_probe): ...this.
1523 (dtrace_probe_is_linespec): Rename to...
1524 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1525 to reflect change.
1526 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1527 Adjust code. Create new instance of 'dtrace_probe'.
1528 (dtrace_build_arg_exprs): Rename to...
1529 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1530 reflect change.
1531 (dtrace_get_probes): Rename to...
1532 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1533 to reflect change.
1534 (dtrace_get_arg): Rename to...
1535 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1536 reflect change.
1537 (dtrace_probe_is_enabled): Rename to...
1538 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
1539 change.
1540 (dtrace_get_probe_address): Rename to...
1541 (dtrace_probe::get_relocated_address): ...this. Adjust code
1542 to reflect change.
1543 (dtrace_get_probe_argument_count): Rename to...
1544 (dtrace_probe::get_argument_count): ...this. Adjust code to
1545 reflect change.
1546 (dtrace_can_evaluate_probe_arguments): Rename to...
1547 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
1548 to reflect change.
1549 (dtrace_evaluate_probe_argument): Rename to...
1550 (dtrace_probe::evaluate_argument): ...this. Adjust code to
1551 reflect change.
1552 (dtrace_compile_to_ax): Rename to...
1553 (dtrace_probe::compile_to_ax): ...this. Adjust code to
1554 reflect change.
1555 (dtrace_probe_destroy): Delete.
1556 (dtrace_type_name): Rename to...
1557 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
1558 reflect change.
1559 (dtrace_probe::get_static_ops): New method.
1560 (dtrace_gen_info_probes_table_header): Rename to...
1561 (dtrace_static_probe_ops::gen_info_probes_table_header):
1562 ...this. Adjust code to reflect change.
1563 (dtrace_gen_info_probes_table_values): Rename to...
1564 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
1565 code to reflect change.
1566 (dtrace_enable_probe): Rename to...
1567 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
1568 change.
1569 (dtrace_disable_probe): Rename to...
1570 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
1571 change.
1572 (struct probe_ops dtrace_probe_ops): Delete.
1573 (info_probes_dtrace_command): Call 'info_probes_for_spops'
1574 instead of 'info_probes_for_ops'.
1575 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
1576 of 'all_probe_ops'.
1577
0e9ae10f
SDJ
15782017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1579 Simon Marchi <simark@simark.ca>
1580
1581 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
1582 variable.
1583 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
1584 <aexpr>: Change type to 'expression_up'.
1585 (stap_probe_arg_s): Delete type and VEC.
1586 (struct stap_probe): Delete. Replace by...
1587 (class stap_static_probe_ops): ...this and...
1588 (class stap_probe): ...this. Rename variables to add 'm_'
1589 prefix. Do not use 'union' for arguments anymore.
1590 (stap_get_expected_argument_type): Receive probe name instead
1591 of 'struct stap_probe'. Adjust code.
1592 (stap_parse_probe_arguments): Rename to...
1593 (stap_probe::parse_arguments): ...this. Adjust code to
1594 reflect change.
1595 (stap_get_probe_address): Rename to...
1596 (stap_probe::get_relocated_address): ...this. Adjust code
1597 to reflect change.
1598 (stap_get_probe_argument_count): Rename to...
1599 (stap_probe::get_argument_count): ...this. Adjust code
1600 to reflect change.
1601 (stap_get_arg): Rename to...
1602 (stap_probe::get_arg_by_number'): ...this. Adjust code to
1603 reflect change.
1604 (can_evaluate_probe_arguments): Rename to...
1605 (stap_probe::can_evaluate_arguments): ...this. Adjust code
1606 to reflect change.
1607 (stap_evaluate_probe_argument): Rename to...
1608 (stap_probe::evaluate_argument): ...this. Adjust code
1609 to reflect change.
1610 (stap_compile_to_ax): Rename to...
1611 (stap_probe::compile_to_ax): ...this. Adjust code to
1612 reflect change.
1613 (stap_probe_destroy): Delete.
1614 (stap_modify_semaphore): Adjust comment.
1615 (stap_set_semaphore): Rename to...
1616 (stap_probe::set_semaphore): ...this. Adjust code to reflect
1617 change.
1618 (stap_clear_semaphore): Rename to...
1619 (stap_probe::clear_semaphore): ...this. Adjust code to
1620 reflect change.
1621 (stap_probe::get_static_ops): New method.
1622 (handle_stap_probe): Adjust code to create instance of
1623 'stap_probe'.
1624 (stap_get_probes): Rename to...
1625 (stap_static_probe_ops::get_probes): ...this. Adjust code to
1626 reflect change.
1627 (stap_probe_is_linespec): Rename to...
1628 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
1629 reflect change.
1630 (stap_type_name): Rename to...
1631 (stap_static_probe_ops::type_name): ...this. Adjust code to
1632 reflect change.
1633 (stap_gen_info_probes_table_header): Rename to...
1634 (stap_static_probe_ops::gen_info_probes_table_header):
1635 ...this. Adjust code to reflect change.
1636 (stap_gen_info_probes_table_values): Rename to...
1637 (stap_probe::gen_info_probes_table_values): ...this. Adjust
1638 code to reflect change.
1639 (struct probe_ops stap_probe_ops): Delete.
1640 (info_probes_stap_command): Use 'info_probes_for_spops'
1641 instead of 'info_probes_for_ops'.
1642 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
1643 of 'all_probe_ops'.
1644
935676c9
SDJ
16452017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1646
1647 * break-catch-throw.c (fetch_probe_arguments): Use
1648 'probe.prob' instead of 'probe.probe'.
1649 * breakpoint.c (create_longjmp_master_breakpoint): Call
1650 'can_evaluate_arguments' and 'get_relocated_address' methods
1651 from probe.
1652 (create_exception_master_breakpoint): Likewise.
1653 (add_location_to_breakpoint): Use 'sal->prob' instead of
1654 'sal->probe'.
1655 (bkpt_probe_insert_location): Call 'set_semaphore' method from
1656 probe.
1657 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
1658 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
1659 of 'probe_ops'.
1660 (probe_key_free): Call 'delete' on probe.
1661 (check_exception_resume): Use 'probe.prob' instead of
1662 'probe.probe'.
1663 * location.c (string_to_event_location_basic): Call
1664 'probe_linespec_to_static_ops'.
1665 * probe.c (class any_static_probe_ops): New class.
1666 (any_static_probe_ops any_static_probe_ops): New variable.
1667 (parse_probes_in_pspace): Receive 'static_probe_ops' as
1668 argument. Adjust code to reflect change.
1669 (parse_probes): Use 'static_probe_ops' instead of
1670 'probe_ops'. Adjust code to reflect change.
1671 (find_probes_in_objfile): Call methods to get name and
1672 provider from probe.
1673 (find_probe_by_pc): Use 'result.prob' instead of
1674 'result.probe'. Call 'get_relocated_address' method from
1675 probe.
1676 (collect_probes): Adjust comment and argument list to receive
1677 'static_probe_ops' instead of 'probe_ops'. Adjust code to
1678 reflect change. Call necessary methods from probe.
1679 (compare_probes): Call methods to get name and provider from
1680 probes.
1681 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
1682 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
1683 adjust code accordingly.
1684 (print_ui_out_not_applicables): Likewise.
1685 (info_probes_for_ops): Rename to...
1686 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
1687 as argument instead of 'probe_ops'. Adjust code. Call
1688 necessary methods from probe.
1689 (info_probes_command): Use 'info_probes_for_spops'.
1690 (enable_probes_command): Pass correct argument to
1691 'collect_probes'. Call methods from probe.
1692 (disable_probes_command): Likewise.
1693 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
1694 (get_probe_argument_count): Move to
1695 'any_static_probe_ops::get_argument_count'.
1696 (can_evaluate_probe_arguments): Move to
1697 'any_static_probe_ops::can_evaluate_arguments'.
1698 (evaluate_probe_argument): Move to
1699 'any_static_probe_ops::evaluate_argument'.
1700 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
1701 'probe.probe'.
1702 (probe_linespec_to_ops): Rename to...
1703 (probe_linespec_to_static_ops): ...this. Adjust code.
1704 (probe_any_is_linespec): Rename to...
1705 (any_static_probe_ops::is_linespec): ...this.
1706 (probe_any_get_probes): Rename to...
1707 (any_static_probe_ops::get_probes): ...this.
1708 (any_static_probe_ops::type_name): New method.
1709 (any_static_probe_ops::gen_info_probes_table_header): New
1710 method.
1711 (compute_probe_arg): Use 'pc_probe.prob' instead of
1712 'pc_probe.probe'. Call methods from probe.
1713 (compile_probe_arg): Likewise.
1714 (std::vector<const probe_ops *> all_probe_ops): Delete.
1715 (std::vector<const static_probe_ops *> all_static_probe_ops):
1716 New variable.
1717 (_initialize_probe): Use 'all_static_probe_ops' instead of
1718 'all_probe_ops'.
1719 * probe.h (struct info_probe_column) <field_name>: Delete
1720 extraneous newline
1721 (info_probe_column_s): Delete type and VEC.
1722 (struct probe_ops): Delete. Replace with...
1723 (class static_probe_ops): ...this and...
1724 (clas probe): ...this.
1725 (struct bound_probe) <bound_probe>: Delete extraneous
1726 newline. Adjust constructor to receive 'probe' instead of
1727 'struct probe'.
1728 <probe>: Rename to...
1729 <prob>: ...this. Delete extraneous newline.
1730 <objfile>: Delete extraneous newline.
1731 (register_probe_ops): Delete unused prototype.
1732 (info_probes_for_ops): Rename to...
1733 (info_probes_for_spops): ...this. Adjust comment.
1734 (get_probe_address): Move to 'probe::get_address'.
1735 (get_probe_argument_count): Move to
1736 'probe::get_argument_count'.
1737 (can_evaluate_probe_arguments): Move to
1738 'probe::can_evaluate_arguments'.
1739 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
1740 * solib-svr4.c (struct svr4_info): Adjust comment.
1741 (struct probe_and_action) <probe>: Rename to...
1742 <prob>: ...this.
1743 (register_solib_event_probe): Receive 'probe' instead of
1744 'struct probe' as argument. Use 'prob' instead of 'probe'
1745 when applicable.
1746 (solib_event_probe_action): Call 'get_argument_count' method
1747 from probe. Adjust comment.
1748 (svr4_handle_solib_event): Adjust comment. Call
1749 'evaluate_argument' method from probe.
1750 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
1751 from probe.
1752 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
1753 'struct probe'. Call 'can_evaluate_arguments' from probe.
1754 * symfile.h: Forward declare 'class probe' instead of 'struct
1755 probe'.
1756 * symtab.h: Likewise.
1757 (struct symtab_and_line) <probe>: Rename to...
1758 <prob>: ...this.
1759 * tracepoint.c (start_tracing): Use 'prob' when applicable.
1760 Call probe methods.
1761 (stop_tracing): Likewise.
1762
8f6cb6c3
JB
17632017-11-22 Joel Brobecker <brobecker@adacore.com>
1764
1765 * ravenscar-thread.c (ravenscar_inferior_created): Remove
1766 trailing newline at end of string in call to warning.
1767
479f8de1
SM
17682017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1769
1770 * osdata.h: Include vector isntead of vec.h.
1771 (osdata_column_s): Remove typedef.
1772 (struct osdata_column): Add constructor.
1773 <name, value>: Change type to std::string.
1774 (DEF_VEC_O (osdata_column_s)): Remove.
1775 (osdata_item_s): Remove typedef.
1776 (struct osdata_item) <columns>: Change type to std::vector.
1777 (DEF_VEC_O (osdata_item_s)): Remove.
1778 (struct osdata): Add constructor.
1779 <type>: Change type to std::string.
1780 <items>: Change type to std::vector.
1781 (osdata_p): Remove typedef.
1782 (DEF_VEC_P (osdata_p)): Remove.
1783 (osdata_parse): Return a unique_ptr.
1784 (osdata_free): Remove.
1785 (make_cleanup_osdata_free): Remove.
1786 (get_osdata): Return a unique_ptr.
1787 (get_osdata_column): Return pointer to std::string, take a
1788 reference to osdata_item as parameter.
1789 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
1790 unique_ptr.
1791 <property_name>: Change type to std::string.
1792 (osdata_start_osdata): Allocate osdata with new and adjust.
1793 (osdata_start_item): Adjust.
1794 (osdata_start_column): Adjust.
1795 (osdata_end_column): Adjust.
1796 (clear_parsing_data): Remove.
1797 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
1798 (osdata_item_clear): Remove.
1799 (get_osdata): return a unique_ptr and adjust.
1800 (get_osdata_column): Return a pointer to std::string and adjust.
1801 (info_osdata): Adjust.
1802 * mi/mi-main.c: Include <map>.
1803 (free_vector_of_osdata_items): Remove.
1804 (list_available_thread_groups): Adjust, use std::map instead of
1805 splay tree.
1806
41bd68f5
SM
18072017-11-22 Simon Marchi <simon.marchi@ericsson.com>
1808
1809 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
1810 case in switch.
1811
7e2fd2f4
SM
18122017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1813
1814 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
1815
0604393c
SM
18162017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1817
1818 * varobj.h (struct varobj_update_result): Add constructor, add
1819 move constructor, disable copy and assign, initialize fields.
1820 <newobj>: Change type to std::vector.
1821 (varobj_update): Return std::vector.
1822 * varobj.c (install_dynamic_child): Change VEC parameters to
1823 std::vector and adjust.
1824 (update_dynamic_varobj_children): Likewise.
1825 (varobj_update): Return std::vector and adjust.
1826 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
1827
ddf0ea08
SM
18282017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1829
1830 * varobj.h (struct varobj) <parent>: Remove const.
1831 <children>: Change type to std::vector.
1832 (varobj_list_children): Return std::vector const reference.
1833 (varobj_restrict_range): Change parameter type to std::vector
1834 const reference.
1835 * varobj.c (varobj_has_more): Adjust.
1836 (varobj_restrict_range): Change parameter type to std::vector
1837 const reference and adjust.
1838 (install_dynamic_child): Adjust.
1839 (update_dynamic_varobj_children): Adjust.
1840 (varobj_list_children): Return std::vector const reference and
1841 adjust.
1842 (varobj_add_child): Adjust.
1843 (update_type_if_necessary): Adjust.
1844 (varobj_update): Adjust.
1845 (delete_variable_1): Adjust.
1846 * ada-varobj.c (ada_value_has_mutated): Adjust.
1847 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
1848
9e5b9d2b
SM
18492017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1850
1851 * varobj.h (struct varobj): Add constructor and destructor,
1852 initialize fields.
1853 * varobj.c (struct varobj_root): Initialize fields.
1854 (struct varobj_dynamic): Initialize fields.
1855 (varobj_create): Use unique_ptr instead of cleanup. Create
1856 varobj with new instead of new_root_variable.
1857 (delete_variable_1): Free variable with delete instead of
1858 free_variable.
1859 (create_child_with_value): Create variable with new instead of
1860 new_variable.
1861 (varobj::varobj): New.
1862 (varobj::~varobj): New (body mostly coming from free_variable).
1863 (new_variable): Remove.
1864 (free_variable): Remove.
1865 (do_free_variable_cleanup): Remove.
1866 (make_cleanup_free_variable): Remove.
1867
fc35dab1
UW
18682017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1869
1870 * core-regset.c: Remove file.
1871 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
1872
2400729e
UW
18732017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1874
1875 * NEWS: Document use of GNU MPFR.
1876 * README: Likewise.
1877
1878 * Makefile.in (LIBMPFR): Add define.
1879 (CLIBS): Add $(LIBMPFR).
1880 * configure.ac: Add --with-mpfr configure option.
1881 * configure: Regenerate.
1882 * config.in: Regenerate.
1883
1884 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
1885 (class mpfr_float_ops): New type.
1886 (mpfr_float_ops::from_target): Two new overloaded functions.
1887 (mpfr_float_ops::to_target): Likewise.
1888 (mpfr_float_ops::to_string): New function.
1889 (mpfr_float_ops::from_string): Likewise.
1890 (mpfr_float_ops::to_longest): Likewise.
1891 (mpfr_float_ops::from_longest): Likewise.
1892 (mpfr_float_ops::from_ulongest): Likewise.
1893 (mpfr_float_ops::to_host_double): Likewise.
1894 (mpfr_float_ops::from_host_double): Likewise.
1895 (mpfr_float_ops::convert): Likewise.
1896 (mpfr_float_ops::binop): Likewise.
1897 (mpfr_float_ops::compare): Likewise.
1898 (get_target_float_ops): Use mpfr_float_ops if available.
1899
7a26362d
UW
19002017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1901
1902 * target-float.c: Do not include <math.h>.
1903 Include <cmath> and <limits>.
1904 (DOUBLEST): Do not define.
1905 (class target_float_ops): New type.
1906 (class host_float_ops): New templated type.
1907 (class decimal_float_ops): New type.
1908
1909 (floatformat_to_doublest): Rename to ...
1910 (host_float_ops<T>::from_target): ... this. Use template type T
1911 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1912 (host_float_ops<T>::from_target): New overload using a type argument.
1913 (floatformat_from_doublest): Rename to ...
1914 (host_float_ops<T>::to_target): ... this. Use template type T
1915 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1916 (host_float_ops<T>::to_target): New overload using a type argument.
1917 (floatformat_printf_format): New function.
1918 (struct printf_length_modifier): New templated type.
1919 (floatformat_to_string): Rename to ...
1920 (host_float_ops<T>::to_string): ... this. Use type instead of
1921 floatformat argument. Use floatformat_printf_format and
1922 printf_length_modifier. Remove special handling of invalid numbers,
1923 infinities and NaN (moved to target_float_to_string).
1924 (struct scanf_length_modifier): New templated type.
1925 (floatformat_from_string): Rename to ...
1926 (host_float_ops<T>::from_string): ... this. Use type instead of
1927 floatformat argument. Use scanf_length_modifier.
1928 (floatformat_to_longest): Rename to ...
1929 (host_float_ops<T>::to_longest): ... this. Use type instead of
1930 floatformat argument. Handle out-of-range values deterministically.
1931 (floatformat_from_longest): Rename to ...
1932 (host_float_ops<T>::from_longest): ... this. Use type instead of
1933 floatformat argument.
1934 (floatformat_from_ulongest): Rename to ...
1935 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
1936 floatformat argument.
1937 (floatformat_to_host_double): Rename to ...
1938 (host_float_ops<T>::to_host_double): ... this. Use type instead of
1939 floatformat argument.
1940 (floatformat_from_host_double): Rename to ...
1941 (host_float_ops<T>::from_host_double): ... this. Use type instead of
1942 floatformat argument.
1943 (floatformat_convert): Rename to ...
1944 (host_float_ops<T>::convert): ... this. Use type instead of
1945 floatformat arguments. Remove handling of no-op conversions.
1946 (floatformat_binop): Rename to ...
1947 (host_float_ops<T>::binop): ... this. Use type instead of
1948 floatformat arguments.
1949 (floatformat_compare): Rename to ...
1950 (host_float_ops<T>::compare): ... this. Use type instead of
1951 floatformat arguments.
1952
1953 (match_endianness): Use type instead of length/byte_order arguments.
1954 (set_decnumber_context): Likewise.
1955 (decimal_from_number): Likewise. Update calls.
1956 (decimal_to_number): Likewise.
1957 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
1958 (decimal_float_ops::to_host_double): New dummy function.
1959 (decimal_float_ops::from_host_double): Likewise.
1960 (decimal_to_string): Rename to ...
1961 (decimal_float_ops::to_string): ... this. Use type instead of
1962 length/byte_order arguments. Update calls.
1963 (decimal_from_string): Rename to ...
1964 (decimal_float_ops::from_string): ... this. Use type instead of
1965 length/byte_order arguments. Update calls.
1966 (decimal_from_longest): Rename to ...
1967 (decimal_float_ops::from_longest): ... this. Use type instead of
1968 length/byte_order arguments. Update calls.
1969 (decimal_from_ulongest): Rename to ...
1970 (decimal_float_ops::from_ulongest): ... this. Use type instead of
1971 length/byte_order arguments. Update calls.
1972 (decimal_to_longest): Rename to ...
1973 (decimal_float_ops::to_longest): ... this. Use type instead of
1974 length/byte_order arguments. Update calls.
1975 (decimal_binop): Rename to ...
1976 (decimal_float_ops::binop): ... this. Use type instead of
1977 length/byte_order arguments. Update calls.
1978 (decimal_compare): Rename to ...
1979 (decimal_float_ops::compare): ... this. Use type instead of
1980 length/byte_order arguments. Update calls.
1981 (decimal_convert): Rename to ...
1982 (decimal_float_ops::convert): ... this. Use type instead of
1983 length/byte_order arguments. Update calls.
1984
1985 (target_float_same_category_p): New function.
1986 (target_float_same_format_p): Likewise.
1987 (target_float_format_length): Likewise.
1988 (enum target_float_ops_kind): New type.
1989 (get_target_float_ops_kind): New function.
1990 (get_target_float_ops): Three new overloaded functions.
1991
1992 (target_float_is_zero): Update call.
1993 (target_float_to_string): Add special handling of invalid numbers,
1994 infinities and NaN (moved from floatformat_to_string). Use
1995 target_float_ops callback.
1996 (target_float_from_string): Use target_float_ops callback.
1997 (target_float_to_longest): Likewise.
1998 (target_float_from_longest): Likewise.
1999 (target_float_from_ulongest): Likewise.
2000 (target_float_to_host_double): Likewise.
2001 (target_float_from_host_double): Likewise.
2002 (target_float_convert): Add special case for no-op conversions.
2003 Use target_float_ops callback.
2004 (target_float_binop): Use target_float_ops callback.
2005 (target_float_compare): Likewise.
2006
a9f26f60
YQ
20072017-11-22 Yao Qi <yao.qi@linaro.org>
2008
2009 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
2010
29f9a567
YQ
20112017-11-22 Yao Qi <yao.qi@linaro.org>
2012
2013 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
2014 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
2015
3b1b69bf
JG
20162017-11-21 Jerome Guitton <guitton@adacore.com>
2017
2018 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
2019 with event ptid from the lower layer before doing the
2020 ravenscar-specific update.
2021
54aa6c67
JB
20222017-11-21 Joel Brobecker <brobecker@adacore.com>
2023
2024 * ravenscar-thread.c (is_ravenscar_task): Also verify that
2025 the ptid's TID is nonzero.
2026
cf3fbed4
JB
20272017-11-21 Joel Brobecker <brobecker@adacore.com>
2028
2029 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
2030 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
2031 Make non-static. Change return type to char *. Adjust code
2032 accordingly. Rewrite the function's documentation.
2033 (read_atcb): Adjust call to get_tcb_types_info accordingly.
2034 * ravenscar-thread.c (ravenscar_inferior_created): Check that
2035 we have enough debugging information in the runtime to support
2036 Ada task debugging before we enable the ravenscar-thread layer.
2037
9edcc12f
JB
20382017-11-21 Joel Brobecker <brobecker@adacore.com>
2039
2040 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
2041 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
2042 * ravenscar-thread.c: Add into comment.
2043 (base_magic_null_ptid): Delete.
2044 (base_ptid): Change documentation.
2045 (ravenscar_active_task): Renames ravenscar_running_thread.
2046 All callers updated throughout.
2047 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
2048 (ravenscar_task_is_currently_active): Likewise.
2049 (get_base_thread_from_ravenscar_task): Ditto.
2050 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
2051 (ravenscar_runtime_initialized): Likewise.
2052 (get_running_thread_id): Add new parameter "cpu". Adjust
2053 implementation to handle this new parameter.
2054 (ravenscar_fetch_registers): Small adjustment to use
2055 is_ravenscar_task and ravenscar_task_is_currently_active in
2056 order to decide whether to use the target beneath or this
2057 module's arch_ops.
2058 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
2059 (ravenscar_stopped_by_sw_breakpoint): Use
2060 get_base_thread_from_ravenscar_task to get the underlying
2061 thread, rather than using base_ptid.
2062 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2063 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2064 Likewise.
2065 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
2066
65d40437
JB
20672017-11-21 Joel Brobecker <brobecker@adacore.com>
2068
2069 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
2070 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
2071 (get_tcb_types_info): Set fieldnos.base_cpu.
2072 (read_atcb): Set task_info->base_cpu.
2073 (info_task): Print "Base CPU" info if set by runtime.
2074
e02544b2
JB
20752017-11-21 Joel Brobecker <brobecker@adacore.com>
2076
2077 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
2078 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
2079 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
2080 New functions.
2081 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
2082 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
2083 to_stopped_data_address and to_core_of_thread fields of
2084 ravenscar_ops.
2085
ed0f4273
UW
20862017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
2087
2088 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
2089 (struct gdbarch_tdep): New member long_double_abi.
2090 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
2091 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
2092 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
2093 format depending on long_double_abi tdep member.
2094 (ppc_floatformat_for_type): Handle __ibm128 type.
2095
0fc76421
SM
20962017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
2097
2098 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
2099
e6b2f5ef
PA
21002017-11-21 Pedro Alves <palves@redhat.com>
2101
2102 * dwarf2read.c (mapped_index::find_name_components_bounds)
2103 <completion mode, upper bound>: Use std::lower_bound instead of
2104 std::upper_bound.
2105 (test_mapped_index_find_name_component_bounds): Remove incorrect
2106 "t1_fund" from expected symbols.
2107
5c58de74
PA
21082017-11-21 Pedro Alves <palves@redhat.com>
2109
2110 * dwarf2read.c (mapped_index::name_components_casing): New field.
2111 (mapped_index) <build_name_components,
2112 find_name_components_bounds): Declare new methods.
2113 (mapped_index::find_name_components_bounds)
2114 (mapped_index::build_name_components): New methods, factored out
2115 from dw2_expand_symtabs_matching_symbol.
2116 (check_find_bounds_finds)
2117 (test_mapped_index_find_name_component_bounds): New.
2118 (run_test): Rename to ...
2119 (test_dw2_expand_symtabs_matching_symbol): ... this.
2120 (run_test): Reimplement.
2121
e1ef7d7a
PA
21222017-11-21 Pedro Alves <palves@redhat.com>
2123
2124 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
2125 (symbol_end): Use cp_ident_is_alnum.
2126 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
2127 * dwarf2read.c (make_sort_after_prefix_name): New function.
2128 (dw2_expand_symtabs_matching_symbol): Use it.
2129 (test_symbols): Add more symbols.
2130 (run_test): Add tests.
2131
cf724bc9
TT
21322017-11-17 Tom Tromey <tom@tromey.com>
2133
2134 * symtab.h (enum symbol_subclass_kind): New.
2135 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
2136 Remove.
2137 <subclass>: New member.
2138 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
2139 * rust-lang.c (rust_get_trait_object_pointer): Update.
2140 * dwarf2read.c (read_func_scope): Update.
2141 (read_variable): Update.
2142
68e745e3
TT
21432017-11-17 Tom Tromey <tom@tromey.com>
2144
2145 * dwarf2read.c (read_func_scope): Update.
2146 * symtab.h (struct template_symbol): Derive from symbol.
2147 <base>: Remove.
2148
71a3c369
TT
21492017-11-17 Tom Tromey <tom@tromey.com>
2150
2151 * symtab.h (struct symbol) <is_rust_vtable>: New member.
2152 (struct rust_vtable_symbol): New.
2153 (find_symbol_at_address): Declare.
2154 * symtab.c (find_symbol_at_address): New function.
2155 * symfile.h (struct quick_symbol_functions)
2156 <find_compunit_symtab_by_address>: New member.
2157 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
2158 function.
2159 (debug_sym_quick_functions): Link to
2160 debug_qf_find_compunit_symtab_by_address.
2161 * rust-lang.c (rust_get_trait_object_pointer): New function.
2162 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
2163 rust_get_trait_object_pointer.
2164 * psymtab.c (psym_relocate): Clear psymbol_map.
2165 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
2166 functions.
2167 (psym_functions): Link to psym_find_compunit_symtab_by_address.
2168 * objfiles.h (struct objfile) <psymbol_map>: New member.
2169 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
2170 (process_die) <DW_TAG_variable>: New case. Call read_variable.
2171 (rust_containing_type, read_variable): New functions.
2172
7468702d
SM
21732017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2174
2175 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
2176
37269bc9
SM
21772017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2178
2179 * common/filestuff.c: Include <algorithm>.
2180 (open_fds): Change type to std::vector<int>.
2181 (do_mark_open_fd): Adjust.
2182 (unmark_fd_no_cloexec): Adjust.
2183 (do_close): Adjust.
2184
5c632425
SM
21852017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2186
2187 * breakpoint.c (output_thread_groups): Take an std::vector.
2188 (print_one_breakpoint_location): Adjust.
2189
ced9779b
JB
21902017-11-17 Joel Brobecker <brobecker@adacore.com>
2191
2192 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2193 (ada_evaluate_subexp_for_cast): New function.
2194 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2195 ada_evaluate_subexp_for_cast.
2196 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2197 eval_skip_value.
2198 * eval.c (evaluate_var_value): Make non-static.
2199 (evaluate_var_msym_value, eval_skip_value): Likewise.
2200 * value.h (evaluate_var_value, evaluate_var_msym_value)
2201 (eval_skip_value): Declare.
2202
b7e22850
JB
22032017-11-16 Joel Brobecker <brobecker@adacore.com>
2204
2205 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2206 Update all callers.
2207
9ccabccd
PA
22082017-11-16 Pedro Alves <palves@redhat.com>
2209
2210 * python/py-unwind.c (pyuw_sniffer): Translate
2211 PyExc_KeyboardInterrupt to a GDB Quit exception.
2212
d930703d
PA
22132017-11-16 Pedro Alves <palves@redhat.com>
2214
2215 * infrun.c (resume_cleanups): Delete.
2216 (resume): No longer install a resume_cleanups cleanup nor call
2217 QUIT.
2218 (proceed): Pass the terminal to the inferior.
2219 (keep_going_pass_signal): No longer install a resume_cleanups
2220 cleanup.
2221
38dc2859
PA
22222017-11-16 Pedro Alves <palves@redhat.com>
2223
2224 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2225 if the prompt is blocked.
2226
688fca4f
PA
22272017-11-16 Pedro Alves <palves@redhat.com>
2228
2229 * breakpoint.c (insert_bp_location): Replace bp_err and
2230 bp_err_message locals by a gdb_exception local.
2231
e2c33ac7
PA
22322017-11-16 Pedro Alves <palves@redhat.com>
2233
2234 * inflow.c (scoped_ignore_sigttou): New class.
2235 (child_terminal_ours_1, new_tty): Use it.
2236
d7236961
UW
22372017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2238
2239 * target-float.c (decimal_from_number): Add byte_order argument and
2240 call match_endianness. Error if unknown floating-point type.
2241 (decimal_to_number): Add byte_order argument and call match_endianness.
2242 (decimal_from_longest): Update call. Do not call match_endianness.
2243 (decimal_from_ulongest): Likewise.
2244 (decimal_binop): Likewise.
2245 (decimal_is_zero): Likewise.
2246 (decimal_compare): Likewise.
2247 (decimal_convert): Likewise.
2248
d8ae99a7
PM
22492017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2250
2251 * python/python.c (gdbpy_rbreak): New function.
2252 * NEWS: Document Python rbreak feature.
2253
c632b645
YQ
22542017-11-16 Yao Qi <yao.qi@linaro.org>
2255
2256 * features/tic6x-c62x.xml: Remove.
2257 * features/tic6x-c64x.xml: Remove.
2258 * features/tic6x-c64xp.xml: Remove.
2259
a014b87a
JB
22602017-11-15 John Baldwin <jhb@FreeBSD.org>
2261
2262 * symtab.h: Include <array>.
2263
94765011
JB
22642017-11-15 John Baldwin <jhb@FreeBSD.org>
2265
2266 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2267 (bsd_kvm_proc_cmd): Likewise.
2268
625ad440
SM
22692017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2270
2271 * tui/tui-win.c (window_name_completer): Replace VEC with
2272 std::vector.
2273
c0c11fa9
AC
22742017-11-15 Andrew Cagney <cagney@gnu.org>
2275
2276 * MAINTAINERS: Remove no-longer applicable entries.
2277
34a7ebaf
AC
22782017-11-15 Andrew Cagney <cagney@gnu.org>
2279
2280 * MAINTAINERS: Move self to Past Maintainers.
2281
5334ef39
YQ
22822017-11-15 Yao Qi <yao.qi@linaro.org>
2283
2284 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2285 * features/nios2-linux.c: Remove.
2286 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2287 initialize_tdesc_nios2_linux.
2288
a714b0d6
YQ
22892017-11-15 Yao Qi <yao.qi@linaro.org>
2290
2291 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2292 M68HC11_LAST_HARD_REG + 1.
2293
92ffd475
PC
22942017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2295
2296 PR gdb/22388
2297 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2298 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2299 Return TARGET_XFER_EOF if size of returned data is 0.
2300
07431908
SM
23012017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2302
2303 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2304 memory-map-selftests.c.
2305 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2306 * memory-map.c (memory_map_start_memory): Fix computation of hi
2307 address.
2308 * unittests/memory-map-selftests.c: New file.
2309
31432a67
JB
23102017-11-09 Joel Brobecker <brobecker@adacore.com>
2311
2312 * ada-lang.c: Fix some typos in the general command documenting
2313 how Ada expressions are being evaluated and how their result
2314 is printed.
2315
e793c052
TT
23162017-11-09 Tom Tromey <tom@tromey.com>
2317
2318 * psymtab.c (psymbol_hash): Do not hash string contents.
2319 (psymbol_compare): Add comment.
2320
7e8835c5
TT
23212017-11-09 Tom Tromey <tom@tromey.com>
2322
2323 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2324
286acbb5
JB
23252017-11-08 Joel Brobecker <brobecker@adacore.com>
2326
2327 * ada-exp.y (write_var_from_sym): Remove parameter
2328 "orig_left_context". Update all callers.
2329
b44ec619
SM
23302017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2331
2332 * tracepoint.h (class collection_list) <stringify>: Return
2333 std::vector<std::string>.
2334 (encode_actions_rsp): Change parameters to
2335 std::vector<std::string> *.
2336 * tracepoint.c (collection_list::stringify): Return
2337 std::vector<std::string> and adjust accordingly.
2338 (encode_actions_rsp): Changee parameters to
2339 std::vector<std::string> and adjust accordingly.
2340 * remote.c (free_actions_list),
2341 free_actions_list_cleanup_wrapper): Remove.
2342 (remote_download_tracepoint): Adjust to std::vector.
2343
2f4732b0
TT
23442017-11-08 Tom Tromey <tom@tromey.com>
2345
2346 * dwarf2read.c (symbolp): Remove typedef.
2347 (read_func_scope): Use std::vector.
2348 (process_structure_scope): Use std::vector.
2349
f9d67a22
PA
23502017-11-08 Pedro Alves <palves@redhat.com>
2351
2352 * ada-lang.c (ada_make_symbol_completion_list): Use
2353 completion_skip_symbol.
2354 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2355 (symbol_is_function_or_method(symbol*)): New.
2356 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2357 completion_skip_symbol.
2358 (default_collect_symbol_completion_matches_break_on): Use
2359 completion_skip_symbol. Pass down mode.
2360 (collect_file_symbol_completion_matches): Pass down mode.
2361 * symtab.h (symbol_is_function_or_method): New declarations.
2362 (completion_skip_symbol): New template function.
2363
56d87ef7
PA
23642017-11-08 Pedro Alves <palves@redhat.com>
2365
2366 * linespec.c (iterate_over_all_matching_symtabs): Add
2367 search_domain parameter. Pass it down to expand_symtabs_matching.
2368 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2369 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2370 search_domain.
2371 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2372 Pass it down.
2373 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2374 symbols.
2375 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2376 it down.
2377
1b026119
PA
23782017-11-08 Pedro Alves <palves@redhat.com>
2379
2380 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2381 text_len locals and don't pass them down.
2382 * symtab.c (completion_list_add_name): Remove
2383 sym_text/sym_text_len parameters and adjust.
2384 (completion_list_add_symbol, completion_list_add_msymbol)
2385 (completion_list_objc_symbol, completion_list_add_fields)
2386 (add_symtab_completions): Likewise.
2387 (default_collect_symbol_completion_matches_break_on)
2388 (collect_file_symbol_completion_matches): Remove sym_text_len
2389 local and don't pass it down.
2390 * symtab.h (completion_list_add_name): Remove
2391 sym_text/sym_text_len parameters.
2392
c62446b1
PA
23932017-11-08 Pedro Alves <palves@redhat.com>
2394
2395 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2396 unittests/lookup_name_info-selftests.c.
2397 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2398 * cp-support.c: Include "selftest.h".
2399 (cp_remove_params_1): Rename from cp_remove_params. Add
2400 'require_param' parameter, and handle it.
2401 (cp_remove_params): Reimplement.
2402 (cp_remove_params_if_any): New.
2403 (selftests::quote): New.
2404 (selftests::check_remove_params): New.
2405 (selftests::test_cp_remove_params): New.
2406 (_initialize_cp_support): Install
2407 selftests::test_cp_remove_params.
2408 * cp-support.h (cp_remove_params_if_any): Declare.
2409 * dwarf2read.c :Include "selftest.h".
2410 (dw2_expand_symtabs_matching_symbol): Use
2411 lookup_name_info::make_ignore_params.
2412 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2413 (selftests::dw2_expand_symtabs_matching::string_or_null)
2414 (selftests::dw2_expand_symtabs_matching::check_match)
2415 (selftests::dw2_expand_symtabs_matching::test_symbols)
2416 (selftests::dw2_expand_symtabs_matching::run_test): New.
2417 (_initialize_dwarf2_read): Register
2418 selftests::dw2_expand_symtabs_matching::run_test.
2419 * psymtab.c (psym_expand_symtabs_matching): Use
2420 lookup_name_info::make_ignore_params.
2421 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2422 If the lookup name wants to ignore parameters, strip them.
2423 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2424 code handling '('.
2425 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2426 (default_collect_symbol_completion_matches_break_on): Don't try to
2427 strip parameters.
2428 * symtab.h (lookup_name_info::lookup_name_info): Add
2429 'ignore_parameters' parameter.
2430 (lookup_name_info::ignore_parameters)
2431 (lookup_name_info::make_ignore_params): New methods.
2432 (lookup_name_info::m_ignore_parameters): New field.
2433 * unittests/lookup_name_info-selftests.c: New file.
2434
61920122
PA
24352017-11-08 Pedro Alves <palves@redhat.com>
2436
2437 * dwarf2read.c (dw2_expand_marked_cus)
2438 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2439 (dw2_expand_symtabs_matching): Move further below.
2440 (dw2_expand_marked_cus): Reindent.
2441
3f563c84
PA
24422017-11-08 Pedro Alves <palves@redhat.com>
2443
2444 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2445 (struct name_component): New.
2446 (mapped_index::name_components): New field.
2447 (mapped_index::symbol_name_at): New method.
2448 (dwarf2_read_index): Call mapped_index ctor.
2449 (dw2_map_matching_symbols): Add comment about name_components
2450 table.
2451 (dw2_expand_symtabs_matching): Factor part to...
2452 (dw2_expand_symtabs_matching_symbol): ... this new function.
2453 Build name components table, and lookup symbols in it before
2454 calling the name matcher.
2455 (dw2_expand_marked_cus): New, factored out from
2456 dw2_expand_symtabs_matching.
2457 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2458
b5ec771e
PA
24592017-11-08 Pedro Alves <palves@redhat.com>
2460
2461 * ada-lang.c (ada_encode): Rename to ..
2462 (ada_encode_1): ... this. Add throw_errors parameter and handle
2463 it.
2464 (ada_encode): Reimplement.
2465 (match_name): Delete, folded into full_name.
2466 (resolve_subexp): No longer pass the encoded name to
2467 ada_lookup_symbol_list.
2468 (should_use_wild_match): Delete.
2469 (name_match_type_from_name): New.
2470 (ada_lookup_simple_minsym): Use lookup_name_info and the
2471 language's symbol_name_matcher_ftype.
2472 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2473 (ada_add_block_renamings): Adjust to use lookup_name_info.
2474 (ada_lookup_name): New.
2475 (add_nonlocal_symbols, ada_add_all_symbols)
2476 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2477 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2478 (ada_name_for_lookup): Delete.
2479 (ada_lookup_encoded_symbol): Construct a verbatim name.
2480 (wild_match): Reverse sense of return type. Use bool.
2481 (full_match): Reverse sense of return type. Inline bits of old
2482 match_name here.
2483 (ada_add_block_symbols): Adjust to use lookup_name_info.
2484 (symbol_completion_match): Delete, folded into...
2485 (ada_lookup_name_info::matches): ... .this new method.
2486 (symbol_completion_add): Delete.
2487 (ada_collect_symbol_completion_matches): Add name_match_type
2488 parameter. Adjust to use lookup_name_info and
2489 completion_list_add_name.
2490 (get_var_value, ada_add_global_exceptions): Adjust to use
2491 lookup_name_info.
2492 (ada_get_symbol_name_cmp): Delete.
2493 (do_wild_match, do_full_match): New functions.
2494 (ada_lookup_name_info::ada_lookup_name_info): New method.
2495 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2496 functions.
2497 (ada_language_defn): Install ada_get_symbol_name_matcher.
2498 * ada-lex.l (processId): If name starts with '<', copy it
2499 verbatim.
2500 * block.c (block_iter_match_step, block_iter_match_first)
2501 (block_iter_match_next, block_lookup_symbol)
2502 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2503 lookup_name_info.
2504 * block.h (block_iter_match_first, block_iter_match_next)
2505 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2506 * c-lang.c (c_language_defn, cplus_language_defn)
2507 (asm_language_defn, minimal_language_defn): Adjust comments to
2508 refer to la_get_symbol_name_matcher.
2509 * completer.c (complete_files_symbols)
2510 (collect_explicit_location_matches, symbol_completer): Pass a
2511 symbol_name_match_type down.
2512 * completer.h (class completion_match, completion_match_result):
2513 New classes.
2514 (completion_tracker::reset_completion_match_result): New method.
2515 (completion_tracker::m_completion_match_result): New field.
2516 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2517 lookup_name_info.
2518 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2519 functions.
2520 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2521 * d-lang.c: Adjust comments to refer to
2522 la_get_symbol_name_matcher.
2523 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2524 Adjust to use lookup_name_info.
2525 (dict_iter_match_first, dict_iter_match_next)
2526 (iter_match_first_hashed, iter_match_next_hashed)
2527 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2528 with a lookup_name_info.
2529 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2530 Likewise.
2531 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2532 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2533 (gdb_index_symbol_name_matcher): New class.
2534 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2535 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2536 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2537 with a symbol_name_match_type.
2538 (f_language_defn): Adjust comments to refer to
2539 la_get_symbol_name_matcher.
2540 * go-lang.c (go_language_defn): Adjust comments to refer to
2541 la_get_symbol_name_matcher.
2542 * language.c (default_symbol_name_matcher)
2543 (language_get_symbol_name_matcher): New functions.
2544 (unknown_language_defn, auto_language_defn): Adjust comments to
2545 refer to la_get_symbol_name_matcher.
2546 * language.h (symbol_name_cmp_ftype): Delete.
2547 (language_defn) <la_collect_symbol_completion_matches>: Add match
2548 type parameter.
2549 <la_get_symbol_name_cmp>: Delete field.
2550 <la_get_symbol_name_matcher>: New field.
2551 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
2552 (default_symbol_name_matcher, language_get_symbol_name_matcher):
2553 Declare.
2554 * linespec.c (iterate_over_all_matching_symtabs)
2555 (iterate_over_file_blocks): Adjust to use lookup_name_info.
2556 (find_methods): Add language parameter, and use lookup_name_info
2557 and the language's symbol_name_matcher_ftype.
2558 (linespec_complete_function): Adjust.
2559 (lookup_prefix_sym): Use lookup_name_info.
2560 (add_all_symbol_names_from_pspace): Adjust.
2561 (find_superclass_methods): Add language parameter and pass it
2562 down.
2563 (find_method): Pass symbol language down.
2564 (find_linespec_symbols): Don't demangle or Ada encode here.
2565 (search_minsyms_for_name): Add lookup_name_info parameter.
2566 (add_matching_symbols_to_info): Add name_match_type parameter.
2567 Use lookup_name_info.
2568 * m2-lang.c (m2_language_defn): Adjust comments to refer to
2569 la_get_symbol_name_matcher.
2570 * minsyms.c: Include <algorithm>.
2571 (add_minsym_to_demangled_hash_table): Remove table parameter and
2572 add objfile parameter. Use search_name_hash, and add language to
2573 demangled languages vector.
2574 (struct found_minimal_symbols): New struct.
2575 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
2576 New functions.
2577 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
2578 input names here. Use lookup_name_info instead. Lookup up
2579 demangled names once for each language in the demangled names
2580 vector.
2581 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
2582 demangled names once for each language in the demangled names
2583 vector.
2584 (build_minimal_symbol_hash_tables): Adjust.
2585 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
2586 lookup_name_info.
2587 * objc-lang.c (objc_language_defn): Adjust comment to refer to
2588 la_get_symbol_name_matcher.
2589 * objfiles.h: Include <vector>.
2590 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
2591 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
2592 la_get_symbol_name_matcher.
2593 * p-lang.c (pascal_language_defn): Adjust comment to refer to
2594 la_get_symbol_name_matcher.
2595 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
2596 (match_partial_symbol): Use symbol_name_match_type,
2597 lookup_name_info and psymbol_name_matches.
2598 (lookup_partial_symbol): Use lookup_name_info.
2599 (map_block): Use symbol_name_match_type and lookup_name_info.
2600 (psym_map_matching_symbols): Use symbol_name_match_type.
2601 (psymbol_name_matches): New.
2602 (recursively_search_psymtabs): Use lookup_name_info and
2603 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
2604 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
2605 'kind' parameter to 'domain'.
2606 * rust-lang.c (rust_language_defn): Adjust comment to refer to
2607 la_get_symbol_name_matcher.
2608 * symfile-debug.c (debug_qf_map_matching_symbols)
2609 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
2610 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
2611 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
2612 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
2613 Adjust to use symbol_name_match_type.
2614 <expand_symtabs_matching>: Adjust to use lookup_name_info.
2615 (expand_symtabs_matching): Adjust to use lookup_name_info.
2616 * symmisc.c (maintenance_expand_symtabs): Use
2617 lookup_name_info::match_any ().
2618 * symtab.c (symbol_matches_search_name): New.
2619 (eq_symbol_entry): Adjust to use lookup_name_info and the
2620 language's matcher.
2621 (demangle_for_lookup_info::demangle_for_lookup_info): New.
2622 (lookup_name_info::match_any): New.
2623 (iterate_over_symbols, search_symbols): Use lookup_name_info.
2624 (compare_symbol_name): Add language, lookup_name_info and
2625 completion_match_result parameters, and use them.
2626 (completion_list_add_name): Make extern. Add language and
2627 lookup_name_info parameters. Use them.
2628 (completion_list_add_symbol, completion_list_add_msymbol)
2629 (completion_list_objc_symbol): Add lookup_name_info parameters and
2630 adjust. Pass down language.
2631 (completion_list_add_fields): Add lookup_name_info parameters and
2632 adjust. Pass down language.
2633 (add_symtab_completions): Add lookup_name_info parameters and
2634 adjust.
2635 (default_collect_symbol_completion_matches_break_on): Add
2636 name_match_type parameter, and use it. Use lookup_name_info.
2637 (default_collect_symbol_completion_matches)
2638 (collect_symbol_completion_matches): Add name_match_type
2639 parameter, and pass it down.
2640 (collect_symbol_completion_matches_type): Adjust.
2641 (collect_file_symbol_completion_matches): Add name_match_type
2642 parameter, and use lookup_name_info.
2643 * symtab.h: Include <string> and "common/gdb_optional.h".
2644 (enum class symbol_name_match_type): New.
2645 (class ada_lookup_name_info): New.
2646 (struct demangle_for_lookup_info): New.
2647 (class lookup_name_info): New.
2648 (symbol_name_matcher_ftype): New.
2649 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
2650 (symbol_matches_search_name): Declare.
2651 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
2652 (default_collect_symbol_completion_matches)
2653 (collect_symbol_completion_matches)
2654 (collect_file_symbol_completion_matches): Add name_match_type
2655 parameter.
2656 (iterate_over_symbols): Use lookup_name_info.
2657 (completion_list_add_name): Declare.
2658 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
2659 (strncmp_iw_with_mode): Now extern.
2660 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
2661 (strncmp_iw_with_mode): Declare.
2662
5ffa0793
PA
26632017-11-08 Keith Seitz <keiths@redhat.com>
2664 Pedro Alves <palves@redhat.com>
2665
2666 * ada-lang.c (ada_language_defn): Install
2667 default_search_name_hash.
2668 * buildsym.c (struct buildsym_compunit): <language>: New field.
2669 (finish_block_internal): Pass language when creating dictionaries.
2670 (start_buildsym_compunit, start_symtab): New language parameters.
2671 Use them.
2672 (restart_symtab): Pass down compilation unit's language.
2673 * buildsym.h (enum language): Forward declare.
2674 (start_symtab): New 'language' parameter.
2675 * c-lang.c (c_language_defn, cplus_language_defn)
2676 (asm_language_defn, minimal_language_defn): Install
2677 default_search_name_hash.
2678 * coffread.c (coff_start_symtab): Adjust.
2679 * d-lang.c (d_language_defn): Install default_search_name_hash.
2680 * dbxread.c (struct symloc): Add 'pst_language' field.
2681 (PST_LANGUAGE): Define.
2682 (start_psymtab, read_ofile_symtab): Use it.
2683 (process_one_symbol): New 'language' parameter. Pass it down.
2684 * dictionary.c (struct dictionary) <language>: New field.
2685 (DICT_LANGUAGE): Define.
2686 (dict_create_hashed, dict_create_hashed_expandable)
2687 (dict_create_linear, dict_create_linear_expandable): New parameter
2688 'language'. Set the dictionary's language.
2689 (iter_match_first_hashed): Adjust to rename.
2690 (insert_symbol_hashed): Assert we don't see mismatching
2691 languages. Adjust to rename.
2692 (dict_hash): Rename to ...
2693 (default_search_name_hash): ... this and make extern.
2694 * dictionary.h (struct language_defn): Forward declare.
2695 (dict_create_hashed): New parameter 'language'.
2696 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
2697 * f-lang.c (f_language_defn): Install default_search_name_hash.
2698 * go-lang.c (go_language_defn): Install default_search_name_hash.
2699 * jit.c (finalize_symtab): Pass compunit's language to dictionary
2700 creation.
2701 * language.c (unknown_language_defn, auto_language_defn):
2702 * language.h (language_defn::la_search_name_hash): New field.
2703 (default_search_name_hash): Declare.
2704 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
2705 * mdebugread.c (new_block): New parameter 'language'.
2706 * mdebugread.c (parse_symbol): Pass symbol language to block
2707 allocation.
2708 (psymtab_to_symtab_1): Pass down language.
2709 (new_symtab): Pass compunit's language to block allocation.
2710 * objc-lang.c (objc_language_defn): Install
2711 default_search_name_hash.
2712 * opencl-lang.c (opencl_language_defn):
2713 * p-lang.c (pascal_language_defn): Install
2714 default_search_name_hash.
2715 * rust-lang.c (rust_language_defn): Install
2716 default_search_name_hash.
2717 * stabsread.h (enum language): Forward declare.
2718 (process_one_symbol): Add 'language' parameter.
2719 * symtab.c (search_name_hash): New function.
2720 * symtab.h (search_name_hash): Declare.
2721 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
2722
2a1dde5d
PA
27232017-11-08 Pedro Alves <palves@redhat.com>
2724
2725 * cp-name-parser.y (main): Don't initialize extra_chars.
2726
95a6b0a1
TT
27272017-11-07 Tom Tromey <tom@tromey.com>
2728
2729 * event-top.h (command_handler): Constify.
2730 * record-full.c (cmd_record_full_start): Update.
2731 * thread.c (thread_apply_all_command): Update.
2732 * printcmd.c (eval_command): Update.
2733 * mi/mi-main.c (mi_execute_cli_command): Update.
2734 (mi_execute_async_cli_command): Update.
2735 * tui/tui-stack.c (tui_update_command): Update.
2736 * cli/cli-interp.c (safe_execute_command): Constify.
2737 * record.c (record_start): Update.
2738 (record_start, record_stop, cmd_record_start): Update.
2739 * record-btrace.c (cmd_record_btrace_bts_start): Update.
2740 (cmd_record_btrace_pt_start): Update.
2741 (cmd_record_btrace_start): Update.
2742 (cmd_record_btrace_start): Update.
2743 * reverse.c (exec_reverse_once): Update.
2744 * python/python.c (execute_gdb_command): Don't copy the command.
2745 * event-top.c (command_line_handler): Update.
2746 (command_handler): Constify.
2747 * defs.h (deprecated_call_command_hook): Constify.
2748 * cli/cli-script.h (execute_user_command): Constify.
2749 * cli/cli-script.c (execute_user_command): Constify.
2750 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
2751 (enum command_control_type): Update.
2752 * main.c (catch_command_errors): Remove non-const overload.
2753 (catch_command_errors_ftype): Remove.
2754 * python/py-cmd.c (cmdpy_function): Constify.
2755 * guile/scm-cmd.c (cmdscm_function): Constify.
2756 * cli/cli-dump.c (call_dump_func): Constify.
2757 * cli/cli-decode.c (do_const_cfunc): Constify.
2758 (do_sfunc): Constify.
2759 (cmd_func): Constify.
2760 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
2761 * top.h (execute_command): Constify.
2762 * top.c (execute_command): Constify.
2763 (execute_command_to_string): Constify.
2764 (deprecated_call_command_hook): Constify.
2765 * command.h (cmd_func): Constify.
2766 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
2767
eb4c3f4a
TT
27682017-11-07 Tom Tromey <tom@tromey.com>
2769
2770 * ada-lang.c (catch_ada_exception_command): Constify.
2771 (catch_assert_command): Constify.
2772 * break-catch-throw.c (catch_catch_command, catch_throw_command)
2773 (catch_rethrow_command): Constify.
2774 (catch_exception_command_1): Constify.
2775 * breakpoint.h (add_catch_command): Constify.
2776 * break-catch-syscall.c (catch_syscall_command_1): Constify.
2777 (catch_syscall_split_args): Constify.
2778 * break-catch-sig.c (catch_signal_command): Constify.
2779 (catch_signal_split_args): Constify.
2780 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
2781 cmd_const_sfunc_ftype.
2782 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
2783 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2784 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2785 (add_setshow_string_cmd, struct cmd_list_element)
2786 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2787 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2788 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
2789 Constify.
2790 (set_cmd_sfunc): Constify.
2791 (empty_sfunc): Constify.
2792 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2793 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2794 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
2795 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2796 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2797 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
2798 Constify.
2799 (set_cmd_sfunc): Constify.
2800 (cmd_sfunc_ftype): Remove.
2801 * compile/compile.c (set_compile_args): Constify.
2802 * infrun.c (set_disable_randomization): Constify.
2803 * infcmd.c (set_args_command, set_cwd_command): Constify.
2804 * breakpoint.c (set_condition_evaluation_mode): Constify.
2805 (add_catch_command): Constify.
2806 (catch_fork_command_1, catch_exec_command_1)
2807 (catch_load_command_1, catch_unload_command_1): Constify.
2808 (catch_load_or_unload): Constify.
2809 * guile/scm-param.c (pascm_set_func): Constify.
2810 (add_setshow_generic): Constify.
2811 * python/py-param.c (get_set_value): Constify.
2812 * top.h (set_verbose): Constify.
2813 * tui/tui-win.c (tui_set_var_cmd): Constify.
2814 * mi/mi-main.c (set_mi_async_command): Constify.
2815 * cli/cli-logging.c (set_logging_overwrite)
2816 (set_logging_redirect): Constify.
2817 * value.c (set_max_value_size): Constify.
2818 * valprint.c (set_input_radix, set_output_radix): Constify.
2819 * utils.c (set_width_command, set_height_command): Constify.
2820 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
2821 * tracepoint.c (set_disconnected_tracing)
2822 (set_circular_trace_buffer, set_trace_buffer_size)
2823 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
2824 * top.c (set_history_size_command, set_verbose, set_editing)
2825 (set_gdb_datadir, set_history_filename): Constify.
2826 * target.c (set_targetdebug, maint_set_target_async_command)
2827 (maint_set_target_non_stop_command, set_target_permissions)
2828 (set_write_memory_permission): Constify.
2829 (open_target): Constify.
2830 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
2831 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
2832 * symtab.c (set_symbol_cache_size_handler): Constify.
2833 * symfile.c (set_ext_lang_command): Constify.
2834 * symfile-debug.c (set_debug_symfile): Constify.
2835 * source.c (set_directories_command): Constify.
2836 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
2837 * serial.c (set_parity): Constify.
2838 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
2839 * remote.c (set_remote_exec_file, set_remotebreak)
2840 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
2841 * record.c (set_record_insn_history_size)
2842 (set_record_call_history_size): Constify.
2843 * record-full.c (set_record_full_insn_max_num): Constify.
2844 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
2845 * osabi.c (set_osabi): Constify.
2846 * mips-tdep.c (set_mips64_transfers_32bit_regs)
2847 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
2848 * maint.c (maintenance_set_profile_cmd): Constify.
2849 * linux-thread-db.c (set_libthread_db_search_path): Constify.
2850 * language.c (set_language_command, set_range_command)
2851 (set_case_command): Constify.
2852 * infrun.c (set_non_stop, set_observer_mode)
2853 (set_stop_on_solib_events, set_schedlock_func)
2854 (set_exec_direction_func): Constify.
2855 * infcmd.c (set_inferior_tty_command): Constify.
2856 * disasm.c (set_disassembler_options_sfunc): Constify.
2857 * demangle.c (set_demangling_command): Constify.
2858 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
2859 * cris-tdep.c (set_cris_version, set_cris_mode)
2860 (set_cris_dwarf2_cfi): Constify.
2861 * corefile.c (set_gnutarget_command): Constify.
2862 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
2863 (set_target_wide_charset_sfunc): Constify.
2864 * breakpoint.c (update_dprintf_commands): Constify.
2865 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
2866 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
2867 (set_disassembly_style_sfunc): Constify.
2868 * arch-utils.c (set_endian, set_architecture): Constify.
2869 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
2870 * agent.c (set_can_use_agent): Constify.
2871
5fed81ff
TT
28722017-11-07 Tom Tromey <tom@tromey.com>
2873
2874 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
2875 (go32_pde, go32_pte, go32_pte_for_address): Constify.
2876 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
2877 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
2878 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
2879 (parse_int_arg, show_thread_default_detach_sc_cmd)
2880 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
2881 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
2882 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
2883 (show_task_pause_cmd, set_task_detach_sc_cmd)
2884 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
2885 (set_noninvasive_cmd, set_thread_pause_cmd)
2886 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
2887 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
2888 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
2889 * windows-nat.c (display_selectors): Constify.
2890 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
2891 non-const "cfunc".
2892 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
2893 (cmd_cfunc_eq): Likewise.
2894 (struct cmd_list_element): Likewise.
2895 (do_cfunc): Remove.
2896 (cli_user_command_p): Update.
2897 * command.h (add_cmd): Remove non-const overload.
2898 (cmd_cfunc_ftype): Remove typedef.
2899 (cmd_cfunc_eq): Remove non-const overload.
2900 * value.c (show_values): Constify.
2901 * thread.c (thread_apply_all_command): Constify.
2902 * symfile.c (load_command): Constify.
2903 * source.c (directory_command): Constify.
2904 * maint.c (maintenance_internal_error)
2905 (maintenance_demangler_warning, maintenance_space_display)
2906 (maintenance_print_architecture, maintenance_translate_address)
2907 (maintenance_info_selftests, maintenance_internal_warning):
2908 Constify.
2909 * breakpoint.c (disable_trace_command, enable_trace_command):
2910 Constify.
2911 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
2912 Constify.
2913 (add_auto_load_safe_path): Constify.
2914 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
2915 * top.h (show_commands): Constify.
2916 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
2917 * sparc64-tdep.c (adi_examine_command): Constify.
2918 (adi_assign_command): Constify.
2919
1d12d88f
TT
29202017-11-07 Tom Tromey <tom@tromey.com>
2921
2922 * frame.h (info_locals_command, info_args_command): Constify.
2923 * auto-load.h (auto_load_info_scripts): Constify.
2924 * inferior.h (registers_info): Constify.
2925 * copying.c: Rebuild.
2926 * copying.awk: Constify generated commands.
2927 * auto-load.c (auto_load_info_scripts)
2928 (info_auto_load_gdb_scripts): Constify.
2929 * cli/cli-decode.c (struct cmd_list_element): Take a
2930 cmd_const_cfunc_ftype.
2931 * command.h (add_info): Take a cmd_const_cfunc_ftype.
2932 * tui/tui-win.c (tui_all_windows_info): Constify.
2933 * python/py-auto-load.c (info_auto_load_python_scripts):
2934 Constify.
2935 * cli/cli-cmds.c (show_command): Remove non-const overload.
2936 * tracepoint.c (info_tvariables_command, info_scope_command):
2937 Constify.
2938 (info_static_tracepoint_markers_command): Constify.
2939 * thread.c (info_threads_command): Constify.
2940 (print_thread_info_1): Constify.
2941 * target.c (info_target_command): Constify.
2942 * symtab.c (info_sources_command, info_functions_command)
2943 (info_types_command): Constify.
2944 (info_variables_command): Remove non-const overload.
2945 * symfile.c (info_ext_lang_command): Constify.
2946 * stack.c (info_frame_command, info_locals_command)
2947 (info_args_command): Constify.
2948 (backtrace_command): Remove non-const overload.
2949 * source.c (info_source_command, info_line_command): Constify.
2950 * solib.c (info_sharedlibrary_command): Constify.
2951 * skip.c (info_skip_command): Constify.
2952 * ser-go32.c (info_serial_command): Constify.
2953 * reverse.c (info_bookmarks_command): Constify.
2954 * printcmd.c (info_symbol_command, info_address_command)
2955 (info_display_command): Constify.
2956 * osdata.c (info_osdata_command): Constify.
2957 * objc-lang.c (info_selectors_command, info_classes_command):
2958 Constify.
2959 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
2960 * memattr.c (info_mem_command): Constify.
2961 * macrocmd.c (info_macro_command, info_macros_command): Constify.
2962 * linux-fork.c (info_checkpoints_command): Constify.
2963 * infrun.c (info_signals_command): Constify.
2964 * inflow.c (info_terminal_command): Constify.
2965 * inferior.c (info_inferiors_command): Constify.
2966 (print_inferior): Constify.
2967 * infcmd.c (info_program_command, info_all_registers_command)
2968 (info_registers_command, info_vector_command)
2969 (info_float_command): Constify.
2970 (registers_info): Constify.
2971 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
2972 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
2973 Constify.
2974 * f-valprint.c (info_common_command): Constify.
2975 * dcache.c (info_dcache_command): Constify.
2976 (dcache_info_1): Constify.
2977 * darwin-nat-info.c (info_mach_tasks_command)
2978 (info_mach_task_command, info_mach_ports_command)
2979 (info_mach_port_command, info_mach_threads_command)
2980 (info_mach_thread_command, info_mach_regions_command)
2981 (info_mach_regions_recurse_command, info_mach_region_command)
2982 (info_mach_exceptions_command): Constify.
2983 (get_task_from_args): Constify.
2984 * cp-support.c (info_vtbl_command): Constify.
2985 * breakpoint.c (info_watchpoints_command)
2986 (info_tracepoints_command): Constify.
2987 (info_breakpoints_command): Remove non-const overload.
2988 * avr-tdep.c (avr_io_reg_read_command): Constify.
2989 * auxv.c (info_auxv_command): Constify.
2990 * ada-tasks.c (info_tasks_command): Constify.
2991 (info_task): Constify.
2992 * ada-lang.c (info_exceptions_command): Constify.
2993
0b39b52e
TT
29942017-11-07 Tom Tromey <tom@tromey.com>
2995
2996 * solib.h (no_shared_libraries): Constify.
2997 * frame.h (return_command): Constify.
2998 * cli/cli-cmds.h (quit_command): Constify.
2999 * top.h (quit_command, execute_command): Constify.
3000 * target.h (flash_erase_command): Constify.
3001 * inferior.h (set_inferior_args, attach_command): Constify.
3002 * tracepoint.h (start_tracing, stop_tracing): Constify.
3003 * breakpoint.h (break_command, tbreak_command)
3004 (hbreak_command_wrapper, thbreak_command_wrapper)
3005 (rbreak_command_wrapper, watch_command_wrapper)
3006 (awatch_command_wrapper, rwatch_command_wrapper)
3007 (get_tracepoint_by_number): Constify.
3008 * symtab.c (info_variables_command, rbreak_command)
3009 (symtab_symbol_info): Constify.
3010 (info_variables_command): Add non-const overload.
3011 * top.c (dont_repeat_command): Constify.
3012 * breakpoint.c (ignore_command, commands_command)
3013 (condition_command, tbreak_command, hbreak_command)
3014 (thbreak_command, clear_command, break_command)
3015 (info_breakpoints_command, watch_command, rwatch_command)
3016 (awatch_command, trace_command, ftrace_command, strace_command)
3017 (trace_pass_command, break_range_command, dprintf_command)
3018 (agent_printf_command, get_tracepoint_by_number)
3019 (watch_maybe_just_location, trace_pass_command): Constify.
3020 (info_breakpoints_command): Add non-const overload.
3021 * tracefile.c (tsave_command): Constify.
3022 * infcmd.c (attach_command, disconnect_command, signal_command)
3023 (queue_signal_command, stepi_command, nexti_command)
3024 (finish_command, next_command, step_command, until_command)
3025 (advance_command, jump_command, continue_command, run_command)
3026 (start_command, starti_command, interrupt_command)
3027 (run_command_1, set_inferior_args, step_1): Constify.
3028 * inferior.c (add_inferior_command, remove_inferior_command)
3029 (clone_inferior_command): Constify.
3030 * linux-fork.c (checkpoint_command, restart_command): Constify.
3031 * windows-nat.c (signal_event_command): Constify.
3032 * guile/guile.c (guile_repl_command, guile_command): Constify.
3033 * printcmd.c (x_command, display_command, printf_command)
3034 (output_command, set_command, call_command, print_command)
3035 (eval_command): Constify.
3036 (non_const_set_command): Remove.
3037 (_initialize_printcmd): Update.
3038 * source.c (forward_search_command, reverse_search_command):
3039 Constify.
3040 * jit.c (jit_reader_load_command, jit_reader_unload_command):
3041 Constify.
3042 * infrun.c (handle_command): Constify.
3043 * memattr.c (mem_command): Constify.
3044 * stack.c (return_command, up_command, up_silently_command)
3045 (down_command, down_silently_command, frame_command)
3046 (backtrace_command, func_command, backtrace_command_1): Constify.
3047 (backtrace_command): Add non-const overload.
3048 * remote-sim.c (simulator_command): Constify.
3049 * exec.c (set_section_command): Constify.
3050 * tracepoint.c (tdump_command, trace_variable_command)
3051 (tstatus_command, tstop_command, tstart_command)
3052 (end_actions_pseudocommand, while_stepping_pseudocommand)
3053 (collect_pseudocommand, teval_pseudocommand, actions_command)
3054 (start_tracing, stop_tracing): Constify.
3055 * value.c (init_if_undefined_command): Constify.
3056 * tui/tui-stack.c (tui_update_command): Constify.
3057 * tui/tui-win.c (tui_refresh_all_command)
3058 (tui_set_tab_width_command, tui_set_win_height_command)
3059 (tui_set_focus_command, tui_scroll_forward_command)
3060 (tui_scroll_backward_command, tui_scroll_left_command)
3061 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
3062 (tui_set_win_height): Constify.
3063 * tui/tui-layout.c (tui_layout_command): Constify.
3064 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
3065 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
3066 (proc_untrace_sysexit_cmd): Constify.
3067 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
3068 (threadset_test_cmd, threadlist_update_test_cmd)
3069 (threadalive_test): Constify.
3070 * objc-lang.c (print_object_command): Constify.
3071 * command.h (add_com): Constify.
3072 * cli/cli-dump.c (restore_command): Constify.
3073 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
3074 (help_command, complete_command, shell_command, edit_command)
3075 (list_command, disassemble_command, make_command)
3076 (apropos_command, alias_command): Constify.
3077 * cli/cli-script.c (document_command, define_command)
3078 (while_command, if_command, validate_comname): Constify.
3079 * cli/cli-decode.c (struct cmd_list_element): Change type of
3080 "fun".
3081 * target.c (do_monitor_command, flash_erase_command): Constify.
3082 * regcache.c (reg_flush_command): Constify.
3083 * reverse.c (reverse_step, reverse_next, reverse_stepi)
3084 (reverse_nexti, reverse_continue, reverse_finish)
3085 (save_bookmark_command, goto_bookmark_command)
3086 (exec_reverse_once): Constify.
3087 * python/python.c (python_interactive_command, python_command):
3088 Constify.
3089 * typeprint.c (ptype_command, whatis_command, whatis_exp):
3090 Constify.
3091 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
3092 * gcore.c (gcore_command): Constify.
3093
85c4be7c
TT
30942017-11-07 Tom Tromey <tom@tromey.com>
3095
3096 * printcmd.c (x_command): Call set_repeat_arguments.
3097 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
3098 * top.c (repeat_arguments): New global.
3099 (set_repeat_arguments): New function.
3100 (execute_command): Handle repeat_arguments.
3101 (show_commands): Calls set_repeat_arguments.
3102 * command.h (set_repeat_arguments): Declare.
3103
022643b4
TT
31042017-11-07 Tom Tromey <tom@tromey.com>
3105
3106 * stack.c (backtrace_command): Use std::string.
3107 (backtrace_command_1): Make "count_exp" const.
3108
5614fb77
TT
31092017-11-07 Tom Tromey <tom@tromey.com>
3110
3111 * source.c (directory_switch, mod_path, add_path): Constify.
3112 * defs.h (add_path, mod_path, directory_switch): Constify.
3113 * mi/mi-cmd-env.c (env_mod_path): Constify.
3114
6be9a197
TT
31152017-11-07 Tom Tromey <tom@tromey.com>
3116
3117 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
3118 (run_command_1, continue_command, step_1, jump_command)
3119 (signal_command, until_command, advance_command, finish_command)
3120 (attach_command): Update.
3121
c2252c0d
TT
31222017-11-07 Tom Tromey <tom@tromey.com>
3123
3124 * command.h (set_cmd_cfunc): Don't declare.
3125 * cli/cli-decode.c (set_cmd_cfunc): Now static.
3126
1ee870c5
TT
31272017-11-07 Tom Tromey <tom@tromey.com>
3128
3129 * stack.c (select_frame_command): Constify.
3130 * cli/cli-decode.c (add_com_suppress_notification): Constify.
3131 * command.h (add_com_suppress_notification): Constify.
3132
ee7ddd71
TT
31332017-11-07 Tom Tromey <tom@tromey.com>
3134
3135 * breakpoint.c (stop_command): Constify.
3136 * cli/cli-decode.c (struct cmd_list_element): Constify.
3137 * command.h (add_abbrev_prefix_cmd): Constify.
3138
95e95a6d
PA
31392017-11-07 Pedro Alves <palves@redhat.com>
3140
3141 * breakpoint.c (extract_bp_kind): New enum.
3142 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
3143 factored out from ...
3144 (extract_bp_number_and_location): ... here.
3145 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
3146
cc638e86
PA
31472017-11-07 Pedro Alves <palves@redhat.com>
3148
3149 * breakpoint.c (extract_bp_number_and_location): Change return
3150 type to void. Throw error instead of warning.
3151 (enable_disable_command): Adjust.
3152
d0fe4701
XR
31532017-11-07 Xavier Roirand <roirand@adacore.com>
3154 Pedro Alves <palves@redhat.com>
3155
3156 * breakpoint.c (map_breakpoint_number_range): New, factored out
3157 from ...
3158 (map_breakpoint_numbers): ... here.
3159 (find_location_by_number): Change parameters from string to
3160 breakpoint number and location.
3161 (extract_bp_number_and_location): New function.
3162 (enable_disable_bp_num_loc)
3163 (enable_disable_breakpoint_location_range)
3164 (enable_disable_command): New functions, factored out ...
3165 (enable_command, disable_command): ... these functions, and
3166 adjusted to support ranges.
3167 * NEWS: Document enable/disable breakpoint location range feature.
3168
635dc5b2
LM
31692017-11-06 Luis Machado <luis.machado@linaro.org>
3170
3171 * MAINTAINERS (Write After Approval): Update my e-mail address.
3172
556e5da5
PA
31732017-11-06 Pedro Alves <palves@redhat.com>
3174
3175 * gnu-nat.c (gnu_terminal_init): Delete.
3176 (gnu_target): Don't install gnu_terminal_init.
3177 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
3178 (child_terminal_init): ... this function.
3179
d1928160
PA
31802017-11-06 Pedro Alves <palves@redhat.com>
3181
3182 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
3183 sgtty.h.
3184 * config.in, configure: Regenerate.
3185
6aa899ce
PA
31862017-11-06 Pedro Alves <palves@redhat.com>
3187
3188 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
3189 (async_init_signals): Adjust.
3190 (handle_stop_sig): Rename to ...
3191 (handle_sigtstp): ... this.
3192 (async_stop_sig): Rename to ...
3193 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3194 SIGTSTP path.
3195 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3196 instead of STOP_SIGNAL thoughout.
3197 (handle_stop_sig): Rename to ...
3198 (handle_sigtstp): ... this.
3199 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3200
a94799ac
PA
32012017-11-06 Pedro Alves <palves@redhat.com>
3202
3203 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3204 longer set flags twice in row.
3205
726e1356
PA
32062017-11-06 Pedro Alves <palves@redhat.com>
3207
3208 * Makefile.in (SER_HARDWIRE): Update comment.
3209 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3210 * common/gdb_termios.h: Delete file.
3211 * common/job-control.c: Include termios.h and unistd.h instead of
3212 gdb_termios.h.
3213 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3214 check.
3215 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3216 Remove sgtty code.
3217 * configure.ac: No longer check for termio.h and sgtty.h.
3218 * configure: Regenerate.
3219 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3220 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3221 Replace PROCESS_GROUP_TYPE references with pid_t references
3222 throughout.
3223 (gdb_getpgrp): Delete.
3224 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3225 (child_terminal_inferior): Remove comment. Remove sgtty code.
3226 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3227 gdb_getpgrp. Use serial_set_tty_state instead aof
3228 serial_noflush_set_tty_state. Remove sgtty code.
3229 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3230 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3231 (inferior_process_group): Now returns pid_t.
3232 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3233 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3234 * ser-event.c (serial_event_ops): Update.
3235 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3236 (dos_ops): Update.
3237 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3238 * ser-pipe.c (pipe_ops): Update.
3239 * ser-tcp.c (tcp_ops): Update.
3240 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3241 HAVE_TERMIOS checks.
3242 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3243 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3244 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3245 assume termios.
3246 (hardwire_noflush_set_tty_state): Delete.
3247 (hardwire_print_tty_state, hardwire_drain_output)
3248 (hardwire_flush_output, hardwire_flush_input)
3249 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3250 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3251 code, and assume termios.
3252 (hardwire_ops): Update.
3253 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3254 * serial.c (serial_noflush_set_tty_state): Delete.
3255 * serial.h (serial_noflush_set_tty_state): Delete.
3256 (serial_ops::noflush_set_tty_state): Delete.
3257
1cfb73db
UW
32582017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3259
3260 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3261 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3262 (COMMON_OBS): Remove doublest.o and dfp.o.
3263 Do not build target-float.c (instead of doublest.c)
3264 with -Wformat-nonliteral.
3265
3266 * doublest.c: Remove file.
3267 * doublest.h: Remove file.
3268 * dfp.c: Remove file.
3269 * dfp.h: Remove file.
3270
3271 * target-float.c: Do not include "doublest.h" and "dfp.h".
3272 (DOUBLEST): Move here from doublest.h.
3273 (enum float_kind): Likewise.
3274 (FLOATFORMAT_CHAR_BIT): Likewise.
3275 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3276 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3277 (floatformat_precision): Likewise.
3278 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3279 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3280 Likewise.
3281 (host_float_format, host_double_format, host_long_double_format):
3282 Likewise.
3283 (floatformat_to_string, floatformat_from_string): Likewise.
3284 (floatformat_to_doublest): Likewise. Also, inline the original
3285 convert_floatformat_to_doublest.
3286 (floatformat_from_doublest): Likewise. Also, inline the original
3287 convert_floatformat_from_doublest.
3288
3289 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3290 (MAX_DECIMAL_STRING): Move here from dfp.c.
3291 (match_endianness): Likewise.
3292 (set_decnumber_context, decimal_check_errors): Likewise.
3293 (decimal_from_number, decimal_to_number): Likewise.
3294 (decimal_to_string, decimal_from_string): Likewise. Make static.
3295 (decimal_from_longest, decimal_from_ulongest): Likewise.
3296 (decimal_to_longest): Likewise.
3297 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3298 (decimal_convert): Likewise.
3299
b07e9c46
UW
33002017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3301
3302 * doublest.c: Do not include "gdbtypes.h".
3303 (extract_typed_floating): Remove.
3304 (store_typed_floating): Remove.
3305 (convert_typed_floating): Remove.
3306 * doublest.h (struct type): Remove.
3307 (DOUBLEST_PRINT_FORMAT): Remove.
3308 (DOUBLEST_SCAN_FORMAT): Remove.
3309 (extract_typed_floating): Remove.
3310 (store_typed_floating): Remove.
3311 (convert_typed_floating): Remove.
3312
3313 * dfp.c (decimal_from_doublest): Remove.
3314 (decimal_to_doublest): Remove.
3315 * dfp.h: Do not include "doublest.h".
3316 (decimal_from_doublest): Remove.
3317 (decimal_to_doublest): Remove.
3318
3319 * value.c: Do not include "doublest.h" and "dfp.h".
3320 (value_as_double): Remove.
3321 (unpack_double): Remove.
3322 (value_from_double): Remove.
3323 (value_from_decfloat): Remove.
3324 * value.h: Do not include "doublest.h".
3325 (value_as_double): Remove.
3326 (unpack_double): Remove.
3327 (value_from_double): Remove.
3328 (value_from_decfloat): Remove.
3329
3b2ca824
UW
33302017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3331
3332 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3333 (i386_extract_return_value): Use target_float_convert.
3334 (i386_store_return_value): Likewise.
3335 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3336 (i387_value_to_register): Likewise.
3337 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3338 (ia64_register_to_value): Use target_float_convert.
3339 (ia64_value_to_register): Likewise.
3340 (ia64_extract_return_value): Likewise.
3341 (ia64_store_return_value): Likewise.
3342 (ia64_push_dummy_call): Likewise.
3343 * m68k-tdep.c: Include "target-float.h".
3344 (m68k_register_to_value): Use target_float_convert.
3345 (m68k_value_to_register): Likewise.
3346 (m68k_svr4_extract_return_value): Likewise.
3347 (m68k_svr4_store_return_value): Likewise.
3348 * ppc-sysv-tdep.c: Include "target-float.h".
3349 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3350 (do_ppc_sysv_return_value): Likewise.
3351 (ppc64_sysv_abi_push_freg): Likewise.
3352 (ppc64_sysv_abi_return_value_base): Likewise.
3353 * rs6000-aix-tdep.c: Include "target-float.h".
3354 (rs6000_push_dummy_call): Use target_float_convert.
3355 (rs6000_return_value): Likewise.
3356 * rs6000-lynx178-tdep.c: Include "target-float.h".
3357 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3358 (rs6000_lynx178_return_value): Likewise.
3359 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3360 (rs6000_register_to_value): Use target_float_convert.
3361 (rs6000_value_to_register): Likewise.
3362 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3363 (arm_extract_return_value): Use target_float_convert.
3364 (arm_store_return_value): Likewise.
3365 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3366 (sh_register_convert_to_virtual): Use target_float_convert.
3367 (sh_register_convert_to_raw): Likewise.
3368 * sh64-tdep.c: Include "target-float.h".
3369 (sh64_extract_return_value): Use target_float_convert.
3370 (sh64_register_convert_to_virtual): Likewise.
3371 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3372
14ad9311
UW
33732017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3374
3375 * target-float.c (floatformat_to_host_double): New function.
3376 (floatformat_from_host_double): Likewise.
3377 (target_float_to_host_double): Likewise.
3378 (target_float_from_host_double): Likewise.
3379 * target-float.h (target_float_to_host_double): Add prototype.
3380 (target_float_from_host_double): Likewise.
3381
3382 * guile/scm-value.c: Include "target-float.h".
3383 (gdbscm_value_to_real): Use target_float_to_host_double.
3384 Handle integer source values via value_as_long.
3385 * guile/scm-math.c: Include "target-float.h". Do not include
3386 "doublest.h", "dfp.h", and "expression.h".
3387 (vlscm_convert_typed_number): Use target_float_from_host_double.
3388 (vlscm_convert_number): Likewise.
3389
3390 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3391 (convert_value_from_python): Use target_float_from_host_double.
3392
50eff16b
UW
33932017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3394
3395 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3396 (cast_from_fixed): Likewise.
3397 (ada_scaling_type): New function.
3398 (ada_delta): Return value instead of DOUBLEST. Perform target
3399 arithmetic instead of host arithmetic.
3400 (scaling_factor): Rename to ...
3401 (ada_scaling_factor) ... this. Make non-static. Return value instead
3402 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3403 (ada_fixed_to_float): Remove.
3404 (ada_float_to_fixed): Remove.
3405 * ada-lang.h (ada_fixed_to_float): Remove.
3406 (ada_float_to_fixed): Remove.
3407 (ada_delta): Return value instead of DOUBLEST.
3408 (ada_scaling_factor): Add prototype.
3409
3410 * ada-typeprint.c: Include "target-float.h".
3411 (print_fixed_point_type): Perform target arithmetic instead of
3412 host arithmetic.
3413 * ada-valprint.c: Include "target-float.h".
3414 (ada_val_print_num): Perform target arithmetic instead of
3415 host arithmetic for fixed-point types.
3416
66c02b9e
UW
34172017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3418
3419 * target-float.c: Include <math.h>.
3420 (floatformat_binop): New function.
3421 (floatformat_compare): Likewise.
3422 (target_float_binop): Likewise.
3423 (target_float_compare): Likewise.
3424 * target-float.h: Include "expression.h".
3425 (target_float_binop): Add prototype.
3426 (target_float_compare): Likewise.
3427
3428 * valarith.c: Do not include "doublest.h" and "dfp.h".
3429 Include "common/byte-vector.h".
3430 (value_args_as_decimal): Remove, replace by ...
3431 (value_args_as_target_float): ... this function. Handle both
3432 binary and decimal target floating-point formats.
3433 (scalar_binop): Handle both binary and decimal FP using
3434 value_args_as_target_float and target_float_binop.
3435 (value_equal): Handle both binary and decimal FP using
3436 value_args_as_target_float and target_float_compare.
3437 (value_less): Likewise.
3438 (value_pos): Handle all scalar types as simple copy.
3439 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3440 * dfp.c (decimal_binop): Throw error instead of internal_error
3441 when called with an unsupported operation code.
3442
f69fdf9b
UW
34432017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3444
3445 * target-float.c (target_float_to_string): New function.
3446 (target_float_from_string): New function.
3447 * target-float.h (target_float_to_string): Add prototype.
3448 (target_float_from_string): Add prototype.
3449
3450 * valprint.c: Include "target-float.h". Do not include
3451 "doublest.h" and "dfp.h".
3452 (print_floating): Use target_float_to_string.
3453 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3454 (printf_floating): Use target_float_to_string.
3455 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3456 (print_i387_value): Use target_float_to_string.
3457 * mips-tdep.c: Include "target-float.h".
3458 (mips_print_fp_register): Use target_float_to_string.
3459 * sh64-tdep.c: Include "target-float.h".
3460 (sh64_do_fp_register): Use target_float_to_string.
3461
3462 * parse.c: Include "target-float.h". Do not include
3463 "doublest.h" and "dfp.h".
3464 (parse_float): Use target_float_from_string.
3465 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3466 (define_symbol): Use target_float_from_string.
3467 * gdbarch-selftests.c: Include "target-float.h".
3468 (register_to_value_test): Use target_float_from_string.
3469
70100014
UW
34702017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3471
3472 * Makefile.c (SFILES): Add target-float.c.
3473 (HFILES_NO_SRCDIR): Add target-float.h.
3474 (COMMON_OBS): Add target-float.o.
3475 * target-float.h: New file.
3476 * target-float.c: New file.
3477
3478 * doublest.c (floatformat_classify): Fix detection of float_zero.
3479
3480 * gdbtypes.c (is_floating_type): New function.
3481 * gdbtypes.h (is_floating_type): Add prototype.
3482
3483 * value.c: Do not include "floatformat.h".
3484 (unpack_double): Use target_float_is_valid.
3485 (is_floating_value): New function.
3486 * value.h (is_floating_value): Add prototype-
3487
3488 * valarith.c: Include "target-float.h".
3489 (value_logical_not): Use target_float_is_zero.
3490
3491 * python/py-value.c: Include "target-float.h".
3492 (valpy_nonzero): Use target_float_is_zero.
3493
ab4b1c46
TT
34942017-11-04 Tom Tromey <tom@tromey.com>
3495
3496 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3497
454dafbd
TT
34982017-11-04 Tom Tromey <tom@tromey.com>
3499
3500 * breakpoint.c (set_momentary_breakpoint): Return
3501 breakpoint_up.
3502 (until_break_command): Update.
3503 (new_until_break_fsm): Change argument types to
3504 breakpoint_up.
3505 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3506 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3507 Remove.
3508 * infcmd.c (finish_forward): Update.
3509 * breakpoint.h (set_momentary_breakpoint)
3510 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3511 (make_cleanup_delete_breakpoint): Remove.
3512 (struct breakpoint_deleter): New.
3513 (breakpoint_up): New typedef.
3514 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3515 (insert_exception_resume_breakpoint): Update.
3516 (insert_exception_resume_from_probe): Update.
3517 (insert_longjmp_resume_breakpoint): Update.
3518 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3519 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3520 * infcall.c (call_function_by_hand_dummy): Update
3521
331b71e5
TT
35222017-11-04 Tom Tromey <tom@tromey.com>
3523
3524 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3525
9f584b37
TT
35262017-11-04 Tom Tromey <tom@tromey.com>
3527
3528 * linux-tdep.c (linux_core_info_proc_mappings): Use
3529 gdb::def_vector.
3530 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3531 "size" argument.
3532 (linux_corefile_thread): Update.
3533 (linux_make_corefile_notes): Remove unused variable.
3534
779bc38e
TT
35352017-11-04 Tom Tromey <tom@tromey.com>
3536
3537 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
3538 gdb::byte_vector.
3539
ed2b3126
TT
35402017-11-04 Tom Tromey <tom@tromey.com>
3541
3542 * objfiles.c (do_free_objfile_cleanup): Remove.
3543 * compile/compile-object-load.c (compile_object_load): Update.
3544 * objfiles.h (make_cleanup_free_objfile): Remove.
3545
7f6743fd
TT
35462017-11-04 Tom Tromey <tom@tromey.com>
3547
3548 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
3549 (adi_read_versions): Change "tags" to "gdb_byte *".
3550 (adi_print_versions): Likewise.
3551
c80049d3
TT
35522017-11-04 Tom Tromey <tom@tromey.com>
3553
3554 * breakpoint.c
3555 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
3556 from start_rbreak_breakpoints.
3557 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
3558 * breakpoint.h (class scoped_rbreak_breakpoints): New.
3559 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
3560 * symtab.c (do_end_rbreak_breakpoints): Remove.
3561 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
3562
167b0be1
TT
35632017-11-04 Tom Tromey <tom@tromey.com>
3564
3565 * cp-namespace.c (reset_directive_searched): Remove.
3566 (cp_lookup_symbol_via_imports): Use scoped_restore.
3567 * cp-support.c (reset_directive_searched): Remove.
3568 (make_symbol_overload_list_using): Use scoped_restore.
3569 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
3570 (reset_directive_searched): Remove.
3571
5eae7aea
TT
35722017-11-04 Tom Tromey <tom@tromey.com>
3573
3574 * symfile.c (find_separate_debug_file_by_debuglink): Use
3575 unique_xmalloc_ptr.
3576
c6bcad5f
TT
35772017-11-04 Tom Tromey <tom@tromey.com>
3578
3579 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
3580 type of "info".
3581 (compute_stack_depth): Likewise.
3582 (do_compile_dwarf_expr_to_c): Use std::vector.
3583
20dcd8ca
TT
35842017-11-04 Tom Tromey <tom@tromey.com>
3585
3586 * compile/compile-object-load.c (link_callbacks_einfo): Use
3587 std::string.
3588
33c7c59d
TT
35892017-11-04 Tom Tromey <tom@tromey.com>
3590
3591 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3592 Use scoped_free_pendings.
3593 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
3594 scoped_free_pendings.
3595 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
3596 (xcoff_initial_scan): Likewise.
3597 * buildsym.c (reset_symtab_globals): Update comment.
3598 (scoped_free_pendings): Rename from really_free_pendings.
3599 (prepare_for_building): Update comment.
3600 (buildsym_init): Likewise.
3601 * buildsym.h (class scoped_free_pendings): New class.
3602 (really_free_pendings): Don't declare.
3603
67fa57cf
UW
36042017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
3605
3606 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
3607 output when converting a zero value to a special byteorder format.
3608
f26ae15b
YQ
36092017-11-02 Yao Qi <yao.qi@linaro.org>
3610
3611 * frame.c (do_frame_register_read): Remove aspace.
3612 * jit.c (jit_frame_sniffer): Likwise.
3613 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3614 * regcache.c (regcache::regcache): Pass nullptr.
3615 (regcache_print): Caller updated.
3616 * regcache.h (regcache::regcache): Remove one constructor
3617 parameter aspace.
3618
6c6e9412
YQ
36192017-11-02 Yao Qi <yao.qi@linaro.org>
3620
3621 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
3622
8b86c959
YQ
36232017-11-02 Yao Qi <yao.qi@linaro.org>
3624
3625 * breakpoint.c (insert_single_step_breakpoints): Update.
3626 * frame.c (struct frame_info) <aspace>: Add const.
3627 (frame_save_as_regcache): Add const.
3628 (get_frame_address_space): Return const address_space *.
3629 * frame.h (get_frame_address_space): Update declaration.
3630 * infrun.c (struct step_over_info) <aspace>: Add const.
3631 (set_step_over_info): Make aspace const.
3632 (displaced_step_prepare_throw): Change variable const.
3633 (resume): Likewise.
3634 (proceed): Likewise.
3635 (adjust_pc_after_break): Likewise.
3636 (save_waitstatus): Likewise.
3637 (handle_signal_stop): Likewise.
3638 (keep_going_pass_signal): Likewise.
3639 * jit.c (jit_frame_sniffer): Add const.
3640 * mips-tdep.c (mips_single_step_through_delay): Likewise.
3641 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3642 * record-full.c (record_full_wait_1): Likewise.
3643 * regcache.c (regcache::regcache): Change parameter to const.
3644 * regcache.h (regcache::regcache): Likewise.
3645 (regcache::aspace): Return const address_space *.
3646 (regcache) <m_aspace>: Add const.
3647
a01bda52
YQ
36482017-11-02 Yao Qi <yao.qi@linaro.org>
3649
3650 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
3651 * frame.c (create_sentinel_frame): Likewise.
3652 * infrun.c (displaced_step_prepare_throw): Likewise.
3653 (resume): Likewise.
3654 (thread_still_needs_step_over_bp): Likewise.
3655 (proceed): Likewise.
3656 (do_target_wait): Likewise.
3657 (adjust_pc_after_break): Likewise.
3658 (handle_syscall_event): Likewise.
3659 (save_waitstatus): Likewise.
3660 (handle_inferior_event_1): Likewise.
3661 (handle_signal_stop): Likewise.
3662 (keep_going_pass_signal): Likewise.
3663 * linux-nat.c (status_callback): Likewise.
3664 (save_stop_reason): Likewise.
3665 (resume_stopped_resumed_lwps): Likewise.
3666 * record-full.c (record_full_exec_insn): Likewise.
3667 (record_full_wait_1): Likewise.
3668 * regcache.c (get_regcache_aspace): Remove.
3669 * regcache.h (get_regcache_aspace): Remove.
3670
d999647b
YQ
36712017-11-02 Yao Qi <yao.qi@linaro.org>
3672
3673 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
3674 (init_regcache_descr): Use gdbarch_num_regs.
3675 (regcache::regcache): Likewise.
3676 (regcache::get_register_status): Likewise.
3677 (regcache::assert_raw_regnum): Likewise.
3678 (regcache::cooked_read): Likewise.
3679 (regcache::cooked_read_value): Likewise.
3680 (regcache::cooked_write): Likewise.
3681 (regcache::dump): Likewise.
3682 (regcache::num_raw_registers): New method.
3683 * regcache.h (class regcache) <num_raw_registers>: New.
3684
4e888c28
YQ
36852017-11-02 Yao Qi <yao.qi@linaro.org>
3686
3687 * regcache.c (regcache::assert_regnum): New method.
3688 (regcache::invalidate): Call assert_regnum.
3689 (regcache::raw_update): Likewise.
3690 (regcache::raw_write): Likewise.
3691 (regcache::raw_read_part): Likewise.
3692 (regcache::raw_write_part): Likewise.
3693 (regcache::raw_supply): Likewise.
3694 (regcache::raw_supply_integer): Likewise.
3695 (regcache::raw_supply_zeroed): Likewise.
3696 (regcache::raw_collect): Likewise.
3697 (regcache::raw_collect_integer): Likewise.
3698 * regcache.h (regcache::assert_regnum): Declare.
3699
2e1b49b3
YQ
37002017-11-02 Yao Qi <yao.qi@linaro.org>
3701
3702 * regcache.c (regcache::dump): Remove code.
3703
6c5218df
YQ
37042017-11-02 Yao Qi <yao.qi@linaro.org>
3705
3706 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
3707 Remove.
3708 <sizeof_cooked_register_status>: Remove.
3709 (init_regcache_descr): Update.
3710 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
3711 (regcache::save): Likewise.
3712 (regcache::dump): Likewise.
3713
dcc31d28
JB
37142017-11-01 James Bowman <james.bowman@ftdichip.com>
3715
3716 * ft32-tdep.c (ft32_fetch_instruction): New function.
3717 (ft32_analyze_prologue): Use ft32_fetch_instruction().
3718
3a87ae65
SM
37192017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
3720
3721 * cli/cli-script.c (execute_control_command): Rename to ...
3722 (execute_control_command_1): ... this.
3723 (execute_control_command): New function.
3724
09b847f3
SM
37252017-10-31 Simon Marchi <simon.marchi@ericsson.com>
3726
3727 * tracepoint.c (tfind_command): Remove const_cast.
3728
f871c485
MG
37292017-10-30 Mike Gulick <mgulick@mathworks.com>
3730
3731 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
3732
b020ff80
SM
37332017-10-30 Simon Marchi <simon.marchi@ericsson.com>
3734
3735 * common/common-utils.h (in_inclusive_range): New function.
3736 * arm-tdep.c (arm_record_extension_space): Use
3737 in_inclusive_range.
3738 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
3739 * cris-tdep.c (cris_spec_reg_applicable): Use
3740 in_inclusive_range.
3741
1b81856f
PA
37422017-10-30 Pedro Alves <palves@redhat.com>
3743 Simon Marchi <simon.marchi@ericsson.com>
3744
3745 * remote.c (remote_set_syscall_catchpoint): Build a std::string
3746 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
3747
31b833b3
PA
37482017-10-30 Pedro Alves <palves@redhat.com>
3749
3750 * common/common-utils.c (string_appendf, string_vappendf): New
3751 functions.
3752 * common/common-utils.h (string_appendf, string_vappendf): New
3753 declarations.
3754 * unittests/common-utils-selftests.c (string_appendf_func)
3755 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
3756 (string_vappendf_tests): New functions.
3757 (_initialize_common_utils_selftests): Register "string_appendf" and
3758 "string_vappendf tests".
3759
4a250334
PA
37602017-10-30 Pedro Alves <palves@redhat.com>
3761
3762 * unittests/common-utils-selftests.c (format_func): New typedef.
3763 (string_printf_tests, string_vprintf_tests): Tests factored out
3764 and merged to ...
3765 (test_format_func): ... this new function.
3766 (string_printf_tests, string_vprintf_tests): Reimplement on top of
3767 test_format_func.
3768
16c5c17e
SM
37692017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3770
3771 * darwin-nat.c: Remove include of gdb.h.
3772
7ca51576
SM
37732017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3774
3775 * xtensa-xtregs.c: Fix formatting issues.
3776
c1342859
SM
37772017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3778
3779 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
3780
484d8d36
MD
37812017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
3782
3783 PR python/21213
3784 * python/py-infthread.c (thpy_get_inferior): Increment reference
3785 of inferior before returning it.
3786
b5540b5f
SM
37872017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3788
3789 * unittests/common-utils-selftests.c (format): Add
3790 ATTRIBUTE_PRINTF.
3791
5a9dcda1
SM
37922017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3793
3794 * xml-syscall.c (struct syscall_desc): Add constructor.
3795 <name>: Change type to std::string.
3796 (syscall_desc_up): New typedef.
3797 (syscall_desc_p): Remove typeder.
3798 (DEF_VEC_P(syscall_desc_p)): Remove.
3799 (struct syscall_group_desc): Add constructor.
3800 <name>: Change type to std::string.
3801 <syscalls>: Change type to std::vector.
3802 (syscall_group_desc_up): New typedef.
3803 (syscall_group_desc_p): Remove typedef.
3804 (DEF_VEC_P(syscall_group_desc_p)): Remove.
3805 (struct syscalls_info) <syscalls>: Change type to std::vector of
3806 unique_ptr.
3807 <groups>: Likewise.
3808 <my_gdb_datadir>: Change type to std::string.
3809 (syscalls_info_up): New typedef.
3810 (allocate_syscalls_info): Remove.
3811 (syscalls_info_free_syscalls_desc): Remove.
3812 (syscalls_info_free_syscall_group_desc): Remove.
3813 (free_syscalls_info): Remove.
3814 (make_cleanup_free_syscalls_info): Remove.
3815 (syscall_group_create_syscall_group_desc): Adjust.
3816 (syscall_group_add_syscall): Adjust.
3817 (syscall_create_syscall_desc): Adjust.
3818 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
3819 (init_syscalls_info): Adjust.
3820 (syscall_group_get_group_by_name): Adjust.
3821 (xml_get_syscall_number): Adjust.
3822 (xml_get_syscall_name): Adjust.
3823 (xml_list_of_syscalls): Adjust.
3824 (xml_list_syscalls_by_group): Adjust.
3825 (xml_list_of_groups): Adjust.
3826
45461e0d
SM
38272017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3828
3829 * probe.h: Don't include gdb_vecs.h.
3830 (DEF_VEC_P (probe_p)): Remove.
3831 (find_probes_in_objfile): Return an std::vector.
3832 * probe.c (find_probes_in_objfile): Likewise.
3833 * breakpoint.c (breakpoint_objfile_data)
3834 <longjmp_probes>: Change type to std::vector.
3835 <exception_probes>: Likewise.
3836 (free_breakpoint_probes): Don't manually free vectors.
3837 (create_longjmp_master_breakpoint): Adjust.
3838 (create_exception_master_breakpoint): Adjust.
3839 * solib-svr4.c (svr4_create_probe_breakpoints): Change
3840 parameter type, adjust.
3841 (svr4_create_solib_event_breakpoints): Adjust.
3842
43dce439
SM
38432017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3844
3845 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
3846 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
3847 with new.
3848 (free_breakpoint_probes): Rename to ...
3849 (free_breakpoint_objfile_data): ... this, and call delete on
3850 bp_objfile_data..
3851
6a1b9516
SM
38522017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3853
3854 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
3855 (loaded_script_ptr): Remove typedef.
3856 (DEF_VEC_P (loaded_script_ptr)): Remove.
3857 (struct collect_matching_scripts_data): Add constructor.
3858 <scripts_p>: Change type to (pointer to) std::vector.
3859 (collect_matching_scripts_data): Adjust.
3860 (sort_scripts_by_name): Make suitable for std::sort.
3861 (print_scripts): Don't sort vector, adjust to std::vector.
3862 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
3863
593e3209
SM
38642017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3865
3866 * symfile.c (filename_language): Make struct, not typedef. Add
3867 constructor.
3868 <ext>: Change type to std::string.
3869 (DEF_VEC_O (filename_language)): Remove.
3870 (filename_language_table): Change type to std::vector.
3871 (add_filename_language): Adjust.
3872 (set_ext_lang_command): Adjust.
3873 (info_ext_lang_command): Adjust.
3874 (deduce_language_from_filename): Adjust.
3875 (class scoped_restore_filename_language_table): Remove.
3876 (test_filename_language): Use scoped_restore.
3877 (test_set_ext_lang_command): Use scoped_restore, adjust to
3878 std::vector change.
3879
32fa66eb
SM
38802017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3881
3882 * symfile.c: Include selftest.h.
3883 (class scoped_restore_filename_language_table): New.
3884 (test_filename_language): New test.
3885 (test_set_ext_lang_command): New test.
3886 (_initialize_symfile): Register tests.
3887
4a27f119
KS
38882017-10-27 Keith Seitz <keiths@redhat.com>
3889
3890 * breakpoint.c (print_breakpoint_location): Use the symbol saved
3891 in the bp_location, falling back to find_pc_sect_function when
3892 needed.
3893 (add_location_to_breakpoint): Save sal->symbol.
3894 * breakpoint.h (struct bp_location) <symbol>: New field.
3895 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
3896 * symtab.h (struct symtab_and_line) <symbol>: New field.
3897
a43f3893
PF
38982017-10-26 Patrick Frants <osscontribute@gmail.com>
3899
7453e6b2 3900 PR gdb/13669
a43f3893
PF
3901 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
3902 to rewind obstack.
3903
23cc4e1b
PA
39042017-10-26 Pedro Alves <palves@redhat.com>
3905
3906 * remote.c (remote_async_terminal_ours_p): Delete.
3907 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
3908 Remove references to 'remote_async_terminal_ours_p'.
3909
6abc18bb
YQ
39102017-10-26 Yao Qi <yao.qi@linaro.org>
3911
3912 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
3913
bd522513
YQ
39142017-10-26 Yao Qi <yao.qi@linaro.org>
3915
3916 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
3917 aspace const.
3918 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
3919 Likewise.
3920 * breakpoint.c (bpstat_check_location): Remove cast.
3921 (breakpoint_hit_catch_fork): Make aspce const.
3922 (breakpoint_hit_catch_solib): Likewise.
3923 (breakpoint_hit_catch_exec): Likewise.
3924 (breakpoint_hit_ranged_breakpoint): Likewise.
3925 (breakpoint_hit_watchpoint): Likewise.
3926 (base_breakpoint_breakpoint_hit): Likewise.
3927 (bkpt_breakpoint_hit): Likewise.
3928 (dprintf_breakpoint_hit): Likewise.
3929 (tracepoint_breakpoint_hit): Likewise.
3930 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
3931
accd0bcd
YQ
39322017-10-26 Yao Qi <yao.qi@linaro.org>
3933
3934 * breakpoint.c (breakpoint_location_address_match): Change
3935 "struct address_space *" to "const address_space".
3936 (breakpoint_location_address_range_overlap): Likewise.
3937 (breakpoint_here_p): Likewise.
3938 (breakpoint_in_range_p): Likewise.
3939 (moribund_breakpoint_here_p): Likewise.
3940 (bp_location_inserted_here_p): Likewise.
3941 (software_breakpoint_inserted_here_p): Likewise.
3942 (hardware_breakpoint_inserted_here_p): Likewise.
3943 (hardware_watchpoint_inserted_in_range): Likewise.
3944 (bpstat_check_location): Likewise.
3945 (bpstat_stop_status): Likewise.
3946 (breakpoint_address_match): Likewise.
3947 (breakpoint_address_match_range): Likewise.
3948 (breakpoint_location_address_match): Likewise.
3949 (breakpoint_location_address_range_overlap): Likewise.
3950 (insert_single_step_breakpoint): Likewise.
3951 (breakpoint_has_location_inserted_here): Likewise.
3952 (single_step_breakpoint_inserted_here_p): Likewise.
3953 (pc_at_non_inline_function): Likewise.
3954 * breakpoint.h (bpstat_stop_status): Update declaration.
3955 (breakpoint_here_p): Likewise.
3956 (breakpoint_in_range_p): Likewise.
3957 (moribund_breakpoint_here_p): Likewise.
3958 (breakpoint_inserted_here_p): Likewise.
3959 (software_breakpoint_inserted_here_p): Likewise.
3960 (hardware_breakpoint_inserted_here_p): Likewise.
3961 (breakpoint_has_location_inserted_here): Likewise.
3962 (single_step_breakpoint_inserted_here_p): Likewise.
3963 (hardware_watchpoint_inserted_in_range): Likewise.
3964 (breakpoint_address_match): Likewise.
3965 (insert_single_step_breakpoint): Likewise.
3966 (pc_at_non_inline_function): Likewise.
3967 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
3968 * record.c (record_check_stopped_by_breakpoint): Likewise.
3969 * record.h (record_check_stopped_by_breakpoint): Likewise.
3970 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
3971
ac7936df
YQ
39722017-10-25 Yao Qi <yao.qi@linaro.org>
3973
3974 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
3975 regcache->arch () instead get_regcache_arch.
3976 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
3977 Likewise.
3978 (aarch64_fbsd_store_inferior_registers): Likewise.
3979 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
3980 (store_gregs_to_thread): Likewise.
3981 (fetch_fpregs_from_thread): Likewise.
3982 (store_fpregs_to_thread): Likewise.
3983 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
3984 (aarch64_store_return_value): Likewise.
3985 (aarch64_software_single_step): Likewise.
3986 * aix-thread.c (aix_thread_wait): Likewise.
3987 (supply_reg32): Likewise.
3988 (supply_sprs64): Likewise.
3989 (supply_sprs32): Likewise.
3990 (fill_gprs64): Likewise.
3991 (fill_gprs32): Likewise.
3992 (fill_sprs64): Likewise.
3993 (fill_sprs32): Likewise.
3994 (store_regs_user_thread): Likewise.
3995 (store_regs_kernel_thread): Likewise.
3996 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
3997 (alphabsd_store_inferior_registers): Likewise.
3998 * alpha-tdep.c (alpha_extract_return_value): Likewise.
3999 (alpha_store_return_value): Likewise.
4000 (alpha_deal_with_atomic_sequence): Likewise.
4001 (alpha_next_pc): Likewise.
4002 (alpha_software_single_step): Likewise.
4003 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
4004 (amd64bsd_store_inferior_registers): Likewise.
4005 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
4006 Likewise.
4007 (amd64_linux_store_inferior_registers): Likewise.
4008 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
4009 (amd64_collect_native_gregset): Likewise.
4010 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
4011 (amd64obsd_collect_uthread): Likewise.
4012 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
4013 (amd64_collect_fpregset): Likewise.
4014 (amd64_supply_fxsave): Likewise.
4015 (amd64_supply_xsave): Likewise.
4016 (amd64_collect_fxsave): Likewise.
4017 (amd64_collect_xsave): Likewise.
4018 * arc-tdep.c (arc_write_pc): Likewise.
4019 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
4020 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
4021 (arm_fbsd_store_inferior_registers): Likewise.
4022 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
4023 (store_vfp_regs): Likewise.
4024 (arm_linux_fetch_inferior_registers): Likewise.
4025 (arm_linux_store_inferior_registers): Likewise.
4026 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
4027 (arm_linux_sigreturn_next_pc): Likewise.
4028 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
4029 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
4030 (fetch_register): Likewise.
4031 (store_register): Likewise.
4032 * arm-tdep.c (arm_is_thumb): Likewise.
4033 (displaced_in_arm_mode): Likewise.
4034 (bx_write_pc): Likewise.
4035 (arm_get_next_pcs_addr_bits_remove): Likewise.
4036 (arm_software_single_step): Likewise.
4037 (arm_extract_return_value): Likewise.
4038 (arm_store_return_value): Likewise.
4039 (arm_write_pc): Likewise.
4040 * bfin-tdep.c (bfin_extract_return_value): Likewise.
4041 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
4042 (bsd_uthread_store_registers): Likewise.
4043 * core-regset.c (fetch_core_registers): Likewise.
4044 * corelow.c (get_core_registers): Likewise.
4045 * cris-tdep.c (cris_store_return_value): Likewise.
4046 (cris_extract_return_value): Likewise.
4047 (find_step_target): Likewise.
4048 (find_step_target): Likewise.
4049 (cris_software_single_step): Likewise.
4050 * ctf.c (ctf_fetch_registers): Likewise.
4051 * darwin-nat.c (cancel_breakpoint): Likewise.
4052 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
4053 * frv-tdep.c (frv_extract_return_value): Likewise.
4054 * ft32-tdep.c (ft32_store_return_value): Likewise.
4055 (ft32_extract_return_value): Likewise.
4056 * go32-nat.c (fetch_register): Likewise.
4057 (go32_fetch_registers): Likewise.
4058 (go32_store_registers): Likewise.
4059 (store_register): Likewise.
4060 * h8300-tdep.c (h8300_extract_return_value): Likewise.
4061 (h8300_store_return_value): Likewise.
4062 * hppa-linux-nat.c (fetch_register): Likewise.
4063 (store_register): Likewise.
4064 (hppa_linux_fetch_inferior_registers): Likewise.
4065 (hppa_linux_store_inferior_registers): Likewise.
4066 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
4067 (i386_darwin_store_inferior_registers): Likewise.
4068 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
4069 (gnu_store_registers): Likewise.
4070 * i386-linux-nat.c (fetch_register): Likewise.
4071 (store_register): Likewise.
4072 (supply_gregset): Likewise.
4073 (fill_gregset): Likewise.
4074 (i386_linux_fetch_inferior_registers): Likewise.
4075 (i386_linux_store_inferior_registers): Likewise.
4076 (i386_linux_resume): Likewise.
4077 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
4078 Likewise.
4079 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
4080 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
4081 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
4082 (i386obsd_collect_uthread): Likewise.
4083 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
4084 (i386_supply_gregset): Likewise.
4085 (i386_collect_gregset): Likewise.
4086 (i386_supply_fpregset): Likewise.
4087 (i386_collect_fpregset): Likewise.
4088 (i386_mpx_bd_base): Likewise.
4089 * i386-v4-nat.c (supply_fpregset): Likewise.
4090 (fill_fpregset): Likewise.
4091 * i387-tdep.c (i387_supply_fsave): Likewise.
4092 (i387_collect_fsave): Likewise.
4093 (i387_supply_fxsave): Likewise.
4094 (i387_collect_fxsave): Likewise.
4095 (i387_supply_xsave): Likewise.
4096 (i387_collect_xsave): Likewise.
4097 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
4098 (ia64_linux_store_registers): Likewise.
4099 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
4100 (ia64_extract_return_value): Likewise.
4101 (ia64_store_return_value): Likewise.
4102 (find_func_descr): Likewise.
4103 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
4104 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
4105 (inf_ptrace_store_registers): Likewise.
4106 * infrun.c (use_displaced_stepping): Likewise.
4107 (displaced_step_prepare_throw): Likewise.
4108 (resume): Likewise.
4109 (proceed): Likewise.
4110 (do_target_wait): Likewise.
4111 (adjust_pc_after_break): Likewise.
4112 (handle_inferior_event_1): Likewise.
4113 (handle_signal_stop): Likewise.
4114 (save_infcall_suspend_state): Likewise.
4115 (restore_infcall_suspend_state): Likewise.
4116 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
4117 * jit.c (jit_frame_prev_register): Likewise.
4118 * linux-nat.c (save_stop_reason): Likewise.
4119 (linux_nat_wait_1): Likewise.
4120 (resume_stopped_resumed_lwps): Likewise.
4121 * linux-record.c (record_linux_sockaddr): Likewise.
4122 (record_linux_msghdr): Likewise.
4123 (record_linux_system_call): Likewise.
4124 * linux-tdep.c (linux_collect_thread_registers): Likewise.
4125 * lm32-tdep.c (lm32_extract_return_value): Likewise.
4126 (lm32_store_return_value): Likewise.
4127 * m32c-tdep.c (m32c_read_flg): Likewise.
4128 (m32c_pseudo_register_read): Likewise.
4129 (m32c_pseudo_register_write): Likewise.
4130 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
4131 (m32r_linux_collect_gregset): Likewise.
4132 * m32r-tdep.c (m32r_store_return_value): Likewise.
4133 (m32r_extract_return_value): Likewise.
4134 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
4135 (m68kbsd_collect_fpregset): Likewise.
4136 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
4137 * m68k-linux-nat.c (fetch_register): Likewise.
4138 (old_fetch_inferior_registers): Likewise.
4139 (old_store_inferior_registers): Likewise.
4140 (store_regs): Likewise.
4141 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
4142 (m68k_svr4_store_return_value): Likewise.
4143 * m88k-tdep.c (m88k_store_arguments): Likewise.
4144 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
4145 (mi_cmd_data_write_register_values): Likewise.
4146 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
4147 (mips_fbsd_store_inferior_registers): Likewise.
4148 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
4149 (mips_fbsd_supply_gregs): Likewise.
4150 (mips_fbsd_collect_fpregs): Likewise.
4151 (mips_fbsd_collect_gregs): Likewise.
4152 (mips_fbsd_supply_fpregset): Likewise.
4153 (mips_fbsd_collect_fpregset): Likewise.
4154 (mips_fbsd_supply_gregset): Likewise.
4155 (mips_fbsd_collect_gregset): Likewise.
4156 * mips-linux-nat.c (supply_gregset): Likewise.
4157 (fill_gregset): Likewise.
4158 (supply_fpregset): Likewise.
4159 (fill_fpregset): Likewise.
4160 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
4161 (mips_fill_gregset): Likewise.
4162 (mips_supply_fpregset): Likewise.
4163 (mips_fill_fpregset): Likewise.
4164 (mips64_supply_gregset): Likewise.
4165 (micromips_linux_sigframe_validate): Likewise.
4166 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
4167 (mipsnbsd_fetch_inferior_registers): Likewise.
4168 (mipsnbsd_store_inferior_registers): Likewise.
4169 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
4170 (mipsnbsd_supply_gregset): Likewise.
4171 (mipsnbsd_iterate_over_regset_sections): Likewise.
4172 (mipsnbsd_supply_reg): Likewise.
4173 (mipsnbsd_supply_fpreg): Likewise.
4174 * mips-tdep.c (mips_in_frame_stub): Likewise.
4175 (mips_dummy_id): Likewise.
4176 (is_octeon_bbit_op): Likewise.
4177 (micromips_bc1_pc): Likewise.
4178 (extended_mips16_next_pc): Likewise.
4179 (mips16_next_pc): Likewise.
4180 (deal_with_atomic_sequence): Likewise.
4181 * moxie-tdep.c (moxie_process_readu): Likewise.
4182 * nios2-tdep.c (nios2_get_next_pc): Likewise.
4183 * nto-procfs.c (procfs_store_registers): Likewise.
4184 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
4185 (ppcfbsd_store_inferior_registers): Likewise.
4186 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
4187 (fetch_altivec_register): Likewise.
4188 (get_spe_registers): Likewise.
4189 (fetch_spe_register): Likewise.
4190 (fetch_altivec_registers): Likewise.
4191 (fetch_all_gp_regs): Likewise.
4192 (fetch_all_fp_regs): Likewise.
4193 (store_vsx_register): Likewise.
4194 (store_altivec_register): Likewise.
4195 (set_spe_registers): Likewise.
4196 (store_spe_register): Likewise.
4197 (store_altivec_registers): Likewise.
4198 (store_all_gp_regs): Likewise.
4199 (store_all_fp_regs): Likewise.
4200 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4201 (ppc_linux_collect_gregset): Likewise.
4202 (ppc_canonicalize_syscall): Likewise.
4203 (ppc_linux_record_signal): Likewise.
4204 (ppu2spu_prev_register): Likewise.
4205 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4206 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4207 (ppcobsd_store_registers): Likewise.
4208 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4209 Likewise.
4210 (ppc_ravenscar_generic_store_registers): Likewise.
4211 * procfs.c (procfs_fetch_registers): Likewise.
4212 (procfs_store_registers): Likewise.
4213 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4214 (ravenscar_store_registers): Likewise.
4215 (ravenscar_prepare_to_store): Likewise.
4216 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4217 * record-full.c (record_full_wait_1): Likewise.
4218 (record_full_registers_change): Likewise.
4219 (record_full_store_registers): Likewise.
4220 (record_full_core_fetch_registers): Likewise.
4221 (record_full_save): Likewise.
4222 (record_full_goto_insn): Likewise.
4223 * regcache.c (regcache_register_size): Likewise.
4224 (get_regcache_arch): Remove.
4225 (regcache_read_pc): Likewise.
4226 * regcache.h (get_regcache_arch): Remove.
4227 * remote-sim.c (gdbsim_fetch_register): Likewise.
4228 (gdbsim_store_register): Likewise.
4229 * remote.c (fetch_register_using_p): Likewise.
4230 (send_g_packet): Likewise.
4231 (remote_prepare_to_store): Likewise.
4232 (store_registers_using_G): Likewise.
4233 * reverse.c (save_bookmark_command): Likewise.
4234 (goto_bookmark_command): Likewise.
4235 * rs6000-aix-tdep.c (branch_dest): Likewise.
4236 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4237 (fetch_register): Likewise.
4238 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4239 (ppc_collect_reg): Likewise.
4240 (ppc_collect_gregset): Likewise.
4241 (ppc_collect_fpregset): Likewise.
4242 (ppc_collect_vsxregset): Likewise.
4243 (ppc_collect_vrregset): Likewise.
4244 (ppc_displaced_step_hw_singlestep): Likewise.
4245 (rs6000_pseudo_register_read): Likewise.
4246 (rs6000_pseudo_register_write): Likewise.
4247 * s390-linux-nat.c (supply_gregset): Likewise.
4248 (fill_gregset): Likewise.
4249 (s390_linux_fetch_inferior_registers): Likewise.
4250 * s390-linux-tdep.c (s390_write_pc): Likewise.
4251 (s390_software_single_step): Likewise.
4252 (s390_all_but_pc_registers_record): Likewise.
4253 (s390_linux_syscall_record): Likewise.
4254 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4255 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4256 (shnbsd_store_inferior_registers): Likewise.
4257 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4258 (sh_extract_return_value_fpu): Likewise.
4259 (sh_store_return_value_nofpu): Likewise.
4260 (sh_corefile_supply_regset): Likewise.
4261 (sh_corefile_collect_regset): Likewise.
4262 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4263 (sh64_store_return_value): Likewise.
4264 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4265 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4266 (sparc_store_inferior_registers): Likewise.
4267 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4268 (sparc_ravenscar_prepare_to_store): Likewise.
4269 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4270 (sparc_analyze_control_transfer): Likewise.
4271 (sparc_step_trap): Likewise.
4272 (sparc_software_single_step): Likewise.
4273 (sparc32_gdbarch_init): Likewise.
4274 (sparc_supply_rwindow): Likewise.
4275 (sparc_collect_rwindow): Likewise.
4276 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4277 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4278 (sparc64nbsd_collect_gregset): Likewise.
4279 (sparc64nbsd_supply_fpregset): Likewise.
4280 (sparc64nbsd_collect_fpregset): Likewise.
4281 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4282 (sparc64_supply_gregset): Likewise.
4283 (sparc64_collect_gregset): Likewise.
4284 (sparc64_supply_fpregset): Likewise.
4285 (sparc64_collect_fpregset): Likewise.
4286 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4287 * spu-tdep.c (spu_unwind_sp): Likewise.
4288 (spu2ppu_prev_register): Likewise.
4289 (spu_memory_remove_breakpoint): Likewise.
4290 * stack.c (return_command): Likewise.
4291 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4292 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4293 * tracefile.c (trace_save_ctf): Likewise.
4294 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4295 (do_windows_store_inferior_registers): Likewise.
4296 (windows_resume): Likewise.
4297 * xtensa-linux-nat.c (fill_gregset): Likewise.
4298 (supply_gregset_reg): Likewise.
4299 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4300 (xtensa_register_read_masked): Likewise.
4301 (xtensa_supply_gregset): Likewise.
4302 (xtensa_extract_return_value): Likewise.
4303 (xtensa_store_return_value): Likewise.
4304
edd079d9
UW
43052017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4306
4307 * doublest.c (floatformat_from_string): New function.
4308 * doublest.h (floatformat_from_string): Add prototype.
4309
4310 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4311 (OP_FLOAT): ... this.
4312 * expression.h: Do not include "doublest.h".
4313 (union exp_element): Replace doubleconst and decfloatconst by
4314 new element floatconst.
4315 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4316 (ada_evaluate_subexp): Likewise.
4317 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4318 OP_DOUBLE and OP_DECFLOAT.
4319 * expprint.c (print_subexp_standard): Likewise.
4320 (dump_subexp_body_standard): Likewise.
4321 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4322
4323 * parse.c: Include "dfp.h".
4324 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4325 (write_exp_elt_floatcst): New function.
4326 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4327 and OP_DECFLOAT.
4328 (operator_check_standard): Likewise.
4329 (parse_float): Do not accept suffix. Take type as input. Return bool.
4330 Return target format buffer instead of host DOUBLEST.
4331 Use floatformat_from_string and decimal_from_string to parse
4332 either binary or decimal floating-point types.
4333 (parse_c_float): Remove.
4334 * parser-defs.h: Do not include "doublest.h".
4335 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4336 (write_exp_elt_floatcst): Add prototype.
4337 (parse_float): Update prototype.
4338 (parse_c_float): Remove.
4339
4340 * c-exp.y: Do not include "dfp.h".
4341 (typed_val_float): Use byte buffer instead of DOUBLEST.
4342 (typed_val_decfloat): Remove.
4343 (DECFLOAT): Remove.
4344 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4345 (parse_number): Update to new parse_float interface.
4346 Parse suffixes and determine type before calling parse_float.
4347 Handle decimal and binary FP types the same way.
4348
4349 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4350 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4351 (parse_number): Update to new parse_float interface.
4352 Parse suffixes and determine type before calling parse_float.
4353
4354 * f-exp.y: Replace dval by typed_val_float.
4355 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4356 (parse_number): Use parse_float instead of atof.
4357
4358 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4359 (parse_go_float): Remove.
4360 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4361 (parse_number): Call parse_float instead of parse_go_float.
4362 Parse suffixes and determine type before calling parse_float.
4363
4364 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4365 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4366 (parse_number): Update to new parse_float interface.
4367 Parse suffixes and determine type before calling parse_float.
4368
4369 * m2-exp.y: Replace dval by byte buffer val.
4370 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4371 (parse_number): Call parse_float instead of atof.
4372
4373 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4374 (lex_number): Call parse_float instead of strtod.
4375 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4376 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4377 Use write_exp_elt_floatcst.
4378 (unit_testing): Remove static variable.
4379 (rust_type): Do not check unit_testing.
4380 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4381
4382 * ada-exp.y (type_float, type_double): Remove.
4383 (typed_val_float): Use byte buffer instead of DOUBLEST.
4384 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4385 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4386
cc628f3d
AH
43872017-10-25 Alan Hayward <alan.hayward@arm.com>
4388
4389 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4390 * arch/aarch64.h: New file.
4391
09a7c6aa
UW
43922017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4393
4394 * dfp.h (decimal_from_string): Use const reference for argument.
4395 * dfp.c (decimal_from_string): Likewise.
4396
8ba0dd51
UW
43972017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4398
4399 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4400 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4401 * mips-tdep.c (mips_print_fp_register): Likewise.
4402
16e812b2
UW
44032017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4404
4405 * common/format.h (enum argclass): Replace decfloat_arg by
4406 dec32float_arg, dec64float_arg, and dec128float_arg.
4407 * common/format.c (parse_format_string): Update to return
4408 new decimal float argument classes.
4409
4410 * printcmd.c (printf_decfloat): Rename to ...
4411 (printf_floating): ... this. Add argclass argument, and use it
4412 instead of parsing the format string again. Add support for
4413 binary floating-point values, using floatformat_to_string.
4414 Convert value to the target format if it doesn't already match.
4415 (ui_printf): Call printf_floating instead of printf_decfloat,
4416 also for double_arg / long_double_arg. Pass argclass.
4417
4418 * dfp.c (decimal_to_string): Add format string argument.
4419 * dfp.h (decimal_to_string): Likewise.
4420
4421 * doublest.c (floatformat_to_string): Add format string argument.
4422 * doublest.h (floatformat_to_string): Likewise.
4423
fdf0cbc2
UW
44242017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4425
4426 * doublest.c (floatformat_precision): New routine.
4427 (floatformat_to_string): Likewise.
4428 * doublest.c (floatformat_to_string): Add prototype.
4429
4430 * printcmd.c (print_scalar_formatted): Only call print_floating
4431 on floating-point types.
4432 * valprint.c: Do not include "floatformat.h".
4433 (generic_val_print_decfloat): Remove.
4434 (generic_val_print): Call generic_val_print_float for both
4435 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4436 (print_floating): Use floatformat_to_string. Handle decimal float.
4437 (print_decimal_floating): Remove, merge into floatformat_to_string.
4438 * value.h (print_decimal_floating): Remove.
4439
4440 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4441
5033013f
UW
44422017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4443
4444 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4445
a664f67e
SM
44462017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4447
4448 * memattr.h: Don't include vec.h.
4449 (struct mem_attrib): Initialize fields.
4450 <unknown>: New static method.
4451 (struct mem_region): Add constructors, operator<, initialize
4452 fields.
4453 * memattr.c: Include algorithm.
4454 (default_mem_attrib, unknown_mem_attrib): Remove.
4455 (user_mem_region_list): New global.
4456 (target_mem_region_list, mem_region_list): Change type to
4457 std::vector<mem_region>.
4458 (mem_use_target): Now a function.
4459 (target_mem_regions_valid): Change type to bool.
4460 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4461 (require_user_regions): Adjust.
4462 (require_target_regions): Adjust.
4463 (create_mem_region): Adjust.
4464 (lookup_mem_region): Adjust.
4465 (invalidate_target_mem_regions): Adjust.
4466 (mem_clear): Rename to...
4467 (user_mem_clear): ... this, and adjust.
4468 (mem_command): Adjust.
4469 (info_mem_command): Adjust.
4470 (mem_enable, enable_mem_command, mem_disable,
4471 disable_mem_command): Adjust.
4472 (mem_delete): Adjust.
4473 (delete_mem_command): Adjust.
4474 * memory-map.h (parse_memory_map): Return an std::vector.
4475 * memory-map.c (parse_memory_map): Likewise.
4476 (struct memory_map_parsing_data): Add constructor.
4477 <memory_map>: Point to std::vector.
4478 (memory_map_start_memory): Adjust.
4479 (memory_map_end_memory): Adjust.
4480 (memory_map_end_property): Adjust.
4481 (clear_result): Remove.
4482 * remote.c (remote_memory_map): Return an std::vector.
4483 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4484 Remove.
4485 (target_debug_print_mem_region_vector): New.
4486 * target-delegates.c: Regenerate.
4487 * target.h (mem_region_vector): New typedef.
4488 (to_memory_map): Return mem_region_vector.
4489 (target_memory_map): Return an std::vector.
4490 * target.c (target_memory_map): Return an std::vector.
4491 (flash_erase_command): Adjust.
4492
6e17c565
SM
44932017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4494
4495 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4496 Change type to std::string.
4497 (memory_map_start_property): Adjust.
4498 (memory_map_end_property): Adjust.
4499
cfba9872
SM
45002017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4501
4502 * infrun.h: Include common/byte-vector.h.
4503 (struct displaced_step_closure): New struct.
4504 (struct buf_displaced_step_closure): New struct.
4505 * infrun.c (displaced_step_closure::~displaced_step_closure):
4506 Provide default implementation.
4507 (displaced_step_clear): Deallocate step closure with delete.
4508 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4509 (aarch64_displaced_step_closure): ... this, extend
4510 displaced_step_closure.
4511 (aarch64_displaced_step_data) <dsc>: Change type to
4512 aarch64_displaced_step_closure.
4513 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4514 unique_ptr.
4515 (aarch64_displaced_step_fixup): Add cast for displaced step
4516 closure.
4517 * amd64-tdep.c (displaced_step_closure): Rename to ...
4518 (amd64_displaced_step_closure): ... this, extend
4519 displaced_step_closure.
4520 <insn_buf>: Change type to std::vector<gdb_byte>.
4521 <max_len>: Remove.
4522 (fixup_riprel): Change type of DSC parameter, adjust to type
4523 change of insn_buf.
4524 (fixup_displaced_copy): Change type of DSC parameter.
4525 (amd64_displaced_step_copy_insn): Instantiate
4526 amd64_displaced_step_closure.
4527 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4528 to type change of insn_buf.
4529 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4530 parameter DSC.
4531 (arm_linux_copy_svc): Likewise.
4532 (cleanup_kernel_helper_return): Likewise.
4533 (arm_catch_kernel_helper_return): Likewise.
4534 (arm_linux_displaced_step_copy_insn): Instantiate
4535 arm_displaced_step_closure.
4536 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4537 (displaced_read_reg): Change type of parameter DSC.
4538 (branch_write_pc): Likewise.
4539 (load_write_pc): Likewise.
4540 (alu_write_pc): Likewise.
4541 (displaced_write_reg): Likewise.
4542 (arm_copy_unmodified): Likewise.
4543 (thumb_copy_unmodified_32bit): Likewise.
4544 (thumb_copy_unmodified_16bit): Likewise.
4545 (cleanup_preload): Likewise.
4546 (install_preload): Likewise.
4547 (arm_copy_preload): Likewise.
4548 (thumb2_copy_preload): Likewise.
4549 (install_preload_reg): Likewise.
4550 (arm_copy_preload_reg): Likewise.
4551 (cleanup_copro_load_store): Likewise.
4552 (install_copro_load_store): Likewise.
4553 (arm_copy_copro_load_store) Likewise.
4554 (thumb2_copy_copro_load_store): Likewise.
4555 (cleanup_branch): Likewise.
4556 (install_b_bl_blx): Likewise.
4557 (arm_copy_b_bl_blx): Likewise.
4558 (thumb2_copy_b_bl_blx): Likewise.
4559 (thumb_copy_b): Likewise.
4560 (install_bx_blx_reg): Likewise.
4561 (arm_copy_bx_blx_reg): Likewise.
4562 (thumb_copy_bx_blx_reg): Likewise.
4563 (cleanup_alu_imm): Likewise.
4564 (arm_copy_alu_imm): Likewise.
4565 (thumb2_copy_alu_imm): Likewise.
4566 (cleanup_alu_reg): Likewise.
4567 (install_alu_reg): Likewise.
4568 (arm_copy_alu_reg): Likewise.
4569 (thumb_copy_alu_reg): Likewise.
4570 (cleanup_alu_shifted_reg): Likewise.
4571 (install_alu_shifted_reg): Likewise.
4572 (arm_copy_alu_shifted_reg): Likewise.
4573 (cleanup_load): Likewise.
4574 (cleanup_store): Likewise.
4575 (arm_copy_extra_ld_st): Likewise.
4576 (install_load_store): Likewise.
4577 (thumb2_copy_load_literal): Likewise.
4578 (thumb2_copy_load_reg_imm): Likewise.
4579 (arm_copy_ldr_str_ldrb_strb): Likewise.
4580 (cleanup_block_load_all): Likewise.
4581 (cleanup_block_store_pc): Likewise.
4582 (cleanup_block_load_pc): Likewise.
4583 (arm_copy_block_xfer): Likewise.
4584 (thumb2_copy_block_xfer): Likewise.
4585 (cleanup_svc): Likewise.
4586 (install_svc): Likewise.
4587 (arm_copy_svc): Likewise.
4588 (thumb_copy_svc): Likewise.
4589 (arm_copy_undef): Likewise.
4590 (thumb_32bit_copy_undef): Likewise.
4591 (arm_copy_unpred): Likewise.
4592 (arm_decode_misc_memhint_neon): Likewise.
4593 (arm_decode_unconditional): Likewise.
4594 (arm_decode_miscellaneous): Likewise.
4595 (arm_decode_dp_misc): Likewise.
4596 (arm_decode_ld_st_word_ubyte): Likewise.
4597 (arm_decode_media): Likewise.
4598 (arm_decode_b_bl_ldmstm): Likewise.
4599 (arm_decode_ext_reg_ld_st): Likewise.
4600 (thumb2_decode_dp_shift_reg): Likewise.
4601 (thumb2_decode_ext_reg_ld_st): Likewise.
4602 (arm_decode_svc_copro): Likewise.
4603 (thumb2_decode_svc_copro): Likewise.
4604 (install_pc_relative): Likewise.
4605 (thumb_copy_pc_relative_16bit): Likewise.
4606 (thumb_decode_pc_relative_16bit): Likewise.
4607 (thumb_copy_pc_relative_32bit): Likewise.
4608 (thumb_copy_16bit_ldr_literal): Likewise.
4609 (thumb_copy_cbnz_cbz): Likewise.
4610 (thumb2_copy_table_branch): Likewise.
4611 (cleanup_pop_pc_16bit_all): Likewise.
4612 (thumb_copy_pop_pc_16bit): Likewise.
4613 (thumb_process_displaced_16bit_insn): Likewise.
4614 (decode_thumb_32bit_ld_mem_hints): Likewise.
4615 (thumb_process_displaced_32bit_insn): Likewise.
4616 (thumb_process_displaced_insn): Likewise.
4617 (arm_process_displaced_insn): Likewise.
4618 (arm_displaced_init_closure): Likewise.
4619 (arm_displaced_step_fixup): Add cast for closure.
4620 * arm-tdep.h: Include infrun.h.
4621 (displaced_step_closure): Rename to ...
4622 (arm_displaced_step_closure): ... this, extend
4623 displaced_step_closure.
4624 <u::svc::copy_svc_os>: Change type of parameter DSC.
4625 <cleanup>: Likewise.
4626 (arm_process_displaced_insn): Likewise.
4627 (arm_displaced_init_closure): Likewise.
4628 (displaced_read_reg): Likewise.
4629 (displaced_write_reg): Likewise.
4630 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4631 Adjust.
4632 * i386-tdep.h: Include infrun.h.
4633 (i386_displaced_step_closure): New typedef.
4634 * i386-tdep.c (i386_displaced_step_copy_insn): Use
4635 i386_displaced_step_closure.
4636 (i386_displaced_step_fixup): Adjust.
4637 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
4638 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
4639 and unique_ptr.
4640 (ppc_displaced_step_fixup): Adjust.
4641 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
4642 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
4643 and unique_ptr.
4644 (s390_displaced_step_fixup): Adjust.
4645
b392b304
SM
46462017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4647
4648 * interps.h (interp_resume, interp_suspend, interp_set_temp):
4649 Remove declarations.
4650
d5833c62
TT
46512017-10-20 Tom Tromey <tom@tromey.com>
4652
4653 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
4654 std::vector.
4655 (gdb_bfd_record_inclusion): Update.
4656 (bfdp): Remove typedef.
4657
06d5bbc8
TT
46582017-10-20 Tom Tromey <tom@tromey.com>
4659
4660 * gdb_bfd.c (gdb_bfd_ref): Use new.
4661 (struct gdb_bfd_data): Add constructor, destructor, and member
4662 initializers.
4663 (gdb_bfd_unref): Use delete.
4664
2712ce2e
TT
46652017-10-20 Tom Tromey <tom@tromey.com>
4666
4667 * exec.c (exec_file_attach): Use new_bfd_ref.
4668 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
4669 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4670 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
4671 new_bfd_ref.
4672 * gdb_bfd.h (new_bfd_ref): New function.
4673
fcc8fb2f
PA
46742017-10-20 Pedro Alves <palves@redhat.com>
4675
4676 * main.c (captured_command_loop): Add attribute noinline.
4677
4c2287b0
SM
46782017-10-19 Simon Marchi <simon.marchi@ericsson.com>
4679
4680 * interps.c (struct interp_factory): Add constructor.
4681 (interp_factory_p): Remove typedef.
4682 (DEF_VEC_P(interp_factory_p)): Remove.
4683 (interpreter_factories): Change type to std::vector.
4684 (interp_factory_register): Adjust.
4685 (interp_lookup): Adjust.
4686 (interpreter_completer): Adjust.
4687
3d415c26
TT
46882017-10-19 Tom Tromey <tom@tromey.com>
4689
4690 * break-catch-syscall.c (catch_syscall_completer): Use
4691 std::string, gdb::unique_xmalloc_ptr.
4692
395423c4
TT
46932017-10-19 Tom Tromey <tom@tromey.com>
4694
4695 * infcall.c (call_function_by_hand_dummy): Use std::string.
4696
54f70bc1
TT
46972017-10-19 Tom Tromey <tom@tromey.com>
4698
4699 * mi/mi-main.c (mi_cmd_execute): Update.
4700 * top.h (prepare_execute_command): Return scoped_value_mark.
4701 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
4702 Add move constructor.
4703 * top.c (prepare_execute_command): Return scoped_value_mark.
4704 (execute_command): Update.
4705
63929e84
PA
47062017-10-19 Pedro Alves <palves@redhat.com>
4707
4708 * xml-support.c (xml_fetch_content_from_file): Check fread's
4709 return.
4710
a75868f5
PA
47112017-10-19 Pedro Alves <palves@redhat.com>
4712
4713 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
4714 async.
4715 (handle_error_fd): New function.
4716 (ser_base_async): Add/delete an event loop file handler for
4717 error_fd.
4718
2edf834e
PA
47192017-10-19 Pedro Alves <palves@redhat.com>
4720
4721 * xml-support.c (xml_fetch_content_from_file): Don't read in
4722 chunks. Instead use fseek to determine the file's size, and read
4723 it in one go.
4724
c8ba13ad
KS
47252017-11-18 Keith Seitz <keiths@redhat.com>
4726
4727 * c-exp.y (oper): Canonicalize conversion operators of user-defined
4728 types.
4729 Add whitespace to front of type name.
4730
37534686
KS
47312017-10-18 Keith Seitz <keiths@redhat.com>
4732
4733 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
4734 DW_AT_accessibility.
4735
28c7c158
YQ
47362017-10-18 Yao Qi <yao.qi@linaro.org>
4737
4738 * features/tic6x-c62x-linux.c: Remove.
4739
30f0b101
TT
47402017-10-17 Tom Tromey <tom@tromey.com>
4741
4742 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
4743 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
4744 (do_mixed_source_and_assembly): Likewise.
4745
57e12da9
TT
47462017-10-17 Tom Tromey <tom@tromey.com>
4747
4748 * regcache.c (regcache::xfer_part): Remove assertion.
4749
7b700999
PA
47502017-10-17 Pedro Alves <palves@redhat.com>
4751
4752 * xml-support.c (xml_fetch_content_from_file): Call
4753 unique_ptr::release() instead unique_ptr::get() when passing
4754 through xrealloc.
4755
d3037ba6
YQ
47562017-10-17 Yao Qi <yao.qi@linaro.org>
4757
4758 * regcache.c (regcache::xfer_part): Remove parameters read and
4759 write, add parameter is_raw. All callers are updated.
4760
83d5a34d
KS
47612017-10-16 Keith Seitz <keiths@redhat.com>
4762
4763 * c-typeprint.c (enum access_specifier): Moved here from
4764 c_type_print_base.
4765 (output_access_specifier): New function.
4766 (c_type_print_base): Consider typedefs when assessing
4767 whether access labels are needed.
4768 Use output_access_specifier as needed.
4769 Output access specifier for typedefs, if needed.
4770 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
4771 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
4772 fields.
4773 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
4774 accessor macros.
4775
87028b87
TT
47762017-10-16 Tom Tromey <tom@tromey.com>
4777
4778 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
4779 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
4780 * target.c (target_fileio_read_stralloc): Update.
4781 * sparc64-tdep.c (adi_is_addr_mapped): Update.
4782 * target.h (target_fileio_read_stralloc): Return
4783 unique_xmalloc_ptr.
4784
b7b030ad
TT
47852017-10-16 Tom Tromey <tom@tromey.com>
4786
4787 * xml-syscall.c (xml_init_syscalls_info): Update.
4788 * xml-support.c (xinclude_start_include): Update.
4789 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
4790 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
4791 (xml_fetch_content_from_file): Likewise.
4792 * osdata.c (get_osdata): Update.
4793 * target.h (target_read_stralloc, target_get_osdata): Return
4794 unique_xmalloc_ptr.
4795 * solib-aix.c (solib_aix_get_library_list): Update.
4796 * solib-target.c (solib_target_current_sos): Update.
4797 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
4798 * xml-tdesc.c (fetch_available_features_from_target): Update.
4799 (target_fetch_description_xml): Update.
4800 (file_read_description_xml): Update.
4801 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
4802 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
4803 (remote_pid_to_exec_file): Update.
4804 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
4805 (target_get_osdata): Likewise.
4806
b80406ac
TT
48072017-10-16 Tom Tromey <tom@tromey.com>
4808
4809 * remote.c (remote_register_number_and_offset): Use std::vector.
4810 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
4811 (putpkt_binary): Use gdb::def_vector.
4812 (compare_sections_command): Use gdb::byte_vector.
4813
a90ecff8
TT
48142017-10-16 Tom Tromey <tom@tromey.com>
4815
4816 * ppc-linux-nat.c (hwdebug_insert_point): Use
4817 gdb::unique_xmalloc_ptr, XDUP.
4818
2dc0e219
TT
48192017-10-16 Tom Tromey <tom@tromey.com>
4820
4821 * probe.c (parse_probes): Use std::string.
4822 (info_probes_for_ops, enable_probes_command)
4823 (disable_probes_command): Remove cleanups.
4824
b05628f0
TT
48252017-10-16 Tom Tromey <tom@tromey.com>
4826
4827 * buildsym.c (block_compar): Remove.
4828 (end_symtab_get_static_block): Use std::vector.
4829
a79b1bc6
SM
48302017-10-16 Simon Marchi <simon.marchi@ericsson.com>
4831
4832 * memrange.h (struct mem_range): Define operator< and operator==.
4833 (mem_range_s): Remove.
4834 (DEF_VEC_O (mem_range_s)): Remove.
4835 (normalize_mem_ranges): Change parameter type to std::vector.
4836 * memrange.c (compare_mem_ranges): Remove.
4837 (normalize_mem_ranges): Change parameter type to std::vector,
4838 adjust to vector change.
4839 * exec.c (section_table_available_memory): Return vector, remove
4840 parameter.
4841 (section_table_read_available_memory): Adjust to std::vector
4842 change.
4843 * remote.c (remote_read_bytes): Adjust to std::vector
4844 change.
4845 * tracepoint.h (traceframe_available_memory): Change parameter
4846 type to std::vector.
4847 * tracepoint.c (traceframe_available_memory): Change parameter
4848 type to std::vector, adjust.
4849 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
4850 std::vector change.
4851 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4852 unittests/memrange-selftests.c.
4853 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
4854 * gdb/unittests/memrange-selftests.c: New file.
4855
63f0e930
PA
48562017-10-16 Pedro Alves <palves@redhat.com>
4857
4858 * elfread.c (probe_key_free): Rename range-for variable.
4859 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
4860 (find_probe_by_pc, collect_probes): Rename range-for variable.
4861
c40c7bfc
YQ
48622017-10-16 Yao Qi <yao.qi@linaro.org>
4863
4864 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
4865 * features/tic6x-c62x.c: Remove.
4866 * features/tic6x-c64x-linux.c: Remove.
4867 * features/tic6x-c64x.c: Remove.
4868 * features/tic6x-c64xp-linux.c: Remove.
4869 * features/tic6x-c64xp.c: Remove.
4870 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
4871 initialize_tdesc_tic6x_*_linux functions.
4872 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
4873 initialize_tdesc_tic6x_* functions.
4874
df27ae6a
YQ
48752017-10-16 Yao Qi <yao.qi@linaro.org>
4876
4877 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
4878 tic6x-c62x.
4879 * regformats/tic6x-c62x.dat: Remove.
4880 * regformats/tic6x-c64x.dat: Remove.
4881 * regformats/tic6x-c64xp.dat: Remove.
4882
86766165
SM
48832017-10-15 Simon Marchi <simon.marchi@ericsson.com>
4884
4885 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
4886 (the !HAVE_LIBEXPAT version).
4887
824dfcc3
SM
48882017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4889
4890 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
4891 const.
4892
2098b393
SM
48932017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4894
4895 * target.h: Include tracepoint.h.
4896 (enum trace_find_type): Move to tracepoint.h.
4897 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
4898 * tracepoint.h: Don't include target.h
4899 (enum trace_find_type): Move from target.h.
4900 (parse_traceframe_info): Return a unique ptr.
4901 * tracepoint.c (current_traceframe_info): Change type to unique
4902 ptr.
4903 (free_traceframe_info): Remove.
4904 (clear_traceframe_info): Don't manually free
4905 current_traceframe_info.
4906 (free_result): Remove.
4907 (parse_traceframe_info): Return a unique ptr.
4908 (get_traceframe_info): Adjust to unique ptr.
4909 * ctf.c (ctf_traceframe_info): Return a unique ptr.
4910 * remote.c (remote_traceframe_info): Return a unique ptr.
4911 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
4912 ptr.
4913 * target-debug.h (target_debug_print_traceframe_info_up): New
4914 macro.
4915 * target-delegates.c: Regenerate.
4916
4cdd21a8
SM
49172017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4918
4919 * memrange.h (struct mem_range): Add constructors.
4920 * tracepoint.h (struct traceframe_info) <memory>: Change type to
4921 std::vector<mem_range>.
4922 * tracepoint.c (free_traceframe_info): Don't manually free
4923 vector.
4924 (traceframe_info_start_memory): Adjust to vector change.
4925 (traceframe_available_memory): Likewise.
4926 * tracefile-tfile.c (build_traceframe_info): Likewise.
4927 * ctf.c (ctf_traceframe_info): Likewise.
4928
d0d292a2
SM
49292017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4930
4931 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
4932 std::vector<int>.
4933 * tracepoint.c (free_traceframe_info): Deallocate with delete.
4934 (traceframe_info_start_tvar): Adjust to vector change.
4935 (parse_traceframe_info): Allocate with new.
4936 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
4937 vector change.
4938 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
4939 change.
4940 tfile_traceframe_info): Allocate with new.
4941 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
4942 change.
4943
8d3c73ef
SM
49442017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4945
4946 * tracepoint.c (traceframe_info): Rename to...
4947 (current_traceframe_info): ...this.
4948 (clear_traceframe_info): Adjust.
4949 (get_traceframe_info): Adjust.
4950
b129dcac
SM
49512017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4952
4953 * nat/linux-osdata.c: Include algorithm.
4954 (compare_processes): Remove.
4955 (struct pid_pgid_entry): New struct.
4956 (linux_xfer_osdata_processgroups): Use std::vector instead of
4957 XNEWVEC.
4958
af5bf4ad
SM
49592017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4960
4961 * objfiles.h: Don't include symfile.h.
4962 (struct partial_symbol): Remove forward-declaration.
4963 (struct objfile) <global_psymbols, static_psymbols>: Change type
4964 to std::vector<partial_symbol *>.
4965 * objfiles.c (objfile::objfile): Don't memset those fields.
4966 (objfile::~objfile): Don't free those fields.
4967 * psympriv.h (struct psymbol_allocation_list): Remove
4968 forward-declaration.
4969 (add_psymbol_to_list): Change psymbol_allocation_list parameter
4970 to std::vector.
4971 (start_psymtab_common): Change parameters to std::vector.
4972 * psymtab.c: Include algorithm.
4973 (require_partial_symbols): Call shrink_to_fit.
4974 (find_pc_sect_psymbol): Adjust to vector change.
4975 (match_partial_symbol): Likewise.
4976 (lookup_partial_symbol): Likewise.
4977 (psym_relocate): Likewise.
4978 (dump_psymtab): Likewise.
4979 (recursively_search_psymtabs): Likewise.
4980 (compare_psymbols): Remove.
4981 (sort_pst_symbols): Adjust to vector change.
4982 (start_psymtab_common): Likewise.
4983 (end_psymtab_common): Likewise.
4984 (psymbol_bcache_full): De-constify return value.
4985 (add_psymbol_to_bcache): Likewise.
4986 (extend_psymbol_list): Remove.
4987 (append_psymbol_to_list): Adjust to vector change.
4988 (add_psymbol_to_list): Likewise.
4989 (init_psymbol_list): Likewise.
4990 (maintenance_info_psymtabs): Likewise.
4991 (maintenance_check_psymtabs): Likewise.
4992 * symfile.h (struct psymbol_allocation_list): Remove.
4993 * symfile.c (reread_symbols): Adjust to vector change.
4994 * dbxread.c (start_psymtab): Change type of parameters.
4995 (dbx_symfile_read): Adjust to vector change.
4996 (read_dbx_symtab): Likewise.
4997 (start_psymtab): Change type of parameters.
4998 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
4999 (create_partial_symtab): Likewise.
5000 (add_partial_symbol): Likewise.
5001 (write_one_signatured_type): Likewise.
5002 (recursively_write_psymbols): Likewise.
5003 * mdebugread.c (parse_partial_symbols): Likewise.
5004 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
5005 (scan_xcoff_symtab): Adjust to vector change.
5006 (xcoff_initial_scan): Likewise.
5007
3ec5942f
SM
50082017-10-13 Simon Marchi <simon.marchi@ericsson.com>
5009
5010 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
5011
2399fe6a
YQ
50122017-10-13 Yao Qi <yao.qi@linaro.org>
5013
5014 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
5015 Remove s390x-*-expedite, add s390x-expedite.
5016
4bf3f4a8
YQ
50172017-10-13 Yao Qi <yao.qi@linaro.org>
5018
5019 * features/s390-gs-linux64.c: Regenerated.
5020 * features/s390x-gs-linux64.c: Regenerated.
5021
9e86da07
TT
50222017-10-13 Tom Tromey <tom@tromey.com>
5023
5024 * compile/compile-object-run.c (do_module_cleanup): Use delete.
5025 * solib.c (update_solib_list, reload_shared_libraries_1): Use
5026 delete.
5027 * symfile.c (symbol_file_add_with_addrs): Use new.
5028 (symbol_file_add_separate): Update comment.
5029 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
5030 * jit.c (jit_object_close_impl): Use new.
5031 (jit_unregister_code): Use delete.
5032 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
5033 (~objfile): Rename from free_objfile.
5034 (free_objfile_separate_debug, do_free_objfile_cleanup)
5035 (free_all_objfiles, objfile_purge_solibs): Use delete.
5036 * objfiles.h (struct objfile): Add constructor and destructor.
5037 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
5038 (allocate_objfile, free_objfile): Don't declare.
5039 (struct objstats): Add initializers.
5040
c2508e90
SM
50412017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5042
5043 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
5044 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
5045 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
5046 * gdbarch.h: Regenerate.
5047 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
5048 Adjust comment.
5049 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
5050 (i386_displaced_step_fixup): Adjust comment.
5051 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
5052
a900ff72
TT
50532017-10-12 Tom Tromey <tom@tromey.com>
5054
5055 * prologue-value.h (pv_area::store_would_trash): Return bool.
5056 (pv_area::find_reg): Likewise.
5057 * prologue-value.c (pv_area::store_would_trash): Return bool.
5058 (pv_area::find_reg): Likewise.
5059
f7b7ed97
TT
50602017-10-12 Tom Tromey <tom@tromey.com>
5061
5062 * s390-linux-tdep.c (s390_store, s390_load)
5063 (s390_check_for_saved, s390_analyze_prologue): Update.
5064 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
5065 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
5066 * prologue-value.h (class pv_area): Move from prologue-value.c.
5067 Change names of members. Add constructor, destructor, member
5068 functions.
5069 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
5070 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
5071 (pv_area_fetch, pv_area_scan): Don't declare.
5072 * prologue-value.c (struct pv_area::area_entry): Now member of
5073 pv_area.
5074 (struct pv_area): Move to prologue-value.h.
5075 (pv_area::pv_area): Rename from make_pv_area.
5076 (pv_area::~pv_area): Rename from free_pv_area.
5077 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
5078 (clear_entries, find_entry, overlaps, store_would_trash, store)
5079 (fetch, find_reg, scan): Now member of pv_area.
5080 Remove "area" argument. Update.
5081 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
5082 Update.
5083 * mn10300-tdep.c (push_reg, check_for_saved)
5084 (mn10300_analyze_prologue): Update.
5085 * mep-tdep.c (is_arg_spill, check_for_saved)
5086 (mep_analyze_prologue): Update.
5087 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
5088 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
5089 (m32c_is_struct_return, m32c_analyze_prologue): Update.
5090 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
5091 Update.
5092 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
5093 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
5094
466eecee
SM
50952017-10-12 Simon Marchi <simon.marchi@ericsson.com>
5096
5097 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
5098 * linux-nat.c (linux_nat_delete_thread): New variable.
5099 (lwp_free): Invoke linux_nat_delete_thread if set.
5100 (linux_nat_set_delete_thread): New function.
5101 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
5102 thread delete callback.
5103 * arm-linux-nat.c (arm_linux_delete_thread): New function.
5104 (_initialize_arm_linux_nat): Assign thread delete callback.
5105 * s390-linux-nat.c (s390_delete_thread): New function.
5106 (_initialize_s390_nat): Assign thread delete callback.
5107 * x86-linux-nat.c (x86_linux_add_target): Likewise.
5108 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
5109 function.
5110 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
5111 declaration.
5112 * nat/x86-linux.c (x86_linux_delete_thread): New function.
5113 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
5114
f71c8822
TT
51152017-10-09 Tom Tromey <tom@tromey.com>
5116
5117 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
5118 std::string.
5119 * tui/tui-layout.c (enum tui_status): Use std::string.
5120
981a3fb3
TT
51212017-10-11 Tom Tromey <tom@tromey.com>
5122
5123 * gdbthread.h (thread_command): Constify.
5124 * inferior.h (detach_command): Constify.
5125 * top.h (set_history, show_history): Constify.
5126 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
5127 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
5128 * bsd-kvm.c (bsd_kvm_cmd): Constify.
5129 * printcmd.c (set_command): Constify.
5130 (non_const_set_command): New function.
5131 * dcache.c (set_dcache_command, show_dcache_command): Constify.
5132 * breakpoint.c (enable_command, disable_command, delete_command)
5133 (catch_command, tcatch_command, set_breakpoint_cmd)
5134 (show_breakpoint_cmd): Constify.
5135 * macrocmd.c (macro_command): Constify.
5136 * infcmd.c (unset_command, kill_command, detach_command)
5137 (info_proc_cmd): Constify.
5138 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
5139 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
5140 (info_auto_load_cmd): Constify.
5141 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
5142 (unset_tdesc_cmd): Constify.
5143 * ada-lang.c (set_ada_command, show_ada_command)
5144 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
5145 * guile/guile.c (set_guile_command, show_guile_command)
5146 (info_guile_command): Constify.
5147 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
5148 Constify.
5149 * skip.c (skip_command): Constify.
5150 * compile/compile.c (_initialize_compile): Constify.
5151 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
5152 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
5153 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
5154 (maint_btrace_pt_show_cmd): Constify.
5155 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
5156 Constify.
5157 * python/python.c (user_show_python, user_set_python): Constify.
5158 * mips-tdep.c (set_mips_command, show_mips_command)
5159 (set_mipsfpu_command): Constify.
5160 * record-btrace.c (cmd_record_btrace_start)
5161 (cmd_set_record_btrace, cmd_show_record_btrace)
5162 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
5163 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
5164 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
5165 Constify.
5166 * symfile.c (overlay_command): Constify.
5167 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
5168 * cli/cli-logging.c (set_logging_command, show_logging_command):
5169 Constify.
5170 * cli/cli-dump.c (dump_command, append_command)
5171 (srec_dump_command, ihex_dump_command, verilog_dump_command)
5172 (tekhex_dump_command, binary_dump_command)
5173 (binary_append_command): Constify.
5174 * cli/cli-decode.c (struct cmd_list_element): Change type of
5175 "fun".
5176 * cli/cli-cmds.c (info_command, show_command, set_debug)
5177 (show_debug): Constify.
5178 (show_command): Add non-const overload.
5179 * top.c (set_history, show_history): Constify.
5180 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
5181 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
5182 * target.c (target_command): Constify.
5183 * sparc64-tdep.c (info_adi_command): Constify.
5184 * record-full.c (cmd_record_full_start): Constify.
5185 (set_record_full_command): Constify. Fix typo.
5186 (show_record_full_command): Constify.
5187 * thread.c (thread_command, thread_apply_command): Constify.
5188 * memattr.c (dummy_cmd): Constify.
5189 * value.c (function_command): Constify.
5190 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
5191 * probe.c (info_probes_command): Constify.
5192 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5193 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5194 (show_thread_cmd, set_thread_default_cmd)
5195 (show_thread_default_cmd): Constify.
5196 (check_empty): Constify.
5197 * tracepoint.c (tfind_command): Constify.
5198 * cp-support.c (maint_cplus_command): Constify.
5199 * windows-tdep.c (info_w32_command): Constify.
5200 * record.c (cmd_record_start, set_record_command)
5201 (show_record_command, info_record_command, cmd_record_goto):
5202 Constify.
5203 * ravenscar-thread.c (set_ravenscar_command)
5204 (show_ravenscar_command): Constify.
5205 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5206 Constify.
5207 (add_internal_problem_command): Remove casts.
5208 * arc-tdep.c (maintenance_print_arc_command): Constify.
5209 * valprint.c (set_print, show_print, set_print_raw)
5210 (show_print_raw): Constify.
5211 * maint.c (maintenance_command, maintenance_info_command)
5212 (maintenance_print_command, maintenance_set_cmd)
5213 (maintenance_show_cmd, set_per_command_cmd)
5214 (show_per_command_cmd, maintenance_check_command): Constify.
5215 * language.c (set_check, show_check): Constify.
5216 * typeprint.c (show_print_type, set_print_type): Constify.
5217 * go32-nat.c (go32_info_dos_command): Constify.
5218
fdf44873
TT
52192017-10-11 Tom Tromey <tom@tromey.com>
5220
5221 * breakpoint.c (prepare_re_set_context): Remove.
5222 (breakpoint_re_set_one): Update. Don't use cleanups.
5223 (breakpoint_re_set): Use scoped_restore, std::string, and
5224 scoped_restore_current_language.
5225
81b1e71c
TT
52262017-10-11 Tom Tromey <tom@tromey.com>
5227
5228 * breakpoint.c (commands_command_1): Use std::string.
5229 (cleanup_executing_breakpoints): Remove.
5230 (bpstat_do_actions_1): Use scoped_restore.
5231 (bpstat_check_watchpoint): Use std::string.
5232 (decode_static_tracepoint_spec): Likewise.
5233 (break_range_command): Likewise.
5234 (watch_command_1): Likewise.
5235 (compare_breakpoints): Change argument types.
5236 (clear_command): Use std::vector.
5237 (cleanup_executing_breakpoints): Remove.
5238 (update_global_location_list): Use unique_xmalloc_ptr.
5239 (strace_command): Remove unused declaration.
5240
4f9d9906
JB
52412017-10-11 John Baldwin <jhb@FreeBSD.org>
5242
5243 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5244 * NEWS: Mention new FreeBSD/arm native configuration.
5245 * configure.host: Add arm*-*-freebsd*.
5246 * configure.nat: Likewise.
5247 * arm-fbsd-nat.c: New file.
5248
7176dfd2
JB
52492017-10-11 John Baldwin <jhb@FreeBSD.org>
5250
5251 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5252 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5253 * NEWS: Mention new FreeBSD/arm target.
5254 * configure.tgt: Add arm*-*-freebsd*.
5255 * arm-fbsd-tdep.c: New file.
5256 * arm-fbsd-tdep.h: New file.
5257
fe220226
MR
52582017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5259
5260 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5261 `gdbarch_elfcore_write_linux_prpsinfo'.
5262 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5263 method.
5264 (elf_internal_linux_prpsinfo): Remove declaration.
5265 * gdbarch.h: Regenerate.
5266 * gdbarch.c: Regenerate.
5267
a2f63b2e
MR
52682017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5269
5270 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5271 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5272
458ca1d0
PA
52732017-10-11 Pedro Alves <palves@redhat.com>
5274
5275 * breakpoint.c (reattach_breakpoints): Delete.
5276 * breakpoint.h (reattach_breakpoints): Delete.
5277
905014d7
SM
52782017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5279
5280 * symfile.c (registered_sym_fns): Make struct, not typedef.
5281 (DEF_VEC_O (registered_sym_fns)): Remove.
5282 (symtab_fns): Change type to std::vector.
5283 (add_symtab_fns): Adjust.
5284 (find_sym_fns): Adjust.
5285
56d704da
AK
52862017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5287
5288 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5289 * arc-tdep.h (arc_arch_is_em): New function.
5290 (arc_arch_is_hs): Likewise.
5291
7fa29be9
EB
52922017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5293
5294 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5295 parentheses in the declaration.
5296 (macro_lookup_inclusion): Likewise.
5297 (macro_lookup_definition): Likewise.
5298 * p-lang.h (pascal_builtin_types): Likewise.
5299 * tui/tui-data.c (tui_win_list): Likewise.
5300 * tui/tui-data.h (tui_win_list): Likewise.
5301 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5302
d9b477e3
KB
53032017-10-11 Mark Rages <markrages@gmail.com>
5304
5305 * target-memory.c (block_boundaries): Fix for block address not
5306 aligned on block size.
5307
65630365
PA
53082017-10-10 Pedro Alves <palves@redhat.com>
5309 Tom Tromey <tom@tromey.com>
5310
5311 * breakpoint.c (struct captured_breakpoint_query_args)
5312 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5313 (print_breakpoint): New.
5314 * breakpoint.h (print_breakpoint): Declare.
5315 * common/common-exceptions.h (enum return_reason): Remove
5316 references to catch_exceptions.
5317 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5318 Delete.
5319 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5320 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5321 * gdb.h: Delete.
5322 * gdbthread.h (thread_select): Declare.
5323 * mi/mi-cmd-break.c: Don't include gdb.h.
5324 (breakpoint_notify): Use print_breakpoint.
5325 * mi/mi-cmd-catch.c: Don't include gdb.h.
5326 * mi/mi-interp.c: Don't include gdb.h.
5327 (mi_print_breakpoint_for_event): New.
5328 (mi_breakpoint_created, mi_breakpoint_modified): Use
5329 mi_print_breakpoint_for_event.
5330 * mi/mi-main.c: Don't include gdb.h.
5331 (mi_cmd_thread_select): Parse the global thread ID here. Use
5332 thread_select instead of gdb_thread_select.
5333 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5334 of using gdb_list_thread_ids.
5335 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5336 FILEIO_ENOSYS here.
5337 (remote_fileio_request): Use TRY/CATCH instead of
5338 catch_exceptions.
5339 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5340 (symbol_file_add_from_memory_wrapper): Delete.
5341 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5342 * thread.c: Don't include gdb.h.
5343 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5344 (thread_alive): Use thread_select.
5345 (do_captured_thread_select): Delete, parts salvaged as ...
5346 (thread_select): ... this new function.
5347 (gdb_thread_select): Delete.
5348
bf469271
PA
53492017-10-10 Pedro Alves <palves@redhat.com>
5350 Tom Tromey <tom@tromey.com>
5351
5352 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5353 and reverse logic.
5354 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5355 No longer macros. Instead ...
5356 (enum wp_check_result): They're now values of this new
5357 enumeration.
5358 (watchpoint_check): Change return type to wp_check_result and
5359 parameter type to bpstat.
5360 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5361 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5362 catch_errors. Reverse logic of watchpoint_check call.
5363 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5364 pointer as parameter.
5365 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5366 * common/common-exceptions.c (throw_exception_sjlj): Update
5367 comments to avoid mentioning catch_errors.
5368 * exceptions.c (catch_errors): Delete.
5369 * exceptions.h: Update comments to avoid mentioning catch_errors.
5370 (catch_errors_ftype, catch_errors): Delete.
5371 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5372 (hook_stop_stub): Delete.
5373 (restore_selected_frame): Change return type to void, and
5374 parameter type to const frame_id &.
5375 (restore_infcall_control_state): Use TRY/CATCH instead of
5376 catch_errors.
5377 * main.c (captured_command_loop): Return void and remove
5378 parameter. Remove references to catch_errors.
5379 (captured_main): Use TRY/CATCH instead of catch_errors.
5380 * objc-lang.c (objc_submethod_helper_data)
5381 (find_objc_msgcall_submethod_helper): Delete.
5382 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5383 catch_errors.
5384 * record-full.c (record_full_message): Return void.
5385 (record_full_message_args, record_full_message_wrapper): Delete.
5386 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5387 instead of catch_errors.
5388 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5389 parameter type to int.
5390 * solib-darwin.c (open_symbol_file_object): Ditto.
5391 * solib-dsbt.c (open_symbol_file_object): Ditto.
5392 * solib-frv.c (open_symbol_file_object): Ditto.
5393 * solib-svr4.c (open_symbol_file_object): Ditto.
5394 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5395 * solib.c (update_solib_list): Use TRY/CATCH instead of
5396 catch_errors.
5397 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5398 Change type.
5399 * symmisc.c (struct print_symbol_args): Remove.
5400 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5401 (print_symbol): Change type.
5402 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5403 and remove parameters.
5404 (catch_errors): New.
5405 (get_windows_debug_event): Adjust.
5406
1a56bfa5
TT
54072017-10-09 Tom Tromey <tom@tromey.com>
5408
5409 * mi/mi-main.c (free_splay_tree): Remove.
5410 (list_available_thread_groups): Use splay_tree_up.
5411 * common/gdb_splay_tree.h: New file.
5412
0c478e2d
TT
54132017-10-09 Tom Tromey <tom@tromey.com>
5414
5415 * mi/mi-main.c (do_nothing): Remove.
5416 (list_available_thread_groups): Update.
5417
cbd2b4e3
PA
54182017-10-09 Pedro Alves <palves@redhat.com>
5419
5420 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5421 reading registers when switching context.
5422
a181c0bf
JB
54232017-10-09 John Baldwin <jhb@FreeBSD.org>
5424
5425 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5426 (fbsd_convert_siginfo): Likewise.
5427 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5428
6e66f753
SM
54292017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5430
5431 * configure.ac (try_guile_versions): Remove guile-2.2.
5432 * configure: Regenerate.
5433
890e9790
TT
54342017-10-09 Tom Tromey <tom@tromey.com>
5435
5436 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5437 (COMPILE.pre): Use $(CXX).
5438
109483d9
PA
54392017-10-09 Pedro Alves <palves@redhat.com>
5440
5441 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5442 Use bool.
5443 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5444 * cp-support.h (cp_remove_params): Now returns a
5445 gdb::unique_xmalloc_ptr.
5446 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5447 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5448 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5449 returning a gdb::unique_xmalloc_ptr.
5450 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5451 * stack.c (find_frame_funname): Adjust to cp_remove_params
5452 returning a gdb::unique_xmalloc_ptr.
5453
791afaa2
TT
54542017-10-08 Tom Tromey <tom@tromey.com>
5455
5456 * dwarf2read.c (dwarf2_get_dwz_file): Use
5457 gdb::unique_xmalloc_ptr.
5458 (find_slot_in_mapped_hash): Likewise.
5459 (dwarf2_physname): Likewise.
5460 (create_dwo_unit_in_dwp_v1): Use std::string.
5461 (create_dwo_unit_in_dwp_v2): Likewise.
5462 (lookup_dwo_cutu): Likewise.
5463 (inherit_abstract_dies): Use std::vector.
5464 (read_array_type): Likewise.
5465 (dwarf_decode_macros): Remove unused declaration.
5466 (unsigned_int_compar): Remove.
5467 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5468 (psymtabs_addrmap_cleanup): Remove.
5469
30a9c02f
TT
54702017-10-08 Tom Tromey <tom@tromey.com>
5471
5472 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5473 * frame.h (frame_cleanup_after_sniffer): Declare.
5474 (frame_prepare_for_sniffer): Return void.
5475 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5476 type of argument.
5477 (frame_prepare_for_sniffer): Return void.
5478
757325a3
TT
54792017-10-08 Tom Tromey <tom@tromey.com>
5480
5481 * utils.h (make_cleanup_value_free): Remove.
5482 * utils.c (do_value_free, struct cleanup): Remove.
5483 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5484 Use gdb_value_up.
5485 * value.h (struct value_deleter): New.
5486 (gdb_value_up): New typedef.
5487
b9c04fb2
TT
54882017-10-08 Tom Tromey <tom@tromey.com>
5489
5490 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5491 (make_cleanup_free_search_symbols): Remove.
5492 (search_symbols): Return std::vector.
5493 (symbol_search::compare_search_syms): Now member of
5494 symbol_search. Change arguments.
5495 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5496 (symtab_symbol_info, rbreak_command): Update.
5497 * symtab.h (struct symbol_search) <next>: Remove.
5498 Add constructors.
5499 (symbol_search::operator<): New function.
5500 (symbol_search::operator==): New function.
5501 (search_symbols): Remove std::vector.
5502 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5503 (symbol_search::compare_search_syms): Declare.
5504
0d28b0a5
YQ
55052017-10-06 Yao Qi <yao.qi@linaro.org>
5506
5507 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5508 arch/aarch64-insn.o.
5509 Remove one rule.
5510 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5511
71917808
YQ
55122017-10-06 Yao Qi <yao.qi@linaro.org>
5513
5514 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5515 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5516 arch/arm-linux.o respectively.
5517 * configure.tgt: Likewise.
5518
2081b2b2
YQ
55192017-10-06 Yao Qi <yao.qi@linaro.org>
5520
5521 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5522 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5523
a1b85d28
PA
55242017-10-06 Pedro Alves <palves@redhat.com>
5525
5526 * windows-nat.c: Include <algorithm>.
5527
d97987e2
YQ
55282017-10-06 Yao Qi <yao.qi@linaro.org>
5529
5530 * configure.tgt (i386_tobjs): New variable.
5531 (amd64_tobjs): New variable.
5532 Set $cpu_obs and $os_obs.
5533
f38307f5
YQ
55342017-10-06 Yao Qi <yao.qi@linaro.org>
5535
5536 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5537 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
5538 (clean): Remove object files and dependency files.
5539 (distclean): Remove the directory.
5540 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5541 * configure: Re-generated.
5542 * configure.tgt: Replace amd64.o with arch/amd64.o.
5543
2f924de6
JM
55442017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
5545
5546 PR build/22188
5547 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
5548 and SETEND.
5549
2fd9d7ca
PA
55502017-10-05 Pedro Alves <palves@redhat.com>
5551
5552 * linux-nat.c (linux_child_follow_fork): When following the parent
5553 and detaching the child, consult the parent thread's architecture
5554 instead of the child's.
5555
d13b8493
UW
55562017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5557
5558 * ax.h: Do not include "doublest.h".
5559 (union agent_val): Remove.
5560
3b4b2f16
UW
55612017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5562
5563 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
5564 (decimal_to_string): Return std::string object.
5565 (decimal_from_string): Accept std::string object. Return bool.
5566 (decimal_from_integral, decimal_from_doublest): Remove.
5567 (decimal_from_longest): Add prototype.
5568 (decimal_from_ulongest): Likewise.
5569 (decimal_to_longest): Likewise.
5570 (decimal_from_doublest): Likewise.
5571 * dfp.c: Do not include "gdbtypes.h" or "value.h".
5572 (MAX_DECIMAL_STRING): Move here.
5573 (decimal_to_string): Return std::string object.
5574 (decimal_from_string): Accept std::string object. Return bool.
5575 (decimal_from_integral): Remove, replace by ...
5576 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
5577 (decimal_to_longest): New function.
5578 (decimal_from_floating): Remove, replace by ...
5579 (decimal_from_doublest): ... this new function.
5580 (decimal_to_doublest): Update to new decimal_to_string interface.
5581
5582 * value.c (unpack_long): Use decimal_to_longest.
5583 * valops.c (value_cast): Use decimal_from_doublest instead of
5584 decimal_from_floating. Use decimal_from_[u]longest isntead of
5585 decimal_from_integral.
5586 * valarith.c (value_args_as_decimal): Likewise.
5587 * valprint.c (print_decimal_floating): Update to new
5588 decimal_to_string interface.
5589 * printcmd.c (printf_decfloat): Likewise.
5590 * c-exp.y (parse_number): Update to new decimal_from_string interface.
5591
1841ee5d
UW
55922017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5593
5594 * doublest.h: Do not include "floatformat.h". Remove stale comments.
5595 * gdbtypes.c: Include "floatformat.h".
5596 * value.c: Likewise.
5597 * m68k-tdep.c: Likewise.
5598
5599 * findvar.c: Do not include "floatformat.h".
5600 * amd64-darwin-tdep.c: Likewise.
5601 * arm-linux-tdep.c: Likewise.
5602 * i386-darwin-tdep.c: Likewise.
5603 * i387-tdep.c: Likewise.
5604 * m68k-linux-tdep.c: Likewise.
5605 * mep-tdep.c: Likewise.
5606 * mips-tdep.c: Likewise.
5607 * nios2-tdep.c: Likewise.
5608 * s390-linux-tdep.c: Likewise.
5609 * sparc-obsd-tdep.c: Likewise.
5610 * sparc-tdep.c: Likewise.
5611 * sparc64-tdep.c: Likewise.
5612 * spu-tdep.c: Likewise.
5613 * tic6x-tdep.c: Likewise.
5614 * tilegx-tdep.c: Likewise.
5615 * vax-tdep.c: Likewise.
5616 * xstormy16-tdep.c: Likewise.
5617 * xtensa-tdep.c: Likewise.
5618
5619 * top.c: Do not include "doublest.h".
5620 * aarch64-tdep.c: Likewise.
5621 * alpha-tdep.c: Likewise.
5622 * arm-linux-tdep.c: Likewise.
5623 * m68k-linux-tdep.c: Likewise.
5624 * tilegx-tdep.c: Likewise.
5625 * xstormy16-tdep.c: Likewise.
5626
a80a6471
JB
56272017-10-05 John Baldwin <jhb@FreeBSD.org>
5628
5629 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
5630 (mipsn32_fbsd_sigframe): Define.
5631 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
5632 for FreeBSD/mipsn32.
5633
12c4bd7f
JB
56342017-10-05 John Baldwin <jhb@FreeBSD.org>
5635
5636 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
5637 AT_HWCAP.
5638
c91933e9
TG
56392017-10-05 Tristan Gingold <tgingold@free.fr>
5640
5641 * MAINTAINERS (Misc): Update my email address.
5642
5cd63fda
PA
56432017-10-04 Pedro Alves <palves@redhat.com>
5644
5645 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
5646 it instead of target_gdbarch.
5647 (get_remote_state, get_remote_packet_size): Adjust
5648 get_remote_arch_state calls, passing down target_gdbarch
5649 explicitly.
5650 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
5651 'gdbarch' and use it instead of target_gdbarch.
5652 (get_memory_packet_size): Adjust get_remote_arch_state calls,
5653 passing down target_gdbarch explicitly.
5654 (struct stop_reply) <arch>: New field.
5655 (remote_parse_stop_reply): Use the stopped thread's architecture,
5656 not the current inferior's. Save the architecture in the
5657 stop_reply.
5658 (process_stop_reply): Use the stop reply's architecture.
5659 (process_g_packet, remote_fetch_registers)
5660 (remote_prepare_to_store, store_registers_using_G)
5661 (remote_store_registers): Adjust get_remote_arch_state calls,
5662 using the regcache's architecture.
5663 (remote_get_trace_status): Adjust get_remote_arch_state calls,
5664 passing down target_gdbarch explicitly.
5665 * spu-multiarch.c (spu_thread_architecture): Defer to the target
5666 beneath instead of calling target_gdbarch.
5667 * target.c (default_thread_architecture): Use the specified
5668 inferior's architecture, instead of the current inferior's
5669 architecture (via target_gdbarch).
5670
ed4227b7
PA
56712017-10-04 Pedro Alves <palves@redhat.com>
5672
5673 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
5674 case.
5675 (regcache_print): Handle !target_has_registers here instead.
5676
55b11ddf
PA
56772017-10-04 Pedro Alves <palves@redhat.com>
5678
5679 * frame.c (create_test_frame): Delete.
5680 * frame.h (create_test_frame): Delete.
5681 * gdbarch-selftests.c: Include gdbthread.h and target.h.
5682 (class regcache_test): Delete.
5683 (test_target_has_registers, test_target_has_stack)
5684 (test_target_has_memory, test_target_prepare_to_store)
5685 (test_target_store_registers): New functions.
5686 (test_target_ops): New class.
5687 (register_to_value_test): Error out if there's already a
5688 process_stratum (or higher) target pushed. Create a fuller mock
5689 environment, with mock target_ops, inferior, address space, thread
5690 and inferior_ptid.
5691 * progspace.c (struct address_space): Move to ...
5692 * progspace.h (struct address_space): ... here.
5693 * regcache.h (regcache::~regcache, regcache::raw_write)
5694 [GDB_SELF_TEST]: No longer virtual.
5695
4c71c105
SM
56962017-10-04 Simon Marchi <simon.marchi@ericsson.com>
5697
5698 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
5699
73dcd72d
PA
57002017-10-04 Pedro Alves <palves@redhat.com>
5701
5702 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
5703 out of 'between TRY and CATCH'.
5704
44704526
PA
57052017-10-04 Pedro Alves <palves@redhat.com>
5706
5707 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
5708 * common/common-exceptions.h (TRY): Open an outermost scope.
5709 Expand intro comment.
5710 (CATCH): Reindent.
5711 (END_CATCH): Close the outermost scope.
5712 * completer.c (complete_line_internal): Add missing END_CATCH.
5713
bc3b087d
SDJ
57142017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5715
5716 * NEWS (Changes since GDB 8.0): Add entry about new
5717 'set-cwd-on-gdbserver' feature.
5718 (New remote packets): Add entry for QSetWorkingDir.
5719 * common/common-inferior.h (set_inferior_cwd): New prototype.
5720 * infcmd.c (set_inferior_cwd): Remove "static".
5721 (show_cwd_command): Expand text to include remote debugging.
5722 * remote.c: Add PACKET_QSetWorkingDir.
5723 (remote_protocol_features) <QSetWorkingDir>: New entry for
5724 PACKET_QSetWorkingDir.
5725 (extended_remote_set_inferior_cwd): New function.
5726 (extended_remote_create_inferior): Call
5727 "extended_remote_set_inferior_cwd".
5728 (_initialize_remote): Call "add_packet_config_cmd" for
5729 QSetWorkingDir.
5730
d092c5a2
SDJ
57312017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5732
5733 * NEWS (New commands): Mention "set/show cwd".
5734 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
5735 "cd" command's help text.
5736 * common/common-inferior.h (get_inferior_cwd): New prototype.
5737 * infcmd.c (inferior_cwd_scratch): New global variable.
5738 (set_inferior_cwd): New function.
5739 (get_inferior_cwd): Likewise.
5740 (set_cwd_command): Likewise.
5741 (show_cwd_command): Likewise.
5742 (_initialize_infcmd): Add "set/show cwd" commands.
5743 * inferior.h (class inferior) <cwd>: New field.
5744 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
5745 (fork_inferior): Change inferior's cwd before its execution.
5746 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
5747 to CreateProcess.
5748
7da0a886
SDJ
57492017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5750
5751 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
5752 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
5753 (COMMON_OBS): Add gdb_tilde_expand.o.
5754 * common/gdb_tilde_expand.c: New file.
5755 * common/gdb_tilde_expand.h: Likewise.
5756
db8dd160
MR
57572017-10-03 Maciej W. Rozycki <macro@imgtec.com>
5758
5759 * gdbarch.sh (objfile): Remove duplicate declaration.
5760 * gdbarch.h: Regenerate.
5761
f8bfbf22
TT
57622017-10-03 Tom Tromey <tom@tromey.com>
5763
5764 * utils.c (internal_vproblem): Use string_vprintf.
5765
5178ed48
TT
57662017-10-03 Tom Tromey <tom@tromey.com>
5767
5768 * printcmd.c (info_symbol_command): Use std::string.
5769
8cff8730
TT
57702017-10-03 Tom Tromey <tom@tromey.com>
5771
5772 * top.c (gdb_safe_append_history): Use std::string.
5773
895b8f30
TT
57742017-10-03 Tom Tromey <tom@tromey.com>
5775
5776 * event-top.c (stdin_event_handler): Update.
5777 * main.c (captured_main_1): Update.
5778 * top.h (make_delete_ui_cleanup): Remove.
5779 (struct ui): Add constructor and destructor.
5780 (new_ui, delete_ui): Remove.
5781 * top.c (make_delete_ui_cleanup): Remove.
5782 (new_ui_command): Use std::unique_ptr.
5783 (delete_ui_cleanup): Remove.
5784 (ui::ui): Rename from new_ui. Update.
5785 (free_ui): Remove.
5786 (ui::~ui): Rename from delete_ui. Update.
5787
0efef640
TT
57882017-10-03 Tom Tromey <tom@tromey.com>
5789
5790 * symfile.c (load_progress): Use gdb::byte_vector.
5791
245ad7d3
TT
57922017-10-03 Tom Tromey <tom@tromey.com>
5793
5794 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
5795 declaration.
5796 * printcmd.c (x_command): Remove unused declaration.
5797 * symfile.c (symbol_file_command): Remove unused declaration.
5798
e05550d7
TT
57992017-10-03 Tom Tromey <tom@tromey.com>
5800
5801 * utils.c (internal_vproblem): Use std::string.
5802 (defaulted_query): Likewise.
5803
b95de2b7
TT
58042017-10-03 Tom Tromey <tom@tromey.com>
5805
5806 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
5807 * top.c (execute_command_to_string): Update.
5808 * utils.c (make_cleanup_restore_page_info): Remove.
5809 (do_restore_page_info_cleanup): Remove.
5810 (set_batch_flag_and_restore_page_info):
5811 New.
5812 (make_cleanup_restore_page_info): Remove.
5813 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5814 (~set_batch_flag_and_restore_page_info): New
5815 (make_cleanup_restore_uinteger): Remove.
5816 (make_cleanup_restore_integer): Remove.
5817 (struct restore_integer_closure): Remove.
5818 (restore_integer): Remove.
5819 * utils.h (struct set_batch_flag_and_restore_page_info): New
5820 class.
5821 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5822 (make_cleanup_restore_page_info): Remove.
5823 (make_cleanup_restore_uinteger) Remove.
5824 (make_cleanup_restore_integer) Remove.
5825
07036511
TT
58262017-10-03 Tom Tromey <tom@tromey.com>
5827
5828 * record-full.h (record_full_gdb_operation_disable_set): Return
5829 scoped_restore_tmpl<int>.
5830 * infrun.c (adjust_pc_after_break): Update.
5831 (handle_signal_stop): Update.
5832 * record-full.c (record_full_gdb_operation_disable_set): Return
5833 scoped_restore_tmpl<int>.
5834 (record_full_wait_1, record_full_insert_breakpoint)
5835 (record_full_remove_breakpoint, record_full_save)
5836 (record_full_goto_insn): Update.
5837
45320ffa
TT
58382017-10-02 Tom Tromey <tom@tromey.com>
5839
5840 PR rust/22236:
5841 * rust-lang.c (rust_val_print_str): New function.
5842 (val_print_struct): Call it.
5843 (rust_subscript): Preserve name of slice type.
5844
b3e3859b
TT
58452017-10-02 Tom Tromey <tom@tromey.com>
5846
5847 * rust-lang.c (rust_subscript): Handle slices in
5848 EVAL_AVOID_SIDE_EFFECTS case.
5849
01af5e0d
TT
58502017-10-02 Tom Tromey <tom@tromey.com>
5851
5852 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
5853
888e3ddb
TT
58542017-10-02 Tom Tromey <tom@tromey.com>
5855
5856 * rust-lang.h (rust_slice_type): Add "extern".
5857
cc536b21
PA
58582017-10-02 Tom Tromey <tom@tromey.com>
5859 Pedro Alves <palves@redhat.com>
5860
5861 * ada-lang.h (ada_exc_info::operator<): Make const.
5862 (ada_exc_info::operator==): Make const.
5863 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
5864 Make const.
5865
386c8614
TT
58662017-09-29 Tom Tromey <tom@tromey.com>
5867
5868 * target.c (read_whatever_is_readable): Change type of "result".
5869 Update.
5870 (free_memory_read_result_vector): Remove.
5871 (read_memory_robust): Change return type. Update.
5872 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
5873 bin2hex, std::string.
5874 * target.h (memory_read_result_s): Remove typedef.
5875 (free_memory_read_result_vector): Remove.
5876 (read_memory_robust): Return std::vector.
5877
789c4b5e
TT
58782017-09-29 Tom Tromey <tom@tromey.com>
5879
5880 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
5881
ab816a27
TT
58822017-09-29 Tom Tromey <tom@tromey.com>
5883
5884 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
5885 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
5886 operator< and operator==.
5887 (ada_exceptions_list): Return a std::vector.
5888 * ada-lang.c (ada_exc_info::operator<): Rename from
5889 compare_ada_exception_info.
5890 (ada_exc_info::operator==): New.
5891 (sort_remove_dups_ada_exceptions_list): Change type of
5892 "exceptions".
5893 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
5894 (ada_add_global_exceptions): Likewise.
5895 (ada_exceptions_list_1): Return a std::vector.
5896 (ada_exceptions_list): Likewise.
5897
52f9abe4
TT
58982017-09-29 Tom Tromey <tom@tromey.com>
5899
5900 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
5901 'std::set *'.
5902 (print_one_inferior): Update.
5903 (free_vector_of_ints): Remove.
5904 (list_available_thread_groups): Change "ids" to std::set.
5905 (mi_cmd_list_thread_groups): Update.
5906 (struct collect_cores_data) <core>: Now a std::set.
5907 (collect_cores): Update.
5908 (unique): Remove.
5909 (print_one_inferior): Update.
5910
dcd5ddcc
TT
59112017-09-29 Tom Tromey <tom@tromey.com>
5912
5913 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
5914 (mi_execute_async_cli_command): Likewise.
5915 (mi_cmd_trace_frame_collected): Use field_fmt.
5916
45d288cc
TT
59172017-09-29 Tom Tromey <tom@tromey.com>
5918
5919 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
5920 gdb::byte_vector.
5921
6afe2f4a
TT
59222017-09-29 Tom Tromey <tom@tromey.com>
5923
5924 * mi/mi-parse.c (mi_parse): Remove unused declaration.
5925
9813429a
TT
59262017-09-29 Tom Tromey <tom@tromey.com>
5927
5928 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
5929
2d6960b4
TT
59302017-09-29 Tom Tromey <tom@tromey.com>
5931
5932 * varobj.h (varobj_gen_name): Return std::string.
5933 * varobj.c (varobj_gen_name): Return std::string.
5934 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
5935 (mi_cmd_var_delete): Don't copy "name".
5936
784c453a
TT
59372017-09-29 Tom Tromey <tom@tromey.com>
5938
5939 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
5940 (mi_cmd_break_insert_1): Update.
5941
a9bc57b9
TT
59422017-09-29 Tom Tromey <tom@tromey.com>
5943
5944 * target.h (make_scoped_defer_target_commit_resume): Update.
5945 * target.c (make_scoped_defer_target_commit_resume): Rename from
5946 make_cleanup_defer_target_commit_resume. Return a
5947 scoped_restore.
5948 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
5949
9754d8c4
TT
59502017-09-29 Tom Tromey <tom@tromey.com>
5951
5952 * main.c (captured_main_1): Remove unused declaration.
5953 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
5954
99ef965c
TT
59552017-09-29 Tom Tromey <tom@tromey.com>
5956
5957 * symtab.c (search_symbols): Remove unused outer cleanup.
5958 (make_source_files_completion_list): Remove unused declaration.
5959
42518ba7
TT
59602017-09-29 Tom Tromey <tom@tromey.com>
5961
5962 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
5963
726b2169
TT
59642017-09-29 Tom Tromey <tom@tromey.com>
5965
5966 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
5967 gdb::byte_vector.
5968
55b06432
TT
59692017-09-29 Tom Tromey <tom@tromey.com>
5970
5971 * complaints.c (vcomplaint): Use std::string.
5972
8abcee91
TT
59732017-09-29 Tom Tromey <tom@tromey.com>
5974
5975 * tracepoint.c (trace_variable_command): Use std::string.
5976 (encode_actions_1): Remove unused declarations.
5977 (create_tsv_from_upload): Use std::string.
5978
6ad94bc7
TT
59792017-09-29 Tom Tromey <tom@tromey.com>
5980
5981 * cp-support.c (gdb_demangle): Use std::string.
5982
2003f3d8
TT
59832017-09-29 Tom Tromey <tom@tromey.com>
5984
5985 * stack.c (parse_frame_specification): Use std::string
5986 (info_frame_command): Use gdb::unique_xmalloc_ptr.
5987
8f8accb5
TT
59882017-09-29 Tom Tromey <tom@tromey.com>
5989
5990 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
5991
200aa7b1
TT
59922017-09-29 Tom Tromey <tom@tromey.com>
5993
5994 * utils.c (vfprintf_maybe_filtered): Use std::string.
5995 (vfprintf_unfiltered): Likewise.
5996
606aae8a
TT
59972017-09-29 Tom Tromey <tom@tromey.com>
5998
5999 * event-top.c (top_level_prompt): Return std::string.
6000 (display_gdb_prompt): Update.
6001
bd413795
TT
60022017-09-29 Tom Tromey <tom@tromey.com>
6003
6004 * unittests/common-utils-selftests.c (format): New function.
6005 (string_vprintf_tests): New function.
6006 (_initialize_common_utils_selftests): Register new tests.
6007 * common/common-utils.c (string_vprintf): New function.
6008 * common/common-utils.h (string_vprintf): Declare.
6009
256642e8
PA
60102017-09-29 Pedro Alves <palves@redhat.com>
6011
6012 * common/rsp-low.c (unpack_varlen_hex): Constify.
6013 * common/rsp-low.h (unpack_varlen_hex): Constify.
6014 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
6015 Constify.
6016 * remote.c (remote_set_permissions, read_ptid)
6017 (remote_current_thread, remote_get_threads_with_qthreadinfo)
6018 (remote_static_tracepoint_marker_at)
6019 (remote_static_tracepoint_markers_by_strid)
6020 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
6021 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
6022 (parse_tracepoint_definition, parse_tsv_definition)
6023 (parse_static_tracepoint_marker_definition): Constify.
6024 * tracepoint.h (parse_static_tracepoint_marker_definition)
6025 (parse_trace_status, parse_tracepoint_status)
6026 (parse_tracepoint_definition, parse_tsv_definition): Constify.
6027
b6bb3468
PA
60282017-09-29 Pedro Alves <palves@redhat.com>
6029
6030 * remote.c (target_buf, target_buf_size): Delete.
6031 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
6032 Use the connection's packet buffer instead.
6033 All callers adjusted.
6034 (_initialize_remote): Remove references to target_buf and
6035 target_buf_size.
6036
b2f8eb7a
PA
60372017-09-28 Pedro Alves <palves@redhat.com>
6038
6039 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6040 unittests/common-utils-selftests.c.
6041 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
6042 (COMMON_OBS): Remove utils-selftests.o.
6043 * utils-selftests.c: Move to ...
6044 * unittests/common-utils-selftests.c: ... here and rename self
6045 test to "string_printf".
6046
08302ed2
DE
60472017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
6048
6049 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
6050 having NULL cus or tus.
6051
96a5a1d3
UW
60522017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6053
6054 * arm-tdep.c: (convert_from_extended): Remove.
6055 (convert_to_extended): Likewise.
6056 (arm_extract_return_value): Use convert_typed_floating.
6057 (arm_store_return_value): Likewise.
6058
6059 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6060 * sh-tdep.c: Do not include "floatformat.h".
6061 (sh_littlebyte_bigword_type): New function.
6062 (sh_register_convert_to_virtual): Use convert_typed_floating.
6063 (sh_register_convert_to_raw): Likewise.
6064 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
6065 (sh64_littlebyte_bigword_type): New function.
6066 (sh64_extract_return_value): Use convert_typed_floating.
6067 (sh64_register_convert_to_virtual): Likewise.
6068 (sh64_register_convert_to_raw): Likewise.
6069
0db7851f
UW
60702017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6071
6072 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
6073 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
6074
6075 * gdbtypes.h (union type_specific): Make field floatformat hold
6076 just a single struct floatformat, not an array.
6077 (floatformat_from_type): Move here.
6078 * gdbtypes.c (floatformat_from_type): Move here. Update to
6079 changed TYPE_FLOATFORMAT definition.
6080 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
6081 (recursive_dump_type): Likewise.
6082 (init_float_type): Install correct floatformat for byte order.
6083 (arch_float_type): Likewise.
6084
77b7c781
UW
60852017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
6086
6087 * gdbtypes.c (init_type): Change incoming argument from
6088 length-in-bytes to length-in-bits. Assert length is a
6089 multiple of TARGET_CHAR_BITS.
6090 (arch_type, arch_flags_type): Likewise.
6091 (init_integer_type): Update call to init_type.
6092 (init_character_type): Likewise.
6093 (init_boolean_type): Likewise.
6094 (init_float_type): Likewise.
6095 (init_decfloat_type): Likewise.
6096 (init_complex_type): Likewise.
6097 (init_pointer_type): Likewise.
6098 (objfile_type): Likewise.
6099 (arch_integer_type): Update call to arch_type.
6100 (arch_character_type): Likewise.
6101 (arch_boolean_type): Likewise.
6102 (arch_float_type): Likewise.
6103 (arch_decfloat_type): Likewise.
6104 (arch_complex_type): Likewise.
6105 (arch_pointer_type): Likewise.
6106 (gdbtypes_post_init): Likewise.
6107
6108 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
6109 (read_base_type): Likewise.
6110 * mdebugread.c (basic_type): Likewise.
6111 * stabsread.c (dbx_init_float_type): Likewise.
6112 (rs6000_builtin_type): Likewise.
6113 (read_range_type): Likewise. Also, fix call to init_integer_type
6114 with erroneous length argument.
6115
6116 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
6117 * d-lang.c (build_d_types): Likewise.
6118 * f-lang.c (build_fortran_types): Likewise.
6119 * go-lang.c (build_go_types): Likewise.
6120 * opencl-lang.c (build_opencl_types): Likewise.
6121 * jit.c (finalize_symtab): Likewise.
6122 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
6123 (build_std_type_info_type): Likewise.
6124 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
6125 update call to arch_flags_type.
6126
6127 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
6128 arch_type.
6129 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
6130 * windows-tdep.c (windows_get_tlb_type): Likewise.
6131
6132 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
6133 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6134 * m32c-tdep.c (make_types): Likewise.
6135 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
6136 (rl78_psw_type): Update call to arch_flags_type.
6137 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
6138 * rx-tdep.c (rx_psw_type): Likewise.
6139 (rx_fpsw_type): Likewise.
6140 * sparc-tdep.c (sparc_psr_type): Likewise.
6141 (sparc_fsr_type): Likewise.
6142 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
6143 (sparc64_ccr_type): Likewise.
6144 (sparc64_fsr_type): Likewise.
6145 (sparc64_fprs_type): Likewise.
6146
f21b4d5c
TT
61472017-09-27 Tom Tromey <tom@tromey.com>
6148
6149 * findcmd.c (find_command): Constify.
6150
643c2ffa
TT
61512017-09-27 Tom Tromey <tom@tromey.com>
6152
6153 * ada-tasks.c (task_command_1, task_command): Constify.
6154
510e5e56
TT
61552017-09-27 Tom Tromey <tom@tromey.com>
6156
6157 * symtab.c (maintenance_print_symbol_cache)
6158 (maintenance_flush_symbol_cache)
6159 (maintenance_print_symbol_cache_statistics): Constify.
6160
e503b191
TT
61612017-09-27 Tom Tromey <tom@tromey.com>
6162
6163 * inferior.c (detach_inferior_command, kill_inferior_command)
6164 (inferior_command): Constify.
6165
4e001312
TT
61662017-09-27 Tom Tromey <tom@tromey.com>
6167
6168 * regcache.c (regcache_print, maintenance_print_registers)
6169 (maintenance_print_raw_registers)
6170 (maintenance_print_cooked_registers)
6171 (maintenance_print_register_groups)
6172 (maintenance_print_remote_registers): Constify.
6173
77763700
TT
61742017-09-27 Tom Tromey <tom@tromey.com>
6175
6176 * printcmd.c (map_display_numbers, undisplay_command)
6177 (enable_disable_display_command, enable_display_command)
6178 (disable_display_command): Constify.
6179
4495129a
TT
61802017-09-27 Tom Tromey <tom@tromey.com>
6181
6182 * breakpoint.h (delete_command): Don't declare.
6183 * breakpoint.c (delete_command, enable_once_command)
6184 (enable_count_command, enable_delete_command, breakpoint_1)
6185 (maintenance_info_breakpoints, stopin_command, stopat_command)
6186 (delete_command, delete_trace_command, save_breakpoints)
6187 (save_breakpoints_command, save_tracepoints_command): Constify.
6188
3088cf40
TT
61892017-09-27 Tom Tromey <tom@tromey.com>
6190
6191 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6192 (skip_ws, extract_identifier, macro_define_command)
6193 (macro_undef_command, macro_list_command): Constify.
6194
69f476a3
TT
61952017-09-27 Tom Tromey <tom@tromey.com>
6196
6197 * infcmd.c (environment_info, set_environment_command)
6198 (unset_environment_command, path_info, info_proc_cmd_1)
6199 (info_proc_cmd_mappings, info_proc_cmd_stat)
6200 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6201 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6202
c4a3e68e
TT
62032017-09-27 Tom Tromey <tom@tromey.com>
6204
6205 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6206 Constify.
6207
c9d31bd6
TT
62082017-09-27 Tom Tromey <tom@tromey.com>
6209
6210 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6211
1f3f85eb
TT
62122017-09-27 Tom Tromey <tom@tromey.com>
6213
6214 * demangle.c (demangle_command): Constify.
6215
9c504b5d
TT
62162017-09-27 Tom Tromey <tom@tromey.com>
6217
6218 * progspace.c (maintenance_info_program_spaces_command):
6219 Constify.
6220
6663cf91
TT
62212017-09-27 Tom Tromey <tom@tromey.com>
6222
6223 * compile/compile.c (check_raw_argument, compile_file_command)
6224 (compile_code_command, compile_print_command): Constify.
6225
34e5fa26
TT
62262017-09-27 Tom Tromey <tom@tromey.com>
6227
6228 * reggroups.c (maintenance_print_reggroups): Constify.
6229
8384c356
TT
62302017-09-27 Tom Tromey <tom@tromey.com>
6231
6232 * dwarf2read.c (save_gdb_index_command): Constify.
6233
884beb0c
TT
62342017-09-27 Tom Tromey <tom@tromey.com>
6235
6236 * stap-probe.c (info_probes_stap_command): Constify.
6237
e0b2930c
TT
62382017-09-27 Tom Tromey <tom@tromey.com>
6239
6240 * fork-child.c (unset_exec_wrapper_command): Constify.
6241
f938677d
TT
62422017-09-27 Tom Tromey <tom@tromey.com>
6243
6244 * btrace.c (get_uint, get_context_size, no_chunk)
6245 (maint_btrace_packet_history_cmd)
6246 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6247 (maint_info_btrace_cmd): Constify.
6248
8949cb87
TT
62492017-09-27 Tom Tromey <tom@tromey.com>
6250
6251 * reverse.c (delete_bookmark_command): Constify.
6252
ac88e2de
TT
62532017-09-27 Tom Tromey <tom@tromey.com>
6254
6255 * remote.c (set_memory_packet_size)
6256 (set_memory_write_packet_size, show_memory_write_packet_size)
6257 (set_memory_read_packet_size, show_memory_read_packet_size)
6258 (compare_sections_command, packet_command, remote_put_command)
6259 (remote_get_command, remote_delete_command): Constify.
6260
bd4c9dfe
TT
62612017-09-27 Tom Tromey <tom@tromey.com>
6262
6263 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6264 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6265 (set_mipsfpu_auto_command): Constify.
6266
5e93d4c6
TT
62672017-09-27 Tom Tromey <tom@tromey.com>
6268
6269 * cli/cli-cmds.h (cd_command): Constify.
6270 * cli/cli-cmds.c (cd_command): Constify.
6271
fc41a75b
TT
62722017-09-27 Tom Tromey <tom@tromey.com>
6273
6274 * thread.c (thread_name_command, thread_find_command): Constify.
6275
67810076
TT
62762017-09-27 Tom Tromey <tom@tromey.com>
6277
6278 * probe.c (enable_probes_command, disable_probes_command):
6279 Constify.
6280
1d8b34a7
TT
62812017-09-27 Tom Tromey <tom@tromey.com>
6282
6283 * symfile.c (symbol_file_command): Constify.
6284 * gdbcore.h (deprecated_file_changed_hook): Constify.
6285 * exec.c (deprecated_file_changed_hook, exec_file_command)
6286 (file_command): Constify.
6287 * defs.h (symbol_file_command): Constify.
6288
442019e1
TT
62892017-09-27 Tom Tromey <tom@tromey.com>
6290
6291 * remote-fileio.c (set_system_call_allowed)
6292 (show_system_call_allowed): Constify.
6293
2983f7cb
TT
62942017-09-27 Tom Tromey <tom@tromey.com>
6295
6296 * tracepoint.c (delete_trace_variable_command)
6297 (tfind_end_command, tfind_start_command, tfind_pc_command)
6298 (tfind_tracepoint_command, tfind_line_command)
6299 (tfind_range_command, tfind_outside_command): Constify.
6300
4fd41b24
TT
63012017-09-27 Tom Tromey <tom@tromey.com>
6302
6303 * ax-gdb.c (maint_agent_printf_command, agent_command)
6304 (agent_eval_command): Constify.
6305
f2fc3015
TT
63062017-09-27 Tom Tromey <tom@tromey.com>
6307
6308 * tracepoint.c (info_scope_command): Constify.
6309 * python/python.c (gdbpy_decode_line): Constify.
6310 * python/py-breakpoint.c (bppy_init): Constify.
6311 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6312 * location.h: (new_linespec_location)
6313 (string_to_event_location_basic, string_to_event_location):
6314 Constify.
6315 * location.c (new_linespec_location)
6316 (string_to_event_location_basic, string_to_event_location):
6317 Constify.
6318 * linespec.h (decode_line_with_current_source)
6319 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6320 * linespec.c (linespec_lex_to_end)
6321 (decode_line_with_current_source)
6322 (decode_line_with_last_displayed): Constify.
6323 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6324 Constify.
6325 * cli/cli-cmds.c (edit_command, list_command): Constify.
6326 * breakpoint.h (until_break_command, watch_command_wrapper)
6327 (awatch_command_wrapper, rwatch_command_wrapper)
6328 (init_ada_exception_breakpoint): Constify.
6329 * breakpoint.c (break_command_1, dprintf_command)
6330 (break_range_command, watch_command_wrapper)
6331 (rwatch_command_wrapper, awatch_command_wrapper)
6332 (until_break_command, init_ada_exception_breakpoint)
6333 (strace_marker_create_sals_from_location, trace_command)
6334 (ftrace_command, strace_command, struct tracepoint): Constify.
6335 * ax-gdb.c (agent_command_1): Constify.
6336 * ada-lang.c (ada_exception_sal): Constify.
6337
8c2f95f4
TT
63382017-09-27 Tom Tromey <tom@tromey.com>
6339
6340 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6341 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6342 (get_context_size, no_chunk, get_insn_history_modifiers)
6343 (cmd_record_insn_history, get_call_history_modifiers)
6344 (cmd_record_call_history): Constify.
6345
a0d65762
TT
63462017-09-27 Tom Tromey <tom@tromey.com>
6347
6348 * source.c (show_substitute_path_command)
6349 (unset_substitute_path_command, set_substitute_path_command):
6350 Constify.
6351
58971144
TT
63522017-09-27 Tom Tromey <tom@tromey.com>
6353
6354 * typeprint.c (maintenance_print_type): Constify.
6355 * maint.c (maintenance_dump_me, maintenance_demangle)
6356 (maintenance_time_display, maintenance_info_sections)
6357 (maintenance_print_statistics, maintenance_deprecate)
6358 (maintenance_undeprecate): Constify.
6359 (maintenance_do_deprecate): Constify. Use std::string.
6360 (maintenance_selftest): Constify.
6361 * gdbtypes.h (maintenance_print_type): Constify.
6362
c482f52c
TT
63632017-09-27 Tom Tromey <tom@tromey.com>
6364
6365 * hppa-tdep.c (unwind_command): Constify.
6366
e100df1a
TT
63672017-09-27 Tom Tromey <tom@tromey.com>
6368
6369 * target-descriptions.c (unset_tdesc_filename_cmd)
6370 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6371 Constify.
6372
31d56ade
TT
63732017-09-27 Tom Tromey <tom@tromey.com>
6374
6375 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6376
b961da0b
TT
63772017-09-27 Tom Tromey <tom@tromey.com>
6378
6379 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6380
e2d8ae16
TT
63812017-09-27 Tom Tromey <tom@tromey.com>
6382
6383 * tui/tui-regs.c (tui_reg_command): Constify.
6384
863779b0
TT
63852017-09-27 Tom Tromey <tom@tromey.com>
6386
6387 * skip.c (skip_file_command, skip_function_command)
6388 (skip_enable_command, skip_disable_command, skip_delete_command):
6389 Constify.
6390
cdb34d4a
TT
63912017-09-27 Tom Tromey <tom@tromey.com>
6392
6393 * record-btrace.c (cmd_record_btrace_bts_start)
6394 (cmd_record_btrace_pt_start): Constify.
6395
e99c83e7
TT
63962017-09-27 Tom Tromey <tom@tromey.com>
6397
6398 * symmisc.c (maintenance_print_symbols)
6399 (maintenance_print_msymbols, maintenance_print_objfiles)
6400 (maintenance_info_symtabs, maintenance_check_symtabs)
6401 (maintenance_expand_symtabs, maintenance_info_line_tables):
6402 Constify.
6403
32faf971
TT
64042017-09-27 Tom Tromey <tom@tromey.com>
6405
6406 * top.c (new_ui_command): Constify.
6407
2cf311eb
TT
64082017-09-27 Tom Tromey <tom@tromey.com>
6409
6410 * symfile.c (add_symbol_file_command)
6411 (remove_symbol_file_command, list_overlays_command)
6412 (map_overlay_command, unmap_overlay_command)
6413 (overlay_auto_command, overlay_manual_command)
6414 (overlay_off_command, overlay_load_command): Constify.
6415
e6738699
TT
64162017-09-27 Tom Tromey <tom@tromey.com>
6417
6418 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6419 (info_spu_mailbox_command, info_spu_dma_command)
6420 (info_spu_proxydma_command): Constify.
6421
aa360cd5
TT
64222017-09-27 Tom Tromey <tom@tromey.com>
6423
6424 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6425
898241a5
TT
64262017-09-27 Tom Tromey <tom@tromey.com>
6427
6428 * cli/cli-script.c (user_defined_command): Constify.
6429
2d0ac106
TT
64302017-09-27 Tom Tromey <tom@tromey.com>
6431
6432 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6433 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6434 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6435 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6436 (dump_binary_value, append_binary_memory, append_binary_value):
6437 Constify.
6438 (struct dump_context) <func>: Constify.
6439 (add_dump_command): Update.
6440
dede02ce
TT
64412017-09-27 Tom Tromey <tom@tromey.com>
6442
6443 * cli/cli-cmds.c (show_version, show_configuration)
6444 (source_command, show_user): Constify.
6445
d3cb6b99
TT
64462017-09-27 Tom Tromey <tom@tromey.com>
6447
6448 * target.c (maintenance_print_target_stack): Constify.
6449
1970a12f
TT
64502017-09-27 Tom Tromey <tom@tromey.com>
6451
6452 * interps.c (interpreter_exec_cmd): Constify.
6453
41243651
TT
64542017-09-27 Tom Tromey <tom@tromey.com>
6455
6456 * record-full.c (cmd_record_full_restore): Constify.
6457
4465d9db
TT
64582017-09-27 Tom Tromey <tom@tromey.com>
6459
6460 * memattr.c (enable_mem_command, disable_mem_command)
6461 (delete_mem_command): Constify.
6462
ad25e423
TT
64632017-09-27 Tom Tromey <tom@tromey.com>
6464
6465 * value.c (show_convenience): Constify.
6466
d64097b1
TT
64672017-09-27 Tom Tromey <tom@tromey.com>
6468
6469 * gdbcore.h (core_file_command): Update.
6470 * corefile.c (core_file_command): Constify.
6471
4d4589ef
TT
64722017-09-27 Tom Tromey <tom@tromey.com>
6473
6474 * user-regs.c (maintenance_print_user_registers): Constify.
6475
32a7bf17
TT
64762017-09-27 Tom Tromey <tom@tromey.com>
6477
6478 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6479
4a475551
TT
64802017-09-27 Tom Tromey <tom@tromey.com>
6481
6482 * cp-support.c (first_component_command): Constify.
6483
990b9f9f
TT
64842017-09-27 Tom Tromey <tom@tromey.com>
6485
6486 * psymtab.c (maintenance_print_psymbols)
6487 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6488 Constify.
6489
c281872e
TT
64902017-09-27 Tom Tromey <tom@tromey.com>
6491
6492 * windows-tdep.c (display_tib): Constify.
6493
5b64bf74
TT
64942017-09-27 Tom Tromey <tom@tromey.com>
6495
6496 * linux-fork.c (delete_checkpoint_command)
6497 (detach_checkpoint_command): Constify.
6498
4ada038f
TT
64992017-09-27 Tom Tromey <tom@tromey.com>
6500
6501 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6502
57f5a81b
TT
65032017-09-27 Tom Tromey <tom@tromey.com>
6504
6505 * arc-tdep.c (dump_arc_instruction_command): Constify.
6506
b0a8e6c4
TT
65072017-09-27 Tom Tromey <tom@tromey.com>
6508
6509 * valprint.c (set_radix, show_radix): Constify.
6510
8d97dc1c
TT
65112017-09-27 Tom Tromey <tom@tromey.com>
6512
6513 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6514
eb7c454d
TT
65152017-09-27 Tom Tromey <tom@tromey.com>
6516
6517 * command.h (not_just_help_class_command): Update.
6518 * cli/cli-decode.h (not_just_help_class_command): Update.
6519 * cli/cli-decode.c (not_just_help_class_command): Constify.
6520
e4e33335
TT
65212017-09-27 Tom Tromey <tom@tromey.com>
6522
6523 * gdb_bfd.c (maintenance_info_bfds): Constify.
6524
0450cc4c
TT
65252017-09-27 Tom Tromey <tom@tromey.com>
6526
6527 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6528 overloads.
6529 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6530 (do_const_cfunc): New function.
6531 (cmd_cfunc_eq): New overload.
6532 (cli_user_command_p): Check do_const_cfunc.
6533 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6534 const_cfunc.
6535 * command.h (add_cmd): Add const overload and no-function
6536 overload.
6537 (set_cmd_cfunc): Add const overload.
6538 (cmd_const_cfunc_ftype): Declare.
6539 (cmd_cfunc_eq): Add const overload.
6540 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
6541 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
6542 overload.
6543
a9bbfbd8
TT
65442017-09-27 Tom Tromey <tom@tromey.com>
6545
6546 * macroexp.c (get_next_token_for_substitution): New function.
6547 (substitute_args): Call it. Check for __VA_OPT__.
6548
5230b05a
WT
65492017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6550 Pedro Alves <palves@redhat.com>
6551
6552 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
6553 producer_is_icc_lt_14.
6554 (producer_is_icc_lt_14): New function.
6555 (check_producer): Add code for checking version of ICC.
6556 (producer_is_icc): Move to producer.c.
6557 (read_structure_type): Restrict ICC workaround to ICC<14.
6558 * producer.c: Include selftest.h.
6559 (producer_is_icc, producer_parsing_tests, _initialize_producer):
6560 New functions.
6561 * producer.h (producer_is_icc): New declaration.
6562
b32b108a
WT
65632017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6564
6565 * Makefile.in (SFILES): Add producer.c.
6566 (COMMON_OBS): Add producer.o
6567 * amd64-tdep.c (producer.h): Add new include.
6568 * dwarf2read.c (producer.h): Add new include.
6569 * producer.c: New file.
6570 * producer.h: New file.
6571 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
6572 producer.c.
6573 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
6574 producer.h.
6575
5007d765
MK
65762017-09-26 Matthias Klose <doko@ubuntu.com>
6577
6578 * configure.ac: Search ncursesw before ncurses.
6579 Check ncursesw/ncurses.h before ncurses/ncurses.h.
6580 * gdb_curses.h: Include <ncursesw/ncurses.h>
6581 * config.in, configure: Regenerate.
6582
281c4447
RO
65832017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6584
6585 PR gdb/22185
6586 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
6587 obsolete.
6588 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
6589 Remove i386sol2 support.
6590 * configure.nat <i386sol2>: Remove.
6591 <sol2-64>: Fold into ...
6592 <sol2>: ... this.
6593 Move common settings to default section.
6594 Add sol-thread.o.
6595 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
6596 x86_64-*-solaris2.1[0-9]*>: Rename to ...
6597 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
6598 <i[34567]86-*-solaris*>: Remove.
6599 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
6600
6601 * configure.ac: Remove wctype in libw check.
6602 (_MSE_INT_H): Don't define on Solaris 7-9.
6603 <solaris*>: Remove libthread_db.so.1 check.
6604 * configure: Regenerate.
6605 * config.in: Regenerate.
6606
6607 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
6608 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
6609 (gdb_ps_size_t): Remove.
6610 Use base types in users.
6611 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
6612
6613 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
6614
39b06c20
RO
66152017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6616
6617 PR build/22206
6618 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
6619 (adi_is_addr_mapped): Likewise.
6620 (PSR_ICC): Don't redefine.
6621 (PSR_IMPL): Likewise.
6622
6c3e20f1
TT
66232017-09-25 Tom Tromey <tom@tromey.com>
6624
6625 * regcache.c (regcache::dump): Use string_printf.
6626
b292235f
TT
66272017-09-25 Tom Tromey <tom@tromey.com>
6628
6629 * regcache.c (class regcache_invalidator): New.
6630 (struct register_to_invalidate): Remove.
6631 (make_cleanup_regcache_invalidate): Remove.
6632 (regcache::raw_write): Use regcache_invalidator.
6633
9ac86b52
TT
66342017-09-25 Tom Tromey <tom@tromey.com>
6635
6636 * spu-tdep.c (spu2ppu_sniffer): Update.
6637 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
6638 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
6639 Remove.
6640 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
6641 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
6642 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
6643 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
6644 (frame_pop): Update.
6645
c0e383c6
TT
66462017-09-25 Tom Tromey <tom@tromey.com>
6647
6648 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
6649 * regcache.h (regcache_xfree): Don't declare.
6650 * regcache.c (regcache_xfree): Remove.
6651 (do_regcache_xfree): Use delete.
6652 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
6653 * linux-fork.c (free_fork): Use delete.
6654 (fork_save_infrun_state): Likewise.
6655 * jit.c (jit_dealloc_cache): Use delete.
6656 * infrun.c (discard_infcall_suspend_state): Use delete.
6657
791199cc
TT
66582017-09-25 Tom Tromey <tom@tromey.com>
6659
6660 * regcache.h (regcache_xmalloc): Don't declare.
6661 (regcache_raw_set_cached_value): Update comment.
6662 * regcache.c (regcache_xmalloc): Remove.
6663 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
6664 * jit.c (jit_frame_sniffer): Use new.
6665 * frame.c (frame_save_as_regcache): Use new.
6666
289e23aa
AA
66672017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6668
6669 * NEWS: Advertise support for guarded-storage registers on IBM z.
6670
1b63490c
AA
66712017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6672
6673 * s390-linux-nat.c (have_regset_gs): New static variable.
6674 (s390_linux_fetch_inferior_registers): Handle guarded-storage
6675 control block and guarded-storage broadcast control regsets.
6676 (s390_read_description): Detect whether the target has
6677 guarded-storage support, return appropriate tdesc.
6678 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
6679 (features/s390x-gs-linux64.c): Likewise.
6680 (struct gdbarch_tdep) <have_gs>: New field.
6681 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
6682 (s390_gsbc_regset): New variables.
6683 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
6684 and s390_gsbc_regset, if applicable.
6685 (s390_core_read_description): Check whether core file was from a
6686 target with guarded-storage support; include appropriate regsets.
6687 (s390_gdbarch_init): Add registers for guarded-storage support.
6688 (_initialize_s390_tdep): Initialize new target descriptions that
6689 include registers for guarded-storage support.
6690 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
6691 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
6692 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
6693 (S390_NUM_REGS): Adjust macro definition.
6694 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
6695 (tdesc_s390x_gs_linux64): New declarations.
6696
96235dc1
AA
66972017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6698
6699 * features/s390-gs-linux64.xml: New file.
6700 * features/s390-gs.xml: New file.
6701 * features/s390-gsbc.xml: New file.
6702 * features/s390x-gs-linux64.xml: New file.
6703 * features/Makefile (WHICH): Add s390-gs-linux64 and
6704 s390x-gs-linux64.
6705 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
6706 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
6707 * features/s390-gs-linux64.c: New generated file.
6708 * features/s390x-gs-linux64.c: New file.
6709 * regformats/s390-gs-linux64.dat: New file.
6710 * regformats/s390x-gs-linux64.dat: New file.
6711
b4a7c699
TT
67122017-09-23 Tom Tromey <tom@tromey.com>
6713
6714 * defs.h (make_cleanup_override_quit_handler): Don't declare.
6715
c2f97536
TT
67162017-09-22 Tom Tromey <tom@tromey.com>
6717
6718 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
6719 type to scoped_restore_tmpl.
6720 <scoped_input_handler>: Initialize m_quit_handler directly.
6721
43573013
SDJ
67222017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6723
6724 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
6725 (cd_command): Likewise. Free "current_directory" before
6726 assigning to it.
6727 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
6728 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
6729 * top.c (gdb_dirbuf): Remove global declaration.
6730 * top.h (gdb_dirbuf): Likewise.
6731
6ec2e0f5
SDJ
67322017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6733
6734 * gnulib/aclocal.m4: Regenerate.
6735 * gnulib/config.in: Regenerate.
6736 * gnulib/configure: Regenerate.
6737 * gnulib/import/Makefile.am: Regenerate.
6738 * gnulib/import/Makefile.in: Regenerate.
6739 * gnulib/import/assure.h: New file.
6740 * gnulib/import/at-func.c: Likewise
6741 * gnulib/import/chdir-long.c: New file.
6742 * gnulib/import/chdir-long.h: New file.
6743 * gnulib/import/cloexec.c: New file.
6744 * gnulib/import/cloexec.h: New file.
6745 * gnulib/import/close.c: New file.
6746 * gnulib/import/closedir.c: New file.
6747 * gnulib/import/dirent-private.h: New file.
6748 * gnulib/import/dup-safer.c: New file.
6749 * gnulib/import/dup.c: New file.
6750 * gnulib/import/dup2.c: New file.
6751 * gnulib/import/error.c: New file.
6752 * gnulib/import/error.h: New file.
6753 * gnulib/import/exitfail.c: New file.
6754 * gnulib/import/exitfail.h: New file.
6755 * gnulib/import/fchdir.c: New file.
6756 * gnulib/import/fcntl.c: New file.
6757 * gnulib/import/fcntl.in.h: New file.
6758 * gnulib/import/fd-hook.c: New file.
6759 * gnulib/import/fd-hook.h: New file.
6760 * gnulib/import/fd-safer.c: New file.
6761 * gnulib/import/fdopendir.c: New file.
6762 * gnulib/import/filename.h: New file.
6763 * gnulib/import/filenamecat-lgpl.c: New file.
6764 * gnulib/import/filenamecat.h: New file.
6765 * gnulib/import/fstat.c: New file.
6766 * gnulib/import/fstatat.c: New file.
6767 * gnulib/import/getcwd-lgpl.c: New file.
6768 * gnulib/import/getcwd.c: New file.
6769 * gnulib/import/getdtablesize.c: New file.
6770 * gnulib/import/getlogin_r.c: New file.
6771 * gnulib/import/getprogname.c: New file.
6772 * gnulib/import/getprogname.h: New file.
6773 * gnulib/import/gettext.h: New file.
6774 * gnulib/import/glob-libc.h: New file.
6775 * gnulib/import/glob.c: New file.
6776 * gnulib/import/glob.in.h: New file.
6777 * gnulib/import/intprops.h: New file.
6778 * gnulib/import/m4/chdir-long.m4: New file.
6779 * gnulib/import/m4/close.m4: New file.
6780 * gnulib/import/m4/closedir.m4: New file.
6781 * gnulib/import/m4/d-ino.m4: New file.
6782 * gnulib/import/m4/d-type.m4: New file.
6783 * gnulib/import/m4/dup.m4: New file.
6784 * gnulib/import/m4/dup2.m4: New file.
6785 * gnulib/import/m4/error.m4: New file.
6786 * gnulib/import/m4/fchdir.m4: New file.
6787 * gnulib/import/m4/fcntl.m4: New file.
6788 * gnulib/import/m4/fcntl_h.m4: New file.
6789 * gnulib/import/m4/fdopendir.m4: New file.
6790 * gnulib/import/m4/filenamecat.m4: New file.
6791 * gnulib/import/m4/fstat.m4: New file.
6792 * gnulib/import/m4/fstatat.m4: New file.
6793 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
6794 * gnulib/import/m4/getcwd-path-max.m4: New file.
6795 * gnulib/import/m4/getcwd.m4: New file.
6796 * gnulib/import/m4/getdtablesize.m4: New file.
6797 * gnulib/import/m4/getlogin_r.m4: New file.
6798 * gnulib/import/m4/getprogname.m4: New file.
6799 * gnulib/import/m4/glob.m4: New file.
6800 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
6801 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
6802 * gnulib/import/m4/mempcpy.m4: New file.
6803 * gnulib/import/m4/memrchr.m4: New file.
6804 * gnulib/import/m4/mode_t.m4: New file.
6805 * gnulib/import/m4/msvc-inval.m4: New file.
6806 * gnulib/import/m4/msvc-nothrow.m4: New file.
6807 * gnulib/import/m4/open.m4: New file.
6808 * gnulib/import/m4/openat.m4: New file.
6809 * gnulib/import/m4/opendir.m4: New file.
6810 * gnulib/import/m4/readdir.m4: New file.
6811 * gnulib/import/m4/realloc.m4: New file.
6812 * gnulib/import/m4/rewinddir.m4: New file.
6813 * gnulib/import/m4/save-cwd.m4: New file.
6814 * gnulib/import/m4/strdup.m4: New file.
6815 * gnulib/import/m4/strerror.m4: New file.
6816 * gnulib/import/m4/unistd-safer.m4: New file.
6817 * gnulib/import/mempcpy.c: New file.
6818 * gnulib/import/memrchr.c: New file.
6819 * gnulib/import/msvc-inval.c: New file.
6820 * gnulib/import/msvc-inval.h: New file.
6821 * gnulib/import/msvc-nothrow.c: New file.
6822 * gnulib/import/msvc-nothrow.h: New file.
6823 * gnulib/import/open.c: New file.
6824 * gnulib/import/openat-die.c: New file.
6825 * gnulib/import/openat-priv.h: New file.
6826 * gnulib/import/openat-proc.c: New file.
6827 * gnulib/import/openat.c: New file.
6828 * gnulib/import/openat.h: New file.
6829 * gnulib/import/opendir.c: New file.
6830 * gnulib/import/pipe-safer.c: New file.
6831 * gnulib/import/readdir.c: New file.
6832 * gnulib/import/realloc.c: New file.
6833 * gnulib/import/rewinddir.c: New file.
6834 * gnulib/import/save-cwd.c: New file.
6835 * gnulib/import/save-cwd.h: New file.
6836 * gnulib/import/strdup.c: New file.
6837 * gnulib/import/strerror-override.c: New file.
6838 * gnulib/import/strerror-override.h: New file.
6839 * gnulib/import/strerror.c: New file.
6840 * gnulib/import/unistd--.h: New file.
6841 * gnulib/import/unistd-safer.h: New file.
6842 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
6843 "getcwd" and "glob".
6844 * ser-tcp.c: Undefine "close" before redefining it.
6845
432ae719
SM
68462017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6847
6848 * guile/scm-value.c (gdbscm_value_address): Initialize address,
6849 get rid of res_val.
6850
4fa7574e
RO
68512017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6852
6853 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
6854 <sol2,sparc>: Likewise.
6855 <sol2-64,i386>: Likewise.
6856
6857 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
6858 -Wdeprecated-declarations on *-*-solaris*.
6859 * configure: Regenerate.
6860
6861 * procfs.c: Include "nat/inferior.h".
6862 (procfs_info_proc): Fix typo.
6863
f6327dcb
KB
68642017-09-21 Kevin Buettner <kevinb@redhat.com>
6865
6866 * remote.c (vector): Include.
6867 (struct private_thread_info): Add field, thread_handle.
6868 (free_private_thread_info): Deallocate storage associated with
6869 thread handle.
6870 (get_private_info_thread): Initialize `thread_handle' field.
6871 (struct thread_item): Add field, thread_handle.
6872 (clear_threads_listing_context): Deallocate storage associated
6873 with thread handle.
6874 (start_thread): Add support for "handle" attribute.
6875 (thread_attributes): Add "handle".
6876 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
6877 field.
6878 (remote_update_thread_list): Update thread_handle.
6879 (remote_thread_handle_to_thread_info): New function.
6880 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
6881
fbbe5337
KB
68822017-09-21 Kevin Buettner <kevinb@redhat.com>
6883
6884 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
6885 function.
6886 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
6887 * python/python-internal.h (thread_object_type): Declare.
6888
e04ee09e
KB
68892017-09-21 Kevin Buettner <kevinb@redhat.com>
6890
6891 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
6892 (target_thread_handle_to_thread_info): Declare.
6893 * target.c (target_thread_handle_to_thread_info): New function.
6894 * target-delegates.c: Regenerate.
6895 * gdbthread.h (find_thread_by_handle): Declare.
6896 * thread.c (find_thread_by_handle): New function.
6897 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
6898 function.
6899 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
6900
1e5b66ed
SM
69012017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6902
6903 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
6904
ebe48ba0
SM
69052017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6906
6907 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
6908
0a0bf5dc
YQ
69092017-09-21 Yao Qi <yao.qi@linaro.org>
6910
6911 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
6912 to gdb_target_obs.
6913
d1b0a7bf
TT
69142017-09-20 Tom Tromey <tom@tromey.com>
6915
6916 * breakpoint.c (struct counted_command_line): Remove.
6917 (breakpoint_commands): Update.
6918 (alloc_counted_command_line, incref_counted_command_line)
6919 (decref_counted_command_line, do_cleanup_counted_command_line)
6920 (make_cleanup_decref_counted_command_line): Remove.
6921 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
6922 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
6923 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
6924 (save_breakpoints): Update.
6925 * breakpoint.h (counted_command_line): Now a typedef to
6926 shared_ptr.
6927 (struct breakpoint) <commands>: Now a counted_command_line.
6928 (struct bpstats) <command>: Likewise.
6929
48649e1b
TT
69302017-09-20 Tom Tromey <tom@tromey.com>
6931
6932 * breakpoint.c (struct commands_info, do_map_commands_command):
6933 Remove.
6934 (commands_command_1): Update.
6935 (iterate_over_related_breakpoints): Take a function_view.
6936 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
6937 (delete_command): Update.
6938 (map_breakpoint_numbers): Take a function_view.
6939 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
6940 (disable_command): Update.
6941 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
6942 (enable_command): Update.
6943 (struct disp_data, do_enable_breakpoint_disp)
6944 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
6945 (do_map_enable_delete_breakpoint): Remove.
6946 (enable_once_command, enable_count_command, enable_delete_command)
6947 (delete_trace_variable_command): Update.
6948
04afa70c
TT
69492017-09-20 Tom Tromey <tom@tromey.com>
6950
6951 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
6952 (bpstat_clear): Use delete.
6953 (bpstats): New constructors.
6954 (bpstat_copy, bpstat_stop_status): Use new.
6955 (dprintf_after_condition_true): Update.
6956 * breakpoint.h (bpstats::bpstats): Add constructors.
6957 (bpstats::~bpstats): Add destructor.
6958
c83833f4
PA
69592017-09-20 Pedro Alves <palves@redhat.com>
6960
6961 * eval.c (make_params): Delete, refactored as ...
6962 (class fake_method): ... this new type's ctor.
6963 (fake_method::~fake_method): New.
6964 (evaluate_subexp_standard): Use 'fake_method'.
6965
223ffa71
TT
69662017-09-20 Tom Tromey <tom@tromey.com>
6967
6968 * windows-nat.c (get_windows_debug_event, windows_wait)
6969 (do_initial_windows_stuff, windows_attach): Update.
6970 * utils.c (vwarning, internal_vproblem): Update.
6971 (ui_unregister_input_event_handler_cleanup)
6972 (prepare_to_handle_input): Remove.
6973 (class scoped_input_handler): New.
6974 (defaulted_query, prompt_for_continue): Update.
6975 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
6976 Update.
6977 * top.c (undo_terminal_modifications_before_exit): Update.
6978 * target/target.h (target_terminal_init, target_terminal_inferior)
6979 (target_terminal_ours): Don't declare.
6980 (class target_terminal): New.
6981 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
6982 (target_terminal_ours_for_output)
6983 (make_cleanup_restore_target_terminal): Don't declare.
6984 (target_terminal_info): Remove.
6985 * target.c (enum terminal_state, terminal_state): Remove.
6986 (target_terminal::terminal_state): Define.
6987 (target_terminal::init): Rename from target_terminal_init.
6988 (target_terminal::inferior): Rename from
6989 target_terminal_inferior.
6990 (target_terminal::ours): Rename from target_terminal_ours.
6991 (target_terminal::ours_for_output): Rename from
6992 target_terminal_ours_for_output.
6993 (target_terminal::info): New method.
6994 (cleanup_restore_target_terminal)
6995 (make_cleanup_restore_target_terminal): Remove.
6996 * solib.c (handle_solib_event): Update.
6997 * remote.c (remote_serial_quit_handler): Update.
6998 (remote_terminal_inferior, remote_wait_as): Update.
6999 * record-full.c (record_full_wait_1): Update.
7000 * nto-procfs.c (procfs_create_inferior): Update.
7001 * nat/fork-inferior.c (startup_inferior): Update.
7002 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
7003 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
7004 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
7005 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
7006 (mi_breakpoint_created, mi_breakpoint_deleted)
7007 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
7008 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
7009 (mi_user_selected_context_changed, report_initial_inferior):
7010 Update.
7011 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
7012 (linux_nat_terminal_inferior): Update.
7013 * infrun.c (follow_fork_inferior)
7014 (handle_vfork_child_exec_or_exit, do_target_resume)
7015 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
7016 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
7017 Update.
7018 * inflow.c (child_terminal_init, info_terminal_command): Update.
7019 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
7020 (attach_command): Update.
7021 * infcall.c (call_thread_fsm_should_stop): Update.
7022 * gnu-nat.c (gnu_attach): Update.
7023 * extension.c (struct active_ext_lang_state)
7024 (restore_active_ext_lang): Update.
7025 * exceptions.c (print_flush): Update.
7026 * event-top.c (async_enable_stdin, default_quit_handler): Update.
7027 (struct quit_handler_cleanup_data, restore_quit_handler)
7028 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
7029 Remove.
7030 * cp-support.c (gdb_demangle): Update.
7031 * breakpoint.c (update_inserted_breakpoint_locations)
7032 (insert_breakpoint_locations, handle_jit_event)
7033 (disable_breakpoints_in_unloaded_shlib): Update.
7034 * annotate.c (annotate_breakpoints_invalid)
7035 (annotate_frames_invalid): Update.
7036
013af3fc
TT
70372017-09-20 Tom Tromey <tom@tromey.com>
7038
7039 * main.c (catch_command_errors): Rename from
7040 catch_command_errors_const.
7041 (captured_main_1): Update.
7042
06871ae8
PA
70432017-09-20 Pedro Alves <palves@redhat.com>
7044
7045 * cli/cli-cmds.c (list_command): Use print_sal_location.
7046 (print_sal_location): New function.
7047 (ambiguous_line_spec): Use print_sal_location.
7048 * linespec.c (symbol_to_sal): Record the symbol in the sal.
7049 * symtab.c (find_function_start_sal): Likewise.
7050 * symtab.h (symtab_and_line::symbol): New field.
7051
e5f25bc5
PA
70522017-09-20 Pedro Alves <palves@redhat.com>
7053
7054 * linespec.c (minsym_found): Handle non-text minsyms.
7055 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
7056
1b7fa39e
WT
70572017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7058
7059 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
7060 backslash.
7061
37dd0825
WT
70622017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
7063
7064 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
7065 vmovups instead vmovaps.
7066 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
7067
4e5a4f58
JB
70682017-09-19 John Baldwin <jhb@FreeBSD.org>
7069
7070 * NEWS (Changes since GDB 8.0): Add starti.
7071 * infcmd.c (enum run_break): New.
7072 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
7073 case.
7074 (run_command): Use enum run_how.
7075 (start_command): Likewise.
7076 (starti_command): New function.
7077 (RUN_ARGS_HELP): New macro.
7078 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
7079 commands. Add starti command.
7080
aa70c9f1
YQ
70812017-09-19 Yao Qi <yao.qi@linaro.org>
7082
7083 * Makefile.in (monitor.o): Remove the rule.
7084
d6541620
YQ
70852017-09-19 Yao Qi <yao.qi@linaro.org>
7086
7087 * annotate.h (struct annotate_arg_emitter): Use
7088 DISABLE_COPY_AND_ASSIGN.
7089 * common/refcounted-object.h (refcounted_object): Likewise.
7090 * completer.h (struct completion_result): Likewise.
7091 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
7092 * filename-seen-cache.h (filename_seen_cache): Likewise.
7093 * gdbcore.h (thread_section_name): Likewise.
7094 * gdb_regex.h (compiled_regex): Likewise.
7095 * gdbthread.h (scoped_restore_current_thread): Likewise.
7096 * inferior.h (scoped_restore_current_inferior): Likewise.
7097 * jit.c (jit_reader): Likewise.
7098 * linespec.h (struct linespec_result): Likewise.
7099 * mi/mi-parse.h (struct mi_parse): Likewise.
7100 * nat/fork-inferior.c (execv_argv): Likewise.
7101 * progspace.h (scoped_restore_current_program_space): Likewise.
7102 * python/python-internal.h (class gdbpy_enter): Likewise.
7103 * regcache.h (regcache): Likewise.
7104 * target-descriptions.c (struct tdesc_reg): Likewise.
7105 (struct tdesc_type): Likewise.
7106 (struct tdesc_feature): Likewise.
7107 * ui-out.h (ui_out_emit_type): Likewise.
7108
0615127c
SM
71092017-09-18 Simon Marchi <simon.marchi@ericsson.com>
7110
7111 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
7112 label abort_expression.
7113
5e187554
SM
71142017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7115
7116 * common/buffer.c (buffer_xml_printf): Adjust.
7117 * common/xml-utils.c (xml_escape_text): Change return type to
7118 std::string, update code accordingly.
7119 * common/xml-utils.h (xml_escape_text): Change return type to
7120 std::string.
7121 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
7122 * windows-tdep.c (windows_xfer_shared_library): Adjust.
7123 * unittests/xml-utils-selftests.c (test_xml_escape_text):
7124 Adjust.
7125
c3d7b541
SM
71262017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7127
7128 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
7129 (SUBDIR_UNITTESTS_OBS): Add new object file.
7130 * unittests/xml-utils-selftests.c: New file.
7131
1526853e
SM
71322017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7133
7134 * common/selftest.h (selftest): New struct/interface.
7135 (register_test): Add name parameter, add new overload.
7136 (run_tests): Add filter parameter.
7137 (for_each_selftest_ftype): New typedef.
7138 (for_each_selftest): New declaration.
7139 * common/selftest.c (tests): Change type to
7140 map<string, unique_ptr<selftest>>.
7141 (simple_selftest): New struct.
7142 (register_test): New function.
7143 (register_test): Add name parameter and use it.
7144 (run_tests): Add filter parameter and use it. Add prints.
7145 Adjust to vector -> map change.
7146 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
7147 registering selftests.
7148 * arm-tdep.c (_initialize_arm_tdep): Likewise.
7149 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
7150 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
7151 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
7152 * findvar.c (_initialize_findvar): Likewise.
7153 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
7154 * maint.c (maintenance_selftest): Update call to run_tests.
7155 (maintenance_info_selftests): New function.
7156 (_initialize_maint_cmds): Register "maintenance info selftests"
7157 command. Update "maintenance selftest" doc.
7158 * regcache.c (_initialize_regcache): Add names when registering
7159 selftests.
7160 * rust-exp.y (_initialize_rust_exp): Likewise.
7161 * selftest-arch.c (gdbarch_selftest): New struct.
7162 (gdbarch_tests): Remove.
7163 (register_test_foreach_arch): Add name parameter. Call
7164 register_test.
7165 (tests_with_arch): Remove, move most content to
7166 gdbarch_selftest::operator().
7167 (_initialize_selftests_foreach_arch): Remove.
7168 * selftest-arch.h (register_test_foreach_arch): Add name
7169 parameter.
7170 (run_tests_with_arch): New declaration.
7171 * utils-selftests.c (_initialize_utils_selftests): Add names
7172 when registering selftests.
7173 * utils.c (_initialize_utils): Likewise.
7174 * unittests/array-view-selftests.c
7175 (_initialize_array_view_selftests): Likewise.
7176 * unittests/environ-selftests.c (_initialize_environ_selftests):
7177 Likewise.
7178 * unittests/function-view-selftests.c
7179 (_initialize_function_view_selftests): Likewise.
7180 * unittests/offset-type-selftests.c
7181 (_initialize_offset_type_selftests): Likewise.
7182 * unittests/optional-selftests.c
7183 (_initialize_optional_selftests): Likewise.
7184 * unittests/scoped_restore-selftests.c
7185 (_initialize_scoped_restore_selftests): Likewise.
7186 * NEWS: Document "maintenance selftest" and "maint info
7187 selftests".
7188
5846367a
SM
71892017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7190
7191 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7192 scoped_restore.
7193
bd77e8ff
SM
71942017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7195
7196 * mi/mi-main.c (mi_load_progress): Make uiout variable
7197 a unique_ptr.
7198
26a67918
PA
71992017-09-15 Pedro Alves <palves@redhat.com>
7200
7201 * compile/compile-c-types.c (convert_enum, convert_int)
7202 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7203
3f8a7804
SM
72042017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7205
7206 * dwarf2read.c (copy_string): Remove.
7207 (parse_macro_definition): Replace copy_string with savestring.
7208
8d200706
YQ
72092017-09-15 Yao Qi <yao.qi@linaro.org>
7210
7211 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7212 gdb_target_obs.
7213 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7214 Likewise.
7215 (i[34567]86-*-linux*): Likewise.
7216
d185219d
SM
72172017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7218
7219 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7220 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7221 <stack>: Change type to std::vector.
7222 <stack_len, stack_allocated>: Remove.
7223 <grow_stack>: Remove.
7224 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7225 (dwarf_expr_context::~dwarf_expr_context): Remove.
7226 (dwarf_expr_context::grow_stack): Remove.
7227 (dwarf_expr_context::push): Adjust.
7228 (dwarf_expr_context::pop): Adjust.
7229 (dwarf_expr_context::fetch): Adjust.
7230 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7231 (dwarf_expr_context::stack_empty_p): Adjust.
7232 (dwarf_expr_context::execute_stack_op): Adjust.
7233
eccd80d6
SM
72342017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7235
7236 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7237 return type to bool.
7238 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7239
69009882
SM
72402017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7241
7242 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7243 Change type to bool.
7244 (dwarf_stack_value) <in_stack_memory>: Likewise.
7245 (dwarf_expr_context) <push_address>: Change parameter type to
7246 bool.
7247 <fetch_in_stack_memory>: Change return type to bool.
7248 <push>: Change parameter type to bool.
7249 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7250 to bool.
7251 (dwarf_expr_context::push_address): Likewise.
7252 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7253 to bool.
7254 (dwarf_expr_context::execute_stack_op): Adjust.
7255 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7256
1e467161
SM
72572017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7258
7259 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7260 (struct dwarf_expr_context) <n_pieces>: Remove.
7261 <pieces>: Change type to std::vector.
7262 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7263 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7264 pieces.
7265 (dwarf_expr_context::add_piece): Adjust.
7266 * dwarf2loc.c (struct piece_closure): Initialize fields.
7267 <n_pieces>: Remove.
7268 <pieces>: Change type to std::vector.
7269 (allocate_piece_closure): Adjust, change parameter to
7270 std::vector rvalue and std::move it to piece_closure.
7271 (rw_pieced_value): Adjust.
7272 (check_pieced_synthetic_pointer): Adjust.
7273 (indirect_synthetic_pointer): Adjust.
7274 (coerce_pieced_ref): Adjust.
7275 (free_pieced_value_closure): Adjust. Use delete to free
7276 piece_closure.
7277 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7278 to allocate_piece_closure.
7279 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7280
0782db84
SM
72812017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7282
7283 * probe.h (probe_ops_cp): Remove typedef.
7284 (DEF_VEC_P (probe_ops_cp)): Remove.
7285 (all_probe_ops): Change type to std::vector.
7286 * probe.c (info_probes_for_ops): Adjust to vector change.
7287 (probe_linespec_to_ops): Likewise.
7288 (all_probe_ops): Change type to std::vector.
7289 (_initialize_probe): Adjust to vector change.
7290 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7291 * elfread.c (elf_get_probes): Likewise.
7292 * stap-probe.c (_initialize_stap_probe): Likewise.
7293
1eac6bea
SM
72942017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7295
7296 * probe.h (struct bound_probe): Define constructors.
7297 * probe.c (bound_probe_s): Remove typedef.
7298 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7299 (collect_probes): Change return type to std::vector, remove
7300 cleanup.
7301 (compare_probes): Return bool, change parameter type. Change
7302 semantic to "less than".
7303 (gen_ui_out_table_header_info): Change parameter to std::vector
7304 and update.
7305 (exists_probe_with_pops): Likewise.
7306 (info_probes_for_ops): Update to std::vector change.
7307 (enable_probes_command): Likewise.
7308 (disable_probes_command): Likewise.
7309
aaa63a31
SM
73102017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7311
7312 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7313 vec to std::vector.
7314 * probe.c (parse_probes_in_pspace): Update.
7315 (find_probes_in_objfile): Update.
7316 (find_probe_by_pc): Update.
7317 (collect_probes): Update.
7318 (probe_any_get_probes): Update.
7319 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7320 return type to reference to std::vector.
7321 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7322 std::vector and update.
7323 (dtrace_process_dof): Likewise.
7324 (dtrace_get_probes): Likewise.
7325 * elfread.c (elf_get_probes): Change return type to std::vector,
7326 store an std::vector in bfd_data.
7327 (probe_key_free): Update to std::vector.
7328 * stap-probe.c (handle_stap_probe): Change parameter to
7329 std::vector and update.
7330 (stap_get_probes): Likewise.
7331 * symfile-debug.c (debug_sym_get_probes): Change return type to
7332 std::vector and update.
7333
cb85b21b
TT
73342017-09-11 Tom Tromey <tom@tromey.com>
7335
7336 * breakpoint.c (program_breakpoint_here_p): Update.
7337 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7338 from make_show_memory_breakpoints_cleanup. Return a
7339 scoped_restore_tmpl<int>.
7340 (restore_show_memory_breakpoints): Remove.
7341 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7342 * mem-break.c (memory_validate_breakpoint): Update.
7343 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7344 (ia64_memory_remove_breakpoint): Update.
7345 (ia64_breakpoint_from_pc): Update.
7346 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7347 from make_show_memory_breakpoints_cleanup.
7348
8fbc99ef
TT
73492017-09-11 Tom Tromey <tom@tromey.com>
7350
7351 * d-namespace.c (d_lookup_symbol): Use std::string.
7352 (find_symbol_in_baseclass): Likewise.
7353
50feb4bd
TT
73542017-09-11 Tom Tromey <tom@tromey.com>
7355
7356 * ctf.c (ctf_start): Use std::string.
7357
c6dc63a1
TT
73582017-09-11 Tom Tromey <tom@tromey.com>
7359
7360 * ada-lang.c (is_known_support_routine): Update.
7361 (ada_unhandled_exception_name_addr_from_raise): Update.
7362 * guile/scm-frame.c (gdbscm_frame_name): Update.
7363 * python/py-frame.c (frapy_name): Update.
7364 (frapy_function): Update.
7365 * stack.h (find_frame_funname): Update.
7366 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7367 (print_frame): Update.
7368
d6b9b80f
TT
73692017-09-11 Tom Tromey <tom@tromey.com>
7370
7371 * findcmd.c (put_bits): Take a gdb::byte_vector.
7372 (parse_find_args): Return gdb::byte_vector. "args" now const.
7373 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7374 cleanups.
7375 (find_command): Update.
7376
a9921622
TT
73772017-09-11 Tom Tromey <tom@tromey.com>
7378
7379 * cli/cli-script.c (class scoped_restore_hook_in): New.
7380 (clear_hook_in_cleanup): Remove.
7381 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7382 scoped_restore_hook_in.
7383
be0d7abb
TT
73842017-09-11 Tom Tromey <tom@tromey.com>
7385
7386 * cli/cli-script.c (restore_interp): Remove.
7387 (read_command_lines): Use scoped_restore_interp.
7388 * interps.c (scoped_restore_interp::set_temp): Rename from
7389 interp_set_temp.
7390 * interps.h (class scoped_restore_interp): New.
7391 (interp_set_temp): Remove.
7392
00f675ff
TT
73932017-09-11 Tom Tromey <tom@tromey.com>
7394
7395 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7396 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7397 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7398 scoped_restore.
7399 (mi_cmd_break_insert_1): Update.
7400 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7401 scoped_restore.
7402
cb791d59
TT
74032017-09-11 Tom Tromey <tom@tromey.com>
7404
7405 * demangle.c (demangle_command): Update.
7406 * breakpoint.c (disable_command): Update.
7407 (enable_command): Update.
7408 (find_location_by_number): Make "number" const. Use
7409 get_number_trailer.
7410 * cli/cli-utils.c (extract_arg): Return std::string.
7411 * probe.c (parse_probe_linespec): Update. Change types.
7412 (collect_probes): Take string arguments.
7413 (parse_probe_linespec): Likewise.
7414 (info_probes_for_ops): Update.
7415 (enable_probes_command): Update.
7416 (disable_probes_command): Update.
7417 * break-catch-sig.c (catch_signal_split_args): Update.
7418 * mi/mi-parse.c (mi_parse): Update.
7419
2039bd9f
TT
74202017-09-11 Tom Tromey <tom@tromey.com>
7421
7422 * language.h (language_enum): Make argument const.
7423 * language.c (language_enum): Make argument const.
7424
f1735a53
TT
74252017-09-11 Tom Tromey <tom@tromey.com>
7426
7427 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7428 as function.
7429 (skip_to_space): Rename from skip_to_space_const.
7430 * common/common-utils.c (skip_to_space): New function.
7431 (skip_to_space): Rename from skip_to_space_const.
7432 * cli/cli-utils.h (get_number): Rename from get_number_const.
7433 (extract_arg): Rename from extract_arg_const.
7434 * cli/cli-utils.c (get_number): Rename from get_number_const.
7435 (extract_arg): Rename from extract_arg_const.
7436 (number_or_range_parser::get_number): Use ::get_number.
7437 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7438 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7439 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7440 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7441 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7442 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7443 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7444 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7445
7d221d74
TT
74462017-09-11 Tom Tromey <tom@tromey.com>
7447
7448 * python/python.c (do_start_initialization): Use
7449 py-event-types.def to initialize types.
7450 Define all object type structures.
7451 * python/python-internal.h: Don't declare event initialization
7452 functions.
7453 * python/py-threadevent.c (thread_event_object_type): Don't
7454 define.
7455 * python/py-stopevent.c (stop_event_object_type): Don't define.
7456 * python/py-signalevent.c (signal_event_object_type): Don't
7457 declare or define.
7458 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7459 (clear_objfiles_event_object_type): Don't declare or define.
7460 * python/py-infevents.c (inferior_call_pre_event_object_type)
7461 (inferior_call_post_event_object_type)
7462 (register_changed_event_object_type)
7463 (memory_changed_event_object_type): Don't declare or define.
7464 * python/py-inferior.c (new_thread_event_object_type)
7465 (new_inferior_event_object_type)
7466 (inferior_deleted_event_object_type): Don't declare or define.
7467 * python/py-exitedevent.c (exited_event_object_type): Don't
7468 declare or define.
7469 * python/py-evts.c (gdbpy_initialize_py_events): Use
7470 py-all-events.def.
7471 * python/py-events.h (thread_event_object_type): Don't declare.
7472 (events_object): Use py-all-events.def.
7473 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7474 py-event-types.def.
7475 * python/py-event-types.def: New file.
7476 * python/py-continueevent.c (create_continue_event_object): Don't
7477 declare or define.
7478 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7479 declare or define.
7480 * python/py-all-events.def: New file.
7481
35c61a1d
TT
74822017-09-11 Tom Tromey <tom@tromey.com>
7483
7484 * python/py-threadevent.c (create_thread_event_object): Return
7485 gdbpy_ref.
7486 * python/py-stopevent.h (create_stop_event_object)
7487 (create_breakpoint_event_object, create_signal_event_object):
7488 Update.
7489 * python/py-stopevent.c (create_stop_event_object): Return
7490 gdbpy_ref.
7491 (emit_stop_event): Update.
7492 * python/py-signalevent.c (create_signal_event_object): Return
7493 gdbpy_ref.
7494 * python/py-infevents.c (create_inferior_call_event_object):
7495 Update.
7496 * python/py-event.h (create_event_object)
7497 (create_thread_event_object): Update.
7498 * python/py-event.c (create_event_object): Return gdbpy_ref.
7499 * python/py-continueevent.c: Return gdbpy_ref.
7500 * python/py-bpevent.c (create_breakpoint_event_object): Return
7501 gdbpy_ref.
7502
7c96f8c1
TT
75032017-09-11 Tom Tromey <tom@tromey.com>
7504
7505 PR python/15622:
7506 * NEWS: Add entry.
7507 * python/python.c (do_start_initialization): Initialize new event
7508 types.
7509 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7510 (gdbpy_initialize_inferior_deleted_event)
7511 (gdbpy_initialize_new_thread_event): Declare.
7512 * python/py-threadevent.c (create_thread_event_object): Add option
7513 "thread" parameter.
7514 * python/py-inferior.c (new_thread_event_object_type)
7515 (new_inferior_event_object_type)
7516 (inferior_deleted_event_object_type): Declare.
7517 (python_new_inferior, python_inferior_deleted): New functions.
7518 (add_thread_object): Emit new_thread event.
7519 (gdbpy_initialize_inferior): Attach new functions to corresponding
7520 observers.
7521 (new_thread, new_inferior, inferior_deleted): Define new event
7522 types.
7523 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7524 registries.
7525 * python/py-events.h (events_object) <new_inferior,
7526 inferior_deleted, new_thread>: New fields.
7527 * python/py-event.h (create_thread_event_breakpoint): Add optional
7528 "thread" parameter.
7529
72542b8e
AB
75302017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7531
7532 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7533 check current_ui instead.
7534 (internal_vproblem): Likewise.
7535
0d64823e
SM
75362017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7537
7538 * thread.c (print_thread_info_1): Remove unnecessary calls to
7539 uiout->is_mi_like_p.
7540
eb1e02fd
TT
75412017-09-09 Tom Tromey <tom@tromey.com>
7542
7543 * namespace.h (add_using_directive): Update.
7544 * namespace.c (add_using_directive): Change type of excludes to
7545 std::vector.
7546 * dwarf2read.c (read_import_statement): Use std::vector.
7547 (read_namespace): Update.
7548 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
7549
0fc21fd8
TT
75502017-09-09 Tom Tromey <tom@tromey.com>
7551
7552 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
7553
49663d05
TT
75542017-09-09 Tom Tromey <tom@tromey.com>
7555
7556 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
7557
0b868b60
TT
75582017-09-09 Tom Tromey <tom@tromey.com>
7559
7560 * stack.c (func_command): Use gdb::def_vector.
7561
c0470d48
TT
75622017-09-09 Tom Tromey <tom@tromey.com>
7563
7564 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
7565 ui_out_emit_list, ui_out_emit_tuple.
7566 (mi_cmd_var_update): Likewise.
7567
ca5909c7
TT
75682017-09-09 Tom Tromey <tom@tromey.com>
7569
7570 * mi/mi-interp.c (mi_user_selected_context_changed): Use
7571 ui_out_redirect_pop.
7572 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7573 ui_out_redirect_pop.
7574 * utils.c (do_ui_out_redirect_pop)
7575 (make_cleanup_ui_out_redirect_pop): Remove.
7576 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
7577 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
7578 * ui-out.h (ui_out_redirect_pop): New class.
7579
e6a2252a
TT
75802017-09-09 Tom Tromey <tom@tromey.com>
7581
7582 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
7583 (list_available_thread_groups, mi_cmd_list_thread_groups)
7584 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
7585 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
7586 Likewise.
7587
393702cd
TT
75882017-09-09 Tom Tromey <tom@tromey.com>
7589
7590 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
7591 ui_out_emit_tuple.
7592
76f9c9cf
TT
75932017-09-09 Tom Tromey <tom@tromey.com>
7594
7595 * target.c (flash_erase_command): Use ui_out_emit_tuple.
7596 * stack.c (print_frame): Use ui_out_emit_tuple.
7597 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
7598 (info_spu_mailbox_command, info_spu_dma_command)
7599 (info_spu_proxydma_command): Likewise.
7600 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
7601 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
7602 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7603 ui_out_emit_tuple.
7604 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
7605
dc9fe180
TT
76062017-09-09 Tom Tromey <tom@tromey.com>
7607
7608 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
7609 (class ui_out_emit_table): Update comment.
7610 * ui-out.c (do_cleanup_table_end)
7611 (make_cleanup_ui_out_table_begin_end): Remove.
7612 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
7613 (info_spu_dma_cmdlist): Likewise.
7614 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
7615 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
7616 ui_out_emit_table.
7617
f8cc3da6
TT
76182017-09-09 Tom Tromey <tom@tromey.com>
7619
7620 * thread.c (print_thread_info_1): Use ui_out_emit_table,
7621 ui_out_emit_list, gdb::optional.
7622
481695ed
JB
76232017-09-09 John Baldwin <jhb@FreeBSD.org>
7624
7625 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
7626 prototype.
7627 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
7628 prototype.
7629 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
7630 prototype.
7631 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
7632 * ada-exp.y: Remove _initialize_ada_exp prototype.
7633 * ada-lang.c: Remove _initialize_ada_language prototype.
7634 * ada-tasks.c: Remove _initialize_tasks prototype.
7635 * addrmap.c: Remove _initialize_addrmap prototype.
7636 * agent.c: Remove _initialize_agent prototype.
7637 * aix-thread.c: Remove _initialize_aix_thread prototype.
7638 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
7639 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
7640 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
7641 prototype.
7642 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
7643 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
7644 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
7645 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
7646 prototype.
7647 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
7648 prototype.
7649 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
7650 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
7651 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
7652 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
7653 prototype.
7654 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
7655 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
7656 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
7657 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
7658 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7659 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
7660 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
7661 prototype.
7662 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
7663 prototype.
7664 * annotate.c: Remove _initialize_annotate prototype.
7665 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
7666 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
7667 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
7668 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
7669 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
7670 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
7671 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
7672 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
7673 prototype.
7674 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
7675 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
7676 * auto-load.c: Remove _initialize_auto_load prototype.
7677 * auxv.c: Remove _initialize_auxv prototype.
7678 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
7679 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
7680 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
7681 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
7682 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
7683 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
7684 prototype.
7685 * break-catch-throw.c: Remove _initialize_break_catch_throw
7686 prototype.
7687 * breakpoint.c: Remove _initialize_breakpoint prototype.
7688 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
7689 * btrace.c: Remove _initialize_btrace prototype.
7690 * charset.c: Remove _initialize_charset prototype.
7691 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
7692 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
7693 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
7694 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
7695 * cli/cli-script.c: Remove _initialize_cli_script prototype.
7696 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
7697 * coffread.c: Remove _initialize_coffread prototype.
7698 * compile/compile.c: Remove _initialize_compile prototype.
7699 * complaints.c: Remove _initialize_complaints prototype.
7700 * completer.c: Remove _initialize_completer prototype.
7701 * copying.awk: Remove _initialize_copying prototype.
7702 * copying.c: Regenerate.
7703 * core-regset.c: Remove _initialize_core_regset prototype.
7704 * corefile.c: Remove _initialize_core prototype.
7705 * corelow.c: Remove _initialize_corelow prototype.
7706 * cp-abi.c: Remove _initialize_cp_abi prototype.
7707 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
7708 * cp-support.c: Remove _initialize_cp_support prototype.
7709 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
7710 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
7711 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
7712 * ctf.c: Remove _initialize_ctf prototype.
7713 * d-lang.c: Remove _initialize_d_language prototype.
7714 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
7715 prototype.
7716 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
7717 * dbxread.c: Remove _initialize_dbxread prototype.
7718 * dcache.c: Remove _initialize_dcache prototype.
7719 * demangle.c: Remove _initialize_demangler prototype.
7720 * disasm-selftests.c: Remove _initialize_disasm_selftests
7721 prototype.
7722 * disasm.c: Remove _initialize_disasm prototype.
7723 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
7724 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
7725 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
7726 prototype.
7727 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
7728 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
7729 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
7730 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
7731 * elfread.c: Remove _initialize_elfread prototype.
7732 * exec.c: Remove _initialize_exec prototype.
7733 * extension.c: Remove _initialize_extension prototype.
7734 * f-lang.c: Remove _initialize_f_language prototype.
7735 * f-valprint.c: Remove _initialize_f_valprint prototype.
7736 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
7737 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
7738 * filesystem.c: Remove _initialize_filesystem prototype.
7739 * findcmd.c: Remove _initialize_mem_search prototype.
7740 * fork-child.c: Remove _initialize_fork_child prototype.
7741 * frame-base.c: Remove _initialize_frame_base prototype.
7742 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
7743 * frame.c: Remove _initialize_frame prototype.
7744 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
7745 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
7746 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
7747 * gcore.c: Remove _initialize_gcore prototype.
7748 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
7749 * gdbarch.c: Regenerate.
7750 * gdbarch.sh: Remove _initialize_gdbarch prototype.
7751 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
7752 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
7753 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
7754 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
7755 * go-lang.c: Remove _initialize_go_language prototype.
7756 * go32-nat.c: Remove _initialize_go32_nat prototype.
7757 * guile/guile.c: Remove _initialize_guile prototype.
7758 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
7759 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
7760 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
7761 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
7762 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
7763 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
7764 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
7765 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
7766 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
7767 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
7768 prototype.
7769 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
7770 prototype.
7771 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
7772 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
7773 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
7774 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
7775 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
7776 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
7777 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
7778 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
7779 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
7780 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
7781 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
7782 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
7783 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
7784 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7785 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
7786 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
7787 prototype.
7788 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
7789 prototype.
7790 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
7791 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
7792 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
7793 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
7794 * infcall.c: Remove _initialize_infcall prototype.
7795 * infcmd.c: Remove _initialize_infcmd prototype.
7796 * inferior.c: Remove _initialize_inferiors prototype.
7797 * inflow.c: Remove _initialize_inflow prototype.
7798 * infrun.c: Remove _initialize_infrun prototype.
7799 * interps.c: Remove _initialize_interpreter prototype.
7800 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
7801 * jit.c: Remove _initialize_jit prototype.
7802 * language.c: Remove _initialize_language prototype.
7803 * linux-fork.c: Remove _initialize_linux_fork prototype.
7804 * linux-nat.c: Remove _initialize_linux_nat prototype.
7805 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
7806 * linux-thread-db.c: Remove _initialize_thread_db prototype.
7807 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
7808 * m2-lang.c: Remove _initialize_m2_language prototype.
7809 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
7810 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
7811 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
7812 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
7813 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
7814 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7815 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7816 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
7817 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
7818 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
7819 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7820 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7821 * machoread.c: Remove _initialize_machoread prototype.
7822 * macrocmd.c: Remove _initialize_macrocmd prototype.
7823 * macroscope.c: Remove _initialize_macroscope prototype.
7824 * maint.c: Remove _initialize_maint_cmds prototype.
7825 * mdebugread.c: Remove _initialize_mdebugread prototype.
7826 * memattr.c: Remove _initialize_mem prototype.
7827 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
7828 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
7829 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
7830 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
7831 * mi/mi-main.c: Remove _initialize_mi_main prototype.
7832 * microblaze-linux-tdep.c: Remove
7833 _initialize_microblaze_linux_tdep prototype.
7834 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
7835 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
7836 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
7837 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
7838 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
7839 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
7840 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
7841 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
7842 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
7843 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
7844 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
7845 prototype.
7846 * mipsread.c: Remove _initialize_mipsread prototype.
7847 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
7848 prototype.
7849 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
7850 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
7851 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
7852 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
7853 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
7854 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
7855 prototype.
7856 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
7857 * nto-procfs.c: Remove _initialize_procfs prototype.
7858 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
7859 * objc-lang.c: Remove _initialize_objc_language prototype.
7860 * objfiles.c: Remove _initialize_objfiles prototype.
7861 * observer.c: Remove observer_test_first_notification_function,
7862 observer_test_second_notification_function,
7863 observer_test_third_notification_function, and
7864 _initialize_observer prototypes.
7865 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
7866 * osabi.c: Remove _initialize_gdb_osabi prototype.
7867 * osdata.c: Remove _initialize_osdata prototype.
7868 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
7869 * parse.c: Remove _initialize_parse prototype.
7870 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
7871 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
7872 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
7873 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
7874 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
7875 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
7876 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
7877 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
7878 * printcmd.c: Remove _initialize_printcmd prototype.
7879 * probe.c: Remove _initialize_probe prototype.
7880 * proc-api.c: Remove _initialize_proc_api prototype.
7881 * proc-events.c: Remove _initialize_proc_events prototype.
7882 * proc-service.c: Remove _initialize_proc_service prototype.
7883 * procfs.c: Remove _initialize_procfs prototype.
7884 * psymtab.c: Remove _initialize_psymtab prototype.
7885 * python/python.c: Remove _initialize_python prototype.
7886 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
7887 * record-btrace.c: Remove _initialize_record_btrace prototype.
7888 * record-full.c: Remove _initialize_record_full prototype.
7889 * record.c: Remove _initialize_record prototype.
7890 * regcache.c: Remove _initialize_regcache prototype.
7891 * reggroups.c: Remove _initialize_reggroup prototype.
7892 * remote-notif.c: Remove _initialize_notif prototype.
7893 * remote-sim.c: Remove _initialize_remote_sim prototype.
7894 * remote.c: Remove _initialize_remote prototype.
7895 * reverse.c: Remove _initialize_reverse prototype.
7896 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
7897 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
7898 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
7899 prototype.
7900 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
7901 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
7902 * rust-exp.y: Remove _initialize_rust_exp prototype.
7903 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
7904 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
7905 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
7906 * score-tdep.c: Remove _initialize_score_tdep prototype.
7907 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
7908 prototype.
7909 * ser-go32.c: Remove _initialize_ser_dos prototype.
7910 * ser-mingw.c: Remove _initialize_ser_windows prototype.
7911 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
7912 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
7913 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
7914 * serial.c: Remove _initialize_serial prototype.
7915 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
7916 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
7917 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
7918 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
7919 * skip.c: Remove _initialize_step_skip prototype.
7920 * sol-thread.c: Remove _initialize_sol_thread prototype.
7921 * solib-aix.c: Remove _initialize_solib_aix prototype.
7922 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
7923 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
7924 * solib-frv.c: Remove _initialize_frv_solib prototype.
7925 * solib-spu.c: Remove _initialize_spu_solib prototype.
7926 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
7927 * solib-target.c: Remove _initialize_solib_target prototype.
7928 * solib.c: Remove _initialize_solib prototype.
7929 * source.c: Remove _initialize_source prototype.
7930 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
7931 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
7932 prototype.
7933 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
7934 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
7935 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
7936 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
7937 prototype.
7938 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
7939 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
7940 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
7941 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
7942 prototype.
7943 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
7944 prototype.
7945 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
7946 prototype.
7947 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
7948 prototype.
7949 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
7950 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
7951 prototype.
7952 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
7953 prototype.
7954 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
7955 prototype.
7956 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
7957 prototype.
7958 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
7959 prototype.
7960 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
7961 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
7962 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
7963 * stabsread.c: Remove _initialize_stabsread prototype.
7964 * stack.c: Remove _initialize_stack prototype.
7965 * stap-probe.c: Remove _initialize_stap_probe prototype.
7966 * std-regs.c: Remove _initialize_frame_reg prototype.
7967 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
7968 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
7969 * symfile.c: Remove _initialize_symfile prototype.
7970 * symmisc.c: Remove _initialize_symmisc prototype.
7971 * symtab.c: Remove _initialize_symtab prototype.
7972 * target-dcache.c: Remove _initialize_target_dcache prototype.
7973 * target-descriptions.c: Remove _initialize_target_descriptions
7974 prototype.
7975 * thread.c: Remove _initialize_thread prototype.
7976 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
7977 prototype.
7978 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
7979 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
7980 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
7981 prototype.
7982 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
7983 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
7984 * tracefile.c: Remove _initialize_tracefile prototype.
7985 * tracepoint.c: Remove _initialize_tracepoint prototype.
7986 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
7987 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
7988 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
7989 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
7990 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
7991 * tui/tui-win.c: Remove _initialize_tui_win prototype.
7992 * tui/tui.c: Remove _initialize_tui prototype.
7993 * typeprint.c: Remove _initialize_typeprint prototype.
7994 * user-regs.c: Remove _initialize_user_regs prototype.
7995 * utils.c: Remove _initialize_utils prototype.
7996 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
7997 * valarith.c: Remove _initialize_valarith prototype.
7998 * valops.c: Remove _initialize_valops prototype.
7999 * valprint.c: Remove _initialize_valprint prototype.
8000 * value.c: Remove _initialize_values prototype.
8001 * varobj.c: Remove _initialize_varobj prototype.
8002 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
8003 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
8004 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
8005 * windows-nat.c: Remove _initialize_windows_nat,
8006 _initialize_check_for_gdb_ini, and _initialize_loadable
8007 prototypes.
8008 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
8009 * xcoffread.c: Remove _initialize_xcoffread prototype.
8010 * xml-support.c: Remove _initialize_xml_support prototype.
8011 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
8012 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
8013 prototype.
8014 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
8015 prototype.
8016 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
8017
a611b5cb
KS
80182017-09-08 Keith Seitz <keiths@redhat.com>
8019
8020 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
8021 field.
8022
469412dd
CW
80232017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
8024
8025 * f-valprint.c (f_val_print): Remove check for one byte
8026 sized integers. Remove printing of character type.
8027
a5ad232b
FP
80282017-09-08 Frank Penczek <frank.penczek@intel.com>
8029 Christoph Weinmann <christoph.t.weinmann@intel.com>
8030 Bernhard Heckel <bernhard.heckel@intel.com>
8031
8032 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
8033 to maintain proper indentation when printing pointers/refs.
8034
e5014227
JB
80352017-09-07 Joel Brobecker <brobecker@adacore.com>
8036
8037 GDB 8.0.1 released.
8038
63c99141
JB
80392017-09-07 Joel Brobecker <brobecker@adacore.com>
8040
8041 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
8042
69c1e056
TT
80432017-09-05 Tom Tromey <tom@tromey.com>
8044
8045 * parse.c (funcall_chain): Now a std::vector.
8046 (start_arglist, end_arglist): Simplify.
8047 (free_funcalls): Remove.
8048 (parse_exp_in_context_1): Remove cleanup.
8049
fef704bf
TT
80502017-09-05 Tom Tromey <tom@tromey.com>
8051
8052 * go-exp.y (go_parse): Don't create a cleanup.
8053
5613c585
TT
80542017-09-05 Tom Tromey <tom@tromey.com>
8055
8056 * d-exp.y (PrimaryExpression): Use std::string.
8057 (d_parse): Don't create a cleanup.
8058
eae49211
TT
80592017-09-05 Tom Tromey <tom@tromey.com>
8060
8061 * utils.c (do_clear_parser_state): Remove.
8062 (make_cleanup_clear_parser_state): Remove.
8063 * p-exp.y (pascal_parse): Use scoped_restore.
8064 * m2-exp.y (m2_parse): Use scoped_restore.
8065 * f-exp.y (f_parse): Use scoped_restore.
8066 * d-exp.y (d_parse): Use scoped_restore.
8067 * c-exp.y (c_parse): Use scoped_restore.
8068 * ada-exp.y (ada_parse): Use scoped_restore.
8069 * utils.h (make_cleanup_clear_parser_state): Remove.
8070
73b9be8b
KS
80712017-09-06 Keith Seitz <keiths@redhat.com>
8072
8073 * dwarf2read.c (dw2_linkage_name_attr): New function.
8074 (dw2_linkage_name): New function.
8075 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
8076 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
8077 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
8078
a102602b
KR
80792017-09-06 Kamil Rytarowski <n54@gmx.com>
8080
8081 * config/djgpp/djconfig.sh: Correct shell portability issue.
8082
28ad437d
KR
80832017-09-06 Kamil Rytarowski <n54@gmx.com>
8084
8085 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
8086
351787dd
JB
80872017-09-06 John Baldwin <jhb@FreeBSD.org>
8088
8089 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
8090 * NEWS: Mention new FreeBSD/mips native configuration.
8091 * configure.host: Add aarch64*-*-freebsd*.
8092 * configure.nat: Likewise.
8093 * aarch64-fbsd-nat.c: New file.
8094
c0f84956
JB
80952017-09-06 John Baldwin <jhb@FreeBSD.org>
8096
8097 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
8098 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
8099 * NEWS: Mention new FreeBSD/aarch64 target.
8100 * configure.tgt: Add aarch64*-*-freebsd*.
8101 * aarch64-fbsd-tdep.c: New file.
8102 * aarch64-fbsd-tdep.h: New file.
8103
7610297a
KR
81042017-09-06 Kamil Rytarowski <n54@gmx.com>
8105
8106 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
8107
fbd1b771
JK
81082017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
8109
8110 * parse.c (find_minsym_type_and_address): Don't relocate addresses
8111 of TLS symbols.
8112
5ca79eae
PW
81132017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
8114
8115 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
8116 call.
8117
bf93d7ba
SM
81182017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8119
8120 * infrun.c (follow_exec): Call add_thread after
8121 target_find_description.
8122
1bb7c059
SM
81232017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8124
8125 * infrun.c (handle_inferior_event_1): When exec'ing, read
8126 stop_pc after follow_exec.
8127
fc809827
SM
81282017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8129
8130 * remote.c (process_g_packet): Update error message.
8131
d2fcdd85
YQ
81322017-09-05 Yao Qi <yao.qi@linaro.org>
8133
8134 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
8135 targets.
8136
e69570ee
PA
81372017-09-05 Pedro Alves <palves@redhat.com>
8138
8139 * eval.c (eval_call, evaluate_funcall): New functions, factored
8140 out from ...
8141 (evaluate_subexp_standard): ... this.
8142
22916b07
YQ
81432017-09-05 Yao Qi <yao.qi@linaro.org>
8144
8145 * amd64-tdep.c (amd64_target_description): Create target
8146 descriptions.
8147 (_initialize_amd64_tdep): Don't call functions
8148 initialize_tdesc_amd64_*. Add self tests.
8149 * arch/amd64.c (amd64_create_target_description): Add parameter
8150 is_linux. Call set_tdesc_osabi if is_linux is true.
8151 * arch/amd64.h (amd64_create_target_description): Update the
8152 declaration.
8153 * arch/i386.c (i386_create_target_description): Add parameter
8154 is_linux. Call set_tdesc_osabi if is_linux is true.
8155 * arch/i386.h (i386_create_target_description): Update
8156 declaration.
8157 * configure.tgt: Add i386.o to gdb_target_obs.
8158 * features/Makefile (XMLTOC): Remove i386/*.xml.
8159 * features/i386/amd64-avx-avx512.c: Remove.
8160 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
8161 * features/i386/amd64-avx-mpx.c: Remove.
8162 * features/i386/amd64-avx.c: Remove.
8163 * features/i386/amd64-mpx.c: Remove.
8164 * features/i386/amd64.c: Remove.
8165 * features/i386/i386-avx-avx512.c: Remove.
8166 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
8167 * features/i386/i386-avx-mpx.c: Remove.
8168 * features/i386/i386-avx.c: Remove.
8169 * features/i386/i386-mmx.c: Remove.
8170 * features/i386/i386-mpx.c: Remove.
8171 * features/i386/i386.c: Remove.
8172 * i386-tdep.c: Don't include features/i386/i386*.c., include
8173 target-descriptions.h and arch/i386.h.
8174 (i386_target_description): Create target descriptions.
8175 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
8176 functions. Do self tests.
8177
0854b7b1
YQ
81782017-09-05 Yao Qi <yao.qi@linaro.org>
8179
8180 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
8181 * features/i386/amd64-avx-avx512-linux.c: Removed.
8182 * features/i386/amd64-avx-linux.c: Removed.
8183 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
8184 * features/i386/amd64-avx-mpx-linux.c: Removed.
8185 * features/i386/amd64-linux.c: Removed.
8186 * features/i386/amd64-mpx-linux.c: Removed.
8187 * features/i386/x32-avx-avx512-linux.c: Removed.
8188 * features/i386/x32-avx-linux.c: Removed.
8189 * features/i386/x32-linux.c: Removed.
8190
b4570e4b
YQ
81912017-09-05 Yao Qi <yao.qi@linaro.org>
8192
8193 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8194 features/i386/*.c.
8195 (amd64_linux_read_description): Call
8196 amd64_create_target_description.
8197 * arch/amd64.c: New file.
8198 * arch/amd64.h: New file.
8199 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8200 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8201
6c73f67f
YQ
82022017-09-05 Yao Qi <yao.qi@linaro.org>
8203
8204 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8205 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8206 (amd64_linux_read_description): Create target descriptions.
8207 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8208 functions. Add unit tests.
8209 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8210 x32-core.xml.
8211 * features/i386/64bit-avx.c: Generated.
8212 * features/i386/64bit-avx512.c: Generated.
8213 * features/i386/64bit-core.c: Generated.
8214 * features/i386/64bit-linux.c: Generated.
8215 * features/i386/64bit-mpx.c: Generated.
8216 * features/i386/64bit-pkeys.c: Generated.
8217 * features/i386/64bit-segments.c: Generated.
8218 * features/i386/64bit-sse.c: Generated.
8219 * features/i386/x32-core.c: Generated.
8220 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8221 c files for amd64-linux and x32-linux.
8222
9d3d478b
YQ
82232017-09-05 Yao Qi <yao.qi@linaro.org>
8224
8225 * amd64-linux-tdep.c (amd64_linux_read_description): New
8226 function.
8227 (amd64_linux_core_read_description): Call
8228 amd64_linux_read_description.
8229 (amd64_linux_init_abi): Likewise.
8230 (amd64_x32_linux_init_abi): Likewise.
8231 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8232 * x86-linux-nat.c (x86_linux_read_description): Call
8233 amd64_linux_read_description.
8234
b9f1d50f
YQ
82352017-09-05 Yao Qi <yao.qi@linaro.org>
8236
8237 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8238 comments.
8239
188c9e6d
YQ
82402017-09-05 Yao Qi <yao.qi@linaro.org>
8241
8242 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8243 * features/i386/i386-avx-avx512-linux.c: Remove.
8244 * features/i386/i386-avx-linux.c: Remove.
8245 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8246 * features/i386/i386-avx-mpx-linux.c: Remove.
8247 * features/i386/i386-linux.c: Remove.
8248 * features/i386/i386-mmx-linux.c: Remove.
8249 * features/i386/i386-mpx-linux.c: Remove.
8250
5f035c07
YQ
82512017-09-05 Yao Qi <yao.qi@linaro.org>
8252
8253 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8254 (SFILES): Add arch/i386.c.
8255 (HFILES_NO_SRCDIR): Add arch/i386.h.
8256 * arch/i386.c: New file.
8257 * arch/i386.h: New file.
8258 * arch/tdesc.h (allocate_target_description): Declare.
8259 (set_tdesc_architecture): Declare.
8260 (set_tdesc_osabi): Declare.
8261 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8262 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8263 include arch/i386.h.
8264 (i386_linux_read_description): Remove code and call
8265 i386_create_target_description.
8266 (set_tdesc_architecture): New function.
8267 (set_tdesc_osabi): New function.
8268 * target-descriptions.h (allocate_target_description): Remove.
8269
0abe8a89
YQ
82702017-09-05 Yao Qi <yao.qi@linaro.org>
8271
8272 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8273 * target-descriptions.c (tdesc_create_feature): Likewise, and
8274 adjust code.
8275 * features/i386/32bit-avx.c: Re-generated.
8276 * features/i386/32bit-avx512.c: Re-generated.
8277 * features/i386/32bit-core.c: Re-generated.
8278 * features/i386/32bit-linux.c: Re-generated.
8279 * features/i386/32bit-mpx.c: Re-generated.
8280 * features/i386/32bit-pkeys.c: Re-generated.
8281 * features/i386/32bit-sse.c: Re-generated.
8282
0a188386
YQ
82832017-09-05 Yao Qi <yao.qi@linaro.org>
8284
8285 * regformats/regdef.h (struct reg): Override operator == and !=.
8286
f49ff000
YQ
82872017-09-05 Yao Qi <yao.qi@linaro.org>
8288
8289 * arch/tdesc.h: New file.
8290 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8291 * target-descriptions.c: Update comments.
8292 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8293 declarations.
8294 * features/i386/32bit-avx.c: Re-generated.
8295 * features/i386/32bit-avx512.c: Re-generated.
8296 * features/i386/32bit-core.c: Re-generated.
8297 * features/i386/32bit-linux.c: Re-generated.
8298 * features/i386/32bit-mpx.c: Re-generated.
8299 * features/i386/32bit-pkeys.c: Re-generated.
8300 * features/i386/32bit-sse.c: Re-generated.
8301
f7000548
YQ
83022017-09-05 Yao Qi <yao.qi@linaro.org>
8303
8304 * regformats/regdat.sh: Update generated code.
8305
c9a5e2a5
YQ
83062017-09-05 Yao Qi <yao.qi@linaro.org>
8307
8308 * regformats/regdat.sh: Adjust code order.
8309
d6b687ac
SM
83102017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8311
8312 * expprint.c (dump_subexp_body_standard): Use constant format
8313 string in fprintf_filtered call.
8314
a379bfd0
JB
83152017-09-04 John Baldwin <jhb@FreeBSD.org>
8316
8317 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8318 NetBSD/i386.
8319 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8320
f7efc967
JB
83212017-09-04 John Baldwin <jhb@FreeBSD.org>
8322
8323 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8324
c49fbc6c
JB
83252017-09-04 John Baldwin <jhb@FreeBSD.org>
8326
8327 * bsd-kvm.o: Define _KMEMUSER.
8328 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8329 * configure: Regenerate.
8330
26562e73
JB
83312017-09-04 John Baldwin <jhb@FreeBSD.org>
8332
8333 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8334 * i386-fbsd-nat.c: Likewise.
8335
31cf1487
JB
83362017-09-04 John Baldwin <jhb@FreeBSD.org>
8337
8338 * unittests/array-view-selftests.c: Add include of <array>.
8339
5b9f8a7c
JB
83402017-09-04 John Baldwin <jhb@FreeBSD.org>
8341
8342 * spu-tdep.c (flush_ea_cache): Add missing argument to
8343 call_function_by_hand.
8344
d69cf9b2
PA
83452017-09-04 Pedro Alves <palves@redhat.com>
8346
8347 * NEWS (Safer support for debugging with no debug info): New.
8348
3693fdb3
PA
83492017-09-04 Pedro Alves <palves@redhat.com>
8350
8351 * c-exp.y (function_method, function_method_void): Add current
8352 instance flags to TYPE_INSTANCE.
8353 * dwarf2read.c (check_modifier): New.
8354 (compute_delayed_physnames): Assert that only C++ adds delayed
8355 physnames. Mark fn_fields as const/volatile depending on
8356 physname.
8357 * eval.c (make_params): New type_instance_flags parameter. Use
8358 it as the new type's instance flags.
8359 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8360 flags element and pass it to make_params.
8361 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8362 instance flags element.
8363 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8364 * gdbtypes.h: Include "enum-flags.h".
8365 (type_instance_flags): New enum-flags type.
8366 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8367 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8368 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8369 (follow_type_instance_flags): New function.
8370 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8371 * parser-defs.h (follow_type_instance_flags): Declare.
8372 * valops.c (value_struct_elt_for_reference): const/volatile must
8373 match too.
8374
e68cb8e0
PA
83752017-09-04 Pedro Alves <palves@redhat.com>
8376
8377 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8378 function/method scopes; lookup the nested name as a function local
8379 static variable.
8380
858be34c
PA
83812017-09-04 Pedro Alves <palves@redhat.com>
8382
8383 (%type <voidval>): Add function_method.
8384 * c-exp.y (exp): New production for calls with no arguments.
8385 (function_method, function_method_void_or_typelist): New
8386 productions.
8387 (exp): New production for "method()::static_var".
8388 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8389 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8390 Handle OP_FUNC_STATIC_VAR.
8391 * parse.c (operator_length_standard):
8392 Handle OP_FUNC_STATIC_VAR.
8393
dd5901a6
PA
83942017-09-04 Pedro Alves <palves@redhat.com>
8395
8396 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8397 handling.
8398 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8399 Ditto.
8400 * parse.c (operator_length_standard, operator_check_standard):
8401 Ditto.
8402 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8403
46a4882b
PA
84042017-09-04 Pedro Alves <palves@redhat.com>
8405
8406 * ax-gdb.c: Include "typeprint.h".
8407 (gen_expr_for_cast): New function.
8408 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8409 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8410 type is unknown.
8411 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8412 nodebug_data_symbol.
8413 * eval.c: Include "typeprint.h".
8414 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8415 Error out if symbol has unknown type.
8416 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8417 evaluate_subexp_for_cast.
8418 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8419 OP_VAR_MSYM_VALUE.
8420 (evaluate_subexp_for_cast): New function.
8421 * gdbtypes.c (init_nodebug_var_type): New function.
8422 (objfile_type): Use it to initialize types of variables with no
8423 debug info.
8424 * typeprint.c (error_unknown_type): New.
8425 * typeprint.h (error_unknown_type): New declaration.
8426 * compile/compile-c-types.c (convert_type_basic): Handle
8427 TYPE_CODE_ERROR; warn and fallback to int for variables with
8428 unknown type.
8429
fe13dfec
PA
84302017-09-04 Pedro Alves <palves@redhat.com>
8431
8432 * eval.c (evaluate_var_value): New function, factored out from ...
8433 (evaluate_subexp_standard): ... here.
8434
d008ee21
PA
84352017-09-04 Pedro Alves <palves@redhat.com>
8436
8437 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8438 Remove useless assignments to 'op'.
8439
827d0c51
PA
84402017-09-04 Pedro Alves <palves@redhat.com>
8441
8442 * eval.c (eval_skip_value): New function.
8443 (evaluate_subexp_standard): Use it.
8444
2c5a2be1
PA
84452017-09-04 Pedro Alves <palves@redhat.com>
8446
8447 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8448 function name from symbol/minsym and pass it to
8449 error_call_unknown_return_type.
8450
74ea4be4
PA
84512017-09-04 Pedro Alves <palves@redhat.com>
8452
8453 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8454 * ax-gdb.c (gen_msym_var_ref): New function.
8455 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8456 * eval.c (evaluate_var_msym_value): New function.
8457 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8458 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8459 to call_function_by_hand.
8460 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8461 Handle OP_VAR_MSYM_VALUE.
8462 (union exp_element) <msymbol>: New field.
8463 * minsyms.h (struct type): Forward declare.
8464 (find_minsym_type_and_address): Declare.
8465 * parse.c (write_exp_elt_msym): New function.
8466 (write_exp_msymbol): Delete, refactored as ...
8467 (find_minsym_type_and_address): ... this new function.
8468 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8469 (operator_length_standard, operator_check_standard): Handle
8470 OP_VAR_MSYM_VALUE.
8471 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8472
7022349d
PA
84732017-09-04 Pedro Alves <palves@redhat.com>
8474
8475 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8476 TYPE_GNU_IFUNC specially here. Throw error if return type is
8477 unknown.
8478 * ada-typeprint.c (print_func_type): Handle functions with unknown
8479 return type.
8480 * c-typeprint.c (c_type_print_base): Handle functions and methods
8481 with unknown return type.
8482 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8483 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8484 * compile/compile-c-types.c: Include "objfiles.h".
8485 (convert_func): For functions with unknown return type, warn and
8486 default to int.
8487 * compile/compile-object-run.c (compile_object_run): Adjust call
8488 to call_function_by_hand_dummy.
8489 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8490 call_function_by_hand.
8491 * eval.c (evaluate_subexp_standard): Adjust calls to
8492 call_function_by_hand. Handle functions and methods with unknown
8493 return type. Pass expect_type to call_function_by_hand.
8494 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8495 return type.
8496 * gcore.c (call_target_sbrk): Adjust call to
8497 call_function_by_hand.
8498 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8499 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8500 an integer address type instead of nodebug.
8501 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8502 call_function_by_hand.
8503 * infcall.c (error_call_unknown_return_type): New function.
8504 (call_function_by_hand): New "default_return_type" parameter.
8505 Pass it down.
8506 (call_function_by_hand_dummy): New "default_return_type"
8507 parameter. Use it instead of defaulting to int. If there's no
8508 default and the return type is unknown, throw an error. If
8509 there's a default return type, and the called function has no
8510 debug info, then assume the function is prototyped.
8511 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8512 New "default_return_type" parameter.
8513 (error_call_unknown_return_type): New declaration.
8514 * linux-fork.c (call_lseek): Cast return type of lseek.
8515 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8516 call_function_by_hand.
8517 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8518 calls to call_function_by_hand.
8519 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8520 return type.
8521 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8522 (value_nsstring, print_object_command): Adjust calls to
8523 call_function_by_hand.
8524 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8525 functions with unknown return type.
8526 (pascal_type_print_func_varspec_suffix): New function.
8527 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8528 TYPE_CODE_METHOD>: Use it.
8529 * python/py-value.c (valpy_call): Adjust call to
8530 call_function_by_hand.
8531 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8532 call_function_by_hand.
8533 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8534 call_function_by_hand.
8535 * valops.c (value_allocate_space_in_inferior): Adjust call to
8536 call_function_by_hand.
8537 * typeprint.c (type_print_unknown_return_type): New function.
8538 * typeprint.h (type_print_unknown_return_type): New declaration.
8539
54990598
PA
85402017-09-04 Pedro Alves <palves@redhat.com>
8541
8542 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
8543 types with more than one parameter as prototyped.
8544
9a24775b
PA
85452017-09-04 Pedro Alves <palves@redhat.com>
8546
8547 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
8548 (disassemble_command): Use gdb_disassembly_flags instead of bare
8549 int.
8550 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
8551 (dump_insns, do_mixed_source_and_assembly_deprecated)
8552 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
8553 Use gdb_disassembly_flags instead of bare int.
8554 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
8555 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
8556 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
8557 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
8558 (enum gdb_disassembly_flag): ... values of this new enumeration.
8559 (gdb_disassembly_flags): Define.
8560 (gdb_disassembly)
8561 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
8562 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
8563 gdb_disassembly_flags instead of bare int.
8564 * record-btrace.c (btrace_insn_history)
8565 (record_btrace_insn_history, record_btrace_insn_history_range)
8566 (record_btrace_insn_history_from): Use gdb_disassembly_flags
8567 instead of bare int.
8568 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
8569 Use gdb_disassembly_flags instead of bare int.
8570 * target-debug.h (target_debug_print_gdb_disassembly_flags):
8571 Define.
8572 * target-delegates.c: Regenerate.
8573 * target.c (target_insn_history, target_insn_history_from)
8574 (target_insn_history_range): Use gdb_disassembly_flags instead of
8575 bare int.
8576 * target.h: Include "disasm.h".
8577 (struct target_ops) <to_insn_history, to_insn_history_from,
8578 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
8579 int.
8580 (target_insn_history, target_insn_history_from)
8581 (target_insn_history_range): Use gdb_disassembly_flags instead of
8582 bare int.
8583
80a65e9b
SM
85842017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8585
8586 * cli/cli-script.c (build_command_line): For if/while commands,
8587 check whether args is empty.
8588
6b66338c
SM
85892017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8590
8591 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
8592 (enum command_control_type): Likewise.
8593 (struct command_line): Likewise.
8594 (free_command_lines): Likewise.
8595 (struct command_lines_deleter): Likewise.
8596 (command_line_up): Likewise.
8597 (read_command_lines): Likewise.
8598 (read_command_lines_1): Likewise.
8599 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
8600 (enum command_control_type): Likewise.
8601 (struct command_line): Likewise.
8602 (free_command_lines): Likewise.
8603 (struct command_lines_deleter): Likewise.
8604 (command_line_up): Likewise.
8605 (read_command_lines): Likewise.
8606 (read_command_lines_1): Likewise.
8607 * breakpoint.h: Include cli/cli-script.h.
8608 * extension-priv.h: Likewise.
8609 * gdbcmd.h: Likewise.
8610
51abb421
PA
86112017-09-04 Pedro Alves <palves@redhat.com>
8612
8613 * ada-lang.c (is_known_support_routine): Move sal declaration to
8614 where it is initialized.
8615 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
8616 (parse_breakpoint_sals, decode_static_tracepoint_spec)
8617 (clear_command, update_static_tracepoint): Remove init_sal
8618 references. Move declarations closer to initializations.
8619 * cli/cli-cmds.c (list_command): Move sal declarations closer to
8620 initializations.
8621 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
8622 references. Move sal declarations closer to initializations.
8623 * frame.c (find_frame_sal): Return a symtab_and_line via function
8624 return instead of output parameter. Remove init_sal references.
8625 * frame.h (find_frame_sal): Return a symtab_and_line via function
8626 return instead of output parameter.
8627 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
8628 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
8629 instead of memset.
8630 (gdbscm_find_pc_line): Remove init_sal reference.
8631 * infcall.c (call_function_by_hand_dummy): Remove init_sal
8632 references. Move declarations closer to initializations.
8633 * infcmd.c (set_step_frame): Update. Move declarations closer to
8634 initializations.
8635 (finish_backward): Remove init_sal references. Move declarations
8636 closer to initializations.
8637 * infrun.c (process_event_stop_test, handle_step_into_function)
8638 (insert_hp_step_resume_breakpoint_at_frame)
8639 (insert_step_resume_breakpoint_at_caller): Likewise.
8640 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
8641 (symbol_to_sal): Likewise.
8642 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
8643 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
8644 to its initialization.
8645 * reverse.c (save_bookmark_command): Use new/delete. Remove
8646 init_sal references. Move declarations closer to initializations.
8647 * source.c (get_current_source_symtab_and_line): Remove brace
8648 initialization.
8649 (set_current_source_symtab_and_line): Now takes the sal by const
8650 reference. Remove brace initialization.
8651 (line_info): Remove init_sal reference.
8652 * source.h (set_current_source_symtab_and_line): Now takes a
8653 symtab_and_line via const reference.
8654 * stack.c (set_current_sal_from_frame): Adjust.
8655 (print_frame_info): Adjust.
8656 (get_last_displayed_sal): Return the sal via function return
8657 instead of via output parameter. Simplify.
8658 (frame_info): Adjust.
8659 * stack.h (get_last_displayed_sal): Return the sal via function
8660 return instead of via output parameter.
8661 * symtab.c (init_sal): Delete.
8662 (find_pc_sect_line): Remove init_sal references. Move
8663 declarations closer to initializations.
8664 (find_function_start_sal): Remove init_sal references. Move
8665 declarations closer to initializations.
8666 * symtab.h (struct symtab_and_line): In-class initialize all
8667 fields.
8668 * tracepoint.c (set_traceframe_context)
8669 (print_one_static_tracepoint_marker): Remove init_sal references.
8670 Move declarations closer to initializations.
8671 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
8672 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
8673 declarations closer to initializations.
8674 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
8675 init_sal references. Adjust.
8676
6c5b2ebe
PA
86772017-09-04 Pedro Alves <palves@redhat.com>
8678
8679 * ax-gdb.c (agent_command_1): Use range-for.
8680 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8681 * breakpoint.c: Include "common/array-view.h".
8682 (init_breakpoint_sal, create_breakpoint_sal): Change sals
8683 parameter from struct symtabs_and_lines to
8684 array_view<symtab_and_line>. Adjust. Use range-for. Update.
8685 (breakpoint_sals_to_pc): Change sals parameter from struct
8686 symtabs_and_lines to std::vector reference.
8687 (check_fast_tracepoint_sals): Change sals parameter from struct
8688 symtabs_and_lines to std::array_view. Use range-for.
8689 (decode_static_tracepoint_spec): Return a std::vector instead of
8690 symtabs_and_lines. Update.
8691 (create_breakpoint): Update.
8692 (break_range_command, until_break_command, clear_command): Update.
8693 (base_breakpoint_decode_location, bkpt_decode_location)
8694 (bkpt_probe_create_sals_from_location)
8695 (bkpt_probe_decode_location, tracepoint_decode_location)
8696 (tracepoint_probe_decode_location)
8697 (strace_marker_create_sals_from_location): Return a std::vector
8698 instead of symtabs_and_lines.
8699 (strace_marker_create_breakpoints_sal): Update.
8700 (strace_marker_decode_location): Return a std::vector instead of
8701 symtabs_and_lines. Update.
8702 (update_breakpoint_locations): Change struct symtabs_and_lines
8703 parameters to gdb::array_view. Adjust.
8704 (location_to_sals): Return a std::vector instead of
8705 symtabs_and_lines. Update.
8706 (breakpoint_re_set_default): Use std::vector instead of struct
8707 symtabs_and_lines.
8708 (decode_location_default): Return a std::vector instead of
8709 symtabs_and_lines. Update.
8710 * breakpoint.h: Include "common/array-view.h".
8711 (struct breakpoint_ops) <decode_location>: Now returns a
8712 std::vector instead of returning a symtabs_and_lines via output
8713 parameter.
8714 (update_breakpoint_locations): Change sals parameters to use
8715 gdb::array_view.
8716 * cli/cli-cmds.c (edit_command, list_command): Update to use
8717 std::vector and gdb::array_view.
8718 (ambiguous_line_spec): Adjust to use gdb::array_view and
8719 range-for.
8720 (compare_symtabs): Rename to ...
8721 (cmp_symtabs): ... this. Change parameters to symtab_and_line
8722 const reference and adjust.
8723 (filter_sals): Rewrite using std::vector and standard algorithms.
8724 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
8725 (jump_command): Update to use std::vector.
8726 * linespec.c (struct linespec_state) <canonical_names>: Update
8727 comment.
8728 (add_sal_to_sals_basic): Delete.
8729 (add_sal_to_sals, filter_results, convert_results_to_lsals)
8730 (decode_line_2, create_sals_line_offset)
8731 (convert_address_location_to_sals, convert_linespec_to_sals)
8732 (convert_explicit_location_to_sals, parse_linespec)
8733 (event_location_to_sals, decode_line_full, decode_line_1)
8734 (decode_line_with_current_source)
8735 (decode_line_with_last_displayed, decode_objc)
8736 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
8737 (linespec_result::~linespec_result): Adjust to use std::vector
8738 instead of symtabs_and_lines.
8739 * linespec.h (linespec_sals::sals): Now a std::vector.
8740 (struct linespec_result): Use std::vector, bool, and in-class
8741 initialization.
8742 (decode_line_1, decode_line_with_current_source)
8743 (decode_line_with_last_displayed): Return std::vector.
8744 * macrocmd.c (info_macros_command): Use std::vector.
8745 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
8746 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
8747 std::vector.
8748 * probe.h (parse_probes): Return a std::vector.
8749 * python/python.c (gdbpy_decode_line): Use std::vector and
8750 gdb::array_view.
8751 * source.c (select_source_symtab, line_info): Use std::vector.
8752 * stack.c (func_command): Use std::vector.
8753 * symtab.h (struct symtabs_and_lines): Delete.
8754 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
8755
7c44b49c
PA
87562017-09-04 Pedro Alves <palves@redhat.com>
8757
8758 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8759 unittests/array-view-selftests.c.
8760 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
8761 * common/array-view.h: New file.
8762 * unittests/array-view-selftests.c: New file.
8763
e439fa14
PA
87642017-09-04 Pedro Alves <palves@redhat.com>
8765
8766 * cli/cli-cmds.c (edit_command): Pass message to
8767 ambiguous_line_spec.
8768 (list_command): Pass message to ambiguous_line_spec. Say
8769 "first"/"last" instead of "start" and "end" to be consistent with
8770 the manual.
8771 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
8772 them to print formatted message.
8773
7525b645
PA
87742017-09-04 Pedro Alves <palves@redhat.com>
8775
8776 * btrace.c (ftrace_add_pt): Pass btrace_insn to
8777 ftrace_update_insns by reference instead of pointer.
8778
badc0020
YQ
87792017-09-04 Yao Qi <yao.qi@linaro.org>
8780
8781 * i386-go32-tdep.c: Include x86-xstate.h.
8782 (i386_go32_init_abi): Call i386_target_description.
8783 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
8784 if xcr0 is X86_XSTATE_X87_MASK.
8785 * i386-tdep.h (tdesc_i386): Remove the declaration.
8786 (tdesc_i386_mmx): Likewise.
8787
d78bdb54
YQ
87882017-09-04 Yao Qi <yao.qi@linaro.org>
8789
8790 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
8791 X86_XSTATE_SSE_MASK instead of 0.
8792
ca1fa5ee
YQ
87932017-09-04 Yao Qi <yao.qi@linaro.org>
8794
8795 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
8796 i386_target_description.
8797 * i386-fbsd-nat.c (i386fbsd_read_description): Call
8798 i386_target_description.
8799 * i386-tdep.c (i386_gdbarch_init): Likewise.
8800
2434b019
YQ
88012017-09-04 Yao Qi <yao.qi@linaro.org>
8802
8803 * amd64-darwin-tdep.c: Include "x86-xstate.h".
8804 (x86_darwin_init_abi_64): Call amd64_target_description.
8805 * amd64-dicos-tdep.c: Likewise.
8806 * amd64-fbsd-nat.c: Likewise.
8807 * amd64-fbsd-tdep.c: Likewise.
8808 * amd64-nbsd-tdep.c: Likewise.
8809 * amd64-obsd-tdep.c: Likewise.
8810 * amd64-sol2-tdep.c: Likewise.
8811 * amd64-windows-tdep.c: Likewise.
8812 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
8813
0860c437
SM
88142017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8815
8816 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
8817 (btrace_function) <insn>: Change type to use std::vector.
8818 * btrace.c (ftrace_debug, ftrace_call_num_insn,
8819 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
8820 ftrace_update_insns, ftrace_compute_global_level_offset,
8821 btrace_stitch_bts, btrace_clear, btrace_insn_get,
8822 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
8823 change to std::vector.
8824 (ftrace_update_insns): Adjust to change to std::vector, change
8825 type of INSN parameter.
8826 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
8827 * record-btrace.c (btrace_call_history_insn_range,
8828 btrace_compute_src_line_range,
8829 record_btrace_frame_prev_register): Adjust to change to
8830 std::vector.
8831 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
8832 to change to std::vector.
8833
0638b7f9
TT
88342017-09-03 Tom Tromey <tom@tromey.com>
8835
8836 * corefile.c (reopen_exec_file): Use std::string.
8837
8f84fb0e
TT
88382017-09-03 Tom Tromey <tom@tromey.com>
8839
8840 * compile/compile.c (compile_register_name_mangled): Return
8841 std::string.
8842 * compile/compile-loc2c.c (pushf_register_address): Update.
8843 (pushf_register): Update.
8844 * compile/compile-c-types.c (convert_array): Update.
8845 * compile/compile-c-symbols.c (generate_vla_size): Update.
8846 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
8847 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
8848 (convert_one_symbol): Update.
8849 (generate_c_for_for_one_variable): Update.
8850 * compile/compile-c-support.c (c_get_range_decl_name): Return a
8851 std::string.
8852 (generate_register_struct): Update.
8853 * compile/compile-internal.h (c_get_range_decl_name): Return a
8854 std::string.
8855 (compile_register_name_mangled): Return std::string.
8856
18e9961f
TT
88572017-09-03 Tom Tromey <tom@tromey.com>
8858
8859 * utils.c (perror_string): Return a std::string.
8860 (throw_perror_with_name, perror_warning_with_name): Update.
8861
45343786
TT
88622017-09-03 Tom Tromey <tom@tromey.com>
8863
8864 * demangle.c (demangle_command): Use std::string,
8865 unique_xmalloc_ptr.
8866
b57af503
TT
88672017-09-03 Tom Tromey <tom@tromey.com>
8868
8869 * cli/cli-setshow.c (do_set_command): Use std::string.
8870
6eecf35f
TT
88712017-09-03 Tom Tromey <tom@tromey.com>
8872
8873 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
8874
56496dd4
TT
88752017-09-03 Tom Tromey <tom@tromey.com>
8876
8877 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
8878
e91a1fa7
TT
88792017-09-03 Tom Tromey <tom@tromey.com>
8880
8881 * mi/mi-cmd-env.c (env_execute_cli_command): Use
8882 gdb::unique_xmalloc_ptr.
8883
7ffd83d7
TT
88842017-09-03 Tom Tromey <tom@tromey.com>
8885
8886 * thread.c (print_thread_info_1): Use string_printf.
8887 (thread_apply_command, thread_apply_all_command): Use
8888 std::string.
8889
1ccbe998
TT
88902017-09-03 Tom Tromey <tom@tromey.com>
8891
8892 * valprint.c (val_print_string): Update.
8893 * gdbcore.h (memory_error_message): Return std::string.
8894 * corefile.c (memory_error_message): Return std::string.
8895 (memory_error): Update.
8896 * breakpoint.c (insert_bp_location): Update.
8897
23fdd69e
SM
88982017-09-03 Simon Marchi <simon.marchi@ericsson.com>
8899
8900 * target/waitstatus.h (target_waitstatus_to_string): Change
8901 return type to std::string.
8902 * target/waitstatus.c (target_waitstatus_to_string): Return
8903 std::string.
8904 * target.h (target_waitstatus_to_string): Remove declaration.
8905 * infrun.c (resume, clear_proceed_status_thread,
8906 print_target_wait_results, do_target_wait, save_waitstatus,
8907 stop_all_threads): Adjust.
8908 * record-btrace.c (record_btrace_wait): Adjust.
8909 * target-debug.h
8910 (target_debug_print_struct_target_waitstatus_p): Adjust.
8911
5c811d30
JK
89122017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8913
8914 PR gdb/22046
8915 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
8916 detection.
8917
0a2dde4a
SDJ
89182017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
8919
8920 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
8921 for setting/unsetting environment variables on the remote target.
8922 (New remote packets): Add entries for QEnvironmentHexEncoded,
8923 QEnvironmentUnset and QEnvironmentReset.
8924 * common/environ.c (gdb_environ::operator=): Extend method to
8925 handle m_user_set_env_list and m_user_unset_env_list.
8926 (gdb_environ::clear): Likewise.
8927 (match_var_in_string): Change type of first parameter from 'char
8928 *' to 'const char *'.
8929 (gdb_environ::set): Extend method to handle
8930 m_user_set_env_list and m_user_unset_env_list.
8931 (gdb_environ::unset): Likewise.
8932 (gdb_environ::clear_user_set_env): New method.
8933 (gdb_environ::user_set_envp): Likewise.
8934 (gdb_environ::user_unset_envp): Likewise.
8935 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
8936 m_user_unset_env_list on move constructor/assignment.
8937 (unset): Add new default parameter 'update_unset_list = true'.
8938 (clear_user_set_env): New method.
8939 (user_set_envp): Likewise.
8940 (user_unset_envp): Likewise.
8941 (m_user_set_env_list): New std::set.
8942 (m_user_unset_env_list): Likewise.
8943 * common/rsp-low.c (hex2str): New function.
8944 (bin2hex): New overload for bin2hex function.
8945 * common/rsp-low.c (hex2str): New prototype.
8946 (str2hex): New overload prototype.
8947 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
8948 QEnvironmentUnset and QEnvironmentReset.
8949 (remote_protocol_features): Add QEnvironmentHexEncoded,
8950 QEnvironmentUnset and QEnvironmentReset packets.
8951 (send_environment_packet): New function.
8952 (extended_remote_environment_support): Likewise.
8953 (extended_remote_create_inferior): Call
8954 extended_remote_environment_support.
8955 (_initialize_remote): Add QEnvironmentHexEncoded,
8956 QEnvironmentUnset and QEnvironmentReset packet configs.
8957 * unittests/environ-selftests.c (gdb_selftest_env_var):
8958 New variable.
8959 (test_vector_initialization): New function.
8960 (test_init_from_host_environ): Likewise.
8961 (test_reinit_from_host_environ): Likewise.
8962 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
8963 Likewise.
8964 (test_unset_set_empty_vector): Likewise.
8965 (test_vector_clear): Likewise.
8966 (test_std_move): Likewise.
8967 (test_move_constructor):
8968 (test_self_move): Likewise.
8969 (test_set_unset_reset): Likewise.
8970 (run_tests): Rewrite in terms of the functions above.
8971
654670a4
WP
89722017-08-31 Weimin Pan <weimin.pan@oracle.com>
8973
8974 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
8975 (adi_available): Use a temp variable of type CORE_ADDR as argument
8976 3 when calling target_auxv_search.
8977 (adi_normalize_address): Use masks and xor operators to calculate
8978 normalized address.
8979 (adi_read_versions, adi_write_versions, adi_print_versions)
8980 (do_examine, do_assign): Use paddress.
8981
7755ddb7
JB
89822017-08-29 John Baldwin <jhb@FreeBSD.org>
8983
8984 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
8985 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
8986 out of loop and add supply of FIR.
8987 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
8988 add collect of FIR.
8989
fd437cbc
SM
89902017-08-28 Simon Marchi <simon.marchi@ericsson.com>
8991
3804a343 8992 PR gdb/21827
fd437cbc
SM
8993 * cli/cli-script.c (define_command): Don't convert command name
8994 to lower case.
8995
988f6b3d
JB
89962017-08-25 Joel Brobecker <brobecker@adacore.com>
8997
8998 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
8999 Update all callers accordingly. Remove all code blocks handling
9000 the case where DISPP is not NULL.
9001
663c44ac
JK
90022017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9003
9004 PR symtab/22003
9005 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
9006 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9007 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
9008
f1902523
JK
90092017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
9010
9011 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
9012 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
9013 (read_comp_units_from_section): New parameter abbrev_section, use
9014 read_and_check_comp_unit_head, allocate signatured_type if needed.
9015 (create_all_comp_units): Update read_comp_units_from_section caller.
9016
87215ad1
SDJ
90172017-08-23 Pedro Alves <palves@redhat.com>
9018
9019 PR remote/21852
9020 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
9021 to null_ptid and switch to thread without reading the registers
9022 after adding the inferior.
9023
6e41ddec
JK
90242017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9025
9026 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
9027 compile-gcc.
9028 * compile/compile.c (compile_gcc, show_compile_gcc): New.
9029 (compile_to_object): Implement compile_gcc.
9030 (_initialize_compile): Install "set compile-gcc". Initialize
9031 compile_gcc.
9032
e68c32d5
JK
90332017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
9034
9035 * compile/compile.c (compile_to_object): Conditionally call
9036 set_verbose. Conditionally call compile or compile_v0.
9037
58afddc6
WP
90382017-08-07 Weimin Pan <weimin.pan@oracle.com>
9039
9040 * sparc64-tdep.h: (adi_normalize_address): New export.
9041 * sparc-nat.h: (open_adi_tag_fd): New export.
9042 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
9043 * sparc64-linux-tdep.c:
9044 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
9045 (sparc64_linux_handle_segmentation_fault): New function.
9046 (sparc64_linux_init_abi): Register
9047 sparc64_linux_handle_segmentation_fault
9048 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
9049 (sparc64_addr_bits_remove): New function.
9050 (sparc64_init_abi): Register sparc64_addr_bits_remove.
9051 (MAX_PROC_NAME_SIZE): New macro.
9052 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
9053 (sparc64adilist): New variable.
9054 (adi_proc_list): New variable.
9055 (find_adi_info): New function.
9056 (add_adi_info): New function.
9057 (get_adi_info_proc): New function.
9058 (get_adi_info): New function.
9059 (info_adi_command): New function.
9060 (read_maps_entry): New function.
9061 (adi_available): New function.
9062 (adi_normalize_address): New function.
9063 (adi_align_address): New function.
9064 (adi_convert_byte_count): New function.
9065 (adi_tag_fd): New function.
9066 (adi_is_addr_mapped): New function.
9067 (adi_read_versions): New function.
9068 (adi_write_versions): New function.
9069 (adi_print_versions): New function.
9070 (do_examine): New function.
9071 (do_assign): New function.
9072 (adi_examine_command): New function.
9073 (adi_assign_command): New function.
9074 (_initialize_sparc64_adi_tdep): New function.
9075
11db9430
SM
90762017-08-22 Simon Marchi <simon.marchi@ericsson.com>
9077
9078 * breakpoint.c (breakpoints_info): Rename to ...
9079 (info_breakpoints_command): ... this.
9080 (watchpoints_info): Rename to ...
9081 (info_watchpoints_command): ... this.
9082 (tracepoints_info): Rename to ...
9083 (info_tracepoints_command): ... this.
9084 (_initialize_breakpoint): Adjust.
9085 * dcache.c (dcache_info): Rename to ...
9086 (info_display_command): ... this.
9087 (_initialize_dcache): Adjust.
9088 * frame.h (args_info): Rename to ...
9089 (info_args_command): ... this.
9090 (locals_info): Rename to ...
9091 (info_locals_command): ... this.
9092 * infcmd.c (nofp_registers_info): Rename to ...
9093 (info_registers_command): ... this.
9094 (float_info): Rename to ...
9095 (info_float_command): ... this.
9096 (program_info): Rename to ...
9097 (info_program_command): ... this.
9098 (all_registers_info): Rename to ...
9099 (info_all_registers_command): ... this.
9100 (vector_info): Rename to ...
9101 (info_vector_command): ... this.
9102 (float_info): Rename to ...
9103 (info_float_command): ... this.
9104 (_initialize_infcmd): Adjust.
9105 * inferior.h (term_info): Rename to ...
9106 (info_terminal_command): ... this.
9107 * inflow.c (term_info): Rename to ...
9108 (info_terminal_command): ... this.
9109 (_initialize_inflow): Adjust.
9110 * infrun.c (signals_info): Rename to ...
9111 (info_signals_command): ... this.
9112 (_initialize_infrun): Adjust.
9113 * objc-lang.c (classes_info): Rename to ...
9114 (info_classes_command): ... this.
9115 (selectors_info): Rename to ...
9116 (info_selectors_command): ... this.
9117 (_initialize_objc_language): Adjust.
9118 * printcmd.c (sym_info): Rename to ...
9119 (info_symbol_command): ... this.
9120 (address_info): Rename to ...
9121 (info_address_command): ... this.
9122 (display_info): Rename to ...
9123 (info_display_command): ... this.
9124 (_initialize_printcmd): Adjust.
9125 * reverse.c (bookmarks_info): Rename to ...
9126 (info_breakpoints_command): ... this.
9127 (_initialize_reverse): Adjust.
9128 * ser-go32.c (dos_info): Rename to ...
9129 (info_serial_command): ... this.
9130 (_initialize_ser_dos): Adjust.
9131 * skip.c (skip_info): Rename to ...
9132 (info_skip_command): ... this.
9133 (_initialize_step_skip): Adjust.
9134 * source.c (line_info): Rename to ...
9135 (info_line_command): ... this.
9136 (source_info): Rename to ...
9137 (info_source_command)
9138 * stack.c (frame_info): Rename to ...
9139 (info_frame_command): ... this.
9140 (locals_info): Rename to ...
9141 (info_locals_command): ... this.
9142 (args_info): Rename to ...
9143 (info_args_command): ... this.
9144 (_initialize_stack): Adjust.
9145 * symtab.c (sources_info): Rename to ...
9146 (info_sources_command): ... this.
9147 (variables_info): Rename to ...
9148 (info_variables_command): ... this.
9149 (functions_info): Rename to ...
9150 (info_functions_command): ... this.
9151 (types_info): Rename to ...
9152 (info_types_command): ... this.
9153 (_initialize_symtab): Adjust.
9154 * target.c (target_info): Rename to ...
9155 (info_target_command): ... this.
9156 (initialize_targets): Adjust.
9157 * tracepoint.c (tvariables_info): Rename to ...
9158 (info_tvariables_command): ... this.
9159 (scope_info): Rename to ...
9160 (info_scope_command): ... this.
9161 (trace_dump_actions): Adjust.
9162 (_initialize_tracepoint): Adjust.
9163
b270e6f9
TT
91642017-08-22 Tom Tromey <tom@tromey.com>
9165
9166 * breakpoint.h (install_breakpoint): Update.
9167 * breakpoint.c (add_solib_catchpoint): Update.
9168 (install_breakpoint): Change argument to a std::unique_ptr.
9169 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
9170 (create_breakpoint_sal, create_breakpoint): Update.
9171 (watch_command_1, catch_exec_command_1)
9172 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
9173 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
9174 Return the breakpoint.
9175 (set_raw_breakpoint_without_location, set_raw_breakpoint)
9176 (new_single_step_breakpoint): Update.
9177 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
9178 std::unique_ptr.
9179 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9180 std::unique_ptr.
9181 * break-catch-sig.c (create_signal_catchpoint): Use
9182 std::unique_ptr.
9183 * ada-lang.c (create_ada_exception_catchpoint): Use
9184 std::unique_ptr.
9185
36bd8eaa
TT
91862017-08-22 Tom Tromey <tom@tromey.com>
9187
9188 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
9189
56f37645
TT
91902017-08-22 Tom Tromey <tom@tromey.com>
9191
9192 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9193 (lookup_partial_symbol): Update.
9194
0b581c69
TT
91952017-08-22 Tom Tromey <tom@tromey.com>
9196
9197 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9198 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9199 (find_and_open_source, symtab_to_fullname): Update.
9200 * psymtab.c (psymtab_to_fullname): Update.
9201
14278e1f
TT
92022017-08-22 Tom Tromey <tom@tromey.com>
9203
9204 * exec.c (exec_file_attach): Update.
9205 * linux-thread-db.c (try_thread_db_load): Update.
9206 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9207 * utils.c (gdb_realpath): Change return type.
9208 (gdb_realpath_keepfile): Update.
9209 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9210 (_initialize_utils): Register the new self test.
9211 * source.c (openp): Update.
9212 (find_and_open_source): Update.
9213 * nto-tdep.c (nto_find_and_open_solib): Update.
9214 * main.c (set_gdb_data_directory): Update.
9215 (captured_main_1): Update.
9216 * dwarf2read.c (dwarf2_get_dwz_file): Update
9217 (dw2_map_symbol_filenames): Update.
9218 * auto-load.c (auto_load_safe_path_vec_update): Update.
9219 (filename_is_in_auto_load_safe_path_vec): Change type of
9220 "filename_realp".
9221 (auto_load_objfile_script): Update.
9222 (file_is_auto_load_safe): Update. Use std::string.
9223 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9224
4971c9a7
TT
92252017-08-22 Tom Tromey <tom@tromey.com>
9226
9227 * utils.c (gdb_realpath_keepfile): Return a
9228 gdb::unique_xmalloc_ptr.
9229 * exec.c (exec_file_attach): Update.
9230 * utils.h (gdb_realpath_keepfile): Return a
9231 gdb::unique_xmalloc_ptr.
9232
e3e41d58
TT
92332017-08-22 Tom Tromey <tom@tromey.com>
9234
9235 * compile/compile.c (compile_file_command): Use
9236 gdb::unique_xmalloc_ptr, std::string.
9237 * utils.c (gdb_abspath): Change return type.
9238 * source.c (openp): Update.
9239 * objfiles.c (allocate_objfile): Update.
9240 * main.c (set_gdb_data_directory): Update.
9241 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9242
0d999a6e
ZZ
92432017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9244
9245 * cli-cmds.c (list_commands): List actual code around more than
9246 one location.
9247
329d5e7e
JB
92482017-08-21 John Baldwin <jhb@FreeBSD.org>
9249
9250 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9251
bf223d3e
PA
92522017-08-21 Pedro Alves <palves@redhat.com>
9253
9254 PR gdb/19487
9255 * c-exp.y (variable production): Handle function aliases.
9256 * minsyms.c (msymbol_is_text): New function.
9257 * minsyms.h (msymbol_is_text): Declare.
9258 * symtab.c (find_function_alias_target): New function.
9259 * symtab.h (find_function_alias_target): Declare.
9260
c973d0aa
PA
92612017-08-21 Pedro Alves <palves@redhat.com>
9262
9263 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9264 typedefs.
9265 * typeprint.c (whatis_exp): If handling "whatis", and expression
9266 is OP_TYPE, strip one typedef level. Otherwise don't strip
9267 typedefs here.
9268 * valops.c (value_cast): Save "to" type before resolving
9269 stubs/typedefs. Use that type as resulting value's type.
9270
2989a365
TT
92712017-08-18 Tom Tromey <tom@tromey.com>
9272 Pedro Alves <palves@redhat.com>
9273
9274 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9275 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9276 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9277 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9278 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9279 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9280 (linux_get_siginfo_data): Add "thread" argument. Use
9281 scoped_restore.
9282 * linux-nat.c (linux_child_follow_fork)
9283 (check_stopped_by_watchpoint): Use scoped_restore.
9284 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9285 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9286 (restore_inferior_ptid, save_inferior_ptid): Remove.
9287 * btrace.c (btrace_fetch): Use scoped_restore.
9288 * bsd-uthread.c (bsd_uthread_fetch_registers)
9289 (bsd_uthread_store_registers): Use scoped_restore.
9290 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9291 scoped_restore.
9292 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9293 (aix_thread_xfer_partial): Use scoped_restore.
9294 * inferior.h (save_inferior_ptid): Remove.
9295
e60eb288
YQ
92962017-08-18 Yao Qi <yao.qi@linaro.org>
9297
9298 PR tdep/21818
9299 * arm-tdep.c (gdb_print_insn_arm): Mark
9300 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9301
6d580b63
YQ
93022017-08-18 Yao Qi <yao.qi@linaro.org>
9303
9304 * NEWS: Mention GDBserver's new option "--selftest".
9305 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9306 * selftest.c: Move it to common/selftest.c.
9307 * selftest.h: Move it to common/selftest.h.
9308 * selftest-arch.c (reset): New function.
9309 (tests_with_arch): Call reset.
9310
86dcbf50
YQ
93112017-08-18 Yao Qi <yao.qi@linaro.org>
9312
9313 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9314 instead of exception_fprintf and printf_filtered.
9315
7649770c
YQ
93162017-08-18 Yao Qi <yao.qi@linaro.org>
9317
9318 * selftest.c (register_self_test): Rename it to
9319 selftests::register_test.
9320 (run_self_tests): selftest::run_tests.
9321 * selftest.h: Update declarations.
9322 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9323 selftests::register_test_foreach_arch.
9324 * selftest-arch.h: Update declaration.
9325 * aarch64-tdep.c: Update.
9326 * arm-tdep.c: Likewise.
9327 * disasm-selftests.c: Likewise.
9328 * dwarf2loc.c: Likewise.
9329 * dwarf2-frame.c: Likewise.
9330 * findvar.c: Likewise.
9331 * gdbarch-selftests.c: Likewise.
9332 * maint.c (maintenance_selftest): Likewise.
9333 * regcache.c: Likewise.
9334 * rust-exp.y: Likewise.
9335 * selftest-arch.c: Likewise.
9336 * unittests/environ-selftests.c: Likewise.
9337 * unittests/function-view-selftests.c: Likewise.
9338 * unittests/offset-type-selftests.c: Likewise.
9339 * unittests/optional-selftests.c: Likewise.
9340 * unittests/scoped_restore-selftests.c: Likewise.
9341 * utils-selftests.c: Likewise.
9342
b0cba12e
PA
93432017-08-17 Pedro Alves <palves@redhat.com>
9344
9345 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9346 local.
9347
4c8aa72d
PA
93482017-08-17 Pedro Alves <palves@redhat.com>
9349
9350 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9351 field.
9352 (reset_die_in_process): Delete, replaced by ...
9353 (process_die_scope): ... this new class. Make it responsible for
9354 freeing cu->line_header too.
9355 (process_die): Use process_die_scope.
9356 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9357 cu->line_header_die_owner. Don't release the line header if it's
9358 owned by the CU.
9359 (setup_type_unit_groups): Make the CU/DIE own the line header.
9360 Don't release the line header here.
9361
ba713918
AL
93622017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9363
9364 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9365
44d0fb3a
RK
93662017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9367
9368 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9369 Single-Key mode
9370
a5afdb16
RK
93712017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9372
9373 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9374 mode command list.
9375
47613aeb
SH
93762017-08-15 Stafford Horne <shorne@gmail.com>
9377
9378 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9379
9c3cc999
SH
93802017-08-15 Stafford Horne <shorne@gmail.com>
9381
9382 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9383
206726fb
SDJ
93842017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9385
9386 PR gdb/21954
9387 * infcmd.c (unset_environment_command): Use the 'clear' method on
9388 the environment instead of resetting it.
9389
0335ac6d
JB
93902017-08-15 John Baldwin <jhb@FreeBSD.org>
9391
9392 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9393 platforms.
9394
d3abe1c8
TT
93952017-08-14 Tom Tromey <tom@tromey.com>
9396
9397 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9398 (print_binary_chars): Likewise.
9399 (BITS_IN_BYTES): Remove.
9400
d6382fff
TT
94012017-08-14 Tom Tromey <tom@tromey.com>
9402
9403 PR gdb/21675
9404 * valprint.c (LOW_ZERO): Change value to 034.
9405 (print_octal_chars): Add static_asserts for octal constants.
9406 * printcmd.c (print_scalar_formatted): Add 'd' case.
9407
f978cb06
TT
94082017-08-11 Tom Tromey <tom@tromey.com>
9409
9410 * symfile.c (add_symbol_file_command): Use std::vector.
9411
2f5404b3
TT
94122017-08-14 Tom Tromey <tom@tromey.com>
9413
9414 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9415 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9416 std::move.
9417 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9418
de7985c3
PA
94192017-08-11 Pedro Alves <palves@redhat.com>
9420
9421 * infrun.c (process_event_stop_test): Adjust
9422 function_name_is_marked_for_skip call.
9423 * skip.c: Include <list>.
9424 (skiplist_entry): Make it a class with private fields, and
9425 getters/setters.
9426 (skiplist_entry_chain): Delete.
9427 (skiplist_entries): New.
9428 (skiplist_entry_count): Delete.
9429 (highest_skiplist_entry_num): New.
9430 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9431 (add_skiplist_entry): Delete.
9432 (skiplist_entry::skiplist_entry): New.
9433 (skiplist_entry::add_entry): New.
9434 (skip_file_command, skip_function): Adjust.
9435 (compile_skip_regexp): Delete.
9436 (skip_command): Don't compile regexp here. Adjust to use
9437 skiplist_entry::add_entry.
9438 (skip_info): Adjust to use range-for and getters.
9439 (skip_enable_command, skip_disable_command): Adjust to use
9440 range-for and setters.
9441 (skip_delete_command): Adjust to use std::list.
9442 (add_skiplist_entry): Delete.
9443 (skip_file_p): Delete, refactored as ...
9444 (skiplist_entry::do_skip_file_p): ... this new method.
9445 (skip_gfile_p): Delete, refactored as ...
9446 (skiplist_entry::do_gskip_file_p): ... this new method.
9447 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9448 (skiplist_entry::skip_function_p): ... this new method.
9449 (function_name_is_marked_for_skip): Now returns bool, and takes
9450 the function sal by const reference. Adjust to use range-for and
9451 skiplist_entry methods.
9452 (_initialize_step_skip): Remove references to
9453 skiplist_entry_chain, skiplist_entry_count.
9454 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9455 takes the function sal by const reference.
9456
be7d3cd5
YQ
94572017-08-11 Yao Qi <yao.qi@linaro.org>
9458
9459 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9460 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9461 (dwarf2_frame_cache):
9462 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9463 RETURN_MASK_ALL and set *this_case to NULL.
9464 * frame-unwind.h: Update comments.
9465
1c90d9f0
YQ
94662017-08-11 Yao Qi <yao.qi@linaro.org>
9467
9468 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9469 (dwarf2_frame_state_copy_regs): Remove.
9470 (dwarf2_frame_state_free_regs): Remove.
9471 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9472 (dwarf2_restore_rule): Call method .alloc_regs instead of
9473 dwarf2_frame_state_alloc_regs.
9474 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9475 constructor. Call std::move.
9476 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9477 (dwarf2_frame_cache): Likewise.
9478
9479 [GDB_SELF_TEST]: Include selftest.h and
9480 selftest-arch.h.
9481 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9482 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9483 execute_cfa_program_test.
9484
9485 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9486 copy ctor, assignment operator, move assignment.
9487 <alloc_regs>: New method.
9488 <swap>: New method.
9489 (struct dwarf2_frame_state): Delete dtor.
9490 (dwarf2_frame_state_alloc_regs): Remove declaration.
9491 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9492 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9493
afe37d6b
YQ
94942017-08-11 Yao Qi <yao.qi@linaro.org>
9495
9496 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9497 (dwarf2_frame_state::dwarf2_frame_state): New.
9498 (dwarf2_frame_state::~dwarf2_frame_state): New.
9499 (dwarf2_fetch_cfa_info): Update.
9500 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9501 rather than a pointer. Update code.
9502 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9503 dtor.
9504 <data_align, code_align, retaddr_column>: Change them to const.
9505 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9506 to bool.
9507
b348037f
YQ
95082017-08-11 Yao Qi <yao.qi@linaro.org>
9509
9510 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9511 <loc.exp>: New field.
9512 * dwarf2-frame.c (execute_cfa_program): Update.
9513 (dwarf2_frame_prev_register): Update.
9514
e7c9de26
PA
95152017-08-10 Pedro Alves <palves@redhat.com>
9516
9517 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9518
e8c6b620
JB
95192017-08-09 John Baldwin <jhb@FreeBSD.org>
9520
9521 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9522 (fbsd_pending_children): Use std::list.
9523 (fbsd_remember_child): Likewise.
9524 (fbsd_is_child_pending): Likewise.
9525 (fbsd_pending_vfork_done): Use std::forward_list.
9526 (fbsd_add_vfork_done): Likewise.
9527 (fbsd_is_vfork_done_pending): Likewise.
9528 (fbsd_next_vfork_done): Likewise.
9529
e4a26669
JB
95302017-08-09 John Baldwin <jhb@FreeBSD.org>
9531
9532 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9533 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9534 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9535 for `mapfilename'.
9536 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 9537 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 9538
142311d3
JB
95392017-08-09 John Baldwin <jhb@FreeBSD.org>
9540
9541 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
9542 "filestuff.h".
9543 (fbsd_find_memory_regions): Fix `mapfile' initialization.
9544
42fa2e0e
TT
95452017-08-09 Tom Tromey <tom@tromey.com>
9546
9547 * skip.c (skiplist_entry): New constructor.
9548 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
9549 (skiplist_entry::file_is_glob): Now bool.
9550 (skiplist_entry::file, skiplist_entry::function): Now
9551 std::string.
9552 (make_skip_entry): Return a unique_ptr. Use new.
9553 (free_skiplist_entry, free_skiplist_entry_cleanup)
9554 (make_free_skiplist_entry_cleanup): Remove.
9555 (skip_command, skip_disable_command, add_skiplist_entry)
9556 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
9557 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
9558 (function_name_is_marked_for_skip): Update.
9559 (skip_delete_command): Update. Use delete.
9560
cd3af38d
JW
95612017-08-09 Jiong Wang <jiong.wang@arm.com>
9562
9563 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
9564 (aarch64_linux_core_read_description): New function.
9565 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
9566
29592bde
PA
95672017-08-09 Pedro Alves <palves@redhat.com>
9568
9569 * cp-name-parser.y (cp_comp_to_string): Return a
9570 gdb::unique_xmalloc_ptr<char>.
9571 * cp-support.c (replace_typedefs_qualified_name)
9572 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
9573 (cp_canonicalize_string_full): Use op= instead of explicit
9574 convertion.
9575 (cp_class_name_from_physname, method_name_from_physname)
9576 (cp_func_name, cp_remove_params): Adjust to use
9577 gdb::unique_xmalloc_ptr<char>.
9578 * cp-support.h (cp_comp_to_string): Return a
9579 gdb::unique_xmalloc_ptr<char>.
9580 * python/py-type.c (typy_lookup_type): Adjust to use
9581 gdb::unique_xmalloc_ptr<char>.
9582
b3340438
L
95832017-08-09 H.J. Lu <hongjiu.lu@intel.com>
9584
9585 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
9586
e88e8651
YQ
95872017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
9588 Yao Qi <yao.qi@linaro.org>
9589
9590 * cp-support.c (cp_canonicalize_string_full): Use
9591 gdb::unique_xmalloc_ptr<char>.
9592 (cp_canonicalize_string): Likewise.
9593
f5a29eb0
YQ
95942017-08-09 Yao Qi <yao.qi@linaro.org>
9595
9596 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
9597 * regformats/i386/amd64-avx-avx512.dat: Remove.
9598 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
9599 * regformats/i386/amd64-avx-mpx.dat:Remove.
9600 * regformats/i386/amd64-avx.dat: Remove.
9601 * regformats/i386/amd64-mpx.dat: Remove.
9602 * regformats/i386/i386-avx-avx512.dat: Remove.
9603 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
9604 * regformats/i386/i386-avx-mpx.dat: Remove.
9605 * regformats/i386/i386-mmx.dat: Remove.
9606 * regformats/i386/i386-mpx.dat: Remove.
9607
57757c2f
YQ
96082017-08-09 Yao Qi <yao.qi@linaro.org>
9609
9610 * amd64-tdep.h (tdesc_x32): Remove the declaration.
9611 * amd64-tdep.c: Don't include features/i386/x32*.c.
9612 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
9613 functions.
9614 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
9615 and i386/x32-avx-avx512.
9616 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
9617 and i386/x32.xml.
9618 * features/i386/x32-avx-avx512.c: Removed.
9619 * features/i386/x32-avx-avx512.xml: Removed.
9620 * features/i386/x32-avx.c: Removed.
9621 * features/i386/x32-avx.xml: Removed.
9622 * features/i386/x32.c: Removed.
9623 * features/i386/x32.xml: Removed.
9624 * regformats/i386/x32-avx-avx512.dat: Removed.
9625 * regformats/i386/x32-avx.dat: Removed.
9626 * regformats/i386/x32.dat: Removed.
9627
ba7b109b
MR
96282017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9629
9630 PR breakpoints/21886
9631 * mem-break.c (default_memory_insert_breakpoint): Use
9632 `->placed_address' rather than `->reqstd_address' for the
9633 breakpoint location.
9634
e347efc3
MR
96352017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9636
9637 * arch-utils.c (default_print_insn): Remove arch/mach/endian
9638 assertions.
9639
0dba2a6c
MR
96402017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9641
9642 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
9643 a union of `tdep_info', `tdesc_data' and `id'.
9644 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
9645 rather than `info.tdep_info'.
9646 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
9647 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9648 * i386-tdep.c (i386_gdbarch_init): Likewise.
9649 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
9650 * mips-tdep.c (mips_gdbarch_init): Likewise.
9651 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9652 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9653 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
9654 `info.tdep_info'.
9655 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
9656 `info.tdep_info'.
9657 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9658 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
9659 `info.tdep_info'.
9660 * spu-tdep.c (spu_gdbarch_init): Likewise.
9661 * gdbarch.h: Regenerate.
9662
16eb6b2d
LS
96632017-08-07 Leszek Swirski <leszeks@google.com>
9664
7b005726 9665 PR symtab/20899
16eb6b2d
LS
9666 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
9667
74cbb09e
SM
96682017-08-07 Simon Marchi <simon.marchi@ericsson.com>
9669
9670 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
9671 (gdbsim_open): Rename gdb_argv args object to argv.
9672
ee0c3293
TT
96732017-08-05 Tom Tromey <tom@tromey.com>
9674
9675 * compile/compile-object-load.c (compile_object_load): Use
9676 gdb::unique_xmalloc_ptr.
9677 * cli/cli-dump.c (scan_filename): Rename from
9678 scan_filename_with_cleanup. Change return type.
9679 (scan_expression): Rename from scan_expression_with_cleanup.
9680 Change return type.
9681 (dump_memory_to_file, dump_value_to_file, restore_command):
9682 Use gdb::unique_xmalloc_ptr. Update.
9683 * cli/cli-cmds.c (find_and_open_script): Use
9684 gdb::unique_xmalloc_ptr.
9685 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
9686 * symmisc.c (maintenance_print_symbols)
9687 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
9688 * symfile.c (symfile_bfd_open, generic_load)
9689 (add_symbol_file_command, remove_symbol_file_command): Use
9690 gdb::unique_xmalloc_ptr.
9691 * source.c (openp): Use gdb::unique_xmalloc_ptr.
9692 * psymtab.c (maintenance_print_psymbols): Use
9693 gdb::unique_xmalloc_ptr.
9694 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
9695 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
9696 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
9697 (reload_shared_libraries_1): Likewise.
9698
3232fabd
TT
96992017-08-05 Tom Tromey <tom@tromey.com>
9700
9701 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
9702 (rust_op_vector, rust_set_vector): New typedefs.
9703 (current_parser): New global.
9704 (work_obstack): Change to pointer type. Update all users.
9705 (rust_ast, pstate): Remove globals.
9706 (struct rust_parser): New.
9707 (%union) <params, field_inits>: Change type.
9708 (start, tuple_expr, unit_expr, struct_expr_list, literal)
9709 (field_expr, expr_list, maybe_expr_list, type_list): Update.
9710 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
9711 (convert_params_to_types, convert_params_to_expression): Change
9712 type of "params".
9713 (ast_string): Change type of "fields".
9714 (rust_parse): Make a rust_parser. Remove cleanups.
9715 (rust_lex_tests): Make and install an auto_obstack.
9716
f02fd774
YQ
97172017-08-04 Yao Qi <yao.qi@linaro.org>
9718
9719 * configure.srv (ipa_x32_linux_regobj): New.
9720 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
9721 instead of X86_TDESC_AVX512.
9722 (initialize_low_tracepoint): Call
9723 init_registers_x32_avx_avx512_linux.
9724
91975afd
YQ
97252017-08-04 Yao Qi <yao.qi@linaro.org>
9726
9727 * utils.h (gdb_argv): Add namespace std for nullptr_t.
9728
2331fa3a
RK
97292017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
9730
9731 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
9732
744e4fe1
TT
97332017-08-03 Tom Tromey <tom@tromey.com>
9734
9735 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
9736 Remove.
9737 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
9738
1c034b67
TT
97392017-08-03 Tom Tromey <tom@tromey.com>
9740
9741 * python/py-param.c (compute_enum_values): Use gdb_argv.
9742
773a1edc
TT
97432017-08-03 Tom Tromey <tom@tromey.com>
9744
9745 * utils.h (struct gdb_argv_deleter): New.
9746 (gdb_argv): New class.
9747 * utils.c (gdb_argv::reset): New method.
9748 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
9749 * tracefile.c (tsave_command): Use gdb_argv.
9750 * top.c (new_ui_command): Use gdb_argv.
9751 * symmisc.c (maintenance_print_symbols)
9752 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
9753 * symfile.c (symbol_file_command, generic_load)
9754 (remove_symbol_file_command): Use gdb_argv.
9755 * stack.c (backtrace_command): Use gdb_argv.
9756 * source.c (add_path, show_substitute_path_command)
9757 (unset_substitute_path_command, set_substitute_path_command):
9758 Use gdb_argv.
9759 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
9760 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
9761 * remote.c (extended_remote_run, remote_put_command)
9762 (remote_get_command, remote_delete_command): Use gdb_argv.
9763 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
9764 (gdbsim_open): Use gdb_argv.
9765 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
9766 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
9767 * procfs.c (procfs_info_proc): Use gdb_argv.
9768 * interps.c (interpreter_exec_cmd): Use gdb_argv.
9769 * infrun.c (handle_command): Use gdb_argv.
9770 * inferior.c (add_inferior_command, clone_inferior_command):
9771 Use gdb_argv.
9772 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
9773 * exec.c (exec_file_command): Use gdb_argv.
9774 * cli/cli-cmds.c (alias_command): Use gdb_argv.
9775 * compile/compile.c (build_argc_argv): Use gdb_argv.
9776
0d50bde3
TT
97772017-08-03 Tom Tromey <tom@tromey.com>
9778
9779 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
9780
7f968c89
TT
97812017-08-03 Tom Tromey <tom@tromey.com>
9782
9783 * python/python.c (compute_python_string): Return std::string.
9784 (gdbpy_eval_from_control_command): Update.
9785 (do_start_initialization): Use std::string.
9786 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
9787 xstrprintf.
9788 * python/py-breakpoint.c (local_setattro): Use string_printf, not
9789 xstrprintf.
9790
3c9ebddd
TT
97912017-08-03 Tom Tromey <tom@tromey.com>
9792
9793 * top.h (do_restore_instream_cleanup): Remove.
9794 * top.c (do_restore_instream_cleanup): Remove.
9795 (read_command_file): Use scoped_restore.
9796 * cli/cli-script.c (execute_user_command): Use scoped_restore.
9797
b51b225e
TT
97982017-08-03 Tom Tromey <tom@tromey.com>
9799
9800 * cli/cli-script.c (execute_user_command)
9801 (execute_control_command): Use scoped_restore.
9802
ac991630
TT
98032017-08-03 Tom Tromey <tom@tromey.com>
9804
9805 * cli/cli-script.c (do_restore_user_call_depth): Remove.
9806 (execute_user_command): Remove user_call_depth; use
9807 user_args_stack's size instead.
9808
898e0c8e
TT
98092017-08-03 Tom Tromey <tom@tromey.com>
9810
9811 * top.h (in_user_command): Remove.
9812 * top.c (in_user_command): Remove.
9813 * cli/cli-script.c (do_restore_user_call_depth)
9814 (execute_user_command): Update.
9815
26fcd5d7
TT
98162017-08-03 Tom Tromey <tom@tromey.com>
9817
9818 * valops.c (search_struct_method): Use gdb::byte_vector.
9819 * valarith.c (value_concat): Use std::vector.
9820 * target.c (memory_xfer_partial): Use gdb::byte_vector.
9821 (simple_search_memory): Likewise.
9822 * printcmd.c (find_string_backward): Use gdb::byte_vector.
9823 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
9824 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
9825 * elfread.c (elf_rel_plt_read): Use std::string.
9826 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
9827 * cli/cli-dump.c (restore_section_callback): Use
9828 gdb::byte_vector.
9829
7c218e6c
TT
98302017-08-03 Tom Tromey <tom@tromey.com>
9831
9832 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
9833
31b68d4a
TT
98342017-08-03 Tom Tromey <tom@tromey.com>
9835
9836 * tui/tui-regs.c (tui_restore_gdbout): Remove.
9837 (tui_register_format): Use scoped_restore.
9838
2ec845e7
TT
98392017-08-03 Tom Tromey <tom@tromey.com>
9840
9841 * reverse.c (exec_direction_default): Remove.
9842 (exec_reverse_once): Use scoped_restore.
9843 * remote.c (restore_remote_timeout): Remove.
9844 (remote_flash_erase, remote_flash_write, remote_flash_done)
9845 (readchar, remote_serial_write): Use scoped_restore.
9846 * cli/cli-script.c (struct source_cleanup_lines_args)
9847 (source_cleanup_lines): Remove.
9848 (script_from_file): Use scoped_restore.
9849 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
9850 (source_command): Use scoped_restore.
9851
b3bc8453
TT
98522017-08-03 Tom Tromey <tom@tromey.com>
9853
9854 * utils.h (make_cleanup_free_so): Remove.
9855 * utils.c (do_free_so, make_cleanup_free_so): Remove.
9856 * solist.h (struct so_deleter): New.
9857 (so_list_up): New typedef.
9858 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
9859
e3ad2841
TT
98602017-08-03 Tom Tromey <tom@tromey.com>
9861
9862 * utils.h (make_cleanup_restore_current_language): Remove.
9863 * utils.c (do_restore_current_language)
9864 (make_cleanup_restore_current_language): Remove.
9865 * parse.c (parse_exp_in_context_1)
9866 (parse_expression_with_language): Use
9867 scoped_restore_current_language.
9868 * mi/mi-main.c (mi_cmd_execute): Use
9869 scoped_restore_current_language.
9870 * language.h (scoped_restore_current_language): New class.
9871
b80cf838
TT
98722017-08-03 Tom Tromey <tom@tromey.com>
9873
9874 * compile/compile.c (cleanup_unlink_file): Remove.
9875 (compile_to_object): Use gdb::unlinker.
9876 (eval_compile_command): Likewise.
9877
fad0444a
TT
98782017-08-03 Tom Tromey <tom@tromey.com>
9879
9880 * utils.h (make_cleanup_fclose): Remove.
9881 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
9882
6e7bc05c
TT
98832017-08-03 Tom Tromey <tom@tromey.com>
9884
9885 * top.c (open_terminal_stream): Return gdb_file_up.
9886 (new_ui_command): Update.
9887
4a45905b
TT
98882017-08-03 Tom Tromey <tom@tromey.com>
9889
9890 * source.c (print_source_lines_base, forward_search_command)
9891 (reverse_search_command): Use gdb_file_up.
9892
7cd06d6e
TT
98932017-08-03 Tom Tromey <tom@tromey.com>
9894
9895 * fbsd-nat.c (fbsd_find_memory_regions): Update.
9896
ed166945
TT
98972017-08-03 Tom Tromey <tom@tromey.com>
9898
9899 * cli/cli-cmds.c (find_and_open_script): Change return type.
9900 Remove "streamp" and "full_path" parameters.
9901 (source_script_with_search): Update.
9902 * auto-load.c (source_script_file): Update.
9903 * cli/cli-cmds.h (find_and_open_script): Change type.
9904 (open_script): New struct.
9905
d419f42d
TT
99062017-08-03 Tom Tromey <tom@tromey.com>
9907
9908 * xml-support.c (xml_fetch_content_from_file): Update.
9909 * ui-file.c (stdio_file::open): Update.
9910 * tracefile-tfile.c (tfile_start): Update.
9911 * remote.c (remote_file_put, remote_file_get): Update.
9912 * nat/linux-procfs.c (linux_proc_get_int)
9913 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
9914 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
9915 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
9916 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
9917 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
9918 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
9919 * linux-nat.c (linux_proc_pending_signals): Update.
9920 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
9921 (file_closer): Remove.
9922 * compile/compile.c (compile_to_object): Update.
9923 * common/filestuff.h (struct gdb_file_deleter): New.
9924 (gdb_file_up): New typedef.
9925 (gdb_fopen_cloexec): Change return type.
9926 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
9927 * cli/cli-dump.c (fopen_with_cleanup): Remove.
9928 (dump_binary_file, restore_binary_file): Update.
9929 * auto-load.c (auto_load_objfile_script_1): Update.
9930
4a2b031d
TT
99312017-08-03 Tom Tromey <tom@tromey.com>
9932
9933 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
9934 (info_static_tracepoint_markers_command): Likewise.
9935 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
9936 * skip.c (skip_info): Use ui_out_emit_table.
9937 * progspace.c (print_program_space): Use ui_out_emit_table.
9938 * osdata.c (info_osdata): Use ui_out_emit_table.
9939 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
9940 ui_out_emit_table.
9941 * linux-thread-db.c (info_auto_load_libthread_db): Use
9942 ui_out_emit_table.
9943 * inferior.c (print_inferior): Use ui_out_emit_table.
9944 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
9945 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
9946 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
9947 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
9948 * ui-out.h (class ui_out_emit_table): New.
9949
a4f320fd
MR
99502017-08-02 Maciej W. Rozycki <macro@imgtec.com>
9951
9952 * mips-tdep.c (mips_fpu_type_str): New function.
9953 (mips_dump_tdep): Call it.
9954
a2f1f308
MR
99552017-08-01 Maciej W. Rozycki <macro@imgtec.com>
9956
9957 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
9958 `->mips_fpu_type'.
9959
7e5ed83b
XR
99602017-07-31 Xavier Roirand <roirand@adacore.com>
9961
9962 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
9963
4c9dc811
XR
99642017-07-27 Xavier Roirand <roirand@adacore.com>
9965
9966 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
9967
27d41eac
YQ
99682017-07-26 Yao Qi <yao.qi@linaro.org>
9969
9970 * cli/cli-cmds.c (maintenancechecklist): New variable.
9971 * gdbcmd.h (maintenancechecklist): Declare it.
9972 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
9973 Call i386_linux_read_description with different masks.
9974 * maint.c (maintenance_check_command): New function.
9975 (_initialize_maint_cmds): Call add_prefix_cmd.
9976 * target-descriptions.c (tdesc_reg): override operator != and ==.
9977 (tdesc_type): Likewise.
9978 (tdesc_feature): Likewise.
9979 (target_desc): Likewise.
9980 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
9981 (maintenance_check_xml_descriptions): New function.
9982 (_initialize_target_descriptions) Add command "xml-descriptions".
9983 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
9984
ea03d0d3
YQ
99852017-07-26 Yao Qi <yao.qi@linaro.org>
9986
9987 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
9988 Include features/i386/32bit-*.c.
9989 (i386_linux_read_description): Generate target description if it
9990 doesn't exist.
9991 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
9992 functions.
9993 * features/i386/32bit-linux.c: Re-generated.
9994 * features/i386/32bit-sse.c: Likewise.
9995 * target-descriptions.c (print_c_feature::visit): Print code to
9996 set register number if needed.
9997 (print_c_feature) <m_next_regnum>: New field.
9998
25aa13e5
YQ
99992017-07-26 Yao Qi <yao.qi@linaro.org>
10000
10001 * features/Makefile (CFILES): Rename with TDESC_CFILES.
10002 (FEATURE_XMLFILES): New.
10003 (FEATURE_CFILES): New.
10004 New rules.
10005 (clean-cfiles): Remove generated c files.
10006 * features/i386/32bit-avx.c: Generated.
10007 * features/i386/32bit-avx512.c: Generated.
10008 * features/i386/32bit-core.c: Generated.
10009 * features/i386/32bit-linux.c: Generated.
10010 * features/i386/32bit-mpx.c: Generated.
10011 * features/i386/32bit-pkeys.c: Generated.
10012 * features/i386/32bit-sse.c: Generated.
10013 * target-descriptions.c: Include algorithm.
10014 (tdesc_element_visitor): Add method visit_end.
10015 (print_c_tdesc): Implement visit_end.
10016 (print_c_tdesc:: m_filename_after_features): Move it to
10017 protected.
10018 (print_c_feature): New class.
10019 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
10020 name starts with "i386/32bit-".
10021
6eb1e6a8
YQ
100222017-07-26 Yao Qi <yao.qi@linaro.org>
10023
10024 * target-descriptions.c (tdesc_element_visitor): New class.
10025 (tdesc_element): New class.
10026 (tdesc_reg): Inherit from tdesc_element.
10027 (tdesc_reg::accept): New function.
10028 (tdesc_type): Inherit from tdesc_element.
10029 (tdesc_type::accept): New function.
10030 (tdesc_feature): Inherit from tdesc_element.
10031 (tdesc_feature::accept): New function.
10032 (target_desc): Inherit from tdesc_element.
10033 (target_desc::target_desc): New.
10034 (target_desc::~target_desc): New.
10035 (target_desc::accept): New.
10036 (allocate_target_description): Use new.
10037 (free_target_description): Use delete.
10038 (print_c_tdesc): New class.
10039 (maint_print_c_tdesc_cmd): Adjust.
10040
10041 * features/aarch64.c: Re-generated.
10042 * features/arc-arcompact.c: Re-generated.
10043 * features/arc-v2.c: Re-generated.
10044 * features/arm/arm-with-iwmmxt.c: Re-generated.
10045 * features/arm/arm-with-m.c: Re-generated.
10046 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
10047 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
10048 * features/arm/arm-with-neon.c: Re-generated.
10049 * features/arm/arm-with-vfpv2.c: Re-generated.
10050 * features/arm/arm-with-vfpv3.c: Re-generated.
10051 * features/i386/amd64-avx-avx512.c: Re-generated.
10052 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10053 * features/i386/amd64-avx.c: Re-generated.
10054 * features/i386/amd64-avx-linux.c: Re-generated.
10055 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
10056 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10057 * features/i386/amd64-avx-mpx.c: Re-generated.
10058 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
10059 * features/i386/amd64.c: Re-generated.
10060 * features/i386/amd64-linux.c: Re-generated.
10061 * features/i386/amd64-mpx.c: Re-generated.
10062 * features/i386/amd64-mpx-linux.c: Re-generated.
10063 * features/i386/i386-avx-avx512.c: Re-generated.
10064 * features/i386/i386-avx-avx512-linux.c: Re-generated.
10065 * features/i386/i386-avx.c: Re-generated.
10066 * features/i386/i386-avx-linux.c: Re-generated.
10067 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
10068 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
10069 * features/i386/i386-avx-mpx.c: Re-generated.
10070 * features/i386/i386-avx-mpx-linux.c: Re-generated.
10071 * features/i386/i386.c: Re-generated.
10072 * features/i386/i386-linux.c: Re-generated.
10073 * features/i386/i386-mmx.c: Re-generated.
10074 * features/i386/i386-mmx-linux.c: Re-generated.
10075 * features/i386/i386-mpx.c: Re-generated.
10076 * features/i386/i386-mpx-linux.c: Re-generated.
10077 * features/i386/x32-avx-avx512.c: Re-generated.
10078 * features/i386/x32-avx-avx512-linux.c: Re-generated.
10079 * features/i386/x32-avx.c: Re-generated.
10080 * features/i386/x32-avx-linux.c: Re-generated.
10081 * features/i386/x32.c: Re-generated.
10082 * features/i386/x32-linux.c: Re-generated.
10083 * features/microblaze.c: Re-generated.
10084 * features/microblaze-with-stack-protect.c: Re-generated.
10085 * features/mips64-dsp-linux.c: Re-generated.
10086 * features/mips64-linux.c: Re-generated.
10087 * features/mips-dsp-linux.c: Re-generated.
10088 * features/mips-linux.c: Re-generated.
10089 * features/nds32.c: Re-generated.
10090 * features/nios2.c: Re-generated.
10091 * features/nios2-linux.c: Re-generated.
10092 * features/rs6000/powerpc-32.c: Re-generated.
10093 * features/rs6000/powerpc-32l.c: Re-generated.
10094 * features/rs6000/powerpc-403.c: Re-generated.
10095 * features/rs6000/powerpc-403gc.c : Re-generated.
10096 * features/rs6000/powerpc-405.c: Re-generated.
10097 * features/rs6000/powerpc-505.c: Re-generated.
10098 * features/rs6000/powerpc-601.c: Re-generated.
10099 * features/rs6000/powerpc-602.c: Re-generated.
10100 * features/rs6000/powerpc-603.c: Re-generated.
10101 * features/rs6000/powerpc-604.c: Re-generated.
10102 * features/rs6000/powerpc-64.c: Re-generated.
10103 * features/rs6000/powerpc-64l.c: Re-generated.
10104 * features/rs6000/powerpc-7400.c: Re-generated.
10105 * features/rs6000/powerpc-750.c: Re-generated.
10106 * features/rs6000/powerpc-860.c: Re-generated.
10107 * features/rs6000/powerpc-altivec32.c: Re-generated.
10108 * features/rs6000/powerpc-altivec32l.c: Re-generated.
10109 * features/rs6000/powerpc-altivec64.c: Re-generated.
10110 * features/rs6000/powerpc-altivec64l.c: Re-generated.
10111 * features/rs6000/powerpc-cell32l.c: Re-generated.
10112 * features/rs6000/powerpc-cell64l.c: Re-generated.
10113 * features/rs6000/powerpc-e500.c: Re-generated.
10114 * features/rs6000/powerpc-e500l.c: Re-generated.
10115 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
10116 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
10117 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
10118 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
10119 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
10120 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
10121 * features/rs6000/powerpc-vsx32.c: Re-generated.
10122 * features/rs6000/powerpc-vsx32l.c: Re-generated.
10123 * features/rs6000/powerpc-vsx64.c: Re-generated.
10124 * features/rs6000/powerpc-vsx64l.c: Re-generated.
10125 * features/rs6000/rs6000.c: Re-generated.
10126 * features/s390-linux32.c: Re-generated.
10127 * features/s390-linux32v1.c: Re-generated.
10128 * features/s390-linux32v2.c: Re-generated.
10129 * features/s390-linux64.c: Re-generated.
10130 * features/s390-linux64v1.c: Re-generated.
10131 * features/s390-linux64v2.c: Re-generated.
10132 * features/s390-te-linux64.c: Re-generated.
10133 * features/s390-tevx-linux64.c: Re-generated.
10134 * features/s390-vx-linux64.c: Re-generated.
10135 * features/s390x-linux64.c: Re-generated.
10136 * features/s390x-linux64v1.c: Re-generated.
10137 * features/s390x-linux64v2.c: Re-generated.
10138 * features/s390x-te-linux64.c: Re-generated.
10139 * features/s390x-tevx-linux64.c: Re-generated.
10140 * features/s390x-vx-linux64.c: Re-generated.
10141 * features/sparc/sparc32-solaris.c: Re-generated.
10142 * features/sparc/sparc64-solaris.c: Re-generated.
10143 * features/tic6x-c62x.c: Re-generated.
10144 * features/tic6x-c62x-linux.c: Re-generated.
10145 * features/tic6x-c64x.c: Re-generated.
10146 * features/tic6x-c64x-linux.c: Re-generated.
10147 * features/tic6x-c64xp.c: Re-generated.
10148 * features/tic6x-c64xp-linux.c: Re-generated.
10149
35b4818d
YQ
101502017-07-26 Yao Qi <yao.qi@linaro.org>
10151
10152 * i386-linux-tdep.c (i386_linux_read_description): New function.
10153 (i386_linux_core_read_description): Call
10154 i386_linux_read_description.
10155 * i386-linux-tdep.h (i386_linux_read_description): Declare.
10156 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
10157 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
10158 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
10159 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
10160 * x86-linux-nat.c (x86_linux_read_description): Call
10161 i386_linux_read_description.
10162
8e2141c6
YQ
101632017-07-26 Yao Qi <yao.qi@linaro.org>
10164
10165 * NEWS: Mention it.
10166 * features/Makefile (%.c: %.xml): Pass the xml file name to
10167 command "maint print c-tdesc".
10168 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
10169 name from 'arg'.
10170
b468ff4c
YQ
101712017-07-26 Yao Qi <yao.qi@linaro.org>
10172
10173 * target-descriptions.c (target_desc): Add ctor and dtor. Do
10174 in-class initialization.
10175 (tdesc_create_feature): Call new instead of XCNEW.
10176 (free_target_description): Ue delete.
10177
b9c0e1b4
JB
101782017-07-25 John Baldwin <jhb@FreeBSD.org>
10179
10180 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
10181
a04b5337
YQ
101822017-07-25 Yao Qi <yao.qi@linaro.org>
10183
10184 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
10185 constant.
10186 (amd64_x32_init_abi): Likewise.
10187 * amd64-tdep.h (amd64_init_abi): Update declaration.
10188 (amd64_x32_init_abi): Likewise.
10189
02ad7fc2
YQ
101902017-07-25 Yao Qi <yao.qi@linaro.org>
10191
10192 PR tdep/21717
10193 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10194 condition for FPSCR.
10195 (arm_linux_store_inferior_registers): Likewise.
10196
b6f48cb0
TT
101972017-07-22 Tom Tromey <tom@tromey.com>
10198
10199 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10200 <syscalls_counts>: Now a std::vector.
10201 (get_catch_syscall_inferior_data): Use "new".
10202 (catch_syscall_inferior_data_cleanup): Use "delete".
10203 (insert_catch_syscall, remove_catch_syscall)
10204 (clear_syscall_counts): Update.
10205
e12c9b7a
TT
102062017-07-22 Tom Tromey <tom@tromey.com>
10207
10208 * break-catch-syscall.c (syscall_catchpoint)
10209 <syscalls_to_be_caught>: Now a std::vector<int>
10210 (~syscall_catchpoint): Remove.
10211 (insert_catch_syscall, remove_catch_syscall)
10212 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10213 (print_mention_catch_syscall, print_recreate_catch_syscall):
10214 Update.
10215 (create_syscall_event_catchpoint): Change type of "filter"
10216 parameter.
10217 (catch_syscall_split_args): Return a std::vector.
10218 (catch_syscall_command_1, catching_syscall_number_1): Update.
10219
4fa8aeac
TT
102202017-07-22 Tom Tromey <tom@tromey.com>
10221
10222 * break-catch-throw.c (struct exception_catchpoint)
10223 <exception_rx>: Now a std::string.
10224 (~exception_catchpoint): Remove.
10225 (print_one_detail_exception_catchpoint): Update.
10226 (handle_gnu_v3_exceptions): Change type of except_rx.
10227 (extract_exception_regexp): Return a std::string.
10228 (catch_exception_command_1): Update.
10229
f746a154
TT
102302017-07-22 Tom Tromey <tom@tromey.com>
10231
10232 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10233 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10234 std::vector.
10235 <catch_all>: Now a bool.
10236 (~signal_catchpoint): Remove.
10237 (signal_catchpoint_insert_location)
10238 (signal_catchpoint_remove_location)
10239 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10240 (signal_catchpoint_print_mention)
10241 (signal_catchpoint_print_recreate)
10242 (signal_catchpoint_explains_signal): Update.
10243 (create_signal_catchpoint): Change type of "filter" and
10244 "catch_all".
10245 (catch_signal_split_args): Return a std::vector. Change type of
10246 "catch_all".
10247 (catch_signal_command): Update.
10248
47e77640
PA
102492017-07-20 Pedro Alves <palves@redhat.com>
10250
10251 * ada-lang.c (ada_language_defn): Make extern.
10252 (_initialize_ada_language): Remove add_language call.
10253 * c-lang.c (c_language_defn, cplus_language_defn)
10254 (asm_language_defn, minimal_language_defn): Make extern.
10255 (_initialize_c_language): Delete.
10256 * completer.c (compare_cstrings): Delete, moved to utils.h.
10257 * d-lang.c (d_language_defn): Make extern.
10258 (_initialize_d_language): Remove add_language calls.
10259 * defs.h (enum language): Add comment.
10260 * f-lang.c (f_language_defn): Make extern.
10261 (_initialize_f_language): Remove add_language call.
10262 * go-lang.c (go_language_defn): Make extern.
10263 (_initialize_go_language): Remove add_language call.
10264 * language.c: Include <algorithm>.
10265 (languages): Redefine as const array.
10266 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10267 (set_language_command): Handle "local". Use for-range loop.
10268 (set_language): Remove loop.
10269 (language_enum): Rewrite.
10270 (language_def, language_str): Remove loops.
10271 (add_language): Delete.
10272 (add_set_language_command): New, based on add_languages.
10273 (skip_language_trampoline): Adjust.
10274 (local_language_defn): Delete.
10275 (language_gdbarch_post_init): Adjust.
10276 (_initialize_language): Remove add_language calls. Call
10277 add_set_language_command.
10278 * language.h (add_language): Delete.
10279 (auto_language_defn)
10280 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10281 (asm_language_defn, c_language_defn, cplus_language_defn)
10282 (d_language_defn, f_language_defn, go_language_defn)
10283 (m2_language_defn, objc_language_defn, opencl_language_defn)
10284 (pascal_language_defn, rust_language_defn): Declare.
10285 * m2-lang.c (m2_language_defn): Make extern.
10286 (_initialize_m2_language): Remove add_language call.
10287 * objc-lang.c (objc_language_defn): Make extern.
10288 (_initialize_objc_language): Remove add_language call.
10289 * opencl-lang.c (opencl_language_defn): Make extern.
10290 (_initialize_opencl_language): Remove add_language call.
10291 * p-lang.c (pascal_language_defn): Make extern.
10292 (_initialize_pascal_language): Delete.
10293 * rust-lang.c (rust_language_defn): Make extern.
10294 (_initialize_rust_language): Delete.
10295 * utils.h (compare_cstrings): New static inline function.
10296
edb0c9cb
PA
102972017-07-20 Pedro Alves <palves@redhat.com>
10298
10299 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10300 (get_var_value): Constify parameters.
10301 (get_int_var_value): Change prototype.
10302 (to_fixed_range_type): Adjust.
10303 * ada-lang.h (get_int_var_value): Change prototype.
10304
a778f165
PA
103052017-07-20 Pedro Alves <palves@redhat.com>
10306
10307 * dwarf2read.c (dw2_lookup_symbol): Use
10308 SYMBOL_MATCHES_SEARCH_NAME.
10309 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10310
42edd901
PA
103112017-07-20 Pedro Alves <palves@redhat.com>
10312
10313 * block.c (block_iter_name_step, block_iter_name_first)
10314 (block_iter_name_next): Delete.
10315 (block_lookup_symbol_primary): Adjust to use
10316 dict_iter_match_first/dict_iter_match_next.
10317 * block.h (block_iter_name_first, block_iter_name_next): Delete
10318 declarations.
10319 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10320 dict_iter_match_first/dict_iter_match_next.
10321
cf325299
PA
103222017-07-20 Pedro Alves <palves@redhat.com>
10323
10324 * cp-support.c (cp_find_first_component_aux): Add missing case for
10325 end of string.
10326
c5ed0576
DB
103272017-07-18 David Blaikie <dblaikie@gmail.com>
10328
10329 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10330 of dwo_cu's dwo_file.
10331
27841e76
YQ
103322017-07-18 Yao Qi <yao.qi@linaro.org>
10333
10334 * remote.c (store_registers_using_G): Remove one line comment.
10335
cfb7e58b
YQ
103362017-07-18 Yao Qi <yao.qi@linaro.org>
10337
10338 * regcache.c (regcache_cpy): Simplify it.
10339 (regcache::cpy_no_passthrough): Remove it.
10340 * regcache.h (cpy_no_passthrough): Remove it.
10341 (regcache_dup, regcache_cpy): Update comments.
10342
386535dd
PA
103432017-07-18 Pedro Alves <palves@redhat.com>
10344
10345 * remote-sim.c (sim_command_completer): Adjust to work with a
10346 completion_tracker instead of a VEC.
10347
c45ec17c
PA
103482017-07-17 Pedro Alves <palves@redhat.com>
10349
10350 * completer.c (complete_source_filenames): New function.
10351 (complete_address_and_linespec_locations): New function.
10352 (location_completer): Use complete_address_and_linespec_locations.
10353 (completion_tracker::build_completion_result): Honor the tracker's
10354 request to suppress append.
10355 * completer.h (completion_tracker::suppress_append_ws)
10356 (completion_tracker::set_suppress_append_ws): New methods.
10357 (completion_tracker::m_suppress_append_ws): New field.
10358 (complete_source_filenames): New declaration.
10359 * linespec.c (linespec_complete_what): New.
10360 (struct ls_parser) <complete_what, completion_word,
10361 completion_quote_char, completion_quote_end, completion_tracker>:
10362 New fields.
10363 (string_find_incomplete_keyword_at_end): New.
10364 (linespec_lexer_lex_string): Record quote char. If in completion
10365 mode, don't throw.
10366 (linespec_lexer_consume_token): Advance the completion word point.
10367 (linespec_lexer_peek_token): Save/restore completion info.
10368 (save_stream_and_consume_token): New.
10369 (set_completion_after_number): New.
10370 (linespec_parse_basic): Set what to complete next depending on
10371 token. Handle function and label completions specially.
10372 (parse_linespec): Disable objc shortcut in completion mode. Set
10373 what to complete next depending on token type. Skip keyword if in
10374 completion mode.
10375 (complete_linespec_component, linespec_complete): New.
10376 * linespec.h (linespec_complete): Declare.
10377
be966d42
PA
103782017-07-17 Pedro Alves <palves@redhat.com>
10379
10380 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10381 Handle 'operator<' / 'operator<<'.
10382
a2459270
PA
103832017-07-17 Pedro Alves <palves@redhat.com>
10384
10385 * completer.c (collect_explicit_location_matches): Handle
10386 MATCH_LABEL.
10387 (convert_explicit_location_to_linespec): New, factored out from
10388 ...
10389 (convert_explicit_location_to_sals): ... this.
10390 (complete_label): New.
10391 (linespec_complete_label, find_label_symbols_in_block): New.
10392 (find_label_symbols): Add completion_mode parameter and adjust to
10393 call find_label_symbols_in_block.
10394 * linespec.h (linespec_complete_label): Declare.
10395
c6756f62
PA
103962017-07-17 Pedro Alves <palves@redhat.com>
10397
10398 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10399 complete_symbol_mode parameter.
10400 * cli/cli-cmds.c (complete_command): Get the completion result out
10401 of the handle_brkchars tracker if used a custom word point.
10402 * completer.c: Include "linespec.h".
10403 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10404 (advance_to_expression_complete_word_point): New.
10405 (completion_tracker::completes_to_completion_word): New.
10406 (complete_files_symbols): Pass down
10407 complete_symbol_mode::EXPRESSION.
10408 (explicit_options, probe_options): New.
10409 (collect_explicit_location_matches): Complete on the
10410 explictit_loc->foo instead of word. Use
10411 linespec_complete_function. Handle MATCH_LINE. Handle offering
10412 keyword and options completions.
10413 (backup_text_ptr): Delete.
10414 (skip_keyword): New.
10415 (complete_explicit_location): Remove 'word' parameter. Add
10416 language, quoted_arg_start and quoted_arg_end parameters.
10417 Rewrite, parsing left to right.
10418 (location_completer): Rewrite.
10419 (location_completer_handle_brkchars): New function.
10420 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10421 (enum complete_line_internal_reason): Adjust comments.
10422 (completion_tracker::discard_completions): New.
10423 (completer_handle_brkchars_func_for_completer): Handle
10424 location_completer.
10425 (gdb_custom_word_point_brkchars)
10426 (gdb_org_rl_basic_quote_characters): New.
10427 (gdb_completion_word_break_characters_throw)
10428 (completion_find_completion_word): Handle trackers that use a
10429 custom word point.
10430 (completion_tracker::advance_custom_word_point_by): New.
10431 (completion_tracker::build_completion_result): Don't rely on
10432 readline appending the quote char.
10433 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10434 use a custom word point.
10435 (gdb_rl_attempted_completion_function): Restore
10436 rl_basic_quote_characters.
10437 * completer.h (class completion_tracker): Extend intro comment.
10438 (completion_tracker::set_quote_char)
10439 (completion_tracker::quote_char)
10440 (completion_tracker::set_use_custom_word_point)
10441 (completion_tracker::use_custom_word_point)
10442 (completion_tracker::custom_word_point)
10443 (completion_tracker::set_custom_word_point)
10444 (completion_tracker::advance_custom_word_point_by)
10445 (completion_tracker::completes_to_completion_word)
10446 (completion_tracker::discard_completions): New methods.
10447 (completion_tracker::m_quote_char)
10448 (completion_tracker::m_use_custom_word_point)
10449 (completion_tracker::m_custom_word_point): New fields.
10450 (advance_to_expression_complete_word_point): Declare.
10451 * f-lang.c (f_collect_symbol_completion_matches): Add
10452 complete_symbol_mode parameter.
10453 * language.h (struct language_defn)
10454 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10455 parameter.
10456 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10457 (linespec_complete_function): New function.
10458 (linespec_lexer_lex_keyword): Adjust.
10459 * linespec.h (linespec_keywords, linespec_complete_function): New
10460 declarations.
10461 * location.c (find_end_quote): New function.
10462 (explicit_location_lex_one): Add explicit_completion_info
10463 parameter. Save quoting info. Don't throw if being called for
10464 completion. Don't handle Ada operators here.
10465 (is_cp_operator, skip_op_false_positives, first_of)
10466 (explicit_location_lex_one_function): New function.
10467 (string_to_explicit_location): Replace 'dont_throw' parameter with
10468 an explicit_completion_info pointer parameter. Handle it. Don't
10469 use explicit_location_lex_one to lex function names. Use
10470 explicit_location_lex_one_function instead.
10471 * location.h (struct explicit_completion_info): New.
10472 (string_to_explicit_location): Replace 'dont_throw' parameter with
10473 an explicit_completion_info pointer parameter.
10474 * symtab.c (default_collect_symbol_completion_matches_break_on):
10475 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10476 (default_collect_symbol_completion_matches)
10477 (collect_symbol_completion_matches): Add complete_symbol_mode
10478 parameter.
10479 (collect_symbol_completion_matches_type): Pass down
10480 complete_symbol_mode::EXPRESSION.
10481 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10482 parameter. Handle LINESPEC mode.
10483 * symtab.h (complete_symbol_mode): New.
10484 (default_collect_symbol_completion_matches_break_on)
10485 (default_collect_symbol_completion_matches)
10486 (collect_symbol_completion_matches)
10487 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10488 parameter.
10489
1d550c82
PA
104902017-07-17 Pedro Alves <palves@redhat.com>
10491
10492 * utils.c (enum class strncmp_iw_mode): New.
10493 (strcmp_iw): Rename to ...
10494 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10495 parameters. Handle them.
10496 (strncmp_iw): New.
10497 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10498 * utils.h (strncmp_iw): Declare.
10499 (strcmp_iw): Move describing comments here.
10500
8090b426
PA
105012017-07-17 Pedro Alves <palves@redhat.com>
10502
10503 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10504 CP_OPERATOR_STR.
10505 * c-typeprint.c (is_type_conversion_operator): Use
10506 CP_OPERATOR_STR.
10507 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10508 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10509 CP_OPERATOR_LEN.
10510 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10511 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10512 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10513 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10514 CP_OPERATOR_STR.
10515 * location.c: Include "cp-support.h".
10516 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10517 CP_OPERATOR_STR.
10518 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10519 CP_OPERATOR_LEN.
10520
6a2c1b87
PA
105212017-07-17 Pedro Alves <palves@redhat.com>
10522
10523 * cli/cli-cmds.c (complete_command): Use a completion tracker
10524 along with completion_find_completion_word for handle_brkchars
10525 phase.
10526 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10527 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10528 (struct gdb_rl_completion_word_info): New.
10529 (gdb_rl_find_completion_word): New.
10530 (completion_find_completion_word): New.
10531 * completer.h (completion_find_completion_word): Declare.
10532
eb3ff9a5
PA
105332017-07-17 Pedro Alves <palves@redhat.com>
10534
10535 * ada-lang.c (symbol_completion_match): Adjust comments.
10536 (symbol_completion_add): Replace vector parameter with
10537 completion_tracker parameter. Use it.
10538 (ada_make_symbol_completion_list): Rename to...
10539 (ada_collect_symbol_completion_matches): ... this. Add
10540 completion_tracker parameter and use it.
10541 (ada_language_defn): Adjust.
10542 * break-catch-syscall.c (catch_syscall_completer): Adjust
10543 prototype and work with completion_tracker instead of VEC.
10544 * breakpoint.c (condition_completer): Adjust prototype and work
10545 with completion_tracker instead of VEC.
10546 * c-lang.c (c_language_defn, cplus_language_defn)
10547 (asm_language_defn, minimal_language_defn): Adjust to renames.
10548 * cli/cli-cmds.c (complete_command): Rework using
10549 completion_tracker. Catch exceptions when completing.
10550 * cli/cli-decode.c (integer_unlimited_completer)
10551 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
10552 with completion_tracker instead of VEC.
10553 * command.h (struct completion_tracker): Forward declare.
10554 (completer_ftype, completer_handle_brkchars_ftype): Change
10555 types.
10556 (complete_on_cmdlist, complete_on_enum): Adjust.
10557 * completer.c: Include <algorithm>.
10558 (struct gdb_completer_state): New.
10559 (current_completion): New global.
10560 (readline_line_completion_function): Delete.
10561 (noop_completer, filename_completer)
10562 (filename_completer_handle_brkchars, complete_files_symbols)
10563 (linespec_location_completer): Adjust to work with a
10564 completion_tracker instead of a VEC.
10565 (string_or_empty): New.
10566 (collect_explicit_location_matches): Adjust to work with a
10567 completion_tracker instead of a VEC.
10568 (explicit_location_completer): Rename to ...
10569 (complete_explicit_location): ... this and adjust to work with a
10570 completion_tracker instead of a VEC.
10571 (location_completer): Adjust to work with a completion_tracker
10572 instead of a VEC.
10573 (add_struct_fields): Adjust to work with a completion_list instead
10574 of VEC.
10575 (expression_completer): Rename to ...
10576 (complete_expression): ... this and adjust to work with a
10577 completion_tracker instead of a VEC. Use complete_files_symbols.
10578 (expression_completer): Reimplement on top of complete_expression.
10579 (symbol_completer): Adjust to work with a completion_tracker
10580 instead of a VEC.
10581 (enum complete_line_internal_reason): Add describing comments.
10582 (complete_line_internal_normal_command): Adjust to work with a
10583 completion_tracker instead of a VEC.
10584 (complete_line_internal): Rename to ...
10585 (complete_line_internal_1): ... this and adjust to work with a
10586 completion_tracker instead of a VEC. Assert TEXT is NULL in the
10587 handle_brkchars phase.
10588 (new_completion_tracker): Delete.
10589 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
10590 complete_line_internal_1.
10591 (free_completion_tracker): Delete.
10592 (INITIAL_COMPLETION_HTAB_SIZE): New.
10593 (completion_tracker::completion_tracker)
10594 (completion_tracker::~completion_tracker): New.
10595 (maybe_add_completion): Delete.
10596 (completion_tracker::maybe_add_completion)
10597 (completion_tracker::add_completion)
10598 (completion_tracker::add_completions): New.
10599 (throw_max_completions_reached_error): Delete.
10600 (complete_line): Adjust to work with a completion_tracker instead
10601 of a VEC. Don't create a completion_tracker_t or check for max
10602 completions here.
10603 (command_completer, command_completer_handle_brkchars)
10604 (signal_completer, reg_or_group_completer_1)
10605 (reg_or_group_completer, default_completer_handle_brkchars):
10606 Adjust to work with a completion_tracker.
10607 (gdb_completion_word_break_characters_throw): New.
10608 (gdb_completion_word_break_characters): Reimplement.
10609 (line_completion_function): Delete.
10610 (completion_tracker::recompute_lowest_common_denominator)
10611 (expand_preserving_ws)
10612 (completion_tracker::build_completion_result)
10613 (completion_result::completion_result)
10614 (completion_result::completion_result)
10615 (completion_result::~completion_result)
10616 (completion_result::completion_result)
10617 (completion_result::release_match_list, compare_cstrings)
10618 (completion_result::sort_match_list)
10619 (completion_result::reset_match_list)
10620 (gdb_rl_attempted_completion_function_throw)
10621 (gdb_rl_attempted_completion_function): New.
10622 * completer.h (completion_list, struct completion_result)
10623 (class completion_tracker): New.
10624 (complete_line): Add completion_tracker parameter.
10625 (readline_line_completion_function): Delete.
10626 (gdb_rl_attempted_completion_function): New.
10627 (noop_completer, filename_completer, expression_completer)
10628 (location_completer, symbol_completer, command_completer)
10629 (signal_completer, reg_or_group_completer): Update prototypes.
10630 (completion_tracker_t, new_completion_tracker)
10631 (make_cleanup_free_completion_tracker): Delete.
10632 (enum maybe_add_completion_enum): Delete.
10633 (maybe_add_completion): Delete.
10634 (throw_max_completions_reached_error): Delete.
10635 * corefile.c (complete_set_gnutarget): Adjust to work with a
10636 completion_tracker instead of a VEC.
10637 * cp-abi.c (cp_abi_completer): Adjust to work with a
10638 completion_tracker instead of a VEC.
10639 * d-lang.c (d_language_defn): Adjust.
10640 * disasm.c (disassembler_options_completer): Adjust to work with a
10641 completion_tracker instead of a VEC.
10642 * f-lang.c (f_make_symbol_completion_list): Rename to ...
10643 (f_collect_symbol_completion_matches): ... this. Adjust to work
10644 with a completion_tracker instead of a VEC.
10645 (f_language_defn): Adjust.
10646 * go-lang.c (go_language_defn): Adjust.
10647 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
10648 Adjust to work with a completion_tracker instead of a VEC.
10649 * infrun.c (handle_completer): Likewise.
10650 * interps.c (interpreter_completer): Likewise.
10651 * interps.h (interpreter_completer): Likewise.
10652 * language.c (unknown_language_defn, auto_language_defn)
10653 (local_language_defn): Adjust.
10654 * language.h (language_defn::la_make_symbol_completion_list):
10655 Rename to ...
10656 (language_defn::la_collect_symbol_completion_matches): ... this
10657 and adjust to work with a completion_tracker instead of a VEC.
10658 * m2-lang.c (m2_language_defn): Adjust.
10659 * objc-lang.c (objc_language_defn): Adjust.
10660 * opencl-lang.c (opencl_language_defn): Adjust.
10661 * p-lang.c (pascal_language_defn): Adjust.
10662 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
10663 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
10664 with a completion_tracker.
10665 * rust-lang.c (rust_language_defn): Adjust.
10666 * symtab.c (free_completion_list, do_free_completion_list)
10667 (return_val, completion_tracker): Delete.
10668 (completion_list_add_name, completion_list_add_symbol)
10669 (completion_list_add_msymbol, completion_list_objc_symbol)
10670 (completion_list_add_fields, add_symtab_completions): Add
10671 completion_tracker parameter and use it.
10672 (default_make_symbol_completion_list_break_on_1): Rename to...
10673 (default_collect_symbol_completion_matches_break_on): ... this.
10674 Add completion_tracker parameter and use it instead of allocating
10675 a completion tracker here.
10676 (default_make_symbol_completion_list_break_on): Delete old
10677 implementation.
10678 (default_make_symbol_completion_list): Delete.
10679 (default_collect_symbol_completion_matches): New.
10680 (make_symbol_completion_list): Delete.
10681 (collect_symbol_completion_matches): New.
10682 (make_symbol_completion_type): Rename to ...
10683 (collect_symbol_completion_matches_type): ... this. Add
10684 completion_tracker parameter and use it instead of VEC.
10685 (make_file_symbol_completion_list_1): Rename to...
10686 (collect_file_symbol_completion_matches): ... this. Add
10687 completion_tracker parameter and use it instead of VEC.
10688 (make_file_symbol_completion_list): Delete.
10689 (add_filename_to_list): Use completion_list instead of a VEC.
10690 (add_partial_filename_data::list): Now a completion_list.
10691 (make_source_files_completion_list): Work with a completion_list
10692 instead of a VEC.
10693 * symtab.h: Include "completer.h".
10694 (default_make_symbol_completion_list_break_on)
10695 (default_make_symbol_completion_list, make_symbol_completion_list)
10696 (make_symbol_completion_type, make_file_symbol_completion_list)
10697 (make_source_files_completion_list): Delete.
10698 (default_collect_symbol_completion_matches_break_on)
10699 (default_collect_symbol_completion_matches)
10700 (collect_symbol_completion_matches)
10701 (collect_symbol_completion_matches_type)
10702 (collect_file_symbol_completion_matches)
10703 (make_source_files_completion_list): New.
10704 * top.c (init_main): Don't install a rl_completion_entry_function
10705 hook. Install a rl_attempted_completion_function hook instead.
10706 * tui/tui-layout.c (layout_completer): Adjust to work with a
10707 completion_tracker.
10708 * tui/tui-regs.c (tui_reggroup_completer):
10709 * tui/tui-win.c (window_name_completer, focus_completer)
10710 (winheight_completer): Adjust to work with a completion_tracker.
10711 * value.c: Include "completer.h".
10712 (complete_internalvar): Adjust to work with a completion_tracker.
10713 * value.h (complete_internalvar): Likewise.
10714
6e1dbf8c
PA
107152017-07-17 Pedro Alves <palves@redhat.com>
10716
10717 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
10718 renames.
10719 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
10720 comments to completer_ftype's declaration.
10721 <completer_handle_brkchars>: Change type to
10722 completer_handle_brkchars_ftype.
10723 * command.h (completer_ftype): Add describing comment and give
10724 names to parameters.
10725 (completer_ftype_void): Rename to ...
10726 (completer_handle_brkchars_ftype) ... this. Add describing comment.
10727 (set_cmd_completer_handle_brkchars): Adjust.
10728 * completer.c (filename_completer_handle_brkchars): New function.
10729 (complete_line_internal_normal_command): New function, factored
10730 out from ...
10731 (complete_line_internal): ... here.
10732 (command_completer_handle_brkchars)
10733 (default_completer_handle_brkchars)
10734 (completer_handle_brkchars_func_for_completer): New functions.
10735 * completer.h (set_gdb_completion_word_break_characters): Delete
10736 declaration.
10737 (completer_handle_brkchars_func_for_completer): New declaration.
10738 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
10739 completer_handle_brkchars_func_for_completer.
10740
78b13106
PA
107412017-07-17 Pedro Alves <palves@redhat.com>
10742
10743 * completer.c (symbol_completer): New function, based on
10744 make_symbol_completion_list_fn.
10745 * completer.h (symbol_completer): New declaration.
10746 * guile/scm-cmd.c (cmdscm_completers): Adjust.
10747 * python/py-cmd.c (completers): Adjust.
10748 * symtab.c (make_symbol_completion_list_fn): Delete.
10749 * symtab.h (make_symbol_completion_list_fn): Delete.
10750 * cli/cli-decode.c (add_cmd): Adjust.
10751
bbf2f4df
PA
107522017-07-17 Pedro Alves <palves@redhat.com>
10753
10754 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
10755 * dwarf2read.c: Include "filename-seen-cache.h".
10756 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
10757 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
10758 * filename-seen-cache.c: New file.
10759 * filename-seen-cache.h: New file.
10760 * symtab.c: Include "filename-seen-cache.h".
10761 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
10762 (create_filename_seen_cache, clear_filename_seen_cache)
10763 (delete_filename_seen_cache, filename_seen): Delete, parts moved
10764 to filename-seen-cache.h/filename-seen-cache.c.
10765 (output_source_filename, sources_info)
10766 (maybe_add_partial_symtab_filename)
10767 (make_source_files_completion_list): Adjust to use
10768 filename_seen_cache.
10769
330cdd98
PA
107702017-07-17 Pedro Alves <palves@redhat.com>
10771
10772 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
10773 fields.
10774 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
10775 dwarf2_debug_sections*)): New.
10776 (dwarf2_per_objfile::dwarf2_per_objfile(const
10777 dwarf2_per_objfile&)): Declare as deleted.
10778 (dwarf2_per_objfile::operator=): Declare as deleted.
10779 (dwarf2_per_objfile::dwarf2_per_objfile)
10780 (dwarf2_per_objfile::~dwarf2_per_objfile)
10781 (dwarf2_per_objfile::free_cached_comp_units): New.
10782 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
10783 ctor. Call dwarf2_per_objfile's ctor manually.
10784 (dwarf2_locate_sections): Deleted/refactored as ...
10785 (dwarf2_per_objfile::locate_sections): ... this new method.
10786 (free_cached_comp_units): Defer to
10787 dwarf2_per_objfile::free_cached_comp_units.
10788 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
10789
8880f2a9
TT
107902017-07-14 Tom Tromey <tom@tromey.com>
10791
10792 PR rust/21764:
10793 * rust-exp.y (convert_ast_to_expression): Add "want_type"
10794 parameter.
10795 <UNOP_SIZEOF>: Split into separate case.
10796 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
10797
65547233
TT
107982017-07-14 Tom Tromey <tom@tromey.com>
10799
10800 PR rust/21763:
10801 * symtab.c (symbol_matches_domain): Add language_rust to special
10802 case.
10803 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
10804 treat LOC_TYPEDEF symbols as variables.
10805
8f14146e
PA
108062017-07-14 Pedro Alves <palves@redhat.com>
10807
10808 * symtab.c (make_file_symbol_completion_list_1): Iterate over
10809 symtabs matching all symtabs with SRCFILE as file name instead of
10810 only considering the first hit, with lookup_symtab.
10811
2347965c
SM
108122017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10813
10814 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
10815 operator_name parameters.
10816 (gen_expr): Update function call.
10817
40f4af28
SM
108182017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10819
10820 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
10821 parameter.
10822 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
10823 Likewise.
10824 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
10825 parameter, use agent_expr::gdbarch instead, update function
10826 calls.
10827 (locexpr_tracepoint_var_ref): Likewise.
10828 (loclist_tracepoint_var_ref): Likewise.
10829 * ax-gdb.c (gen_trace_static_fields): Likewise.
10830 (gen_traced_pop): Likewise.
10831 (gen_frame_args_address): Likewise.
10832 (gen_frame_locals_address): Likewise.
10833 (gen_var_ref): Likewise.
10834 (gen_struct_ref_recursive): Likewise.
10835 (gen_static_field): Likewise.
10836 (gen_maybe_namespace_elt): Likewise.
10837 (gen_expr): Likewise.
10838 (gen_trace_for_var): Likewise.
10839 (gen_trace_for_expr): Likewise.
10840 (gen_trace_for_return_address): Likewise.
10841
053f8057
SM
108422017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10843
10844 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
10845 parameter.
10846 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
10847
6661ad48
SM
108482017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10849
10850 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
10851 from ax, update calls.
10852 (gen_usual_arithmetic): Likewise.
10853 (gen_integral_promotions): Likewise.
10854 (gen_bitfield_ref): Likewise.
10855 (gen_primitive_field): Likewise.
10856 (gen_struct_ref_recursive): Likewise.
10857 (gen_struct_ref): Likewise.
10858 (gen_maybe_namespace_elt): Likewise.
10859 (gen_struct_elt_for_reference): Likewise.
10860 (gen_namespace_elt): Likewise.
10861 (gen_aggregate_elt_ref): Likewise.
10862 (gen_expr): Get gdbarch from ax, update calls.
10863 (gen_expr_binop_rest): Likewise.
10864
c55a47e7
PA
108652017-07-13 Pedro Alves <palves@redhat.com>
10866
10867 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
10868 as default tdesc.
10869 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
10870 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
10871 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
10872 tdesc_amd64_linux as default tdesc. Get final tdesc from the
10873 tdep.
10874 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
10875 Get final tdesc from the tdep.
10876 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
10877 default tdesc.
10878 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
10879 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
10880 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
10881 Use it as default tdesc.
10882 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
10883 down to amd_init_abi. No longer handle fallback tdesc here.
10884 * amd64-tdep.h (tdesc_x32): Declare.
10885 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
10886 parameter.
10887 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
10888 as default tdesc.
10889
55efceab
AA
108902017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10891
10892 * s390-linux-tdep.c (s390_process_record): Add support for
10893 instructions new in arch12.
10894
0aa37b65
JB
108952017-07-11 John Baldwin <jhb@FreeBSD.org>
10896
10897 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
10898 PT_GETFSBASE and PT_GETGSBASE.
10899 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
10900 PT_SETGSBASE.
10901
48aeef91
JB
109022017-07-11 John Baldwin <jhb@FreeBSD.org>
10903
10904 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
10905 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
10906 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
10907 those rules.
10908 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
10909 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
10910 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
10911 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
10912 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
10913 * features/i386/amd64.xml: Add 64bit-segments.xml.
10914 * features/i386/amd64-avx-avx512.c: Regenerated.
10915 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
10916 * features/i386/amd64-avx-mpx.c: Regenerated.
10917 * features/i386/amd64-avx.c: Regenerated.
10918 * features/i386/amd64-mpx.c: Regenerated.
10919 * features/i386/amd64.c: Regenerated.
10920 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
10921 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10922 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
10923 * regformats/i386/amd64-avx.dat: Regenerated.
10924 * regformats/i386/amd64-mpx.dat: Regenerated.
10925 * regformats/i386/amd64.dat: Regenerated.
10926
77c501bc
YQ
109272017-07-10 Yao Qi <yao.qi@linaro.org>
10928
10929 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10930 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10931
6dc8d757
AK
109322017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
10933
10934 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
10935 unsetenv.
10936 * gnulib/aclocal.m4: Regenerate.
10937 * gnulib/config.in: Regenerate.
10938 * gnulib/configure: Regenerate.
10939 * gnulib/import/Makefile.am: Regenerate.
10940 * gnulib/import/Makefile.in: Regenerate.
10941 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
10942 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
10943 * gnulib/import/m4/environ.m4: New file.
10944 * gnulib/import/m4/setenv.m4: New file.
10945 * gnulib/import/setenv.c: New file.
10946 * gnulib/import/unsetenv.c: New file.
10947
266934d1
SM
109482017-07-09 Simon Marchi <simon.marchi@ericsson.com>
10949
10950 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
10951 address when op is DW_OP_addr.
10952
03278692
TT
109532017-07-09 Tom Tromey <tom@tromey.com>
10954
10955 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
10956 check and apply to outer type.
10957
4b654465
JB
109582017-07-07 John Baldwin <jhb@FreeBSD.org>
10959
10960 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
10961 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
10962 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
10963 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
10964
2af9fc44
JB
109652017-07-07 John Baldwin <jhb@FreeBSD.org>
10966
10967 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
10968
382b69bb
JB
109692017-07-07 John Baldwin <jhb@FreeBSD.org>
10970
10971 * corelow.c (get_core_siginfo): Remove.
10972 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
10973 instead of get_core_siginfo.
10974 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
10975 * gdbarch.h: Re-generate.
10976 * gdbarch.c: Re-generate.
10977 * linux-tdep.c (linux_core_xfer_siginfo): New.
10978 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
10979
6e5eab33
JB
109802017-07-07 John Baldwin <jhb@FreeBSD.org>
10981
10982 * corelow.c (thread_section_name): Move to ...
10983 * gdbcore.h (thread_section_name): ... here.
10984
929edea9
JB
109852017-07-07 John Baldwin <jhb@FreeBSD.org>
10986
10987 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
10988 (struct siginfo32): New.
10989 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
10990 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
10991 via ptrace(PT_LWPINFO).
10992
762c974a
JB
109932017-07-07 John Baldwin <jhb@FreeBSD.org>
10994
10995 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
10996 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
10997 (fbsd_get_siginfo_type): New.
10998 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
10999 (_initialize_fbsd_tdep): New.
11000
33c5cd75
DB
110012017-07-06 David Blaikie <dblaikie@gmail.com>
11002
11003 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
11004 a singular dwo_unit*) to support multiple CUs in the same way that
11005 multiple TUs are supported.
11006 (create_cus_hash_table): Replace create_dwo_cu with a function for
11007 parsing multiple CUs from a DWO file.
11008 (open_and_init_dwo_file): Use create_cus_hash_table rather than
11009 create_dwo_cu.
11010 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
11011 htab_find, rather than comparing the signature to a singleton CU in
11012 the dwo_file.
11013
8455d262
PA
110142017-07-06 Pedro Alves <palves@redhat.com>
11015
11016 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
11017
4da3eb35
PA
110182017-07-04 Pedro Alves <palves@redhat.com>
11019
11020 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
11021 * gdbtypes.h (TYPE_STATIC): Delete.
11022 (struct fn_field) <is_public, is_abstract, is_static, is_final,
11023 is_synchronized, is_native>: Delete.
11024 <dummy>: Bump.
11025 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
11026 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
11027 (TYPE_FN_FIELD_ABSTRACT): Delete.
11028
5bfd255c
SM
110292017-07-03 Simon Marchi <simon.marchi@ericsson.com>
11030
11031 * buffer.h (buffer_finish): Fix spelling mistakes.
11032
25c54127
EZ
110332017-07-01 Eli Zaretskii <eliz@gnu.org>
11034
11035 * .dir-locals.el: Automatically switch to C-style comments in
11036 versions of Emacs that support the feature.
11037
dc4bde35
SDJ
110382017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11039 Pedro Alves <palves@redhat.com>
11040
11041 PR cli/21688
11042 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
11043 (process_next_line): New variable 'inline_cmd'.
11044 Adjust 'if' clauses for "python", "compile" and "guile" to use
11045 'command_name_equals' and check for '!inline_cmd'.
11046
51ed89aa
SDJ
110472017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
11048
11049 PR cli/21688
11050 * cli/cli-script.c (command_name_equals_not_inline): New function.
11051 (process_next_line): Adjust 'if' clauses for "python", "compile"
11052 and "guile" to use command_name_equals_not_inline.
11053
eb17d413
PA
110542017-06-29 Pedro Alves <palves@redhat.com>
11055
11056 * completer.c (expression_completer): Call
11057 linespec_location_completer instead of location_completer.
11058
195bcdd5
PA
110592017-06-29 Pedro Alves <palves@redhat.com>
11060
11061 * completer.c (expression_completer): Remove code that recomputes
11062 'text' from 'word'.
11063
adc764e7
YQ
110642017-06-29 Yao Qi <yao.qi@linaro.org>
11065
11066 * regformats/regdat.sh: Generate code with
11067 "ifndef IN_PROCESS_AGENT".
11068
6e75794e
PA
110692017-06-28 Pedro Alves <palves@redhat.com>
11070
11071 * command.h: Include "common/scoped_restore.h".
11072
bc491f2e
YQ
110732017-06-28 Yao Qi <yao.qi@linaro.org>
11074
11075 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
11076 instead of obstack_grow.
11077
41664b45
DG
110782017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
11079
11080 PR gdb/21337
11081 * symfile.c (reread_symbols): Call objfiles_changed just before
11082 read_symbols.
11083
6da67eb1
PA
110842017-06-27 Pedro Alves <palves@redhat.com>
11085
11086 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
11087 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
11088 (completion_list_add_symbol, completion_list_add_msymbol):
11089 ... these new functions.
11090 (add_symtab_completions)
11091 (default_make_symbol_completion_list_break_on_1): Adjust.
11092
23732b1e
PA
110932017-06-27 Pedro Alves <palves@redhat.com>
11094
11095 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
11096 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
11097 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
11098 dtor.
11099 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
11100 'storage_obstack' field an auto_obstack. In-class initialize all
11101 non-bitfield fields. Make minsyms_read bool.
11102 * symfile.c (read_symbols): Adjust.
11103
a4d1e79a
AH
111042017-06-27 Alan Hayward <alan.hayward@arm.com>
11105
11106 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
11107 (gdbsim_store_register): Likewise.
11108
8268c778
PA
111092017-06-27 Pedro Alves <palves@redhat.com>
11110
11111 * c-exp.y (name_obstack): Now an auto_obstack.
11112 (yylex): Use auto_obstack::clear.
11113 (c_parse): Use auto_obstack::clear instead of reinitializing and
11114 freeing the obstack.
11115 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
11116 * d-exp.y (name_obstack): Now an auto_obstack.
11117 (yylex): Use auto_obstack::clear.
11118 (d_parse): Use auto_obstack::clear instead of reinitializing and
11119 freeing the obstack.
11120 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
11121 auto_obstack.
11122 * dwarf2read.c (create_addrmap_from_index)
11123 (dwarf2_build_psymtabs_hard)
11124 (update_enumeration_type_from_children): Likewise.
11125 * gdb_obstack.h (auto_obstack): New type.
11126 * go-exp.y (name_obstack): Now an auto_obstack.
11127 (build_packaged_name): Use auto_obstack::clear.
11128 (go_parse): Use auto_obstack::clear instead of reinitializing and
11129 freeing the obstack.
11130 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
11131 auto_obstack.
11132 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
11133 * rust-exp.y (work_obstack): Now an auto_obstack.
11134 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
11135 reinitializing and freeing the obstack.
11136 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
11137 (host_char_to_target): Use auto_obstack.
11138 * utils.h (make_cleanup_obstack_free): Delete declaration.
11139 * valprint.c (generic_emit_char, generic_printstr): Use
11140 auto_obstack.
11141
db665f42
SM
111422017-06-27 Simon Marchi <simon.marchi@ericsson.com>
11143
11144 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
11145 thread.
11146 (darwin_init_thread_list): Don't update dummy thread.
11147 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
11148
873c0814
SM
111492017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11150
11151 * record-full.c (netorder16): Remove.
11152
8b5a7a6e
SM
111532017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11154
11155 * common/diagnostics.h: Define macros for GCC.
11156 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
11157 * common/vec.h: Include diagnostics.h.
11158 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
11159 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
11160 warning.
11161
d1435379
SM
111622017-06-26 Simon Marchi <simon.marchi@ericsson.com>
11163
11164 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
11165 New macro.
11166 * ada-lex.l: Ignore deprecated register warnings.
11167
cc75e0fd
SM
111682017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11169
11170 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
11171 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
11172
07809eaf
SM
111732017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11174
11175 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
11176 its own line.
11177
f076f034
SM
111782017-06-25 Simon Marchi <simon.marchi@ericsson.com>
11179
11180 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
11181
0dd5cbc5
AH
111822017-06-23 Alan Hayward <alan.hayward@arm.com>
11183
11184 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
11185 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
11186 (xtensa_register_read_masked): Likewise.
11187
d4c6ce5b
SDJ
111882017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
11189
11190 * common/environ.c (gdb_environ::unset): Update comment.
11191
16892a03
AH
111922017-06-22 Alan Hayward <alan.hayward@arm.com>
11193
11194 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11195 registers.
11196
d7dcbefc
AH
111972017-06-22 Alan Hayward <alan.hayward@arm.com>
11198
11199 * record-full.c (record_full_exec_insn): Use byte_vector.
11200
b30ff123
YQ
112012017-06-22 Yao Qi <yao.qi@linaro.org>
11202
11203 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11204 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11205
4fa847d7
AH
112062017-06-22 Alan Hayward <alan.hayward@arm.com>
11207
11208 * remote.c (cached_reg): Move from here...
11209 * regcache.h (cached_reg): ...to here.
11210 * python/py-unwind.c (struct reg_info): Remove.
11211 (cached_frame_info): Use cached_reg_t.
11212 (pyuw_prev_register): Likewise.
11213 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11214 (pyuw_dealloc_cache): Free all registers.
11215
f4906a9a
PA
112162017-06-22 Pedro Alves <palves@redhat.com>
11217 Simon Marchi <simon.marchi@ericsson.com>
11218
11219 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11220 warning.
11221 * common/diagnostics.h: New file.
11222
b45a1208
PA
112232017-06-22 Pedro Alves <palves@redhat.com>
11224
11225 * common/agent.h: Add include guards.
11226
e4da2c61
SM
112272017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11228
11229 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11230 talk about addressable units instead of bytes.
11231
96160d60
SDJ
112322017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11233
11234 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11235 of '::const_iterator'.
11236
9a6c7d9c
SDJ
112372017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11238
11239 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11240 'unittests/environ-selftests.c'.
11241 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11242 * charset.c (find_charset_names): Declare object 'iconv_env'.
11243 Update code to use 'iconv_env' object. Remove call to
11244 'free_environ'.
11245 * common/environ.c: Include <utility>.
11246 (make_environ): Delete function.
11247 (free_environ): Delete function.
11248 (gdb_environ::clear): New function.
11249 (gdb_environ::operator=): New function.
11250 (gdb_environ::get): Likewise.
11251 (environ_vector): Delete function.
11252 (set_in_environ): Delete function.
11253 (gdb_environ::set): New function.
11254 (unset_in_environ): Delete function.
11255 (gdb_environ::unset): New function.
11256 (gdb_environ::envp): Likewise.
11257 * common/environ.h: Include <vector>.
11258 (struct gdb_environ): Delete; transform into...
11259 (class gdb_environ): ... this class.
11260 (free_environ): Delete prototype.
11261 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11262 environ_vector): Likewise.
11263 * infcmd.c (run_command_1): Update code to call
11264 'envp' from 'gdb_environ' class.
11265 (environment_info): Update code to call methods from 'gdb_environ'
11266 class.
11267 (unset_environment_command): Likewise.
11268 (path_info): Likewise.
11269 (path_command): Likewise.
11270 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11271 (inferior::inferior): Initialize 'environment' using the host's
11272 information.
11273 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11274 Include "environ.h".
11275 (class inferior) <environment>: Change type from 'struct
11276 gdb_environ' to 'gdb_environ'.
11277 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11278 methods from 'gdb_environ' class.
11279 * solib.c (solib_find_1): Likewise
11280 * unittests/environ-selftests.c: New file.
11281
75c554cf
YQ
112822017-06-20 Yao Qi <yao.qi@linaro.org>
11283
11284 * features/i386/i386-linux.xml: Exchange the order of including
11285 32bit-linux.xml and 32bit-sse.xml.
11286 * features/i386/i386-linux.c: Regenerated.
11287
72ddacb7
YQ
112882017-06-20 Yao Qi <yao.qi@linaro.org>
11289
11290 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11291 Delete copy ctor and assignment operator.
11292 (tdesc_type): Likewise.
11293 (tdesc_feature): Likewise.
11294 (tdesc_free_reg): Remove.
11295 (tdesc_create_reg): Use new.
11296 (tdesc_free_type): Remove.
11297 (tdesc_create_vector): Use new.
11298 (tdesc_create_union): Likewise.
11299 (tdesc_create_flags): Likewise.
11300 (tdesc_create_enum): Likewise.
11301 (tdesc_free_feature): Delete.
11302 (free_target_description): Use delete.
11303
325c9fd4
JB
113042017-06-19 John Baldwin <jhb@FreeBSD.org>
11305
11306 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11307 registers.
11308
16b7a719
PA
113092017-06-19 Pedro Alves <palves@redhat.com>
11310
11311 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11312 after gdb::unlinker.
11313
1c8e01c9
SDJ
113142017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11315
11316 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11317 gdb_environ to access an environment variable.
11318
ffce45d2
TP
113192017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11320
11321 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11322 gdb_byte*.
11323
1d4fbac9
SM
113242017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11325
11326 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11327
8465943a
SM
113282017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11329
11330 * configure: Re-generate.
11331 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11332
3e019bdc
SM
113332017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11334
11335 * configure: Re-generate.
11336 * warning.m4: Pass -Werror to compiler when checking for
11337 supported warning flags.
11338
cf0dd6f0
SM
113392017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11340
11341 * Makefile.in (COMPILE.pre): Add "-x c++".
11342
6f98355c
YQ
113432017-06-16 Alan Hayward <alan.hayward@arm.com>
11344 Pedro Alves <palves@redhat.com>
11345 Yao Qi <yao.qi@linaro.org>
11346
11347 * defs.h (RequireLongest): New.
11348 (extract_integer): Declare function template.
11349 (extract_signed_integer): Remove the declaration, but define it
11350 static inline.
11351 (extract_unsigned_integer): Likewise.
11352 (store_integer): Declare function template.
11353 (store_signed_integer): Remove the declaration, but define it
11354 static inline.
11355 (store_unsigned_integer): Likewise.
11356 * findvar.c (extract_integer): New function template.
11357 (extract_signed_integer): Remove.
11358 (extract_unsigned_integer): Remove.
11359 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11360 instantiations.
11361 (store_integer): New function template.
11362 (store_signed_integer): Remove.
11363 (store_unsigned_integer): Remove.
11364 (store_integer): Explicit instantiations.
11365 * regcache.c (regcache_raw_read_signed): Update.
11366 (regcache::raw_read): New function.
11367 (regcache::raw_read_signed): Remove.
11368 (regcache::raw_read_unsigned): Remove.
11369 (regcache_raw_read_unsigned): Update.
11370 (regcache_raw_write_unsigned): Update.
11371 (regcache::raw_write_signed): Remove.
11372 (regcache::raw_write): New function.
11373 (regcache_cooked_read_signed): Update.
11374 (regcache::raw_write_unsigned): Remove.
11375 (regcache::cooked_read_signed): Remove.
11376 (regcache_cooked_read_unsigned): Update.
11377 (regcache::cooked_read_unsigned): Remove.
11378 (regcache_cooked_write_signed): Update.
11379 (regcache_cooked_write_unsigned): Update.
11380 * regcache.h (regcache) <raw_read_signed>: Remove.
11381 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11382 <raw_read, raw_write>: New.
11383 <cooked_read_signed, cooked_write_signed>: Remove.
11384 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11385 <cooked_read, cooked_write>: New.
11386 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11387 (sh64_pseudo_register_write): Update.
11388
a87dc45a
AK
113892017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11390
11391 * arc-tdep.c (arc_disassembler_options): New variable.
11392 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11393 of default_print_insn.
11394 (arc_delayed_print_insn): Set info->section when needed,
11395 use default_print_insn to retrieve a disassembler.
11396
45159d6a
SDJ
113972017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11398
11399 PR gdb/21574
11400 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11401 to mention $SHELL and startup-with-shell.
11402
b46c4cf0
MF
114032017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11404
11405 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11406
6394c606
YQ
114072017-06-14 Yao Qi <yao.qi@linaro.org>
11408
11409 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11410 default_print_insn instead of print_insn_aarch64.
11411 * arm-tdep.c (gdb_print_insn_arm): Call
11412 default_print_insn instead of print_insn_big_arm
11413 and print_insn_little_arm.
11414 * i386-tdep.c (i386_print_insn): Call default_print_insn
11415 instead of print_insn_i386.
11416 * ia64-tdep.c (ia64_print_insn): Call
11417 default_print_insn instead of print_insn_ia64.
11418 * mips-tdep.c (gdb_print_insn_mips): Call
11419 default_print_insn instead of print_insn_big_mips
11420 and print_insn_little_mips.
11421 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11422 instead of print_insn_spu.
11423
d5722aa2
PA
114242017-06-14 Pedro Alves <palves@redhat.com>
11425
11426 * ada-lang.c: Include "common/byte-vector.h".
11427 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11428 * charset.c (wchar_iterator::iterate): Resize the vector instead
11429 of reserving it.
11430 * common/byte-vector.h: Include "common/def-vector.h".
11431 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11432 * cli/cli-dump.c: Include "common/byte-vector.h".
11433 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11434 * common/byte-vector.h: New file.
11435 * common/def-vector.h: New file.
11436 * common/default-init-alloc.h: New file.
11437 * dwarf2loc.c: Include "common/byte-vector.h".
11438 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11439 instead of reserving it.
11440 * dwarf2read.c: Include "common/byte-vector.h".
11441 (data_buf::m_vec): Now a gdb::byte_vector.
11442 * gdb_regex.c: Include "common/def-vector.h".
11443 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11444 * mi/mi-main.c: Include "common/byte-vector.h".
11445 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11446 * printcmd.c: Include "common/byte-vector.h".
11447 (print_scalar_formatted): Use gdb::byte_vector.
11448 * valprint.c: Include "common/byte-vector.h".
11449 (maybe_negate_by_bytes, print_decimal_chars): Use
11450 gdb::byte_vector.
11451
01ec7a27
SM
114522017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11453
11454 * darwin-nat.c: Include "nat/fork-inferior.h".
11455
848d9074
SM
114562017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11457
11458 * configure.nat: Factor out Darwin bits that are not
11459 architecture-specific. Add fork-inferior.o.
11460
3b912944
SM
114612017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11462
11463 * configure.nat: Factor out AIX bits that are not
11464 architecture-specific. Add fork-inferior.o.
11465
55acdf22
AA
114662017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11467
11468 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11469 (read_pieced_value, write_pieced_value): ...here. Reduce to
11470 wrappers that just call rw_pieced_value.
11471
f65e2044
AA
114722017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11473
11474 * dwarf2loc.c (write_pieced_value): When writing the data for a
11475 memory piece, use write_memory_with_notification instead of
11476 write_memory.
11477
23f945bf
AA
114782017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11479
11480 * valops.c (read_value_memory): Change embedded_offset to
11481 represent a bit offset instead of a byte offset.
11482 * value.h (read_value_memory): Adjust comment.
11483
f236533e
AA
114842017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11485
11486 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11487 dest_offset_bits and source_offset_bits.
11488 (write_pieced_value): Likewise.
11489
65d84b76
AA
114902017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11491
11492 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11493 given by DW_OP_bit_piece.
11494 (write_pieced_value): Likewise.
11495
242d31ab
AA
114962017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11497
11498 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11499 some other preparations to the places where sufficient information
11500 is available.
11501 (write_pieced_value): Likewise.
11502
03c8af18
AA
115032017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11504
11505 * dwarf2loc.c (bits_to_bytes): New function.
11506 (read_pieced_value): Fix offset calculations for register pieces
11507 on big-endian targets.
11508 (write_pieced_value): Likewise.
11509
840989c1
AA
115102017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11511
11512 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11513 (write_pieced_value): Likewise.
11514
359b19bb
AA
115152017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11516
11517 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11518 transfer the source value's least significant bits, instead of its
11519 lowest-addressed ones. Rename type_len to max_offset.
11520 (read_pieced_value): Mirror above changes to write_pieced_value as
11521 applicable.
11522
07c9ca3b
AA
115232017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11524
11525 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11526 truncate full bytes from dest_offset_bits before using it as an
11527 offset into the buffer.
11528
f1cc9874
AA
115292017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11530
11531 * dwarf2loc.c (write_pieced_value): Include transfer size in
11532 byte-wise check.
11533
cdaac320
AA
115342017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11535
11536 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11537 calculation of this_size.
11538
af547a96
AA
115392017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11540
11541 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
11542 when targeting a bit-field.
11543 (write_pieced_value): Likewise.
11544
ddd7882a
AA
115452017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11546
11547 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
11548 (allocate_piece_closure): Drop addr_size parameter.
11549 (dwarf2_evaluate_loc_desc_full): Adjust call to
11550 allocate_piece_closure.
11551
e9352324
AA
115522017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11553
11554 PR gdb/21226
11555 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
11556 the LSB end, independent of endianness.
11557
d5d1163e
AA
115582017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11559
11560 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
11561 size capping.
11562
032bb6ea
YQ
115632017-06-13 Yao Qi <yao.qi@linaro.org>
11564
11565 * mips-linux-nat.c: Move include features/mips*-linux.c to
11566 mips-linux-tdep.c.
11567 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
11568 to mips-linux-tdep.c.
11569 * mips-linux-tdep.c: Include features/mips*-linux.c
11570 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
11571 functions.
11572 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
11573 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
11574 (tdesc_mips64_dsp_linux): Declare.
11575
f12f6bad
TT
115762017-06-12 Tom Tromey <tom@tromey.com>
11577
11578 * valprint.h (val_print_type_code_int): Remove.
11579 * valprint.c (generic_val_print_int): Always call
11580 val_print_scalar_formatted.
11581 (val_print_type_code_int): Remove.
11582 * printcmd.c (print_scalar_formatted): Handle options->format==0.
11583 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
11584 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
11585 * ada-valprint.c (ada_val_print_num): Use
11586 val_print_scalar_formatted.
11587
d9109c80
TT
115882017-06-12 Tom Tromey <tom@tromey.com>
11589
11590 * printcmd.c (print_scalar_formatted): Unify the two switches.
11591 Don't convert scalars to LONGEST.
11592
4ac0cb1c
TT
115932017-06-12 Tom Tromey <tom@tromey.com>
11594
11595 PR exp/16225:
11596 * valprint.h (print_decimal_chars): Update.
11597 * valprint.c (maybe_negate_by_bytes): New function.
11598 (print_decimal_chars): Add "is_signed" argument.
11599 * printcmd.c (print_scalar_formatted): Update.
11600
30a25466
TT
116012017-06-12 Tom Tromey <tom@tromey.com>
11602
11603 PR exp/16225:
11604 * valprint.h (print_binary_chars, print_hex_chars): Update.
11605 * valprint.c (val_print_type_code_int): Update.
11606 (print_binary_chars): Add "zero_pad" argument.
11607 (emit_octal_digit): New function.
11608 (print_octal_chars): Don't zero-pad.
11609 (print_decimal_chars): Likewise.
11610 (print_hex_chars): Add "zero_pad" argument.
11611 * sh64-tdep.c (sh64_do_fp_register): Update.
11612 * regcache.c (regcache::dump): Update.
11613 * printcmd.c (print_scalar_formatted): Update.
11614 * infcmd.c (default_print_one_register_info): Update.
11615
b3464d03
PA
116162017-06-12 Pedro Alves <palves@redhat.com>
11617 Alan Hayward <alan.hayward@arm.com>
11618
11619 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
11620 (mips_eabi_push_dummy_call): Rename local 'regsize' to
11621 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
11622 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
11623 Assert that abi_regsize bytes fit in 'ref_valbuf'.
11624
4b76cda9
PA
116252017-06-12 Pedro Alves <palves@redhat.com>
11626
11627 * dwarf2read.c (mapped_symtab::data): Now a vector of
11628 symtab_index_entry instead of vector of
11629 std::unique_ptr<symtab_index_entry>. All users adjusted to check
11630 whether an element's name is NULL instead of checking whether the
11631 element itself is NULL.
11632 (find_slot): Change return type. Adjust.
11633 (hash_expand, , add_index_entry, uniquify_cu_indices)
11634 (write_hash_table): Adjust.
11635
e8f8bcb3
PA
116362017-06-12 Pedro Alves <palves@redhat.com>
11637
11638 * dwarf2read.c (recursively_count_psymbols): New function.
11639 (write_psymtabs_to_index): Call it to compute number of psyms and
11640 pass estimate size of psyms_seen to unordered_set's ctor.
11641
70a1152b
PA
116422017-06-12 Pedro Alves <palves@redhat.com>
11643
11644 * dwarf2read.c (write_hash_table): Check if key already exists
11645 before emplacing.
11646
c2f134ac
PA
116472017-06-12 Pedro Alves <palves@redhat.com>
11648
11649 * dwarf2read.c (data_buf::append_space): Rename to...
11650 (data_buf::grow): ... this, and make private. Adjust all callers.
11651 (data_buf::append_uint): New method.
11652 (add_address_entry, write_one_signatured_type)
11653 (write_psymtabs_to_index): Use it.
11654
a81e6d4d
PA
116552017-06-12 Pedro Alves <palves@redhat.com>
11656
11657 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
11658 (file_write (FILE *, const std::vector<Elem>&)): Delete.
11659 (data_buf::file_write): Call ::fwrite directly.
11660
6fd931f2
PA
116612017-06-12 Pedro Alves <palves@redhat.com>
11662
11663 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
11664 std::vector::erase.
11665
bc8f2430
JK
116662017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11667
11668 Code cleanup: C++ify .gdb_index producer.
11669 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
11670 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
11671 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
11672 (create_strtab, add_string): Remove.
11673 (file_write, data_buf): New.
11674 (struct symtab_index_entry): Use std::vector for cu_indices.
11675 (struct mapped_symtab): Use std::vector for data.
11676 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
11677 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
11678 Remove.
11679 (find_slot): Change return type. Update it to the new data structures.
11680 (hash_expand, add_index_entry): Update it to the new data structures.
11681 (offset_type_compare): Remove.
11682 (uniquify_cu_indices): Update it to the new data structures.
11683 (c_str_view, c_str_view_hasher, vector_hasher): New.
11684 (add_indices_to_cpool): Remove.
11685 (write_hash_table): Update it to the new data structures.
11686 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
11687 (eq_psymtab_cu_index): Remove.
11688 (psym_index_map): New typedef.
11689 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
11690 reference and std::unordered_map for cu_index_htab.
11691 (add_address_entry, add_address_entry_worker, write_address_map)
11692 (write_psymbols): Update it to the new data structures.
11693 (write_obstack): Remove.
11694 (struct signatured_type_index_data): Change types_list to a data_buf
11695 reference and psyms_seen to a std::unordered_set reference.
11696 (write_one_signatured_type, recursively_write_psymbols)
11697 (write_psymtabs_to_index): Update it to the new data structures.
11698
c4dcb155
SM
116992017-06-11 Simon Marchi <simon.marchi@ericsson.com>
11700
11701 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
11702 separate-debug-file commands.
11703 * symfile.h (separate_debug_file_debug): New global.
11704 * symfile.c (separate_debug_file_debug): New global.
11705 (separate_debug_file_exists, find_separate_debug_file): Add
11706 debug output.
11707 (_initialize_symfile): Add "set debug separate-debug-file"
11708 command.
11709 * build-id.c (build_id_to_debug_bfd,
11710 find_separate_debug_file_by_buildid): Add debug output.
11711
6d45d4b4
SM
117122017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
11713
11714 * gdbarch.sh (displaced_step_free_closure): Remove.
11715 * gdbarch.h, gdbarch.c: Re-generate.
11716 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
11717 displaced_step_free_closure.
11718 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
11719 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
11720 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
11721 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11722 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
11723 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11724 * arch-utils.h (simple_displaced_step_free_closure): Remove.
11725 * arch-utils.c (simple_displaced_step_free_closure): Remove.
11726 * infrun.c (displaced_step_clear): Call xfree instead of
11727 gdbarch_displaced_step_free_closure.
11728
2f91880f
SDJ
117292017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
11730
11731 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
11732 NULL".
11733
b8b6e72f
AH
117342017-06-08 Alan Hayward <alan.hayward@arm.com>
11735
11736 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
11737 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
11738 (mn10300_push_dummy_call): Likewise.
11739
5369082e
AH
117402017-06-08 Alan Hayward <alan.hayward@arm.com>
11741
11742 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
11743
ff4ca5ac
AH
117442017-06-08 Alan Hayward <alan.hayward@arm.com>
11745
11746 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
11747
aefd8b33
SDJ
117482017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11749
11750 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
11751 able to start inferiors using a shell.
11752 (New remote packets): Announce new packet "QStartupWithShell".
11753 * remote.c: Add PACKET_QStartupWithShell.
11754 (extended_remote_create_inferior): Handle new
11755 PACKET_QStartupWithShell.
11756 (remote_protocol_features) <QStartupWithShell>: New entry for
11757 PACKET_QStartupWithShell.
11758 (_initialize_remote): Call "add_packet_config_cmd" for
11759 QStartupShell.
11760
2090129c
SDJ
117612017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11762 Pedro Alves <palves@redhat.com>
11763
11764 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
11765 and "nat/fork-inferior.h".
11766 * common/common-inferior.h: New file, with contents from
11767 "gdb/inferior.h".
11768 * commom/common-utils.c: Include "common-utils.h".
11769 (stringify_argv): New function.
11770 * common/common-utils.h (stringify_argv): New prototype.
11771 * configure.nat: Add "fork-inferior.o" as a dependency for
11772 "*linux*", "fbsd*" and "nbsd*" hosts.
11773 * corefile.c (get_exec_file): Update comment.
11774 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
11775 instead of "startup_inferior".
11776 (darwin_create_inferior): Call "add_thread_silent" after
11777 "fork_inferior".
11778 * fork-child.c: Cleanup unnecessary includes.
11779 (SHELL_FILE): Move to "common/common-fork-child.c".
11780 (environ): Likewise.
11781 (exec_wrapper): Initialize.
11782 (get_exec_wrapper): New function.
11783 (breakup_args): Move to "common/common-fork-child.c"; rename to
11784 "breakup_args_for_exec".
11785 (escape_bang_in_quoted_argument): Move to
11786 "common/common-fork-child.c".
11787 (saved_ui): New variable.
11788 (prefork_hook): New function.
11789 (postfork_hook): Likewise.
11790 (postfork_child_hook): Likewise.
11791 (gdb_startup_inferior): Likewise.
11792 (fork_inferior): Move to "common/common-fork-child.c". Update
11793 function to support gdbserver.
11794 (startup_inferior): Likewise.
11795 * gdbcore.h (get_exec_file): Remove declaration.
11796 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
11797 instead of "startup_inferior". Call "add_thread_silent" after
11798 "fork_inferior".
11799 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
11800 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
11801 instead of "startup_inferior". Call "add_thread_silent" after
11802 "fork_inferior".
11803 * inferior.h: Include "common-inferior.h".
11804 (trace_start_error): Move to "common/common-utils.h".
11805 (trace_start_error_with_name): Likewise.
11806 (fork_inferior): Move prototype to "nat/fork-inferior.h".
11807 (startup_inferior): Likewise.
11808 (gdb_startup_inferior): New prototype.
11809 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
11810 * nat/fork-inferior.h: New file.
11811 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
11812 instead of "startup_inferior". Call "add_thread_silent" after
11813 "fork_inferior".
11814 * target.h (target_terminal_init): Move prototype to
11815 "target/target.h".
11816 (target_terminal_inferior): Likewise.
11817 (target_terminal_ours): Likewise.
11818 * target/target.h (target_terminal_init): New prototype, moved
11819 from "target.h".
11820 (target_terminal_inferior): Likewise.
11821 (target_terminal_ours): Likewise.
11822 * utils.c (gdb_flush_out_err): New function.
11823
043a4934
SDJ
118242017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11825
11826 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
11827 * common/common-gdbthread.h: New file, with parts from
11828 "gdb/gdbthread.h".
11829 * gdbthread.h: Include "common-gdbthread.h".
11830 (switch_to_thread): Moved to "common/common-gdbthread.h".
11831
15652511
SDJ
118322017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11833
11834 * Makefile.in (SFILES): Add "common/job-control.c".
11835 (HFILES_NO_SRCDIR): Add "common/job-control.h".
11836 (COMMON_OBS): Add "job-control.o".
11837 * common/job-control.c: New file, with contents from
11838 "gdb/inflow.c".
11839 * common/job-control.h: New file, with contents from "terminal.h".
11840 * fork-child.c: Include "job-control.h".
11841 * inflow.c: Include "job-control.h".
11842 (gdb_setpgid): Move to "common/common-inflow.c".
11843 (_initialize_inflow): Move setting of "job_control" to
11844 "handle_job_control".
11845 * terminal.h (job_control): Moved to "common/common-terminal.h".
11846 (gdb_setpgid): Likewise.
11847 * top.c: Include "job_control.h".
11848 * utils.c: Likewise.
11849 (job_control): Moved to "job-control.c".
11850
2d7cc5c7
PA
118512017-06-07 Pedro Alves <palves@redhat.com>
11852
11853 * Makefile.in (SFILES): Add gdb_regex.c.
11854 (COMMON_OBS): Add gdb_regex.o.
11855 * ada-lang.c (ada_add_standard_exceptions)
11856 (ada_add_exceptions_from_frame, name_matches_regex)
11857 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
11858 parameter type to compiled_regex. Adjust.
11859 (ada_exceptions_list): Use compiled_regex.
11860 * break-catch-throw.c (exception_catchpoint::pattern): Now a
11861 std::unique_ptr<compiled_regex>.
11862 (exception_catchpoint::~exception_catchpoint): Remove regfree
11863 call.
11864 (check_status_exception_catchpoint): Adjust to use compiled_regex.
11865 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
11866 * breakpoint.c (solib_catchpoint::compiled): Now a
11867 std::unique_ptr<compiled_regex>.
11868 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
11869 (check_status_catch_solib): Adjust to use compiled_regex.
11870 (add_solib_catchpoint): Adjust to use compiled_regex.
11871 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
11872 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
11873 compiled_regex reference. Adjust to use it.
11874 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
11875 declaration. Include "gdb_regex.h".
11876 (apropos_cmd): Change regex parameter to compiled_regex reference.
11877 * gdb_regex.c: New file.
11878 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
11879 declarations.
11880 (class compiled_regex): New.
11881 * linux-tdep.c: Include "common/gdb_optional.h".
11882 (struct mapping_regexes): New, factored out from
11883 mapping_is_anonymous_p, and adjusted to use compiled_regex.
11884 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
11885 gdb::optional and remove cleanups. Adjust to compiled_regex.
11886 * probe.c: Include "common/gdb_optional.h".
11887 (collect_probes): Use compiled_regex and gdb::optional and remove
11888 cleanups.
11889 * skip.c: Include "common/gdb_optional.h".
11890 (skiplist_entry::compiled_function_regexp): Now a
11891 gdb::optional<compiled_regex>.
11892 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
11893 (free_skiplist_entry): Remove regfree call.
11894 (compile_skip_regexp, skip_rfunction_p): Adjust to use
11895 compiled_regex and gdb::optional.
11896 * symtab.c: Include "common/gdb_optional.h".
11897 (search_symbols): Use compiled_regex and gdb::optional.
11898 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
11899 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
11900 to gdb_regex.c.
11901
50d6adef
AH
119022017-06-07 Alan Hayward <alan.hayward@arm.com>
11903
11904 * regcache.c (regcache::save): Avoid buffer use.
11905 (regcache::dump): Likewise.
11906
4a8a33c8
AH
119072017-06-07 Alan Hayward <alan.hayward@arm.com>
11908
11909 * sh-tdep.c (sh_pseudo_register_read): Remove
11910 MAX_REGISTER_SIZE.
11911 (sh_pseudo_register_write): Likewise.
11912 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
11913 (sh64_pseudo_register_write): Likewise
11914
d1be909e
AH
119152017-06-07 Alan Hayward <alan.hayward@arm.com>
11916
11917 * aarch64-tdep.c (aarch64_store_return_value): Use
11918 V_REGISTER_SIZE.
11919 (aarch64_pseudo_read_value): Likewise.
11920 (aarch64_pseudo_write): Likewise.
11921
f4a65042
YQ
119222017-06-06 Yao Qi <yao.qi@linaro.org>
11923
11924 * regformats/regdef.h (set_register_cache): Remove the
11925 declaration.
11926
9f7fb0aa
AH
119272017-06-06 Alan Hayward <alan.hayward@arm.com>
11928
11929 * frame.c (frame_unwind_register_signed): Use
11930 frame_unwind_register_value.
11931
e1e01040
PA
119322017-06-06 Pedro Alves <palves@redhat.com>
11933
11934 PR breakpoints/21553
11935 * breakpoint.c (create_breakpoints_sal_default)
11936 (init_breakpoint_sal, create_breakpoint_sal): Use
11937 gdb::unique_xmalloc_ptr for string parameters.
11938 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11939 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
11940 (base_breakpoint_create_breakpoints_sal)
11941 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
11942 (strace_marker_create_breakpoints_sal)
11943 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
11944 string parameters.
11945 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
11946 gdb::unique_xmalloc_ptr for string parameters.
11947 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11948 parameters.
11949
fbe654c8
AH
119502017-06-06 Alan Hayward <alan.hayward@arm.com>
11951
11952 * alpha-tdep.c (alpha_register_to_value): Use
11953 get_frame_register_value.
11954 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
11955
ae0d01d6
AH
119562017-06-06 Alan Hayward <alan.hayward@arm.com>
11957
11958 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
11959 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
11960 (ia64_value_to_register): Likewise.
11961 (ia64_extract_return_value): Likewise.
11962 (ia64_store_return_value): Likewise.
11963 (ia64_push_dummy_call): Likewise.
11964
49cf576c
JB
119652017-06-04 Joel Brobecker <brobecker@adacore.com>
11966
11967 GDB 8.0 released.
11968
26b6a6ab
SM
119692017-06-03 Simon Marchi <simon.marchi@ericsson.com>
11970
11971 * x86-linux-nat.c (struct arch_lwp_info): Remove.
11972
22827c51
SM
119732017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
11974
11975 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
11976 parameter.
11977 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
11978
0e05cf3a
SM
119792017-06-02 Simon Marchi <simon.marchi@ericsson.com>
11980
11981 * event-loop.c (poll_timers): Unallocate timer using delete
11982 instead of xfree.
11983
c1fc2657
SM
119842017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11985
11986 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
11987 (struct breakpoint) <~breakpoint>: New.
11988 (struct watchpoint): Inherit from breakpoint.
11989 <~watchpoint>: New.
11990 <base>: Remove.
11991 (struct tracepoint): Inherit from breakpoint.
11992 <base>: Remove.
11993 * breakpoint.c (longjmp_breakpoint_ops): Remove.
11994 (struct longjmp_breakpoint): Inherit from breakpoint.
11995 <~longjmp_breakpoint>: New.
11996 <base>: Remove.
11997 (new_breakpoint_from_type): Remove casts.
11998 (watchpoint_in_thread_scope): Remove reference to base field.
11999 (watchpoint_del_at_next_stop): Likewise.
12000 (update_watchpoint): Likewise.
12001 (watchpoint_check): Likewise.
12002 (bpstat_check_watchpoint): Likewise.
12003 (set_longjmp_breakpoint): Likewise.
12004 (struct fork_catchpoint): Inherit from breakpoint.
12005 <base>: Remove.
12006 (struct solib_catchpoint): Inherit from breakpoint.
12007 <~solib_catchpoint>: New.
12008 <base>: Remove.
12009 (dtor_catch_solib): Change to ...
12010 (solib_catchpoint::~solib_catchpoint): ... this.
12011 (breakpoint_hit_catch_solib): Remove reference to base field.
12012 (add_solib_catchpoint): Likewise.
12013 (create_fork_vfork_event_catchpoint): Likewise.
12014 (struct exec_catchpoint): Inherit from breakpoint.
12015 <~exec_catchpoint>: New.
12016 <base>: Remove.
12017 (dtor_catch_exec): Change to ...
12018 (exec_catchpoint::~exec_catchpoint): ... this.
12019 (dtor_watchpoint): Change to ...
12020 (watchpoint::~watchpoint): ... this.
12021 (watch_command_1): Remove reference to base field.
12022 (catch_exec_command_1): Likewise.
12023 (base_breakpoint_dtor): Change to ...
12024 (breakpoint::~breakpoint): ... this.
12025 (base_breakpoint_ops): Remove dtor field value.
12026 (longjmp_bkpt_dtor): Change to ...
12027 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
12028 (strace_marker_create_breakpoints_sal): Remove reference to base
12029 field.
12030 (delete_breakpoint): Don't manually call breakpoint destructor.
12031 (create_tracepoint_from_upload): Remove reference to base field.
12032 (trace_pass_set_count): Likewise.
12033 (initialize_breakpoint_ops): Don't initialize
12034 momentary_breakpoint_ops, don't set dtors.
12035 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
12036 <~ada_catchpoint>: New.
12037 <base>: Remove.
12038 (create_excep_cond_exprs): Remove reference to base field.
12039 (dtor_exception): Change to ...
12040 (ada_catchpoint::~ada_catchpoint): ... this.
12041 (dtor_catch_exception): Remove.
12042 (dtor_catch_exception_unhandled): Remove.
12043 (dtor_catch_assert): Remove.
12044 (create_ada_exception_catchpoint): Remove reference to base
12045 field.
12046 (initialize_ada_catchpoint_ops): Don't set dtors.
12047 * break-catch-sig.c (struct signal_catchpoint): Inherit from
12048 breakpoint.
12049 <~signal_catchpoint>: New.
12050 <base>: Remove.
12051 (signal_catchpoint_dtor): Change to ...
12052 (signal_catchpoint::~signal_catchpoint): ... this.
12053 (create_signal_catchpoint): Remove reference to base field.
12054 (initialize_signal_catchpoint_ops): Don't set dtor.
12055 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
12056 from breakpoint.
12057 <~syscall_catchpoint>: New.
12058 <base>: Remove.
12059 (dtor_catch_syscall): Change to ...
12060 (syscall_catchpoint::~syscall_catchpoint): ... this.
12061 (create_syscall_event_catchpoint): Remove reference to base
12062 field.
12063 (initialize_syscall_catchpoint_ops): Don't set dtor.
12064 * break-catch-throw.c (struct exception_catchpoint): Inherit
12065 from breakpoint.
12066 <~exception_catchpoint>: New.
12067 <base>: Remove.
12068 (dtor_exception_catchpoint): Change to ...
12069 (exception_catchpoint::~exception_catchpoint): ... this.
12070 (handle_gnu_v3_exceptions): Remove reference to base field.
12071 (initialize_throw_catchpoint_ops): Don't set dtor.
12072 * ctf.c (ctf_get_traceframe_address): Remove reference to base
12073 field.
12074 * remote.c (remote_get_tracepoint_status): Likewise.
12075 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
12076 * tracefile.c (tracefile_fetch_registers): Likewise.
12077 * tracepoint.c (actions_command): Likewise.
12078 (validate_actionline): Likewise.
12079 (tfind_1): Likewise.
12080 (get_traceframe_location): Likewise.
12081 (find_matching_tracepoint_location): Likewise.
12082 (parse_tracepoint_status): Likewise.
12083 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
12084
3b0871f4
SM
120852017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12086
12087 * breakpoint.c (struct longjmp_breakpoint): New struct.
12088 (is_tracepoint_type): Change return type to bool.
12089 (is_longjmp_type): New function.
12090 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
12091 (set_raw_breakpoint_without_location): Use
12092 new_breakpoint_from_type.
12093 (set_raw_breakpoint): Likewise.
12094
a5e364af
SM
120952017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
12096
12097 * breakpoint.c (new_breakpoint_from_type): New function.
12098 (create_breakpoint_sal): Use new_breakpoint_from_type and
12099 unique_ptr.
12100 (create_breakpoint): Likewise.
12101
ae3b3f34
SM
121022017-05-31 Simon Marchi <simon.marchi@ericsson.com>
12103
12104 * memattr.c (mem_info_command): Rename to ...
12105 (info_mem_command): ... this.
12106 (mem_enable_command): Rename to ...
12107 (enable_mem_command): ... this.
12108 (mem_disable_command): Rename to ...
12109 (disable_mem_command): ... this.
12110 (mem_delete_command): Rename to ...
12111 (delete_mem_command): ... this.
12112 (_initialize_mem): Adjust function names.
12113
13ace077
MM
121142017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12115
12116 * btrace.c (handle_pt_insn_events): New.
12117 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
12118 STATUS. Split into this and ...
12119 (handle_pt_insn_event_flags): ... this.
12120
c56ccc05
MM
121212017-05-31 Markus Metzger <markus.t.metzger@intel.com>
12122
12123 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
12124 and struct pt_insn.resynced.
12125 * configure: Regenerated.
12126 * config.in: Regenerated.
12127
08c3f6d2
TW
121282017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12129
12130 * btrace.c (ftrace_find_call_by_number): New function.
12131 (ftrace_new_function): Store objects, not pointers.
12132 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
12133 ftrace_new_gap, ftrace_update_function,
12134 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
12135 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
12136 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
12137 btrace_ends_with_single_insn, btrace_call_get): Account for
12138 btrace_thread_info::functions now storing objects.
12139 * btrace.h (struct btrace_thread_info): Add constructor.
12140 (struct btrace_thread_info) <functions>: Make std::vector.
12141 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
12142 Initialize with default values.
12143 * record-btrace.c (record_btrace_frame_sniffer): Account for
12144 btrace_thread_info::functions now storing objects.
12145
8ffd39f2
TW
121462017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12147
12148 * btrace.c: Remove typedef bfun_s.
12149 (ftrace_new_gap): Directly add gaps to the list of gaps.
12150 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
12151 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
12152 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
12153 instead of gdb VEC.
12154
4aeb0dfc
TW
121552017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12156
12157 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
12158 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
12159 with btrace_thread_info::next_segment and
12160 btrace_thread_info::prev_segment.
12161 * btrace.h: Remove struct btrace_func_link.
12162 (struct btrace_function): Replace pair of function segment pointers
12163 with pair of indices.
12164 * python/py-record-btrace.c (btpy_call_prev_sibling,
12165 btpy_call_next_sibling): Replace references to
12166 btrace_thread_info::segment with btrace_thread_info::next_segment and
12167 btrace_thread_info::prev_segment.
12168 * record-btrace.c (record_btrace_frame_this_id): Use
12169 btrace_find_call_by_number.
12170
eb8f2b9c
TW
121712017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12172
12173 * btrace.c (ftrace_new_function, ftrace_fixup_level,
12174 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
12175 btrace_insn_next, btrace_insn_prev): Remove references to
12176 btrace_thread_info::flow.
12177 * btrace.h (struct btrace_function): Remove FLOW.
12178
42bfe59e
TW
121792017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12180
12181 * btrace.c (ftrace_find_call_by_number): New function.
12182 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
12183 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
12184 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
12185 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
12186 index.
12187 * btrace.h (struct btrace_function): Turn UP into an index.
12188 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
12189 as an index.
12190 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
12191 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12192 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12193
b54b03bd
TW
121942017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12195
12196 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12197 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12198 ftrace_update_function, ftrace_compute_global_level_offset,
12199 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12200 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12201 btrace_insn_end, btrace_is_empty): Remove references to
12202 btrace_thread_info::begin and btrace_thread_info::end.
12203 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12204 (struct btrace_thread_info) <functions>: Adjust comment.
12205 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12206 btrace_thread_info::begin.
12207
8286623c
TW
122082017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12209
12210 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12211 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12212 ftrace_update_function): Remove arguments that implicitly were always
12213 BTINFO->END.
12214 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12215 Don't pass BTINFO->END.
12216
a0f1b963
TW
122172017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12218
12219 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12220 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12221 btrace_find_insn_by_number): Replace function segment pointer with
12222 index.
12223 (btrace_insn_cmp): Simplify.
12224 * btrace.h: (struct btrace_insn_iterator) Rename index to
12225 insn_index. Replace function segment pointer with index into function
12226 segment vector.
12227 * record-btrace.c (record_btrace_call_history): Replace function
12228 segment pointer use with index.
12229 (record_btrace_frame_sniffer): Retrieve function call segment through
12230 vector.
12231 (record_btrace_set_replay): Remove defunc't safety check.
12232
f158f208
TW
122332017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12234
12235 * btrace.c (btrace_ends_with_single_insn): New function.
12236 (btrace_call_get, btrace_call_number, btrace_call_begin,
12237 btrace_call_end, btrace_call_next, btrace_call_prev,
12238 btrace_find_call_by_number): Use index into call segment vector
12239 instead of pointer.
12240 (btrace_call_cmp): Simplify.
12241 * btrace.h (struct btrace_call_iterator): Replace function call segment
12242 pointer with index into vector.
12243 * record-btrace.c (record_btrace_call_history): Use index instead of
12244 pointer.
12245
521103fd
TW
122462017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12247
12248 * btrace.c (btrace_insn_begin, btrace_insn_end,
12249 btrace_find_insn_by_number): Add btinfo to iterator.
12250 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12251
17b89b34
TW
122522017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12253
12254 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12255 and save pointers directly.
12256 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12257 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12258 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12259 changed signature of functions.
12260 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12261 (btrace_fetch): Remove code that adds btrace_function pointers to
12262 vector of btrace_functions.
12263 (btrace_clear): Simplify freeing vector of btrace_functions.
12264
2b51eddc
TW
122652017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12266
12267 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12268 Replace VEC_* with std::vector functions.
12269 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12270 (struct btrace_thread_info)<functions>: Change type to std::vector.
12271
db6be0d5
SM
122722017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12273
12274 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12275 "Removed targets and native configurations" up. Merge duplicate
12276 "New commands" sub-sections. Add "New options" sub-sections.
12277
b057297a
AH
122782017-05-26 Alan Hayward <alan.hayward@arm.com>
12279
12280 * defs.h (copy_integer_to_size): New declaration.
12281 * findvar.c (copy_integer_to_size): New function.
12282 (do_cint_test): New selftest function.
12283 (copy_integer_to_size_test): Likewise.
12284 (_initialize_findvar): Likewise.
12285 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12286 (mips_fbsd_collect_reg): Use raw_collect_integer.
12287 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12288 (mips64_fill_gregset): Use raw_collect_integer
12289 (mips64_fill_fpregset): Use raw_supply_integer.
12290 * regcache.c (regcache::raw_supply_integer): New function.
12291 (regcache::raw_collect_integer): Likewise.
12292 * regcache.h: (regcache::raw_supply_integer): New declaration.
12293 (regcache::raw_collect_integer): Likewise.
12294
b77b02a5
YQ
122952017-05-24 Yao Qi <yao.qi@linaro.org>
12296
12297 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12298 (COMMON_OBS): Add gdbarch-selftests.o.
12299 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12300 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12301 * gdbarch-selftests.c: New file.
12302 * regcache.h (regcache) <~regcache>: Mark it virtual if
12303 GDB_SELF_TEST.
12304 <raw_write>: Likewise.
12305
e521e87e
YQ
123062017-05-24 Yao Qi <yao.qi@linaro.org>
12307
12308 * regcache.c (current_regcache): Change it to
12309 regcache::current_regcache.
12310 (regcache_observer_target_changed): Update.
12311 (regcache_thread_ptid_changed): Make it a regcache static
12312 method.
12313 (regcache_thread_ptid_changed): Update.
12314 (class regcache_access): New.
12315 (current_regcache_test): Update.
12316 (_initialize_regcache): Update.
12317 * regcache.h: Include forward_list.
12318 (regcache): Declare regcache_thread_ptid_changed and declare
12319 registers_changed_ptid as friend.
12320
d8e07dda
YQ
123212017-05-24 Yao Qi <yao.qi@linaro.org>
12322
12323 * i387-tdep.c (i387_register_to_value): Use register_size
12324 instead of TYPE_LENGTH.
12325 * m68k-tdep.c (m68k_register_to_value): Likewise.
12326
8c8f9122
YQ
123272017-05-24 Yao Qi <yao.qi@linaro.org>
12328
12329 * i387-tdep.c (i387_convert_register_p): Return false if type
12330 code isn't TYPE_CODE_FLT.
12331
68fce50f
YQ
123322017-05-24 Yao Qi <yao.qi@linaro.org>
12333
12334 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12335 length is 4.
12336 (alpha_register_to_value): Remove type length check.
12337 (alpha_value_to_register): Likewise.
12338
88954b49
YQ
123392017-05-24 Yao Qi <yao.qi@linaro.org>
12340
12341 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12342 TYPE_CODE_FLT.
12343
e3ec9b69
YQ
123442017-05-24 Yao Qi <yao.qi@linaro.org>
12345
12346 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12347 TYPE_CODE_FLT or not.
12348
cdd238da
YQ
123492017-05-24 Yao Qi <yao.qi@linaro.org>
12350
12351 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12352 * avr-tdep.c (avr_gdbarch_init): Likewise.
12353 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12354 * cris-tdep.c (cris_gdbarch_init): Likewise.
12355 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12356 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12357 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12358 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12359 * mep-tdep.c (mep_gdbarch_init): Likewise.
12360 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12361 * mips-tdep.c (mips_gdbarch_init): Likewise.
12362 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12363 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12364 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12365 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12366 * v850-tdep.c (v850_gdbarch_init): Likewise.
12367
7a3929c4
YQ
123682017-05-24 Yao Qi <yao.qi@linaro.org>
12369
12370 * selftest-arch.c (tests_with_arch): Call registers_changed
12371 and reinit_frame_cache.
12372 * selftest.c (run_self_tests): Likewise.
12373
f4985dba
YQ
123742017-05-24 Yao Qi <yao.qi@linaro.org>
12375
12376 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12377 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12378
ab20fa4a
YQ
123792017-05-24 Yao Qi <yao.qi@linaro.org>
12380
12381 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12382 set_gdbarch_print_insn.
12383
f532ab94
YQ
123842017-05-24 Yao Qi <yao.qi@linaro.org>
12385
12386 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12387 set_gdbarch_print_insn.
12388
39503f82
YQ
123892017-05-24 Yao Qi <yao.qi@linaro.org>
12390
12391 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12392 set_gdbarch_print_insn.
12393 * arc-tdep.c (arc_gdbarch_init): Likewise.
12394 * arch-utils.c: include dis-asm.h.
12395 (default_print_insn): New function.
12396 * arch-utils.h (default_print_insn): Declare.
12397 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12398 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12399 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12400 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12401 * frv-tdep.c (frv_gdbarch_init): Likewise.
12402 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12403 * gdbarch.sh (print_insn): Use default_print_insn.
12404 * gdbarch.c: Regenerated.
12405 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12406 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12407 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12408 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12409 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12410 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12411 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12412 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12413 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12414 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12415 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12416 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12417 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12418 * mt-tdep.c (mt_gdbarch_init): Likewise.
12419 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12420 * nios2-tdep.c (nios2_print_insn): Remove.
12421 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12422 * rx-tdep.c (rx_gdbarch_init): Likewise.
12423 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12424 * score-tdep.c (score_print_insn): Remove.
12425 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12426 * sh-tdep.c (sh_gdbarch_init): Likewise.
12427 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12428 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12429 * tic6x-tdep.c (tic6x_print_insn): Remove.
12430 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12431 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12432 * v850-tdep.c (v850_gdbarch_init): Likewise.
12433 * vax-tdep.c (vax_gdbarch_init): Likewise.
12434 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12435 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12436
f7241d4f
JB
124372017-05-23 John Baldwin <jhb@FreeBSD.org>
12438
12439 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12440 (MIPS_FP0_REGNUM): Remove.
12441 (MIPS_FSR_REGNUM): Remove.
12442 (mips_fbsd_supply_fpregs): Use mips_regnum.
12443 (mips_fbsd_supply_gregs): Likewise.
12444 (mips_fbsd_collect_fpregs): Likewise.
12445 (mips_fbsd_collect_gregs): Likewise.
12446
d489d81d
JB
124472017-05-23 John Baldwin <jhb@FreeBSD.org>
12448
12449 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12450 (getpfpregs_supplies): New function.
12451 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12452 getfpregs_supplies.
12453 (mips_fbsd_store_inferior_registers): Likewise.
12454
e11b3cdc
PA
124552017-05-22 Pedro Alves <palves@redhat.com>
12456
12457 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12458 maintainer.
12459
0f068fb5
AH
124602017-05-22 Alan Hayward <alan.hayward@arm.com>
12461
12462 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12463 (store_register): Likewise.
12464 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12465 (get_decimal_float_return_value): Likewise.
12466 (do_ppc_sysv_return_value): Likewise.
12467 (ppc64_sysv_abi_push_integer): Likewise.
12468 (ppc64_sysv_abi_push_freg): Likewise.
12469 (ppc64_sysv_abi_return_value_base): Likewise.
12470 (ppc64_sysv_abi_return_value): Likewise.
12471 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12472 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12473 * rs6000-nat.c: Likewise.
12474 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12475 (rs6000_value_to_register): Likewise.
12476 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12477
e6cf65f2
TT
124782017-05-21 Tom Tromey <tom@tromey.com>
12479
12480 PR rust/21466:
12481 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12482 arrays as "[T]", not "[T; ]".
12483
43cc5389
TT
124842017-05-19 Tom Tromey <tom@tromey.com>
12485
12486 PR rust/21484:
12487 * rust-lang.c (exp_descriptor_rust): New function.
12488 (rust_language_defn): Use it.
12489 * p-lang.c (pascal_language_defn): Update.
12490 * opencl-lang.c (opencl_language_defn): Update.
12491 * objc-lang.c (objc_language_defn): Update.
12492 * m2-lang.c (m2_language_defn): Update.
12493 * language.h (struct language_defn)
12494 <la_watch_location_expression>: New member.
12495 * language.c (unknown_language_defn, auto_language_defn)
12496 (local_language_defn): Update.
12497 * go-lang.c (go_language_defn): Update.
12498 * f-lang.c (f_language_defn): Update.
12499 * d-lang.c (d_language_defn): Update.
12500 * c-lang.h (c_watch_location_expression): Declare.
12501 * c-lang.c (c_watch_location_expression): New function.
12502 (c_language_defn, cplus_language_defn, asm_language_defn)
12503 (minimal_language_defn): Use it.
12504 * breakpoint.c (watch_command_1): Call
12505 la_watch_location_expression.
12506 * ada-lang.c (ada_language_defn): Update.
12507
7a6e7fcc
RO
125082017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12509
6e7e1744
RO
12510 PR tui/21482
12511 * gdb_curses.h (NOMACROS): Define.
12512 (NCURSES_NOMACROS): Define.
12513
125142017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12515
12516 PR tui/21482
7a6e7fcc
RO
12517 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12518 arg to char *.
12519 * tui/tui-wingeneral.c (box_win): Likewise.
12520 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12521 (tui_show_source_line): Likewise.
12522 (tui_show_exec_info_content): Likewise.
12523
1933fd8e
VM
125242017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12525
12526 * sparc-tdep.c (sparc_structure_return_p)
12527 (sparc_arg_on_registers_p): New functions.
12528 (sparc32_store_arguments): Use them.
12529 * sparc64-tdep.c (sparc64_16_byte_align_p)
12530 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12531 Handle TYPE_CODE_ARRAY.
12532
21873064
YQ
125332017-05-17 Yao Qi <yao.qi@linaro.org>
12534
12535 * cli/cli-decode.c (add_alias_cmd): New function.
12536 * command.h (add_alias_cmd): Declare.
12537 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
12538 instead call add_alias_cmd.
12539
2b351b19
PA
125402017-05-17 Pedro Alves <palves@redhat.com>
12541
12542 * Makefile.in (nat_extra_makefile_frag): Rename to ...
12543 (nat_makefile_frag): ... this. All references updated.
12544 * configure.ac: Likewise.
12545 * configure.nat: Likewise. Enhance comments.
12546 * configure: Regenerate.
12547
5f2ad7a3
RO
125482017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12549
12550 * procfs.c (procfs_create_inferior): Change prototype to match
12551 definition.
12552
adf3dde5
EZ
125532017-05-13 Eli Zaretskii <eliz@gnu.org>
12554
12555 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
12556 C++ compiler warning.
12557
6830f270
TT
125582017-05-12 Tom Tromey <tom@tromey.com>
12559
12560 PR rust/21483:
12561 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
12562 recurse, just call value_struct_elt directly.
12563
68f2f2e3
TT
125642017-05-12 Tom Tromey <tom@tromey.com>
12565
12566 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
12567 OP_RUST_ARRAY>: Fix.
12568
256afbc2
TT
125692017-05-12 Tom Tromey <tom@tromey.com>
12570
12571 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
12572
94bb8dfe
YQ
125732017-05-09 Yao Qi <yao.qi@linaro.org>
12574
12575 * regcache.c: Include <forward_list>.
12576 (struct regcache_list): Remove.
12577 (current_regcache): Update.
12578 (get_thread_arch_aspace_regcache): Update for std::forward_list.
12579 (regcache_thread_ptid_changed): Likewise.
12580 (registers_changed_ptid): Likewise.
12581 (current_regcache_size): Likewise.
12582
8248946c
YQ
125832017-05-09 Yao Qi <yao.qi@linaro.org>
12584
12585 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
12586 (current_regcache_size): New function.
12587 (current_regcache_test): New function.
12588 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
12589
313c5961
AH
125902017-05-08 Alan Hayward <alan.hayward@arm.com>
12591
12592 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
12593 (print_gp_register_row): Use get_frame_register_value.
12594
27bfc1d1
AH
125952017-05-08 Alan Hayward <alan.hayward@arm.com>
12596
12597 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
12598 (mips_supply_fpregset): Likewise.
12599 (mips64_supply_gregset): Likewise.
12600
146e6c5c
AH
126012017-05-08 Alan Hayward <alan.hayward@arm.com>
12602
12603 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
12604 regcache->raw_supply_zeroed.
12605
e50f25ec
SDJ
126062017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12607
12608 * configure.nat: Rearrange 'case' statements to match
12609 host before cpu.
12610
21ea5acd
SDJ
126112017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12612
12613 * Makefile.in: Remove "@host_makefile_frag@". Add variables
12614 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
12615 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
12616 "@nat_extra_makefile_frag@".
12617 (Makefile): Remove dependency on "@frags@".
12618 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
12619 (data-directory/Makefile): Likewise.
12620 * config/aarch64/linux.mh: Deleted; moved contents to
12621 "gdb/configure.nat".
12622 * config/alpha/alpha-linux.mh: Likewise.
12623 * config/alpha/nbsd.mh: Likewise.
12624 * config/arm/linux.mh: Likewise.
12625 * config/arm/nbsdelf.mh: Likewise.
12626 * config/i386/cygwin.mh: Likewise.
12627 * config/i386/cygwin64.mh: Likewise.
12628 * config/i386/darwin.mh: Likewise.
12629 * config/i386/fbsd.mh: Likewise.
12630 * config/i386/fbsd64.mh: Likewise.
12631 * config/i386/go32.mh: Likewise.
12632 * config/i386/i386gnu.mh: Likewise.
12633 * config/i386/i386sol2.mh: Likewise.
12634 * config/i386/linux.mh: Likewise.
12635 * config/i386/linux64.mh: Likewise.
12636 * config/i386/mingw.mh: Likewise.
12637 * config/i386/mingw64.mh: Likewise.
12638 * config/i386/nbsd64.mh: Likewise.
12639 * config/i386/nbsdelf.mh: Likewise.
12640 * config/i386/nto.mh: Likewise.
12641 * config/i386/obsd.mh: Likewise.
12642 * config/i386/obsd64.mh: Likewise.
12643 * config/i386/sol2-64.mh: Likewise.
12644 * config/ia64/linux.mh: Likewise.
12645 * config/m32r/linux.mh: Likewise.
12646 * config/m68k/linux.mh: Likewise.
12647 * config/m68k/nbsdelf.mh: Likewise.
12648 * config/m68k/obsd.mh: Likewise.
12649 * config/m88k/obsd.mh: Likewise.
12650 * config/mips/fbsd.mh: Likewise.
12651 * config/mips/linux.mh: Likewise.
12652 * config/mips/nbsd.mh: Likewise.
12653 * config/mips/obsd64.mh: Likewise.
12654 * config/pa/linux.mh: Likewise.
12655 * config/pa/nbsd.mh: Likewise.
12656 * config/pa/obsd.mh: Likewise.
12657 * config/powerpc/aix.mh: Likewise.
12658 * config/powerpc/fbsd.mh: Likewise.
12659 * config/powerpc/linux.mh: Likewise.
12660 * config/powerpc/nbsd.mh: Likewise.
12661 * config/powerpc/obsd.mh: Likewise.
12662 * config/powerpc/ppc64-linux.mh: Likewise.
12663 * config/powerpc/spu-linux.mh: Likewise.
12664 * config/s390/linux.mh: Likewise.
12665 * config/sh/nbsd.mh: Likewise.
12666 * config/sparc/fbsd.mh: Likewise.
12667 * config/sparc/linux.mh: Likewise.
12668 * config/sparc/linux64.mh: Likewise.
12669 * config/sparc/nbsd64.mh: Likewise.
12670 * config/sparc/nbsdelf.mh: Likewise.
12671 * config/sparc/obsd64.mh: Likewise.
12672 * config/sparc/sol2.mh: Likewise.
12673 * config/tilegx/linux.mh: Likewise.
12674 * config/vax/nbsdelf.mh: Likewise.
12675 * config/vax/obsd.mh: Likewise.
12676 * config/xtensa/linux.mh: Likewise.
12677 * config/i386/i386gnu.mn: New file, with excerpts from
12678 "config/i386/i386gnu.mh".
12679 * configure: Regenerate.
12680 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
12681 *.mh files under "gdb/config".
12682 * configure.nat: New file, with contents from the
12683 "gdb/config/*/*.mh" files.
12684
7ed1acaf
TW
126852017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
12686
12687 * btrace.c (btrace_clear): Free insn vector.
12688
e13cb306
PA
126892017-05-05 Pedro Alves <palves@redhat.com>
12690
12691 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
12692 * configure: Regenerate.
12693
5ed8105e
PA
126942017-05-04 Pedro Alves <palves@redhat.com>
12695
12696 * Makefile.in (SFILES): Add progspace-and-thread.c.
12697 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
12698 (COMMON_OBS): Add progspace-and-thread.o.
12699 * breakpoint.c: Include "progspace-and-thread.h".
12700 (update_inserted_breakpoint_locations)
12701 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
12702 Use scoped_restore_current_pspace_and_thread.
12703 (create_std_terminate_master_breakpoint): Use
12704 scoped_restore_current_program_space.
12705 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
12706 (print_breakpoint_location): Use
12707 scoped_restore_current_program_space.
12708 (bp_loc_is_permanent): Use
12709 scoped_restore_current_pspace_and_thread.
12710 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
12711 (download_tracepoint_locations): Use
12712 scoped_restore_current_pspace_and_thread.
12713 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
12714 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
12715 (enum step_over_calls_kind): Moved from inferior.h.
12716 (class scoped_restore_current_thread): New class.
12717 * gdbthread.h (make_cleanup_restore_current_thread): Delete
12718 declaration.
12719 (scoped_restore_current_thread): New class.
12720 * infcmd.c: Include "common/gdb_optional.h".
12721 (continue_1, proceed_after_attach): Use
12722 scoped_restore_current_thread.
12723 (notice_new_inferior): Use scoped_restore_current_thread.
12724 * inferior.c: Include "progspace-and-thread.h".
12725 (restore_inferior, save_current_inferior): Delete.
12726 (add_inferior_command, clone_inferior_command): Use
12727 scoped_restore_current_pspace_and_thread.
12728 * inferior.h (scoped_restore_current_inferior): New class.
12729 * infrun.c: Include "progspace-and-thread.h" and
12730 "common/gdb_optional.h".
12731 (follow_fork_inferior): Use
12732 scoped_restore_current_pspace_and_thread.
12733 (scoped_restore_exited_inferior): New class.
12734 (handle_vfork_child_exec_or_exit): Use
12735 scoped_restore_exited_inferior,
12736 scoped_restore_current_pspace_and_thread,
12737 scoped_restore_current_thread and scoped_restore.
12738 (fetch_inferior_event): Use scoped_restore_current_thread.
12739 * linespec.c (decode_line_full, decode_line_1): Use
12740 scoped_restore_current_program_space.
12741 * mi/mi-main.c: Include "progspace-and-thread.h".
12742 (exec_continue): Use scoped_restore_current_thread.
12743 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
12744 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
12745 * proc-service.c (ps_pglobal_lookup): Use
12746 scoped_restore_current_program_space.
12747 * progspace-and-thread.c: New file.
12748 * progspace-and-thread.h: New file.
12749 * progspace.c (release_program_space, clone_program_space): Use
12750 scoped_restore_current_program_space.
12751 (restore_program_space, save_current_program_space)
12752 (save_current_space_and_thread): Delete.
12753 (switch_to_program_space_and_thread): Moved to
12754 progspace-and-thread.c.
12755 * progspace.h (save_current_program_space)
12756 (save_current_space_and_thread): Delete declarations.
12757 (scoped_restore_current_program_space): New class.
12758 * remote.c (remote_btrace_maybe_reopen): Use
12759 scoped_restore_current_thread.
12760 * symtab.c: Include "progspace-and-thread.h".
12761 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
12762 * thread.c (print_thread_info_1): Use
12763 scoped_restore_current_thread.
12764 (struct current_thread_cleanup): Delete.
12765 (do_restore_current_thread_cleanup)
12766 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
12767 (scoped_restore_current_thread::~scoped_restore_current_thread):
12768 ... this new dtor.
12769 (make_cleanup_restore_current_thread): Rename/convert to ...
12770 (scoped_restore_current_thread::scoped_restore_current_thread):
12771 ... this new ctor.
12772 (thread_apply_all_command): Use scoped_restore_current_thread.
12773 (thread_apply_command): Use scoped_restore_current_thread.
12774 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
12775 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
12776
f6223dbb
PA
127772017-05-04 Pedro Alves <palves@redhat.com>
12778
12779 * thread.c (make_cleanup_restore_current_thread): Move
12780 find_thread_ptid call before the is_stopped call. Assert that the
12781 thread is found. Replace is_stopped call by checking the thread's
12782 state directly. Remove unnecessary NULL-thread check.
12783
3c3ae77e
PA
127842017-05-04 Pedro Alves <palves@redhat.com>
12785
12786 * corelow.c (thread_section_name): New class.
12787 (get_core_register_section, get_core_siginfo): Use it.
12788
45eba0ab
AA
127892017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
12790
12791 * corelow.c (sniff_core_bfd): Remove extra semicolon.
12792 (get_core_register_section): Remove xfree of NULL pointer.
12793
f81fdd35
AH
127942017-05-03 Alan Hayward <alan.hayward@arm.com>
12795
12796 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
12797 * regcache.c (regcache::raw_supply_zeroed): New function.
12798 * regcache.h (regcache::raw_supply_zeroed): New declaration.
12799
35837774
SM
128002017-05-03 Simon Marchi <simon.marchi@ericsson.com>
12801
12802 * gdbarch.sh: Remove commented out definition of
12803 TARGET_CHAR_BIT.
12804 * gdbarch.h: Re-generate.
12805
c94fee56
SDJ
128062017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
12807
12808 * configure: Regenerate.
12809
d17f7b36
SM
128102017-05-02 Simon Marchi <simon.marchi@ericsson.com>
12811
12812 * solib-target.c (solib_target_relocate_section_addresses):
12813 Remove num_section_bases, num_bases, segment_bases variables.
12814
b560ebd6
SM
128152017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12816
12817 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
12818
f2f46dfc
SM
128192017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12820
12821 * solib-target.c: Include <vector>
12822 (struct lm_info_target) <~lm_info_target>: Remove.
12823 <segment_bases, section_bases>: Change type to
12824 std::vector<CORE_ADDR>.
12825 (library_list_start_segment, library_list_start_section,
12826 library_list_end_library,
12827 solib_target_relocate_section_addresses): Adjust.
12828
a0ff9e1a
SM
128292017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12830
12831 * gdbarch.sh (software_single_step): Change return type to
12832 std::vector<CORE_ADDR>.
12833 * gdbarch.c, gdbarch.h: Re-generate.
12834 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
12835 Adjust.
12836 (arm_deal_with_atomic_sequence_raw): Adjust.
12837 (thumb_get_next_pcs_raw): Adjust.
12838 (arm_get_next_pcs_raw): Adjust.
12839 (arm_get_next_pcs): Adjust.
12840 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
12841 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
12842 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
12843 (alpha_software_single_step): Adjust.
12844 * alpha-tdep.h (alpha_software_single_step): Adjust.
12845 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
12846 * arm-tdep.c (arm_software_single_step): Adjust.
12847 (arm_breakpoint_kind_from_current_state): Adjust.
12848 * arm-tdep.h (arm_software_single_step): Adjust.
12849 * breakpoint.c (insert_single_step_breakpoint): Adjust.
12850 * cris-tdep.c (cris_software_single_step): Adjust.
12851 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
12852 (micromips_deal_with_atomic_sequence): Adjust.
12853 (deal_with_atomic_sequence): Adjust.
12854 (mips_software_single_step): Adjust.
12855 * mips-tdep.h (mips_software_single_step): Adjust.
12856 * moxie-tdep.c (moxie_software_single_step): Adjust.
12857 * nios2-tdep.c (nios2_software_single_step): Adjust.
12858 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
12859 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
12860 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
12861 * s390-linux-tdep.c (s390_software_single_step): Adjust.
12862 * sparc-tdep.c (sparc_software_single_step): Adjust.
12863 * spu-tdep.c (spu_software_single_step): Adjust.
12864 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
12865
ea480a30
SM
128662017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12867
12868 * gdbarch.sh: Use semi-colon as field separator instead of colon.
12869 * gdbarch.h: Re-generate.
12870
d050f7d7
TW
128712017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12872
12873 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
12874 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
12875 * python/py-instruction.c, python/py-instruction.h: New file.
12876 * python/py-record.c: Add py-instruction.h include.
12877 (gdbpy_initialize_record): Make gdb.Instruction a super class of
12878 gdb.RecordInstruction.
12879 * python/python-internal.h: Add gdbpy_initialize_instruction
12880 declaration.
12881 * python/python.c (do_start_initialization): Add
12882 gdbpy_initialize_instruction.
12883
14f819c8
TW
128842017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12885
12886 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
12887 Remove.
12888 (btrace_func_from_recpy_func): New function.
12889 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
12890 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
12891 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
12892 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
12893 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
12894 Also, use new helper functions.
12895 (btpy_list_item): Use new helper functions.
12896 (recpy_bt_function_call_history): Use new type name.
12897 (btpy_call_getset): Remove.
12898 (gdbpy_initialize_btrace): Remove code to initialize
12899 gdb.BtraceFunctionCall.
12900 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
12901 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
12902 recpy_bt_func_prev, recpy_bt_func_next): New export.
12903 * python/py-record.c (recpy_func_type): New static object.
12904 (recpy_func_new, recpy_func_level, recpy_func_symbol,
12905 recpy_func_instructions, recpy_func_up, recpy_func_prev,
12906 recpy_func_next): New function.
12907 (recpy_element_hash, recpy_element_richcompare): Updated comment.
12908 (recpy_func_getset): New static object.
12909 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
12910 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
12911
0ed5da75
TW
129122017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12913
12914 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
12915 (btpy_object, btpy_insn_type, btpy_new): Remove.
12916 (btpy_list_object): Use gdb.RecordInstruction type instead of
12917 gdb.BtraceInstruction type.
12918 (btrace_insn_from_recpy_insn): New function.
12919 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
12920 btpy_new.
12921 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
12922 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
12923 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
12924 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
12925 instead of btpy_object.
12926 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12927 btpy_insn_data, btpy_insn_decode): Rename to ...
12928 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
12929 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
12930 recpy_bt_insn_decode): This. Also, use new helper functions.
12931 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
12932 recpy_insn_type.
12933 (btpy_insn_getset): Remove.
12934 (gdbpy_initialize_btrace): Remove code to initialize
12935 gdb.BtraceInstruction. Use recpy_element_object.
12936 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
12937 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
12938 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
12939 * python/py-record.c (recpy_insn_type): New static object.
12940 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
12941 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
12942 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
12943 New function.
12944 (recpy_insn_getset): New static object.
12945 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
12946 * python/py-record.h (recpy_element_object): New typedef.
12947 (recpy_insn_type, recpy_insn_new): New export.
12948
913aeadd
TW
129492017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12950
12951 * py-record-btrace.c (btpy_insn_new): Removed.
12952 (btpy_insn_or_gap_new): New function.
12953 (btpy_insn_error): Removed.
12954 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12955 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
12956 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
12957 btpy_insn_or_gap_new instead of btpy_insn_new.
12958 (btpy_insn_getset): Remove btpy_insn_error.
12959 * py-record.c (recpy_gap_type): New static object.
12960 (recpy_gap_object): New typedef.
12961 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
12962 recpy_gap_reason_string): New function.
12963 (recpy_gap_getset): New static object.
12964 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
12965 * py-record.h (recpy_gap_new): New export.
12966
a3be24ad
TW
129672017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12968
12969 * python/py-record.c (recpy_ptid): Remove.
12970 (recpy_record_getset): Remove recpy_ptid.
12971
ae20e79a
TW
129722017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12973
12974 * btrace.c (btrace_fetch): Set inferior_ptid.
12975 * python/py-record-btrace.c: Add "py-record.h" include.
12976 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
12977 recpy_bt_end, recpy_bt_instruction_history,
12978 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
12979 in gdb.Record object instead of current ptid.
12980 * python/py-record.c: Include new "py-record.h" file.
12981 (recpy_record_object): Moved to py-record.h.
12982 * python/py-record.h: New file.
12983
8d0050ea
TW
129842017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12985
12986 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
12987 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
12988 indentation.
12989
3f380b50
JB
129902017-05-01 Joel Brobecker <brobecker@adacore.com>
12991
12992 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
12993 the past maintainers section.
12994
07495424
YQ
129952017-04-28 Yao Qi <yao.qi@linaro.org>
12996
12997 * infcmd.c (get_return_value): Use regcache ctor, and remove
12998 cleanup.
12999
deb1fa3e
YQ
130002017-04-28 Yao Qi <yao.qi@linaro.org>
13001 Pedro Alves <palves@redhat.com>
13002
13003 * regcache.c (regcache::regcache): New tag dispatch ctor.
13004 (do_cooked_read): Moved above.
13005 (regcache_dup): Use the tag dispatch ctor..
13006 * regcache.h (regcache): Declare ctor, delete copy ctor and
13007 assignment operator, remove friend regcache_dup.
13008
b421c83c
YQ
130092017-04-28 Yao Qi <yao.qi@linaro.org>
13010
13011 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
13012 call method save instead of regcache_cpy.
13013 * regcache.h (struct regcache): Make regcache_dup a friend.
13014
ef79d9a3
YQ
130152017-04-28 Yao Qi <yao.qi@linaro.org>
13016
13017 * regcache.c (struct regcache): Move to regcache.h
13018 (regcache::arch): New method.
13019 (regcache_get_ptid): Update.
13020 (get_regcache_arch): Call arch method.
13021 (get_regcache_aspace): Call method aspace.
13022 (register_buffer): Change it to method.
13023 (regcache_save): Change it to regcache::save.
13024 (regcache_restore): Likewise.
13025 (regcache_cpy_no_passthrough): Remove the declaration.
13026 (regcache_cpy): Call methods restore and cpy_no_passthrough.
13027 (regcache_cpy_no_passthrough): Change it to method
13028 cpy_no_passthrough.
13029 (regcache_register_status): Change it to method
13030 get_register_status.
13031 (regcache_invalidate): Change it to method invalidate.
13032 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
13033 (regcache_raw_update): Change it to method raw_update.
13034 (regcache_raw_read): Likewise.
13035 (regcache_raw_read_signed): Likewise.
13036 (regcache_raw_read_unsigned): Likewise.
13037 (regcache_raw_write_signed): Likewise.
13038 (regcache_raw_write_unsigned): Likewise.
13039 (regcache_cooked_read): Likewise.
13040 (regcache_cooked_read_value): Likewise.
13041 (regcache_cooked_read_signed): Likewise.
13042 (regcache_cooked_read_unsigned): Likewise.
13043 (regcache_cooked_write_signed): Likewise.
13044 (regcache_cooked_write_unsigned): Likewise.
13045 (regcache_raw_set_cached_value): Likewise.
13046 (regcache_raw_write): Likewise.
13047 (regcache_cooked_write): Likewise.
13048 (regcache_xfer_part): Likewise.
13049 (regcache_raw_read_part): Likewise.
13050 (regcache_raw_write_part): Likewise.
13051 (regcache_cooked_read_part): Likewise.
13052 (regcache_cooked_write_part): Likewise.
13053 (regcache_raw_supply): Likewise.
13054 (regcache_raw_collect): Likewise.
13055 (regcache_transfer_regset): Likewise.
13056 (regcache_supply_regset): Likewise.
13057 (regcache_collect_regset): Likewise.
13058 (regcache_debug_print_register): Likewise.
13059 (enum regcache_dump_what): Move it to regcache.h.
13060 (regcache_dump): Change it to method dump.
13061 * regcache.h (enum regcache_dump_what): New.
13062 (class regcache): New.
13063 * target.c (target_fetch_registers): Call method
13064 debug_print_register.
13065 (target_store_registers): Likewise.
13066
f8fdb78e
SM
130672017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13068
13069 * windows-nat.c (struct lm_info_windows): Initialize field.
13070 (windows_make_so): Allocate lm_info_windows with new.
13071 (windows_free_so): Free lm_info_windows with delete.
13072
9ccbfd7b
SM
130732017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13074
13075 * solib-darwin.c (struct lm_info_darwin): Initialize field.
13076 (darwin_current_sos): Allocate lm_info_darwin with new, remove
13077 cleanup.
13078 (darwin_free_so): Free lm_info_darwin with delete.
13079
76e75227
SM
130802017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13081
13082 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
13083 <l_addr_p>: Change type to bool.
13084 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
13085 (svr4_free_so): Free lm_info_svr4 with delete.
13086 (svr4_copy_library_list): Replace memcpy with call to copy
13087 constructor.
13088 (library_list_start_library, svr4_default_sos): Allocate
13089 lm_info_svr4 with new.
13090
51046d9e
SM
130912017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13092
13093 * solib-target.c (struct lm_info_target): Add destructor,
13094 initialize fields.
13095 <name>: Change type to std::string.
13096 (library_list_start_library): Allocate lm_info_target with new.
13097 (solib_target_free_library_list): Free lm_info_target with
13098 delete.
13099 (solib_target_current_sos): Adapt to std::string.
13100 (solib_target_free_so): Free lm_info_target with delete.
13101
4023ae76
SM
131022017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13103
13104 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
13105 fields.
13106 (frv_current_sos): Allocate lm_info_frv with new.
13107 (frv_relocate_main_executable): Free lm_info_frv with delete,
13108 allocate with new.
13109 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
13110
af43057b
SM
131112017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13112
13113 * solib-frv.c (struct lm_info_frv): Fix indentation.
13114
b0911207
SM
131152017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13116
13117 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
13118 map field.
13119 (dsbt_current_sos): Allocate lm_info_dsbt with new.
13120 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
13121 and allocate with new.
13122 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
13123
6c401f72
SM
131242017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13125
13126 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
13127 <filename, member_name>: Change type to std::string.
13128 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
13129 (library_list_start_library): Allocate lm_info_aix with new.
13130 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
13131 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
13132 with copy constructor.
13133
d0e449a1
SM
131342017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13135
13136 * solist.h (struct lm_info): Remove.
13137 (struct lm_info_base): New class.
13138 (struct so_list) <lm_info>: Change type to lm_info_base *.
13139 * nto-tdep.c (struct lm_info): Remove.
13140 (lm_addr): Adjust.
13141 * solib-aix.c (struct lm_info): Rename to ...
13142 (struct lm_info_aix): ... this. Extend lm_info_base.
13143 (lm_info_p): Rename to ...
13144 (lm_info_aix_p): ... this, and adjust.
13145 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
13146 solib_aix_parse_libraries, library_list_start_library,
13147 solib_aix_free_library_list, solib_aix_parse_libraries,
13148 solib_aix_get_library_list,
13149 solib_aix_relocate_section_addresses, solib_aix_free_so,
13150 solib_aix_get_section_offsets,
13151 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
13152 Adjust.
13153 (struct solib_aix_inferior_data) <library_list>: Adjust.
13154 * solib-darwin.c (struct lm_info): Rename to ...
13155 (struct lm_info_darwin): ... this. Extend lm_info_base.
13156 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
13157 * solib-dsbt.c (struct lm_info): Rename to ...
13158 (struct lm_info_dsbt): ... this. Extend lm_info_base.
13159 (struct dsbt_info) <main_executable_lm_info): Adjust.
13160 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
13161 dsbt_relocate_section_addresses): Adjust.
13162 * solib-frv.c (struct lm_info): Rename to ...
13163 (struct lm_info_frv): ... this. Extend lm_info_base.
13164 (main_executable_lm_info): Adjust.
13165 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
13166 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
13167 find_canonical_descriptor_in_load_object,
13168 frv_fdpic_find_canonical_descriptor): Adjust.
13169 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
13170 to lm_info_svr4.
13171 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
13172 svr4_clear_so, svr4_copy_library_list,
13173 library_list_start_library, svr4_default_sos, svr4_read_so_list,
13174 svr4_current_sos, svr4_fetch_objfile_link_map,
13175 solist_update_incremental): Adjust.
13176 * solib-svr4.h (struct lm_info_svr4): Move here from
13177 solib-svr4.c.
13178 * solib-target.c (struct lm_info): Rename to ...
13179 (struct lm_info_target): ... this. Extend lm_info_base.
13180 (lm_info_p): Rename to ...
13181 (lm_info_target_p): ... this.
13182 (solib_target_parse_libraries, library_list_start_segment,
13183 library_list_start_section, library_list_start_library,
13184 library_list_end_library, solib_target_free_library_list,
13185 solib_target_current_sos, solib_target_free_so,
13186 solib_target_relocate_section_addresses): Adjust.
13187 * windows-nat.c (struct lm_info): Rename to ...
13188 (struct lm_info_windows): ... this. Extend lm_info_base.
13189 (windows_make_so, handle_load_dll, handle_unload_dll,
13190 windows_xfer_shared_libraries): Adjust.
13191
434a4023
SM
131922017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13193
13194 * solib-darwin.c (struct darwin_so_list): Remove.
13195 (darwin_current_sos): Allocate an so_list object instead of a
13196 darwin_so_list, separately allocate an lm_info object.
13197 (darwin_free_so): Free lm_info.
13198
428544e8
JB
131992017-04-28 John Baldwin <jhb@FreeBSD.org>
13200
13201 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13202 with fprintf_filtered.
13203
4621115f
YQ
132042017-04-28 Yao Qi <yao.qi@linaro.org>
13205
13206 * regcache.c (regcache::regcache): New function.
13207 (regcache::~regcache): New function.
13208 (regcache_xmalloc_1): Remove.
13209 (regcache_xmalloc): Call new regcache.
13210 (regcache_xfree): Call delete regcache.
13211 (get_thread_arch_aspace_regcache): Call new regcache.
13212
339053c2
YQ
132132017-04-28 Yao Qi <yao.qi@linaro.org>
13214
13215 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13216 lwp instead of ptid_get_lwp.
13217
7974a605
YQ
132182017-04-28 Yao Qi <yao.qi@linaro.org>
13219
13220 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13221 lwp_info instead of getting from inferior_ptid.
13222
e15c3eb4
KS
132232017-04-27 Keith Seitz <keiths@redhat.com>
13224
13225 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13226 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13227 (CV_CONVERSION_BADNESS): Define.
13228 (rank_one_type): Remove overly restrictive rvalue reference
13229 rank checks.
13230 Add cv-qualifier checks and subranks for type equality.
13231 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13232 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13233 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13234
72bc1d24
SM
132352017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13236
13237 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13238 count when creating the object.
13239
55bcecda
UW
132402017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13241 Ulrich Weigand <uweigand@de.ibm.com>
13242
13243 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13244 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13245 is used in AIX.
13246 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13247 (process_xcoff_symbol): Likewise.
13248 (scan_xcoff_symtab): Likewise.
13249
5c99fcf8
AH
132502017-04-26 Alan Hayward <alan.hayward@arm.com>
13251
13252 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13253 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13254 (ia64_access_reg): Use get_frame_register_unsigned.
13255 (ia64_access_rse_reg): Likewise.
13256 (ia64_libunwind_frame_prev_register): Likewise.
13257
b41c5a85
JW
132582017-04-26 Jiong Wang <jiong.wang@arm.com>
13259
13260 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13261 * gdbarch.c: Regenerated.
13262 * gdbarch.h: Regenerated.
13263 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13264 visibility external.
13265 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13266 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13267 (enum cfa_how_kind): Move to ...
13268 (struct dwarf2_frame_state_reg_info): Likewise.
13269 (struct dwarf2_frame_state): Likewise.
13270 * dwarf2-frame.h: ... here.
13271 (dwarf2_frame_state_alloc_regs): New declaration.
13272 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13273 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13274
c185f580
AH
132752017-04-26 Alan Hayward <alan.hayward@arm.com>
13276
13277 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13278 regcache_raw_read_unsigned.
13279 (xtensa_pseudo_register_write): Likewise.
13280
19c45594
AH
132812017-04-26 Alan Hayward <alan.hayward@arm.com>
13282
13283 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13284 (nds32_pseudo_register_write): Likewise.
13285
4658f12e
YQ
132862017-04-25 Yao Qi <yao.qi@linaro.org>
13287
13288 * regcache.c (struct regcache) <readonly_p>: Change its type
13289 to bool.
13290 (regcache_xmalloc_1): Update parameter type and callers update.
13291
d581dda8
YQ
132922017-04-25 Yao Qi <yao.qi@linaro.org>
13293
13294 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13295 set_gdbarch_wchar_bit.
13296 * arm-tdep.c (arm_gdbarch_init): Likewise.
13297
debed3db
PA
132982017-04-25 Pedro Alves <palves@redhat.com>
13299
13300 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13301 (BothAreRelocatable, memcopy, memmove): Don't define.
13302 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13303 macros.
13304
b0b92aeb
PA
133052017-04-25 Pedro Alves <palves@redhat.com>
13306
13307 * common/common-defs.h: Include "common/poison.h".
13308 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13309 and adjust.
13310 * common/poison.h: New file.
13311 * common/traits.h: Include <type_traits>.
13312 (Not, Or, Requires): New, moved from common/function-view.h.
13313
16c4d54a
PA
133142017-04-25 Pedro Alves <palves@redhat.com>
13315
13316 * breakpoint.h (struct breakpoint): In-class initialize all
13317 fields. Make boolean fields "bool".
13318 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13319 memset call and initializations no longer necessary.
13320
b5c36682
PA
133212017-04-25 Pedro Alves <palves@redhat.com>
13322
13323 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13324 reference.
13325 (pt_btrace_insn): New function.
13326 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13327
5625a286
PA
133282017-04-25 Pedro Alves <palves@redhat.com>
13329
13330 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13331 "base" field and inherit from "bp_location" instead. Add
13332 non-default ctor.
13333 (allocate_location_exception): Use new non-default ctor.
13334 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13335 (init_bp_location): Convert to ...
13336 (bp_location::bp_location): ... this new ctor, and remove memset
13337 call.
13338 (base_breakpoint_allocate_location): Use the new non-default ctor.
13339 * breakpoint.h (bp_location): Now a class. Declare default and
13340 non-default ctors. In-class initialize all members.
13341 (init_bp_location): Remove declaration.
13342
23bcc18f
PA
133432017-04-25 Pedro Alves <palves@redhat.com>
13344
13345 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13346 assignment operator.
13347
e1ba3053
YQ
133482017-04-24 Yao Qi <yao.qi@linaro.org>
13349
13350 * doublest.c (convert_doublest_to_floatformat): Call
13351 floatformat_totalsize_bytes.
13352
10f489e5
TT
133532017-04-22 Tom Tromey <tom@tromey.com>
13354
13355 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13356 ui_out_emit_list.
13357 * stack.c (print_frame): Use ui_out_emit_list.
13358 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13359 ui_out_emit_list.
13360 * mi/mi-main.c (print_one_inferior)
13361 (mi_cmd_data_list_register_names)
13362 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13363 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13364 ui_out_emit_list.
13365 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13366 (mi_output_solib_attribs): Use ui_out_emit_list,
13367 ui_out_emit_tuple.
13368 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13369 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13370 (mi_cmd_stack_list_args, list_args_or_locals): Use
13371 ui_out_emit_list.
13372 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13373 * breakpoint.c (print_solib_event, output_thread_groups): Use
13374 ui_out_emit_list.
13375
0092b74d
TT
133762017-04-22 Tom Tromey <tom@tromey.com>
13377
13378 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13379 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13380 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13381
a14a62dd
TT
133822017-04-22 Tom Tromey <tom@tromey.com>
13383
13384 * tracepoint.c (tvariables_info_1)
13385 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13386
46b9c129
TT
133872017-04-22 Tom Tromey <tom@tromey.com>
13388
13389 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13390 annotate_arg_emitter.
13391 * breakpoint.c (print_mention_watchpoint)
13392 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13393 * annotate.h (struct annotate_arg_emitter): New.
13394
2e783024
TT
133952017-04-22 Tom Tromey <tom@tromey.com>
13396
13397 * record-btrace.c (record_btrace_insn_history)
13398 (record_btrace_insn_history_range, record_btrace_call_history)
13399 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13400 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13401 ui_out_emit_tuple.
13402 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13403 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13404 * skip.c (skip_info): Use ui_out_emit_tuple.
13405 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13406 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13407 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13408 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13409 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13410 ui_out_emit_tuple.
13411 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13412 (output_register, mi_cmd_data_read_memory)
13413 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13414 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13415 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13416 Use ui_out_emit_tuple.
13417 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13418 ui_out_emit_tuple.
13419 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13420 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13421 * linux-thread-db.c (info_auto_load_libthread_db): Use
13422 ui_out_emit_tuple.
13423 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13424 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13425 * disasm.c (do_mixed_source_and_assembly_deprecated)
13426 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13427 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13428 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13429 * breakpoint.c (print_one_breakpoint_location)
13430 (print_one_breakpoint): Use ui_out_emit_tuple.
13431 * auto-load.c (print_script, info_auto_load_cmd): Use
13432 ui_out_emit_tuple.
13433 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13434
9be21bb4
SM
134352017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13436
13437 * thread.c (print_thread_info_1): Remove dead code.
13438
0d4c07af
JK
134392017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13440
13441 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13442 GDB_SELF_TEST.
13443 * arm-tdep.c (selftests::arm_record_test): Likewise.
13444
4daf993d
YQ
134452017-04-21 Yao Qi <yao.qi@linaro.org>
13446
13447 * regcache.c (regcache_restore): Remove argument 2. Replace
13448 argument 3 with regcache. Get register status from
13449 src->register_status and get register contents from
13450 register_buffer (src, regnum).
13451 (regcache_cpy): Update.
13452
a6c21d4a
PA
134532017-04-19 Pedro Alves <palves@redhat.com>
13454
13455 * gdbthread.h (thread): Add missing closing parenthesis in
13456 comment.
13457
3a3fd0fd
PA
134582017-04-19 Pedro Alves <palves@redhat.com>
13459
13460 * common/refcounted-object.h: New file.
13461 * gdbthread.h: Include "common/refcounted-object.h".
13462 (thread_info): Inherit from refcounted_object and add comments.
13463 (thread_info::incref, thread_info::decref)
13464 (thread_info::m_refcount): Delete.
13465 (thread_info::deletable): Use the refcounted_object::refcount()
13466 method.
13467 * inferior.c (current_inferior_): Add comment.
13468 (set_current_inferior): Increment/decrement refcounts.
13469 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13470 not-deletable instead of comparing with the current inferior.
13471 (initialize_inferiors): Increment the initial inferior's refcount.
13472 * inferior.h (struct inferior): Forward declare.
13473 Include "common/refcounted-object.h".
13474 (current_inferior, set_current_inferior): Move declaration to
13475 before struct inferior's definition, and fix comment.
13476 (inferior): Inherit from refcounted_object. Add comments.
13477 * thread.c (switch_to_thread_no_regs): Reference the thread's
13478 inferior pointer directly instead of doing a ptid lookup.
13479 (switch_to_no_thread): New function.
13480 (switch_to_thread(thread_info *)): New function, factored out
13481 from ...
13482 (switch_to_thread(ptid_t)): ... this.
13483 (restore_current_thread): Delete.
13484 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13485 fields, and add 'inf' field.
13486 (do_restore_current_thread_cleanup): Check whether old->inf is
13487 alive instead of looking up an inferior by ptid. Use
13488 switch_to_thread and switch_to_no_thread.
13489 (restore_current_thread_cleanup_dtor): Use old->inf directly
13490 instead of lookup up an inferior by id. Decref the inferior.
13491 Don't restore 'removable'.
13492 (make_cleanup_restore_current_thread): Same the inferior pointer
13493 in old, instead of the inferior number. Incref the inferior.
13494 Don't save/clear 'removable'.
13495
9bcb1f16
PA
134962017-04-19 Pedro Alves <palves@redhat.com>
13497
13498 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13499 unittests/scoped_restore-selftests.c.
13500 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13501 * common/scoped_restore.h (scoped_restore_base): Make "class".
13502 (scoped_restore_base::release): New public method.
13503 (scoped_restore_base::scoped_restore_base): New protected ctor.
13504 (scoped_restore_base::m_saved_var): New protected field.
13505 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13506 scoped_restore_base base class instead of m_saved_var directly.
13507 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13508 (scoped_restore_tmpl::scoped_restore_tmpl(const
13509 scoped_restore_tmpl<T>&)): Likewise.
13510 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13511 method.
13512 (scoped_restore_tmpl::saved_var): New method.
13513 (scoped_restore_tmpl::m_saved_var): Delete.
13514 * inferior.h (inferior::detaching): Now a bool.
13515 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13516 cleanup.
13517 * unittests/scoped_restore-selftests.c: New file.
13518
26fcd539
PA
135192017-04-19 Pedro Alves <palves@redhat.com>
13520
13521 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13522 Re-sort in alphabetic order.
13523
fdd243b0
PA
135242017-04-18 Pedro Alves <palves@redhat.com>
13525
13526 * xml-support.c (obstack_xml_printf): Delete.
13527 * xml-support.h (obstack_xml_printf): Delete.
13528
4895cde2
PA
135292017-04-18 Pedro Alves <palves@redhat.com>
13530
13531 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13532 vdebug, verror, body_text, start_element, end_element, name,
13533 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13534 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13535 is_xinclude>: Make private and add m_ prefix.
13536 (gdb_xml_parser::body_text): New method, based on ...
13537 (gdb_xml_body_text): ... this. Adjust.
13538 (gdb_xml_parser::vdebug): New method, based on ...
13539 (gdb_xml_debug): ... this. Adjust.
13540 (gdb_xml_parser::verror): New method, based on ...
13541 (gdb_xml_error): ... this. Adjust.
13542 (gdb_xml_parser::start_element): New method, based on ...
13543 (gdb_xml_start_element): ... this. Adjust.
13544 (gdb_xml_start_element_wrapper): Defer to
13545 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
13546 (gdb_xml_parser::end_element): New method, based on ...
13547 (gdb_xml_end_element_wrapper): ... this. Adjust.
13548 (gdb_xml_parser::~gdb_xml_parser): Adjust.
13549 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
13550 (gdb_xml_parser::use_dtd): New method, based on ...
13551 (gdb_xml_use_dtd): ... this. Adjust.
13552 (gdb_xml_parser::parse): New method, based on ...
13553 (gdb_xml_parse): ... this. Adjust.
13554 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
13555 (xinclude_start_include): Adjust to call the parser's name method.
13556 (xml_xinclude_default, xml_xinclude_start_doctype)
13557 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
13558 method.
13559 (xml_process_xincludes): Adjust to call parser methods.
13560 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
13561 declarations.
13562
bd8a901f
PA
135632017-04-18 Pedro Alves <palves@redhat.com>
13564
13565 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
13566 gdb::optional<std::string>.
13567 * xml-support.c: Include <string>.
13568 (scope_level::scope_level(scope_level &&))
13569 (scope_level::~scope_level): Delete.
13570 (scope_level::body): Now a std::string.
13571 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
13572 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
13573 parameter.
13574 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
13575 (xinclude_parsing_data::output): Now a std::string reference.
13576 (xinclude_start_include): Adjust.
13577 (xml_xinclude_default): Adjust.
13578 (xml_process_xincludes): Add 'output' parameter, and return bool.
13579 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
13580 and return bool.
13581 * xml-tdesc.c: Include <unordered_map> and <string>.
13582 (tdesc_xml_cache): Delete.
13583 (tdesc_xml_cache_s): Delete.
13584 (xml_cache): Now an std::unordered_map.
13585 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
13586 (target_fetch_description_xml): Change return type to
13587 gdb::optional<std::string>, and adjust.
13588 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
13589 (target_fetch_description_xml): Change return type to
13590 gdb::optional<std::string>.
13591
d35d1958
PA
135922017-04-18 Pedro Alves <palves@redhat.com>
13593
13594 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13595 unittests/optional-selftests.c.
13596 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
13597 * unittests/optional-selftests.c: New file.
13598 * unittests/optional/assignment/1.cc: New file.
13599 * unittests/optional/assignment/2.cc: New file.
13600 * unittests/optional/assignment/3.cc: New file.
13601 * unittests/optional/assignment/4.cc: New file.
13602 * unittests/optional/assignment/5.cc: New file.
13603 * unittests/optional/assignment/6.cc: New file.
13604 * unittests/optional/assignment/7.cc: New file.
13605 * unittests/optional/cons/copy.cc: New file.
13606 * unittests/optional/cons/default.cc: New file.
13607 * unittests/optional/cons/move.cc: New file.
13608 * unittests/optional/cons/value.cc: New file.
13609 * unittests/optional/in_place.cc: New file.
13610 * unittests/optional/observers/1.cc: New file.
13611 * unittests/optional/observers/2.cc: New file.
13612
22796e97
PA
136132017-04-18 Pedro Alves <palves@redhat.com>
13614
13615 * common/gdb_optional.h: Include common/traits.h.
13616 (in_place_t): New type.
13617 (in_place): New constexpr variable.
13618 (optional::optional): Remove member initialization of
13619 m_instantiated.
13620 (optional::optional(in_place_t...)): New constructor.
13621 (optional::~optional): Use reset.
13622 (optional::optional(const optional&)): New.
13623 (optional::optional(const optional&&)): New.
13624 (optional::optional(T &)): New.
13625 (optional::optional(T &&)): New.
13626 (operator::operator=(const optional &)): New.
13627 (operator::operator=(optional &&)): New.
13628 (operator::operator= (const T &))
13629 (operator::operator= (T &&))
13630 (operator::emplace (Args &&... args)): Return a T&. Use reset.
13631 (operator::reset): New.
13632 (operator::m_instantiated):: Add in-class initializer.
13633 * common/traits.h: Include <type_traits>.
13634 (struct And): New types.
13635
a7fc9b61
PA
136362017-04-18 Pedro Alves <palves@redhat.com>
13637
13638 * xml-support.c: Include <vector>.
13639 (scope_level::scope_level(const gdb_xml_element *))
13640 (scope_level::scope_level(scope_level&&)): New.
13641 (scope_level::~scope_level): New.
13642 (scope_level_s): Delete.
13643 (gdb_xml_parser::scopes): Now a std::vector.
13644 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
13645 Use std::vector.
13646 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
13647 scope cleanup code.
13648 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
13649 of the scopes member. Use std::vector::emplace_back.
13650
010151c9
PA
136512017-04-18 Pedro Alves <palves@redhat.com>
13652
13653 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
13654 a bool.
13655 (gdb_xml_end_element): Change type of first parameter.
13656 (gdb_xml_cleanup): Rename to ...
13657 (gdb_xml_parser::~gdb_xml_parser): ... this.
13658 (gdb_xml_create_parser_and_cleanup): Delete with ...
13659 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
13660 to this new ctor.
13661 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
13662 using gdb_xml_create_parser_and_cleanup.
13663 (xinclude_parsing_data): Add ctor/dtor.
13664 (xml_xinclude_cleanup): Delete.
13665 (xml_process_xincludes): Create a local xinclude_parsing_data
13666 instead of heap-allocating one. Create a local gdb_xml_parser
13667 instead of heap-allocating one with
13668 gdb_xml_create_parser_and_cleanup.
13669
d56060f0
JB
136702017-04-18 John Baldwin <jhb@FreeBSD.org>
13671
13672 PR threads/20743
13673 * fbsd-nat.c (resume_one_thread_cb): Remove.
13674 (resume_all_threads_cb): Remove.
13675 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
13676 iterate_over_threads.
13677
305d16a9
JB
136782017-04-17 Joel Brobecker <brobecker@adacore.com>
13679
13680 * NEWS: Create a new section for the next release branch.
13681 Rename the section of the current branch, now that it has
13682 been cut.
13683
8bb57231
JB
136842017-04-17 Joel Brobecker <brobecker@adacore.com>
13685
13686 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
13687 * version.in: Bump version to 8.0.50.DATE-git.
13688
096c92dd
SDJ
136892017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
13690
13691 PR gdb/21385
13692 * windows-nat.c (windows_create_inferior): Declare 'allargs'
13693 independently of the host, and fix build breakage on Cygwin.
13694
0550c955
PA
136952017-04-13 Pedro Alves <palves@redhat.com>
13696
13697 * inferior.c (free_inferior): Convert to ...
13698 (inferior::~inferior): ... this dtor.
13699 (inferior::inferior): New ctor, factored out from ...
13700 (add_inferior_silent): ... here. Allocate the inferior with a new
13701 expression.
13702 (delete_inferior): Call delete instead of free_inferior.
13703 * inferior.h (gdb_environ, continuation): Forward declare.
13704 (inferior): Now a class. Add in-class initialization to all
13705 members. Make boolean fields bool, except 'detaching'.
13706 (inferior::inferior): New explicit ctor.
13707 (inferior::~inferior): New.
13708
e3d60dfc
PA
137092017-04-13 Pedro Alves <palves@redhat.com>
13710
13711 * inferior.c (init_inferior_list): Delete.
13712 * inferior.h (init_inferior_list): Delete.
13713
5fd69d0a
PA
137142017-04-13 Pedro Alves <palves@redhat.com>
13715
13716 PR threads/13217
13717 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
13718 (top level): Call it twice, with different thread sets.
13719
c6609450
PA
137202017-04-13 Pedro Alves <palves@redhat.com>
13721
13722 * thread.c: Include <algorithm>.
13723 (thread_array_cleanup): Delete.
13724 (scoped_inc_dec_ref): New class.
13725 (live_threads_count): New function.
13726 (set_thread_refcount): Delete.
13727 (tp_array_compar_ascending): Now a bool.
13728 (tp_array_compar): Convert to a std::sort comparison function.
13729 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
13730 and live_threads_count.
13731
2a00d7ce
PA
137322017-04-13 Pedro Alves <palves@redhat.com>
13733
13734 * infrun.c (follow_fork_inferior): Also switch the current
13735 inferior.
13736
441d7c93
PA
137372017-04-13 Pedro Alves <palves@redhat.com>
13738
13739 * breakpoint.c (watch_command_1): Save watchpoint-frame info
13740 before calling create_internal_breakpoint.
13741
808480f6
PA
137422017-04-13 Pedro Alves <palves@redhat.com>
13743
13744 * fork-child.c (execv_argv): New class.
13745 (breakup_args): Refactored as ...
13746 (execv_argv::init_for_no_shell): .. this method of execv_argv.
13747 Copy arguments to storage and replace separators with NULL
13748 terminators in place.
13749 (escape_bang_in_quoted_argument): Adjust to return bool.
13750 (execv_argv::execv_argv): New ctor.
13751 (execv_argv::init_for_shell): New method, factored out from
13752 fork_inferior. Don't strdup strings into the vector.
13753 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
13754 Remove free_vector_argv call.
13755
ad3d022a
YQ
137562017-04-13 Yao Qi <yao.qi@linaro.org>
13757
13758 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
13759 tdep->rx_psw_type.
13760
e6ddc3bf
YQ
137612017-04-13 Yao Qi <yao.qi@linaro.org>
13762
13763 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
13764 * rx-tdep.c (rx_gdbarch_init): Likewise.
13765
bfb8cf90
PA
137662017-04-13 Pedro Alves <palves@redhat.com>
13767
13768 * breakpoint.h (struct breakpoint): Reindent.
13769
f5336ca5
PA
137702017-04-13 Pedro Alves <palves@redhat.com>
13771
13772 * breakpoint.c (bp_location): Rename to ...
13773 (bp_locations): ... this. All references updated.
13774 (bp_location_count): Rename to ...
13775 (bp_locations_count): ... this. All references updated.
13776 (bp_location_placed_address_before_address_max): Rename to ...
13777 (bp_locations_placed_address_before_address_max): ... this. All
13778 references updated.
13779 (bp_location_shadow_len_after_address_max): Rename to ...
13780 (bp_locations_shadow_len_after_address_max): ... this. All
13781 references updated.
13782 (bp_location_compare_addrs): Rename to ...
13783 (bp_locations_compare_addrs): ... this. All references updated.
13784 (bp_location_compare):Rename to ...
13785 (bp_locations_compare): ... this. All references updated.
13786 (bp_location_target_extensions_update): Rename to ...
13787 (bp_locations_target_extensions_update): ... this. All references
13788 updated.
13789
be628ab8
SDJ
137902017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13791
13792 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
13793 * common/common.m4: Check headers 'termios.h', 'termio.h' and
13794 'sgtty.h'.
13795 * common/gdb_termios.h: New file, with parts of "terminal.h".
13796 * inflow.c: Include "gdb_termios.h".
13797 * ser-unix.c: Include "gdb_termios.h".
13798 * terminal.h: Move terminal-related defines to
13799 "common/gdb_termios.h".
13800
8e9e35b1
TT
138012017-04-12 Tom Tromey <tom@tromey.com>
13802
13803 * probe.c (parse_probes): Update.
13804 * location.h (delete_event_location): Don't declare.
13805 (event_location_deleter::operator()): Update.
13806 * location.c (event_location_deleter::operator()): Rename from
13807 delete_event_location.
13808 * linespec.h (linespec_result) <location>: Change type to
13809 event_location_up.
13810 * linespec.c (canonicalize_linespec, event_location_to_sals)
13811 (decode_objc): Update.
13812 (linespec_result): Don't call delete_event_location.
13813 * breakpoint.c (create_breakpoints_sal)
13814 (bkpt_probe_create_sals_from_location)
13815 (strace_marker_create_sals_from_location): Update.
13816
16e802b9
TT
138172017-04-12 Tom Tromey <tom@tromey.com>
13818
13819 * linespec.h (struct linespec_result): Add constructor and
13820 destructor.
13821 (init_linespec_result, destroy_linespec_result)
13822 (make_cleanup_destroy_linespec_result): Don't declare.
13823 * linespec.c (init_linespec_result): Remove.
13824 (linespec_result::~linespec_result): Rename from
13825 destroy_linespec_result. Update.
13826 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
13827 Remove.
13828 * breakpoint.c (create_breakpoint, break_range_command)
13829 (decode_location_default): Update.
13830 * ax-gdb.c (agent_command_1): Update.
13831
d28cd78a
TT
138322017-04-12 Tom Tromey <tom@tromey.com>
13833
13834 * remote.c (remote_download_tracepoint): Update.
13835 * python/py-breakpoint.c (bppy_get_location): Update.
13836 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
13837 (gdbscm_breakpoint_location): Update.
13838 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
13839 * breakpoint.h (struct breakpoint) <location, location_range_end>:
13840 Change type to event_location_up.
13841 * breakpoint.c (create_overlay_event_breakpoint)
13842 (create_longjmp_master_breakpoint)
13843 (create_std_terminate_master_breakpoint)
13844 (create_exception_master_breakpoint)
13845 (breakpoint_event_location_empty_p, print_breakpoint_location)
13846 (print_one_breakpoint_location, create_thread_event_breakpoint)
13847 (init_breakpoint_sal, create_breakpoint)
13848 (print_recreate_ranged_breakpoint, break_range_command)
13849 (init_ada_exception_breakpoint, say_where): Update.
13850 (base_breakpoint_dtor): Don't call delete_event_location.
13851 (bkpt_print_recreate, tracepoint_print_recreate)
13852 (dprintf_print_recreate, update_static_tracepoint)
13853 (breakpoint_re_set_default): Update.
13854
711799d5
TT
138552017-04-12 Tom Tromey <tom@tromey.com>
13856
13857 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
13858 type of "to_do". Update.
13859 (compute_stack_depth): Use std::vector.
13860
52d214d3
TT
138612017-04-12 Tom Tromey <tom@tromey.com>
13862
13863 * printcmd.c (find_instruction_backward): Use std::vector.
13864
4c404b8b
TT
138652017-04-12 Tom Tromey <tom@tromey.com>
13866
13867 * symfile.c (objfilep): Remove typedef.
13868 (reread_symbols): Use a std::vector.
13869
156d9eab
TT
138702017-04-12 Tom Tromey <tom@tromey.com>
13871
13872 * mi/mi-main.c (exec_direction_forward): Remove.
13873 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
13874 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
13875 scoped_restore.
13876 * guile/guile.c (guile_repl_command, guile_command)
13877 (gdbscm_execute_gdb_command): Use scoped_restore.
13878 * go-exp.y (go_parse): Use scoped_restore.
13879 * d-exp.y (d_parse): Use scoped_restore.
13880 * cli/cli-decode.c (cmd_func): Use scoped_restore.
13881 * c-exp.y (c_parse): Use scoped_restore.
13882
4d89769a
TT
138832017-04-12 Tom Tromey <tom@tromey.com>
13884
13885 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
13886 (mi_parse): Update return type.
13887 (mi_parse_free): Remove.
13888 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
13889 (mi_parse::~mi_parse): Rename from mi_parse_free.
13890 (mi_parse_cleanup): Remove.
13891 (mi_parse): Return a unique_ptr. Use new.
13892 * mi/mi-main.c (mi_execute_command): Update.
13893
4b217cc7
TT
138942017-04-12 Tom Tromey <tom@tromey.com>
13895
13896 * location.c (explicit_location_lex_one): Return a
13897 unique_xmalloc_ptr.
13898 (string_to_explicit_location): Update. Remove cleanups.
13899
59d3651b
TT
139002017-04-12 Tom Tromey <tom@tromey.com>
13901
13902 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
13903 (compare_value_and_voffset): Change type. Update.
13904 (compute_vtable_size): Change type of "offset_vec".
13905 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
13906 (gnuv3_get_typeid): Remove extraneous declaration.
13907
b24b0d6c
TT
139082017-04-12 Tom Tromey <tom@tromey.com>
13909
13910 * charset.h (wchar_iterator): Fix comment.
13911
80a3b8c5
TT
139122017-04-12 Tom Tromey <tom@tromey.com>
13913
13914 * charset.c (iconv_wrapper): New class.
13915 (cleanup_iconv): Remove.
13916 (convert_between_encodings): Use it.
13917
c83dd867
TT
139182017-04-12 Tom Tromey <tom@tromey.com>
13919
13920 * symfile.h (increment_reading_symtab): Update type.
13921 * symfile.c (decrement_reading_symtab): Remove.
13922 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
13923 * psymtab.c (psymtab_to_symtab): Update.
13924 * dwarf2read.c (dw2_instantiate_symtab): Update.
13925
0e8621a0
TT
139262017-04-12 Tom Tromey <tom@tromey.com>
13927
13928 * jit.c (struct jit_reader): Declare separately. Add constructor
13929 and destructor. Change type of "handle".
13930 (loaded_jit_reader): Define separately.
13931 (jit_reader_load): Update. New "new".
13932 (jit_reader_unload_command): Use "delete".
13933 * gdb-dlfcn.h (struct dlclose_deleter): New.
13934 (gdb_dlhandle_up): New typedef.
13935 (gdb_dlopen, gdb_dlsym): Update types.
13936 (gdb_dlclose): Remove.
13937 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
13938 (gdb_dlsym): Change type of "handle".
13939 (make_cleanup_dlclose): Remove.
13940 (dlclose_deleter::operator()): Rename from gdb_dlclose.
13941 * compile/compile-c-support.c (load_libcc): Update.
13942
67d89901
TT
139432017-04-12 Tom Tromey <tom@tromey.com>
13944
13945 * symtab.h (find_pcs_for_symtab_line): Change return type.
13946 * symtab.c (find_pcs_for_symtab_line): Change return type.
13947 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
13948 type of "vec". Update.
13949 (ltpy_get_pcs_for_line): Update.
13950 * linespec.c (decode_digits_ordinary): Update.
13951
93921405
TT
139522017-04-12 Tom Tromey <tom@tromey.com>
13953
13954 * tracepoint.c (actions_command): Update.
13955 * python/python.c (python_command, python_interactive_command):
13956 Update.
13957 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
13958 * guile/guile.c (guile_command): Update.
13959 * defs.h (read_command_lines, read_command_lines_1): Return
13960 command_line_up.
13961 (command_lines_deleter): New struct.
13962 (command_line_up): New typedef.
13963 * compile/compile.c (compile_code_command)
13964 (compile_print_command): Update.
13965 * cli/cli-script.h (get_command_line, copy_command_lines): Return
13966 command_line_up.
13967 (make_cleanup_free_command_lines): Remove.
13968 * cli/cli-script.c (get_command_line, read_command_lines_1)
13969 (copy_command_lines): Return command_line_up.
13970 (while_command, if_command, read_command_lines, define_command)
13971 (document_command): Update.
13972 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
13973 Remove.
13974 * breakpoint.h (breakpoint_set_commands): Change type of
13975 "commands".
13976 * breakpoint.c (breakpoint_set_commands): Change type of
13977 "commands". Update.
13978 (do_map_commands_command, update_dprintf_command_list)
13979 (create_tracepoint_from_upload): Update.
13980
ffc2605c
TT
139812017-04-12 Tom Tromey <tom@tromey.com>
13982
13983 * tracepoint.c (scope_info): Update.
13984 * spu-tdep.c (spu_catch_start): Update.
13985 * python/python.c (gdbpy_decode_line): Update.
13986 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
13987 * python/py-breakpoint.c (bppy_init): Update.
13988 * probe.c (parse_probes): Update.
13989 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
13990 * location.h (event_location_deleter): New struct.
13991 (event_location_up): New typedef.
13992 (new_linespec_location, new_address_location, new_probe_location)
13993 (new_explicit_location, copy_event_location)
13994 (string_to_event_location, string_to_event_location_basic)
13995 (string_to_explicit_location): Update return type.
13996 (make_cleanup_delete_event_location): Remove.
13997 * location.c (new_linespec_location, new_address_location)
13998 (new_probe_location, new_explicit_location, copy_event_location):
13999 Return event_location_up.
14000 (delete_event_location_cleanup)
14001 (make_cleanup_delete_event_location): Remove.
14002 (string_to_explicit_location, string_to_event_location_basic)
14003 (string_to_event_location): Return event_location_up.
14004 * linespec.c (canonicalize_linespec, event_location_to_sals)
14005 (decode_line_with_current_source)
14006 (decode_line_with_last_displayed, decode_objc): Update.
14007 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
14008 * completer.c (location_completer): Update.
14009 * cli/cli-cmds.c (edit_command, list_command): Update.
14010 * breakpoint.c (create_overlay_event_breakpoint)
14011 (create_longjmp_master_breakpoint)
14012 (create_std_terminate_master_breakpoint)
14013 (create_exception_master_breakpoint)
14014 (create_thread_event_breakpoint): Update.
14015 (init_breakpoint_sal): Update. Remove some dead code.
14016 (create_breakpoint_sal): Change type of "location". Update.
14017 (create_breakpoints_sal, create_breakpoint, break_command_1)
14018 (dprintf_command, break_range_command, until_break_command)
14019 (init_ada_exception_breakpoint)
14020 (strace_marker_create_sals_from_location)
14021 (update_static_tracepoint, trace_command, ftrace_command)
14022 (strace_command, create_tracepoint_from_upload): Update.
14023 * break-catch-throw.c (re_set_exception_catchpoint): Update.
14024 * ax-gdb.c (agent_command_1): Update.
14025
8f10c932
PA
140262017-04-12 Pedro Alves <palves@redhat.com>
14027
14028 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
14029 * configure.tgt: Handle i[34567]86-*-go32* and
14030 i[34567]86-*-msdosdjgpp*.
14031 * i386-tdep.c (i386_svr4_reg_to_regnum):
14032 Make extern.
14033 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
14034 i386-go32-tdep.c.
14035 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
14036 * i386-go32-tdep.c: New file.
14037 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
14038 declarations.
14039
0a31ccfb
SM
140402017-04-12 Simon Marchi <simon.marchi@ericsson.com>
14041
14042 * aix-thread.c (pd_status2str): Change return type to const char *.
14043
e9bb3fbb
PA
140442017-04-12 Pedro Alves <palves@redhat.com>
14045
14046 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
14047 calls to set_gdbarch_gnu_triplet_regexp.
14048
53375380
PA
140492017-04-12 Pedro Alves <palves@redhat.com>
14050
14051 PR gdb/21323
14052 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
14053 New enum value.
14054 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
14055 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
14056 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
14057 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
14058 * gdbarch.h, gdbarch.c: Regenerate.
14059 * aarch64-tdep.c (aarch64_gdbarch_init): Override
14060 gdbarch_wchar_bit and gdbarch_wchar_signed.
14061 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
14062 * arm-tdep.c (arm_gdbarch_init): Likewise.
14063 * avr-tdep.c (avr_gdbarch_init): Likewise.
14064 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
14065 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
14066 * i386-tdep.c (i386_go32_init_abi): Likewise.
14067 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
14068 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
14069 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
14070 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
14071 * sh-tdep.c (sh_gdbarch_init): Likewise.
14072 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
14073 * sparc64-tdep.c (sparc64_init_abi): Likewise.
14074 * windows-tdep.c (windows_init_abi): Likewise.
14075 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
14076
53e710ac
PA
140772017-04-12 Pedro Alves <palves@redhat.com>
14078
14079 PR c++/21323
14080 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
14081 cplus_primitive_type_char32_t>: New enum values.
14082 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
14083 and cplus_primitive_type_char32_t.
14084 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
14085 32, use the archtecture's built-in type for char16_t and char32_t,
14086 respectively. Otherwise, fallback to init_integer_type as before,
14087 but make the type unsigned, and issue a complaint.
14088 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
14089
ab0538b8
AH
140902017-04-12 Alan Hayward <alan.hayward@arm.com>
14091
5e0e0422 14092 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
14093 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
14094
5430098f
SDJ
140952017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14096
14097 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
14098 'const char *'.
14099
7c5ded6a
SDJ
141002017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
14101
14102 * common/common-utils.c (free_vector_argv): New function.
14103 * common/common-utils.h: Include <vector>.
14104 (free_vector_argv): New prototype.
14105 * darwin-nat.c (darwin_create_inferior): Rewrite function
14106 prototype in order to constify "exec_file" and accept a
14107 "std::string" for "allargs".
14108 * fork-child.c: Include <vector>.
14109 (breakup_args): Rewrite function, using C++.
14110 (fork_inferior): Rewrite function header, constify "exec_file_arg"
14111 and accept "std::string" for "allargs". Update the code to
14112 calculate "argv" based on "allargs". Update calls to "exec_fun"
14113 and "execvp".
14114 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
14115 order to constify "exec_file" and accept a "std::string" for
14116 "allargs".
14117 * go32-nat.c (go32_create_inferior): Likewise.
14118 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
14119 * infcmd.c (run_command_1): Constify "exec_file". Use
14120 "std::string" for inferior arguments.
14121 * inferior.h (fork_inferior): Update prototype.
14122 * linux-nat.c (linux_nat_create_inferior): Rewrite function
14123 prototype in order to constify "exec_file" and accept a
14124 "std::string" for "allargs".
14125 * nto-procfs.c (procfs_create_inferior): Likewise.
14126 * procfs.c (procfs_create_inferior): Likewise.
14127 * remote-sim.c (gdbsim_create_inferior): Likewise.
14128 * remote.c (extended_remote_run): Update code to accept
14129 "std::string" as argument.
14130 (extended_remote_create_inferior): Rewrite function prototype in
14131 order to constify "exec_file" and accept a "std::string" for
14132 "allargs".
14133 * rs6000-nat.c (super_create_inferior): Likewise.
14134 (rs6000_create_inferior): Likewise.
14135 * target.h (struct target_ops) <to_create_inferior>: Likewise.
14136 * windows-nat.c (windows_create_inferior): Likewise.
14137
ae0eee42
PA
141382017-04-11 Pedro Alves <palves@redhat.com>
14139
14140 * thread.c: Fix whitespace throughout.
14141
a6acac06
PR
141422017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
14143
14144 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
14145
64403bd1
AH
141462017-04-11 Alan Hayward <alan.hayward@arm.com>
14147
14148 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
14149
a5bef50f
SDJ
141502017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
14151
14152 PR gdb/21364
14153 * osdata.c (info_osdata): Check if 'type' is an empty string
14154 instead of NULL.
14155
9295a5a9
PA
141562017-04-10 Pedro Alves <palves@redhat.com>
14157
14158 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
14159 (ptid_to_global_thread_id, in_thread_list)
14160 (do_captured_list_thread_ids, set_resumed, set_running)
14161 (set_executing, set_stop_requested, finish_thread_state)
14162 (validate_registers_access, can_access_registers_ptid)
14163 (print_thread_info_1, switch_to_thread)
14164 (do_restore_current_thread_cleanup)
14165 (make_cleanup_restore_current_thread, thread_command)
14166 (thread_name_command): Use operator== instead of ptid_equal.
14167
996812e3
PA
141682017-04-10 Pedro Alves <palves@redhat.com>
14169
14170 * thread.c (struct current_thread_cleanup) <next>: Delete field.
14171 (current_thread_cleanup_chain): Delete.
14172 (restore_current_thread_cleanup_dtor)
14173 (make_cleanup_restore_current_thread): Remove references to
14174 current_thread_cleanup_chain.
14175
845b344f
AH
141762017-04-10 Alan Hayward <alan.hayward@arm.com>
14177
14178 * msp430-tdep.c (msp430_pseudo_register_read): Never return
14179 REG_UNKNOWN.
14180
803bdfe4
YQ
141812017-04-10 Yao Qi <yao.qi@linaro.org>
14182
14183 PR gdb/19942
14184 * gdbthread.h (thread_info::deletable): New method.
14185 (thread_info::incref): New method.
14186 (thread_info::decref): New method.
14187 (thread_info::refcount): Move it to private.
14188 * infrun.c (save_stop_context): Call inc_refcount.
14189 (release_stop_context_cleanup): Likewise.
14190 * thread.c (set_thread_exited): New function.
14191 (init_thread_list): Delete "tp" only it is deletable, otherwise
14192 call set_thread_exited.
14193 (delete_thread_1): Call set_thread_exited.
14194 (current_thread_cleanup) <inferior_pid>: Remove.
14195 <thread>: New field.
14196 (restore_current_thread_ptid_changed): Removed.
14197 (do_restore_current_thread_cleanup): Adjust.
14198 (restore_current_thread_cleanup_dtor): Don't call
14199 find_thread_ptid.
14200 (set_thread_refcount): Use dec_refcount.
14201 (make_cleanup_restore_current_thread): Adjust.
14202 (thread_apply_all_command): Call inc_refcount.
14203 (_initialize_thread): Don't call
14204 observer_attach_thread_ptid_changed.
14205
8c25b497
YQ
142062017-04-10 Yao Qi <yao.qi@linaro.org>
14207
14208 * thread.c (delete_thread_1): Hoist code on marking thread as
14209 exited.
14210
8473b447
SM
142112017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14212
14213 * windows-nat.c (windows_detach): Initialize ptid with
14214 minus_one_ptid.
14215
6670ec13
SM
142162017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14217
14218 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14219
ba2f91bb
AH
142202017-04-07 Alan Hayward <alan.hayward@arm.com>
14221
14222 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14223 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14224 (bfin_pseudo_register_write): Likewise
14225
436252de
SM
142262017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14227
14228 * common/ptid.h (struct ptid): Change to...
14229 (class ptid_t): ... this.
14230 <ptid_t>: New constructors.
14231 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14232 matches>: New methods.
14233 <make_null, make_minus_one>: New static methods.
14234 <pid>: Rename to...
14235 <m_pid>: ...this.
14236 <lwp>: Rename to...
14237 <m_lwp>: ...this.
14238 <tid>: Rename to...
14239 <m_tid>: ...this.
14240 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14241 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14242 as references, move comment to class ptid_t.
14243 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14244 ptid_t static methods.
14245 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14246 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14247 Take ptid arguments as references, implement using ptid_t methods.
14248 * unittests/ptid-selftests.c: New file.
14249 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14250 unittests/ptid-selftests.c.
14251 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14252
0dedf377
TP
142532017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14254
14255 * python/python.c (python_run_simple_file): Cast mode literal to
14256 non-const char pointer as expected by PyFile_FromString.
14257
4e9868d4
SM
142582017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14259
14260 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14261 minus_one_ptid and null_ptid.
14262
9bf2a700
PA
142632017-04-05 Pedro Alves <palves@redhat.com>
14264
14265 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14266 * configure: Regenerate.
14267
a121b7c1
PA
142682017-04-05 Pedro Alves <palves@redhat.com>
14269
14270 * ada-exp.y (yyerror): Constify.
14271 * ada-lang.c (bound_name, get_selections)
14272 (ada_variant_discrim_type)
14273 (ada_variant_discrim_name, ada_value_struct_elt)
14274 (ada_lookup_struct_elt_type, is_unchecked_variant)
14275 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14276 (catch_ada_exception_command_split)
14277 (catch_ada_assert_command_split, catch_assert_command)
14278 (ada_op_name): Constify.
14279 * ada-lang.h (ada_yyerror, get_selections)
14280 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14281 * arc-tdep.c (arc_print_frame_cache): Constify.
14282 * arm-tdep.c (arm_skip_stub): Constify.
14283 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14284 (gen_aggregate_elt_ref): Constify.
14285 * bcache.c (print_bcache_statistics): Constify.
14286 * bcache.h (print_bcache_statistics): Constify.
14287 * break-catch-throw.c (catch_exception_command_1):
14288 * breakpoint.c (struct ep_type_description::description):
14289 Constify.
14290 (add_solib_catchpoint): Constify.
14291 (catch_fork_command_1): Add cast.
14292 (add_catch_command): Constify.
14293 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14294 Constify.
14295 * bsd-uthread.c (bsd_uthread_state): Constify.
14296 * buildsym.c (patch_subfile_names): Constify.
14297 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14298 Constify.
14299 * c-exp.y (yyerror): Constify.
14300 (token::oper): Constify.
14301 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14302 * c-varobj.c (cplus_describe_child): Constify.
14303 * charset.c (find_charset_names): Add cast.
14304 (find_charset_names): Constify array and add const_cast.
14305 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14306 (edit_command): Constify.
14307 * cli/cli-decode.c (lookup_cmd): Constify.
14308 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14309 Constify.
14310 (struct dump_context): Constify.
14311 (add_dump_command, restore_command): Constify.
14312 * cli/cli-script.c (get_command_line): Constify.
14313 * cli/cli-script.h (get_command_line): Constify.
14314 * cli/cli-utils.c (check_for_argument): Constify.
14315 * cli/cli-utils.h (check_for_argument): Constify.
14316 * coff-pe-read.c (struct read_pe_section_data): Constify.
14317 * command.h (lookup_cmd): Constify.
14318 * common/print-utils.c (decimal2str): Constify.
14319 * completer.c (gdb_print_filename): Constify.
14320 * corefile.c (set_gnutarget): Constify.
14321 * cp-name-parser.y (yyerror): Constify.
14322 * cp-valprint.c (cp_print_class_member): Constify.
14323 * cris-tdep.c (cris_register_name, crisv32_register_name):
14324 Constify.
14325 * d-exp.y (yyerror): Constify.
14326 (struct token::oper): Constify.
14327 * d-lang.h (d_yyerror): Constify.
14328 * dbxread.c (struct header_file_location::name): Constify.
14329 (add_old_header_file, add_new_header_file, last_function_name)
14330 (dbx_next_symbol_text, add_bincl_to_list)
14331 (find_corresponding_bincl_psymtab, set_namestring)
14332 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14333 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14334 * defs.h (command_line_input, print_address_symbolic)
14335 (deprecated_readline_begin_hook): Constify.
14336 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14337 Constify.
14338 * event-top.c (handle_line_of_input): Constify and add cast.
14339 * exceptions.c (catch_errors): Constify.
14340 * exceptions.h (catch_errors): Constify.
14341 * expprint.c (print_subexp_standard, op_string, op_name)
14342 (op_name_standard, dump_raw_expression, dump_raw_expression):
14343 * expression.h (op_name, op_string, dump_raw_expression):
14344 Constify.
14345 * f-exp.y (yyerror): Constify.
14346 (struct token::oper): Constify.
14347 (struct f77_boolean_val::name): Constify.
14348 * f-lang.c (f_word_break_characters): Constify.
14349 * f-lang.h (f_yyerror): Constify.
14350 * fork-child.c (fork_inferior): Add cast.
14351 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14352 (new_variant): Constify.
14353 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14354 * gdbarch.c: Regenerate.
14355 * gdbcore.h (set_gnutarget): Constify.
14356 * go-exp.y (yyerror): Constify.
14357 (token::oper): Constify.
14358 * go-lang.h (go_yyerror): Constify.
14359 * go32-nat.c (go32_sysinfo): Constify.
14360 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14361 * guile/scm-cmd.c (cmdscm_function): Constify.
14362 * guile/scm-param.c (pascm_param_value): Constify.
14363 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14364 (h8300sx_register_name): Constify.
14365 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14366 Constify.
14367 * ia64-tdep.c (ia64_register_names): Constify.
14368 * infcmd.c (construct_inferior_arguments): Constify.
14369 (path_command, attach_post_wait): Constify.
14370 * language.c (show_range_command, show_case_command)
14371 (unk_lang_error): Constify.
14372 * language.h (language_defn::la_error)
14373 (language_defn::la_name_of_this): Constify.
14374 * linespec.c (decode_line_2): Constify.
14375 * linux-thread-db.c (thread_db_err_str): Constify.
14376 * lm32-tdep.c (lm32_register_name): Constify.
14377 * m2-exp.y (yyerror): Constify.
14378 * m2-lang.h (m2_yyerror): Constify.
14379 * m32r-tdep.c (m32r_register_names): Constify and make static.
14380 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14381 * m88k-tdep.c (m88k_register_name): Constify.
14382 * macroexp.c (appendmem): Constify.
14383 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14384 (upgrade_type, parse_external, parse_partial_symbols)
14385 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14386 (new_symbol): Constify.
14387 * memattr.c (mem_info_command): Constify.
14388 * mep-tdep.c (register_name_from_keyword): Constify.
14389 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14390 Constify.
14391 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14392 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14393 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14394 cast.
14395 (mi_execute_async_cli_command): Constify.
14396 * mips-tdep.c (mips_register_name): Constify.
14397 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14398 (am33_register_name, am33_2_register_name)
14399 * moxie-tdep.c (moxie_register_names): Constify.
14400 * nat/linux-osdata.c (osdata_type): Constify fields.
14401 * nto-tdep.c (nto_parse_redirection): Constify.
14402 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14403 (lookup_child_selector): Constify.
14404 (objc_methcall::name): Constify.
14405 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14406 (lookup_struct_typedef): Constify.
14407 * objfiles.c (pc_in_section): Constify.
14408 * objfiles.h (pc_in_section): Constify.
14409 * p-exp.y (struct token::oper): Constify.
14410 (yyerror): Constify.
14411 * p-lang.h (pascal_yyerror): Constify.
14412 * parser-defs.h (op_name_standard): Constify.
14413 (op_print::string): Constify.
14414 (exp_descriptor::op_name): Constify.
14415 * printcmd.c (print_address_symbolic): Constify.
14416 * psymtab.c (print_partial_symbols): Constify.
14417 * python/py-breakpoint.c (stop_func): Constify.
14418 (bppy_get_expression): Constify.
14419 * python/py-cmd.c (cmdpy_completer::name): Constify.
14420 (cmdpy_function): Constify.
14421 * python/py-event.c (evpy_add_attribute)
14422 (gdbpy_initialize_event_generic): Constify.
14423 * python/py-event.h (evpy_add_attribute)
14424 (gdbpy_initialize_event_generic): Constify.
14425 * python/py-evts.c (add_new_registry): Constify.
14426 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14427 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14428 * python/py-inferior.c (get_buffer): Add cast.
14429 * python/py-param.c (parm_constant::name): Constify.
14430 * python/py-unwind.c (fprint_frame_id): Constify.
14431 * python/python.c (gdbpy_parameter_value): Constify.
14432 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14433 * remote.c (memory_packet_config::name): Constify.
14434 (show_packet_config_cmd, remote_write_bytes)
14435 (remote_buffer_add_string):
14436 * reverse.c (exec_reverse_once): Constify.
14437 * rs6000-tdep.c (variant::name, variant::description): Constify.
14438 * rust-exp.y (rustyyerror): Constify.
14439 * rust-lang.c (rust_op_name): Constify.
14440 * rust-lang.h (rustyyerror): Constify.
14441 * serial.h (serial_ops::name): Constify.
14442 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14443 (sh_sh3e_register_name, sh_sh2e_register_name)
14444 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14445 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14446 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14447 (sh_sh4al_dsp_register_name): Constify.
14448 * sh64-tdep.c (sh64_register_name): Constify.
14449 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14450 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14451 * stabsread.c (patch_block_stabs, read_type_number)
14452 (ref_map::stabs, ref_add, process_reference)
14453 (symbol_reference_defined, define_symbol, define_symbol)
14454 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14455 (read_one_struct_field, read_struct_fields, read_baseclasses)
14456 (read_tilde_fields, read_struct_type, read_array_type)
14457 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14458 (read_huge_number, read_range_type, read_args, common_block_start)
14459 (find_name_end): Constify.
14460 * stabsread.h (common_block_start, define_symbol)
14461 (process_one_symbol, symbol_reference_defined, ref_add):
14462 * symfile.c (get_section_index, add_symbol_file_command):
14463 * symfile.h (get_section_index): Constify.
14464 * target-descriptions.c (tdesc_type::name): Constify.
14465 (tdesc_free_type): Add cast.
14466 * target.c (find_default_run_target):
14467 (add_deprecated_target_alias, find_default_run_target)
14468 (target_announce_detach): Constify.
14469 (do_option): Constify.
14470 * target.h (add_deprecated_target_alias): Constify.
14471 * thread.c (print_thread_info_1): Constify.
14472 * top.c (deprecated_readline_begin_hook, command_line_input):
14473 Constify.
14474 (init_main): Add casts.
14475 * top.h (handle_line_of_input): Constify.
14476 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14477 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14478 (tfind_command): Rename to ...
14479 (tfind_command_1): ... this and constify.
14480 (tfind_command): New function.
14481 (tfind_end_command, tfind_start_command): Adjust.
14482 (encode_source_string): Constify.
14483 * tracepoint.h (encode_source_string): Constify.
14484 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14485 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14486 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14487 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14488 * tui/tui-win.c (parse_scrolling_args): Constify.
14489 * tui/tui-windata.c (tui_erase_data_content): Constify.
14490 * tui/tui-windata.h (tui_erase_data_content): Constify.
14491 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14492 * tui/tui.c (tui_enable): Add cast.
14493 * utils.c (defaulted_query): Constify.
14494 (init_page_info): Add cast.
14495 (puts_debug, subset_compare): Constify.
14496 * utils.h (subset_compare): Constify.
14497 * varobj.c (varobj_format_string): Constify.
14498 * varobj.h (varobj_format_string): Constify.
14499 * vax-tdep.c (vax_register_name): Constify.
14500 * windows-nat.c (windows_detach): Constify.
14501 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14502 * xml-support.c (gdb_xml_end_element): Constify.
14503 * xml-tdesc.c (tdesc_start_reg): Constify.
14504 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14505 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14506 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14507
995816ba
PA
145082017-04-05 Pedro Alves <palves@redhat.com>
14509
14510 * proc-api.c (struct trans): Constify.
14511 (procfs_note): Constify.
14512 * proc-events.c (struct trans, syscall_table):
14513 * proc-flags.c (struct trans): Constify.
14514 * proc-utils.h (procfs_note): Constify.
14515 * proc-why.c (struct trans): Constify.
14516 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14517 (procfs_detach): Constify.
14518 * sol-thread.c (struct string_map): Constify.
14519 (td_err_string, td_state_string): Constify.
14520
3e83a920
PA
145212017-04-05 Pedro Alves <palves@redhat.com>
14522
14523 * proc-api.c (procfs_filename): Don't initialize
14524 procfs_filename.
14525 (prepare_to_trace): Assume procfs_filename is non-NULL.
14526 (_initialize_proc_api): Give procfs_filename a default value here.
14527
63160a43
PA
145282017-04-05 Pedro Alves <palves@redhat.com>
14529
14530 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14531 'cond_string' parameter.
14532 (extract_exception_regexp): Constify 'string' parameter.
14533 (catch_exception_command_1): Constify.
14534 * breakpoint.c (init_catchpoint)
14535 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14536 parameter.
14537 (ep_parse_optional_if_clause, catch_fork_command_1)
14538 (catch_exec_command_1): Constify.
14539 * breakpoint.h (init_catchpoint): Constify 'cond_string'
14540 parameter.
14541 (ep_parse_optional_if_clause): Constify.
14542 * cli/cli-utils.c (remove_trailing_whitespace)
14543 (check_for_argument): Constify.
14544 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
14545 non-const overload.
14546 (check_for_argument): Likewise.
14547
9b2eba3d
PA
145482017-04-05 Pedro Alves <palves@redhat.com>
14549
14550 * event-top.c (command_line_handler): Add cast to execute_command
14551 call.
14552 * record-btrace.c (cmd_record_btrace_bts_start)
14553 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
14554 (cmd_record_btrace_start): Add cast to execute_command call.
14555 * record-full.c (record_full_goto_insn):
14556 * record.c (record_start, record_stop): Add cast to
14557 execute_command_to_string calls.
14558 (cmd_record_start): Add cast to execute_command calls.
14559
2adadf51
PA
145602017-04-05 Pedro Alves <palves@redhat.com>
14561
14562 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
14563 static inline function.
14564 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
14565 array and use gdb_PyArg_ParseTupleAndKeywords.
14566 * python/py-cmd.c (cmdpy_init): Likewise.
14567 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
14568 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
14569 (infpy_search_memory): Likewise.
14570 * python/py-objfile.c (objfpy_add_separate_debug_file)
14571 (gdbpy_lookup_objfile): Likewise.
14572 * python/py-symbol.c (gdbpy_lookup_symbol)
14573 (gdbpy_lookup_global_symbol): Likewise.
14574 * python/py-type.c (gdbpy_lookup_type): Likewise.
14575 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
14576 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
14577 Likewise.
14578
0d1f4ceb
PA
145792017-04-05 Pedro Alves <palves@redhat.com>
14580
14581 * python/python-internal.h (gdb_PyGetSetDef): New type.
14582 * python/py-block.c (block_object_getset)
14583 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
14584 * python/py-event.c (event_object_getset)
14585 (finish_breakpoint_object_getset): Likewise.
14586 * python/py-inferior.c (inferior_object_getset): Likewise.
14587 * python/py-infthread.c (thread_object_getset): Likewise.
14588 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
14589 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
14590 * python/py-objfile.c (objfile_getset): Likewise.
14591 * python/py-progspace.c (pspace_getset): Likewise.
14592 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
14593 Likewise.
14594 * python/py-record.c (recpy_record_getset): Likewise.
14595 * python/py-symbol.c (symbol_object_getset): Likewise.
14596 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
14597 Likewise.
14598 * python/py-type.c (type_object_getset, field_object_getset):
14599 Likewise.
14600 * python/py-value.c (value_object_getset): Likewise.
14601
4d759979
PA
146022017-04-05 Pedro Alves <palves@redhat.com>
14603
14604 * python/python-internal.h (gdb_PyObject_CallMethod)
14605 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
14606 New functions.
14607 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
14608 (PySys_GetObject, PySys_SetPath): New macros.
14609
fdf9e36f
PA
146102017-04-05 Pedro Alves <palves@redhat.com>
14611
14612 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
14613 info_osdata_command.
14614 * osdata.c (info_osdata_command): Rename to ...
14615 (info_osdata): ... this. Constify 'type' parameter, and remove
14616 the 'from_tty' parameter. Accept NULL TYPE.
14617 (info_osdata_command): New function.
14618 * osdata.h (info_osdata_command): Remove declaration.
14619 (info_osdata): New declaration.
14620
9f33b8b7
PA
146212017-04-05 Pedro Alves <palves@redhat.com>
14622
14623 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
14624 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
14625 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
14626 parameter.
14627 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
14628 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
14629 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
14630 parameter.
14631 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
14632 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
14633 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
14634 (mi_cmd_file_list_exec_source_files)
14635 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
14636 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
14637 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
14638 parameter.
14639 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
14640 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
14641 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
14642 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
14643 (mi_cmd_stack_info_frame): Constify 'command' parameter.
14644 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
14645 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
14646 'command' parameter.
14647 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
14648 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
14649 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
14650 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
14651 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
14652 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
14653 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
14654 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
14655 (mi_cmd_var_set_update_range): Constify 'command' parameter.
14656 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
14657 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
14658 parameter.
14659 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
14660 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
14661 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
14662 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
14663 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
14664 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
14665 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
14666 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
14667 (mi_cmd_data_list_changed_registers)
14668 (mi_cmd_data_write_register_values)
14669 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
14670 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
14671 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
14672 (mi_cmd_list_features, mi_cmd_list_target_features)
14673 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
14674 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
14675 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
14676 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
14677 (mi_cmd_trace_frame_collected): Constify 'command'
14678 parameter.
14679 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
14680 'command' parameter.
14681
67cb5b2d
PA
146822017-04-05 Pedro Alves <palves@redhat.com>
14683
14684 * ada-lang.c (ada_completer_word_break_characters): Now a const
14685 array.
14686 (ada_get_gdb_completer_word_break_characters): Constify.
14687 * completer.c (gdb_completer_command_word_break_characters)
14688 (gdb_completer_file_name_break_characters)
14689 (gdb_completer_quote_characters): Now const arrays.
14690 (get_gdb_completer_quote_characters): Constify.
14691 (set_rl_completer_word_break_characters): New function.
14692 (set_gdb_completion_word_break_characters)
14693 (complete_line_internal): Use it.
14694 * completer.h (get_gdb_completer_quote_characters): Constify.
14695 (set_rl_completer_word_break_characters): Declare.
14696 * f-lang.c (f_word_break_characters): Constify.
14697 * language.c (default_word_break_characters): Constify.
14698 * language.h (language_defn::la_word_break_characters): Constify.
14699 (default_word_break_characters): Constify.
14700 * top.c (init_main): Use set_rl_completer_word_break_characters.
14701
7a114964
PA
147022017-04-05 Pedro Alves <palves@redhat.com>
14703
14704 * aix-thread.c (aix_thread_pid_to_str)
14705 (aix_thread_extra_thread_info): Constify.
14706 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
14707 * bsd-uthread.c (bsd_uthread_extra_thread_info)
14708 (bsd_uthread_pid_to_str): Constify.
14709 * corelow.c (core_pid_to_str): Constify.
14710 * darwin-nat.c (darwin_pid_to_str): Constify.
14711 * fbsd-nat.c (fbsd_pid_to_str): Constify.
14712 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
14713 Constify.
14714 * gnu-nat.c (gnu_pid_to_str): Constify.
14715 * go32-nat.c (go32_pid_to_str): Constify.
14716 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
14717 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
14718 * inferior.c (inferior_pid_to_str): Constify.
14719 * linux-nat.c (linux_nat_pid_to_str): Constify.
14720 * linux-tdep.c (linux_core_pid_to_str): Constify.
14721 * linux-thread-db.c (thread_db_pid_to_str)
14722 (thread_db_extra_thread_info): Constify.
14723 * nto-tdep.c (nto_extra_thread_info): Constify.
14724 * nto-tdep.h (nto_extra_thread_info): Constify.
14725 * obsd-nat.c (obsd_pid_to_str): Constify.
14726 * procfs.c (procfs_pid_to_str): Constify.
14727 * ravenscar-thread.c (ravenscar_extra_thread_info)
14728 (ravenscar_pid_to_str): Constify.
14729 * remote-sim.c (gdbsim_pid_to_str): Constify.
14730 * remote.c (remote_threads_extra_info, remote_pid_to_str):
14731 Constify.
14732 * sol-thread.c (solaris_pid_to_str): Constify.
14733 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
14734 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
14735 * target.c (default_pid_to_str, target_pid_to_str)
14736 (normal_pid_to_str, default_pid_to_str): Constify.
14737 * target.h (target_ops::to_pid_to_str)
14738 (target_ops::to_extra_thread_info): Constify.
14739 (target_pid_to_str, normal_pid_to_str): Constify.
14740 * windows-nat.c (windows_pid_to_str): Constify.
14741 * gdbarch.sh (core_pid_to_str): Constify.
14742 * target-delegates.c: Regenerate.
14743 * gdbarch.h, gdbarch.c: Regenerate.
14744
69bbf465
PA
147452017-04-05 Pedro Alves <palves@redhat.com>
14746
14747 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
14748 the memory of the temporary warning_pre_print override.
14749 * utils.c (warning_pre_print): Constify.
14750 * utils.h (warning_pre_print): Constify.
14751
be47f9e8
PA
147522017-04-05 Pedro Alves <palves@redhat.com>
14753
14754 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
14755 (shell_command): New function.
14756 (make_command): Use std::string.
14757 (init_cli_cmds): Register shell_command instead of shell_escape.
14758
bde6261a
PA
147592017-04-05 Pedro Alves <palves@redhat.com>
14760
14761 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
14762 * tracepoint.c (default_collect): Don't initialize.
14763
b38ef47f
PA
147642017-04-05 Pedro Alves <palves@redhat.com>
14765
14766 * macroexp.c (macro_buffer::shared): Now a bool.
14767 (init_buffer): Update.
14768 (init_shared_buffer): Constify 'addr' parameter.
14769 (substitute_args, expand, macro_expand, macro_expand_next): Remove
14770 casts.
14771
f995bbe8
PA
147722017-04-05 Pedro Alves <palves@redhat.com>
14773
14774 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
14775 * disasm.c (set_disassembler_options): Constify local.
14776 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
14777
4a596fe2
SDJ
147782017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
14779
14780 PR gdb/21352
14781 * tracefile.c (tsave_command): Fix argument parsing for '-r'
14782 option.
14783
2cad08ea
YQ
147842017-04-05 Yao Qi <yao.qi@linaro.org>
14785
14786 * frame.c (frame_unwind_register_unsigned): Call
14787 frame_unwind_register_value.
14788
55a98976
YQ
147892017-04-05 Yao Qi <yao.qi@linaro.org>
14790
14791 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
14792 Use gdb_test_multiple, and don't match anchor.
14793
4ac40124
PA
147942017-04-05 Pedro Alves <palves@redhat.com>
14795
14796 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
14797 (Write After Approval): Remove Simon Marchi.
14798
c053b654
PA
147992017-04-05 Pedro Alves <palves@redhat.com>
14800
14801 * common/gdb_optional.h (optional::optional): Make constexpr and
14802 initialize m_dummy.
14803
4c7bf4f9
JB
148042017-04-04 John Baldwin <jhb@FreeBSD.org>
14805
14806 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14807 (amd64fbsd_jmp_buf_reg_offset): Remove.
14808 (amd64fbsd_supply_uthread): Remove function.
14809 (amd64fbsd_collect_uthread): Remove function.
14810 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
14811 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
14812 (x86_64-*-freebsd*): Remove bsd-uthread.o.
14813 (fbsd-nat.c): Update comment.
14814 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14815 (i386fbsd_jmp_buf_reg_offset): Remove.
14816 (i386fbsd_supply_uthread): Remove function.
14817 (i386fbsd_collect_uthread): Remove function.
14818 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
14819
1e1a8bef
JB
148202017-04-04 John Baldwin <jhb@FreeBSD.org>
14821
14822 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
14823 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
14824 * NEWS: Mention that support for FreeBSD/alpha was removed.
14825 * alpha-fbsd-tdep.c: Delete file.
14826 * config/alpha/fbsd.mh: Delete file.
14827 * configure.host: Delete alpha*-*-freebsd* and
14828 alpha*-*-kfreebsd*-gnu.
14829 * configure.tgt: Delete alpha*-*-freebsd* and
14830 alpha*-*-kfreebsd*-gnu.
14831
49907934
JB
148322017-04-04 John Baldwin <jhb@FreeBSD.org>
14833
14834 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
14835 amd64bsd_store_inferior_registers): Use ptid from regcache.
14836
6f77053d
PA
148372017-04-04 Pedro Alves <palves@redhat.com>
14838
14839 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
14840 data fields, make them private and add "m_" prefixes.
14841 (lnp_state_machine::lnp_state_machine): New ctor.
14842 (record_line, check_line_address, handle_set_discriminator)
14843 (handle_set_address, handle_advance_pc, handle_special_opcode)
14844 (handle_advance_line, handle_set_file, handle_negate_stmt)
14845 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
14846 (end_sequence, advance_line): New methods.
14847 (m_gdbarch, m_record_lines_p): New fields.
14848 (lnp_reader_state): Delete.
14849 (dwarf_record_line): Rename to ...
14850 (lnp_state_machine::record_line): ... adjust.
14851 (init_lnp_state_machine): Delete.
14852 (lnp_state_machine::lnp_state_machine): New.
14853 (check_line_address): Rename to ...
14854 (lnp_state_machine::check_line_address): This.
14855 (dwarf_decode_lines_1): Remove reference to "reader_state".
14856 Adjust lnp_state_machine having a non-default ctor. Use bool.
14857 State machine internal state manipulation moved to
14858 lnp_state_machine methods.
14859
9c541725
PA
148602017-04-04 Pedro Alves <palves@redhat.com>
14861
14862 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14863 unittests/offset-type-selftests.c.
14864 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
14865 * common/offset-type.h: New file.
14866 * common/preprocessor.h: New file.
14867 * common/traits.h: New file.
14868 * common/valid-expr.h: New file.
14869 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
14870 sect_offset and cu_offset strong typedefs throughout.
14871 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
14872 typedefs throughout.
14873 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
14874 sect_offset and cu_offset strong typedefs throughout.
14875 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
14876 typedefs throughout.
14877 * gdbtypes.h: Include "common/offset-type.h".
14878 (cu_offset): Now an offset type (strong typedef) instead of a
14879 struct.
14880 (sect_offset): Likewise.
14881 (union call_site_parameter_u): Rename "param_offset" field to
14882 "param_cu_off".
14883 * unittests/offset-type-selftests.c: New file.
14884
ecfb656c
PA
148852017-04-04 Pedro Alves <palves@redhat.com>
14886
14887 * common/underlying.h: New file.
14888 * dwarf2read.c: Include "common/gdb_optional.h" and
14889 "common/underlying.h".
14890 (dir_index, file_name_index): New types.
14891 (file_entry): Use them.
14892 (file_entry::include): Use to_underlying.
14893 (line_header::add_file_name): Use dir_index.
14894 (read_formatted_entries): Use gdb::optional. Read form before
14895 writting to file_entry.
14896 (dwarf_decode_line_header): Use dir_index.
14897 (lnp_state_machine::current_file): Use to_underlying.
14898 (lnp_state_machine::file): Change type to file_name_index.
14899 (dwarf_record_line): Use to_underlying.
14900 (init_lnp_state_machine): Use file_name_index.
14901 (dwarf_decode_lines_1): Use dir_index and file_name_index.
14902
d194f1fe
PA
149032017-04-04 Pedro Alves <palves@redhat.com>
14904
14905 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
14906 operator bool, has_value and get methods.
14907
fff8551c
PA
149082017-04-04 Pedro Alves <palves@redhat.com>
14909
14910 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
14911 fields.
14912 (line_header): Initialize all data fields. Change type of
14913 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
14914 Change type of include_dirs to std::vector<const char *>. Remove
14915 num_include_dirs, include_dirs_size. Change type of file_names to
14916 std::vector<file_entry>. Remove num_file_names, file_names_size.
14917 (line_header::line_header): New.
14918 (line_header::add_include_dir, line_header::add_file_name): New
14919 methods.
14920 (line_header::include_dir_at): Remove NULL check.
14921 (line_header::file_name_at): Add const overload.
14922 (line_header_up): New unique_ptr typedef.
14923 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
14924 std::vector. Remove free_line_header call.
14925 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
14926 free_line_header call.
14927 (free_cu_line_header): Delete.
14928 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
14929 (setup_type_unit_groups): Use line_header_up instead of cleanups.
14930 Adjust to use std::vector.
14931 (free_line_header): Delete.
14932 (free_line_header_voidp): Use delete.
14933 (add_include_dir): Replace with ...
14934 (line_header::add_include_dir): ... this method. Use std::vector.
14935 (add_file_name): Replace with ...
14936 (line_header::add_file_name): ... this method. Use std::vector.
14937 (add_include_dir_stub): Delete.
14938 (read_formatted_entries): Remove memset.
14939 (dwarf_decode_line_header): Return a line_header_up instead of a
14940 raw pointer. Remove cleanup handling. Pass lambdas to
14941 read_formatted_entries. Adjust to use line_header methods.
14942 (dwarf_decode_lines_1): Adjust to use line_header methods.
14943 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
14944 use std::vector.
14945
d62a8ae2
SM
149462017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
14947
14948 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
14949 instead of struct ptid.
14950
db3a1dc7
AH
149512017-05-04 Alan Hayward <alan.hayward@arm.com>
14952
14953 * frame.c (get_frame_register_bytes): Unwind using value.
14954 (put_frame_register_bytes): Likewise.
14955
b1b45502
IB
149562017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
14957
14958 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
14959 aggregate-like.
14960
ec13808e
JK
149612017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
14962
14963 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
14964
12316564
YQ
149652017-03-29 Yao Qi <yao.qi@linaro.org>
14966
14967 * gdbthread.h (struct thread_info): Declare constructor and
14968 destructor. Add some in-class member initializers.
14969 * thread.c (free_thread): Remove.
14970 (init_thread_list): Call delete instead of free_thread.
14971 (new_thread): Call thread_info constructor.
14972 (thread_info::thread_info): New function.
14973 (thread_info::~thread_info): New function.
14974 (delete_thread_1): Call delete instead of free_thread.
14975 (make_cleanup_restore_current_thread): Move tp and frame to
14976 inner block.
14977
fe5f7374
AK
149782017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14979
14980 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
14981 (arc_skip_prologue): Likewise.
14982 (arc_make_frame_cache): Likewise.
14983 (arc_pv_get_operand): New function.
14984 (arc_is_in_prologue): Likewise.
14985 (arc_analyze_prologue): Likewise.
14986 (arc_print_frame_cache): Likewise.
14987 (MAX_PROLOGUE_LENGTH): New constant.
14988
eea78757
AK
149892017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14990
14991 * configure.tgt: Add arc-insn.o.
14992 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
14993 (dump_arc_instruction_command): New function.
14994 (arc_fprintf_disasm): Likewise.
14995 (arc_disassemble_info): Likewise.
14996 (arc_insn_get_operand_value): Likewise.
14997 (arc_insn_get_operand_value_signed): Likewise.
14998 (arc_insn_get_memory_base_reg): Likewise.
14999 (arc_insn_get_memory_offset): Likewise.
15000 (arc_insn_get_branch_target): Likewise.
15001 (arc_insn_dump): Likewise.
15002 (arc_insn_get_linear_next_pc): Likewise.
15003 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
15004 (arc_disassemble_info): Likewise.
15005 (arc_insn_get_branch_target): Likewise.
15006 (arc_insn_get_linear_next_pc): Likewise.
15007 * NEWS: Mention new "maint print arc arc-instruction".
15008
3be78afd
AK
150092017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15010
15011 * arc-tdep (maintenance_print_arc_list): New variable.
15012 (maintenance_print_arc_command): New function.
15013
296ec4fa
AK
150142017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
15015
15016 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
15017 Add "limm" and "reserved".
15018 (arc_cannot_fetch_register, arc_cannot_store_register): Add
15019 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
15020 * arc-tdep.h (arc_regnum): Likewise.
15021
f74f865e
MF
150222017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15023
15024 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15025 for THREADPTR register.
15026 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
15027 register.
15028 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
15029 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
15030 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
15031
0d0bf81a
MF
150322017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15033
15034 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
15035 registers above gdbarch_num_regs (gdbarch) as privileged in
15036 call0 ABI.
15037
0ce4291e
MF
150382017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15039
15040 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
15041 for a single specified register or for all registers in
15042 a0_base..a0_base + C0_NREGS range.
15043 (supply_gregset_reg): Call regcache_raw_supply for a single
15044 specified register or for all registers in a0_base..a0_base +
15045 C0_NREGS range.
15046
c56054f9
MF
150472017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15048
15049 * arch/xtensa.h (C0_NREGS): Add definition.
15050 * xtensa-tdep.c (C0_NREGS): Remove definition.
15051
a4398628
MF
150522017-03-27 Max Filippov <jcmvbkbc@gmail.com>
15053
15054 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
15055 Drop xtensa_default_isa initialization.
15056 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
15057
8c43009f
PA
150582017-03-27 Pedro Alves <palves@redhat.com>
15059
15060 * dwarf2read.c (file_entry) <dir_index>: Add comment.
15061 (file_entry::include_dir): New method.
15062 (line_header::include_dir_at, line_header::file_name_at): New
15063 methods.
15064 (setup_type_unit_groups, setup_type_unit_groups)
15065 (psymtab_include_file_name): Simplify using the new methods.
15066 (lnp_state_machine) <the_line_header>: New field.
15067 <file>: Add comment.
15068 (lnp_state_machine::current_file): New method.
15069 (dwarf_record_line): Simplify using the new methods.
15070 (init_lnp_state_machine): Initialize the "the_line_header" field.
15071 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
15072 Simplify using the new methods.
15073
a7e80b9e
PA
150742017-03-27 Pedro Alves <palves@redhat.com>
15075
15076 * cp-name-parser.y (make_empty): Delete.
15077 (demangler_special, nested_name, ptr_operator, array_indicator)
15078 (direct_declarator, declarator_1): Use fill_comp instead of
15079 make_empty.
15080
21047726
PA
150812017-03-27 Pedro Alves <palves@redhat.com>
15082
15083 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
15084 to ATTRIBUTE_PRINTF.
15085 * solib-target.c (library_list_start_list): Print "string" not
15086 "version".
15087 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
15088 gdb_xml_error call.
15089
d721ba37
PA
150902017-03-27 Pedro Alves <palves@redhat.com>
15091
15092 * dwarf2read.c (struct file_and_directory): New.
15093 (dwarf2_get_dwz_file): Adjust to use std::string.
15094 (dw2_get_file_names_reader): Adjust to use file_and_directory.
15095 (find_file_and_directory): Adjust to return a file_and_directory
15096 object.
15097 (read_file_scope): Adjust to use file_and_directory. Remove
15098 make_cleanup/do_cleanups calls.
15099 (open_and_init_dwp_file): Adjust to use std::string. Remove
15100 make_cleanup/do_cleanups calls.
15101 * python/python.c (do_start_initialization): Adjust to ldirname
15102 returning a std::string.
15103 * utils.c (ldirname): Now returns a std::string.
15104 * utils.h (ldirname): Change return type to std::string.
15105 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
15106 returning a std::string.
15107 * xml-tdesc.c (file_read_description_xml): Likewise.
15108
ed771251
AH
151092017-03-24 Alan Hayward <alan.hayward@arm.com>
15110
15111 * regcache.c (regcache_debug_print_register): New function.
15112 * regcache.h (regcache_debug_print_register): New declaration.
15113 * target.c (debug_print_register): Remove.
15114 (target_fetch_registers): Call regcache_debug_print_register.
15115 (target_store_registers): Likewise.
15116
568c1b9f
PB
151172017-03-24 Pádraig Brady <pbrady@fb.com>
15118
15119 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
15120 reference beyond the 'lh->include_dirs' array before accessing to
15121 it.
15122 (psymtab_include_file_name): Likewise.
15123 (dwarf_decode_lines_1): Likewise.
15124 (dwarf_decode_lines): Likewise.
15125 (file_file_name): Likewise.
15126
3e00d44f
SM
151272017-03-23 Simon Marchi <simon.marchi@ericsson.com>
15128
15129 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
15130 inferior_ptid.
15131 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15132 ps_lsetfpregs): Likewise.
15133 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
15134 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
15135 ps_lsetfpregs): Likewise.
15136 * target.c (target_fetch_registers, target_store_registers):
15137 Remove asserts.
15138
077ae656
AH
151392017-03-23 Alan Hayward <alan.hayward@arm.com>
15140
15141 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
15142
1e2b521d
YQ
151432017-03-23 Yao Qi <yao.qi@linaro.org>
15144
15145 * aarch64-tdep.c (aarch64_process_record_test): Declare.
15146 (_initialize_aarch64_tdep): Register it.
15147 (aarch64_record_load_store): Handle PRFM instruction.
15148 (aarch64_process_record_test): New function.
15149
33877125
YQ
151502017-03-23 Yao Qi <yao.qi@linaro.org>
15151
15152 * aarch64-tdep.c (aarch64_record_load_store): Fix code
15153 indentation.
15154
a0eef940
YQ
151552017-03-23 Yao Qi <yao.qi@linaro.org>
15156
15157 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
15158
3f2a3564
PR
151592017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
15160
15161 python/python.c (do_start_initialization): Fix memory leak.
15162
b67aeab0
SM
151632017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
15164
15165 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
15166 using get_ptrace_pid.
15167 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
15168 inferior_ptid.
15169 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
15170 inferior_ptid instead of pid.
15171
ffdbe864
YQ
151722017-03-22 Yao Qi <yao.qi@linaro.org>
15173
15174 * aarch64-tdep.c: Wrap locally used classes in anonymous
15175 namespace.
15176 * arm-tdep.c: Likewise.
15177 * linespec.c: Likewise.
15178 * ui-out.c: Likewise.
15179
9d736fbf
JG
151802017-03-22 Jonah Graham <jonah@kichwacoders.com>
15181
15182 PR gdb/19637
15183 * python/lib/gdb/printer/bound_registers.py: Import sys.
15184
3de88e9a
SM
151852017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15186
15187 * windows-nat.c (do_windows_fetch_inferior_registers): Add
15188 windows_thread_info parameter and use it instead of
15189 current_thread.
15190 (windows_fetch_inferior_registers): Don't set current_thread,
15191 pass the thread to do_windows_fetch_inferior_registers. Use
15192 ptid from regcache instead of inferior_ptid.
15193 (do_windows_store_inferior_registers): Add windows_thread_info
15194 parameter and use it instead of current_thread.
15195 (windows_store_inferior_registers): Don't set current_thread,
15196 pass the thread to do_windows_store_inferior_registers. Use
15197 ptid from regcache instead of inferior_ptid.
15198
0e7b8f61
SM
151992017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15200
15201 * ser-mingw.c (ser_windows_raw): Remove reference to
15202 struct serial::current_timeout.
15203
5badf10a
IR
152042017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15205
15206 PR tdep/20928
15207 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15208 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15209 (sparc64_fsr_type): Fix %fsr decoding.
15210
cee59b3f
TW
152112017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15212
15213 * python/py-record-btrace.c (btpy_insn_data): Change return type
15214 for Python 2.
15215
639a9038
SM
152162017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15217
15218 * spu-linux-nat.c (spu_fetch_inferior_registers,
15219 spu_store_inferior_registers): Use ptid from regcache, set and
15220 restore inferior_ptid.
15221 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15222 Likewise.
15223
bcc0c096
SM
152242017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15225
15226 * i386-linux-nat.c (fetch_register, store_register,
15227 i386_linux_fetch_inferior_registers,
15228 i386_linux_store_inferior_registers): Use ptid from regcache.
15229 * ia64-linux-nat.c (ia64_linux_fetch_register,
15230 ia64_linux_store_register): Likewise.
15231 * inf-ptrace.c (inf_ptrace_fetch_register,
15232 inf_ptrace_store_register): Likewise.
15233 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15234 m32r_linux_store_inferior_registers): Likewise.
15235 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15236 m68kbsd_store_inferior_registers): Likewise.
15237 * m68k-linux-nat.c (fetch_register, store_register,
15238 m68k_linux_fetch_inferior_registers,
15239 m68k_linux_store_inferior_registers): Likewise.
15240 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15241 m88kbsd_store_inferior_registers): Likewise.
15242 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15243 mips_fbsd_store_inferior_registers): Likewise.
15244 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15245 mips64_linux_regsets_store_registers): Likewise.
15246 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15247 mipsnbsd_store_inferior_registers): Likewise.
15248 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15249 mips64obsd_store_inferior_registers): Likewise.
15250 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15251 Likewise.
15252 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15253 ppcfbsd_store_inferior_registers): Likewise.
15254 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15255 ppc_linux_store_inferior_registers): Likewise.
15256 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15257 ppcnbsd_store_inferior_registers): Likewise.
15258 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15259 ppcobsd_store_registers): Likewise.
15260 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15261 Likewise.
15262 * ravenscar-thread.c (ravenscar_fetch_registers,
15263 ravenscar_store_registers, ravenscar_prepare_to_store):
15264 Likewise.
15265 * record-btrace.c (record_btrace_fetch_registers,
15266 record_btrace_store_registers, record_btrace_prepare_to_store):
15267 Likewise.
15268 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15269 Lookup inferior using ptid from regcache, instead of
15270 current_inferior.
15271 * remote.c (remote_fetch_registers, remote_store_registers): Use
15272 ptid from regcache.
15273 * rs6000-nat.c (fetch_register, store_register): Likewise.
15274 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15275 s390_linux_store_inferior_registers): Likewise.
15276 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15277 shnbsd_store_inferior_registers): Likewise.
15278 * sol-thread.c (sol_thread_fetch_registers,
15279 sol_thread_store_registers): Likewise.
15280 * sparc-nat.c (sparc_fetch_inferior_registers,
15281 sparc_store_inferior_registers): Likewise.
15282 * tilegx-linux-nat.c (fetch_inferior_registers,
15283 store_inferior_registers): Likewise.
15284 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15285 vaxbsd_store_inferior_registers): Likewise.
15286 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15287 store_xtregs): Likewise.
15288
c0f55cc6
AV
152892017-03-20 Artemiy Volkov <artemiyv@acm.org>
15290
15291 PR gdb/14441
15292 * NEWS: Mention support for rvalue references in GDB and python.
15293 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15294 supports both lvalue and rvalue references.
15295
15c0a2a9
AV
152962017-03-20 Artemiy Volkov <artemiyv@acm.org>
15297
15298 PR gdb/14441
15299 * gdbtypes.c (rank_one_type): Implement overloading
15300 resolution rules regarding rvalue references.
15301
aa006118
AV
153022017-03-20 Artemiy Volkov <artemiyv@acm.org>
15303
15304 PR gdb/14441
15305 * aarch64-tdep.c (aarch64_type_align)
15306 (aarch64_extract_return_value, aarch64_store_return_value): Change
15307 lvalue reference type checks to general reference type checks.
15308 * amd64-tdep.c (amd64_classify): Likewise.
15309 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15310 Likewise.
15311 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15312 (arm_store_return_value): Likewise.
15313 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15314 * c-typeprint.c (c_print_type): Likewise.
15315 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15316 (cplus_number_of_children, cplus_describe_child): Likewise.
15317 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15318 * completer.c (expression_completer): Likewise.
15319 * cp-support.c (make_symbol_overload_list_adl_namespace):
15320 Likewise.
15321 * darwin-nat-info.c (info_mach_region_command): Likewise.
15322 * dwarf2loc.c (entry_data_value_coerce_ref)
15323 (value_of_dwarf_reg_entry): Likewise.
15324 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15325 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15326 Likewise.
15327 * findvar.c (extract_typed_address, store_typed_address):
15328 Likewise.
15329 * gdbtypes.c (rank_one_type): Likewise.
15330 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15331 * infcall.c (value_arg_coerce): Likewise.
15332 * language.c (pointer_type): Likewise.
15333 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15334 Likewise.
15335 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15336 * mn10300-tdep.c (mn10300_type_align): Likewise.
15337 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15338 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15339 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15340 Likewise.
15341 * printcmd.c (print_formatted, x_command): Likewise.
15342 * python/py-type.c (typy_get_composite, typy_template_argument):
15343 Likewise.
15344 * python/py-value.c (valpy_referenced_value)
15345 (valpy_get_dynamic_type, value_has_field): Likewise.
15346 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15347 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15348 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15349 * spu-tdep.c (spu_scalar_value_p): Likewise.
15350 * symtab.c (lookup_symbol_aux): Likewise.
15351 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15352 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15353 Likewise.
15354 * valops.c (value_cast_pointers, value_cast)
15355 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15356 (value_struct_elt, value_struct_elt_bitpos)
15357 (value_find_oload_method_list, find_overload_match)
15358 (value_rtti_indirect_type): Likewise.
15359 * valprint.c (val_print_scalar_type_p, generic_val_print):
15360 Likewise.
15361 * value.c (value_actual_type, value_as_address, unpack_long)
15362 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15363 (coerce_ref): Likewise.
15364 * varobj.c (varobj_get_value_type): Likewise.
15365
3fcf899d
AV
153662017-03-20 Artemiy Volkov <artemiyv@acm.org>
15367
15368 PR gdb/14441
15369 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15370 table of constants.
15371 * python/lib/gdb/command/explore.py: Support exploring values
15372 of rvalue reference types.
15373 * python/lib/gdb/types.py: Implement get_basic_type() for
15374 rvalue reference types.
15375 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15376 constant.
15377 * python/py-value.c (valpy_getitem): Add an rvalue reference
15378 check.
15379 (valpy_reference_value): Add new parameter "refcode".
15380 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15381 New wrappers for valpy_reference_value().
15382 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15383 (gdbpy_invoke_xmethod): Likewise.
15384
4297a3f0
AV
153852017-03-20 Artemiy Volkov <artemiyv@acm.org>
15386
15387 PR gdb/14441
15388 * dwarf2read.c (process_die, read_type_die_1): Handle the
15389 DW_TAG_rvalue_reference_type DIE.
15390 (read_tag_reference_type): Add new parameter "refcode".
15391
e1cb3213
AV
153922017-03-20 Artemiy Volkov <artemiyv@acm.org>
15393
15394 PR gdb/14441
15395 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15396 (c_type_print_modifier, c_type_print_varspec_suffix)
15397 (c_type_print_base): Support printing rvalue reference types.
15398 * c-valprint.c (c_val_print, c_value_print): Support printing
15399 rvalue reference values.
15400
e4347c89
AV
154012017-03-20 Artemiy Volkov <artemiyv@acm.org>
15402
15403 PR gdb/14441
15404 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15405 typename.
15406 * cp-support.c (replace_typedefs): Handle
15407 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15408 * python/py-type.c (typy_lookup_type): Likewise.
15409
53cc15f5
AV
154102017-03-20 Artemiy Volkov <artemiyv@acm.org>
15411
15412 PR gdb/14441
15413 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15414 * parse.c (insert_type): Change assert statement.
15415 (follow_types): Handle rvalue reference types.
15416 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15417 constant.
15418
a65cfae5
AV
154192017-03-20 Artemiy Volkov <artemiyv@acm.org>
15420
15421 PR gdb/14441
15422 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15423 value_ref() interface.
15424 * c-valprint.c (c_value_print): Likewise.
15425 * infcall.c (value_arg_coerce): Likewise.
15426 * python/py-value.c (valpy_reference_value): Likewise.
15427 * valops.c (value_cast, value_reinterpret_cast)
15428 (value_dynamic_cast, typecmp): Likewise.
15429 (value_ref): Parameterize by kind of return value reference type.
15430 * value.h (value_ref): Add new parameter "refcode".
15431
3b224330
AV
154322017-03-20 Artemiy Volkov <artemiyv@acm.org>
15433
15434 PR gdb/14441
15435 * dwarf2read.c (read_tag_reference_type): Use
15436 lookup_lvalue_reference_type() instead of lookup_reference_type().
15437 * eval.c (evaluate_subexp_standard): Likewise.
15438 * f-exp.y: Likewise.
15439 * gdbtypes.c (make_reference_type, lookup_reference_type):
15440 Generalize with rvalue reference types.
15441 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15442 convenience wrappers for lookup_reference_type().
15443 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15444 reference kind parameter.
15445 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15446 wrappers for lookup_reference_type().
15447 * guile/scm-type.c (gdbscm_type_reference): Use
15448 lookup_lvalue_reference_type() instead of lookup_reference_type().
15449 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15450 * parse.c (follow_types): Likewise.
15451 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15452 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15453 Likewise.
15454 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15455 (gdbpy_invoke_xmethod): Likewise.
15456 * stabsread.c: Provide extra argument to make_reference_type()
15457 call.
15458 * valops.c (value_ref, value_rtti_indirect_type): Use
15459 lookup_lvalue_reference_type() instead of lookup_reference_type().
15460
f9aeb8d4
AV
154612017-03-20 Artemiy Volkov <artemiyv@acm.org>
15462
15463 PR gdb/14441
15464 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15465 (TYPE_IS_REFERENCE): New macro.
15466 (struct type): Add rvalue_reference_type field.
15467 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15468
51457a05
MAL
154692017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15470
15471 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15472 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15473 New function definition.
15474 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15475 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15476 New function declaration.
15477 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15478 * mi/mi-interp.h: New file.
15479 * solib.c (info_sharedlibrary_command): Replace for loop with
15480 ALL_SO_LIBS macro
15481 * solib.h (update_solib_list): New function declaration.
15482 (so_list_head): Move macro.
15483 * solist.h (ALL_SO_LIBS): New macro.
15484
e696b3ad
MAL
154852017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15486
15487 * infcmd.c (post_create_inferior): Remove unused argument in
15488 call to solib_add.
15489 * remote.c (remote_start_remote): Likewise.
15490 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15491 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15492 (enable_break): Likewise.
15493 * solib.c (update_solib_list): Remove unused target argument
15494 and its documentation.
15495 (solib_add): Remove unused target argument. Remove unused
15496 argument in call to update_solib_list.
15497 (info_sharedlibrary_command): Remove unused argument in call
15498 to update_solib_list.
15499 (sharedlibrary_command): Remove unused argument in call to
15500 solib_add.
15501 (handle_solib_event): Likewise.
15502 (reload_shared_libraries): Likewise.
15503 * solib.h (solib_add): Remove unused target argument.
15504
dcb84eda
AA
155052017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15506
15507 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15508 (s390_displaced_step_fixup): Cover relative branches with the
15509 default fixup handling. This fixes lack of support for some
15510 relative branch instructions.
15511
d9cb6cdc
SM
155122017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15513
15514 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15515 ptid from regcache.
15516
1afaf9f4
SM
155172017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15518
15519 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15520 i386_darwin_store_inferior_registers): Use ptid from regcache.
15521
aac12e24
SM
155222017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15523
15524 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15525 i386bsd_store_inferior_registers): Use ptid from regcache.
15526
bbe1eef1
SM
155272017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15528
15529 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15530 hppaobsd_store_registers): Use ptid from regcache.
15531
10799020
SM
155322017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15533
15534 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15535 hppanbsd_store_registers): Use ptid from regcache.
15536
00204cf7
SM
155372017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15538
15539 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
15540 from regcache. Use get_ptrace_pid.
15541
11a33714
SM
155422017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15543
15544 * corelow.c (get_core_register_section): Use ptid from regcache,
15545 update doc.
15546
317cd492
SM
155472017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15548
15549 * bsd-uthread.c (bsd_uthread_fetch_registers,
15550 bsd_uthread_store_registers): Use ptid from regcache, set and
15551 restore inferior_ptid.
15552
9ac8a7c2
SM
155532017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15554
15555 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
15556 fetch_fp_regs, store_register, store_regs, store_fp_register,
15557 store_fp_regs): Use ptid from regcache.
15558
4ac4bb6a
SM
155592017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15560
15561 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
15562 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
15563 store_vfp_regs): Use ptid from regcache.
15564
9bcbdca8
PA
155652017-03-17 Pedro Alves <palves@redhat.com>
15566
15567 PR remote/21188
15568 * ser-base.c (ser_base_wait_for): Add comment.
15569 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
15570 version.
15571 * ser-unix.c (hardwire_raw): Remove reference to
15572 scb->current_timeout.
15573 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
15574 (hardwire_ops): Install ser_base_readchar instead of
15575 hardwire_readchar.
15576 * serial.h (struct serial) <current_timeout, timeout_remaining>:
15577 Remove fields.
15578
7503099f
JG
155792017-03-17 Jonah Graham <jonah@kichwacoders.com>
15580
15581 PR gdb/19637
15582 * python/lib/gdb/printer/bound_registers.py: Add support for
15583 Python 3.
15584
7942e96e
AA
155852017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
15586
15587 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
15588 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
15589 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
15590 byte_offset to subobj_byte_offset. Fix the handling of
15591 DWARF_VALUE_STACK on big-endian targets when coming via an
15592 implicit pointer.
15593 (dwarf2_evaluate_loc_desc): Adjust call to
15594 dwarf2_evaluate_loc_desc_full.
15595 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
15596 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
15597
ba14f379
YQ
155982017-03-16 Yao Qi <yao.qi@linaro.org>
15599
15600 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
15601 and REVSH instructions.
15602
b121eeb9
YQ
156032017-03-16 Yao Qi <yao.qi@linaro.org>
15604
15605 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
15606 (arm_record_test): Declare.
15607 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
15608 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
15609 align with the manual.
15610 (thumb_record_misc): Adjust the code order to align with the
15611 manual.
15612 (thumb2_record_decode_insn_handler): Fix instruction matching.
15613 (instruction_reader_thumb): New class.
15614 (arm_record_test): New function.
15615
728a7913
YQ
156162017-03-16 Yao Qi <yao.qi@linaro.org>
15617
15618 * arm-tdep.c (abstract_memory_reader): New class.
15619 (instruction_reader): New class.
15620 (extract_arm_insn): Add argument 'reader'. Callers updated.
15621 (decode_insn): Likewise.
15622
34b43320
DE
156232017-03-16 Doug Evans <dje@google.com>
15624
a7c0469f
DE
15625 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
15626 member. Change type of TYPE member to SCM. All uses updated.
15627 (lsscm_make_lazy_string_smob): Add assert.
15628 (lsscm_make_lazy_string): Flag bad length values.
15629 (lsscm_elt_type): New function.
15630 (gdbscm_lazy_string_to_value): Rewrite to use
15631 lsscm_safe_lazy_string_to_value.
15632 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
15633 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
15634 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
15635 in incoming type.
15636 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15637 * guile/scm-type.c (tyscm_scm_to_type): New function.
15638
156392017-03-15 Doug Evans <dje@google.com>
15640
34b43320
DE
15641 PR python/17728, python/18439, python/18779
15642 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
15643 member. Change type of TYPE member to PyObject *. All uses updated.
15644 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
15645 (gdbpy_create_lazy_string_object): Flag bad length values.
15646 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
15647 Handle typedefs in incoming type.
15648 (stpy_lazy_string_elt_type): New function.
15649 (gdbpy_extract_lazy_string): Call it.
15650 * python/py-value.c (valpy_lazy_string): Flag bad length values.
15651 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
15652 typedefs in incoming type.
15653
a3a5fecc
DE
156542017-03-16 Doug Evans <dje@google.com>
15655
15656 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15657 * guile/scm-type.c (tyscm_scm_to_type): New function.
15658
28f1c605
JW
156592017-03-16 Jiong Wang <jiong.wang@arm.com>
15660
15661 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
15662 "ULONGEST" for "skip".
15663
87c336f6
AA
156642017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15665
15666 PR gdb/21220
15667 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
15668 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
15669 (inf_ptrace_peek_poke): ...here. New function. Now also loop
15670 over ptrace peek/poke until end of buffer or error.
15671
cf81cf60
SM
156722017-03-14 Simon Marchi <simon.marchi@ericsson.com>
15673
15674 * parse.c (length_of_subexp): Make static.
15675 * parser-defs.h (length_of_subexp): Remove.
15676
a379284a
AA
156772017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15678
15679 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
15680 as well.
15681
8a6200ba
PA
156822017-03-14 Pedro Alves <palves@redhat.com>
15683
15684 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
15685 (main): Use std::unique_ptr. Remove calls to
15686 cp_demangled_name_parse_free.
15687
f79ec206
SM
156882017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15689
15690 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
15691 alphabsd_store_inferior_registers): Use regcache->ptid instead
15692 of inferior_ptid.
15693
edb5fb00
SM
156942017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15695
15696 * aix-thread.c (aix_thread_fetch_registers,
15697 aix_thread_store_registers): Use regcache->ptid instead of
15698 inferior_ptid.
15699
55119686
SM
157002017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15701
15702 * aarch64-linux-nat.c (fetch_gregs_from_thread,
15703 store_gregs_to_thread, fetch_fpregs_from_thread,
15704 store_fpregs_to_thread): Use regcache->ptid instead of
15705 inferior_ptid.
15706
6a06fbb7
SM
157072017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15708
15709 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
15710 amd64_linux_fetch_inferior_registers): Use regcache->ptid
15711 instead of inferior_ptid.
15712
c6386875
SM
157132017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15714
15715 * target.c (target_fetch_registers, target_store_registers): Add
15716 assert.
15717
ddaaf0fb
SM
157182017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15719
15720 * regcache.h (regcache_get_ptid): New function.
15721 * regcache.c (regcache_get_ptid): New function.
15722
b9da89d1 157232017-03-13 Mark Wielaard <mark@klomp.org>
15724
15725 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
15726
5f4d1085
KS
157272017-03-10 Keith Seitz <keiths@redhat.com>
15728
15729 PR c++/8218
15730 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
15731
c65d6b55
PA
157322017-03-08 Pedro Alves <palves@redhat.com>
15733
15734 PR gdb/18360
15735 * infrun.c (start_step_over, do_target_resume, resume)
15736 (restart_threads): Assert we're not resuming a thread that is
15737 meant to be stopped.
15738 (infrun_thread_stop_requested_callback): Delete.
15739 (infrun_thread_stop_requested): If the thread is internally
15740 stopped, queue a pending stop event and clear the thread's
15741 inline-frame state.
15742 (handle_stop_requested): New function.
15743 (handle_syscall_event, handle_inferior_event_1): Use
15744 handle_stop_requested.
15745 (handle_stop_requested): New function.
15746 (handle_signal_stop): Set the thread's stop_signal here instead of
15747 at caller.
15748 (finish_step_over): Clear step over info unconditionally.
15749 (handle_signal_stop): If the user had interrupted the event
15750 thread, consider the stop a random signal.
15751 (handle_signal_stop) <signal arrived while stepping over
15752 breakpoint>: Don't restart threads here.
15753 (stop_waiting): Don't clear step-over info here.
15754
15c22686
PA
157552017-03-08 Pedro Alves <palves@redhat.com>
15756
15757 PR 21206
15758 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
15759 goes to argument 2, not 1.
15760
6e5d74e7
PA
157612017-03-08 Pedro Alves <palves@redhat.com>
15762
15763 PR cli/21218
15764 * top.c (gdb_readline_wrapper): Avoid passing NULL to
15765 display_gdb_prompt.
15766 (command_line_input): Add comment.
15767
9753a2f6
PA
157682017-03-08 Pedro Alves <palves@redhat.com>
15769
15770 PR tui/21216
15771 * tui/tui-file.c (tui_file::write): New.
15772 * tui/tui-file.h (tui_file): Override "write".
15773 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
15774 factored out from ...
15775 (tui_puts): ... here.
15776 (tui_putc): Use them.
15777 (tui_write): New function.
15778 * tui/tui-io.h (tui_write): Declare.
15779
1672e0d9
SDJ
157802017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
15781
15782 * Makefile.in (SFILES): Replace "environ.c" with
15783 "common/environ.c".
15784 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
15785 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
15786 to...
15787 * common/environ.c: ... here.
15788 * environ.h: Moved to...
15789 * common/environ.h: ... here.
15790
f7bb4e3a
PB
157912017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15792
15793 * gdbarch.sh (pstring_ptr): New static function.
15794 (gdbarch_disassembler_options): Use it.
15795 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
15796 not valid_disassembler_option->name.
15797 * gdbarch.c: Regenerate.
15798
e45ced6c
PB
157992017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15800
15801 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
15802
5f6fd321
PA
158032017-03-07 Pedro Alves <palves@redhat.com>
15804
15805 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
15806
6dbb839a 158072017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
15808
15809 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
15810 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
15811 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 15812 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 15813
d274ecf4
SM
158142017-03-06 Simon Marchi <simon.marchi@ericsson.com>
15815
15816 * xtensa-linux-nat.c (fetch_gregs): Remove const.
15817
df97be55
SM
158182017-03-03 Simon Marchi <simon.marchi@ericsson.com>
15819
15820 * remote.c (remote_add_target_side_commands): Use range-based
15821 for loop.
15822
7d45f3df
YQ
158232017-03-03 Yao Qi <yao.qi@linaro.org>
15824
15825 PR gdb/21165
15826 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
15827 value is lazy.
15828 * valprint.c (common_val_print): Likewise.
15829
65b48a81
PB
158302017-02-28 Peter Bergner <bergner@vnet.ibm.com>
15831
15832 * NEWS: Mention new set/show disassembler-options commands.
15833 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
15834 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
15835 (prospective_options): New static variable.
15836 (gdb_disassembler::gdb_disassembler): Initialize
15837 m_di.disassembler_options.
15838 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
15839 (get_disassembler_options): New function.
15840 (set_disassembler_options): Likewise.
15841 (set_disassembler_options_sfunc): Likewise.
15842 (show_disassembler_options_sfunc): Likewise.
15843 (disassembler_options_completer): Likewise.
15844 (_initialize_disasm): Likewise.
15845 * disasm.h (get_disassembler_options): New prototype.
15846 (set_disassembler_options): Likewise.
15847 * gdbarch.sh (gdbarch_disassembler_options): New variable.
15848 (gdbarch_verify_disassembler_options): Likewise.
15849 * gdbarch.c: Regenerate.
15850 * gdbarch.h: Likewise.
15851 * arm-tdep.c (num_disassembly_options): Delete.
15852 (set_disassembly_style): Likewise.
15853 (arm_disassembler_options): New static variable.
15854 (set_disassembly_style_sfunc): Convert short style name into long
15855 option name. Call set_disassembler_options.
15856 (show_disassembly_style_sfunc): New function.
15857 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
15858 set_gdbarch_verify_disassembler_options.
15859 (_initialize_arm_tdep): Delete regnames variable and update callers.
15860 (arm_disassembler_options): Initialize.
15861 (disasm_options): New variable.
15862 (num_disassembly_options): Rename from this...
15863 (num_disassembly_styles): ...to this. Compute by scanning through
15864 disasm_options.
15865 (valid_disassembly_styles): Initialize using disasm_options.
15866 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
15867 set_arm_regname_option.
15868 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
15869 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
15870 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
15871 set_gdbarch_verify_disassembler_options.
15872 * s390-tdep.c (s390_disassembler_options): New static variable.
15873 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
15874 set_gdbarch_verify_disassembler_options.
15875
d538e36d
SM
158762017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15877
15878 * remote.c (remote_add_target_side_condition): Remove "struct"
15879 keyword from range-based for loop.
15880
83621223
SM
158812017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15882
15883 * remote.c (remote_add_target_side_condition): Use range-based
15884 for loop. Update comment.
15885
2123df0e
YQ
158862017-02-27 Yao Qi <yao.qi@linaro.org>
15887
15888 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
15889
8e368124
AH
158902017-02-26 Alan Hayward <alan.hayward@arm.com>
15891
15892 * regcache.c (regcache_raw_update): New function.
15893 (regcache_raw_read): Move code to regcache_raw_update.
15894 * regcache.h (regcache_raw_update): New declaration.
15895 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
15896
a49dd8dd
JK
158972017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
15898
15899 * dwarf2read.c (create_debug_type_hash_table): Initialize
15900 header.signature and header.type_offset_in_tu.
15901
34e4bae9
PA
159022017-02-24 Pedro Alves <palves@redhat.com>
15903
15904 * symtab.c (make_file_symbol_completion_list_1): Use
15905 add_symtab_completions.
15906
b0e4b369
AH
159072017-02-24 Alan Hayward <alan.hayward@arm.com>
15908
15909 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
15910
975c21ab
AH
159112017-02-24 Alan Hayward <alan.hayward@arm.com>
15912
15913 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
15914 I386_MAX_REGISTER_SIZE.
15915 (i386_pseudo_register_write): Likewise.
15916 (i386_process_record): Likewise.
15917 * i387-tdep.c (i387_supply_xsave): Likewise.
15918 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
15919 (store_register): Likewise.
15920
14bc53a8
PA
159212017-02-23 Pedro Alves <palves@redhat.com>
15922
15923 * ada-lang.c: Include "common/function-view.h".
15924 (ada_iterate_over_symbols): Adjust to use function_view as
15925 callback type.
15926 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
15927 (ada_make_symbol_completion_list): Use a lambda.
15928 (ada_exc_search_name_matches): Delete.
15929 (name_matches_regex): New.
15930 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
15931 * compile/compile-c-support.c: Include "common/function-view.h".
15932 (print_one_macro): Change prototype to accept a ui_file pointer.
15933 (write_macro_definitions): Use a lambda.
15934 * dwarf2read.c: Include "common/function-view.h".
15935 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
15936 (dw2_expand_symtabs_matching): Adjust to use function_view as
15937 callback type.
15938 * language.h: Include "common/function-view.h".
15939 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
15940 function_view as callback type.
15941 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
15942 * linespec.c: Include "common/function-view.h".
15943 (collect_info::add_symbol): New method.
15944 (struct symbol_and_data_callback, iterate_inline_only, struct
15945 symbol_matcher_data, iterate_name_matcher): Delete.
15946 (iterate_over_all_matching_symtabs): Adjust to use function_view
15947 as callback type and lambdas.
15948 (iterate_over_file_blocks): Adjust to use function_view as
15949 callback type.
15950 (decode_compound_collector): Now a class with private fields.
15951 (decode_compound_collector::release_symbols): New method.
15952 (collect_one_symbol): Rename to...
15953 (decode_compound_collector::operator()): ... this and adjust.
15954 (lookup_prefix_sym): decode_compound_collector construction bits
15955 move to decode_compound_collector ctor. Pass the
15956 decode_compound_collector object directly as callback. Remove
15957 cleanups and use decode_compound_collector::release_symbols
15958 instead.
15959 (symtab_collector): Now a class with private fields.
15960 (symtab_collector::release_symtabs): New method.
15961 (add_symtabs_to_list): Rename to...
15962 (symtab_collector::operator()): ... this and adjust.
15963 (collect_symtabs_from_filename): symtab_collector construction
15964 bits move to symtab_collector ctor. Pass the symtab_collector
15965 object directly as callback. Remove cleanups and use
15966 symtab_collector::release_symtabs instead.
15967 (collect_symbols): Delete.
15968 (add_matching_symbols_to_info): Use lambdas.
15969 * macrocmd.c (print_macro_callback): Delete.
15970 (info_macro_command): Use a lambda.
15971 (info_macros_command): Pass print_macro_definition as callable
15972 directly.
15973 (print_one_macro): Remove 'ignore' parameter.
15974 (macro_list_command): Adjust.
15975 * macrotab.c (macro_for_each_data::fn): Now a function_view.
15976 (macro_for_each_data::user_data): Delete field.
15977 (foreach_macro): Adjust to call the function_view.
15978 (macro_for_each): Adjust to use function_view as callback type.
15979 (foreach_macro_in_scope): Adjust to call the function_view.
15980 (macro_for_each_in_scope): Adjust to use function_view as callback
15981 type.
15982 * macrotab.h: Include "common/function-view.h".
15983 (macro_callback_fn): Declare a prototype instead of a pointer.
15984 Remove "user_data" parameter.
15985 (macro_for_each, macro_for_each_in_scope): Adjust to use
15986 function_view as callback type.
15987 * psymtab.c (partial_map_expand_apply)
15988 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
15989 Adjust to use function_view as callback type and to return bool.
15990 (psym_expand_symtabs_matching): Adjust to use function_view as
15991 callback types.
15992 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
15993 to use function_view as callback type and to return bool.
15994 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
15995 callback types.
15996 * symfile.c (expand_symtabs_matching): Adjust to use function_view
15997 as callback types.
15998 * symfile.h: Include "common/function-view.h".
15999 (expand_symtabs_file_matcher_ftype)
16000 (expand_symtabs_symbol_matcher_ftype)
16001 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
16002 return bool.
16003 (quick_symbol_functions::map_symtabs_matching_filename)
16004 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
16005 function_view as callback type and return bool.
16006 (expand_symtabs_matching): Adjust to use function_view as callback
16007 type.
16008 (maintenance_expand_name_matcher)
16009 (maintenance_expand_file_matcher): Delete.
16010 (maintenance_expand_symtabs): Use lambdas.
16011 * symtab.c (iterate_over_some_symtabs): Adjust to use
16012 function_view as callback types and return bool.
16013 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
16014 of a cleanup.
16015 (lookup_symtab_callback): Delete.
16016 (lookup_symtab): Use a lambda.
16017 (iterate_over_symbols): Adjust to use function_view as callback
16018 type.
16019 (struct search_symbols_data, search_symbols_file_matches)
16020 (search_symbols_name_matches): Delete.
16021 (search_symbols): Use a pair of lambdas.
16022 (struct add_name_data, add_macro_name, symbol_completion_matcher)
16023 (symtab_expansion_callback): Delete.
16024 (default_make_symbol_completion_list_break_on_1): Use lambdas.
16025 * symtab.h: Include "common/function-view.h".
16026 (iterate_over_some_symtabs): Adjust to use function_view as
16027 callback type and return bool.
16028 (iterate_over_symtabs): Adjust to use function_view as callback
16029 type.
16030 (symbol_found_callback_ftype): Remove 'data' parameter and return
16031 bool.
16032 (iterate_over_symbols): Adjust to use function_view as callback
16033 type.
16034
07e253aa
PA
160352017-02-23 Pedro Alves <palves@redhat.com>
16036
16037 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
16038 (%.o) <unittests/%.c>: New pattern.
16039 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
16040 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
16041 * common/function-view.h: New file.
16042 * unittests/function-view-selftests.c: New file.
16043 * configure: Regenerate.
16044
8eaf5320
SM
160452017-02-23 Simon Marchi <simon.marchi@ericsson.com>
16046
16047 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
16048 inferior_ptid.
16049 * go32-nat.c (go32_thread_alive): Likewise.
16050
38768751
YQ
160512017-02-23 Yao Qi <yao.qi@linaro.org>
16052
16053 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
16054 delete.
16055
0a8beaba
YQ
160562017-02-23 Yao Qi <yao.qi@linaro.org>
16057
16058 * varobj.c (varobj_clear_saved_item): Use delete instead of
16059 xfree.
16060 (update_dynamic_varobj_children): Likewise.
16061
58fdfd2c
JK
160622017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16063
16064 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
16065
1b90b139
SM
160662017-02-21 Simon Marchi <simon.marchi@ericsson.com>
16067
16068 * common/enum-flags.h (enum_flags::enum_flags): Initialize
16069 m_enum_value to 0 in default constructor.
16070
2039d74e
EBM
160712017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
16072
16073 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
16074 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
16075 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
16076 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
16077 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
16078 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
16079 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
16080 IS_STORE_CONDITIONAL_INSN.
16081
7814882a
JK
160822017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
16083
16084 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
16085
0ae60b63
JK
160862017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16087
16088 * NEWS (Changes since GDB 7.12): Add DWARF-5.
16089
0224619f
JK
160902017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16091
16092 * dwarf2read.c (skip_one_die, read_attribute_value)
16093 (dwarf2_const_value_attr, dump_die_shallow)
16094 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
16095 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
16096
0af92d60
JK
160972017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16098
16099 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
16100 (dwarf_parse_macro_header): Accept DWARF version 5.
16101 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
16102
216f72a1
JK
161032017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16104
16105 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
16106 DW_AT_GNU_*.
16107 * common/common-exceptions.h (enum errors): Likewise.
16108 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
16109 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
16110 (dwarf_expr_context::execute_stack_op): Likewise.
16111 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
16112 Likewise.
16113 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
16114 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
16115 (show_entry_values_debug, call_site_to_target_addr)
16116 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
16117 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
16118 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
16119 (value_of_dwarf_block_entry, indirect_pieced_value)
16120 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
16121 (disassemble_dwarf_expression): Likewise.
16122 * dwarf2read.c (process_die, inherit_abstract_dies)
16123 (read_call_site_scope): Likewise.
16124 * gdbtypes.h (struct func_type, struct call_site_parameter)
16125 (struct call_site): Likewise.
16126 * stack.c (read_frame_arg): Likewise.
16127 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
16128
43988095
JK
161292017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16130
16131 * defs.h (read_unsigned_leb128): New declaration.
16132 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
16133 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
16134 (dwarf2_find_location_expression): Call also
16135 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
16136 * dwarf2loc.h (dwarf2_version): New declaration.
16137 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
16138 rnglists.
16139 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
16140 .debug_rnglists.
16141 (struct dwop_section_names): Add loclists_dwo.
16142 (dwop_section_names): Add .debug_loclists.dwo.
16143 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
16144 (struct dwarf2_per_cu_data): Add dwarf_version.
16145 (struct dwo_sections): Add loclists.
16146 (struct attr_abbrev): Add implicit_const.
16147 (read_indirect_line_string): New declaration.
16148 (read_unsigned_leb128): Delete declaration.
16149 (rcuh_kind): New definition.
16150 (read_and_check_comp_unit_head): Change parameter
16151 is_debug_types_section to section_kind.
16152 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
16153 (read_comp_unit_head): Change parameter abfd to section, add parameter
16154 section_kind. Handle DWARF-5.
16155 (error_check_comp_unit_head): Accept also DWARF version 5.
16156 (read_and_check_comp_unit_head): Change parameter
16157 is_debug_types_section to section_kind.
16158 (read_and_check_type_unit_head): Delete function.
16159 (read_abbrev_offset): Handle DWARF-5.
16160 (create_debug_type_hash_table): Add parameter section_kind. Process
16161 only DW_UT_type. Use signature and type_offset_in_tu from struct
16162 comp_unit_head.
16163 (create_debug_types_hash_table): Update create_debug_type_hash_table
16164 caller.
16165 (create_all_type_units): Call create_debug_type_hash_table.
16166 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
16167 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
16168 caller.
16169 (skip_one_die): Handle DW_FORM_implicit_const.
16170 (dwarf2_rnglists_process): New function.
16171 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
16172 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
16173 (read_attribute_value): Handle DW_FORM_implicit_const,
16174 DW_FORM_line_strp.
16175 (read_attribute): Handle DW_FORM_implicit_const.
16176 (read_indirect_string_at_offset_from): New function from
16177 read_indirect_string_at_offset.
16178 (read_indirect_string_at_offset): Call
16179 read_indirect_string_at_offset_from.
16180 (read_indirect_line_string_at_offset): New function.
16181 (read_indirect_string): New function comment.
16182 (read_indirect_line_string): New function.
16183 (read_unsigned_leb128): Make it global.
16184 (dwarf2_string_attr): Handle DWARF-5.
16185 (add_include_dir_stub, read_formatted_entries): New functions.
16186 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
16187 Handle DWARF-5.
16188 (per_cu_header_read_in): Update read_comp_unit_head caller.
16189 (dwarf2_version): New function.
16190 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
16191 rnglists.
16192 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16193 fields.
16194
22d2f3ab
JK
161952017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16196
16197 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16198
5f46c5a5
JK
161992017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16200
16201 * dwarf2read.c (dwarf2_ranges_process): New function from
16202 dwarf2_ranges_read.
16203 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16204 dwarf2_ranges_process.
16205
78d4d2c5
JK
162062017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16207
16208 * dwarf2read.c (create_debug_type_hash_table): New function from
16209 create_debug_types_hash_table.
16210 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16211 (create_all_type_units, open_and_init_dwo_file): Update
16212 create_debug_types_hash_table callers.
16213
1b076f25
SDJ
162142017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16215
16216 PR gdb/16188
16217 * fork-child.c (trace_start_error): Fix thinko. va_end should
16218 refer to 'ap', not 'args'.
16219
0db8980c
SDJ
162202017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16221 Pedro Alves <palves@redhat.com>
16222
16223 PR gdb/16188
16224 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16225 calls succeeded.
16226 * fork-child.c (trace_start_error): New function.
16227 (trace_start_error_with_name): Likewise.
16228 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16229 * inf-ptrace.c (inf_ptrace_me): Likewise.
16230 * inferior.h (trace_start_error): New prototype.
16231 (trace_start_error_with_name): Likewise.
16232
99e8a4f9
SDJ
162332017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16234
16235 PR gdb/21164
16236 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16237 NULL before using it.
16238 * symmisc.c (maintenance_print_symbols): Likewise.
16239 (maintenance_print_msymbols): Likewise.
16240
4e746bb6
TW
162412017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16242
16243 * NEWS: Add record Python bindings entry.
16244
162452017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16246
16247 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16248 py-record-full.o.
16249 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16250 * python/py-record-btrace.c, python/py-record-btrace.h,
16251 python/py-record-full.c, python/py-record-full.h: New file.
16252 * python/py-record.c: Add include for py-record-btrace.h and
16253 py-record-full.h.
16254 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16255 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16256 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16257 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16258 New definition.
16259 (gdbpy_initialize_btrace): New export.
16260 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16261
162622017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16263
16264 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16265 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16266 * python/py-record.c: New file.
16267 * python/python-internal.h (gdbpy_start_recording,
16268 gdbpy_current_recording, gdpy_stop_recording,
16269 gdbpy_initialize_record): New export.
16270 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16271 (python_GdbMethods): Add gdbpy_start_recording,
16272 gdbpy_current_recording and gdbpy_stop_recording.
16273
162742017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16275
16276 * record-btrace.c (record_btrace_record_method): New function.
16277 (init_record_btrace_ops): Initialize to_record_method.
16278 * record-full.c (record_full_record_method): New function.
16279 (init_record_full_ops, init_record_full_core_ops): Add
16280 record_full_record_method.
16281 * record.h (enum record_method): New enum.
16282 * target-debug.h (target_debug_print_enum_record_method: New define.
16283 * target-delegates.c: Regenerate.
16284 * target.c (target_record_method): New function.
16285 * target.h: Include record.h.
16286 (struct target_ops) <to_record_method>: New field.
16287 (target_record_method): New export.
16288
162892017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16290
16291 * record.h (record_start, record_stop): New export.
16292 * record.c (record_start, record_stop): New function.
16293
162942017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16295
16296 * btrace.c (btrace_fetch): Copy function call segments pointer
16297 into a vector.
16298 (btrace_clear): Clear the vector.
16299 (btrace_find_insn_by_number): Use binary search to find the correct
16300 function call segment.
16301 * btrace.h (brace_fun_p): New typedef.
16302 (struct btrace_thread_info) <functions>: New field.
16303
163042017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16305
16306 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16307 * btrace.c (btrace_decode_error): ... here. New function.
16308 * btrace.h (btrace_decode_error): New export.
16309
163102017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16311
16312 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16313 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16314 btrace_find_insn_by_number): Remove special case for gaps.
16315 * btrace.h (btrace_insn_get_error): New export.
16316 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16317 * record-btrace.c (btrace_insn_history): Print number for gaps.
16318 (record_btrace_info, record_btrace_goto): Handle gaps.
16319
3f77c769
TT
163202017-02-14 Tom Tromey <tom@tromey.com>
16321
16322 PR python/13598:
16323 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16324 event.
16325 * python/py-evts.c (gdbpy_initialize_py_events): Add
16326 before_prompt registry.
16327 * python/py-events.h (events_object) <before_prompt>: New field.
16328
4c2c7ac6
MM
163292017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16330
16331 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16332
5cf30ebf
LM
163332017-02-13 Luis Machado <lgustavo@codesourcery.com>
16334
16335 * symfile (_initialize_symfile): Add usage text to the load command's
16336 help text.
16337
26a06916
SM
163382017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16339
16340 * utils.c (defaulted_query): Don't query on secondary UIs.
16341
0b145e37
TT
163422017-02-10 Tom Tromey <tom@tromey.com>
16343
16344 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16345
2d8365c4
TT
163462017-02-10 Tom Tromey <tom@tromey.com>
16347
16348 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16349 "cleanup" local.
16350 * python/py-type.c (typy_legacy_template_argument): Remove
16351 unnecessary "cleanup" local.
16352
2bb8f231
TT
163532017-02-10 Tom Tromey <tom@tromey.com>
16354
16355 * python/python.c (do_start_initialization): New function, from
16356 _initialize_python.
16357 (_initialize_python): Call do_start_initialization.
16358 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16359 goto.
16360
1bdfaf42
TT
163612017-02-10 Tom Tromey <tom@tromey.com>
16362
16363 * python/py-prettyprint.c (pretty_print_one_value): Use
16364 gdbpy_ref.
16365
88b6faea
TT
163662017-02-10 Tom Tromey <tom@tromey.com>
16367
16368 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16369 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16370 gdbpy_ref.
16371 * python/py-type.c (field_new): Use gdbpy_ref.
16372 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16373 gdbpy_ref.
16374 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16375 (py_free_pspace): Likewise.
16376 (pspace_to_pspace_object): Likewise.
16377 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16378 (py_free_objfile): Likewise.
16379 (objfile_to_objfile_object): Likewise.
16380 * python/py-inferior.c (delete_thread_object): Use
16381 gdbpy_ref.
16382 (infpy_read_memory): Likewise.
16383 (py_free_inferior): Likewise.
16384 * python/py-evtregistry.c (create_eventregistry_object): Use
16385 gdbpy_ref.
16386 * python/py-event.c (create_event_object): Use gdbpy_ref.
16387
7780f186
TT
163882017-02-10 Tom Tromey <tom@tromey.com>
16389
16390 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16391 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16392 used.
16393 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16394 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16395 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16396 python/py-framefilter.c, python/py-function.c,
16397 python/py-inferior.c, python/py-infevents.c,
16398 python/py-linetable.c, python/py-newobjfileevent.c,
16399 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16400 python/py-signalevent.c, python/py-stopevent.c,
16401 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16402 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16403 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16404 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16405
d4b0bb18
TT
164062017-02-10 Tom Tromey <tom@tromey.com>
16407
16408 * ui-out.h (ui_out_emit_type): New class.
16409 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16410 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16411 and ui_out_emit_tuple.
16412 (enumerate_locals): Likewise.
16413 (py_mi_print_variables, py_print_locals, py_print_args): Use
16414 ui_out_emit_list.
16415 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16416 ui_out_emit_list.
16417 * common/gdb_optional.h: New file.
16418
f67f945c
MG
164192017-02-10 Martin Galvan <martingalvan@sourceware.org>
16420
16421 * MAINTAINERS (Write After Approval): Update my e-mail address.
16422
18da0c51
MG
164232017-02-10 Martin Galvan <martingalvan@sourceware.org>
16424
16425 PR gdb/21122
16426 * breakpoint.c (_initialize_breakpoint): Update the help description
16427 of the 'commands' command to indicate that it takes a list argument.
16428
62c14536
SM
164292017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16430
16431 * interps.c (current_interp_set_logging): Remove "return".
16432
ff6fa247
GB
164332017-02-09 Gary Benson <gbenson@redhat.com>
16434
16435 * symtab.c (add_symtab_completions): Prevent NULL pointer
16436 dereference.
16437
a474bd8e
PA
164382017-02-08 Pedro Alves <palves@redhat.com>
16439
16440 * interps.c (interp::interp): Remove reference to quiet_p.
16441 (interp_set): Make static. Remove dead "Switching to" output
16442 code.
16443 (interp_quiet_p, interp_set_quiet): Delete.
16444 (interpreter_exec_cmd): Don't set the interpreter quiet.
16445 * interps.h (interp_quiet_p): Make static.
16446 (class interp) <quiet_p>: Remove field
16447
3d7b173c
JG
164482017-02-08 Jerome Guitton <guitton@adacore.com>
16449
604c4576
JG
16450 * cli/cli-decode.c (find_command_name_length): Make it extern.
16451 * cli/cli-decode.h (find_command_name_length): Declare.
16452 * cli/cli-script.c (command_name_equals, line_first_arg):
16453 New functions.
16454 (process_next_line): Use cli-decode to parse command names.
16455 (build_command_line): Make args a constant pointer.
16456
164572017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 16458
3d7b173c
JG
16459 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16460 Remove case-insensitive search.
16461
1291063d
JM
164622017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16463
16464 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16465 at the end of the line. Avoids an ARI warning.
16466
20b477a7
LM
164672017-02-06 Luis Machado <lgustavo@codesourcery.com>
16468
16469 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16470 rdseed instructions.
16471 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16472
3f7b46f2
IR
164732017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16474
16475 PR tdep/20936
16476 Provide and use sparc32 and sparc64 target description XML files.
16477 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16478 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16479 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16480 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16481 * features/sparc/sparc32-solaris.xml: New file.
16482 * features/sparc/sparc64-solaris.xml: New file.
16483 * features/sparc/sparc32-solaris.c: Generated.
16484 * features/sparc/sparc64-solaris.c: Generated.
16485 * sparc-tdep.h: Account for differences in target descriptions.
16486 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16487 (sparc32_register_type): Use target provided registers.
16488 (validate_tdesc_registers): New function.
16489 (sparc32_gdbarch_init): Use tdesc_has_registers.
16490 Set pseudoregister functions.
16491 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16492 (sparc64_register_type): Use target provided registers.
16493 (sparc64_init_abi): Set pseudoregister functions.
16494
f0fd41c1
TT
164952017-02-03 Tom Tromey <tom@tromey.com>
16496
16497 PR rust/21097:
16498 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16499 with a single member.
16500
d6f9b0fb
PA
165012017-02-03 Pedro Alves <palves@redhat.com>
16502
16503 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16504 (cli_interp_base::~cli_interp_base): New.
16505 (cli_interp): New struct.
16506 (as_cli_interp): Cast the interp itself to cli_interp.
16507 (cli_interpreter_pre_command_loop): Rename to ...
16508 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16509 parameter.
16510 (cli_interpreter_init): Rename to ...
16511 (cli_interp::init): ... this. Remove 'self' parameter. Use
16512 boolean. Make extern.
16513 (cli_interpreter_resume): Rename to ...
16514 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16515 extern.
16516 (cli_interpreter_suspend): Rename to ...
16517 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16518 extern.
16519 (cli_interpreter_exec): Rename to ...
16520 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16521 extern.
16522 (cli_interpreter_supports_command_editing): Rename to ...
16523 (cli_interp_base::supports_command_editing): ... this. Remove
16524 'interp' parameter. Make extern.
16525 (cli_ui_out): Rename to ...
16526 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16527 Make extern.
16528 (cli_set_logging): Rename to ...
16529 (cli_interp_base::set_logging): ... this. Remove 'interp'
16530 parameter. Make extern.
16531 (cli_interp_procs): Delete.
16532 (cli_interp_factory): Adjust to use "new".
16533 * cli/cli-interp.h: Include "interps.h".
16534 (struct cli_interp_base): New struct.
16535 * interps.c (struct interp): Delete. Fields moved to interps.h.
16536 (interp_new): Delete.
16537 (interp::interp, interp::~interp): New.
16538 (interp_set): Use bool, and return void. Assume the interpreter
16539 has suspend, init and resume methods, and that the all return
16540 void.
16541 (set_top_level_interpreter): interp_set returns void.
16542 (interp_ui_out): Adapt.
16543 (current_interp_set_logging): Adapt.
16544 (interp_data): Delete.
16545 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
16546 (interp_exec): Adapt.
16547 (top_level_interpreter_data): Delete.
16548 * interps.h (interp_init_ftype, interp_resume_ftype)
16549 (interp_suspend_ftype, interp_exec_ftype)
16550 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
16551 (class interp): New.
16552 (interp_new): Delete.
16553 (interp_set): Now returns void. Use bool.
16554 (interp_data, top_level_interpreter_data): Delete.
16555 * mi/mi-common.h: Include interps.h.
16556 (class mi_interp): Inherit from interp. Define a ctor. Declare
16557 init, resume, suspect, exec, interp_ui_out, set_logging and
16558 pre_command_loop methods.
16559 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
16560 (mi_interpreter_init): Rename to ...
16561 (mi_interp::init): ... this. Remove the 'interp' parameter, use
16562 bool, return void and make extern. Adjust.
16563 (mi_interpreter_resume): ... Rename to ...
16564 (mi_interp::resume): ... this. Remove the 'data' parameter,
16565 return void and make extern. Adjust.
16566 (mi_interpreter_suspend): ... Rename to ...
16567 (mi_interp::suspend): ... this. Remove the 'data' parameter,
16568 return void and make extern. Adjust.
16569 (mi_interpreter_exec): ... Rename to ...
16570 (mi_interp::exec): ... this. Remove the 'data' parameter and make
16571 extern. Adjust.
16572 (mi_interpreter_pre_command_loop): ... Rename to ...
16573 (mi_interp::pre_command_loop): ... this. Remove the 'self'
16574 parameter and make extern.
16575 (mi_on_normal_stop_1): Adjust.
16576 (mi_ui_out): Rename to ...
16577 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
16578 parameter and make extern. Adjust.
16579 (mi_set_logging): Rename to ...
16580 (mi_interp::set_logging): ... this. Remove the 'interp'
16581 parameter and make extern. Adjust.
16582 (mi_interp_procs): Delete.
16583 (mi_interp_factory): Adjust to use 'new'.
16584 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
16585 (mi_print_exception, mi_execute_command, mi_load_progress):
16586 Adjust.
16587 * tui/tui-interp.c (tui_interp): New class.
16588 (as_tui_interp): Return a tui_interp pointer.
16589 (tui_on_normal_stop, tui_on_signal_received)
16590 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
16591 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
16592 to use interp::interp_ui_out.
16593 (tui_init): Rename to ...
16594 (tui_interp::init): ... this. Remove the 'self' parameter, use
16595 bool, return void and make extern. Adjust.
16596 (tui_resume): Rename to ...
16597 (tui_interp::resume): ... this. Remove the 'data' parameter,
16598 return void and make extern. Adjust.
16599 (tui_suspend): Rename to ...
16600 (tui_interp::suspend): ... this. Remove the 'data' parameter,
16601 return void and make extern. Adjust.
16602 (tui_ui_out): Rename to ...
16603 (tui_interp::interp_ui_out): ... this. Remove the 'self'
16604 parameter, and make extern. Adjust.
16605 (tui_exec): Rename to ...
16606 (tui_interp::exec): ... this. Remove the 'data' parameter and
16607 make extern.
16608 (tui_interp_procs): Delete.
16609 (tui_interp_factory): Use "new".
16610
65c40c95
TT
166112017-02-02 Tom Tromey <tom@tromey.com>
16612
16613 * rust-exp.y (ends_raw_string, space_then_number)
16614 (rust_identifier_start_p): Return bool.
16615 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
16616 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
16617 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
16618 (rust_chartype_p): Return bool.
16619 (val_print_struct, rust_print_struct_def, rust_print_type):
16620 Update.
16621 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
16622 Return bool.
16623
b50f188d
TT
166242017-02-02 Tom Tromey <tom@tromey.com>
16625
16626 * rust-lang.c: Reindent.
16627
03c85b11
TT
166282017-02-02 Tom Tromey <tom@tromey.com>
16629
16630 * rust-lang.h (rust_crate_for_block): Update.
16631 * rust-lang.c (rust_crate_for_block): Return std::string.
16632 (rust_get_disr_info): Use std:;string, not
16633 gdb::unique_xmalloc_ptr.
16634 * rust-exp.y (crate_name): Update.
16635
9b6da501
PA
166362017-02-02 Pedro Alves <palves@redhat.com>
16637
16638 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
16639 field out of gdb_disassembler_test and make it static.
16640
ec4cb20b
PA
166412017-02-02 Pedro Alves <palves@redhat.com>
16642
16643 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
16644 mi1_interp and mi_interp fields.
16645
5be5dbf0
PA
166462017-02-02 Pedro Alves <palves@redhat.com>
16647
616268b6
PA
16648 * cli/cli-interp.c (struct saved_output_files, saved_output):
16649 Moved from cli/cli-logging.c.
16650 (cli_set_logging): New function.
16651 (cli_interp_procs): Install cli_set_logging.
16652 * cli/cli-interp.h (make_logging_output, cli_set_logging):
16653 Declare.
16654 * cli/cli-logging.c (struct saved_output_files, saved_output):
16655 Moved to cli/cli-interp.c.
16656 (pop_output_files): Don't save outputs here.
16657 (make_logging_output): New function.
16658 (handle_redirections): Don't build tee nor save previous outputs
16659 here.
16660 * interps.c (current_interp_set_logging): Change prototype.
16661 Assume there's always a set_logging_proc method installed.
16662 * interps.h (interp_set_logging_ftype): Change prototype.
16663 (current_interp_set_logging): Change prototype and adjust comment.
16664 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
16665 use make_logging_output.
16666 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
166672017-02-02 Pedro Alves <palves@redhat.com>
16668
5be5dbf0
PA
16669 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
16670 from ...
16671 (set_logging_overwrite): ... here.
16672 (logging_no_redirect_file): Delete.
16673 (set_logging_redirect): Don't handle redirection on the fly.
16674 Instead warn that "logging off" / "logging on" is necessary.
16675 (pop_output_files): Delete references to logging_no_redirect_file.
16676 (show_logging_command): Always speak in terms of what will happen
16677 once logging is reenabled.
16678
c99cc448
PA
166792017-02-02 Pedro Alves <palves@redhat.com>
16680
16681 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
16682
8b172ce7
PA
166832017-02-02 Pedro Alves <palves@redhat.com>
16684
16685 * disasm.c (gdb_pretty_print_insn): Rename to ...
16686 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
16687 Remove gdbarch parameter. Adapt to clear the object's buffers
16688 instead of allocating new buffers, and to print using the object's
16689 gdb_disassembler instead of calling gdb_print_insn.
16690 (dump_insns): Use gdb_pretty_print_disassembler.
16691 * disasm.h (gdb_pretty_print_insn): Delete declaration.
16692 (gdb_pretty_print_disassembler): New class.
16693 * record-btrace.c (btrace_insn_history): Use
16694 gdb_pretty_print_disassembler.
16695
d7e74731
PA
166962017-02-02 Pedro Alves <palves@redhat.com>
16697
16698 * ada-lang.c (type_as_string): Use string_file.
16699 * ada-valprint.c (ada_print_floating): Use string_file.
16700 * ada-varobj.c (ada_varobj_scalar_image)
16701 (ada_varobj_get_value_image): Use string_file.
16702 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
16703 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
16704 * breakpoint.c (update_inserted_breakpoint_locations)
16705 (insert_breakpoint_locations, reattach_breakpoints)
16706 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
16707 (print_it_watchpoint): Use string_file.
16708 (save_breakpoints): Use stdio_file.
16709 * c-exp.y (oper): Use string_file.
16710 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
16711 tee_file.
16712 (pop_output_files): Use delete.
16713 (handle_redirections): Use stdio_file and tee_file.
16714 * cli/cli-setshow.c (do_show_command): Use string_file.
16715 * compile/compile-c-support.c (c_compute_program): Use
16716 string_file.
16717 * compile/compile-c-symbols.c (generate_vla_size): Take a
16718 'string_file &' instead of a 'ui_file *'.
16719 (generate_c_for_for_one_variable): Take a 'string_file &' instead
16720 of a 'ui_file *'. Use string_file.
16721 (generate_c_for_variable_locations): Take a 'string_file &'
16722 instead of a 'ui_file *'.
16723 * compile/compile-internal.h (generate_c_for_for_one_variable):
16724 Take a 'string_file &' instead of a 'ui_file *'.
16725 * compile/compile-loc2c.c (push, pushf, unary, binary)
16726 (print_label, pushf_register_address, pushf_register)
16727 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
16728 'ui_file *'. Adjust.
16729 * compile/compile.c (compile_to_object): Use string_file.
16730 * compile/compile.h (compile_dwarf_expr_to_c)
16731 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
16732 'ui_file *'.
16733 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
16734 (replace_typedefs_qualified_name): Use string_file and
16735 obstack_copy0.
16736 * disasm.c (gdb_pretty_print_insn): Use string_file.
16737 (gdb_disassembly): Adjust reference the null_stream global.
16738 (do_ui_file_delete): Delete.
16739 (gdb_insn_length): Use null_stream.
16740 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
16741 * dwarf2loc.c (dwarf2_compile_property_to_c)
16742 (locexpr_generate_c_location, loclist_generate_c_location): Take a
16743 'string_file &' instead of a 'ui_file *'.
16744 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
16745 * dwarf2read.c (do_ui_file_peek_last): Delete.
16746 (dwarf2_compute_name): Use string_file.
16747 * event-top.c (gdb_setup_readline): Use stdio_file.
16748 * gdbarch.sh (verify_gdbarch): Use string_file.
16749 * gdbtypes.c (safe_parse_type): Use null_stream.
16750 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
16751 string_file.
16752 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
16753 'string_file *' instead of a 'ui_file *'.
16754 (gdbscm_arch_disassemble): Use string_file.
16755 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
16756 * guile/scm-ports.c (class ioscm_file_port): Now a class that
16757 inherits from ui_file.
16758 (ioscm_file_port_delete, ioscm_file_port_rewind)
16759 (ioscm_file_port_put): Delete.
16760 (ioscm_file_port_write): Rename to ...
16761 (ioscm_file_port::write): ... this. Remove file_port_magic
16762 checks.
16763 (ioscm_file_port_new): Delete.
16764 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
16765 ui_file_up.
16766 * guile/scm-type.c (tyscm_type_name): Use string_file.
16767 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
16768 Use string_file.
16769 * infcmd.c (print_return_value_1): Use string_file.
16770 * infrun.c (print_target_wait_results): Use string_file.
16771 * language.c (add_language): Use string_file.
16772 * location.c (explicit_to_string_internal): Use string_file.
16773 * main.c (captured_main_1): Use null_file.
16774 * maint.c (maintenance_print_architecture): Use stdio_file.
16775 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
16776 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
16777 event_channel>: Change type to mi_console_file pointer.
16778 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
16779 (mi_console_file_delete): Delete.
16780 (struct mi_console_file): Delete.
16781 (mi_console_file_magic): Delete.
16782 (mi_console_file_new): Delete.
16783 (mi_console_file::mi_console_file): New.
16784 (mi_console_file_delete): Delete.
16785 (mi_console_file_fputs): Delete.
16786 (mi_console_file::write): New.
16787 (mi_console_raw_packet): Delete.
16788 (mi_console_file::flush): New.
16789 (mi_console_file_flush): Delete.
16790 (mi_console_set_raw): Rename to ...
16791 (mi_console_file::set_raw): ... this.
16792 * mi/mi-console.h (class mi_console_file): New class.
16793 (mi_console_file_new, mi_console_set_raw): Delete.
16794 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
16795 (mi_set_logging): Use delete and tee_file. Adjust.
16796 * mi/mi-main.c (output_register): Use string_file.
16797 (mi_cmd_data_evaluate_expression): Use string_file.
16798 (mi_cmd_data_read_memory): Use string_file.
16799 (mi_cmd_execute, print_variable_or_computed): Use string_file.
16800 * mi/mi-out.c (mi_ui_out::main_stream): New.
16801 (mi_ui_out::rewind): Use main_stream and
16802 string_file.
16803 (mi_ui_out::put): Use main_stream and string_file.
16804 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16805 Allocate a 'string_file' instead.
16806 (mi_out_new): Don't allocate a mem_fileopen stream here.
16807 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16808 (mi_ui_out::main_stream): Declare method.
16809 * printcmd.c (eval_command): Use string_file.
16810 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
16811 * python/py-arch.c (archpy_disassemble): Use string_file.
16812 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
16813 * python/py-frame.c (frapy_str): Use string_file.
16814 * python/py-framefilter.c (py_print_type, py_print_single_arg):
16815 Use string_file.
16816 * python/py-type.c (typy_str): Use string_file.
16817 * python/py-unwind.c (unwind_infopy_str): Use string_file.
16818 * python/py-value.c (valpy_str): Use string_file.
16819 * record-btrace.c (btrace_insn_history): Use string_file.
16820 * regcache.c (regcache_print): Use stdio_file.
16821 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
16822 * remote.c (escape_buffer): Use string_file.
16823 * rust-lang.c (rust_get_disr_info): Use string_file.
16824 * serial.c (serial_open_ops_1): Use stdio_file.
16825 (do_serial_close): Use delete.
16826 * stack.c (print_frame_arg): Use string_file.
16827 (print_frame_args): Remove local mem_fileopen stream, not used.
16828 (print_frame): Use string_file.
16829 * symmisc.c (maintenance_print_symbols): Use stdio_file.
16830 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
16831 Take a 'string_file *' instead of a 'ui_file *'.
16832 * top.c (new_ui): Use stdio_file and stderr_file.
16833 (free_ui): Use delete.
16834 (execute_command_to_string): Use string_file.
16835 (quit_confirm): Use string_file.
16836 * tracepoint.c (collection_list::append_exp): Use string_file.
16837 * tui/tui-disasm.c (tui_disassemble): Use string_file.
16838 * tui/tui-file.c: Don't include "ui-file.h".
16839 (enum streamtype, struct tui_stream): Delete.
16840 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
16841 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
16842 (tui_file::tui_file): New method.
16843 (tui_file_fputs): Delete.
16844 (tui_file_get_strbuf): Delete.
16845 (tui_file::puts): New method.
16846 (tui_file_adjust_strbuf): Delete.
16847 (tui_file_flush): Delete.
16848 (tui_file::flush): New method.
16849 * tui/tui-file.h: Tweak intro comment.
16850 Include ui-file.h.
16851 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
16852 (tui_file_adjust_strbuf): Delete declarations.
16853 (class tui_file): New class.
16854 * tui/tui-io.c (tui_initialize_io): Use tui_file.
16855 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
16856 (tui_register_format): Use string_stream.
16857 * tui/tui-stack.c (tui_make_status_line): Use string_file.
16858 (tui_get_function_from_frame): Use string_file.
16859 * typeprint.c (type_to_string): Use string_file.
16860 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
16861 (null_stream): New global.
16862 (ui_file_delete): Delete.
16863 (ui_file::ui_file): New.
16864 (null_file_isatty): Delete.
16865 (ui_file::~ui_file): New.
16866 (null_file_rewind): Delete.
16867 (ui_file::printf): New.
16868 (null_file_put): Delete.
16869 (null_file_flush): Delete.
16870 (ui_file::putstr): New.
16871 (null_file_write): Delete.
16872 (ui_file::putstrn): New.
16873 (null_file_read): Delete.
16874 (ui_file::putc): New.
16875 (null_file_fputs): Delete.
16876 (null_file_write_async_safe): Delete.
16877 (ui_file::vprintf): New.
16878 (null_file_delete): Delete.
16879 (null_file::write): New.
16880 (null_file_fseek): Delete.
16881 (null_file::puts): New.
16882 (ui_file_data): Delete.
16883 (null_file::write_async_safe): New.
16884 (gdb_flush, ui_file_isatty): Adjust.
16885 (ui_file_put, ui_file_rewind): Delete.
16886 (ui_file_write): Adjust.
16887 (ui_file_write_for_put): Delete.
16888 (ui_file_write_async_safe, ui_file_read): Adjust.
16889 (ui_file_fseek): Delete.
16890 (fputs_unfiltered): Adjust.
16891 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
16892 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
16893 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
16894 (set_ui_file_data): Delete.
16895 (string_file::~string_file, string_file::write)
16896 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
16897 (do_ui_file_as_string, ui_file_as_string): Delete.
16898 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
16899 (struct mem_file): Delete.
16900 (mem_file_new): Delete.
16901 (stdio_file::stdio_file): New.
16902 (mem_file_delete): Delete.
16903 (stdio_file::stdio_file): New.
16904 (mem_fileopen): Delete.
16905 (stdio_file::~stdio_file): New.
16906 (mem_file_rewind): Delete.
16907 (stdio_file::set_stream): New.
16908 (mem_file_put): Delete.
16909 (stdio_file::open): New.
16910 (mem_file_write): Delete.
16911 (stdio_file_magic, struct stdio_file): Delete.
16912 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
16913 (stdio_file::flush): New.
16914 (stdio_file_read): Rename to ...
16915 (stdio_file::read): ... this. Adjust.
16916 (stdio_file_write): Rename to ...
16917 (stdio_file::write): ... this. Adjust.
16918 (stdio_file_write_async_safe): Rename to ...
16919 (stdio_file::write_async_safe) ... this. Adjust.
16920 (stdio_file_fputs): Rename to ...
16921 (stdio_file::puts) ... this. Adjust.
16922 (stdio_file_isatty): Delete.
16923 (stdio_file_fseek): Delete.
16924 (stdio_file::isatty): New.
16925 (stderr_file_write): Rename to ...
16926 (stderr_file::write) ... this. Adjust.
16927 (stderr_file_fputs): Rename to ...
16928 (stderr_file::puts) ... this. Adjust.
16929 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
16930 (stderr_file::stderr_file): New.
16931 (tee_file_magic): Delete.
16932 (struct tee_file): Delete.
16933 (tee_file::tee_file): New.
16934 (tee_file_new): Delete.
16935 (tee_file::~tee_file): New.
16936 (tee_file_delete): Delete.
16937 (tee_file_flush): Rename to ...
16938 (tee_file::flush): ... this. Adjust.
16939 (tee_file_write): Rename to ...
16940 (tee_file::write): ... this. Adjust.
16941 (tee_file::write_async_safe): New.
16942 (tee_file_fputs): Rename to ...
16943 (tee_file::puts): ... this. Adjust.
16944 (tee_file_isatty): Rename to ...
16945 (tee_file::isatty): ... this. Adjust.
16946 * ui-file.h (struct obstack, struct ui_file): Don't
16947 forward-declare.
16948 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
16949 (ui_file_write_ftype)
16950 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
16951 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
16952 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
16953 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
16954 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
16955 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
16956 (set_ui_file_fseek): Delete.
16957 (ui_file_data, ui_file_delete, ui_file_rewind)
16958 (struct ui_file): New.
16959 (ui_file_up): New.
16960 (class null_file): New.
16961 (null_stream): Declare.
16962 (ui_file_write_for_put, ui_file_put): Delete.
16963 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
16964 Delete.
16965 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
16966 (gdb_fopen, tee_file_new): Delete.
16967 (struct string_file): New.
16968 (struct stdio_file): New.
16969 (stdio_file_up): New.
16970 (struct stderr_file): New.
16971 (class tee_file): New.
16972 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
16973 of a 'ui_file *'. Adjust.
16974 * ui-out.h (class ui_out) <field_stream>: Likewise.
16975 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
16976 (null_stream): Delete.
16977 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
16978 Adjust.
16979 * utils.h (struct ui_file): Delete forward declaration..
16980 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
16981 (error_stream): Take a 'string_file &' instead of a
16982 'ui_file *'.
16983 * varobj.c (varobj_value_get_print_value): Use string_file.
16984 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
16985 * gdbarch.c: Regenerate.
16986
187808b0
PA
169872017-02-02 Pedro Alves <palves@redhat.com>
16988
16989 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
16990 (gdb_pretty_print_insn): ... this. Now a free function. Add back
16991 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
16992 Adjust to call gdb_print_insn instead of
16993 gdb_disassembler::print_insn.
16994 (dump_insns, do_mixed_source_and_assembly_deprecated)
16995 (do_mixed_source_and_assembly, do_assembly_only): Add back a
16996 'gdbarch' parameter. Remove gdb_disassembler parameter.
16997 (gdb_disassembly): Don't allocate a gdb_disassembler here.
16998 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
16999 declaration.
17000 (gdb_pretty_print_insn): Re-add declaration.
17001 * record-btrace.c (btrace_insn_history): Don't allocate a
17002 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
17003
7a8eb317
SM
170042017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
17005
17006 * disasm.h (gdb_disassembly): Remove file_string parameter.
17007 * disasm.c (gdb_disassembly): Likewise.
17008 * cli/cli-cmds.c (print_disassembly): Adapt.
17009 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
17010 * stack.c (do_gdb_disassembly): Likewise.
17011
7346ef59
AA
170122017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
17013
17014 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
17015 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
17016 targets. And if the implicit value is longer than needed, extract
17017 the first bytes instead of the "least significant" ones.
17018
cd4007e4
MM
170192017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17020
17021 * btrace.c (btrace_enable): Do not call btrace_add_pc for
17022 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
17023 (btrace_fetch): Assert can_access_registers_ptid.
17024 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
17025 validate_registers_access.
17026
cf77c34e
MM
170272017-02-01 Markus Metzger <markus.t.metzger@intel.com>
17028
17029 * gdbthread.h (can_access_registers_ptid): New.
17030 * thread.c (can_access_registers_ptid): New.
17031
be85ce7d
PA
170322017-02-01 Pedro Alves <palves@redhat.com>
17033
17034 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
17035
29b0b251
PA
170362017-01-31 Pedro Alves <palves@redhat.com>
17037
17038 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
17039 Fix typos.
17040
289b5b24
PA
170412017-01-31 Pedro Alves <palves@redhat.com>
17042
17043 * stack.c (print_frame_args): Remove local mem_fileopen stream,
17044 not used.
17045
b47413b4
PA
170462017-01-31 Pedro Alves <palves@redhat.com>
17047
17048 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
17049
60adb36c
PA
170502017-01-31 Pedro Alves <palves@redhat.com>
17051
17052 * common/scoped_restore.h
17053 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
17054 change the value's parameter type to T2.
17055 (make_scoped_restore): Likewise.
17056
2735833d
WT
170572017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17058 Richard Henderson <rth@redhat.com>
17059
17060 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
17061 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
17062 GS_BASE for older kernels.
17063 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
17064 GS_BASE for older kernels.
17065 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
17066 and GS_BASE to the offset table.
17067 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
17068 system register group.
17069 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
17070 for older kernels.
17071 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
17072 amd64 ABI.
17073 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
17074 AMD64_GSBASE_REGNUM.
17075 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
17076 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
17077 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
17078 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
17079 i386/64bit-segments.xml in those rules.
17080 * features/i386/64bit-segments.xml: New file.
17081 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
17082 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
17083 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
17084 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
17085 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
17086 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
17087 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
17088 * features/i386/amd64-avx-linux.c: Regenerated.
17089 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
17090 * features/i386/amd64-avx-mpx.c: Regenerated.
17091 * features/i386/amd64-avx512-linux.c: Regenerated.
17092 * features/i386/amd64-linux.c: Regenerated.
17093 * features/i386/amd64-mpx-linux.c: Regenerated.
17094 * features/i386/i386-avx-mpx-linux.c: Regenerated.
17095 * features/i386/i386-avx-mpx.c: Regenerated.
17096 * features/i386/x32-avx-linux.c: Regenerated.
17097 * features/i386/x32-avx512-linux.c: Regenerated.
17098 * regformats/i386/amd64-avx-linux.dat: Regenerated.
17099 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
17100 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
17101 * regformats/i386/amd64-linux.dat: Regenerated.
17102 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
17103 * regformats/i386/x32-avx-linux.dat: Regenerated.
17104 * regformats/i386/x32-avx512-linux.dat: Regenerated.
17105 * regformats/i386/x32-linux.dat: Regenerated.
17106
8884e97e
WT
171072017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17108
17109 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
17110 Set to AMD64_NUM_REGS.
17111
7005d26a
WT
171122017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
17113
17114 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
17115 that checks validity of a register number.
17116
4bd2e1b2
KC
171172017-01-27 Kees Cook <keescook@google.com>
17118
17119 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
17120 fetch_fpregs if target has fpa registers.
17121 (arm_linux_store_inferior_registers): Call store_fpregs if target
17122 has fpa registers.
17123
7cf1de6c
AA
171242017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
17125
17126 * cris-tdep.c (cris_gdbarch_init): Remove check for
17127 info.byte_order and force it to BFD_ENDIAN_LITTLE.
17128
874a1c8c
AT
171292017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
17130
17131 * corelow.c (get_core_register_section): Check for regset
17132 existence before checking for REGSET_VARIABLE_SIZE.
17133
d8b49cf0
YQ
171342017-01-26 Yao Qi <yao.qi@linaro.org>
17135 Pedro Alves <palves@redhat.com>
17136
17137 PR gdb/20939
17138 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
17139 call memory_error, save memaddr instead.
17140 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
17141 negative, cal memory_error.
17142 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
17143
658ca58c
YQ
171442017-01-26 Yao Qi <yao.qi@linaro.org>
17145
17146 * disasm-selftests.c (memory_error_test): New function.
17147 (_initialize_disasm_selftests): Register memory_error_test.
17148
79843d45
YQ
171492017-01-26 Yao Qi <yao.qi@linaro.org>
17150
17151 * Makefile.in (SFILES): Add disasm-selftests.c and
17152 selftest-arch.c.
17153 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
17154 * disasm-selftests.c: New file.
17155 * selftest-arch.c: New file.
17156 * selftest-arch.h: New file.
17157
8cafda32
YQ
171582017-01-26 Yao Qi <yao.qi@linaro.org>
17159
17160 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
17161 to bfd_arch_mep. Don't return 0 if section is not
17162 found. Call print_insn_mep.
17163
e47ad6c0
YQ
171642017-01-26 Pedro Alves <palves@redhat.com>
17165 Yao Qi <yao.qi@linaro.org>
17166
17167 * arm-tdep.c: Include "disasm.h".
17168 (gdb_print_insn_arm): Update code to get gdbarch.
17169 * disasm.c (dis_asm_read_memory): Change it to
17170 gdb_disassembler::dis_asm_read_memory.
17171 (dis_asm_memory_error): Likewise.
17172 (dis_asm_print_address): Likewise.
17173 (gdb_pretty_print_insn): Change it to
17174 gdb_disassembler::pretty_print_insn.
17175 (dump_insns): Add one argument gdb_disassemlber. All
17176 callers updated.
17177 (do_mixed_source_and_assembly_deprecated): Likewise.
17178 (do_mixed_source_and_assembly): Likewise.
17179 (do_assembly_only): Likewise.
17180 (gdb_disassembler::gdb_disassembler): New.
17181 (gdb_disassembler::print_insn): New.
17182 * disasm.h (class gdb_disassembler): New.
17183 (gdb_pretty_print_insn): Remove declaration.
17184 (gdb_disassemble_info): Likewise.
17185 * guile/scm-disasm.c (class gdbscm_disassembler): New.
17186 (gdbscm_disasm_read_memory_worker): Update.
17187 (gdbscm_disasm_read_memory): Update.
17188 (gdbscm_disasm_memory_error): Remove.
17189 (gdbscm_disasm_print_address): Remove.
17190 (gdbscm_disassembler::gdbscm_disassembler): New.
17191 (gdbscm_print_insn_from_port): Update.
17192 * mips-tdep.c: Include disasm.h.
17193 (gdb_print_insn_mips): Update code to get gdbarch.
17194 * record-btrace.c (btrace_insn_history): Update.
17195 * spu-tdep.c: Include disasm.h.
17196 (struct spu_dis_asm_data): Remove.
17197 (struct spu_dis_asm_info): New.
17198 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17199 SPU id.
17200 (gdb_print_insn_spu): Cast disassemble_info to
17201 spu_dis_asm_info.
17202
80d75874
YQ
172032017-01-26 Yao Qi <yao.qi@linaro.org>
17204
17205 * disasm.c (do_ui_file_delete): Delete.
17206 (gdb_insn_length): Move code creating stream to ...
17207 * utils.c (null_stream): ... here. New function.
17208 * utils.h (null_stream): Declare.
17209
60685cd0
SM
172102017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17211
17212 * python/py-inferior.c (find_thread_object): Return directly
17213 from the loop. Remove "found" variable.
17214
eb1cdb62
JB
172152017-01-21 Joel Brobecker <brobecker@adacore.com>
17216
17217 GDB 7.12.1 released.
17218
b1ce6568
SM
172192017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17220
17221 * python/py-function.c (fnpy_call): Reorder declarations to have
17222 the gdbpy_enter object declared first.
17223 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17224
6f8b0407
SM
172252017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17226
fec93fb1 17227 PR python/21068
6f8b0407
SM
17228 * python/python-internal.h (PyMem_RawMalloc): Define for
17229 Python < 3.4.
17230 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17231 PyMem_RawMalloc instead of PyMem_Malloc.
17232
78cbbba8
LM
172332017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17234 Luis Machado <lgustavo@codesourcery.com>
17235
17236 * NEWS (New commands): Mention flash-erase.
17237 (New MI commands): Mention target-flash-erase.
17238 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17239 command.
17240 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17241 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17242 * target.c (flash_erase_command): New function.
17243 (initialize_targets): Add new flash-erase command.
17244 * target.h (flash_erase_command): New declaration.
17245
2132fe85
JB
172462017-01-20 Joel Brobecker <brobecker@adacore.com>
17247
17248 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17249 HAVE_SYS_PROCFS_H is defined.
17250
d1dff226
AH
172512017-01-18 Alan Hayward <alan.hayward@arm.com>
17252
17253 * remote.c (struct cached_reg): Change data into a pointer.
17254 * (stop_reply_dtr): Free data pointers before deleting vector.
17255 (process_stop_reply): Likewise.
17256 (remote_parse_stop_reply): Allocate space for data
17257
9890e433
AH
172582017-01-18 Alan Hayward <alan.hayward@arm.com>
17259
17260 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17261 MAX_REGISTER_SIZE.
17262 (amd64_pseudo_register_read_value): Likewise.
17263 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17264 (store_register_using_P): Likewise.
17265 * regcache.c (regcache_xfer_part): Likewise.
17266
7a36499a
IR
172672017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17268
17269 Split real and pseudo registers.
17270 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17271 (sparc32_pseudo_regnum): New enum.
17272 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17273 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17274 (SPARC32_CP0_REGISTERS): New macro.
17275 (sparc32_pseudo_register_name): New function.
17276 (sparc32_register_name): Use sparc32_pseudo_register_name.
17277 (sparc32_pseudo_register_type): New function.
17278 (sparc32_register_type): Use sparc32_pseudo_register_type.
17279 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17280 pseudo register numbers.
17281 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17282 (SPARC64_CP0_REGISTERS): New macro.
17283 (sparc64_pseudo_register_name): New function.
17284 (sparc64_register_name): Use sparc64_pseudo_register_name.
17285 (sparc64_pseudo_register_type): New function.
17286 (sparc64_register_type): Use sparc64_pseudo_register_type.
17287 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17288 pseudo register numbers.
17289 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17290 sparc64_store_arguments): Handle pseudo register numbers.
17291
6f8976bf
YQ
172922017-01-13 Yao Qi <yao.qi@linaro.org>
17293
17294 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17295 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17296 output.
17297 (getpkt_or_notif_sane_1): Likewise.
17298
e4241ace
YQ
172992017-01-13 Yao Qi <yao.qi@linaro.org>
17300
17301 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17302 of CC. Pass "-x c++-header" instead of "-x c".
17303
3015c064
SM
173042017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17305
17306 * remote.c (remote_can_async_p): Update comment.
17307
fde1b17d
SM
173082017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17309
17310 * linux-nat.c (linux_nat_can_async_p): Update comment.
17311
ca1ca08b
SM
173122017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17313
17314 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17315
4ad2da73
SM
173162017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17317
17318 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17319
c8b23b3f
TT
173202017-01-10 Tom Tromey <tom@tromey.com>
17321
17322 * python/py-type.c (typy_legacy_template_argument): Update.
17323 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17324 ~demangle_parse_info): Declare new members.
17325 (cp_demangled_name_to_comp): Return unique_ptr.
17326 (cp_demangled_name_parse_free)
17327 (make_cleanup_cp_demangled_name_parse_free)
17328 (cp_new_demangle_parse_info): Remove.
17329 * cp-support.c (do_demangled_name_parse_free_cleanup)
17330 (make_cleanup_cp_demangled_name_parse_free): Remove.
17331 (inspect_type, cp_canonicalize_string_full)
17332 (cp_canonicalize_string): Update.
17333 (mangled_name_to_comp): Change return type.
17334 (cp_class_name_from_physname, method_name_from_physname)
17335 (cp_func_name, cp_remove_params): Update.
17336 * cp-name-parser.y (demangle_parse_info): New constructor, from
17337 cp_new_demangle_parse_info.
17338 (~demangle_parse_info): New destructor, from
17339 cp_demangled_name_parse_free.
17340 (cp_merge_demangle_parse_infos): Update.
17341 (cp_demangled_name_to_comp): Change return type.
17342
1ac32117
TT
173432017-01-10 Tom Tromey <tom@tromey.com>
17344
17345 * top.c (prevent_dont_repeat): Change return type.
17346 * python/python.c (execute_gdb_command): Use std::string.
17347 Update.
17348 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17349 * command.h (prevent_dont_repeat): Change return type.
17350 * breakpoint.c (bpstat_do_actions_1): Update.
17351
0cf08227
TT
173522017-01-10 Tom Tromey <tom@tromey.com>
17353
17354 * value.h (scoped_value_mark::~scoped_value_mark): Call
17355 free_to_mark.
17356 (scoped_value_mark::free_to_mark): New method.
17357 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17358 scoped_value_mark.
17359
eb115069
TT
173602017-01-10 Tom Tromey <tom@tromey.com>
17361
17362 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17363 (valpy_reference_value, valpy_const_value, valpy_get_address)
17364 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17365 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17366 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17367 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17368 scoped_value_mark.
17369 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17370 * value.h (scoped_value_mark): New class.
17371
906768f9
TT
173722017-01-10 Tom Tromey <tom@tromey.com>
17373
17374 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17375 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17376 * psymtab.c (discard_psymtabs_upto): Remove.
17377 (make_cleanup_discard_psymtabs): Remove.
17378 (struct psymtab_state): Remove.
17379
bef155c3
TT
173802017-01-10 Tom Tromey <tom@tromey.com>
17381
17382 * record-full.c (record_full_save_cleanups): Remove.
17383 (record_full_save): Use gdb::unlinker.
17384 * gcore.c (do_bfd_delete_cleanup): Remove.
17385 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17386 cleanups.
17387 * dwarf2read.c (unlink_if_set): Remove.
17388 (write_psymtabs_to_index): Use gdb::unlinker.
17389 * common/gdb_unlinker.h: New file.
17390
192b62ce
TT
173912017-01-10 Tom Tromey <tom@tromey.com>
17392
17393 * windows-tdep.c (windows_xfer_shared_library): Update.
17394 * windows-nat.c (windows_make_so): Update.
17395 * utils.h (make_cleanup_bfd_unref): Remove.
17396 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17397 * symfile.h (symfile_bfd_open)
17398 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17399 * symfile.c (read_symbols, symbol_file_add)
17400 (separate_debug_file_exists): Update.
17401 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17402 (generic_load, reread_symbols): Update.
17403 * symfile-mem.c (symbol_file_add_from_memory): Update.
17404 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17405 (spu_symbol_file_add_from_memory): Update.
17406 * solist.h (struct target_so_ops) <bfd_open>: Return
17407 gdb_bfd_ref_ptr.
17408 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17409 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17410 gdb_bfd_ref_ptr.
17411 (solib_map_sections, reload_shared_libraries_1): Update.
17412 * solib-svr4.c (enable_break): Update.
17413 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17414 * solib-frv.c (enable_break2): Update.
17415 * solib-dsbt.c (enable_break): Update.
17416 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17417 gdb_bfd_ref_ptr.
17418 (darwin_solib_get_all_image_info_addr_at_init): Update.
17419 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17420 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17421 * record-full.c (record_full_save): Update.
17422 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17423 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17424 * minidebug.c (find_separate_debug_file_in_section): Return
17425 gdb_bfd_ref_ptr.
17426 * machoread.c (macho_add_oso_symfile): Change abfd to
17427 gdb_bfd_ref_ptr.
17428 (macho_symfile_read_all_oso): Update.
17429 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17430 (macho_symfile_read): Update.
17431 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17432 (jit_bfd_try_read_symtab): Update.
17433 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17434 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17435 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17436 gdb_bfd_ref_ptr.
17437 (gdb_bfd_ref_policy): New struct.
17438 (gdb_bfd_ref_ptr): New typedef.
17439 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17440 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17441 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17442 gdb_bfd_ref_ptr.
17443 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17444 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17445 (gcore_command): Update.
17446 * exec.c (exec_file_attach): Update.
17447 * elfread.c (elf_symfile_read): Update.
17448 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17449 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17450 (open_and_init_dwo_file): Update.
17451 (open_dwp_file): Return gdb_bfd_ref_ptr.
17452 (open_and_init_dwp_file): Update.
17453 * corelow.c (core_open): Update.
17454 * compile/compile-object-load.c (compile_object_load): Update.
17455 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17456 * coffread.c (coff_symfile_read): Update.
17457 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17458 gdb_bfd_ref_ptr. Rename.
17459 (dump_bfd_file, restore_command): Update.
17460 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17461 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17462 (find_separate_debug_file_by_buildid): Update.
17463
50315b21
TT
174642017-01-10 Tom Tromey <tom@tromey.com>
17465
17466 * common/gdb_ref_ptr.h: New file.
17467 * python/py-ref.h (struct gdbpy_ref_policy): New.
17468 (gdbpy_ref): Now a typedef.
17469
fc4007c9
TT
174702017-01-10 Tom Tromey <tom@tromey.com>
17471
17472 * utils.h (make_cleanup_htab_delete): Don't declare.
17473 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17474 Remove.
17475 * linespec.c (decode_compound_collector): Add constructor,
17476 destructor.
17477 (lookup_prefix_sym): Remove cleanup.
17478 (symtab_collector): Add constructor, destructor.
17479 (collect_symtabs_from_filename): Remove cleanup.
17480 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17481 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17482 Use htab_up.
17483 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17484 * dwarf2read.c (dw2_expand_symtabs_matching)
17485 (dw2_map_symbol_filenames, dwarf_decode_macros)
17486 (write_psymtabs_to_index): Use htab_up.
17487 * dwarf2loc.c (func_verify_no_selftailcall)
17488 (call_site_find_chain_1, func_verify_no_selftailcall)
17489 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17490 std::vector, gdb::unique_xmalloc_ptr.
17491 (call_sitep): Remove typedef.
17492 (dwarf2_locexpr_baton_eval): Remove unused variable.
17493
8dbcee67
TT
174942017-01-10 Tom Tromey <tom@tromey.com>
17495
17496 * python/python-internal.h (make_cleanup_py_decref)
17497 (make_cleanup_py_xdecref): Don't declare.
17498 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17499 (py_xdecref, make_cleanup_py_xdecref): Remove.
17500
13df46cc
TT
175012017-01-10 Tom Tromey <tom@tromey.com>
17502
17503 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17504 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17505
06fc9bf7
TT
175062017-01-10 Tom Tromey <tom@tromey.com>
17507
17508 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17509
830a4934
TT
175102017-01-10 Tom Tromey <tom@tromey.com>
17511
17512 * python/py-utils.c (unicode_to_encoded_string)
17513 (python_string_to_target_string)
17514 (python_string_to_target_python_string)
17515 (python_string_to_host_string, gdbpy_obj_to_string)
17516 (get_addr_from_python): Use gdbpy_ref.
17517
4586d543
TT
175182017-01-10 Tom Tromey <tom@tromey.com>
17519
17520 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17521 gdbpy_ref.
17522
59876f8f
TT
175232017-01-10 Tom Tromey <tom@tromey.com>
17524
17525 * python/python.c (eval_python_command, gdbpy_decode_line)
17526 (gdbpy_run_events, gdbpy_start_type_printers)
17527 (gdbpy_apply_type_printers): Use gdbpy_ref.
17528
97d83487
TT
175292017-01-10 Tom Tromey <tom@tromey.com>
17530
17531 * python/py-param.c (get_doc_string, compute_enum_values): Use
17532 gdbpy_ref.
17533
9205649a
TT
175342017-01-10 Tom Tromey <tom@tromey.com>
17535
17536 * python/py-inferior.c (find_thread_object, build_inferior_list):
17537 Use gdbpy_ref.
17538
74c49d45
TT
175392017-01-10 Tom Tromey <tom@tromey.com>
17540
17541 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17542
16361ffb
TT
175432017-01-10 Tom Tromey <tom@tromey.com>
17544
17545 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
17546 gdbpy_ref.
17547
905f2cca
TT
175482017-01-10 Tom Tromey <tom@tromey.com>
17549
17550 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
17551 extra incref.
17552 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
17553 Use gdbpy_ref.
17554
64081434
TT
175552017-01-10 Tom Tromey <tom@tromey.com>
17556
17557 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17558 gdbpy_ref.
17559
59e9e831
TT
175602017-01-10 Tom Tromey <tom@tromey.com>
17561
17562 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
17563 decref results of PyArg_ParseTupleAndKeywords.
17564
9de10f6d
TT
175652017-01-10 Tom Tromey <tom@tromey.com>
17566
17567 * python/python.c (python_run_simple_file): Use
17568 unique_xmalloc_ptr, gdbpy_ref.
17569
2bd5759d
TT
175702017-01-10 Tom Tromey <tom@tromey.com>
17571
17572 * python/py-prettyprint.c (print_stack_unless_memory_error)
17573 (print_string_repr, print_children): Use gdbpy_ref.
17574 (dummy_python_frame): New class.
17575 (dummy_python_frame::dummy_python_frame): Rename from
17576 push_dummy_python_frame.
17577 (py_restore_tstate): Remove.
17578
3b4e0e01
TT
175792017-01-10 Tom Tromey <tom@tromey.com>
17580
17581 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17582
17a22718
TT
175832017-01-10 Tom Tromey <tom@tromey.com>
17584
17585 * python/python.c (ensure_python_env, restore_python_env):
17586 Remove.
17587 * python/python-internal.h (ensure_python_env): Don't declare.
17588 * varobj.h (varobj_ensure_python_env): Don't declare.
17589 * varobj.c (varobj_ensure_python_env): Remove.
17590
68cdc557
TT
175912017-01-10 Tom Tromey <tom@tromey.com>
17592
17593 * varobj.c (varobj_value_get_print_value): Use
17594 gdbpy_enter_varobj.
17595
1eba6383
TT
175962017-01-10 Tom Tromey <tom@tromey.com>
17597
17598 * python/py-prettyprint.c (print_string_repr, print_children):
17599 Update.
17600 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
17601 of "encoding".
17602 * varobj.c (varobj_value_get_print_value): Update.
17603 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
17604
bde7b3e3
TT
176052017-01-10 Tom Tromey <tom@tromey.com>
17606
17607 * varobj.c (varobj_get_display_hint)
17608 (dynamic_varobj_has_child_method, install_new_value_visualizer)
17609 (varobj_set_visualizer, free_variable): Use
17610 gdbpy_enter_varobj.
17611
a7785f8c
TT
176122017-01-10 Tom Tromey <tom@tromey.com>
17613
17614 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
17615 (do_finish_initialization): New function. Use gdbpy_ref.
17616 (gdbpy_finish_initialization): Use gdbpy_enter. Call
17617 do_finish_initialization.
17618
2865bfce
TT
176192017-01-10 Tom Tromey <tom@tromey.com>
17620
17621 * python/py-param.c (get_set_value, get_show_value): Use
17622 gdbpy_enter, gdbpy_ref.
17623
0e9dcc75
TT
176242017-01-10 Tom Tromey <tom@tromey.com>
17625
17626 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
17627
12a5cedd
TT
176282017-01-10 Tom Tromey <tom@tromey.com>
17629
17630 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
17631
788f2586
TT
176322017-01-10 Tom Tromey <tom@tromey.com>
17633
17634 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
17635 Use gdbpy_enter_varobj.
17636
6cd67bea
TT
176372017-01-10 Tom Tromey <tom@tromey.com>
17638
17639 * varobj.c (gdbpy_enter_varobj): New constructor.
17640 * python/python-internal.h (gdbpy_enter_varobj): New class.
17641 * python/py-varobj.c (py_varobj_get_iterator): Use
17642 gdbpy_enter_varobj.
17643
14b122bf
TT
176442017-01-10 Tom Tromey <tom@tromey.com>
17645
17646 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
17647 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17648 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
17649 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
17650 unique_xmalloc_ptr.
17651 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
17652
bf1ca3b9
TT
176532017-01-10 Tom Tromey <tom@tromey.com>
17654
17655 * python/py-xmethods.c (invoke_match_method): Use
17656 gdbpy_ref.
17657
572a5524
TT
176582017-01-10 Tom Tromey <tom@tromey.com>
17659
17660 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
17661 gdbpy_enter, gdbpy_ref.
17662
396a78b6
TT
176632017-01-10 Tom Tromey <tom@tromey.com>
17664
17665 * python/python.c (python_interactive_command): Use gdbpy_enter.
17666
a88b13c7
TT
176672017-01-10 Tom Tromey <tom@tromey.com>
17668
17669 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
17670 gdbpy_ref.
17671
e9f0c363
TT
176722017-01-10 Tom Tromey <tom@tromey.com>
17673
17674 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
17675 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17676
6349f452
TT
176772017-01-10 Tom Tromey <tom@tromey.com>
17678
17679 * utils.h (htab_deleter): New struct.
17680 (htab_up): New typedef.
17681 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
17682 gdbpy_enter, gdbpy_ref, htab_up.
17683
c0171de6
TT
176842017-01-10 Tom Tromey <tom@tromey.com>
17685
17686 * python/py-unwind.c (pending_frame_invalidate): Remove.
17687 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
17688
f18e226f
TT
176892017-01-10 Tom Tromey <tom@tromey.com>
17690
17691 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
17692 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
17693
c57af3f1
TT
176942017-01-10 Tom Tromey <tom@tromey.com>
17695
17696 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
17697
60e600ec
TT
176982017-01-10 Tom Tromey <tom@tromey.com>
17699
17700 * python/python.c (gdbpy_eval_from_control_command)
17701 (gdbpy_source_script, gdbpy_run_events)
17702 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
17703 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
17704 gdbpy_enter.
17705
bf7da5b0
TT
177062017-01-10 Tom Tromey <tom@tromey.com>
17707
17708 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
17709
2d38bced
TT
177102017-01-10 Tom Tromey <tom@tromey.com>
17711
17712 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
17713
07bc7329
TT
177142017-01-10 Tom Tromey <tom@tromey.com>
17715
17716 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
17717 (python_on_inferior_call_pre, python_on_inferior_call_post)
17718 (python_on_memory_change, python_on_register_change)
17719 (python_inferior_exit, python_new_objfile, add_thread_object)
17720 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
17721
6e7c365e
TT
177222017-01-10 Tom Tromey <tom@tromey.com>
17723
17724 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
17725 (bpfinishpy_handle_exit): Use gdbpy_enter.
17726
6ba0cd40
TT
177272017-01-10 Tom Tromey <tom@tromey.com>
17728
17729 * python/py-cmd.c (cmdpy_destroyer)
17730 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
17731 gdbpy_enter.
17732
de2dc875
TT
177332017-01-10 Tom Tromey <tom@tromey.com>
17734
17735 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17736 gdbpy_enter.
17737 (gdbpy_breakpoint_has_cond): Likewise.
17738
4ecee2c4
TT
177392017-01-10 Tom Tromey <tom@tromey.com>
17740
17741 * python/python.c (gdbpy_enter): New constructor.
17742 (~gdbpy_enter): New destructor.
17743 (restore_python_env, ensure_python_env): Rewrite.
17744 * python/python-internal.h (gdbpy_enter): New class.
17745
37fce74f
TT
177462017-01-10 Tom Tromey <tom@tromey.com>
17747
17748 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
17749
53a0cca3
TT
177502017-01-10 Tom Tromey <tom@tromey.com>
17751
17752 * python/py-value.c (value_has_field, get_field_flag)
17753 (get_field_type, valpy_getitem, convert_value_from_python): Use
17754 gdbpy_ref.
17755
ff3724f5
TT
177562017-01-10 Tom Tromey <tom@tromey.com>
17757
17758 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
17759 gdbpy_ref.
17760
0700aea5
TT
177612017-01-10 Tom Tromey <tom@tromey.com>
17762
17763 * python/py-prettyprint.c (search_pp_list)
17764 (find_pretty_printer_from_objfiles)
17765 (find_pretty_printer_from_progspace)
17766 (find_pretty_printer_from_gdb, find_pretty_printer)
17767 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
17768 gdbpy_ref.
17769
1bb44c9f
TT
177702017-01-10 Tom Tromey <tom@tromey.com>
17771
17772 * python/py-param.c (call_doc_function): Use gdbpy_ref.
17773
87ce03fd
TT
177742017-01-10 Tom Tromey <tom@tromey.com>
17775
17776 * python/py-linetable.c (build_line_table_tuple_from_pcs)
17777 (ltpy_get_all_source_lines): Use gdbpy_ref.
17778
ee0a3fb8
TT
177792017-01-10 Tom Tromey <tom@tromey.com>
17780
17781 * python/py-framefilter.c (extract_sym, extract_value)
17782 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
17783 gdbpy_ref.
17784
bf2a52fa
TT
177852017-01-10 Tom Tromey <tom@tromey.com>
17786
17787 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
17788
f59fe7f8
TT
177892017-01-10 Tom Tromey <tom@tromey.com>
17790
17791 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
17792
80bd970a
TT
177932017-01-10 Tom Tromey <tom@tromey.com>
17794
17795 * python/py-function.c (convert_values_to_python, fnpy_init): Use
17796 gdbpy_ref.
17797
d1b3de2e
TT
177982017-01-10 Tom Tromey <tom@tromey.com>
17799
17800 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
17801
3bb43384
TT
178022017-01-10 Tom Tromey <tom@tromey.com>
17803
17804 * python/py-type.c (convert_field, make_fielditem, typy_fields)
17805 (typy_range): Use gdbpy_ref.
17806
abf5651e
TT
178072017-01-10 Tom Tromey <tom@tromey.com>
17808
17809 * python/py-threadevent.c (create_thread_event_object): Use
17810 gdbpy_ref.
17811 * python/py-stopevent.c (create_stop_event_object): Simplify.
17812 (emit_stop_event): Use gdbpy_ref.
17813 * python/py-signalevent.c (create_signal_event_object): Use
17814 gdbpy_ref.
17815 * python/py-newobjfileevent.c (create_new_objfile_event_object)
17816 (emit_new_objfile_event, create_clear_objfiles_event_object)
17817 (emit_clear_objfiles_event): Use gdbpy_ref.
17818 * python/py-infevents.c (create_inferior_call_event_object)
17819 (create_register_changed_event_object)
17820 (create_memory_changed_event_object, emit_inferior_call_event)
17821 (emit_memory_changed_event, emit_register_changed_event): Use
17822 gdbpy_ref.
17823 * python/py-exitedevent.c (create_exited_event_object)
17824 (emit_exited_event): Use gdbpy_ref.
17825 * python/py-event.h (evpy_emit_event): Remove
17826 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
17827 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
17828 * python/py-continueevent.c (emit_continue_event): Use
17829 gdbpy_ref.
17830 * python/py-breakpoint.c (gdbpy_breakpoint_created)
17831 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
17832 gdbpy_ref.
17833 * python/py-bpevent.c (create_breakpoint_event_object): Use
17834 gdbpy_ref.
17835
a68ff33e
TT
178362017-01-10 Tom Tromey <tom@tromey.com>
17837
17838 * python/py-ref.h: New file.
17839
7becfd03
SM
178402017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17841
17842 * cli-out.c (cli_ui_out::do_redirect): Change return type to
17843 void.
17844 * cli-out.h (cli_ui_out::do_redirect): Likewise.
17845 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
17846 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
17847 * ui-out.c (ui_out::redirect): Likewise.
17848 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
17849 * cli/cli-logging.c (set_logging_redirect): Update call site of
17850 ui_out::redirect.
17851 (handle_redirections): Likewise.
17852 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
17853 * top.c (execute_command_to_string): Likewise.
17854 * utils.c (do_ui_out_redirect_pop): Likewise.
17855
df294654
SM
178562017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17857
17858 * stack.c (_initialize_stack): Update "frame" command help message.
17859
f5e6296e
IB
178602017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
17861
17862 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
17863
0e2d6fa6
YQ
178642017-01-06 Yao Qi <yao.qi@linaro.org>
17865
17866 * x86-linux-nat.h: Include gdb_proc_service.h.
17867
44d6d3f9
YQ
178682017-01-06 Yao Qi <yao.qi@linaro.org>
17869
17870 * ser-base.h: Include serial.h.
17871
656731fe
YQ
178722017-01-06 Yao Qi <yao.qi@linaro.org>
17873
17874 * ppc-linux-tdep.h: Include ppc-tdep.h.
17875
1ca8f924
YQ
178762017-01-06 Yao Qi <yao.qi@linaro.org>
17877
17878 * nat/amd64-linux-siginfo.h: Include signal.h.
17879
bc3008c4
YQ
178802017-01-06 Yao Qi <yao.qi@linaro.org>
17881
17882 * nat/aarch64-linux-hw-point.h: Include break-common.h.
17883
66c80d03
YQ
178842017-01-06 Yao Qi <yao.qi@linaro.org>
17885
17886 * mi/mi-parse.h: Include mi-cmds.h.
17887
051d2dda
YQ
178882017-01-06 Yao Qi <yao.qi@linaro.org>
17889
17890 * inf-loop.c: Don't include "target.h".
17891 * inf-loop.h: Include it here.
17892
8018d34f
YQ
178932017-01-06 Yao Qi <yao.qi@linaro.org>
17894
17895 * dfp.h: Include "dboulest.h" and "expression.h".
17896
c0b8369c
YQ
178972017-01-06 Yao Qi <yao.qi@linaro.org>
17898
17899 * ax-gdb.h: Include "ax.h".
17900
ad5cba2a
YQ
179012017-01-06 Yao Qi <yao.qi@linaro.org>
17902
17903 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
17904 with nat/gdb_ptrace.h.
17905
1c33cd7f
YQ
179062017-01-05 Yao Qi <yao.qi@linaro.org>
17907
17908 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
17909 new line.
17910 (mips64_fbsd_sigframe_init): Likewise.
17911
c988ac1d
JB
179122017-01-04 John Baldwin <jhb@FreeBSD.org>
17913
17914 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
17915 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
17916
b268007c
JB
179172017-01-04 John Baldwin <jhb@FreeBSD.org>
17918
17919 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
17920 * NEWS: Mention new FreeBSD/mips native configuration.
17921 * config/mips/fbsd.mh: New file.
17922 * configure.host: Add mips*-*-freebsd*.
17923 * mips-fbsd-nat.c: New file.
17924
387360da
JB
179252017-01-04 John Baldwin <jhb@FreeBSD.org>
17926
17927 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
17928 (ALLDEPFILES): Add mips-fbsd-tdep.c.
17929 * NEWS: Mention new FreeBSD/mips target.
17930 * configure.tgt: Add mips*-*-freebsd*.
17931 * mips-fbsd-tdep.c: New file.
17932 * mips-fbsd-tdep.h: New file.
17933
2aaaf250
YQ
179342017-01-04 Yao Qi <yao.qi@linaro.org>
17935
17936 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
17937 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
17938
61baf725
JB
179392017-01-01 Joel Brobecker <brobecker@adacore.com>
17940
6dbb839a 17941 Update copyright year range in all GDB files.
61baf725 17942
c113e7ff 179432017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 17944
c113e7ff 17945 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 17946
c113e7ff 17947For older changes see ChangeLog-2016.
c906108c
SS
17948\f
17949Local Variables:
17950mode: change-log
17951left-margin: 8
17952fill-column: 74
17953version-control: never
57da7796 17954coding: utf-8
c906108c 17955End:
This page took 2.882691 seconds and 4 git commands to generate.