]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Split tdesc_type into multiple classes
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
d4a0e8b5
SM
12017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
2
3 * target-descriptions.c (struct tdesc_type): Use default
4 destructor.
5 <u>: Remove.
6 <accept>: Remove.
7 (struct tdesc_type_builtin): New.
8 (struct tdesc_type_vector): New.
9 (struct tdesc_type_with_fields): New.
10 (tdesc_predefined_types): Change type to tdesc_type_builtin[].
11 (tdesc_gdb_type): Remove.
12 (tdesc_register_type): Adjust.
13 (tdesc_create_vector): Create tdesc_type_vector.
14 (tdesc_create_struct): Create tdesc_type_with_fields.
15 (tdesc_set_struct_size): Change parameter type.
16 (tdesc_create_union): Create tdesc_type_with_fields.
17 (tdesc_create_flags): Likewise.
18 (tdesc_create_enum): Likewise.
19 (tdesc_add_field): Change parameter type.
20 (tdesc_add_typed_bitfield): Likewise.
21 (tdesc_add_bitfield): Likewise.
22 (tdesc_add_flag): Likewise.
23 (tdesc_add_enum_value): Likewise.
24 (print_c_tdesc) <visit>: Remove overload with tdesc_type
25 parameter, add overloads for tdesc_type_builtin,
26 tdesc_type_with_fields and tdesc_type_vector.
27 <m_printed_type>: Remove.
28 <m_printed_element_type, m_printed_type_with_fields>: Add.
29 * target-descriptions.h (tdesc_create_enum): Change return type.
30 (tdesc_add_typed_bitfield): Change parameter type.
31 (tdesc_add_enum_value): Change parameter type.
32 * xml-tdesc.c (struct tdesc_parsing_data) <current_type>: Change
33 type to tdesc_type_with_fields.
34 (tdesc_start_struct): Adjust.
35 (tdesc_start_flags): Adjust.
36 (tdesc_start_enum): Adjust.
37 (tdesc_start_field): Adjust.
38 * arch/tdesc.h (struct tdesc_type_builtin): Forward-declare.
39 (struct tdesc_type_vector): Forward-declare.
40 (struct tdesc_type_with_fields): Forward-declare.
41 (tdesc_create_struct): Change return type.
42 (tdesc_create_union): Likewise.
43 (tdesc_create_flags): Likewise.
44 (tdesc_add_field): Change parameter type.
45 (tdesc_set_struct_size): Likewise.
46 (tdesc_add_bitfield): Likewise.
47 (tdesc_add_flag): Likewise.
48 * features: Re-generate C files.
49
f0cddbef
SM
502017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
51
52 * target-descriptions.c (tdesc_arch_reg): Remove typedef.
53 (struct tdesc_arch_reg): Add constructor.
54 (DEF_VEC_O (tdesc_arch_reg)): Remove.
55 (struct tdesc_arch_data): Initialize fields.
56 <arch_regs>: Change type to std::vector.
57 (target_find_description): Adjust.
58 (tdesc_find_type): Adjust.
59 (tdesc_data_init): Call tdesc_arch_data constructor.
60 (tdesc_data_alloc): Allocate tdesc_arch_data with new.
61 (tdesc_data_cleanup): Free data with delete.
62 (tdesc_numbered_register): Adjust.
63 (tdesc_find_arch_register): Adjust.
64 (tdesc_use_registers): Adjust.
65
d05200d1
SM
662017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
67
68 * target-descriptions.c (tdesc_type_field): Remove typedef.
69 (DEF_VEC_O (tdesc_type_field)): Remove.
70 (struct tdesc_type_field): Add constructor.
71 <name>: Change type to std::string.
72 (struct tdesc_type) <tdesc_type>: Instantiate vector if the type
73 kind uses it.
74 <~tdesc_type>: Destroy vector if the type kind uses it.
75 <u::u::fields>: Change type to std::vector.
76 (tdesc_gdb_type): Adjust.
77 (tdesc_add_field): Adjust.
78 (tdesc_add_typed_bitfield): Adjust.
79 (tdesc_add_field): Adjust.
80 (tdesc_add_enum_value): Adjust.
81 (class print_c_tdesc) <visit>: Adjust.
82
082b9140
SM
832017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
84
85 * target-descriptions.c (struct tdesc_type) <name>: Change type
86 to std::string.
87 <~tdesc_type>: Don't manually free name.
88 <operator==>: Adjust.
89 (tdesc_named_type): Adjust.
90 (tdesc_find_type): Adjust.
91 (tdesc_gdb_type): Adjust.
92 (class print_c_tdesc) <visit>: Adjust.
93
53c934e9
SM
942017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
95
96 * target-descriptions.c (tdesc_type_p): Remove typedef.
97 (DEF_VEC_P (tdesc_type_p)): Remove.
98 (struct tdesc_feature) <types>: Change type to std::vector.
99 <~tdesc_feature>: Replace with default implementation.
100 <accept>: Adjust.
101 (tdesc_named_type): Adjust.
102 (tdesc_create_vector): Adjust.
103 (tdesc_create_struct): Adjust.
104 (tdesc_create_union): Adjust.
105 (tdesc_create_flags): Adjust.
106 (tdesc_create_enum): Adjust.
107
a8142ee1
SM
1082017-12-05 Simon Marchi <simon.marchi@ericsson.com>
109
110 * target-descriptions.c (struct tdesc_reg) <tdesc_reg>: Change
111 type of name_ parameter, adjust to std::string change.
112 <name, group, type>: Change type to std::string.
113 <~tdesc_reg>: Replace with default implementation.
114 <operator==>: Adjust.
115 (tdesc_find_register_early): Adjust.
116 (tdesc_register_name): Adjust.
117 (tdesc_register_type): Adjust.
118 (tdesc_register_in_reggroup_p): Adjust.
119 (class print_c_tdesc) <visit>: Adjust.
120 (class print_c_feature) <visit>: Adjust.
121
c9c895b9
SM
1222017-12-05 Simon Marchi <simon.marchi@ericsson.com>
123
124 * target-descriptions.c (tdesc_reg_p): Remove typedef.
125 (DEF_VEC_P (tdesc_reg_p)): Remove.
126 (struct tdesc_feature) <registers>: Change type to std::vector.
127 <~tdesc_feature>: Don't manually free registers.
128 <accept>: Adjust.
129 <operator==>: Adjust.
130 (tdesc_has_registers): Adjust.
131 (tdesc_find_register_early): Adjust.
132 (tdesc_use_registers): Adjust.
133 (tdesc_create_reg): Adjust.
134
f65ff9f9
SM
1352017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
136
137 * target-descriptions.c (tdesc_feature) <name>: Change type to
138 std::string.
139 <~tdesc_feature>: Don't manually free name.
140 <operator==>: Adjust.
141 (tdesc_find_feature): Adjust.
142 (tdesc_feature_name): Adjust.
143 (class print_c_tdesc) <visit_pre>: Adjust.
144 (class print_c_feature) <visit_pre>: Adjust.
145
3eea796c
SM
1462017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
147
148 * target-descriptions.c (tdesc_feature_p): Remove typedef.
149 (DEF_VEC_P (tdesc_feature_p)): Remove.
150 (struct target_desc) <features>: Change type to std::vector.
151 <~target_desc>: Replace with default implementation.
152 <accept>: Adjust.
153 <operator==>: Adjust.
154 (tdesc_has_registers): Adjust.
155 (tdesc_find_feature): Adjust.
156 (tdesc_use_registers): Adjust.
157 (tdesc_create_feature): Adjust.
158
40e2a983
SM
1592017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
160
161 * target-descriptions.c (arch_p): Remove typedef.
162 (DEF_VEC_P (arch_p)): Remove.
163 (struct target_desc) <compatible>: Change type to std::vector.
164 <~target_desc>: Don't manually free compatible.
165 (tdesc_compatible_p): Adjust.
166 (tdesc_add_compatible): Adjust.
167 (class print_c_tdesc) <visit_pre>: Adjust.
168
129c10bc
SM
1692017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
170
171 * target-descriptions.c (property_s): Remove typedef.
172 (DEF_VEC_O (property_s)): Remove.
173 (struct target_desc) <properties>: Make an std::vector.
174 <~target_desc>: Don't manually free properties.
175 (tdesc_property): Adjust.
176 (set_tdesc_property): Adjust.
177 (class print_c_tdesc) <visit_pre>: Adjust.
178
ed9376bd
SM
1792017-12-05 Simon Marchi <simon.marchi@ericsson.com>
180
181 * common/gdb_assert.h (gdb_static_assert): Redefine using
182 static_assert.
183
798a7429
SM
1842017-12-05 Simon Marchi <simon.marchi@ericsson.com>
185
186 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
187 unused variables.
188 (ada_is_redundant_range_encoding): Likewise.
189 * ada-varobj.c (ada_varobj_get_value_of_array_variable):
190 Likewise.
191 * alpha-tdep.c (alpha_software_single_step): Likewise.
192 * arm-tdep.c (_initialize_arm_tdep): Likewise.
193 * auto-load.c (info_auto_load_cmd): Likewise.
194 * break-catch-syscall.c (insert_catch_syscall): Likewise.
195 (remove_catch_syscall): Likewise.
196 * breakpoint.c (condition_completer): Likewise.
197 (clear_command): Likewise.
198 (update_breakpoint_locations): Likewise.
199 * btrace.c (btrace_disable): Likewise.
200 (btrace_teardown): Likewise.
201 (btrace_maint_update_pt_packets): Likewise.
202 (maint_btrace_clear_cmd): Likewise.
203 * cli/cli-decode.c (lookup_cmd_1): Likewise.
204 (lookup_cmd_composition): Likewise.
205 * cli/cli-dump.c (scan_filename): Likewise.
206 (restore_command): Likewise.
207 * compile/compile-loc2c.c (compute_stack_depth): Likewise.
208 * compile/compile-object-load.c (compile_object_load): Likewise.
209 * compile/compile-object-run.c (compile_object_run): Likewise.
210 * compile/compile.c (compile_to_object): Likewise.
211 * completer.c (filename_completer): Likewise.
212 (complete_files_symbols): Likewise.
213 (complete_expression): Likewise.
214 * corelow.c (core_open): Likewise.
215 * ctf.c (ctf_start): Likewise.
216 (ctf_write_status): Likewise.
217 (ctf_write_uploaded_tsv): Likewise.
218 (ctf_write_definition_end): Likewise.
219 (ctf_open_dir): Likewise.
220 (ctf_xfer_partial): Likewise.
221 (ctf_trace_find): Likewise.
222 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
223 Likewise.
224 * dwarf2loc.c (allocate_piece_closure): Likewise.
225 (indirect_pieced_value): Likewise.
226 (dwarf2_evaluate_loc_desc_full): Likewise.
227 * dwarf2read.c (dw2_expand_marked_cus): Likewise.
228 (dw2_expand_symtabs_matching): Likewise.
229 (dw2_map_symbol_filenames): Likewise.
230 (read_and_check_comp_unit_head): Likewise.
231 (read_cutu_die_from_dwo): Likewise.
232 (lookup_dwo_unit): Likewise.
233 (read_comp_units_from_section): Likewise.
234 (dwarf2_compute_name): Likewise.
235 (handle_DW_AT_stmt_list): Likewise.
236 (create_cus_hash_table): Likewise.
237 (create_dwp_v2_section): Likewise.
238 (dwarf2_rnglists_process): Likewise.
239 (dwarf2_ranges_process): Likewise.
240 (dwarf2_record_block_ranges): Likewise.
241 (is_vtable_name): Likewise.
242 (read_formatted_entries): Likewise.
243 (skip_form_bytes): Likewise.
244 * elfread.c (elf_symtab_read): Likewise.
245 * exec.c (exec_file_command): Likewise.
246 * f-valprint.c (f_val_print): Likewise.
247 (info_common_command_for_block): Likewise.
248 * guile/guile.c (initialize_scheme_side): Likewise.
249 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Likewise.
250 * guile/scm-cmd.c (cmdscm_completer): Likewise.
251 (gdbscm_register_command_x): Likewise.
252 * guile/scm-frame.c (gdbscm_frame_read_var): Likewise.
253 * guile/scm-param.c (gdbscm_parameter_value): Likewise.
254 * guile/scm-ports.c (file_port_magic): Likewise.
255 * guile/scm-pretty-print.c (ppscm_search_pp_list): Likewise.
256 (ppscm_pretty_print_one_value): Likewise.
257 (ppscm_print_children): Likewise.
258 * guile/scm-string.c (gdbscm_string_to_argv): Likewise.
259 * guile/scm-symtab.c (gdbscm_sal_symtab): Likewise.
260 * guile/scm-type.c (gdbscm_type_next_field_x): Likewise.
261 * guile/scm-utils.c (gdbscm_parse_function_args): Likewise.
262 * i386-tdep.c (i386_register_reggroup_p): Likewise.
263 * infcmd.c (run_command_1): Likewise.
264 (until_next_fsm_clean_up): Likewise.
265 * linespec.c (linespec_complete): Likewise.
266 (find_label_symbols): Likewise.
267 * m2-valprint.c (m2_val_print): Likewise.
268 * memattr.c (require_user_regions): Likewise.
269 (lookup_mem_region): Likewise.
270 (disable_mem_command): Likewise.
271 (mem_delete): Likewise.
272 * mep-tdep.c (mep_register_name): Likewise.
273 (mep_analyze_prologue): Likewise.
274 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Likewise.
275 * mi/mi-interp.c (mi_on_sync_execution_done): Likewise.
276 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
277 * microblaze-linux-tdep.c (microblaze_linux_init_abi): Likewise.
278 * minidebug.c (lzma_open): Likewise.
279 * minsyms.c (lookup_minimal_symbol): Likewise.
280 * mips-linux-tdep.c (mips64_fill_fpregset): Likewise.
281 * mips-tdep.c (mips_stub_frame_sniffer): Likewise.
282 (mips_o64_return_value): Likewise.
283 (mips_single_step_through_delay): Likewise.
284 (_initialize_mips_tdep): Likewise.
285 * nios2-tdep.c (nios2_push_dummy_call): Likewise.
286 (nios2_software_single_step): Likewise.
287 * parse.c (find_minsym_type_and_address): Likewise.
288 * psymtab.c (psym_relocate): Likewise.
289 * python/py-breakpoint.c (bppy_get_commands): Likewise.
290 (gdbpy_breakpoint_modified): Likewise.
291 * python/py-infevents.c (create_inferior_call_event_object):
292 Likewise.
293 * python/py-record-btrace.c (btpy_list_item): Likewise.
294 * python/py-type.c (typy_str): Likewise.
295 * python/py-value.c (valpy_call): Likewise.
296 * python/python.c (do_start_initialization): Likewise.
297 * record-btrace.c (record_btrace_insn_history_range): Likewise.
298 (record_btrace_call_history_range): Likewise.
299 (record_btrace_record_method): Likewise.
300 (record_btrace_xfer_partial): Likewise.
301 (btrace_get_frame_function): Likewise.
302 * record-full.c (record_full_open): Likewise.
303 * record.c (get_context_size): Likewise.
304 * registry.h (DEFINE_REGISTRY): Likewise.
305 * remote-fileio.c (remote_fileio_request): Likewise.
306 * remote.c (remote_update_thread_list): Likewise.
307 (remote_check_symbols): Likewise.
308 (remote_commit_resume): Likewise.
309 (remote_interrupt): Likewise.
310 (remote_insert_breakpoint): Likewise.
311 (compare_sections_command): Likewise.
312 * rust-exp.y (super_name): Likewise.
313 (lex_string): Likewise.
314 (convert_ast_to_type): Likewise.
315 (convert_ast_to_expression): Likewise.
316 * rust-lang.c (rust_print_struct_def): Likewise.
317 (rust_print_type): Likewise.
318 (rust_evaluate_subexp): Likewise.
319 * rx-tdep.c (rx_register_type): Likewise.
320 * ser-event.c (serial_event_clear): Likewise.
321 * serial.c (serial_open): Likewise.
322 * spu-tdep.c (spu_overlay_new_objfile): Likewise.
323 * symfile.c (section_is_overlay): Likewise.
324 (overlay_unmapped_address): Likewise.
325 (overlay_mapped_address): Likewise.
326 (simple_overlay_update_1): Likewise.
327 (simple_overlay_update): Likewise.
328 * symtab.c (symbol_find_demangled_name): Likewise.
329 (search_symbols): Likewise.
330 * target-descriptions.c (tdesc_predefined_type): Likewise.
331 * target.c (target_commit_resume): Likewise.
332 * thread.c (print_selected_thread_frame): Likewise.
333 * top.c (new_ui_command): Likewise.
334 (gdb_readline_no_editing): Likewise.
335 * tracefile-tfile.c (tfile_open): Likewise.
336 * tracepoint.c (create_tsv_from_upload): Likewise.
337 * utils.c (quit): Likewise.
338 (defaulted_query): Likewise.
339 * valarith.c (value_concat): Likewise.
340 * xml-syscall.c (xml_list_syscalls_by_group): Likewise.
341 * xml-tdesc.c (target_fetch_description_xml): Likewise.
342 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
343 (xtensa_pseudo_register_write): Likewise.
344
7403715e
TT
3452017-12-04 Tom Tromey <tom@tromey.com>
346
347 * NEWS: Mention Rust trait object inspection.
348
50a1fdd5
PA
3492017-12-04 Pedro Alves <palves@redhat.com>
350
351 PR gdb/22499
352 * amd64-tdep.c (amd64_insn::rex_offset): Rename to...
353 (amd64_insn::enc_prefix_offset): ... this, and tweak comment.
354 (vex2_prefix_p, vex3_prefix_p): New functions.
355 (amd64_get_insn_details): Adjust to rename. Also skip VEX2 and
356 VEX3 prefixes.
357 (fixup_riprel): Set VEX3.!B.
358
1e97a227
SM
3592017-12-03 Simon Marchi <simon.marchi@ericsson.com>
360
361 * target.h (mem_region_vector): Remove.
362 (struct target_ops) <to_memory_map>: Change return type to
363 std::vector<mem_region>.
364 * target-debug.h (target_debug_print_mem_region_vector): Rename
365 to ...
366 (target_debug_print_std_vector_mem_region): ... this.
367 * target-delegates.c: Re-generate.
368
10f64178
PA
3692017-12-03 Pedro Alves <palves@redhat.com>
370
371 * make-target-delegates (munge_type): Also munge '<', '>', and
372 ':'. Avoid double underscores in identifiers, and trailing
373 underscores.
374 * target-debug.h
375 (target_debug_print_VEC_static_tracepoint_marker_p__p): Rename to
376 ...
377 (target_debug_print_VEC_static_tracepoint_marker_p_p): ... this.
378 * target-delegates.c: Regenerate.
379
6d83e819
SM
3802017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
381
382 * common/poison.h (XDELETE): Fix typo.
383
97cbe998
SDJ
3842017-12-01 Andrew Cagney <cagney@redhat.com>
385 Joel Brobecker <brobecker@adacore.com>
386 Sergio Durigan Junior <sergiodj@redhat.com>
387
388 * NEWS (Changes since GDB 8.0: Mention new '--readnever'
389 feature.
390 * coffread.c (coff_symfile_read): Do not map over sections with
391 'coff_locate_sections' if readnever is on.
392 * dwarf2read.c (dwarf2_has_info): Return 0 if
393 readnever is on.
394 * elfread.c (elf_symfile_read): Do not map over sections with
395 'elf_locate_sections' if readnever is on.
396 * main.c (validate_readnow_readnever): New function.
397 (captured_main_1): Add support for --readnever.
398 (print_gdb_help): Document --readnever.
399 * objfile-flags.h (enum objfile_flag) <OBJF_READNEVER>: New
400 flag.
401 * symfile.c (readnever_symbol_files): New global.
402 (symbol_file_add_with_addrs): Set 'OBJF_READNEVER' when
403 'READNEVER_SYMBOL_FILES' is set.
404 (validate_readnow_readnever): New function.
405 (symbol_file_command): Handle '-readnever' option.
406 Call 'validate_readnow_readnever'.
407 (add_symbol_file_command): Handle '-readnever' option.
408 Call 'validate_readnow_readnever'.
409 (_initialize_symfile): Document new '-readnever' option for
410 both 'symbol-file' and 'add-symbol-file' commands.
411 * top.h (readnever_symbol_files): New extern global.
412 * xcoffread.c (xcoff_initial_scan): Do not read debug
413 information if readnever is on.
414
40fc416f
SDJ
4152017-12-01 Sergio Durigan Junior <sergiodj@redhat.com>
416
417 * symfile.c (symbol_file_command): Call
418 'symbol_file_add_main_1' only after processing all command
419 line options.
420 (add_symbol_file_command): Modify logic to make arguments
421 position-independent.
422
ec6a20c2
JB
4232017-12-01 Joel Brobecker <brobecker@adacore.com>
424
425 * ada-lang.c (symbol_list_obstack): Delete.
426 (resolve_subexp): Make sure "candidates" gets xfree'ed.
427 (ada_lookup_symbol_list_worker): Remove the limitation that
428 the result is only good until the next call, now making it
429 the responsibility of the caller to free the result when no
430 longer needed. Adjust the function's intro comment accordingly.
431 (ada_lookup_symbol_list): Adjust the function's intro comment.
432 (ada_iterate_over_symbols): Make sure "results" gets xfree'ed.
433 (ada_lookup_encoded_symbol, get_var_value): Likewise.
434 (_initialize_ada_language): Remove symbol_list_obstack
435 initialization.
436 * ada-exp.y (block_lookup): Make sure "syms" gets xfree'ed.
437 (write_var_or_type, write_name_assoc): Likewise.
438
d0df06af
TT
4392017-12-01 Tom Tromey <tom@tromey.com>
440
441 * Makefile.in (all_deps_files): New variable.
442 Include .Po files using all_deps_files.
443
2ee0c9b3
JB
4442017-12-01 Joel Brobecker <brobecker@adacore.com>
445
446 * MAINTAINERS: Update list of maintainers, moving those who
447 stepped down or became inactive to the "Past Maintainers"
448 section.
449
44122162
RO
4502017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
451
452 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
453 sys/proc.h.
454 (NEW_PROC_API): Remove.
455 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
456 Likewise.
457 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
458 * configure: Regenerate.
459 * config.in: Regenerate.
460 * gdbserver/configure: Regenerate.
461 * gdbserver/config.in: Regenerate.
462
463 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
464 NEW_PROC_API test.
465 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
466
467 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
468
469 * proc-api.c: Remove !NEW_PROC_API support.
470 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
471 Remove tests for macros always defined on Solaris.
472 * proc-events.c: Remove !NEW_PROC_API support.
473 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
474 HAVE_SYS_USER_H tests.
475 (init_syscall_table): Remove non-Solaris syscalls.
476 Remove tests for syscalls present on all Solaris versions.
477 Add missing Solaris 10+ syscalls.
478 (signal_table): Remove non-Solaris signals.
479 Remove tests for signals present on all Solaris versions.
480 (fault_table): Remove non-Solaris faults.
481 Remove tests for faults present on all Solaris versions.
482 * proc-flags.c: Remove !NEW_PROC_API support.
483 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
484 Remove non-Solaris flags.
485 * proc-why.c: Remove !NEW_PROC_API support.
486 (pr_why_table): Remove meaningless comments.
487 Remove tests for reasons present on all Solaris versions.
488 Remove OSF/1 cases.
489 (proc_prettyfprint_why): Likewise.
490
491 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
492 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
493 Remove WA_READ test, IRIX watchpoint support.
494 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
495 types. Change users.
496 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
497 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
498 Change callers.
499 Remove CTL_PROC_NAME_FMT tests.
500 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
501 users.
502 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
503 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
504 (proc_modify_flag): Replace GDBRESET by PCUNSET.
505 Remove PR_ASYNC, PR_KLC tests.
506 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
507 (proc_parent_pid): Remove PCWATCH etc. tests.
508 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
509 Remove PCAGENT test.
510 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
511 Remove SYS_lwpcreate || SYS_lwp_create test.
512 (proc_get_current_thread): Likewise.
513 [PIOCNTHR && PIOCTLIST]: Remove.
514 [PIOCLSTATUS]: Remove.
515 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
516 [PRFS_STOPEXEC]: Remove.
517 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
518 (syscall_is_exit): Likewise.
519 (syscall_is_exec): Likewise.
520 (syscall_is_lwp_create): Likewise.
521 Remove SYS_syssgi support.
522 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
523 [SYS_syssgi]: Remove.
524 Remove non-Solaris cases, conditionals.
525 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
526 Remove.
527 (procfs_init_inferior) [SYS_syssgi]: Remove.
528 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
529 (procfs_inferior_created) [SYS_syssgi]: Remove.
530 (procfs_set_watchpoint): Remove !AIX5 test.
531 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
532 case.
533 (mappingflags) [MA_PHYS]: Remove.
534 (info_mappings_callback): Remove PCAGENT test.
535 Remove PIOCOPENLWP || PCAGENT test.
536
e8020e54
RO
5372017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
538
539 * sol-thread.c (info_solthreads): Constify args.
540 Cast args to void *.
541
75059544
JB
5422017-11-29 John Baldwin <jhb@FreeBSD.org>
543
544 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
545
f5a91472
JB
5462017-11-29 Joel Brobecker <brobecker@adacore.com>
547
548 * ada-lang.c (to_fixed_range_type): Make sure that the size
549 of the range type being returned is the same as the size
550 of the range type being fixed.
551
bd69330d
PA
5522017-11-29 Pedro Alves <palves@redhat.com>
553
554 PR c++/19436
555 * NEWS: Mention setting breakpoints on functions with C++ ABI
556 tags.
557 * completer.h (completion_match_for_lcd) <match,
558 mark_ignored_range>: New methods.
559 <finish>: Consider ignored ranges.
560 <clear>: Clear ignored ranges.
561 <m_ignored_ranges, m_finished_storage>: New fields.
562 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
563 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
564 completion_match_for_lcd pointer to strncmp_iw_with_mode.
565 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
566 * language.c (default_symbol_name_matcher): Pass the
567 completion_match_for_lcd pointer to strncmp_iw_with_mode.
568 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
569 * utils.c (skip_abi_tag): New function.
570 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
571 Handle ABI tags.
572 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
573 parameter.
574
5752017-11-29 Pedro Alves <palves@redhat.com>
576
577 PR c++/19436
578 * NEWS: Mention setting breakpoints on functions with C++ ABI
579 tags.
580 * completer.h (completion_match_for_lcd) <match,
581 mark_ignored_range>: New methods.
582 <finish>: Consider ignored ranges.
583 <clear>: Clear ignored ranges.
584 <m_ignored_ranges, m_finished_storage>: New fields.
585 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
586 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
587 completion_match_for_lcd pointer to strncmp_iw_with_mode.
588 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
589 * language.c (default_symbol_name_matcher): Pass the
590 completion_match_for_lcd pointer to strncmp_iw_with_mode.
591 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
592 * utils.c (skip_abi_tag): New function.
593 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
594 Handle ABI tags.
595 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
596 parameter.
597
a20714ff
PA
5982017-11-29 Pedro Alves <palves@redhat.com>
599
600 * NEWS: Mention that breakpoints on C++ functions are now set on
601 on all namespaces/classes by default, and mention "break
602 -qualified".
603 * ax-gdb.c (agent_command_1): Adjust to pass a
604 symbol_name_match_type to new_linespec_location.
605 * breakpoint.c (parse_breakpoint_sals): Adjust to
606 get_linespec_location's return type change.
607 (strace_marker_create_sals_from_location): Adjust to pass a
608 symbol_name_match_type to new_linespec_location.
609 (strace_marker_decode_location): Adjust to get_linespec_location's
610 return type change.
611 (strace_command): Adjust to pass a symbol_name_match_type to
612 new_linespec_location.
613 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
614 mention "-qualified".
615 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
616 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
617 enumerator.
618 (complete_address_and_linespec_locations): New parameter
619 'match_type'. Pass it down.
620 (explicit_options): Add "-qualified".
621 (collect_explicit_location_matches): Pass the requested match type
622 to the linespec completers. Handle MATCH_QUALIFIED.
623 (location_completer): Handle "-qualified" combined with linespecs.
624 * cp-support.c (cp_search_name_hash): New.
625 (cp_symbol_name_matches_1): Implement wild matching for C++.
626 (cp_fq_symbol_name_matches): Reimplement.
627 (cp_get_symbol_name_matcher): Return different matchers depending
628 on the lookup name's match type.
629 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
630 * cp-support.h (cp_search_name_hash): New declaration.
631 * dwarf2read.c
632 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
633 symbols.
634 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
635 tests.
636 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
637 pass a symbol_name_match_type to new_linespec_location.
638 * linespec.c (linespec_parse_basic): Lookup function symbols using
639 the parser's symbol name match type.
640 (convert_explicit_location_to_linespec): New
641 symbol_name_match_type parameter. Pass it down to
642 find_linespec_symbols.
643 (convert_explicit_location_to_sals): Pass the location's name
644 match type to convert_explicit_location_to_linespec.
645 (parse_linespec): New match_type parameter. Save it in the
646 parser.
647 (linespec_parser_new): Default to symbol_name_match_type::WILD.
648 (linespec_complete_function): New symbol_name_match_type
649 parameter. Use it.
650 (complete_linespec_component): Pass down the parser's recorded
651 name match type.
652 (linespec_complete_label): New symbol_name_match_type parameter.
653 Use it.
654 (linespec_complete): New symbol_name_match_type parameter. Save
655 it in the parser and pass it down. Adjust to
656 get_linespec_location's prototype change.
657 (find_function_symbols, find_linespec_symbols): New
658 symbol_name_match_type parameter. Pass it down instead of
659 assuming symbol_name_match_type::WILD.
660 * linespec.h (linespec_complete, linespec_complete_function)
661 (linespec_complete_label): New symbol_name_match_type parameter.
662 * location.c (event_location::linespec_location): Now a struct
663 linespec_location.
664 (EL_LINESPEC): Adjust.
665 (initialize_explicit_location): Default to
666 symbol_name_match_type::WILD.
667 (new_linespec_location): New symbol_name_match_type parameter.
668 Record it in the location.
669 (get_linespec_location): Now returns a struct linespec_location.
670 (new_explicit_location): Also copy func_name_match_type.
671 (explicit_to_string_internal)
672 (string_to_explicit_location): Handle "-qualified".
673 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
674 Copy symbol_name_match_type fields.
675 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
676 type change.
677 (event_location_to_string): Adjust to LINESPEC_LOCATION type
678 change. Handle "-qualfied".
679 (string_to_explicit_location): Handle "-qualified".
680 (string_to_event_location_basic): New symbol_name_match_type
681 parameter. Pass it down.
682 (string_to_event_location): Handle "-qualified".
683 * location.h (struct linespec_location): New.
684 (explicit_location::func_name_match_type): New field.
685 (new_linespec_location): Now returns a const linespec_location *.
686 (string_to_event_location_basic): New symbol_name_match_type
687 parameter.
688 (explicit_completion_info::saw_explicit_location_option): New
689 field.
690 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
691 symbol_name_match_type to new_linespec_location.
692 * python/py-breakpoint.c (bppy_init): Likewise.
693 * python/python.c (gdbpy_decode_line): Likewise.
694
a207cff2
PA
6952017-11-29 Pedro Alves <palves@redhat.com>
696
697 * ada-lang.c (ada_lookup_name_info::matches): Change type of
698 parameter from completion_match to completion_match_result.
699 Adjust.
700 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
701 * completer.c (completion_tracker::maybe_add_completion): Add
702 match_for_lcd parameter and use it.
703 (completion_tracker::add_completion): Likewise.
704 * completer.h (class completion_match_for_lcd): New class.
705 (completion_match_result::match_for_lcd): New field.
706 (completion_match_result::set_match): New method.
707 (completion_tracker): Add comments.
708 (completion_tracker::add_completion): Add match_for_lcd parameter.
709 (completion_tracker::reset_completion_match_result): Reset
710 match_for_lcd too.
711 (completion_tracker::maybe_add_completion): Add match_for_lcd
712 parameter.
713 (completion_tracker::m_lowest_common_denominator_unique): Extend
714 comments.
715 * cp-support.c (cp_symbol_name_matches_1)
716 (cp_fq_symbol_name_matches): Change type of parameter from
717 completion_match to completion_match_result. Adjust.
718 * language.c (default_symbol_name_matcher): Change type of
719 parameter from completion_match to completion_match_result.
720 Adjust.
721 * language.h (completion_match_for_lcd): Forward declare.
722 (default_symbol_name_matcher): Change type of parameter from
723 completion_match to completion_match_result.
724 * symtab.c (compare_symbol_name): Adjust.
725 (completion_list_add_name): Pass the match_for_lcd to the tracker.
726 * symtab.h (ada_lookup_name_info::matches): Change type of
727 parameter from completion_match to completion_match_result.
728 (symbol_name_matcher_ftype): Likewise, and update comments.
729
4024cf2b
PA
7302017-11-29 Pedro Alves <palves@redhat.com>
731
732 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
733 * minsyms.c (msymbol_is_text): Delete.
734 (msymbol_is_function): New function.
735 * minsyms.h (msymbol_is_text): Delete.
736 (msymbol_is_function): New declaration.
737 * symtab.c (find_function_alias_target): Use msymbol_is_function.
738
5dcf52c1
TT
7392017-11-29 Tom Tromey <tom@tromey.com>
740
741 * Makefile.in (distclean): Handle the case where rmdir fails.
742
8ca2f0b9
TT
7432017-11-29 Tom Tromey <tom@tromey.com>
744
745 * symfile.c (_initialize_symfile): Update usage text for
746 add-symbol-file, symbol-file, load.
747
02ca603a
TT
7482017-11-29 Tom Tromey <tom@tromey.com>
749
750 * symfile.c (add_symbol_file_command): Error if some arguments to
751 -s are missing. Change unrecognized-argument error message.
752 (_initialize_symfile): Fix usage text for add-symbol-file.
753
18ca7347
TT
7542017-11-27 Tom Tromey <tom@tromey.com>
755
756 * Makefile.in (REMOTE_OBS): Remove.
757 (SFILES): Remove remote sources.
758 (COMMON_SFILES): Add remote sources.
759 (ALLDEPFILES): Remove dcache.c.
760
66599a7d
TT
7612017-11-27 Tom Tromey <tom@tromey.com>
762
763 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
764 variables.
765 (SFILES): Use SUBDIR_TARGET_SRCS.
766 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
767 (CONFIG_SRC_SUBDIR): Add target.
768 (%.o): Remove target rule.
769
4f04fba8
TT
7702017-11-27 Tom Tromey <tom@tromey.com>
771
772 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
773 registry.o, thread-fsm.o, debug.o.
774 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
775 thread-fsm.c, debug.c.
776
b5adff3b
TT
7772017-11-27 Tom Tromey <tom@tromey.com>
778
779 * Makefile.in (COMMON_SFILES): New.
780 (SFILES): Move some entries to COMMON_SFILES.
781 (COMMON_OBS): Use COMMON_SFILES.
782
afa0a411
TT
7832017-11-27 Tom Tromey <tom@tromey.com>
784
785 * Makefile.in (YYFILES): Update comment.
786 (YYOBJ): Redefine.
787
8fd8d003
TT
7882017-11-27 Tom Tromey <tom@tromey.com>
789
790 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
791 (CONFIG_SRC_SUBDIR): Add python.
792 (%.o): Remove python rule.
793 (python/%.o): New rule.
794 * configure: Rebuild.
795 * configure.ac (CONFIG_OBS): Refer to python/python.o
796
bd810fff
TT
7972017-11-27 Tom Tromey <tom@tromey.com>
798
799 * configure: Rebuild.
800 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
801 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
802 (CONFIG_SRC_SUBDIR): Add guile.
803 (%.o): Remove guile rule.
804
75787ac1
TT
8052017-11-27 Tom Tromey <tom@tromey.com>
806
807 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
808 (%.o): Remove unittests rule.
809 (CONFIG_SRC_SUBDIR): Add unittests.
810
5c8a9431
TT
8112017-11-27 Tom Tromey <tom@tromey.com>
812
813 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
814 (CONFIG_SRC_SUBDIR): Add tui.
815 (%.o): Remove tui rule.
816
a26aa30c
TT
8172017-11-27 Tom Tromey <tom@tromey.com>
818
819 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
820 (%.o): Remove compile rule.
821 (CONFIG_SRC_SUBDIR): Add compile.
822
6f3cdf9a
TT
8232017-11-27 Tom Tromey <tom@tromey.com>
824
825 * Makefile.in (SUBDIR_MI_OBS): Redefine.
826 (%.o): Remove mi rule.
827 (CONFIG_SRC_SUBDIR): Add mi.
828 (COMMON_OBS): Use mi/mi-common.o
829
f06afa53
TT
8302017-11-27 Tom Tromey <tom@tromey.com>
831
832 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
833 (%.o): Remove cli rule.
834 (CONFIG_SRC_SUBDIR): Add cli.
835
b22c88c2
TT
8362017-11-27 Tom Tromey <tom@tromey.com>
837
838 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
839 * configure: Rebuild.
840 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
841 (CONFIG_DEP_SUBDIR): New variable.
842 (%.o): Add order-only dependency.
843 ($(CONFIG_DEP_SUBDIR)): New target.
844
ee9a09e9
DC
8452017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
846
847 PR gdb/21945
848 * findcmd.c (_initialize_mem_search): Update find command help
849 text.
850
e8e7d10c
SM
8512017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
852
853 * python/python.c (do_start_initialization): Change progname
854 type to gdb::unique_xmalloc_ptr. Release the pointer when using
855 Python 2.
856
6a997029
TT
8572017-11-26 Tom Tromey <tom@tromey.com>
858
859 * common/format.h: Add include guards.
860
41272101
TT
8612017-11-26 Tom Tromey <tom@tromey.com>
862
863 * nat/linux-personality.h (class
864 maybe_disable_address_space_randomization): New class.
865 (maybe_disable_address_space_randomization): Don't declare
866 function.
867 * nat/linux-personality.c (restore_personality)
868 (make_disable_asr_cleanup): Remove.
869 (maybe_disable_address_space_randomization): Now a constructor.
870 (~maybe_disable_address_space_randomization): New destructor.
871 * linux-nat.c (linux_nat_create_inferior): Update.
872
44287fd8
TT
8732017-11-26 Tom Tromey <tom@tromey.com>
874
875 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
876
5ffd2cb7
UW
8772017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
878
879 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
880 "cooked" register. Access only first four bytes of branch target
881 registers.
882
0e5457dc
SDJ
8832017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
884
885 PR gdb/22491
886 * stap-probe.c (relocate_address): New function.
887 (stap_probe::get_relocated_address): Use 'relocate_address'.
888 (stap_probe::set_semaphore): Use 'relocate_address' and pass
889 'm_sem_addr'.
890 (stap_probe::clear_semaphore): Likewise.
891
deeeba55
PA
8922017-11-25 Pedro Alves <palves@redhat.com>
893
894 * dictionary.c: Include "safe-ctype.h".
895 * minsyms.c: Include "safe-ctype.h".
896 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
897
a81aaca0
PA
8982017-11-25 Pedro Alves <palves@redhat.com>
899
900 * completer.c (complete_line_internal_1): Skip spaces until the
901 start of the command.
902
0662b6a7
PA
9032017-11-24 Pedro Alves <palves@redhat.com>
904
905 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
906 cp_fq_symbol_name_matches. Pass language_cplus to
907 strncmp_with_mode.
908 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
909 (selftests::test_cp_symbol_name_cmp): New.
910 (_initialize_cp_support): Register "cp_symbol_name_matches"
911 selftests.
912 * language.c (default_symbol_name_matcher): Pass language_minimal
913 to strncmp_iw_with_mode.
914 * utils.c: Include "cp-support.h" and <algorithm>.
915 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
916 (cp_is_operator): New functions.
917 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
918 skip whitespace in the symbol name when the lookup name doesn't
919 have spaces, and vice versa.
920 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
921 * utils.h (strncmp_iw_with_mode): Add language parameter.
922
e547c119
JB
9232017-11-24 Joel Brobecker <brobecker@adacore.com>
924
925 * ada-lang.c (ada_exception_message_1, ada_exception_message):
926 New functions.
927 (print_it_exception): If available, display the exception
928 message as well.
929 * NEWS: Document new feature.
930
d7fcdff9
UW
9312017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
932
933 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
934
30649c14
PR
9352017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
936
937 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
938 (dtrace_probe::is_enabled, dtrace_probe::enable)
939 (dtrace_probe::disable): Remove keyword 'struct' at for-range
940 variable
941 * probe.c (gen_ui_out_table_header_info)
942 (print_ui_out_not_applicables): Remove keyword 'struct' at
943 for-range variable
944
7696f5c9
AH
9452017-11-24 Alan Hayward <alan.hayward@arm.com>
946
947 * configure.tgt: Add arch/aarch64.o
948
8172f16b
SM
9492017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
950
951 * common/common-utils.h: Include poison.h.
952 (xfree): Remove declaration, add definition with static_assert.
953 * common/common-utils.c (xfree): Remove.
954 * common/poison.h (IsMallocatable): Define.
955 (IsFreeable): Define.
956 (free): Delete for non-freeable types.
957 (xnew): New.
958 (XNEW): Undef and redefine.
959 (xcnew): New.
960 (XCNEW): Undef and redefine.
961 (xdelete): New.
962 (XDELETE): Undef and redefine.
963 (xnewvec): New.
964 (XNEWVEC): Undef and redefine.
965 (xcnewvec): New.
966 (XCNEWVEC): Undef and redefine.
967 (xresizevec): New.
968 (XRESIZEVEC): Undef and redefine.
969 (xdeletevec): New.
970 (XDELETEVEC): Undef and redefine.
971 (xnewvar): New.
972 (XNEWVAR): Undef and redefine.
973 (xcnewvar): New.
974 (XCNEWVAR): Undef and redefine.
975 (xresizevar): New.
976 (XRESIZEVAR): Undef and redefine.
977
7aabaf9d
SM
9782017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
979
980 * gdbthread.h (private_thread_info): Define structure type, add
981 virtual pure destructor.
982 (thread_info) <priv>: Change type to unique_ptr.
983 <private_dtor>: Remove.
984 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
985 (private_thread_info::~private_thread_info): Provide default
986 implementation.
987 (thread_info::~thread_info): Don't call private_dtor nor
988 manually free priv.
989 * aix-thread.c (private_thread_info): Rename to ...
990 (aix_thread_info): ... this.
991 (get_aix_thread_info): New.
992 (sync_threadlists): Adjust.
993 (iter_tid): Adjust.
994 (aix_thread_resume): Adjust.
995 (aix_thread_fetch_registers): Adjust.
996 (aix_thread_store_registers): Adjust.
997 (aix_thread_extra_thread_info): Adjust.
998 * darwin-nat.h (private_thread_info): Rename to ...
999 (darwin_thread_info): ... this.
1000 (get_darwin_thread_info): New.
1001 * darwin-nat.c (darwin_init_thread_list): Adjust.
1002 (darwin_check_new_threads): Adjust.
1003 (thread_info_from_private_thread_info): Adjust.
1004 * linux-thread-db.c (private_thread_info): Rename to ...
1005 (thread_db_thread_info): ... this, initialize fields.
1006 (get_thread_db_thread_info): New.
1007 <dying>: Change type to bool.
1008 (update_thread_state): Adjust to type rename.
1009 (record_thread): Adjust to type rename an use of unique_ptr.
1010 (thread_db_pid_to_str): Likewise.
1011 (thread_db_extra_thread_info): Likewise.
1012 (thread_db_thread_handle_to_thread_info): Likewise.
1013 (thread_db_get_thread_local_address): Likewise.
1014 * nto-tdep.h (private_thread_info): Rename to ...
1015 (nto_thread_info): ... this, initialize fields.
1016 (get_nto_thread_info): New.
1017 <name>: Change type to std::string.
1018 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
1019 use of unique_ptr.
1020 * nto-procfs.c (update_thread_private_data_name): Adjust to
1021 std::string change, allocate nto_private_thread_info with new.
1022 (update_thread_private_data): Adjust to unique_ptr.
1023 * remote.c (private_thread_info): Rename to ...
1024 (remote_thread_info): ... this, initialize data members with
1025 default values.
1026 <extra, name>: Change type to std::string.
1027 <thread_handle>: Change type to non-pointer.
1028 (free_private_thread_info): Remove.
1029 (get_private_info_thread): Rename to...
1030 (get_remote_thread_info): ... this, change return type, adjust to
1031 use of unique_ptr, use remote_thread_info constructor.
1032 (remote_add_thread): Adjust.
1033 (get_private_info_ptid): Rename to...
1034 (get_remote_thread_info): ...this, change return type.
1035 (remote_thread_name): Use get_remote_thread_info, adjust to
1036 change to std::string.
1037 (struct thread_item) <~thread_item>: Remove.
1038 <thread_handle>: Make non pointer.
1039 (start_thread): Adjust to thread_item::thread_handle type
1040 change.
1041 (remote_update_thread_list): Adjust to type name change, move
1042 strings from temporary to long-lived object instead of
1043 duplicating.
1044 (remote_threads_extra_info): Use get_remote_thread_info.
1045 (process_initial_stop_replies): Likewise.
1046 (resume_clear_thread_private_info): Likewise.
1047 (remote_resume): Adjust to type name change.
1048 (remote_commit_resume): Use get_remote_thread_info.
1049 (process_stop_reply): Adjust to type name change.
1050 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
1051 (remote_stopped_by_hw_breakpoint): Likewise.
1052 (remote_stopped_by_watchpoint): Likewise.
1053 (remote_stopped_data_address): Likewise.
1054 (remote_core_of_thread): Likewise.
1055 (remote_thread_handle_to_thread_info): Use
1056 get_private_info_thread, adjust to thread_handle field type
1057 change.
1058
21fe1c75
SM
10592017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
1060
1061 * remote.c (struct thread_item): Add constructor, disable copy
1062 construction and copy assignment, define default move
1063 construction and move assignment.
1064 <extra, name>: Change type to std::string.
1065 <core>: Initialize.
1066 <thread_handle>: Make non-pointer.
1067 (thread_item_t): Remove typedef.
1068 (DEF_VEC_O(thread_item_t)): Remove.
1069 (threads_listing_context) <contains_thread>: New method.
1070 <remove_thread>: New method.
1071 <items>: Change type to std::vector.
1072 (clear_threads_listing_context): Remove.
1073 (threads_listing_context_remove): Remove.
1074 (remote_newthread_step): Use thread_item constructor, adjust to
1075 change to std::vector.
1076 (start_thread): Use thread_item constructor, adjust to change to
1077 std::vector.
1078 (end_thread): Adjust to change to std::vector and std::string.
1079 (remote_get_threads_with_qthreadinfo): Use thread_item
1080 constructor, adjust to std::vector.
1081 (remote_update_thread_list): Adjust to change to std::vector and
1082 std::string, use threads_listing_context methods.
1083 (remove_child_of_pending_fork): Adjust.
1084 (remove_new_fork_children): Adjust.
1085 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
1086 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
1087 * unittests/rsp-low-selftests.c: New file.
1088 * common/rsp-low.h: Include common/byte-vector.h.
1089 (hex2bin): New overload.
1090 * common/rsp-low.c (hex2bin): New overload.
1091
089354bb
SM
10922017-11-24 Simon Marchi <simon.marchi@ericsson.com>
1093
1094 * inferior.h (private_inferior): Define structure type, add
1095 virtual pure destructor.
1096 (inferior) <priv>: Change type to unique_ptr.
1097 * inferior.c (private_inferior::~private_inferior): Provide
1098 default implementation.
1099 (inferior::~inferior): Don't free priv field.
1100 (exit_inferior_1): Likewise.
1101 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
1102 (darwin_exception_info): Remove typedef.
1103 (DEF_VEC_O (darwin_thread_t)); Remove.
1104 (private_inferior): Rename to ...
1105 (darwin_private_inferior): ... this, extend private_inferior.
1106 (get_darwin_inferior): New.
1107 <threads>: Change type to std::vector of darwin_thread_t pointers.
1108 * darwin-nat.c (darwin_check_new_threads): Adjust.
1109 (find_inferior_task_it): Adjust.
1110 (darwin_find_thread); Adjust.
1111 (darwin_suspend_inferior): Adjust.
1112 (darwin_resume_inferior): Adjust.
1113 (darwin_find_new_inferior): Adjust.
1114 (darwin_decode_notify_message): Adjust.
1115 (darwin_send_reply): Adjust.
1116 (darwin_resume_inferior_threads): Adjust.
1117 (darwin_suspend_inferior_threads): Adjust.
1118 (darwin_decode_message): Adjust.
1119 (darwin_wait): Adjust.
1120 (darwin_interrupt): Adjust.
1121 (darwin_deallocate_threads): Adjust.
1122 (darwin_mourn_inferior): Adjust, don't free private data.
1123 (darwin_reply_to_all_pending_messages): Adjust.
1124 (darwin_stop_inferior): Adjust.
1125 (darwin_setup_exceptions): Adjust.
1126 (darwin_kill_inferior): Adjust.
1127 (darwin_setup_request_notification): Adjust.
1128 (darwin_attach_pid): Adjust.
1129 (darwin_init_thread_list): Adjust.
1130 (darwin_setup_fake_stop_event): Adjust.
1131 (darwin_attach): Adjust.
1132 (darwin_detach): Adjust.
1133 (darwin_xfer_partial): Adjust.
1134 (set_enable_mach_exceptions): Adjust.
1135 (darwin_pid_to_exec_file): Adjust.
1136 (darwin_get_ada_task_ptid): Adjust.
1137 * darwin-nat-info.c (get_task_from_args): Adjust.
1138 (info_mach_ports_command): Adjust.
1139 (info_mach_region_command): Adjust.
1140 (info_mach_exceptions_command): Adjust.
1141 * remote.c (private_inferior): Rename to ...
1142 (remote_private_inferior): ... this, initialize fields.
1143 (get_remote_inferior); New.
1144 (remote_commit_resume): Use get_remote_inferior.
1145 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
1146
d044bac8
PA
11472017-11-24 Pedro Alves <palves@redhat.com>
1148
1149 * NEWS: Mention linespecs and explicit locations, and completion
1150 improvements.
1151
e8d58cba
YQ
11522017-11-24 Yao Qi <yao.qi@linaro.org>
1153
1154 * regcache.c (regcache::dump): Remove footnote_register_size.
1155
a63f2d2f
YQ
11562017-11-24 Yao Qi <yao.qi@linaro.org>
1157
1158 * regcache.c (cooked_read_test): Add more test for readonly
1159 regcache.
1160
1b30aaa5
YQ
11612017-11-24 Yao Qi <yao.qi@linaro.org>
1162
1163 * gdbarch-selftests.c (test_target_has_registers): Move it to
1164 target.c.
1165 (test_target_has_stack): Likewise.
1166 (test_target_has_memory): Likewise.
1167 (test_target_prepare_to_store): Likewise.
1168 (test_target_store_registers): Likewise.
1169 (test_target_ops): Likewise.
1170 * regcache.c: Include selftest-arch.h and gdbthread.h.
1171 (target_ops_no_register): New class.
1172 (test_target_fetch_registers): New.
1173 (test_target_store_registers): New.
1174 (test_target_xfer_partial): New.
1175 (readwrite_regcache): New.
1176 (cooked_read_test): New.
1177 (_initialize_regcache): Register the test.
1178 * target.c: (test_target_has_registers): Moved from
1179 gdbarch-selftests.c.
1180 (test_target_has_stack): Likewise.
1181 (test_target_has_memory): Likewise.
1182 (test_target_prepare_to_store): Likewise.
1183 (test_target_store_registers): Likewise.
1184 * target.h (test_target_ops): New class.
1185
6654d750
AH
11862017-11-24 Alan Hayward <alan.hayward@arm.com>
1187
1188 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
1189 selftest.
1190
49bdb7ee
AH
11912017-11-24 Alan Hayward <alan.hayward@arm.com>
1192
1193 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
1194 * arch/aarch64.c (aarch64_create_target_description): Create
1195 new target description.
1196 * features/Makefile: Add new files.
1197 * features/aarch64.c: Remove file.
1198 * features/aarch64-core.c: New autogenerated file.
1199 * features/aarch64-fpu.c: New autogenerated file.
1200 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
da434ccb
AH
1201
12022017-11-24 Alan Hayward <alan.hayward@arm.com>
1203
1204 * Makefile.in: Add new files.
1205 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
1206 aarch64_read_description.
1207 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
1208 Call aarch64_read_description.
1209 * aarch64-tdep.c (aarch64_read_description): New function.
1210 (aarch64_gdbarch_init): Call aarch64_read_description.
1211 * aarch64-tdep.h (aarch64_read_description): New function.
1212 * arch/aarch64.c: New file.
1213 * configure.tgt: Add new files.
1214
98ead37e
YQ
12152017-11-24 Yao Qi <yao.qi@linaro.org>
1216
1217 * mi/mi-main.c (register_changed_p): Update.
1218 * value.c (value_contents_bits_eq): Change return type.
1219 (value_contents_eq): Likewise.
1220 * value.h: Update comments.
1221
62ad7ce7
YQ
12222017-11-24 Yao Qi <yao.qi@linaro.org>
1223
1224 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
1225 local 'changed'. Remove error.
1226 (register_changed_p): Change return type to bool.
1227
506fe5f4
YQ
12282017-11-24 Yao Qi <yao.qi@linaro.org>
1229
1230 * arch/tic6x.c: New file.
1231 * arch/tic6x.h: New file.
1232 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
1233 tic6x-core.xml and tic6x-gp.xml.
1234 * features/tic6x-c6xp.c: Generated.
1235 * features/tic6x-core.c: Generated.
1236 * features/tic6x-gp.c: Generated.
1237 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
1238 "tic6x-".
1239
00ea2e2a
SM
12402017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1241
1242 * mi/mi-main.c (list_available_thread_groups): Change map value
1243 type to std::vector.
1244
f45e2a77
SM
12452017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1246
1247 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
1248
bd046f64
SM
12492017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1250
1251 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
1252 back to...
1253 <children_requested>: ... this.
1254 (varobj_get_num_children, varobj_update): Adjust.
1255
4c37490d
SM
12562017-11-23 Simon Marchi <simon.marchi@ericsson.com>
1257
1258 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
1259 (ada_value_has_mutated): Likewise.
1260 * c-varobj.c (varobj_is_anonymous_child): Likewise.
1261 (c_is_path_expr_parent): Likewise.
1262 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
1263 (mi_cmd_var_set_frozen): Likewise.
1264 (mi_cmd_var_update_iter): Likewise.
1265 (mi_cmd_var_update): Likewise.
1266 * varobj.c (pretty_printing): Likewise.
1267 (varobj_enable_pretty_printing): Likewise.
1268 (struct varobj_root) <floating, is_valid>: Likewise.
1269 (struct varobj_dynamic) <children_requested>: Likewise.
1270 (delete_variable): Likewise.
1271 (delete_variable_1): Likewise.
1272 (install_variable): Likewise.
1273 (update_type_if_necessary): Likewise.
1274 (install_new_value): Likewise.
1275 (value_of_root): Likewise.
1276 (is_root_p): Likewise.
1277 (varobj_create): Likewise.
1278 (varobj_delete): Likewise.
1279 (varobj_has_more): Likewise.
1280 (varobj_set_frozen): Likewise.
1281 (varobj_get_frozen): Likewise.
1282 (install_dynamic_child): Likewise.
1283 (dynamic_varobj_has_child_method): Likewise.
1284 (update_dynamic_varobj_children): Likewise.
1285 (varobj_get_num_children): Likewise.
1286 (varobj_list_children): Likewise.
1287 (is_path_expr_parent): Likewise.
1288 (varobj_default_is_path_expr_parent): Likewise.
1289 (varobj_is_dynamic_p): Likewise.
1290 (varobj_set_value): Likewise.
1291 (varobj_value_has_mutated): Likewise.
1292 (varobj_update): Likewise.
1293 (check_scope): Likewise.
1294 (value_of_root_1): Likewise.
1295 (varobj_value_get_print_value): Likewise.
1296 (varobj_editable_p): Likewise.
1297 (varobj_value_is_changeable_p): Likewise.
1298 (varobj_floating_p): Likewise.
1299 (varobj_default_value_is_changeable_p): Likewise.
1300 (varobj_invalidate_iter): Likewise.
1301 * varobj.h (struct varobj_update_result) <type_changed,
1302 children_changed, changed, value_installed>: Likewise.
1303 (struct varobj) <updated, frozen, not_fetched>: Likewise.
1304 (struct lang_varobj_ops) <value_is_changeable_p,
1305 value_has_mutated, is_path_expr_parent>: Likewise.
1306 (varobj_delete): Likewise.
1307 (varobj_set_frozen): Likewise.
1308 (varobj_get_frozen): Likewise.
1309 (varobj_set_value): Likewise.
1310 (varobj_update): Likewise.
1311 (varobj_editable_p): Likewise.
1312 (varobj_floating_p): Likewise.
1313 (varobj_has_more): Likewise.
1314 (varobj_is_dynamic_p): Likewise.
1315 (varobj_default_value_is_changeable_p): Likewise.
1316 (varobj_value_is_changeable_p): Likewise.
1317 (varobj_is_anonymous_child): Likewise.
1318 (varobj_default_is_path_expr_parent): Likewise.
1319
9c23b42f
SDJ
13202017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1321
1322 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
1323 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
1324 <type_str>: Convert to 'std::string'.
1325 <expr>: Convert to 'expression_up'.
1326 (dtrace_probe_arg_s): Delete type and VEC.
1327 (dtrace_probe_enabler_s): Likewise.
1328 (struct dtrace_probe): Replace by...
1329 (class dtrace_static_probe_ops): ...this and...
1330 (class dtrace_probe): ...this.
1331 (dtrace_probe_is_linespec): Rename to...
1332 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
1333 to reflect change.
1334 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
1335 Adjust code. Create new instance of 'dtrace_probe'.
1336 (dtrace_build_arg_exprs): Rename to...
1337 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
1338 reflect change.
1339 (dtrace_get_probes): Rename to...
1340 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
1341 to reflect change.
1342 (dtrace_get_arg): Rename to...
1343 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
1344 reflect change.
1345 (dtrace_probe_is_enabled): Rename to...
1346 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
1347 change.
1348 (dtrace_get_probe_address): Rename to...
1349 (dtrace_probe::get_relocated_address): ...this. Adjust code
1350 to reflect change.
1351 (dtrace_get_probe_argument_count): Rename to...
1352 (dtrace_probe::get_argument_count): ...this. Adjust code to
1353 reflect change.
1354 (dtrace_can_evaluate_probe_arguments): Rename to...
1355 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
1356 to reflect change.
1357 (dtrace_evaluate_probe_argument): Rename to...
1358 (dtrace_probe::evaluate_argument): ...this. Adjust code to
1359 reflect change.
1360 (dtrace_compile_to_ax): Rename to...
1361 (dtrace_probe::compile_to_ax): ...this. Adjust code to
1362 reflect change.
1363 (dtrace_probe_destroy): Delete.
1364 (dtrace_type_name): Rename to...
1365 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
1366 reflect change.
1367 (dtrace_probe::get_static_ops): New method.
1368 (dtrace_gen_info_probes_table_header): Rename to...
1369 (dtrace_static_probe_ops::gen_info_probes_table_header):
1370 ...this. Adjust code to reflect change.
1371 (dtrace_gen_info_probes_table_values): Rename to...
1372 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
1373 code to reflect change.
1374 (dtrace_enable_probe): Rename to...
1375 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
1376 change.
1377 (dtrace_disable_probe): Rename to...
1378 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
1379 change.
1380 (struct probe_ops dtrace_probe_ops): Delete.
1381 (info_probes_dtrace_command): Call 'info_probes_for_spops'
1382 instead of 'info_probes_for_ops'.
1383 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
1384 of 'all_probe_ops'.
1385
0e9ae10f
SDJ
13862017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1387 Simon Marchi <simark@simark.ca>
1388
1389 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
1390 variable.
1391 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
1392 <aexpr>: Change type to 'expression_up'.
1393 (stap_probe_arg_s): Delete type and VEC.
1394 (struct stap_probe): Delete. Replace by...
1395 (class stap_static_probe_ops): ...this and...
1396 (class stap_probe): ...this. Rename variables to add 'm_'
1397 prefix. Do not use 'union' for arguments anymore.
1398 (stap_get_expected_argument_type): Receive probe name instead
1399 of 'struct stap_probe'. Adjust code.
1400 (stap_parse_probe_arguments): Rename to...
1401 (stap_probe::parse_arguments): ...this. Adjust code to
1402 reflect change.
1403 (stap_get_probe_address): Rename to...
1404 (stap_probe::get_relocated_address): ...this. Adjust code
1405 to reflect change.
1406 (stap_get_probe_argument_count): Rename to...
1407 (stap_probe::get_argument_count): ...this. Adjust code
1408 to reflect change.
1409 (stap_get_arg): Rename to...
1410 (stap_probe::get_arg_by_number'): ...this. Adjust code to
1411 reflect change.
1412 (can_evaluate_probe_arguments): Rename to...
1413 (stap_probe::can_evaluate_arguments): ...this. Adjust code
1414 to reflect change.
1415 (stap_evaluate_probe_argument): Rename to...
1416 (stap_probe::evaluate_argument): ...this. Adjust code
1417 to reflect change.
1418 (stap_compile_to_ax): Rename to...
1419 (stap_probe::compile_to_ax): ...this. Adjust code to
1420 reflect change.
1421 (stap_probe_destroy): Delete.
1422 (stap_modify_semaphore): Adjust comment.
1423 (stap_set_semaphore): Rename to...
1424 (stap_probe::set_semaphore): ...this. Adjust code to reflect
1425 change.
1426 (stap_clear_semaphore): Rename to...
1427 (stap_probe::clear_semaphore): ...this. Adjust code to
1428 reflect change.
1429 (stap_probe::get_static_ops): New method.
1430 (handle_stap_probe): Adjust code to create instance of
1431 'stap_probe'.
1432 (stap_get_probes): Rename to...
1433 (stap_static_probe_ops::get_probes): ...this. Adjust code to
1434 reflect change.
1435 (stap_probe_is_linespec): Rename to...
1436 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
1437 reflect change.
1438 (stap_type_name): Rename to...
1439 (stap_static_probe_ops::type_name): ...this. Adjust code to
1440 reflect change.
1441 (stap_gen_info_probes_table_header): Rename to...
1442 (stap_static_probe_ops::gen_info_probes_table_header):
1443 ...this. Adjust code to reflect change.
1444 (stap_gen_info_probes_table_values): Rename to...
1445 (stap_probe::gen_info_probes_table_values): ...this. Adjust
1446 code to reflect change.
1447 (struct probe_ops stap_probe_ops): Delete.
1448 (info_probes_stap_command): Use 'info_probes_for_spops'
1449 instead of 'info_probes_for_ops'.
1450 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
1451 of 'all_probe_ops'.
1452
935676c9
SDJ
14532017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1454
1455 * break-catch-throw.c (fetch_probe_arguments): Use
1456 'probe.prob' instead of 'probe.probe'.
1457 * breakpoint.c (create_longjmp_master_breakpoint): Call
1458 'can_evaluate_arguments' and 'get_relocated_address' methods
1459 from probe.
1460 (create_exception_master_breakpoint): Likewise.
1461 (add_location_to_breakpoint): Use 'sal->prob' instead of
1462 'sal->probe'.
1463 (bkpt_probe_insert_location): Call 'set_semaphore' method from
1464 probe.
1465 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
1466 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
1467 of 'probe_ops'.
1468 (probe_key_free): Call 'delete' on probe.
1469 (check_exception_resume): Use 'probe.prob' instead of
1470 'probe.probe'.
1471 * location.c (string_to_event_location_basic): Call
1472 'probe_linespec_to_static_ops'.
1473 * probe.c (class any_static_probe_ops): New class.
1474 (any_static_probe_ops any_static_probe_ops): New variable.
1475 (parse_probes_in_pspace): Receive 'static_probe_ops' as
1476 argument. Adjust code to reflect change.
1477 (parse_probes): Use 'static_probe_ops' instead of
1478 'probe_ops'. Adjust code to reflect change.
1479 (find_probes_in_objfile): Call methods to get name and
1480 provider from probe.
1481 (find_probe_by_pc): Use 'result.prob' instead of
1482 'result.probe'. Call 'get_relocated_address' method from
1483 probe.
1484 (collect_probes): Adjust comment and argument list to receive
1485 'static_probe_ops' instead of 'probe_ops'. Adjust code to
1486 reflect change. Call necessary methods from probe.
1487 (compare_probes): Call methods to get name and provider from
1488 probes.
1489 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
1490 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
1491 adjust code accordingly.
1492 (print_ui_out_not_applicables): Likewise.
1493 (info_probes_for_ops): Rename to...
1494 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
1495 as argument instead of 'probe_ops'. Adjust code. Call
1496 necessary methods from probe.
1497 (info_probes_command): Use 'info_probes_for_spops'.
1498 (enable_probes_command): Pass correct argument to
1499 'collect_probes'. Call methods from probe.
1500 (disable_probes_command): Likewise.
1501 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
1502 (get_probe_argument_count): Move to
1503 'any_static_probe_ops::get_argument_count'.
1504 (can_evaluate_probe_arguments): Move to
1505 'any_static_probe_ops::can_evaluate_arguments'.
1506 (evaluate_probe_argument): Move to
1507 'any_static_probe_ops::evaluate_argument'.
1508 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
1509 'probe.probe'.
1510 (probe_linespec_to_ops): Rename to...
1511 (probe_linespec_to_static_ops): ...this. Adjust code.
1512 (probe_any_is_linespec): Rename to...
1513 (any_static_probe_ops::is_linespec): ...this.
1514 (probe_any_get_probes): Rename to...
1515 (any_static_probe_ops::get_probes): ...this.
1516 (any_static_probe_ops::type_name): New method.
1517 (any_static_probe_ops::gen_info_probes_table_header): New
1518 method.
1519 (compute_probe_arg): Use 'pc_probe.prob' instead of
1520 'pc_probe.probe'. Call methods from probe.
1521 (compile_probe_arg): Likewise.
1522 (std::vector<const probe_ops *> all_probe_ops): Delete.
1523 (std::vector<const static_probe_ops *> all_static_probe_ops):
1524 New variable.
1525 (_initialize_probe): Use 'all_static_probe_ops' instead of
1526 'all_probe_ops'.
1527 * probe.h (struct info_probe_column) <field_name>: Delete
1528 extraneous newline
1529 (info_probe_column_s): Delete type and VEC.
1530 (struct probe_ops): Delete. Replace with...
1531 (class static_probe_ops): ...this and...
1532 (clas probe): ...this.
1533 (struct bound_probe) <bound_probe>: Delete extraneous
1534 newline. Adjust constructor to receive 'probe' instead of
1535 'struct probe'.
1536 <probe>: Rename to...
1537 <prob>: ...this. Delete extraneous newline.
1538 <objfile>: Delete extraneous newline.
1539 (register_probe_ops): Delete unused prototype.
1540 (info_probes_for_ops): Rename to...
1541 (info_probes_for_spops): ...this. Adjust comment.
1542 (get_probe_address): Move to 'probe::get_address'.
1543 (get_probe_argument_count): Move to
1544 'probe::get_argument_count'.
1545 (can_evaluate_probe_arguments): Move to
1546 'probe::can_evaluate_arguments'.
1547 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
1548 * solib-svr4.c (struct svr4_info): Adjust comment.
1549 (struct probe_and_action) <probe>: Rename to...
1550 <prob>: ...this.
1551 (register_solib_event_probe): Receive 'probe' instead of
1552 'struct probe' as argument. Use 'prob' instead of 'probe'
1553 when applicable.
1554 (solib_event_probe_action): Call 'get_argument_count' method
1555 from probe. Adjust comment.
1556 (svr4_handle_solib_event): Adjust comment. Call
1557 'evaluate_argument' method from probe.
1558 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
1559 from probe.
1560 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
1561 'struct probe'. Call 'can_evaluate_arguments' from probe.
1562 * symfile.h: Forward declare 'class probe' instead of 'struct
1563 probe'.
1564 * symtab.h: Likewise.
1565 (struct symtab_and_line) <probe>: Rename to...
1566 <prob>: ...this.
1567 * tracepoint.c (start_tracing): Use 'prob' when applicable.
1568 Call probe methods.
1569 (stop_tracing): Likewise.
1570
8f6cb6c3
JB
15712017-11-22 Joel Brobecker <brobecker@adacore.com>
1572
1573 * ravenscar-thread.c (ravenscar_inferior_created): Remove
1574 trailing newline at end of string in call to warning.
1575
479f8de1
SM
15762017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1577
1578 * osdata.h: Include vector isntead of vec.h.
1579 (osdata_column_s): Remove typedef.
1580 (struct osdata_column): Add constructor.
1581 <name, value>: Change type to std::string.
1582 (DEF_VEC_O (osdata_column_s)): Remove.
1583 (osdata_item_s): Remove typedef.
1584 (struct osdata_item) <columns>: Change type to std::vector.
1585 (DEF_VEC_O (osdata_item_s)): Remove.
1586 (struct osdata): Add constructor.
1587 <type>: Change type to std::string.
1588 <items>: Change type to std::vector.
1589 (osdata_p): Remove typedef.
1590 (DEF_VEC_P (osdata_p)): Remove.
1591 (osdata_parse): Return a unique_ptr.
1592 (osdata_free): Remove.
1593 (make_cleanup_osdata_free): Remove.
1594 (get_osdata): Return a unique_ptr.
1595 (get_osdata_column): Return pointer to std::string, take a
1596 reference to osdata_item as parameter.
1597 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
1598 unique_ptr.
1599 <property_name>: Change type to std::string.
1600 (osdata_start_osdata): Allocate osdata with new and adjust.
1601 (osdata_start_item): Adjust.
1602 (osdata_start_column): Adjust.
1603 (osdata_end_column): Adjust.
1604 (clear_parsing_data): Remove.
1605 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
1606 (osdata_item_clear): Remove.
1607 (get_osdata): return a unique_ptr and adjust.
1608 (get_osdata_column): Return a pointer to std::string and adjust.
1609 (info_osdata): Adjust.
1610 * mi/mi-main.c: Include <map>.
1611 (free_vector_of_osdata_items): Remove.
1612 (list_available_thread_groups): Adjust, use std::map instead of
1613 splay tree.
1614
41bd68f5
SM
16152017-11-22 Simon Marchi <simon.marchi@ericsson.com>
1616
1617 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
1618 case in switch.
1619
7e2fd2f4
SM
16202017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1621
1622 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
1623
0604393c
SM
16242017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1625
1626 * varobj.h (struct varobj_update_result): Add constructor, add
1627 move constructor, disable copy and assign, initialize fields.
1628 <newobj>: Change type to std::vector.
1629 (varobj_update): Return std::vector.
1630 * varobj.c (install_dynamic_child): Change VEC parameters to
1631 std::vector and adjust.
1632 (update_dynamic_varobj_children): Likewise.
1633 (varobj_update): Return std::vector and adjust.
1634 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
1635
ddf0ea08
SM
16362017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1637
1638 * varobj.h (struct varobj) <parent>: Remove const.
1639 <children>: Change type to std::vector.
1640 (varobj_list_children): Return std::vector const reference.
1641 (varobj_restrict_range): Change parameter type to std::vector
1642 const reference.
1643 * varobj.c (varobj_has_more): Adjust.
1644 (varobj_restrict_range): Change parameter type to std::vector
1645 const reference and adjust.
1646 (install_dynamic_child): Adjust.
1647 (update_dynamic_varobj_children): Adjust.
1648 (varobj_list_children): Return std::vector const reference and
1649 adjust.
1650 (varobj_add_child): Adjust.
1651 (update_type_if_necessary): Adjust.
1652 (varobj_update): Adjust.
1653 (delete_variable_1): Adjust.
1654 * ada-varobj.c (ada_value_has_mutated): Adjust.
1655 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
1656
9e5b9d2b
SM
16572017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1658
1659 * varobj.h (struct varobj): Add constructor and destructor,
1660 initialize fields.
1661 * varobj.c (struct varobj_root): Initialize fields.
1662 (struct varobj_dynamic): Initialize fields.
1663 (varobj_create): Use unique_ptr instead of cleanup. Create
1664 varobj with new instead of new_root_variable.
1665 (delete_variable_1): Free variable with delete instead of
1666 free_variable.
1667 (create_child_with_value): Create variable with new instead of
1668 new_variable.
1669 (varobj::varobj): New.
1670 (varobj::~varobj): New (body mostly coming from free_variable).
1671 (new_variable): Remove.
1672 (free_variable): Remove.
1673 (do_free_variable_cleanup): Remove.
1674 (make_cleanup_free_variable): Remove.
1675
fc35dab1
UW
16762017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1677
1678 * core-regset.c: Remove file.
1679 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
1680
2400729e
UW
16812017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1682
1683 * NEWS: Document use of GNU MPFR.
1684 * README: Likewise.
1685
1686 * Makefile.in (LIBMPFR): Add define.
1687 (CLIBS): Add $(LIBMPFR).
1688 * configure.ac: Add --with-mpfr configure option.
1689 * configure: Regenerate.
1690 * config.in: Regenerate.
1691
1692 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
1693 (class mpfr_float_ops): New type.
1694 (mpfr_float_ops::from_target): Two new overloaded functions.
1695 (mpfr_float_ops::to_target): Likewise.
1696 (mpfr_float_ops::to_string): New function.
1697 (mpfr_float_ops::from_string): Likewise.
1698 (mpfr_float_ops::to_longest): Likewise.
1699 (mpfr_float_ops::from_longest): Likewise.
1700 (mpfr_float_ops::from_ulongest): Likewise.
1701 (mpfr_float_ops::to_host_double): Likewise.
1702 (mpfr_float_ops::from_host_double): Likewise.
1703 (mpfr_float_ops::convert): Likewise.
1704 (mpfr_float_ops::binop): Likewise.
1705 (mpfr_float_ops::compare): Likewise.
1706 (get_target_float_ops): Use mpfr_float_ops if available.
1707
7a26362d
UW
17082017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1709
1710 * target-float.c: Do not include <math.h>.
1711 Include <cmath> and <limits>.
1712 (DOUBLEST): Do not define.
1713 (class target_float_ops): New type.
1714 (class host_float_ops): New templated type.
1715 (class decimal_float_ops): New type.
1716
1717 (floatformat_to_doublest): Rename to ...
1718 (host_float_ops<T>::from_target): ... this. Use template type T
1719 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1720 (host_float_ops<T>::from_target): New overload using a type argument.
1721 (floatformat_from_doublest): Rename to ...
1722 (host_float_ops<T>::to_target): ... this. Use template type T
1723 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1724 (host_float_ops<T>::to_target): New overload using a type argument.
1725 (floatformat_printf_format): New function.
1726 (struct printf_length_modifier): New templated type.
1727 (floatformat_to_string): Rename to ...
1728 (host_float_ops<T>::to_string): ... this. Use type instead of
1729 floatformat argument. Use floatformat_printf_format and
1730 printf_length_modifier. Remove special handling of invalid numbers,
1731 infinities and NaN (moved to target_float_to_string).
1732 (struct scanf_length_modifier): New templated type.
1733 (floatformat_from_string): Rename to ...
1734 (host_float_ops<T>::from_string): ... this. Use type instead of
1735 floatformat argument. Use scanf_length_modifier.
1736 (floatformat_to_longest): Rename to ...
1737 (host_float_ops<T>::to_longest): ... this. Use type instead of
1738 floatformat argument. Handle out-of-range values deterministically.
1739 (floatformat_from_longest): Rename to ...
1740 (host_float_ops<T>::from_longest): ... this. Use type instead of
1741 floatformat argument.
1742 (floatformat_from_ulongest): Rename to ...
1743 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
1744 floatformat argument.
1745 (floatformat_to_host_double): Rename to ...
1746 (host_float_ops<T>::to_host_double): ... this. Use type instead of
1747 floatformat argument.
1748 (floatformat_from_host_double): Rename to ...
1749 (host_float_ops<T>::from_host_double): ... this. Use type instead of
1750 floatformat argument.
1751 (floatformat_convert): Rename to ...
1752 (host_float_ops<T>::convert): ... this. Use type instead of
1753 floatformat arguments. Remove handling of no-op conversions.
1754 (floatformat_binop): Rename to ...
1755 (host_float_ops<T>::binop): ... this. Use type instead of
1756 floatformat arguments.
1757 (floatformat_compare): Rename to ...
1758 (host_float_ops<T>::compare): ... this. Use type instead of
1759 floatformat arguments.
1760
1761 (match_endianness): Use type instead of length/byte_order arguments.
1762 (set_decnumber_context): Likewise.
1763 (decimal_from_number): Likewise. Update calls.
1764 (decimal_to_number): Likewise.
1765 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
1766 (decimal_float_ops::to_host_double): New dummy function.
1767 (decimal_float_ops::from_host_double): Likewise.
1768 (decimal_to_string): Rename to ...
1769 (decimal_float_ops::to_string): ... this. Use type instead of
1770 length/byte_order arguments. Update calls.
1771 (decimal_from_string): Rename to ...
1772 (decimal_float_ops::from_string): ... this. Use type instead of
1773 length/byte_order arguments. Update calls.
1774 (decimal_from_longest): Rename to ...
1775 (decimal_float_ops::from_longest): ... this. Use type instead of
1776 length/byte_order arguments. Update calls.
1777 (decimal_from_ulongest): Rename to ...
1778 (decimal_float_ops::from_ulongest): ... this. Use type instead of
1779 length/byte_order arguments. Update calls.
1780 (decimal_to_longest): Rename to ...
1781 (decimal_float_ops::to_longest): ... this. Use type instead of
1782 length/byte_order arguments. Update calls.
1783 (decimal_binop): Rename to ...
1784 (decimal_float_ops::binop): ... this. Use type instead of
1785 length/byte_order arguments. Update calls.
1786 (decimal_compare): Rename to ...
1787 (decimal_float_ops::compare): ... this. Use type instead of
1788 length/byte_order arguments. Update calls.
1789 (decimal_convert): Rename to ...
1790 (decimal_float_ops::convert): ... this. Use type instead of
1791 length/byte_order arguments. Update calls.
1792
1793 (target_float_same_category_p): New function.
1794 (target_float_same_format_p): Likewise.
1795 (target_float_format_length): Likewise.
1796 (enum target_float_ops_kind): New type.
1797 (get_target_float_ops_kind): New function.
1798 (get_target_float_ops): Three new overloaded functions.
1799
1800 (target_float_is_zero): Update call.
1801 (target_float_to_string): Add special handling of invalid numbers,
1802 infinities and NaN (moved from floatformat_to_string). Use
1803 target_float_ops callback.
1804 (target_float_from_string): Use target_float_ops callback.
1805 (target_float_to_longest): Likewise.
1806 (target_float_from_longest): Likewise.
1807 (target_float_from_ulongest): Likewise.
1808 (target_float_to_host_double): Likewise.
1809 (target_float_from_host_double): Likewise.
1810 (target_float_convert): Add special case for no-op conversions.
1811 Use target_float_ops callback.
1812 (target_float_binop): Use target_float_ops callback.
1813 (target_float_compare): Likewise.
1814
a9f26f60
YQ
18152017-11-22 Yao Qi <yao.qi@linaro.org>
1816
1817 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
1818
29f9a567
YQ
18192017-11-22 Yao Qi <yao.qi@linaro.org>
1820
1821 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
1822 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
1823
3b1b69bf
JG
18242017-11-21 Jerome Guitton <guitton@adacore.com>
1825
1826 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
1827 with event ptid from the lower layer before doing the
1828 ravenscar-specific update.
1829
54aa6c67
JB
18302017-11-21 Joel Brobecker <brobecker@adacore.com>
1831
1832 * ravenscar-thread.c (is_ravenscar_task): Also verify that
1833 the ptid's TID is nonzero.
1834
cf3fbed4
JB
18352017-11-21 Joel Brobecker <brobecker@adacore.com>
1836
1837 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
1838 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
1839 Make non-static. Change return type to char *. Adjust code
1840 accordingly. Rewrite the function's documentation.
1841 (read_atcb): Adjust call to get_tcb_types_info accordingly.
1842 * ravenscar-thread.c (ravenscar_inferior_created): Check that
1843 we have enough debugging information in the runtime to support
1844 Ada task debugging before we enable the ravenscar-thread layer.
1845
9edcc12f
JB
18462017-11-21 Joel Brobecker <brobecker@adacore.com>
1847
1848 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
1849 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
1850 * ravenscar-thread.c: Add into comment.
1851 (base_magic_null_ptid): Delete.
1852 (base_ptid): Change documentation.
1853 (ravenscar_active_task): Renames ravenscar_running_thread.
1854 All callers updated throughout.
1855 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
1856 (ravenscar_task_is_currently_active): Likewise.
1857 (get_base_thread_from_ravenscar_task): Ditto.
1858 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
1859 (ravenscar_runtime_initialized): Likewise.
1860 (get_running_thread_id): Add new parameter "cpu". Adjust
1861 implementation to handle this new parameter.
1862 (ravenscar_fetch_registers): Small adjustment to use
1863 is_ravenscar_task and ravenscar_task_is_currently_active in
1864 order to decide whether to use the target beneath or this
1865 module's arch_ops.
1866 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
1867 (ravenscar_stopped_by_sw_breakpoint): Use
1868 get_base_thread_from_ravenscar_task to get the underlying
1869 thread, rather than using base_ptid.
1870 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1871 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1872 Likewise.
1873 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
1874
65d40437
JB
18752017-11-21 Joel Brobecker <brobecker@adacore.com>
1876
1877 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
1878 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
1879 (get_tcb_types_info): Set fieldnos.base_cpu.
1880 (read_atcb): Set task_info->base_cpu.
1881 (info_task): Print "Base CPU" info if set by runtime.
1882
e02544b2
JB
18832017-11-21 Joel Brobecker <brobecker@adacore.com>
1884
1885 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
1886 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1887 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1888 New functions.
1889 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
1890 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
1891 to_stopped_data_address and to_core_of_thread fields of
1892 ravenscar_ops.
1893
ed0f4273
UW
18942017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
1895
1896 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
1897 (struct gdbarch_tdep): New member long_double_abi.
1898 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
1899 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
1900 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
1901 format depending on long_double_abi tdep member.
1902 (ppc_floatformat_for_type): Handle __ibm128 type.
1903
0fc76421
SM
19042017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
1905
1906 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
1907
e6b2f5ef
PA
19082017-11-21 Pedro Alves <palves@redhat.com>
1909
1910 * dwarf2read.c (mapped_index::find_name_components_bounds)
1911 <completion mode, upper bound>: Use std::lower_bound instead of
1912 std::upper_bound.
1913 (test_mapped_index_find_name_component_bounds): Remove incorrect
1914 "t1_fund" from expected symbols.
1915
5c58de74
PA
19162017-11-21 Pedro Alves <palves@redhat.com>
1917
1918 * dwarf2read.c (mapped_index::name_components_casing): New field.
1919 (mapped_index) <build_name_components,
1920 find_name_components_bounds): Declare new methods.
1921 (mapped_index::find_name_components_bounds)
1922 (mapped_index::build_name_components): New methods, factored out
1923 from dw2_expand_symtabs_matching_symbol.
1924 (check_find_bounds_finds)
1925 (test_mapped_index_find_name_component_bounds): New.
1926 (run_test): Rename to ...
1927 (test_dw2_expand_symtabs_matching_symbol): ... this.
1928 (run_test): Reimplement.
1929
e1ef7d7a
PA
19302017-11-21 Pedro Alves <palves@redhat.com>
1931
1932 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
1933 (symbol_end): Use cp_ident_is_alnum.
1934 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
1935 * dwarf2read.c (make_sort_after_prefix_name): New function.
1936 (dw2_expand_symtabs_matching_symbol): Use it.
1937 (test_symbols): Add more symbols.
1938 (run_test): Add tests.
1939
cf724bc9
TT
19402017-11-17 Tom Tromey <tom@tromey.com>
1941
1942 * symtab.h (enum symbol_subclass_kind): New.
1943 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
1944 Remove.
1945 <subclass>: New member.
1946 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
1947 * rust-lang.c (rust_get_trait_object_pointer): Update.
1948 * dwarf2read.c (read_func_scope): Update.
1949 (read_variable): Update.
1950
68e745e3
TT
19512017-11-17 Tom Tromey <tom@tromey.com>
1952
1953 * dwarf2read.c (read_func_scope): Update.
1954 * symtab.h (struct template_symbol): Derive from symbol.
1955 <base>: Remove.
1956
71a3c369
TT
19572017-11-17 Tom Tromey <tom@tromey.com>
1958
1959 * symtab.h (struct symbol) <is_rust_vtable>: New member.
1960 (struct rust_vtable_symbol): New.
1961 (find_symbol_at_address): Declare.
1962 * symtab.c (find_symbol_at_address): New function.
1963 * symfile.h (struct quick_symbol_functions)
1964 <find_compunit_symtab_by_address>: New member.
1965 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
1966 function.
1967 (debug_sym_quick_functions): Link to
1968 debug_qf_find_compunit_symtab_by_address.
1969 * rust-lang.c (rust_get_trait_object_pointer): New function.
1970 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
1971 rust_get_trait_object_pointer.
1972 * psymtab.c (psym_relocate): Clear psymbol_map.
1973 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
1974 functions.
1975 (psym_functions): Link to psym_find_compunit_symtab_by_address.
1976 * objfiles.h (struct objfile) <psymbol_map>: New member.
1977 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
1978 (process_die) <DW_TAG_variable>: New case. Call read_variable.
1979 (rust_containing_type, read_variable): New functions.
1980
7468702d
SM
19812017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1982
1983 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
1984
37269bc9
SM
19852017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1986
1987 * common/filestuff.c: Include <algorithm>.
1988 (open_fds): Change type to std::vector<int>.
1989 (do_mark_open_fd): Adjust.
1990 (unmark_fd_no_cloexec): Adjust.
1991 (do_close): Adjust.
1992
5c632425
SM
19932017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1994
1995 * breakpoint.c (output_thread_groups): Take an std::vector.
1996 (print_one_breakpoint_location): Adjust.
1997
ced9779b
JB
19982017-11-17 Joel Brobecker <brobecker@adacore.com>
1999
2000 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
2001 (ada_evaluate_subexp_for_cast): New function.
2002 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
2003 ada_evaluate_subexp_for_cast.
2004 (ada_evaluate_subexp) <nosideret>: Replace code by call to
2005 eval_skip_value.
2006 * eval.c (evaluate_var_value): Make non-static.
2007 (evaluate_var_msym_value, eval_skip_value): Likewise.
2008 * value.h (evaluate_var_value, evaluate_var_msym_value)
2009 (eval_skip_value): Declare.
2010
b7e22850
JB
20112017-11-16 Joel Brobecker <brobecker@adacore.com>
2012
2013 * ada-lang.c (ada_value_cast): Remove parameter "noside".
2014 Update all callers.
2015
9ccabccd
PA
20162017-11-16 Pedro Alves <palves@redhat.com>
2017
2018 * python/py-unwind.c (pyuw_sniffer): Translate
2019 PyExc_KeyboardInterrupt to a GDB Quit exception.
2020
d930703d
PA
20212017-11-16 Pedro Alves <palves@redhat.com>
2022
2023 * infrun.c (resume_cleanups): Delete.
2024 (resume): No longer install a resume_cleanups cleanup nor call
2025 QUIT.
2026 (proceed): Pass the terminal to the inferior.
2027 (keep_going_pass_signal): No longer install a resume_cleanups
2028 cleanup.
2029
38dc2859
PA
20302017-11-16 Pedro Alves <palves@redhat.com>
2031
2032 * inf-loop.c (inferior_event_handler): Don't swallow the exception
2033 if the prompt is blocked.
2034
688fca4f
PA
20352017-11-16 Pedro Alves <palves@redhat.com>
2036
2037 * breakpoint.c (insert_bp_location): Replace bp_err and
2038 bp_err_message locals by a gdb_exception local.
2039
e2c33ac7
PA
20402017-11-16 Pedro Alves <palves@redhat.com>
2041
2042 * inflow.c (scoped_ignore_sigttou): New class.
2043 (child_terminal_ours_1, new_tty): Use it.
2044
d7236961
UW
20452017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
2046
2047 * target-float.c (decimal_from_number): Add byte_order argument and
2048 call match_endianness. Error if unknown floating-point type.
2049 (decimal_to_number): Add byte_order argument and call match_endianness.
2050 (decimal_from_longest): Update call. Do not call match_endianness.
2051 (decimal_from_ulongest): Likewise.
2052 (decimal_binop): Likewise.
2053 (decimal_is_zero): Likewise.
2054 (decimal_compare): Likewise.
2055 (decimal_convert): Likewise.
2056
d8ae99a7
PM
20572017-11-16 Phil Muldoon <pmuldoon@redhat.com>
2058
2059 * python/python.c (gdbpy_rbreak): New function.
2060 * NEWS: Document Python rbreak feature.
2061
c632b645
YQ
20622017-11-16 Yao Qi <yao.qi@linaro.org>
2063
2064 * features/tic6x-c62x.xml: Remove.
2065 * features/tic6x-c64x.xml: Remove.
2066 * features/tic6x-c64xp.xml: Remove.
2067
a014b87a
JB
20682017-11-15 John Baldwin <jhb@FreeBSD.org>
2069
2070 * symtab.h: Include <array>.
2071
94765011
JB
20722017-11-15 John Baldwin <jhb@FreeBSD.org>
2073
2074 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
2075 (bsd_kvm_proc_cmd): Likewise.
2076
625ad440
SM
20772017-11-15 Simon Marchi <simon.marchi@ericsson.com>
2078
2079 * tui/tui-win.c (window_name_completer): Replace VEC with
2080 std::vector.
2081
c0c11fa9
AC
20822017-11-15 Andrew Cagney <cagney@gnu.org>
2083
2084 * MAINTAINERS: Remove no-longer applicable entries.
2085
34a7ebaf
AC
20862017-11-15 Andrew Cagney <cagney@gnu.org>
2087
2088 * MAINTAINERS: Move self to Past Maintainers.
2089
5334ef39
YQ
20902017-11-15 Yao Qi <yao.qi@linaro.org>
2091
2092 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
2093 * features/nios2-linux.c: Remove.
2094 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
2095 initialize_tdesc_nios2_linux.
2096
a714b0d6
YQ
20972017-11-15 Yao Qi <yao.qi@linaro.org>
2098
2099 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
2100 M68HC11_LAST_HARD_REG + 1.
2101
92ffd475
PC
21022017-11-14 Paul Carroll <pcarroll@codesourcery.com>
2103
2104 PR gdb/22388
2105 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
2106 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
2107 Return TARGET_XFER_EOF if size of returned data is 0.
2108
07431908
SM
21092017-11-14 Simon Marchi <simon.marchi@ericsson.com>
2110
2111 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2112 memory-map-selftests.c.
2113 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
2114 * memory-map.c (memory_map_start_memory): Fix computation of hi
2115 address.
2116 * unittests/memory-map-selftests.c: New file.
2117
31432a67
JB
21182017-11-09 Joel Brobecker <brobecker@adacore.com>
2119
2120 * ada-lang.c: Fix some typos in the general command documenting
2121 how Ada expressions are being evaluated and how their result
2122 is printed.
2123
e793c052
TT
21242017-11-09 Tom Tromey <tom@tromey.com>
2125
2126 * psymtab.c (psymbol_hash): Do not hash string contents.
2127 (psymbol_compare): Add comment.
2128
7e8835c5
TT
21292017-11-09 Tom Tromey <tom@tromey.com>
2130
2131 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
2132
286acbb5
JB
21332017-11-08 Joel Brobecker <brobecker@adacore.com>
2134
2135 * ada-exp.y (write_var_from_sym): Remove parameter
2136 "orig_left_context". Update all callers.
2137
b44ec619
SM
21382017-11-08 Simon Marchi <simon.marchi@ericsson.com>
2139
2140 * tracepoint.h (class collection_list) <stringify>: Return
2141 std::vector<std::string>.
2142 (encode_actions_rsp): Change parameters to
2143 std::vector<std::string> *.
2144 * tracepoint.c (collection_list::stringify): Return
2145 std::vector<std::string> and adjust accordingly.
2146 (encode_actions_rsp): Changee parameters to
2147 std::vector<std::string> and adjust accordingly.
2148 * remote.c (free_actions_list),
2149 free_actions_list_cleanup_wrapper): Remove.
2150 (remote_download_tracepoint): Adjust to std::vector.
2151
2f4732b0
TT
21522017-11-08 Tom Tromey <tom@tromey.com>
2153
2154 * dwarf2read.c (symbolp): Remove typedef.
2155 (read_func_scope): Use std::vector.
2156 (process_structure_scope): Use std::vector.
2157
f9d67a22
PA
21582017-11-08 Pedro Alves <palves@redhat.com>
2159
2160 * ada-lang.c (ada_make_symbol_completion_list): Use
2161 completion_skip_symbol.
2162 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
2163 (symbol_is_function_or_method(symbol*)): New.
2164 (add_symtab_completions): Add complete_symbol_mode parameter. Use
2165 completion_skip_symbol.
2166 (default_collect_symbol_completion_matches_break_on): Use
2167 completion_skip_symbol. Pass down mode.
2168 (collect_file_symbol_completion_matches): Pass down mode.
2169 * symtab.h (symbol_is_function_or_method): New declarations.
2170 (completion_skip_symbol): New template function.
2171
56d87ef7
PA
21722017-11-08 Pedro Alves <palves@redhat.com>
2173
2174 * linespec.c (iterate_over_all_matching_symtabs): Add
2175 search_domain parameter. Pass it down to expand_symtabs_matching.
2176 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
2177 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
2178 search_domain.
2179 (add_all_symbol_names_from_pspace): Add search_domain parameter.
2180 Pass it down.
2181 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
2182 symbols.
2183 (add_matching_symbols_to_info): Add search_domain parameter. Pass
2184 it down.
2185
1b026119
PA
21862017-11-08 Pedro Alves <palves@redhat.com>
2187
2188 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
2189 text_len locals and don't pass them down.
2190 * symtab.c (completion_list_add_name): Remove
2191 sym_text/sym_text_len parameters and adjust.
2192 (completion_list_add_symbol, completion_list_add_msymbol)
2193 (completion_list_objc_symbol, completion_list_add_fields)
2194 (add_symtab_completions): Likewise.
2195 (default_collect_symbol_completion_matches_break_on)
2196 (collect_file_symbol_completion_matches): Remove sym_text_len
2197 local and don't pass it down.
2198 * symtab.h (completion_list_add_name): Remove
2199 sym_text/sym_text_len parameters.
2200
c62446b1
PA
22012017-11-08 Pedro Alves <palves@redhat.com>
2202
2203 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2204 unittests/lookup_name_info-selftests.c.
2205 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
2206 * cp-support.c: Include "selftest.h".
2207 (cp_remove_params_1): Rename from cp_remove_params. Add
2208 'require_param' parameter, and handle it.
2209 (cp_remove_params): Reimplement.
2210 (cp_remove_params_if_any): New.
2211 (selftests::quote): New.
2212 (selftests::check_remove_params): New.
2213 (selftests::test_cp_remove_params): New.
2214 (_initialize_cp_support): Install
2215 selftests::test_cp_remove_params.
2216 * cp-support.h (cp_remove_params_if_any): Declare.
2217 * dwarf2read.c :Include "selftest.h".
2218 (dw2_expand_symtabs_matching_symbol): Use
2219 lookup_name_info::make_ignore_params.
2220 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
2221 (selftests::dw2_expand_symtabs_matching::string_or_null)
2222 (selftests::dw2_expand_symtabs_matching::check_match)
2223 (selftests::dw2_expand_symtabs_matching::test_symbols)
2224 (selftests::dw2_expand_symtabs_matching::run_test): New.
2225 (_initialize_dwarf2_read): Register
2226 selftests::dw2_expand_symtabs_matching::run_test.
2227 * psymtab.c (psym_expand_symtabs_matching): Use
2228 lookup_name_info::make_ignore_params.
2229 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
2230 If the lookup name wants to ignore parameters, strip them.
2231 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
2232 code handling '('.
2233 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
2234 (default_collect_symbol_completion_matches_break_on): Don't try to
2235 strip parameters.
2236 * symtab.h (lookup_name_info::lookup_name_info): Add
2237 'ignore_parameters' parameter.
2238 (lookup_name_info::ignore_parameters)
2239 (lookup_name_info::make_ignore_params): New methods.
2240 (lookup_name_info::m_ignore_parameters): New field.
2241 * unittests/lookup_name_info-selftests.c: New file.
2242
61920122
PA
22432017-11-08 Pedro Alves <palves@redhat.com>
2244
2245 * dwarf2read.c (dw2_expand_marked_cus)
2246 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
2247 (dw2_expand_symtabs_matching): Move further below.
2248 (dw2_expand_marked_cus): Reindent.
2249
3f563c84
PA
22502017-11-08 Pedro Alves <palves@redhat.com>
2251
2252 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
2253 (struct name_component): New.
2254 (mapped_index::name_components): New field.
2255 (mapped_index::symbol_name_at): New method.
2256 (dwarf2_read_index): Call mapped_index ctor.
2257 (dw2_map_matching_symbols): Add comment about name_components
2258 table.
2259 (dw2_expand_symtabs_matching): Factor part to...
2260 (dw2_expand_symtabs_matching_symbol): ... this new function.
2261 Build name components table, and lookup symbols in it before
2262 calling the name matcher.
2263 (dw2_expand_marked_cus): New, factored out from
2264 dw2_expand_symtabs_matching.
2265 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
2266
b5ec771e
PA
22672017-11-08 Pedro Alves <palves@redhat.com>
2268
2269 * ada-lang.c (ada_encode): Rename to ..
2270 (ada_encode_1): ... this. Add throw_errors parameter and handle
2271 it.
2272 (ada_encode): Reimplement.
2273 (match_name): Delete, folded into full_name.
2274 (resolve_subexp): No longer pass the encoded name to
2275 ada_lookup_symbol_list.
2276 (should_use_wild_match): Delete.
2277 (name_match_type_from_name): New.
2278 (ada_lookup_simple_minsym): Use lookup_name_info and the
2279 language's symbol_name_matcher_ftype.
2280 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
2281 (ada_add_block_renamings): Adjust to use lookup_name_info.
2282 (ada_lookup_name): New.
2283 (add_nonlocal_symbols, ada_add_all_symbols)
2284 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
2285 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
2286 (ada_name_for_lookup): Delete.
2287 (ada_lookup_encoded_symbol): Construct a verbatim name.
2288 (wild_match): Reverse sense of return type. Use bool.
2289 (full_match): Reverse sense of return type. Inline bits of old
2290 match_name here.
2291 (ada_add_block_symbols): Adjust to use lookup_name_info.
2292 (symbol_completion_match): Delete, folded into...
2293 (ada_lookup_name_info::matches): ... .this new method.
2294 (symbol_completion_add): Delete.
2295 (ada_collect_symbol_completion_matches): Add name_match_type
2296 parameter. Adjust to use lookup_name_info and
2297 completion_list_add_name.
2298 (get_var_value, ada_add_global_exceptions): Adjust to use
2299 lookup_name_info.
2300 (ada_get_symbol_name_cmp): Delete.
2301 (do_wild_match, do_full_match): New functions.
2302 (ada_lookup_name_info::ada_lookup_name_info): New method.
2303 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
2304 functions.
2305 (ada_language_defn): Install ada_get_symbol_name_matcher.
2306 * ada-lex.l (processId): If name starts with '<', copy it
2307 verbatim.
2308 * block.c (block_iter_match_step, block_iter_match_first)
2309 (block_iter_match_next, block_lookup_symbol)
2310 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
2311 lookup_name_info.
2312 * block.h (block_iter_match_first, block_iter_match_next)
2313 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
2314 * c-lang.c (c_language_defn, cplus_language_defn)
2315 (asm_language_defn, minimal_language_defn): Adjust comments to
2316 refer to la_get_symbol_name_matcher.
2317 * completer.c (complete_files_symbols)
2318 (collect_explicit_location_matches, symbol_completer): Pass a
2319 symbol_name_match_type down.
2320 * completer.h (class completion_match, completion_match_result):
2321 New classes.
2322 (completion_tracker::reset_completion_match_result): New method.
2323 (completion_tracker::m_completion_match_result): New field.
2324 * cp-support.c (make_symbol_overload_list_block): Adjust to use
2325 lookup_name_info.
2326 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
2327 functions.
2328 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
2329 * d-lang.c: Adjust comments to refer to
2330 la_get_symbol_name_matcher.
2331 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
2332 Adjust to use lookup_name_info.
2333 (dict_iter_match_first, dict_iter_match_next)
2334 (iter_match_first_hashed, iter_match_next_hashed)
2335 (iter_match_first_linear, iter_match_next_linear): Adjust to work
2336 with a lookup_name_info.
2337 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
2338 Likewise.
2339 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
2340 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
2341 (gdb_index_symbol_name_matcher): New class.
2342 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
2343 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
2344 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
2345 with a symbol_name_match_type.
2346 (f_language_defn): Adjust comments to refer to
2347 la_get_symbol_name_matcher.
2348 * go-lang.c (go_language_defn): Adjust comments to refer to
2349 la_get_symbol_name_matcher.
2350 * language.c (default_symbol_name_matcher)
2351 (language_get_symbol_name_matcher): New functions.
2352 (unknown_language_defn, auto_language_defn): Adjust comments to
2353 refer to la_get_symbol_name_matcher.
2354 * language.h (symbol_name_cmp_ftype): Delete.
2355 (language_defn) <la_collect_symbol_completion_matches>: Add match
2356 type parameter.
2357 <la_get_symbol_name_cmp>: Delete field.
2358 <la_get_symbol_name_matcher>: New field.
2359 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
2360 (default_symbol_name_matcher, language_get_symbol_name_matcher):
2361 Declare.
2362 * linespec.c (iterate_over_all_matching_symtabs)
2363 (iterate_over_file_blocks): Adjust to use lookup_name_info.
2364 (find_methods): Add language parameter, and use lookup_name_info
2365 and the language's symbol_name_matcher_ftype.
2366 (linespec_complete_function): Adjust.
2367 (lookup_prefix_sym): Use lookup_name_info.
2368 (add_all_symbol_names_from_pspace): Adjust.
2369 (find_superclass_methods): Add language parameter and pass it
2370 down.
2371 (find_method): Pass symbol language down.
2372 (find_linespec_symbols): Don't demangle or Ada encode here.
2373 (search_minsyms_for_name): Add lookup_name_info parameter.
2374 (add_matching_symbols_to_info): Add name_match_type parameter.
2375 Use lookup_name_info.
2376 * m2-lang.c (m2_language_defn): Adjust comments to refer to
2377 la_get_symbol_name_matcher.
2378 * minsyms.c: Include <algorithm>.
2379 (add_minsym_to_demangled_hash_table): Remove table parameter and
2380 add objfile parameter. Use search_name_hash, and add language to
2381 demangled languages vector.
2382 (struct found_minimal_symbols): New struct.
2383 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
2384 New functions.
2385 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
2386 input names here. Use lookup_name_info instead. Lookup up
2387 demangled names once for each language in the demangled names
2388 vector.
2389 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
2390 demangled names once for each language in the demangled names
2391 vector.
2392 (build_minimal_symbol_hash_tables): Adjust.
2393 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
2394 lookup_name_info.
2395 * objc-lang.c (objc_language_defn): Adjust comment to refer to
2396 la_get_symbol_name_matcher.
2397 * objfiles.h: Include <vector>.
2398 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
2399 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
2400 la_get_symbol_name_matcher.
2401 * p-lang.c (pascal_language_defn): Adjust comment to refer to
2402 la_get_symbol_name_matcher.
2403 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
2404 (match_partial_symbol): Use symbol_name_match_type,
2405 lookup_name_info and psymbol_name_matches.
2406 (lookup_partial_symbol): Use lookup_name_info.
2407 (map_block): Use symbol_name_match_type and lookup_name_info.
2408 (psym_map_matching_symbols): Use symbol_name_match_type.
2409 (psymbol_name_matches): New.
2410 (recursively_search_psymtabs): Use lookup_name_info and
2411 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
2412 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
2413 'kind' parameter to 'domain'.
2414 * rust-lang.c (rust_language_defn): Adjust comment to refer to
2415 la_get_symbol_name_matcher.
2416 * symfile-debug.c (debug_qf_map_matching_symbols)
2417 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
2418 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
2419 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
2420 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
2421 Adjust to use symbol_name_match_type.
2422 <expand_symtabs_matching>: Adjust to use lookup_name_info.
2423 (expand_symtabs_matching): Adjust to use lookup_name_info.
2424 * symmisc.c (maintenance_expand_symtabs): Use
2425 lookup_name_info::match_any ().
2426 * symtab.c (symbol_matches_search_name): New.
2427 (eq_symbol_entry): Adjust to use lookup_name_info and the
2428 language's matcher.
2429 (demangle_for_lookup_info::demangle_for_lookup_info): New.
2430 (lookup_name_info::match_any): New.
2431 (iterate_over_symbols, search_symbols): Use lookup_name_info.
2432 (compare_symbol_name): Add language, lookup_name_info and
2433 completion_match_result parameters, and use them.
2434 (completion_list_add_name): Make extern. Add language and
2435 lookup_name_info parameters. Use them.
2436 (completion_list_add_symbol, completion_list_add_msymbol)
2437 (completion_list_objc_symbol): Add lookup_name_info parameters and
2438 adjust. Pass down language.
2439 (completion_list_add_fields): Add lookup_name_info parameters and
2440 adjust. Pass down language.
2441 (add_symtab_completions): Add lookup_name_info parameters and
2442 adjust.
2443 (default_collect_symbol_completion_matches_break_on): Add
2444 name_match_type parameter, and use it. Use lookup_name_info.
2445 (default_collect_symbol_completion_matches)
2446 (collect_symbol_completion_matches): Add name_match_type
2447 parameter, and pass it down.
2448 (collect_symbol_completion_matches_type): Adjust.
2449 (collect_file_symbol_completion_matches): Add name_match_type
2450 parameter, and use lookup_name_info.
2451 * symtab.h: Include <string> and "common/gdb_optional.h".
2452 (enum class symbol_name_match_type): New.
2453 (class ada_lookup_name_info): New.
2454 (struct demangle_for_lookup_info): New.
2455 (class lookup_name_info): New.
2456 (symbol_name_matcher_ftype): New.
2457 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
2458 (symbol_matches_search_name): Declare.
2459 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
2460 (default_collect_symbol_completion_matches)
2461 (collect_symbol_completion_matches)
2462 (collect_file_symbol_completion_matches): Add name_match_type
2463 parameter.
2464 (iterate_over_symbols): Use lookup_name_info.
2465 (completion_list_add_name): Declare.
2466 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
2467 (strncmp_iw_with_mode): Now extern.
2468 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
2469 (strncmp_iw_with_mode): Declare.
2470
5ffa0793
PA
24712017-11-08 Keith Seitz <keiths@redhat.com>
2472 Pedro Alves <palves@redhat.com>
2473
2474 * ada-lang.c (ada_language_defn): Install
2475 default_search_name_hash.
2476 * buildsym.c (struct buildsym_compunit): <language>: New field.
2477 (finish_block_internal): Pass language when creating dictionaries.
2478 (start_buildsym_compunit, start_symtab): New language parameters.
2479 Use them.
2480 (restart_symtab): Pass down compilation unit's language.
2481 * buildsym.h (enum language): Forward declare.
2482 (start_symtab): New 'language' parameter.
2483 * c-lang.c (c_language_defn, cplus_language_defn)
2484 (asm_language_defn, minimal_language_defn): Install
2485 default_search_name_hash.
2486 * coffread.c (coff_start_symtab): Adjust.
2487 * d-lang.c (d_language_defn): Install default_search_name_hash.
2488 * dbxread.c (struct symloc): Add 'pst_language' field.
2489 (PST_LANGUAGE): Define.
2490 (start_psymtab, read_ofile_symtab): Use it.
2491 (process_one_symbol): New 'language' parameter. Pass it down.
2492 * dictionary.c (struct dictionary) <language>: New field.
2493 (DICT_LANGUAGE): Define.
2494 (dict_create_hashed, dict_create_hashed_expandable)
2495 (dict_create_linear, dict_create_linear_expandable): New parameter
2496 'language'. Set the dictionary's language.
2497 (iter_match_first_hashed): Adjust to rename.
2498 (insert_symbol_hashed): Assert we don't see mismatching
2499 languages. Adjust to rename.
2500 (dict_hash): Rename to ...
2501 (default_search_name_hash): ... this and make extern.
2502 * dictionary.h (struct language_defn): Forward declare.
2503 (dict_create_hashed): New parameter 'language'.
2504 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
2505 * f-lang.c (f_language_defn): Install default_search_name_hash.
2506 * go-lang.c (go_language_defn): Install default_search_name_hash.
2507 * jit.c (finalize_symtab): Pass compunit's language to dictionary
2508 creation.
2509 * language.c (unknown_language_defn, auto_language_defn):
2510 * language.h (language_defn::la_search_name_hash): New field.
2511 (default_search_name_hash): Declare.
2512 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
2513 * mdebugread.c (new_block): New parameter 'language'.
2514 * mdebugread.c (parse_symbol): Pass symbol language to block
2515 allocation.
2516 (psymtab_to_symtab_1): Pass down language.
2517 (new_symtab): Pass compunit's language to block allocation.
2518 * objc-lang.c (objc_language_defn): Install
2519 default_search_name_hash.
2520 * opencl-lang.c (opencl_language_defn):
2521 * p-lang.c (pascal_language_defn): Install
2522 default_search_name_hash.
2523 * rust-lang.c (rust_language_defn): Install
2524 default_search_name_hash.
2525 * stabsread.h (enum language): Forward declare.
2526 (process_one_symbol): Add 'language' parameter.
2527 * symtab.c (search_name_hash): New function.
2528 * symtab.h (search_name_hash): Declare.
2529 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
2530
2a1dde5d
PA
25312017-11-08 Pedro Alves <palves@redhat.com>
2532
2533 * cp-name-parser.y (main): Don't initialize extra_chars.
2534
95a6b0a1
TT
25352017-11-07 Tom Tromey <tom@tromey.com>
2536
2537 * event-top.h (command_handler): Constify.
2538 * record-full.c (cmd_record_full_start): Update.
2539 * thread.c (thread_apply_all_command): Update.
2540 * printcmd.c (eval_command): Update.
2541 * mi/mi-main.c (mi_execute_cli_command): Update.
2542 (mi_execute_async_cli_command): Update.
2543 * tui/tui-stack.c (tui_update_command): Update.
2544 * cli/cli-interp.c (safe_execute_command): Constify.
2545 * record.c (record_start): Update.
2546 (record_start, record_stop, cmd_record_start): Update.
2547 * record-btrace.c (cmd_record_btrace_bts_start): Update.
2548 (cmd_record_btrace_pt_start): Update.
2549 (cmd_record_btrace_start): Update.
2550 (cmd_record_btrace_start): Update.
2551 * reverse.c (exec_reverse_once): Update.
2552 * python/python.c (execute_gdb_command): Don't copy the command.
2553 * event-top.c (command_line_handler): Update.
2554 (command_handler): Constify.
2555 * defs.h (deprecated_call_command_hook): Constify.
2556 * cli/cli-script.h (execute_user_command): Constify.
2557 * cli/cli-script.c (execute_user_command): Constify.
2558 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
2559 (enum command_control_type): Update.
2560 * main.c (catch_command_errors): Remove non-const overload.
2561 (catch_command_errors_ftype): Remove.
2562 * python/py-cmd.c (cmdpy_function): Constify.
2563 * guile/scm-cmd.c (cmdscm_function): Constify.
2564 * cli/cli-dump.c (call_dump_func): Constify.
2565 * cli/cli-decode.c (do_const_cfunc): Constify.
2566 (do_sfunc): Constify.
2567 (cmd_func): Constify.
2568 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
2569 * top.h (execute_command): Constify.
2570 * top.c (execute_command): Constify.
2571 (execute_command_to_string): Constify.
2572 (deprecated_call_command_hook): Constify.
2573 * command.h (cmd_func): Constify.
2574 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
2575
eb4c3f4a
TT
25762017-11-07 Tom Tromey <tom@tromey.com>
2577
2578 * ada-lang.c (catch_ada_exception_command): Constify.
2579 (catch_assert_command): Constify.
2580 * break-catch-throw.c (catch_catch_command, catch_throw_command)
2581 (catch_rethrow_command): Constify.
2582 (catch_exception_command_1): Constify.
2583 * breakpoint.h (add_catch_command): Constify.
2584 * break-catch-syscall.c (catch_syscall_command_1): Constify.
2585 (catch_syscall_split_args): Constify.
2586 * break-catch-sig.c (catch_signal_command): Constify.
2587 (catch_signal_split_args): Constify.
2588 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
2589 cmd_const_sfunc_ftype.
2590 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
2591 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2592 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2593 (add_setshow_string_cmd, struct cmd_list_element)
2594 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2595 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2596 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
2597 Constify.
2598 (set_cmd_sfunc): Constify.
2599 (empty_sfunc): Constify.
2600 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2601 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2602 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
2603 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2604 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2605 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
2606 Constify.
2607 (set_cmd_sfunc): Constify.
2608 (cmd_sfunc_ftype): Remove.
2609 * compile/compile.c (set_compile_args): Constify.
2610 * infrun.c (set_disable_randomization): Constify.
2611 * infcmd.c (set_args_command, set_cwd_command): Constify.
2612 * breakpoint.c (set_condition_evaluation_mode): Constify.
2613 (add_catch_command): Constify.
2614 (catch_fork_command_1, catch_exec_command_1)
2615 (catch_load_command_1, catch_unload_command_1): Constify.
2616 (catch_load_or_unload): Constify.
2617 * guile/scm-param.c (pascm_set_func): Constify.
2618 (add_setshow_generic): Constify.
2619 * python/py-param.c (get_set_value): Constify.
2620 * top.h (set_verbose): Constify.
2621 * tui/tui-win.c (tui_set_var_cmd): Constify.
2622 * mi/mi-main.c (set_mi_async_command): Constify.
2623 * cli/cli-logging.c (set_logging_overwrite)
2624 (set_logging_redirect): Constify.
2625 * value.c (set_max_value_size): Constify.
2626 * valprint.c (set_input_radix, set_output_radix): Constify.
2627 * utils.c (set_width_command, set_height_command): Constify.
2628 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
2629 * tracepoint.c (set_disconnected_tracing)
2630 (set_circular_trace_buffer, set_trace_buffer_size)
2631 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
2632 * top.c (set_history_size_command, set_verbose, set_editing)
2633 (set_gdb_datadir, set_history_filename): Constify.
2634 * target.c (set_targetdebug, maint_set_target_async_command)
2635 (maint_set_target_non_stop_command, set_target_permissions)
2636 (set_write_memory_permission): Constify.
2637 (open_target): Constify.
2638 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
2639 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
2640 * symtab.c (set_symbol_cache_size_handler): Constify.
2641 * symfile.c (set_ext_lang_command): Constify.
2642 * symfile-debug.c (set_debug_symfile): Constify.
2643 * source.c (set_directories_command): Constify.
2644 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
2645 * serial.c (set_parity): Constify.
2646 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
2647 * remote.c (set_remote_exec_file, set_remotebreak)
2648 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
2649 * record.c (set_record_insn_history_size)
2650 (set_record_call_history_size): Constify.
2651 * record-full.c (set_record_full_insn_max_num): Constify.
2652 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
2653 * osabi.c (set_osabi): Constify.
2654 * mips-tdep.c (set_mips64_transfers_32bit_regs)
2655 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
2656 * maint.c (maintenance_set_profile_cmd): Constify.
2657 * linux-thread-db.c (set_libthread_db_search_path): Constify.
2658 * language.c (set_language_command, set_range_command)
2659 (set_case_command): Constify.
2660 * infrun.c (set_non_stop, set_observer_mode)
2661 (set_stop_on_solib_events, set_schedlock_func)
2662 (set_exec_direction_func): Constify.
2663 * infcmd.c (set_inferior_tty_command): Constify.
2664 * disasm.c (set_disassembler_options_sfunc): Constify.
2665 * demangle.c (set_demangling_command): Constify.
2666 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
2667 * cris-tdep.c (set_cris_version, set_cris_mode)
2668 (set_cris_dwarf2_cfi): Constify.
2669 * corefile.c (set_gnutarget_command): Constify.
2670 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
2671 (set_target_wide_charset_sfunc): Constify.
2672 * breakpoint.c (update_dprintf_commands): Constify.
2673 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
2674 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
2675 (set_disassembly_style_sfunc): Constify.
2676 * arch-utils.c (set_endian, set_architecture): Constify.
2677 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
2678 * agent.c (set_can_use_agent): Constify.
2679
5fed81ff
TT
26802017-11-07 Tom Tromey <tom@tromey.com>
2681
2682 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
2683 (go32_pde, go32_pte, go32_pte_for_address): Constify.
2684 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
2685 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
2686 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
2687 (parse_int_arg, show_thread_default_detach_sc_cmd)
2688 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
2689 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
2690 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
2691 (show_task_pause_cmd, set_task_detach_sc_cmd)
2692 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
2693 (set_noninvasive_cmd, set_thread_pause_cmd)
2694 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
2695 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
2696 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
2697 * windows-nat.c (display_selectors): Constify.
2698 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
2699 non-const "cfunc".
2700 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
2701 (cmd_cfunc_eq): Likewise.
2702 (struct cmd_list_element): Likewise.
2703 (do_cfunc): Remove.
2704 (cli_user_command_p): Update.
2705 * command.h (add_cmd): Remove non-const overload.
2706 (cmd_cfunc_ftype): Remove typedef.
2707 (cmd_cfunc_eq): Remove non-const overload.
2708 * value.c (show_values): Constify.
2709 * thread.c (thread_apply_all_command): Constify.
2710 * symfile.c (load_command): Constify.
2711 * source.c (directory_command): Constify.
2712 * maint.c (maintenance_internal_error)
2713 (maintenance_demangler_warning, maintenance_space_display)
2714 (maintenance_print_architecture, maintenance_translate_address)
2715 (maintenance_info_selftests, maintenance_internal_warning):
2716 Constify.
2717 * breakpoint.c (disable_trace_command, enable_trace_command):
2718 Constify.
2719 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
2720 Constify.
2721 (add_auto_load_safe_path): Constify.
2722 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
2723 * top.h (show_commands): Constify.
2724 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
2725 * sparc64-tdep.c (adi_examine_command): Constify.
2726 (adi_assign_command): Constify.
2727
1d12d88f
TT
27282017-11-07 Tom Tromey <tom@tromey.com>
2729
2730 * frame.h (info_locals_command, info_args_command): Constify.
2731 * auto-load.h (auto_load_info_scripts): Constify.
2732 * inferior.h (registers_info): Constify.
2733 * copying.c: Rebuild.
2734 * copying.awk: Constify generated commands.
2735 * auto-load.c (auto_load_info_scripts)
2736 (info_auto_load_gdb_scripts): Constify.
2737 * cli/cli-decode.c (struct cmd_list_element): Take a
2738 cmd_const_cfunc_ftype.
2739 * command.h (add_info): Take a cmd_const_cfunc_ftype.
2740 * tui/tui-win.c (tui_all_windows_info): Constify.
2741 * python/py-auto-load.c (info_auto_load_python_scripts):
2742 Constify.
2743 * cli/cli-cmds.c (show_command): Remove non-const overload.
2744 * tracepoint.c (info_tvariables_command, info_scope_command):
2745 Constify.
2746 (info_static_tracepoint_markers_command): Constify.
2747 * thread.c (info_threads_command): Constify.
2748 (print_thread_info_1): Constify.
2749 * target.c (info_target_command): Constify.
2750 * symtab.c (info_sources_command, info_functions_command)
2751 (info_types_command): Constify.
2752 (info_variables_command): Remove non-const overload.
2753 * symfile.c (info_ext_lang_command): Constify.
2754 * stack.c (info_frame_command, info_locals_command)
2755 (info_args_command): Constify.
2756 (backtrace_command): Remove non-const overload.
2757 * source.c (info_source_command, info_line_command): Constify.
2758 * solib.c (info_sharedlibrary_command): Constify.
2759 * skip.c (info_skip_command): Constify.
2760 * ser-go32.c (info_serial_command): Constify.
2761 * reverse.c (info_bookmarks_command): Constify.
2762 * printcmd.c (info_symbol_command, info_address_command)
2763 (info_display_command): Constify.
2764 * osdata.c (info_osdata_command): Constify.
2765 * objc-lang.c (info_selectors_command, info_classes_command):
2766 Constify.
2767 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
2768 * memattr.c (info_mem_command): Constify.
2769 * macrocmd.c (info_macro_command, info_macros_command): Constify.
2770 * linux-fork.c (info_checkpoints_command): Constify.
2771 * infrun.c (info_signals_command): Constify.
2772 * inflow.c (info_terminal_command): Constify.
2773 * inferior.c (info_inferiors_command): Constify.
2774 (print_inferior): Constify.
2775 * infcmd.c (info_program_command, info_all_registers_command)
2776 (info_registers_command, info_vector_command)
2777 (info_float_command): Constify.
2778 (registers_info): Constify.
2779 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
2780 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
2781 Constify.
2782 * f-valprint.c (info_common_command): Constify.
2783 * dcache.c (info_dcache_command): Constify.
2784 (dcache_info_1): Constify.
2785 * darwin-nat-info.c (info_mach_tasks_command)
2786 (info_mach_task_command, info_mach_ports_command)
2787 (info_mach_port_command, info_mach_threads_command)
2788 (info_mach_thread_command, info_mach_regions_command)
2789 (info_mach_regions_recurse_command, info_mach_region_command)
2790 (info_mach_exceptions_command): Constify.
2791 (get_task_from_args): Constify.
2792 * cp-support.c (info_vtbl_command): Constify.
2793 * breakpoint.c (info_watchpoints_command)
2794 (info_tracepoints_command): Constify.
2795 (info_breakpoints_command): Remove non-const overload.
2796 * avr-tdep.c (avr_io_reg_read_command): Constify.
2797 * auxv.c (info_auxv_command): Constify.
2798 * ada-tasks.c (info_tasks_command): Constify.
2799 (info_task): Constify.
2800 * ada-lang.c (info_exceptions_command): Constify.
2801
0b39b52e
TT
28022017-11-07 Tom Tromey <tom@tromey.com>
2803
2804 * solib.h (no_shared_libraries): Constify.
2805 * frame.h (return_command): Constify.
2806 * cli/cli-cmds.h (quit_command): Constify.
2807 * top.h (quit_command, execute_command): Constify.
2808 * target.h (flash_erase_command): Constify.
2809 * inferior.h (set_inferior_args, attach_command): Constify.
2810 * tracepoint.h (start_tracing, stop_tracing): Constify.
2811 * breakpoint.h (break_command, tbreak_command)
2812 (hbreak_command_wrapper, thbreak_command_wrapper)
2813 (rbreak_command_wrapper, watch_command_wrapper)
2814 (awatch_command_wrapper, rwatch_command_wrapper)
2815 (get_tracepoint_by_number): Constify.
2816 * symtab.c (info_variables_command, rbreak_command)
2817 (symtab_symbol_info): Constify.
2818 (info_variables_command): Add non-const overload.
2819 * top.c (dont_repeat_command): Constify.
2820 * breakpoint.c (ignore_command, commands_command)
2821 (condition_command, tbreak_command, hbreak_command)
2822 (thbreak_command, clear_command, break_command)
2823 (info_breakpoints_command, watch_command, rwatch_command)
2824 (awatch_command, trace_command, ftrace_command, strace_command)
2825 (trace_pass_command, break_range_command, dprintf_command)
2826 (agent_printf_command, get_tracepoint_by_number)
2827 (watch_maybe_just_location, trace_pass_command): Constify.
2828 (info_breakpoints_command): Add non-const overload.
2829 * tracefile.c (tsave_command): Constify.
2830 * infcmd.c (attach_command, disconnect_command, signal_command)
2831 (queue_signal_command, stepi_command, nexti_command)
2832 (finish_command, next_command, step_command, until_command)
2833 (advance_command, jump_command, continue_command, run_command)
2834 (start_command, starti_command, interrupt_command)
2835 (run_command_1, set_inferior_args, step_1): Constify.
2836 * inferior.c (add_inferior_command, remove_inferior_command)
2837 (clone_inferior_command): Constify.
2838 * linux-fork.c (checkpoint_command, restart_command): Constify.
2839 * windows-nat.c (signal_event_command): Constify.
2840 * guile/guile.c (guile_repl_command, guile_command): Constify.
2841 * printcmd.c (x_command, display_command, printf_command)
2842 (output_command, set_command, call_command, print_command)
2843 (eval_command): Constify.
2844 (non_const_set_command): Remove.
2845 (_initialize_printcmd): Update.
2846 * source.c (forward_search_command, reverse_search_command):
2847 Constify.
2848 * jit.c (jit_reader_load_command, jit_reader_unload_command):
2849 Constify.
2850 * infrun.c (handle_command): Constify.
2851 * memattr.c (mem_command): Constify.
2852 * stack.c (return_command, up_command, up_silently_command)
2853 (down_command, down_silently_command, frame_command)
2854 (backtrace_command, func_command, backtrace_command_1): Constify.
2855 (backtrace_command): Add non-const overload.
2856 * remote-sim.c (simulator_command): Constify.
2857 * exec.c (set_section_command): Constify.
2858 * tracepoint.c (tdump_command, trace_variable_command)
2859 (tstatus_command, tstop_command, tstart_command)
2860 (end_actions_pseudocommand, while_stepping_pseudocommand)
2861 (collect_pseudocommand, teval_pseudocommand, actions_command)
2862 (start_tracing, stop_tracing): Constify.
2863 * value.c (init_if_undefined_command): Constify.
2864 * tui/tui-stack.c (tui_update_command): Constify.
2865 * tui/tui-win.c (tui_refresh_all_command)
2866 (tui_set_tab_width_command, tui_set_win_height_command)
2867 (tui_set_focus_command, tui_scroll_forward_command)
2868 (tui_scroll_backward_command, tui_scroll_left_command)
2869 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
2870 (tui_set_win_height): Constify.
2871 * tui/tui-layout.c (tui_layout_command): Constify.
2872 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
2873 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
2874 (proc_untrace_sysexit_cmd): Constify.
2875 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
2876 (threadset_test_cmd, threadlist_update_test_cmd)
2877 (threadalive_test): Constify.
2878 * objc-lang.c (print_object_command): Constify.
2879 * command.h (add_com): Constify.
2880 * cli/cli-dump.c (restore_command): Constify.
2881 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
2882 (help_command, complete_command, shell_command, edit_command)
2883 (list_command, disassemble_command, make_command)
2884 (apropos_command, alias_command): Constify.
2885 * cli/cli-script.c (document_command, define_command)
2886 (while_command, if_command, validate_comname): Constify.
2887 * cli/cli-decode.c (struct cmd_list_element): Change type of
2888 "fun".
2889 * target.c (do_monitor_command, flash_erase_command): Constify.
2890 * regcache.c (reg_flush_command): Constify.
2891 * reverse.c (reverse_step, reverse_next, reverse_stepi)
2892 (reverse_nexti, reverse_continue, reverse_finish)
2893 (save_bookmark_command, goto_bookmark_command)
2894 (exec_reverse_once): Constify.
2895 * python/python.c (python_interactive_command, python_command):
2896 Constify.
2897 * typeprint.c (ptype_command, whatis_command, whatis_exp):
2898 Constify.
2899 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
2900 * gcore.c (gcore_command): Constify.
2901
85c4be7c
TT
29022017-11-07 Tom Tromey <tom@tromey.com>
2903
2904 * printcmd.c (x_command): Call set_repeat_arguments.
2905 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
2906 * top.c (repeat_arguments): New global.
2907 (set_repeat_arguments): New function.
2908 (execute_command): Handle repeat_arguments.
2909 (show_commands): Calls set_repeat_arguments.
2910 * command.h (set_repeat_arguments): Declare.
2911
022643b4
TT
29122017-11-07 Tom Tromey <tom@tromey.com>
2913
2914 * stack.c (backtrace_command): Use std::string.
2915 (backtrace_command_1): Make "count_exp" const.
2916
5614fb77
TT
29172017-11-07 Tom Tromey <tom@tromey.com>
2918
2919 * source.c (directory_switch, mod_path, add_path): Constify.
2920 * defs.h (add_path, mod_path, directory_switch): Constify.
2921 * mi/mi-cmd-env.c (env_mod_path): Constify.
2922
6be9a197
TT
29232017-11-07 Tom Tromey <tom@tromey.com>
2924
2925 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
2926 (run_command_1, continue_command, step_1, jump_command)
2927 (signal_command, until_command, advance_command, finish_command)
2928 (attach_command): Update.
2929
c2252c0d
TT
29302017-11-07 Tom Tromey <tom@tromey.com>
2931
2932 * command.h (set_cmd_cfunc): Don't declare.
2933 * cli/cli-decode.c (set_cmd_cfunc): Now static.
2934
1ee870c5
TT
29352017-11-07 Tom Tromey <tom@tromey.com>
2936
2937 * stack.c (select_frame_command): Constify.
2938 * cli/cli-decode.c (add_com_suppress_notification): Constify.
2939 * command.h (add_com_suppress_notification): Constify.
2940
ee7ddd71
TT
29412017-11-07 Tom Tromey <tom@tromey.com>
2942
2943 * breakpoint.c (stop_command): Constify.
2944 * cli/cli-decode.c (struct cmd_list_element): Constify.
2945 * command.h (add_abbrev_prefix_cmd): Constify.
2946
95e95a6d
PA
29472017-11-07 Pedro Alves <palves@redhat.com>
2948
2949 * breakpoint.c (extract_bp_kind): New enum.
2950 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
2951 factored out from ...
2952 (extract_bp_number_and_location): ... here.
2953 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
2954
cc638e86
PA
29552017-11-07 Pedro Alves <palves@redhat.com>
2956
2957 * breakpoint.c (extract_bp_number_and_location): Change return
2958 type to void. Throw error instead of warning.
2959 (enable_disable_command): Adjust.
2960
d0fe4701
XR
29612017-11-07 Xavier Roirand <roirand@adacore.com>
2962 Pedro Alves <palves@redhat.com>
2963
2964 * breakpoint.c (map_breakpoint_number_range): New, factored out
2965 from ...
2966 (map_breakpoint_numbers): ... here.
2967 (find_location_by_number): Change parameters from string to
2968 breakpoint number and location.
2969 (extract_bp_number_and_location): New function.
2970 (enable_disable_bp_num_loc)
2971 (enable_disable_breakpoint_location_range)
2972 (enable_disable_command): New functions, factored out ...
2973 (enable_command, disable_command): ... these functions, and
2974 adjusted to support ranges.
2975 * NEWS: Document enable/disable breakpoint location range feature.
2976
635dc5b2
LM
29772017-11-06 Luis Machado <luis.machado@linaro.org>
2978
2979 * MAINTAINERS (Write After Approval): Update my e-mail address.
2980
556e5da5
PA
29812017-11-06 Pedro Alves <palves@redhat.com>
2982
2983 * gnu-nat.c (gnu_terminal_init): Delete.
2984 (gnu_target): Don't install gnu_terminal_init.
2985 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
2986 (child_terminal_init): ... this function.
2987
d1928160
PA
29882017-11-06 Pedro Alves <palves@redhat.com>
2989
2990 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
2991 sgtty.h.
2992 * config.in, configure: Regenerate.
2993
6aa899ce
PA
29942017-11-06 Pedro Alves <palves@redhat.com>
2995
2996 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
2997 (async_init_signals): Adjust.
2998 (handle_stop_sig): Rename to ...
2999 (handle_sigtstp): ... this.
3000 (async_stop_sig): Rename to ...
3001 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
3002 SIGTSTP path.
3003 * event-top.h: Move signal.h include to the top. Check SIGTSTP
3004 instead of STOP_SIGNAL thoughout.
3005 (handle_stop_sig): Rename to ...
3006 (handle_sigtstp): ... this.
3007 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
3008
a94799ac
PA
30092017-11-06 Pedro Alves <palves@redhat.com>
3010
3011 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
3012 longer set flags twice in row.
3013
726e1356
PA
30142017-11-06 Pedro Alves <palves@redhat.com>
3015
3016 * Makefile.in (SER_HARDWIRE): Update comment.
3017 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
3018 * common/gdb_termios.h: Delete file.
3019 * common/job-control.c: Include termios.h and unistd.h instead of
3020 gdb_termios.h.
3021 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
3022 check.
3023 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
3024 Remove sgtty code.
3025 * configure.ac: No longer check for termio.h and sgtty.h.
3026 * configure: Regenerate.
3027 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
3028 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
3029 Replace PROCESS_GROUP_TYPE references with pid_t references
3030 throughout.
3031 (gdb_getpgrp): Delete.
3032 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
3033 (child_terminal_inferior): Remove comment. Remove sgtty code.
3034 (child_terminal_ours_1): Use tcgetpgrp directly instead of
3035 gdb_getpgrp. Use serial_set_tty_state instead aof
3036 serial_noflush_set_tty_state. Remove sgtty code.
3037 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
3038 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
3039 (inferior_process_group): Now returns pid_t.
3040 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
3041 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
3042 * ser-event.c (serial_event_ops): Update.
3043 * ser-go32.c (dos_noflush_set_tty_state): Delete.
3044 (dos_ops): Update.
3045 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
3046 * ser-pipe.c (pipe_ops): Update.
3047 * ser-tcp.c (tcp_ops): Update.
3048 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
3049 HAVE_TERMIOS checks.
3050 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
3051 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
3052 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
3053 assume termios.
3054 (hardwire_noflush_set_tty_state): Delete.
3055 (hardwire_print_tty_state, hardwire_drain_output)
3056 (hardwire_flush_output, hardwire_flush_input)
3057 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
3058 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
3059 code, and assume termios.
3060 (hardwire_ops): Update.
3061 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
3062 * serial.c (serial_noflush_set_tty_state): Delete.
3063 * serial.h (serial_noflush_set_tty_state): Delete.
3064 (serial_ops::noflush_set_tty_state): Delete.
3065
1cfb73db
UW
30662017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3067
3068 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
3069 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
3070 (COMMON_OBS): Remove doublest.o and dfp.o.
3071 Do not build target-float.c (instead of doublest.c)
3072 with -Wformat-nonliteral.
3073
3074 * doublest.c: Remove file.
3075 * doublest.h: Remove file.
3076 * dfp.c: Remove file.
3077 * dfp.h: Remove file.
3078
3079 * target-float.c: Do not include "doublest.h" and "dfp.h".
3080 (DOUBLEST): Move here from doublest.h.
3081 (enum float_kind): Likewise.
3082 (FLOATFORMAT_CHAR_BIT): Likewise.
3083 (FLOATFORMAT_LARGEST_BYTES): Likewise.
3084 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
3085 (floatformat_precision): Likewise.
3086 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
3087 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
3088 Likewise.
3089 (host_float_format, host_double_format, host_long_double_format):
3090 Likewise.
3091 (floatformat_to_string, floatformat_from_string): Likewise.
3092 (floatformat_to_doublest): Likewise. Also, inline the original
3093 convert_floatformat_to_doublest.
3094 (floatformat_from_doublest): Likewise. Also, inline the original
3095 convert_floatformat_from_doublest.
3096
3097 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
3098 (MAX_DECIMAL_STRING): Move here from dfp.c.
3099 (match_endianness): Likewise.
3100 (set_decnumber_context, decimal_check_errors): Likewise.
3101 (decimal_from_number, decimal_to_number): Likewise.
3102 (decimal_to_string, decimal_from_string): Likewise. Make static.
3103 (decimal_from_longest, decimal_from_ulongest): Likewise.
3104 (decimal_to_longest): Likewise.
3105 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
3106 (decimal_convert): Likewise.
3107
b07e9c46
UW
31082017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3109
3110 * doublest.c: Do not include "gdbtypes.h".
3111 (extract_typed_floating): Remove.
3112 (store_typed_floating): Remove.
3113 (convert_typed_floating): Remove.
3114 * doublest.h (struct type): Remove.
3115 (DOUBLEST_PRINT_FORMAT): Remove.
3116 (DOUBLEST_SCAN_FORMAT): Remove.
3117 (extract_typed_floating): Remove.
3118 (store_typed_floating): Remove.
3119 (convert_typed_floating): Remove.
3120
3121 * dfp.c (decimal_from_doublest): Remove.
3122 (decimal_to_doublest): Remove.
3123 * dfp.h: Do not include "doublest.h".
3124 (decimal_from_doublest): Remove.
3125 (decimal_to_doublest): Remove.
3126
3127 * value.c: Do not include "doublest.h" and "dfp.h".
3128 (value_as_double): Remove.
3129 (unpack_double): Remove.
3130 (value_from_double): Remove.
3131 (value_from_decfloat): Remove.
3132 * value.h: Do not include "doublest.h".
3133 (value_as_double): Remove.
3134 (unpack_double): Remove.
3135 (value_from_double): Remove.
3136 (value_from_decfloat): Remove.
3137
3b2ca824
UW
31382017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3139
3140 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
3141 (i386_extract_return_value): Use target_float_convert.
3142 (i386_store_return_value): Likewise.
3143 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
3144 (i387_value_to_register): Likewise.
3145 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
3146 (ia64_register_to_value): Use target_float_convert.
3147 (ia64_value_to_register): Likewise.
3148 (ia64_extract_return_value): Likewise.
3149 (ia64_store_return_value): Likewise.
3150 (ia64_push_dummy_call): Likewise.
3151 * m68k-tdep.c: Include "target-float.h".
3152 (m68k_register_to_value): Use target_float_convert.
3153 (m68k_value_to_register): Likewise.
3154 (m68k_svr4_extract_return_value): Likewise.
3155 (m68k_svr4_store_return_value): Likewise.
3156 * ppc-sysv-tdep.c: Include "target-float.h".
3157 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
3158 (do_ppc_sysv_return_value): Likewise.
3159 (ppc64_sysv_abi_push_freg): Likewise.
3160 (ppc64_sysv_abi_return_value_base): Likewise.
3161 * rs6000-aix-tdep.c: Include "target-float.h".
3162 (rs6000_push_dummy_call): Use target_float_convert.
3163 (rs6000_return_value): Likewise.
3164 * rs6000-lynx178-tdep.c: Include "target-float.h".
3165 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
3166 (rs6000_lynx178_return_value): Likewise.
3167 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
3168 (rs6000_register_to_value): Use target_float_convert.
3169 (rs6000_value_to_register): Likewise.
3170 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
3171 (arm_extract_return_value): Use target_float_convert.
3172 (arm_store_return_value): Likewise.
3173 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
3174 (sh_register_convert_to_virtual): Use target_float_convert.
3175 (sh_register_convert_to_raw): Likewise.
3176 * sh64-tdep.c: Include "target-float.h".
3177 (sh64_extract_return_value): Use target_float_convert.
3178 (sh64_register_convert_to_virtual): Likewise.
3179 (sh64_register_convert_to_raw): Likewise. Fix argument types.
3180
14ad9311
UW
31812017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3182
3183 * target-float.c (floatformat_to_host_double): New function.
3184 (floatformat_from_host_double): Likewise.
3185 (target_float_to_host_double): Likewise.
3186 (target_float_from_host_double): Likewise.
3187 * target-float.h (target_float_to_host_double): Add prototype.
3188 (target_float_from_host_double): Likewise.
3189
3190 * guile/scm-value.c: Include "target-float.h".
3191 (gdbscm_value_to_real): Use target_float_to_host_double.
3192 Handle integer source values via value_as_long.
3193 * guile/scm-math.c: Include "target-float.h". Do not include
3194 "doublest.h", "dfp.h", and "expression.h".
3195 (vlscm_convert_typed_number): Use target_float_from_host_double.
3196 (vlscm_convert_number): Likewise.
3197
3198 * python/py-value.c (valpy_float): Use target_float_to_host_double.
3199 (convert_value_from_python): Use target_float_from_host_double.
3200
50eff16b
UW
32012017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3202
3203 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
3204 (cast_from_fixed): Likewise.
3205 (ada_scaling_type): New function.
3206 (ada_delta): Return value instead of DOUBLEST. Perform target
3207 arithmetic instead of host arithmetic.
3208 (scaling_factor): Rename to ...
3209 (ada_scaling_factor) ... this. Make non-static. Return value instead
3210 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
3211 (ada_fixed_to_float): Remove.
3212 (ada_float_to_fixed): Remove.
3213 * ada-lang.h (ada_fixed_to_float): Remove.
3214 (ada_float_to_fixed): Remove.
3215 (ada_delta): Return value instead of DOUBLEST.
3216 (ada_scaling_factor): Add prototype.
3217
3218 * ada-typeprint.c: Include "target-float.h".
3219 (print_fixed_point_type): Perform target arithmetic instead of
3220 host arithmetic.
3221 * ada-valprint.c: Include "target-float.h".
3222 (ada_val_print_num): Perform target arithmetic instead of
3223 host arithmetic for fixed-point types.
3224
66c02b9e
UW
32252017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3226
3227 * target-float.c: Include <math.h>.
3228 (floatformat_binop): New function.
3229 (floatformat_compare): Likewise.
3230 (target_float_binop): Likewise.
3231 (target_float_compare): Likewise.
3232 * target-float.h: Include "expression.h".
3233 (target_float_binop): Add prototype.
3234 (target_float_compare): Likewise.
3235
3236 * valarith.c: Do not include "doublest.h" and "dfp.h".
3237 Include "common/byte-vector.h".
3238 (value_args_as_decimal): Remove, replace by ...
3239 (value_args_as_target_float): ... this function. Handle both
3240 binary and decimal target floating-point formats.
3241 (scalar_binop): Handle both binary and decimal FP using
3242 value_args_as_target_float and target_float_binop.
3243 (value_equal): Handle both binary and decimal FP using
3244 value_args_as_target_float and target_float_compare.
3245 (value_less): Likewise.
3246 (value_pos): Handle all scalar types as simple copy.
3247 (value_neg): Handle all scalar types via BINOP_SUB from 0.
3248 * dfp.c (decimal_binop): Throw error instead of internal_error
3249 when called with an unsupported operation code.
3250
f69fdf9b
UW
32512017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3252
3253 * target-float.c (target_float_to_string): New function.
3254 (target_float_from_string): New function.
3255 * target-float.h (target_float_to_string): Add prototype.
3256 (target_float_from_string): Add prototype.
3257
3258 * valprint.c: Include "target-float.h". Do not include
3259 "doublest.h" and "dfp.h".
3260 (print_floating): Use target_float_to_string.
3261 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
3262 (printf_floating): Use target_float_to_string.
3263 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
3264 (print_i387_value): Use target_float_to_string.
3265 * mips-tdep.c: Include "target-float.h".
3266 (mips_print_fp_register): Use target_float_to_string.
3267 * sh64-tdep.c: Include "target-float.h".
3268 (sh64_do_fp_register): Use target_float_to_string.
3269
3270 * parse.c: Include "target-float.h". Do not include
3271 "doublest.h" and "dfp.h".
3272 (parse_float): Use target_float_from_string.
3273 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
3274 (define_symbol): Use target_float_from_string.
3275 * gdbarch-selftests.c: Include "target-float.h".
3276 (register_to_value_test): Use target_float_from_string.
3277
70100014
UW
32782017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
3279
3280 * Makefile.c (SFILES): Add target-float.c.
3281 (HFILES_NO_SRCDIR): Add target-float.h.
3282 (COMMON_OBS): Add target-float.o.
3283 * target-float.h: New file.
3284 * target-float.c: New file.
3285
3286 * doublest.c (floatformat_classify): Fix detection of float_zero.
3287
3288 * gdbtypes.c (is_floating_type): New function.
3289 * gdbtypes.h (is_floating_type): Add prototype.
3290
3291 * value.c: Do not include "floatformat.h".
3292 (unpack_double): Use target_float_is_valid.
3293 (is_floating_value): New function.
3294 * value.h (is_floating_value): Add prototype-
3295
3296 * valarith.c: Include "target-float.h".
3297 (value_logical_not): Use target_float_is_zero.
3298
3299 * python/py-value.c: Include "target-float.h".
3300 (valpy_nonzero): Use target_float_is_zero.
3301
ab4b1c46
TT
33022017-11-04 Tom Tromey <tom@tromey.com>
3303
3304 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
3305
454dafbd
TT
33062017-11-04 Tom Tromey <tom@tromey.com>
3307
3308 * breakpoint.c (set_momentary_breakpoint): Return
3309 breakpoint_up.
3310 (until_break_command): Update.
3311 (new_until_break_fsm): Change argument types to
3312 breakpoint_up.
3313 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3314 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
3315 Remove.
3316 * infcmd.c (finish_forward): Update.
3317 * breakpoint.h (set_momentary_breakpoint)
3318 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
3319 (make_cleanup_delete_breakpoint): Remove.
3320 (struct breakpoint_deleter): New.
3321 (breakpoint_up): New typedef.
3322 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
3323 (insert_exception_resume_breakpoint): Update.
3324 (insert_exception_resume_from_probe): Update.
3325 (insert_longjmp_resume_breakpoint): Update.
3326 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
3327 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
3328 * infcall.c (call_function_by_hand_dummy): Update
3329
331b71e5
TT
33302017-11-04 Tom Tromey <tom@tromey.com>
3331
3332 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
3333
9f584b37
TT
33342017-11-04 Tom Tromey <tom@tromey.com>
3335
3336 * linux-tdep.c (linux_core_info_proc_mappings): Use
3337 gdb::def_vector.
3338 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
3339 "size" argument.
3340 (linux_corefile_thread): Update.
3341 (linux_make_corefile_notes): Remove unused variable.
3342
779bc38e
TT
33432017-11-04 Tom Tromey <tom@tromey.com>
3344
3345 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
3346 gdb::byte_vector.
3347
ed2b3126
TT
33482017-11-04 Tom Tromey <tom@tromey.com>
3349
3350 * objfiles.c (do_free_objfile_cleanup): Remove.
3351 * compile/compile-object-load.c (compile_object_load): Update.
3352 * objfiles.h (make_cleanup_free_objfile): Remove.
3353
7f6743fd
TT
33542017-11-04 Tom Tromey <tom@tromey.com>
3355
3356 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
3357 (adi_read_versions): Change "tags" to "gdb_byte *".
3358 (adi_print_versions): Likewise.
3359
c80049d3
TT
33602017-11-04 Tom Tromey <tom@tromey.com>
3361
3362 * breakpoint.c
3363 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
3364 from start_rbreak_breakpoints.
3365 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
3366 * breakpoint.h (class scoped_rbreak_breakpoints): New.
3367 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
3368 * symtab.c (do_end_rbreak_breakpoints): Remove.
3369 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
3370
167b0be1
TT
33712017-11-04 Tom Tromey <tom@tromey.com>
3372
3373 * cp-namespace.c (reset_directive_searched): Remove.
3374 (cp_lookup_symbol_via_imports): Use scoped_restore.
3375 * cp-support.c (reset_directive_searched): Remove.
3376 (make_symbol_overload_list_using): Use scoped_restore.
3377 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
3378 (reset_directive_searched): Remove.
3379
5eae7aea
TT
33802017-11-04 Tom Tromey <tom@tromey.com>
3381
3382 * symfile.c (find_separate_debug_file_by_debuglink): Use
3383 unique_xmalloc_ptr.
3384
c6bcad5f
TT
33852017-11-04 Tom Tromey <tom@tromey.com>
3386
3387 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
3388 type of "info".
3389 (compute_stack_depth): Likewise.
3390 (do_compile_dwarf_expr_to_c): Use std::vector.
3391
20dcd8ca
TT
33922017-11-04 Tom Tromey <tom@tromey.com>
3393
3394 * compile/compile-object-load.c (link_callbacks_einfo): Use
3395 std::string.
3396
33c7c59d
TT
33972017-11-04 Tom Tromey <tom@tromey.com>
3398
3399 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
3400 Use scoped_free_pendings.
3401 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
3402 scoped_free_pendings.
3403 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
3404 (xcoff_initial_scan): Likewise.
3405 * buildsym.c (reset_symtab_globals): Update comment.
3406 (scoped_free_pendings): Rename from really_free_pendings.
3407 (prepare_for_building): Update comment.
3408 (buildsym_init): Likewise.
3409 * buildsym.h (class scoped_free_pendings): New class.
3410 (really_free_pendings): Don't declare.
3411
67fa57cf
UW
34122017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
3413
3414 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
3415 output when converting a zero value to a special byteorder format.
3416
f26ae15b
YQ
34172017-11-02 Yao Qi <yao.qi@linaro.org>
3418
3419 * frame.c (do_frame_register_read): Remove aspace.
3420 * jit.c (jit_frame_sniffer): Likwise.
3421 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3422 * regcache.c (regcache::regcache): Pass nullptr.
3423 (regcache_print): Caller updated.
3424 * regcache.h (regcache::regcache): Remove one constructor
3425 parameter aspace.
3426
6c6e9412
YQ
34272017-11-02 Yao Qi <yao.qi@linaro.org>
3428
3429 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
3430
8b86c959
YQ
34312017-11-02 Yao Qi <yao.qi@linaro.org>
3432
3433 * breakpoint.c (insert_single_step_breakpoints): Update.
3434 * frame.c (struct frame_info) <aspace>: Add const.
3435 (frame_save_as_regcache): Add const.
3436 (get_frame_address_space): Return const address_space *.
3437 * frame.h (get_frame_address_space): Update declaration.
3438 * infrun.c (struct step_over_info) <aspace>: Add const.
3439 (set_step_over_info): Make aspace const.
3440 (displaced_step_prepare_throw): Change variable const.
3441 (resume): Likewise.
3442 (proceed): Likewise.
3443 (adjust_pc_after_break): Likewise.
3444 (save_waitstatus): Likewise.
3445 (handle_signal_stop): Likewise.
3446 (keep_going_pass_signal): Likewise.
3447 * jit.c (jit_frame_sniffer): Add const.
3448 * mips-tdep.c (mips_single_step_through_delay): Likewise.
3449 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3450 * record-full.c (record_full_wait_1): Likewise.
3451 * regcache.c (regcache::regcache): Change parameter to const.
3452 * regcache.h (regcache::regcache): Likewise.
3453 (regcache::aspace): Return const address_space *.
3454 (regcache) <m_aspace>: Add const.
3455
a01bda52
YQ
34562017-11-02 Yao Qi <yao.qi@linaro.org>
3457
3458 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
3459 * frame.c (create_sentinel_frame): Likewise.
3460 * infrun.c (displaced_step_prepare_throw): Likewise.
3461 (resume): Likewise.
3462 (thread_still_needs_step_over_bp): Likewise.
3463 (proceed): Likewise.
3464 (do_target_wait): Likewise.
3465 (adjust_pc_after_break): Likewise.
3466 (handle_syscall_event): Likewise.
3467 (save_waitstatus): Likewise.
3468 (handle_inferior_event_1): Likewise.
3469 (handle_signal_stop): Likewise.
3470 (keep_going_pass_signal): Likewise.
3471 * linux-nat.c (status_callback): Likewise.
3472 (save_stop_reason): Likewise.
3473 (resume_stopped_resumed_lwps): Likewise.
3474 * record-full.c (record_full_exec_insn): Likewise.
3475 (record_full_wait_1): Likewise.
3476 * regcache.c (get_regcache_aspace): Remove.
3477 * regcache.h (get_regcache_aspace): Remove.
3478
d999647b
YQ
34792017-11-02 Yao Qi <yao.qi@linaro.org>
3480
3481 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
3482 (init_regcache_descr): Use gdbarch_num_regs.
3483 (regcache::regcache): Likewise.
3484 (regcache::get_register_status): Likewise.
3485 (regcache::assert_raw_regnum): Likewise.
3486 (regcache::cooked_read): Likewise.
3487 (regcache::cooked_read_value): Likewise.
3488 (regcache::cooked_write): Likewise.
3489 (regcache::dump): Likewise.
3490 (regcache::num_raw_registers): New method.
3491 * regcache.h (class regcache) <num_raw_registers>: New.
3492
4e888c28
YQ
34932017-11-02 Yao Qi <yao.qi@linaro.org>
3494
3495 * regcache.c (regcache::assert_regnum): New method.
3496 (regcache::invalidate): Call assert_regnum.
3497 (regcache::raw_update): Likewise.
3498 (regcache::raw_write): Likewise.
3499 (regcache::raw_read_part): Likewise.
3500 (regcache::raw_write_part): Likewise.
3501 (regcache::raw_supply): Likewise.
3502 (regcache::raw_supply_integer): Likewise.
3503 (regcache::raw_supply_zeroed): Likewise.
3504 (regcache::raw_collect): Likewise.
3505 (regcache::raw_collect_integer): Likewise.
3506 * regcache.h (regcache::assert_regnum): Declare.
3507
2e1b49b3
YQ
35082017-11-02 Yao Qi <yao.qi@linaro.org>
3509
3510 * regcache.c (regcache::dump): Remove code.
3511
6c5218df
YQ
35122017-11-02 Yao Qi <yao.qi@linaro.org>
3513
3514 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
3515 Remove.
3516 <sizeof_cooked_register_status>: Remove.
3517 (init_regcache_descr): Update.
3518 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
3519 (regcache::save): Likewise.
3520 (regcache::dump): Likewise.
3521
dcc31d28
JB
35222017-11-01 James Bowman <james.bowman@ftdichip.com>
3523
3524 * ft32-tdep.c (ft32_fetch_instruction): New function.
3525 (ft32_analyze_prologue): Use ft32_fetch_instruction().
3526
3a87ae65
SM
35272017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
3528
3529 * cli/cli-script.c (execute_control_command): Rename to ...
3530 (execute_control_command_1): ... this.
3531 (execute_control_command): New function.
3532
09b847f3
SM
35332017-10-31 Simon Marchi <simon.marchi@ericsson.com>
3534
3535 * tracepoint.c (tfind_command): Remove const_cast.
3536
f871c485
MG
35372017-10-30 Mike Gulick <mgulick@mathworks.com>
3538
3539 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
3540
b020ff80
SM
35412017-10-30 Simon Marchi <simon.marchi@ericsson.com>
3542
3543 * common/common-utils.h (in_inclusive_range): New function.
3544 * arm-tdep.c (arm_record_extension_space): Use
3545 in_inclusive_range.
3546 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
3547 * cris-tdep.c (cris_spec_reg_applicable): Use
3548 in_inclusive_range.
3549
1b81856f
PA
35502017-10-30 Pedro Alves <palves@redhat.com>
3551 Simon Marchi <simon.marchi@ericsson.com>
3552
3553 * remote.c (remote_set_syscall_catchpoint): Build a std::string
3554 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
3555
31b833b3
PA
35562017-10-30 Pedro Alves <palves@redhat.com>
3557
3558 * common/common-utils.c (string_appendf, string_vappendf): New
3559 functions.
3560 * common/common-utils.h (string_appendf, string_vappendf): New
3561 declarations.
3562 * unittests/common-utils-selftests.c (string_appendf_func)
3563 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
3564 (string_vappendf_tests): New functions.
3565 (_initialize_common_utils_selftests): Register "string_appendf" and
3566 "string_vappendf tests".
3567
4a250334
PA
35682017-10-30 Pedro Alves <palves@redhat.com>
3569
3570 * unittests/common-utils-selftests.c (format_func): New typedef.
3571 (string_printf_tests, string_vprintf_tests): Tests factored out
3572 and merged to ...
3573 (test_format_func): ... this new function.
3574 (string_printf_tests, string_vprintf_tests): Reimplement on top of
3575 test_format_func.
3576
16c5c17e
SM
35772017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3578
3579 * darwin-nat.c: Remove include of gdb.h.
3580
7ca51576
SM
35812017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3582
3583 * xtensa-xtregs.c: Fix formatting issues.
3584
c1342859
SM
35852017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3586
3587 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
3588
484d8d36
MD
35892017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
3590
3591 PR python/21213
3592 * python/py-infthread.c (thpy_get_inferior): Increment reference
3593 of inferior before returning it.
3594
b5540b5f
SM
35952017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3596
3597 * unittests/common-utils-selftests.c (format): Add
3598 ATTRIBUTE_PRINTF.
3599
5a9dcda1
SM
36002017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3601
3602 * xml-syscall.c (struct syscall_desc): Add constructor.
3603 <name>: Change type to std::string.
3604 (syscall_desc_up): New typedef.
3605 (syscall_desc_p): Remove typeder.
3606 (DEF_VEC_P(syscall_desc_p)): Remove.
3607 (struct syscall_group_desc): Add constructor.
3608 <name>: Change type to std::string.
3609 <syscalls>: Change type to std::vector.
3610 (syscall_group_desc_up): New typedef.
3611 (syscall_group_desc_p): Remove typedef.
3612 (DEF_VEC_P(syscall_group_desc_p)): Remove.
3613 (struct syscalls_info) <syscalls>: Change type to std::vector of
3614 unique_ptr.
3615 <groups>: Likewise.
3616 <my_gdb_datadir>: Change type to std::string.
3617 (syscalls_info_up): New typedef.
3618 (allocate_syscalls_info): Remove.
3619 (syscalls_info_free_syscalls_desc): Remove.
3620 (syscalls_info_free_syscall_group_desc): Remove.
3621 (free_syscalls_info): Remove.
3622 (make_cleanup_free_syscalls_info): Remove.
3623 (syscall_group_create_syscall_group_desc): Adjust.
3624 (syscall_group_add_syscall): Adjust.
3625 (syscall_create_syscall_desc): Adjust.
3626 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
3627 (init_syscalls_info): Adjust.
3628 (syscall_group_get_group_by_name): Adjust.
3629 (xml_get_syscall_number): Adjust.
3630 (xml_get_syscall_name): Adjust.
3631 (xml_list_of_syscalls): Adjust.
3632 (xml_list_syscalls_by_group): Adjust.
3633 (xml_list_of_groups): Adjust.
3634
45461e0d
SM
36352017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3636
3637 * probe.h: Don't include gdb_vecs.h.
3638 (DEF_VEC_P (probe_p)): Remove.
3639 (find_probes_in_objfile): Return an std::vector.
3640 * probe.c (find_probes_in_objfile): Likewise.
3641 * breakpoint.c (breakpoint_objfile_data)
3642 <longjmp_probes>: Change type to std::vector.
3643 <exception_probes>: Likewise.
3644 (free_breakpoint_probes): Don't manually free vectors.
3645 (create_longjmp_master_breakpoint): Adjust.
3646 (create_exception_master_breakpoint): Adjust.
3647 * solib-svr4.c (svr4_create_probe_breakpoints): Change
3648 parameter type, adjust.
3649 (svr4_create_solib_event_breakpoints): Adjust.
3650
43dce439
SM
36512017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3652
3653 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
3654 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
3655 with new.
3656 (free_breakpoint_probes): Rename to ...
3657 (free_breakpoint_objfile_data): ... this, and call delete on
3658 bp_objfile_data..
3659
6a1b9516
SM
36602017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3661
3662 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
3663 (loaded_script_ptr): Remove typedef.
3664 (DEF_VEC_P (loaded_script_ptr)): Remove.
3665 (struct collect_matching_scripts_data): Add constructor.
3666 <scripts_p>: Change type to (pointer to) std::vector.
3667 (collect_matching_scripts_data): Adjust.
3668 (sort_scripts_by_name): Make suitable for std::sort.
3669 (print_scripts): Don't sort vector, adjust to std::vector.
3670 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
3671
593e3209
SM
36722017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3673
3674 * symfile.c (filename_language): Make struct, not typedef. Add
3675 constructor.
3676 <ext>: Change type to std::string.
3677 (DEF_VEC_O (filename_language)): Remove.
3678 (filename_language_table): Change type to std::vector.
3679 (add_filename_language): Adjust.
3680 (set_ext_lang_command): Adjust.
3681 (info_ext_lang_command): Adjust.
3682 (deduce_language_from_filename): Adjust.
3683 (class scoped_restore_filename_language_table): Remove.
3684 (test_filename_language): Use scoped_restore.
3685 (test_set_ext_lang_command): Use scoped_restore, adjust to
3686 std::vector change.
3687
32fa66eb
SM
36882017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3689
3690 * symfile.c: Include selftest.h.
3691 (class scoped_restore_filename_language_table): New.
3692 (test_filename_language): New test.
3693 (test_set_ext_lang_command): New test.
3694 (_initialize_symfile): Register tests.
3695
4a27f119
KS
36962017-10-27 Keith Seitz <keiths@redhat.com>
3697
3698 * breakpoint.c (print_breakpoint_location): Use the symbol saved
3699 in the bp_location, falling back to find_pc_sect_function when
3700 needed.
3701 (add_location_to_breakpoint): Save sal->symbol.
3702 * breakpoint.h (struct bp_location) <symbol>: New field.
3703 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
3704 * symtab.h (struct symtab_and_line) <symbol>: New field.
3705
a43f3893
PF
37062017-10-26 Patrick Frants <osscontribute@gmail.com>
3707
7453e6b2 3708 PR gdb/13669
a43f3893
PF
3709 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
3710 to rewind obstack.
3711
23cc4e1b
PA
37122017-10-26 Pedro Alves <palves@redhat.com>
3713
3714 * remote.c (remote_async_terminal_ours_p): Delete.
3715 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
3716 Remove references to 'remote_async_terminal_ours_p'.
3717
6abc18bb
YQ
37182017-10-26 Yao Qi <yao.qi@linaro.org>
3719
3720 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
3721
bd522513
YQ
37222017-10-26 Yao Qi <yao.qi@linaro.org>
3723
3724 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
3725 aspace const.
3726 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
3727 Likewise.
3728 * breakpoint.c (bpstat_check_location): Remove cast.
3729 (breakpoint_hit_catch_fork): Make aspce const.
3730 (breakpoint_hit_catch_solib): Likewise.
3731 (breakpoint_hit_catch_exec): Likewise.
3732 (breakpoint_hit_ranged_breakpoint): Likewise.
3733 (breakpoint_hit_watchpoint): Likewise.
3734 (base_breakpoint_breakpoint_hit): Likewise.
3735 (bkpt_breakpoint_hit): Likewise.
3736 (dprintf_breakpoint_hit): Likewise.
3737 (tracepoint_breakpoint_hit): Likewise.
3738 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
3739
accd0bcd
YQ
37402017-10-26 Yao Qi <yao.qi@linaro.org>
3741
3742 * breakpoint.c (breakpoint_location_address_match): Change
3743 "struct address_space *" to "const address_space".
3744 (breakpoint_location_address_range_overlap): Likewise.
3745 (breakpoint_here_p): Likewise.
3746 (breakpoint_in_range_p): Likewise.
3747 (moribund_breakpoint_here_p): Likewise.
3748 (bp_location_inserted_here_p): Likewise.
3749 (software_breakpoint_inserted_here_p): Likewise.
3750 (hardware_breakpoint_inserted_here_p): Likewise.
3751 (hardware_watchpoint_inserted_in_range): Likewise.
3752 (bpstat_check_location): Likewise.
3753 (bpstat_stop_status): Likewise.
3754 (breakpoint_address_match): Likewise.
3755 (breakpoint_address_match_range): Likewise.
3756 (breakpoint_location_address_match): Likewise.
3757 (breakpoint_location_address_range_overlap): Likewise.
3758 (insert_single_step_breakpoint): Likewise.
3759 (breakpoint_has_location_inserted_here): Likewise.
3760 (single_step_breakpoint_inserted_here_p): Likewise.
3761 (pc_at_non_inline_function): Likewise.
3762 * breakpoint.h (bpstat_stop_status): Update declaration.
3763 (breakpoint_here_p): Likewise.
3764 (breakpoint_in_range_p): Likewise.
3765 (moribund_breakpoint_here_p): Likewise.
3766 (breakpoint_inserted_here_p): Likewise.
3767 (software_breakpoint_inserted_here_p): Likewise.
3768 (hardware_breakpoint_inserted_here_p): Likewise.
3769 (breakpoint_has_location_inserted_here): Likewise.
3770 (single_step_breakpoint_inserted_here_p): Likewise.
3771 (hardware_watchpoint_inserted_in_range): Likewise.
3772 (breakpoint_address_match): Likewise.
3773 (insert_single_step_breakpoint): Likewise.
3774 (pc_at_non_inline_function): Likewise.
3775 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
3776 * record.c (record_check_stopped_by_breakpoint): Likewise.
3777 * record.h (record_check_stopped_by_breakpoint): Likewise.
3778 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
3779
ac7936df
YQ
37802017-10-25 Yao Qi <yao.qi@linaro.org>
3781
3782 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
3783 regcache->arch () instead get_regcache_arch.
3784 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
3785 Likewise.
3786 (aarch64_fbsd_store_inferior_registers): Likewise.
3787 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
3788 (store_gregs_to_thread): Likewise.
3789 (fetch_fpregs_from_thread): Likewise.
3790 (store_fpregs_to_thread): Likewise.
3791 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
3792 (aarch64_store_return_value): Likewise.
3793 (aarch64_software_single_step): Likewise.
3794 * aix-thread.c (aix_thread_wait): Likewise.
3795 (supply_reg32): Likewise.
3796 (supply_sprs64): Likewise.
3797 (supply_sprs32): Likewise.
3798 (fill_gprs64): Likewise.
3799 (fill_gprs32): Likewise.
3800 (fill_sprs64): Likewise.
3801 (fill_sprs32): Likewise.
3802 (store_regs_user_thread): Likewise.
3803 (store_regs_kernel_thread): Likewise.
3804 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
3805 (alphabsd_store_inferior_registers): Likewise.
3806 * alpha-tdep.c (alpha_extract_return_value): Likewise.
3807 (alpha_store_return_value): Likewise.
3808 (alpha_deal_with_atomic_sequence): Likewise.
3809 (alpha_next_pc): Likewise.
3810 (alpha_software_single_step): Likewise.
3811 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
3812 (amd64bsd_store_inferior_registers): Likewise.
3813 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
3814 Likewise.
3815 (amd64_linux_store_inferior_registers): Likewise.
3816 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
3817 (amd64_collect_native_gregset): Likewise.
3818 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
3819 (amd64obsd_collect_uthread): Likewise.
3820 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
3821 (amd64_collect_fpregset): Likewise.
3822 (amd64_supply_fxsave): Likewise.
3823 (amd64_supply_xsave): Likewise.
3824 (amd64_collect_fxsave): Likewise.
3825 (amd64_collect_xsave): Likewise.
3826 * arc-tdep.c (arc_write_pc): Likewise.
3827 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
3828 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
3829 (arm_fbsd_store_inferior_registers): Likewise.
3830 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
3831 (store_vfp_regs): Likewise.
3832 (arm_linux_fetch_inferior_registers): Likewise.
3833 (arm_linux_store_inferior_registers): Likewise.
3834 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
3835 (arm_linux_sigreturn_next_pc): Likewise.
3836 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
3837 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
3838 (fetch_register): Likewise.
3839 (store_register): Likewise.
3840 * arm-tdep.c (arm_is_thumb): Likewise.
3841 (displaced_in_arm_mode): Likewise.
3842 (bx_write_pc): Likewise.
3843 (arm_get_next_pcs_addr_bits_remove): Likewise.
3844 (arm_software_single_step): Likewise.
3845 (arm_extract_return_value): Likewise.
3846 (arm_store_return_value): Likewise.
3847 (arm_write_pc): Likewise.
3848 * bfin-tdep.c (bfin_extract_return_value): Likewise.
3849 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
3850 (bsd_uthread_store_registers): Likewise.
3851 * core-regset.c (fetch_core_registers): Likewise.
3852 * corelow.c (get_core_registers): Likewise.
3853 * cris-tdep.c (cris_store_return_value): Likewise.
3854 (cris_extract_return_value): Likewise.
3855 (find_step_target): Likewise.
3856 (find_step_target): Likewise.
3857 (cris_software_single_step): Likewise.
3858 * ctf.c (ctf_fetch_registers): Likewise.
3859 * darwin-nat.c (cancel_breakpoint): Likewise.
3860 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
3861 * frv-tdep.c (frv_extract_return_value): Likewise.
3862 * ft32-tdep.c (ft32_store_return_value): Likewise.
3863 (ft32_extract_return_value): Likewise.
3864 * go32-nat.c (fetch_register): Likewise.
3865 (go32_fetch_registers): Likewise.
3866 (go32_store_registers): Likewise.
3867 (store_register): Likewise.
3868 * h8300-tdep.c (h8300_extract_return_value): Likewise.
3869 (h8300_store_return_value): Likewise.
3870 * hppa-linux-nat.c (fetch_register): Likewise.
3871 (store_register): Likewise.
3872 (hppa_linux_fetch_inferior_registers): Likewise.
3873 (hppa_linux_store_inferior_registers): Likewise.
3874 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
3875 (i386_darwin_store_inferior_registers): Likewise.
3876 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
3877 (gnu_store_registers): Likewise.
3878 * i386-linux-nat.c (fetch_register): Likewise.
3879 (store_register): Likewise.
3880 (supply_gregset): Likewise.
3881 (fill_gregset): Likewise.
3882 (i386_linux_fetch_inferior_registers): Likewise.
3883 (i386_linux_store_inferior_registers): Likewise.
3884 (i386_linux_resume): Likewise.
3885 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
3886 Likewise.
3887 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
3888 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
3889 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
3890 (i386obsd_collect_uthread): Likewise.
3891 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3892 (i386_supply_gregset): Likewise.
3893 (i386_collect_gregset): Likewise.
3894 (i386_supply_fpregset): Likewise.
3895 (i386_collect_fpregset): Likewise.
3896 (i386_mpx_bd_base): Likewise.
3897 * i386-v4-nat.c (supply_fpregset): Likewise.
3898 (fill_fpregset): Likewise.
3899 * i387-tdep.c (i387_supply_fsave): Likewise.
3900 (i387_collect_fsave): Likewise.
3901 (i387_supply_fxsave): Likewise.
3902 (i387_collect_fxsave): Likewise.
3903 (i387_supply_xsave): Likewise.
3904 (i387_collect_xsave): Likewise.
3905 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
3906 (ia64_linux_store_registers): Likewise.
3907 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
3908 (ia64_extract_return_value): Likewise.
3909 (ia64_store_return_value): Likewise.
3910 (find_func_descr): Likewise.
3911 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
3912 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
3913 (inf_ptrace_store_registers): Likewise.
3914 * infrun.c (use_displaced_stepping): Likewise.
3915 (displaced_step_prepare_throw): Likewise.
3916 (resume): Likewise.
3917 (proceed): Likewise.
3918 (do_target_wait): Likewise.
3919 (adjust_pc_after_break): Likewise.
3920 (handle_inferior_event_1): Likewise.
3921 (handle_signal_stop): Likewise.
3922 (save_infcall_suspend_state): Likewise.
3923 (restore_infcall_suspend_state): Likewise.
3924 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
3925 * jit.c (jit_frame_prev_register): Likewise.
3926 * linux-nat.c (save_stop_reason): Likewise.
3927 (linux_nat_wait_1): Likewise.
3928 (resume_stopped_resumed_lwps): Likewise.
3929 * linux-record.c (record_linux_sockaddr): Likewise.
3930 (record_linux_msghdr): Likewise.
3931 (record_linux_system_call): Likewise.
3932 * linux-tdep.c (linux_collect_thread_registers): Likewise.
3933 * lm32-tdep.c (lm32_extract_return_value): Likewise.
3934 (lm32_store_return_value): Likewise.
3935 * m32c-tdep.c (m32c_read_flg): Likewise.
3936 (m32c_pseudo_register_read): Likewise.
3937 (m32c_pseudo_register_write): Likewise.
3938 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
3939 (m32r_linux_collect_gregset): Likewise.
3940 * m32r-tdep.c (m32r_store_return_value): Likewise.
3941 (m32r_extract_return_value): Likewise.
3942 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
3943 (m68kbsd_collect_fpregset): Likewise.
3944 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
3945 * m68k-linux-nat.c (fetch_register): Likewise.
3946 (old_fetch_inferior_registers): Likewise.
3947 (old_store_inferior_registers): Likewise.
3948 (store_regs): Likewise.
3949 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
3950 (m68k_svr4_store_return_value): Likewise.
3951 * m88k-tdep.c (m88k_store_arguments): Likewise.
3952 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
3953 (mi_cmd_data_write_register_values): Likewise.
3954 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
3955 (mips_fbsd_store_inferior_registers): Likewise.
3956 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
3957 (mips_fbsd_supply_gregs): Likewise.
3958 (mips_fbsd_collect_fpregs): Likewise.
3959 (mips_fbsd_collect_gregs): Likewise.
3960 (mips_fbsd_supply_fpregset): Likewise.
3961 (mips_fbsd_collect_fpregset): Likewise.
3962 (mips_fbsd_supply_gregset): Likewise.
3963 (mips_fbsd_collect_gregset): Likewise.
3964 * mips-linux-nat.c (supply_gregset): Likewise.
3965 (fill_gregset): Likewise.
3966 (supply_fpregset): Likewise.
3967 (fill_fpregset): Likewise.
3968 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
3969 (mips_fill_gregset): Likewise.
3970 (mips_supply_fpregset): Likewise.
3971 (mips_fill_fpregset): Likewise.
3972 (mips64_supply_gregset): Likewise.
3973 (micromips_linux_sigframe_validate): Likewise.
3974 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
3975 (mipsnbsd_fetch_inferior_registers): Likewise.
3976 (mipsnbsd_store_inferior_registers): Likewise.
3977 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
3978 (mipsnbsd_supply_gregset): Likewise.
3979 (mipsnbsd_iterate_over_regset_sections): Likewise.
3980 (mipsnbsd_supply_reg): Likewise.
3981 (mipsnbsd_supply_fpreg): Likewise.
3982 * mips-tdep.c (mips_in_frame_stub): Likewise.
3983 (mips_dummy_id): Likewise.
3984 (is_octeon_bbit_op): Likewise.
3985 (micromips_bc1_pc): Likewise.
3986 (extended_mips16_next_pc): Likewise.
3987 (mips16_next_pc): Likewise.
3988 (deal_with_atomic_sequence): Likewise.
3989 * moxie-tdep.c (moxie_process_readu): Likewise.
3990 * nios2-tdep.c (nios2_get_next_pc): Likewise.
3991 * nto-procfs.c (procfs_store_registers): Likewise.
3992 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
3993 (ppcfbsd_store_inferior_registers): Likewise.
3994 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
3995 (fetch_altivec_register): Likewise.
3996 (get_spe_registers): Likewise.
3997 (fetch_spe_register): Likewise.
3998 (fetch_altivec_registers): Likewise.
3999 (fetch_all_gp_regs): Likewise.
4000 (fetch_all_fp_regs): Likewise.
4001 (store_vsx_register): Likewise.
4002 (store_altivec_register): Likewise.
4003 (set_spe_registers): Likewise.
4004 (store_spe_register): Likewise.
4005 (store_altivec_registers): Likewise.
4006 (store_all_gp_regs): Likewise.
4007 (store_all_fp_regs): Likewise.
4008 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
4009 (ppc_linux_collect_gregset): Likewise.
4010 (ppc_canonicalize_syscall): Likewise.
4011 (ppc_linux_record_signal): Likewise.
4012 (ppu2spu_prev_register): Likewise.
4013 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
4014 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
4015 (ppcobsd_store_registers): Likewise.
4016 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
4017 Likewise.
4018 (ppc_ravenscar_generic_store_registers): Likewise.
4019 * procfs.c (procfs_fetch_registers): Likewise.
4020 (procfs_store_registers): Likewise.
4021 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
4022 (ravenscar_store_registers): Likewise.
4023 (ravenscar_prepare_to_store): Likewise.
4024 * record-btrace.c (record_btrace_fetch_registers): Likewise.
4025 * record-full.c (record_full_wait_1): Likewise.
4026 (record_full_registers_change): Likewise.
4027 (record_full_store_registers): Likewise.
4028 (record_full_core_fetch_registers): Likewise.
4029 (record_full_save): Likewise.
4030 (record_full_goto_insn): Likewise.
4031 * regcache.c (regcache_register_size): Likewise.
4032 (get_regcache_arch): Remove.
4033 (regcache_read_pc): Likewise.
4034 * regcache.h (get_regcache_arch): Remove.
4035 * remote-sim.c (gdbsim_fetch_register): Likewise.
4036 (gdbsim_store_register): Likewise.
4037 * remote.c (fetch_register_using_p): Likewise.
4038 (send_g_packet): Likewise.
4039 (remote_prepare_to_store): Likewise.
4040 (store_registers_using_G): Likewise.
4041 * reverse.c (save_bookmark_command): Likewise.
4042 (goto_bookmark_command): Likewise.
4043 * rs6000-aix-tdep.c (branch_dest): Likewise.
4044 * rs6000-nat.c (rs6000_ptrace64): Likewise.
4045 (fetch_register): Likewise.
4046 * rs6000-tdep.c (ppc_supply_reg): Likewise.
4047 (ppc_collect_reg): Likewise.
4048 (ppc_collect_gregset): Likewise.
4049 (ppc_collect_fpregset): Likewise.
4050 (ppc_collect_vsxregset): Likewise.
4051 (ppc_collect_vrregset): Likewise.
4052 (ppc_displaced_step_hw_singlestep): Likewise.
4053 (rs6000_pseudo_register_read): Likewise.
4054 (rs6000_pseudo_register_write): Likewise.
4055 * s390-linux-nat.c (supply_gregset): Likewise.
4056 (fill_gregset): Likewise.
4057 (s390_linux_fetch_inferior_registers): Likewise.
4058 * s390-linux-tdep.c (s390_write_pc): Likewise.
4059 (s390_software_single_step): Likewise.
4060 (s390_all_but_pc_registers_record): Likewise.
4061 (s390_linux_syscall_record): Likewise.
4062 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
4063 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
4064 (shnbsd_store_inferior_registers): Likewise.
4065 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
4066 (sh_extract_return_value_fpu): Likewise.
4067 (sh_store_return_value_nofpu): Likewise.
4068 (sh_corefile_supply_regset): Likewise.
4069 (sh_corefile_collect_regset): Likewise.
4070 * sh64-tdep.c (sh64_extract_return_value): Likewise.
4071 (sh64_store_return_value): Likewise.
4072 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
4073 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
4074 (sparc_store_inferior_registers): Likewise.
4075 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
4076 (sparc_ravenscar_prepare_to_store): Likewise.
4077 * sparc-tdep.c (sparc32_store_arguments): Likewise.
4078 (sparc_analyze_control_transfer): Likewise.
4079 (sparc_step_trap): Likewise.
4080 (sparc_software_single_step): Likewise.
4081 (sparc32_gdbarch_init): Likewise.
4082 (sparc_supply_rwindow): Likewise.
4083 (sparc_collect_rwindow): Likewise.
4084 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
4085 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
4086 (sparc64nbsd_collect_gregset): Likewise.
4087 (sparc64nbsd_supply_fpregset): Likewise.
4088 (sparc64nbsd_collect_fpregset): Likewise.
4089 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
4090 (sparc64_supply_gregset): Likewise.
4091 (sparc64_collect_gregset): Likewise.
4092 (sparc64_supply_fpregset): Likewise.
4093 (sparc64_collect_fpregset): Likewise.
4094 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
4095 * spu-tdep.c (spu_unwind_sp): Likewise.
4096 (spu2ppu_prev_register): Likewise.
4097 (spu_memory_remove_breakpoint): Likewise.
4098 * stack.c (return_command): Likewise.
4099 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
4100 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
4101 * tracefile.c (trace_save_ctf): Likewise.
4102 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
4103 (do_windows_store_inferior_registers): Likewise.
4104 (windows_resume): Likewise.
4105 * xtensa-linux-nat.c (fill_gregset): Likewise.
4106 (supply_gregset_reg): Likewise.
4107 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
4108 (xtensa_register_read_masked): Likewise.
4109 (xtensa_supply_gregset): Likewise.
4110 (xtensa_extract_return_value): Likewise.
4111 (xtensa_store_return_value): Likewise.
4112
edd079d9
UW
41132017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
4114
4115 * doublest.c (floatformat_from_string): New function.
4116 * doublest.h (floatformat_from_string): Add prototype.
4117
4118 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
4119 (OP_FLOAT): ... this.
4120 * expression.h: Do not include "doublest.h".
4121 (union exp_element): Replace doubleconst and decfloatconst by
4122 new element floatconst.
4123 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
4124 (ada_evaluate_subexp): Likewise.
4125 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
4126 OP_DOUBLE and OP_DECFLOAT.
4127 * expprint.c (print_subexp_standard): Likewise.
4128 (dump_subexp_body_standard): Likewise.
4129 * breakpoint.c (watchpoint_exp_is_const): Likewise.
4130
4131 * parse.c: Include "dfp.h".
4132 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4133 (write_exp_elt_floatcst): New function.
4134 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
4135 and OP_DECFLOAT.
4136 (operator_check_standard): Likewise.
4137 (parse_float): Do not accept suffix. Take type as input. Return bool.
4138 Return target format buffer instead of host DOUBLEST.
4139 Use floatformat_from_string and decimal_from_string to parse
4140 either binary or decimal floating-point types.
4141 (parse_c_float): Remove.
4142 * parser-defs.h: Do not include "doublest.h".
4143 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
4144 (write_exp_elt_floatcst): Add prototype.
4145 (parse_float): Update prototype.
4146 (parse_c_float): Remove.
4147
4148 * c-exp.y: Do not include "dfp.h".
4149 (typed_val_float): Use byte buffer instead of DOUBLEST.
4150 (typed_val_decfloat): Remove.
4151 (DECFLOAT): Remove.
4152 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4153 (parse_number): Update to new parse_float interface.
4154 Parse suffixes and determine type before calling parse_float.
4155 Handle decimal and binary FP types the same way.
4156
4157 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4158 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
4159 (parse_number): Update to new parse_float interface.
4160 Parse suffixes and determine type before calling parse_float.
4161
4162 * f-exp.y: Replace dval by typed_val_float.
4163 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4164 (parse_number): Use parse_float instead of atof.
4165
4166 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4167 (parse_go_float): Remove.
4168 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4169 (parse_number): Call parse_float instead of parse_go_float.
4170 Parse suffixes and determine type before calling parse_float.
4171
4172 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4173 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4174 (parse_number): Update to new parse_float interface.
4175 Parse suffixes and determine type before calling parse_float.
4176
4177 * m2-exp.y: Replace dval by byte buffer val.
4178 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4179 (parse_number): Call parse_float instead of atof.
4180
4181 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
4182 (lex_number): Call parse_float instead of strtod.
4183 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
4184 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
4185 Use write_exp_elt_floatcst.
4186 (unit_testing): Remove static variable.
4187 (rust_type): Do not check unit_testing.
4188 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
4189
4190 * ada-exp.y (type_float, type_double): Remove.
4191 (typed_val_float): Use byte buffer instead of DOUBLEST.
4192 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
4193 * ada-lex.l (processReal): Use parse_float instead of sscanf.
4194
cc628f3d
AH
41952017-10-25 Alan Hayward <alan.hayward@arm.com>
4196
4197 * aarch64-tdep.h (enum aarch64_regnum): Remove.
4198 * arch/aarch64.h: New file.
4199
09a7c6aa
UW
42002017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4201
4202 * dfp.h (decimal_from_string): Use const reference for argument.
4203 * dfp.c (decimal_from_string): Likewise.
4204
8ba0dd51
UW
42052017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4206
4207 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
4208 * sh64-tdep.c (sh64_do_fp_register): Likewise.
4209 * mips-tdep.c (mips_print_fp_register): Likewise.
4210
16e812b2
UW
42112017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4212
4213 * common/format.h (enum argclass): Replace decfloat_arg by
4214 dec32float_arg, dec64float_arg, and dec128float_arg.
4215 * common/format.c (parse_format_string): Update to return
4216 new decimal float argument classes.
4217
4218 * printcmd.c (printf_decfloat): Rename to ...
4219 (printf_floating): ... this. Add argclass argument, and use it
4220 instead of parsing the format string again. Add support for
4221 binary floating-point values, using floatformat_to_string.
4222 Convert value to the target format if it doesn't already match.
4223 (ui_printf): Call printf_floating instead of printf_decfloat,
4224 also for double_arg / long_double_arg. Pass argclass.
4225
4226 * dfp.c (decimal_to_string): Add format string argument.
4227 * dfp.h (decimal_to_string): Likewise.
4228
4229 * doublest.c (floatformat_to_string): Add format string argument.
4230 * doublest.h (floatformat_to_string): Likewise.
4231
fdf0cbc2
UW
42322017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4233
4234 * doublest.c (floatformat_precision): New routine.
4235 (floatformat_to_string): Likewise.
4236 * doublest.c (floatformat_to_string): Add prototype.
4237
4238 * printcmd.c (print_scalar_formatted): Only call print_floating
4239 on floating-point types.
4240 * valprint.c: Do not include "floatformat.h".
4241 (generic_val_print_decfloat): Remove.
4242 (generic_val_print): Call generic_val_print_float for both
4243 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
4244 (print_floating): Use floatformat_to_string. Handle decimal float.
4245 (print_decimal_floating): Remove, merge into floatformat_to_string.
4246 * value.h (print_decimal_floating): Remove.
4247
4248 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
4249
5033013f
UW
42502017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
4251
4252 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
4253
a664f67e
SM
42542017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4255
4256 * memattr.h: Don't include vec.h.
4257 (struct mem_attrib): Initialize fields.
4258 <unknown>: New static method.
4259 (struct mem_region): Add constructors, operator<, initialize
4260 fields.
4261 * memattr.c: Include algorithm.
4262 (default_mem_attrib, unknown_mem_attrib): Remove.
4263 (user_mem_region_list): New global.
4264 (target_mem_region_list, mem_region_list): Change type to
4265 std::vector<mem_region>.
4266 (mem_use_target): Now a function.
4267 (target_mem_regions_valid): Change type to bool.
4268 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
4269 (require_user_regions): Adjust.
4270 (require_target_regions): Adjust.
4271 (create_mem_region): Adjust.
4272 (lookup_mem_region): Adjust.
4273 (invalidate_target_mem_regions): Adjust.
4274 (mem_clear): Rename to...
4275 (user_mem_clear): ... this, and adjust.
4276 (mem_command): Adjust.
4277 (info_mem_command): Adjust.
4278 (mem_enable, enable_mem_command, mem_disable,
4279 disable_mem_command): Adjust.
4280 (mem_delete): Adjust.
4281 (delete_mem_command): Adjust.
4282 * memory-map.h (parse_memory_map): Return an std::vector.
4283 * memory-map.c (parse_memory_map): Likewise.
4284 (struct memory_map_parsing_data): Add constructor.
4285 <memory_map>: Point to std::vector.
4286 (memory_map_start_memory): Adjust.
4287 (memory_map_end_memory): Adjust.
4288 (memory_map_end_property): Adjust.
4289 (clear_result): Remove.
4290 * remote.c (remote_memory_map): Return an std::vector.
4291 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
4292 Remove.
4293 (target_debug_print_mem_region_vector): New.
4294 * target-delegates.c: Regenerate.
4295 * target.h (mem_region_vector): New typedef.
4296 (to_memory_map): Return mem_region_vector.
4297 (target_memory_map): Return an std::vector.
4298 * target.c (target_memory_map): Return an std::vector.
4299 (flash_erase_command): Adjust.
4300
6e17c565
SM
43012017-10-21 Simon Marchi <simon.marchi@ericsson.com>
4302
4303 * memory-map.c (struct memory_map_parsing_data) <property_name>:
4304 Change type to std::string.
4305 (memory_map_start_property): Adjust.
4306 (memory_map_end_property): Adjust.
4307
cfba9872
SM
43082017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4309
4310 * infrun.h: Include common/byte-vector.h.
4311 (struct displaced_step_closure): New struct.
4312 (struct buf_displaced_step_closure): New struct.
4313 * infrun.c (displaced_step_closure::~displaced_step_closure):
4314 Provide default implementation.
4315 (displaced_step_clear): Deallocate step closure with delete.
4316 * aarch64-tdep.c (displaced_step_closure): Rename to ...
4317 (aarch64_displaced_step_closure): ... this, extend
4318 displaced_step_closure.
4319 (aarch64_displaced_step_data) <dsc>: Change type to
4320 aarch64_displaced_step_closure.
4321 (aarch64_displaced_step_copy_insn): Adjust to type change, use
4322 unique_ptr.
4323 (aarch64_displaced_step_fixup): Add cast for displaced step
4324 closure.
4325 * amd64-tdep.c (displaced_step_closure): Rename to ...
4326 (amd64_displaced_step_closure): ... this, extend
4327 displaced_step_closure.
4328 <insn_buf>: Change type to std::vector<gdb_byte>.
4329 <max_len>: Remove.
4330 (fixup_riprel): Change type of DSC parameter, adjust to type
4331 change of insn_buf.
4332 (fixup_displaced_copy): Change type of DSC parameter.
4333 (amd64_displaced_step_copy_insn): Instantiate
4334 amd64_displaced_step_closure.
4335 (amd64_displaced_step_fixup): Add cast for closure type, adjust
4336 to type change of insn_buf.
4337 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
4338 parameter DSC.
4339 (arm_linux_copy_svc): Likewise.
4340 (cleanup_kernel_helper_return): Likewise.
4341 (arm_catch_kernel_helper_return): Likewise.
4342 (arm_linux_displaced_step_copy_insn): Instantiate
4343 arm_displaced_step_closure.
4344 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
4345 (displaced_read_reg): Change type of parameter DSC.
4346 (branch_write_pc): Likewise.
4347 (load_write_pc): Likewise.
4348 (alu_write_pc): Likewise.
4349 (displaced_write_reg): Likewise.
4350 (arm_copy_unmodified): Likewise.
4351 (thumb_copy_unmodified_32bit): Likewise.
4352 (thumb_copy_unmodified_16bit): Likewise.
4353 (cleanup_preload): Likewise.
4354 (install_preload): Likewise.
4355 (arm_copy_preload): Likewise.
4356 (thumb2_copy_preload): Likewise.
4357 (install_preload_reg): Likewise.
4358 (arm_copy_preload_reg): Likewise.
4359 (cleanup_copro_load_store): Likewise.
4360 (install_copro_load_store): Likewise.
4361 (arm_copy_copro_load_store) Likewise.
4362 (thumb2_copy_copro_load_store): Likewise.
4363 (cleanup_branch): Likewise.
4364 (install_b_bl_blx): Likewise.
4365 (arm_copy_b_bl_blx): Likewise.
4366 (thumb2_copy_b_bl_blx): Likewise.
4367 (thumb_copy_b): Likewise.
4368 (install_bx_blx_reg): Likewise.
4369 (arm_copy_bx_blx_reg): Likewise.
4370 (thumb_copy_bx_blx_reg): Likewise.
4371 (cleanup_alu_imm): Likewise.
4372 (arm_copy_alu_imm): Likewise.
4373 (thumb2_copy_alu_imm): Likewise.
4374 (cleanup_alu_reg): Likewise.
4375 (install_alu_reg): Likewise.
4376 (arm_copy_alu_reg): Likewise.
4377 (thumb_copy_alu_reg): Likewise.
4378 (cleanup_alu_shifted_reg): Likewise.
4379 (install_alu_shifted_reg): Likewise.
4380 (arm_copy_alu_shifted_reg): Likewise.
4381 (cleanup_load): Likewise.
4382 (cleanup_store): Likewise.
4383 (arm_copy_extra_ld_st): Likewise.
4384 (install_load_store): Likewise.
4385 (thumb2_copy_load_literal): Likewise.
4386 (thumb2_copy_load_reg_imm): Likewise.
4387 (arm_copy_ldr_str_ldrb_strb): Likewise.
4388 (cleanup_block_load_all): Likewise.
4389 (cleanup_block_store_pc): Likewise.
4390 (cleanup_block_load_pc): Likewise.
4391 (arm_copy_block_xfer): Likewise.
4392 (thumb2_copy_block_xfer): Likewise.
4393 (cleanup_svc): Likewise.
4394 (install_svc): Likewise.
4395 (arm_copy_svc): Likewise.
4396 (thumb_copy_svc): Likewise.
4397 (arm_copy_undef): Likewise.
4398 (thumb_32bit_copy_undef): Likewise.
4399 (arm_copy_unpred): Likewise.
4400 (arm_decode_misc_memhint_neon): Likewise.
4401 (arm_decode_unconditional): Likewise.
4402 (arm_decode_miscellaneous): Likewise.
4403 (arm_decode_dp_misc): Likewise.
4404 (arm_decode_ld_st_word_ubyte): Likewise.
4405 (arm_decode_media): Likewise.
4406 (arm_decode_b_bl_ldmstm): Likewise.
4407 (arm_decode_ext_reg_ld_st): Likewise.
4408 (thumb2_decode_dp_shift_reg): Likewise.
4409 (thumb2_decode_ext_reg_ld_st): Likewise.
4410 (arm_decode_svc_copro): Likewise.
4411 (thumb2_decode_svc_copro): Likewise.
4412 (install_pc_relative): Likewise.
4413 (thumb_copy_pc_relative_16bit): Likewise.
4414 (thumb_decode_pc_relative_16bit): Likewise.
4415 (thumb_copy_pc_relative_32bit): Likewise.
4416 (thumb_copy_16bit_ldr_literal): Likewise.
4417 (thumb_copy_cbnz_cbz): Likewise.
4418 (thumb2_copy_table_branch): Likewise.
4419 (cleanup_pop_pc_16bit_all): Likewise.
4420 (thumb_copy_pop_pc_16bit): Likewise.
4421 (thumb_process_displaced_16bit_insn): Likewise.
4422 (decode_thumb_32bit_ld_mem_hints): Likewise.
4423 (thumb_process_displaced_32bit_insn): Likewise.
4424 (thumb_process_displaced_insn): Likewise.
4425 (arm_process_displaced_insn): Likewise.
4426 (arm_displaced_init_closure): Likewise.
4427 (arm_displaced_step_fixup): Add cast for closure.
4428 * arm-tdep.h: Include infrun.h.
4429 (displaced_step_closure): Rename to ...
4430 (arm_displaced_step_closure): ... this, extend
4431 displaced_step_closure.
4432 <u::svc::copy_svc_os>: Change type of parameter DSC.
4433 <cleanup>: Likewise.
4434 (arm_process_displaced_insn): Likewise.
4435 (arm_displaced_init_closure): Likewise.
4436 (displaced_read_reg): Likewise.
4437 (displaced_write_reg): Likewise.
4438 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4439 Adjust.
4440 * i386-tdep.h: Include infrun.h.
4441 (i386_displaced_step_closure): New typedef.
4442 * i386-tdep.c (i386_displaced_step_copy_insn): Use
4443 i386_displaced_step_closure.
4444 (i386_displaced_step_fixup): Adjust.
4445 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
4446 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
4447 and unique_ptr.
4448 (ppc_displaced_step_fixup): Adjust.
4449 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
4450 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
4451 and unique_ptr.
4452 (s390_displaced_step_fixup): Adjust.
4453
b392b304
SM
44542017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4455
4456 * interps.h (interp_resume, interp_suspend, interp_set_temp):
4457 Remove declarations.
4458
d5833c62
TT
44592017-10-20 Tom Tromey <tom@tromey.com>
4460
4461 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
4462 std::vector.
4463 (gdb_bfd_record_inclusion): Update.
4464 (bfdp): Remove typedef.
4465
06d5bbc8
TT
44662017-10-20 Tom Tromey <tom@tromey.com>
4467
4468 * gdb_bfd.c (gdb_bfd_ref): Use new.
4469 (struct gdb_bfd_data): Add constructor, destructor, and member
4470 initializers.
4471 (gdb_bfd_unref): Use delete.
4472
2712ce2e
TT
44732017-10-20 Tom Tromey <tom@tromey.com>
4474
4475 * exec.c (exec_file_attach): Use new_bfd_ref.
4476 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
4477 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4478 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
4479 new_bfd_ref.
4480 * gdb_bfd.h (new_bfd_ref): New function.
4481
fcc8fb2f
PA
44822017-10-20 Pedro Alves <palves@redhat.com>
4483
4484 * main.c (captured_command_loop): Add attribute noinline.
4485
4c2287b0
SM
44862017-10-19 Simon Marchi <simon.marchi@ericsson.com>
4487
4488 * interps.c (struct interp_factory): Add constructor.
4489 (interp_factory_p): Remove typedef.
4490 (DEF_VEC_P(interp_factory_p)): Remove.
4491 (interpreter_factories): Change type to std::vector.
4492 (interp_factory_register): Adjust.
4493 (interp_lookup): Adjust.
4494 (interpreter_completer): Adjust.
4495
3d415c26
TT
44962017-10-19 Tom Tromey <tom@tromey.com>
4497
4498 * break-catch-syscall.c (catch_syscall_completer): Use
4499 std::string, gdb::unique_xmalloc_ptr.
4500
395423c4
TT
45012017-10-19 Tom Tromey <tom@tromey.com>
4502
4503 * infcall.c (call_function_by_hand_dummy): Use std::string.
4504
54f70bc1
TT
45052017-10-19 Tom Tromey <tom@tromey.com>
4506
4507 * mi/mi-main.c (mi_cmd_execute): Update.
4508 * top.h (prepare_execute_command): Return scoped_value_mark.
4509 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
4510 Add move constructor.
4511 * top.c (prepare_execute_command): Return scoped_value_mark.
4512 (execute_command): Update.
4513
63929e84
PA
45142017-10-19 Pedro Alves <palves@redhat.com>
4515
4516 * xml-support.c (xml_fetch_content_from_file): Check fread's
4517 return.
4518
a75868f5
PA
45192017-10-19 Pedro Alves <palves@redhat.com>
4520
4521 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
4522 async.
4523 (handle_error_fd): New function.
4524 (ser_base_async): Add/delete an event loop file handler for
4525 error_fd.
4526
2edf834e
PA
45272017-10-19 Pedro Alves <palves@redhat.com>
4528
4529 * xml-support.c (xml_fetch_content_from_file): Don't read in
4530 chunks. Instead use fseek to determine the file's size, and read
4531 it in one go.
4532
c8ba13ad
KS
45332017-11-18 Keith Seitz <keiths@redhat.com>
4534
4535 * c-exp.y (oper): Canonicalize conversion operators of user-defined
4536 types.
4537 Add whitespace to front of type name.
4538
37534686
KS
45392017-10-18 Keith Seitz <keiths@redhat.com>
4540
4541 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
4542 DW_AT_accessibility.
4543
28c7c158
YQ
45442017-10-18 Yao Qi <yao.qi@linaro.org>
4545
4546 * features/tic6x-c62x-linux.c: Remove.
4547
30f0b101
TT
45482017-10-17 Tom Tromey <tom@tromey.com>
4549
4550 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
4551 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
4552 (do_mixed_source_and_assembly): Likewise.
4553
57e12da9
TT
45542017-10-17 Tom Tromey <tom@tromey.com>
4555
4556 * regcache.c (regcache::xfer_part): Remove assertion.
4557
7b700999
PA
45582017-10-17 Pedro Alves <palves@redhat.com>
4559
4560 * xml-support.c (xml_fetch_content_from_file): Call
4561 unique_ptr::release() instead unique_ptr::get() when passing
4562 through xrealloc.
4563
d3037ba6
YQ
45642017-10-17 Yao Qi <yao.qi@linaro.org>
4565
4566 * regcache.c (regcache::xfer_part): Remove parameters read and
4567 write, add parameter is_raw. All callers are updated.
4568
83d5a34d
KS
45692017-10-16 Keith Seitz <keiths@redhat.com>
4570
4571 * c-typeprint.c (enum access_specifier): Moved here from
4572 c_type_print_base.
4573 (output_access_specifier): New function.
4574 (c_type_print_base): Consider typedefs when assessing
4575 whether access labels are needed.
4576 Use output_access_specifier as needed.
4577 Output access specifier for typedefs, if needed.
4578 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
4579 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
4580 fields.
4581 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
4582 accessor macros.
4583
87028b87
TT
45842017-10-16 Tom Tromey <tom@tromey.com>
4585
4586 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
4587 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
4588 * target.c (target_fileio_read_stralloc): Update.
4589 * sparc64-tdep.c (adi_is_addr_mapped): Update.
4590 * target.h (target_fileio_read_stralloc): Return
4591 unique_xmalloc_ptr.
4592
b7b030ad
TT
45932017-10-16 Tom Tromey <tom@tromey.com>
4594
4595 * xml-syscall.c (xml_init_syscalls_info): Update.
4596 * xml-support.c (xinclude_start_include): Update.
4597 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
4598 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
4599 (xml_fetch_content_from_file): Likewise.
4600 * osdata.c (get_osdata): Update.
4601 * target.h (target_read_stralloc, target_get_osdata): Return
4602 unique_xmalloc_ptr.
4603 * solib-aix.c (solib_aix_get_library_list): Update.
4604 * solib-target.c (solib_target_current_sos): Update.
4605 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
4606 * xml-tdesc.c (fetch_available_features_from_target): Update.
4607 (target_fetch_description_xml): Update.
4608 (file_read_description_xml): Update.
4609 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
4610 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
4611 (remote_pid_to_exec_file): Update.
4612 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
4613 (target_get_osdata): Likewise.
4614
b80406ac
TT
46152017-10-16 Tom Tromey <tom@tromey.com>
4616
4617 * remote.c (remote_register_number_and_offset): Use std::vector.
4618 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
4619 (putpkt_binary): Use gdb::def_vector.
4620 (compare_sections_command): Use gdb::byte_vector.
4621
a90ecff8
TT
46222017-10-16 Tom Tromey <tom@tromey.com>
4623
4624 * ppc-linux-nat.c (hwdebug_insert_point): Use
4625 gdb::unique_xmalloc_ptr, XDUP.
4626
2dc0e219
TT
46272017-10-16 Tom Tromey <tom@tromey.com>
4628
4629 * probe.c (parse_probes): Use std::string.
4630 (info_probes_for_ops, enable_probes_command)
4631 (disable_probes_command): Remove cleanups.
4632
b05628f0
TT
46332017-10-16 Tom Tromey <tom@tromey.com>
4634
4635 * buildsym.c (block_compar): Remove.
4636 (end_symtab_get_static_block): Use std::vector.
4637
a79b1bc6
SM
46382017-10-16 Simon Marchi <simon.marchi@ericsson.com>
4639
4640 * memrange.h (struct mem_range): Define operator< and operator==.
4641 (mem_range_s): Remove.
4642 (DEF_VEC_O (mem_range_s)): Remove.
4643 (normalize_mem_ranges): Change parameter type to std::vector.
4644 * memrange.c (compare_mem_ranges): Remove.
4645 (normalize_mem_ranges): Change parameter type to std::vector,
4646 adjust to vector change.
4647 * exec.c (section_table_available_memory): Return vector, remove
4648 parameter.
4649 (section_table_read_available_memory): Adjust to std::vector
4650 change.
4651 * remote.c (remote_read_bytes): Adjust to std::vector
4652 change.
4653 * tracepoint.h (traceframe_available_memory): Change parameter
4654 type to std::vector.
4655 * tracepoint.c (traceframe_available_memory): Change parameter
4656 type to std::vector, adjust.
4657 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
4658 std::vector change.
4659 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4660 unittests/memrange-selftests.c.
4661 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
4662 * gdb/unittests/memrange-selftests.c: New file.
4663
63f0e930
PA
46642017-10-16 Pedro Alves <palves@redhat.com>
4665
4666 * elfread.c (probe_key_free): Rename range-for variable.
4667 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
4668 (find_probe_by_pc, collect_probes): Rename range-for variable.
4669
c40c7bfc
YQ
46702017-10-16 Yao Qi <yao.qi@linaro.org>
4671
4672 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
4673 * features/tic6x-c62x.c: Remove.
4674 * features/tic6x-c64x-linux.c: Remove.
4675 * features/tic6x-c64x.c: Remove.
4676 * features/tic6x-c64xp-linux.c: Remove.
4677 * features/tic6x-c64xp.c: Remove.
4678 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
4679 initialize_tdesc_tic6x_*_linux functions.
4680 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
4681 initialize_tdesc_tic6x_* functions.
4682
df27ae6a
YQ
46832017-10-16 Yao Qi <yao.qi@linaro.org>
4684
4685 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
4686 tic6x-c62x.
4687 * regformats/tic6x-c62x.dat: Remove.
4688 * regformats/tic6x-c64x.dat: Remove.
4689 * regformats/tic6x-c64xp.dat: Remove.
4690
86766165
SM
46912017-10-15 Simon Marchi <simon.marchi@ericsson.com>
4692
4693 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
4694 (the !HAVE_LIBEXPAT version).
4695
824dfcc3
SM
46962017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4697
4698 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
4699 const.
4700
2098b393
SM
47012017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4702
4703 * target.h: Include tracepoint.h.
4704 (enum trace_find_type): Move to tracepoint.h.
4705 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
4706 * tracepoint.h: Don't include target.h
4707 (enum trace_find_type): Move from target.h.
4708 (parse_traceframe_info): Return a unique ptr.
4709 * tracepoint.c (current_traceframe_info): Change type to unique
4710 ptr.
4711 (free_traceframe_info): Remove.
4712 (clear_traceframe_info): Don't manually free
4713 current_traceframe_info.
4714 (free_result): Remove.
4715 (parse_traceframe_info): Return a unique ptr.
4716 (get_traceframe_info): Adjust to unique ptr.
4717 * ctf.c (ctf_traceframe_info): Return a unique ptr.
4718 * remote.c (remote_traceframe_info): Return a unique ptr.
4719 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
4720 ptr.
4721 * target-debug.h (target_debug_print_traceframe_info_up): New
4722 macro.
4723 * target-delegates.c: Regenerate.
4724
4cdd21a8
SM
47252017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4726
4727 * memrange.h (struct mem_range): Add constructors.
4728 * tracepoint.h (struct traceframe_info) <memory>: Change type to
4729 std::vector<mem_range>.
4730 * tracepoint.c (free_traceframe_info): Don't manually free
4731 vector.
4732 (traceframe_info_start_memory): Adjust to vector change.
4733 (traceframe_available_memory): Likewise.
4734 * tracefile-tfile.c (build_traceframe_info): Likewise.
4735 * ctf.c (ctf_traceframe_info): Likewise.
4736
d0d292a2
SM
47372017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4738
4739 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
4740 std::vector<int>.
4741 * tracepoint.c (free_traceframe_info): Deallocate with delete.
4742 (traceframe_info_start_tvar): Adjust to vector change.
4743 (parse_traceframe_info): Allocate with new.
4744 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
4745 vector change.
4746 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
4747 change.
4748 tfile_traceframe_info): Allocate with new.
4749 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
4750 change.
4751
8d3c73ef
SM
47522017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4753
4754 * tracepoint.c (traceframe_info): Rename to...
4755 (current_traceframe_info): ...this.
4756 (clear_traceframe_info): Adjust.
4757 (get_traceframe_info): Adjust.
4758
b129dcac
SM
47592017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4760
4761 * nat/linux-osdata.c: Include algorithm.
4762 (compare_processes): Remove.
4763 (struct pid_pgid_entry): New struct.
4764 (linux_xfer_osdata_processgroups): Use std::vector instead of
4765 XNEWVEC.
4766
af5bf4ad
SM
47672017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4768
4769 * objfiles.h: Don't include symfile.h.
4770 (struct partial_symbol): Remove forward-declaration.
4771 (struct objfile) <global_psymbols, static_psymbols>: Change type
4772 to std::vector<partial_symbol *>.
4773 * objfiles.c (objfile::objfile): Don't memset those fields.
4774 (objfile::~objfile): Don't free those fields.
4775 * psympriv.h (struct psymbol_allocation_list): Remove
4776 forward-declaration.
4777 (add_psymbol_to_list): Change psymbol_allocation_list parameter
4778 to std::vector.
4779 (start_psymtab_common): Change parameters to std::vector.
4780 * psymtab.c: Include algorithm.
4781 (require_partial_symbols): Call shrink_to_fit.
4782 (find_pc_sect_psymbol): Adjust to vector change.
4783 (match_partial_symbol): Likewise.
4784 (lookup_partial_symbol): Likewise.
4785 (psym_relocate): Likewise.
4786 (dump_psymtab): Likewise.
4787 (recursively_search_psymtabs): Likewise.
4788 (compare_psymbols): Remove.
4789 (sort_pst_symbols): Adjust to vector change.
4790 (start_psymtab_common): Likewise.
4791 (end_psymtab_common): Likewise.
4792 (psymbol_bcache_full): De-constify return value.
4793 (add_psymbol_to_bcache): Likewise.
4794 (extend_psymbol_list): Remove.
4795 (append_psymbol_to_list): Adjust to vector change.
4796 (add_psymbol_to_list): Likewise.
4797 (init_psymbol_list): Likewise.
4798 (maintenance_info_psymtabs): Likewise.
4799 (maintenance_check_psymtabs): Likewise.
4800 * symfile.h (struct psymbol_allocation_list): Remove.
4801 * symfile.c (reread_symbols): Adjust to vector change.
4802 * dbxread.c (start_psymtab): Change type of parameters.
4803 (dbx_symfile_read): Adjust to vector change.
4804 (read_dbx_symtab): Likewise.
4805 (start_psymtab): Change type of parameters.
4806 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
4807 (create_partial_symtab): Likewise.
4808 (add_partial_symbol): Likewise.
4809 (write_one_signatured_type): Likewise.
4810 (recursively_write_psymbols): Likewise.
4811 * mdebugread.c (parse_partial_symbols): Likewise.
4812 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
4813 (scan_xcoff_symtab): Adjust to vector change.
4814 (xcoff_initial_scan): Likewise.
4815
3ec5942f
SM
48162017-10-13 Simon Marchi <simon.marchi@ericsson.com>
4817
4818 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
4819
2399fe6a
YQ
48202017-10-13 Yao Qi <yao.qi@linaro.org>
4821
4822 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
4823 Remove s390x-*-expedite, add s390x-expedite.
4824
4bf3f4a8
YQ
48252017-10-13 Yao Qi <yao.qi@linaro.org>
4826
4827 * features/s390-gs-linux64.c: Regenerated.
4828 * features/s390x-gs-linux64.c: Regenerated.
4829
9e86da07
TT
48302017-10-13 Tom Tromey <tom@tromey.com>
4831
4832 * compile/compile-object-run.c (do_module_cleanup): Use delete.
4833 * solib.c (update_solib_list, reload_shared_libraries_1): Use
4834 delete.
4835 * symfile.c (symbol_file_add_with_addrs): Use new.
4836 (symbol_file_add_separate): Update comment.
4837 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
4838 * jit.c (jit_object_close_impl): Use new.
4839 (jit_unregister_code): Use delete.
4840 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
4841 (~objfile): Rename from free_objfile.
4842 (free_objfile_separate_debug, do_free_objfile_cleanup)
4843 (free_all_objfiles, objfile_purge_solibs): Use delete.
4844 * objfiles.h (struct objfile): Add constructor and destructor.
4845 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
4846 (allocate_objfile, free_objfile): Don't declare.
4847 (struct objstats): Add initializers.
4848
c2508e90
SM
48492017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4850
4851 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
4852 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
4853 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
4854 * gdbarch.h: Regenerate.
4855 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4856 Adjust comment.
4857 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
4858 (i386_displaced_step_fixup): Adjust comment.
4859 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
4860
a900ff72
TT
48612017-10-12 Tom Tromey <tom@tromey.com>
4862
4863 * prologue-value.h (pv_area::store_would_trash): Return bool.
4864 (pv_area::find_reg): Likewise.
4865 * prologue-value.c (pv_area::store_would_trash): Return bool.
4866 (pv_area::find_reg): Likewise.
4867
f7b7ed97
TT
48682017-10-12 Tom Tromey <tom@tromey.com>
4869
4870 * s390-linux-tdep.c (s390_store, s390_load)
4871 (s390_check_for_saved, s390_analyze_prologue): Update.
4872 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
4873 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
4874 * prologue-value.h (class pv_area): Move from prologue-value.c.
4875 Change names of members. Add constructor, destructor, member
4876 functions.
4877 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
4878 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
4879 (pv_area_fetch, pv_area_scan): Don't declare.
4880 * prologue-value.c (struct pv_area::area_entry): Now member of
4881 pv_area.
4882 (struct pv_area): Move to prologue-value.h.
4883 (pv_area::pv_area): Rename from make_pv_area.
4884 (pv_area::~pv_area): Rename from free_pv_area.
4885 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
4886 (clear_entries, find_entry, overlaps, store_would_trash, store)
4887 (fetch, find_reg, scan): Now member of pv_area.
4888 Remove "area" argument. Update.
4889 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
4890 Update.
4891 * mn10300-tdep.c (push_reg, check_for_saved)
4892 (mn10300_analyze_prologue): Update.
4893 * mep-tdep.c (is_arg_spill, check_for_saved)
4894 (mep_analyze_prologue): Update.
4895 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
4896 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
4897 (m32c_is_struct_return, m32c_analyze_prologue): Update.
4898 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
4899 Update.
4900 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
4901 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
4902
466eecee
SM
49032017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4904
4905 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
4906 * linux-nat.c (linux_nat_delete_thread): New variable.
4907 (lwp_free): Invoke linux_nat_delete_thread if set.
4908 (linux_nat_set_delete_thread): New function.
4909 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
4910 thread delete callback.
4911 * arm-linux-nat.c (arm_linux_delete_thread): New function.
4912 (_initialize_arm_linux_nat): Assign thread delete callback.
4913 * s390-linux-nat.c (s390_delete_thread): New function.
4914 (_initialize_s390_nat): Assign thread delete callback.
4915 * x86-linux-nat.c (x86_linux_add_target): Likewise.
4916 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
4917 function.
4918 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
4919 declaration.
4920 * nat/x86-linux.c (x86_linux_delete_thread): New function.
4921 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
4922
f71c8822
TT
49232017-10-09 Tom Tromey <tom@tromey.com>
4924
4925 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
4926 std::string.
4927 * tui/tui-layout.c (enum tui_status): Use std::string.
4928
981a3fb3
TT
49292017-10-11 Tom Tromey <tom@tromey.com>
4930
4931 * gdbthread.h (thread_command): Constify.
4932 * inferior.h (detach_command): Constify.
4933 * top.h (set_history, show_history): Constify.
4934 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
4935 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
4936 * bsd-kvm.c (bsd_kvm_cmd): Constify.
4937 * printcmd.c (set_command): Constify.
4938 (non_const_set_command): New function.
4939 * dcache.c (set_dcache_command, show_dcache_command): Constify.
4940 * breakpoint.c (enable_command, disable_command, delete_command)
4941 (catch_command, tcatch_command, set_breakpoint_cmd)
4942 (show_breakpoint_cmd): Constify.
4943 * macrocmd.c (macro_command): Constify.
4944 * infcmd.c (unset_command, kill_command, detach_command)
4945 (info_proc_cmd): Constify.
4946 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
4947 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
4948 (info_auto_load_cmd): Constify.
4949 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4950 (unset_tdesc_cmd): Constify.
4951 * ada-lang.c (set_ada_command, show_ada_command)
4952 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
4953 * guile/guile.c (set_guile_command, show_guile_command)
4954 (info_guile_command): Constify.
4955 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
4956 Constify.
4957 * skip.c (skip_command): Constify.
4958 * compile/compile.c (_initialize_compile): Constify.
4959 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
4960 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4961 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4962 (maint_btrace_pt_show_cmd): Constify.
4963 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
4964 Constify.
4965 * python/python.c (user_show_python, user_set_python): Constify.
4966 * mips-tdep.c (set_mips_command, show_mips_command)
4967 (set_mipsfpu_command): Constify.
4968 * record-btrace.c (cmd_record_btrace_start)
4969 (cmd_set_record_btrace, cmd_show_record_btrace)
4970 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
4971 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
4972 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
4973 Constify.
4974 * symfile.c (overlay_command): Constify.
4975 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
4976 * cli/cli-logging.c (set_logging_command, show_logging_command):
4977 Constify.
4978 * cli/cli-dump.c (dump_command, append_command)
4979 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4980 (tekhex_dump_command, binary_dump_command)
4981 (binary_append_command): Constify.
4982 * cli/cli-decode.c (struct cmd_list_element): Change type of
4983 "fun".
4984 * cli/cli-cmds.c (info_command, show_command, set_debug)
4985 (show_debug): Constify.
4986 (show_command): Add non-const overload.
4987 * top.c (set_history, show_history): Constify.
4988 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
4989 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
4990 * target.c (target_command): Constify.
4991 * sparc64-tdep.c (info_adi_command): Constify.
4992 * record-full.c (cmd_record_full_start): Constify.
4993 (set_record_full_command): Constify. Fix typo.
4994 (show_record_full_command): Constify.
4995 * thread.c (thread_command, thread_apply_command): Constify.
4996 * memattr.c (dummy_cmd): Constify.
4997 * value.c (function_command): Constify.
4998 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
4999 * probe.c (info_probes_command): Constify.
5000 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
5001 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
5002 (show_thread_cmd, set_thread_default_cmd)
5003 (show_thread_default_cmd): Constify.
5004 (check_empty): Constify.
5005 * tracepoint.c (tfind_command): Constify.
5006 * cp-support.c (maint_cplus_command): Constify.
5007 * windows-tdep.c (info_w32_command): Constify.
5008 * record.c (cmd_record_start, set_record_command)
5009 (show_record_command, info_record_command, cmd_record_goto):
5010 Constify.
5011 * ravenscar-thread.c (set_ravenscar_command)
5012 (show_ravenscar_command): Constify.
5013 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
5014 Constify.
5015 (add_internal_problem_command): Remove casts.
5016 * arc-tdep.c (maintenance_print_arc_command): Constify.
5017 * valprint.c (set_print, show_print, set_print_raw)
5018 (show_print_raw): Constify.
5019 * maint.c (maintenance_command, maintenance_info_command)
5020 (maintenance_print_command, maintenance_set_cmd)
5021 (maintenance_show_cmd, set_per_command_cmd)
5022 (show_per_command_cmd, maintenance_check_command): Constify.
5023 * language.c (set_check, show_check): Constify.
5024 * typeprint.c (show_print_type, set_print_type): Constify.
5025 * go32-nat.c (go32_info_dos_command): Constify.
5026
fdf44873
TT
50272017-10-11 Tom Tromey <tom@tromey.com>
5028
5029 * breakpoint.c (prepare_re_set_context): Remove.
5030 (breakpoint_re_set_one): Update. Don't use cleanups.
5031 (breakpoint_re_set): Use scoped_restore, std::string, and
5032 scoped_restore_current_language.
5033
81b1e71c
TT
50342017-10-11 Tom Tromey <tom@tromey.com>
5035
5036 * breakpoint.c (commands_command_1): Use std::string.
5037 (cleanup_executing_breakpoints): Remove.
5038 (bpstat_do_actions_1): Use scoped_restore.
5039 (bpstat_check_watchpoint): Use std::string.
5040 (decode_static_tracepoint_spec): Likewise.
5041 (break_range_command): Likewise.
5042 (watch_command_1): Likewise.
5043 (compare_breakpoints): Change argument types.
5044 (clear_command): Use std::vector.
5045 (cleanup_executing_breakpoints): Remove.
5046 (update_global_location_list): Use unique_xmalloc_ptr.
5047 (strace_command): Remove unused declaration.
5048
4f9d9906
JB
50492017-10-11 John Baldwin <jhb@FreeBSD.org>
5050
5051 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
5052 * NEWS: Mention new FreeBSD/arm native configuration.
5053 * configure.host: Add arm*-*-freebsd*.
5054 * configure.nat: Likewise.
5055 * arm-fbsd-nat.c: New file.
5056
7176dfd2
JB
50572017-10-11 John Baldwin <jhb@FreeBSD.org>
5058
5059 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
5060 (ALLDEPFILES): Add arm-fbsd-tdep.c.
5061 * NEWS: Mention new FreeBSD/arm target.
5062 * configure.tgt: Add arm*-*-freebsd*.
5063 * arm-fbsd-tdep.c: New file.
5064 * arm-fbsd-tdep.h: New file.
5065
fe220226
MR
50662017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5067
5068 * linux-tdep.c (linux_make_corefile_notes): Remove call to
5069 `gdbarch_elfcore_write_linux_prpsinfo'.
5070 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
5071 method.
5072 (elf_internal_linux_prpsinfo): Remove declaration.
5073 * gdbarch.h: Regenerate.
5074 * gdbarch.c: Regenerate.
5075
a2f63b2e
MR
50762017-10-11 Maciej W. Rozycki <macro@imgtec.com>
5077
5078 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
5079 `set_gdbarch_elfcore_write_linux_prpsinfo'.
5080
458ca1d0
PA
50812017-10-11 Pedro Alves <palves@redhat.com>
5082
5083 * breakpoint.c (reattach_breakpoints): Delete.
5084 * breakpoint.h (reattach_breakpoints): Delete.
5085
905014d7
SM
50862017-10-11 Simon Marchi <simon.marchi@ericsson.com>
5087
5088 * symfile.c (registered_sym_fns): Make struct, not typedef.
5089 (DEF_VEC_O (registered_sym_fns)): Remove.
5090 (symtab_fns): Change type to std::vector.
5091 (add_symtab_fns): Adjust.
5092 (find_sym_fns): Adjust.
5093
56d704da
AK
50942017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
5095
5096 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
5097 * arc-tdep.h (arc_arch_is_em): New function.
5098 (arc_arch_is_hs): Likewise.
5099
7fa29be9
EB
51002017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
5101
5102 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
5103 parentheses in the declaration.
5104 (macro_lookup_inclusion): Likewise.
5105 (macro_lookup_definition): Likewise.
5106 * p-lang.h (pascal_builtin_types): Likewise.
5107 * tui/tui-data.c (tui_win_list): Likewise.
5108 * tui/tui-data.h (tui_win_list): Likewise.
5109 * utils.h (make_cleanup_free_section_addr_info): Likewise.
5110
d9b477e3
KB
51112017-10-11 Mark Rages <markrages@gmail.com>
5112
5113 * target-memory.c (block_boundaries): Fix for block address not
5114 aligned on block size.
5115
65630365
PA
51162017-10-10 Pedro Alves <palves@redhat.com>
5117 Tom Tromey <tom@tromey.com>
5118
5119 * breakpoint.c (struct captured_breakpoint_query_args)
5120 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
5121 (print_breakpoint): New.
5122 * breakpoint.h (print_breakpoint): Declare.
5123 * common/common-exceptions.h (enum return_reason): Remove
5124 references to catch_exceptions.
5125 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
5126 Delete.
5127 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
5128 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
5129 * gdb.h: Delete.
5130 * gdbthread.h (thread_select): Declare.
5131 * mi/mi-cmd-break.c: Don't include gdb.h.
5132 (breakpoint_notify): Use print_breakpoint.
5133 * mi/mi-cmd-catch.c: Don't include gdb.h.
5134 * mi/mi-interp.c: Don't include gdb.h.
5135 (mi_print_breakpoint_for_event): New.
5136 (mi_breakpoint_created, mi_breakpoint_modified): Use
5137 mi_print_breakpoint_for_event.
5138 * mi/mi-main.c: Don't include gdb.h.
5139 (mi_cmd_thread_select): Parse the global thread ID here. Use
5140 thread_select instead of gdb_thread_select.
5141 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
5142 of using gdb_list_thread_ids.
5143 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
5144 FILEIO_ENOSYS here.
5145 (remote_fileio_request): Use TRY/CATCH instead of
5146 catch_exceptions.
5147 * symfile-mem.c (struct symbol_file_add_from_memory_args)
5148 (symbol_file_add_from_memory_wrapper): Delete.
5149 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
5150 * thread.c: Don't include gdb.h.
5151 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
5152 (thread_alive): Use thread_select.
5153 (do_captured_thread_select): Delete, parts salvaged as ...
5154 (thread_select): ... this new function.
5155 (gdb_thread_select): Delete.
5156
bf469271
PA
51572017-10-10 Pedro Alves <palves@redhat.com>
5158 Tom Tromey <tom@tromey.com>
5159
5160 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
5161 and reverse logic.
5162 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
5163 No longer macros. Instead ...
5164 (enum wp_check_result): They're now values of this new
5165 enumeration.
5166 (watchpoint_check): Change return type to wp_check_result and
5167 parameter type to bpstat.
5168 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
5169 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
5170 catch_errors. Reverse logic of watchpoint_check call.
5171 (breakpoint_re_set_one): Now returns void and takes a breakpoint
5172 pointer as parameter.
5173 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
5174 * common/common-exceptions.c (throw_exception_sjlj): Update
5175 comments to avoid mentioning catch_errors.
5176 * exceptions.c (catch_errors): Delete.
5177 * exceptions.h: Update comments to avoid mentioning catch_errors.
5178 (catch_errors_ftype, catch_errors): Delete.
5179 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
5180 (hook_stop_stub): Delete.
5181 (restore_selected_frame): Change return type to void, and
5182 parameter type to const frame_id &.
5183 (restore_infcall_control_state): Use TRY/CATCH instead of
5184 catch_errors.
5185 * main.c (captured_command_loop): Return void and remove
5186 parameter. Remove references to catch_errors.
5187 (captured_main): Use TRY/CATCH instead of catch_errors.
5188 * objc-lang.c (objc_submethod_helper_data)
5189 (find_objc_msgcall_submethod_helper): Delete.
5190 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
5191 catch_errors.
5192 * record-full.c (record_full_message): Return void.
5193 (record_full_message_args, record_full_message_wrapper): Delete.
5194 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
5195 instead of catch_errors.
5196 * solib-aix.c (solib_aix_open_symbol_file_object): Change
5197 parameter type to int.
5198 * solib-darwin.c (open_symbol_file_object): Ditto.
5199 * solib-dsbt.c (open_symbol_file_object): Ditto.
5200 * solib-frv.c (open_symbol_file_object): Ditto.
5201 * solib-svr4.c (open_symbol_file_object): Ditto.
5202 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
5203 * solib.c (update_solib_list): Use TRY/CATCH instead of
5204 catch_errors.
5205 * solist.h (struct target_so_ops) <open_symbol_file_object>:
5206 Change type.
5207 * symmisc.c (struct print_symbol_args): Remove.
5208 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
5209 (print_symbol): Change type.
5210 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
5211 and remove parameters.
5212 (catch_errors): New.
5213 (get_windows_debug_event): Adjust.
5214
1a56bfa5
TT
52152017-10-09 Tom Tromey <tom@tromey.com>
5216
5217 * mi/mi-main.c (free_splay_tree): Remove.
5218 (list_available_thread_groups): Use splay_tree_up.
5219 * common/gdb_splay_tree.h: New file.
5220
0c478e2d
TT
52212017-10-09 Tom Tromey <tom@tromey.com>
5222
5223 * mi/mi-main.c (do_nothing): Remove.
5224 (list_available_thread_groups): Update.
5225
cbd2b4e3
PA
52262017-10-09 Pedro Alves <palves@redhat.com>
5227
5228 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
5229 reading registers when switching context.
5230
a181c0bf
JB
52312017-10-09 John Baldwin <jhb@FreeBSD.org>
5232
5233 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
5234 (fbsd_convert_siginfo): Likewise.
5235 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
5236
6e66f753
SM
52372017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
5238
5239 * configure.ac (try_guile_versions): Remove guile-2.2.
5240 * configure: Regenerate.
5241
890e9790
TT
52422017-10-09 Tom Tromey <tom@tromey.com>
5243
5244 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
5245 (COMPILE.pre): Use $(CXX).
5246
109483d9
PA
52472017-10-09 Pedro Alves <palves@redhat.com>
5248
5249 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
5250 Use bool.
5251 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5252 * cp-support.h (cp_remove_params): Now returns a
5253 gdb::unique_xmalloc_ptr.
5254 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
5255 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
5256 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
5257 returning a gdb::unique_xmalloc_ptr.
5258 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
5259 * stack.c (find_frame_funname): Adjust to cp_remove_params
5260 returning a gdb::unique_xmalloc_ptr.
5261
791afaa2
TT
52622017-10-08 Tom Tromey <tom@tromey.com>
5263
5264 * dwarf2read.c (dwarf2_get_dwz_file): Use
5265 gdb::unique_xmalloc_ptr.
5266 (find_slot_in_mapped_hash): Likewise.
5267 (dwarf2_physname): Likewise.
5268 (create_dwo_unit_in_dwp_v1): Use std::string.
5269 (create_dwo_unit_in_dwp_v2): Likewise.
5270 (lookup_dwo_cutu): Likewise.
5271 (inherit_abstract_dies): Use std::vector.
5272 (read_array_type): Likewise.
5273 (dwarf_decode_macros): Remove unused declaration.
5274 (unsigned_int_compar): Remove.
5275 (dwarf2_build_psymtabs_hard): Use scoped_restore.
5276 (psymtabs_addrmap_cleanup): Remove.
5277
30a9c02f
TT
52782017-10-08 Tom Tromey <tom@tromey.com>
5279
5280 * frame-unwind.c (frame_unwind_try_unwinder): Update.
5281 * frame.h (frame_cleanup_after_sniffer): Declare.
5282 (frame_prepare_for_sniffer): Return void.
5283 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
5284 type of argument.
5285 (frame_prepare_for_sniffer): Return void.
5286
757325a3
TT
52872017-10-08 Tom Tromey <tom@tromey.com>
5288
5289 * utils.h (make_cleanup_value_free): Remove.
5290 * utils.c (do_value_free, struct cleanup): Remove.
5291 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
5292 Use gdb_value_up.
5293 * value.h (struct value_deleter): New.
5294 (gdb_value_up): New typedef.
5295
b9c04fb2
TT
52962017-10-08 Tom Tromey <tom@tromey.com>
5297
5298 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
5299 (make_cleanup_free_search_symbols): Remove.
5300 (search_symbols): Return std::vector.
5301 (symbol_search::compare_search_syms): Now member of
5302 symbol_search. Change arguments.
5303 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
5304 (symtab_symbol_info, rbreak_command): Update.
5305 * symtab.h (struct symbol_search) <next>: Remove.
5306 Add constructors.
5307 (symbol_search::operator<): New function.
5308 (symbol_search::operator==): New function.
5309 (search_symbols): Remove std::vector.
5310 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
5311 (symbol_search::compare_search_syms): Declare.
5312
0d28b0a5
YQ
53132017-10-06 Yao Qi <yao.qi@linaro.org>
5314
5315 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
5316 arch/aarch64-insn.o.
5317 Remove one rule.
5318 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
5319
71917808
YQ
53202017-10-06 Yao Qi <yao.qi@linaro.org>
5321
5322 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
5323 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
5324 arch/arm-linux.o respectively.
5325 * configure.tgt: Likewise.
5326
2081b2b2
YQ
53272017-10-06 Yao Qi <yao.qi@linaro.org>
5328
5329 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
5330 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
5331
a1b85d28
PA
53322017-10-06 Pedro Alves <palves@redhat.com>
5333
5334 * windows-nat.c: Include <algorithm>.
5335
d97987e2
YQ
53362017-10-06 Yao Qi <yao.qi@linaro.org>
5337
5338 * configure.tgt (i386_tobjs): New variable.
5339 (amd64_tobjs): New variable.
5340 Set $cpu_obs and $os_obs.
5341
f38307f5
YQ
53422017-10-06 Yao Qi <yao.qi@linaro.org>
5343
5344 * Makefile.in (CONFIG_SRC_SUBDIR): New.
5345 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
5346 (clean): Remove object files and dependency files.
5347 (distclean): Remove the directory.
5348 * configure.ac: Invoke AC_CONFIG_COMMANDS.
5349 * configure: Re-generated.
5350 * configure.tgt: Replace amd64.o with arch/amd64.o.
5351
2f924de6
JM
53522017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
5353
5354 PR build/22188
5355 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
5356 and SETEND.
5357
2fd9d7ca
PA
53582017-10-05 Pedro Alves <palves@redhat.com>
5359
5360 * linux-nat.c (linux_child_follow_fork): When following the parent
5361 and detaching the child, consult the parent thread's architecture
5362 instead of the child's.
5363
d13b8493
UW
53642017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5365
5366 * ax.h: Do not include "doublest.h".
5367 (union agent_val): Remove.
5368
3b4b2f16
UW
53692017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5370
5371 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
5372 (decimal_to_string): Return std::string object.
5373 (decimal_from_string): Accept std::string object. Return bool.
5374 (decimal_from_integral, decimal_from_doublest): Remove.
5375 (decimal_from_longest): Add prototype.
5376 (decimal_from_ulongest): Likewise.
5377 (decimal_to_longest): Likewise.
5378 (decimal_from_doublest): Likewise.
5379 * dfp.c: Do not include "gdbtypes.h" or "value.h".
5380 (MAX_DECIMAL_STRING): Move here.
5381 (decimal_to_string): Return std::string object.
5382 (decimal_from_string): Accept std::string object. Return bool.
5383 (decimal_from_integral): Remove, replace by ...
5384 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
5385 (decimal_to_longest): New function.
5386 (decimal_from_floating): Remove, replace by ...
5387 (decimal_from_doublest): ... this new function.
5388 (decimal_to_doublest): Update to new decimal_to_string interface.
5389
5390 * value.c (unpack_long): Use decimal_to_longest.
5391 * valops.c (value_cast): Use decimal_from_doublest instead of
5392 decimal_from_floating. Use decimal_from_[u]longest isntead of
5393 decimal_from_integral.
5394 * valarith.c (value_args_as_decimal): Likewise.
5395 * valprint.c (print_decimal_floating): Update to new
5396 decimal_to_string interface.
5397 * printcmd.c (printf_decfloat): Likewise.
5398 * c-exp.y (parse_number): Update to new decimal_from_string interface.
5399
1841ee5d
UW
54002017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
5401
5402 * doublest.h: Do not include "floatformat.h". Remove stale comments.
5403 * gdbtypes.c: Include "floatformat.h".
5404 * value.c: Likewise.
5405 * m68k-tdep.c: Likewise.
5406
5407 * findvar.c: Do not include "floatformat.h".
5408 * amd64-darwin-tdep.c: Likewise.
5409 * arm-linux-tdep.c: Likewise.
5410 * i386-darwin-tdep.c: Likewise.
5411 * i387-tdep.c: Likewise.
5412 * m68k-linux-tdep.c: Likewise.
5413 * mep-tdep.c: Likewise.
5414 * mips-tdep.c: Likewise.
5415 * nios2-tdep.c: Likewise.
5416 * s390-linux-tdep.c: Likewise.
5417 * sparc-obsd-tdep.c: Likewise.
5418 * sparc-tdep.c: Likewise.
5419 * sparc64-tdep.c: Likewise.
5420 * spu-tdep.c: Likewise.
5421 * tic6x-tdep.c: Likewise.
5422 * tilegx-tdep.c: Likewise.
5423 * vax-tdep.c: Likewise.
5424 * xstormy16-tdep.c: Likewise.
5425 * xtensa-tdep.c: Likewise.
5426
5427 * top.c: Do not include "doublest.h".
5428 * aarch64-tdep.c: Likewise.
5429 * alpha-tdep.c: Likewise.
5430 * arm-linux-tdep.c: Likewise.
5431 * m68k-linux-tdep.c: Likewise.
5432 * tilegx-tdep.c: Likewise.
5433 * xstormy16-tdep.c: Likewise.
5434
a80a6471
JB
54352017-10-05 John Baldwin <jhb@FreeBSD.org>
5436
5437 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
5438 (mipsn32_fbsd_sigframe): Define.
5439 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
5440 for FreeBSD/mipsn32.
5441
12c4bd7f
JB
54422017-10-05 John Baldwin <jhb@FreeBSD.org>
5443
5444 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
5445 AT_HWCAP.
5446
c91933e9
TG
54472017-10-05 Tristan Gingold <tgingold@free.fr>
5448
5449 * MAINTAINERS (Misc): Update my email address.
5450
5cd63fda
PA
54512017-10-04 Pedro Alves <palves@redhat.com>
5452
5453 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
5454 it instead of target_gdbarch.
5455 (get_remote_state, get_remote_packet_size): Adjust
5456 get_remote_arch_state calls, passing down target_gdbarch
5457 explicitly.
5458 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
5459 'gdbarch' and use it instead of target_gdbarch.
5460 (get_memory_packet_size): Adjust get_remote_arch_state calls,
5461 passing down target_gdbarch explicitly.
5462 (struct stop_reply) <arch>: New field.
5463 (remote_parse_stop_reply): Use the stopped thread's architecture,
5464 not the current inferior's. Save the architecture in the
5465 stop_reply.
5466 (process_stop_reply): Use the stop reply's architecture.
5467 (process_g_packet, remote_fetch_registers)
5468 (remote_prepare_to_store, store_registers_using_G)
5469 (remote_store_registers): Adjust get_remote_arch_state calls,
5470 using the regcache's architecture.
5471 (remote_get_trace_status): Adjust get_remote_arch_state calls,
5472 passing down target_gdbarch explicitly.
5473 * spu-multiarch.c (spu_thread_architecture): Defer to the target
5474 beneath instead of calling target_gdbarch.
5475 * target.c (default_thread_architecture): Use the specified
5476 inferior's architecture, instead of the current inferior's
5477 architecture (via target_gdbarch).
5478
ed4227b7
PA
54792017-10-04 Pedro Alves <palves@redhat.com>
5480
5481 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
5482 case.
5483 (regcache_print): Handle !target_has_registers here instead.
5484
55b11ddf
PA
54852017-10-04 Pedro Alves <palves@redhat.com>
5486
5487 * frame.c (create_test_frame): Delete.
5488 * frame.h (create_test_frame): Delete.
5489 * gdbarch-selftests.c: Include gdbthread.h and target.h.
5490 (class regcache_test): Delete.
5491 (test_target_has_registers, test_target_has_stack)
5492 (test_target_has_memory, test_target_prepare_to_store)
5493 (test_target_store_registers): New functions.
5494 (test_target_ops): New class.
5495 (register_to_value_test): Error out if there's already a
5496 process_stratum (or higher) target pushed. Create a fuller mock
5497 environment, with mock target_ops, inferior, address space, thread
5498 and inferior_ptid.
5499 * progspace.c (struct address_space): Move to ...
5500 * progspace.h (struct address_space): ... here.
5501 * regcache.h (regcache::~regcache, regcache::raw_write)
5502 [GDB_SELF_TEST]: No longer virtual.
5503
4c71c105
SM
55042017-10-04 Simon Marchi <simon.marchi@ericsson.com>
5505
5506 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
5507
73dcd72d
PA
55082017-10-04 Pedro Alves <palves@redhat.com>
5509
5510 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
5511 out of 'between TRY and CATCH'.
5512
44704526
PA
55132017-10-04 Pedro Alves <palves@redhat.com>
5514
5515 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
5516 * common/common-exceptions.h (TRY): Open an outermost scope.
5517 Expand intro comment.
5518 (CATCH): Reindent.
5519 (END_CATCH): Close the outermost scope.
5520 * completer.c (complete_line_internal): Add missing END_CATCH.
5521
bc3b087d
SDJ
55222017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5523
5524 * NEWS (Changes since GDB 8.0): Add entry about new
5525 'set-cwd-on-gdbserver' feature.
5526 (New remote packets): Add entry for QSetWorkingDir.
5527 * common/common-inferior.h (set_inferior_cwd): New prototype.
5528 * infcmd.c (set_inferior_cwd): Remove "static".
5529 (show_cwd_command): Expand text to include remote debugging.
5530 * remote.c: Add PACKET_QSetWorkingDir.
5531 (remote_protocol_features) <QSetWorkingDir>: New entry for
5532 PACKET_QSetWorkingDir.
5533 (extended_remote_set_inferior_cwd): New function.
5534 (extended_remote_create_inferior): Call
5535 "extended_remote_set_inferior_cwd".
5536 (_initialize_remote): Call "add_packet_config_cmd" for
5537 QSetWorkingDir.
5538
d092c5a2
SDJ
55392017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5540
5541 * NEWS (New commands): Mention "set/show cwd".
5542 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
5543 "cd" command's help text.
5544 * common/common-inferior.h (get_inferior_cwd): New prototype.
5545 * infcmd.c (inferior_cwd_scratch): New global variable.
5546 (set_inferior_cwd): New function.
5547 (get_inferior_cwd): Likewise.
5548 (set_cwd_command): Likewise.
5549 (show_cwd_command): Likewise.
5550 (_initialize_infcmd): Add "set/show cwd" commands.
5551 * inferior.h (class inferior) <cwd>: New field.
5552 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
5553 (fork_inferior): Change inferior's cwd before its execution.
5554 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
5555 to CreateProcess.
5556
7da0a886
SDJ
55572017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5558
5559 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
5560 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
5561 (COMMON_OBS): Add gdb_tilde_expand.o.
5562 * common/gdb_tilde_expand.c: New file.
5563 * common/gdb_tilde_expand.h: Likewise.
5564
db8dd160
MR
55652017-10-03 Maciej W. Rozycki <macro@imgtec.com>
5566
5567 * gdbarch.sh (objfile): Remove duplicate declaration.
5568 * gdbarch.h: Regenerate.
5569
f8bfbf22
TT
55702017-10-03 Tom Tromey <tom@tromey.com>
5571
5572 * utils.c (internal_vproblem): Use string_vprintf.
5573
5178ed48
TT
55742017-10-03 Tom Tromey <tom@tromey.com>
5575
5576 * printcmd.c (info_symbol_command): Use std::string.
5577
8cff8730
TT
55782017-10-03 Tom Tromey <tom@tromey.com>
5579
5580 * top.c (gdb_safe_append_history): Use std::string.
5581
895b8f30
TT
55822017-10-03 Tom Tromey <tom@tromey.com>
5583
5584 * event-top.c (stdin_event_handler): Update.
5585 * main.c (captured_main_1): Update.
5586 * top.h (make_delete_ui_cleanup): Remove.
5587 (struct ui): Add constructor and destructor.
5588 (new_ui, delete_ui): Remove.
5589 * top.c (make_delete_ui_cleanup): Remove.
5590 (new_ui_command): Use std::unique_ptr.
5591 (delete_ui_cleanup): Remove.
5592 (ui::ui): Rename from new_ui. Update.
5593 (free_ui): Remove.
5594 (ui::~ui): Rename from delete_ui. Update.
5595
0efef640
TT
55962017-10-03 Tom Tromey <tom@tromey.com>
5597
5598 * symfile.c (load_progress): Use gdb::byte_vector.
5599
245ad7d3
TT
56002017-10-03 Tom Tromey <tom@tromey.com>
5601
5602 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
5603 declaration.
5604 * printcmd.c (x_command): Remove unused declaration.
5605 * symfile.c (symbol_file_command): Remove unused declaration.
5606
e05550d7
TT
56072017-10-03 Tom Tromey <tom@tromey.com>
5608
5609 * utils.c (internal_vproblem): Use std::string.
5610 (defaulted_query): Likewise.
5611
b95de2b7
TT
56122017-10-03 Tom Tromey <tom@tromey.com>
5613
5614 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
5615 * top.c (execute_command_to_string): Update.
5616 * utils.c (make_cleanup_restore_page_info): Remove.
5617 (do_restore_page_info_cleanup): Remove.
5618 (set_batch_flag_and_restore_page_info):
5619 New.
5620 (make_cleanup_restore_page_info): Remove.
5621 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5622 (~set_batch_flag_and_restore_page_info): New
5623 (make_cleanup_restore_uinteger): Remove.
5624 (make_cleanup_restore_integer): Remove.
5625 (struct restore_integer_closure): Remove.
5626 (restore_integer): Remove.
5627 * utils.h (struct set_batch_flag_and_restore_page_info): New
5628 class.
5629 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5630 (make_cleanup_restore_page_info): Remove.
5631 (make_cleanup_restore_uinteger) Remove.
5632 (make_cleanup_restore_integer) Remove.
5633
07036511
TT
56342017-10-03 Tom Tromey <tom@tromey.com>
5635
5636 * record-full.h (record_full_gdb_operation_disable_set): Return
5637 scoped_restore_tmpl<int>.
5638 * infrun.c (adjust_pc_after_break): Update.
5639 (handle_signal_stop): Update.
5640 * record-full.c (record_full_gdb_operation_disable_set): Return
5641 scoped_restore_tmpl<int>.
5642 (record_full_wait_1, record_full_insert_breakpoint)
5643 (record_full_remove_breakpoint, record_full_save)
5644 (record_full_goto_insn): Update.
5645
45320ffa
TT
56462017-10-02 Tom Tromey <tom@tromey.com>
5647
5648 PR rust/22236:
5649 * rust-lang.c (rust_val_print_str): New function.
5650 (val_print_struct): Call it.
5651 (rust_subscript): Preserve name of slice type.
5652
b3e3859b
TT
56532017-10-02 Tom Tromey <tom@tromey.com>
5654
5655 * rust-lang.c (rust_subscript): Handle slices in
5656 EVAL_AVOID_SIDE_EFFECTS case.
5657
01af5e0d
TT
56582017-10-02 Tom Tromey <tom@tromey.com>
5659
5660 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
5661
888e3ddb
TT
56622017-10-02 Tom Tromey <tom@tromey.com>
5663
5664 * rust-lang.h (rust_slice_type): Add "extern".
5665
cc536b21
PA
56662017-10-02 Tom Tromey <tom@tromey.com>
5667 Pedro Alves <palves@redhat.com>
5668
5669 * ada-lang.h (ada_exc_info::operator<): Make const.
5670 (ada_exc_info::operator==): Make const.
5671 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
5672 Make const.
5673
386c8614
TT
56742017-09-29 Tom Tromey <tom@tromey.com>
5675
5676 * target.c (read_whatever_is_readable): Change type of "result".
5677 Update.
5678 (free_memory_read_result_vector): Remove.
5679 (read_memory_robust): Change return type. Update.
5680 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
5681 bin2hex, std::string.
5682 * target.h (memory_read_result_s): Remove typedef.
5683 (free_memory_read_result_vector): Remove.
5684 (read_memory_robust): Return std::vector.
5685
789c4b5e
TT
56862017-09-29 Tom Tromey <tom@tromey.com>
5687
5688 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
5689
ab816a27
TT
56902017-09-29 Tom Tromey <tom@tromey.com>
5691
5692 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
5693 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
5694 operator< and operator==.
5695 (ada_exceptions_list): Return a std::vector.
5696 * ada-lang.c (ada_exc_info::operator<): Rename from
5697 compare_ada_exception_info.
5698 (ada_exc_info::operator==): New.
5699 (sort_remove_dups_ada_exceptions_list): Change type of
5700 "exceptions".
5701 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
5702 (ada_add_global_exceptions): Likewise.
5703 (ada_exceptions_list_1): Return a std::vector.
5704 (ada_exceptions_list): Likewise.
5705
52f9abe4
TT
57062017-09-29 Tom Tromey <tom@tromey.com>
5707
5708 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
5709 'std::set *'.
5710 (print_one_inferior): Update.
5711 (free_vector_of_ints): Remove.
5712 (list_available_thread_groups): Change "ids" to std::set.
5713 (mi_cmd_list_thread_groups): Update.
5714 (struct collect_cores_data) <core>: Now a std::set.
5715 (collect_cores): Update.
5716 (unique): Remove.
5717 (print_one_inferior): Update.
5718
dcd5ddcc
TT
57192017-09-29 Tom Tromey <tom@tromey.com>
5720
5721 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
5722 (mi_execute_async_cli_command): Likewise.
5723 (mi_cmd_trace_frame_collected): Use field_fmt.
5724
45d288cc
TT
57252017-09-29 Tom Tromey <tom@tromey.com>
5726
5727 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
5728 gdb::byte_vector.
5729
6afe2f4a
TT
57302017-09-29 Tom Tromey <tom@tromey.com>
5731
5732 * mi/mi-parse.c (mi_parse): Remove unused declaration.
5733
9813429a
TT
57342017-09-29 Tom Tromey <tom@tromey.com>
5735
5736 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
5737
2d6960b4
TT
57382017-09-29 Tom Tromey <tom@tromey.com>
5739
5740 * varobj.h (varobj_gen_name): Return std::string.
5741 * varobj.c (varobj_gen_name): Return std::string.
5742 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
5743 (mi_cmd_var_delete): Don't copy "name".
5744
784c453a
TT
57452017-09-29 Tom Tromey <tom@tromey.com>
5746
5747 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
5748 (mi_cmd_break_insert_1): Update.
5749
a9bc57b9
TT
57502017-09-29 Tom Tromey <tom@tromey.com>
5751
5752 * target.h (make_scoped_defer_target_commit_resume): Update.
5753 * target.c (make_scoped_defer_target_commit_resume): Rename from
5754 make_cleanup_defer_target_commit_resume. Return a
5755 scoped_restore.
5756 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
5757
9754d8c4
TT
57582017-09-29 Tom Tromey <tom@tromey.com>
5759
5760 * main.c (captured_main_1): Remove unused declaration.
5761 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
5762
99ef965c
TT
57632017-09-29 Tom Tromey <tom@tromey.com>
5764
5765 * symtab.c (search_symbols): Remove unused outer cleanup.
5766 (make_source_files_completion_list): Remove unused declaration.
5767
42518ba7
TT
57682017-09-29 Tom Tromey <tom@tromey.com>
5769
5770 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
5771
726b2169
TT
57722017-09-29 Tom Tromey <tom@tromey.com>
5773
5774 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
5775 gdb::byte_vector.
5776
55b06432
TT
57772017-09-29 Tom Tromey <tom@tromey.com>
5778
5779 * complaints.c (vcomplaint): Use std::string.
5780
8abcee91
TT
57812017-09-29 Tom Tromey <tom@tromey.com>
5782
5783 * tracepoint.c (trace_variable_command): Use std::string.
5784 (encode_actions_1): Remove unused declarations.
5785 (create_tsv_from_upload): Use std::string.
5786
6ad94bc7
TT
57872017-09-29 Tom Tromey <tom@tromey.com>
5788
5789 * cp-support.c (gdb_demangle): Use std::string.
5790
2003f3d8
TT
57912017-09-29 Tom Tromey <tom@tromey.com>
5792
5793 * stack.c (parse_frame_specification): Use std::string
5794 (info_frame_command): Use gdb::unique_xmalloc_ptr.
5795
8f8accb5
TT
57962017-09-29 Tom Tromey <tom@tromey.com>
5797
5798 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
5799
200aa7b1
TT
58002017-09-29 Tom Tromey <tom@tromey.com>
5801
5802 * utils.c (vfprintf_maybe_filtered): Use std::string.
5803 (vfprintf_unfiltered): Likewise.
5804
606aae8a
TT
58052017-09-29 Tom Tromey <tom@tromey.com>
5806
5807 * event-top.c (top_level_prompt): Return std::string.
5808 (display_gdb_prompt): Update.
5809
bd413795
TT
58102017-09-29 Tom Tromey <tom@tromey.com>
5811
5812 * unittests/common-utils-selftests.c (format): New function.
5813 (string_vprintf_tests): New function.
5814 (_initialize_common_utils_selftests): Register new tests.
5815 * common/common-utils.c (string_vprintf): New function.
5816 * common/common-utils.h (string_vprintf): Declare.
5817
256642e8
PA
58182017-09-29 Pedro Alves <palves@redhat.com>
5819
5820 * common/rsp-low.c (unpack_varlen_hex): Constify.
5821 * common/rsp-low.h (unpack_varlen_hex): Constify.
5822 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
5823 Constify.
5824 * remote.c (remote_set_permissions, read_ptid)
5825 (remote_current_thread, remote_get_threads_with_qthreadinfo)
5826 (remote_static_tracepoint_marker_at)
5827 (remote_static_tracepoint_markers_by_strid)
5828 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
5829 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
5830 (parse_tracepoint_definition, parse_tsv_definition)
5831 (parse_static_tracepoint_marker_definition): Constify.
5832 * tracepoint.h (parse_static_tracepoint_marker_definition)
5833 (parse_trace_status, parse_tracepoint_status)
5834 (parse_tracepoint_definition, parse_tsv_definition): Constify.
5835
b6bb3468
PA
58362017-09-29 Pedro Alves <palves@redhat.com>
5837
5838 * remote.c (target_buf, target_buf_size): Delete.
5839 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
5840 Use the connection's packet buffer instead.
5841 All callers adjusted.
5842 (_initialize_remote): Remove references to target_buf and
5843 target_buf_size.
5844
b2f8eb7a
PA
58452017-09-28 Pedro Alves <palves@redhat.com>
5846
5847 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5848 unittests/common-utils-selftests.c.
5849 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
5850 (COMMON_OBS): Remove utils-selftests.o.
5851 * utils-selftests.c: Move to ...
5852 * unittests/common-utils-selftests.c: ... here and rename self
5853 test to "string_printf".
5854
08302ed2
DE
58552017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
5856
5857 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
5858 having NULL cus or tus.
5859
96a5a1d3
UW
58602017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5861
5862 * arm-tdep.c: (convert_from_extended): Remove.
5863 (convert_to_extended): Likewise.
5864 (arm_extract_return_value): Use convert_typed_floating.
5865 (arm_store_return_value): Likewise.
5866
5867 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5868 * sh-tdep.c: Do not include "floatformat.h".
5869 (sh_littlebyte_bigword_type): New function.
5870 (sh_register_convert_to_virtual): Use convert_typed_floating.
5871 (sh_register_convert_to_raw): Likewise.
5872 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5873 (sh64_littlebyte_bigword_type): New function.
5874 (sh64_extract_return_value): Use convert_typed_floating.
5875 (sh64_register_convert_to_virtual): Likewise.
5876 (sh64_register_convert_to_raw): Likewise.
5877
0db7851f
UW
58782017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5879
5880 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
5881 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
5882
5883 * gdbtypes.h (union type_specific): Make field floatformat hold
5884 just a single struct floatformat, not an array.
5885 (floatformat_from_type): Move here.
5886 * gdbtypes.c (floatformat_from_type): Move here. Update to
5887 changed TYPE_FLOATFORMAT definition.
5888 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
5889 (recursive_dump_type): Likewise.
5890 (init_float_type): Install correct floatformat for byte order.
5891 (arch_float_type): Likewise.
5892
77b7c781
UW
58932017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5894
5895 * gdbtypes.c (init_type): Change incoming argument from
5896 length-in-bytes to length-in-bits. Assert length is a
5897 multiple of TARGET_CHAR_BITS.
5898 (arch_type, arch_flags_type): Likewise.
5899 (init_integer_type): Update call to init_type.
5900 (init_character_type): Likewise.
5901 (init_boolean_type): Likewise.
5902 (init_float_type): Likewise.
5903 (init_decfloat_type): Likewise.
5904 (init_complex_type): Likewise.
5905 (init_pointer_type): Likewise.
5906 (objfile_type): Likewise.
5907 (arch_integer_type): Update call to arch_type.
5908 (arch_character_type): Likewise.
5909 (arch_boolean_type): Likewise.
5910 (arch_float_type): Likewise.
5911 (arch_decfloat_type): Likewise.
5912 (arch_complex_type): Likewise.
5913 (arch_pointer_type): Likewise.
5914 (gdbtypes_post_init): Likewise.
5915
5916 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
5917 (read_base_type): Likewise.
5918 * mdebugread.c (basic_type): Likewise.
5919 * stabsread.c (dbx_init_float_type): Likewise.
5920 (rs6000_builtin_type): Likewise.
5921 (read_range_type): Likewise. Also, fix call to init_integer_type
5922 with erroneous length argument.
5923
5924 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
5925 * d-lang.c (build_d_types): Likewise.
5926 * f-lang.c (build_fortran_types): Likewise.
5927 * go-lang.c (build_go_types): Likewise.
5928 * opencl-lang.c (build_opencl_types): Likewise.
5929 * jit.c (finalize_symtab): Likewise.
5930 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
5931 (build_std_type_info_type): Likewise.
5932 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
5933 update call to arch_flags_type.
5934
5935 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
5936 arch_type.
5937 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
5938 * windows-tdep.c (windows_get_tlb_type): Likewise.
5939
5940 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
5941 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5942 * m32c-tdep.c (make_types): Likewise.
5943 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
5944 (rl78_psw_type): Update call to arch_flags_type.
5945 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
5946 * rx-tdep.c (rx_psw_type): Likewise.
5947 (rx_fpsw_type): Likewise.
5948 * sparc-tdep.c (sparc_psr_type): Likewise.
5949 (sparc_fsr_type): Likewise.
5950 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
5951 (sparc64_ccr_type): Likewise.
5952 (sparc64_fsr_type): Likewise.
5953 (sparc64_fprs_type): Likewise.
5954
f21b4d5c
TT
59552017-09-27 Tom Tromey <tom@tromey.com>
5956
5957 * findcmd.c (find_command): Constify.
5958
643c2ffa
TT
59592017-09-27 Tom Tromey <tom@tromey.com>
5960
5961 * ada-tasks.c (task_command_1, task_command): Constify.
5962
510e5e56
TT
59632017-09-27 Tom Tromey <tom@tromey.com>
5964
5965 * symtab.c (maintenance_print_symbol_cache)
5966 (maintenance_flush_symbol_cache)
5967 (maintenance_print_symbol_cache_statistics): Constify.
5968
e503b191
TT
59692017-09-27 Tom Tromey <tom@tromey.com>
5970
5971 * inferior.c (detach_inferior_command, kill_inferior_command)
5972 (inferior_command): Constify.
5973
4e001312
TT
59742017-09-27 Tom Tromey <tom@tromey.com>
5975
5976 * regcache.c (regcache_print, maintenance_print_registers)
5977 (maintenance_print_raw_registers)
5978 (maintenance_print_cooked_registers)
5979 (maintenance_print_register_groups)
5980 (maintenance_print_remote_registers): Constify.
5981
77763700
TT
59822017-09-27 Tom Tromey <tom@tromey.com>
5983
5984 * printcmd.c (map_display_numbers, undisplay_command)
5985 (enable_disable_display_command, enable_display_command)
5986 (disable_display_command): Constify.
5987
4495129a
TT
59882017-09-27 Tom Tromey <tom@tromey.com>
5989
5990 * breakpoint.h (delete_command): Don't declare.
5991 * breakpoint.c (delete_command, enable_once_command)
5992 (enable_count_command, enable_delete_command, breakpoint_1)
5993 (maintenance_info_breakpoints, stopin_command, stopat_command)
5994 (delete_command, delete_trace_command, save_breakpoints)
5995 (save_breakpoints_command, save_tracepoints_command): Constify.
5996
3088cf40
TT
59972017-09-27 Tom Tromey <tom@tromey.com>
5998
5999 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6000 (skip_ws, extract_identifier, macro_define_command)
6001 (macro_undef_command, macro_list_command): Constify.
6002
69f476a3
TT
60032017-09-27 Tom Tromey <tom@tromey.com>
6004
6005 * infcmd.c (environment_info, set_environment_command)
6006 (unset_environment_command, path_info, info_proc_cmd_1)
6007 (info_proc_cmd_mappings, info_proc_cmd_stat)
6008 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
6009 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
6010
c4a3e68e
TT
60112017-09-27 Tom Tromey <tom@tromey.com>
6012
6013 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
6014 Constify.
6015
c9d31bd6
TT
60162017-09-27 Tom Tromey <tom@tromey.com>
6017
6018 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
6019
1f3f85eb
TT
60202017-09-27 Tom Tromey <tom@tromey.com>
6021
6022 * demangle.c (demangle_command): Constify.
6023
9c504b5d
TT
60242017-09-27 Tom Tromey <tom@tromey.com>
6025
6026 * progspace.c (maintenance_info_program_spaces_command):
6027 Constify.
6028
6663cf91
TT
60292017-09-27 Tom Tromey <tom@tromey.com>
6030
6031 * compile/compile.c (check_raw_argument, compile_file_command)
6032 (compile_code_command, compile_print_command): Constify.
6033
34e5fa26
TT
60342017-09-27 Tom Tromey <tom@tromey.com>
6035
6036 * reggroups.c (maintenance_print_reggroups): Constify.
6037
8384c356
TT
60382017-09-27 Tom Tromey <tom@tromey.com>
6039
6040 * dwarf2read.c (save_gdb_index_command): Constify.
6041
884beb0c
TT
60422017-09-27 Tom Tromey <tom@tromey.com>
6043
6044 * stap-probe.c (info_probes_stap_command): Constify.
6045
e0b2930c
TT
60462017-09-27 Tom Tromey <tom@tromey.com>
6047
6048 * fork-child.c (unset_exec_wrapper_command): Constify.
6049
f938677d
TT
60502017-09-27 Tom Tromey <tom@tromey.com>
6051
6052 * btrace.c (get_uint, get_context_size, no_chunk)
6053 (maint_btrace_packet_history_cmd)
6054 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
6055 (maint_info_btrace_cmd): Constify.
6056
8949cb87
TT
60572017-09-27 Tom Tromey <tom@tromey.com>
6058
6059 * reverse.c (delete_bookmark_command): Constify.
6060
ac88e2de
TT
60612017-09-27 Tom Tromey <tom@tromey.com>
6062
6063 * remote.c (set_memory_packet_size)
6064 (set_memory_write_packet_size, show_memory_write_packet_size)
6065 (set_memory_read_packet_size, show_memory_read_packet_size)
6066 (compare_sections_command, packet_command, remote_put_command)
6067 (remote_get_command, remote_delete_command): Constify.
6068
bd4c9dfe
TT
60692017-09-27 Tom Tromey <tom@tromey.com>
6070
6071 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
6072 (set_mipsfpu_double_command, set_mipsfpu_none_command)
6073 (set_mipsfpu_auto_command): Constify.
6074
5e93d4c6
TT
60752017-09-27 Tom Tromey <tom@tromey.com>
6076
6077 * cli/cli-cmds.h (cd_command): Constify.
6078 * cli/cli-cmds.c (cd_command): Constify.
6079
fc41a75b
TT
60802017-09-27 Tom Tromey <tom@tromey.com>
6081
6082 * thread.c (thread_name_command, thread_find_command): Constify.
6083
67810076
TT
60842017-09-27 Tom Tromey <tom@tromey.com>
6085
6086 * probe.c (enable_probes_command, disable_probes_command):
6087 Constify.
6088
1d8b34a7
TT
60892017-09-27 Tom Tromey <tom@tromey.com>
6090
6091 * symfile.c (symbol_file_command): Constify.
6092 * gdbcore.h (deprecated_file_changed_hook): Constify.
6093 * exec.c (deprecated_file_changed_hook, exec_file_command)
6094 (file_command): Constify.
6095 * defs.h (symbol_file_command): Constify.
6096
442019e1
TT
60972017-09-27 Tom Tromey <tom@tromey.com>
6098
6099 * remote-fileio.c (set_system_call_allowed)
6100 (show_system_call_allowed): Constify.
6101
2983f7cb
TT
61022017-09-27 Tom Tromey <tom@tromey.com>
6103
6104 * tracepoint.c (delete_trace_variable_command)
6105 (tfind_end_command, tfind_start_command, tfind_pc_command)
6106 (tfind_tracepoint_command, tfind_line_command)
6107 (tfind_range_command, tfind_outside_command): Constify.
6108
4fd41b24
TT
61092017-09-27 Tom Tromey <tom@tromey.com>
6110
6111 * ax-gdb.c (maint_agent_printf_command, agent_command)
6112 (agent_eval_command): Constify.
6113
f2fc3015
TT
61142017-09-27 Tom Tromey <tom@tromey.com>
6115
6116 * tracepoint.c (info_scope_command): Constify.
6117 * python/python.c (gdbpy_decode_line): Constify.
6118 * python/py-breakpoint.c (bppy_init): Constify.
6119 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
6120 * location.h: (new_linespec_location)
6121 (string_to_event_location_basic, string_to_event_location):
6122 Constify.
6123 * location.c (new_linespec_location)
6124 (string_to_event_location_basic, string_to_event_location):
6125 Constify.
6126 * linespec.h (decode_line_with_current_source)
6127 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
6128 * linespec.c (linespec_lex_to_end)
6129 (decode_line_with_current_source)
6130 (decode_line_with_last_displayed): Constify.
6131 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
6132 Constify.
6133 * cli/cli-cmds.c (edit_command, list_command): Constify.
6134 * breakpoint.h (until_break_command, watch_command_wrapper)
6135 (awatch_command_wrapper, rwatch_command_wrapper)
6136 (init_ada_exception_breakpoint): Constify.
6137 * breakpoint.c (break_command_1, dprintf_command)
6138 (break_range_command, watch_command_wrapper)
6139 (rwatch_command_wrapper, awatch_command_wrapper)
6140 (until_break_command, init_ada_exception_breakpoint)
6141 (strace_marker_create_sals_from_location, trace_command)
6142 (ftrace_command, strace_command, struct tracepoint): Constify.
6143 * ax-gdb.c (agent_command_1): Constify.
6144 * ada-lang.c (ada_exception_sal): Constify.
6145
8c2f95f4
TT
61462017-09-27 Tom Tromey <tom@tromey.com>
6147
6148 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
6149 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
6150 (get_context_size, no_chunk, get_insn_history_modifiers)
6151 (cmd_record_insn_history, get_call_history_modifiers)
6152 (cmd_record_call_history): Constify.
6153
a0d65762
TT
61542017-09-27 Tom Tromey <tom@tromey.com>
6155
6156 * source.c (show_substitute_path_command)
6157 (unset_substitute_path_command, set_substitute_path_command):
6158 Constify.
6159
58971144
TT
61602017-09-27 Tom Tromey <tom@tromey.com>
6161
6162 * typeprint.c (maintenance_print_type): Constify.
6163 * maint.c (maintenance_dump_me, maintenance_demangle)
6164 (maintenance_time_display, maintenance_info_sections)
6165 (maintenance_print_statistics, maintenance_deprecate)
6166 (maintenance_undeprecate): Constify.
6167 (maintenance_do_deprecate): Constify. Use std::string.
6168 (maintenance_selftest): Constify.
6169 * gdbtypes.h (maintenance_print_type): Constify.
6170
c482f52c
TT
61712017-09-27 Tom Tromey <tom@tromey.com>
6172
6173 * hppa-tdep.c (unwind_command): Constify.
6174
e100df1a
TT
61752017-09-27 Tom Tromey <tom@tromey.com>
6176
6177 * target-descriptions.c (unset_tdesc_filename_cmd)
6178 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
6179 Constify.
6180
31d56ade
TT
61812017-09-27 Tom Tromey <tom@tromey.com>
6182
6183 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
6184
b961da0b
TT
61852017-09-27 Tom Tromey <tom@tromey.com>
6186
6187 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
6188
e2d8ae16
TT
61892017-09-27 Tom Tromey <tom@tromey.com>
6190
6191 * tui/tui-regs.c (tui_reg_command): Constify.
6192
863779b0
TT
61932017-09-27 Tom Tromey <tom@tromey.com>
6194
6195 * skip.c (skip_file_command, skip_function_command)
6196 (skip_enable_command, skip_disable_command, skip_delete_command):
6197 Constify.
6198
cdb34d4a
TT
61992017-09-27 Tom Tromey <tom@tromey.com>
6200
6201 * record-btrace.c (cmd_record_btrace_bts_start)
6202 (cmd_record_btrace_pt_start): Constify.
6203
e99c83e7
TT
62042017-09-27 Tom Tromey <tom@tromey.com>
6205
6206 * symmisc.c (maintenance_print_symbols)
6207 (maintenance_print_msymbols, maintenance_print_objfiles)
6208 (maintenance_info_symtabs, maintenance_check_symtabs)
6209 (maintenance_expand_symtabs, maintenance_info_line_tables):
6210 Constify.
6211
32faf971
TT
62122017-09-27 Tom Tromey <tom@tromey.com>
6213
6214 * top.c (new_ui_command): Constify.
6215
2cf311eb
TT
62162017-09-27 Tom Tromey <tom@tromey.com>
6217
6218 * symfile.c (add_symbol_file_command)
6219 (remove_symbol_file_command, list_overlays_command)
6220 (map_overlay_command, unmap_overlay_command)
6221 (overlay_auto_command, overlay_manual_command)
6222 (overlay_off_command, overlay_load_command): Constify.
6223
e6738699
TT
62242017-09-27 Tom Tromey <tom@tromey.com>
6225
6226 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
6227 (info_spu_mailbox_command, info_spu_dma_command)
6228 (info_spu_proxydma_command): Constify.
6229
aa360cd5
TT
62302017-09-27 Tom Tromey <tom@tromey.com>
6231
6232 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
6233
898241a5
TT
62342017-09-27 Tom Tromey <tom@tromey.com>
6235
6236 * cli/cli-script.c (user_defined_command): Constify.
6237
2d0ac106
TT
62382017-09-27 Tom Tromey <tom@tromey.com>
6239
6240 * cli/cli-dump.c (dump_memory_command, dump_value_command)
6241 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
6242 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
6243 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
6244 (dump_binary_value, append_binary_memory, append_binary_value):
6245 Constify.
6246 (struct dump_context) <func>: Constify.
6247 (add_dump_command): Update.
6248
dede02ce
TT
62492017-09-27 Tom Tromey <tom@tromey.com>
6250
6251 * cli/cli-cmds.c (show_version, show_configuration)
6252 (source_command, show_user): Constify.
6253
d3cb6b99
TT
62542017-09-27 Tom Tromey <tom@tromey.com>
6255
6256 * target.c (maintenance_print_target_stack): Constify.
6257
1970a12f
TT
62582017-09-27 Tom Tromey <tom@tromey.com>
6259
6260 * interps.c (interpreter_exec_cmd): Constify.
6261
41243651
TT
62622017-09-27 Tom Tromey <tom@tromey.com>
6263
6264 * record-full.c (cmd_record_full_restore): Constify.
6265
4465d9db
TT
62662017-09-27 Tom Tromey <tom@tromey.com>
6267
6268 * memattr.c (enable_mem_command, disable_mem_command)
6269 (delete_mem_command): Constify.
6270
ad25e423
TT
62712017-09-27 Tom Tromey <tom@tromey.com>
6272
6273 * value.c (show_convenience): Constify.
6274
d64097b1
TT
62752017-09-27 Tom Tromey <tom@tromey.com>
6276
6277 * gdbcore.h (core_file_command): Update.
6278 * corefile.c (core_file_command): Constify.
6279
4d4589ef
TT
62802017-09-27 Tom Tromey <tom@tromey.com>
6281
6282 * user-regs.c (maintenance_print_user_registers): Constify.
6283
32a7bf17
TT
62842017-09-27 Tom Tromey <tom@tromey.com>
6285
6286 * cp-namespace.c (maintenance_cplus_namespace): Constify.
6287
4a475551
TT
62882017-09-27 Tom Tromey <tom@tromey.com>
6289
6290 * cp-support.c (first_component_command): Constify.
6291
990b9f9f
TT
62922017-09-27 Tom Tromey <tom@tromey.com>
6293
6294 * psymtab.c (maintenance_print_psymbols)
6295 (maintenance_info_psymtabs, maintenance_check_psymtabs):
6296 Constify.
6297
c281872e
TT
62982017-09-27 Tom Tromey <tom@tromey.com>
6299
6300 * windows-tdep.c (display_tib): Constify.
6301
5b64bf74
TT
63022017-09-27 Tom Tromey <tom@tromey.com>
6303
6304 * linux-fork.c (delete_checkpoint_command)
6305 (detach_checkpoint_command): Constify.
6306
4ada038f
TT
63072017-09-27 Tom Tromey <tom@tromey.com>
6308
6309 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
6310
57f5a81b
TT
63112017-09-27 Tom Tromey <tom@tromey.com>
6312
6313 * arc-tdep.c (dump_arc_instruction_command): Constify.
6314
b0a8e6c4
TT
63152017-09-27 Tom Tromey <tom@tromey.com>
6316
6317 * valprint.c (set_radix, show_radix): Constify.
6318
8d97dc1c
TT
63192017-09-27 Tom Tromey <tom@tromey.com>
6320
6321 * dtrace-probe.c (info_probes_dtrace_command): Constify.
6322
eb7c454d
TT
63232017-09-27 Tom Tromey <tom@tromey.com>
6324
6325 * command.h (not_just_help_class_command): Update.
6326 * cli/cli-decode.h (not_just_help_class_command): Update.
6327 * cli/cli-decode.c (not_just_help_class_command): Constify.
6328
e4e33335
TT
63292017-09-27 Tom Tromey <tom@tromey.com>
6330
6331 * gdb_bfd.c (maintenance_info_bfds): Constify.
6332
0450cc4c
TT
63332017-09-27 Tom Tromey <tom@tromey.com>
6334
6335 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
6336 overloads.
6337 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
6338 (do_const_cfunc): New function.
6339 (cmd_cfunc_eq): New overload.
6340 (cli_user_command_p): Check do_const_cfunc.
6341 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
6342 const_cfunc.
6343 * command.h (add_cmd): Add const overload and no-function
6344 overload.
6345 (set_cmd_cfunc): Add const overload.
6346 (cmd_const_cfunc_ftype): Declare.
6347 (cmd_cfunc_eq): Add const overload.
6348 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
6349 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
6350 overload.
6351
a9bbfbd8
TT
63522017-09-27 Tom Tromey <tom@tromey.com>
6353
6354 * macroexp.c (get_next_token_for_substitution): New function.
6355 (substitute_args): Call it. Check for __VA_OPT__.
6356
5230b05a
WT
63572017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6358 Pedro Alves <palves@redhat.com>
6359
6360 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
6361 producer_is_icc_lt_14.
6362 (producer_is_icc_lt_14): New function.
6363 (check_producer): Add code for checking version of ICC.
6364 (producer_is_icc): Move to producer.c.
6365 (read_structure_type): Restrict ICC workaround to ICC<14.
6366 * producer.c: Include selftest.h.
6367 (producer_is_icc, producer_parsing_tests, _initialize_producer):
6368 New functions.
6369 * producer.h (producer_is_icc): New declaration.
6370
b32b108a
WT
63712017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
6372
6373 * Makefile.in (SFILES): Add producer.c.
6374 (COMMON_OBS): Add producer.o
6375 * amd64-tdep.c (producer.h): Add new include.
6376 * dwarf2read.c (producer.h): Add new include.
6377 * producer.c: New file.
6378 * producer.h: New file.
6379 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
6380 producer.c.
6381 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
6382 producer.h.
6383
5007d765
MK
63842017-09-26 Matthias Klose <doko@ubuntu.com>
6385
6386 * configure.ac: Search ncursesw before ncurses.
6387 Check ncursesw/ncurses.h before ncurses/ncurses.h.
6388 * gdb_curses.h: Include <ncursesw/ncurses.h>
6389 * config.in, configure: Regenerate.
6390
281c4447
RO
63912017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6392
6393 PR gdb/22185
6394 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
6395 obsolete.
6396 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
6397 Remove i386sol2 support.
6398 * configure.nat <i386sol2>: Remove.
6399 <sol2-64>: Fold into ...
6400 <sol2>: ... this.
6401 Move common settings to default section.
6402 Add sol-thread.o.
6403 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
6404 x86_64-*-solaris2.1[0-9]*>: Rename to ...
6405 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
6406 <i[34567]86-*-solaris*>: Remove.
6407 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
6408
6409 * configure.ac: Remove wctype in libw check.
6410 (_MSE_INT_H): Don't define on Solaris 7-9.
6411 <solaris*>: Remove libthread_db.so.1 check.
6412 * configure: Regenerate.
6413 * config.in: Regenerate.
6414
6415 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
6416 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
6417 (gdb_ps_size_t): Remove.
6418 Use base types in users.
6419 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
6420
6421 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
6422
39b06c20
RO
64232017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6424
6425 PR build/22206
6426 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
6427 (adi_is_addr_mapped): Likewise.
6428 (PSR_ICC): Don't redefine.
6429 (PSR_IMPL): Likewise.
6430
6c3e20f1
TT
64312017-09-25 Tom Tromey <tom@tromey.com>
6432
6433 * regcache.c (regcache::dump): Use string_printf.
6434
b292235f
TT
64352017-09-25 Tom Tromey <tom@tromey.com>
6436
6437 * regcache.c (class regcache_invalidator): New.
6438 (struct register_to_invalidate): Remove.
6439 (make_cleanup_regcache_invalidate): Remove.
6440 (regcache::raw_write): Use regcache_invalidator.
6441
9ac86b52
TT
64422017-09-25 Tom Tromey <tom@tromey.com>
6443
6444 * spu-tdep.c (spu2ppu_sniffer): Update.
6445 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
6446 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
6447 Remove.
6448 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
6449 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
6450 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
6451 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
6452 (frame_pop): Update.
6453
c0e383c6
TT
64542017-09-25 Tom Tromey <tom@tromey.com>
6455
6456 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
6457 * regcache.h (regcache_xfree): Don't declare.
6458 * regcache.c (regcache_xfree): Remove.
6459 (do_regcache_xfree): Use delete.
6460 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
6461 * linux-fork.c (free_fork): Use delete.
6462 (fork_save_infrun_state): Likewise.
6463 * jit.c (jit_dealloc_cache): Use delete.
6464 * infrun.c (discard_infcall_suspend_state): Use delete.
6465
791199cc
TT
64662017-09-25 Tom Tromey <tom@tromey.com>
6467
6468 * regcache.h (regcache_xmalloc): Don't declare.
6469 (regcache_raw_set_cached_value): Update comment.
6470 * regcache.c (regcache_xmalloc): Remove.
6471 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
6472 * jit.c (jit_frame_sniffer): Use new.
6473 * frame.c (frame_save_as_regcache): Use new.
6474
289e23aa
AA
64752017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6476
6477 * NEWS: Advertise support for guarded-storage registers on IBM z.
6478
1b63490c
AA
64792017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6480
6481 * s390-linux-nat.c (have_regset_gs): New static variable.
6482 (s390_linux_fetch_inferior_registers): Handle guarded-storage
6483 control block and guarded-storage broadcast control regsets.
6484 (s390_read_description): Detect whether the target has
6485 guarded-storage support, return appropriate tdesc.
6486 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
6487 (features/s390x-gs-linux64.c): Likewise.
6488 (struct gdbarch_tdep) <have_gs>: New field.
6489 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
6490 (s390_gsbc_regset): New variables.
6491 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
6492 and s390_gsbc_regset, if applicable.
6493 (s390_core_read_description): Check whether core file was from a
6494 target with guarded-storage support; include appropriate regsets.
6495 (s390_gdbarch_init): Add registers for guarded-storage support.
6496 (_initialize_s390_tdep): Initialize new target descriptions that
6497 include registers for guarded-storage support.
6498 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
6499 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
6500 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
6501 (S390_NUM_REGS): Adjust macro definition.
6502 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
6503 (tdesc_s390x_gs_linux64): New declarations.
6504
96235dc1
AA
65052017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6506
6507 * features/s390-gs-linux64.xml: New file.
6508 * features/s390-gs.xml: New file.
6509 * features/s390-gsbc.xml: New file.
6510 * features/s390x-gs-linux64.xml: New file.
6511 * features/Makefile (WHICH): Add s390-gs-linux64 and
6512 s390x-gs-linux64.
6513 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
6514 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
6515 * features/s390-gs-linux64.c: New generated file.
6516 * features/s390x-gs-linux64.c: New file.
6517 * regformats/s390-gs-linux64.dat: New file.
6518 * regformats/s390x-gs-linux64.dat: New file.
6519
b4a7c699
TT
65202017-09-23 Tom Tromey <tom@tromey.com>
6521
6522 * defs.h (make_cleanup_override_quit_handler): Don't declare.
6523
c2f97536
TT
65242017-09-22 Tom Tromey <tom@tromey.com>
6525
6526 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
6527 type to scoped_restore_tmpl.
6528 <scoped_input_handler>: Initialize m_quit_handler directly.
6529
43573013
SDJ
65302017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6531
6532 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
6533 (cd_command): Likewise. Free "current_directory" before
6534 assigning to it.
6535 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
6536 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
6537 * top.c (gdb_dirbuf): Remove global declaration.
6538 * top.h (gdb_dirbuf): Likewise.
6539
6ec2e0f5
SDJ
65402017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6541
6542 * gnulib/aclocal.m4: Regenerate.
6543 * gnulib/config.in: Regenerate.
6544 * gnulib/configure: Regenerate.
6545 * gnulib/import/Makefile.am: Regenerate.
6546 * gnulib/import/Makefile.in: Regenerate.
6547 * gnulib/import/assure.h: New file.
6548 * gnulib/import/at-func.c: Likewise
6549 * gnulib/import/chdir-long.c: New file.
6550 * gnulib/import/chdir-long.h: New file.
6551 * gnulib/import/cloexec.c: New file.
6552 * gnulib/import/cloexec.h: New file.
6553 * gnulib/import/close.c: New file.
6554 * gnulib/import/closedir.c: New file.
6555 * gnulib/import/dirent-private.h: New file.
6556 * gnulib/import/dup-safer.c: New file.
6557 * gnulib/import/dup.c: New file.
6558 * gnulib/import/dup2.c: New file.
6559 * gnulib/import/error.c: New file.
6560 * gnulib/import/error.h: New file.
6561 * gnulib/import/exitfail.c: New file.
6562 * gnulib/import/exitfail.h: New file.
6563 * gnulib/import/fchdir.c: New file.
6564 * gnulib/import/fcntl.c: New file.
6565 * gnulib/import/fcntl.in.h: New file.
6566 * gnulib/import/fd-hook.c: New file.
6567 * gnulib/import/fd-hook.h: New file.
6568 * gnulib/import/fd-safer.c: New file.
6569 * gnulib/import/fdopendir.c: New file.
6570 * gnulib/import/filename.h: New file.
6571 * gnulib/import/filenamecat-lgpl.c: New file.
6572 * gnulib/import/filenamecat.h: New file.
6573 * gnulib/import/fstat.c: New file.
6574 * gnulib/import/fstatat.c: New file.
6575 * gnulib/import/getcwd-lgpl.c: New file.
6576 * gnulib/import/getcwd.c: New file.
6577 * gnulib/import/getdtablesize.c: New file.
6578 * gnulib/import/getlogin_r.c: New file.
6579 * gnulib/import/getprogname.c: New file.
6580 * gnulib/import/getprogname.h: New file.
6581 * gnulib/import/gettext.h: New file.
6582 * gnulib/import/glob-libc.h: New file.
6583 * gnulib/import/glob.c: New file.
6584 * gnulib/import/glob.in.h: New file.
6585 * gnulib/import/intprops.h: New file.
6586 * gnulib/import/m4/chdir-long.m4: New file.
6587 * gnulib/import/m4/close.m4: New file.
6588 * gnulib/import/m4/closedir.m4: New file.
6589 * gnulib/import/m4/d-ino.m4: New file.
6590 * gnulib/import/m4/d-type.m4: New file.
6591 * gnulib/import/m4/dup.m4: New file.
6592 * gnulib/import/m4/dup2.m4: New file.
6593 * gnulib/import/m4/error.m4: New file.
6594 * gnulib/import/m4/fchdir.m4: New file.
6595 * gnulib/import/m4/fcntl.m4: New file.
6596 * gnulib/import/m4/fcntl_h.m4: New file.
6597 * gnulib/import/m4/fdopendir.m4: New file.
6598 * gnulib/import/m4/filenamecat.m4: New file.
6599 * gnulib/import/m4/fstat.m4: New file.
6600 * gnulib/import/m4/fstatat.m4: New file.
6601 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
6602 * gnulib/import/m4/getcwd-path-max.m4: New file.
6603 * gnulib/import/m4/getcwd.m4: New file.
6604 * gnulib/import/m4/getdtablesize.m4: New file.
6605 * gnulib/import/m4/getlogin_r.m4: New file.
6606 * gnulib/import/m4/getprogname.m4: New file.
6607 * gnulib/import/m4/glob.m4: New file.
6608 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
6609 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
6610 * gnulib/import/m4/mempcpy.m4: New file.
6611 * gnulib/import/m4/memrchr.m4: New file.
6612 * gnulib/import/m4/mode_t.m4: New file.
6613 * gnulib/import/m4/msvc-inval.m4: New file.
6614 * gnulib/import/m4/msvc-nothrow.m4: New file.
6615 * gnulib/import/m4/open.m4: New file.
6616 * gnulib/import/m4/openat.m4: New file.
6617 * gnulib/import/m4/opendir.m4: New file.
6618 * gnulib/import/m4/readdir.m4: New file.
6619 * gnulib/import/m4/realloc.m4: New file.
6620 * gnulib/import/m4/rewinddir.m4: New file.
6621 * gnulib/import/m4/save-cwd.m4: New file.
6622 * gnulib/import/m4/strdup.m4: New file.
6623 * gnulib/import/m4/strerror.m4: New file.
6624 * gnulib/import/m4/unistd-safer.m4: New file.
6625 * gnulib/import/mempcpy.c: New file.
6626 * gnulib/import/memrchr.c: New file.
6627 * gnulib/import/msvc-inval.c: New file.
6628 * gnulib/import/msvc-inval.h: New file.
6629 * gnulib/import/msvc-nothrow.c: New file.
6630 * gnulib/import/msvc-nothrow.h: New file.
6631 * gnulib/import/open.c: New file.
6632 * gnulib/import/openat-die.c: New file.
6633 * gnulib/import/openat-priv.h: New file.
6634 * gnulib/import/openat-proc.c: New file.
6635 * gnulib/import/openat.c: New file.
6636 * gnulib/import/openat.h: New file.
6637 * gnulib/import/opendir.c: New file.
6638 * gnulib/import/pipe-safer.c: New file.
6639 * gnulib/import/readdir.c: New file.
6640 * gnulib/import/realloc.c: New file.
6641 * gnulib/import/rewinddir.c: New file.
6642 * gnulib/import/save-cwd.c: New file.
6643 * gnulib/import/save-cwd.h: New file.
6644 * gnulib/import/strdup.c: New file.
6645 * gnulib/import/strerror-override.c: New file.
6646 * gnulib/import/strerror-override.h: New file.
6647 * gnulib/import/strerror.c: New file.
6648 * gnulib/import/unistd--.h: New file.
6649 * gnulib/import/unistd-safer.h: New file.
6650 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
6651 "getcwd" and "glob".
6652 * ser-tcp.c: Undefine "close" before redefining it.
6653
432ae719
SM
66542017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6655
6656 * guile/scm-value.c (gdbscm_value_address): Initialize address,
6657 get rid of res_val.
6658
4fa7574e
RO
66592017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6660
6661 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
6662 <sol2,sparc>: Likewise.
6663 <sol2-64,i386>: Likewise.
6664
6665 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
6666 -Wdeprecated-declarations on *-*-solaris*.
6667 * configure: Regenerate.
6668
6669 * procfs.c: Include "nat/inferior.h".
6670 (procfs_info_proc): Fix typo.
6671
f6327dcb
KB
66722017-09-21 Kevin Buettner <kevinb@redhat.com>
6673
6674 * remote.c (vector): Include.
6675 (struct private_thread_info): Add field, thread_handle.
6676 (free_private_thread_info): Deallocate storage associated with
6677 thread handle.
6678 (get_private_info_thread): Initialize `thread_handle' field.
6679 (struct thread_item): Add field, thread_handle.
6680 (clear_threads_listing_context): Deallocate storage associated
6681 with thread handle.
6682 (start_thread): Add support for "handle" attribute.
6683 (thread_attributes): Add "handle".
6684 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
6685 field.
6686 (remote_update_thread_list): Update thread_handle.
6687 (remote_thread_handle_to_thread_info): New function.
6688 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
6689
fbbe5337
KB
66902017-09-21 Kevin Buettner <kevinb@redhat.com>
6691
6692 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
6693 function.
6694 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
6695 * python/python-internal.h (thread_object_type): Declare.
6696
e04ee09e
KB
66972017-09-21 Kevin Buettner <kevinb@redhat.com>
6698
6699 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
6700 (target_thread_handle_to_thread_info): Declare.
6701 * target.c (target_thread_handle_to_thread_info): New function.
6702 * target-delegates.c: Regenerate.
6703 * gdbthread.h (find_thread_by_handle): Declare.
6704 * thread.c (find_thread_by_handle): New function.
6705 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
6706 function.
6707 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
6708
1e5b66ed
SM
67092017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6710
6711 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
6712
ebe48ba0
SM
67132017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6714
6715 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
6716
0a0bf5dc
YQ
67172017-09-21 Yao Qi <yao.qi@linaro.org>
6718
6719 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
6720 to gdb_target_obs.
6721
d1b0a7bf
TT
67222017-09-20 Tom Tromey <tom@tromey.com>
6723
6724 * breakpoint.c (struct counted_command_line): Remove.
6725 (breakpoint_commands): Update.
6726 (alloc_counted_command_line, incref_counted_command_line)
6727 (decref_counted_command_line, do_cleanup_counted_command_line)
6728 (make_cleanup_decref_counted_command_line): Remove.
6729 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
6730 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
6731 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
6732 (save_breakpoints): Update.
6733 * breakpoint.h (counted_command_line): Now a typedef to
6734 shared_ptr.
6735 (struct breakpoint) <commands>: Now a counted_command_line.
6736 (struct bpstats) <command>: Likewise.
6737
48649e1b
TT
67382017-09-20 Tom Tromey <tom@tromey.com>
6739
6740 * breakpoint.c (struct commands_info, do_map_commands_command):
6741 Remove.
6742 (commands_command_1): Update.
6743 (iterate_over_related_breakpoints): Take a function_view.
6744 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
6745 (delete_command): Update.
6746 (map_breakpoint_numbers): Take a function_view.
6747 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
6748 (disable_command): Update.
6749 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
6750 (enable_command): Update.
6751 (struct disp_data, do_enable_breakpoint_disp)
6752 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
6753 (do_map_enable_delete_breakpoint): Remove.
6754 (enable_once_command, enable_count_command, enable_delete_command)
6755 (delete_trace_variable_command): Update.
6756
04afa70c
TT
67572017-09-20 Tom Tromey <tom@tromey.com>
6758
6759 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
6760 (bpstat_clear): Use delete.
6761 (bpstats): New constructors.
6762 (bpstat_copy, bpstat_stop_status): Use new.
6763 (dprintf_after_condition_true): Update.
6764 * breakpoint.h (bpstats::bpstats): Add constructors.
6765 (bpstats::~bpstats): Add destructor.
6766
c83833f4
PA
67672017-09-20 Pedro Alves <palves@redhat.com>
6768
6769 * eval.c (make_params): Delete, refactored as ...
6770 (class fake_method): ... this new type's ctor.
6771 (fake_method::~fake_method): New.
6772 (evaluate_subexp_standard): Use 'fake_method'.
6773
223ffa71
TT
67742017-09-20 Tom Tromey <tom@tromey.com>
6775
6776 * windows-nat.c (get_windows_debug_event, windows_wait)
6777 (do_initial_windows_stuff, windows_attach): Update.
6778 * utils.c (vwarning, internal_vproblem): Update.
6779 (ui_unregister_input_event_handler_cleanup)
6780 (prepare_to_handle_input): Remove.
6781 (class scoped_input_handler): New.
6782 (defaulted_query, prompt_for_continue): Update.
6783 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
6784 Update.
6785 * top.c (undo_terminal_modifications_before_exit): Update.
6786 * target/target.h (target_terminal_init, target_terminal_inferior)
6787 (target_terminal_ours): Don't declare.
6788 (class target_terminal): New.
6789 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
6790 (target_terminal_ours_for_output)
6791 (make_cleanup_restore_target_terminal): Don't declare.
6792 (target_terminal_info): Remove.
6793 * target.c (enum terminal_state, terminal_state): Remove.
6794 (target_terminal::terminal_state): Define.
6795 (target_terminal::init): Rename from target_terminal_init.
6796 (target_terminal::inferior): Rename from
6797 target_terminal_inferior.
6798 (target_terminal::ours): Rename from target_terminal_ours.
6799 (target_terminal::ours_for_output): Rename from
6800 target_terminal_ours_for_output.
6801 (target_terminal::info): New method.
6802 (cleanup_restore_target_terminal)
6803 (make_cleanup_restore_target_terminal): Remove.
6804 * solib.c (handle_solib_event): Update.
6805 * remote.c (remote_serial_quit_handler): Update.
6806 (remote_terminal_inferior, remote_wait_as): Update.
6807 * record-full.c (record_full_wait_1): Update.
6808 * nto-procfs.c (procfs_create_inferior): Update.
6809 * nat/fork-inferior.c (startup_inferior): Update.
6810 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
6811 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
6812 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
6813 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
6814 (mi_breakpoint_created, mi_breakpoint_deleted)
6815 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
6816 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6817 (mi_user_selected_context_changed, report_initial_inferior):
6818 Update.
6819 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
6820 (linux_nat_terminal_inferior): Update.
6821 * infrun.c (follow_fork_inferior)
6822 (handle_vfork_child_exec_or_exit, do_target_resume)
6823 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
6824 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
6825 Update.
6826 * inflow.c (child_terminal_init, info_terminal_command): Update.
6827 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
6828 (attach_command): Update.
6829 * infcall.c (call_thread_fsm_should_stop): Update.
6830 * gnu-nat.c (gnu_attach): Update.
6831 * extension.c (struct active_ext_lang_state)
6832 (restore_active_ext_lang): Update.
6833 * exceptions.c (print_flush): Update.
6834 * event-top.c (async_enable_stdin, default_quit_handler): Update.
6835 (struct quit_handler_cleanup_data, restore_quit_handler)
6836 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
6837 Remove.
6838 * cp-support.c (gdb_demangle): Update.
6839 * breakpoint.c (update_inserted_breakpoint_locations)
6840 (insert_breakpoint_locations, handle_jit_event)
6841 (disable_breakpoints_in_unloaded_shlib): Update.
6842 * annotate.c (annotate_breakpoints_invalid)
6843 (annotate_frames_invalid): Update.
6844
013af3fc
TT
68452017-09-20 Tom Tromey <tom@tromey.com>
6846
6847 * main.c (catch_command_errors): Rename from
6848 catch_command_errors_const.
6849 (captured_main_1): Update.
6850
06871ae8
PA
68512017-09-20 Pedro Alves <palves@redhat.com>
6852
6853 * cli/cli-cmds.c (list_command): Use print_sal_location.
6854 (print_sal_location): New function.
6855 (ambiguous_line_spec): Use print_sal_location.
6856 * linespec.c (symbol_to_sal): Record the symbol in the sal.
6857 * symtab.c (find_function_start_sal): Likewise.
6858 * symtab.h (symtab_and_line::symbol): New field.
6859
e5f25bc5
PA
68602017-09-20 Pedro Alves <palves@redhat.com>
6861
6862 * linespec.c (minsym_found): Handle non-text minsyms.
6863 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
6864
1b7fa39e
WT
68652017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6866
6867 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
6868 backslash.
6869
37dd0825
WT
68702017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6871
6872 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
6873 vmovups instead vmovaps.
6874 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
6875
4e5a4f58
JB
68762017-09-19 John Baldwin <jhb@FreeBSD.org>
6877
6878 * NEWS (Changes since GDB 8.0): Add starti.
6879 * infcmd.c (enum run_break): New.
6880 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
6881 case.
6882 (run_command): Use enum run_how.
6883 (start_command): Likewise.
6884 (starti_command): New function.
6885 (RUN_ARGS_HELP): New macro.
6886 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
6887 commands. Add starti command.
6888
aa70c9f1
YQ
68892017-09-19 Yao Qi <yao.qi@linaro.org>
6890
6891 * Makefile.in (monitor.o): Remove the rule.
6892
d6541620
YQ
68932017-09-19 Yao Qi <yao.qi@linaro.org>
6894
6895 * annotate.h (struct annotate_arg_emitter): Use
6896 DISABLE_COPY_AND_ASSIGN.
6897 * common/refcounted-object.h (refcounted_object): Likewise.
6898 * completer.h (struct completion_result): Likewise.
6899 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
6900 * filename-seen-cache.h (filename_seen_cache): Likewise.
6901 * gdbcore.h (thread_section_name): Likewise.
6902 * gdb_regex.h (compiled_regex): Likewise.
6903 * gdbthread.h (scoped_restore_current_thread): Likewise.
6904 * inferior.h (scoped_restore_current_inferior): Likewise.
6905 * jit.c (jit_reader): Likewise.
6906 * linespec.h (struct linespec_result): Likewise.
6907 * mi/mi-parse.h (struct mi_parse): Likewise.
6908 * nat/fork-inferior.c (execv_argv): Likewise.
6909 * progspace.h (scoped_restore_current_program_space): Likewise.
6910 * python/python-internal.h (class gdbpy_enter): Likewise.
6911 * regcache.h (regcache): Likewise.
6912 * target-descriptions.c (struct tdesc_reg): Likewise.
6913 (struct tdesc_type): Likewise.
6914 (struct tdesc_feature): Likewise.
6915 * ui-out.h (ui_out_emit_type): Likewise.
6916
0615127c
SM
69172017-09-18 Simon Marchi <simon.marchi@ericsson.com>
6918
6919 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
6920 label abort_expression.
6921
5e187554
SM
69222017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6923
6924 * common/buffer.c (buffer_xml_printf): Adjust.
6925 * common/xml-utils.c (xml_escape_text): Change return type to
6926 std::string, update code accordingly.
6927 * common/xml-utils.h (xml_escape_text): Change return type to
6928 std::string.
6929 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
6930 * windows-tdep.c (windows_xfer_shared_library): Adjust.
6931 * unittests/xml-utils-selftests.c (test_xml_escape_text):
6932 Adjust.
6933
c3d7b541
SM
69342017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6935
6936 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
6937 (SUBDIR_UNITTESTS_OBS): Add new object file.
6938 * unittests/xml-utils-selftests.c: New file.
6939
1526853e
SM
69402017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6941
6942 * common/selftest.h (selftest): New struct/interface.
6943 (register_test): Add name parameter, add new overload.
6944 (run_tests): Add filter parameter.
6945 (for_each_selftest_ftype): New typedef.
6946 (for_each_selftest): New declaration.
6947 * common/selftest.c (tests): Change type to
6948 map<string, unique_ptr<selftest>>.
6949 (simple_selftest): New struct.
6950 (register_test): New function.
6951 (register_test): Add name parameter and use it.
6952 (run_tests): Add filter parameter and use it. Add prints.
6953 Adjust to vector -> map change.
6954 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
6955 registering selftests.
6956 * arm-tdep.c (_initialize_arm_tdep): Likewise.
6957 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
6958 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
6959 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
6960 * findvar.c (_initialize_findvar): Likewise.
6961 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
6962 * maint.c (maintenance_selftest): Update call to run_tests.
6963 (maintenance_info_selftests): New function.
6964 (_initialize_maint_cmds): Register "maintenance info selftests"
6965 command. Update "maintenance selftest" doc.
6966 * regcache.c (_initialize_regcache): Add names when registering
6967 selftests.
6968 * rust-exp.y (_initialize_rust_exp): Likewise.
6969 * selftest-arch.c (gdbarch_selftest): New struct.
6970 (gdbarch_tests): Remove.
6971 (register_test_foreach_arch): Add name parameter. Call
6972 register_test.
6973 (tests_with_arch): Remove, move most content to
6974 gdbarch_selftest::operator().
6975 (_initialize_selftests_foreach_arch): Remove.
6976 * selftest-arch.h (register_test_foreach_arch): Add name
6977 parameter.
6978 (run_tests_with_arch): New declaration.
6979 * utils-selftests.c (_initialize_utils_selftests): Add names
6980 when registering selftests.
6981 * utils.c (_initialize_utils): Likewise.
6982 * unittests/array-view-selftests.c
6983 (_initialize_array_view_selftests): Likewise.
6984 * unittests/environ-selftests.c (_initialize_environ_selftests):
6985 Likewise.
6986 * unittests/function-view-selftests.c
6987 (_initialize_function_view_selftests): Likewise.
6988 * unittests/offset-type-selftests.c
6989 (_initialize_offset_type_selftests): Likewise.
6990 * unittests/optional-selftests.c
6991 (_initialize_optional_selftests): Likewise.
6992 * unittests/scoped_restore-selftests.c
6993 (_initialize_scoped_restore_selftests): Likewise.
6994 * NEWS: Document "maintenance selftest" and "maint info
6995 selftests".
6996
5846367a
SM
69972017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6998
6999 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
7000 scoped_restore.
7001
bd77e8ff
SM
70022017-09-16 Simon Marchi <simon.marchi@ericsson.com>
7003
7004 * mi/mi-main.c (mi_load_progress): Make uiout variable
7005 a unique_ptr.
7006
26a67918
PA
70072017-09-15 Pedro Alves <palves@redhat.com>
7008
7009 * compile/compile-c-types.c (convert_enum, convert_int)
7010 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
7011
3f8a7804
SM
70122017-09-15 Simon Marchi <simon.marchi@ericsson.com>
7013
7014 * dwarf2read.c (copy_string): Remove.
7015 (parse_macro_definition): Replace copy_string with savestring.
7016
8d200706
YQ
70172017-09-15 Yao Qi <yao.qi@linaro.org>
7018
7019 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
7020 gdb_target_obs.
7021 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
7022 Likewise.
7023 (i[34567]86-*-linux*): Likewise.
7024
d185219d
SM
70252017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7026
7027 * dwarf2expr.h (dwarf_stack_value): Add constructor.
7028 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
7029 <stack>: Change type to std::vector.
7030 <stack_len, stack_allocated>: Remove.
7031 <grow_stack>: Remove.
7032 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7033 (dwarf_expr_context::~dwarf_expr_context): Remove.
7034 (dwarf_expr_context::grow_stack): Remove.
7035 (dwarf_expr_context::push): Adjust.
7036 (dwarf_expr_context::pop): Adjust.
7037 (dwarf_expr_context::fetch): Adjust.
7038 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
7039 (dwarf_expr_context::stack_empty_p): Adjust.
7040 (dwarf_expr_context::execute_stack_op): Adjust.
7041
eccd80d6
SM
70422017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7043
7044 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
7045 return type to bool.
7046 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
7047
69009882
SM
70482017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7049
7050 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
7051 Change type to bool.
7052 (dwarf_stack_value) <in_stack_memory>: Likewise.
7053 (dwarf_expr_context) <push_address>: Change parameter type to
7054 bool.
7055 <fetch_in_stack_memory>: Change return type to bool.
7056 <push>: Change parameter type to bool.
7057 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
7058 to bool.
7059 (dwarf_expr_context::push_address): Likewise.
7060 (dwarf_expr_context::fetch_in_stack_memory): Change return type
7061 to bool.
7062 (dwarf_expr_context::execute_stack_op): Adjust.
7063 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
7064
1e467161
SM
70652017-09-14 Simon Marchi <simon.marchi@ericsson.com>
7066
7067 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
7068 (struct dwarf_expr_context) <n_pieces>: Remove.
7069 <pieces>: Change type to std::vector.
7070 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
7071 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
7072 pieces.
7073 (dwarf_expr_context::add_piece): Adjust.
7074 * dwarf2loc.c (struct piece_closure): Initialize fields.
7075 <n_pieces>: Remove.
7076 <pieces>: Change type to std::vector.
7077 (allocate_piece_closure): Adjust, change parameter to
7078 std::vector rvalue and std::move it to piece_closure.
7079 (rw_pieced_value): Adjust.
7080 (check_pieced_synthetic_pointer): Adjust.
7081 (indirect_synthetic_pointer): Adjust.
7082 (coerce_pieced_ref): Adjust.
7083 (free_pieced_value_closure): Adjust. Use delete to free
7084 piece_closure.
7085 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
7086 to allocate_piece_closure.
7087 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
7088
0782db84
SM
70892017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7090
7091 * probe.h (probe_ops_cp): Remove typedef.
7092 (DEF_VEC_P (probe_ops_cp)): Remove.
7093 (all_probe_ops): Change type to std::vector.
7094 * probe.c (info_probes_for_ops): Adjust to vector change.
7095 (probe_linespec_to_ops): Likewise.
7096 (all_probe_ops): Change type to std::vector.
7097 (_initialize_probe): Adjust to vector change.
7098 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
7099 * elfread.c (elf_get_probes): Likewise.
7100 * stap-probe.c (_initialize_stap_probe): Likewise.
7101
1eac6bea
SM
71022017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7103
7104 * probe.h (struct bound_probe): Define constructors.
7105 * probe.c (bound_probe_s): Remove typedef.
7106 (DEF_VEC_O (bound_probe_s)): Remove VEC.
7107 (collect_probes): Change return type to std::vector, remove
7108 cleanup.
7109 (compare_probes): Return bool, change parameter type. Change
7110 semantic to "less than".
7111 (gen_ui_out_table_header_info): Change parameter to std::vector
7112 and update.
7113 (exists_probe_with_pops): Likewise.
7114 (info_probes_for_ops): Update to std::vector change.
7115 (enable_probes_command): Likewise.
7116 (disable_probes_command): Likewise.
7117
aaa63a31
SM
71182017-09-12 Simon Marchi <simon.marchi@ericsson.com>
7119
7120 * probe.h (struct probe_ops) <get_probes>: Change parameter from
7121 vec to std::vector.
7122 * probe.c (parse_probes_in_pspace): Update.
7123 (find_probes_in_objfile): Update.
7124 (find_probe_by_pc): Update.
7125 (collect_probes): Update.
7126 (probe_any_get_probes): Update.
7127 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
7128 return type to reference to std::vector.
7129 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
7130 std::vector and update.
7131 (dtrace_process_dof): Likewise.
7132 (dtrace_get_probes): Likewise.
7133 * elfread.c (elf_get_probes): Change return type to std::vector,
7134 store an std::vector in bfd_data.
7135 (probe_key_free): Update to std::vector.
7136 * stap-probe.c (handle_stap_probe): Change parameter to
7137 std::vector and update.
7138 (stap_get_probes): Likewise.
7139 * symfile-debug.c (debug_sym_get_probes): Change return type to
7140 std::vector and update.
7141
cb85b21b
TT
71422017-09-11 Tom Tromey <tom@tromey.com>
7143
7144 * breakpoint.c (program_breakpoint_here_p): Update.
7145 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
7146 from make_show_memory_breakpoints_cleanup. Return a
7147 scoped_restore_tmpl<int>.
7148 (restore_show_memory_breakpoints): Remove.
7149 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
7150 * mem-break.c (memory_validate_breakpoint): Update.
7151 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
7152 (ia64_memory_remove_breakpoint): Update.
7153 (ia64_breakpoint_from_pc): Update.
7154 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
7155 from make_show_memory_breakpoints_cleanup.
7156
8fbc99ef
TT
71572017-09-11 Tom Tromey <tom@tromey.com>
7158
7159 * d-namespace.c (d_lookup_symbol): Use std::string.
7160 (find_symbol_in_baseclass): Likewise.
7161
50feb4bd
TT
71622017-09-11 Tom Tromey <tom@tromey.com>
7163
7164 * ctf.c (ctf_start): Use std::string.
7165
c6dc63a1
TT
71662017-09-11 Tom Tromey <tom@tromey.com>
7167
7168 * ada-lang.c (is_known_support_routine): Update.
7169 (ada_unhandled_exception_name_addr_from_raise): Update.
7170 * guile/scm-frame.c (gdbscm_frame_name): Update.
7171 * python/py-frame.c (frapy_name): Update.
7172 (frapy_function): Update.
7173 * stack.h (find_frame_funname): Update.
7174 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
7175 (print_frame): Update.
7176
d6b9b80f
TT
71772017-09-11 Tom Tromey <tom@tromey.com>
7178
7179 * findcmd.c (put_bits): Take a gdb::byte_vector.
7180 (parse_find_args): Return gdb::byte_vector. "args" now const.
7181 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
7182 cleanups.
7183 (find_command): Update.
7184
a9921622
TT
71852017-09-11 Tom Tromey <tom@tromey.com>
7186
7187 * cli/cli-script.c (class scoped_restore_hook_in): New.
7188 (clear_hook_in_cleanup): Remove.
7189 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
7190 scoped_restore_hook_in.
7191
be0d7abb
TT
71922017-09-11 Tom Tromey <tom@tromey.com>
7193
7194 * cli/cli-script.c (restore_interp): Remove.
7195 (read_command_lines): Use scoped_restore_interp.
7196 * interps.c (scoped_restore_interp::set_temp): Rename from
7197 interp_set_temp.
7198 * interps.h (class scoped_restore_interp): New.
7199 (interp_set_temp): Remove.
7200
00f675ff
TT
72012017-09-11 Tom Tromey <tom@tromey.com>
7202
7203 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
7204 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
7205 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
7206 scoped_restore.
7207 (mi_cmd_break_insert_1): Update.
7208 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
7209 scoped_restore.
7210
cb791d59
TT
72112017-09-11 Tom Tromey <tom@tromey.com>
7212
7213 * demangle.c (demangle_command): Update.
7214 * breakpoint.c (disable_command): Update.
7215 (enable_command): Update.
7216 (find_location_by_number): Make "number" const. Use
7217 get_number_trailer.
7218 * cli/cli-utils.c (extract_arg): Return std::string.
7219 * probe.c (parse_probe_linespec): Update. Change types.
7220 (collect_probes): Take string arguments.
7221 (parse_probe_linespec): Likewise.
7222 (info_probes_for_ops): Update.
7223 (enable_probes_command): Update.
7224 (disable_probes_command): Update.
7225 * break-catch-sig.c (catch_signal_split_args): Update.
7226 * mi/mi-parse.c (mi_parse): Update.
7227
2039bd9f
TT
72282017-09-11 Tom Tromey <tom@tromey.com>
7229
7230 * language.h (language_enum): Make argument const.
7231 * language.c (language_enum): Make argument const.
7232
f1735a53
TT
72332017-09-11 Tom Tromey <tom@tromey.com>
7234
7235 * common/common-utils.h (skip_to_space): Remove macro, redeclare
7236 as function.
7237 (skip_to_space): Rename from skip_to_space_const.
7238 * common/common-utils.c (skip_to_space): New function.
7239 (skip_to_space): Rename from skip_to_space_const.
7240 * cli/cli-utils.h (get_number): Rename from get_number_const.
7241 (extract_arg): Rename from extract_arg_const.
7242 * cli/cli-utils.c (get_number): Rename from get_number_const.
7243 (extract_arg): Rename from extract_arg_const.
7244 (number_or_range_parser::get_number): Use ::get_number.
7245 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
7246 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
7247 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
7248 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
7249 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
7250 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
7251 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
7252 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
7253
7d221d74
TT
72542017-09-11 Tom Tromey <tom@tromey.com>
7255
7256 * python/python.c (do_start_initialization): Use
7257 py-event-types.def to initialize types.
7258 Define all object type structures.
7259 * python/python-internal.h: Don't declare event initialization
7260 functions.
7261 * python/py-threadevent.c (thread_event_object_type): Don't
7262 define.
7263 * python/py-stopevent.c (stop_event_object_type): Don't define.
7264 * python/py-signalevent.c (signal_event_object_type): Don't
7265 declare or define.
7266 * python/py-newobjfileevent.c (new_objfile_event_object_type)
7267 (clear_objfiles_event_object_type): Don't declare or define.
7268 * python/py-infevents.c (inferior_call_pre_event_object_type)
7269 (inferior_call_post_event_object_type)
7270 (register_changed_event_object_type)
7271 (memory_changed_event_object_type): Don't declare or define.
7272 * python/py-inferior.c (new_thread_event_object_type)
7273 (new_inferior_event_object_type)
7274 (inferior_deleted_event_object_type): Don't declare or define.
7275 * python/py-exitedevent.c (exited_event_object_type): Don't
7276 declare or define.
7277 * python/py-evts.c (gdbpy_initialize_py_events): Use
7278 py-all-events.def.
7279 * python/py-events.h (thread_event_object_type): Don't declare.
7280 (events_object): Use py-all-events.def.
7281 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
7282 py-event-types.def.
7283 * python/py-event-types.def: New file.
7284 * python/py-continueevent.c (create_continue_event_object): Don't
7285 declare or define.
7286 * python/py-bpevent.c (breakpoint_event_object_type): Don't
7287 declare or define.
7288 * python/py-all-events.def: New file.
7289
35c61a1d
TT
72902017-09-11 Tom Tromey <tom@tromey.com>
7291
7292 * python/py-threadevent.c (create_thread_event_object): Return
7293 gdbpy_ref.
7294 * python/py-stopevent.h (create_stop_event_object)
7295 (create_breakpoint_event_object, create_signal_event_object):
7296 Update.
7297 * python/py-stopevent.c (create_stop_event_object): Return
7298 gdbpy_ref.
7299 (emit_stop_event): Update.
7300 * python/py-signalevent.c (create_signal_event_object): Return
7301 gdbpy_ref.
7302 * python/py-infevents.c (create_inferior_call_event_object):
7303 Update.
7304 * python/py-event.h (create_event_object)
7305 (create_thread_event_object): Update.
7306 * python/py-event.c (create_event_object): Return gdbpy_ref.
7307 * python/py-continueevent.c: Return gdbpy_ref.
7308 * python/py-bpevent.c (create_breakpoint_event_object): Return
7309 gdbpy_ref.
7310
7c96f8c1
TT
73112017-09-11 Tom Tromey <tom@tromey.com>
7312
7313 PR python/15622:
7314 * NEWS: Add entry.
7315 * python/python.c (do_start_initialization): Initialize new event
7316 types.
7317 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
7318 (gdbpy_initialize_inferior_deleted_event)
7319 (gdbpy_initialize_new_thread_event): Declare.
7320 * python/py-threadevent.c (create_thread_event_object): Add option
7321 "thread" parameter.
7322 * python/py-inferior.c (new_thread_event_object_type)
7323 (new_inferior_event_object_type)
7324 (inferior_deleted_event_object_type): Declare.
7325 (python_new_inferior, python_inferior_deleted): New functions.
7326 (add_thread_object): Emit new_thread event.
7327 (gdbpy_initialize_inferior): Attach new functions to corresponding
7328 observers.
7329 (new_thread, new_inferior, inferior_deleted): Define new event
7330 types.
7331 * python/py-evts.c (gdbpy_initialize_py_events): Add new
7332 registries.
7333 * python/py-events.h (events_object) <new_inferior,
7334 inferior_deleted, new_thread>: New fields.
7335 * python/py-event.h (create_thread_event_breakpoint): Add optional
7336 "thread" parameter.
7337
72542b8e
AB
73382017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
7339
7340 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
7341 check current_ui instead.
7342 (internal_vproblem): Likewise.
7343
0d64823e
SM
73442017-09-09 Simon Marchi <simon.marchi@ericsson.com>
7345
7346 * thread.c (print_thread_info_1): Remove unnecessary calls to
7347 uiout->is_mi_like_p.
7348
eb1e02fd
TT
73492017-09-09 Tom Tromey <tom@tromey.com>
7350
7351 * namespace.h (add_using_directive): Update.
7352 * namespace.c (add_using_directive): Change type of excludes to
7353 std::vector.
7354 * dwarf2read.c (read_import_statement): Use std::vector.
7355 (read_namespace): Update.
7356 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
7357
0fc21fd8
TT
73582017-09-09 Tom Tromey <tom@tromey.com>
7359
7360 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
7361
49663d05
TT
73622017-09-09 Tom Tromey <tom@tromey.com>
7363
7364 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
7365
0b868b60
TT
73662017-09-09 Tom Tromey <tom@tromey.com>
7367
7368 * stack.c (func_command): Use gdb::def_vector.
7369
c0470d48
TT
73702017-09-09 Tom Tromey <tom@tromey.com>
7371
7372 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
7373 ui_out_emit_list, ui_out_emit_tuple.
7374 (mi_cmd_var_update): Likewise.
7375
ca5909c7
TT
73762017-09-09 Tom Tromey <tom@tromey.com>
7377
7378 * mi/mi-interp.c (mi_user_selected_context_changed): Use
7379 ui_out_redirect_pop.
7380 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7381 ui_out_redirect_pop.
7382 * utils.c (do_ui_out_redirect_pop)
7383 (make_cleanup_ui_out_redirect_pop): Remove.
7384 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
7385 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
7386 * ui-out.h (ui_out_redirect_pop): New class.
7387
e6a2252a
TT
73882017-09-09 Tom Tromey <tom@tromey.com>
7389
7390 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
7391 (list_available_thread_groups, mi_cmd_list_thread_groups)
7392 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
7393 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
7394 Likewise.
7395
393702cd
TT
73962017-09-09 Tom Tromey <tom@tromey.com>
7397
7398 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
7399 ui_out_emit_tuple.
7400
76f9c9cf
TT
74012017-09-09 Tom Tromey <tom@tromey.com>
7402
7403 * target.c (flash_erase_command): Use ui_out_emit_tuple.
7404 * stack.c (print_frame): Use ui_out_emit_tuple.
7405 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
7406 (info_spu_mailbox_command, info_spu_dma_command)
7407 (info_spu_proxydma_command): Likewise.
7408 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
7409 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
7410 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7411 ui_out_emit_tuple.
7412 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
7413
dc9fe180
TT
74142017-09-09 Tom Tromey <tom@tromey.com>
7415
7416 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
7417 (class ui_out_emit_table): Update comment.
7418 * ui-out.c (do_cleanup_table_end)
7419 (make_cleanup_ui_out_table_begin_end): Remove.
7420 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
7421 (info_spu_dma_cmdlist): Likewise.
7422 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
7423 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
7424 ui_out_emit_table.
7425
f8cc3da6
TT
74262017-09-09 Tom Tromey <tom@tromey.com>
7427
7428 * thread.c (print_thread_info_1): Use ui_out_emit_table,
7429 ui_out_emit_list, gdb::optional.
7430
481695ed
JB
74312017-09-09 John Baldwin <jhb@FreeBSD.org>
7432
7433 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
7434 prototype.
7435 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
7436 prototype.
7437 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
7438 prototype.
7439 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
7440 * ada-exp.y: Remove _initialize_ada_exp prototype.
7441 * ada-lang.c: Remove _initialize_ada_language prototype.
7442 * ada-tasks.c: Remove _initialize_tasks prototype.
7443 * addrmap.c: Remove _initialize_addrmap prototype.
7444 * agent.c: Remove _initialize_agent prototype.
7445 * aix-thread.c: Remove _initialize_aix_thread prototype.
7446 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
7447 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
7448 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
7449 prototype.
7450 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
7451 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
7452 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
7453 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
7454 prototype.
7455 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
7456 prototype.
7457 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
7458 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
7459 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
7460 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
7461 prototype.
7462 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
7463 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
7464 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
7465 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
7466 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7467 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
7468 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
7469 prototype.
7470 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
7471 prototype.
7472 * annotate.c: Remove _initialize_annotate prototype.
7473 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
7474 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
7475 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
7476 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
7477 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
7478 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
7479 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
7480 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
7481 prototype.
7482 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
7483 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
7484 * auto-load.c: Remove _initialize_auto_load prototype.
7485 * auxv.c: Remove _initialize_auxv prototype.
7486 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
7487 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
7488 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
7489 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
7490 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
7491 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
7492 prototype.
7493 * break-catch-throw.c: Remove _initialize_break_catch_throw
7494 prototype.
7495 * breakpoint.c: Remove _initialize_breakpoint prototype.
7496 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
7497 * btrace.c: Remove _initialize_btrace prototype.
7498 * charset.c: Remove _initialize_charset prototype.
7499 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
7500 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
7501 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
7502 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
7503 * cli/cli-script.c: Remove _initialize_cli_script prototype.
7504 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
7505 * coffread.c: Remove _initialize_coffread prototype.
7506 * compile/compile.c: Remove _initialize_compile prototype.
7507 * complaints.c: Remove _initialize_complaints prototype.
7508 * completer.c: Remove _initialize_completer prototype.
7509 * copying.awk: Remove _initialize_copying prototype.
7510 * copying.c: Regenerate.
7511 * core-regset.c: Remove _initialize_core_regset prototype.
7512 * corefile.c: Remove _initialize_core prototype.
7513 * corelow.c: Remove _initialize_corelow prototype.
7514 * cp-abi.c: Remove _initialize_cp_abi prototype.
7515 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
7516 * cp-support.c: Remove _initialize_cp_support prototype.
7517 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
7518 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
7519 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
7520 * ctf.c: Remove _initialize_ctf prototype.
7521 * d-lang.c: Remove _initialize_d_language prototype.
7522 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
7523 prototype.
7524 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
7525 * dbxread.c: Remove _initialize_dbxread prototype.
7526 * dcache.c: Remove _initialize_dcache prototype.
7527 * demangle.c: Remove _initialize_demangler prototype.
7528 * disasm-selftests.c: Remove _initialize_disasm_selftests
7529 prototype.
7530 * disasm.c: Remove _initialize_disasm prototype.
7531 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
7532 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
7533 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
7534 prototype.
7535 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
7536 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
7537 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
7538 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
7539 * elfread.c: Remove _initialize_elfread prototype.
7540 * exec.c: Remove _initialize_exec prototype.
7541 * extension.c: Remove _initialize_extension prototype.
7542 * f-lang.c: Remove _initialize_f_language prototype.
7543 * f-valprint.c: Remove _initialize_f_valprint prototype.
7544 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
7545 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
7546 * filesystem.c: Remove _initialize_filesystem prototype.
7547 * findcmd.c: Remove _initialize_mem_search prototype.
7548 * fork-child.c: Remove _initialize_fork_child prototype.
7549 * frame-base.c: Remove _initialize_frame_base prototype.
7550 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
7551 * frame.c: Remove _initialize_frame prototype.
7552 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
7553 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
7554 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
7555 * gcore.c: Remove _initialize_gcore prototype.
7556 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
7557 * gdbarch.c: Regenerate.
7558 * gdbarch.sh: Remove _initialize_gdbarch prototype.
7559 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
7560 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
7561 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
7562 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
7563 * go-lang.c: Remove _initialize_go_language prototype.
7564 * go32-nat.c: Remove _initialize_go32_nat prototype.
7565 * guile/guile.c: Remove _initialize_guile prototype.
7566 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
7567 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
7568 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
7569 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
7570 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
7571 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
7572 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
7573 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
7574 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
7575 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
7576 prototype.
7577 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
7578 prototype.
7579 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
7580 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
7581 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
7582 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
7583 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
7584 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
7585 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
7586 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
7587 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
7588 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
7589 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
7590 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
7591 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
7592 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7593 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
7594 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
7595 prototype.
7596 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
7597 prototype.
7598 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
7599 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
7600 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
7601 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
7602 * infcall.c: Remove _initialize_infcall prototype.
7603 * infcmd.c: Remove _initialize_infcmd prototype.
7604 * inferior.c: Remove _initialize_inferiors prototype.
7605 * inflow.c: Remove _initialize_inflow prototype.
7606 * infrun.c: Remove _initialize_infrun prototype.
7607 * interps.c: Remove _initialize_interpreter prototype.
7608 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
7609 * jit.c: Remove _initialize_jit prototype.
7610 * language.c: Remove _initialize_language prototype.
7611 * linux-fork.c: Remove _initialize_linux_fork prototype.
7612 * linux-nat.c: Remove _initialize_linux_nat prototype.
7613 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
7614 * linux-thread-db.c: Remove _initialize_thread_db prototype.
7615 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
7616 * m2-lang.c: Remove _initialize_m2_language prototype.
7617 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
7618 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
7619 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
7620 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
7621 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
7622 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7623 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7624 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
7625 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
7626 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
7627 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7628 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7629 * machoread.c: Remove _initialize_machoread prototype.
7630 * macrocmd.c: Remove _initialize_macrocmd prototype.
7631 * macroscope.c: Remove _initialize_macroscope prototype.
7632 * maint.c: Remove _initialize_maint_cmds prototype.
7633 * mdebugread.c: Remove _initialize_mdebugread prototype.
7634 * memattr.c: Remove _initialize_mem prototype.
7635 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
7636 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
7637 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
7638 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
7639 * mi/mi-main.c: Remove _initialize_mi_main prototype.
7640 * microblaze-linux-tdep.c: Remove
7641 _initialize_microblaze_linux_tdep prototype.
7642 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
7643 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
7644 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
7645 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
7646 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
7647 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
7648 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
7649 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
7650 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
7651 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
7652 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
7653 prototype.
7654 * mipsread.c: Remove _initialize_mipsread prototype.
7655 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
7656 prototype.
7657 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
7658 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
7659 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
7660 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
7661 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
7662 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
7663 prototype.
7664 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
7665 * nto-procfs.c: Remove _initialize_procfs prototype.
7666 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
7667 * objc-lang.c: Remove _initialize_objc_language prototype.
7668 * objfiles.c: Remove _initialize_objfiles prototype.
7669 * observer.c: Remove observer_test_first_notification_function,
7670 observer_test_second_notification_function,
7671 observer_test_third_notification_function, and
7672 _initialize_observer prototypes.
7673 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
7674 * osabi.c: Remove _initialize_gdb_osabi prototype.
7675 * osdata.c: Remove _initialize_osdata prototype.
7676 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
7677 * parse.c: Remove _initialize_parse prototype.
7678 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
7679 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
7680 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
7681 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
7682 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
7683 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
7684 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
7685 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
7686 * printcmd.c: Remove _initialize_printcmd prototype.
7687 * probe.c: Remove _initialize_probe prototype.
7688 * proc-api.c: Remove _initialize_proc_api prototype.
7689 * proc-events.c: Remove _initialize_proc_events prototype.
7690 * proc-service.c: Remove _initialize_proc_service prototype.
7691 * procfs.c: Remove _initialize_procfs prototype.
7692 * psymtab.c: Remove _initialize_psymtab prototype.
7693 * python/python.c: Remove _initialize_python prototype.
7694 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
7695 * record-btrace.c: Remove _initialize_record_btrace prototype.
7696 * record-full.c: Remove _initialize_record_full prototype.
7697 * record.c: Remove _initialize_record prototype.
7698 * regcache.c: Remove _initialize_regcache prototype.
7699 * reggroups.c: Remove _initialize_reggroup prototype.
7700 * remote-notif.c: Remove _initialize_notif prototype.
7701 * remote-sim.c: Remove _initialize_remote_sim prototype.
7702 * remote.c: Remove _initialize_remote prototype.
7703 * reverse.c: Remove _initialize_reverse prototype.
7704 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
7705 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
7706 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
7707 prototype.
7708 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
7709 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
7710 * rust-exp.y: Remove _initialize_rust_exp prototype.
7711 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
7712 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
7713 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
7714 * score-tdep.c: Remove _initialize_score_tdep prototype.
7715 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
7716 prototype.
7717 * ser-go32.c: Remove _initialize_ser_dos prototype.
7718 * ser-mingw.c: Remove _initialize_ser_windows prototype.
7719 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
7720 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
7721 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
7722 * serial.c: Remove _initialize_serial prototype.
7723 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
7724 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
7725 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
7726 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
7727 * skip.c: Remove _initialize_step_skip prototype.
7728 * sol-thread.c: Remove _initialize_sol_thread prototype.
7729 * solib-aix.c: Remove _initialize_solib_aix prototype.
7730 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
7731 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
7732 * solib-frv.c: Remove _initialize_frv_solib prototype.
7733 * solib-spu.c: Remove _initialize_spu_solib prototype.
7734 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
7735 * solib-target.c: Remove _initialize_solib_target prototype.
7736 * solib.c: Remove _initialize_solib prototype.
7737 * source.c: Remove _initialize_source prototype.
7738 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
7739 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
7740 prototype.
7741 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
7742 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
7743 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
7744 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
7745 prototype.
7746 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
7747 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
7748 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
7749 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
7750 prototype.
7751 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
7752 prototype.
7753 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
7754 prototype.
7755 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
7756 prototype.
7757 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
7758 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
7759 prototype.
7760 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
7761 prototype.
7762 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
7763 prototype.
7764 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
7765 prototype.
7766 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
7767 prototype.
7768 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
7769 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
7770 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
7771 * stabsread.c: Remove _initialize_stabsread prototype.
7772 * stack.c: Remove _initialize_stack prototype.
7773 * stap-probe.c: Remove _initialize_stap_probe prototype.
7774 * std-regs.c: Remove _initialize_frame_reg prototype.
7775 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
7776 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
7777 * symfile.c: Remove _initialize_symfile prototype.
7778 * symmisc.c: Remove _initialize_symmisc prototype.
7779 * symtab.c: Remove _initialize_symtab prototype.
7780 * target-dcache.c: Remove _initialize_target_dcache prototype.
7781 * target-descriptions.c: Remove _initialize_target_descriptions
7782 prototype.
7783 * thread.c: Remove _initialize_thread prototype.
7784 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
7785 prototype.
7786 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
7787 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
7788 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
7789 prototype.
7790 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
7791 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
7792 * tracefile.c: Remove _initialize_tracefile prototype.
7793 * tracepoint.c: Remove _initialize_tracepoint prototype.
7794 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
7795 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
7796 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
7797 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
7798 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
7799 * tui/tui-win.c: Remove _initialize_tui_win prototype.
7800 * tui/tui.c: Remove _initialize_tui prototype.
7801 * typeprint.c: Remove _initialize_typeprint prototype.
7802 * user-regs.c: Remove _initialize_user_regs prototype.
7803 * utils.c: Remove _initialize_utils prototype.
7804 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
7805 * valarith.c: Remove _initialize_valarith prototype.
7806 * valops.c: Remove _initialize_valops prototype.
7807 * valprint.c: Remove _initialize_valprint prototype.
7808 * value.c: Remove _initialize_values prototype.
7809 * varobj.c: Remove _initialize_varobj prototype.
7810 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
7811 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
7812 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
7813 * windows-nat.c: Remove _initialize_windows_nat,
7814 _initialize_check_for_gdb_ini, and _initialize_loadable
7815 prototypes.
7816 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
7817 * xcoffread.c: Remove _initialize_xcoffread prototype.
7818 * xml-support.c: Remove _initialize_xml_support prototype.
7819 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
7820 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
7821 prototype.
7822 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
7823 prototype.
7824 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
7825
a611b5cb
KS
78262017-09-08 Keith Seitz <keiths@redhat.com>
7827
7828 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
7829 field.
7830
469412dd
CW
78312017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
7832
7833 * f-valprint.c (f_val_print): Remove check for one byte
7834 sized integers. Remove printing of character type.
7835
a5ad232b
FP
78362017-09-08 Frank Penczek <frank.penczek@intel.com>
7837 Christoph Weinmann <christoph.t.weinmann@intel.com>
7838 Bernhard Heckel <bernhard.heckel@intel.com>
7839
7840 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
7841 to maintain proper indentation when printing pointers/refs.
7842
e5014227
JB
78432017-09-07 Joel Brobecker <brobecker@adacore.com>
7844
7845 GDB 8.0.1 released.
7846
63c99141
JB
78472017-09-07 Joel Brobecker <brobecker@adacore.com>
7848
7849 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
7850
69c1e056
TT
78512017-09-05 Tom Tromey <tom@tromey.com>
7852
7853 * parse.c (funcall_chain): Now a std::vector.
7854 (start_arglist, end_arglist): Simplify.
7855 (free_funcalls): Remove.
7856 (parse_exp_in_context_1): Remove cleanup.
7857
fef704bf
TT
78582017-09-05 Tom Tromey <tom@tromey.com>
7859
7860 * go-exp.y (go_parse): Don't create a cleanup.
7861
5613c585
TT
78622017-09-05 Tom Tromey <tom@tromey.com>
7863
7864 * d-exp.y (PrimaryExpression): Use std::string.
7865 (d_parse): Don't create a cleanup.
7866
eae49211
TT
78672017-09-05 Tom Tromey <tom@tromey.com>
7868
7869 * utils.c (do_clear_parser_state): Remove.
7870 (make_cleanup_clear_parser_state): Remove.
7871 * p-exp.y (pascal_parse): Use scoped_restore.
7872 * m2-exp.y (m2_parse): Use scoped_restore.
7873 * f-exp.y (f_parse): Use scoped_restore.
7874 * d-exp.y (d_parse): Use scoped_restore.
7875 * c-exp.y (c_parse): Use scoped_restore.
7876 * ada-exp.y (ada_parse): Use scoped_restore.
7877 * utils.h (make_cleanup_clear_parser_state): Remove.
7878
73b9be8b
KS
78792017-09-06 Keith Seitz <keiths@redhat.com>
7880
7881 * dwarf2read.c (dw2_linkage_name_attr): New function.
7882 (dw2_linkage_name): New function.
7883 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
7884 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
7885 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
7886
a102602b
KR
78872017-09-06 Kamil Rytarowski <n54@gmx.com>
7888
7889 * config/djgpp/djconfig.sh: Correct shell portability issue.
7890
28ad437d
KR
78912017-09-06 Kamil Rytarowski <n54@gmx.com>
7892
7893 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
7894
351787dd
JB
78952017-09-06 John Baldwin <jhb@FreeBSD.org>
7896
7897 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
7898 * NEWS: Mention new FreeBSD/mips native configuration.
7899 * configure.host: Add aarch64*-*-freebsd*.
7900 * configure.nat: Likewise.
7901 * aarch64-fbsd-nat.c: New file.
7902
c0f84956
JB
79032017-09-06 John Baldwin <jhb@FreeBSD.org>
7904
7905 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
7906 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
7907 * NEWS: Mention new FreeBSD/aarch64 target.
7908 * configure.tgt: Add aarch64*-*-freebsd*.
7909 * aarch64-fbsd-tdep.c: New file.
7910 * aarch64-fbsd-tdep.h: New file.
7911
7610297a
KR
79122017-09-06 Kamil Rytarowski <n54@gmx.com>
7913
7914 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
7915
fbd1b771
JK
79162017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7917
7918 * parse.c (find_minsym_type_and_address): Don't relocate addresses
7919 of TLS symbols.
7920
5ca79eae
PW
79212017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7922
7923 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
7924 call.
7925
bf93d7ba
SM
79262017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7927
7928 * infrun.c (follow_exec): Call add_thread after
7929 target_find_description.
7930
1bb7c059
SM
79312017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7932
7933 * infrun.c (handle_inferior_event_1): When exec'ing, read
7934 stop_pc after follow_exec.
7935
fc809827
SM
79362017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7937
7938 * remote.c (process_g_packet): Update error message.
7939
d2fcdd85
YQ
79402017-09-05 Yao Qi <yao.qi@linaro.org>
7941
7942 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
7943 targets.
7944
e69570ee
PA
79452017-09-05 Pedro Alves <palves@redhat.com>
7946
7947 * eval.c (eval_call, evaluate_funcall): New functions, factored
7948 out from ...
7949 (evaluate_subexp_standard): ... this.
7950
22916b07
YQ
79512017-09-05 Yao Qi <yao.qi@linaro.org>
7952
7953 * amd64-tdep.c (amd64_target_description): Create target
7954 descriptions.
7955 (_initialize_amd64_tdep): Don't call functions
7956 initialize_tdesc_amd64_*. Add self tests.
7957 * arch/amd64.c (amd64_create_target_description): Add parameter
7958 is_linux. Call set_tdesc_osabi if is_linux is true.
7959 * arch/amd64.h (amd64_create_target_description): Update the
7960 declaration.
7961 * arch/i386.c (i386_create_target_description): Add parameter
7962 is_linux. Call set_tdesc_osabi if is_linux is true.
7963 * arch/i386.h (i386_create_target_description): Update
7964 declaration.
7965 * configure.tgt: Add i386.o to gdb_target_obs.
7966 * features/Makefile (XMLTOC): Remove i386/*.xml.
7967 * features/i386/amd64-avx-avx512.c: Remove.
7968 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
7969 * features/i386/amd64-avx-mpx.c: Remove.
7970 * features/i386/amd64-avx.c: Remove.
7971 * features/i386/amd64-mpx.c: Remove.
7972 * features/i386/amd64.c: Remove.
7973 * features/i386/i386-avx-avx512.c: Remove.
7974 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
7975 * features/i386/i386-avx-mpx.c: Remove.
7976 * features/i386/i386-avx.c: Remove.
7977 * features/i386/i386-mmx.c: Remove.
7978 * features/i386/i386-mpx.c: Remove.
7979 * features/i386/i386.c: Remove.
7980 * i386-tdep.c: Don't include features/i386/i386*.c., include
7981 target-descriptions.h and arch/i386.h.
7982 (i386_target_description): Create target descriptions.
7983 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
7984 functions. Do self tests.
7985
0854b7b1
YQ
79862017-09-05 Yao Qi <yao.qi@linaro.org>
7987
7988 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
7989 * features/i386/amd64-avx-avx512-linux.c: Removed.
7990 * features/i386/amd64-avx-linux.c: Removed.
7991 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
7992 * features/i386/amd64-avx-mpx-linux.c: Removed.
7993 * features/i386/amd64-linux.c: Removed.
7994 * features/i386/amd64-mpx-linux.c: Removed.
7995 * features/i386/x32-avx-avx512-linux.c: Removed.
7996 * features/i386/x32-avx-linux.c: Removed.
7997 * features/i386/x32-linux.c: Removed.
7998
b4570e4b
YQ
79992017-09-05 Yao Qi <yao.qi@linaro.org>
8000
8001 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
8002 features/i386/*.c.
8003 (amd64_linux_read_description): Call
8004 amd64_create_target_description.
8005 * arch/amd64.c: New file.
8006 * arch/amd64.h: New file.
8007 * configure.tgt (x86_64-*-linux*): Append amd64.o.
8008 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
8009
6c73f67f
YQ
80102017-09-05 Yao Qi <yao.qi@linaro.org>
8011
8012 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
8013 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
8014 (amd64_linux_read_description): Create target descriptions.
8015 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
8016 functions. Add unit tests.
8017 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
8018 x32-core.xml.
8019 * features/i386/64bit-avx.c: Generated.
8020 * features/i386/64bit-avx512.c: Generated.
8021 * features/i386/64bit-core.c: Generated.
8022 * features/i386/64bit-linux.c: Generated.
8023 * features/i386/64bit-mpx.c: Generated.
8024 * features/i386/64bit-pkeys.c: Generated.
8025 * features/i386/64bit-segments.c: Generated.
8026 * features/i386/64bit-sse.c: Generated.
8027 * features/i386/x32-core.c: Generated.
8028 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
8029 c files for amd64-linux and x32-linux.
8030
9d3d478b
YQ
80312017-09-05 Yao Qi <yao.qi@linaro.org>
8032
8033 * amd64-linux-tdep.c (amd64_linux_read_description): New
8034 function.
8035 (amd64_linux_core_read_description): Call
8036 amd64_linux_read_description.
8037 (amd64_linux_init_abi): Likewise.
8038 (amd64_x32_linux_init_abi): Likewise.
8039 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
8040 * x86-linux-nat.c (x86_linux_read_description): Call
8041 amd64_linux_read_description.
8042
b9f1d50f
YQ
80432017-09-05 Yao Qi <yao.qi@linaro.org>
8044
8045 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
8046 comments.
8047
188c9e6d
YQ
80482017-09-05 Yao Qi <yao.qi@linaro.org>
8049
8050 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
8051 * features/i386/i386-avx-avx512-linux.c: Remove.
8052 * features/i386/i386-avx-linux.c: Remove.
8053 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
8054 * features/i386/i386-avx-mpx-linux.c: Remove.
8055 * features/i386/i386-linux.c: Remove.
8056 * features/i386/i386-mmx-linux.c: Remove.
8057 * features/i386/i386-mpx-linux.c: Remove.
8058
5f035c07
YQ
80592017-09-05 Yao Qi <yao.qi@linaro.org>
8060
8061 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
8062 (SFILES): Add arch/i386.c.
8063 (HFILES_NO_SRCDIR): Add arch/i386.h.
8064 * arch/i386.c: New file.
8065 * arch/i386.h: New file.
8066 * arch/tdesc.h (allocate_target_description): Declare.
8067 (set_tdesc_architecture): Declare.
8068 (set_tdesc_osabi): Declare.
8069 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
8070 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
8071 include arch/i386.h.
8072 (i386_linux_read_description): Remove code and call
8073 i386_create_target_description.
8074 (set_tdesc_architecture): New function.
8075 (set_tdesc_osabi): New function.
8076 * target-descriptions.h (allocate_target_description): Remove.
8077
0abe8a89
YQ
80782017-09-05 Yao Qi <yao.qi@linaro.org>
8079
8080 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
8081 * target-descriptions.c (tdesc_create_feature): Likewise, and
8082 adjust code.
8083 * features/i386/32bit-avx.c: Re-generated.
8084 * features/i386/32bit-avx512.c: Re-generated.
8085 * features/i386/32bit-core.c: Re-generated.
8086 * features/i386/32bit-linux.c: Re-generated.
8087 * features/i386/32bit-mpx.c: Re-generated.
8088 * features/i386/32bit-pkeys.c: Re-generated.
8089 * features/i386/32bit-sse.c: Re-generated.
8090
0a188386
YQ
80912017-09-05 Yao Qi <yao.qi@linaro.org>
8092
8093 * regformats/regdef.h (struct reg): Override operator == and !=.
8094
f49ff000
YQ
80952017-09-05 Yao Qi <yao.qi@linaro.org>
8096
8097 * arch/tdesc.h: New file.
8098 * regformats/regdat.sh: Generate code using tdesc_create_reg.
8099 * target-descriptions.c: Update comments.
8100 * target-descriptions.h: Include "arch/tdesc.h". Remove the
8101 declarations.
8102 * features/i386/32bit-avx.c: Re-generated.
8103 * features/i386/32bit-avx512.c: Re-generated.
8104 * features/i386/32bit-core.c: Re-generated.
8105 * features/i386/32bit-linux.c: Re-generated.
8106 * features/i386/32bit-mpx.c: Re-generated.
8107 * features/i386/32bit-pkeys.c: Re-generated.
8108 * features/i386/32bit-sse.c: Re-generated.
8109
f7000548
YQ
81102017-09-05 Yao Qi <yao.qi@linaro.org>
8111
8112 * regformats/regdat.sh: Update generated code.
8113
c9a5e2a5
YQ
81142017-09-05 Yao Qi <yao.qi@linaro.org>
8115
8116 * regformats/regdat.sh: Adjust code order.
8117
d6b687ac
SM
81182017-09-05 Simon Marchi <simon.marchi@ericsson.com>
8119
8120 * expprint.c (dump_subexp_body_standard): Use constant format
8121 string in fprintf_filtered call.
8122
a379bfd0
JB
81232017-09-04 John Baldwin <jhb@FreeBSD.org>
8124
8125 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
8126 NetBSD/i386.
8127 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
8128
f7efc967
JB
81292017-09-04 John Baldwin <jhb@FreeBSD.org>
8130
8131 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
8132
c49fbc6c
JB
81332017-09-04 John Baldwin <jhb@FreeBSD.org>
8134
8135 * bsd-kvm.o: Define _KMEMUSER.
8136 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
8137 * configure: Regenerate.
8138
26562e73
JB
81392017-09-04 John Baldwin <jhb@FreeBSD.org>
8140
8141 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
8142 * i386-fbsd-nat.c: Likewise.
8143
31cf1487
JB
81442017-09-04 John Baldwin <jhb@FreeBSD.org>
8145
8146 * unittests/array-view-selftests.c: Add include of <array>.
8147
5b9f8a7c
JB
81482017-09-04 John Baldwin <jhb@FreeBSD.org>
8149
8150 * spu-tdep.c (flush_ea_cache): Add missing argument to
8151 call_function_by_hand.
8152
d69cf9b2
PA
81532017-09-04 Pedro Alves <palves@redhat.com>
8154
8155 * NEWS (Safer support for debugging with no debug info): New.
8156
3693fdb3
PA
81572017-09-04 Pedro Alves <palves@redhat.com>
8158
8159 * c-exp.y (function_method, function_method_void): Add current
8160 instance flags to TYPE_INSTANCE.
8161 * dwarf2read.c (check_modifier): New.
8162 (compute_delayed_physnames): Assert that only C++ adds delayed
8163 physnames. Mark fn_fields as const/volatile depending on
8164 physname.
8165 * eval.c (make_params): New type_instance_flags parameter. Use
8166 it as the new type's instance flags.
8167 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
8168 flags element and pass it to make_params.
8169 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
8170 instance flags element.
8171 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
8172 * gdbtypes.h: Include "enum-flags.h".
8173 (type_instance_flags): New enum-flags type.
8174 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
8175 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
8176 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
8177 (follow_type_instance_flags): New function.
8178 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
8179 * parser-defs.h (follow_type_instance_flags): Declare.
8180 * valops.c (value_struct_elt_for_reference): const/volatile must
8181 match too.
8182
e68cb8e0
PA
81832017-09-04 Pedro Alves <palves@redhat.com>
8184
8185 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
8186 function/method scopes; lookup the nested name as a function local
8187 static variable.
8188
858be34c
PA
81892017-09-04 Pedro Alves <palves@redhat.com>
8190
8191 (%type <voidval>): Add function_method.
8192 * c-exp.y (exp): New production for calls with no arguments.
8193 (function_method, function_method_void_or_typelist): New
8194 productions.
8195 (exp): New production for "method()::static_var".
8196 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
8197 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8198 Handle OP_FUNC_STATIC_VAR.
8199 * parse.c (operator_length_standard):
8200 Handle OP_FUNC_STATIC_VAR.
8201
dd5901a6
PA
82022017-09-04 Pedro Alves <palves@redhat.com>
8203
8204 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
8205 handling.
8206 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8207 Ditto.
8208 * parse.c (operator_length_standard, operator_check_standard):
8209 Ditto.
8210 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
8211
46a4882b
PA
82122017-09-04 Pedro Alves <palves@redhat.com>
8213
8214 * ax-gdb.c: Include "typeprint.h".
8215 (gen_expr_for_cast): New function.
8216 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
8217 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
8218 type is unknown.
8219 * dwarf2read.c (new_symbol_full): Fallback to int instead of
8220 nodebug_data_symbol.
8221 * eval.c: Include "typeprint.h".
8222 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
8223 Error out if symbol has unknown type.
8224 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
8225 evaluate_subexp_for_cast.
8226 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
8227 OP_VAR_MSYM_VALUE.
8228 (evaluate_subexp_for_cast): New function.
8229 * gdbtypes.c (init_nodebug_var_type): New function.
8230 (objfile_type): Use it to initialize types of variables with no
8231 debug info.
8232 * typeprint.c (error_unknown_type): New.
8233 * typeprint.h (error_unknown_type): New declaration.
8234 * compile/compile-c-types.c (convert_type_basic): Handle
8235 TYPE_CODE_ERROR; warn and fallback to int for variables with
8236 unknown type.
8237
fe13dfec
PA
82382017-09-04 Pedro Alves <palves@redhat.com>
8239
8240 * eval.c (evaluate_var_value): New function, factored out from ...
8241 (evaluate_subexp_standard): ... here.
8242
d008ee21
PA
82432017-09-04 Pedro Alves <palves@redhat.com>
8244
8245 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
8246 Remove useless assignments to 'op'.
8247
827d0c51
PA
82482017-09-04 Pedro Alves <palves@redhat.com>
8249
8250 * eval.c (eval_skip_value): New function.
8251 (evaluate_subexp_standard): Use it.
8252
2c5a2be1
PA
82532017-09-04 Pedro Alves <palves@redhat.com>
8254
8255 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
8256 function name from symbol/minsym and pass it to
8257 error_call_unknown_return_type.
8258
74ea4be4
PA
82592017-09-04 Pedro Alves <palves@redhat.com>
8260
8261 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
8262 * ax-gdb.c (gen_msym_var_ref): New function.
8263 (gen_expr): Handle OP_VAR_MSYM_VALUE.
8264 * eval.c (evaluate_var_msym_value): New function.
8265 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
8266 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
8267 to call_function_by_hand.
8268 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
8269 Handle OP_VAR_MSYM_VALUE.
8270 (union exp_element) <msymbol>: New field.
8271 * minsyms.h (struct type): Forward declare.
8272 (find_minsym_type_and_address): Declare.
8273 * parse.c (write_exp_elt_msym): New function.
8274 (write_exp_msymbol): Delete, refactored as ...
8275 (find_minsym_type_and_address): ... this new function.
8276 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
8277 (operator_length_standard, operator_check_standard): Handle
8278 OP_VAR_MSYM_VALUE.
8279 * std-operator.def (OP_VAR_MSYM_VALUE): New.
8280
7022349d
PA
82812017-09-04 Pedro Alves <palves@redhat.com>
8282
8283 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
8284 TYPE_GNU_IFUNC specially here. Throw error if return type is
8285 unknown.
8286 * ada-typeprint.c (print_func_type): Handle functions with unknown
8287 return type.
8288 * c-typeprint.c (c_type_print_base): Handle functions and methods
8289 with unknown return type.
8290 * compile/compile-c-symbols.c (convert_symbol_bmsym)
8291 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
8292 * compile/compile-c-types.c: Include "objfiles.h".
8293 (convert_func): For functions with unknown return type, warn and
8294 default to int.
8295 * compile/compile-object-run.c (compile_object_run): Adjust call
8296 to call_function_by_hand_dummy.
8297 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
8298 call_function_by_hand.
8299 * eval.c (evaluate_subexp_standard): Adjust calls to
8300 call_function_by_hand. Handle functions and methods with unknown
8301 return type. Pass expect_type to call_function_by_hand.
8302 * f-typeprint.c (f_type_print_base): Handle functions with unknown
8303 return type.
8304 * gcore.c (call_target_sbrk): Adjust call to
8305 call_function_by_hand.
8306 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
8307 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
8308 an integer address type instead of nodebug.
8309 * guile/scm-value.c (gdbscm_value_call): Adjust call to
8310 call_function_by_hand.
8311 * infcall.c (error_call_unknown_return_type): New function.
8312 (call_function_by_hand): New "default_return_type" parameter.
8313 Pass it down.
8314 (call_function_by_hand_dummy): New "default_return_type"
8315 parameter. Use it instead of defaulting to int. If there's no
8316 default and the return type is unknown, throw an error. If
8317 there's a default return type, and the called function has no
8318 debug info, then assume the function is prototyped.
8319 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
8320 New "default_return_type" parameter.
8321 (error_call_unknown_return_type): New declaration.
8322 * linux-fork.c (call_lseek): Cast return type of lseek.
8323 (inferior_call_waitpid, checkpoint_command): Adjust calls to
8324 call_function_by_hand.
8325 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
8326 calls to call_function_by_hand.
8327 * m2-typeprint.c (m2_procedure): Handle functions with unknown
8328 return type.
8329 * objc-lang.c (lookup_objc_class, lookup_child_selector)
8330 (value_nsstring, print_object_command): Adjust calls to
8331 call_function_by_hand.
8332 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
8333 functions with unknown return type.
8334 (pascal_type_print_func_varspec_suffix): New function.
8335 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
8336 TYPE_CODE_METHOD>: Use it.
8337 * python/py-value.c (valpy_call): Adjust call to
8338 call_function_by_hand.
8339 * rust-lang.c (rust_evaluate_funcall): Adjust call to
8340 call_function_by_hand.
8341 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
8342 call_function_by_hand.
8343 * valops.c (value_allocate_space_in_inferior): Adjust call to
8344 call_function_by_hand.
8345 * typeprint.c (type_print_unknown_return_type): New function.
8346 * typeprint.h (type_print_unknown_return_type): New declaration.
8347
54990598
PA
83482017-09-04 Pedro Alves <palves@redhat.com>
8349
8350 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
8351 types with more than one parameter as prototyped.
8352
9a24775b
PA
83532017-09-04 Pedro Alves <palves@redhat.com>
8354
8355 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
8356 (disassemble_command): Use gdb_disassembly_flags instead of bare
8357 int.
8358 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
8359 (dump_insns, do_mixed_source_and_assembly_deprecated)
8360 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
8361 Use gdb_disassembly_flags instead of bare int.
8362 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
8363 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
8364 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
8365 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
8366 (enum gdb_disassembly_flag): ... values of this new enumeration.
8367 (gdb_disassembly_flags): Define.
8368 (gdb_disassembly)
8369 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
8370 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
8371 gdb_disassembly_flags instead of bare int.
8372 * record-btrace.c (btrace_insn_history)
8373 (record_btrace_insn_history, record_btrace_insn_history_range)
8374 (record_btrace_insn_history_from): Use gdb_disassembly_flags
8375 instead of bare int.
8376 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
8377 Use gdb_disassembly_flags instead of bare int.
8378 * target-debug.h (target_debug_print_gdb_disassembly_flags):
8379 Define.
8380 * target-delegates.c: Regenerate.
8381 * target.c (target_insn_history, target_insn_history_from)
8382 (target_insn_history_range): Use gdb_disassembly_flags instead of
8383 bare int.
8384 * target.h: Include "disasm.h".
8385 (struct target_ops) <to_insn_history, to_insn_history_from,
8386 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
8387 int.
8388 (target_insn_history, target_insn_history_from)
8389 (target_insn_history_range): Use gdb_disassembly_flags instead of
8390 bare int.
8391
80a65e9b
SM
83922017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8393
8394 * cli/cli-script.c (build_command_line): For if/while commands,
8395 check whether args is empty.
8396
6b66338c
SM
83972017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8398
8399 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
8400 (enum command_control_type): Likewise.
8401 (struct command_line): Likewise.
8402 (free_command_lines): Likewise.
8403 (struct command_lines_deleter): Likewise.
8404 (command_line_up): Likewise.
8405 (read_command_lines): Likewise.
8406 (read_command_lines_1): Likewise.
8407 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
8408 (enum command_control_type): Likewise.
8409 (struct command_line): Likewise.
8410 (free_command_lines): Likewise.
8411 (struct command_lines_deleter): Likewise.
8412 (command_line_up): Likewise.
8413 (read_command_lines): Likewise.
8414 (read_command_lines_1): Likewise.
8415 * breakpoint.h: Include cli/cli-script.h.
8416 * extension-priv.h: Likewise.
8417 * gdbcmd.h: Likewise.
8418
51abb421
PA
84192017-09-04 Pedro Alves <palves@redhat.com>
8420
8421 * ada-lang.c (is_known_support_routine): Move sal declaration to
8422 where it is initialized.
8423 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
8424 (parse_breakpoint_sals, decode_static_tracepoint_spec)
8425 (clear_command, update_static_tracepoint): Remove init_sal
8426 references. Move declarations closer to initializations.
8427 * cli/cli-cmds.c (list_command): Move sal declarations closer to
8428 initializations.
8429 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
8430 references. Move sal declarations closer to initializations.
8431 * frame.c (find_frame_sal): Return a symtab_and_line via function
8432 return instead of output parameter. Remove init_sal references.
8433 * frame.h (find_frame_sal): Return a symtab_and_line via function
8434 return instead of output parameter.
8435 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
8436 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
8437 instead of memset.
8438 (gdbscm_find_pc_line): Remove init_sal reference.
8439 * infcall.c (call_function_by_hand_dummy): Remove init_sal
8440 references. Move declarations closer to initializations.
8441 * infcmd.c (set_step_frame): Update. Move declarations closer to
8442 initializations.
8443 (finish_backward): Remove init_sal references. Move declarations
8444 closer to initializations.
8445 * infrun.c (process_event_stop_test, handle_step_into_function)
8446 (insert_hp_step_resume_breakpoint_at_frame)
8447 (insert_step_resume_breakpoint_at_caller): Likewise.
8448 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
8449 (symbol_to_sal): Likewise.
8450 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
8451 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
8452 to its initialization.
8453 * reverse.c (save_bookmark_command): Use new/delete. Remove
8454 init_sal references. Move declarations closer to initializations.
8455 * source.c (get_current_source_symtab_and_line): Remove brace
8456 initialization.
8457 (set_current_source_symtab_and_line): Now takes the sal by const
8458 reference. Remove brace initialization.
8459 (line_info): Remove init_sal reference.
8460 * source.h (set_current_source_symtab_and_line): Now takes a
8461 symtab_and_line via const reference.
8462 * stack.c (set_current_sal_from_frame): Adjust.
8463 (print_frame_info): Adjust.
8464 (get_last_displayed_sal): Return the sal via function return
8465 instead of via output parameter. Simplify.
8466 (frame_info): Adjust.
8467 * stack.h (get_last_displayed_sal): Return the sal via function
8468 return instead of via output parameter.
8469 * symtab.c (init_sal): Delete.
8470 (find_pc_sect_line): Remove init_sal references. Move
8471 declarations closer to initializations.
8472 (find_function_start_sal): Remove init_sal references. Move
8473 declarations closer to initializations.
8474 * symtab.h (struct symtab_and_line): In-class initialize all
8475 fields.
8476 * tracepoint.c (set_traceframe_context)
8477 (print_one_static_tracepoint_marker): Remove init_sal references.
8478 Move declarations closer to initializations.
8479 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
8480 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
8481 declarations closer to initializations.
8482 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
8483 init_sal references. Adjust.
8484
6c5b2ebe
PA
84852017-09-04 Pedro Alves <palves@redhat.com>
8486
8487 * ax-gdb.c (agent_command_1): Use range-for.
8488 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8489 * breakpoint.c: Include "common/array-view.h".
8490 (init_breakpoint_sal, create_breakpoint_sal): Change sals
8491 parameter from struct symtabs_and_lines to
8492 array_view<symtab_and_line>. Adjust. Use range-for. Update.
8493 (breakpoint_sals_to_pc): Change sals parameter from struct
8494 symtabs_and_lines to std::vector reference.
8495 (check_fast_tracepoint_sals): Change sals parameter from struct
8496 symtabs_and_lines to std::array_view. Use range-for.
8497 (decode_static_tracepoint_spec): Return a std::vector instead of
8498 symtabs_and_lines. Update.
8499 (create_breakpoint): Update.
8500 (break_range_command, until_break_command, clear_command): Update.
8501 (base_breakpoint_decode_location, bkpt_decode_location)
8502 (bkpt_probe_create_sals_from_location)
8503 (bkpt_probe_decode_location, tracepoint_decode_location)
8504 (tracepoint_probe_decode_location)
8505 (strace_marker_create_sals_from_location): Return a std::vector
8506 instead of symtabs_and_lines.
8507 (strace_marker_create_breakpoints_sal): Update.
8508 (strace_marker_decode_location): Return a std::vector instead of
8509 symtabs_and_lines. Update.
8510 (update_breakpoint_locations): Change struct symtabs_and_lines
8511 parameters to gdb::array_view. Adjust.
8512 (location_to_sals): Return a std::vector instead of
8513 symtabs_and_lines. Update.
8514 (breakpoint_re_set_default): Use std::vector instead of struct
8515 symtabs_and_lines.
8516 (decode_location_default): Return a std::vector instead of
8517 symtabs_and_lines. Update.
8518 * breakpoint.h: Include "common/array-view.h".
8519 (struct breakpoint_ops) <decode_location>: Now returns a
8520 std::vector instead of returning a symtabs_and_lines via output
8521 parameter.
8522 (update_breakpoint_locations): Change sals parameters to use
8523 gdb::array_view.
8524 * cli/cli-cmds.c (edit_command, list_command): Update to use
8525 std::vector and gdb::array_view.
8526 (ambiguous_line_spec): Adjust to use gdb::array_view and
8527 range-for.
8528 (compare_symtabs): Rename to ...
8529 (cmp_symtabs): ... this. Change parameters to symtab_and_line
8530 const reference and adjust.
8531 (filter_sals): Rewrite using std::vector and standard algorithms.
8532 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
8533 (jump_command): Update to use std::vector.
8534 * linespec.c (struct linespec_state) <canonical_names>: Update
8535 comment.
8536 (add_sal_to_sals_basic): Delete.
8537 (add_sal_to_sals, filter_results, convert_results_to_lsals)
8538 (decode_line_2, create_sals_line_offset)
8539 (convert_address_location_to_sals, convert_linespec_to_sals)
8540 (convert_explicit_location_to_sals, parse_linespec)
8541 (event_location_to_sals, decode_line_full, decode_line_1)
8542 (decode_line_with_current_source)
8543 (decode_line_with_last_displayed, decode_objc)
8544 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
8545 (linespec_result::~linespec_result): Adjust to use std::vector
8546 instead of symtabs_and_lines.
8547 * linespec.h (linespec_sals::sals): Now a std::vector.
8548 (struct linespec_result): Use std::vector, bool, and in-class
8549 initialization.
8550 (decode_line_1, decode_line_with_current_source)
8551 (decode_line_with_last_displayed): Return std::vector.
8552 * macrocmd.c (info_macros_command): Use std::vector.
8553 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
8554 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
8555 std::vector.
8556 * probe.h (parse_probes): Return a std::vector.
8557 * python/python.c (gdbpy_decode_line): Use std::vector and
8558 gdb::array_view.
8559 * source.c (select_source_symtab, line_info): Use std::vector.
8560 * stack.c (func_command): Use std::vector.
8561 * symtab.h (struct symtabs_and_lines): Delete.
8562 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
8563
7c44b49c
PA
85642017-09-04 Pedro Alves <palves@redhat.com>
8565
8566 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8567 unittests/array-view-selftests.c.
8568 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
8569 * common/array-view.h: New file.
8570 * unittests/array-view-selftests.c: New file.
8571
e439fa14
PA
85722017-09-04 Pedro Alves <palves@redhat.com>
8573
8574 * cli/cli-cmds.c (edit_command): Pass message to
8575 ambiguous_line_spec.
8576 (list_command): Pass message to ambiguous_line_spec. Say
8577 "first"/"last" instead of "start" and "end" to be consistent with
8578 the manual.
8579 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
8580 them to print formatted message.
8581
7525b645
PA
85822017-09-04 Pedro Alves <palves@redhat.com>
8583
8584 * btrace.c (ftrace_add_pt): Pass btrace_insn to
8585 ftrace_update_insns by reference instead of pointer.
8586
badc0020
YQ
85872017-09-04 Yao Qi <yao.qi@linaro.org>
8588
8589 * i386-go32-tdep.c: Include x86-xstate.h.
8590 (i386_go32_init_abi): Call i386_target_description.
8591 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
8592 if xcr0 is X86_XSTATE_X87_MASK.
8593 * i386-tdep.h (tdesc_i386): Remove the declaration.
8594 (tdesc_i386_mmx): Likewise.
8595
d78bdb54
YQ
85962017-09-04 Yao Qi <yao.qi@linaro.org>
8597
8598 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
8599 X86_XSTATE_SSE_MASK instead of 0.
8600
ca1fa5ee
YQ
86012017-09-04 Yao Qi <yao.qi@linaro.org>
8602
8603 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
8604 i386_target_description.
8605 * i386-fbsd-nat.c (i386fbsd_read_description): Call
8606 i386_target_description.
8607 * i386-tdep.c (i386_gdbarch_init): Likewise.
8608
2434b019
YQ
86092017-09-04 Yao Qi <yao.qi@linaro.org>
8610
8611 * amd64-darwin-tdep.c: Include "x86-xstate.h".
8612 (x86_darwin_init_abi_64): Call amd64_target_description.
8613 * amd64-dicos-tdep.c: Likewise.
8614 * amd64-fbsd-nat.c: Likewise.
8615 * amd64-fbsd-tdep.c: Likewise.
8616 * amd64-nbsd-tdep.c: Likewise.
8617 * amd64-obsd-tdep.c: Likewise.
8618 * amd64-sol2-tdep.c: Likewise.
8619 * amd64-windows-tdep.c: Likewise.
8620 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
8621
0860c437
SM
86222017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8623
8624 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
8625 (btrace_function) <insn>: Change type to use std::vector.
8626 * btrace.c (ftrace_debug, ftrace_call_num_insn,
8627 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
8628 ftrace_update_insns, ftrace_compute_global_level_offset,
8629 btrace_stitch_bts, btrace_clear, btrace_insn_get,
8630 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
8631 change to std::vector.
8632 (ftrace_update_insns): Adjust to change to std::vector, change
8633 type of INSN parameter.
8634 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
8635 * record-btrace.c (btrace_call_history_insn_range,
8636 btrace_compute_src_line_range,
8637 record_btrace_frame_prev_register): Adjust to change to
8638 std::vector.
8639 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
8640 to change to std::vector.
8641
0638b7f9
TT
86422017-09-03 Tom Tromey <tom@tromey.com>
8643
8644 * corefile.c (reopen_exec_file): Use std::string.
8645
8f84fb0e
TT
86462017-09-03 Tom Tromey <tom@tromey.com>
8647
8648 * compile/compile.c (compile_register_name_mangled): Return
8649 std::string.
8650 * compile/compile-loc2c.c (pushf_register_address): Update.
8651 (pushf_register): Update.
8652 * compile/compile-c-types.c (convert_array): Update.
8653 * compile/compile-c-symbols.c (generate_vla_size): Update.
8654 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
8655 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
8656 (convert_one_symbol): Update.
8657 (generate_c_for_for_one_variable): Update.
8658 * compile/compile-c-support.c (c_get_range_decl_name): Return a
8659 std::string.
8660 (generate_register_struct): Update.
8661 * compile/compile-internal.h (c_get_range_decl_name): Return a
8662 std::string.
8663 (compile_register_name_mangled): Return std::string.
8664
18e9961f
TT
86652017-09-03 Tom Tromey <tom@tromey.com>
8666
8667 * utils.c (perror_string): Return a std::string.
8668 (throw_perror_with_name, perror_warning_with_name): Update.
8669
45343786
TT
86702017-09-03 Tom Tromey <tom@tromey.com>
8671
8672 * demangle.c (demangle_command): Use std::string,
8673 unique_xmalloc_ptr.
8674
b57af503
TT
86752017-09-03 Tom Tromey <tom@tromey.com>
8676
8677 * cli/cli-setshow.c (do_set_command): Use std::string.
8678
6eecf35f
TT
86792017-09-03 Tom Tromey <tom@tromey.com>
8680
8681 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
8682
56496dd4
TT
86832017-09-03 Tom Tromey <tom@tromey.com>
8684
8685 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
8686
e91a1fa7
TT
86872017-09-03 Tom Tromey <tom@tromey.com>
8688
8689 * mi/mi-cmd-env.c (env_execute_cli_command): Use
8690 gdb::unique_xmalloc_ptr.
8691
7ffd83d7
TT
86922017-09-03 Tom Tromey <tom@tromey.com>
8693
8694 * thread.c (print_thread_info_1): Use string_printf.
8695 (thread_apply_command, thread_apply_all_command): Use
8696 std::string.
8697
1ccbe998
TT
86982017-09-03 Tom Tromey <tom@tromey.com>
8699
8700 * valprint.c (val_print_string): Update.
8701 * gdbcore.h (memory_error_message): Return std::string.
8702 * corefile.c (memory_error_message): Return std::string.
8703 (memory_error): Update.
8704 * breakpoint.c (insert_bp_location): Update.
8705
23fdd69e
SM
87062017-09-03 Simon Marchi <simon.marchi@ericsson.com>
8707
8708 * target/waitstatus.h (target_waitstatus_to_string): Change
8709 return type to std::string.
8710 * target/waitstatus.c (target_waitstatus_to_string): Return
8711 std::string.
8712 * target.h (target_waitstatus_to_string): Remove declaration.
8713 * infrun.c (resume, clear_proceed_status_thread,
8714 print_target_wait_results, do_target_wait, save_waitstatus,
8715 stop_all_threads): Adjust.
8716 * record-btrace.c (record_btrace_wait): Adjust.
8717 * target-debug.h
8718 (target_debug_print_struct_target_waitstatus_p): Adjust.
8719
5c811d30
JK
87202017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8721
8722 PR gdb/22046
8723 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
8724 detection.
8725
0a2dde4a
SDJ
87262017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
8727
8728 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
8729 for setting/unsetting environment variables on the remote target.
8730 (New remote packets): Add entries for QEnvironmentHexEncoded,
8731 QEnvironmentUnset and QEnvironmentReset.
8732 * common/environ.c (gdb_environ::operator=): Extend method to
8733 handle m_user_set_env_list and m_user_unset_env_list.
8734 (gdb_environ::clear): Likewise.
8735 (match_var_in_string): Change type of first parameter from 'char
8736 *' to 'const char *'.
8737 (gdb_environ::set): Extend method to handle
8738 m_user_set_env_list and m_user_unset_env_list.
8739 (gdb_environ::unset): Likewise.
8740 (gdb_environ::clear_user_set_env): New method.
8741 (gdb_environ::user_set_envp): Likewise.
8742 (gdb_environ::user_unset_envp): Likewise.
8743 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
8744 m_user_unset_env_list on move constructor/assignment.
8745 (unset): Add new default parameter 'update_unset_list = true'.
8746 (clear_user_set_env): New method.
8747 (user_set_envp): Likewise.
8748 (user_unset_envp): Likewise.
8749 (m_user_set_env_list): New std::set.
8750 (m_user_unset_env_list): Likewise.
8751 * common/rsp-low.c (hex2str): New function.
8752 (bin2hex): New overload for bin2hex function.
8753 * common/rsp-low.c (hex2str): New prototype.
8754 (str2hex): New overload prototype.
8755 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
8756 QEnvironmentUnset and QEnvironmentReset.
8757 (remote_protocol_features): Add QEnvironmentHexEncoded,
8758 QEnvironmentUnset and QEnvironmentReset packets.
8759 (send_environment_packet): New function.
8760 (extended_remote_environment_support): Likewise.
8761 (extended_remote_create_inferior): Call
8762 extended_remote_environment_support.
8763 (_initialize_remote): Add QEnvironmentHexEncoded,
8764 QEnvironmentUnset and QEnvironmentReset packet configs.
8765 * unittests/environ-selftests.c (gdb_selftest_env_var):
8766 New variable.
8767 (test_vector_initialization): New function.
8768 (test_init_from_host_environ): Likewise.
8769 (test_reinit_from_host_environ): Likewise.
8770 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
8771 Likewise.
8772 (test_unset_set_empty_vector): Likewise.
8773 (test_vector_clear): Likewise.
8774 (test_std_move): Likewise.
8775 (test_move_constructor):
8776 (test_self_move): Likewise.
8777 (test_set_unset_reset): Likewise.
8778 (run_tests): Rewrite in terms of the functions above.
8779
654670a4
WP
87802017-08-31 Weimin Pan <weimin.pan@oracle.com>
8781
8782 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
8783 (adi_available): Use a temp variable of type CORE_ADDR as argument
8784 3 when calling target_auxv_search.
8785 (adi_normalize_address): Use masks and xor operators to calculate
8786 normalized address.
8787 (adi_read_versions, adi_write_versions, adi_print_versions)
8788 (do_examine, do_assign): Use paddress.
8789
7755ddb7
JB
87902017-08-29 John Baldwin <jhb@FreeBSD.org>
8791
8792 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
8793 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
8794 out of loop and add supply of FIR.
8795 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
8796 add collect of FIR.
8797
fd437cbc
SM
87982017-08-28 Simon Marchi <simon.marchi@ericsson.com>
8799
3804a343 8800 PR gdb/21827
fd437cbc
SM
8801 * cli/cli-script.c (define_command): Don't convert command name
8802 to lower case.
8803
988f6b3d
JB
88042017-08-25 Joel Brobecker <brobecker@adacore.com>
8805
8806 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
8807 Update all callers accordingly. Remove all code blocks handling
8808 the case where DISPP is not NULL.
8809
663c44ac
JK
88102017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8811
8812 PR symtab/22003
8813 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
8814 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8815 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
8816
f1902523
JK
88172017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8818
8819 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
8820 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
8821 (read_comp_units_from_section): New parameter abbrev_section, use
8822 read_and_check_comp_unit_head, allocate signatured_type if needed.
8823 (create_all_comp_units): Update read_comp_units_from_section caller.
8824
87215ad1
SDJ
88252017-08-23 Pedro Alves <palves@redhat.com>
8826
8827 PR remote/21852
8828 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
8829 to null_ptid and switch to thread without reading the registers
8830 after adding the inferior.
8831
6e41ddec
JK
88322017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8833
8834 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
8835 compile-gcc.
8836 * compile/compile.c (compile_gcc, show_compile_gcc): New.
8837 (compile_to_object): Implement compile_gcc.
8838 (_initialize_compile): Install "set compile-gcc". Initialize
8839 compile_gcc.
8840
e68c32d5
JK
88412017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8842
8843 * compile/compile.c (compile_to_object): Conditionally call
8844 set_verbose. Conditionally call compile or compile_v0.
8845
58afddc6
WP
88462017-08-07 Weimin Pan <weimin.pan@oracle.com>
8847
8848 * sparc64-tdep.h: (adi_normalize_address): New export.
8849 * sparc-nat.h: (open_adi_tag_fd): New export.
8850 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
8851 * sparc64-linux-tdep.c:
8852 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
8853 (sparc64_linux_handle_segmentation_fault): New function.
8854 (sparc64_linux_init_abi): Register
8855 sparc64_linux_handle_segmentation_fault
8856 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
8857 (sparc64_addr_bits_remove): New function.
8858 (sparc64_init_abi): Register sparc64_addr_bits_remove.
8859 (MAX_PROC_NAME_SIZE): New macro.
8860 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
8861 (sparc64adilist): New variable.
8862 (adi_proc_list): New variable.
8863 (find_adi_info): New function.
8864 (add_adi_info): New function.
8865 (get_adi_info_proc): New function.
8866 (get_adi_info): New function.
8867 (info_adi_command): New function.
8868 (read_maps_entry): New function.
8869 (adi_available): New function.
8870 (adi_normalize_address): New function.
8871 (adi_align_address): New function.
8872 (adi_convert_byte_count): New function.
8873 (adi_tag_fd): New function.
8874 (adi_is_addr_mapped): New function.
8875 (adi_read_versions): New function.
8876 (adi_write_versions): New function.
8877 (adi_print_versions): New function.
8878 (do_examine): New function.
8879 (do_assign): New function.
8880 (adi_examine_command): New function.
8881 (adi_assign_command): New function.
8882 (_initialize_sparc64_adi_tdep): New function.
8883
11db9430
SM
88842017-08-22 Simon Marchi <simon.marchi@ericsson.com>
8885
8886 * breakpoint.c (breakpoints_info): Rename to ...
8887 (info_breakpoints_command): ... this.
8888 (watchpoints_info): Rename to ...
8889 (info_watchpoints_command): ... this.
8890 (tracepoints_info): Rename to ...
8891 (info_tracepoints_command): ... this.
8892 (_initialize_breakpoint): Adjust.
8893 * dcache.c (dcache_info): Rename to ...
8894 (info_display_command): ... this.
8895 (_initialize_dcache): Adjust.
8896 * frame.h (args_info): Rename to ...
8897 (info_args_command): ... this.
8898 (locals_info): Rename to ...
8899 (info_locals_command): ... this.
8900 * infcmd.c (nofp_registers_info): Rename to ...
8901 (info_registers_command): ... this.
8902 (float_info): Rename to ...
8903 (info_float_command): ... this.
8904 (program_info): Rename to ...
8905 (info_program_command): ... this.
8906 (all_registers_info): Rename to ...
8907 (info_all_registers_command): ... this.
8908 (vector_info): Rename to ...
8909 (info_vector_command): ... this.
8910 (float_info): Rename to ...
8911 (info_float_command): ... this.
8912 (_initialize_infcmd): Adjust.
8913 * inferior.h (term_info): Rename to ...
8914 (info_terminal_command): ... this.
8915 * inflow.c (term_info): Rename to ...
8916 (info_terminal_command): ... this.
8917 (_initialize_inflow): Adjust.
8918 * infrun.c (signals_info): Rename to ...
8919 (info_signals_command): ... this.
8920 (_initialize_infrun): Adjust.
8921 * objc-lang.c (classes_info): Rename to ...
8922 (info_classes_command): ... this.
8923 (selectors_info): Rename to ...
8924 (info_selectors_command): ... this.
8925 (_initialize_objc_language): Adjust.
8926 * printcmd.c (sym_info): Rename to ...
8927 (info_symbol_command): ... this.
8928 (address_info): Rename to ...
8929 (info_address_command): ... this.
8930 (display_info): Rename to ...
8931 (info_display_command): ... this.
8932 (_initialize_printcmd): Adjust.
8933 * reverse.c (bookmarks_info): Rename to ...
8934 (info_breakpoints_command): ... this.
8935 (_initialize_reverse): Adjust.
8936 * ser-go32.c (dos_info): Rename to ...
8937 (info_serial_command): ... this.
8938 (_initialize_ser_dos): Adjust.
8939 * skip.c (skip_info): Rename to ...
8940 (info_skip_command): ... this.
8941 (_initialize_step_skip): Adjust.
8942 * source.c (line_info): Rename to ...
8943 (info_line_command): ... this.
8944 (source_info): Rename to ...
8945 (info_source_command)
8946 * stack.c (frame_info): Rename to ...
8947 (info_frame_command): ... this.
8948 (locals_info): Rename to ...
8949 (info_locals_command): ... this.
8950 (args_info): Rename to ...
8951 (info_args_command): ... this.
8952 (_initialize_stack): Adjust.
8953 * symtab.c (sources_info): Rename to ...
8954 (info_sources_command): ... this.
8955 (variables_info): Rename to ...
8956 (info_variables_command): ... this.
8957 (functions_info): Rename to ...
8958 (info_functions_command): ... this.
8959 (types_info): Rename to ...
8960 (info_types_command): ... this.
8961 (_initialize_symtab): Adjust.
8962 * target.c (target_info): Rename to ...
8963 (info_target_command): ... this.
8964 (initialize_targets): Adjust.
8965 * tracepoint.c (tvariables_info): Rename to ...
8966 (info_tvariables_command): ... this.
8967 (scope_info): Rename to ...
8968 (info_scope_command): ... this.
8969 (trace_dump_actions): Adjust.
8970 (_initialize_tracepoint): Adjust.
8971
b270e6f9
TT
89722017-08-22 Tom Tromey <tom@tromey.com>
8973
8974 * breakpoint.h (install_breakpoint): Update.
8975 * breakpoint.c (add_solib_catchpoint): Update.
8976 (install_breakpoint): Change argument to a std::unique_ptr.
8977 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
8978 (create_breakpoint_sal, create_breakpoint): Update.
8979 (watch_command_1, catch_exec_command_1)
8980 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
8981 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
8982 Return the breakpoint.
8983 (set_raw_breakpoint_without_location, set_raw_breakpoint)
8984 (new_single_step_breakpoint): Update.
8985 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
8986 std::unique_ptr.
8987 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8988 std::unique_ptr.
8989 * break-catch-sig.c (create_signal_catchpoint): Use
8990 std::unique_ptr.
8991 * ada-lang.c (create_ada_exception_catchpoint): Use
8992 std::unique_ptr.
8993
36bd8eaa
TT
89942017-08-22 Tom Tromey <tom@tromey.com>
8995
8996 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
8997
56f37645
TT
89982017-08-22 Tom Tromey <tom@tromey.com>
8999
9000 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
9001 (lookup_partial_symbol): Update.
9002
0b581c69
TT
90032017-08-22 Tom Tromey <tom@tromey.com>
9004
9005 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
9006 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
9007 (find_and_open_source, symtab_to_fullname): Update.
9008 * psymtab.c (psymtab_to_fullname): Update.
9009
14278e1f
TT
90102017-08-22 Tom Tromey <tom@tromey.com>
9011
9012 * exec.c (exec_file_attach): Update.
9013 * linux-thread-db.c (try_thread_db_load): Update.
9014 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
9015 * utils.c (gdb_realpath): Change return type.
9016 (gdb_realpath_keepfile): Update.
9017 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
9018 (_initialize_utils): Register the new self test.
9019 * source.c (openp): Update.
9020 (find_and_open_source): Update.
9021 * nto-tdep.c (nto_find_and_open_solib): Update.
9022 * main.c (set_gdb_data_directory): Update.
9023 (captured_main_1): Update.
9024 * dwarf2read.c (dwarf2_get_dwz_file): Update
9025 (dw2_map_symbol_filenames): Update.
9026 * auto-load.c (auto_load_safe_path_vec_update): Update.
9027 (filename_is_in_auto_load_safe_path_vec): Change type of
9028 "filename_realp".
9029 (auto_load_objfile_script): Update.
9030 (file_is_auto_load_safe): Update. Use std::string.
9031 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
9032
4971c9a7
TT
90332017-08-22 Tom Tromey <tom@tromey.com>
9034
9035 * utils.c (gdb_realpath_keepfile): Return a
9036 gdb::unique_xmalloc_ptr.
9037 * exec.c (exec_file_attach): Update.
9038 * utils.h (gdb_realpath_keepfile): Return a
9039 gdb::unique_xmalloc_ptr.
9040
e3e41d58
TT
90412017-08-22 Tom Tromey <tom@tromey.com>
9042
9043 * compile/compile.c (compile_file_command): Use
9044 gdb::unique_xmalloc_ptr, std::string.
9045 * utils.c (gdb_abspath): Change return type.
9046 * source.c (openp): Update.
9047 * objfiles.c (allocate_objfile): Update.
9048 * main.c (set_gdb_data_directory): Update.
9049 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
9050
0d999a6e
ZZ
90512017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
9052
9053 * cli-cmds.c (list_commands): List actual code around more than
9054 one location.
9055
329d5e7e
JB
90562017-08-21 John Baldwin <jhb@FreeBSD.org>
9057
9058 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
9059
bf223d3e
PA
90602017-08-21 Pedro Alves <palves@redhat.com>
9061
9062 PR gdb/19487
9063 * c-exp.y (variable production): Handle function aliases.
9064 * minsyms.c (msymbol_is_text): New function.
9065 * minsyms.h (msymbol_is_text): Declare.
9066 * symtab.c (find_function_alias_target): New function.
9067 * symtab.h (find_function_alias_target): Declare.
9068
c973d0aa
PA
90692017-08-21 Pedro Alves <palves@redhat.com>
9070
9071 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
9072 typedefs.
9073 * typeprint.c (whatis_exp): If handling "whatis", and expression
9074 is OP_TYPE, strip one typedef level. Otherwise don't strip
9075 typedefs here.
9076 * valops.c (value_cast): Save "to" type before resolving
9077 stubs/typedefs. Use that type as resulting value's type.
9078
2989a365
TT
90792017-08-18 Tom Tromey <tom@tromey.com>
9080 Pedro Alves <palves@redhat.com>
9081
9082 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
9083 * sol-thread.c (sol_thread_resume, sol_thread_wait)
9084 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
9085 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
9086 * proc-service.c (ps_xfer_memory): Use scoped_restore.
9087 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
9088 (linux_get_siginfo_data): Add "thread" argument. Use
9089 scoped_restore.
9090 * linux-nat.c (linux_child_follow_fork)
9091 (check_stopped_by_watchpoint): Use scoped_restore.
9092 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
9093 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
9094 (restore_inferior_ptid, save_inferior_ptid): Remove.
9095 * btrace.c (btrace_fetch): Use scoped_restore.
9096 * bsd-uthread.c (bsd_uthread_fetch_registers)
9097 (bsd_uthread_store_registers): Use scoped_restore.
9098 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
9099 scoped_restore.
9100 * aix-thread.c (aix_thread_resume, aix_thread_wait)
9101 (aix_thread_xfer_partial): Use scoped_restore.
9102 * inferior.h (save_inferior_ptid): Remove.
9103
e60eb288
YQ
91042017-08-18 Yao Qi <yao.qi@linaro.org>
9105
9106 PR tdep/21818
9107 * arm-tdep.c (gdb_print_insn_arm): Mark
9108 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
9109
6d580b63
YQ
91102017-08-18 Yao Qi <yao.qi@linaro.org>
9111
9112 * NEWS: Mention GDBserver's new option "--selftest".
9113 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
9114 * selftest.c: Move it to common/selftest.c.
9115 * selftest.h: Move it to common/selftest.h.
9116 * selftest-arch.c (reset): New function.
9117 (tests_with_arch): Call reset.
9118
86dcbf50
YQ
91192017-08-18 Yao Qi <yao.qi@linaro.org>
9120
9121 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
9122 instead of exception_fprintf and printf_filtered.
9123
7649770c
YQ
91242017-08-18 Yao Qi <yao.qi@linaro.org>
9125
9126 * selftest.c (register_self_test): Rename it to
9127 selftests::register_test.
9128 (run_self_tests): selftest::run_tests.
9129 * selftest.h: Update declarations.
9130 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
9131 selftests::register_test_foreach_arch.
9132 * selftest-arch.h: Update declaration.
9133 * aarch64-tdep.c: Update.
9134 * arm-tdep.c: Likewise.
9135 * disasm-selftests.c: Likewise.
9136 * dwarf2loc.c: Likewise.
9137 * dwarf2-frame.c: Likewise.
9138 * findvar.c: Likewise.
9139 * gdbarch-selftests.c: Likewise.
9140 * maint.c (maintenance_selftest): Likewise.
9141 * regcache.c: Likewise.
9142 * rust-exp.y: Likewise.
9143 * selftest-arch.c: Likewise.
9144 * unittests/environ-selftests.c: Likewise.
9145 * unittests/function-view-selftests.c: Likewise.
9146 * unittests/offset-type-selftests.c: Likewise.
9147 * unittests/optional-selftests.c: Likewise.
9148 * unittests/scoped_restore-selftests.c: Likewise.
9149 * utils-selftests.c: Likewise.
9150
b0cba12e
PA
91512017-08-17 Pedro Alves <palves@redhat.com>
9152
9153 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
9154 local.
9155
4c8aa72d
PA
91562017-08-17 Pedro Alves <palves@redhat.com>
9157
9158 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
9159 field.
9160 (reset_die_in_process): Delete, replaced by ...
9161 (process_die_scope): ... this new class. Make it responsible for
9162 freeing cu->line_header too.
9163 (process_die): Use process_die_scope.
9164 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
9165 cu->line_header_die_owner. Don't release the line header if it's
9166 owned by the CU.
9167 (setup_type_unit_groups): Make the CU/DIE own the line header.
9168 Don't release the line header here.
9169
ba713918
AL
91702017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
9171
9172 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
9173
44d0fb3a
RK
91742017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
9175
9176 * NEWS: Mention new shortcuts for nexti and stepi in TUI
9177 Single-Key mode
9178
a5afdb16
RK
91792017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
9180
9181 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
9182 mode command list.
9183
47613aeb
SH
91842017-08-15 Stafford Horne <shorne@gmail.com>
9185
9186 * MAINTAINERS (Write After Approval): Add Stafford Horne.
9187
9c3cc999
SH
91882017-08-15 Stafford Horne <shorne@gmail.com>
9189
9190 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
9191
206726fb
SDJ
91922017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
9193
9194 PR gdb/21954
9195 * infcmd.c (unset_environment_command): Use the 'clear' method on
9196 the environment instead of resetting it.
9197
0335ac6d
JB
91982017-08-15 John Baldwin <jhb@FreeBSD.org>
9199
9200 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
9201 platforms.
9202
d3abe1c8
TT
92032017-08-14 Tom Tromey <tom@tromey.com>
9204
9205 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
9206 (print_binary_chars): Likewise.
9207 (BITS_IN_BYTES): Remove.
9208
d6382fff
TT
92092017-08-14 Tom Tromey <tom@tromey.com>
9210
9211 PR gdb/21675
9212 * valprint.c (LOW_ZERO): Change value to 034.
9213 (print_octal_chars): Add static_asserts for octal constants.
9214 * printcmd.c (print_scalar_formatted): Add 'd' case.
9215
f978cb06
TT
92162017-08-11 Tom Tromey <tom@tromey.com>
9217
9218 * symfile.c (add_symbol_file_command): Use std::vector.
9219
2f5404b3
TT
92202017-08-14 Tom Tromey <tom@tromey.com>
9221
9222 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
9223 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
9224 std::move.
9225 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
9226
de7985c3
PA
92272017-08-11 Pedro Alves <palves@redhat.com>
9228
9229 * infrun.c (process_event_stop_test): Adjust
9230 function_name_is_marked_for_skip call.
9231 * skip.c: Include <list>.
9232 (skiplist_entry): Make it a class with private fields, and
9233 getters/setters.
9234 (skiplist_entry_chain): Delete.
9235 (skiplist_entries): New.
9236 (skiplist_entry_count): Delete.
9237 (highest_skiplist_entry_num): New.
9238 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
9239 (add_skiplist_entry): Delete.
9240 (skiplist_entry::skiplist_entry): New.
9241 (skiplist_entry::add_entry): New.
9242 (skip_file_command, skip_function): Adjust.
9243 (compile_skip_regexp): Delete.
9244 (skip_command): Don't compile regexp here. Adjust to use
9245 skiplist_entry::add_entry.
9246 (skip_info): Adjust to use range-for and getters.
9247 (skip_enable_command, skip_disable_command): Adjust to use
9248 range-for and setters.
9249 (skip_delete_command): Adjust to use std::list.
9250 (add_skiplist_entry): Delete.
9251 (skip_file_p): Delete, refactored as ...
9252 (skiplist_entry::do_skip_file_p): ... this new method.
9253 (skip_gfile_p): Delete, refactored as ...
9254 (skiplist_entry::do_gskip_file_p): ... this new method.
9255 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
9256 (skiplist_entry::skip_function_p): ... this new method.
9257 (function_name_is_marked_for_skip): Now returns bool, and takes
9258 the function sal by const reference. Adjust to use range-for and
9259 skiplist_entry methods.
9260 (_initialize_step_skip): Remove references to
9261 skiplist_entry_chain, skiplist_entry_count.
9262 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
9263 takes the function sal by const reference.
9264
be7d3cd5
YQ
92652017-08-11 Yao Qi <yao.qi@linaro.org>
9266
9267 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
9268 (dwarf2_frame_cache): Remove reset_cache_cleanup.
9269 (dwarf2_frame_cache):
9270 * frame-unwind.c (frame_unwind_try_unwinder): Catch
9271 RETURN_MASK_ALL and set *this_case to NULL.
9272 * frame-unwind.h: Update comments.
9273
1c90d9f0
YQ
92742017-08-11 Yao Qi <yao.qi@linaro.org>
9275
9276 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
9277 (dwarf2_frame_state_copy_regs): Remove.
9278 (dwarf2_frame_state_free_regs): Remove.
9279 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
9280 (dwarf2_restore_rule): Call method .alloc_regs instead of
9281 dwarf2_frame_state_alloc_regs.
9282 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
9283 constructor. Call std::move.
9284 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
9285 (dwarf2_frame_cache): Likewise.
9286
9287 [GDB_SELF_TEST]: Include selftest.h and
9288 selftest-arch.h.
9289 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
9290 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
9291 execute_cfa_program_test.
9292
9293 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
9294 copy ctor, assignment operator, move assignment.
9295 <alloc_regs>: New method.
9296 <swap>: New method.
9297 (struct dwarf2_frame_state): Delete dtor.
9298 (dwarf2_frame_state_alloc_regs): Remove declaration.
9299 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
9300 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
9301
afe37d6b
YQ
93022017-08-11 Yao Qi <yao.qi@linaro.org>
9303
9304 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
9305 (dwarf2_frame_state::dwarf2_frame_state): New.
9306 (dwarf2_frame_state::~dwarf2_frame_state): New.
9307 (dwarf2_fetch_cfa_info): Update.
9308 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
9309 rather than a pointer. Update code.
9310 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
9311 dtor.
9312 <data_align, code_align, retaddr_column>: Change them to const.
9313 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
9314 to bool.
9315
b348037f
YQ
93162017-08-11 Yao Qi <yao.qi@linaro.org>
9317
9318 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
9319 <loc.exp>: New field.
9320 * dwarf2-frame.c (execute_cfa_program): Update.
9321 (dwarf2_frame_prev_register): Update.
9322
e7c9de26
PA
93232017-08-10 Pedro Alves <palves@redhat.com>
9324
9325 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
9326
e8c6b620
JB
93272017-08-09 John Baldwin <jhb@FreeBSD.org>
9328
9329 * fbsd-nat.c (struct fbsd_fork_info): Remove.
9330 (fbsd_pending_children): Use std::list.
9331 (fbsd_remember_child): Likewise.
9332 (fbsd_is_child_pending): Likewise.
9333 (fbsd_pending_vfork_done): Use std::forward_list.
9334 (fbsd_add_vfork_done): Likewise.
9335 (fbsd_is_vfork_done_pending): Likewise.
9336 (fbsd_next_vfork_done): Likewise.
9337
e4a26669
JB
93382017-08-09 John Baldwin <jhb@FreeBSD.org>
9339
9340 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
9341 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
9342 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
9343 for `mapfilename'.
9344 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 9345 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 9346
142311d3
JB
93472017-08-09 John Baldwin <jhb@FreeBSD.org>
9348
9349 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
9350 "filestuff.h".
9351 (fbsd_find_memory_regions): Fix `mapfile' initialization.
9352
42fa2e0e
TT
93532017-08-09 Tom Tromey <tom@tromey.com>
9354
9355 * skip.c (skiplist_entry): New constructor.
9356 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
9357 (skiplist_entry::file_is_glob): Now bool.
9358 (skiplist_entry::file, skiplist_entry::function): Now
9359 std::string.
9360 (make_skip_entry): Return a unique_ptr. Use new.
9361 (free_skiplist_entry, free_skiplist_entry_cleanup)
9362 (make_free_skiplist_entry_cleanup): Remove.
9363 (skip_command, skip_disable_command, add_skiplist_entry)
9364 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
9365 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
9366 (function_name_is_marked_for_skip): Update.
9367 (skip_delete_command): Update. Use delete.
9368
cd3af38d
JW
93692017-08-09 Jiong Wang <jiong.wang@arm.com>
9370
9371 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
9372 (aarch64_linux_core_read_description): New function.
9373 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
9374
29592bde
PA
93752017-08-09 Pedro Alves <palves@redhat.com>
9376
9377 * cp-name-parser.y (cp_comp_to_string): Return a
9378 gdb::unique_xmalloc_ptr<char>.
9379 * cp-support.c (replace_typedefs_qualified_name)
9380 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
9381 (cp_canonicalize_string_full): Use op= instead of explicit
9382 convertion.
9383 (cp_class_name_from_physname, method_name_from_physname)
9384 (cp_func_name, cp_remove_params): Adjust to use
9385 gdb::unique_xmalloc_ptr<char>.
9386 * cp-support.h (cp_comp_to_string): Return a
9387 gdb::unique_xmalloc_ptr<char>.
9388 * python/py-type.c (typy_lookup_type): Adjust to use
9389 gdb::unique_xmalloc_ptr<char>.
9390
b3340438
L
93912017-08-09 H.J. Lu <hongjiu.lu@intel.com>
9392
9393 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
9394
e88e8651
YQ
93952017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
9396 Yao Qi <yao.qi@linaro.org>
9397
9398 * cp-support.c (cp_canonicalize_string_full): Use
9399 gdb::unique_xmalloc_ptr<char>.
9400 (cp_canonicalize_string): Likewise.
9401
f5a29eb0
YQ
94022017-08-09 Yao Qi <yao.qi@linaro.org>
9403
9404 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
9405 * regformats/i386/amd64-avx-avx512.dat: Remove.
9406 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
9407 * regformats/i386/amd64-avx-mpx.dat:Remove.
9408 * regformats/i386/amd64-avx.dat: Remove.
9409 * regformats/i386/amd64-mpx.dat: Remove.
9410 * regformats/i386/i386-avx-avx512.dat: Remove.
9411 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
9412 * regformats/i386/i386-avx-mpx.dat: Remove.
9413 * regformats/i386/i386-mmx.dat: Remove.
9414 * regformats/i386/i386-mpx.dat: Remove.
9415
57757c2f
YQ
94162017-08-09 Yao Qi <yao.qi@linaro.org>
9417
9418 * amd64-tdep.h (tdesc_x32): Remove the declaration.
9419 * amd64-tdep.c: Don't include features/i386/x32*.c.
9420 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
9421 functions.
9422 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
9423 and i386/x32-avx-avx512.
9424 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
9425 and i386/x32.xml.
9426 * features/i386/x32-avx-avx512.c: Removed.
9427 * features/i386/x32-avx-avx512.xml: Removed.
9428 * features/i386/x32-avx.c: Removed.
9429 * features/i386/x32-avx.xml: Removed.
9430 * features/i386/x32.c: Removed.
9431 * features/i386/x32.xml: Removed.
9432 * regformats/i386/x32-avx-avx512.dat: Removed.
9433 * regformats/i386/x32-avx.dat: Removed.
9434 * regformats/i386/x32.dat: Removed.
9435
ba7b109b
MR
94362017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9437
9438 PR breakpoints/21886
9439 * mem-break.c (default_memory_insert_breakpoint): Use
9440 `->placed_address' rather than `->reqstd_address' for the
9441 breakpoint location.
9442
e347efc3
MR
94432017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9444
9445 * arch-utils.c (default_print_insn): Remove arch/mach/endian
9446 assertions.
9447
0dba2a6c
MR
94482017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9449
9450 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
9451 a union of `tdep_info', `tdesc_data' and `id'.
9452 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
9453 rather than `info.tdep_info'.
9454 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
9455 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9456 * i386-tdep.c (i386_gdbarch_init): Likewise.
9457 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
9458 * mips-tdep.c (mips_gdbarch_init): Likewise.
9459 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9460 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9461 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
9462 `info.tdep_info'.
9463 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
9464 `info.tdep_info'.
9465 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9466 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
9467 `info.tdep_info'.
9468 * spu-tdep.c (spu_gdbarch_init): Likewise.
9469 * gdbarch.h: Regenerate.
9470
16eb6b2d
LS
94712017-08-07 Leszek Swirski <leszeks@google.com>
9472
7b005726 9473 PR symtab/20899
16eb6b2d
LS
9474 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
9475
74cbb09e
SM
94762017-08-07 Simon Marchi <simon.marchi@ericsson.com>
9477
9478 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
9479 (gdbsim_open): Rename gdb_argv args object to argv.
9480
ee0c3293
TT
94812017-08-05 Tom Tromey <tom@tromey.com>
9482
9483 * compile/compile-object-load.c (compile_object_load): Use
9484 gdb::unique_xmalloc_ptr.
9485 * cli/cli-dump.c (scan_filename): Rename from
9486 scan_filename_with_cleanup. Change return type.
9487 (scan_expression): Rename from scan_expression_with_cleanup.
9488 Change return type.
9489 (dump_memory_to_file, dump_value_to_file, restore_command):
9490 Use gdb::unique_xmalloc_ptr. Update.
9491 * cli/cli-cmds.c (find_and_open_script): Use
9492 gdb::unique_xmalloc_ptr.
9493 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
9494 * symmisc.c (maintenance_print_symbols)
9495 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
9496 * symfile.c (symfile_bfd_open, generic_load)
9497 (add_symbol_file_command, remove_symbol_file_command): Use
9498 gdb::unique_xmalloc_ptr.
9499 * source.c (openp): Use gdb::unique_xmalloc_ptr.
9500 * psymtab.c (maintenance_print_psymbols): Use
9501 gdb::unique_xmalloc_ptr.
9502 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
9503 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
9504 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
9505 (reload_shared_libraries_1): Likewise.
9506
3232fabd
TT
95072017-08-05 Tom Tromey <tom@tromey.com>
9508
9509 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
9510 (rust_op_vector, rust_set_vector): New typedefs.
9511 (current_parser): New global.
9512 (work_obstack): Change to pointer type. Update all users.
9513 (rust_ast, pstate): Remove globals.
9514 (struct rust_parser): New.
9515 (%union) <params, field_inits>: Change type.
9516 (start, tuple_expr, unit_expr, struct_expr_list, literal)
9517 (field_expr, expr_list, maybe_expr_list, type_list): Update.
9518 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
9519 (convert_params_to_types, convert_params_to_expression): Change
9520 type of "params".
9521 (ast_string): Change type of "fields".
9522 (rust_parse): Make a rust_parser. Remove cleanups.
9523 (rust_lex_tests): Make and install an auto_obstack.
9524
f02fd774
YQ
95252017-08-04 Yao Qi <yao.qi@linaro.org>
9526
9527 * configure.srv (ipa_x32_linux_regobj): New.
9528 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
9529 instead of X86_TDESC_AVX512.
9530 (initialize_low_tracepoint): Call
9531 init_registers_x32_avx_avx512_linux.
9532
91975afd
YQ
95332017-08-04 Yao Qi <yao.qi@linaro.org>
9534
9535 * utils.h (gdb_argv): Add namespace std for nullptr_t.
9536
2331fa3a
RK
95372017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
9538
9539 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
9540
744e4fe1
TT
95412017-08-03 Tom Tromey <tom@tromey.com>
9542
9543 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
9544 Remove.
9545 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
9546
1c034b67
TT
95472017-08-03 Tom Tromey <tom@tromey.com>
9548
9549 * python/py-param.c (compute_enum_values): Use gdb_argv.
9550
773a1edc
TT
95512017-08-03 Tom Tromey <tom@tromey.com>
9552
9553 * utils.h (struct gdb_argv_deleter): New.
9554 (gdb_argv): New class.
9555 * utils.c (gdb_argv::reset): New method.
9556 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
9557 * tracefile.c (tsave_command): Use gdb_argv.
9558 * top.c (new_ui_command): Use gdb_argv.
9559 * symmisc.c (maintenance_print_symbols)
9560 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
9561 * symfile.c (symbol_file_command, generic_load)
9562 (remove_symbol_file_command): Use gdb_argv.
9563 * stack.c (backtrace_command): Use gdb_argv.
9564 * source.c (add_path, show_substitute_path_command)
9565 (unset_substitute_path_command, set_substitute_path_command):
9566 Use gdb_argv.
9567 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
9568 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
9569 * remote.c (extended_remote_run, remote_put_command)
9570 (remote_get_command, remote_delete_command): Use gdb_argv.
9571 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
9572 (gdbsim_open): Use gdb_argv.
9573 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
9574 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
9575 * procfs.c (procfs_info_proc): Use gdb_argv.
9576 * interps.c (interpreter_exec_cmd): Use gdb_argv.
9577 * infrun.c (handle_command): Use gdb_argv.
9578 * inferior.c (add_inferior_command, clone_inferior_command):
9579 Use gdb_argv.
9580 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
9581 * exec.c (exec_file_command): Use gdb_argv.
9582 * cli/cli-cmds.c (alias_command): Use gdb_argv.
9583 * compile/compile.c (build_argc_argv): Use gdb_argv.
9584
0d50bde3
TT
95852017-08-03 Tom Tromey <tom@tromey.com>
9586
9587 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
9588
7f968c89
TT
95892017-08-03 Tom Tromey <tom@tromey.com>
9590
9591 * python/python.c (compute_python_string): Return std::string.
9592 (gdbpy_eval_from_control_command): Update.
9593 (do_start_initialization): Use std::string.
9594 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
9595 xstrprintf.
9596 * python/py-breakpoint.c (local_setattro): Use string_printf, not
9597 xstrprintf.
9598
3c9ebddd
TT
95992017-08-03 Tom Tromey <tom@tromey.com>
9600
9601 * top.h (do_restore_instream_cleanup): Remove.
9602 * top.c (do_restore_instream_cleanup): Remove.
9603 (read_command_file): Use scoped_restore.
9604 * cli/cli-script.c (execute_user_command): Use scoped_restore.
9605
b51b225e
TT
96062017-08-03 Tom Tromey <tom@tromey.com>
9607
9608 * cli/cli-script.c (execute_user_command)
9609 (execute_control_command): Use scoped_restore.
9610
ac991630
TT
96112017-08-03 Tom Tromey <tom@tromey.com>
9612
9613 * cli/cli-script.c (do_restore_user_call_depth): Remove.
9614 (execute_user_command): Remove user_call_depth; use
9615 user_args_stack's size instead.
9616
898e0c8e
TT
96172017-08-03 Tom Tromey <tom@tromey.com>
9618
9619 * top.h (in_user_command): Remove.
9620 * top.c (in_user_command): Remove.
9621 * cli/cli-script.c (do_restore_user_call_depth)
9622 (execute_user_command): Update.
9623
26fcd5d7
TT
96242017-08-03 Tom Tromey <tom@tromey.com>
9625
9626 * valops.c (search_struct_method): Use gdb::byte_vector.
9627 * valarith.c (value_concat): Use std::vector.
9628 * target.c (memory_xfer_partial): Use gdb::byte_vector.
9629 (simple_search_memory): Likewise.
9630 * printcmd.c (find_string_backward): Use gdb::byte_vector.
9631 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
9632 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
9633 * elfread.c (elf_rel_plt_read): Use std::string.
9634 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
9635 * cli/cli-dump.c (restore_section_callback): Use
9636 gdb::byte_vector.
9637
7c218e6c
TT
96382017-08-03 Tom Tromey <tom@tromey.com>
9639
9640 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
9641
31b68d4a
TT
96422017-08-03 Tom Tromey <tom@tromey.com>
9643
9644 * tui/tui-regs.c (tui_restore_gdbout): Remove.
9645 (tui_register_format): Use scoped_restore.
9646
2ec845e7
TT
96472017-08-03 Tom Tromey <tom@tromey.com>
9648
9649 * reverse.c (exec_direction_default): Remove.
9650 (exec_reverse_once): Use scoped_restore.
9651 * remote.c (restore_remote_timeout): Remove.
9652 (remote_flash_erase, remote_flash_write, remote_flash_done)
9653 (readchar, remote_serial_write): Use scoped_restore.
9654 * cli/cli-script.c (struct source_cleanup_lines_args)
9655 (source_cleanup_lines): Remove.
9656 (script_from_file): Use scoped_restore.
9657 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
9658 (source_command): Use scoped_restore.
9659
b3bc8453
TT
96602017-08-03 Tom Tromey <tom@tromey.com>
9661
9662 * utils.h (make_cleanup_free_so): Remove.
9663 * utils.c (do_free_so, make_cleanup_free_so): Remove.
9664 * solist.h (struct so_deleter): New.
9665 (so_list_up): New typedef.
9666 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
9667
e3ad2841
TT
96682017-08-03 Tom Tromey <tom@tromey.com>
9669
9670 * utils.h (make_cleanup_restore_current_language): Remove.
9671 * utils.c (do_restore_current_language)
9672 (make_cleanup_restore_current_language): Remove.
9673 * parse.c (parse_exp_in_context_1)
9674 (parse_expression_with_language): Use
9675 scoped_restore_current_language.
9676 * mi/mi-main.c (mi_cmd_execute): Use
9677 scoped_restore_current_language.
9678 * language.h (scoped_restore_current_language): New class.
9679
b80cf838
TT
96802017-08-03 Tom Tromey <tom@tromey.com>
9681
9682 * compile/compile.c (cleanup_unlink_file): Remove.
9683 (compile_to_object): Use gdb::unlinker.
9684 (eval_compile_command): Likewise.
9685
fad0444a
TT
96862017-08-03 Tom Tromey <tom@tromey.com>
9687
9688 * utils.h (make_cleanup_fclose): Remove.
9689 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
9690
6e7bc05c
TT
96912017-08-03 Tom Tromey <tom@tromey.com>
9692
9693 * top.c (open_terminal_stream): Return gdb_file_up.
9694 (new_ui_command): Update.
9695
4a45905b
TT
96962017-08-03 Tom Tromey <tom@tromey.com>
9697
9698 * source.c (print_source_lines_base, forward_search_command)
9699 (reverse_search_command): Use gdb_file_up.
9700
7cd06d6e
TT
97012017-08-03 Tom Tromey <tom@tromey.com>
9702
9703 * fbsd-nat.c (fbsd_find_memory_regions): Update.
9704
ed166945
TT
97052017-08-03 Tom Tromey <tom@tromey.com>
9706
9707 * cli/cli-cmds.c (find_and_open_script): Change return type.
9708 Remove "streamp" and "full_path" parameters.
9709 (source_script_with_search): Update.
9710 * auto-load.c (source_script_file): Update.
9711 * cli/cli-cmds.h (find_and_open_script): Change type.
9712 (open_script): New struct.
9713
d419f42d
TT
97142017-08-03 Tom Tromey <tom@tromey.com>
9715
9716 * xml-support.c (xml_fetch_content_from_file): Update.
9717 * ui-file.c (stdio_file::open): Update.
9718 * tracefile-tfile.c (tfile_start): Update.
9719 * remote.c (remote_file_put, remote_file_get): Update.
9720 * nat/linux-procfs.c (linux_proc_get_int)
9721 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
9722 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
9723 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
9724 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
9725 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
9726 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
9727 * linux-nat.c (linux_proc_pending_signals): Update.
9728 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
9729 (file_closer): Remove.
9730 * compile/compile.c (compile_to_object): Update.
9731 * common/filestuff.h (struct gdb_file_deleter): New.
9732 (gdb_file_up): New typedef.
9733 (gdb_fopen_cloexec): Change return type.
9734 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
9735 * cli/cli-dump.c (fopen_with_cleanup): Remove.
9736 (dump_binary_file, restore_binary_file): Update.
9737 * auto-load.c (auto_load_objfile_script_1): Update.
9738
4a2b031d
TT
97392017-08-03 Tom Tromey <tom@tromey.com>
9740
9741 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
9742 (info_static_tracepoint_markers_command): Likewise.
9743 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
9744 * skip.c (skip_info): Use ui_out_emit_table.
9745 * progspace.c (print_program_space): Use ui_out_emit_table.
9746 * osdata.c (info_osdata): Use ui_out_emit_table.
9747 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
9748 ui_out_emit_table.
9749 * linux-thread-db.c (info_auto_load_libthread_db): Use
9750 ui_out_emit_table.
9751 * inferior.c (print_inferior): Use ui_out_emit_table.
9752 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
9753 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
9754 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
9755 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
9756 * ui-out.h (class ui_out_emit_table): New.
9757
a4f320fd
MR
97582017-08-02 Maciej W. Rozycki <macro@imgtec.com>
9759
9760 * mips-tdep.c (mips_fpu_type_str): New function.
9761 (mips_dump_tdep): Call it.
9762
a2f1f308
MR
97632017-08-01 Maciej W. Rozycki <macro@imgtec.com>
9764
9765 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
9766 `->mips_fpu_type'.
9767
7e5ed83b
XR
97682017-07-31 Xavier Roirand <roirand@adacore.com>
9769
9770 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
9771
4c9dc811
XR
97722017-07-27 Xavier Roirand <roirand@adacore.com>
9773
9774 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
9775
27d41eac
YQ
97762017-07-26 Yao Qi <yao.qi@linaro.org>
9777
9778 * cli/cli-cmds.c (maintenancechecklist): New variable.
9779 * gdbcmd.h (maintenancechecklist): Declare it.
9780 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
9781 Call i386_linux_read_description with different masks.
9782 * maint.c (maintenance_check_command): New function.
9783 (_initialize_maint_cmds): Call add_prefix_cmd.
9784 * target-descriptions.c (tdesc_reg): override operator != and ==.
9785 (tdesc_type): Likewise.
9786 (tdesc_feature): Likewise.
9787 (target_desc): Likewise.
9788 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
9789 (maintenance_check_xml_descriptions): New function.
9790 (_initialize_target_descriptions) Add command "xml-descriptions".
9791 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
9792
ea03d0d3
YQ
97932017-07-26 Yao Qi <yao.qi@linaro.org>
9794
9795 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
9796 Include features/i386/32bit-*.c.
9797 (i386_linux_read_description): Generate target description if it
9798 doesn't exist.
9799 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
9800 functions.
9801 * features/i386/32bit-linux.c: Re-generated.
9802 * features/i386/32bit-sse.c: Likewise.
9803 * target-descriptions.c (print_c_feature::visit): Print code to
9804 set register number if needed.
9805 (print_c_feature) <m_next_regnum>: New field.
9806
25aa13e5
YQ
98072017-07-26 Yao Qi <yao.qi@linaro.org>
9808
9809 * features/Makefile (CFILES): Rename with TDESC_CFILES.
9810 (FEATURE_XMLFILES): New.
9811 (FEATURE_CFILES): New.
9812 New rules.
9813 (clean-cfiles): Remove generated c files.
9814 * features/i386/32bit-avx.c: Generated.
9815 * features/i386/32bit-avx512.c: Generated.
9816 * features/i386/32bit-core.c: Generated.
9817 * features/i386/32bit-linux.c: Generated.
9818 * features/i386/32bit-mpx.c: Generated.
9819 * features/i386/32bit-pkeys.c: Generated.
9820 * features/i386/32bit-sse.c: Generated.
9821 * target-descriptions.c: Include algorithm.
9822 (tdesc_element_visitor): Add method visit_end.
9823 (print_c_tdesc): Implement visit_end.
9824 (print_c_tdesc:: m_filename_after_features): Move it to
9825 protected.
9826 (print_c_feature): New class.
9827 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
9828 name starts with "i386/32bit-".
9829
6eb1e6a8
YQ
98302017-07-26 Yao Qi <yao.qi@linaro.org>
9831
9832 * target-descriptions.c (tdesc_element_visitor): New class.
9833 (tdesc_element): New class.
9834 (tdesc_reg): Inherit from tdesc_element.
9835 (tdesc_reg::accept): New function.
9836 (tdesc_type): Inherit from tdesc_element.
9837 (tdesc_type::accept): New function.
9838 (tdesc_feature): Inherit from tdesc_element.
9839 (tdesc_feature::accept): New function.
9840 (target_desc): Inherit from tdesc_element.
9841 (target_desc::target_desc): New.
9842 (target_desc::~target_desc): New.
9843 (target_desc::accept): New.
9844 (allocate_target_description): Use new.
9845 (free_target_description): Use delete.
9846 (print_c_tdesc): New class.
9847 (maint_print_c_tdesc_cmd): Adjust.
9848
9849 * features/aarch64.c: Re-generated.
9850 * features/arc-arcompact.c: Re-generated.
9851 * features/arc-v2.c: Re-generated.
9852 * features/arm/arm-with-iwmmxt.c: Re-generated.
9853 * features/arm/arm-with-m.c: Re-generated.
9854 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
9855 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
9856 * features/arm/arm-with-neon.c: Re-generated.
9857 * features/arm/arm-with-vfpv2.c: Re-generated.
9858 * features/arm/arm-with-vfpv3.c: Re-generated.
9859 * features/i386/amd64-avx-avx512.c: Re-generated.
9860 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9861 * features/i386/amd64-avx.c: Re-generated.
9862 * features/i386/amd64-avx-linux.c: Re-generated.
9863 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
9864 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9865 * features/i386/amd64-avx-mpx.c: Re-generated.
9866 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
9867 * features/i386/amd64.c: Re-generated.
9868 * features/i386/amd64-linux.c: Re-generated.
9869 * features/i386/amd64-mpx.c: Re-generated.
9870 * features/i386/amd64-mpx-linux.c: Re-generated.
9871 * features/i386/i386-avx-avx512.c: Re-generated.
9872 * features/i386/i386-avx-avx512-linux.c: Re-generated.
9873 * features/i386/i386-avx.c: Re-generated.
9874 * features/i386/i386-avx-linux.c: Re-generated.
9875 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
9876 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
9877 * features/i386/i386-avx-mpx.c: Re-generated.
9878 * features/i386/i386-avx-mpx-linux.c: Re-generated.
9879 * features/i386/i386.c: Re-generated.
9880 * features/i386/i386-linux.c: Re-generated.
9881 * features/i386/i386-mmx.c: Re-generated.
9882 * features/i386/i386-mmx-linux.c: Re-generated.
9883 * features/i386/i386-mpx.c: Re-generated.
9884 * features/i386/i386-mpx-linux.c: Re-generated.
9885 * features/i386/x32-avx-avx512.c: Re-generated.
9886 * features/i386/x32-avx-avx512-linux.c: Re-generated.
9887 * features/i386/x32-avx.c: Re-generated.
9888 * features/i386/x32-avx-linux.c: Re-generated.
9889 * features/i386/x32.c: Re-generated.
9890 * features/i386/x32-linux.c: Re-generated.
9891 * features/microblaze.c: Re-generated.
9892 * features/microblaze-with-stack-protect.c: Re-generated.
9893 * features/mips64-dsp-linux.c: Re-generated.
9894 * features/mips64-linux.c: Re-generated.
9895 * features/mips-dsp-linux.c: Re-generated.
9896 * features/mips-linux.c: Re-generated.
9897 * features/nds32.c: Re-generated.
9898 * features/nios2.c: Re-generated.
9899 * features/nios2-linux.c: Re-generated.
9900 * features/rs6000/powerpc-32.c: Re-generated.
9901 * features/rs6000/powerpc-32l.c: Re-generated.
9902 * features/rs6000/powerpc-403.c: Re-generated.
9903 * features/rs6000/powerpc-403gc.c : Re-generated.
9904 * features/rs6000/powerpc-405.c: Re-generated.
9905 * features/rs6000/powerpc-505.c: Re-generated.
9906 * features/rs6000/powerpc-601.c: Re-generated.
9907 * features/rs6000/powerpc-602.c: Re-generated.
9908 * features/rs6000/powerpc-603.c: Re-generated.
9909 * features/rs6000/powerpc-604.c: Re-generated.
9910 * features/rs6000/powerpc-64.c: Re-generated.
9911 * features/rs6000/powerpc-64l.c: Re-generated.
9912 * features/rs6000/powerpc-7400.c: Re-generated.
9913 * features/rs6000/powerpc-750.c: Re-generated.
9914 * features/rs6000/powerpc-860.c: Re-generated.
9915 * features/rs6000/powerpc-altivec32.c: Re-generated.
9916 * features/rs6000/powerpc-altivec32l.c: Re-generated.
9917 * features/rs6000/powerpc-altivec64.c: Re-generated.
9918 * features/rs6000/powerpc-altivec64l.c: Re-generated.
9919 * features/rs6000/powerpc-cell32l.c: Re-generated.
9920 * features/rs6000/powerpc-cell64l.c: Re-generated.
9921 * features/rs6000/powerpc-e500.c: Re-generated.
9922 * features/rs6000/powerpc-e500l.c: Re-generated.
9923 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
9924 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
9925 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
9926 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
9927 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
9928 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
9929 * features/rs6000/powerpc-vsx32.c: Re-generated.
9930 * features/rs6000/powerpc-vsx32l.c: Re-generated.
9931 * features/rs6000/powerpc-vsx64.c: Re-generated.
9932 * features/rs6000/powerpc-vsx64l.c: Re-generated.
9933 * features/rs6000/rs6000.c: Re-generated.
9934 * features/s390-linux32.c: Re-generated.
9935 * features/s390-linux32v1.c: Re-generated.
9936 * features/s390-linux32v2.c: Re-generated.
9937 * features/s390-linux64.c: Re-generated.
9938 * features/s390-linux64v1.c: Re-generated.
9939 * features/s390-linux64v2.c: Re-generated.
9940 * features/s390-te-linux64.c: Re-generated.
9941 * features/s390-tevx-linux64.c: Re-generated.
9942 * features/s390-vx-linux64.c: Re-generated.
9943 * features/s390x-linux64.c: Re-generated.
9944 * features/s390x-linux64v1.c: Re-generated.
9945 * features/s390x-linux64v2.c: Re-generated.
9946 * features/s390x-te-linux64.c: Re-generated.
9947 * features/s390x-tevx-linux64.c: Re-generated.
9948 * features/s390x-vx-linux64.c: Re-generated.
9949 * features/sparc/sparc32-solaris.c: Re-generated.
9950 * features/sparc/sparc64-solaris.c: Re-generated.
9951 * features/tic6x-c62x.c: Re-generated.
9952 * features/tic6x-c62x-linux.c: Re-generated.
9953 * features/tic6x-c64x.c: Re-generated.
9954 * features/tic6x-c64x-linux.c: Re-generated.
9955 * features/tic6x-c64xp.c: Re-generated.
9956 * features/tic6x-c64xp-linux.c: Re-generated.
9957
35b4818d
YQ
99582017-07-26 Yao Qi <yao.qi@linaro.org>
9959
9960 * i386-linux-tdep.c (i386_linux_read_description): New function.
9961 (i386_linux_core_read_description): Call
9962 i386_linux_read_description.
9963 * i386-linux-tdep.h (i386_linux_read_description): Declare.
9964 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
9965 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
9966 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
9967 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
9968 * x86-linux-nat.c (x86_linux_read_description): Call
9969 i386_linux_read_description.
9970
8e2141c6
YQ
99712017-07-26 Yao Qi <yao.qi@linaro.org>
9972
9973 * NEWS: Mention it.
9974 * features/Makefile (%.c: %.xml): Pass the xml file name to
9975 command "maint print c-tdesc".
9976 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
9977 name from 'arg'.
9978
b468ff4c
YQ
99792017-07-26 Yao Qi <yao.qi@linaro.org>
9980
9981 * target-descriptions.c (target_desc): Add ctor and dtor. Do
9982 in-class initialization.
9983 (tdesc_create_feature): Call new instead of XCNEW.
9984 (free_target_description): Ue delete.
9985
b9c0e1b4
JB
99862017-07-25 John Baldwin <jhb@FreeBSD.org>
9987
9988 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
9989
a04b5337
YQ
99902017-07-25 Yao Qi <yao.qi@linaro.org>
9991
9992 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
9993 constant.
9994 (amd64_x32_init_abi): Likewise.
9995 * amd64-tdep.h (amd64_init_abi): Update declaration.
9996 (amd64_x32_init_abi): Likewise.
9997
02ad7fc2
YQ
99982017-07-25 Yao Qi <yao.qi@linaro.org>
9999
10000 PR tdep/21717
10001 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
10002 condition for FPSCR.
10003 (arm_linux_store_inferior_registers): Likewise.
10004
b6f48cb0
TT
100052017-07-22 Tom Tromey <tom@tromey.com>
10006
10007 * break-catch-syscall.c (struct catch_syscall_inferior_data)
10008 <syscalls_counts>: Now a std::vector.
10009 (get_catch_syscall_inferior_data): Use "new".
10010 (catch_syscall_inferior_data_cleanup): Use "delete".
10011 (insert_catch_syscall, remove_catch_syscall)
10012 (clear_syscall_counts): Update.
10013
e12c9b7a
TT
100142017-07-22 Tom Tromey <tom@tromey.com>
10015
10016 * break-catch-syscall.c (syscall_catchpoint)
10017 <syscalls_to_be_caught>: Now a std::vector<int>
10018 (~syscall_catchpoint): Remove.
10019 (insert_catch_syscall, remove_catch_syscall)
10020 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
10021 (print_mention_catch_syscall, print_recreate_catch_syscall):
10022 Update.
10023 (create_syscall_event_catchpoint): Change type of "filter"
10024 parameter.
10025 (catch_syscall_split_args): Return a std::vector.
10026 (catch_syscall_command_1, catching_syscall_number_1): Update.
10027
4fa8aeac
TT
100282017-07-22 Tom Tromey <tom@tromey.com>
10029
10030 * break-catch-throw.c (struct exception_catchpoint)
10031 <exception_rx>: Now a std::string.
10032 (~exception_catchpoint): Remove.
10033 (print_one_detail_exception_catchpoint): Update.
10034 (handle_gnu_v3_exceptions): Change type of except_rx.
10035 (extract_exception_regexp): Return a std::string.
10036 (catch_exception_command_1): Update.
10037
f746a154
TT
100382017-07-22 Tom Tromey <tom@tromey.com>
10039
10040 * break-catch-sig.c (gdb_signal_type): Remove typedef.
10041 (struct signal_catchpoint) <signals_to_be_caught>: Now a
10042 std::vector.
10043 <catch_all>: Now a bool.
10044 (~signal_catchpoint): Remove.
10045 (signal_catchpoint_insert_location)
10046 (signal_catchpoint_remove_location)
10047 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
10048 (signal_catchpoint_print_mention)
10049 (signal_catchpoint_print_recreate)
10050 (signal_catchpoint_explains_signal): Update.
10051 (create_signal_catchpoint): Change type of "filter" and
10052 "catch_all".
10053 (catch_signal_split_args): Return a std::vector. Change type of
10054 "catch_all".
10055 (catch_signal_command): Update.
10056
47e77640
PA
100572017-07-20 Pedro Alves <palves@redhat.com>
10058
10059 * ada-lang.c (ada_language_defn): Make extern.
10060 (_initialize_ada_language): Remove add_language call.
10061 * c-lang.c (c_language_defn, cplus_language_defn)
10062 (asm_language_defn, minimal_language_defn): Make extern.
10063 (_initialize_c_language): Delete.
10064 * completer.c (compare_cstrings): Delete, moved to utils.h.
10065 * d-lang.c (d_language_defn): Make extern.
10066 (_initialize_d_language): Remove add_language calls.
10067 * defs.h (enum language): Add comment.
10068 * f-lang.c (f_language_defn): Make extern.
10069 (_initialize_f_language): Remove add_language call.
10070 * go-lang.c (go_language_defn): Make extern.
10071 (_initialize_go_language): Remove add_language call.
10072 * language.c: Include <algorithm>.
10073 (languages): Redefine as const array.
10074 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
10075 (set_language_command): Handle "local". Use for-range loop.
10076 (set_language): Remove loop.
10077 (language_enum): Rewrite.
10078 (language_def, language_str): Remove loops.
10079 (add_language): Delete.
10080 (add_set_language_command): New, based on add_languages.
10081 (skip_language_trampoline): Adjust.
10082 (local_language_defn): Delete.
10083 (language_gdbarch_post_init): Adjust.
10084 (_initialize_language): Remove add_language calls. Call
10085 add_set_language_command.
10086 * language.h (add_language): Delete.
10087 (auto_language_defn)
10088 (unknown_language_defn, minimal_language_defn, ada_language_defn)
10089 (asm_language_defn, c_language_defn, cplus_language_defn)
10090 (d_language_defn, f_language_defn, go_language_defn)
10091 (m2_language_defn, objc_language_defn, opencl_language_defn)
10092 (pascal_language_defn, rust_language_defn): Declare.
10093 * m2-lang.c (m2_language_defn): Make extern.
10094 (_initialize_m2_language): Remove add_language call.
10095 * objc-lang.c (objc_language_defn): Make extern.
10096 (_initialize_objc_language): Remove add_language call.
10097 * opencl-lang.c (opencl_language_defn): Make extern.
10098 (_initialize_opencl_language): Remove add_language call.
10099 * p-lang.c (pascal_language_defn): Make extern.
10100 (_initialize_pascal_language): Delete.
10101 * rust-lang.c (rust_language_defn): Make extern.
10102 (_initialize_rust_language): Delete.
10103 * utils.h (compare_cstrings): New static inline function.
10104
edb0c9cb
PA
101052017-07-20 Pedro Alves <palves@redhat.com>
10106
10107 * ada-lang.c (ada_to_fixed_type_1): Adjust.
10108 (get_var_value): Constify parameters.
10109 (get_int_var_value): Change prototype.
10110 (to_fixed_range_type): Adjust.
10111 * ada-lang.h (get_int_var_value): Change prototype.
10112
a778f165
PA
101132017-07-20 Pedro Alves <palves@redhat.com>
10114
10115 * dwarf2read.c (dw2_lookup_symbol): Use
10116 SYMBOL_MATCHES_SEARCH_NAME.
10117 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
10118
42edd901
PA
101192017-07-20 Pedro Alves <palves@redhat.com>
10120
10121 * block.c (block_iter_name_step, block_iter_name_first)
10122 (block_iter_name_next): Delete.
10123 (block_lookup_symbol_primary): Adjust to use
10124 dict_iter_match_first/dict_iter_match_next.
10125 * block.h (block_iter_name_first, block_iter_name_next): Delete
10126 declarations.
10127 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
10128 dict_iter_match_first/dict_iter_match_next.
10129
cf325299
PA
101302017-07-20 Pedro Alves <palves@redhat.com>
10131
10132 * cp-support.c (cp_find_first_component_aux): Add missing case for
10133 end of string.
10134
c5ed0576
DB
101352017-07-18 David Blaikie <dblaikie@gmail.com>
10136
10137 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
10138 of dwo_cu's dwo_file.
10139
27841e76
YQ
101402017-07-18 Yao Qi <yao.qi@linaro.org>
10141
10142 * remote.c (store_registers_using_G): Remove one line comment.
10143
cfb7e58b
YQ
101442017-07-18 Yao Qi <yao.qi@linaro.org>
10145
10146 * regcache.c (regcache_cpy): Simplify it.
10147 (regcache::cpy_no_passthrough): Remove it.
10148 * regcache.h (cpy_no_passthrough): Remove it.
10149 (regcache_dup, regcache_cpy): Update comments.
10150
386535dd
PA
101512017-07-18 Pedro Alves <palves@redhat.com>
10152
10153 * remote-sim.c (sim_command_completer): Adjust to work with a
10154 completion_tracker instead of a VEC.
10155
c45ec17c
PA
101562017-07-17 Pedro Alves <palves@redhat.com>
10157
10158 * completer.c (complete_source_filenames): New function.
10159 (complete_address_and_linespec_locations): New function.
10160 (location_completer): Use complete_address_and_linespec_locations.
10161 (completion_tracker::build_completion_result): Honor the tracker's
10162 request to suppress append.
10163 * completer.h (completion_tracker::suppress_append_ws)
10164 (completion_tracker::set_suppress_append_ws): New methods.
10165 (completion_tracker::m_suppress_append_ws): New field.
10166 (complete_source_filenames): New declaration.
10167 * linespec.c (linespec_complete_what): New.
10168 (struct ls_parser) <complete_what, completion_word,
10169 completion_quote_char, completion_quote_end, completion_tracker>:
10170 New fields.
10171 (string_find_incomplete_keyword_at_end): New.
10172 (linespec_lexer_lex_string): Record quote char. If in completion
10173 mode, don't throw.
10174 (linespec_lexer_consume_token): Advance the completion word point.
10175 (linespec_lexer_peek_token): Save/restore completion info.
10176 (save_stream_and_consume_token): New.
10177 (set_completion_after_number): New.
10178 (linespec_parse_basic): Set what to complete next depending on
10179 token. Handle function and label completions specially.
10180 (parse_linespec): Disable objc shortcut in completion mode. Set
10181 what to complete next depending on token type. Skip keyword if in
10182 completion mode.
10183 (complete_linespec_component, linespec_complete): New.
10184 * linespec.h (linespec_complete): Declare.
10185
be966d42
PA
101862017-07-17 Pedro Alves <palves@redhat.com>
10187
10188 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
10189 Handle 'operator<' / 'operator<<'.
10190
a2459270
PA
101912017-07-17 Pedro Alves <palves@redhat.com>
10192
10193 * completer.c (collect_explicit_location_matches): Handle
10194 MATCH_LABEL.
10195 (convert_explicit_location_to_linespec): New, factored out from
10196 ...
10197 (convert_explicit_location_to_sals): ... this.
10198 (complete_label): New.
10199 (linespec_complete_label, find_label_symbols_in_block): New.
10200 (find_label_symbols): Add completion_mode parameter and adjust to
10201 call find_label_symbols_in_block.
10202 * linespec.h (linespec_complete_label): Declare.
10203
c6756f62
PA
102042017-07-17 Pedro Alves <palves@redhat.com>
10205
10206 * ada-lang.c (ada_collect_symbol_completion_matches): Add
10207 complete_symbol_mode parameter.
10208 * cli/cli-cmds.c (complete_command): Get the completion result out
10209 of the handle_brkchars tracker if used a custom word point.
10210 * completer.c: Include "linespec.h".
10211 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
10212 (advance_to_expression_complete_word_point): New.
10213 (completion_tracker::completes_to_completion_word): New.
10214 (complete_files_symbols): Pass down
10215 complete_symbol_mode::EXPRESSION.
10216 (explicit_options, probe_options): New.
10217 (collect_explicit_location_matches): Complete on the
10218 explictit_loc->foo instead of word. Use
10219 linespec_complete_function. Handle MATCH_LINE. Handle offering
10220 keyword and options completions.
10221 (backup_text_ptr): Delete.
10222 (skip_keyword): New.
10223 (complete_explicit_location): Remove 'word' parameter. Add
10224 language, quoted_arg_start and quoted_arg_end parameters.
10225 Rewrite, parsing left to right.
10226 (location_completer): Rewrite.
10227 (location_completer_handle_brkchars): New function.
10228 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
10229 (enum complete_line_internal_reason): Adjust comments.
10230 (completion_tracker::discard_completions): New.
10231 (completer_handle_brkchars_func_for_completer): Handle
10232 location_completer.
10233 (gdb_custom_word_point_brkchars)
10234 (gdb_org_rl_basic_quote_characters): New.
10235 (gdb_completion_word_break_characters_throw)
10236 (completion_find_completion_word): Handle trackers that use a
10237 custom word point.
10238 (completion_tracker::advance_custom_word_point_by): New.
10239 (completion_tracker::build_completion_result): Don't rely on
10240 readline appending the quote char.
10241 (gdb_rl_attempted_completion_function_throw): Handle trackers that
10242 use a custom word point.
10243 (gdb_rl_attempted_completion_function): Restore
10244 rl_basic_quote_characters.
10245 * completer.h (class completion_tracker): Extend intro comment.
10246 (completion_tracker::set_quote_char)
10247 (completion_tracker::quote_char)
10248 (completion_tracker::set_use_custom_word_point)
10249 (completion_tracker::use_custom_word_point)
10250 (completion_tracker::custom_word_point)
10251 (completion_tracker::set_custom_word_point)
10252 (completion_tracker::advance_custom_word_point_by)
10253 (completion_tracker::completes_to_completion_word)
10254 (completion_tracker::discard_completions): New methods.
10255 (completion_tracker::m_quote_char)
10256 (completion_tracker::m_use_custom_word_point)
10257 (completion_tracker::m_custom_word_point): New fields.
10258 (advance_to_expression_complete_word_point): Declare.
10259 * f-lang.c (f_collect_symbol_completion_matches): Add
10260 complete_symbol_mode parameter.
10261 * language.h (struct language_defn)
10262 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
10263 parameter.
10264 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
10265 (linespec_complete_function): New function.
10266 (linespec_lexer_lex_keyword): Adjust.
10267 * linespec.h (linespec_keywords, linespec_complete_function): New
10268 declarations.
10269 * location.c (find_end_quote): New function.
10270 (explicit_location_lex_one): Add explicit_completion_info
10271 parameter. Save quoting info. Don't throw if being called for
10272 completion. Don't handle Ada operators here.
10273 (is_cp_operator, skip_op_false_positives, first_of)
10274 (explicit_location_lex_one_function): New function.
10275 (string_to_explicit_location): Replace 'dont_throw' parameter with
10276 an explicit_completion_info pointer parameter. Handle it. Don't
10277 use explicit_location_lex_one to lex function names. Use
10278 explicit_location_lex_one_function instead.
10279 * location.h (struct explicit_completion_info): New.
10280 (string_to_explicit_location): Replace 'dont_throw' parameter with
10281 an explicit_completion_info pointer parameter.
10282 * symtab.c (default_collect_symbol_completion_matches_break_on):
10283 Add complete_symbol_mode parameter. Handle LINESPEC mode.
10284 (default_collect_symbol_completion_matches)
10285 (collect_symbol_completion_matches): Add complete_symbol_mode
10286 parameter.
10287 (collect_symbol_completion_matches_type): Pass down
10288 complete_symbol_mode::EXPRESSION.
10289 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10290 parameter. Handle LINESPEC mode.
10291 * symtab.h (complete_symbol_mode): New.
10292 (default_collect_symbol_completion_matches_break_on)
10293 (default_collect_symbol_completion_matches)
10294 (collect_symbol_completion_matches)
10295 (collect_file_symbol_completion_matches): Add complete_symbol_mode
10296 parameter.
10297
1d550c82
PA
102982017-07-17 Pedro Alves <palves@redhat.com>
10299
10300 * utils.c (enum class strncmp_iw_mode): New.
10301 (strcmp_iw): Rename to ...
10302 (strncmp_iw_with_mode): ... this. Add string2_len and mode
10303 parameters. Handle them.
10304 (strncmp_iw): New.
10305 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
10306 * utils.h (strncmp_iw): Declare.
10307 (strcmp_iw): Move describing comments here.
10308
8090b426
PA
103092017-07-17 Pedro Alves <palves@redhat.com>
10310
10311 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
10312 CP_OPERATOR_STR.
10313 * c-typeprint.c (is_type_conversion_operator): Use
10314 CP_OPERATOR_STR.
10315 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
10316 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
10317 CP_OPERATOR_LEN.
10318 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
10319 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
10320 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
10321 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
10322 CP_OPERATOR_STR.
10323 * location.c: Include "cp-support.h".
10324 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
10325 CP_OPERATOR_STR.
10326 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
10327 CP_OPERATOR_LEN.
10328
6a2c1b87
PA
103292017-07-17 Pedro Alves <palves@redhat.com>
10330
10331 * cli/cli-cmds.c (complete_command): Use a completion tracker
10332 along with completion_find_completion_word for handle_brkchars
10333 phase.
10334 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
10335 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
10336 (struct gdb_rl_completion_word_info): New.
10337 (gdb_rl_find_completion_word): New.
10338 (completion_find_completion_word): New.
10339 * completer.h (completion_find_completion_word): Declare.
10340
eb3ff9a5
PA
103412017-07-17 Pedro Alves <palves@redhat.com>
10342
10343 * ada-lang.c (symbol_completion_match): Adjust comments.
10344 (symbol_completion_add): Replace vector parameter with
10345 completion_tracker parameter. Use it.
10346 (ada_make_symbol_completion_list): Rename to...
10347 (ada_collect_symbol_completion_matches): ... this. Add
10348 completion_tracker parameter and use it.
10349 (ada_language_defn): Adjust.
10350 * break-catch-syscall.c (catch_syscall_completer): Adjust
10351 prototype and work with completion_tracker instead of VEC.
10352 * breakpoint.c (condition_completer): Adjust prototype and work
10353 with completion_tracker instead of VEC.
10354 * c-lang.c (c_language_defn, cplus_language_defn)
10355 (asm_language_defn, minimal_language_defn): Adjust to renames.
10356 * cli/cli-cmds.c (complete_command): Rework using
10357 completion_tracker. Catch exceptions when completing.
10358 * cli/cli-decode.c (integer_unlimited_completer)
10359 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
10360 with completion_tracker instead of VEC.
10361 * command.h (struct completion_tracker): Forward declare.
10362 (completer_ftype, completer_handle_brkchars_ftype): Change
10363 types.
10364 (complete_on_cmdlist, complete_on_enum): Adjust.
10365 * completer.c: Include <algorithm>.
10366 (struct gdb_completer_state): New.
10367 (current_completion): New global.
10368 (readline_line_completion_function): Delete.
10369 (noop_completer, filename_completer)
10370 (filename_completer_handle_brkchars, complete_files_symbols)
10371 (linespec_location_completer): Adjust to work with a
10372 completion_tracker instead of a VEC.
10373 (string_or_empty): New.
10374 (collect_explicit_location_matches): Adjust to work with a
10375 completion_tracker instead of a VEC.
10376 (explicit_location_completer): Rename to ...
10377 (complete_explicit_location): ... this and adjust to work with a
10378 completion_tracker instead of a VEC.
10379 (location_completer): Adjust to work with a completion_tracker
10380 instead of a VEC.
10381 (add_struct_fields): Adjust to work with a completion_list instead
10382 of VEC.
10383 (expression_completer): Rename to ...
10384 (complete_expression): ... this and adjust to work with a
10385 completion_tracker instead of a VEC. Use complete_files_symbols.
10386 (expression_completer): Reimplement on top of complete_expression.
10387 (symbol_completer): Adjust to work with a completion_tracker
10388 instead of a VEC.
10389 (enum complete_line_internal_reason): Add describing comments.
10390 (complete_line_internal_normal_command): Adjust to work with a
10391 completion_tracker instead of a VEC.
10392 (complete_line_internal): Rename to ...
10393 (complete_line_internal_1): ... this and adjust to work with a
10394 completion_tracker instead of a VEC. Assert TEXT is NULL in the
10395 handle_brkchars phase.
10396 (new_completion_tracker): Delete.
10397 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
10398 complete_line_internal_1.
10399 (free_completion_tracker): Delete.
10400 (INITIAL_COMPLETION_HTAB_SIZE): New.
10401 (completion_tracker::completion_tracker)
10402 (completion_tracker::~completion_tracker): New.
10403 (maybe_add_completion): Delete.
10404 (completion_tracker::maybe_add_completion)
10405 (completion_tracker::add_completion)
10406 (completion_tracker::add_completions): New.
10407 (throw_max_completions_reached_error): Delete.
10408 (complete_line): Adjust to work with a completion_tracker instead
10409 of a VEC. Don't create a completion_tracker_t or check for max
10410 completions here.
10411 (command_completer, command_completer_handle_brkchars)
10412 (signal_completer, reg_or_group_completer_1)
10413 (reg_or_group_completer, default_completer_handle_brkchars):
10414 Adjust to work with a completion_tracker.
10415 (gdb_completion_word_break_characters_throw): New.
10416 (gdb_completion_word_break_characters): Reimplement.
10417 (line_completion_function): Delete.
10418 (completion_tracker::recompute_lowest_common_denominator)
10419 (expand_preserving_ws)
10420 (completion_tracker::build_completion_result)
10421 (completion_result::completion_result)
10422 (completion_result::completion_result)
10423 (completion_result::~completion_result)
10424 (completion_result::completion_result)
10425 (completion_result::release_match_list, compare_cstrings)
10426 (completion_result::sort_match_list)
10427 (completion_result::reset_match_list)
10428 (gdb_rl_attempted_completion_function_throw)
10429 (gdb_rl_attempted_completion_function): New.
10430 * completer.h (completion_list, struct completion_result)
10431 (class completion_tracker): New.
10432 (complete_line): Add completion_tracker parameter.
10433 (readline_line_completion_function): Delete.
10434 (gdb_rl_attempted_completion_function): New.
10435 (noop_completer, filename_completer, expression_completer)
10436 (location_completer, symbol_completer, command_completer)
10437 (signal_completer, reg_or_group_completer): Update prototypes.
10438 (completion_tracker_t, new_completion_tracker)
10439 (make_cleanup_free_completion_tracker): Delete.
10440 (enum maybe_add_completion_enum): Delete.
10441 (maybe_add_completion): Delete.
10442 (throw_max_completions_reached_error): Delete.
10443 * corefile.c (complete_set_gnutarget): Adjust to work with a
10444 completion_tracker instead of a VEC.
10445 * cp-abi.c (cp_abi_completer): Adjust to work with a
10446 completion_tracker instead of a VEC.
10447 * d-lang.c (d_language_defn): Adjust.
10448 * disasm.c (disassembler_options_completer): Adjust to work with a
10449 completion_tracker instead of a VEC.
10450 * f-lang.c (f_make_symbol_completion_list): Rename to ...
10451 (f_collect_symbol_completion_matches): ... this. Adjust to work
10452 with a completion_tracker instead of a VEC.
10453 (f_language_defn): Adjust.
10454 * go-lang.c (go_language_defn): Adjust.
10455 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
10456 Adjust to work with a completion_tracker instead of a VEC.
10457 * infrun.c (handle_completer): Likewise.
10458 * interps.c (interpreter_completer): Likewise.
10459 * interps.h (interpreter_completer): Likewise.
10460 * language.c (unknown_language_defn, auto_language_defn)
10461 (local_language_defn): Adjust.
10462 * language.h (language_defn::la_make_symbol_completion_list):
10463 Rename to ...
10464 (language_defn::la_collect_symbol_completion_matches): ... this
10465 and adjust to work with a completion_tracker instead of a VEC.
10466 * m2-lang.c (m2_language_defn): Adjust.
10467 * objc-lang.c (objc_language_defn): Adjust.
10468 * opencl-lang.c (opencl_language_defn): Adjust.
10469 * p-lang.c (pascal_language_defn): Adjust.
10470 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
10471 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
10472 with a completion_tracker.
10473 * rust-lang.c (rust_language_defn): Adjust.
10474 * symtab.c (free_completion_list, do_free_completion_list)
10475 (return_val, completion_tracker): Delete.
10476 (completion_list_add_name, completion_list_add_symbol)
10477 (completion_list_add_msymbol, completion_list_objc_symbol)
10478 (completion_list_add_fields, add_symtab_completions): Add
10479 completion_tracker parameter and use it.
10480 (default_make_symbol_completion_list_break_on_1): Rename to...
10481 (default_collect_symbol_completion_matches_break_on): ... this.
10482 Add completion_tracker parameter and use it instead of allocating
10483 a completion tracker here.
10484 (default_make_symbol_completion_list_break_on): Delete old
10485 implementation.
10486 (default_make_symbol_completion_list): Delete.
10487 (default_collect_symbol_completion_matches): New.
10488 (make_symbol_completion_list): Delete.
10489 (collect_symbol_completion_matches): New.
10490 (make_symbol_completion_type): Rename to ...
10491 (collect_symbol_completion_matches_type): ... this. Add
10492 completion_tracker parameter and use it instead of VEC.
10493 (make_file_symbol_completion_list_1): Rename to...
10494 (collect_file_symbol_completion_matches): ... this. Add
10495 completion_tracker parameter and use it instead of VEC.
10496 (make_file_symbol_completion_list): Delete.
10497 (add_filename_to_list): Use completion_list instead of a VEC.
10498 (add_partial_filename_data::list): Now a completion_list.
10499 (make_source_files_completion_list): Work with a completion_list
10500 instead of a VEC.
10501 * symtab.h: Include "completer.h".
10502 (default_make_symbol_completion_list_break_on)
10503 (default_make_symbol_completion_list, make_symbol_completion_list)
10504 (make_symbol_completion_type, make_file_symbol_completion_list)
10505 (make_source_files_completion_list): Delete.
10506 (default_collect_symbol_completion_matches_break_on)
10507 (default_collect_symbol_completion_matches)
10508 (collect_symbol_completion_matches)
10509 (collect_symbol_completion_matches_type)
10510 (collect_file_symbol_completion_matches)
10511 (make_source_files_completion_list): New.
10512 * top.c (init_main): Don't install a rl_completion_entry_function
10513 hook. Install a rl_attempted_completion_function hook instead.
10514 * tui/tui-layout.c (layout_completer): Adjust to work with a
10515 completion_tracker.
10516 * tui/tui-regs.c (tui_reggroup_completer):
10517 * tui/tui-win.c (window_name_completer, focus_completer)
10518 (winheight_completer): Adjust to work with a completion_tracker.
10519 * value.c: Include "completer.h".
10520 (complete_internalvar): Adjust to work with a completion_tracker.
10521 * value.h (complete_internalvar): Likewise.
10522
6e1dbf8c
PA
105232017-07-17 Pedro Alves <palves@redhat.com>
10524
10525 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
10526 renames.
10527 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
10528 comments to completer_ftype's declaration.
10529 <completer_handle_brkchars>: Change type to
10530 completer_handle_brkchars_ftype.
10531 * command.h (completer_ftype): Add describing comment and give
10532 names to parameters.
10533 (completer_ftype_void): Rename to ...
10534 (completer_handle_brkchars_ftype) ... this. Add describing comment.
10535 (set_cmd_completer_handle_brkchars): Adjust.
10536 * completer.c (filename_completer_handle_brkchars): New function.
10537 (complete_line_internal_normal_command): New function, factored
10538 out from ...
10539 (complete_line_internal): ... here.
10540 (command_completer_handle_brkchars)
10541 (default_completer_handle_brkchars)
10542 (completer_handle_brkchars_func_for_completer): New functions.
10543 * completer.h (set_gdb_completion_word_break_characters): Delete
10544 declaration.
10545 (completer_handle_brkchars_func_for_completer): New declaration.
10546 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
10547 completer_handle_brkchars_func_for_completer.
10548
78b13106
PA
105492017-07-17 Pedro Alves <palves@redhat.com>
10550
10551 * completer.c (symbol_completer): New function, based on
10552 make_symbol_completion_list_fn.
10553 * completer.h (symbol_completer): New declaration.
10554 * guile/scm-cmd.c (cmdscm_completers): Adjust.
10555 * python/py-cmd.c (completers): Adjust.
10556 * symtab.c (make_symbol_completion_list_fn): Delete.
10557 * symtab.h (make_symbol_completion_list_fn): Delete.
10558 * cli/cli-decode.c (add_cmd): Adjust.
10559
bbf2f4df
PA
105602017-07-17 Pedro Alves <palves@redhat.com>
10561
10562 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
10563 * dwarf2read.c: Include "filename-seen-cache.h".
10564 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
10565 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
10566 * filename-seen-cache.c: New file.
10567 * filename-seen-cache.h: New file.
10568 * symtab.c: Include "filename-seen-cache.h".
10569 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
10570 (create_filename_seen_cache, clear_filename_seen_cache)
10571 (delete_filename_seen_cache, filename_seen): Delete, parts moved
10572 to filename-seen-cache.h/filename-seen-cache.c.
10573 (output_source_filename, sources_info)
10574 (maybe_add_partial_symtab_filename)
10575 (make_source_files_completion_list): Adjust to use
10576 filename_seen_cache.
10577
330cdd98
PA
105782017-07-17 Pedro Alves <palves@redhat.com>
10579
10580 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
10581 fields.
10582 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
10583 dwarf2_debug_sections*)): New.
10584 (dwarf2_per_objfile::dwarf2_per_objfile(const
10585 dwarf2_per_objfile&)): Declare as deleted.
10586 (dwarf2_per_objfile::operator=): Declare as deleted.
10587 (dwarf2_per_objfile::dwarf2_per_objfile)
10588 (dwarf2_per_objfile::~dwarf2_per_objfile)
10589 (dwarf2_per_objfile::free_cached_comp_units): New.
10590 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
10591 ctor. Call dwarf2_per_objfile's ctor manually.
10592 (dwarf2_locate_sections): Deleted/refactored as ...
10593 (dwarf2_per_objfile::locate_sections): ... this new method.
10594 (free_cached_comp_units): Defer to
10595 dwarf2_per_objfile::free_cached_comp_units.
10596 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
10597
8880f2a9
TT
105982017-07-14 Tom Tromey <tom@tromey.com>
10599
10600 PR rust/21764:
10601 * rust-exp.y (convert_ast_to_expression): Add "want_type"
10602 parameter.
10603 <UNOP_SIZEOF>: Split into separate case.
10604 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
10605
65547233
TT
106062017-07-14 Tom Tromey <tom@tromey.com>
10607
10608 PR rust/21763:
10609 * symtab.c (symbol_matches_domain): Add language_rust to special
10610 case.
10611 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
10612 treat LOC_TYPEDEF symbols as variables.
10613
8f14146e
PA
106142017-07-14 Pedro Alves <palves@redhat.com>
10615
10616 * symtab.c (make_file_symbol_completion_list_1): Iterate over
10617 symtabs matching all symtabs with SRCFILE as file name instead of
10618 only considering the first hit, with lookup_symtab.
10619
2347965c
SM
106202017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10621
10622 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
10623 operator_name parameters.
10624 (gen_expr): Update function call.
10625
40f4af28
SM
106262017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10627
10628 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
10629 parameter.
10630 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
10631 Likewise.
10632 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
10633 parameter, use agent_expr::gdbarch instead, update function
10634 calls.
10635 (locexpr_tracepoint_var_ref): Likewise.
10636 (loclist_tracepoint_var_ref): Likewise.
10637 * ax-gdb.c (gen_trace_static_fields): Likewise.
10638 (gen_traced_pop): Likewise.
10639 (gen_frame_args_address): Likewise.
10640 (gen_frame_locals_address): Likewise.
10641 (gen_var_ref): Likewise.
10642 (gen_struct_ref_recursive): Likewise.
10643 (gen_static_field): Likewise.
10644 (gen_maybe_namespace_elt): Likewise.
10645 (gen_expr): Likewise.
10646 (gen_trace_for_var): Likewise.
10647 (gen_trace_for_expr): Likewise.
10648 (gen_trace_for_return_address): Likewise.
10649
053f8057
SM
106502017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10651
10652 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
10653 parameter.
10654 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
10655
6661ad48
SM
106562017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10657
10658 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
10659 from ax, update calls.
10660 (gen_usual_arithmetic): Likewise.
10661 (gen_integral_promotions): Likewise.
10662 (gen_bitfield_ref): Likewise.
10663 (gen_primitive_field): Likewise.
10664 (gen_struct_ref_recursive): Likewise.
10665 (gen_struct_ref): Likewise.
10666 (gen_maybe_namespace_elt): Likewise.
10667 (gen_struct_elt_for_reference): Likewise.
10668 (gen_namespace_elt): Likewise.
10669 (gen_aggregate_elt_ref): Likewise.
10670 (gen_expr): Get gdbarch from ax, update calls.
10671 (gen_expr_binop_rest): Likewise.
10672
c55a47e7
PA
106732017-07-13 Pedro Alves <palves@redhat.com>
10674
10675 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
10676 as default tdesc.
10677 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
10678 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
10679 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
10680 tdesc_amd64_linux as default tdesc. Get final tdesc from the
10681 tdep.
10682 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
10683 Get final tdesc from the tdep.
10684 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
10685 default tdesc.
10686 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
10687 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
10688 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
10689 Use it as default tdesc.
10690 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
10691 down to amd_init_abi. No longer handle fallback tdesc here.
10692 * amd64-tdep.h (tdesc_x32): Declare.
10693 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
10694 parameter.
10695 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
10696 as default tdesc.
10697
55efceab
AA
106982017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10699
10700 * s390-linux-tdep.c (s390_process_record): Add support for
10701 instructions new in arch12.
10702
0aa37b65
JB
107032017-07-11 John Baldwin <jhb@FreeBSD.org>
10704
10705 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
10706 PT_GETFSBASE and PT_GETGSBASE.
10707 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
10708 PT_SETGSBASE.
10709
48aeef91
JB
107102017-07-11 John Baldwin <jhb@FreeBSD.org>
10711
10712 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
10713 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
10714 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
10715 those rules.
10716 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
10717 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
10718 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
10719 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
10720 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
10721 * features/i386/amd64.xml: Add 64bit-segments.xml.
10722 * features/i386/amd64-avx-avx512.c: Regenerated.
10723 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
10724 * features/i386/amd64-avx-mpx.c: Regenerated.
10725 * features/i386/amd64-avx.c: Regenerated.
10726 * features/i386/amd64-mpx.c: Regenerated.
10727 * features/i386/amd64.c: Regenerated.
10728 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
10729 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10730 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
10731 * regformats/i386/amd64-avx.dat: Regenerated.
10732 * regformats/i386/amd64-mpx.dat: Regenerated.
10733 * regformats/i386/amd64.dat: Regenerated.
10734
77c501bc
YQ
107352017-07-10 Yao Qi <yao.qi@linaro.org>
10736
10737 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10738 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10739
6dc8d757
AK
107402017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
10741
10742 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
10743 unsetenv.
10744 * gnulib/aclocal.m4: Regenerate.
10745 * gnulib/config.in: Regenerate.
10746 * gnulib/configure: Regenerate.
10747 * gnulib/import/Makefile.am: Regenerate.
10748 * gnulib/import/Makefile.in: Regenerate.
10749 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
10750 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
10751 * gnulib/import/m4/environ.m4: New file.
10752 * gnulib/import/m4/setenv.m4: New file.
10753 * gnulib/import/setenv.c: New file.
10754 * gnulib/import/unsetenv.c: New file.
10755
266934d1
SM
107562017-07-09 Simon Marchi <simon.marchi@ericsson.com>
10757
10758 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
10759 address when op is DW_OP_addr.
10760
03278692
TT
107612017-07-09 Tom Tromey <tom@tromey.com>
10762
10763 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
10764 check and apply to outer type.
10765
4b654465
JB
107662017-07-07 John Baldwin <jhb@FreeBSD.org>
10767
10768 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
10769 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
10770 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
10771 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
10772
2af9fc44
JB
107732017-07-07 John Baldwin <jhb@FreeBSD.org>
10774
10775 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
10776
382b69bb
JB
107772017-07-07 John Baldwin <jhb@FreeBSD.org>
10778
10779 * corelow.c (get_core_siginfo): Remove.
10780 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
10781 instead of get_core_siginfo.
10782 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
10783 * gdbarch.h: Re-generate.
10784 * gdbarch.c: Re-generate.
10785 * linux-tdep.c (linux_core_xfer_siginfo): New.
10786 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
10787
6e5eab33
JB
107882017-07-07 John Baldwin <jhb@FreeBSD.org>
10789
10790 * corelow.c (thread_section_name): Move to ...
10791 * gdbcore.h (thread_section_name): ... here.
10792
929edea9
JB
107932017-07-07 John Baldwin <jhb@FreeBSD.org>
10794
10795 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
10796 (struct siginfo32): New.
10797 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
10798 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
10799 via ptrace(PT_LWPINFO).
10800
762c974a
JB
108012017-07-07 John Baldwin <jhb@FreeBSD.org>
10802
10803 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
10804 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
10805 (fbsd_get_siginfo_type): New.
10806 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
10807 (_initialize_fbsd_tdep): New.
10808
33c5cd75
DB
108092017-07-06 David Blaikie <dblaikie@gmail.com>
10810
10811 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
10812 a singular dwo_unit*) to support multiple CUs in the same way that
10813 multiple TUs are supported.
10814 (create_cus_hash_table): Replace create_dwo_cu with a function for
10815 parsing multiple CUs from a DWO file.
10816 (open_and_init_dwo_file): Use create_cus_hash_table rather than
10817 create_dwo_cu.
10818 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
10819 htab_find, rather than comparing the signature to a singleton CU in
10820 the dwo_file.
10821
8455d262
PA
108222017-07-06 Pedro Alves <palves@redhat.com>
10823
10824 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
10825
4da3eb35
PA
108262017-07-04 Pedro Alves <palves@redhat.com>
10827
10828 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
10829 * gdbtypes.h (TYPE_STATIC): Delete.
10830 (struct fn_field) <is_public, is_abstract, is_static, is_final,
10831 is_synchronized, is_native>: Delete.
10832 <dummy>: Bump.
10833 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
10834 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
10835 (TYPE_FN_FIELD_ABSTRACT): Delete.
10836
5bfd255c
SM
108372017-07-03 Simon Marchi <simon.marchi@ericsson.com>
10838
10839 * buffer.h (buffer_finish): Fix spelling mistakes.
10840
25c54127
EZ
108412017-07-01 Eli Zaretskii <eliz@gnu.org>
10842
10843 * .dir-locals.el: Automatically switch to C-style comments in
10844 versions of Emacs that support the feature.
10845
dc4bde35
SDJ
108462017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10847 Pedro Alves <palves@redhat.com>
10848
10849 PR cli/21688
10850 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
10851 (process_next_line): New variable 'inline_cmd'.
10852 Adjust 'if' clauses for "python", "compile" and "guile" to use
10853 'command_name_equals' and check for '!inline_cmd'.
10854
51ed89aa
SDJ
108552017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10856
10857 PR cli/21688
10858 * cli/cli-script.c (command_name_equals_not_inline): New function.
10859 (process_next_line): Adjust 'if' clauses for "python", "compile"
10860 and "guile" to use command_name_equals_not_inline.
10861
eb17d413
PA
108622017-06-29 Pedro Alves <palves@redhat.com>
10863
10864 * completer.c (expression_completer): Call
10865 linespec_location_completer instead of location_completer.
10866
195bcdd5
PA
108672017-06-29 Pedro Alves <palves@redhat.com>
10868
10869 * completer.c (expression_completer): Remove code that recomputes
10870 'text' from 'word'.
10871
adc764e7
YQ
108722017-06-29 Yao Qi <yao.qi@linaro.org>
10873
10874 * regformats/regdat.sh: Generate code with
10875 "ifndef IN_PROCESS_AGENT".
10876
6e75794e
PA
108772017-06-28 Pedro Alves <palves@redhat.com>
10878
10879 * command.h: Include "common/scoped_restore.h".
10880
bc491f2e
YQ
108812017-06-28 Yao Qi <yao.qi@linaro.org>
10882
10883 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
10884 instead of obstack_grow.
10885
41664b45
DG
108862017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
10887
10888 PR gdb/21337
10889 * symfile.c (reread_symbols): Call objfiles_changed just before
10890 read_symbols.
10891
6da67eb1
PA
108922017-06-27 Pedro Alves <palves@redhat.com>
10893
10894 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
10895 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
10896 (completion_list_add_symbol, completion_list_add_msymbol):
10897 ... these new functions.
10898 (add_symtab_completions)
10899 (default_make_symbol_completion_list_break_on_1): Adjust.
10900
23732b1e
PA
109012017-06-27 Pedro Alves <palves@redhat.com>
10902
10903 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
10904 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
10905 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
10906 dtor.
10907 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
10908 'storage_obstack' field an auto_obstack. In-class initialize all
10909 non-bitfield fields. Make minsyms_read bool.
10910 * symfile.c (read_symbols): Adjust.
10911
a4d1e79a
AH
109122017-06-27 Alan Hayward <alan.hayward@arm.com>
10913
10914 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
10915 (gdbsim_store_register): Likewise.
10916
8268c778
PA
109172017-06-27 Pedro Alves <palves@redhat.com>
10918
10919 * c-exp.y (name_obstack): Now an auto_obstack.
10920 (yylex): Use auto_obstack::clear.
10921 (c_parse): Use auto_obstack::clear instead of reinitializing and
10922 freeing the obstack.
10923 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
10924 * d-exp.y (name_obstack): Now an auto_obstack.
10925 (yylex): Use auto_obstack::clear.
10926 (d_parse): Use auto_obstack::clear instead of reinitializing and
10927 freeing the obstack.
10928 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
10929 auto_obstack.
10930 * dwarf2read.c (create_addrmap_from_index)
10931 (dwarf2_build_psymtabs_hard)
10932 (update_enumeration_type_from_children): Likewise.
10933 * gdb_obstack.h (auto_obstack): New type.
10934 * go-exp.y (name_obstack): Now an auto_obstack.
10935 (build_packaged_name): Use auto_obstack::clear.
10936 (go_parse): Use auto_obstack::clear instead of reinitializing and
10937 freeing the obstack.
10938 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
10939 auto_obstack.
10940 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
10941 * rust-exp.y (work_obstack): Now an auto_obstack.
10942 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
10943 reinitializing and freeing the obstack.
10944 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
10945 (host_char_to_target): Use auto_obstack.
10946 * utils.h (make_cleanup_obstack_free): Delete declaration.
10947 * valprint.c (generic_emit_char, generic_printstr): Use
10948 auto_obstack.
10949
db665f42
SM
109502017-06-27 Simon Marchi <simon.marchi@ericsson.com>
10951
10952 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
10953 thread.
10954 (darwin_init_thread_list): Don't update dummy thread.
10955 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
10956
873c0814
SM
109572017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10958
10959 * record-full.c (netorder16): Remove.
10960
8b5a7a6e
SM
109612017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10962
10963 * common/diagnostics.h: Define macros for GCC.
10964 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
10965 * common/vec.h: Include diagnostics.h.
10966 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
10967 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
10968 warning.
10969
d1435379
SM
109702017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10971
10972 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
10973 New macro.
10974 * ada-lex.l: Ignore deprecated register warnings.
10975
cc75e0fd
SM
109762017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10977
10978 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
10979 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
10980
07809eaf
SM
109812017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10982
10983 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
10984 its own line.
10985
f076f034
SM
109862017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10987
10988 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
10989
0dd5cbc5
AH
109902017-06-23 Alan Hayward <alan.hayward@arm.com>
10991
10992 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
10993 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
10994 (xtensa_register_read_masked): Likewise.
10995
d4c6ce5b
SDJ
109962017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
10997
10998 * common/environ.c (gdb_environ::unset): Update comment.
10999
16892a03
AH
110002017-06-22 Alan Hayward <alan.hayward@arm.com>
11001
11002 * python/py-unwind.c (pyuw_sniffer): Allocate space for
11003 registers.
11004
d7dcbefc
AH
110052017-06-22 Alan Hayward <alan.hayward@arm.com>
11006
11007 * record-full.c (record_full_exec_insn): Use byte_vector.
11008
b30ff123
YQ
110092017-06-22 Yao Qi <yao.qi@linaro.org>
11010
11011 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
11012 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
11013
4fa847d7
AH
110142017-06-22 Alan Hayward <alan.hayward@arm.com>
11015
11016 * remote.c (cached_reg): Move from here...
11017 * regcache.h (cached_reg): ...to here.
11018 * python/py-unwind.c (struct reg_info): Remove.
11019 (cached_frame_info): Use cached_reg_t.
11020 (pyuw_prev_register): Likewise.
11021 (pyuw_sniffer): Use cached_reg_t and allocate registers.
11022 (pyuw_dealloc_cache): Free all registers.
11023
f4906a9a
PA
110242017-06-22 Pedro Alves <palves@redhat.com>
11025 Simon Marchi <simon.marchi@ericsson.com>
11026
11027 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
11028 warning.
11029 * common/diagnostics.h: New file.
11030
b45a1208
PA
110312017-06-22 Pedro Alves <palves@redhat.com>
11032
11033 * common/agent.h: Add include guards.
11034
e4da2c61
SM
110352017-06-21 Simon Marchi <simon.marchi@ericsson.com>
11036
11037 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
11038 talk about addressable units instead of bytes.
11039
96160d60
SDJ
110402017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11041
11042 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
11043 of '::const_iterator'.
11044
9a6c7d9c
SDJ
110452017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
11046
11047 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11048 'unittests/environ-selftests.c'.
11049 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
11050 * charset.c (find_charset_names): Declare object 'iconv_env'.
11051 Update code to use 'iconv_env' object. Remove call to
11052 'free_environ'.
11053 * common/environ.c: Include <utility>.
11054 (make_environ): Delete function.
11055 (free_environ): Delete function.
11056 (gdb_environ::clear): New function.
11057 (gdb_environ::operator=): New function.
11058 (gdb_environ::get): Likewise.
11059 (environ_vector): Delete function.
11060 (set_in_environ): Delete function.
11061 (gdb_environ::set): New function.
11062 (unset_in_environ): Delete function.
11063 (gdb_environ::unset): New function.
11064 (gdb_environ::envp): Likewise.
11065 * common/environ.h: Include <vector>.
11066 (struct gdb_environ): Delete; transform into...
11067 (class gdb_environ): ... this class.
11068 (free_environ): Delete prototype.
11069 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
11070 environ_vector): Likewise.
11071 * infcmd.c (run_command_1): Update code to call
11072 'envp' from 'gdb_environ' class.
11073 (environment_info): Update code to call methods from 'gdb_environ'
11074 class.
11075 (unset_environment_command): Likewise.
11076 (path_info): Likewise.
11077 (path_command): Likewise.
11078 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
11079 (inferior::inferior): Initialize 'environment' using the host's
11080 information.
11081 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
11082 Include "environ.h".
11083 (class inferior) <environment>: Change type from 'struct
11084 gdb_environ' to 'gdb_environ'.
11085 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
11086 methods from 'gdb_environ' class.
11087 * solib.c (solib_find_1): Likewise
11088 * unittests/environ-selftests.c: New file.
11089
75c554cf
YQ
110902017-06-20 Yao Qi <yao.qi@linaro.org>
11091
11092 * features/i386/i386-linux.xml: Exchange the order of including
11093 32bit-linux.xml and 32bit-sse.xml.
11094 * features/i386/i386-linux.c: Regenerated.
11095
72ddacb7
YQ
110962017-06-20 Yao Qi <yao.qi@linaro.org>
11097
11098 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
11099 Delete copy ctor and assignment operator.
11100 (tdesc_type): Likewise.
11101 (tdesc_feature): Likewise.
11102 (tdesc_free_reg): Remove.
11103 (tdesc_create_reg): Use new.
11104 (tdesc_free_type): Remove.
11105 (tdesc_create_vector): Use new.
11106 (tdesc_create_union): Likewise.
11107 (tdesc_create_flags): Likewise.
11108 (tdesc_create_enum): Likewise.
11109 (tdesc_free_feature): Delete.
11110 (free_target_description): Use delete.
11111
325c9fd4
JB
111122017-06-19 John Baldwin <jhb@FreeBSD.org>
11113
11114 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
11115 registers.
11116
16b7a719
PA
111172017-06-19 Pedro Alves <palves@redhat.com>
11118
11119 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
11120 after gdb::unlinker.
11121
1c8e01c9
SDJ
111222017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
11123
11124 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
11125 gdb_environ to access an environment variable.
11126
ffce45d2
TP
111272017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
11128
11129 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
11130 gdb_byte*.
11131
1d4fbac9
SM
111322017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11133
11134 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
11135
8465943a
SM
111362017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11137
11138 * configure: Re-generate.
11139 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
11140
3e019bdc
SM
111412017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11142
11143 * configure: Re-generate.
11144 * warning.m4: Pass -Werror to compiler when checking for
11145 supported warning flags.
11146
cf0dd6f0
SM
111472017-06-17 Simon Marchi <simon.marchi@ericsson.com>
11148
11149 * Makefile.in (COMPILE.pre): Add "-x c++".
11150
6f98355c
YQ
111512017-06-16 Alan Hayward <alan.hayward@arm.com>
11152 Pedro Alves <palves@redhat.com>
11153 Yao Qi <yao.qi@linaro.org>
11154
11155 * defs.h (RequireLongest): New.
11156 (extract_integer): Declare function template.
11157 (extract_signed_integer): Remove the declaration, but define it
11158 static inline.
11159 (extract_unsigned_integer): Likewise.
11160 (store_integer): Declare function template.
11161 (store_signed_integer): Remove the declaration, but define it
11162 static inline.
11163 (store_unsigned_integer): Likewise.
11164 * findvar.c (extract_integer): New function template.
11165 (extract_signed_integer): Remove.
11166 (extract_unsigned_integer): Remove.
11167 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
11168 instantiations.
11169 (store_integer): New function template.
11170 (store_signed_integer): Remove.
11171 (store_unsigned_integer): Remove.
11172 (store_integer): Explicit instantiations.
11173 * regcache.c (regcache_raw_read_signed): Update.
11174 (regcache::raw_read): New function.
11175 (regcache::raw_read_signed): Remove.
11176 (regcache::raw_read_unsigned): Remove.
11177 (regcache_raw_read_unsigned): Update.
11178 (regcache_raw_write_unsigned): Update.
11179 (regcache::raw_write_signed): Remove.
11180 (regcache::raw_write): New function.
11181 (regcache_cooked_read_signed): Update.
11182 (regcache::raw_write_unsigned): Remove.
11183 (regcache::cooked_read_signed): Remove.
11184 (regcache_cooked_read_unsigned): Update.
11185 (regcache::cooked_read_unsigned): Remove.
11186 (regcache_cooked_write_signed): Update.
11187 (regcache_cooked_write_unsigned): Update.
11188 * regcache.h (regcache) <raw_read_signed>: Remove.
11189 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
11190 <raw_read, raw_write>: New.
11191 <cooked_read_signed, cooked_write_signed>: Remove.
11192 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
11193 <cooked_read, cooked_write>: New.
11194 * sh64-tdep.c (sh64_pseudo_register_read): Update.
11195 (sh64_pseudo_register_write): Update.
11196
a87dc45a
AK
111972017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
11198
11199 * arc-tdep.c (arc_disassembler_options): New variable.
11200 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
11201 of default_print_insn.
11202 (arc_delayed_print_insn): Set info->section when needed,
11203 use default_print_insn to retrieve a disassembler.
11204
45159d6a
SDJ
112052017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
11206
11207 PR gdb/21574
11208 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
11209 to mention $SHELL and startup-with-shell.
11210
b46c4cf0
MF
112112017-06-14 Max Filippov <jcmvbkbc@gmail.com>
11212
11213 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
11214
6394c606
YQ
112152017-06-14 Yao Qi <yao.qi@linaro.org>
11216
11217 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
11218 default_print_insn instead of print_insn_aarch64.
11219 * arm-tdep.c (gdb_print_insn_arm): Call
11220 default_print_insn instead of print_insn_big_arm
11221 and print_insn_little_arm.
11222 * i386-tdep.c (i386_print_insn): Call default_print_insn
11223 instead of print_insn_i386.
11224 * ia64-tdep.c (ia64_print_insn): Call
11225 default_print_insn instead of print_insn_ia64.
11226 * mips-tdep.c (gdb_print_insn_mips): Call
11227 default_print_insn instead of print_insn_big_mips
11228 and print_insn_little_mips.
11229 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
11230 instead of print_insn_spu.
11231
d5722aa2
PA
112322017-06-14 Pedro Alves <palves@redhat.com>
11233
11234 * ada-lang.c: Include "common/byte-vector.h".
11235 (ada_value_primitive_packed_val): Use gdb::byte_vector.
11236 * charset.c (wchar_iterator::iterate): Resize the vector instead
11237 of reserving it.
11238 * common/byte-vector.h: Include "common/def-vector.h".
11239 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
11240 * cli/cli-dump.c: Include "common/byte-vector.h".
11241 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
11242 * common/byte-vector.h: New file.
11243 * common/def-vector.h: New file.
11244 * common/default-init-alloc.h: New file.
11245 * dwarf2loc.c: Include "common/byte-vector.h".
11246 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
11247 instead of reserving it.
11248 * dwarf2read.c: Include "common/byte-vector.h".
11249 (data_buf::m_vec): Now a gdb::byte_vector.
11250 * gdb_regex.c: Include "common/def-vector.h".
11251 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
11252 * mi/mi-main.c: Include "common/byte-vector.h".
11253 (mi_cmd_data_read_memory): Use gdb::byte_vector.
11254 * printcmd.c: Include "common/byte-vector.h".
11255 (print_scalar_formatted): Use gdb::byte_vector.
11256 * valprint.c: Include "common/byte-vector.h".
11257 (maybe_negate_by_bytes, print_decimal_chars): Use
11258 gdb::byte_vector.
11259
01ec7a27
SM
112602017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11261
11262 * darwin-nat.c: Include "nat/fork-inferior.h".
11263
848d9074
SM
112642017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11265
11266 * configure.nat: Factor out Darwin bits that are not
11267 architecture-specific. Add fork-inferior.o.
11268
3b912944
SM
112692017-06-13 Simon Marchi <simon.marchi@ericsson.com>
11270
11271 * configure.nat: Factor out AIX bits that are not
11272 architecture-specific. Add fork-inferior.o.
11273
55acdf22
AA
112742017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11275
11276 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
11277 (read_pieced_value, write_pieced_value): ...here. Reduce to
11278 wrappers that just call rw_pieced_value.
11279
f65e2044
AA
112802017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11281
11282 * dwarf2loc.c (write_pieced_value): When writing the data for a
11283 memory piece, use write_memory_with_notification instead of
11284 write_memory.
11285
23f945bf
AA
112862017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11287
11288 * valops.c (read_value_memory): Change embedded_offset to
11289 represent a bit offset instead of a byte offset.
11290 * value.h (read_value_memory): Adjust comment.
11291
f236533e
AA
112922017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11293
11294 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
11295 dest_offset_bits and source_offset_bits.
11296 (write_pieced_value): Likewise.
11297
65d84b76
AA
112982017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11299
11300 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
11301 given by DW_OP_bit_piece.
11302 (write_pieced_value): Likewise.
11303
242d31ab
AA
113042017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11305
11306 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
11307 some other preparations to the places where sufficient information
11308 is available.
11309 (write_pieced_value): Likewise.
11310
03c8af18
AA
113112017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11312
11313 * dwarf2loc.c (bits_to_bytes): New function.
11314 (read_pieced_value): Fix offset calculations for register pieces
11315 on big-endian targets.
11316 (write_pieced_value): Likewise.
11317
840989c1
AA
113182017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11319
11320 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
11321 (write_pieced_value): Likewise.
11322
359b19bb
AA
113232017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11324
11325 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
11326 transfer the source value's least significant bits, instead of its
11327 lowest-addressed ones. Rename type_len to max_offset.
11328 (read_pieced_value): Mirror above changes to write_pieced_value as
11329 applicable.
11330
07c9ca3b
AA
113312017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11332
11333 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
11334 truncate full bytes from dest_offset_bits before using it as an
11335 offset into the buffer.
11336
f1cc9874
AA
113372017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11338
11339 * dwarf2loc.c (write_pieced_value): Include transfer size in
11340 byte-wise check.
11341
cdaac320
AA
113422017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11343
11344 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
11345 calculation of this_size.
11346
af547a96
AA
113472017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11348
11349 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
11350 when targeting a bit-field.
11351 (write_pieced_value): Likewise.
11352
ddd7882a
AA
113532017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11354
11355 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
11356 (allocate_piece_closure): Drop addr_size parameter.
11357 (dwarf2_evaluate_loc_desc_full): Adjust call to
11358 allocate_piece_closure.
11359
e9352324
AA
113602017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11361
11362 PR gdb/21226
11363 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
11364 the LSB end, independent of endianness.
11365
d5d1163e
AA
113662017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
11367
11368 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
11369 size capping.
11370
032bb6ea
YQ
113712017-06-13 Yao Qi <yao.qi@linaro.org>
11372
11373 * mips-linux-nat.c: Move include features/mips*-linux.c to
11374 mips-linux-tdep.c.
11375 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
11376 to mips-linux-tdep.c.
11377 * mips-linux-tdep.c: Include features/mips*-linux.c
11378 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
11379 functions.
11380 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
11381 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
11382 (tdesc_mips64_dsp_linux): Declare.
11383
f12f6bad
TT
113842017-06-12 Tom Tromey <tom@tromey.com>
11385
11386 * valprint.h (val_print_type_code_int): Remove.
11387 * valprint.c (generic_val_print_int): Always call
11388 val_print_scalar_formatted.
11389 (val_print_type_code_int): Remove.
11390 * printcmd.c (print_scalar_formatted): Handle options->format==0.
11391 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
11392 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
11393 * ada-valprint.c (ada_val_print_num): Use
11394 val_print_scalar_formatted.
11395
d9109c80
TT
113962017-06-12 Tom Tromey <tom@tromey.com>
11397
11398 * printcmd.c (print_scalar_formatted): Unify the two switches.
11399 Don't convert scalars to LONGEST.
11400
4ac0cb1c
TT
114012017-06-12 Tom Tromey <tom@tromey.com>
11402
11403 PR exp/16225:
11404 * valprint.h (print_decimal_chars): Update.
11405 * valprint.c (maybe_negate_by_bytes): New function.
11406 (print_decimal_chars): Add "is_signed" argument.
11407 * printcmd.c (print_scalar_formatted): Update.
11408
30a25466
TT
114092017-06-12 Tom Tromey <tom@tromey.com>
11410
11411 PR exp/16225:
11412 * valprint.h (print_binary_chars, print_hex_chars): Update.
11413 * valprint.c (val_print_type_code_int): Update.
11414 (print_binary_chars): Add "zero_pad" argument.
11415 (emit_octal_digit): New function.
11416 (print_octal_chars): Don't zero-pad.
11417 (print_decimal_chars): Likewise.
11418 (print_hex_chars): Add "zero_pad" argument.
11419 * sh64-tdep.c (sh64_do_fp_register): Update.
11420 * regcache.c (regcache::dump): Update.
11421 * printcmd.c (print_scalar_formatted): Update.
11422 * infcmd.c (default_print_one_register_info): Update.
11423
b3464d03
PA
114242017-06-12 Pedro Alves <palves@redhat.com>
11425 Alan Hayward <alan.hayward@arm.com>
11426
11427 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
11428 (mips_eabi_push_dummy_call): Rename local 'regsize' to
11429 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
11430 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
11431 Assert that abi_regsize bytes fit in 'ref_valbuf'.
11432
4b76cda9
PA
114332017-06-12 Pedro Alves <palves@redhat.com>
11434
11435 * dwarf2read.c (mapped_symtab::data): Now a vector of
11436 symtab_index_entry instead of vector of
11437 std::unique_ptr<symtab_index_entry>. All users adjusted to check
11438 whether an element's name is NULL instead of checking whether the
11439 element itself is NULL.
11440 (find_slot): Change return type. Adjust.
11441 (hash_expand, , add_index_entry, uniquify_cu_indices)
11442 (write_hash_table): Adjust.
11443
e8f8bcb3
PA
114442017-06-12 Pedro Alves <palves@redhat.com>
11445
11446 * dwarf2read.c (recursively_count_psymbols): New function.
11447 (write_psymtabs_to_index): Call it to compute number of psyms and
11448 pass estimate size of psyms_seen to unordered_set's ctor.
11449
70a1152b
PA
114502017-06-12 Pedro Alves <palves@redhat.com>
11451
11452 * dwarf2read.c (write_hash_table): Check if key already exists
11453 before emplacing.
11454
c2f134ac
PA
114552017-06-12 Pedro Alves <palves@redhat.com>
11456
11457 * dwarf2read.c (data_buf::append_space): Rename to...
11458 (data_buf::grow): ... this, and make private. Adjust all callers.
11459 (data_buf::append_uint): New method.
11460 (add_address_entry, write_one_signatured_type)
11461 (write_psymtabs_to_index): Use it.
11462
a81e6d4d
PA
114632017-06-12 Pedro Alves <palves@redhat.com>
11464
11465 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
11466 (file_write (FILE *, const std::vector<Elem>&)): Delete.
11467 (data_buf::file_write): Call ::fwrite directly.
11468
6fd931f2
PA
114692017-06-12 Pedro Alves <palves@redhat.com>
11470
11471 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
11472 std::vector::erase.
11473
bc8f2430
JK
114742017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11475
11476 Code cleanup: C++ify .gdb_index producer.
11477 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
11478 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
11479 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
11480 (create_strtab, add_string): Remove.
11481 (file_write, data_buf): New.
11482 (struct symtab_index_entry): Use std::vector for cu_indices.
11483 (struct mapped_symtab): Use std::vector for data.
11484 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
11485 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
11486 Remove.
11487 (find_slot): Change return type. Update it to the new data structures.
11488 (hash_expand, add_index_entry): Update it to the new data structures.
11489 (offset_type_compare): Remove.
11490 (uniquify_cu_indices): Update it to the new data structures.
11491 (c_str_view, c_str_view_hasher, vector_hasher): New.
11492 (add_indices_to_cpool): Remove.
11493 (write_hash_table): Update it to the new data structures.
11494 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
11495 (eq_psymtab_cu_index): Remove.
11496 (psym_index_map): New typedef.
11497 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
11498 reference and std::unordered_map for cu_index_htab.
11499 (add_address_entry, add_address_entry_worker, write_address_map)
11500 (write_psymbols): Update it to the new data structures.
11501 (write_obstack): Remove.
11502 (struct signatured_type_index_data): Change types_list to a data_buf
11503 reference and psyms_seen to a std::unordered_set reference.
11504 (write_one_signatured_type, recursively_write_psymbols)
11505 (write_psymtabs_to_index): Update it to the new data structures.
11506
c4dcb155
SM
115072017-06-11 Simon Marchi <simon.marchi@ericsson.com>
11508
11509 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
11510 separate-debug-file commands.
11511 * symfile.h (separate_debug_file_debug): New global.
11512 * symfile.c (separate_debug_file_debug): New global.
11513 (separate_debug_file_exists, find_separate_debug_file): Add
11514 debug output.
11515 (_initialize_symfile): Add "set debug separate-debug-file"
11516 command.
11517 * build-id.c (build_id_to_debug_bfd,
11518 find_separate_debug_file_by_buildid): Add debug output.
11519
6d45d4b4
SM
115202017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
11521
11522 * gdbarch.sh (displaced_step_free_closure): Remove.
11523 * gdbarch.h, gdbarch.c: Re-generate.
11524 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
11525 displaced_step_free_closure.
11526 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
11527 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
11528 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
11529 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11530 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
11531 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11532 * arch-utils.h (simple_displaced_step_free_closure): Remove.
11533 * arch-utils.c (simple_displaced_step_free_closure): Remove.
11534 * infrun.c (displaced_step_clear): Call xfree instead of
11535 gdbarch_displaced_step_free_closure.
11536
2f91880f
SDJ
115372017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
11538
11539 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
11540 NULL".
11541
b8b6e72f
AH
115422017-06-08 Alan Hayward <alan.hayward@arm.com>
11543
11544 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
11545 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
11546 (mn10300_push_dummy_call): Likewise.
11547
5369082e
AH
115482017-06-08 Alan Hayward <alan.hayward@arm.com>
11549
11550 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
11551
ff4ca5ac
AH
115522017-06-08 Alan Hayward <alan.hayward@arm.com>
11553
11554 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
11555
aefd8b33
SDJ
115562017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11557
11558 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
11559 able to start inferiors using a shell.
11560 (New remote packets): Announce new packet "QStartupWithShell".
11561 * remote.c: Add PACKET_QStartupWithShell.
11562 (extended_remote_create_inferior): Handle new
11563 PACKET_QStartupWithShell.
11564 (remote_protocol_features) <QStartupWithShell>: New entry for
11565 PACKET_QStartupWithShell.
11566 (_initialize_remote): Call "add_packet_config_cmd" for
11567 QStartupShell.
11568
2090129c
SDJ
115692017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11570 Pedro Alves <palves@redhat.com>
11571
11572 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
11573 and "nat/fork-inferior.h".
11574 * common/common-inferior.h: New file, with contents from
11575 "gdb/inferior.h".
11576 * commom/common-utils.c: Include "common-utils.h".
11577 (stringify_argv): New function.
11578 * common/common-utils.h (stringify_argv): New prototype.
11579 * configure.nat: Add "fork-inferior.o" as a dependency for
11580 "*linux*", "fbsd*" and "nbsd*" hosts.
11581 * corefile.c (get_exec_file): Update comment.
11582 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
11583 instead of "startup_inferior".
11584 (darwin_create_inferior): Call "add_thread_silent" after
11585 "fork_inferior".
11586 * fork-child.c: Cleanup unnecessary includes.
11587 (SHELL_FILE): Move to "common/common-fork-child.c".
11588 (environ): Likewise.
11589 (exec_wrapper): Initialize.
11590 (get_exec_wrapper): New function.
11591 (breakup_args): Move to "common/common-fork-child.c"; rename to
11592 "breakup_args_for_exec".
11593 (escape_bang_in_quoted_argument): Move to
11594 "common/common-fork-child.c".
11595 (saved_ui): New variable.
11596 (prefork_hook): New function.
11597 (postfork_hook): Likewise.
11598 (postfork_child_hook): Likewise.
11599 (gdb_startup_inferior): Likewise.
11600 (fork_inferior): Move to "common/common-fork-child.c". Update
11601 function to support gdbserver.
11602 (startup_inferior): Likewise.
11603 * gdbcore.h (get_exec_file): Remove declaration.
11604 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
11605 instead of "startup_inferior". Call "add_thread_silent" after
11606 "fork_inferior".
11607 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
11608 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
11609 instead of "startup_inferior". Call "add_thread_silent" after
11610 "fork_inferior".
11611 * inferior.h: Include "common-inferior.h".
11612 (trace_start_error): Move to "common/common-utils.h".
11613 (trace_start_error_with_name): Likewise.
11614 (fork_inferior): Move prototype to "nat/fork-inferior.h".
11615 (startup_inferior): Likewise.
11616 (gdb_startup_inferior): New prototype.
11617 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
11618 * nat/fork-inferior.h: New file.
11619 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
11620 instead of "startup_inferior". Call "add_thread_silent" after
11621 "fork_inferior".
11622 * target.h (target_terminal_init): Move prototype to
11623 "target/target.h".
11624 (target_terminal_inferior): Likewise.
11625 (target_terminal_ours): Likewise.
11626 * target/target.h (target_terminal_init): New prototype, moved
11627 from "target.h".
11628 (target_terminal_inferior): Likewise.
11629 (target_terminal_ours): Likewise.
11630 * utils.c (gdb_flush_out_err): New function.
11631
043a4934
SDJ
116322017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11633
11634 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
11635 * common/common-gdbthread.h: New file, with parts from
11636 "gdb/gdbthread.h".
11637 * gdbthread.h: Include "common-gdbthread.h".
11638 (switch_to_thread): Moved to "common/common-gdbthread.h".
11639
15652511
SDJ
116402017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11641
11642 * Makefile.in (SFILES): Add "common/job-control.c".
11643 (HFILES_NO_SRCDIR): Add "common/job-control.h".
11644 (COMMON_OBS): Add "job-control.o".
11645 * common/job-control.c: New file, with contents from
11646 "gdb/inflow.c".
11647 * common/job-control.h: New file, with contents from "terminal.h".
11648 * fork-child.c: Include "job-control.h".
11649 * inflow.c: Include "job-control.h".
11650 (gdb_setpgid): Move to "common/common-inflow.c".
11651 (_initialize_inflow): Move setting of "job_control" to
11652 "handle_job_control".
11653 * terminal.h (job_control): Moved to "common/common-terminal.h".
11654 (gdb_setpgid): Likewise.
11655 * top.c: Include "job_control.h".
11656 * utils.c: Likewise.
11657 (job_control): Moved to "job-control.c".
11658
2d7cc5c7
PA
116592017-06-07 Pedro Alves <palves@redhat.com>
11660
11661 * Makefile.in (SFILES): Add gdb_regex.c.
11662 (COMMON_OBS): Add gdb_regex.o.
11663 * ada-lang.c (ada_add_standard_exceptions)
11664 (ada_add_exceptions_from_frame, name_matches_regex)
11665 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
11666 parameter type to compiled_regex. Adjust.
11667 (ada_exceptions_list): Use compiled_regex.
11668 * break-catch-throw.c (exception_catchpoint::pattern): Now a
11669 std::unique_ptr<compiled_regex>.
11670 (exception_catchpoint::~exception_catchpoint): Remove regfree
11671 call.
11672 (check_status_exception_catchpoint): Adjust to use compiled_regex.
11673 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
11674 * breakpoint.c (solib_catchpoint::compiled): Now a
11675 std::unique_ptr<compiled_regex>.
11676 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
11677 (check_status_catch_solib): Adjust to use compiled_regex.
11678 (add_solib_catchpoint): Adjust to use compiled_regex.
11679 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
11680 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
11681 compiled_regex reference. Adjust to use it.
11682 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
11683 declaration. Include "gdb_regex.h".
11684 (apropos_cmd): Change regex parameter to compiled_regex reference.
11685 * gdb_regex.c: New file.
11686 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
11687 declarations.
11688 (class compiled_regex): New.
11689 * linux-tdep.c: Include "common/gdb_optional.h".
11690 (struct mapping_regexes): New, factored out from
11691 mapping_is_anonymous_p, and adjusted to use compiled_regex.
11692 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
11693 gdb::optional and remove cleanups. Adjust to compiled_regex.
11694 * probe.c: Include "common/gdb_optional.h".
11695 (collect_probes): Use compiled_regex and gdb::optional and remove
11696 cleanups.
11697 * skip.c: Include "common/gdb_optional.h".
11698 (skiplist_entry::compiled_function_regexp): Now a
11699 gdb::optional<compiled_regex>.
11700 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
11701 (free_skiplist_entry): Remove regfree call.
11702 (compile_skip_regexp, skip_rfunction_p): Adjust to use
11703 compiled_regex and gdb::optional.
11704 * symtab.c: Include "common/gdb_optional.h".
11705 (search_symbols): Use compiled_regex and gdb::optional.
11706 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
11707 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
11708 to gdb_regex.c.
11709
50d6adef
AH
117102017-06-07 Alan Hayward <alan.hayward@arm.com>
11711
11712 * regcache.c (regcache::save): Avoid buffer use.
11713 (regcache::dump): Likewise.
11714
4a8a33c8
AH
117152017-06-07 Alan Hayward <alan.hayward@arm.com>
11716
11717 * sh-tdep.c (sh_pseudo_register_read): Remove
11718 MAX_REGISTER_SIZE.
11719 (sh_pseudo_register_write): Likewise.
11720 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
11721 (sh64_pseudo_register_write): Likewise
11722
d1be909e
AH
117232017-06-07 Alan Hayward <alan.hayward@arm.com>
11724
11725 * aarch64-tdep.c (aarch64_store_return_value): Use
11726 V_REGISTER_SIZE.
11727 (aarch64_pseudo_read_value): Likewise.
11728 (aarch64_pseudo_write): Likewise.
11729
f4a65042
YQ
117302017-06-06 Yao Qi <yao.qi@linaro.org>
11731
11732 * regformats/regdef.h (set_register_cache): Remove the
11733 declaration.
11734
9f7fb0aa
AH
117352017-06-06 Alan Hayward <alan.hayward@arm.com>
11736
11737 * frame.c (frame_unwind_register_signed): Use
11738 frame_unwind_register_value.
11739
e1e01040
PA
117402017-06-06 Pedro Alves <palves@redhat.com>
11741
11742 PR breakpoints/21553
11743 * breakpoint.c (create_breakpoints_sal_default)
11744 (init_breakpoint_sal, create_breakpoint_sal): Use
11745 gdb::unique_xmalloc_ptr for string parameters.
11746 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11747 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
11748 (base_breakpoint_create_breakpoints_sal)
11749 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
11750 (strace_marker_create_breakpoints_sal)
11751 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
11752 string parameters.
11753 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
11754 gdb::unique_xmalloc_ptr for string parameters.
11755 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11756 parameters.
11757
fbe654c8
AH
117582017-06-06 Alan Hayward <alan.hayward@arm.com>
11759
11760 * alpha-tdep.c (alpha_register_to_value): Use
11761 get_frame_register_value.
11762 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
11763
ae0d01d6
AH
117642017-06-06 Alan Hayward <alan.hayward@arm.com>
11765
11766 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
11767 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
11768 (ia64_value_to_register): Likewise.
11769 (ia64_extract_return_value): Likewise.
11770 (ia64_store_return_value): Likewise.
11771 (ia64_push_dummy_call): Likewise.
11772
49cf576c
JB
117732017-06-04 Joel Brobecker <brobecker@adacore.com>
11774
11775 GDB 8.0 released.
11776
26b6a6ab
SM
117772017-06-03 Simon Marchi <simon.marchi@ericsson.com>
11778
11779 * x86-linux-nat.c (struct arch_lwp_info): Remove.
11780
22827c51
SM
117812017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
11782
11783 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
11784 parameter.
11785 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
11786
0e05cf3a
SM
117872017-06-02 Simon Marchi <simon.marchi@ericsson.com>
11788
11789 * event-loop.c (poll_timers): Unallocate timer using delete
11790 instead of xfree.
11791
c1fc2657
SM
117922017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11793
11794 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
11795 (struct breakpoint) <~breakpoint>: New.
11796 (struct watchpoint): Inherit from breakpoint.
11797 <~watchpoint>: New.
11798 <base>: Remove.
11799 (struct tracepoint): Inherit from breakpoint.
11800 <base>: Remove.
11801 * breakpoint.c (longjmp_breakpoint_ops): Remove.
11802 (struct longjmp_breakpoint): Inherit from breakpoint.
11803 <~longjmp_breakpoint>: New.
11804 <base>: Remove.
11805 (new_breakpoint_from_type): Remove casts.
11806 (watchpoint_in_thread_scope): Remove reference to base field.
11807 (watchpoint_del_at_next_stop): Likewise.
11808 (update_watchpoint): Likewise.
11809 (watchpoint_check): Likewise.
11810 (bpstat_check_watchpoint): Likewise.
11811 (set_longjmp_breakpoint): Likewise.
11812 (struct fork_catchpoint): Inherit from breakpoint.
11813 <base>: Remove.
11814 (struct solib_catchpoint): Inherit from breakpoint.
11815 <~solib_catchpoint>: New.
11816 <base>: Remove.
11817 (dtor_catch_solib): Change to ...
11818 (solib_catchpoint::~solib_catchpoint): ... this.
11819 (breakpoint_hit_catch_solib): Remove reference to base field.
11820 (add_solib_catchpoint): Likewise.
11821 (create_fork_vfork_event_catchpoint): Likewise.
11822 (struct exec_catchpoint): Inherit from breakpoint.
11823 <~exec_catchpoint>: New.
11824 <base>: Remove.
11825 (dtor_catch_exec): Change to ...
11826 (exec_catchpoint::~exec_catchpoint): ... this.
11827 (dtor_watchpoint): Change to ...
11828 (watchpoint::~watchpoint): ... this.
11829 (watch_command_1): Remove reference to base field.
11830 (catch_exec_command_1): Likewise.
11831 (base_breakpoint_dtor): Change to ...
11832 (breakpoint::~breakpoint): ... this.
11833 (base_breakpoint_ops): Remove dtor field value.
11834 (longjmp_bkpt_dtor): Change to ...
11835 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
11836 (strace_marker_create_breakpoints_sal): Remove reference to base
11837 field.
11838 (delete_breakpoint): Don't manually call breakpoint destructor.
11839 (create_tracepoint_from_upload): Remove reference to base field.
11840 (trace_pass_set_count): Likewise.
11841 (initialize_breakpoint_ops): Don't initialize
11842 momentary_breakpoint_ops, don't set dtors.
11843 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
11844 <~ada_catchpoint>: New.
11845 <base>: Remove.
11846 (create_excep_cond_exprs): Remove reference to base field.
11847 (dtor_exception): Change to ...
11848 (ada_catchpoint::~ada_catchpoint): ... this.
11849 (dtor_catch_exception): Remove.
11850 (dtor_catch_exception_unhandled): Remove.
11851 (dtor_catch_assert): Remove.
11852 (create_ada_exception_catchpoint): Remove reference to base
11853 field.
11854 (initialize_ada_catchpoint_ops): Don't set dtors.
11855 * break-catch-sig.c (struct signal_catchpoint): Inherit from
11856 breakpoint.
11857 <~signal_catchpoint>: New.
11858 <base>: Remove.
11859 (signal_catchpoint_dtor): Change to ...
11860 (signal_catchpoint::~signal_catchpoint): ... this.
11861 (create_signal_catchpoint): Remove reference to base field.
11862 (initialize_signal_catchpoint_ops): Don't set dtor.
11863 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
11864 from breakpoint.
11865 <~syscall_catchpoint>: New.
11866 <base>: Remove.
11867 (dtor_catch_syscall): Change to ...
11868 (syscall_catchpoint::~syscall_catchpoint): ... this.
11869 (create_syscall_event_catchpoint): Remove reference to base
11870 field.
11871 (initialize_syscall_catchpoint_ops): Don't set dtor.
11872 * break-catch-throw.c (struct exception_catchpoint): Inherit
11873 from breakpoint.
11874 <~exception_catchpoint>: New.
11875 <base>: Remove.
11876 (dtor_exception_catchpoint): Change to ...
11877 (exception_catchpoint::~exception_catchpoint): ... this.
11878 (handle_gnu_v3_exceptions): Remove reference to base field.
11879 (initialize_throw_catchpoint_ops): Don't set dtor.
11880 * ctf.c (ctf_get_traceframe_address): Remove reference to base
11881 field.
11882 * remote.c (remote_get_tracepoint_status): Likewise.
11883 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
11884 * tracefile.c (tracefile_fetch_registers): Likewise.
11885 * tracepoint.c (actions_command): Likewise.
11886 (validate_actionline): Likewise.
11887 (tfind_1): Likewise.
11888 (get_traceframe_location): Likewise.
11889 (find_matching_tracepoint_location): Likewise.
11890 (parse_tracepoint_status): Likewise.
11891 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
11892
3b0871f4
SM
118932017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11894
11895 * breakpoint.c (struct longjmp_breakpoint): New struct.
11896 (is_tracepoint_type): Change return type to bool.
11897 (is_longjmp_type): New function.
11898 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
11899 (set_raw_breakpoint_without_location): Use
11900 new_breakpoint_from_type.
11901 (set_raw_breakpoint): Likewise.
11902
a5e364af
SM
119032017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11904
11905 * breakpoint.c (new_breakpoint_from_type): New function.
11906 (create_breakpoint_sal): Use new_breakpoint_from_type and
11907 unique_ptr.
11908 (create_breakpoint): Likewise.
11909
ae3b3f34
SM
119102017-05-31 Simon Marchi <simon.marchi@ericsson.com>
11911
11912 * memattr.c (mem_info_command): Rename to ...
11913 (info_mem_command): ... this.
11914 (mem_enable_command): Rename to ...
11915 (enable_mem_command): ... this.
11916 (mem_disable_command): Rename to ...
11917 (disable_mem_command): ... this.
11918 (mem_delete_command): Rename to ...
11919 (delete_mem_command): ... this.
11920 (_initialize_mem): Adjust function names.
11921
13ace077
MM
119222017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11923
11924 * btrace.c (handle_pt_insn_events): New.
11925 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
11926 STATUS. Split into this and ...
11927 (handle_pt_insn_event_flags): ... this.
11928
c56ccc05
MM
119292017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11930
11931 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
11932 and struct pt_insn.resynced.
11933 * configure: Regenerated.
11934 * config.in: Regenerated.
11935
08c3f6d2
TW
119362017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11937
11938 * btrace.c (ftrace_find_call_by_number): New function.
11939 (ftrace_new_function): Store objects, not pointers.
11940 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
11941 ftrace_new_gap, ftrace_update_function,
11942 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
11943 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
11944 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
11945 btrace_ends_with_single_insn, btrace_call_get): Account for
11946 btrace_thread_info::functions now storing objects.
11947 * btrace.h (struct btrace_thread_info): Add constructor.
11948 (struct btrace_thread_info) <functions>: Make std::vector.
11949 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
11950 Initialize with default values.
11951 * record-btrace.c (record_btrace_frame_sniffer): Account for
11952 btrace_thread_info::functions now storing objects.
11953
8ffd39f2
TW
119542017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11955
11956 * btrace.c: Remove typedef bfun_s.
11957 (ftrace_new_gap): Directly add gaps to the list of gaps.
11958 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
11959 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
11960 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
11961 instead of gdb VEC.
11962
4aeb0dfc
TW
119632017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11964
11965 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
11966 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
11967 with btrace_thread_info::next_segment and
11968 btrace_thread_info::prev_segment.
11969 * btrace.h: Remove struct btrace_func_link.
11970 (struct btrace_function): Replace pair of function segment pointers
11971 with pair of indices.
11972 * python/py-record-btrace.c (btpy_call_prev_sibling,
11973 btpy_call_next_sibling): Replace references to
11974 btrace_thread_info::segment with btrace_thread_info::next_segment and
11975 btrace_thread_info::prev_segment.
11976 * record-btrace.c (record_btrace_frame_this_id): Use
11977 btrace_find_call_by_number.
11978
eb8f2b9c
TW
119792017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11980
11981 * btrace.c (ftrace_new_function, ftrace_fixup_level,
11982 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
11983 btrace_insn_next, btrace_insn_prev): Remove references to
11984 btrace_thread_info::flow.
11985 * btrace.h (struct btrace_function): Remove FLOW.
11986
42bfe59e
TW
119872017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11988
11989 * btrace.c (ftrace_find_call_by_number): New function.
11990 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
11991 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
11992 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
11993 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
11994 index.
11995 * btrace.h (struct btrace_function): Turn UP into an index.
11996 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
11997 as an index.
11998 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
11999 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
12000 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
12001
b54b03bd
TW
120022017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12003
12004 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12005 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12006 ftrace_update_function, ftrace_compute_global_level_offset,
12007 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
12008 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
12009 btrace_insn_end, btrace_is_empty): Remove references to
12010 btrace_thread_info::begin and btrace_thread_info::end.
12011 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
12012 (struct btrace_thread_info) <functions>: Adjust comment.
12013 * record-btrace.c (record_btrace_start_replaying): Remove reference to
12014 btrace_thread_info::begin.
12015
8286623c
TW
120162017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12017
12018 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
12019 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
12020 ftrace_update_function): Remove arguments that implicitly were always
12021 BTINFO->END.
12022 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
12023 Don't pass BTINFO->END.
12024
a0f1b963
TW
120252017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12026
12027 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
12028 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
12029 btrace_find_insn_by_number): Replace function segment pointer with
12030 index.
12031 (btrace_insn_cmp): Simplify.
12032 * btrace.h: (struct btrace_insn_iterator) Rename index to
12033 insn_index. Replace function segment pointer with index into function
12034 segment vector.
12035 * record-btrace.c (record_btrace_call_history): Replace function
12036 segment pointer use with index.
12037 (record_btrace_frame_sniffer): Retrieve function call segment through
12038 vector.
12039 (record_btrace_set_replay): Remove defunc't safety check.
12040
f158f208
TW
120412017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12042
12043 * btrace.c (btrace_ends_with_single_insn): New function.
12044 (btrace_call_get, btrace_call_number, btrace_call_begin,
12045 btrace_call_end, btrace_call_next, btrace_call_prev,
12046 btrace_find_call_by_number): Use index into call segment vector
12047 instead of pointer.
12048 (btrace_call_cmp): Simplify.
12049 * btrace.h (struct btrace_call_iterator): Replace function call segment
12050 pointer with index into vector.
12051 * record-btrace.c (record_btrace_call_history): Use index instead of
12052 pointer.
12053
521103fd
TW
120542017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12055
12056 * btrace.c (btrace_insn_begin, btrace_insn_end,
12057 btrace_find_insn_by_number): Add btinfo to iterator.
12058 * btrace.h (struct btrace_insn_iterator): Add btinfo.
12059
17b89b34
TW
120602017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12061
12062 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
12063 and save pointers directly.
12064 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
12065 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
12066 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
12067 changed signature of functions.
12068 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
12069 (btrace_fetch): Remove code that adds btrace_function pointers to
12070 vector of btrace_functions.
12071 (btrace_clear): Simplify freeing vector of btrace_functions.
12072
2b51eddc
TW
120732017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
12074
12075 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
12076 Replace VEC_* with std::vector functions.
12077 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
12078 (struct btrace_thread_info)<functions>: Change type to std::vector.
12079
db6be0d5
SM
120802017-05-30 Simon Marchi <simon.marchi@ericsson.com>
12081
12082 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
12083 "Removed targets and native configurations" up. Merge duplicate
12084 "New commands" sub-sections. Add "New options" sub-sections.
12085
b057297a
AH
120862017-05-26 Alan Hayward <alan.hayward@arm.com>
12087
12088 * defs.h (copy_integer_to_size): New declaration.
12089 * findvar.c (copy_integer_to_size): New function.
12090 (do_cint_test): New selftest function.
12091 (copy_integer_to_size_test): Likewise.
12092 (_initialize_findvar): Likewise.
12093 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
12094 (mips_fbsd_collect_reg): Use raw_collect_integer.
12095 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
12096 (mips64_fill_gregset): Use raw_collect_integer
12097 (mips64_fill_fpregset): Use raw_supply_integer.
12098 * regcache.c (regcache::raw_supply_integer): New function.
12099 (regcache::raw_collect_integer): Likewise.
12100 * regcache.h: (regcache::raw_supply_integer): New declaration.
12101 (regcache::raw_collect_integer): Likewise.
12102
b77b02a5
YQ
121032017-05-24 Yao Qi <yao.qi@linaro.org>
12104
12105 * Makefile.in (SFILES): Add gdbarch-selftests.c.
12106 (COMMON_OBS): Add gdbarch-selftests.o.
12107 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
12108 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
12109 * gdbarch-selftests.c: New file.
12110 * regcache.h (regcache) <~regcache>: Mark it virtual if
12111 GDB_SELF_TEST.
12112 <raw_write>: Likewise.
12113
e521e87e
YQ
121142017-05-24 Yao Qi <yao.qi@linaro.org>
12115
12116 * regcache.c (current_regcache): Change it to
12117 regcache::current_regcache.
12118 (regcache_observer_target_changed): Update.
12119 (regcache_thread_ptid_changed): Make it a regcache static
12120 method.
12121 (regcache_thread_ptid_changed): Update.
12122 (class regcache_access): New.
12123 (current_regcache_test): Update.
12124 (_initialize_regcache): Update.
12125 * regcache.h: Include forward_list.
12126 (regcache): Declare regcache_thread_ptid_changed and declare
12127 registers_changed_ptid as friend.
12128
d8e07dda
YQ
121292017-05-24 Yao Qi <yao.qi@linaro.org>
12130
12131 * i387-tdep.c (i387_register_to_value): Use register_size
12132 instead of TYPE_LENGTH.
12133 * m68k-tdep.c (m68k_register_to_value): Likewise.
12134
8c8f9122
YQ
121352017-05-24 Yao Qi <yao.qi@linaro.org>
12136
12137 * i387-tdep.c (i387_convert_register_p): Return false if type
12138 code isn't TYPE_CODE_FLT.
12139
68fce50f
YQ
121402017-05-24 Yao Qi <yao.qi@linaro.org>
12141
12142 * alpha-tdep.c (alpha_convert_register_p): Return true if type
12143 length is 4.
12144 (alpha_register_to_value): Remove type length check.
12145 (alpha_value_to_register): Likewise.
12146
88954b49
YQ
121472017-05-24 Yao Qi <yao.qi@linaro.org>
12148
12149 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
12150 TYPE_CODE_FLT.
12151
e3ec9b69
YQ
121522017-05-24 Yao Qi <yao.qi@linaro.org>
12153
12154 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
12155 TYPE_CODE_FLT or not.
12156
cdd238da
YQ
121572017-05-24 Yao Qi <yao.qi@linaro.org>
12158
12159 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
12160 * avr-tdep.c (avr_gdbarch_init): Likewise.
12161 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12162 * cris-tdep.c (cris_gdbarch_init): Likewise.
12163 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12164 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12165 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12166 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
12167 * mep-tdep.c (mep_gdbarch_init): Likewise.
12168 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12169 * mips-tdep.c (mips_gdbarch_init): Likewise.
12170 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12171 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12172 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12173 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12174 * v850-tdep.c (v850_gdbarch_init): Likewise.
12175
7a3929c4
YQ
121762017-05-24 Yao Qi <yao.qi@linaro.org>
12177
12178 * selftest-arch.c (tests_with_arch): Call registers_changed
12179 and reinit_frame_cache.
12180 * selftest.c (run_self_tests): Likewise.
12181
f4985dba
YQ
121822017-05-24 Yao Qi <yao.qi@linaro.org>
12183
12184 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
12185 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
12186
ab20fa4a
YQ
121872017-05-24 Yao Qi <yao.qi@linaro.org>
12188
12189 * rl78-tdep.c (rl78_gdbarch_init): Don't call
12190 set_gdbarch_print_insn.
12191
f532ab94
YQ
121922017-05-24 Yao Qi <yao.qi@linaro.org>
12193
12194 * h8300-tdep.c (h8300_gdbarch_init): Don't call
12195 set_gdbarch_print_insn.
12196
39503f82
YQ
121972017-05-24 Yao Qi <yao.qi@linaro.org>
12198
12199 * alpha-tdep.c (alpha_gdbarch_init): Don't call
12200 set_gdbarch_print_insn.
12201 * arc-tdep.c (arc_gdbarch_init): Likewise.
12202 * arch-utils.c: include dis-asm.h.
12203 (default_print_insn): New function.
12204 * arch-utils.h (default_print_insn): Declare.
12205 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
12206 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
12207 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
12208 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
12209 * frv-tdep.c (frv_gdbarch_init): Likewise.
12210 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
12211 * gdbarch.sh (print_insn): Use default_print_insn.
12212 * gdbarch.c: Regenerated.
12213 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
12214 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
12215 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
12216 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
12217 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12218 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
12219 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
12220 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
12221 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
12222 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
12223 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
12224 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12225 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
12226 * mt-tdep.c (mt_gdbarch_init): Likewise.
12227 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12228 * nios2-tdep.c (nios2_print_insn): Remove.
12229 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
12230 * rx-tdep.c (rx_gdbarch_init): Likewise.
12231 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
12232 * score-tdep.c (score_print_insn): Remove.
12233 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
12234 * sh-tdep.c (sh_gdbarch_init): Likewise.
12235 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
12236 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12237 * tic6x-tdep.c (tic6x_print_insn): Remove.
12238 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
12239 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
12240 * v850-tdep.c (v850_gdbarch_init): Likewise.
12241 * vax-tdep.c (vax_gdbarch_init): Likewise.
12242 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12243 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
12244
f7241d4f
JB
122452017-05-23 John Baldwin <jhb@FreeBSD.org>
12246
12247 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
12248 (MIPS_FP0_REGNUM): Remove.
12249 (MIPS_FSR_REGNUM): Remove.
12250 (mips_fbsd_supply_fpregs): Use mips_regnum.
12251 (mips_fbsd_supply_gregs): Likewise.
12252 (mips_fbsd_collect_fpregs): Likewise.
12253 (mips_fbsd_collect_gregs): Likewise.
12254
d489d81d
JB
122552017-05-23 John Baldwin <jhb@FreeBSD.org>
12256
12257 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
12258 (getpfpregs_supplies): New function.
12259 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
12260 getfpregs_supplies.
12261 (mips_fbsd_store_inferior_registers): Likewise.
12262
e11b3cdc
PA
122632017-05-22 Pedro Alves <palves@redhat.com>
12264
12265 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
12266 maintainer.
12267
0f068fb5
AH
122682017-05-22 Alan Hayward <alan.hayward@arm.com>
12269
12270 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
12271 (store_register): Likewise.
12272 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
12273 (get_decimal_float_return_value): Likewise.
12274 (do_ppc_sysv_return_value): Likewise.
12275 (ppc64_sysv_abi_push_integer): Likewise.
12276 (ppc64_sysv_abi_push_freg): Likewise.
12277 (ppc64_sysv_abi_return_value_base): Likewise.
12278 (ppc64_sysv_abi_return_value): Likewise.
12279 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
12280 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
12281 * rs6000-nat.c: Likewise.
12282 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
12283 (rs6000_value_to_register): Likewise.
12284 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
12285
e6cf65f2
TT
122862017-05-21 Tom Tromey <tom@tromey.com>
12287
12288 PR rust/21466:
12289 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
12290 arrays as "[T]", not "[T; ]".
12291
43cc5389
TT
122922017-05-19 Tom Tromey <tom@tromey.com>
12293
12294 PR rust/21484:
12295 * rust-lang.c (exp_descriptor_rust): New function.
12296 (rust_language_defn): Use it.
12297 * p-lang.c (pascal_language_defn): Update.
12298 * opencl-lang.c (opencl_language_defn): Update.
12299 * objc-lang.c (objc_language_defn): Update.
12300 * m2-lang.c (m2_language_defn): Update.
12301 * language.h (struct language_defn)
12302 <la_watch_location_expression>: New member.
12303 * language.c (unknown_language_defn, auto_language_defn)
12304 (local_language_defn): Update.
12305 * go-lang.c (go_language_defn): Update.
12306 * f-lang.c (f_language_defn): Update.
12307 * d-lang.c (d_language_defn): Update.
12308 * c-lang.h (c_watch_location_expression): Declare.
12309 * c-lang.c (c_watch_location_expression): New function.
12310 (c_language_defn, cplus_language_defn, asm_language_defn)
12311 (minimal_language_defn): Use it.
12312 * breakpoint.c (watch_command_1): Call
12313 la_watch_location_expression.
12314 * ada-lang.c (ada_language_defn): Update.
12315
7a6e7fcc
RO
123162017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12317
6e7e1744
RO
12318 PR tui/21482
12319 * gdb_curses.h (NOMACROS): Define.
12320 (NCURSES_NOMACROS): Define.
12321
123222017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12323
12324 PR tui/21482
7a6e7fcc
RO
12325 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
12326 arg to char *.
12327 * tui/tui-wingeneral.c (box_win): Likewise.
12328 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
12329 (tui_show_source_line): Likewise.
12330 (tui_show_exec_info_content): Likewise.
12331
1933fd8e
VM
123322017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
12333
12334 * sparc-tdep.c (sparc_structure_return_p)
12335 (sparc_arg_on_registers_p): New functions.
12336 (sparc32_store_arguments): Use them.
12337 * sparc64-tdep.c (sparc64_16_byte_align_p)
12338 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
12339 Handle TYPE_CODE_ARRAY.
12340
21873064
YQ
123412017-05-17 Yao Qi <yao.qi@linaro.org>
12342
12343 * cli/cli-decode.c (add_alias_cmd): New function.
12344 * command.h (add_alias_cmd): Declare.
12345 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
12346 instead call add_alias_cmd.
12347
2b351b19
PA
123482017-05-17 Pedro Alves <palves@redhat.com>
12349
12350 * Makefile.in (nat_extra_makefile_frag): Rename to ...
12351 (nat_makefile_frag): ... this. All references updated.
12352 * configure.ac: Likewise.
12353 * configure.nat: Likewise. Enhance comments.
12354 * configure: Regenerate.
12355
5f2ad7a3
RO
123562017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12357
12358 * procfs.c (procfs_create_inferior): Change prototype to match
12359 definition.
12360
adf3dde5
EZ
123612017-05-13 Eli Zaretskii <eliz@gnu.org>
12362
12363 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
12364 C++ compiler warning.
12365
6830f270
TT
123662017-05-12 Tom Tromey <tom@tromey.com>
12367
12368 PR rust/21483:
12369 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
12370 recurse, just call value_struct_elt directly.
12371
68f2f2e3
TT
123722017-05-12 Tom Tromey <tom@tromey.com>
12373
12374 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
12375 OP_RUST_ARRAY>: Fix.
12376
256afbc2
TT
123772017-05-12 Tom Tromey <tom@tromey.com>
12378
12379 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
12380
94bb8dfe
YQ
123812017-05-09 Yao Qi <yao.qi@linaro.org>
12382
12383 * regcache.c: Include <forward_list>.
12384 (struct regcache_list): Remove.
12385 (current_regcache): Update.
12386 (get_thread_arch_aspace_regcache): Update for std::forward_list.
12387 (regcache_thread_ptid_changed): Likewise.
12388 (registers_changed_ptid): Likewise.
12389 (current_regcache_size): Likewise.
12390
8248946c
YQ
123912017-05-09 Yao Qi <yao.qi@linaro.org>
12392
12393 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
12394 (current_regcache_size): New function.
12395 (current_regcache_test): New function.
12396 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
12397
313c5961
AH
123982017-05-08 Alan Hayward <alan.hayward@arm.com>
12399
12400 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
12401 (print_gp_register_row): Use get_frame_register_value.
12402
27bfc1d1
AH
124032017-05-08 Alan Hayward <alan.hayward@arm.com>
12404
12405 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
12406 (mips_supply_fpregset): Likewise.
12407 (mips64_supply_gregset): Likewise.
12408
146e6c5c
AH
124092017-05-08 Alan Hayward <alan.hayward@arm.com>
12410
12411 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
12412 regcache->raw_supply_zeroed.
12413
e50f25ec
SDJ
124142017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12415
12416 * configure.nat: Rearrange 'case' statements to match
12417 host before cpu.
12418
21ea5acd
SDJ
124192017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
12420
12421 * Makefile.in: Remove "@host_makefile_frag@". Add variables
12422 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
12423 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
12424 "@nat_extra_makefile_frag@".
12425 (Makefile): Remove dependency on "@frags@".
12426 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
12427 (data-directory/Makefile): Likewise.
12428 * config/aarch64/linux.mh: Deleted; moved contents to
12429 "gdb/configure.nat".
12430 * config/alpha/alpha-linux.mh: Likewise.
12431 * config/alpha/nbsd.mh: Likewise.
12432 * config/arm/linux.mh: Likewise.
12433 * config/arm/nbsdelf.mh: Likewise.
12434 * config/i386/cygwin.mh: Likewise.
12435 * config/i386/cygwin64.mh: Likewise.
12436 * config/i386/darwin.mh: Likewise.
12437 * config/i386/fbsd.mh: Likewise.
12438 * config/i386/fbsd64.mh: Likewise.
12439 * config/i386/go32.mh: Likewise.
12440 * config/i386/i386gnu.mh: Likewise.
12441 * config/i386/i386sol2.mh: Likewise.
12442 * config/i386/linux.mh: Likewise.
12443 * config/i386/linux64.mh: Likewise.
12444 * config/i386/mingw.mh: Likewise.
12445 * config/i386/mingw64.mh: Likewise.
12446 * config/i386/nbsd64.mh: Likewise.
12447 * config/i386/nbsdelf.mh: Likewise.
12448 * config/i386/nto.mh: Likewise.
12449 * config/i386/obsd.mh: Likewise.
12450 * config/i386/obsd64.mh: Likewise.
12451 * config/i386/sol2-64.mh: Likewise.
12452 * config/ia64/linux.mh: Likewise.
12453 * config/m32r/linux.mh: Likewise.
12454 * config/m68k/linux.mh: Likewise.
12455 * config/m68k/nbsdelf.mh: Likewise.
12456 * config/m68k/obsd.mh: Likewise.
12457 * config/m88k/obsd.mh: Likewise.
12458 * config/mips/fbsd.mh: Likewise.
12459 * config/mips/linux.mh: Likewise.
12460 * config/mips/nbsd.mh: Likewise.
12461 * config/mips/obsd64.mh: Likewise.
12462 * config/pa/linux.mh: Likewise.
12463 * config/pa/nbsd.mh: Likewise.
12464 * config/pa/obsd.mh: Likewise.
12465 * config/powerpc/aix.mh: Likewise.
12466 * config/powerpc/fbsd.mh: Likewise.
12467 * config/powerpc/linux.mh: Likewise.
12468 * config/powerpc/nbsd.mh: Likewise.
12469 * config/powerpc/obsd.mh: Likewise.
12470 * config/powerpc/ppc64-linux.mh: Likewise.
12471 * config/powerpc/spu-linux.mh: Likewise.
12472 * config/s390/linux.mh: Likewise.
12473 * config/sh/nbsd.mh: Likewise.
12474 * config/sparc/fbsd.mh: Likewise.
12475 * config/sparc/linux.mh: Likewise.
12476 * config/sparc/linux64.mh: Likewise.
12477 * config/sparc/nbsd64.mh: Likewise.
12478 * config/sparc/nbsdelf.mh: Likewise.
12479 * config/sparc/obsd64.mh: Likewise.
12480 * config/sparc/sol2.mh: Likewise.
12481 * config/tilegx/linux.mh: Likewise.
12482 * config/vax/nbsdelf.mh: Likewise.
12483 * config/vax/obsd.mh: Likewise.
12484 * config/xtensa/linux.mh: Likewise.
12485 * config/i386/i386gnu.mn: New file, with excerpts from
12486 "config/i386/i386gnu.mh".
12487 * configure: Regenerate.
12488 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
12489 *.mh files under "gdb/config".
12490 * configure.nat: New file, with contents from the
12491 "gdb/config/*/*.mh" files.
12492
7ed1acaf
TW
124932017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
12494
12495 * btrace.c (btrace_clear): Free insn vector.
12496
e13cb306
PA
124972017-05-05 Pedro Alves <palves@redhat.com>
12498
12499 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
12500 * configure: Regenerate.
12501
5ed8105e
PA
125022017-05-04 Pedro Alves <palves@redhat.com>
12503
12504 * Makefile.in (SFILES): Add progspace-and-thread.c.
12505 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
12506 (COMMON_OBS): Add progspace-and-thread.o.
12507 * breakpoint.c: Include "progspace-and-thread.h".
12508 (update_inserted_breakpoint_locations)
12509 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
12510 Use scoped_restore_current_pspace_and_thread.
12511 (create_std_terminate_master_breakpoint): Use
12512 scoped_restore_current_program_space.
12513 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
12514 (print_breakpoint_location): Use
12515 scoped_restore_current_program_space.
12516 (bp_loc_is_permanent): Use
12517 scoped_restore_current_pspace_and_thread.
12518 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
12519 (download_tracepoint_locations): Use
12520 scoped_restore_current_pspace_and_thread.
12521 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
12522 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
12523 (enum step_over_calls_kind): Moved from inferior.h.
12524 (class scoped_restore_current_thread): New class.
12525 * gdbthread.h (make_cleanup_restore_current_thread): Delete
12526 declaration.
12527 (scoped_restore_current_thread): New class.
12528 * infcmd.c: Include "common/gdb_optional.h".
12529 (continue_1, proceed_after_attach): Use
12530 scoped_restore_current_thread.
12531 (notice_new_inferior): Use scoped_restore_current_thread.
12532 * inferior.c: Include "progspace-and-thread.h".
12533 (restore_inferior, save_current_inferior): Delete.
12534 (add_inferior_command, clone_inferior_command): Use
12535 scoped_restore_current_pspace_and_thread.
12536 * inferior.h (scoped_restore_current_inferior): New class.
12537 * infrun.c: Include "progspace-and-thread.h" and
12538 "common/gdb_optional.h".
12539 (follow_fork_inferior): Use
12540 scoped_restore_current_pspace_and_thread.
12541 (scoped_restore_exited_inferior): New class.
12542 (handle_vfork_child_exec_or_exit): Use
12543 scoped_restore_exited_inferior,
12544 scoped_restore_current_pspace_and_thread,
12545 scoped_restore_current_thread and scoped_restore.
12546 (fetch_inferior_event): Use scoped_restore_current_thread.
12547 * linespec.c (decode_line_full, decode_line_1): Use
12548 scoped_restore_current_program_space.
12549 * mi/mi-main.c: Include "progspace-and-thread.h".
12550 (exec_continue): Use scoped_restore_current_thread.
12551 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
12552 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
12553 * proc-service.c (ps_pglobal_lookup): Use
12554 scoped_restore_current_program_space.
12555 * progspace-and-thread.c: New file.
12556 * progspace-and-thread.h: New file.
12557 * progspace.c (release_program_space, clone_program_space): Use
12558 scoped_restore_current_program_space.
12559 (restore_program_space, save_current_program_space)
12560 (save_current_space_and_thread): Delete.
12561 (switch_to_program_space_and_thread): Moved to
12562 progspace-and-thread.c.
12563 * progspace.h (save_current_program_space)
12564 (save_current_space_and_thread): Delete declarations.
12565 (scoped_restore_current_program_space): New class.
12566 * remote.c (remote_btrace_maybe_reopen): Use
12567 scoped_restore_current_thread.
12568 * symtab.c: Include "progspace-and-thread.h".
12569 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
12570 * thread.c (print_thread_info_1): Use
12571 scoped_restore_current_thread.
12572 (struct current_thread_cleanup): Delete.
12573 (do_restore_current_thread_cleanup)
12574 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
12575 (scoped_restore_current_thread::~scoped_restore_current_thread):
12576 ... this new dtor.
12577 (make_cleanup_restore_current_thread): Rename/convert to ...
12578 (scoped_restore_current_thread::scoped_restore_current_thread):
12579 ... this new ctor.
12580 (thread_apply_all_command): Use scoped_restore_current_thread.
12581 (thread_apply_command): Use scoped_restore_current_thread.
12582 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
12583 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
12584
f6223dbb
PA
125852017-05-04 Pedro Alves <palves@redhat.com>
12586
12587 * thread.c (make_cleanup_restore_current_thread): Move
12588 find_thread_ptid call before the is_stopped call. Assert that the
12589 thread is found. Replace is_stopped call by checking the thread's
12590 state directly. Remove unnecessary NULL-thread check.
12591
3c3ae77e
PA
125922017-05-04 Pedro Alves <palves@redhat.com>
12593
12594 * corelow.c (thread_section_name): New class.
12595 (get_core_register_section, get_core_siginfo): Use it.
12596
45eba0ab
AA
125972017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
12598
12599 * corelow.c (sniff_core_bfd): Remove extra semicolon.
12600 (get_core_register_section): Remove xfree of NULL pointer.
12601
f81fdd35
AH
126022017-05-03 Alan Hayward <alan.hayward@arm.com>
12603
12604 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
12605 * regcache.c (regcache::raw_supply_zeroed): New function.
12606 * regcache.h (regcache::raw_supply_zeroed): New declaration.
12607
35837774
SM
126082017-05-03 Simon Marchi <simon.marchi@ericsson.com>
12609
12610 * gdbarch.sh: Remove commented out definition of
12611 TARGET_CHAR_BIT.
12612 * gdbarch.h: Re-generate.
12613
c94fee56
SDJ
126142017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
12615
12616 * configure: Regenerate.
12617
d17f7b36
SM
126182017-05-02 Simon Marchi <simon.marchi@ericsson.com>
12619
12620 * solib-target.c (solib_target_relocate_section_addresses):
12621 Remove num_section_bases, num_bases, segment_bases variables.
12622
b560ebd6
SM
126232017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12624
12625 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
12626
f2f46dfc
SM
126272017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12628
12629 * solib-target.c: Include <vector>
12630 (struct lm_info_target) <~lm_info_target>: Remove.
12631 <segment_bases, section_bases>: Change type to
12632 std::vector<CORE_ADDR>.
12633 (library_list_start_segment, library_list_start_section,
12634 library_list_end_library,
12635 solib_target_relocate_section_addresses): Adjust.
12636
a0ff9e1a
SM
126372017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12638
12639 * gdbarch.sh (software_single_step): Change return type to
12640 std::vector<CORE_ADDR>.
12641 * gdbarch.c, gdbarch.h: Re-generate.
12642 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
12643 Adjust.
12644 (arm_deal_with_atomic_sequence_raw): Adjust.
12645 (thumb_get_next_pcs_raw): Adjust.
12646 (arm_get_next_pcs_raw): Adjust.
12647 (arm_get_next_pcs): Adjust.
12648 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
12649 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
12650 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
12651 (alpha_software_single_step): Adjust.
12652 * alpha-tdep.h (alpha_software_single_step): Adjust.
12653 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
12654 * arm-tdep.c (arm_software_single_step): Adjust.
12655 (arm_breakpoint_kind_from_current_state): Adjust.
12656 * arm-tdep.h (arm_software_single_step): Adjust.
12657 * breakpoint.c (insert_single_step_breakpoint): Adjust.
12658 * cris-tdep.c (cris_software_single_step): Adjust.
12659 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
12660 (micromips_deal_with_atomic_sequence): Adjust.
12661 (deal_with_atomic_sequence): Adjust.
12662 (mips_software_single_step): Adjust.
12663 * mips-tdep.h (mips_software_single_step): Adjust.
12664 * moxie-tdep.c (moxie_software_single_step): Adjust.
12665 * nios2-tdep.c (nios2_software_single_step): Adjust.
12666 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
12667 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
12668 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
12669 * s390-linux-tdep.c (s390_software_single_step): Adjust.
12670 * sparc-tdep.c (sparc_software_single_step): Adjust.
12671 * spu-tdep.c (spu_software_single_step): Adjust.
12672 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
12673
ea480a30
SM
126742017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12675
12676 * gdbarch.sh: Use semi-colon as field separator instead of colon.
12677 * gdbarch.h: Re-generate.
12678
d050f7d7
TW
126792017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12680
12681 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
12682 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
12683 * python/py-instruction.c, python/py-instruction.h: New file.
12684 * python/py-record.c: Add py-instruction.h include.
12685 (gdbpy_initialize_record): Make gdb.Instruction a super class of
12686 gdb.RecordInstruction.
12687 * python/python-internal.h: Add gdbpy_initialize_instruction
12688 declaration.
12689 * python/python.c (do_start_initialization): Add
12690 gdbpy_initialize_instruction.
12691
14f819c8
TW
126922017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12693
12694 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
12695 Remove.
12696 (btrace_func_from_recpy_func): New function.
12697 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
12698 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
12699 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
12700 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
12701 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
12702 Also, use new helper functions.
12703 (btpy_list_item): Use new helper functions.
12704 (recpy_bt_function_call_history): Use new type name.
12705 (btpy_call_getset): Remove.
12706 (gdbpy_initialize_btrace): Remove code to initialize
12707 gdb.BtraceFunctionCall.
12708 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
12709 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
12710 recpy_bt_func_prev, recpy_bt_func_next): New export.
12711 * python/py-record.c (recpy_func_type): New static object.
12712 (recpy_func_new, recpy_func_level, recpy_func_symbol,
12713 recpy_func_instructions, recpy_func_up, recpy_func_prev,
12714 recpy_func_next): New function.
12715 (recpy_element_hash, recpy_element_richcompare): Updated comment.
12716 (recpy_func_getset): New static object.
12717 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
12718 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
12719
0ed5da75
TW
127202017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12721
12722 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
12723 (btpy_object, btpy_insn_type, btpy_new): Remove.
12724 (btpy_list_object): Use gdb.RecordInstruction type instead of
12725 gdb.BtraceInstruction type.
12726 (btrace_insn_from_recpy_insn): New function.
12727 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
12728 btpy_new.
12729 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
12730 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
12731 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
12732 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
12733 instead of btpy_object.
12734 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12735 btpy_insn_data, btpy_insn_decode): Rename to ...
12736 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
12737 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
12738 recpy_bt_insn_decode): This. Also, use new helper functions.
12739 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
12740 recpy_insn_type.
12741 (btpy_insn_getset): Remove.
12742 (gdbpy_initialize_btrace): Remove code to initialize
12743 gdb.BtraceInstruction. Use recpy_element_object.
12744 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
12745 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
12746 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
12747 * python/py-record.c (recpy_insn_type): New static object.
12748 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
12749 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
12750 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
12751 New function.
12752 (recpy_insn_getset): New static object.
12753 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
12754 * python/py-record.h (recpy_element_object): New typedef.
12755 (recpy_insn_type, recpy_insn_new): New export.
12756
913aeadd
TW
127572017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12758
12759 * py-record-btrace.c (btpy_insn_new): Removed.
12760 (btpy_insn_or_gap_new): New function.
12761 (btpy_insn_error): Removed.
12762 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12763 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
12764 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
12765 btpy_insn_or_gap_new instead of btpy_insn_new.
12766 (btpy_insn_getset): Remove btpy_insn_error.
12767 * py-record.c (recpy_gap_type): New static object.
12768 (recpy_gap_object): New typedef.
12769 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
12770 recpy_gap_reason_string): New function.
12771 (recpy_gap_getset): New static object.
12772 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
12773 * py-record.h (recpy_gap_new): New export.
12774
a3be24ad
TW
127752017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12776
12777 * python/py-record.c (recpy_ptid): Remove.
12778 (recpy_record_getset): Remove recpy_ptid.
12779
ae20e79a
TW
127802017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12781
12782 * btrace.c (btrace_fetch): Set inferior_ptid.
12783 * python/py-record-btrace.c: Add "py-record.h" include.
12784 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
12785 recpy_bt_end, recpy_bt_instruction_history,
12786 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
12787 in gdb.Record object instead of current ptid.
12788 * python/py-record.c: Include new "py-record.h" file.
12789 (recpy_record_object): Moved to py-record.h.
12790 * python/py-record.h: New file.
12791
8d0050ea
TW
127922017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12793
12794 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
12795 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
12796 indentation.
12797
3f380b50
JB
127982017-05-01 Joel Brobecker <brobecker@adacore.com>
12799
12800 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
12801 the past maintainers section.
12802
07495424
YQ
128032017-04-28 Yao Qi <yao.qi@linaro.org>
12804
12805 * infcmd.c (get_return_value): Use regcache ctor, and remove
12806 cleanup.
12807
deb1fa3e
YQ
128082017-04-28 Yao Qi <yao.qi@linaro.org>
12809 Pedro Alves <palves@redhat.com>
12810
12811 * regcache.c (regcache::regcache): New tag dispatch ctor.
12812 (do_cooked_read): Moved above.
12813 (regcache_dup): Use the tag dispatch ctor..
12814 * regcache.h (regcache): Declare ctor, delete copy ctor and
12815 assignment operator, remove friend regcache_dup.
12816
b421c83c
YQ
128172017-04-28 Yao Qi <yao.qi@linaro.org>
12818
12819 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
12820 call method save instead of regcache_cpy.
12821 * regcache.h (struct regcache): Make regcache_dup a friend.
12822
ef79d9a3
YQ
128232017-04-28 Yao Qi <yao.qi@linaro.org>
12824
12825 * regcache.c (struct regcache): Move to regcache.h
12826 (regcache::arch): New method.
12827 (regcache_get_ptid): Update.
12828 (get_regcache_arch): Call arch method.
12829 (get_regcache_aspace): Call method aspace.
12830 (register_buffer): Change it to method.
12831 (regcache_save): Change it to regcache::save.
12832 (regcache_restore): Likewise.
12833 (regcache_cpy_no_passthrough): Remove the declaration.
12834 (regcache_cpy): Call methods restore and cpy_no_passthrough.
12835 (regcache_cpy_no_passthrough): Change it to method
12836 cpy_no_passthrough.
12837 (regcache_register_status): Change it to method
12838 get_register_status.
12839 (regcache_invalidate): Change it to method invalidate.
12840 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
12841 (regcache_raw_update): Change it to method raw_update.
12842 (regcache_raw_read): Likewise.
12843 (regcache_raw_read_signed): Likewise.
12844 (regcache_raw_read_unsigned): Likewise.
12845 (regcache_raw_write_signed): Likewise.
12846 (regcache_raw_write_unsigned): Likewise.
12847 (regcache_cooked_read): Likewise.
12848 (regcache_cooked_read_value): Likewise.
12849 (regcache_cooked_read_signed): Likewise.
12850 (regcache_cooked_read_unsigned): Likewise.
12851 (regcache_cooked_write_signed): Likewise.
12852 (regcache_cooked_write_unsigned): Likewise.
12853 (regcache_raw_set_cached_value): Likewise.
12854 (regcache_raw_write): Likewise.
12855 (regcache_cooked_write): Likewise.
12856 (regcache_xfer_part): Likewise.
12857 (regcache_raw_read_part): Likewise.
12858 (regcache_raw_write_part): Likewise.
12859 (regcache_cooked_read_part): Likewise.
12860 (regcache_cooked_write_part): Likewise.
12861 (regcache_raw_supply): Likewise.
12862 (regcache_raw_collect): Likewise.
12863 (regcache_transfer_regset): Likewise.
12864 (regcache_supply_regset): Likewise.
12865 (regcache_collect_regset): Likewise.
12866 (regcache_debug_print_register): Likewise.
12867 (enum regcache_dump_what): Move it to regcache.h.
12868 (regcache_dump): Change it to method dump.
12869 * regcache.h (enum regcache_dump_what): New.
12870 (class regcache): New.
12871 * target.c (target_fetch_registers): Call method
12872 debug_print_register.
12873 (target_store_registers): Likewise.
12874
f8fdb78e
SM
128752017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12876
12877 * windows-nat.c (struct lm_info_windows): Initialize field.
12878 (windows_make_so): Allocate lm_info_windows with new.
12879 (windows_free_so): Free lm_info_windows with delete.
12880
9ccbfd7b
SM
128812017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12882
12883 * solib-darwin.c (struct lm_info_darwin): Initialize field.
12884 (darwin_current_sos): Allocate lm_info_darwin with new, remove
12885 cleanup.
12886 (darwin_free_so): Free lm_info_darwin with delete.
12887
76e75227
SM
128882017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12889
12890 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
12891 <l_addr_p>: Change type to bool.
12892 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
12893 (svr4_free_so): Free lm_info_svr4 with delete.
12894 (svr4_copy_library_list): Replace memcpy with call to copy
12895 constructor.
12896 (library_list_start_library, svr4_default_sos): Allocate
12897 lm_info_svr4 with new.
12898
51046d9e
SM
128992017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12900
12901 * solib-target.c (struct lm_info_target): Add destructor,
12902 initialize fields.
12903 <name>: Change type to std::string.
12904 (library_list_start_library): Allocate lm_info_target with new.
12905 (solib_target_free_library_list): Free lm_info_target with
12906 delete.
12907 (solib_target_current_sos): Adapt to std::string.
12908 (solib_target_free_so): Free lm_info_target with delete.
12909
4023ae76
SM
129102017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12911
12912 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
12913 fields.
12914 (frv_current_sos): Allocate lm_info_frv with new.
12915 (frv_relocate_main_executable): Free lm_info_frv with delete,
12916 allocate with new.
12917 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
12918
af43057b
SM
129192017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12920
12921 * solib-frv.c (struct lm_info_frv): Fix indentation.
12922
b0911207
SM
129232017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12924
12925 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
12926 map field.
12927 (dsbt_current_sos): Allocate lm_info_dsbt with new.
12928 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
12929 and allocate with new.
12930 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
12931
6c401f72
SM
129322017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12933
12934 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
12935 <filename, member_name>: Change type to std::string.
12936 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
12937 (library_list_start_library): Allocate lm_info_aix with new.
12938 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
12939 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
12940 with copy constructor.
12941
d0e449a1
SM
129422017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12943
12944 * solist.h (struct lm_info): Remove.
12945 (struct lm_info_base): New class.
12946 (struct so_list) <lm_info>: Change type to lm_info_base *.
12947 * nto-tdep.c (struct lm_info): Remove.
12948 (lm_addr): Adjust.
12949 * solib-aix.c (struct lm_info): Rename to ...
12950 (struct lm_info_aix): ... this. Extend lm_info_base.
12951 (lm_info_p): Rename to ...
12952 (lm_info_aix_p): ... this, and adjust.
12953 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
12954 solib_aix_parse_libraries, library_list_start_library,
12955 solib_aix_free_library_list, solib_aix_parse_libraries,
12956 solib_aix_get_library_list,
12957 solib_aix_relocate_section_addresses, solib_aix_free_so,
12958 solib_aix_get_section_offsets,
12959 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
12960 Adjust.
12961 (struct solib_aix_inferior_data) <library_list>: Adjust.
12962 * solib-darwin.c (struct lm_info): Rename to ...
12963 (struct lm_info_darwin): ... this. Extend lm_info_base.
12964 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
12965 * solib-dsbt.c (struct lm_info): Rename to ...
12966 (struct lm_info_dsbt): ... this. Extend lm_info_base.
12967 (struct dsbt_info) <main_executable_lm_info): Adjust.
12968 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
12969 dsbt_relocate_section_addresses): Adjust.
12970 * solib-frv.c (struct lm_info): Rename to ...
12971 (struct lm_info_frv): ... this. Extend lm_info_base.
12972 (main_executable_lm_info): Adjust.
12973 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
12974 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
12975 find_canonical_descriptor_in_load_object,
12976 frv_fdpic_find_canonical_descriptor): Adjust.
12977 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
12978 to lm_info_svr4.
12979 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
12980 svr4_clear_so, svr4_copy_library_list,
12981 library_list_start_library, svr4_default_sos, svr4_read_so_list,
12982 svr4_current_sos, svr4_fetch_objfile_link_map,
12983 solist_update_incremental): Adjust.
12984 * solib-svr4.h (struct lm_info_svr4): Move here from
12985 solib-svr4.c.
12986 * solib-target.c (struct lm_info): Rename to ...
12987 (struct lm_info_target): ... this. Extend lm_info_base.
12988 (lm_info_p): Rename to ...
12989 (lm_info_target_p): ... this.
12990 (solib_target_parse_libraries, library_list_start_segment,
12991 library_list_start_section, library_list_start_library,
12992 library_list_end_library, solib_target_free_library_list,
12993 solib_target_current_sos, solib_target_free_so,
12994 solib_target_relocate_section_addresses): Adjust.
12995 * windows-nat.c (struct lm_info): Rename to ...
12996 (struct lm_info_windows): ... this. Extend lm_info_base.
12997 (windows_make_so, handle_load_dll, handle_unload_dll,
12998 windows_xfer_shared_libraries): Adjust.
12999
434a4023
SM
130002017-04-28 Simon Marchi <simon.marchi@ericsson.com>
13001
13002 * solib-darwin.c (struct darwin_so_list): Remove.
13003 (darwin_current_sos): Allocate an so_list object instead of a
13004 darwin_so_list, separately allocate an lm_info object.
13005 (darwin_free_so): Free lm_info.
13006
428544e8
JB
130072017-04-28 John Baldwin <jhb@FreeBSD.org>
13008
13009 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
13010 with fprintf_filtered.
13011
4621115f
YQ
130122017-04-28 Yao Qi <yao.qi@linaro.org>
13013
13014 * regcache.c (regcache::regcache): New function.
13015 (regcache::~regcache): New function.
13016 (regcache_xmalloc_1): Remove.
13017 (regcache_xmalloc): Call new regcache.
13018 (regcache_xfree): Call delete regcache.
13019 (get_thread_arch_aspace_regcache): Call new regcache.
13020
339053c2
YQ
130212017-04-28 Yao Qi <yao.qi@linaro.org>
13022
13023 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
13024 lwp instead of ptid_get_lwp.
13025
7974a605
YQ
130262017-04-28 Yao Qi <yao.qi@linaro.org>
13027
13028 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
13029 lwp_info instead of getting from inferior_ptid.
13030
e15c3eb4
KS
130312017-04-27 Keith Seitz <keiths@redhat.com>
13032
13033 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
13034 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
13035 (CV_CONVERSION_BADNESS): Define.
13036 (rank_one_type): Remove overly restrictive rvalue reference
13037 rank checks.
13038 Add cv-qualifier checks and subranks for type equality.
13039 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
13040 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
13041 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
13042
72bc1d24
SM
130432017-04-27 Simon Marchi <simon.marchi@ericsson.com>
13044
13045 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
13046 count when creating the object.
13047
55bcecda
UW
130482017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
13049 Ulrich Weigand <uweigand@de.ibm.com>
13050
13051 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
13052 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
13053 is used in AIX.
13054 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
13055 (process_xcoff_symbol): Likewise.
13056 (scan_xcoff_symtab): Likewise.
13057
5c99fcf8
AH
130582017-04-26 Alan Hayward <alan.hayward@arm.com>
13059
13060 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
13061 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
13062 (ia64_access_reg): Use get_frame_register_unsigned.
13063 (ia64_access_rse_reg): Likewise.
13064 (ia64_libunwind_frame_prev_register): Likewise.
13065
b41c5a85
JW
130662017-04-26 Jiong Wang <jiong.wang@arm.com>
13067
13068 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
13069 * gdbarch.c: Regenerated.
13070 * gdbarch.h: Regenerated.
13071 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
13072 visibility external.
13073 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
13074 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
13075 (enum cfa_how_kind): Move to ...
13076 (struct dwarf2_frame_state_reg_info): Likewise.
13077 (struct dwarf2_frame_state): Likewise.
13078 * dwarf2-frame.h: ... here.
13079 (dwarf2_frame_state_alloc_regs): New declaration.
13080 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
13081 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
13082
c185f580
AH
130832017-04-26 Alan Hayward <alan.hayward@arm.com>
13084
13085 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
13086 regcache_raw_read_unsigned.
13087 (xtensa_pseudo_register_write): Likewise.
13088
19c45594
AH
130892017-04-26 Alan Hayward <alan.hayward@arm.com>
13090
13091 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
13092 (nds32_pseudo_register_write): Likewise.
13093
4658f12e
YQ
130942017-04-25 Yao Qi <yao.qi@linaro.org>
13095
13096 * regcache.c (struct regcache) <readonly_p>: Change its type
13097 to bool.
13098 (regcache_xmalloc_1): Update parameter type and callers update.
13099
d581dda8
YQ
131002017-04-25 Yao Qi <yao.qi@linaro.org>
13101
13102 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
13103 set_gdbarch_wchar_bit.
13104 * arm-tdep.c (arm_gdbarch_init): Likewise.
13105
debed3db
PA
131062017-04-25 Pedro Alves <palves@redhat.com>
13107
13108 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
13109 (BothAreRelocatable, memcopy, memmove): Don't define.
13110 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
13111 macros.
13112
b0b92aeb
PA
131132017-04-25 Pedro Alves <palves@redhat.com>
13114
13115 * common/common-defs.h: Include "common/poison.h".
13116 * common/function-view.h: (Not, Or, Requires): Move to traits.h
13117 and adjust.
13118 * common/poison.h: New file.
13119 * common/traits.h: Include <type_traits>.
13120 (Not, Or, Requires): New, moved from common/function-view.h.
13121
16c4d54a
PA
131222017-04-25 Pedro Alves <palves@redhat.com>
13123
13124 * breakpoint.h (struct breakpoint): In-class initialize all
13125 fields. Make boolean fields "bool".
13126 * breakpoint.c (init_raw_breakpoint_without_location): Remove
13127 memset call and initializations no longer necessary.
13128
b5c36682
PA
131292017-04-25 Pedro Alves <palves@redhat.com>
13130
13131 * btrace.c (pt_btrace_insn_flags): Change parameter type to
13132 reference.
13133 (pt_btrace_insn): New function.
13134 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
13135
5625a286
PA
131362017-04-25 Pedro Alves <palves@redhat.com>
13137
13138 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
13139 "base" field and inherit from "bp_location" instead. Add
13140 non-default ctor.
13141 (allocate_location_exception): Use new non-default ctor.
13142 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
13143 (init_bp_location): Convert to ...
13144 (bp_location::bp_location): ... this new ctor, and remove memset
13145 call.
13146 (base_breakpoint_allocate_location): Use the new non-default ctor.
13147 * breakpoint.h (bp_location): Now a class. Declare default and
13148 non-default ctors. In-class initialize all members.
13149 (init_bp_location): Remove declaration.
13150
23bcc18f
PA
131512017-04-25 Pedro Alves <palves@redhat.com>
13152
13153 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
13154 assignment operator.
13155
e1ba3053
YQ
131562017-04-24 Yao Qi <yao.qi@linaro.org>
13157
13158 * doublest.c (convert_doublest_to_floatformat): Call
13159 floatformat_totalsize_bytes.
13160
10f489e5
TT
131612017-04-22 Tom Tromey <tom@tromey.com>
13162
13163 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
13164 ui_out_emit_list.
13165 * stack.c (print_frame): Use ui_out_emit_list.
13166 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13167 ui_out_emit_list.
13168 * mi/mi-main.c (print_one_inferior)
13169 (mi_cmd_data_list_register_names)
13170 (mi_cmd_data_list_register_values, mi_cmd_list_features)
13171 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
13172 ui_out_emit_list.
13173 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
13174 (mi_output_solib_attribs): Use ui_out_emit_list,
13175 ui_out_emit_tuple.
13176 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
13177 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
13178 (mi_cmd_stack_list_args, list_args_or_locals): Use
13179 ui_out_emit_list.
13180 * disasm.c (do_assembly_only): Use ui_out_emit_list.
13181 * breakpoint.c (print_solib_event, output_thread_groups): Use
13182 ui_out_emit_list.
13183
0092b74d
TT
131842017-04-22 Tom Tromey <tom@tromey.com>
13185
13186 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
13187 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
13188 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
13189
a14a62dd
TT
131902017-04-22 Tom Tromey <tom@tromey.com>
13191
13192 * tracepoint.c (tvariables_info_1)
13193 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
13194
46b9c129
TT
131952017-04-22 Tom Tromey <tom@tromey.com>
13196
13197 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
13198 annotate_arg_emitter.
13199 * breakpoint.c (print_mention_watchpoint)
13200 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
13201 * annotate.h (struct annotate_arg_emitter): New.
13202
2e783024
TT
132032017-04-22 Tom Tromey <tom@tromey.com>
13204
13205 * record-btrace.c (record_btrace_insn_history)
13206 (record_btrace_insn_history_range, record_btrace_call_history)
13207 (record_btrace_call_history_range): Use ui_out_emit_tuple.
13208 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
13209 ui_out_emit_tuple.
13210 * stack.c (print_frame_info): Use ui_out_emit_tuple.
13211 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
13212 * skip.c (skip_info): Use ui_out_emit_tuple.
13213 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
13214 * progspace.c (print_program_space): Use ui_out_emit_tuple.
13215 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
13216 * osdata.c (info_osdata): Use ui_out_emit_tuple.
13217 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
13218 ui_out_emit_tuple.
13219 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
13220 (output_register, mi_cmd_data_read_memory)
13221 (mi_cmd_data_read_memory_bytes, mi_load_progress)
13222 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
13223 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
13224 Use ui_out_emit_tuple.
13225 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
13226 ui_out_emit_tuple.
13227 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13228 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
13229 * linux-thread-db.c (info_auto_load_libthread_db): Use
13230 ui_out_emit_tuple.
13231 * inferior.c (print_inferior): Use ui_out_emit_tuple.
13232 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
13233 * disasm.c (do_mixed_source_and_assembly_deprecated)
13234 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
13235 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
13236 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
13237 * breakpoint.c (print_one_breakpoint_location)
13238 (print_one_breakpoint): Use ui_out_emit_tuple.
13239 * auto-load.c (print_script, info_auto_load_cmd): Use
13240 ui_out_emit_tuple.
13241 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
13242
9be21bb4
SM
132432017-04-21 Simon Marchi <simon.marchi@ericsson.com>
13244
13245 * thread.c (print_thread_info_1): Remove dead code.
13246
0d4c07af
JK
132472017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13248
13249 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
13250 GDB_SELF_TEST.
13251 * arm-tdep.c (selftests::arm_record_test): Likewise.
13252
4daf993d
YQ
132532017-04-21 Yao Qi <yao.qi@linaro.org>
13254
13255 * regcache.c (regcache_restore): Remove argument 2. Replace
13256 argument 3 with regcache. Get register status from
13257 src->register_status and get register contents from
13258 register_buffer (src, regnum).
13259 (regcache_cpy): Update.
13260
a6c21d4a
PA
132612017-04-19 Pedro Alves <palves@redhat.com>
13262
13263 * gdbthread.h (thread): Add missing closing parenthesis in
13264 comment.
13265
3a3fd0fd
PA
132662017-04-19 Pedro Alves <palves@redhat.com>
13267
13268 * common/refcounted-object.h: New file.
13269 * gdbthread.h: Include "common/refcounted-object.h".
13270 (thread_info): Inherit from refcounted_object and add comments.
13271 (thread_info::incref, thread_info::decref)
13272 (thread_info::m_refcount): Delete.
13273 (thread_info::deletable): Use the refcounted_object::refcount()
13274 method.
13275 * inferior.c (current_inferior_): Add comment.
13276 (set_current_inferior): Increment/decrement refcounts.
13277 (prune_inferiors, remove_inferior_command): Skip inferiors marked
13278 not-deletable instead of comparing with the current inferior.
13279 (initialize_inferiors): Increment the initial inferior's refcount.
13280 * inferior.h (struct inferior): Forward declare.
13281 Include "common/refcounted-object.h".
13282 (current_inferior, set_current_inferior): Move declaration to
13283 before struct inferior's definition, and fix comment.
13284 (inferior): Inherit from refcounted_object. Add comments.
13285 * thread.c (switch_to_thread_no_regs): Reference the thread's
13286 inferior pointer directly instead of doing a ptid lookup.
13287 (switch_to_no_thread): New function.
13288 (switch_to_thread(thread_info *)): New function, factored out
13289 from ...
13290 (switch_to_thread(ptid_t)): ... this.
13291 (restore_current_thread): Delete.
13292 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
13293 fields, and add 'inf' field.
13294 (do_restore_current_thread_cleanup): Check whether old->inf is
13295 alive instead of looking up an inferior by ptid. Use
13296 switch_to_thread and switch_to_no_thread.
13297 (restore_current_thread_cleanup_dtor): Use old->inf directly
13298 instead of lookup up an inferior by id. Decref the inferior.
13299 Don't restore 'removable'.
13300 (make_cleanup_restore_current_thread): Same the inferior pointer
13301 in old, instead of the inferior number. Incref the inferior.
13302 Don't save/clear 'removable'.
13303
9bcb1f16
PA
133042017-04-19 Pedro Alves <palves@redhat.com>
13305
13306 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13307 unittests/scoped_restore-selftests.c.
13308 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
13309 * common/scoped_restore.h (scoped_restore_base): Make "class".
13310 (scoped_restore_base::release): New public method.
13311 (scoped_restore_base::scoped_restore_base): New protected ctor.
13312 (scoped_restore_base::m_saved_var): New protected field.
13313 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
13314 scoped_restore_base base class instead of m_saved_var directly.
13315 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
13316 (scoped_restore_tmpl::scoped_restore_tmpl(const
13317 scoped_restore_tmpl<T>&)): Likewise.
13318 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
13319 method.
13320 (scoped_restore_tmpl::saved_var): New method.
13321 (scoped_restore_tmpl::m_saved_var): Delete.
13322 * inferior.h (inferior::detaching): Now a bool.
13323 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
13324 cleanup.
13325 * unittests/scoped_restore-selftests.c: New file.
13326
26fcd539
PA
133272017-04-19 Pedro Alves <palves@redhat.com>
13328
13329 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
13330 Re-sort in alphabetic order.
13331
fdd243b0
PA
133322017-04-18 Pedro Alves <palves@redhat.com>
13333
13334 * xml-support.c (obstack_xml_printf): Delete.
13335 * xml-support.h (obstack_xml_printf): Delete.
13336
4895cde2
PA
133372017-04-18 Pedro Alves <palves@redhat.com>
13338
13339 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
13340 vdebug, verror, body_text, start_element, end_element, name,
13341 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
13342 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
13343 is_xinclude>: Make private and add m_ prefix.
13344 (gdb_xml_parser::body_text): New method, based on ...
13345 (gdb_xml_body_text): ... this. Adjust.
13346 (gdb_xml_parser::vdebug): New method, based on ...
13347 (gdb_xml_debug): ... this. Adjust.
13348 (gdb_xml_parser::verror): New method, based on ...
13349 (gdb_xml_error): ... this. Adjust.
13350 (gdb_xml_parser::start_element): New method, based on ...
13351 (gdb_xml_start_element): ... this. Adjust.
13352 (gdb_xml_start_element_wrapper): Defer to
13353 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
13354 (gdb_xml_parser::end_element): New method, based on ...
13355 (gdb_xml_end_element_wrapper): ... this. Adjust.
13356 (gdb_xml_parser::~gdb_xml_parser): Adjust.
13357 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
13358 (gdb_xml_parser::use_dtd): New method, based on ...
13359 (gdb_xml_use_dtd): ... this. Adjust.
13360 (gdb_xml_parser::parse): New method, based on ...
13361 (gdb_xml_parse): ... this. Adjust.
13362 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
13363 (xinclude_start_include): Adjust to call the parser's name method.
13364 (xml_xinclude_default, xml_xinclude_start_doctype)
13365 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
13366 method.
13367 (xml_process_xincludes): Adjust to call parser methods.
13368 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
13369 declarations.
13370
bd8a901f
PA
133712017-04-18 Pedro Alves <palves@redhat.com>
13372
13373 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
13374 gdb::optional<std::string>.
13375 * xml-support.c: Include <string>.
13376 (scope_level::scope_level(scope_level &&))
13377 (scope_level::~scope_level): Delete.
13378 (scope_level::body): Now a std::string.
13379 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
13380 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
13381 parameter.
13382 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
13383 (xinclude_parsing_data::output): Now a std::string reference.
13384 (xinclude_start_include): Adjust.
13385 (xml_xinclude_default): Adjust.
13386 (xml_process_xincludes): Add 'output' parameter, and return bool.
13387 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
13388 and return bool.
13389 * xml-tdesc.c: Include <unordered_map> and <string>.
13390 (tdesc_xml_cache): Delete.
13391 (tdesc_xml_cache_s): Delete.
13392 (xml_cache): Now an std::unordered_map.
13393 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
13394 (target_fetch_description_xml): Change return type to
13395 gdb::optional<std::string>, and adjust.
13396 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
13397 (target_fetch_description_xml): Change return type to
13398 gdb::optional<std::string>.
13399
d35d1958
PA
134002017-04-18 Pedro Alves <palves@redhat.com>
13401
13402 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13403 unittests/optional-selftests.c.
13404 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
13405 * unittests/optional-selftests.c: New file.
13406 * unittests/optional/assignment/1.cc: New file.
13407 * unittests/optional/assignment/2.cc: New file.
13408 * unittests/optional/assignment/3.cc: New file.
13409 * unittests/optional/assignment/4.cc: New file.
13410 * unittests/optional/assignment/5.cc: New file.
13411 * unittests/optional/assignment/6.cc: New file.
13412 * unittests/optional/assignment/7.cc: New file.
13413 * unittests/optional/cons/copy.cc: New file.
13414 * unittests/optional/cons/default.cc: New file.
13415 * unittests/optional/cons/move.cc: New file.
13416 * unittests/optional/cons/value.cc: New file.
13417 * unittests/optional/in_place.cc: New file.
13418 * unittests/optional/observers/1.cc: New file.
13419 * unittests/optional/observers/2.cc: New file.
13420
22796e97
PA
134212017-04-18 Pedro Alves <palves@redhat.com>
13422
13423 * common/gdb_optional.h: Include common/traits.h.
13424 (in_place_t): New type.
13425 (in_place): New constexpr variable.
13426 (optional::optional): Remove member initialization of
13427 m_instantiated.
13428 (optional::optional(in_place_t...)): New constructor.
13429 (optional::~optional): Use reset.
13430 (optional::optional(const optional&)): New.
13431 (optional::optional(const optional&&)): New.
13432 (optional::optional(T &)): New.
13433 (optional::optional(T &&)): New.
13434 (operator::operator=(const optional &)): New.
13435 (operator::operator=(optional &&)): New.
13436 (operator::operator= (const T &))
13437 (operator::operator= (T &&))
13438 (operator::emplace (Args &&... args)): Return a T&. Use reset.
13439 (operator::reset): New.
13440 (operator::m_instantiated):: Add in-class initializer.
13441 * common/traits.h: Include <type_traits>.
13442 (struct And): New types.
13443
a7fc9b61
PA
134442017-04-18 Pedro Alves <palves@redhat.com>
13445
13446 * xml-support.c: Include <vector>.
13447 (scope_level::scope_level(const gdb_xml_element *))
13448 (scope_level::scope_level(scope_level&&)): New.
13449 (scope_level::~scope_level): New.
13450 (scope_level_s): Delete.
13451 (gdb_xml_parser::scopes): Now a std::vector.
13452 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
13453 Use std::vector.
13454 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
13455 scope cleanup code.
13456 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
13457 of the scopes member. Use std::vector::emplace_back.
13458
010151c9
PA
134592017-04-18 Pedro Alves <palves@redhat.com>
13460
13461 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
13462 a bool.
13463 (gdb_xml_end_element): Change type of first parameter.
13464 (gdb_xml_cleanup): Rename to ...
13465 (gdb_xml_parser::~gdb_xml_parser): ... this.
13466 (gdb_xml_create_parser_and_cleanup): Delete with ...
13467 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
13468 to this new ctor.
13469 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
13470 using gdb_xml_create_parser_and_cleanup.
13471 (xinclude_parsing_data): Add ctor/dtor.
13472 (xml_xinclude_cleanup): Delete.
13473 (xml_process_xincludes): Create a local xinclude_parsing_data
13474 instead of heap-allocating one. Create a local gdb_xml_parser
13475 instead of heap-allocating one with
13476 gdb_xml_create_parser_and_cleanup.
13477
d56060f0
JB
134782017-04-18 John Baldwin <jhb@FreeBSD.org>
13479
13480 PR threads/20743
13481 * fbsd-nat.c (resume_one_thread_cb): Remove.
13482 (resume_all_threads_cb): Remove.
13483 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
13484 iterate_over_threads.
13485
305d16a9
JB
134862017-04-17 Joel Brobecker <brobecker@adacore.com>
13487
13488 * NEWS: Create a new section for the next release branch.
13489 Rename the section of the current branch, now that it has
13490 been cut.
13491
8bb57231
JB
134922017-04-17 Joel Brobecker <brobecker@adacore.com>
13493
13494 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
13495 * version.in: Bump version to 8.0.50.DATE-git.
13496
096c92dd
SDJ
134972017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
13498
13499 PR gdb/21385
13500 * windows-nat.c (windows_create_inferior): Declare 'allargs'
13501 independently of the host, and fix build breakage on Cygwin.
13502
0550c955
PA
135032017-04-13 Pedro Alves <palves@redhat.com>
13504
13505 * inferior.c (free_inferior): Convert to ...
13506 (inferior::~inferior): ... this dtor.
13507 (inferior::inferior): New ctor, factored out from ...
13508 (add_inferior_silent): ... here. Allocate the inferior with a new
13509 expression.
13510 (delete_inferior): Call delete instead of free_inferior.
13511 * inferior.h (gdb_environ, continuation): Forward declare.
13512 (inferior): Now a class. Add in-class initialization to all
13513 members. Make boolean fields bool, except 'detaching'.
13514 (inferior::inferior): New explicit ctor.
13515 (inferior::~inferior): New.
13516
e3d60dfc
PA
135172017-04-13 Pedro Alves <palves@redhat.com>
13518
13519 * inferior.c (init_inferior_list): Delete.
13520 * inferior.h (init_inferior_list): Delete.
13521
5fd69d0a
PA
135222017-04-13 Pedro Alves <palves@redhat.com>
13523
13524 PR threads/13217
13525 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
13526 (top level): Call it twice, with different thread sets.
13527
c6609450
PA
135282017-04-13 Pedro Alves <palves@redhat.com>
13529
13530 * thread.c: Include <algorithm>.
13531 (thread_array_cleanup): Delete.
13532 (scoped_inc_dec_ref): New class.
13533 (live_threads_count): New function.
13534 (set_thread_refcount): Delete.
13535 (tp_array_compar_ascending): Now a bool.
13536 (tp_array_compar): Convert to a std::sort comparison function.
13537 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
13538 and live_threads_count.
13539
2a00d7ce
PA
135402017-04-13 Pedro Alves <palves@redhat.com>
13541
13542 * infrun.c (follow_fork_inferior): Also switch the current
13543 inferior.
13544
441d7c93
PA
135452017-04-13 Pedro Alves <palves@redhat.com>
13546
13547 * breakpoint.c (watch_command_1): Save watchpoint-frame info
13548 before calling create_internal_breakpoint.
13549
808480f6
PA
135502017-04-13 Pedro Alves <palves@redhat.com>
13551
13552 * fork-child.c (execv_argv): New class.
13553 (breakup_args): Refactored as ...
13554 (execv_argv::init_for_no_shell): .. this method of execv_argv.
13555 Copy arguments to storage and replace separators with NULL
13556 terminators in place.
13557 (escape_bang_in_quoted_argument): Adjust to return bool.
13558 (execv_argv::execv_argv): New ctor.
13559 (execv_argv::init_for_shell): New method, factored out from
13560 fork_inferior. Don't strdup strings into the vector.
13561 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
13562 Remove free_vector_argv call.
13563
ad3d022a
YQ
135642017-04-13 Yao Qi <yao.qi@linaro.org>
13565
13566 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
13567 tdep->rx_psw_type.
13568
e6ddc3bf
YQ
135692017-04-13 Yao Qi <yao.qi@linaro.org>
13570
13571 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
13572 * rx-tdep.c (rx_gdbarch_init): Likewise.
13573
bfb8cf90
PA
135742017-04-13 Pedro Alves <palves@redhat.com>
13575
13576 * breakpoint.h (struct breakpoint): Reindent.
13577
f5336ca5
PA
135782017-04-13 Pedro Alves <palves@redhat.com>
13579
13580 * breakpoint.c (bp_location): Rename to ...
13581 (bp_locations): ... this. All references updated.
13582 (bp_location_count): Rename to ...
13583 (bp_locations_count): ... this. All references updated.
13584 (bp_location_placed_address_before_address_max): Rename to ...
13585 (bp_locations_placed_address_before_address_max): ... this. All
13586 references updated.
13587 (bp_location_shadow_len_after_address_max): Rename to ...
13588 (bp_locations_shadow_len_after_address_max): ... this. All
13589 references updated.
13590 (bp_location_compare_addrs): Rename to ...
13591 (bp_locations_compare_addrs): ... this. All references updated.
13592 (bp_location_compare):Rename to ...
13593 (bp_locations_compare): ... this. All references updated.
13594 (bp_location_target_extensions_update): Rename to ...
13595 (bp_locations_target_extensions_update): ... this. All references
13596 updated.
13597
be628ab8
SDJ
135982017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13599
13600 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
13601 * common/common.m4: Check headers 'termios.h', 'termio.h' and
13602 'sgtty.h'.
13603 * common/gdb_termios.h: New file, with parts of "terminal.h".
13604 * inflow.c: Include "gdb_termios.h".
13605 * ser-unix.c: Include "gdb_termios.h".
13606 * terminal.h: Move terminal-related defines to
13607 "common/gdb_termios.h".
13608
8e9e35b1
TT
136092017-04-12 Tom Tromey <tom@tromey.com>
13610
13611 * probe.c (parse_probes): Update.
13612 * location.h (delete_event_location): Don't declare.
13613 (event_location_deleter::operator()): Update.
13614 * location.c (event_location_deleter::operator()): Rename from
13615 delete_event_location.
13616 * linespec.h (linespec_result) <location>: Change type to
13617 event_location_up.
13618 * linespec.c (canonicalize_linespec, event_location_to_sals)
13619 (decode_objc): Update.
13620 (linespec_result): Don't call delete_event_location.
13621 * breakpoint.c (create_breakpoints_sal)
13622 (bkpt_probe_create_sals_from_location)
13623 (strace_marker_create_sals_from_location): Update.
13624
16e802b9
TT
136252017-04-12 Tom Tromey <tom@tromey.com>
13626
13627 * linespec.h (struct linespec_result): Add constructor and
13628 destructor.
13629 (init_linespec_result, destroy_linespec_result)
13630 (make_cleanup_destroy_linespec_result): Don't declare.
13631 * linespec.c (init_linespec_result): Remove.
13632 (linespec_result::~linespec_result): Rename from
13633 destroy_linespec_result. Update.
13634 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
13635 Remove.
13636 * breakpoint.c (create_breakpoint, break_range_command)
13637 (decode_location_default): Update.
13638 * ax-gdb.c (agent_command_1): Update.
13639
d28cd78a
TT
136402017-04-12 Tom Tromey <tom@tromey.com>
13641
13642 * remote.c (remote_download_tracepoint): Update.
13643 * python/py-breakpoint.c (bppy_get_location): Update.
13644 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
13645 (gdbscm_breakpoint_location): Update.
13646 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
13647 * breakpoint.h (struct breakpoint) <location, location_range_end>:
13648 Change type to event_location_up.
13649 * breakpoint.c (create_overlay_event_breakpoint)
13650 (create_longjmp_master_breakpoint)
13651 (create_std_terminate_master_breakpoint)
13652 (create_exception_master_breakpoint)
13653 (breakpoint_event_location_empty_p, print_breakpoint_location)
13654 (print_one_breakpoint_location, create_thread_event_breakpoint)
13655 (init_breakpoint_sal, create_breakpoint)
13656 (print_recreate_ranged_breakpoint, break_range_command)
13657 (init_ada_exception_breakpoint, say_where): Update.
13658 (base_breakpoint_dtor): Don't call delete_event_location.
13659 (bkpt_print_recreate, tracepoint_print_recreate)
13660 (dprintf_print_recreate, update_static_tracepoint)
13661 (breakpoint_re_set_default): Update.
13662
711799d5
TT
136632017-04-12 Tom Tromey <tom@tromey.com>
13664
13665 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
13666 type of "to_do". Update.
13667 (compute_stack_depth): Use std::vector.
13668
52d214d3
TT
136692017-04-12 Tom Tromey <tom@tromey.com>
13670
13671 * printcmd.c (find_instruction_backward): Use std::vector.
13672
4c404b8b
TT
136732017-04-12 Tom Tromey <tom@tromey.com>
13674
13675 * symfile.c (objfilep): Remove typedef.
13676 (reread_symbols): Use a std::vector.
13677
156d9eab
TT
136782017-04-12 Tom Tromey <tom@tromey.com>
13679
13680 * mi/mi-main.c (exec_direction_forward): Remove.
13681 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
13682 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
13683 scoped_restore.
13684 * guile/guile.c (guile_repl_command, guile_command)
13685 (gdbscm_execute_gdb_command): Use scoped_restore.
13686 * go-exp.y (go_parse): Use scoped_restore.
13687 * d-exp.y (d_parse): Use scoped_restore.
13688 * cli/cli-decode.c (cmd_func): Use scoped_restore.
13689 * c-exp.y (c_parse): Use scoped_restore.
13690
4d89769a
TT
136912017-04-12 Tom Tromey <tom@tromey.com>
13692
13693 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
13694 (mi_parse): Update return type.
13695 (mi_parse_free): Remove.
13696 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
13697 (mi_parse::~mi_parse): Rename from mi_parse_free.
13698 (mi_parse_cleanup): Remove.
13699 (mi_parse): Return a unique_ptr. Use new.
13700 * mi/mi-main.c (mi_execute_command): Update.
13701
4b217cc7
TT
137022017-04-12 Tom Tromey <tom@tromey.com>
13703
13704 * location.c (explicit_location_lex_one): Return a
13705 unique_xmalloc_ptr.
13706 (string_to_explicit_location): Update. Remove cleanups.
13707
59d3651b
TT
137082017-04-12 Tom Tromey <tom@tromey.com>
13709
13710 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
13711 (compare_value_and_voffset): Change type. Update.
13712 (compute_vtable_size): Change type of "offset_vec".
13713 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
13714 (gnuv3_get_typeid): Remove extraneous declaration.
13715
b24b0d6c
TT
137162017-04-12 Tom Tromey <tom@tromey.com>
13717
13718 * charset.h (wchar_iterator): Fix comment.
13719
80a3b8c5
TT
137202017-04-12 Tom Tromey <tom@tromey.com>
13721
13722 * charset.c (iconv_wrapper): New class.
13723 (cleanup_iconv): Remove.
13724 (convert_between_encodings): Use it.
13725
c83dd867
TT
137262017-04-12 Tom Tromey <tom@tromey.com>
13727
13728 * symfile.h (increment_reading_symtab): Update type.
13729 * symfile.c (decrement_reading_symtab): Remove.
13730 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
13731 * psymtab.c (psymtab_to_symtab): Update.
13732 * dwarf2read.c (dw2_instantiate_symtab): Update.
13733
0e8621a0
TT
137342017-04-12 Tom Tromey <tom@tromey.com>
13735
13736 * jit.c (struct jit_reader): Declare separately. Add constructor
13737 and destructor. Change type of "handle".
13738 (loaded_jit_reader): Define separately.
13739 (jit_reader_load): Update. New "new".
13740 (jit_reader_unload_command): Use "delete".
13741 * gdb-dlfcn.h (struct dlclose_deleter): New.
13742 (gdb_dlhandle_up): New typedef.
13743 (gdb_dlopen, gdb_dlsym): Update types.
13744 (gdb_dlclose): Remove.
13745 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
13746 (gdb_dlsym): Change type of "handle".
13747 (make_cleanup_dlclose): Remove.
13748 (dlclose_deleter::operator()): Rename from gdb_dlclose.
13749 * compile/compile-c-support.c (load_libcc): Update.
13750
67d89901
TT
137512017-04-12 Tom Tromey <tom@tromey.com>
13752
13753 * symtab.h (find_pcs_for_symtab_line): Change return type.
13754 * symtab.c (find_pcs_for_symtab_line): Change return type.
13755 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
13756 type of "vec". Update.
13757 (ltpy_get_pcs_for_line): Update.
13758 * linespec.c (decode_digits_ordinary): Update.
13759
93921405
TT
137602017-04-12 Tom Tromey <tom@tromey.com>
13761
13762 * tracepoint.c (actions_command): Update.
13763 * python/python.c (python_command, python_interactive_command):
13764 Update.
13765 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
13766 * guile/guile.c (guile_command): Update.
13767 * defs.h (read_command_lines, read_command_lines_1): Return
13768 command_line_up.
13769 (command_lines_deleter): New struct.
13770 (command_line_up): New typedef.
13771 * compile/compile.c (compile_code_command)
13772 (compile_print_command): Update.
13773 * cli/cli-script.h (get_command_line, copy_command_lines): Return
13774 command_line_up.
13775 (make_cleanup_free_command_lines): Remove.
13776 * cli/cli-script.c (get_command_line, read_command_lines_1)
13777 (copy_command_lines): Return command_line_up.
13778 (while_command, if_command, read_command_lines, define_command)
13779 (document_command): Update.
13780 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
13781 Remove.
13782 * breakpoint.h (breakpoint_set_commands): Change type of
13783 "commands".
13784 * breakpoint.c (breakpoint_set_commands): Change type of
13785 "commands". Update.
13786 (do_map_commands_command, update_dprintf_command_list)
13787 (create_tracepoint_from_upload): Update.
13788
ffc2605c
TT
137892017-04-12 Tom Tromey <tom@tromey.com>
13790
13791 * tracepoint.c (scope_info): Update.
13792 * spu-tdep.c (spu_catch_start): Update.
13793 * python/python.c (gdbpy_decode_line): Update.
13794 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
13795 * python/py-breakpoint.c (bppy_init): Update.
13796 * probe.c (parse_probes): Update.
13797 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
13798 * location.h (event_location_deleter): New struct.
13799 (event_location_up): New typedef.
13800 (new_linespec_location, new_address_location, new_probe_location)
13801 (new_explicit_location, copy_event_location)
13802 (string_to_event_location, string_to_event_location_basic)
13803 (string_to_explicit_location): Update return type.
13804 (make_cleanup_delete_event_location): Remove.
13805 * location.c (new_linespec_location, new_address_location)
13806 (new_probe_location, new_explicit_location, copy_event_location):
13807 Return event_location_up.
13808 (delete_event_location_cleanup)
13809 (make_cleanup_delete_event_location): Remove.
13810 (string_to_explicit_location, string_to_event_location_basic)
13811 (string_to_event_location): Return event_location_up.
13812 * linespec.c (canonicalize_linespec, event_location_to_sals)
13813 (decode_line_with_current_source)
13814 (decode_line_with_last_displayed, decode_objc): Update.
13815 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
13816 * completer.c (location_completer): Update.
13817 * cli/cli-cmds.c (edit_command, list_command): Update.
13818 * breakpoint.c (create_overlay_event_breakpoint)
13819 (create_longjmp_master_breakpoint)
13820 (create_std_terminate_master_breakpoint)
13821 (create_exception_master_breakpoint)
13822 (create_thread_event_breakpoint): Update.
13823 (init_breakpoint_sal): Update. Remove some dead code.
13824 (create_breakpoint_sal): Change type of "location". Update.
13825 (create_breakpoints_sal, create_breakpoint, break_command_1)
13826 (dprintf_command, break_range_command, until_break_command)
13827 (init_ada_exception_breakpoint)
13828 (strace_marker_create_sals_from_location)
13829 (update_static_tracepoint, trace_command, ftrace_command)
13830 (strace_command, create_tracepoint_from_upload): Update.
13831 * break-catch-throw.c (re_set_exception_catchpoint): Update.
13832 * ax-gdb.c (agent_command_1): Update.
13833
8f10c932
PA
138342017-04-12 Pedro Alves <palves@redhat.com>
13835
13836 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
13837 * configure.tgt: Handle i[34567]86-*-go32* and
13838 i[34567]86-*-msdosdjgpp*.
13839 * i386-tdep.c (i386_svr4_reg_to_regnum):
13840 Make extern.
13841 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
13842 i386-go32-tdep.c.
13843 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
13844 * i386-go32-tdep.c: New file.
13845 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
13846 declarations.
13847
0a31ccfb
SM
138482017-04-12 Simon Marchi <simon.marchi@ericsson.com>
13849
13850 * aix-thread.c (pd_status2str): Change return type to const char *.
13851
e9bb3fbb
PA
138522017-04-12 Pedro Alves <palves@redhat.com>
13853
13854 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
13855 calls to set_gdbarch_gnu_triplet_regexp.
13856
53375380
PA
138572017-04-12 Pedro Alves <palves@redhat.com>
13858
13859 PR gdb/21323
13860 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
13861 New enum value.
13862 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
13863 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
13864 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
13865 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
13866 * gdbarch.h, gdbarch.c: Regenerate.
13867 * aarch64-tdep.c (aarch64_gdbarch_init): Override
13868 gdbarch_wchar_bit and gdbarch_wchar_signed.
13869 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
13870 * arm-tdep.c (arm_gdbarch_init): Likewise.
13871 * avr-tdep.c (avr_gdbarch_init): Likewise.
13872 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
13873 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
13874 * i386-tdep.c (i386_go32_init_abi): Likewise.
13875 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
13876 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
13877 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
13878 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
13879 * sh-tdep.c (sh_gdbarch_init): Likewise.
13880 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
13881 * sparc64-tdep.c (sparc64_init_abi): Likewise.
13882 * windows-tdep.c (windows_init_abi): Likewise.
13883 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
13884
53e710ac
PA
138852017-04-12 Pedro Alves <palves@redhat.com>
13886
13887 PR c++/21323
13888 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
13889 cplus_primitive_type_char32_t>: New enum values.
13890 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
13891 and cplus_primitive_type_char32_t.
13892 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
13893 32, use the archtecture's built-in type for char16_t and char32_t,
13894 respectively. Otherwise, fallback to init_integer_type as before,
13895 but make the type unsigned, and issue a complaint.
13896 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
13897
ab0538b8
AH
138982017-04-12 Alan Hayward <alan.hayward@arm.com>
13899
5e0e0422 13900 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
13901 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
13902
5430098f
SDJ
139032017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13904
13905 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
13906 'const char *'.
13907
7c5ded6a
SDJ
139082017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13909
13910 * common/common-utils.c (free_vector_argv): New function.
13911 * common/common-utils.h: Include <vector>.
13912 (free_vector_argv): New prototype.
13913 * darwin-nat.c (darwin_create_inferior): Rewrite function
13914 prototype in order to constify "exec_file" and accept a
13915 "std::string" for "allargs".
13916 * fork-child.c: Include <vector>.
13917 (breakup_args): Rewrite function, using C++.
13918 (fork_inferior): Rewrite function header, constify "exec_file_arg"
13919 and accept "std::string" for "allargs". Update the code to
13920 calculate "argv" based on "allargs". Update calls to "exec_fun"
13921 and "execvp".
13922 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
13923 order to constify "exec_file" and accept a "std::string" for
13924 "allargs".
13925 * go32-nat.c (go32_create_inferior): Likewise.
13926 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
13927 * infcmd.c (run_command_1): Constify "exec_file". Use
13928 "std::string" for inferior arguments.
13929 * inferior.h (fork_inferior): Update prototype.
13930 * linux-nat.c (linux_nat_create_inferior): Rewrite function
13931 prototype in order to constify "exec_file" and accept a
13932 "std::string" for "allargs".
13933 * nto-procfs.c (procfs_create_inferior): Likewise.
13934 * procfs.c (procfs_create_inferior): Likewise.
13935 * remote-sim.c (gdbsim_create_inferior): Likewise.
13936 * remote.c (extended_remote_run): Update code to accept
13937 "std::string" as argument.
13938 (extended_remote_create_inferior): Rewrite function prototype in
13939 order to constify "exec_file" and accept a "std::string" for
13940 "allargs".
13941 * rs6000-nat.c (super_create_inferior): Likewise.
13942 (rs6000_create_inferior): Likewise.
13943 * target.h (struct target_ops) <to_create_inferior>: Likewise.
13944 * windows-nat.c (windows_create_inferior): Likewise.
13945
ae0eee42
PA
139462017-04-11 Pedro Alves <palves@redhat.com>
13947
13948 * thread.c: Fix whitespace throughout.
13949
a6acac06
PR
139502017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
13951
13952 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
13953
64403bd1
AH
139542017-04-11 Alan Hayward <alan.hayward@arm.com>
13955
13956 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
13957
a5bef50f
SDJ
139582017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
13959
13960 PR gdb/21364
13961 * osdata.c (info_osdata): Check if 'type' is an empty string
13962 instead of NULL.
13963
9295a5a9
PA
139642017-04-10 Pedro Alves <palves@redhat.com>
13965
13966 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
13967 (ptid_to_global_thread_id, in_thread_list)
13968 (do_captured_list_thread_ids, set_resumed, set_running)
13969 (set_executing, set_stop_requested, finish_thread_state)
13970 (validate_registers_access, can_access_registers_ptid)
13971 (print_thread_info_1, switch_to_thread)
13972 (do_restore_current_thread_cleanup)
13973 (make_cleanup_restore_current_thread, thread_command)
13974 (thread_name_command): Use operator== instead of ptid_equal.
13975
996812e3
PA
139762017-04-10 Pedro Alves <palves@redhat.com>
13977
13978 * thread.c (struct current_thread_cleanup) <next>: Delete field.
13979 (current_thread_cleanup_chain): Delete.
13980 (restore_current_thread_cleanup_dtor)
13981 (make_cleanup_restore_current_thread): Remove references to
13982 current_thread_cleanup_chain.
13983
845b344f
AH
139842017-04-10 Alan Hayward <alan.hayward@arm.com>
13985
13986 * msp430-tdep.c (msp430_pseudo_register_read): Never return
13987 REG_UNKNOWN.
13988
803bdfe4
YQ
139892017-04-10 Yao Qi <yao.qi@linaro.org>
13990
13991 PR gdb/19942
13992 * gdbthread.h (thread_info::deletable): New method.
13993 (thread_info::incref): New method.
13994 (thread_info::decref): New method.
13995 (thread_info::refcount): Move it to private.
13996 * infrun.c (save_stop_context): Call inc_refcount.
13997 (release_stop_context_cleanup): Likewise.
13998 * thread.c (set_thread_exited): New function.
13999 (init_thread_list): Delete "tp" only it is deletable, otherwise
14000 call set_thread_exited.
14001 (delete_thread_1): Call set_thread_exited.
14002 (current_thread_cleanup) <inferior_pid>: Remove.
14003 <thread>: New field.
14004 (restore_current_thread_ptid_changed): Removed.
14005 (do_restore_current_thread_cleanup): Adjust.
14006 (restore_current_thread_cleanup_dtor): Don't call
14007 find_thread_ptid.
14008 (set_thread_refcount): Use dec_refcount.
14009 (make_cleanup_restore_current_thread): Adjust.
14010 (thread_apply_all_command): Call inc_refcount.
14011 (_initialize_thread): Don't call
14012 observer_attach_thread_ptid_changed.
14013
8c25b497
YQ
140142017-04-10 Yao Qi <yao.qi@linaro.org>
14015
14016 * thread.c (delete_thread_1): Hoist code on marking thread as
14017 exited.
14018
8473b447
SM
140192017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
14020
14021 * windows-nat.c (windows_detach): Initialize ptid with
14022 minus_one_ptid.
14023
6670ec13
SM
140242017-04-07 Simon Marchi <simon.marchi@ericsson.com>
14025
14026 * unittests/ptid-selftests.c: Fix erroneous assert messages.
14027
ba2f91bb
AH
140282017-04-07 Alan Hayward <alan.hayward@arm.com>
14029
14030 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
14031 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
14032 (bfin_pseudo_register_write): Likewise
14033
436252de
SM
140342017-04-06 Simon Marchi <simon.marchi@ericsson.com>
14035
14036 * common/ptid.h (struct ptid): Change to...
14037 (class ptid_t): ... this.
14038 <ptid_t>: New constructors.
14039 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
14040 matches>: New methods.
14041 <make_null, make_minus_one>: New static methods.
14042 <pid>: Rename to...
14043 <m_pid>: ...this.
14044 <lwp>: Rename to...
14045 <m_lwp>: ...this.
14046 <tid>: Rename to...
14047 <m_tid>: ...this.
14048 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
14049 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
14050 as references, move comment to class ptid_t.
14051 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
14052 ptid_t static methods.
14053 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
14054 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
14055 Take ptid arguments as references, implement using ptid_t methods.
14056 * unittests/ptid-selftests.c: New file.
14057 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14058 unittests/ptid-selftests.c.
14059 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
14060
0dedf377
TP
140612017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
14062
14063 * python/python.c (python_run_simple_file): Cast mode literal to
14064 non-const char pointer as expected by PyFile_FromString.
14065
4e9868d4
SM
140662017-04-05 Simon Marchi <simon.marchi@ericsson.com>
14067
14068 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
14069 minus_one_ptid and null_ptid.
14070
9bf2a700
PA
140712017-04-05 Pedro Alves <palves@redhat.com>
14072
14073 * warning.m4 (build_warnings): Remove -Wno-write-strings.
14074 * configure: Regenerate.
14075
a121b7c1
PA
140762017-04-05 Pedro Alves <palves@redhat.com>
14077
14078 * ada-exp.y (yyerror): Constify.
14079 * ada-lang.c (bound_name, get_selections)
14080 (ada_variant_discrim_type)
14081 (ada_variant_discrim_name, ada_value_struct_elt)
14082 (ada_lookup_struct_elt_type, is_unchecked_variant)
14083 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
14084 (catch_ada_exception_command_split)
14085 (catch_ada_assert_command_split, catch_assert_command)
14086 (ada_op_name): Constify.
14087 * ada-lang.h (ada_yyerror, get_selections)
14088 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
14089 * arc-tdep.c (arc_print_frame_cache): Constify.
14090 * arm-tdep.c (arm_skip_stub): Constify.
14091 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
14092 (gen_aggregate_elt_ref): Constify.
14093 * bcache.c (print_bcache_statistics): Constify.
14094 * bcache.h (print_bcache_statistics): Constify.
14095 * break-catch-throw.c (catch_exception_command_1):
14096 * breakpoint.c (struct ep_type_description::description):
14097 Constify.
14098 (add_solib_catchpoint): Constify.
14099 (catch_fork_command_1): Add cast.
14100 (add_catch_command): Constify.
14101 * breakpoint.h (add_catch_command, add_solib_catchpoint):
14102 Constify.
14103 * bsd-uthread.c (bsd_uthread_state): Constify.
14104 * buildsym.c (patch_subfile_names): Constify.
14105 * buildsym.h (next_symbol_text_func, patch_subfile_names):
14106 Constify.
14107 * c-exp.y (yyerror): Constify.
14108 (token::oper): Constify.
14109 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
14110 * c-varobj.c (cplus_describe_child): Constify.
14111 * charset.c (find_charset_names): Add cast.
14112 (find_charset_names): Constify array and add const_cast.
14113 * cli/cli-cmds.c (complete_command, cd_command): Constify.
14114 (edit_command): Constify.
14115 * cli/cli-decode.c (lookup_cmd): Constify.
14116 * cli/cli-dump.c (dump_memory_command, dump_value_command):
14117 Constify.
14118 (struct dump_context): Constify.
14119 (add_dump_command, restore_command): Constify.
14120 * cli/cli-script.c (get_command_line): Constify.
14121 * cli/cli-script.h (get_command_line): Constify.
14122 * cli/cli-utils.c (check_for_argument): Constify.
14123 * cli/cli-utils.h (check_for_argument): Constify.
14124 * coff-pe-read.c (struct read_pe_section_data): Constify.
14125 * command.h (lookup_cmd): Constify.
14126 * common/print-utils.c (decimal2str): Constify.
14127 * completer.c (gdb_print_filename): Constify.
14128 * corefile.c (set_gnutarget): Constify.
14129 * cp-name-parser.y (yyerror): Constify.
14130 * cp-valprint.c (cp_print_class_member): Constify.
14131 * cris-tdep.c (cris_register_name, crisv32_register_name):
14132 Constify.
14133 * d-exp.y (yyerror): Constify.
14134 (struct token::oper): Constify.
14135 * d-lang.h (d_yyerror): Constify.
14136 * dbxread.c (struct header_file_location::name): Constify.
14137 (add_old_header_file, add_new_header_file, last_function_name)
14138 (dbx_next_symbol_text, add_bincl_to_list)
14139 (find_corresponding_bincl_psymtab, set_namestring)
14140 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
14141 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
14142 * defs.h (command_line_input, print_address_symbolic)
14143 (deprecated_readline_begin_hook): Constify.
14144 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
14145 Constify.
14146 * event-top.c (handle_line_of_input): Constify and add cast.
14147 * exceptions.c (catch_errors): Constify.
14148 * exceptions.h (catch_errors): Constify.
14149 * expprint.c (print_subexp_standard, op_string, op_name)
14150 (op_name_standard, dump_raw_expression, dump_raw_expression):
14151 * expression.h (op_name, op_string, dump_raw_expression):
14152 Constify.
14153 * f-exp.y (yyerror): Constify.
14154 (struct token::oper): Constify.
14155 (struct f77_boolean_val::name): Constify.
14156 * f-lang.c (f_word_break_characters): Constify.
14157 * f-lang.h (f_yyerror): Constify.
14158 * fork-child.c (fork_inferior): Add cast.
14159 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
14160 (new_variant): Constify.
14161 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
14162 * gdbarch.c: Regenerate.
14163 * gdbcore.h (set_gnutarget): Constify.
14164 * go-exp.y (yyerror): Constify.
14165 (token::oper): Constify.
14166 * go-lang.h (go_yyerror): Constify.
14167 * go32-nat.c (go32_sysinfo): Constify.
14168 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
14169 * guile/scm-cmd.c (cmdscm_function): Constify.
14170 * guile/scm-param.c (pascm_param_value): Constify.
14171 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
14172 (h8300sx_register_name): Constify.
14173 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
14174 Constify.
14175 * ia64-tdep.c (ia64_register_names): Constify.
14176 * infcmd.c (construct_inferior_arguments): Constify.
14177 (path_command, attach_post_wait): Constify.
14178 * language.c (show_range_command, show_case_command)
14179 (unk_lang_error): Constify.
14180 * language.h (language_defn::la_error)
14181 (language_defn::la_name_of_this): Constify.
14182 * linespec.c (decode_line_2): Constify.
14183 * linux-thread-db.c (thread_db_err_str): Constify.
14184 * lm32-tdep.c (lm32_register_name): Constify.
14185 * m2-exp.y (yyerror): Constify.
14186 * m2-lang.h (m2_yyerror): Constify.
14187 * m32r-tdep.c (m32r_register_names): Constify and make static.
14188 * m68hc11-tdep.c (m68hc11_register_names): Constify.
14189 * m88k-tdep.c (m88k_register_name): Constify.
14190 * macroexp.c (appendmem): Constify.
14191 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
14192 (upgrade_type, parse_external, parse_partial_symbols)
14193 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
14194 (new_symbol): Constify.
14195 * memattr.c (mem_info_command): Constify.
14196 * mep-tdep.c (register_name_from_keyword): Constify.
14197 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
14198 Constify.
14199 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
14200 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
14201 * mi/mi-main.c (captured_mi_execute_command): Constify and add
14202 cast.
14203 (mi_execute_async_cli_command): Constify.
14204 * mips-tdep.c (mips_register_name): Constify.
14205 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
14206 (am33_register_name, am33_2_register_name)
14207 * moxie-tdep.c (moxie_register_names): Constify.
14208 * nat/linux-osdata.c (osdata_type): Constify fields.
14209 * nto-tdep.c (nto_parse_redirection): Constify.
14210 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
14211 (lookup_child_selector): Constify.
14212 (objc_methcall::name): Constify.
14213 * objc-lang.h (lookup_objc_class, lookup_child_selector)
14214 (lookup_struct_typedef): Constify.
14215 * objfiles.c (pc_in_section): Constify.
14216 * objfiles.h (pc_in_section): Constify.
14217 * p-exp.y (struct token::oper): Constify.
14218 (yyerror): Constify.
14219 * p-lang.h (pascal_yyerror): Constify.
14220 * parser-defs.h (op_name_standard): Constify.
14221 (op_print::string): Constify.
14222 (exp_descriptor::op_name): Constify.
14223 * printcmd.c (print_address_symbolic): Constify.
14224 * psymtab.c (print_partial_symbols): Constify.
14225 * python/py-breakpoint.c (stop_func): Constify.
14226 (bppy_get_expression): Constify.
14227 * python/py-cmd.c (cmdpy_completer::name): Constify.
14228 (cmdpy_function): Constify.
14229 * python/py-event.c (evpy_add_attribute)
14230 (gdbpy_initialize_event_generic): Constify.
14231 * python/py-event.h (evpy_add_attribute)
14232 (gdbpy_initialize_event_generic): Constify.
14233 * python/py-evts.c (add_new_registry): Constify.
14234 * python/py-finishbreakpoint.c (outofscope_func): Constify.
14235 * python/py-framefilter.c (get_py_iter_from_func): Constify.
14236 * python/py-inferior.c (get_buffer): Add cast.
14237 * python/py-param.c (parm_constant::name): Constify.
14238 * python/py-unwind.c (fprint_frame_id): Constify.
14239 * python/python.c (gdbpy_parameter_value): Constify.
14240 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
14241 * remote.c (memory_packet_config::name): Constify.
14242 (show_packet_config_cmd, remote_write_bytes)
14243 (remote_buffer_add_string):
14244 * reverse.c (exec_reverse_once): Constify.
14245 * rs6000-tdep.c (variant::name, variant::description): Constify.
14246 * rust-exp.y (rustyyerror): Constify.
14247 * rust-lang.c (rust_op_name): Constify.
14248 * rust-lang.h (rustyyerror): Constify.
14249 * serial.h (serial_ops::name): Constify.
14250 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
14251 (sh_sh3e_register_name, sh_sh2e_register_name)
14252 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
14253 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
14254 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
14255 (sh_sh4al_dsp_register_name): Constify.
14256 * sh64-tdep.c (sh64_register_name): Constify.
14257 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
14258 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
14259 * stabsread.c (patch_block_stabs, read_type_number)
14260 (ref_map::stabs, ref_add, process_reference)
14261 (symbol_reference_defined, define_symbol, define_symbol)
14262 (error_type, read_type, read_member_functions, read_cpp_abbrev)
14263 (read_one_struct_field, read_struct_fields, read_baseclasses)
14264 (read_tilde_fields, read_struct_type, read_array_type)
14265 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
14266 (read_huge_number, read_range_type, read_args, common_block_start)
14267 (find_name_end): Constify.
14268 * stabsread.h (common_block_start, define_symbol)
14269 (process_one_symbol, symbol_reference_defined, ref_add):
14270 * symfile.c (get_section_index, add_symbol_file_command):
14271 * symfile.h (get_section_index): Constify.
14272 * target-descriptions.c (tdesc_type::name): Constify.
14273 (tdesc_free_type): Add cast.
14274 * target.c (find_default_run_target):
14275 (add_deprecated_target_alias, find_default_run_target)
14276 (target_announce_detach): Constify.
14277 (do_option): Constify.
14278 * target.h (add_deprecated_target_alias): Constify.
14279 * thread.c (print_thread_info_1): Constify.
14280 * top.c (deprecated_readline_begin_hook, command_line_input):
14281 Constify.
14282 (init_main): Add casts.
14283 * top.h (handle_line_of_input): Constify.
14284 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
14285 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
14286 (tfind_command): Rename to ...
14287 (tfind_command_1): ... this and constify.
14288 (tfind_command): New function.
14289 (tfind_end_command, tfind_start_command): Adjust.
14290 (encode_source_string): Constify.
14291 * tracepoint.h (encode_source_string): Constify.
14292 * tui/tui-data.c (tui_partial_win_by_name): Constify.
14293 * tui/tui-data.h (tui_partial_win_by_name): Constify.
14294 * tui/tui-source.c (tui_set_source_content_nil): Constify.
14295 * tui/tui-source.h (tui_set_source_content_nil): Constify.
14296 * tui/tui-win.c (parse_scrolling_args): Constify.
14297 * tui/tui-windata.c (tui_erase_data_content): Constify.
14298 * tui/tui-windata.h (tui_erase_data_content): Constify.
14299 * tui/tui-winsource.c (tui_erase_source_content): Constify.
14300 * tui/tui.c (tui_enable): Add cast.
14301 * utils.c (defaulted_query): Constify.
14302 (init_page_info): Add cast.
14303 (puts_debug, subset_compare): Constify.
14304 * utils.h (subset_compare): Constify.
14305 * varobj.c (varobj_format_string): Constify.
14306 * varobj.h (varobj_format_string): Constify.
14307 * vax-tdep.c (vax_register_name): Constify.
14308 * windows-nat.c (windows_detach): Constify.
14309 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
14310 * xml-support.c (gdb_xml_end_element): Constify.
14311 * xml-tdesc.c (tdesc_start_reg): Constify.
14312 * xstormy16-tdep.c (xstormy16_register_name): Constify.
14313 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
14314 * xtensa-tdep.h (xtensa_register_t::name): Constify.
14315
995816ba
PA
143162017-04-05 Pedro Alves <palves@redhat.com>
14317
14318 * proc-api.c (struct trans): Constify.
14319 (procfs_note): Constify.
14320 * proc-events.c (struct trans, syscall_table):
14321 * proc-flags.c (struct trans): Constify.
14322 * proc-utils.h (procfs_note): Constify.
14323 * proc-why.c (struct trans): Constify.
14324 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
14325 (procfs_detach): Constify.
14326 * sol-thread.c (struct string_map): Constify.
14327 (td_err_string, td_state_string): Constify.
14328
3e83a920
PA
143292017-04-05 Pedro Alves <palves@redhat.com>
14330
14331 * proc-api.c (procfs_filename): Don't initialize
14332 procfs_filename.
14333 (prepare_to_trace): Assume procfs_filename is non-NULL.
14334 (_initialize_proc_api): Give procfs_filename a default value here.
14335
63160a43
PA
143362017-04-05 Pedro Alves <palves@redhat.com>
14337
14338 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
14339 'cond_string' parameter.
14340 (extract_exception_regexp): Constify 'string' parameter.
14341 (catch_exception_command_1): Constify.
14342 * breakpoint.c (init_catchpoint)
14343 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
14344 parameter.
14345 (ep_parse_optional_if_clause, catch_fork_command_1)
14346 (catch_exec_command_1): Constify.
14347 * breakpoint.h (init_catchpoint): Constify 'cond_string'
14348 parameter.
14349 (ep_parse_optional_if_clause): Constify.
14350 * cli/cli-utils.c (remove_trailing_whitespace)
14351 (check_for_argument): Constify.
14352 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
14353 non-const overload.
14354 (check_for_argument): Likewise.
14355
9b2eba3d
PA
143562017-04-05 Pedro Alves <palves@redhat.com>
14357
14358 * event-top.c (command_line_handler): Add cast to execute_command
14359 call.
14360 * record-btrace.c (cmd_record_btrace_bts_start)
14361 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
14362 (cmd_record_btrace_start): Add cast to execute_command call.
14363 * record-full.c (record_full_goto_insn):
14364 * record.c (record_start, record_stop): Add cast to
14365 execute_command_to_string calls.
14366 (cmd_record_start): Add cast to execute_command calls.
14367
2adadf51
PA
143682017-04-05 Pedro Alves <palves@redhat.com>
14369
14370 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
14371 static inline function.
14372 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
14373 array and use gdb_PyArg_ParseTupleAndKeywords.
14374 * python/py-cmd.c (cmdpy_init): Likewise.
14375 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
14376 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
14377 (infpy_search_memory): Likewise.
14378 * python/py-objfile.c (objfpy_add_separate_debug_file)
14379 (gdbpy_lookup_objfile): Likewise.
14380 * python/py-symbol.c (gdbpy_lookup_symbol)
14381 (gdbpy_lookup_global_symbol): Likewise.
14382 * python/py-type.c (gdbpy_lookup_type): Likewise.
14383 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
14384 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
14385 Likewise.
14386
0d1f4ceb
PA
143872017-04-05 Pedro Alves <palves@redhat.com>
14388
14389 * python/python-internal.h (gdb_PyGetSetDef): New type.
14390 * python/py-block.c (block_object_getset)
14391 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
14392 * python/py-event.c (event_object_getset)
14393 (finish_breakpoint_object_getset): Likewise.
14394 * python/py-inferior.c (inferior_object_getset): Likewise.
14395 * python/py-infthread.c (thread_object_getset): Likewise.
14396 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
14397 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
14398 * python/py-objfile.c (objfile_getset): Likewise.
14399 * python/py-progspace.c (pspace_getset): Likewise.
14400 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
14401 Likewise.
14402 * python/py-record.c (recpy_record_getset): Likewise.
14403 * python/py-symbol.c (symbol_object_getset): Likewise.
14404 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
14405 Likewise.
14406 * python/py-type.c (type_object_getset, field_object_getset):
14407 Likewise.
14408 * python/py-value.c (value_object_getset): Likewise.
14409
4d759979
PA
144102017-04-05 Pedro Alves <palves@redhat.com>
14411
14412 * python/python-internal.h (gdb_PyObject_CallMethod)
14413 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
14414 New functions.
14415 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
14416 (PySys_GetObject, PySys_SetPath): New macros.
14417
fdf9e36f
PA
144182017-04-05 Pedro Alves <palves@redhat.com>
14419
14420 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
14421 info_osdata_command.
14422 * osdata.c (info_osdata_command): Rename to ...
14423 (info_osdata): ... this. Constify 'type' parameter, and remove
14424 the 'from_tty' parameter. Accept NULL TYPE.
14425 (info_osdata_command): New function.
14426 * osdata.h (info_osdata_command): Remove declaration.
14427 (info_osdata): New declaration.
14428
9f33b8b7
PA
144292017-04-05 Pedro Alves <palves@redhat.com>
14430
14431 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
14432 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
14433 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
14434 parameter.
14435 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
14436 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
14437 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
14438 parameter.
14439 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
14440 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
14441 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
14442 (mi_cmd_file_list_exec_source_files)
14443 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
14444 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
14445 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
14446 parameter.
14447 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
14448 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
14449 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
14450 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
14451 (mi_cmd_stack_info_frame): Constify 'command' parameter.
14452 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
14453 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
14454 'command' parameter.
14455 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
14456 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
14457 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
14458 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
14459 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
14460 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
14461 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
14462 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
14463 (mi_cmd_var_set_update_range): Constify 'command' parameter.
14464 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
14465 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
14466 parameter.
14467 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
14468 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
14469 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
14470 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
14471 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
14472 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
14473 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
14474 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
14475 (mi_cmd_data_list_changed_registers)
14476 (mi_cmd_data_write_register_values)
14477 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
14478 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
14479 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
14480 (mi_cmd_list_features, mi_cmd_list_target_features)
14481 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
14482 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
14483 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
14484 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
14485 (mi_cmd_trace_frame_collected): Constify 'command'
14486 parameter.
14487 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
14488 'command' parameter.
14489
67cb5b2d
PA
144902017-04-05 Pedro Alves <palves@redhat.com>
14491
14492 * ada-lang.c (ada_completer_word_break_characters): Now a const
14493 array.
14494 (ada_get_gdb_completer_word_break_characters): Constify.
14495 * completer.c (gdb_completer_command_word_break_characters)
14496 (gdb_completer_file_name_break_characters)
14497 (gdb_completer_quote_characters): Now const arrays.
14498 (get_gdb_completer_quote_characters): Constify.
14499 (set_rl_completer_word_break_characters): New function.
14500 (set_gdb_completion_word_break_characters)
14501 (complete_line_internal): Use it.
14502 * completer.h (get_gdb_completer_quote_characters): Constify.
14503 (set_rl_completer_word_break_characters): Declare.
14504 * f-lang.c (f_word_break_characters): Constify.
14505 * language.c (default_word_break_characters): Constify.
14506 * language.h (language_defn::la_word_break_characters): Constify.
14507 (default_word_break_characters): Constify.
14508 * top.c (init_main): Use set_rl_completer_word_break_characters.
14509
7a114964
PA
145102017-04-05 Pedro Alves <palves@redhat.com>
14511
14512 * aix-thread.c (aix_thread_pid_to_str)
14513 (aix_thread_extra_thread_info): Constify.
14514 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
14515 * bsd-uthread.c (bsd_uthread_extra_thread_info)
14516 (bsd_uthread_pid_to_str): Constify.
14517 * corelow.c (core_pid_to_str): Constify.
14518 * darwin-nat.c (darwin_pid_to_str): Constify.
14519 * fbsd-nat.c (fbsd_pid_to_str): Constify.
14520 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
14521 Constify.
14522 * gnu-nat.c (gnu_pid_to_str): Constify.
14523 * go32-nat.c (go32_pid_to_str): Constify.
14524 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
14525 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
14526 * inferior.c (inferior_pid_to_str): Constify.
14527 * linux-nat.c (linux_nat_pid_to_str): Constify.
14528 * linux-tdep.c (linux_core_pid_to_str): Constify.
14529 * linux-thread-db.c (thread_db_pid_to_str)
14530 (thread_db_extra_thread_info): Constify.
14531 * nto-tdep.c (nto_extra_thread_info): Constify.
14532 * nto-tdep.h (nto_extra_thread_info): Constify.
14533 * obsd-nat.c (obsd_pid_to_str): Constify.
14534 * procfs.c (procfs_pid_to_str): Constify.
14535 * ravenscar-thread.c (ravenscar_extra_thread_info)
14536 (ravenscar_pid_to_str): Constify.
14537 * remote-sim.c (gdbsim_pid_to_str): Constify.
14538 * remote.c (remote_threads_extra_info, remote_pid_to_str):
14539 Constify.
14540 * sol-thread.c (solaris_pid_to_str): Constify.
14541 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
14542 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
14543 * target.c (default_pid_to_str, target_pid_to_str)
14544 (normal_pid_to_str, default_pid_to_str): Constify.
14545 * target.h (target_ops::to_pid_to_str)
14546 (target_ops::to_extra_thread_info): Constify.
14547 (target_pid_to_str, normal_pid_to_str): Constify.
14548 * windows-nat.c (windows_pid_to_str): Constify.
14549 * gdbarch.sh (core_pid_to_str): Constify.
14550 * target-delegates.c: Regenerate.
14551 * gdbarch.h, gdbarch.c: Regenerate.
14552
69bbf465
PA
145532017-04-05 Pedro Alves <palves@redhat.com>
14554
14555 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
14556 the memory of the temporary warning_pre_print override.
14557 * utils.c (warning_pre_print): Constify.
14558 * utils.h (warning_pre_print): Constify.
14559
be47f9e8
PA
145602017-04-05 Pedro Alves <palves@redhat.com>
14561
14562 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
14563 (shell_command): New function.
14564 (make_command): Use std::string.
14565 (init_cli_cmds): Register shell_command instead of shell_escape.
14566
bde6261a
PA
145672017-04-05 Pedro Alves <palves@redhat.com>
14568
14569 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
14570 * tracepoint.c (default_collect): Don't initialize.
14571
b38ef47f
PA
145722017-04-05 Pedro Alves <palves@redhat.com>
14573
14574 * macroexp.c (macro_buffer::shared): Now a bool.
14575 (init_buffer): Update.
14576 (init_shared_buffer): Constify 'addr' parameter.
14577 (substitute_args, expand, macro_expand, macro_expand_next): Remove
14578 casts.
14579
f995bbe8
PA
145802017-04-05 Pedro Alves <palves@redhat.com>
14581
14582 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
14583 * disasm.c (set_disassembler_options): Constify local.
14584 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
14585
4a596fe2
SDJ
145862017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
14587
14588 PR gdb/21352
14589 * tracefile.c (tsave_command): Fix argument parsing for '-r'
14590 option.
14591
2cad08ea
YQ
145922017-04-05 Yao Qi <yao.qi@linaro.org>
14593
14594 * frame.c (frame_unwind_register_unsigned): Call
14595 frame_unwind_register_value.
14596
55a98976
YQ
145972017-04-05 Yao Qi <yao.qi@linaro.org>
14598
14599 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
14600 Use gdb_test_multiple, and don't match anchor.
14601
4ac40124
PA
146022017-04-05 Pedro Alves <palves@redhat.com>
14603
14604 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
14605 (Write After Approval): Remove Simon Marchi.
14606
c053b654
PA
146072017-04-05 Pedro Alves <palves@redhat.com>
14608
14609 * common/gdb_optional.h (optional::optional): Make constexpr and
14610 initialize m_dummy.
14611
4c7bf4f9
JB
146122017-04-04 John Baldwin <jhb@FreeBSD.org>
14613
14614 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14615 (amd64fbsd_jmp_buf_reg_offset): Remove.
14616 (amd64fbsd_supply_uthread): Remove function.
14617 (amd64fbsd_collect_uthread): Remove function.
14618 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
14619 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
14620 (x86_64-*-freebsd*): Remove bsd-uthread.o.
14621 (fbsd-nat.c): Update comment.
14622 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14623 (i386fbsd_jmp_buf_reg_offset): Remove.
14624 (i386fbsd_supply_uthread): Remove function.
14625 (i386fbsd_collect_uthread): Remove function.
14626 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
14627
1e1a8bef
JB
146282017-04-04 John Baldwin <jhb@FreeBSD.org>
14629
14630 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
14631 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
14632 * NEWS: Mention that support for FreeBSD/alpha was removed.
14633 * alpha-fbsd-tdep.c: Delete file.
14634 * config/alpha/fbsd.mh: Delete file.
14635 * configure.host: Delete alpha*-*-freebsd* and
14636 alpha*-*-kfreebsd*-gnu.
14637 * configure.tgt: Delete alpha*-*-freebsd* and
14638 alpha*-*-kfreebsd*-gnu.
14639
49907934
JB
146402017-04-04 John Baldwin <jhb@FreeBSD.org>
14641
14642 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
14643 amd64bsd_store_inferior_registers): Use ptid from regcache.
14644
6f77053d
PA
146452017-04-04 Pedro Alves <palves@redhat.com>
14646
14647 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
14648 data fields, make them private and add "m_" prefixes.
14649 (lnp_state_machine::lnp_state_machine): New ctor.
14650 (record_line, check_line_address, handle_set_discriminator)
14651 (handle_set_address, handle_advance_pc, handle_special_opcode)
14652 (handle_advance_line, handle_set_file, handle_negate_stmt)
14653 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
14654 (end_sequence, advance_line): New methods.
14655 (m_gdbarch, m_record_lines_p): New fields.
14656 (lnp_reader_state): Delete.
14657 (dwarf_record_line): Rename to ...
14658 (lnp_state_machine::record_line): ... adjust.
14659 (init_lnp_state_machine): Delete.
14660 (lnp_state_machine::lnp_state_machine): New.
14661 (check_line_address): Rename to ...
14662 (lnp_state_machine::check_line_address): This.
14663 (dwarf_decode_lines_1): Remove reference to "reader_state".
14664 Adjust lnp_state_machine having a non-default ctor. Use bool.
14665 State machine internal state manipulation moved to
14666 lnp_state_machine methods.
14667
9c541725
PA
146682017-04-04 Pedro Alves <palves@redhat.com>
14669
14670 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14671 unittests/offset-type-selftests.c.
14672 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
14673 * common/offset-type.h: New file.
14674 * common/preprocessor.h: New file.
14675 * common/traits.h: New file.
14676 * common/valid-expr.h: New file.
14677 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
14678 sect_offset and cu_offset strong typedefs throughout.
14679 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
14680 typedefs throughout.
14681 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
14682 sect_offset and cu_offset strong typedefs throughout.
14683 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
14684 typedefs throughout.
14685 * gdbtypes.h: Include "common/offset-type.h".
14686 (cu_offset): Now an offset type (strong typedef) instead of a
14687 struct.
14688 (sect_offset): Likewise.
14689 (union call_site_parameter_u): Rename "param_offset" field to
14690 "param_cu_off".
14691 * unittests/offset-type-selftests.c: New file.
14692
ecfb656c
PA
146932017-04-04 Pedro Alves <palves@redhat.com>
14694
14695 * common/underlying.h: New file.
14696 * dwarf2read.c: Include "common/gdb_optional.h" and
14697 "common/underlying.h".
14698 (dir_index, file_name_index): New types.
14699 (file_entry): Use them.
14700 (file_entry::include): Use to_underlying.
14701 (line_header::add_file_name): Use dir_index.
14702 (read_formatted_entries): Use gdb::optional. Read form before
14703 writting to file_entry.
14704 (dwarf_decode_line_header): Use dir_index.
14705 (lnp_state_machine::current_file): Use to_underlying.
14706 (lnp_state_machine::file): Change type to file_name_index.
14707 (dwarf_record_line): Use to_underlying.
14708 (init_lnp_state_machine): Use file_name_index.
14709 (dwarf_decode_lines_1): Use dir_index and file_name_index.
14710
d194f1fe
PA
147112017-04-04 Pedro Alves <palves@redhat.com>
14712
14713 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
14714 operator bool, has_value and get methods.
14715
fff8551c
PA
147162017-04-04 Pedro Alves <palves@redhat.com>
14717
14718 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
14719 fields.
14720 (line_header): Initialize all data fields. Change type of
14721 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
14722 Change type of include_dirs to std::vector<const char *>. Remove
14723 num_include_dirs, include_dirs_size. Change type of file_names to
14724 std::vector<file_entry>. Remove num_file_names, file_names_size.
14725 (line_header::line_header): New.
14726 (line_header::add_include_dir, line_header::add_file_name): New
14727 methods.
14728 (line_header::include_dir_at): Remove NULL check.
14729 (line_header::file_name_at): Add const overload.
14730 (line_header_up): New unique_ptr typedef.
14731 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
14732 std::vector. Remove free_line_header call.
14733 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
14734 free_line_header call.
14735 (free_cu_line_header): Delete.
14736 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
14737 (setup_type_unit_groups): Use line_header_up instead of cleanups.
14738 Adjust to use std::vector.
14739 (free_line_header): Delete.
14740 (free_line_header_voidp): Use delete.
14741 (add_include_dir): Replace with ...
14742 (line_header::add_include_dir): ... this method. Use std::vector.
14743 (add_file_name): Replace with ...
14744 (line_header::add_file_name): ... this method. Use std::vector.
14745 (add_include_dir_stub): Delete.
14746 (read_formatted_entries): Remove memset.
14747 (dwarf_decode_line_header): Return a line_header_up instead of a
14748 raw pointer. Remove cleanup handling. Pass lambdas to
14749 read_formatted_entries. Adjust to use line_header methods.
14750 (dwarf_decode_lines_1): Adjust to use line_header methods.
14751 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
14752 use std::vector.
14753
d62a8ae2
SM
147542017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
14755
14756 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
14757 instead of struct ptid.
14758
db3a1dc7
AH
147592017-05-04 Alan Hayward <alan.hayward@arm.com>
14760
14761 * frame.c (get_frame_register_bytes): Unwind using value.
14762 (put_frame_register_bytes): Likewise.
14763
b1b45502
IB
147642017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
14765
14766 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
14767 aggregate-like.
14768
ec13808e
JK
147692017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
14770
14771 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
14772
12316564
YQ
147732017-03-29 Yao Qi <yao.qi@linaro.org>
14774
14775 * gdbthread.h (struct thread_info): Declare constructor and
14776 destructor. Add some in-class member initializers.
14777 * thread.c (free_thread): Remove.
14778 (init_thread_list): Call delete instead of free_thread.
14779 (new_thread): Call thread_info constructor.
14780 (thread_info::thread_info): New function.
14781 (thread_info::~thread_info): New function.
14782 (delete_thread_1): Call delete instead of free_thread.
14783 (make_cleanup_restore_current_thread): Move tp and frame to
14784 inner block.
14785
fe5f7374
AK
147862017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14787
14788 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
14789 (arc_skip_prologue): Likewise.
14790 (arc_make_frame_cache): Likewise.
14791 (arc_pv_get_operand): New function.
14792 (arc_is_in_prologue): Likewise.
14793 (arc_analyze_prologue): Likewise.
14794 (arc_print_frame_cache): Likewise.
14795 (MAX_PROLOGUE_LENGTH): New constant.
14796
eea78757
AK
147972017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14798
14799 * configure.tgt: Add arc-insn.o.
14800 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
14801 (dump_arc_instruction_command): New function.
14802 (arc_fprintf_disasm): Likewise.
14803 (arc_disassemble_info): Likewise.
14804 (arc_insn_get_operand_value): Likewise.
14805 (arc_insn_get_operand_value_signed): Likewise.
14806 (arc_insn_get_memory_base_reg): Likewise.
14807 (arc_insn_get_memory_offset): Likewise.
14808 (arc_insn_get_branch_target): Likewise.
14809 (arc_insn_dump): Likewise.
14810 (arc_insn_get_linear_next_pc): Likewise.
14811 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
14812 (arc_disassemble_info): Likewise.
14813 (arc_insn_get_branch_target): Likewise.
14814 (arc_insn_get_linear_next_pc): Likewise.
14815 * NEWS: Mention new "maint print arc arc-instruction".
14816
3be78afd
AK
148172017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14818
14819 * arc-tdep (maintenance_print_arc_list): New variable.
14820 (maintenance_print_arc_command): New function.
14821
296ec4fa
AK
148222017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14823
14824 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
14825 Add "limm" and "reserved".
14826 (arc_cannot_fetch_register, arc_cannot_store_register): Add
14827 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
14828 * arc-tdep.h (arc_regnum): Likewise.
14829
f74f865e
MF
148302017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14831
14832 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14833 for THREADPTR register.
14834 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
14835 register.
14836 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
14837 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
14838 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
14839
0d0bf81a
MF
148402017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14841
14842 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
14843 registers above gdbarch_num_regs (gdbarch) as privileged in
14844 call0 ABI.
14845
0ce4291e
MF
148462017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14847
14848 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14849 for a single specified register or for all registers in
14850 a0_base..a0_base + C0_NREGS range.
14851 (supply_gregset_reg): Call regcache_raw_supply for a single
14852 specified register or for all registers in a0_base..a0_base +
14853 C0_NREGS range.
14854
c56054f9
MF
148552017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14856
14857 * arch/xtensa.h (C0_NREGS): Add definition.
14858 * xtensa-tdep.c (C0_NREGS): Remove definition.
14859
a4398628
MF
148602017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14861
14862 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
14863 Drop xtensa_default_isa initialization.
14864 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
14865
8c43009f
PA
148662017-03-27 Pedro Alves <palves@redhat.com>
14867
14868 * dwarf2read.c (file_entry) <dir_index>: Add comment.
14869 (file_entry::include_dir): New method.
14870 (line_header::include_dir_at, line_header::file_name_at): New
14871 methods.
14872 (setup_type_unit_groups, setup_type_unit_groups)
14873 (psymtab_include_file_name): Simplify using the new methods.
14874 (lnp_state_machine) <the_line_header>: New field.
14875 <file>: Add comment.
14876 (lnp_state_machine::current_file): New method.
14877 (dwarf_record_line): Simplify using the new methods.
14878 (init_lnp_state_machine): Initialize the "the_line_header" field.
14879 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
14880 Simplify using the new methods.
14881
a7e80b9e
PA
148822017-03-27 Pedro Alves <palves@redhat.com>
14883
14884 * cp-name-parser.y (make_empty): Delete.
14885 (demangler_special, nested_name, ptr_operator, array_indicator)
14886 (direct_declarator, declarator_1): Use fill_comp instead of
14887 make_empty.
14888
21047726
PA
148892017-03-27 Pedro Alves <palves@redhat.com>
14890
14891 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
14892 to ATTRIBUTE_PRINTF.
14893 * solib-target.c (library_list_start_list): Print "string" not
14894 "version".
14895 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
14896 gdb_xml_error call.
14897
d721ba37
PA
148982017-03-27 Pedro Alves <palves@redhat.com>
14899
14900 * dwarf2read.c (struct file_and_directory): New.
14901 (dwarf2_get_dwz_file): Adjust to use std::string.
14902 (dw2_get_file_names_reader): Adjust to use file_and_directory.
14903 (find_file_and_directory): Adjust to return a file_and_directory
14904 object.
14905 (read_file_scope): Adjust to use file_and_directory. Remove
14906 make_cleanup/do_cleanups calls.
14907 (open_and_init_dwp_file): Adjust to use std::string. Remove
14908 make_cleanup/do_cleanups calls.
14909 * python/python.c (do_start_initialization): Adjust to ldirname
14910 returning a std::string.
14911 * utils.c (ldirname): Now returns a std::string.
14912 * utils.h (ldirname): Change return type to std::string.
14913 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
14914 returning a std::string.
14915 * xml-tdesc.c (file_read_description_xml): Likewise.
14916
ed771251
AH
149172017-03-24 Alan Hayward <alan.hayward@arm.com>
14918
14919 * regcache.c (regcache_debug_print_register): New function.
14920 * regcache.h (regcache_debug_print_register): New declaration.
14921 * target.c (debug_print_register): Remove.
14922 (target_fetch_registers): Call regcache_debug_print_register.
14923 (target_store_registers): Likewise.
14924
568c1b9f
PB
149252017-03-24 Pádraig Brady <pbrady@fb.com>
14926
14927 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
14928 reference beyond the 'lh->include_dirs' array before accessing to
14929 it.
14930 (psymtab_include_file_name): Likewise.
14931 (dwarf_decode_lines_1): Likewise.
14932 (dwarf_decode_lines): Likewise.
14933 (file_file_name): Likewise.
14934
3e00d44f
SM
149352017-03-23 Simon Marchi <simon.marchi@ericsson.com>
14936
14937 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
14938 inferior_ptid.
14939 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14940 ps_lsetfpregs): Likewise.
14941 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
14942 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14943 ps_lsetfpregs): Likewise.
14944 * target.c (target_fetch_registers, target_store_registers):
14945 Remove asserts.
14946
077ae656
AH
149472017-03-23 Alan Hayward <alan.hayward@arm.com>
14948
14949 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
14950
1e2b521d
YQ
149512017-03-23 Yao Qi <yao.qi@linaro.org>
14952
14953 * aarch64-tdep.c (aarch64_process_record_test): Declare.
14954 (_initialize_aarch64_tdep): Register it.
14955 (aarch64_record_load_store): Handle PRFM instruction.
14956 (aarch64_process_record_test): New function.
14957
33877125
YQ
149582017-03-23 Yao Qi <yao.qi@linaro.org>
14959
14960 * aarch64-tdep.c (aarch64_record_load_store): Fix code
14961 indentation.
14962
a0eef940
YQ
149632017-03-23 Yao Qi <yao.qi@linaro.org>
14964
14965 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
14966
3f2a3564
PR
149672017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14968
14969 python/python.c (do_start_initialization): Fix memory leak.
14970
b67aeab0
SM
149712017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14972
14973 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
14974 using get_ptrace_pid.
14975 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
14976 inferior_ptid.
14977 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
14978 inferior_ptid instead of pid.
14979
ffdbe864
YQ
149802017-03-22 Yao Qi <yao.qi@linaro.org>
14981
14982 * aarch64-tdep.c: Wrap locally used classes in anonymous
14983 namespace.
14984 * arm-tdep.c: Likewise.
14985 * linespec.c: Likewise.
14986 * ui-out.c: Likewise.
14987
9d736fbf
JG
149882017-03-22 Jonah Graham <jonah@kichwacoders.com>
14989
14990 PR gdb/19637
14991 * python/lib/gdb/printer/bound_registers.py: Import sys.
14992
3de88e9a
SM
149932017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14994
14995 * windows-nat.c (do_windows_fetch_inferior_registers): Add
14996 windows_thread_info parameter and use it instead of
14997 current_thread.
14998 (windows_fetch_inferior_registers): Don't set current_thread,
14999 pass the thread to do_windows_fetch_inferior_registers. Use
15000 ptid from regcache instead of inferior_ptid.
15001 (do_windows_store_inferior_registers): Add windows_thread_info
15002 parameter and use it instead of current_thread.
15003 (windows_store_inferior_registers): Don't set current_thread,
15004 pass the thread to do_windows_store_inferior_registers. Use
15005 ptid from regcache instead of inferior_ptid.
15006
0e7b8f61
SM
150072017-03-21 Simon Marchi <simon.marchi@ericsson.com>
15008
15009 * ser-mingw.c (ser_windows_raw): Remove reference to
15010 struct serial::current_timeout.
15011
5badf10a
IR
150122017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
15013
15014 PR tdep/20928
15015 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
15016 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
15017 (sparc64_fsr_type): Fix %fsr decoding.
15018
cee59b3f
TW
150192017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
15020
15021 * python/py-record-btrace.c (btpy_insn_data): Change return type
15022 for Python 2.
15023
639a9038
SM
150242017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15025
15026 * spu-linux-nat.c (spu_fetch_inferior_registers,
15027 spu_store_inferior_registers): Use ptid from regcache, set and
15028 restore inferior_ptid.
15029 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
15030 Likewise.
15031
bcc0c096
SM
150322017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
15033
15034 * i386-linux-nat.c (fetch_register, store_register,
15035 i386_linux_fetch_inferior_registers,
15036 i386_linux_store_inferior_registers): Use ptid from regcache.
15037 * ia64-linux-nat.c (ia64_linux_fetch_register,
15038 ia64_linux_store_register): Likewise.
15039 * inf-ptrace.c (inf_ptrace_fetch_register,
15040 inf_ptrace_store_register): Likewise.
15041 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
15042 m32r_linux_store_inferior_registers): Likewise.
15043 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
15044 m68kbsd_store_inferior_registers): Likewise.
15045 * m68k-linux-nat.c (fetch_register, store_register,
15046 m68k_linux_fetch_inferior_registers,
15047 m68k_linux_store_inferior_registers): Likewise.
15048 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
15049 m88kbsd_store_inferior_registers): Likewise.
15050 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
15051 mips_fbsd_store_inferior_registers): Likewise.
15052 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
15053 mips64_linux_regsets_store_registers): Likewise.
15054 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
15055 mipsnbsd_store_inferior_registers): Likewise.
15056 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
15057 mips64obsd_store_inferior_registers): Likewise.
15058 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
15059 Likewise.
15060 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
15061 ppcfbsd_store_inferior_registers): Likewise.
15062 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
15063 ppc_linux_store_inferior_registers): Likewise.
15064 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
15065 ppcnbsd_store_inferior_registers): Likewise.
15066 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
15067 ppcobsd_store_registers): Likewise.
15068 * procfs.c (procfs_fetch_registers, procfs_store_registers):
15069 Likewise.
15070 * ravenscar-thread.c (ravenscar_fetch_registers,
15071 ravenscar_store_registers, ravenscar_prepare_to_store):
15072 Likewise.
15073 * record-btrace.c (record_btrace_fetch_registers,
15074 record_btrace_store_registers, record_btrace_prepare_to_store):
15075 Likewise.
15076 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
15077 Lookup inferior using ptid from regcache, instead of
15078 current_inferior.
15079 * remote.c (remote_fetch_registers, remote_store_registers): Use
15080 ptid from regcache.
15081 * rs6000-nat.c (fetch_register, store_register): Likewise.
15082 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
15083 s390_linux_store_inferior_registers): Likewise.
15084 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
15085 shnbsd_store_inferior_registers): Likewise.
15086 * sol-thread.c (sol_thread_fetch_registers,
15087 sol_thread_store_registers): Likewise.
15088 * sparc-nat.c (sparc_fetch_inferior_registers,
15089 sparc_store_inferior_registers): Likewise.
15090 * tilegx-linux-nat.c (fetch_inferior_registers,
15091 store_inferior_registers): Likewise.
15092 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
15093 vaxbsd_store_inferior_registers): Likewise.
15094 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
15095 store_xtregs): Likewise.
15096
c0f55cc6
AV
150972017-03-20 Artemiy Volkov <artemiyv@acm.org>
15098
15099 PR gdb/14441
15100 * NEWS: Mention support for rvalue references in GDB and python.
15101 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
15102 supports both lvalue and rvalue references.
15103
15c0a2a9
AV
151042017-03-20 Artemiy Volkov <artemiyv@acm.org>
15105
15106 PR gdb/14441
15107 * gdbtypes.c (rank_one_type): Implement overloading
15108 resolution rules regarding rvalue references.
15109
aa006118
AV
151102017-03-20 Artemiy Volkov <artemiyv@acm.org>
15111
15112 PR gdb/14441
15113 * aarch64-tdep.c (aarch64_type_align)
15114 (aarch64_extract_return_value, aarch64_store_return_value): Change
15115 lvalue reference type checks to general reference type checks.
15116 * amd64-tdep.c (amd64_classify): Likewise.
15117 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
15118 Likewise.
15119 * arm-tdep.c (arm_type_align, arm_extract_return_value)
15120 (arm_store_return_value): Likewise.
15121 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
15122 * c-typeprint.c (c_print_type): Likewise.
15123 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
15124 (cplus_number_of_children, cplus_describe_child): Likewise.
15125 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
15126 * completer.c (expression_completer): Likewise.
15127 * cp-support.c (make_symbol_overload_list_adl_namespace):
15128 Likewise.
15129 * darwin-nat-info.c (info_mach_region_command): Likewise.
15130 * dwarf2loc.c (entry_data_value_coerce_ref)
15131 (value_of_dwarf_reg_entry): Likewise.
15132 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
15133 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
15134 Likewise.
15135 * findvar.c (extract_typed_address, store_typed_address):
15136 Likewise.
15137 * gdbtypes.c (rank_one_type): Likewise.
15138 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
15139 * infcall.c (value_arg_coerce): Likewise.
15140 * language.c (pointer_type): Likewise.
15141 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
15142 Likewise.
15143 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
15144 * mn10300-tdep.c (mn10300_type_align): Likewise.
15145 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
15146 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
15147 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
15148 Likewise.
15149 * printcmd.c (print_formatted, x_command): Likewise.
15150 * python/py-type.c (typy_get_composite, typy_template_argument):
15151 Likewise.
15152 * python/py-value.c (valpy_referenced_value)
15153 (valpy_get_dynamic_type, value_has_field): Likewise.
15154 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
15155 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
15156 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
15157 * spu-tdep.c (spu_scalar_value_p): Likewise.
15158 * symtab.c (lookup_symbol_aux): Likewise.
15159 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
15160 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
15161 Likewise.
15162 * valops.c (value_cast_pointers, value_cast)
15163 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
15164 (value_struct_elt, value_struct_elt_bitpos)
15165 (value_find_oload_method_list, find_overload_match)
15166 (value_rtti_indirect_type): Likewise.
15167 * valprint.c (val_print_scalar_type_p, generic_val_print):
15168 Likewise.
15169 * value.c (value_actual_type, value_as_address, unpack_long)
15170 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
15171 (coerce_ref): Likewise.
15172 * varobj.c (varobj_get_value_type): Likewise.
15173
3fcf899d
AV
151742017-03-20 Artemiy Volkov <artemiyv@acm.org>
15175
15176 PR gdb/14441
15177 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
15178 table of constants.
15179 * python/lib/gdb/command/explore.py: Support exploring values
15180 of rvalue reference types.
15181 * python/lib/gdb/types.py: Implement get_basic_type() for
15182 rvalue reference types.
15183 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
15184 constant.
15185 * python/py-value.c (valpy_getitem): Add an rvalue reference
15186 check.
15187 (valpy_reference_value): Add new parameter "refcode".
15188 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
15189 New wrappers for valpy_reference_value().
15190 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15191 (gdbpy_invoke_xmethod): Likewise.
15192
4297a3f0
AV
151932017-03-20 Artemiy Volkov <artemiyv@acm.org>
15194
15195 PR gdb/14441
15196 * dwarf2read.c (process_die, read_type_die_1): Handle the
15197 DW_TAG_rvalue_reference_type DIE.
15198 (read_tag_reference_type): Add new parameter "refcode".
15199
e1cb3213
AV
152002017-03-20 Artemiy Volkov <artemiyv@acm.org>
15201
15202 PR gdb/14441
15203 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
15204 (c_type_print_modifier, c_type_print_varspec_suffix)
15205 (c_type_print_base): Support printing rvalue reference types.
15206 * c-valprint.c (c_val_print, c_value_print): Support printing
15207 rvalue reference values.
15208
e4347c89
AV
152092017-03-20 Artemiy Volkov <artemiyv@acm.org>
15210
15211 PR gdb/14441
15212 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
15213 typename.
15214 * cp-support.c (replace_typedefs): Handle
15215 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
15216 * python/py-type.c (typy_lookup_type): Likewise.
15217
53cc15f5
AV
152182017-03-20 Artemiy Volkov <artemiyv@acm.org>
15219
15220 PR gdb/14441
15221 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
15222 * parse.c (insert_type): Change assert statement.
15223 (follow_types): Handle rvalue reference types.
15224 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
15225 constant.
15226
a65cfae5
AV
152272017-03-20 Artemiy Volkov <artemiyv@acm.org>
15228
15229 PR gdb/14441
15230 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
15231 value_ref() interface.
15232 * c-valprint.c (c_value_print): Likewise.
15233 * infcall.c (value_arg_coerce): Likewise.
15234 * python/py-value.c (valpy_reference_value): Likewise.
15235 * valops.c (value_cast, value_reinterpret_cast)
15236 (value_dynamic_cast, typecmp): Likewise.
15237 (value_ref): Parameterize by kind of return value reference type.
15238 * value.h (value_ref): Add new parameter "refcode".
15239
3b224330
AV
152402017-03-20 Artemiy Volkov <artemiyv@acm.org>
15241
15242 PR gdb/14441
15243 * dwarf2read.c (read_tag_reference_type): Use
15244 lookup_lvalue_reference_type() instead of lookup_reference_type().
15245 * eval.c (evaluate_subexp_standard): Likewise.
15246 * f-exp.y: Likewise.
15247 * gdbtypes.c (make_reference_type, lookup_reference_type):
15248 Generalize with rvalue reference types.
15249 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
15250 convenience wrappers for lookup_reference_type().
15251 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
15252 reference kind parameter.
15253 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
15254 wrappers for lookup_reference_type().
15255 * guile/scm-type.c (gdbscm_type_reference): Use
15256 lookup_lvalue_reference_type() instead of lookup_reference_type().
15257 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
15258 * parse.c (follow_types): Likewise.
15259 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
15260 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
15261 Likewise.
15262 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
15263 (gdbpy_invoke_xmethod): Likewise.
15264 * stabsread.c: Provide extra argument to make_reference_type()
15265 call.
15266 * valops.c (value_ref, value_rtti_indirect_type): Use
15267 lookup_lvalue_reference_type() instead of lookup_reference_type().
15268
f9aeb8d4
AV
152692017-03-20 Artemiy Volkov <artemiyv@acm.org>
15270
15271 PR gdb/14441
15272 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
15273 (TYPE_IS_REFERENCE): New macro.
15274 (struct type): Add rvalue_reference_type field.
15275 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
15276
51457a05
MAL
152772017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15278
15279 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
15280 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
15281 New function definition.
15282 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
15283 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
15284 New function declaration.
15285 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
15286 * mi/mi-interp.h: New file.
15287 * solib.c (info_sharedlibrary_command): Replace for loop with
15288 ALL_SO_LIBS macro
15289 * solib.h (update_solib_list): New function declaration.
15290 (so_list_head): Move macro.
15291 * solist.h (ALL_SO_LIBS): New macro.
15292
e696b3ad
MAL
152932017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
15294
15295 * infcmd.c (post_create_inferior): Remove unused argument in
15296 call to solib_add.
15297 * remote.c (remote_start_remote): Likewise.
15298 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
15299 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
15300 (enable_break): Likewise.
15301 * solib.c (update_solib_list): Remove unused target argument
15302 and its documentation.
15303 (solib_add): Remove unused target argument. Remove unused
15304 argument in call to update_solib_list.
15305 (info_sharedlibrary_command): Remove unused argument in call
15306 to update_solib_list.
15307 (sharedlibrary_command): Remove unused argument in call to
15308 solib_add.
15309 (handle_solib_event): Likewise.
15310 (reload_shared_libraries): Likewise.
15311 * solib.h (solib_add): Remove unused target argument.
15312
dcb84eda
AA
153132017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
15314
15315 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
15316 (s390_displaced_step_fixup): Cover relative branches with the
15317 default fixup handling. This fixes lack of support for some
15318 relative branch instructions.
15319
d9cb6cdc
SM
153202017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15321
15322 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
15323 ptid from regcache.
15324
1afaf9f4
SM
153252017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15326
15327 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
15328 i386_darwin_store_inferior_registers): Use ptid from regcache.
15329
aac12e24
SM
153302017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15331
15332 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
15333 i386bsd_store_inferior_registers): Use ptid from regcache.
15334
bbe1eef1
SM
153352017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15336
15337 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
15338 hppaobsd_store_registers): Use ptid from regcache.
15339
10799020
SM
153402017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15341
15342 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
15343 hppanbsd_store_registers): Use ptid from regcache.
15344
00204cf7
SM
153452017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15346
15347 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
15348 from regcache. Use get_ptrace_pid.
15349
11a33714
SM
153502017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15351
15352 * corelow.c (get_core_register_section): Use ptid from regcache,
15353 update doc.
15354
317cd492
SM
153552017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15356
15357 * bsd-uthread.c (bsd_uthread_fetch_registers,
15358 bsd_uthread_store_registers): Use ptid from regcache, set and
15359 restore inferior_ptid.
15360
9ac8a7c2
SM
153612017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15362
15363 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
15364 fetch_fp_regs, store_register, store_regs, store_fp_register,
15365 store_fp_regs): Use ptid from regcache.
15366
4ac4bb6a
SM
153672017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
15368
15369 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
15370 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
15371 store_vfp_regs): Use ptid from regcache.
15372
9bcbdca8
PA
153732017-03-17 Pedro Alves <palves@redhat.com>
15374
15375 PR remote/21188
15376 * ser-base.c (ser_base_wait_for): Add comment.
15377 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
15378 version.
15379 * ser-unix.c (hardwire_raw): Remove reference to
15380 scb->current_timeout.
15381 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
15382 (hardwire_ops): Install ser_base_readchar instead of
15383 hardwire_readchar.
15384 * serial.h (struct serial) <current_timeout, timeout_remaining>:
15385 Remove fields.
15386
7503099f
JG
153872017-03-17 Jonah Graham <jonah@kichwacoders.com>
15388
15389 PR gdb/19637
15390 * python/lib/gdb/printer/bound_registers.py: Add support for
15391 Python 3.
15392
7942e96e
AA
153932017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
15394
15395 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
15396 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
15397 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
15398 byte_offset to subobj_byte_offset. Fix the handling of
15399 DWARF_VALUE_STACK on big-endian targets when coming via an
15400 implicit pointer.
15401 (dwarf2_evaluate_loc_desc): Adjust call to
15402 dwarf2_evaluate_loc_desc_full.
15403 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
15404 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
15405
ba14f379
YQ
154062017-03-16 Yao Qi <yao.qi@linaro.org>
15407
15408 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
15409 and REVSH instructions.
15410
b121eeb9
YQ
154112017-03-16 Yao Qi <yao.qi@linaro.org>
15412
15413 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
15414 (arm_record_test): Declare.
15415 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
15416 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
15417 align with the manual.
15418 (thumb_record_misc): Adjust the code order to align with the
15419 manual.
15420 (thumb2_record_decode_insn_handler): Fix instruction matching.
15421 (instruction_reader_thumb): New class.
15422 (arm_record_test): New function.
15423
728a7913
YQ
154242017-03-16 Yao Qi <yao.qi@linaro.org>
15425
15426 * arm-tdep.c (abstract_memory_reader): New class.
15427 (instruction_reader): New class.
15428 (extract_arm_insn): Add argument 'reader'. Callers updated.
15429 (decode_insn): Likewise.
15430
34b43320
DE
154312017-03-16 Doug Evans <dje@google.com>
15432
a7c0469f
DE
15433 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
15434 member. Change type of TYPE member to SCM. All uses updated.
15435 (lsscm_make_lazy_string_smob): Add assert.
15436 (lsscm_make_lazy_string): Flag bad length values.
15437 (lsscm_elt_type): New function.
15438 (gdbscm_lazy_string_to_value): Rewrite to use
15439 lsscm_safe_lazy_string_to_value.
15440 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
15441 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
15442 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
15443 in incoming type.
15444 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15445 * guile/scm-type.c (tyscm_scm_to_type): New function.
15446
154472017-03-15 Doug Evans <dje@google.com>
15448
34b43320
DE
15449 PR python/17728, python/18439, python/18779
15450 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
15451 member. Change type of TYPE member to PyObject *. All uses updated.
15452 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
15453 (gdbpy_create_lazy_string_object): Flag bad length values.
15454 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
15455 Handle typedefs in incoming type.
15456 (stpy_lazy_string_elt_type): New function.
15457 (gdbpy_extract_lazy_string): Call it.
15458 * python/py-value.c (valpy_lazy_string): Flag bad length values.
15459 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
15460 typedefs in incoming type.
15461
a3a5fecc
DE
154622017-03-16 Doug Evans <dje@google.com>
15463
15464 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15465 * guile/scm-type.c (tyscm_scm_to_type): New function.
15466
28f1c605
JW
154672017-03-16 Jiong Wang <jiong.wang@arm.com>
15468
15469 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
15470 "ULONGEST" for "skip".
15471
87c336f6
AA
154722017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15473
15474 PR gdb/21220
15475 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
15476 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
15477 (inf_ptrace_peek_poke): ...here. New function. Now also loop
15478 over ptrace peek/poke until end of buffer or error.
15479
cf81cf60
SM
154802017-03-14 Simon Marchi <simon.marchi@ericsson.com>
15481
15482 * parse.c (length_of_subexp): Make static.
15483 * parser-defs.h (length_of_subexp): Remove.
15484
a379284a
AA
154852017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15486
15487 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
15488 as well.
15489
8a6200ba
PA
154902017-03-14 Pedro Alves <palves@redhat.com>
15491
15492 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
15493 (main): Use std::unique_ptr. Remove calls to
15494 cp_demangled_name_parse_free.
15495
f79ec206
SM
154962017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15497
15498 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
15499 alphabsd_store_inferior_registers): Use regcache->ptid instead
15500 of inferior_ptid.
15501
edb5fb00
SM
155022017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15503
15504 * aix-thread.c (aix_thread_fetch_registers,
15505 aix_thread_store_registers): Use regcache->ptid instead of
15506 inferior_ptid.
15507
55119686
SM
155082017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15509
15510 * aarch64-linux-nat.c (fetch_gregs_from_thread,
15511 store_gregs_to_thread, fetch_fpregs_from_thread,
15512 store_fpregs_to_thread): Use regcache->ptid instead of
15513 inferior_ptid.
15514
6a06fbb7
SM
155152017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15516
15517 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
15518 amd64_linux_fetch_inferior_registers): Use regcache->ptid
15519 instead of inferior_ptid.
15520
c6386875
SM
155212017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15522
15523 * target.c (target_fetch_registers, target_store_registers): Add
15524 assert.
15525
ddaaf0fb
SM
155262017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15527
15528 * regcache.h (regcache_get_ptid): New function.
15529 * regcache.c (regcache_get_ptid): New function.
15530
b9da89d1 155312017-03-13 Mark Wielaard <mark@klomp.org>
15532
15533 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
15534
5f4d1085
KS
155352017-03-10 Keith Seitz <keiths@redhat.com>
15536
15537 PR c++/8218
15538 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
15539
c65d6b55
PA
155402017-03-08 Pedro Alves <palves@redhat.com>
15541
15542 PR gdb/18360
15543 * infrun.c (start_step_over, do_target_resume, resume)
15544 (restart_threads): Assert we're not resuming a thread that is
15545 meant to be stopped.
15546 (infrun_thread_stop_requested_callback): Delete.
15547 (infrun_thread_stop_requested): If the thread is internally
15548 stopped, queue a pending stop event and clear the thread's
15549 inline-frame state.
15550 (handle_stop_requested): New function.
15551 (handle_syscall_event, handle_inferior_event_1): Use
15552 handle_stop_requested.
15553 (handle_stop_requested): New function.
15554 (handle_signal_stop): Set the thread's stop_signal here instead of
15555 at caller.
15556 (finish_step_over): Clear step over info unconditionally.
15557 (handle_signal_stop): If the user had interrupted the event
15558 thread, consider the stop a random signal.
15559 (handle_signal_stop) <signal arrived while stepping over
15560 breakpoint>: Don't restart threads here.
15561 (stop_waiting): Don't clear step-over info here.
15562
15c22686
PA
155632017-03-08 Pedro Alves <palves@redhat.com>
15564
15565 PR 21206
15566 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
15567 goes to argument 2, not 1.
15568
6e5d74e7
PA
155692017-03-08 Pedro Alves <palves@redhat.com>
15570
15571 PR cli/21218
15572 * top.c (gdb_readline_wrapper): Avoid passing NULL to
15573 display_gdb_prompt.
15574 (command_line_input): Add comment.
15575
9753a2f6
PA
155762017-03-08 Pedro Alves <palves@redhat.com>
15577
15578 PR tui/21216
15579 * tui/tui-file.c (tui_file::write): New.
15580 * tui/tui-file.h (tui_file): Override "write".
15581 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
15582 factored out from ...
15583 (tui_puts): ... here.
15584 (tui_putc): Use them.
15585 (tui_write): New function.
15586 * tui/tui-io.h (tui_write): Declare.
15587
1672e0d9
SDJ
155882017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
15589
15590 * Makefile.in (SFILES): Replace "environ.c" with
15591 "common/environ.c".
15592 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
15593 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
15594 to...
15595 * common/environ.c: ... here.
15596 * environ.h: Moved to...
15597 * common/environ.h: ... here.
15598
f7bb4e3a
PB
155992017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15600
15601 * gdbarch.sh (pstring_ptr): New static function.
15602 (gdbarch_disassembler_options): Use it.
15603 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
15604 not valid_disassembler_option->name.
15605 * gdbarch.c: Regenerate.
15606
e45ced6c
PB
156072017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15608
15609 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
15610
5f6fd321
PA
156112017-03-07 Pedro Alves <palves@redhat.com>
15612
15613 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
15614
6dbb839a 156152017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
15616
15617 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
15618 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
15619 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 15620 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 15621
d274ecf4
SM
156222017-03-06 Simon Marchi <simon.marchi@ericsson.com>
15623
15624 * xtensa-linux-nat.c (fetch_gregs): Remove const.
15625
df97be55
SM
156262017-03-03 Simon Marchi <simon.marchi@ericsson.com>
15627
15628 * remote.c (remote_add_target_side_commands): Use range-based
15629 for loop.
15630
7d45f3df
YQ
156312017-03-03 Yao Qi <yao.qi@linaro.org>
15632
15633 PR gdb/21165
15634 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
15635 value is lazy.
15636 * valprint.c (common_val_print): Likewise.
15637
65b48a81
PB
156382017-02-28 Peter Bergner <bergner@vnet.ibm.com>
15639
15640 * NEWS: Mention new set/show disassembler-options commands.
15641 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
15642 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
15643 (prospective_options): New static variable.
15644 (gdb_disassembler::gdb_disassembler): Initialize
15645 m_di.disassembler_options.
15646 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
15647 (get_disassembler_options): New function.
15648 (set_disassembler_options): Likewise.
15649 (set_disassembler_options_sfunc): Likewise.
15650 (show_disassembler_options_sfunc): Likewise.
15651 (disassembler_options_completer): Likewise.
15652 (_initialize_disasm): Likewise.
15653 * disasm.h (get_disassembler_options): New prototype.
15654 (set_disassembler_options): Likewise.
15655 * gdbarch.sh (gdbarch_disassembler_options): New variable.
15656 (gdbarch_verify_disassembler_options): Likewise.
15657 * gdbarch.c: Regenerate.
15658 * gdbarch.h: Likewise.
15659 * arm-tdep.c (num_disassembly_options): Delete.
15660 (set_disassembly_style): Likewise.
15661 (arm_disassembler_options): New static variable.
15662 (set_disassembly_style_sfunc): Convert short style name into long
15663 option name. Call set_disassembler_options.
15664 (show_disassembly_style_sfunc): New function.
15665 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
15666 set_gdbarch_verify_disassembler_options.
15667 (_initialize_arm_tdep): Delete regnames variable and update callers.
15668 (arm_disassembler_options): Initialize.
15669 (disasm_options): New variable.
15670 (num_disassembly_options): Rename from this...
15671 (num_disassembly_styles): ...to this. Compute by scanning through
15672 disasm_options.
15673 (valid_disassembly_styles): Initialize using disasm_options.
15674 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
15675 set_arm_regname_option.
15676 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
15677 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
15678 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
15679 set_gdbarch_verify_disassembler_options.
15680 * s390-tdep.c (s390_disassembler_options): New static variable.
15681 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
15682 set_gdbarch_verify_disassembler_options.
15683
d538e36d
SM
156842017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15685
15686 * remote.c (remote_add_target_side_condition): Remove "struct"
15687 keyword from range-based for loop.
15688
83621223
SM
156892017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15690
15691 * remote.c (remote_add_target_side_condition): Use range-based
15692 for loop. Update comment.
15693
2123df0e
YQ
156942017-02-27 Yao Qi <yao.qi@linaro.org>
15695
15696 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
15697
8e368124
AH
156982017-02-26 Alan Hayward <alan.hayward@arm.com>
15699
15700 * regcache.c (regcache_raw_update): New function.
15701 (regcache_raw_read): Move code to regcache_raw_update.
15702 * regcache.h (regcache_raw_update): New declaration.
15703 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
15704
a49dd8dd
JK
157052017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
15706
15707 * dwarf2read.c (create_debug_type_hash_table): Initialize
15708 header.signature and header.type_offset_in_tu.
15709
34e4bae9
PA
157102017-02-24 Pedro Alves <palves@redhat.com>
15711
15712 * symtab.c (make_file_symbol_completion_list_1): Use
15713 add_symtab_completions.
15714
b0e4b369
AH
157152017-02-24 Alan Hayward <alan.hayward@arm.com>
15716
15717 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
15718
975c21ab
AH
157192017-02-24 Alan Hayward <alan.hayward@arm.com>
15720
15721 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
15722 I386_MAX_REGISTER_SIZE.
15723 (i386_pseudo_register_write): Likewise.
15724 (i386_process_record): Likewise.
15725 * i387-tdep.c (i387_supply_xsave): Likewise.
15726 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
15727 (store_register): Likewise.
15728
14bc53a8
PA
157292017-02-23 Pedro Alves <palves@redhat.com>
15730
15731 * ada-lang.c: Include "common/function-view.h".
15732 (ada_iterate_over_symbols): Adjust to use function_view as
15733 callback type.
15734 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
15735 (ada_make_symbol_completion_list): Use a lambda.
15736 (ada_exc_search_name_matches): Delete.
15737 (name_matches_regex): New.
15738 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
15739 * compile/compile-c-support.c: Include "common/function-view.h".
15740 (print_one_macro): Change prototype to accept a ui_file pointer.
15741 (write_macro_definitions): Use a lambda.
15742 * dwarf2read.c: Include "common/function-view.h".
15743 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
15744 (dw2_expand_symtabs_matching): Adjust to use function_view as
15745 callback type.
15746 * language.h: Include "common/function-view.h".
15747 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
15748 function_view as callback type.
15749 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
15750 * linespec.c: Include "common/function-view.h".
15751 (collect_info::add_symbol): New method.
15752 (struct symbol_and_data_callback, iterate_inline_only, struct
15753 symbol_matcher_data, iterate_name_matcher): Delete.
15754 (iterate_over_all_matching_symtabs): Adjust to use function_view
15755 as callback type and lambdas.
15756 (iterate_over_file_blocks): Adjust to use function_view as
15757 callback type.
15758 (decode_compound_collector): Now a class with private fields.
15759 (decode_compound_collector::release_symbols): New method.
15760 (collect_one_symbol): Rename to...
15761 (decode_compound_collector::operator()): ... this and adjust.
15762 (lookup_prefix_sym): decode_compound_collector construction bits
15763 move to decode_compound_collector ctor. Pass the
15764 decode_compound_collector object directly as callback. Remove
15765 cleanups and use decode_compound_collector::release_symbols
15766 instead.
15767 (symtab_collector): Now a class with private fields.
15768 (symtab_collector::release_symtabs): New method.
15769 (add_symtabs_to_list): Rename to...
15770 (symtab_collector::operator()): ... this and adjust.
15771 (collect_symtabs_from_filename): symtab_collector construction
15772 bits move to symtab_collector ctor. Pass the symtab_collector
15773 object directly as callback. Remove cleanups and use
15774 symtab_collector::release_symtabs instead.
15775 (collect_symbols): Delete.
15776 (add_matching_symbols_to_info): Use lambdas.
15777 * macrocmd.c (print_macro_callback): Delete.
15778 (info_macro_command): Use a lambda.
15779 (info_macros_command): Pass print_macro_definition as callable
15780 directly.
15781 (print_one_macro): Remove 'ignore' parameter.
15782 (macro_list_command): Adjust.
15783 * macrotab.c (macro_for_each_data::fn): Now a function_view.
15784 (macro_for_each_data::user_data): Delete field.
15785 (foreach_macro): Adjust to call the function_view.
15786 (macro_for_each): Adjust to use function_view as callback type.
15787 (foreach_macro_in_scope): Adjust to call the function_view.
15788 (macro_for_each_in_scope): Adjust to use function_view as callback
15789 type.
15790 * macrotab.h: Include "common/function-view.h".
15791 (macro_callback_fn): Declare a prototype instead of a pointer.
15792 Remove "user_data" parameter.
15793 (macro_for_each, macro_for_each_in_scope): Adjust to use
15794 function_view as callback type.
15795 * psymtab.c (partial_map_expand_apply)
15796 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
15797 Adjust to use function_view as callback type and to return bool.
15798 (psym_expand_symtabs_matching): Adjust to use function_view as
15799 callback types.
15800 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
15801 to use function_view as callback type and to return bool.
15802 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
15803 callback types.
15804 * symfile.c (expand_symtabs_matching): Adjust to use function_view
15805 as callback types.
15806 * symfile.h: Include "common/function-view.h".
15807 (expand_symtabs_file_matcher_ftype)
15808 (expand_symtabs_symbol_matcher_ftype)
15809 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
15810 return bool.
15811 (quick_symbol_functions::map_symtabs_matching_filename)
15812 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
15813 function_view as callback type and return bool.
15814 (expand_symtabs_matching): Adjust to use function_view as callback
15815 type.
15816 (maintenance_expand_name_matcher)
15817 (maintenance_expand_file_matcher): Delete.
15818 (maintenance_expand_symtabs): Use lambdas.
15819 * symtab.c (iterate_over_some_symtabs): Adjust to use
15820 function_view as callback types and return bool.
15821 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
15822 of a cleanup.
15823 (lookup_symtab_callback): Delete.
15824 (lookup_symtab): Use a lambda.
15825 (iterate_over_symbols): Adjust to use function_view as callback
15826 type.
15827 (struct search_symbols_data, search_symbols_file_matches)
15828 (search_symbols_name_matches): Delete.
15829 (search_symbols): Use a pair of lambdas.
15830 (struct add_name_data, add_macro_name, symbol_completion_matcher)
15831 (symtab_expansion_callback): Delete.
15832 (default_make_symbol_completion_list_break_on_1): Use lambdas.
15833 * symtab.h: Include "common/function-view.h".
15834 (iterate_over_some_symtabs): Adjust to use function_view as
15835 callback type and return bool.
15836 (iterate_over_symtabs): Adjust to use function_view as callback
15837 type.
15838 (symbol_found_callback_ftype): Remove 'data' parameter and return
15839 bool.
15840 (iterate_over_symbols): Adjust to use function_view as callback
15841 type.
15842
07e253aa
PA
158432017-02-23 Pedro Alves <palves@redhat.com>
15844
15845 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
15846 (%.o) <unittests/%.c>: New pattern.
15847 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
15848 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
15849 * common/function-view.h: New file.
15850 * unittests/function-view-selftests.c: New file.
15851 * configure: Regenerate.
15852
8eaf5320
SM
158532017-02-23 Simon Marchi <simon.marchi@ericsson.com>
15854
15855 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
15856 inferior_ptid.
15857 * go32-nat.c (go32_thread_alive): Likewise.
15858
38768751
YQ
158592017-02-23 Yao Qi <yao.qi@linaro.org>
15860
15861 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
15862 delete.
15863
0a8beaba
YQ
158642017-02-23 Yao Qi <yao.qi@linaro.org>
15865
15866 * varobj.c (varobj_clear_saved_item): Use delete instead of
15867 xfree.
15868 (update_dynamic_varobj_children): Likewise.
15869
58fdfd2c
JK
158702017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15871
15872 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
15873
1b90b139
SM
158742017-02-21 Simon Marchi <simon.marchi@ericsson.com>
15875
15876 * common/enum-flags.h (enum_flags::enum_flags): Initialize
15877 m_enum_value to 0 in default constructor.
15878
2039d74e
EBM
158792017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
15880
15881 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
15882 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
15883 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
15884 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
15885 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
15886 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
15887 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
15888 IS_STORE_CONDITIONAL_INSN.
15889
7814882a
JK
158902017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15891
15892 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
15893
0ae60b63
JK
158942017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15895
15896 * NEWS (Changes since GDB 7.12): Add DWARF-5.
15897
0224619f
JK
158982017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15899
15900 * dwarf2read.c (skip_one_die, read_attribute_value)
15901 (dwarf2_const_value_attr, dump_die_shallow)
15902 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
15903 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
15904
0af92d60
JK
159052017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15906
15907 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
15908 (dwarf_parse_macro_header): Accept DWARF version 5.
15909 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
15910
216f72a1
JK
159112017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15912
15913 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
15914 DW_AT_GNU_*.
15915 * common/common-exceptions.h (enum errors): Likewise.
15916 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
15917 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
15918 (dwarf_expr_context::execute_stack_op): Likewise.
15919 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
15920 Likewise.
15921 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
15922 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
15923 (show_entry_values_debug, call_site_to_target_addr)
15924 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
15925 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
15926 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
15927 (value_of_dwarf_block_entry, indirect_pieced_value)
15928 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
15929 (disassemble_dwarf_expression): Likewise.
15930 * dwarf2read.c (process_die, inherit_abstract_dies)
15931 (read_call_site_scope): Likewise.
15932 * gdbtypes.h (struct func_type, struct call_site_parameter)
15933 (struct call_site): Likewise.
15934 * stack.c (read_frame_arg): Likewise.
15935 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
15936
43988095
JK
159372017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15938
15939 * defs.h (read_unsigned_leb128): New declaration.
15940 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
15941 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
15942 (dwarf2_find_location_expression): Call also
15943 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
15944 * dwarf2loc.h (dwarf2_version): New declaration.
15945 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
15946 rnglists.
15947 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
15948 .debug_rnglists.
15949 (struct dwop_section_names): Add loclists_dwo.
15950 (dwop_section_names): Add .debug_loclists.dwo.
15951 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
15952 (struct dwarf2_per_cu_data): Add dwarf_version.
15953 (struct dwo_sections): Add loclists.
15954 (struct attr_abbrev): Add implicit_const.
15955 (read_indirect_line_string): New declaration.
15956 (read_unsigned_leb128): Delete declaration.
15957 (rcuh_kind): New definition.
15958 (read_and_check_comp_unit_head): Change parameter
15959 is_debug_types_section to section_kind.
15960 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
15961 (read_comp_unit_head): Change parameter abfd to section, add parameter
15962 section_kind. Handle DWARF-5.
15963 (error_check_comp_unit_head): Accept also DWARF version 5.
15964 (read_and_check_comp_unit_head): Change parameter
15965 is_debug_types_section to section_kind.
15966 (read_and_check_type_unit_head): Delete function.
15967 (read_abbrev_offset): Handle DWARF-5.
15968 (create_debug_type_hash_table): Add parameter section_kind. Process
15969 only DW_UT_type. Use signature and type_offset_in_tu from struct
15970 comp_unit_head.
15971 (create_debug_types_hash_table): Update create_debug_type_hash_table
15972 caller.
15973 (create_all_type_units): Call create_debug_type_hash_table.
15974 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
15975 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
15976 caller.
15977 (skip_one_die): Handle DW_FORM_implicit_const.
15978 (dwarf2_rnglists_process): New function.
15979 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
15980 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
15981 (read_attribute_value): Handle DW_FORM_implicit_const,
15982 DW_FORM_line_strp.
15983 (read_attribute): Handle DW_FORM_implicit_const.
15984 (read_indirect_string_at_offset_from): New function from
15985 read_indirect_string_at_offset.
15986 (read_indirect_string_at_offset): Call
15987 read_indirect_string_at_offset_from.
15988 (read_indirect_line_string_at_offset): New function.
15989 (read_indirect_string): New function comment.
15990 (read_indirect_line_string): New function.
15991 (read_unsigned_leb128): Make it global.
15992 (dwarf2_string_attr): Handle DWARF-5.
15993 (add_include_dir_stub, read_formatted_entries): New functions.
15994 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
15995 Handle DWARF-5.
15996 (per_cu_header_read_in): Update read_comp_unit_head caller.
15997 (dwarf2_version): New function.
15998 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
15999 rnglists.
16000 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
16001 fields.
16002
22d2f3ab
JK
160032017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16004
16005 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
16006
5f46c5a5
JK
160072017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16008
16009 * dwarf2read.c (dwarf2_ranges_process): New function from
16010 dwarf2_ranges_read.
16011 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
16012 dwarf2_ranges_process.
16013
78d4d2c5
JK
160142017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
16015
16016 * dwarf2read.c (create_debug_type_hash_table): New function from
16017 create_debug_types_hash_table.
16018 (create_debug_types_hash_table): Call create_debug_type_hash_table.
16019 (create_all_type_units, open_and_init_dwo_file): Update
16020 create_debug_types_hash_table callers.
16021
1b076f25
SDJ
160222017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16023
16024 PR gdb/16188
16025 * fork-child.c (trace_start_error): Fix thinko. va_end should
16026 refer to 'ap', not 'args'.
16027
0db8980c
SDJ
160282017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
16029 Pedro Alves <palves@redhat.com>
16030
16031 PR gdb/16188
16032 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
16033 calls succeeded.
16034 * fork-child.c (trace_start_error): New function.
16035 (trace_start_error_with_name): Likewise.
16036 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
16037 * inf-ptrace.c (inf_ptrace_me): Likewise.
16038 * inferior.h (trace_start_error): New prototype.
16039 (trace_start_error_with_name): Likewise.
16040
99e8a4f9
SDJ
160412017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
16042
16043 PR gdb/21164
16044 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
16045 NULL before using it.
16046 * symmisc.c (maintenance_print_symbols): Likewise.
16047 (maintenance_print_msymbols): Likewise.
16048
4e746bb6
TW
160492017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16050
16051 * NEWS: Add record Python bindings entry.
16052
160532017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16054
16055 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
16056 py-record-full.o.
16057 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
16058 * python/py-record-btrace.c, python/py-record-btrace.h,
16059 python/py-record-full.c, python/py-record-full.h: New file.
16060 * python/py-record.c: Add include for py-record-btrace.h and
16061 py-record-full.h.
16062 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
16063 recpy_instruction_history, recpy_function_call_history, recpy_begin,
16064 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
16065 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
16066 New definition.
16067 (gdbpy_initialize_btrace): New export.
16068 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
16069
160702017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16071
16072 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
16073 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
16074 * python/py-record.c: New file.
16075 * python/python-internal.h (gdbpy_start_recording,
16076 gdbpy_current_recording, gdpy_stop_recording,
16077 gdbpy_initialize_record): New export.
16078 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
16079 (python_GdbMethods): Add gdbpy_start_recording,
16080 gdbpy_current_recording and gdbpy_stop_recording.
16081
160822017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16083
16084 * record-btrace.c (record_btrace_record_method): New function.
16085 (init_record_btrace_ops): Initialize to_record_method.
16086 * record-full.c (record_full_record_method): New function.
16087 (init_record_full_ops, init_record_full_core_ops): Add
16088 record_full_record_method.
16089 * record.h (enum record_method): New enum.
16090 * target-debug.h (target_debug_print_enum_record_method: New define.
16091 * target-delegates.c: Regenerate.
16092 * target.c (target_record_method): New function.
16093 * target.h: Include record.h.
16094 (struct target_ops) <to_record_method>: New field.
16095 (target_record_method): New export.
16096
160972017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16098
16099 * record.h (record_start, record_stop): New export.
16100 * record.c (record_start, record_stop): New function.
16101
161022017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16103
16104 * btrace.c (btrace_fetch): Copy function call segments pointer
16105 into a vector.
16106 (btrace_clear): Clear the vector.
16107 (btrace_find_insn_by_number): Use binary search to find the correct
16108 function call segment.
16109 * btrace.h (brace_fun_p): New typedef.
16110 (struct btrace_thread_info) <functions>: New field.
16111
161122017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16113
16114 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
16115 * btrace.c (btrace_decode_error): ... here. New function.
16116 * btrace.h (btrace_decode_error): New export.
16117
161182017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
16119
16120 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
16121 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
16122 btrace_find_insn_by_number): Remove special case for gaps.
16123 * btrace.h (btrace_insn_get_error): New export.
16124 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
16125 * record-btrace.c (btrace_insn_history): Print number for gaps.
16126 (record_btrace_info, record_btrace_goto): Handle gaps.
16127
3f77c769
TT
161282017-02-14 Tom Tromey <tom@tromey.com>
16129
16130 PR python/13598:
16131 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
16132 event.
16133 * python/py-evts.c (gdbpy_initialize_py_events): Add
16134 before_prompt registry.
16135 * python/py-events.h (events_object) <before_prompt>: New field.
16136
4c2c7ac6
MM
161372017-02-14 Markus Metzger <markus.t.metzger@intel.com>
16138
16139 * btrace.c (ftrace_new_switch): Preserve up link and flags.
16140
5cf30ebf
LM
161412017-02-13 Luis Machado <lgustavo@codesourcery.com>
16142
16143 * symfile (_initialize_symfile): Add usage text to the load command's
16144 help text.
16145
26a06916
SM
161462017-02-10 Simon Marchi <simon.marchi@ericsson.com>
16147
16148 * utils.c (defaulted_query): Don't query on secondary UIs.
16149
0b145e37
TT
161502017-02-10 Tom Tromey <tom@tromey.com>
16151
16152 * rust-lang.c (rust_get_disr_info): Remove unused variable.
16153
2d8365c4
TT
161542017-02-10 Tom Tromey <tom@tromey.com>
16155
16156 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
16157 "cleanup" local.
16158 * python/py-type.c (typy_legacy_template_argument): Remove
16159 unnecessary "cleanup" local.
16160
2bb8f231
TT
161612017-02-10 Tom Tromey <tom@tromey.com>
16162
16163 * python/python.c (do_start_initialization): New function, from
16164 _initialize_python.
16165 (_initialize_python): Call do_start_initialization.
16166 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
16167 goto.
16168
1bdfaf42
TT
161692017-02-10 Tom Tromey <tom@tromey.com>
16170
16171 * python/py-prettyprint.c (pretty_print_one_value): Use
16172 gdbpy_ref.
16173
88b6faea
TT
161742017-02-10 Tom Tromey <tom@tromey.com>
16175
16176 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
16177 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
16178 gdbpy_ref.
16179 * python/py-type.c (field_new): Use gdbpy_ref.
16180 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
16181 gdbpy_ref.
16182 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
16183 (py_free_pspace): Likewise.
16184 (pspace_to_pspace_object): Likewise.
16185 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
16186 (py_free_objfile): Likewise.
16187 (objfile_to_objfile_object): Likewise.
16188 * python/py-inferior.c (delete_thread_object): Use
16189 gdbpy_ref.
16190 (infpy_read_memory): Likewise.
16191 (py_free_inferior): Likewise.
16192 * python/py-evtregistry.c (create_eventregistry_object): Use
16193 gdbpy_ref.
16194 * python/py-event.c (create_event_object): Use gdbpy_ref.
16195
7780f186
TT
161962017-02-10 Tom Tromey <tom@tromey.com>
16197
16198 * python/py-ref.h (gdbpy_ref_policy): Now a template.
16199 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
16200 used.
16201 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
16202 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
16203 python/py-exitedevent.c, python/py-finishbreakpoint.c,
16204 python/py-framefilter.c, python/py-function.c,
16205 python/py-inferior.c, python/py-infevents.c,
16206 python/py-linetable.c, python/py-newobjfileevent.c,
16207 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
16208 python/py-signalevent.c, python/py-stopevent.c,
16209 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
16210 python/py-unwind.c, python/py-utils.c, python/py-value.c,
16211 python/py-varobj.c, python/py-xmethods.c, python/python.c,
16212 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
16213
d4b0bb18
TT
162142017-02-10 Tom Tromey <tom@tromey.com>
16215
16216 * ui-out.h (ui_out_emit_type): New class.
16217 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
16218 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
16219 and ui_out_emit_tuple.
16220 (enumerate_locals): Likewise.
16221 (py_mi_print_variables, py_print_locals, py_print_args): Use
16222 ui_out_emit_list.
16223 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
16224 ui_out_emit_list.
16225 * common/gdb_optional.h: New file.
16226
f67f945c
MG
162272017-02-10 Martin Galvan <martingalvan@sourceware.org>
16228
16229 * MAINTAINERS (Write After Approval): Update my e-mail address.
16230
18da0c51
MG
162312017-02-10 Martin Galvan <martingalvan@sourceware.org>
16232
16233 PR gdb/21122
16234 * breakpoint.c (_initialize_breakpoint): Update the help description
16235 of the 'commands' command to indicate that it takes a list argument.
16236
62c14536
SM
162372017-02-09 Simon Marchi <simon.marchi@ericsson.com>
16238
16239 * interps.c (current_interp_set_logging): Remove "return".
16240
ff6fa247
GB
162412017-02-09 Gary Benson <gbenson@redhat.com>
16242
16243 * symtab.c (add_symtab_completions): Prevent NULL pointer
16244 dereference.
16245
a474bd8e
PA
162462017-02-08 Pedro Alves <palves@redhat.com>
16247
16248 * interps.c (interp::interp): Remove reference to quiet_p.
16249 (interp_set): Make static. Remove dead "Switching to" output
16250 code.
16251 (interp_quiet_p, interp_set_quiet): Delete.
16252 (interpreter_exec_cmd): Don't set the interpreter quiet.
16253 * interps.h (interp_quiet_p): Make static.
16254 (class interp) <quiet_p>: Remove field
16255
3d7b173c
JG
162562017-02-08 Jerome Guitton <guitton@adacore.com>
16257
604c4576
JG
16258 * cli/cli-decode.c (find_command_name_length): Make it extern.
16259 * cli/cli-decode.h (find_command_name_length): Declare.
16260 * cli/cli-script.c (command_name_equals, line_first_arg):
16261 New functions.
16262 (process_next_line): Use cli-decode to parse command names.
16263 (build_command_line): Make args a constant pointer.
16264
162652017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 16266
3d7b173c
JG
16267 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
16268 Remove case-insensitive search.
16269
1291063d
JM
162702017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
16271
16272 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
16273 at the end of the line. Avoids an ARI warning.
16274
20b477a7
LM
162752017-02-06 Luis Machado <lgustavo@codesourcery.com>
16276
16277 * NEWS: Mention support for record/replay of Intel 64 rdrand and
16278 rdseed instructions.
16279 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
16280
3f7b46f2
IR
162812017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
16282
16283 PR tdep/20936
16284 Provide and use sparc32 and sparc64 target description XML files.
16285 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
16286 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
16287 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
16288 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
16289 * features/sparc/sparc32-solaris.xml: New file.
16290 * features/sparc/sparc64-solaris.xml: New file.
16291 * features/sparc/sparc32-solaris.c: Generated.
16292 * features/sparc/sparc64-solaris.c: Generated.
16293 * sparc-tdep.h: Account for differences in target descriptions.
16294 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
16295 (sparc32_register_type): Use target provided registers.
16296 (validate_tdesc_registers): New function.
16297 (sparc32_gdbarch_init): Use tdesc_has_registers.
16298 Set pseudoregister functions.
16299 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
16300 (sparc64_register_type): Use target provided registers.
16301 (sparc64_init_abi): Set pseudoregister functions.
16302
f0fd41c1
TT
163032017-02-03 Tom Tromey <tom@tromey.com>
16304
16305 PR rust/21097:
16306 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
16307 with a single member.
16308
d6f9b0fb
PA
163092017-02-03 Pedro Alves <palves@redhat.com>
16310
16311 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
16312 (cli_interp_base::~cli_interp_base): New.
16313 (cli_interp): New struct.
16314 (as_cli_interp): Cast the interp itself to cli_interp.
16315 (cli_interpreter_pre_command_loop): Rename to ...
16316 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
16317 parameter.
16318 (cli_interpreter_init): Rename to ...
16319 (cli_interp::init): ... this. Remove 'self' parameter. Use
16320 boolean. Make extern.
16321 (cli_interpreter_resume): Rename to ...
16322 (cli_interp::resume): ... this. Remove 'data' parameter. Make
16323 extern.
16324 (cli_interpreter_suspend): Rename to ...
16325 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
16326 extern.
16327 (cli_interpreter_exec): Rename to ...
16328 (cli_interp::exec): ... this. Remove 'data' parameter. Make
16329 extern.
16330 (cli_interpreter_supports_command_editing): Rename to ...
16331 (cli_interp_base::supports_command_editing): ... this. Remove
16332 'interp' parameter. Make extern.
16333 (cli_ui_out): Rename to ...
16334 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
16335 Make extern.
16336 (cli_set_logging): Rename to ...
16337 (cli_interp_base::set_logging): ... this. Remove 'interp'
16338 parameter. Make extern.
16339 (cli_interp_procs): Delete.
16340 (cli_interp_factory): Adjust to use "new".
16341 * cli/cli-interp.h: Include "interps.h".
16342 (struct cli_interp_base): New struct.
16343 * interps.c (struct interp): Delete. Fields moved to interps.h.
16344 (interp_new): Delete.
16345 (interp::interp, interp::~interp): New.
16346 (interp_set): Use bool, and return void. Assume the interpreter
16347 has suspend, init and resume methods, and that the all return
16348 void.
16349 (set_top_level_interpreter): interp_set returns void.
16350 (interp_ui_out): Adapt.
16351 (current_interp_set_logging): Adapt.
16352 (interp_data): Delete.
16353 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
16354 (interp_exec): Adapt.
16355 (top_level_interpreter_data): Delete.
16356 * interps.h (interp_init_ftype, interp_resume_ftype)
16357 (interp_suspend_ftype, interp_exec_ftype)
16358 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
16359 (class interp): New.
16360 (interp_new): Delete.
16361 (interp_set): Now returns void. Use bool.
16362 (interp_data, top_level_interpreter_data): Delete.
16363 * mi/mi-common.h: Include interps.h.
16364 (class mi_interp): Inherit from interp. Define a ctor. Declare
16365 init, resume, suspect, exec, interp_ui_out, set_logging and
16366 pre_command_loop methods.
16367 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
16368 (mi_interpreter_init): Rename to ...
16369 (mi_interp::init): ... this. Remove the 'interp' parameter, use
16370 bool, return void and make extern. Adjust.
16371 (mi_interpreter_resume): ... Rename to ...
16372 (mi_interp::resume): ... this. Remove the 'data' parameter,
16373 return void and make extern. Adjust.
16374 (mi_interpreter_suspend): ... Rename to ...
16375 (mi_interp::suspend): ... this. Remove the 'data' parameter,
16376 return void and make extern. Adjust.
16377 (mi_interpreter_exec): ... Rename to ...
16378 (mi_interp::exec): ... this. Remove the 'data' parameter and make
16379 extern. Adjust.
16380 (mi_interpreter_pre_command_loop): ... Rename to ...
16381 (mi_interp::pre_command_loop): ... this. Remove the 'self'
16382 parameter and make extern.
16383 (mi_on_normal_stop_1): Adjust.
16384 (mi_ui_out): Rename to ...
16385 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
16386 parameter and make extern. Adjust.
16387 (mi_set_logging): Rename to ...
16388 (mi_interp::set_logging): ... this. Remove the 'interp'
16389 parameter and make extern. Adjust.
16390 (mi_interp_procs): Delete.
16391 (mi_interp_factory): Adjust to use 'new'.
16392 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
16393 (mi_print_exception, mi_execute_command, mi_load_progress):
16394 Adjust.
16395 * tui/tui-interp.c (tui_interp): New class.
16396 (as_tui_interp): Return a tui_interp pointer.
16397 (tui_on_normal_stop, tui_on_signal_received)
16398 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
16399 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
16400 to use interp::interp_ui_out.
16401 (tui_init): Rename to ...
16402 (tui_interp::init): ... this. Remove the 'self' parameter, use
16403 bool, return void and make extern. Adjust.
16404 (tui_resume): Rename to ...
16405 (tui_interp::resume): ... this. Remove the 'data' parameter,
16406 return void and make extern. Adjust.
16407 (tui_suspend): Rename to ...
16408 (tui_interp::suspend): ... this. Remove the 'data' parameter,
16409 return void and make extern. Adjust.
16410 (tui_ui_out): Rename to ...
16411 (tui_interp::interp_ui_out): ... this. Remove the 'self'
16412 parameter, and make extern. Adjust.
16413 (tui_exec): Rename to ...
16414 (tui_interp::exec): ... this. Remove the 'data' parameter and
16415 make extern.
16416 (tui_interp_procs): Delete.
16417 (tui_interp_factory): Use "new".
16418
65c40c95
TT
164192017-02-02 Tom Tromey <tom@tromey.com>
16420
16421 * rust-exp.y (ends_raw_string, space_then_number)
16422 (rust_identifier_start_p): Return bool.
16423 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
16424 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
16425 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
16426 (rust_chartype_p): Return bool.
16427 (val_print_struct, rust_print_struct_def, rust_print_type):
16428 Update.
16429 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
16430 Return bool.
16431
b50f188d
TT
164322017-02-02 Tom Tromey <tom@tromey.com>
16433
16434 * rust-lang.c: Reindent.
16435
03c85b11
TT
164362017-02-02 Tom Tromey <tom@tromey.com>
16437
16438 * rust-lang.h (rust_crate_for_block): Update.
16439 * rust-lang.c (rust_crate_for_block): Return std::string.
16440 (rust_get_disr_info): Use std:;string, not
16441 gdb::unique_xmalloc_ptr.
16442 * rust-exp.y (crate_name): Update.
16443
9b6da501
PA
164442017-02-02 Pedro Alves <palves@redhat.com>
16445
16446 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
16447 field out of gdb_disassembler_test and make it static.
16448
ec4cb20b
PA
164492017-02-02 Pedro Alves <palves@redhat.com>
16450
16451 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
16452 mi1_interp and mi_interp fields.
16453
5be5dbf0
PA
164542017-02-02 Pedro Alves <palves@redhat.com>
16455
616268b6
PA
16456 * cli/cli-interp.c (struct saved_output_files, saved_output):
16457 Moved from cli/cli-logging.c.
16458 (cli_set_logging): New function.
16459 (cli_interp_procs): Install cli_set_logging.
16460 * cli/cli-interp.h (make_logging_output, cli_set_logging):
16461 Declare.
16462 * cli/cli-logging.c (struct saved_output_files, saved_output):
16463 Moved to cli/cli-interp.c.
16464 (pop_output_files): Don't save outputs here.
16465 (make_logging_output): New function.
16466 (handle_redirections): Don't build tee nor save previous outputs
16467 here.
16468 * interps.c (current_interp_set_logging): Change prototype.
16469 Assume there's always a set_logging_proc method installed.
16470 * interps.h (interp_set_logging_ftype): Change prototype.
16471 (current_interp_set_logging): Change prototype and adjust comment.
16472 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
16473 use make_logging_output.
16474 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
164752017-02-02 Pedro Alves <palves@redhat.com>
16476
5be5dbf0
PA
16477 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
16478 from ...
16479 (set_logging_overwrite): ... here.
16480 (logging_no_redirect_file): Delete.
16481 (set_logging_redirect): Don't handle redirection on the fly.
16482 Instead warn that "logging off" / "logging on" is necessary.
16483 (pop_output_files): Delete references to logging_no_redirect_file.
16484 (show_logging_command): Always speak in terms of what will happen
16485 once logging is reenabled.
16486
c99cc448
PA
164872017-02-02 Pedro Alves <palves@redhat.com>
16488
16489 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
16490
8b172ce7
PA
164912017-02-02 Pedro Alves <palves@redhat.com>
16492
16493 * disasm.c (gdb_pretty_print_insn): Rename to ...
16494 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
16495 Remove gdbarch parameter. Adapt to clear the object's buffers
16496 instead of allocating new buffers, and to print using the object's
16497 gdb_disassembler instead of calling gdb_print_insn.
16498 (dump_insns): Use gdb_pretty_print_disassembler.
16499 * disasm.h (gdb_pretty_print_insn): Delete declaration.
16500 (gdb_pretty_print_disassembler): New class.
16501 * record-btrace.c (btrace_insn_history): Use
16502 gdb_pretty_print_disassembler.
16503
d7e74731
PA
165042017-02-02 Pedro Alves <palves@redhat.com>
16505
16506 * ada-lang.c (type_as_string): Use string_file.
16507 * ada-valprint.c (ada_print_floating): Use string_file.
16508 * ada-varobj.c (ada_varobj_scalar_image)
16509 (ada_varobj_get_value_image): Use string_file.
16510 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
16511 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
16512 * breakpoint.c (update_inserted_breakpoint_locations)
16513 (insert_breakpoint_locations, reattach_breakpoints)
16514 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
16515 (print_it_watchpoint): Use string_file.
16516 (save_breakpoints): Use stdio_file.
16517 * c-exp.y (oper): Use string_file.
16518 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
16519 tee_file.
16520 (pop_output_files): Use delete.
16521 (handle_redirections): Use stdio_file and tee_file.
16522 * cli/cli-setshow.c (do_show_command): Use string_file.
16523 * compile/compile-c-support.c (c_compute_program): Use
16524 string_file.
16525 * compile/compile-c-symbols.c (generate_vla_size): Take a
16526 'string_file &' instead of a 'ui_file *'.
16527 (generate_c_for_for_one_variable): Take a 'string_file &' instead
16528 of a 'ui_file *'. Use string_file.
16529 (generate_c_for_variable_locations): Take a 'string_file &'
16530 instead of a 'ui_file *'.
16531 * compile/compile-internal.h (generate_c_for_for_one_variable):
16532 Take a 'string_file &' instead of a 'ui_file *'.
16533 * compile/compile-loc2c.c (push, pushf, unary, binary)
16534 (print_label, pushf_register_address, pushf_register)
16535 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
16536 'ui_file *'. Adjust.
16537 * compile/compile.c (compile_to_object): Use string_file.
16538 * compile/compile.h (compile_dwarf_expr_to_c)
16539 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
16540 'ui_file *'.
16541 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
16542 (replace_typedefs_qualified_name): Use string_file and
16543 obstack_copy0.
16544 * disasm.c (gdb_pretty_print_insn): Use string_file.
16545 (gdb_disassembly): Adjust reference the null_stream global.
16546 (do_ui_file_delete): Delete.
16547 (gdb_insn_length): Use null_stream.
16548 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
16549 * dwarf2loc.c (dwarf2_compile_property_to_c)
16550 (locexpr_generate_c_location, loclist_generate_c_location): Take a
16551 'string_file &' instead of a 'ui_file *'.
16552 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
16553 * dwarf2read.c (do_ui_file_peek_last): Delete.
16554 (dwarf2_compute_name): Use string_file.
16555 * event-top.c (gdb_setup_readline): Use stdio_file.
16556 * gdbarch.sh (verify_gdbarch): Use string_file.
16557 * gdbtypes.c (safe_parse_type): Use null_stream.
16558 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
16559 string_file.
16560 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
16561 'string_file *' instead of a 'ui_file *'.
16562 (gdbscm_arch_disassemble): Use string_file.
16563 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
16564 * guile/scm-ports.c (class ioscm_file_port): Now a class that
16565 inherits from ui_file.
16566 (ioscm_file_port_delete, ioscm_file_port_rewind)
16567 (ioscm_file_port_put): Delete.
16568 (ioscm_file_port_write): Rename to ...
16569 (ioscm_file_port::write): ... this. Remove file_port_magic
16570 checks.
16571 (ioscm_file_port_new): Delete.
16572 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
16573 ui_file_up.
16574 * guile/scm-type.c (tyscm_type_name): Use string_file.
16575 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
16576 Use string_file.
16577 * infcmd.c (print_return_value_1): Use string_file.
16578 * infrun.c (print_target_wait_results): Use string_file.
16579 * language.c (add_language): Use string_file.
16580 * location.c (explicit_to_string_internal): Use string_file.
16581 * main.c (captured_main_1): Use null_file.
16582 * maint.c (maintenance_print_architecture): Use stdio_file.
16583 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
16584 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
16585 event_channel>: Change type to mi_console_file pointer.
16586 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
16587 (mi_console_file_delete): Delete.
16588 (struct mi_console_file): Delete.
16589 (mi_console_file_magic): Delete.
16590 (mi_console_file_new): Delete.
16591 (mi_console_file::mi_console_file): New.
16592 (mi_console_file_delete): Delete.
16593 (mi_console_file_fputs): Delete.
16594 (mi_console_file::write): New.
16595 (mi_console_raw_packet): Delete.
16596 (mi_console_file::flush): New.
16597 (mi_console_file_flush): Delete.
16598 (mi_console_set_raw): Rename to ...
16599 (mi_console_file::set_raw): ... this.
16600 * mi/mi-console.h (class mi_console_file): New class.
16601 (mi_console_file_new, mi_console_set_raw): Delete.
16602 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
16603 (mi_set_logging): Use delete and tee_file. Adjust.
16604 * mi/mi-main.c (output_register): Use string_file.
16605 (mi_cmd_data_evaluate_expression): Use string_file.
16606 (mi_cmd_data_read_memory): Use string_file.
16607 (mi_cmd_execute, print_variable_or_computed): Use string_file.
16608 * mi/mi-out.c (mi_ui_out::main_stream): New.
16609 (mi_ui_out::rewind): Use main_stream and
16610 string_file.
16611 (mi_ui_out::put): Use main_stream and string_file.
16612 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16613 Allocate a 'string_file' instead.
16614 (mi_out_new): Don't allocate a mem_fileopen stream here.
16615 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16616 (mi_ui_out::main_stream): Declare method.
16617 * printcmd.c (eval_command): Use string_file.
16618 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
16619 * python/py-arch.c (archpy_disassemble): Use string_file.
16620 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
16621 * python/py-frame.c (frapy_str): Use string_file.
16622 * python/py-framefilter.c (py_print_type, py_print_single_arg):
16623 Use string_file.
16624 * python/py-type.c (typy_str): Use string_file.
16625 * python/py-unwind.c (unwind_infopy_str): Use string_file.
16626 * python/py-value.c (valpy_str): Use string_file.
16627 * record-btrace.c (btrace_insn_history): Use string_file.
16628 * regcache.c (regcache_print): Use stdio_file.
16629 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
16630 * remote.c (escape_buffer): Use string_file.
16631 * rust-lang.c (rust_get_disr_info): Use string_file.
16632 * serial.c (serial_open_ops_1): Use stdio_file.
16633 (do_serial_close): Use delete.
16634 * stack.c (print_frame_arg): Use string_file.
16635 (print_frame_args): Remove local mem_fileopen stream, not used.
16636 (print_frame): Use string_file.
16637 * symmisc.c (maintenance_print_symbols): Use stdio_file.
16638 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
16639 Take a 'string_file *' instead of a 'ui_file *'.
16640 * top.c (new_ui): Use stdio_file and stderr_file.
16641 (free_ui): Use delete.
16642 (execute_command_to_string): Use string_file.
16643 (quit_confirm): Use string_file.
16644 * tracepoint.c (collection_list::append_exp): Use string_file.
16645 * tui/tui-disasm.c (tui_disassemble): Use string_file.
16646 * tui/tui-file.c: Don't include "ui-file.h".
16647 (enum streamtype, struct tui_stream): Delete.
16648 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
16649 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
16650 (tui_file::tui_file): New method.
16651 (tui_file_fputs): Delete.
16652 (tui_file_get_strbuf): Delete.
16653 (tui_file::puts): New method.
16654 (tui_file_adjust_strbuf): Delete.
16655 (tui_file_flush): Delete.
16656 (tui_file::flush): New method.
16657 * tui/tui-file.h: Tweak intro comment.
16658 Include ui-file.h.
16659 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
16660 (tui_file_adjust_strbuf): Delete declarations.
16661 (class tui_file): New class.
16662 * tui/tui-io.c (tui_initialize_io): Use tui_file.
16663 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
16664 (tui_register_format): Use string_stream.
16665 * tui/tui-stack.c (tui_make_status_line): Use string_file.
16666 (tui_get_function_from_frame): Use string_file.
16667 * typeprint.c (type_to_string): Use string_file.
16668 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
16669 (null_stream): New global.
16670 (ui_file_delete): Delete.
16671 (ui_file::ui_file): New.
16672 (null_file_isatty): Delete.
16673 (ui_file::~ui_file): New.
16674 (null_file_rewind): Delete.
16675 (ui_file::printf): New.
16676 (null_file_put): Delete.
16677 (null_file_flush): Delete.
16678 (ui_file::putstr): New.
16679 (null_file_write): Delete.
16680 (ui_file::putstrn): New.
16681 (null_file_read): Delete.
16682 (ui_file::putc): New.
16683 (null_file_fputs): Delete.
16684 (null_file_write_async_safe): Delete.
16685 (ui_file::vprintf): New.
16686 (null_file_delete): Delete.
16687 (null_file::write): New.
16688 (null_file_fseek): Delete.
16689 (null_file::puts): New.
16690 (ui_file_data): Delete.
16691 (null_file::write_async_safe): New.
16692 (gdb_flush, ui_file_isatty): Adjust.
16693 (ui_file_put, ui_file_rewind): Delete.
16694 (ui_file_write): Adjust.
16695 (ui_file_write_for_put): Delete.
16696 (ui_file_write_async_safe, ui_file_read): Adjust.
16697 (ui_file_fseek): Delete.
16698 (fputs_unfiltered): Adjust.
16699 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
16700 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
16701 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
16702 (set_ui_file_data): Delete.
16703 (string_file::~string_file, string_file::write)
16704 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
16705 (do_ui_file_as_string, ui_file_as_string): Delete.
16706 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
16707 (struct mem_file): Delete.
16708 (mem_file_new): Delete.
16709 (stdio_file::stdio_file): New.
16710 (mem_file_delete): Delete.
16711 (stdio_file::stdio_file): New.
16712 (mem_fileopen): Delete.
16713 (stdio_file::~stdio_file): New.
16714 (mem_file_rewind): Delete.
16715 (stdio_file::set_stream): New.
16716 (mem_file_put): Delete.
16717 (stdio_file::open): New.
16718 (mem_file_write): Delete.
16719 (stdio_file_magic, struct stdio_file): Delete.
16720 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
16721 (stdio_file::flush): New.
16722 (stdio_file_read): Rename to ...
16723 (stdio_file::read): ... this. Adjust.
16724 (stdio_file_write): Rename to ...
16725 (stdio_file::write): ... this. Adjust.
16726 (stdio_file_write_async_safe): Rename to ...
16727 (stdio_file::write_async_safe) ... this. Adjust.
16728 (stdio_file_fputs): Rename to ...
16729 (stdio_file::puts) ... this. Adjust.
16730 (stdio_file_isatty): Delete.
16731 (stdio_file_fseek): Delete.
16732 (stdio_file::isatty): New.
16733 (stderr_file_write): Rename to ...
16734 (stderr_file::write) ... this. Adjust.
16735 (stderr_file_fputs): Rename to ...
16736 (stderr_file::puts) ... this. Adjust.
16737 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
16738 (stderr_file::stderr_file): New.
16739 (tee_file_magic): Delete.
16740 (struct tee_file): Delete.
16741 (tee_file::tee_file): New.
16742 (tee_file_new): Delete.
16743 (tee_file::~tee_file): New.
16744 (tee_file_delete): Delete.
16745 (tee_file_flush): Rename to ...
16746 (tee_file::flush): ... this. Adjust.
16747 (tee_file_write): Rename to ...
16748 (tee_file::write): ... this. Adjust.
16749 (tee_file::write_async_safe): New.
16750 (tee_file_fputs): Rename to ...
16751 (tee_file::puts): ... this. Adjust.
16752 (tee_file_isatty): Rename to ...
16753 (tee_file::isatty): ... this. Adjust.
16754 * ui-file.h (struct obstack, struct ui_file): Don't
16755 forward-declare.
16756 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
16757 (ui_file_write_ftype)
16758 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
16759 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
16760 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
16761 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
16762 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
16763 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
16764 (set_ui_file_fseek): Delete.
16765 (ui_file_data, ui_file_delete, ui_file_rewind)
16766 (struct ui_file): New.
16767 (ui_file_up): New.
16768 (class null_file): New.
16769 (null_stream): Declare.
16770 (ui_file_write_for_put, ui_file_put): Delete.
16771 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
16772 Delete.
16773 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
16774 (gdb_fopen, tee_file_new): Delete.
16775 (struct string_file): New.
16776 (struct stdio_file): New.
16777 (stdio_file_up): New.
16778 (struct stderr_file): New.
16779 (class tee_file): New.
16780 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
16781 of a 'ui_file *'. Adjust.
16782 * ui-out.h (class ui_out) <field_stream>: Likewise.
16783 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
16784 (null_stream): Delete.
16785 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
16786 Adjust.
16787 * utils.h (struct ui_file): Delete forward declaration..
16788 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
16789 (error_stream): Take a 'string_file &' instead of a
16790 'ui_file *'.
16791 * varobj.c (varobj_value_get_print_value): Use string_file.
16792 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
16793 * gdbarch.c: Regenerate.
16794
187808b0
PA
167952017-02-02 Pedro Alves <palves@redhat.com>
16796
16797 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
16798 (gdb_pretty_print_insn): ... this. Now a free function. Add back
16799 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
16800 Adjust to call gdb_print_insn instead of
16801 gdb_disassembler::print_insn.
16802 (dump_insns, do_mixed_source_and_assembly_deprecated)
16803 (do_mixed_source_and_assembly, do_assembly_only): Add back a
16804 'gdbarch' parameter. Remove gdb_disassembler parameter.
16805 (gdb_disassembly): Don't allocate a gdb_disassembler here.
16806 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
16807 declaration.
16808 (gdb_pretty_print_insn): Re-add declaration.
16809 * record-btrace.c (btrace_insn_history): Don't allocate a
16810 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
16811
7a8eb317
SM
168122017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
16813
16814 * disasm.h (gdb_disassembly): Remove file_string parameter.
16815 * disasm.c (gdb_disassembly): Likewise.
16816 * cli/cli-cmds.c (print_disassembly): Adapt.
16817 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
16818 * stack.c (do_gdb_disassembly): Likewise.
16819
7346ef59
AA
168202017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
16821
16822 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
16823 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
16824 targets. And if the implicit value is longer than needed, extract
16825 the first bytes instead of the "least significant" ones.
16826
cd4007e4
MM
168272017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16828
16829 * btrace.c (btrace_enable): Do not call btrace_add_pc for
16830 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
16831 (btrace_fetch): Assert can_access_registers_ptid.
16832 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
16833 validate_registers_access.
16834
cf77c34e
MM
168352017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16836
16837 * gdbthread.h (can_access_registers_ptid): New.
16838 * thread.c (can_access_registers_ptid): New.
16839
be85ce7d
PA
168402017-02-01 Pedro Alves <palves@redhat.com>
16841
16842 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
16843
29b0b251
PA
168442017-01-31 Pedro Alves <palves@redhat.com>
16845
16846 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
16847 Fix typos.
16848
289b5b24
PA
168492017-01-31 Pedro Alves <palves@redhat.com>
16850
16851 * stack.c (print_frame_args): Remove local mem_fileopen stream,
16852 not used.
16853
b47413b4
PA
168542017-01-31 Pedro Alves <palves@redhat.com>
16855
16856 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
16857
60adb36c
PA
168582017-01-31 Pedro Alves <palves@redhat.com>
16859
16860 * common/scoped_restore.h
16861 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
16862 change the value's parameter type to T2.
16863 (make_scoped_restore): Likewise.
16864
2735833d
WT
168652017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16866 Richard Henderson <rth@redhat.com>
16867
16868 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
16869 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
16870 GS_BASE for older kernels.
16871 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
16872 GS_BASE for older kernels.
16873 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
16874 and GS_BASE to the offset table.
16875 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
16876 system register group.
16877 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
16878 for older kernels.
16879 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
16880 amd64 ABI.
16881 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
16882 AMD64_GSBASE_REGNUM.
16883 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
16884 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
16885 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
16886 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
16887 i386/64bit-segments.xml in those rules.
16888 * features/i386/64bit-segments.xml: New file.
16889 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
16890 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
16891 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
16892 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
16893 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
16894 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
16895 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
16896 * features/i386/amd64-avx-linux.c: Regenerated.
16897 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
16898 * features/i386/amd64-avx-mpx.c: Regenerated.
16899 * features/i386/amd64-avx512-linux.c: Regenerated.
16900 * features/i386/amd64-linux.c: Regenerated.
16901 * features/i386/amd64-mpx-linux.c: Regenerated.
16902 * features/i386/i386-avx-mpx-linux.c: Regenerated.
16903 * features/i386/i386-avx-mpx.c: Regenerated.
16904 * features/i386/x32-avx-linux.c: Regenerated.
16905 * features/i386/x32-avx512-linux.c: Regenerated.
16906 * regformats/i386/amd64-avx-linux.dat: Regenerated.
16907 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
16908 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
16909 * regformats/i386/amd64-linux.dat: Regenerated.
16910 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
16911 * regformats/i386/x32-avx-linux.dat: Regenerated.
16912 * regformats/i386/x32-avx512-linux.dat: Regenerated.
16913 * regformats/i386/x32-linux.dat: Regenerated.
16914
8884e97e
WT
169152017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16916
16917 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
16918 Set to AMD64_NUM_REGS.
16919
7005d26a
WT
169202017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16921
16922 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
16923 that checks validity of a register number.
16924
4bd2e1b2
KC
169252017-01-27 Kees Cook <keescook@google.com>
16926
16927 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
16928 fetch_fpregs if target has fpa registers.
16929 (arm_linux_store_inferior_registers): Call store_fpregs if target
16930 has fpa registers.
16931
7cf1de6c
AA
169322017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
16933
16934 * cris-tdep.c (cris_gdbarch_init): Remove check for
16935 info.byte_order and force it to BFD_ENDIAN_LITTLE.
16936
874a1c8c
AT
169372017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
16938
16939 * corelow.c (get_core_register_section): Check for regset
16940 existence before checking for REGSET_VARIABLE_SIZE.
16941
d8b49cf0
YQ
169422017-01-26 Yao Qi <yao.qi@linaro.org>
16943 Pedro Alves <palves@redhat.com>
16944
16945 PR gdb/20939
16946 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
16947 call memory_error, save memaddr instead.
16948 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
16949 negative, cal memory_error.
16950 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
16951
658ca58c
YQ
169522017-01-26 Yao Qi <yao.qi@linaro.org>
16953
16954 * disasm-selftests.c (memory_error_test): New function.
16955 (_initialize_disasm_selftests): Register memory_error_test.
16956
79843d45
YQ
169572017-01-26 Yao Qi <yao.qi@linaro.org>
16958
16959 * Makefile.in (SFILES): Add disasm-selftests.c and
16960 selftest-arch.c.
16961 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
16962 * disasm-selftests.c: New file.
16963 * selftest-arch.c: New file.
16964 * selftest-arch.h: New file.
16965
8cafda32
YQ
169662017-01-26 Yao Qi <yao.qi@linaro.org>
16967
16968 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
16969 to bfd_arch_mep. Don't return 0 if section is not
16970 found. Call print_insn_mep.
16971
e47ad6c0
YQ
169722017-01-26 Pedro Alves <palves@redhat.com>
16973 Yao Qi <yao.qi@linaro.org>
16974
16975 * arm-tdep.c: Include "disasm.h".
16976 (gdb_print_insn_arm): Update code to get gdbarch.
16977 * disasm.c (dis_asm_read_memory): Change it to
16978 gdb_disassembler::dis_asm_read_memory.
16979 (dis_asm_memory_error): Likewise.
16980 (dis_asm_print_address): Likewise.
16981 (gdb_pretty_print_insn): Change it to
16982 gdb_disassembler::pretty_print_insn.
16983 (dump_insns): Add one argument gdb_disassemlber. All
16984 callers updated.
16985 (do_mixed_source_and_assembly_deprecated): Likewise.
16986 (do_mixed_source_and_assembly): Likewise.
16987 (do_assembly_only): Likewise.
16988 (gdb_disassembler::gdb_disassembler): New.
16989 (gdb_disassembler::print_insn): New.
16990 * disasm.h (class gdb_disassembler): New.
16991 (gdb_pretty_print_insn): Remove declaration.
16992 (gdb_disassemble_info): Likewise.
16993 * guile/scm-disasm.c (class gdbscm_disassembler): New.
16994 (gdbscm_disasm_read_memory_worker): Update.
16995 (gdbscm_disasm_read_memory): Update.
16996 (gdbscm_disasm_memory_error): Remove.
16997 (gdbscm_disasm_print_address): Remove.
16998 (gdbscm_disassembler::gdbscm_disassembler): New.
16999 (gdbscm_print_insn_from_port): Update.
17000 * mips-tdep.c: Include disasm.h.
17001 (gdb_print_insn_mips): Update code to get gdbarch.
17002 * record-btrace.c (btrace_insn_history): Update.
17003 * spu-tdep.c: Include disasm.h.
17004 (struct spu_dis_asm_data): Remove.
17005 (struct spu_dis_asm_info): New.
17006 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
17007 SPU id.
17008 (gdb_print_insn_spu): Cast disassemble_info to
17009 spu_dis_asm_info.
17010
80d75874
YQ
170112017-01-26 Yao Qi <yao.qi@linaro.org>
17012
17013 * disasm.c (do_ui_file_delete): Delete.
17014 (gdb_insn_length): Move code creating stream to ...
17015 * utils.c (null_stream): ... here. New function.
17016 * utils.h (null_stream): Declare.
17017
60685cd0
SM
170182017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
17019
17020 * python/py-inferior.c (find_thread_object): Return directly
17021 from the loop. Remove "found" variable.
17022
eb1cdb62
JB
170232017-01-21 Joel Brobecker <brobecker@adacore.com>
17024
17025 GDB 7.12.1 released.
17026
b1ce6568
SM
170272017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17028
17029 * python/py-function.c (fnpy_call): Reorder declarations to have
17030 the gdbpy_enter object declared first.
17031 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
17032
6f8b0407
SM
170332017-01-20 Simon Marchi <simon.marchi@ericsson.com>
17034
fec93fb1 17035 PR python/21068
6f8b0407
SM
17036 * python/python-internal.h (PyMem_RawMalloc): Define for
17037 Python < 3.4.
17038 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
17039 PyMem_RawMalloc instead of PyMem_Malloc.
17040
78cbbba8
LM
170412017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
17042 Luis Machado <lgustavo@codesourcery.com>
17043
17044 * NEWS (New commands): Mention flash-erase.
17045 (New MI commands): Mention target-flash-erase.
17046 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
17047 command.
17048 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
17049 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
17050 * target.c (flash_erase_command): New function.
17051 (initialize_targets): Add new flash-erase command.
17052 * target.h (flash_erase_command): New declaration.
17053
2132fe85
JB
170542017-01-20 Joel Brobecker <brobecker@adacore.com>
17055
17056 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
17057 HAVE_SYS_PROCFS_H is defined.
17058
d1dff226
AH
170592017-01-18 Alan Hayward <alan.hayward@arm.com>
17060
17061 * remote.c (struct cached_reg): Change data into a pointer.
17062 * (stop_reply_dtr): Free data pointers before deleting vector.
17063 (process_stop_reply): Likewise.
17064 (remote_parse_stop_reply): Allocate space for data
17065
9890e433
AH
170662017-01-18 Alan Hayward <alan.hayward@arm.com>
17067
17068 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
17069 MAX_REGISTER_SIZE.
17070 (amd64_pseudo_register_read_value): Likewise.
17071 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
17072 (store_register_using_P): Likewise.
17073 * regcache.c (regcache_xfer_part): Likewise.
17074
7a36499a
IR
170752017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
17076
17077 Split real and pseudo registers.
17078 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
17079 (sparc32_pseudo_regnum): New enum.
17080 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
17081 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
17082 (SPARC32_CP0_REGISTERS): New macro.
17083 (sparc32_pseudo_register_name): New function.
17084 (sparc32_register_name): Use sparc32_pseudo_register_name.
17085 (sparc32_pseudo_register_type): New function.
17086 (sparc32_register_type): Use sparc32_pseudo_register_type.
17087 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
17088 pseudo register numbers.
17089 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
17090 (SPARC64_CP0_REGISTERS): New macro.
17091 (sparc64_pseudo_register_name): New function.
17092 (sparc64_register_name): Use sparc64_pseudo_register_name.
17093 (sparc64_pseudo_register_type): New function.
17094 (sparc64_register_type): Use sparc64_pseudo_register_type.
17095 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
17096 pseudo register numbers.
17097 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
17098 sparc64_store_arguments): Handle pseudo register numbers.
17099
6f8976bf
YQ
171002017-01-13 Yao Qi <yao.qi@linaro.org>
17101
17102 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
17103 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
17104 output.
17105 (getpkt_or_notif_sane_1): Likewise.
17106
e4241ace
YQ
171072017-01-13 Yao Qi <yao.qi@linaro.org>
17108
17109 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
17110 of CC. Pass "-x c++-header" instead of "-x c".
17111
3015c064
SM
171122017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17113
17114 * remote.c (remote_can_async_p): Update comment.
17115
fde1b17d
SM
171162017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17117
17118 * linux-nat.c (linux_nat_can_async_p): Update comment.
17119
ca1ca08b
SM
171202017-01-12 Simon Marchi <simon.marchi@ericsson.com>
17121
17122 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
17123
4ad2da73
SM
171242017-01-11 Simon Marchi <simon.marchi@ericsson.com>
17125
17126 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
17127
c8b23b3f
TT
171282017-01-10 Tom Tromey <tom@tromey.com>
17129
17130 * python/py-type.c (typy_legacy_template_argument): Update.
17131 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
17132 ~demangle_parse_info): Declare new members.
17133 (cp_demangled_name_to_comp): Return unique_ptr.
17134 (cp_demangled_name_parse_free)
17135 (make_cleanup_cp_demangled_name_parse_free)
17136 (cp_new_demangle_parse_info): Remove.
17137 * cp-support.c (do_demangled_name_parse_free_cleanup)
17138 (make_cleanup_cp_demangled_name_parse_free): Remove.
17139 (inspect_type, cp_canonicalize_string_full)
17140 (cp_canonicalize_string): Update.
17141 (mangled_name_to_comp): Change return type.
17142 (cp_class_name_from_physname, method_name_from_physname)
17143 (cp_func_name, cp_remove_params): Update.
17144 * cp-name-parser.y (demangle_parse_info): New constructor, from
17145 cp_new_demangle_parse_info.
17146 (~demangle_parse_info): New destructor, from
17147 cp_demangled_name_parse_free.
17148 (cp_merge_demangle_parse_infos): Update.
17149 (cp_demangled_name_to_comp): Change return type.
17150
1ac32117
TT
171512017-01-10 Tom Tromey <tom@tromey.com>
17152
17153 * top.c (prevent_dont_repeat): Change return type.
17154 * python/python.c (execute_gdb_command): Use std::string.
17155 Update.
17156 * guile/guile.c (gdbscm_execute_gdb_command): Update.
17157 * command.h (prevent_dont_repeat): Change return type.
17158 * breakpoint.c (bpstat_do_actions_1): Update.
17159
0cf08227
TT
171602017-01-10 Tom Tromey <tom@tromey.com>
17161
17162 * value.h (scoped_value_mark::~scoped_value_mark): Call
17163 free_to_mark.
17164 (scoped_value_mark::free_to_mark): New method.
17165 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
17166 scoped_value_mark.
17167
eb115069
TT
171682017-01-10 Tom Tromey <tom@tromey.com>
17169
17170 * python/py-value.c (valpy_dereference, valpy_referenced_value)
17171 (valpy_reference_value, valpy_const_value, valpy_get_address)
17172 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
17173 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
17174 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
17175 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
17176 scoped_value_mark.
17177 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
17178 * value.h (scoped_value_mark): New class.
17179
906768f9
TT
171802017-01-10 Tom Tromey <tom@tromey.com>
17181
17182 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
17183 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
17184 * psymtab.c (discard_psymtabs_upto): Remove.
17185 (make_cleanup_discard_psymtabs): Remove.
17186 (struct psymtab_state): Remove.
17187
bef155c3
TT
171882017-01-10 Tom Tromey <tom@tromey.com>
17189
17190 * record-full.c (record_full_save_cleanups): Remove.
17191 (record_full_save): Use gdb::unlinker.
17192 * gcore.c (do_bfd_delete_cleanup): Remove.
17193 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
17194 cleanups.
17195 * dwarf2read.c (unlink_if_set): Remove.
17196 (write_psymtabs_to_index): Use gdb::unlinker.
17197 * common/gdb_unlinker.h: New file.
17198
192b62ce
TT
171992017-01-10 Tom Tromey <tom@tromey.com>
17200
17201 * windows-tdep.c (windows_xfer_shared_library): Update.
17202 * windows-nat.c (windows_make_so): Update.
17203 * utils.h (make_cleanup_bfd_unref): Remove.
17204 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
17205 * symfile.h (symfile_bfd_open)
17206 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
17207 * symfile.c (read_symbols, symbol_file_add)
17208 (separate_debug_file_exists): Update.
17209 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
17210 (generic_load, reread_symbols): Update.
17211 * symfile-mem.c (symbol_file_add_from_memory): Update.
17212 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
17213 (spu_symbol_file_add_from_memory): Update.
17214 * solist.h (struct target_so_ops) <bfd_open>: Return
17215 gdb_bfd_ref_ptr.
17216 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
17217 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
17218 gdb_bfd_ref_ptr.
17219 (solib_map_sections, reload_shared_libraries_1): Update.
17220 * solib-svr4.c (enable_break): Update.
17221 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
17222 * solib-frv.c (enable_break2): Update.
17223 * solib-dsbt.c (enable_break): Update.
17224 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
17225 gdb_bfd_ref_ptr.
17226 (darwin_solib_get_all_image_info_addr_at_init): Update.
17227 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
17228 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
17229 * record-full.c (record_full_save): Update.
17230 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
17231 * procfs.c (insert_dbx_link_bpt_in_file): Update.
17232 * minidebug.c (find_separate_debug_file_in_section): Return
17233 gdb_bfd_ref_ptr.
17234 * machoread.c (macho_add_oso_symfile): Change abfd to
17235 gdb_bfd_ref_ptr.
17236 (macho_symfile_read_all_oso): Update.
17237 (macho_check_dsym): Return gdb_bfd_ref_ptr.
17238 (macho_symfile_read): Update.
17239 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
17240 (jit_bfd_try_read_symtab): Update.
17241 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17242 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17243 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17244 gdb_bfd_ref_ptr.
17245 (gdb_bfd_ref_policy): New struct.
17246 (gdb_bfd_ref_ptr): New typedef.
17247 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
17248 (gdb_bfd_openw, gdb_bfd_openr_iovec)
17249 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
17250 gdb_bfd_ref_ptr.
17251 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17252 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
17253 (gcore_command): Update.
17254 * exec.c (exec_file_attach): Update.
17255 * elfread.c (elf_symfile_read): Update.
17256 * dwarf2read.c (dwarf2_get_dwz_file): Update.
17257 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
17258 (open_and_init_dwo_file): Update.
17259 (open_dwp_file): Return gdb_bfd_ref_ptr.
17260 (open_and_init_dwp_file): Update.
17261 * corelow.c (core_open): Update.
17262 * compile/compile-object-load.c (compile_object_load): Update.
17263 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
17264 * coffread.c (coff_symfile_read): Update.
17265 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
17266 gdb_bfd_ref_ptr. Rename.
17267 (dump_bfd_file, restore_command): Update.
17268 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17269 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
17270 (find_separate_debug_file_by_buildid): Update.
17271
50315b21
TT
172722017-01-10 Tom Tromey <tom@tromey.com>
17273
17274 * common/gdb_ref_ptr.h: New file.
17275 * python/py-ref.h (struct gdbpy_ref_policy): New.
17276 (gdbpy_ref): Now a typedef.
17277
fc4007c9
TT
172782017-01-10 Tom Tromey <tom@tromey.com>
17279
17280 * utils.h (make_cleanup_htab_delete): Don't declare.
17281 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
17282 Remove.
17283 * linespec.c (decode_compound_collector): Add constructor,
17284 destructor.
17285 (lookup_prefix_sym): Remove cleanup.
17286 (symtab_collector): Add constructor, destructor.
17287 (collect_symtabs_from_filename): Remove cleanup.
17288 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
17289 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
17290 Use htab_up.
17291 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
17292 * dwarf2read.c (dw2_expand_symtabs_matching)
17293 (dw2_map_symbol_filenames, dwarf_decode_macros)
17294 (write_psymtabs_to_index): Use htab_up.
17295 * dwarf2loc.c (func_verify_no_selftailcall)
17296 (call_site_find_chain_1, func_verify_no_selftailcall)
17297 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
17298 std::vector, gdb::unique_xmalloc_ptr.
17299 (call_sitep): Remove typedef.
17300 (dwarf2_locexpr_baton_eval): Remove unused variable.
17301
8dbcee67
TT
173022017-01-10 Tom Tromey <tom@tromey.com>
17303
17304 * python/python-internal.h (make_cleanup_py_decref)
17305 (make_cleanup_py_xdecref): Don't declare.
17306 * python/py-utils.c (py_decref, make_cleanup_py_decref)
17307 (py_xdecref, make_cleanup_py_xdecref): Remove.
17308
13df46cc
TT
173092017-01-10 Tom Tromey <tom@tromey.com>
17310
17311 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
17312 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
17313
06fc9bf7
TT
173142017-01-10 Tom Tromey <tom@tromey.com>
17315
17316 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
17317
830a4934
TT
173182017-01-10 Tom Tromey <tom@tromey.com>
17319
17320 * python/py-utils.c (unicode_to_encoded_string)
17321 (python_string_to_target_string)
17322 (python_string_to_target_python_string)
17323 (python_string_to_host_string, gdbpy_obj_to_string)
17324 (get_addr_from_python): Use gdbpy_ref.
17325
4586d543
TT
173262017-01-10 Tom Tromey <tom@tromey.com>
17327
17328 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
17329 gdbpy_ref.
17330
59876f8f
TT
173312017-01-10 Tom Tromey <tom@tromey.com>
17332
17333 * python/python.c (eval_python_command, gdbpy_decode_line)
17334 (gdbpy_run_events, gdbpy_start_type_printers)
17335 (gdbpy_apply_type_printers): Use gdbpy_ref.
17336
97d83487
TT
173372017-01-10 Tom Tromey <tom@tromey.com>
17338
17339 * python/py-param.c (get_doc_string, compute_enum_values): Use
17340 gdbpy_ref.
17341
9205649a
TT
173422017-01-10 Tom Tromey <tom@tromey.com>
17343
17344 * python/py-inferior.c (find_thread_object, build_inferior_list):
17345 Use gdbpy_ref.
17346
74c49d45
TT
173472017-01-10 Tom Tromey <tom@tromey.com>
17348
17349 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17350
16361ffb
TT
173512017-01-10 Tom Tromey <tom@tromey.com>
17352
17353 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
17354 gdbpy_ref.
17355
905f2cca
TT
173562017-01-10 Tom Tromey <tom@tromey.com>
17357
17358 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
17359 extra incref.
17360 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
17361 Use gdbpy_ref.
17362
64081434
TT
173632017-01-10 Tom Tromey <tom@tromey.com>
17364
17365 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17366 gdbpy_ref.
17367
59e9e831
TT
173682017-01-10 Tom Tromey <tom@tromey.com>
17369
17370 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
17371 decref results of PyArg_ParseTupleAndKeywords.
17372
9de10f6d
TT
173732017-01-10 Tom Tromey <tom@tromey.com>
17374
17375 * python/python.c (python_run_simple_file): Use
17376 unique_xmalloc_ptr, gdbpy_ref.
17377
2bd5759d
TT
173782017-01-10 Tom Tromey <tom@tromey.com>
17379
17380 * python/py-prettyprint.c (print_stack_unless_memory_error)
17381 (print_string_repr, print_children): Use gdbpy_ref.
17382 (dummy_python_frame): New class.
17383 (dummy_python_frame::dummy_python_frame): Rename from
17384 push_dummy_python_frame.
17385 (py_restore_tstate): Remove.
17386
3b4e0e01
TT
173872017-01-10 Tom Tromey <tom@tromey.com>
17388
17389 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
17390
17a22718
TT
173912017-01-10 Tom Tromey <tom@tromey.com>
17392
17393 * python/python.c (ensure_python_env, restore_python_env):
17394 Remove.
17395 * python/python-internal.h (ensure_python_env): Don't declare.
17396 * varobj.h (varobj_ensure_python_env): Don't declare.
17397 * varobj.c (varobj_ensure_python_env): Remove.
17398
68cdc557
TT
173992017-01-10 Tom Tromey <tom@tromey.com>
17400
17401 * varobj.c (varobj_value_get_print_value): Use
17402 gdbpy_enter_varobj.
17403
1eba6383
TT
174042017-01-10 Tom Tromey <tom@tromey.com>
17405
17406 * python/py-prettyprint.c (print_string_repr, print_children):
17407 Update.
17408 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
17409 of "encoding".
17410 * varobj.c (varobj_value_get_print_value): Update.
17411 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
17412
bde7b3e3
TT
174132017-01-10 Tom Tromey <tom@tromey.com>
17414
17415 * varobj.c (varobj_get_display_hint)
17416 (dynamic_varobj_has_child_method, install_new_value_visualizer)
17417 (varobj_set_visualizer, free_variable): Use
17418 gdbpy_enter_varobj.
17419
a7785f8c
TT
174202017-01-10 Tom Tromey <tom@tromey.com>
17421
17422 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
17423 (do_finish_initialization): New function. Use gdbpy_ref.
17424 (gdbpy_finish_initialization): Use gdbpy_enter. Call
17425 do_finish_initialization.
17426
2865bfce
TT
174272017-01-10 Tom Tromey <tom@tromey.com>
17428
17429 * python/py-param.c (get_set_value, get_show_value): Use
17430 gdbpy_enter, gdbpy_ref.
17431
0e9dcc75
TT
174322017-01-10 Tom Tromey <tom@tromey.com>
17433
17434 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
17435
12a5cedd
TT
174362017-01-10 Tom Tromey <tom@tromey.com>
17437
17438 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
17439
788f2586
TT
174402017-01-10 Tom Tromey <tom@tromey.com>
17441
17442 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
17443 Use gdbpy_enter_varobj.
17444
6cd67bea
TT
174452017-01-10 Tom Tromey <tom@tromey.com>
17446
17447 * varobj.c (gdbpy_enter_varobj): New constructor.
17448 * python/python-internal.h (gdbpy_enter_varobj): New class.
17449 * python/py-varobj.c (py_varobj_get_iterator): Use
17450 gdbpy_enter_varobj.
17451
14b122bf
TT
174522017-01-10 Tom Tromey <tom@tromey.com>
17453
17454 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
17455 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17456 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
17457 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
17458 unique_xmalloc_ptr.
17459 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
17460
bf1ca3b9
TT
174612017-01-10 Tom Tromey <tom@tromey.com>
17462
17463 * python/py-xmethods.c (invoke_match_method): Use
17464 gdbpy_ref.
17465
572a5524
TT
174662017-01-10 Tom Tromey <tom@tromey.com>
17467
17468 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
17469 gdbpy_enter, gdbpy_ref.
17470
396a78b6
TT
174712017-01-10 Tom Tromey <tom@tromey.com>
17472
17473 * python/python.c (python_interactive_command): Use gdbpy_enter.
17474
a88b13c7
TT
174752017-01-10 Tom Tromey <tom@tromey.com>
17476
17477 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
17478 gdbpy_ref.
17479
e9f0c363
TT
174802017-01-10 Tom Tromey <tom@tromey.com>
17481
17482 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
17483 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17484
6349f452
TT
174852017-01-10 Tom Tromey <tom@tromey.com>
17486
17487 * utils.h (htab_deleter): New struct.
17488 (htab_up): New typedef.
17489 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
17490 gdbpy_enter, gdbpy_ref, htab_up.
17491
c0171de6
TT
174922017-01-10 Tom Tromey <tom@tromey.com>
17493
17494 * python/py-unwind.c (pending_frame_invalidate): Remove.
17495 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
17496
f18e226f
TT
174972017-01-10 Tom Tromey <tom@tromey.com>
17498
17499 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
17500 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
17501
c57af3f1
TT
175022017-01-10 Tom Tromey <tom@tromey.com>
17503
17504 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
17505
60e600ec
TT
175062017-01-10 Tom Tromey <tom@tromey.com>
17507
17508 * python/python.c (gdbpy_eval_from_control_command)
17509 (gdbpy_source_script, gdbpy_run_events)
17510 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
17511 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
17512 gdbpy_enter.
17513
bf7da5b0
TT
175142017-01-10 Tom Tromey <tom@tromey.com>
17515
17516 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
17517
2d38bced
TT
175182017-01-10 Tom Tromey <tom@tromey.com>
17519
17520 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
17521
07bc7329
TT
175222017-01-10 Tom Tromey <tom@tromey.com>
17523
17524 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
17525 (python_on_inferior_call_pre, python_on_inferior_call_post)
17526 (python_on_memory_change, python_on_register_change)
17527 (python_inferior_exit, python_new_objfile, add_thread_object)
17528 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
17529
6e7c365e
TT
175302017-01-10 Tom Tromey <tom@tromey.com>
17531
17532 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
17533 (bpfinishpy_handle_exit): Use gdbpy_enter.
17534
6ba0cd40
TT
175352017-01-10 Tom Tromey <tom@tromey.com>
17536
17537 * python/py-cmd.c (cmdpy_destroyer)
17538 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
17539 gdbpy_enter.
17540
de2dc875
TT
175412017-01-10 Tom Tromey <tom@tromey.com>
17542
17543 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17544 gdbpy_enter.
17545 (gdbpy_breakpoint_has_cond): Likewise.
17546
4ecee2c4
TT
175472017-01-10 Tom Tromey <tom@tromey.com>
17548
17549 * python/python.c (gdbpy_enter): New constructor.
17550 (~gdbpy_enter): New destructor.
17551 (restore_python_env, ensure_python_env): Rewrite.
17552 * python/python-internal.h (gdbpy_enter): New class.
17553
37fce74f
TT
175542017-01-10 Tom Tromey <tom@tromey.com>
17555
17556 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
17557
53a0cca3
TT
175582017-01-10 Tom Tromey <tom@tromey.com>
17559
17560 * python/py-value.c (value_has_field, get_field_flag)
17561 (get_field_type, valpy_getitem, convert_value_from_python): Use
17562 gdbpy_ref.
17563
ff3724f5
TT
175642017-01-10 Tom Tromey <tom@tromey.com>
17565
17566 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
17567 gdbpy_ref.
17568
0700aea5
TT
175692017-01-10 Tom Tromey <tom@tromey.com>
17570
17571 * python/py-prettyprint.c (search_pp_list)
17572 (find_pretty_printer_from_objfiles)
17573 (find_pretty_printer_from_progspace)
17574 (find_pretty_printer_from_gdb, find_pretty_printer)
17575 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
17576 gdbpy_ref.
17577
1bb44c9f
TT
175782017-01-10 Tom Tromey <tom@tromey.com>
17579
17580 * python/py-param.c (call_doc_function): Use gdbpy_ref.
17581
87ce03fd
TT
175822017-01-10 Tom Tromey <tom@tromey.com>
17583
17584 * python/py-linetable.c (build_line_table_tuple_from_pcs)
17585 (ltpy_get_all_source_lines): Use gdbpy_ref.
17586
ee0a3fb8
TT
175872017-01-10 Tom Tromey <tom@tromey.com>
17588
17589 * python/py-framefilter.c (extract_sym, extract_value)
17590 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
17591 gdbpy_ref.
17592
bf2a52fa
TT
175932017-01-10 Tom Tromey <tom@tromey.com>
17594
17595 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
17596
f59fe7f8
TT
175972017-01-10 Tom Tromey <tom@tromey.com>
17598
17599 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
17600
80bd970a
TT
176012017-01-10 Tom Tromey <tom@tromey.com>
17602
17603 * python/py-function.c (convert_values_to_python, fnpy_init): Use
17604 gdbpy_ref.
17605
d1b3de2e
TT
176062017-01-10 Tom Tromey <tom@tromey.com>
17607
17608 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
17609
3bb43384
TT
176102017-01-10 Tom Tromey <tom@tromey.com>
17611
17612 * python/py-type.c (convert_field, make_fielditem, typy_fields)
17613 (typy_range): Use gdbpy_ref.
17614
abf5651e
TT
176152017-01-10 Tom Tromey <tom@tromey.com>
17616
17617 * python/py-threadevent.c (create_thread_event_object): Use
17618 gdbpy_ref.
17619 * python/py-stopevent.c (create_stop_event_object): Simplify.
17620 (emit_stop_event): Use gdbpy_ref.
17621 * python/py-signalevent.c (create_signal_event_object): Use
17622 gdbpy_ref.
17623 * python/py-newobjfileevent.c (create_new_objfile_event_object)
17624 (emit_new_objfile_event, create_clear_objfiles_event_object)
17625 (emit_clear_objfiles_event): Use gdbpy_ref.
17626 * python/py-infevents.c (create_inferior_call_event_object)
17627 (create_register_changed_event_object)
17628 (create_memory_changed_event_object, emit_inferior_call_event)
17629 (emit_memory_changed_event, emit_register_changed_event): Use
17630 gdbpy_ref.
17631 * python/py-exitedevent.c (create_exited_event_object)
17632 (emit_exited_event): Use gdbpy_ref.
17633 * python/py-event.h (evpy_emit_event): Remove
17634 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
17635 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
17636 * python/py-continueevent.c (emit_continue_event): Use
17637 gdbpy_ref.
17638 * python/py-breakpoint.c (gdbpy_breakpoint_created)
17639 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
17640 gdbpy_ref.
17641 * python/py-bpevent.c (create_breakpoint_event_object): Use
17642 gdbpy_ref.
17643
a68ff33e
TT
176442017-01-10 Tom Tromey <tom@tromey.com>
17645
17646 * python/py-ref.h: New file.
17647
7becfd03
SM
176482017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17649
17650 * cli-out.c (cli_ui_out::do_redirect): Change return type to
17651 void.
17652 * cli-out.h (cli_ui_out::do_redirect): Likewise.
17653 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
17654 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
17655 * ui-out.c (ui_out::redirect): Likewise.
17656 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
17657 * cli/cli-logging.c (set_logging_redirect): Update call site of
17658 ui_out::redirect.
17659 (handle_redirections): Likewise.
17660 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
17661 * top.c (execute_command_to_string): Likewise.
17662 * utils.c (do_ui_out_redirect_pop): Likewise.
17663
df294654
SM
176642017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17665
17666 * stack.c (_initialize_stack): Update "frame" command help message.
17667
f5e6296e
IB
176682017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
17669
17670 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
17671
0e2d6fa6
YQ
176722017-01-06 Yao Qi <yao.qi@linaro.org>
17673
17674 * x86-linux-nat.h: Include gdb_proc_service.h.
17675
44d6d3f9
YQ
176762017-01-06 Yao Qi <yao.qi@linaro.org>
17677
17678 * ser-base.h: Include serial.h.
17679
656731fe
YQ
176802017-01-06 Yao Qi <yao.qi@linaro.org>
17681
17682 * ppc-linux-tdep.h: Include ppc-tdep.h.
17683
1ca8f924
YQ
176842017-01-06 Yao Qi <yao.qi@linaro.org>
17685
17686 * nat/amd64-linux-siginfo.h: Include signal.h.
17687
bc3008c4
YQ
176882017-01-06 Yao Qi <yao.qi@linaro.org>
17689
17690 * nat/aarch64-linux-hw-point.h: Include break-common.h.
17691
66c80d03
YQ
176922017-01-06 Yao Qi <yao.qi@linaro.org>
17693
17694 * mi/mi-parse.h: Include mi-cmds.h.
17695
051d2dda
YQ
176962017-01-06 Yao Qi <yao.qi@linaro.org>
17697
17698 * inf-loop.c: Don't include "target.h".
17699 * inf-loop.h: Include it here.
17700
8018d34f
YQ
177012017-01-06 Yao Qi <yao.qi@linaro.org>
17702
17703 * dfp.h: Include "dboulest.h" and "expression.h".
17704
c0b8369c
YQ
177052017-01-06 Yao Qi <yao.qi@linaro.org>
17706
17707 * ax-gdb.h: Include "ax.h".
17708
ad5cba2a
YQ
177092017-01-06 Yao Qi <yao.qi@linaro.org>
17710
17711 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
17712 with nat/gdb_ptrace.h.
17713
1c33cd7f
YQ
177142017-01-05 Yao Qi <yao.qi@linaro.org>
17715
17716 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
17717 new line.
17718 (mips64_fbsd_sigframe_init): Likewise.
17719
c988ac1d
JB
177202017-01-04 John Baldwin <jhb@FreeBSD.org>
17721
17722 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
17723 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
17724
b268007c
JB
177252017-01-04 John Baldwin <jhb@FreeBSD.org>
17726
17727 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
17728 * NEWS: Mention new FreeBSD/mips native configuration.
17729 * config/mips/fbsd.mh: New file.
17730 * configure.host: Add mips*-*-freebsd*.
17731 * mips-fbsd-nat.c: New file.
17732
387360da
JB
177332017-01-04 John Baldwin <jhb@FreeBSD.org>
17734
17735 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
17736 (ALLDEPFILES): Add mips-fbsd-tdep.c.
17737 * NEWS: Mention new FreeBSD/mips target.
17738 * configure.tgt: Add mips*-*-freebsd*.
17739 * mips-fbsd-tdep.c: New file.
17740 * mips-fbsd-tdep.h: New file.
17741
2aaaf250
YQ
177422017-01-04 Yao Qi <yao.qi@linaro.org>
17743
17744 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
17745 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
17746
61baf725
JB
177472017-01-01 Joel Brobecker <brobecker@adacore.com>
17748
6dbb839a 17749 Update copyright year range in all GDB files.
61baf725 17750
c113e7ff 177512017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 17752
c113e7ff 17753 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 17754
c113e7ff 17755For older changes see ChangeLog-2016.
c906108c
SS
17756\f
17757Local Variables:
17758mode: change-log
17759left-margin: 8
17760fill-column: 74
17761version-control: never
57da7796 17762coding: utf-8
c906108c 17763End: