Remove cleanup from mt-tdep.c
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-09-29 Tom Tromey <tom@tromey.com>
2
3 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
4
5 2017-09-29 Tom Tromey <tom@tromey.com>
6
7 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
8 gdb::byte_vector.
9
10 2017-09-29 Tom Tromey <tom@tromey.com>
11
12 * complaints.c (vcomplaint): Use std::string.
13
14 2017-09-29 Tom Tromey <tom@tromey.com>
15
16 * tracepoint.c (trace_variable_command): Use std::string.
17 (encode_actions_1): Remove unused declarations.
18 (create_tsv_from_upload): Use std::string.
19
20 2017-09-29 Tom Tromey <tom@tromey.com>
21
22 * cp-support.c (gdb_demangle): Use std::string.
23
24 2017-09-29 Tom Tromey <tom@tromey.com>
25
26 * stack.c (parse_frame_specification): Use std::string
27 (info_frame_command): Use gdb::unique_xmalloc_ptr.
28
29 2017-09-29 Tom Tromey <tom@tromey.com>
30
31 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
32
33 2017-09-29 Tom Tromey <tom@tromey.com>
34
35 * utils.c (vfprintf_maybe_filtered): Use std::string.
36 (vfprintf_unfiltered): Likewise.
37
38 2017-09-29 Tom Tromey <tom@tromey.com>
39
40 * event-top.c (top_level_prompt): Return std::string.
41 (display_gdb_prompt): Update.
42
43 2017-09-29 Tom Tromey <tom@tromey.com>
44
45 * unittests/common-utils-selftests.c (format): New function.
46 (string_vprintf_tests): New function.
47 (_initialize_common_utils_selftests): Register new tests.
48 * common/common-utils.c (string_vprintf): New function.
49 * common/common-utils.h (string_vprintf): Declare.
50
51 2017-09-29 Pedro Alves <palves@redhat.com>
52
53 * common/rsp-low.c (unpack_varlen_hex): Constify.
54 * common/rsp-low.h (unpack_varlen_hex): Constify.
55 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
56 Constify.
57 * remote.c (remote_set_permissions, read_ptid)
58 (remote_current_thread, remote_get_threads_with_qthreadinfo)
59 (remote_static_tracepoint_marker_at)
60 (remote_static_tracepoint_markers_by_strid)
61 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
62 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
63 (parse_tracepoint_definition, parse_tsv_definition)
64 (parse_static_tracepoint_marker_definition): Constify.
65 * tracepoint.h (parse_static_tracepoint_marker_definition)
66 (parse_trace_status, parse_tracepoint_status)
67 (parse_tracepoint_definition, parse_tsv_definition): Constify.
68
69 2017-09-29 Pedro Alves <palves@redhat.com>
70
71 * remote.c (target_buf, target_buf_size): Delete.
72 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
73 Use the connection's packet buffer instead.
74 All callers adjusted.
75 (_initialize_remote): Remove references to target_buf and
76 target_buf_size.
77
78 2017-09-28 Pedro Alves <palves@redhat.com>
79
80 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
81 unittests/common-utils-selftests.c.
82 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
83 (COMMON_OBS): Remove utils-selftests.o.
84 * utils-selftests.c: Move to ...
85 * unittests/common-utils-selftests.c: ... here and rename self
86 test to "string_printf".
87
88 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
89
90 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
91 having NULL cus or tus.
92
93 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
94
95 * arm-tdep.c: (convert_from_extended): Remove.
96 (convert_to_extended): Likewise.
97 (arm_extract_return_value): Use convert_typed_floating.
98 (arm_store_return_value): Likewise.
99
100 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
101 * sh-tdep.c: Do not include "floatformat.h".
102 (sh_littlebyte_bigword_type): New function.
103 (sh_register_convert_to_virtual): Use convert_typed_floating.
104 (sh_register_convert_to_raw): Likewise.
105 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
106 (sh64_littlebyte_bigword_type): New function.
107 (sh64_extract_return_value): Use convert_typed_floating.
108 (sh64_register_convert_to_virtual): Likewise.
109 (sh64_register_convert_to_raw): Likewise.
110
111 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
112
113 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
114 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
115
116 * gdbtypes.h (union type_specific): Make field floatformat hold
117 just a single struct floatformat, not an array.
118 (floatformat_from_type): Move here.
119 * gdbtypes.c (floatformat_from_type): Move here. Update to
120 changed TYPE_FLOATFORMAT definition.
121 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
122 (recursive_dump_type): Likewise.
123 (init_float_type): Install correct floatformat for byte order.
124 (arch_float_type): Likewise.
125
126 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
127
128 * gdbtypes.c (init_type): Change incoming argument from
129 length-in-bytes to length-in-bits. Assert length is a
130 multiple of TARGET_CHAR_BITS.
131 (arch_type, arch_flags_type): Likewise.
132 (init_integer_type): Update call to init_type.
133 (init_character_type): Likewise.
134 (init_boolean_type): Likewise.
135 (init_float_type): Likewise.
136 (init_decfloat_type): Likewise.
137 (init_complex_type): Likewise.
138 (init_pointer_type): Likewise.
139 (objfile_type): Likewise.
140 (arch_integer_type): Update call to arch_type.
141 (arch_character_type): Likewise.
142 (arch_boolean_type): Likewise.
143 (arch_float_type): Likewise.
144 (arch_decfloat_type): Likewise.
145 (arch_complex_type): Likewise.
146 (arch_pointer_type): Likewise.
147 (gdbtypes_post_init): Likewise.
148
149 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
150 (read_base_type): Likewise.
151 * mdebugread.c (basic_type): Likewise.
152 * stabsread.c (dbx_init_float_type): Likewise.
153 (rs6000_builtin_type): Likewise.
154 (read_range_type): Likewise. Also, fix call to init_integer_type
155 with erroneous length argument.
156
157 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
158 * d-lang.c (build_d_types): Likewise.
159 * f-lang.c (build_fortran_types): Likewise.
160 * go-lang.c (build_go_types): Likewise.
161 * opencl-lang.c (build_opencl_types): Likewise.
162 * jit.c (finalize_symtab): Likewise.
163 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
164 (build_std_type_info_type): Likewise.
165 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
166 update call to arch_flags_type.
167
168 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
169 arch_type.
170 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
171 * windows-tdep.c (windows_get_tlb_type): Likewise.
172
173 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
174 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
175 * m32c-tdep.c (make_types): Likewise.
176 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
177 (rl78_psw_type): Update call to arch_flags_type.
178 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
179 * rx-tdep.c (rx_psw_type): Likewise.
180 (rx_fpsw_type): Likewise.
181 * sparc-tdep.c (sparc_psr_type): Likewise.
182 (sparc_fsr_type): Likewise.
183 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
184 (sparc64_ccr_type): Likewise.
185 (sparc64_fsr_type): Likewise.
186 (sparc64_fprs_type): Likewise.
187
188 2017-09-27 Tom Tromey <tom@tromey.com>
189
190 * findcmd.c (find_command): Constify.
191
192 2017-09-27 Tom Tromey <tom@tromey.com>
193
194 * ada-tasks.c (task_command_1, task_command): Constify.
195
196 2017-09-27 Tom Tromey <tom@tromey.com>
197
198 * symtab.c (maintenance_print_symbol_cache)
199 (maintenance_flush_symbol_cache)
200 (maintenance_print_symbol_cache_statistics): Constify.
201
202 2017-09-27 Tom Tromey <tom@tromey.com>
203
204 * inferior.c (detach_inferior_command, kill_inferior_command)
205 (inferior_command): Constify.
206
207 2017-09-27 Tom Tromey <tom@tromey.com>
208
209 * regcache.c (regcache_print, maintenance_print_registers)
210 (maintenance_print_raw_registers)
211 (maintenance_print_cooked_registers)
212 (maintenance_print_register_groups)
213 (maintenance_print_remote_registers): Constify.
214
215 2017-09-27 Tom Tromey <tom@tromey.com>
216
217 * printcmd.c (map_display_numbers, undisplay_command)
218 (enable_disable_display_command, enable_display_command)
219 (disable_display_command): Constify.
220
221 2017-09-27 Tom Tromey <tom@tromey.com>
222
223 * breakpoint.h (delete_command): Don't declare.
224 * breakpoint.c (delete_command, enable_once_command)
225 (enable_count_command, enable_delete_command, breakpoint_1)
226 (maintenance_info_breakpoints, stopin_command, stopat_command)
227 (delete_command, delete_trace_command, save_breakpoints)
228 (save_breakpoints_command, save_tracepoints_command): Constify.
229
230 2017-09-27 Tom Tromey <tom@tromey.com>
231
232 * macrocmd.c (macro_expand_command, macro_expand_once_command)
233 (skip_ws, extract_identifier, macro_define_command)
234 (macro_undef_command, macro_list_command): Constify.
235
236 2017-09-27 Tom Tromey <tom@tromey.com>
237
238 * infcmd.c (environment_info, set_environment_command)
239 (unset_environment_command, path_info, info_proc_cmd_1)
240 (info_proc_cmd_mappings, info_proc_cmd_stat)
241 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
242 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
243
244 2017-09-27 Tom Tromey <tom@tromey.com>
245
246 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
247 Constify.
248
249 2017-09-27 Tom Tromey <tom@tromey.com>
250
251 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
252
253 2017-09-27 Tom Tromey <tom@tromey.com>
254
255 * demangle.c (demangle_command): Constify.
256
257 2017-09-27 Tom Tromey <tom@tromey.com>
258
259 * progspace.c (maintenance_info_program_spaces_command):
260 Constify.
261
262 2017-09-27 Tom Tromey <tom@tromey.com>
263
264 * compile/compile.c (check_raw_argument, compile_file_command)
265 (compile_code_command, compile_print_command): Constify.
266
267 2017-09-27 Tom Tromey <tom@tromey.com>
268
269 * reggroups.c (maintenance_print_reggroups): Constify.
270
271 2017-09-27 Tom Tromey <tom@tromey.com>
272
273 * dwarf2read.c (save_gdb_index_command): Constify.
274
275 2017-09-27 Tom Tromey <tom@tromey.com>
276
277 * stap-probe.c (info_probes_stap_command): Constify.
278
279 2017-09-27 Tom Tromey <tom@tromey.com>
280
281 * fork-child.c (unset_exec_wrapper_command): Constify.
282
283 2017-09-27 Tom Tromey <tom@tromey.com>
284
285 * btrace.c (get_uint, get_context_size, no_chunk)
286 (maint_btrace_packet_history_cmd)
287 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
288 (maint_info_btrace_cmd): Constify.
289
290 2017-09-27 Tom Tromey <tom@tromey.com>
291
292 * reverse.c (delete_bookmark_command): Constify.
293
294 2017-09-27 Tom Tromey <tom@tromey.com>
295
296 * remote.c (set_memory_packet_size)
297 (set_memory_write_packet_size, show_memory_write_packet_size)
298 (set_memory_read_packet_size, show_memory_read_packet_size)
299 (compare_sections_command, packet_command, remote_put_command)
300 (remote_get_command, remote_delete_command): Constify.
301
302 2017-09-27 Tom Tromey <tom@tromey.com>
303
304 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
305 (set_mipsfpu_double_command, set_mipsfpu_none_command)
306 (set_mipsfpu_auto_command): Constify.
307
308 2017-09-27 Tom Tromey <tom@tromey.com>
309
310 * cli/cli-cmds.h (cd_command): Constify.
311 * cli/cli-cmds.c (cd_command): Constify.
312
313 2017-09-27 Tom Tromey <tom@tromey.com>
314
315 * thread.c (thread_name_command, thread_find_command): Constify.
316
317 2017-09-27 Tom Tromey <tom@tromey.com>
318
319 * probe.c (enable_probes_command, disable_probes_command):
320 Constify.
321
322 2017-09-27 Tom Tromey <tom@tromey.com>
323
324 * symfile.c (symbol_file_command): Constify.
325 * gdbcore.h (deprecated_file_changed_hook): Constify.
326 * exec.c (deprecated_file_changed_hook, exec_file_command)
327 (file_command): Constify.
328 * defs.h (symbol_file_command): Constify.
329
330 2017-09-27 Tom Tromey <tom@tromey.com>
331
332 * remote-fileio.c (set_system_call_allowed)
333 (show_system_call_allowed): Constify.
334
335 2017-09-27 Tom Tromey <tom@tromey.com>
336
337 * tracepoint.c (delete_trace_variable_command)
338 (tfind_end_command, tfind_start_command, tfind_pc_command)
339 (tfind_tracepoint_command, tfind_line_command)
340 (tfind_range_command, tfind_outside_command): Constify.
341
342 2017-09-27 Tom Tromey <tom@tromey.com>
343
344 * ax-gdb.c (maint_agent_printf_command, agent_command)
345 (agent_eval_command): Constify.
346
347 2017-09-27 Tom Tromey <tom@tromey.com>
348
349 * tracepoint.c (info_scope_command): Constify.
350 * python/python.c (gdbpy_decode_line): Constify.
351 * python/py-breakpoint.c (bppy_init): Constify.
352 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
353 * location.h: (new_linespec_location)
354 (string_to_event_location_basic, string_to_event_location):
355 Constify.
356 * location.c (new_linespec_location)
357 (string_to_event_location_basic, string_to_event_location):
358 Constify.
359 * linespec.h (decode_line_with_current_source)
360 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
361 * linespec.c (linespec_lex_to_end)
362 (decode_line_with_current_source)
363 (decode_line_with_last_displayed): Constify.
364 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
365 Constify.
366 * cli/cli-cmds.c (edit_command, list_command): Constify.
367 * breakpoint.h (until_break_command, watch_command_wrapper)
368 (awatch_command_wrapper, rwatch_command_wrapper)
369 (init_ada_exception_breakpoint): Constify.
370 * breakpoint.c (break_command_1, dprintf_command)
371 (break_range_command, watch_command_wrapper)
372 (rwatch_command_wrapper, awatch_command_wrapper)
373 (until_break_command, init_ada_exception_breakpoint)
374 (strace_marker_create_sals_from_location, trace_command)
375 (ftrace_command, strace_command, struct tracepoint): Constify.
376 * ax-gdb.c (agent_command_1): Constify.
377 * ada-lang.c (ada_exception_sal): Constify.
378
379 2017-09-27 Tom Tromey <tom@tromey.com>
380
381 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
382 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
383 (get_context_size, no_chunk, get_insn_history_modifiers)
384 (cmd_record_insn_history, get_call_history_modifiers)
385 (cmd_record_call_history): Constify.
386
387 2017-09-27 Tom Tromey <tom@tromey.com>
388
389 * source.c (show_substitute_path_command)
390 (unset_substitute_path_command, set_substitute_path_command):
391 Constify.
392
393 2017-09-27 Tom Tromey <tom@tromey.com>
394
395 * typeprint.c (maintenance_print_type): Constify.
396 * maint.c (maintenance_dump_me, maintenance_demangle)
397 (maintenance_time_display, maintenance_info_sections)
398 (maintenance_print_statistics, maintenance_deprecate)
399 (maintenance_undeprecate): Constify.
400 (maintenance_do_deprecate): Constify. Use std::string.
401 (maintenance_selftest): Constify.
402 * gdbtypes.h (maintenance_print_type): Constify.
403
404 2017-09-27 Tom Tromey <tom@tromey.com>
405
406 * hppa-tdep.c (unwind_command): Constify.
407
408 2017-09-27 Tom Tromey <tom@tromey.com>
409
410 * target-descriptions.c (unset_tdesc_filename_cmd)
411 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
412 Constify.
413
414 2017-09-27 Tom Tromey <tom@tromey.com>
415
416 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
417
418 2017-09-27 Tom Tromey <tom@tromey.com>
419
420 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
421
422 2017-09-27 Tom Tromey <tom@tromey.com>
423
424 * tui/tui-regs.c (tui_reg_command): Constify.
425
426 2017-09-27 Tom Tromey <tom@tromey.com>
427
428 * skip.c (skip_file_command, skip_function_command)
429 (skip_enable_command, skip_disable_command, skip_delete_command):
430 Constify.
431
432 2017-09-27 Tom Tromey <tom@tromey.com>
433
434 * record-btrace.c (cmd_record_btrace_bts_start)
435 (cmd_record_btrace_pt_start): Constify.
436
437 2017-09-27 Tom Tromey <tom@tromey.com>
438
439 * symmisc.c (maintenance_print_symbols)
440 (maintenance_print_msymbols, maintenance_print_objfiles)
441 (maintenance_info_symtabs, maintenance_check_symtabs)
442 (maintenance_expand_symtabs, maintenance_info_line_tables):
443 Constify.
444
445 2017-09-27 Tom Tromey <tom@tromey.com>
446
447 * top.c (new_ui_command): Constify.
448
449 2017-09-27 Tom Tromey <tom@tromey.com>
450
451 * symfile.c (add_symbol_file_command)
452 (remove_symbol_file_command, list_overlays_command)
453 (map_overlay_command, unmap_overlay_command)
454 (overlay_auto_command, overlay_manual_command)
455 (overlay_off_command, overlay_load_command): Constify.
456
457 2017-09-27 Tom Tromey <tom@tromey.com>
458
459 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
460 (info_spu_mailbox_command, info_spu_dma_command)
461 (info_spu_proxydma_command): Constify.
462
463 2017-09-27 Tom Tromey <tom@tromey.com>
464
465 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
466
467 2017-09-27 Tom Tromey <tom@tromey.com>
468
469 * cli/cli-script.c (user_defined_command): Constify.
470
471 2017-09-27 Tom Tromey <tom@tromey.com>
472
473 * cli/cli-dump.c (dump_memory_command, dump_value_command)
474 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
475 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
476 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
477 (dump_binary_value, append_binary_memory, append_binary_value):
478 Constify.
479 (struct dump_context) <func>: Constify.
480 (add_dump_command): Update.
481
482 2017-09-27 Tom Tromey <tom@tromey.com>
483
484 * cli/cli-cmds.c (show_version, show_configuration)
485 (source_command, show_user): Constify.
486
487 2017-09-27 Tom Tromey <tom@tromey.com>
488
489 * target.c (maintenance_print_target_stack): Constify.
490
491 2017-09-27 Tom Tromey <tom@tromey.com>
492
493 * interps.c (interpreter_exec_cmd): Constify.
494
495 2017-09-27 Tom Tromey <tom@tromey.com>
496
497 * record-full.c (cmd_record_full_restore): Constify.
498
499 2017-09-27 Tom Tromey <tom@tromey.com>
500
501 * memattr.c (enable_mem_command, disable_mem_command)
502 (delete_mem_command): Constify.
503
504 2017-09-27 Tom Tromey <tom@tromey.com>
505
506 * value.c (show_convenience): Constify.
507
508 2017-09-27 Tom Tromey <tom@tromey.com>
509
510 * gdbcore.h (core_file_command): Update.
511 * corefile.c (core_file_command): Constify.
512
513 2017-09-27 Tom Tromey <tom@tromey.com>
514
515 * user-regs.c (maintenance_print_user_registers): Constify.
516
517 2017-09-27 Tom Tromey <tom@tromey.com>
518
519 * cp-namespace.c (maintenance_cplus_namespace): Constify.
520
521 2017-09-27 Tom Tromey <tom@tromey.com>
522
523 * cp-support.c (first_component_command): Constify.
524
525 2017-09-27 Tom Tromey <tom@tromey.com>
526
527 * psymtab.c (maintenance_print_psymbols)
528 (maintenance_info_psymtabs, maintenance_check_psymtabs):
529 Constify.
530
531 2017-09-27 Tom Tromey <tom@tromey.com>
532
533 * windows-tdep.c (display_tib): Constify.
534
535 2017-09-27 Tom Tromey <tom@tromey.com>
536
537 * linux-fork.c (delete_checkpoint_command)
538 (detach_checkpoint_command): Constify.
539
540 2017-09-27 Tom Tromey <tom@tromey.com>
541
542 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
543
544 2017-09-27 Tom Tromey <tom@tromey.com>
545
546 * arc-tdep.c (dump_arc_instruction_command): Constify.
547
548 2017-09-27 Tom Tromey <tom@tromey.com>
549
550 * valprint.c (set_radix, show_radix): Constify.
551
552 2017-09-27 Tom Tromey <tom@tromey.com>
553
554 * dtrace-probe.c (info_probes_dtrace_command): Constify.
555
556 2017-09-27 Tom Tromey <tom@tromey.com>
557
558 * command.h (not_just_help_class_command): Update.
559 * cli/cli-decode.h (not_just_help_class_command): Update.
560 * cli/cli-decode.c (not_just_help_class_command): Constify.
561
562 2017-09-27 Tom Tromey <tom@tromey.com>
563
564 * gdb_bfd.c (maintenance_info_bfds): Constify.
565
566 2017-09-27 Tom Tromey <tom@tromey.com>
567
568 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
569 overloads.
570 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
571 (do_const_cfunc): New function.
572 (cmd_cfunc_eq): New overload.
573 (cli_user_command_p): Check do_const_cfunc.
574 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
575 const_cfunc.
576 * command.h (add_cmd): Add const overload and no-function
577 overload.
578 (set_cmd_cfunc): Add const overload.
579 (cmd_const_cfunc_ftype): Declare.
580 (cmd_cfunc_eq): Add const overload.
581 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
582 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
583 overload.
584
585 2017-09-27 Tom Tromey <tom@tromey.com>
586
587 * macroexp.c (get_next_token_for_substitution): New function.
588 (substitute_args): Call it. Check for __VA_OPT__.
589
590 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
591 Pedro Alves <palves@redhat.com>
592
593 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
594 producer_is_icc_lt_14.
595 (producer_is_icc_lt_14): New function.
596 (check_producer): Add code for checking version of ICC.
597 (producer_is_icc): Move to producer.c.
598 (read_structure_type): Restrict ICC workaround to ICC<14.
599 * producer.c: Include selftest.h.
600 (producer_is_icc, producer_parsing_tests, _initialize_producer):
601 New functions.
602 * producer.h (producer_is_icc): New declaration.
603
604 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
605
606 * Makefile.in (SFILES): Add producer.c.
607 (COMMON_OBS): Add producer.o
608 * amd64-tdep.c (producer.h): Add new include.
609 * dwarf2read.c (producer.h): Add new include.
610 * producer.c: New file.
611 * producer.h: New file.
612 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
613 producer.c.
614 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
615 producer.h.
616
617 2017-09-26 Matthias Klose <doko@ubuntu.com>
618
619 * configure.ac: Search ncursesw before ncurses.
620 Check ncursesw/ncurses.h before ncurses/ncurses.h.
621 * gdb_curses.h: Include <ncursesw/ncurses.h>
622 * config.in, configure: Regenerate.
623
624 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
625
626 PR gdb/22185
627 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
628 obsolete.
629 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
630 Remove i386sol2 support.
631 * configure.nat <i386sol2>: Remove.
632 <sol2-64>: Fold into ...
633 <sol2>: ... this.
634 Move common settings to default section.
635 Add sol-thread.o.
636 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
637 x86_64-*-solaris2.1[0-9]*>: Rename to ...
638 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
639 <i[34567]86-*-solaris*>: Remove.
640 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
641
642 * configure.ac: Remove wctype in libw check.
643 (_MSE_INT_H): Don't define on Solaris 7-9.
644 <solaris*>: Remove libthread_db.so.1 check.
645 * configure: Regenerate.
646 * config.in: Regenerate.
647
648 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
649 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
650 (gdb_ps_size_t): Remove.
651 Use base types in users.
652 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
653
654 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
655
656 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
657
658 PR build/22206
659 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
660 (adi_is_addr_mapped): Likewise.
661 (PSR_ICC): Don't redefine.
662 (PSR_IMPL): Likewise.
663
664 2017-09-25 Tom Tromey <tom@tromey.com>
665
666 * regcache.c (regcache::dump): Use string_printf.
667
668 2017-09-25 Tom Tromey <tom@tromey.com>
669
670 * regcache.c (class regcache_invalidator): New.
671 (struct register_to_invalidate): Remove.
672 (make_cleanup_regcache_invalidate): Remove.
673 (regcache::raw_write): Use regcache_invalidator.
674
675 2017-09-25 Tom Tromey <tom@tromey.com>
676
677 * spu-tdep.c (spu2ppu_sniffer): Update.
678 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
679 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
680 Remove.
681 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
682 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
683 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
684 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
685 (frame_pop): Update.
686
687 2017-09-25 Tom Tromey <tom@tromey.com>
688
689 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
690 * regcache.h (regcache_xfree): Don't declare.
691 * regcache.c (regcache_xfree): Remove.
692 (do_regcache_xfree): Use delete.
693 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
694 * linux-fork.c (free_fork): Use delete.
695 (fork_save_infrun_state): Likewise.
696 * jit.c (jit_dealloc_cache): Use delete.
697 * infrun.c (discard_infcall_suspend_state): Use delete.
698
699 2017-09-25 Tom Tromey <tom@tromey.com>
700
701 * regcache.h (regcache_xmalloc): Don't declare.
702 (regcache_raw_set_cached_value): Update comment.
703 * regcache.c (regcache_xmalloc): Remove.
704 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
705 * jit.c (jit_frame_sniffer): Use new.
706 * frame.c (frame_save_as_regcache): Use new.
707
708 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
709
710 * NEWS: Advertise support for guarded-storage registers on IBM z.
711
712 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
713
714 * s390-linux-nat.c (have_regset_gs): New static variable.
715 (s390_linux_fetch_inferior_registers): Handle guarded-storage
716 control block and guarded-storage broadcast control regsets.
717 (s390_read_description): Detect whether the target has
718 guarded-storage support, return appropriate tdesc.
719 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
720 (features/s390x-gs-linux64.c): Likewise.
721 (struct gdbarch_tdep) <have_gs>: New field.
722 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
723 (s390_gsbc_regset): New variables.
724 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
725 and s390_gsbc_regset, if applicable.
726 (s390_core_read_description): Check whether core file was from a
727 target with guarded-storage support; include appropriate regsets.
728 (s390_gdbarch_init): Add registers for guarded-storage support.
729 (_initialize_s390_tdep): Initialize new target descriptions that
730 include registers for guarded-storage support.
731 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
732 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
733 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
734 (S390_NUM_REGS): Adjust macro definition.
735 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
736 (tdesc_s390x_gs_linux64): New declarations.
737
738 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
739
740 * features/s390-gs-linux64.xml: New file.
741 * features/s390-gs.xml: New file.
742 * features/s390-gsbc.xml: New file.
743 * features/s390x-gs-linux64.xml: New file.
744 * features/Makefile (WHICH): Add s390-gs-linux64 and
745 s390x-gs-linux64.
746 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
747 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
748 * features/s390-gs-linux64.c: New generated file.
749 * features/s390x-gs-linux64.c: New file.
750 * regformats/s390-gs-linux64.dat: New file.
751 * regformats/s390x-gs-linux64.dat: New file.
752
753 2017-09-23 Tom Tromey <tom@tromey.com>
754
755 * defs.h (make_cleanup_override_quit_handler): Don't declare.
756
757 2017-09-22 Tom Tromey <tom@tromey.com>
758
759 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
760 type to scoped_restore_tmpl.
761 <scoped_input_handler>: Initialize m_quit_handler directly.
762
763 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
764
765 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
766 (cd_command): Likewise. Free "current_directory" before
767 assigning to it.
768 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
769 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
770 * top.c (gdb_dirbuf): Remove global declaration.
771 * top.h (gdb_dirbuf): Likewise.
772
773 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
774
775 * gnulib/aclocal.m4: Regenerate.
776 * gnulib/config.in: Regenerate.
777 * gnulib/configure: Regenerate.
778 * gnulib/import/Makefile.am: Regenerate.
779 * gnulib/import/Makefile.in: Regenerate.
780 * gnulib/import/assure.h: New file.
781 * gnulib/import/at-func.c: Likewise
782 * gnulib/import/chdir-long.c: New file.
783 * gnulib/import/chdir-long.h: New file.
784 * gnulib/import/cloexec.c: New file.
785 * gnulib/import/cloexec.h: New file.
786 * gnulib/import/close.c: New file.
787 * gnulib/import/closedir.c: New file.
788 * gnulib/import/dirent-private.h: New file.
789 * gnulib/import/dup-safer.c: New file.
790 * gnulib/import/dup.c: New file.
791 * gnulib/import/dup2.c: New file.
792 * gnulib/import/error.c: New file.
793 * gnulib/import/error.h: New file.
794 * gnulib/import/exitfail.c: New file.
795 * gnulib/import/exitfail.h: New file.
796 * gnulib/import/fchdir.c: New file.
797 * gnulib/import/fcntl.c: New file.
798 * gnulib/import/fcntl.in.h: New file.
799 * gnulib/import/fd-hook.c: New file.
800 * gnulib/import/fd-hook.h: New file.
801 * gnulib/import/fd-safer.c: New file.
802 * gnulib/import/fdopendir.c: New file.
803 * gnulib/import/filename.h: New file.
804 * gnulib/import/filenamecat-lgpl.c: New file.
805 * gnulib/import/filenamecat.h: New file.
806 * gnulib/import/fstat.c: New file.
807 * gnulib/import/fstatat.c: New file.
808 * gnulib/import/getcwd-lgpl.c: New file.
809 * gnulib/import/getcwd.c: New file.
810 * gnulib/import/getdtablesize.c: New file.
811 * gnulib/import/getlogin_r.c: New file.
812 * gnulib/import/getprogname.c: New file.
813 * gnulib/import/getprogname.h: New file.
814 * gnulib/import/gettext.h: New file.
815 * gnulib/import/glob-libc.h: New file.
816 * gnulib/import/glob.c: New file.
817 * gnulib/import/glob.in.h: New file.
818 * gnulib/import/intprops.h: New file.
819 * gnulib/import/m4/chdir-long.m4: New file.
820 * gnulib/import/m4/close.m4: New file.
821 * gnulib/import/m4/closedir.m4: New file.
822 * gnulib/import/m4/d-ino.m4: New file.
823 * gnulib/import/m4/d-type.m4: New file.
824 * gnulib/import/m4/dup.m4: New file.
825 * gnulib/import/m4/dup2.m4: New file.
826 * gnulib/import/m4/error.m4: New file.
827 * gnulib/import/m4/fchdir.m4: New file.
828 * gnulib/import/m4/fcntl.m4: New file.
829 * gnulib/import/m4/fcntl_h.m4: New file.
830 * gnulib/import/m4/fdopendir.m4: New file.
831 * gnulib/import/m4/filenamecat.m4: New file.
832 * gnulib/import/m4/fstat.m4: New file.
833 * gnulib/import/m4/fstatat.m4: New file.
834 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
835 * gnulib/import/m4/getcwd-path-max.m4: New file.
836 * gnulib/import/m4/getcwd.m4: New file.
837 * gnulib/import/m4/getdtablesize.m4: New file.
838 * gnulib/import/m4/getlogin_r.m4: New file.
839 * gnulib/import/m4/getprogname.m4: New file.
840 * gnulib/import/m4/glob.m4: New file.
841 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
842 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
843 * gnulib/import/m4/mempcpy.m4: New file.
844 * gnulib/import/m4/memrchr.m4: New file.
845 * gnulib/import/m4/mode_t.m4: New file.
846 * gnulib/import/m4/msvc-inval.m4: New file.
847 * gnulib/import/m4/msvc-nothrow.m4: New file.
848 * gnulib/import/m4/open.m4: New file.
849 * gnulib/import/m4/openat.m4: New file.
850 * gnulib/import/m4/opendir.m4: New file.
851 * gnulib/import/m4/readdir.m4: New file.
852 * gnulib/import/m4/realloc.m4: New file.
853 * gnulib/import/m4/rewinddir.m4: New file.
854 * gnulib/import/m4/save-cwd.m4: New file.
855 * gnulib/import/m4/strdup.m4: New file.
856 * gnulib/import/m4/strerror.m4: New file.
857 * gnulib/import/m4/unistd-safer.m4: New file.
858 * gnulib/import/mempcpy.c: New file.
859 * gnulib/import/memrchr.c: New file.
860 * gnulib/import/msvc-inval.c: New file.
861 * gnulib/import/msvc-inval.h: New file.
862 * gnulib/import/msvc-nothrow.c: New file.
863 * gnulib/import/msvc-nothrow.h: New file.
864 * gnulib/import/open.c: New file.
865 * gnulib/import/openat-die.c: New file.
866 * gnulib/import/openat-priv.h: New file.
867 * gnulib/import/openat-proc.c: New file.
868 * gnulib/import/openat.c: New file.
869 * gnulib/import/openat.h: New file.
870 * gnulib/import/opendir.c: New file.
871 * gnulib/import/pipe-safer.c: New file.
872 * gnulib/import/readdir.c: New file.
873 * gnulib/import/realloc.c: New file.
874 * gnulib/import/rewinddir.c: New file.
875 * gnulib/import/save-cwd.c: New file.
876 * gnulib/import/save-cwd.h: New file.
877 * gnulib/import/strdup.c: New file.
878 * gnulib/import/strerror-override.c: New file.
879 * gnulib/import/strerror-override.h: New file.
880 * gnulib/import/strerror.c: New file.
881 * gnulib/import/unistd--.h: New file.
882 * gnulib/import/unistd-safer.h: New file.
883 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
884 "getcwd" and "glob".
885 * ser-tcp.c: Undefine "close" before redefining it.
886
887 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
888
889 * guile/scm-value.c (gdbscm_value_address): Initialize address,
890 get rid of res_val.
891
892 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
893
894 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
895 <sol2,sparc>: Likewise.
896 <sol2-64,i386>: Likewise.
897
898 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
899 -Wdeprecated-declarations on *-*-solaris*.
900 * configure: Regenerate.
901
902 * procfs.c: Include "nat/inferior.h".
903 (procfs_info_proc): Fix typo.
904
905 2017-09-21 Kevin Buettner <kevinb@redhat.com>
906
907 * remote.c (vector): Include.
908 (struct private_thread_info): Add field, thread_handle.
909 (free_private_thread_info): Deallocate storage associated with
910 thread handle.
911 (get_private_info_thread): Initialize `thread_handle' field.
912 (struct thread_item): Add field, thread_handle.
913 (clear_threads_listing_context): Deallocate storage associated
914 with thread handle.
915 (start_thread): Add support for "handle" attribute.
916 (thread_attributes): Add "handle".
917 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
918 field.
919 (remote_update_thread_list): Update thread_handle.
920 (remote_thread_handle_to_thread_info): New function.
921 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
922
923 2017-09-21 Kevin Buettner <kevinb@redhat.com>
924
925 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
926 function.
927 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
928 * python/python-internal.h (thread_object_type): Declare.
929
930 2017-09-21 Kevin Buettner <kevinb@redhat.com>
931
932 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
933 (target_thread_handle_to_thread_info): Declare.
934 * target.c (target_thread_handle_to_thread_info): New function.
935 * target-delegates.c: Regenerate.
936 * gdbthread.h (find_thread_by_handle): Declare.
937 * thread.c (find_thread_by_handle): New function.
938 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
939 function.
940 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
941
942 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
943
944 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
945
946 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
947
948 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
949
950 2017-09-21 Yao Qi <yao.qi@linaro.org>
951
952 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
953 to gdb_target_obs.
954
955 2017-09-20 Tom Tromey <tom@tromey.com>
956
957 * breakpoint.c (struct counted_command_line): Remove.
958 (breakpoint_commands): Update.
959 (alloc_counted_command_line, incref_counted_command_line)
960 (decref_counted_command_line, do_cleanup_counted_command_line)
961 (make_cleanup_decref_counted_command_line): Remove.
962 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
963 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
964 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
965 (save_breakpoints): Update.
966 * breakpoint.h (counted_command_line): Now a typedef to
967 shared_ptr.
968 (struct breakpoint) <commands>: Now a counted_command_line.
969 (struct bpstats) <command>: Likewise.
970
971 2017-09-20 Tom Tromey <tom@tromey.com>
972
973 * breakpoint.c (struct commands_info, do_map_commands_command):
974 Remove.
975 (commands_command_1): Update.
976 (iterate_over_related_breakpoints): Take a function_view.
977 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
978 (delete_command): Update.
979 (map_breakpoint_numbers): Take a function_view.
980 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
981 (disable_command): Update.
982 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
983 (enable_command): Update.
984 (struct disp_data, do_enable_breakpoint_disp)
985 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
986 (do_map_enable_delete_breakpoint): Remove.
987 (enable_once_command, enable_count_command, enable_delete_command)
988 (delete_trace_variable_command): Update.
989
990 2017-09-20 Tom Tromey <tom@tromey.com>
991
992 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
993 (bpstat_clear): Use delete.
994 (bpstats): New constructors.
995 (bpstat_copy, bpstat_stop_status): Use new.
996 (dprintf_after_condition_true): Update.
997 * breakpoint.h (bpstats::bpstats): Add constructors.
998 (bpstats::~bpstats): Add destructor.
999
1000 2017-09-20 Pedro Alves <palves@redhat.com>
1001
1002 * eval.c (make_params): Delete, refactored as ...
1003 (class fake_method): ... this new type's ctor.
1004 (fake_method::~fake_method): New.
1005 (evaluate_subexp_standard): Use 'fake_method'.
1006
1007 2017-09-20 Tom Tromey <tom@tromey.com>
1008
1009 * windows-nat.c (get_windows_debug_event, windows_wait)
1010 (do_initial_windows_stuff, windows_attach): Update.
1011 * utils.c (vwarning, internal_vproblem): Update.
1012 (ui_unregister_input_event_handler_cleanup)
1013 (prepare_to_handle_input): Remove.
1014 (class scoped_input_handler): New.
1015 (defaulted_query, prompt_for_continue): Update.
1016 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
1017 Update.
1018 * top.c (undo_terminal_modifications_before_exit): Update.
1019 * target/target.h (target_terminal_init, target_terminal_inferior)
1020 (target_terminal_ours): Don't declare.
1021 (class target_terminal): New.
1022 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
1023 (target_terminal_ours_for_output)
1024 (make_cleanup_restore_target_terminal): Don't declare.
1025 (target_terminal_info): Remove.
1026 * target.c (enum terminal_state, terminal_state): Remove.
1027 (target_terminal::terminal_state): Define.
1028 (target_terminal::init): Rename from target_terminal_init.
1029 (target_terminal::inferior): Rename from
1030 target_terminal_inferior.
1031 (target_terminal::ours): Rename from target_terminal_ours.
1032 (target_terminal::ours_for_output): Rename from
1033 target_terminal_ours_for_output.
1034 (target_terminal::info): New method.
1035 (cleanup_restore_target_terminal)
1036 (make_cleanup_restore_target_terminal): Remove.
1037 * solib.c (handle_solib_event): Update.
1038 * remote.c (remote_serial_quit_handler): Update.
1039 (remote_terminal_inferior, remote_wait_as): Update.
1040 * record-full.c (record_full_wait_1): Update.
1041 * nto-procfs.c (procfs_create_inferior): Update.
1042 * nat/fork-inferior.c (startup_inferior): Update.
1043 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
1044 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
1045 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
1046 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
1047 (mi_breakpoint_created, mi_breakpoint_deleted)
1048 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
1049 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
1050 (mi_user_selected_context_changed, report_initial_inferior):
1051 Update.
1052 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
1053 (linux_nat_terminal_inferior): Update.
1054 * infrun.c (follow_fork_inferior)
1055 (handle_vfork_child_exec_or_exit, do_target_resume)
1056 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
1057 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
1058 Update.
1059 * inflow.c (child_terminal_init, info_terminal_command): Update.
1060 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
1061 (attach_command): Update.
1062 * infcall.c (call_thread_fsm_should_stop): Update.
1063 * gnu-nat.c (gnu_attach): Update.
1064 * extension.c (struct active_ext_lang_state)
1065 (restore_active_ext_lang): Update.
1066 * exceptions.c (print_flush): Update.
1067 * event-top.c (async_enable_stdin, default_quit_handler): Update.
1068 (struct quit_handler_cleanup_data, restore_quit_handler)
1069 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
1070 Remove.
1071 * cp-support.c (gdb_demangle): Update.
1072 * breakpoint.c (update_inserted_breakpoint_locations)
1073 (insert_breakpoint_locations, handle_jit_event)
1074 (disable_breakpoints_in_unloaded_shlib): Update.
1075 * annotate.c (annotate_breakpoints_invalid)
1076 (annotate_frames_invalid): Update.
1077
1078 2017-09-20 Tom Tromey <tom@tromey.com>
1079
1080 * main.c (catch_command_errors): Rename from
1081 catch_command_errors_const.
1082 (captured_main_1): Update.
1083
1084 2017-09-20 Pedro Alves <palves@redhat.com>
1085
1086 * cli/cli-cmds.c (list_command): Use print_sal_location.
1087 (print_sal_location): New function.
1088 (ambiguous_line_spec): Use print_sal_location.
1089 * linespec.c (symbol_to_sal): Record the symbol in the sal.
1090 * symtab.c (find_function_start_sal): Likewise.
1091 * symtab.h (symtab_and_line::symbol): New field.
1092
1093 2017-09-20 Pedro Alves <palves@redhat.com>
1094
1095 * linespec.c (minsym_found): Handle non-text minsyms.
1096 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
1097
1098 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1099
1100 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
1101 backslash.
1102
1103 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1104
1105 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
1106 vmovups instead vmovaps.
1107 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
1108
1109 2017-09-19 John Baldwin <jhb@FreeBSD.org>
1110
1111 * NEWS (Changes since GDB 8.0): Add starti.
1112 * infcmd.c (enum run_break): New.
1113 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
1114 case.
1115 (run_command): Use enum run_how.
1116 (start_command): Likewise.
1117 (starti_command): New function.
1118 (RUN_ARGS_HELP): New macro.
1119 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
1120 commands. Add starti command.
1121
1122 2017-09-19 Yao Qi <yao.qi@linaro.org>
1123
1124 * Makefile.in (monitor.o): Remove the rule.
1125
1126 2017-09-19 Yao Qi <yao.qi@linaro.org>
1127
1128 * annotate.h (struct annotate_arg_emitter): Use
1129 DISABLE_COPY_AND_ASSIGN.
1130 * common/refcounted-object.h (refcounted_object): Likewise.
1131 * completer.h (struct completion_result): Likewise.
1132 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
1133 * filename-seen-cache.h (filename_seen_cache): Likewise.
1134 * gdbcore.h (thread_section_name): Likewise.
1135 * gdb_regex.h (compiled_regex): Likewise.
1136 * gdbthread.h (scoped_restore_current_thread): Likewise.
1137 * inferior.h (scoped_restore_current_inferior): Likewise.
1138 * jit.c (jit_reader): Likewise.
1139 * linespec.h (struct linespec_result): Likewise.
1140 * mi/mi-parse.h (struct mi_parse): Likewise.
1141 * nat/fork-inferior.c (execv_argv): Likewise.
1142 * progspace.h (scoped_restore_current_program_space): Likewise.
1143 * python/python-internal.h (class gdbpy_enter): Likewise.
1144 * regcache.h (regcache): Likewise.
1145 * target-descriptions.c (struct tdesc_reg): Likewise.
1146 (struct tdesc_type): Likewise.
1147 (struct tdesc_feature): Likewise.
1148 * ui-out.h (ui_out_emit_type): Likewise.
1149
1150 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
1151
1152 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
1153 label abort_expression.
1154
1155 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1156
1157 * common/buffer.c (buffer_xml_printf): Adjust.
1158 * common/xml-utils.c (xml_escape_text): Change return type to
1159 std::string, update code accordingly.
1160 * common/xml-utils.h (xml_escape_text): Change return type to
1161 std::string.
1162 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
1163 * windows-tdep.c (windows_xfer_shared_library): Adjust.
1164 * unittests/xml-utils-selftests.c (test_xml_escape_text):
1165 Adjust.
1166
1167 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1168
1169 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
1170 (SUBDIR_UNITTESTS_OBS): Add new object file.
1171 * unittests/xml-utils-selftests.c: New file.
1172
1173 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1174
1175 * common/selftest.h (selftest): New struct/interface.
1176 (register_test): Add name parameter, add new overload.
1177 (run_tests): Add filter parameter.
1178 (for_each_selftest_ftype): New typedef.
1179 (for_each_selftest): New declaration.
1180 * common/selftest.c (tests): Change type to
1181 map<string, unique_ptr<selftest>>.
1182 (simple_selftest): New struct.
1183 (register_test): New function.
1184 (register_test): Add name parameter and use it.
1185 (run_tests): Add filter parameter and use it. Add prints.
1186 Adjust to vector -> map change.
1187 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
1188 registering selftests.
1189 * arm-tdep.c (_initialize_arm_tdep): Likewise.
1190 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
1191 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
1192 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
1193 * findvar.c (_initialize_findvar): Likewise.
1194 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
1195 * maint.c (maintenance_selftest): Update call to run_tests.
1196 (maintenance_info_selftests): New function.
1197 (_initialize_maint_cmds): Register "maintenance info selftests"
1198 command. Update "maintenance selftest" doc.
1199 * regcache.c (_initialize_regcache): Add names when registering
1200 selftests.
1201 * rust-exp.y (_initialize_rust_exp): Likewise.
1202 * selftest-arch.c (gdbarch_selftest): New struct.
1203 (gdbarch_tests): Remove.
1204 (register_test_foreach_arch): Add name parameter. Call
1205 register_test.
1206 (tests_with_arch): Remove, move most content to
1207 gdbarch_selftest::operator().
1208 (_initialize_selftests_foreach_arch): Remove.
1209 * selftest-arch.h (register_test_foreach_arch): Add name
1210 parameter.
1211 (run_tests_with_arch): New declaration.
1212 * utils-selftests.c (_initialize_utils_selftests): Add names
1213 when registering selftests.
1214 * utils.c (_initialize_utils): Likewise.
1215 * unittests/array-view-selftests.c
1216 (_initialize_array_view_selftests): Likewise.
1217 * unittests/environ-selftests.c (_initialize_environ_selftests):
1218 Likewise.
1219 * unittests/function-view-selftests.c
1220 (_initialize_function_view_selftests): Likewise.
1221 * unittests/offset-type-selftests.c
1222 (_initialize_offset_type_selftests): Likewise.
1223 * unittests/optional-selftests.c
1224 (_initialize_optional_selftests): Likewise.
1225 * unittests/scoped_restore-selftests.c
1226 (_initialize_scoped_restore_selftests): Likewise.
1227 * NEWS: Document "maintenance selftest" and "maint info
1228 selftests".
1229
1230 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1231
1232 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
1233 scoped_restore.
1234
1235 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1236
1237 * mi/mi-main.c (mi_load_progress): Make uiout variable
1238 a unique_ptr.
1239
1240 2017-09-15 Pedro Alves <palves@redhat.com>
1241
1242 * compile/compile-c-types.c (convert_enum, convert_int)
1243 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
1244
1245 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1246
1247 * dwarf2read.c (copy_string): Remove.
1248 (parse_macro_definition): Replace copy_string with savestring.
1249
1250 2017-09-15 Yao Qi <yao.qi@linaro.org>
1251
1252 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
1253 gdb_target_obs.
1254 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
1255 Likewise.
1256 (i[34567]86-*-linux*): Likewise.
1257
1258 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1259
1260 * dwarf2expr.h (dwarf_stack_value): Add constructor.
1261 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
1262 <stack>: Change type to std::vector.
1263 <stack_len, stack_allocated>: Remove.
1264 <grow_stack>: Remove.
1265 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1266 (dwarf_expr_context::~dwarf_expr_context): Remove.
1267 (dwarf_expr_context::grow_stack): Remove.
1268 (dwarf_expr_context::push): Adjust.
1269 (dwarf_expr_context::pop): Adjust.
1270 (dwarf_expr_context::fetch): Adjust.
1271 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
1272 (dwarf_expr_context::stack_empty_p): Adjust.
1273 (dwarf_expr_context::execute_stack_op): Adjust.
1274
1275 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1276
1277 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
1278 return type to bool.
1279 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
1280
1281 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1282
1283 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
1284 Change type to bool.
1285 (dwarf_stack_value) <in_stack_memory>: Likewise.
1286 (dwarf_expr_context) <push_address>: Change parameter type to
1287 bool.
1288 <fetch_in_stack_memory>: Change return type to bool.
1289 <push>: Change parameter type to bool.
1290 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
1291 to bool.
1292 (dwarf_expr_context::push_address): Likewise.
1293 (dwarf_expr_context::fetch_in_stack_memory): Change return type
1294 to bool.
1295 (dwarf_expr_context::execute_stack_op): Adjust.
1296 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
1297
1298 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1299
1300 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
1301 (struct dwarf_expr_context) <n_pieces>: Remove.
1302 <pieces>: Change type to std::vector.
1303 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1304 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
1305 pieces.
1306 (dwarf_expr_context::add_piece): Adjust.
1307 * dwarf2loc.c (struct piece_closure): Initialize fields.
1308 <n_pieces>: Remove.
1309 <pieces>: Change type to std::vector.
1310 (allocate_piece_closure): Adjust, change parameter to
1311 std::vector rvalue and std::move it to piece_closure.
1312 (rw_pieced_value): Adjust.
1313 (check_pieced_synthetic_pointer): Adjust.
1314 (indirect_synthetic_pointer): Adjust.
1315 (coerce_pieced_ref): Adjust.
1316 (free_pieced_value_closure): Adjust. Use delete to free
1317 piece_closure.
1318 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
1319 to allocate_piece_closure.
1320 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
1321
1322 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1323
1324 * probe.h (probe_ops_cp): Remove typedef.
1325 (DEF_VEC_P (probe_ops_cp)): Remove.
1326 (all_probe_ops): Change type to std::vector.
1327 * probe.c (info_probes_for_ops): Adjust to vector change.
1328 (probe_linespec_to_ops): Likewise.
1329 (all_probe_ops): Change type to std::vector.
1330 (_initialize_probe): Adjust to vector change.
1331 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
1332 * elfread.c (elf_get_probes): Likewise.
1333 * stap-probe.c (_initialize_stap_probe): Likewise.
1334
1335 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1336
1337 * probe.h (struct bound_probe): Define constructors.
1338 * probe.c (bound_probe_s): Remove typedef.
1339 (DEF_VEC_O (bound_probe_s)): Remove VEC.
1340 (collect_probes): Change return type to std::vector, remove
1341 cleanup.
1342 (compare_probes): Return bool, change parameter type. Change
1343 semantic to "less than".
1344 (gen_ui_out_table_header_info): Change parameter to std::vector
1345 and update.
1346 (exists_probe_with_pops): Likewise.
1347 (info_probes_for_ops): Update to std::vector change.
1348 (enable_probes_command): Likewise.
1349 (disable_probes_command): Likewise.
1350
1351 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1352
1353 * probe.h (struct probe_ops) <get_probes>: Change parameter from
1354 vec to std::vector.
1355 * probe.c (parse_probes_in_pspace): Update.
1356 (find_probes_in_objfile): Update.
1357 (find_probe_by_pc): Update.
1358 (collect_probes): Update.
1359 (probe_any_get_probes): Update.
1360 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
1361 return type to reference to std::vector.
1362 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
1363 std::vector and update.
1364 (dtrace_process_dof): Likewise.
1365 (dtrace_get_probes): Likewise.
1366 * elfread.c (elf_get_probes): Change return type to std::vector,
1367 store an std::vector in bfd_data.
1368 (probe_key_free): Update to std::vector.
1369 * stap-probe.c (handle_stap_probe): Change parameter to
1370 std::vector and update.
1371 (stap_get_probes): Likewise.
1372 * symfile-debug.c (debug_sym_get_probes): Change return type to
1373 std::vector and update.
1374
1375 2017-09-11 Tom Tromey <tom@tromey.com>
1376
1377 * breakpoint.c (program_breakpoint_here_p): Update.
1378 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
1379 from make_show_memory_breakpoints_cleanup. Return a
1380 scoped_restore_tmpl<int>.
1381 (restore_show_memory_breakpoints): Remove.
1382 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
1383 * mem-break.c (memory_validate_breakpoint): Update.
1384 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
1385 (ia64_memory_remove_breakpoint): Update.
1386 (ia64_breakpoint_from_pc): Update.
1387 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
1388 from make_show_memory_breakpoints_cleanup.
1389
1390 2017-09-11 Tom Tromey <tom@tromey.com>
1391
1392 * d-namespace.c (d_lookup_symbol): Use std::string.
1393 (find_symbol_in_baseclass): Likewise.
1394
1395 2017-09-11 Tom Tromey <tom@tromey.com>
1396
1397 * ctf.c (ctf_start): Use std::string.
1398
1399 2017-09-11 Tom Tromey <tom@tromey.com>
1400
1401 * ada-lang.c (is_known_support_routine): Update.
1402 (ada_unhandled_exception_name_addr_from_raise): Update.
1403 * guile/scm-frame.c (gdbscm_frame_name): Update.
1404 * python/py-frame.c (frapy_name): Update.
1405 (frapy_function): Update.
1406 * stack.h (find_frame_funname): Update.
1407 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1408 (print_frame): Update.
1409
1410 2017-09-11 Tom Tromey <tom@tromey.com>
1411
1412 * findcmd.c (put_bits): Take a gdb::byte_vector.
1413 (parse_find_args): Return gdb::byte_vector. "args" now const.
1414 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1415 cleanups.
1416 (find_command): Update.
1417
1418 2017-09-11 Tom Tromey <tom@tromey.com>
1419
1420 * cli/cli-script.c (class scoped_restore_hook_in): New.
1421 (clear_hook_in_cleanup): Remove.
1422 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1423 scoped_restore_hook_in.
1424
1425 2017-09-11 Tom Tromey <tom@tromey.com>
1426
1427 * cli/cli-script.c (restore_interp): Remove.
1428 (read_command_lines): Use scoped_restore_interp.
1429 * interps.c (scoped_restore_interp::set_temp): Rename from
1430 interp_set_temp.
1431 * interps.h (class scoped_restore_interp): New.
1432 (interp_set_temp): Remove.
1433
1434 2017-09-11 Tom Tromey <tom@tromey.com>
1435
1436 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1437 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1438 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1439 scoped_restore.
1440 (mi_cmd_break_insert_1): Update.
1441 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1442 scoped_restore.
1443
1444 2017-09-11 Tom Tromey <tom@tromey.com>
1445
1446 * demangle.c (demangle_command): Update.
1447 * breakpoint.c (disable_command): Update.
1448 (enable_command): Update.
1449 (find_location_by_number): Make "number" const. Use
1450 get_number_trailer.
1451 * cli/cli-utils.c (extract_arg): Return std::string.
1452 * probe.c (parse_probe_linespec): Update. Change types.
1453 (collect_probes): Take string arguments.
1454 (parse_probe_linespec): Likewise.
1455 (info_probes_for_ops): Update.
1456 (enable_probes_command): Update.
1457 (disable_probes_command): Update.
1458 * break-catch-sig.c (catch_signal_split_args): Update.
1459 * mi/mi-parse.c (mi_parse): Update.
1460
1461 2017-09-11 Tom Tromey <tom@tromey.com>
1462
1463 * language.h (language_enum): Make argument const.
1464 * language.c (language_enum): Make argument const.
1465
1466 2017-09-11 Tom Tromey <tom@tromey.com>
1467
1468 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1469 as function.
1470 (skip_to_space): Rename from skip_to_space_const.
1471 * common/common-utils.c (skip_to_space): New function.
1472 (skip_to_space): Rename from skip_to_space_const.
1473 * cli/cli-utils.h (get_number): Rename from get_number_const.
1474 (extract_arg): Rename from extract_arg_const.
1475 * cli/cli-utils.c (get_number): Rename from get_number_const.
1476 (extract_arg): Rename from extract_arg_const.
1477 (number_or_range_parser::get_number): Use ::get_number.
1478 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1479 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1480 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1481 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1482 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1483 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1484 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1485 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1486
1487 2017-09-11 Tom Tromey <tom@tromey.com>
1488
1489 * python/python.c (do_start_initialization): Use
1490 py-event-types.def to initialize types.
1491 Define all object type structures.
1492 * python/python-internal.h: Don't declare event initialization
1493 functions.
1494 * python/py-threadevent.c (thread_event_object_type): Don't
1495 define.
1496 * python/py-stopevent.c (stop_event_object_type): Don't define.
1497 * python/py-signalevent.c (signal_event_object_type): Don't
1498 declare or define.
1499 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1500 (clear_objfiles_event_object_type): Don't declare or define.
1501 * python/py-infevents.c (inferior_call_pre_event_object_type)
1502 (inferior_call_post_event_object_type)
1503 (register_changed_event_object_type)
1504 (memory_changed_event_object_type): Don't declare or define.
1505 * python/py-inferior.c (new_thread_event_object_type)
1506 (new_inferior_event_object_type)
1507 (inferior_deleted_event_object_type): Don't declare or define.
1508 * python/py-exitedevent.c (exited_event_object_type): Don't
1509 declare or define.
1510 * python/py-evts.c (gdbpy_initialize_py_events): Use
1511 py-all-events.def.
1512 * python/py-events.h (thread_event_object_type): Don't declare.
1513 (events_object): Use py-all-events.def.
1514 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1515 py-event-types.def.
1516 * python/py-event-types.def: New file.
1517 * python/py-continueevent.c (create_continue_event_object): Don't
1518 declare or define.
1519 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1520 declare or define.
1521 * python/py-all-events.def: New file.
1522
1523 2017-09-11 Tom Tromey <tom@tromey.com>
1524
1525 * python/py-threadevent.c (create_thread_event_object): Return
1526 gdbpy_ref.
1527 * python/py-stopevent.h (create_stop_event_object)
1528 (create_breakpoint_event_object, create_signal_event_object):
1529 Update.
1530 * python/py-stopevent.c (create_stop_event_object): Return
1531 gdbpy_ref.
1532 (emit_stop_event): Update.
1533 * python/py-signalevent.c (create_signal_event_object): Return
1534 gdbpy_ref.
1535 * python/py-infevents.c (create_inferior_call_event_object):
1536 Update.
1537 * python/py-event.h (create_event_object)
1538 (create_thread_event_object): Update.
1539 * python/py-event.c (create_event_object): Return gdbpy_ref.
1540 * python/py-continueevent.c: Return gdbpy_ref.
1541 * python/py-bpevent.c (create_breakpoint_event_object): Return
1542 gdbpy_ref.
1543
1544 2017-09-11 Tom Tromey <tom@tromey.com>
1545
1546 PR python/15622:
1547 * NEWS: Add entry.
1548 * python/python.c (do_start_initialization): Initialize new event
1549 types.
1550 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1551 (gdbpy_initialize_inferior_deleted_event)
1552 (gdbpy_initialize_new_thread_event): Declare.
1553 * python/py-threadevent.c (create_thread_event_object): Add option
1554 "thread" parameter.
1555 * python/py-inferior.c (new_thread_event_object_type)
1556 (new_inferior_event_object_type)
1557 (inferior_deleted_event_object_type): Declare.
1558 (python_new_inferior, python_inferior_deleted): New functions.
1559 (add_thread_object): Emit new_thread event.
1560 (gdbpy_initialize_inferior): Attach new functions to corresponding
1561 observers.
1562 (new_thread, new_inferior, inferior_deleted): Define new event
1563 types.
1564 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1565 registries.
1566 * python/py-events.h (events_object) <new_inferior,
1567 inferior_deleted, new_thread>: New fields.
1568 * python/py-event.h (create_thread_event_breakpoint): Add optional
1569 "thread" parameter.
1570
1571 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1572
1573 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1574 check current_ui instead.
1575 (internal_vproblem): Likewise.
1576
1577 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1578
1579 * thread.c (print_thread_info_1): Remove unnecessary calls to
1580 uiout->is_mi_like_p.
1581
1582 2017-09-09 Tom Tromey <tom@tromey.com>
1583
1584 * namespace.h (add_using_directive): Update.
1585 * namespace.c (add_using_directive): Change type of excludes to
1586 std::vector.
1587 * dwarf2read.c (read_import_statement): Use std::vector.
1588 (read_namespace): Update.
1589 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1590
1591 2017-09-09 Tom Tromey <tom@tromey.com>
1592
1593 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1594
1595 2017-09-09 Tom Tromey <tom@tromey.com>
1596
1597 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1598
1599 2017-09-09 Tom Tromey <tom@tromey.com>
1600
1601 * stack.c (func_command): Use gdb::def_vector.
1602
1603 2017-09-09 Tom Tromey <tom@tromey.com>
1604
1605 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1606 ui_out_emit_list, ui_out_emit_tuple.
1607 (mi_cmd_var_update): Likewise.
1608
1609 2017-09-09 Tom Tromey <tom@tromey.com>
1610
1611 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1612 ui_out_redirect_pop.
1613 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1614 ui_out_redirect_pop.
1615 * utils.c (do_ui_out_redirect_pop)
1616 (make_cleanup_ui_out_redirect_pop): Remove.
1617 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1618 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1619 * ui-out.h (ui_out_redirect_pop): New class.
1620
1621 2017-09-09 Tom Tromey <tom@tromey.com>
1622
1623 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1624 (list_available_thread_groups, mi_cmd_list_thread_groups)
1625 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1626 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1627 Likewise.
1628
1629 2017-09-09 Tom Tromey <tom@tromey.com>
1630
1631 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1632 ui_out_emit_tuple.
1633
1634 2017-09-09 Tom Tromey <tom@tromey.com>
1635
1636 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1637 * stack.c (print_frame): Use ui_out_emit_tuple.
1638 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1639 (info_spu_mailbox_command, info_spu_dma_command)
1640 (info_spu_proxydma_command): Likewise.
1641 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1642 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1643 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1644 ui_out_emit_tuple.
1645 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1646
1647 2017-09-09 Tom Tromey <tom@tromey.com>
1648
1649 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1650 (class ui_out_emit_table): Update comment.
1651 * ui-out.c (do_cleanup_table_end)
1652 (make_cleanup_ui_out_table_begin_end): Remove.
1653 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1654 (info_spu_dma_cmdlist): Likewise.
1655 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1656 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1657 ui_out_emit_table.
1658
1659 2017-09-09 Tom Tromey <tom@tromey.com>
1660
1661 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1662 ui_out_emit_list, gdb::optional.
1663
1664 2017-09-09 John Baldwin <jhb@FreeBSD.org>
1665
1666 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1667 prototype.
1668 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1669 prototype.
1670 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1671 prototype.
1672 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1673 * ada-exp.y: Remove _initialize_ada_exp prototype.
1674 * ada-lang.c: Remove _initialize_ada_language prototype.
1675 * ada-tasks.c: Remove _initialize_tasks prototype.
1676 * addrmap.c: Remove _initialize_addrmap prototype.
1677 * agent.c: Remove _initialize_agent prototype.
1678 * aix-thread.c: Remove _initialize_aix_thread prototype.
1679 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
1680 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
1681 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
1682 prototype.
1683 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
1684 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
1685 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
1686 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
1687 prototype.
1688 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
1689 prototype.
1690 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
1691 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
1692 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
1693 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
1694 prototype.
1695 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
1696 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
1697 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
1698 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
1699 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1700 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
1701 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
1702 prototype.
1703 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
1704 prototype.
1705 * annotate.c: Remove _initialize_annotate prototype.
1706 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
1707 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
1708 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
1709 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
1710 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
1711 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
1712 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
1713 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
1714 prototype.
1715 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
1716 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
1717 * auto-load.c: Remove _initialize_auto_load prototype.
1718 * auxv.c: Remove _initialize_auxv prototype.
1719 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
1720 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
1721 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
1722 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
1723 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
1724 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
1725 prototype.
1726 * break-catch-throw.c: Remove _initialize_break_catch_throw
1727 prototype.
1728 * breakpoint.c: Remove _initialize_breakpoint prototype.
1729 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
1730 * btrace.c: Remove _initialize_btrace prototype.
1731 * charset.c: Remove _initialize_charset prototype.
1732 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
1733 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
1734 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
1735 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
1736 * cli/cli-script.c: Remove _initialize_cli_script prototype.
1737 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
1738 * coffread.c: Remove _initialize_coffread prototype.
1739 * compile/compile.c: Remove _initialize_compile prototype.
1740 * complaints.c: Remove _initialize_complaints prototype.
1741 * completer.c: Remove _initialize_completer prototype.
1742 * copying.awk: Remove _initialize_copying prototype.
1743 * copying.c: Regenerate.
1744 * core-regset.c: Remove _initialize_core_regset prototype.
1745 * corefile.c: Remove _initialize_core prototype.
1746 * corelow.c: Remove _initialize_corelow prototype.
1747 * cp-abi.c: Remove _initialize_cp_abi prototype.
1748 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
1749 * cp-support.c: Remove _initialize_cp_support prototype.
1750 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
1751 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
1752 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
1753 * ctf.c: Remove _initialize_ctf prototype.
1754 * d-lang.c: Remove _initialize_d_language prototype.
1755 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
1756 prototype.
1757 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
1758 * dbxread.c: Remove _initialize_dbxread prototype.
1759 * dcache.c: Remove _initialize_dcache prototype.
1760 * demangle.c: Remove _initialize_demangler prototype.
1761 * disasm-selftests.c: Remove _initialize_disasm_selftests
1762 prototype.
1763 * disasm.c: Remove _initialize_disasm prototype.
1764 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
1765 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
1766 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
1767 prototype.
1768 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
1769 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
1770 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
1771 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
1772 * elfread.c: Remove _initialize_elfread prototype.
1773 * exec.c: Remove _initialize_exec prototype.
1774 * extension.c: Remove _initialize_extension prototype.
1775 * f-lang.c: Remove _initialize_f_language prototype.
1776 * f-valprint.c: Remove _initialize_f_valprint prototype.
1777 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
1778 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
1779 * filesystem.c: Remove _initialize_filesystem prototype.
1780 * findcmd.c: Remove _initialize_mem_search prototype.
1781 * fork-child.c: Remove _initialize_fork_child prototype.
1782 * frame-base.c: Remove _initialize_frame_base prototype.
1783 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
1784 * frame.c: Remove _initialize_frame prototype.
1785 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
1786 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
1787 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
1788 * gcore.c: Remove _initialize_gcore prototype.
1789 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
1790 * gdbarch.c: Regenerate.
1791 * gdbarch.sh: Remove _initialize_gdbarch prototype.
1792 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
1793 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
1794 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
1795 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
1796 * go-lang.c: Remove _initialize_go_language prototype.
1797 * go32-nat.c: Remove _initialize_go32_nat prototype.
1798 * guile/guile.c: Remove _initialize_guile prototype.
1799 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
1800 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
1801 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
1802 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
1803 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
1804 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
1805 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
1806 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
1807 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
1808 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
1809 prototype.
1810 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
1811 prototype.
1812 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
1813 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
1814 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
1815 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
1816 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
1817 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
1818 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
1819 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
1820 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
1821 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
1822 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
1823 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
1824 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
1825 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1826 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
1827 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
1828 prototype.
1829 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
1830 prototype.
1831 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
1832 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
1833 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
1834 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
1835 * infcall.c: Remove _initialize_infcall prototype.
1836 * infcmd.c: Remove _initialize_infcmd prototype.
1837 * inferior.c: Remove _initialize_inferiors prototype.
1838 * inflow.c: Remove _initialize_inflow prototype.
1839 * infrun.c: Remove _initialize_infrun prototype.
1840 * interps.c: Remove _initialize_interpreter prototype.
1841 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
1842 * jit.c: Remove _initialize_jit prototype.
1843 * language.c: Remove _initialize_language prototype.
1844 * linux-fork.c: Remove _initialize_linux_fork prototype.
1845 * linux-nat.c: Remove _initialize_linux_nat prototype.
1846 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
1847 * linux-thread-db.c: Remove _initialize_thread_db prototype.
1848 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
1849 * m2-lang.c: Remove _initialize_m2_language prototype.
1850 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
1851 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
1852 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
1853 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
1854 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
1855 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1856 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1857 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
1858 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
1859 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
1860 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1861 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1862 * machoread.c: Remove _initialize_machoread prototype.
1863 * macrocmd.c: Remove _initialize_macrocmd prototype.
1864 * macroscope.c: Remove _initialize_macroscope prototype.
1865 * maint.c: Remove _initialize_maint_cmds prototype.
1866 * mdebugread.c: Remove _initialize_mdebugread prototype.
1867 * memattr.c: Remove _initialize_mem prototype.
1868 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
1869 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
1870 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
1871 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
1872 * mi/mi-main.c: Remove _initialize_mi_main prototype.
1873 * microblaze-linux-tdep.c: Remove
1874 _initialize_microblaze_linux_tdep prototype.
1875 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
1876 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
1877 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
1878 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
1879 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
1880 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
1881 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
1882 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
1883 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
1884 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
1885 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
1886 prototype.
1887 * mipsread.c: Remove _initialize_mipsread prototype.
1888 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
1889 prototype.
1890 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
1891 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
1892 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
1893 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
1894 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
1895 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
1896 prototype.
1897 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
1898 * nto-procfs.c: Remove _initialize_procfs prototype.
1899 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
1900 * objc-lang.c: Remove _initialize_objc_language prototype.
1901 * objfiles.c: Remove _initialize_objfiles prototype.
1902 * observer.c: Remove observer_test_first_notification_function,
1903 observer_test_second_notification_function,
1904 observer_test_third_notification_function, and
1905 _initialize_observer prototypes.
1906 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
1907 * osabi.c: Remove _initialize_gdb_osabi prototype.
1908 * osdata.c: Remove _initialize_osdata prototype.
1909 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
1910 * parse.c: Remove _initialize_parse prototype.
1911 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
1912 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
1913 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
1914 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
1915 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
1916 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
1917 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
1918 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
1919 * printcmd.c: Remove _initialize_printcmd prototype.
1920 * probe.c: Remove _initialize_probe prototype.
1921 * proc-api.c: Remove _initialize_proc_api prototype.
1922 * proc-events.c: Remove _initialize_proc_events prototype.
1923 * proc-service.c: Remove _initialize_proc_service prototype.
1924 * procfs.c: Remove _initialize_procfs prototype.
1925 * psymtab.c: Remove _initialize_psymtab prototype.
1926 * python/python.c: Remove _initialize_python prototype.
1927 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
1928 * record-btrace.c: Remove _initialize_record_btrace prototype.
1929 * record-full.c: Remove _initialize_record_full prototype.
1930 * record.c: Remove _initialize_record prototype.
1931 * regcache.c: Remove _initialize_regcache prototype.
1932 * reggroups.c: Remove _initialize_reggroup prototype.
1933 * remote-notif.c: Remove _initialize_notif prototype.
1934 * remote-sim.c: Remove _initialize_remote_sim prototype.
1935 * remote.c: Remove _initialize_remote prototype.
1936 * reverse.c: Remove _initialize_reverse prototype.
1937 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
1938 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
1939 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
1940 prototype.
1941 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
1942 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
1943 * rust-exp.y: Remove _initialize_rust_exp prototype.
1944 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
1945 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
1946 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
1947 * score-tdep.c: Remove _initialize_score_tdep prototype.
1948 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
1949 prototype.
1950 * ser-go32.c: Remove _initialize_ser_dos prototype.
1951 * ser-mingw.c: Remove _initialize_ser_windows prototype.
1952 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
1953 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
1954 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
1955 * serial.c: Remove _initialize_serial prototype.
1956 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
1957 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
1958 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
1959 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
1960 * skip.c: Remove _initialize_step_skip prototype.
1961 * sol-thread.c: Remove _initialize_sol_thread prototype.
1962 * solib-aix.c: Remove _initialize_solib_aix prototype.
1963 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
1964 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
1965 * solib-frv.c: Remove _initialize_frv_solib prototype.
1966 * solib-spu.c: Remove _initialize_spu_solib prototype.
1967 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
1968 * solib-target.c: Remove _initialize_solib_target prototype.
1969 * solib.c: Remove _initialize_solib prototype.
1970 * source.c: Remove _initialize_source prototype.
1971 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
1972 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
1973 prototype.
1974 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
1975 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
1976 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
1977 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
1978 prototype.
1979 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
1980 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
1981 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
1982 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
1983 prototype.
1984 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
1985 prototype.
1986 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
1987 prototype.
1988 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
1989 prototype.
1990 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
1991 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
1992 prototype.
1993 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
1994 prototype.
1995 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
1996 prototype.
1997 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
1998 prototype.
1999 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
2000 prototype.
2001 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
2002 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
2003 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
2004 * stabsread.c: Remove _initialize_stabsread prototype.
2005 * stack.c: Remove _initialize_stack prototype.
2006 * stap-probe.c: Remove _initialize_stap_probe prototype.
2007 * std-regs.c: Remove _initialize_frame_reg prototype.
2008 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
2009 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
2010 * symfile.c: Remove _initialize_symfile prototype.
2011 * symmisc.c: Remove _initialize_symmisc prototype.
2012 * symtab.c: Remove _initialize_symtab prototype.
2013 * target-dcache.c: Remove _initialize_target_dcache prototype.
2014 * target-descriptions.c: Remove _initialize_target_descriptions
2015 prototype.
2016 * thread.c: Remove _initialize_thread prototype.
2017 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
2018 prototype.
2019 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
2020 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
2021 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
2022 prototype.
2023 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
2024 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
2025 * tracefile.c: Remove _initialize_tracefile prototype.
2026 * tracepoint.c: Remove _initialize_tracepoint prototype.
2027 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
2028 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
2029 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
2030 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
2031 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
2032 * tui/tui-win.c: Remove _initialize_tui_win prototype.
2033 * tui/tui.c: Remove _initialize_tui prototype.
2034 * typeprint.c: Remove _initialize_typeprint prototype.
2035 * user-regs.c: Remove _initialize_user_regs prototype.
2036 * utils.c: Remove _initialize_utils prototype.
2037 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
2038 * valarith.c: Remove _initialize_valarith prototype.
2039 * valops.c: Remove _initialize_valops prototype.
2040 * valprint.c: Remove _initialize_valprint prototype.
2041 * value.c: Remove _initialize_values prototype.
2042 * varobj.c: Remove _initialize_varobj prototype.
2043 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
2044 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
2045 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
2046 * windows-nat.c: Remove _initialize_windows_nat,
2047 _initialize_check_for_gdb_ini, and _initialize_loadable
2048 prototypes.
2049 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
2050 * xcoffread.c: Remove _initialize_xcoffread prototype.
2051 * xml-support.c: Remove _initialize_xml_support prototype.
2052 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
2053 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
2054 prototype.
2055 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
2056 prototype.
2057 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
2058
2059 2017-09-08 Keith Seitz <keiths@redhat.com>
2060
2061 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
2062 field.
2063
2064 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
2065
2066 * f-valprint.c (f_val_print): Remove check for one byte
2067 sized integers. Remove printing of character type.
2068
2069 2017-09-08 Frank Penczek <frank.penczek@intel.com>
2070 Christoph Weinmann <christoph.t.weinmann@intel.com>
2071 Bernhard Heckel <bernhard.heckel@intel.com>
2072
2073 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
2074 to maintain proper indentation when printing pointers/refs.
2075
2076 2017-09-07 Joel Brobecker <brobecker@adacore.com>
2077
2078 GDB 8.0.1 released.
2079
2080 2017-09-07 Joel Brobecker <brobecker@adacore.com>
2081
2082 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
2083
2084 2017-09-05 Tom Tromey <tom@tromey.com>
2085
2086 * parse.c (funcall_chain): Now a std::vector.
2087 (start_arglist, end_arglist): Simplify.
2088 (free_funcalls): Remove.
2089 (parse_exp_in_context_1): Remove cleanup.
2090
2091 2017-09-05 Tom Tromey <tom@tromey.com>
2092
2093 * go-exp.y (go_parse): Don't create a cleanup.
2094
2095 2017-09-05 Tom Tromey <tom@tromey.com>
2096
2097 * d-exp.y (PrimaryExpression): Use std::string.
2098 (d_parse): Don't create a cleanup.
2099
2100 2017-09-05 Tom Tromey <tom@tromey.com>
2101
2102 * utils.c (do_clear_parser_state): Remove.
2103 (make_cleanup_clear_parser_state): Remove.
2104 * p-exp.y (pascal_parse): Use scoped_restore.
2105 * m2-exp.y (m2_parse): Use scoped_restore.
2106 * f-exp.y (f_parse): Use scoped_restore.
2107 * d-exp.y (d_parse): Use scoped_restore.
2108 * c-exp.y (c_parse): Use scoped_restore.
2109 * ada-exp.y (ada_parse): Use scoped_restore.
2110 * utils.h (make_cleanup_clear_parser_state): Remove.
2111
2112 2017-09-06 Keith Seitz <keiths@redhat.com>
2113
2114 * dwarf2read.c (dw2_linkage_name_attr): New function.
2115 (dw2_linkage_name): New function.
2116 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
2117 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
2118 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
2119
2120 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2121
2122 * config/djgpp/djconfig.sh: Correct shell portability issue.
2123
2124 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2125
2126 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
2127
2128 2017-09-06 John Baldwin <jhb@FreeBSD.org>
2129
2130 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
2131 * NEWS: Mention new FreeBSD/mips native configuration.
2132 * configure.host: Add aarch64*-*-freebsd*.
2133 * configure.nat: Likewise.
2134 * aarch64-fbsd-nat.c: New file.
2135
2136 2017-09-06 John Baldwin <jhb@FreeBSD.org>
2137
2138 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
2139 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
2140 * NEWS: Mention new FreeBSD/aarch64 target.
2141 * configure.tgt: Add aarch64*-*-freebsd*.
2142 * aarch64-fbsd-tdep.c: New file.
2143 * aarch64-fbsd-tdep.h: New file.
2144
2145 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2146
2147 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
2148
2149 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
2150
2151 * parse.c (find_minsym_type_and_address): Don't relocate addresses
2152 of TLS symbols.
2153
2154 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2155
2156 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
2157 call.
2158
2159 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2160
2161 * infrun.c (follow_exec): Call add_thread after
2162 target_find_description.
2163
2164 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2165
2166 * infrun.c (handle_inferior_event_1): When exec'ing, read
2167 stop_pc after follow_exec.
2168
2169 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2170
2171 * remote.c (process_g_packet): Update error message.
2172
2173 2017-09-05 Yao Qi <yao.qi@linaro.org>
2174
2175 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
2176 targets.
2177
2178 2017-09-05 Pedro Alves <palves@redhat.com>
2179
2180 * eval.c (eval_call, evaluate_funcall): New functions, factored
2181 out from ...
2182 (evaluate_subexp_standard): ... this.
2183
2184 2017-09-05 Yao Qi <yao.qi@linaro.org>
2185
2186 * amd64-tdep.c (amd64_target_description): Create target
2187 descriptions.
2188 (_initialize_amd64_tdep): Don't call functions
2189 initialize_tdesc_amd64_*. Add self tests.
2190 * arch/amd64.c (amd64_create_target_description): Add parameter
2191 is_linux. Call set_tdesc_osabi if is_linux is true.
2192 * arch/amd64.h (amd64_create_target_description): Update the
2193 declaration.
2194 * arch/i386.c (i386_create_target_description): Add parameter
2195 is_linux. Call set_tdesc_osabi if is_linux is true.
2196 * arch/i386.h (i386_create_target_description): Update
2197 declaration.
2198 * configure.tgt: Add i386.o to gdb_target_obs.
2199 * features/Makefile (XMLTOC): Remove i386/*.xml.
2200 * features/i386/amd64-avx-avx512.c: Remove.
2201 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
2202 * features/i386/amd64-avx-mpx.c: Remove.
2203 * features/i386/amd64-avx.c: Remove.
2204 * features/i386/amd64-mpx.c: Remove.
2205 * features/i386/amd64.c: Remove.
2206 * features/i386/i386-avx-avx512.c: Remove.
2207 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
2208 * features/i386/i386-avx-mpx.c: Remove.
2209 * features/i386/i386-avx.c: Remove.
2210 * features/i386/i386-mmx.c: Remove.
2211 * features/i386/i386-mpx.c: Remove.
2212 * features/i386/i386.c: Remove.
2213 * i386-tdep.c: Don't include features/i386/i386*.c., include
2214 target-descriptions.h and arch/i386.h.
2215 (i386_target_description): Create target descriptions.
2216 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
2217 functions. Do self tests.
2218
2219 2017-09-05 Yao Qi <yao.qi@linaro.org>
2220
2221 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
2222 * features/i386/amd64-avx-avx512-linux.c: Removed.
2223 * features/i386/amd64-avx-linux.c: Removed.
2224 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
2225 * features/i386/amd64-avx-mpx-linux.c: Removed.
2226 * features/i386/amd64-linux.c: Removed.
2227 * features/i386/amd64-mpx-linux.c: Removed.
2228 * features/i386/x32-avx-avx512-linux.c: Removed.
2229 * features/i386/x32-avx-linux.c: Removed.
2230 * features/i386/x32-linux.c: Removed.
2231
2232 2017-09-05 Yao Qi <yao.qi@linaro.org>
2233
2234 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
2235 features/i386/*.c.
2236 (amd64_linux_read_description): Call
2237 amd64_create_target_description.
2238 * arch/amd64.c: New file.
2239 * arch/amd64.h: New file.
2240 * configure.tgt (x86_64-*-linux*): Append amd64.o.
2241 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
2242
2243 2017-09-05 Yao Qi <yao.qi@linaro.org>
2244
2245 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
2246 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
2247 (amd64_linux_read_description): Create target descriptions.
2248 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
2249 functions. Add unit tests.
2250 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
2251 x32-core.xml.
2252 * features/i386/64bit-avx.c: Generated.
2253 * features/i386/64bit-avx512.c: Generated.
2254 * features/i386/64bit-core.c: Generated.
2255 * features/i386/64bit-linux.c: Generated.
2256 * features/i386/64bit-mpx.c: Generated.
2257 * features/i386/64bit-pkeys.c: Generated.
2258 * features/i386/64bit-segments.c: Generated.
2259 * features/i386/64bit-sse.c: Generated.
2260 * features/i386/x32-core.c: Generated.
2261 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
2262 c files for amd64-linux and x32-linux.
2263
2264 2017-09-05 Yao Qi <yao.qi@linaro.org>
2265
2266 * amd64-linux-tdep.c (amd64_linux_read_description): New
2267 function.
2268 (amd64_linux_core_read_description): Call
2269 amd64_linux_read_description.
2270 (amd64_linux_init_abi): Likewise.
2271 (amd64_x32_linux_init_abi): Likewise.
2272 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
2273 * x86-linux-nat.c (x86_linux_read_description): Call
2274 amd64_linux_read_description.
2275
2276 2017-09-05 Yao Qi <yao.qi@linaro.org>
2277
2278 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
2279 comments.
2280
2281 2017-09-05 Yao Qi <yao.qi@linaro.org>
2282
2283 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
2284 * features/i386/i386-avx-avx512-linux.c: Remove.
2285 * features/i386/i386-avx-linux.c: Remove.
2286 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
2287 * features/i386/i386-avx-mpx-linux.c: Remove.
2288 * features/i386/i386-linux.c: Remove.
2289 * features/i386/i386-mmx-linux.c: Remove.
2290 * features/i386/i386-mpx-linux.c: Remove.
2291
2292 2017-09-05 Yao Qi <yao.qi@linaro.org>
2293
2294 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
2295 (SFILES): Add arch/i386.c.
2296 (HFILES_NO_SRCDIR): Add arch/i386.h.
2297 * arch/i386.c: New file.
2298 * arch/i386.h: New file.
2299 * arch/tdesc.h (allocate_target_description): Declare.
2300 (set_tdesc_architecture): Declare.
2301 (set_tdesc_osabi): Declare.
2302 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
2303 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
2304 include arch/i386.h.
2305 (i386_linux_read_description): Remove code and call
2306 i386_create_target_description.
2307 (set_tdesc_architecture): New function.
2308 (set_tdesc_osabi): New function.
2309 * target-descriptions.h (allocate_target_description): Remove.
2310
2311 2017-09-05 Yao Qi <yao.qi@linaro.org>
2312
2313 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
2314 * target-descriptions.c (tdesc_create_feature): Likewise, and
2315 adjust code.
2316 * features/i386/32bit-avx.c: Re-generated.
2317 * features/i386/32bit-avx512.c: Re-generated.
2318 * features/i386/32bit-core.c: Re-generated.
2319 * features/i386/32bit-linux.c: Re-generated.
2320 * features/i386/32bit-mpx.c: Re-generated.
2321 * features/i386/32bit-pkeys.c: Re-generated.
2322 * features/i386/32bit-sse.c: Re-generated.
2323
2324 2017-09-05 Yao Qi <yao.qi@linaro.org>
2325
2326 * regformats/regdef.h (struct reg): Override operator == and !=.
2327
2328 2017-09-05 Yao Qi <yao.qi@linaro.org>
2329
2330 * arch/tdesc.h: New file.
2331 * regformats/regdat.sh: Generate code using tdesc_create_reg.
2332 * target-descriptions.c: Update comments.
2333 * target-descriptions.h: Include "arch/tdesc.h". Remove the
2334 declarations.
2335 * features/i386/32bit-avx.c: Re-generated.
2336 * features/i386/32bit-avx512.c: Re-generated.
2337 * features/i386/32bit-core.c: Re-generated.
2338 * features/i386/32bit-linux.c: Re-generated.
2339 * features/i386/32bit-mpx.c: Re-generated.
2340 * features/i386/32bit-pkeys.c: Re-generated.
2341 * features/i386/32bit-sse.c: Re-generated.
2342
2343 2017-09-05 Yao Qi <yao.qi@linaro.org>
2344
2345 * regformats/regdat.sh: Update generated code.
2346
2347 2017-09-05 Yao Qi <yao.qi@linaro.org>
2348
2349 * regformats/regdat.sh: Adjust code order.
2350
2351 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2352
2353 * expprint.c (dump_subexp_body_standard): Use constant format
2354 string in fprintf_filtered call.
2355
2356 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2357
2358 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
2359 NetBSD/i386.
2360 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
2361
2362 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2363
2364 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
2365
2366 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2367
2368 * bsd-kvm.o: Define _KMEMUSER.
2369 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
2370 * configure: Regenerate.
2371
2372 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2373
2374 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
2375 * i386-fbsd-nat.c: Likewise.
2376
2377 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2378
2379 * unittests/array-view-selftests.c: Add include of <array>.
2380
2381 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2382
2383 * spu-tdep.c (flush_ea_cache): Add missing argument to
2384 call_function_by_hand.
2385
2386 2017-09-04 Pedro Alves <palves@redhat.com>
2387
2388 * NEWS (Safer support for debugging with no debug info): New.
2389
2390 2017-09-04 Pedro Alves <palves@redhat.com>
2391
2392 * c-exp.y (function_method, function_method_void): Add current
2393 instance flags to TYPE_INSTANCE.
2394 * dwarf2read.c (check_modifier): New.
2395 (compute_delayed_physnames): Assert that only C++ adds delayed
2396 physnames. Mark fn_fields as const/volatile depending on
2397 physname.
2398 * eval.c (make_params): New type_instance_flags parameter. Use
2399 it as the new type's instance flags.
2400 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2401 flags element and pass it to make_params.
2402 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2403 instance flags element.
2404 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2405 * gdbtypes.h: Include "enum-flags.h".
2406 (type_instance_flags): New enum-flags type.
2407 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2408 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2409 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2410 (follow_type_instance_flags): New function.
2411 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2412 * parser-defs.h (follow_type_instance_flags): Declare.
2413 * valops.c (value_struct_elt_for_reference): const/volatile must
2414 match too.
2415
2416 2017-09-04 Pedro Alves <palves@redhat.com>
2417
2418 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2419 function/method scopes; lookup the nested name as a function local
2420 static variable.
2421
2422 2017-09-04 Pedro Alves <palves@redhat.com>
2423
2424 (%type <voidval>): Add function_method.
2425 * c-exp.y (exp): New production for calls with no arguments.
2426 (function_method, function_method_void_or_typelist): New
2427 productions.
2428 (exp): New production for "method()::static_var".
2429 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2430 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2431 Handle OP_FUNC_STATIC_VAR.
2432 * parse.c (operator_length_standard):
2433 Handle OP_FUNC_STATIC_VAR.
2434
2435 2017-09-04 Pedro Alves <palves@redhat.com>
2436
2437 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2438 handling.
2439 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2440 Ditto.
2441 * parse.c (operator_length_standard, operator_check_standard):
2442 Ditto.
2443 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2444
2445 2017-09-04 Pedro Alves <palves@redhat.com>
2446
2447 * ax-gdb.c: Include "typeprint.h".
2448 (gen_expr_for_cast): New function.
2449 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2450 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2451 type is unknown.
2452 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2453 nodebug_data_symbol.
2454 * eval.c: Include "typeprint.h".
2455 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2456 Error out if symbol has unknown type.
2457 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2458 evaluate_subexp_for_cast.
2459 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2460 OP_VAR_MSYM_VALUE.
2461 (evaluate_subexp_for_cast): New function.
2462 * gdbtypes.c (init_nodebug_var_type): New function.
2463 (objfile_type): Use it to initialize types of variables with no
2464 debug info.
2465 * typeprint.c (error_unknown_type): New.
2466 * typeprint.h (error_unknown_type): New declaration.
2467 * compile/compile-c-types.c (convert_type_basic): Handle
2468 TYPE_CODE_ERROR; warn and fallback to int for variables with
2469 unknown type.
2470
2471 2017-09-04 Pedro Alves <palves@redhat.com>
2472
2473 * eval.c (evaluate_var_value): New function, factored out from ...
2474 (evaluate_subexp_standard): ... here.
2475
2476 2017-09-04 Pedro Alves <palves@redhat.com>
2477
2478 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2479 Remove useless assignments to 'op'.
2480
2481 2017-09-04 Pedro Alves <palves@redhat.com>
2482
2483 * eval.c (eval_skip_value): New function.
2484 (evaluate_subexp_standard): Use it.
2485
2486 2017-09-04 Pedro Alves <palves@redhat.com>
2487
2488 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2489 function name from symbol/minsym and pass it to
2490 error_call_unknown_return_type.
2491
2492 2017-09-04 Pedro Alves <palves@redhat.com>
2493
2494 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2495 * ax-gdb.c (gen_msym_var_ref): New function.
2496 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2497 * eval.c (evaluate_var_msym_value): New function.
2498 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2499 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2500 to call_function_by_hand.
2501 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2502 Handle OP_VAR_MSYM_VALUE.
2503 (union exp_element) <msymbol>: New field.
2504 * minsyms.h (struct type): Forward declare.
2505 (find_minsym_type_and_address): Declare.
2506 * parse.c (write_exp_elt_msym): New function.
2507 (write_exp_msymbol): Delete, refactored as ...
2508 (find_minsym_type_and_address): ... this new function.
2509 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2510 (operator_length_standard, operator_check_standard): Handle
2511 OP_VAR_MSYM_VALUE.
2512 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2513
2514 2017-09-04 Pedro Alves <palves@redhat.com>
2515
2516 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2517 TYPE_GNU_IFUNC specially here. Throw error if return type is
2518 unknown.
2519 * ada-typeprint.c (print_func_type): Handle functions with unknown
2520 return type.
2521 * c-typeprint.c (c_type_print_base): Handle functions and methods
2522 with unknown return type.
2523 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2524 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2525 * compile/compile-c-types.c: Include "objfiles.h".
2526 (convert_func): For functions with unknown return type, warn and
2527 default to int.
2528 * compile/compile-object-run.c (compile_object_run): Adjust call
2529 to call_function_by_hand_dummy.
2530 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2531 call_function_by_hand.
2532 * eval.c (evaluate_subexp_standard): Adjust calls to
2533 call_function_by_hand. Handle functions and methods with unknown
2534 return type. Pass expect_type to call_function_by_hand.
2535 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2536 return type.
2537 * gcore.c (call_target_sbrk): Adjust call to
2538 call_function_by_hand.
2539 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2540 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2541 an integer address type instead of nodebug.
2542 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2543 call_function_by_hand.
2544 * infcall.c (error_call_unknown_return_type): New function.
2545 (call_function_by_hand): New "default_return_type" parameter.
2546 Pass it down.
2547 (call_function_by_hand_dummy): New "default_return_type"
2548 parameter. Use it instead of defaulting to int. If there's no
2549 default and the return type is unknown, throw an error. If
2550 there's a default return type, and the called function has no
2551 debug info, then assume the function is prototyped.
2552 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2553 New "default_return_type" parameter.
2554 (error_call_unknown_return_type): New declaration.
2555 * linux-fork.c (call_lseek): Cast return type of lseek.
2556 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2557 call_function_by_hand.
2558 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2559 calls to call_function_by_hand.
2560 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2561 return type.
2562 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2563 (value_nsstring, print_object_command): Adjust calls to
2564 call_function_by_hand.
2565 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2566 functions with unknown return type.
2567 (pascal_type_print_func_varspec_suffix): New function.
2568 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2569 TYPE_CODE_METHOD>: Use it.
2570 * python/py-value.c (valpy_call): Adjust call to
2571 call_function_by_hand.
2572 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2573 call_function_by_hand.
2574 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2575 call_function_by_hand.
2576 * valops.c (value_allocate_space_in_inferior): Adjust call to
2577 call_function_by_hand.
2578 * typeprint.c (type_print_unknown_return_type): New function.
2579 * typeprint.h (type_print_unknown_return_type): New declaration.
2580
2581 2017-09-04 Pedro Alves <palves@redhat.com>
2582
2583 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2584 types with more than one parameter as prototyped.
2585
2586 2017-09-04 Pedro Alves <palves@redhat.com>
2587
2588 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2589 (disassemble_command): Use gdb_disassembly_flags instead of bare
2590 int.
2591 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2592 (dump_insns, do_mixed_source_and_assembly_deprecated)
2593 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2594 Use gdb_disassembly_flags instead of bare int.
2595 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2596 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2597 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2598 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2599 (enum gdb_disassembly_flag): ... values of this new enumeration.
2600 (gdb_disassembly_flags): Define.
2601 (gdb_disassembly)
2602 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2603 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2604 gdb_disassembly_flags instead of bare int.
2605 * record-btrace.c (btrace_insn_history)
2606 (record_btrace_insn_history, record_btrace_insn_history_range)
2607 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2608 instead of bare int.
2609 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2610 Use gdb_disassembly_flags instead of bare int.
2611 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2612 Define.
2613 * target-delegates.c: Regenerate.
2614 * target.c (target_insn_history, target_insn_history_from)
2615 (target_insn_history_range): Use gdb_disassembly_flags instead of
2616 bare int.
2617 * target.h: Include "disasm.h".
2618 (struct target_ops) <to_insn_history, to_insn_history_from,
2619 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2620 int.
2621 (target_insn_history, target_insn_history_from)
2622 (target_insn_history_range): Use gdb_disassembly_flags instead of
2623 bare int.
2624
2625 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2626
2627 * cli/cli-script.c (build_command_line): For if/while commands,
2628 check whether args is empty.
2629
2630 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2631
2632 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2633 (enum command_control_type): Likewise.
2634 (struct command_line): Likewise.
2635 (free_command_lines): Likewise.
2636 (struct command_lines_deleter): Likewise.
2637 (command_line_up): Likewise.
2638 (read_command_lines): Likewise.
2639 (read_command_lines_1): Likewise.
2640 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2641 (enum command_control_type): Likewise.
2642 (struct command_line): Likewise.
2643 (free_command_lines): Likewise.
2644 (struct command_lines_deleter): Likewise.
2645 (command_line_up): Likewise.
2646 (read_command_lines): Likewise.
2647 (read_command_lines_1): Likewise.
2648 * breakpoint.h: Include cli/cli-script.h.
2649 * extension-priv.h: Likewise.
2650 * gdbcmd.h: Likewise.
2651
2652 2017-09-04 Pedro Alves <palves@redhat.com>
2653
2654 * ada-lang.c (is_known_support_routine): Move sal declaration to
2655 where it is initialized.
2656 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2657 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2658 (clear_command, update_static_tracepoint): Remove init_sal
2659 references. Move declarations closer to initializations.
2660 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2661 initializations.
2662 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2663 references. Move sal declarations closer to initializations.
2664 * frame.c (find_frame_sal): Return a symtab_and_line via function
2665 return instead of output parameter. Remove init_sal references.
2666 * frame.h (find_frame_sal): Return a symtab_and_line via function
2667 return instead of output parameter.
2668 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2669 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2670 instead of memset.
2671 (gdbscm_find_pc_line): Remove init_sal reference.
2672 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2673 references. Move declarations closer to initializations.
2674 * infcmd.c (set_step_frame): Update. Move declarations closer to
2675 initializations.
2676 (finish_backward): Remove init_sal references. Move declarations
2677 closer to initializations.
2678 * infrun.c (process_event_stop_test, handle_step_into_function)
2679 (insert_hp_step_resume_breakpoint_at_frame)
2680 (insert_step_resume_breakpoint_at_caller): Likewise.
2681 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
2682 (symbol_to_sal): Likewise.
2683 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
2684 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
2685 to its initialization.
2686 * reverse.c (save_bookmark_command): Use new/delete. Remove
2687 init_sal references. Move declarations closer to initializations.
2688 * source.c (get_current_source_symtab_and_line): Remove brace
2689 initialization.
2690 (set_current_source_symtab_and_line): Now takes the sal by const
2691 reference. Remove brace initialization.
2692 (line_info): Remove init_sal reference.
2693 * source.h (set_current_source_symtab_and_line): Now takes a
2694 symtab_and_line via const reference.
2695 * stack.c (set_current_sal_from_frame): Adjust.
2696 (print_frame_info): Adjust.
2697 (get_last_displayed_sal): Return the sal via function return
2698 instead of via output parameter. Simplify.
2699 (frame_info): Adjust.
2700 * stack.h (get_last_displayed_sal): Return the sal via function
2701 return instead of via output parameter.
2702 * symtab.c (init_sal): Delete.
2703 (find_pc_sect_line): Remove init_sal references. Move
2704 declarations closer to initializations.
2705 (find_function_start_sal): Remove init_sal references. Move
2706 declarations closer to initializations.
2707 * symtab.h (struct symtab_and_line): In-class initialize all
2708 fields.
2709 * tracepoint.c (set_traceframe_context)
2710 (print_one_static_tracepoint_marker): Remove init_sal references.
2711 Move declarations closer to initializations.
2712 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
2713 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
2714 declarations closer to initializations.
2715 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
2716 init_sal references. Adjust.
2717
2718 2017-09-04 Pedro Alves <palves@redhat.com>
2719
2720 * ax-gdb.c (agent_command_1): Use range-for.
2721 * break-catch-throw.c (re_set_exception_catchpoint): Update.
2722 * breakpoint.c: Include "common/array-view.h".
2723 (init_breakpoint_sal, create_breakpoint_sal): Change sals
2724 parameter from struct symtabs_and_lines to
2725 array_view<symtab_and_line>. Adjust. Use range-for. Update.
2726 (breakpoint_sals_to_pc): Change sals parameter from struct
2727 symtabs_and_lines to std::vector reference.
2728 (check_fast_tracepoint_sals): Change sals parameter from struct
2729 symtabs_and_lines to std::array_view. Use range-for.
2730 (decode_static_tracepoint_spec): Return a std::vector instead of
2731 symtabs_and_lines. Update.
2732 (create_breakpoint): Update.
2733 (break_range_command, until_break_command, clear_command): Update.
2734 (base_breakpoint_decode_location, bkpt_decode_location)
2735 (bkpt_probe_create_sals_from_location)
2736 (bkpt_probe_decode_location, tracepoint_decode_location)
2737 (tracepoint_probe_decode_location)
2738 (strace_marker_create_sals_from_location): Return a std::vector
2739 instead of symtabs_and_lines.
2740 (strace_marker_create_breakpoints_sal): Update.
2741 (strace_marker_decode_location): Return a std::vector instead of
2742 symtabs_and_lines. Update.
2743 (update_breakpoint_locations): Change struct symtabs_and_lines
2744 parameters to gdb::array_view. Adjust.
2745 (location_to_sals): Return a std::vector instead of
2746 symtabs_and_lines. Update.
2747 (breakpoint_re_set_default): Use std::vector instead of struct
2748 symtabs_and_lines.
2749 (decode_location_default): Return a std::vector instead of
2750 symtabs_and_lines. Update.
2751 * breakpoint.h: Include "common/array-view.h".
2752 (struct breakpoint_ops) <decode_location>: Now returns a
2753 std::vector instead of returning a symtabs_and_lines via output
2754 parameter.
2755 (update_breakpoint_locations): Change sals parameters to use
2756 gdb::array_view.
2757 * cli/cli-cmds.c (edit_command, list_command): Update to use
2758 std::vector and gdb::array_view.
2759 (ambiguous_line_spec): Adjust to use gdb::array_view and
2760 range-for.
2761 (compare_symtabs): Rename to ...
2762 (cmp_symtabs): ... this. Change parameters to symtab_and_line
2763 const reference and adjust.
2764 (filter_sals): Rewrite using std::vector and standard algorithms.
2765 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
2766 (jump_command): Update to use std::vector.
2767 * linespec.c (struct linespec_state) <canonical_names>: Update
2768 comment.
2769 (add_sal_to_sals_basic): Delete.
2770 (add_sal_to_sals, filter_results, convert_results_to_lsals)
2771 (decode_line_2, create_sals_line_offset)
2772 (convert_address_location_to_sals, convert_linespec_to_sals)
2773 (convert_explicit_location_to_sals, parse_linespec)
2774 (event_location_to_sals, decode_line_full, decode_line_1)
2775 (decode_line_with_current_source)
2776 (decode_line_with_last_displayed, decode_objc)
2777 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
2778 (linespec_result::~linespec_result): Adjust to use std::vector
2779 instead of symtabs_and_lines.
2780 * linespec.h (linespec_sals::sals): Now a std::vector.
2781 (struct linespec_result): Use std::vector, bool, and in-class
2782 initialization.
2783 (decode_line_1, decode_line_with_current_source)
2784 (decode_line_with_last_displayed): Return std::vector.
2785 * macrocmd.c (info_macros_command): Use std::vector.
2786 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
2787 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
2788 std::vector.
2789 * probe.h (parse_probes): Return a std::vector.
2790 * python/python.c (gdbpy_decode_line): Use std::vector and
2791 gdb::array_view.
2792 * source.c (select_source_symtab, line_info): Use std::vector.
2793 * stack.c (func_command): Use std::vector.
2794 * symtab.h (struct symtabs_and_lines): Delete.
2795 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
2796
2797 2017-09-04 Pedro Alves <palves@redhat.com>
2798
2799 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2800 unittests/array-view-selftests.c.
2801 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
2802 * common/array-view.h: New file.
2803 * unittests/array-view-selftests.c: New file.
2804
2805 2017-09-04 Pedro Alves <palves@redhat.com>
2806
2807 * cli/cli-cmds.c (edit_command): Pass message to
2808 ambiguous_line_spec.
2809 (list_command): Pass message to ambiguous_line_spec. Say
2810 "first"/"last" instead of "start" and "end" to be consistent with
2811 the manual.
2812 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
2813 them to print formatted message.
2814
2815 2017-09-04 Pedro Alves <palves@redhat.com>
2816
2817 * btrace.c (ftrace_add_pt): Pass btrace_insn to
2818 ftrace_update_insns by reference instead of pointer.
2819
2820 2017-09-04 Yao Qi <yao.qi@linaro.org>
2821
2822 * i386-go32-tdep.c: Include x86-xstate.h.
2823 (i386_go32_init_abi): Call i386_target_description.
2824 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
2825 if xcr0 is X86_XSTATE_X87_MASK.
2826 * i386-tdep.h (tdesc_i386): Remove the declaration.
2827 (tdesc_i386_mmx): Likewise.
2828
2829 2017-09-04 Yao Qi <yao.qi@linaro.org>
2830
2831 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
2832 X86_XSTATE_SSE_MASK instead of 0.
2833
2834 2017-09-04 Yao Qi <yao.qi@linaro.org>
2835
2836 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
2837 i386_target_description.
2838 * i386-fbsd-nat.c (i386fbsd_read_description): Call
2839 i386_target_description.
2840 * i386-tdep.c (i386_gdbarch_init): Likewise.
2841
2842 2017-09-04 Yao Qi <yao.qi@linaro.org>
2843
2844 * amd64-darwin-tdep.c: Include "x86-xstate.h".
2845 (x86_darwin_init_abi_64): Call amd64_target_description.
2846 * amd64-dicos-tdep.c: Likewise.
2847 * amd64-fbsd-nat.c: Likewise.
2848 * amd64-fbsd-tdep.c: Likewise.
2849 * amd64-nbsd-tdep.c: Likewise.
2850 * amd64-obsd-tdep.c: Likewise.
2851 * amd64-sol2-tdep.c: Likewise.
2852 * amd64-windows-tdep.c: Likewise.
2853 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
2854
2855 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2856
2857 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
2858 (btrace_function) <insn>: Change type to use std::vector.
2859 * btrace.c (ftrace_debug, ftrace_call_num_insn,
2860 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
2861 ftrace_update_insns, ftrace_compute_global_level_offset,
2862 btrace_stitch_bts, btrace_clear, btrace_insn_get,
2863 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
2864 change to std::vector.
2865 (ftrace_update_insns): Adjust to change to std::vector, change
2866 type of INSN parameter.
2867 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
2868 * record-btrace.c (btrace_call_history_insn_range,
2869 btrace_compute_src_line_range,
2870 record_btrace_frame_prev_register): Adjust to change to
2871 std::vector.
2872 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
2873 to change to std::vector.
2874
2875 2017-09-03 Tom Tromey <tom@tromey.com>
2876
2877 * corefile.c (reopen_exec_file): Use std::string.
2878
2879 2017-09-03 Tom Tromey <tom@tromey.com>
2880
2881 * compile/compile.c (compile_register_name_mangled): Return
2882 std::string.
2883 * compile/compile-loc2c.c (pushf_register_address): Update.
2884 (pushf_register): Update.
2885 * compile/compile-c-types.c (convert_array): Update.
2886 * compile/compile-c-symbols.c (generate_vla_size): Update.
2887 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
2888 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
2889 (convert_one_symbol): Update.
2890 (generate_c_for_for_one_variable): Update.
2891 * compile/compile-c-support.c (c_get_range_decl_name): Return a
2892 std::string.
2893 (generate_register_struct): Update.
2894 * compile/compile-internal.h (c_get_range_decl_name): Return a
2895 std::string.
2896 (compile_register_name_mangled): Return std::string.
2897
2898 2017-09-03 Tom Tromey <tom@tromey.com>
2899
2900 * utils.c (perror_string): Return a std::string.
2901 (throw_perror_with_name, perror_warning_with_name): Update.
2902
2903 2017-09-03 Tom Tromey <tom@tromey.com>
2904
2905 * demangle.c (demangle_command): Use std::string,
2906 unique_xmalloc_ptr.
2907
2908 2017-09-03 Tom Tromey <tom@tromey.com>
2909
2910 * cli/cli-setshow.c (do_set_command): Use std::string.
2911
2912 2017-09-03 Tom Tromey <tom@tromey.com>
2913
2914 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
2915
2916 2017-09-03 Tom Tromey <tom@tromey.com>
2917
2918 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
2919
2920 2017-09-03 Tom Tromey <tom@tromey.com>
2921
2922 * mi/mi-cmd-env.c (env_execute_cli_command): Use
2923 gdb::unique_xmalloc_ptr.
2924
2925 2017-09-03 Tom Tromey <tom@tromey.com>
2926
2927 * thread.c (print_thread_info_1): Use string_printf.
2928 (thread_apply_command, thread_apply_all_command): Use
2929 std::string.
2930
2931 2017-09-03 Tom Tromey <tom@tromey.com>
2932
2933 * valprint.c (val_print_string): Update.
2934 * gdbcore.h (memory_error_message): Return std::string.
2935 * corefile.c (memory_error_message): Return std::string.
2936 (memory_error): Update.
2937 * breakpoint.c (insert_bp_location): Update.
2938
2939 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2940
2941 * target/waitstatus.h (target_waitstatus_to_string): Change
2942 return type to std::string.
2943 * target/waitstatus.c (target_waitstatus_to_string): Return
2944 std::string.
2945 * target.h (target_waitstatus_to_string): Remove declaration.
2946 * infrun.c (resume, clear_proceed_status_thread,
2947 print_target_wait_results, do_target_wait, save_waitstatus,
2948 stop_all_threads): Adjust.
2949 * record-btrace.c (record_btrace_wait): Adjust.
2950 * target-debug.h
2951 (target_debug_print_struct_target_waitstatus_p): Adjust.
2952
2953 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2954
2955 PR gdb/22046
2956 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
2957 detection.
2958
2959 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2960
2961 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
2962 for setting/unsetting environment variables on the remote target.
2963 (New remote packets): Add entries for QEnvironmentHexEncoded,
2964 QEnvironmentUnset and QEnvironmentReset.
2965 * common/environ.c (gdb_environ::operator=): Extend method to
2966 handle m_user_set_env_list and m_user_unset_env_list.
2967 (gdb_environ::clear): Likewise.
2968 (match_var_in_string): Change type of first parameter from 'char
2969 *' to 'const char *'.
2970 (gdb_environ::set): Extend method to handle
2971 m_user_set_env_list and m_user_unset_env_list.
2972 (gdb_environ::unset): Likewise.
2973 (gdb_environ::clear_user_set_env): New method.
2974 (gdb_environ::user_set_envp): Likewise.
2975 (gdb_environ::user_unset_envp): Likewise.
2976 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
2977 m_user_unset_env_list on move constructor/assignment.
2978 (unset): Add new default parameter 'update_unset_list = true'.
2979 (clear_user_set_env): New method.
2980 (user_set_envp): Likewise.
2981 (user_unset_envp): Likewise.
2982 (m_user_set_env_list): New std::set.
2983 (m_user_unset_env_list): Likewise.
2984 * common/rsp-low.c (hex2str): New function.
2985 (bin2hex): New overload for bin2hex function.
2986 * common/rsp-low.c (hex2str): New prototype.
2987 (str2hex): New overload prototype.
2988 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
2989 QEnvironmentUnset and QEnvironmentReset.
2990 (remote_protocol_features): Add QEnvironmentHexEncoded,
2991 QEnvironmentUnset and QEnvironmentReset packets.
2992 (send_environment_packet): New function.
2993 (extended_remote_environment_support): Likewise.
2994 (extended_remote_create_inferior): Call
2995 extended_remote_environment_support.
2996 (_initialize_remote): Add QEnvironmentHexEncoded,
2997 QEnvironmentUnset and QEnvironmentReset packet configs.
2998 * unittests/environ-selftests.c (gdb_selftest_env_var):
2999 New variable.
3000 (test_vector_initialization): New function.
3001 (test_init_from_host_environ): Likewise.
3002 (test_reinit_from_host_environ): Likewise.
3003 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
3004 Likewise.
3005 (test_unset_set_empty_vector): Likewise.
3006 (test_vector_clear): Likewise.
3007 (test_std_move): Likewise.
3008 (test_move_constructor):
3009 (test_self_move): Likewise.
3010 (test_set_unset_reset): Likewise.
3011 (run_tests): Rewrite in terms of the functions above.
3012
3013 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
3014
3015 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
3016 (adi_available): Use a temp variable of type CORE_ADDR as argument
3017 3 when calling target_auxv_search.
3018 (adi_normalize_address): Use masks and xor operators to calculate
3019 normalized address.
3020 (adi_read_versions, adi_write_versions, adi_print_versions)
3021 (do_examine, do_assign): Use paddress.
3022
3023 2017-08-29 John Baldwin <jhb@FreeBSD.org>
3024
3025 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
3026 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
3027 out of loop and add supply of FIR.
3028 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
3029 add collect of FIR.
3030
3031 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
3032
3033 PR gdb/21827
3034 * cli/cli-script.c (define_command): Don't convert command name
3035 to lower case.
3036
3037 2017-08-25 Joel Brobecker <brobecker@adacore.com>
3038
3039 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
3040 Update all callers accordingly. Remove all code blocks handling
3041 the case where DISPP is not NULL.
3042
3043 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3044
3045 PR symtab/22003
3046 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
3047 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3048 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
3049
3050 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3051
3052 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
3053 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
3054 (read_comp_units_from_section): New parameter abbrev_section, use
3055 read_and_check_comp_unit_head, allocate signatured_type if needed.
3056 (create_all_comp_units): Update read_comp_units_from_section caller.
3057
3058 2017-08-23 Pedro Alves <palves@redhat.com>
3059
3060 PR remote/21852
3061 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
3062 to null_ptid and switch to thread without reading the registers
3063 after adding the inferior.
3064
3065 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3066
3067 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
3068 compile-gcc.
3069 * compile/compile.c (compile_gcc, show_compile_gcc): New.
3070 (compile_to_object): Implement compile_gcc.
3071 (_initialize_compile): Install "set compile-gcc". Initialize
3072 compile_gcc.
3073
3074 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3075
3076 * compile/compile.c (compile_to_object): Conditionally call
3077 set_verbose. Conditionally call compile or compile_v0.
3078
3079 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
3080
3081 * sparc64-tdep.h: (adi_normalize_address): New export.
3082 * sparc-nat.h: (open_adi_tag_fd): New export.
3083 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
3084 * sparc64-linux-tdep.c:
3085 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
3086 (sparc64_linux_handle_segmentation_fault): New function.
3087 (sparc64_linux_init_abi): Register
3088 sparc64_linux_handle_segmentation_fault
3089 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
3090 (sparc64_addr_bits_remove): New function.
3091 (sparc64_init_abi): Register sparc64_addr_bits_remove.
3092 (MAX_PROC_NAME_SIZE): New macro.
3093 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
3094 (sparc64adilist): New variable.
3095 (adi_proc_list): New variable.
3096 (find_adi_info): New function.
3097 (add_adi_info): New function.
3098 (get_adi_info_proc): New function.
3099 (get_adi_info): New function.
3100 (info_adi_command): New function.
3101 (read_maps_entry): New function.
3102 (adi_available): New function.
3103 (adi_normalize_address): New function.
3104 (adi_align_address): New function.
3105 (adi_convert_byte_count): New function.
3106 (adi_tag_fd): New function.
3107 (adi_is_addr_mapped): New function.
3108 (adi_read_versions): New function.
3109 (adi_write_versions): New function.
3110 (adi_print_versions): New function.
3111 (do_examine): New function.
3112 (do_assign): New function.
3113 (adi_examine_command): New function.
3114 (adi_assign_command): New function.
3115 (_initialize_sparc64_adi_tdep): New function.
3116
3117 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
3118
3119 * breakpoint.c (breakpoints_info): Rename to ...
3120 (info_breakpoints_command): ... this.
3121 (watchpoints_info): Rename to ...
3122 (info_watchpoints_command): ... this.
3123 (tracepoints_info): Rename to ...
3124 (info_tracepoints_command): ... this.
3125 (_initialize_breakpoint): Adjust.
3126 * dcache.c (dcache_info): Rename to ...
3127 (info_display_command): ... this.
3128 (_initialize_dcache): Adjust.
3129 * frame.h (args_info): Rename to ...
3130 (info_args_command): ... this.
3131 (locals_info): Rename to ...
3132 (info_locals_command): ... this.
3133 * infcmd.c (nofp_registers_info): Rename to ...
3134 (info_registers_command): ... this.
3135 (float_info): Rename to ...
3136 (info_float_command): ... this.
3137 (program_info): Rename to ...
3138 (info_program_command): ... this.
3139 (all_registers_info): Rename to ...
3140 (info_all_registers_command): ... this.
3141 (vector_info): Rename to ...
3142 (info_vector_command): ... this.
3143 (float_info): Rename to ...
3144 (info_float_command): ... this.
3145 (_initialize_infcmd): Adjust.
3146 * inferior.h (term_info): Rename to ...
3147 (info_terminal_command): ... this.
3148 * inflow.c (term_info): Rename to ...
3149 (info_terminal_command): ... this.
3150 (_initialize_inflow): Adjust.
3151 * infrun.c (signals_info): Rename to ...
3152 (info_signals_command): ... this.
3153 (_initialize_infrun): Adjust.
3154 * objc-lang.c (classes_info): Rename to ...
3155 (info_classes_command): ... this.
3156 (selectors_info): Rename to ...
3157 (info_selectors_command): ... this.
3158 (_initialize_objc_language): Adjust.
3159 * printcmd.c (sym_info): Rename to ...
3160 (info_symbol_command): ... this.
3161 (address_info): Rename to ...
3162 (info_address_command): ... this.
3163 (display_info): Rename to ...
3164 (info_display_command): ... this.
3165 (_initialize_printcmd): Adjust.
3166 * reverse.c (bookmarks_info): Rename to ...
3167 (info_breakpoints_command): ... this.
3168 (_initialize_reverse): Adjust.
3169 * ser-go32.c (dos_info): Rename to ...
3170 (info_serial_command): ... this.
3171 (_initialize_ser_dos): Adjust.
3172 * skip.c (skip_info): Rename to ...
3173 (info_skip_command): ... this.
3174 (_initialize_step_skip): Adjust.
3175 * source.c (line_info): Rename to ...
3176 (info_line_command): ... this.
3177 (source_info): Rename to ...
3178 (info_source_command)
3179 * stack.c (frame_info): Rename to ...
3180 (info_frame_command): ... this.
3181 (locals_info): Rename to ...
3182 (info_locals_command): ... this.
3183 (args_info): Rename to ...
3184 (info_args_command): ... this.
3185 (_initialize_stack): Adjust.
3186 * symtab.c (sources_info): Rename to ...
3187 (info_sources_command): ... this.
3188 (variables_info): Rename to ...
3189 (info_variables_command): ... this.
3190 (functions_info): Rename to ...
3191 (info_functions_command): ... this.
3192 (types_info): Rename to ...
3193 (info_types_command): ... this.
3194 (_initialize_symtab): Adjust.
3195 * target.c (target_info): Rename to ...
3196 (info_target_command): ... this.
3197 (initialize_targets): Adjust.
3198 * tracepoint.c (tvariables_info): Rename to ...
3199 (info_tvariables_command): ... this.
3200 (scope_info): Rename to ...
3201 (info_scope_command): ... this.
3202 (trace_dump_actions): Adjust.
3203 (_initialize_tracepoint): Adjust.
3204
3205 2017-08-22 Tom Tromey <tom@tromey.com>
3206
3207 * breakpoint.h (install_breakpoint): Update.
3208 * breakpoint.c (add_solib_catchpoint): Update.
3209 (install_breakpoint): Change argument to a std::unique_ptr.
3210 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
3211 (create_breakpoint_sal, create_breakpoint): Update.
3212 (watch_command_1, catch_exec_command_1)
3213 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
3214 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
3215 Return the breakpoint.
3216 (set_raw_breakpoint_without_location, set_raw_breakpoint)
3217 (new_single_step_breakpoint): Update.
3218 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
3219 std::unique_ptr.
3220 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3221 std::unique_ptr.
3222 * break-catch-sig.c (create_signal_catchpoint): Use
3223 std::unique_ptr.
3224 * ada-lang.c (create_ada_exception_catchpoint): Use
3225 std::unique_ptr.
3226
3227 2017-08-22 Tom Tromey <tom@tromey.com>
3228
3229 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
3230
3231 2017-08-22 Tom Tromey <tom@tromey.com>
3232
3233 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
3234 (lookup_partial_symbol): Update.
3235
3236 2017-08-22 Tom Tromey <tom@tromey.com>
3237
3238 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
3239 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
3240 (find_and_open_source, symtab_to_fullname): Update.
3241 * psymtab.c (psymtab_to_fullname): Update.
3242
3243 2017-08-22 Tom Tromey <tom@tromey.com>
3244
3245 * exec.c (exec_file_attach): Update.
3246 * linux-thread-db.c (try_thread_db_load): Update.
3247 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
3248 * utils.c (gdb_realpath): Change return type.
3249 (gdb_realpath_keepfile): Update.
3250 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
3251 (_initialize_utils): Register the new self test.
3252 * source.c (openp): Update.
3253 (find_and_open_source): Update.
3254 * nto-tdep.c (nto_find_and_open_solib): Update.
3255 * main.c (set_gdb_data_directory): Update.
3256 (captured_main_1): Update.
3257 * dwarf2read.c (dwarf2_get_dwz_file): Update
3258 (dw2_map_symbol_filenames): Update.
3259 * auto-load.c (auto_load_safe_path_vec_update): Update.
3260 (filename_is_in_auto_load_safe_path_vec): Change type of
3261 "filename_realp".
3262 (auto_load_objfile_script): Update.
3263 (file_is_auto_load_safe): Update. Use std::string.
3264 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
3265
3266 2017-08-22 Tom Tromey <tom@tromey.com>
3267
3268 * utils.c (gdb_realpath_keepfile): Return a
3269 gdb::unique_xmalloc_ptr.
3270 * exec.c (exec_file_attach): Update.
3271 * utils.h (gdb_realpath_keepfile): Return a
3272 gdb::unique_xmalloc_ptr.
3273
3274 2017-08-22 Tom Tromey <tom@tromey.com>
3275
3276 * compile/compile.c (compile_file_command): Use
3277 gdb::unique_xmalloc_ptr, std::string.
3278 * utils.c (gdb_abspath): Change return type.
3279 * source.c (openp): Update.
3280 * objfiles.c (allocate_objfile): Update.
3281 * main.c (set_gdb_data_directory): Update.
3282 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
3283
3284 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
3285
3286 * cli-cmds.c (list_commands): List actual code around more than
3287 one location.
3288
3289 2017-08-21 John Baldwin <jhb@FreeBSD.org>
3290
3291 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
3292
3293 2017-08-21 Pedro Alves <palves@redhat.com>
3294
3295 PR gdb/19487
3296 * c-exp.y (variable production): Handle function aliases.
3297 * minsyms.c (msymbol_is_text): New function.
3298 * minsyms.h (msymbol_is_text): Declare.
3299 * symtab.c (find_function_alias_target): New function.
3300 * symtab.h (find_function_alias_target): Declare.
3301
3302 2017-08-21 Pedro Alves <palves@redhat.com>
3303
3304 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
3305 typedefs.
3306 * typeprint.c (whatis_exp): If handling "whatis", and expression
3307 is OP_TYPE, strip one typedef level. Otherwise don't strip
3308 typedefs here.
3309 * valops.c (value_cast): Save "to" type before resolving
3310 stubs/typedefs. Use that type as resulting value's type.
3311
3312 2017-08-18 Tom Tromey <tom@tromey.com>
3313 Pedro Alves <palves@redhat.com>
3314
3315 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
3316 * sol-thread.c (sol_thread_resume, sol_thread_wait)
3317 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
3318 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
3319 * proc-service.c (ps_xfer_memory): Use scoped_restore.
3320 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
3321 (linux_get_siginfo_data): Add "thread" argument. Use
3322 scoped_restore.
3323 * linux-nat.c (linux_child_follow_fork)
3324 (check_stopped_by_watchpoint): Use scoped_restore.
3325 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
3326 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
3327 (restore_inferior_ptid, save_inferior_ptid): Remove.
3328 * btrace.c (btrace_fetch): Use scoped_restore.
3329 * bsd-uthread.c (bsd_uthread_fetch_registers)
3330 (bsd_uthread_store_registers): Use scoped_restore.
3331 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
3332 scoped_restore.
3333 * aix-thread.c (aix_thread_resume, aix_thread_wait)
3334 (aix_thread_xfer_partial): Use scoped_restore.
3335 * inferior.h (save_inferior_ptid): Remove.
3336
3337 2017-08-18 Yao Qi <yao.qi@linaro.org>
3338
3339 PR tdep/21818
3340 * arm-tdep.c (gdb_print_insn_arm): Mark
3341 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
3342
3343 2017-08-18 Yao Qi <yao.qi@linaro.org>
3344
3345 * NEWS: Mention GDBserver's new option "--selftest".
3346 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
3347 * selftest.c: Move it to common/selftest.c.
3348 * selftest.h: Move it to common/selftest.h.
3349 * selftest-arch.c (reset): New function.
3350 (tests_with_arch): Call reset.
3351
3352 2017-08-18 Yao Qi <yao.qi@linaro.org>
3353
3354 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
3355 instead of exception_fprintf and printf_filtered.
3356
3357 2017-08-18 Yao Qi <yao.qi@linaro.org>
3358
3359 * selftest.c (register_self_test): Rename it to
3360 selftests::register_test.
3361 (run_self_tests): selftest::run_tests.
3362 * selftest.h: Update declarations.
3363 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
3364 selftests::register_test_foreach_arch.
3365 * selftest-arch.h: Update declaration.
3366 * aarch64-tdep.c: Update.
3367 * arm-tdep.c: Likewise.
3368 * disasm-selftests.c: Likewise.
3369 * dwarf2loc.c: Likewise.
3370 * dwarf2-frame.c: Likewise.
3371 * findvar.c: Likewise.
3372 * gdbarch-selftests.c: Likewise.
3373 * maint.c (maintenance_selftest): Likewise.
3374 * regcache.c: Likewise.
3375 * rust-exp.y: Likewise.
3376 * selftest-arch.c: Likewise.
3377 * unittests/environ-selftests.c: Likewise.
3378 * unittests/function-view-selftests.c: Likewise.
3379 * unittests/offset-type-selftests.c: Likewise.
3380 * unittests/optional-selftests.c: Likewise.
3381 * unittests/scoped_restore-selftests.c: Likewise.
3382 * utils-selftests.c: Likewise.
3383
3384 2017-08-17 Pedro Alves <palves@redhat.com>
3385
3386 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
3387 local.
3388
3389 2017-08-17 Pedro Alves <palves@redhat.com>
3390
3391 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3392 field.
3393 (reset_die_in_process): Delete, replaced by ...
3394 (process_die_scope): ... this new class. Make it responsible for
3395 freeing cu->line_header too.
3396 (process_die): Use process_die_scope.
3397 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3398 cu->line_header_die_owner. Don't release the line header if it's
3399 owned by the CU.
3400 (setup_type_unit_groups): Make the CU/DIE own the line header.
3401 Don't release the line header here.
3402
3403 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3404
3405 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3406
3407 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3408
3409 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3410 Single-Key mode
3411
3412 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3413
3414 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3415 mode command list.
3416
3417 2017-08-15 Stafford Horne <shorne@gmail.com>
3418
3419 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3420
3421 2017-08-15 Stafford Horne <shorne@gmail.com>
3422
3423 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3424
3425 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3426
3427 PR gdb/21954
3428 * infcmd.c (unset_environment_command): Use the 'clear' method on
3429 the environment instead of resetting it.
3430
3431 2017-08-15 John Baldwin <jhb@FreeBSD.org>
3432
3433 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3434 platforms.
3435
3436 2017-08-14 Tom Tromey <tom@tromey.com>
3437
3438 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3439 (print_binary_chars): Likewise.
3440 (BITS_IN_BYTES): Remove.
3441
3442 2017-08-14 Tom Tromey <tom@tromey.com>
3443
3444 PR gdb/21675
3445 * valprint.c (LOW_ZERO): Change value to 034.
3446 (print_octal_chars): Add static_asserts for octal constants.
3447 * printcmd.c (print_scalar_formatted): Add 'd' case.
3448
3449 2017-08-11 Tom Tromey <tom@tromey.com>
3450
3451 * symfile.c (add_symbol_file_command): Use std::vector.
3452
3453 2017-08-14 Tom Tromey <tom@tromey.com>
3454
3455 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3456 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3457 std::move.
3458 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3459
3460 2017-08-11 Pedro Alves <palves@redhat.com>
3461
3462 * infrun.c (process_event_stop_test): Adjust
3463 function_name_is_marked_for_skip call.
3464 * skip.c: Include <list>.
3465 (skiplist_entry): Make it a class with private fields, and
3466 getters/setters.
3467 (skiplist_entry_chain): Delete.
3468 (skiplist_entries): New.
3469 (skiplist_entry_count): Delete.
3470 (highest_skiplist_entry_num): New.
3471 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3472 (add_skiplist_entry): Delete.
3473 (skiplist_entry::skiplist_entry): New.
3474 (skiplist_entry::add_entry): New.
3475 (skip_file_command, skip_function): Adjust.
3476 (compile_skip_regexp): Delete.
3477 (skip_command): Don't compile regexp here. Adjust to use
3478 skiplist_entry::add_entry.
3479 (skip_info): Adjust to use range-for and getters.
3480 (skip_enable_command, skip_disable_command): Adjust to use
3481 range-for and setters.
3482 (skip_delete_command): Adjust to use std::list.
3483 (add_skiplist_entry): Delete.
3484 (skip_file_p): Delete, refactored as ...
3485 (skiplist_entry::do_skip_file_p): ... this new method.
3486 (skip_gfile_p): Delete, refactored as ...
3487 (skiplist_entry::do_gskip_file_p): ... this new method.
3488 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3489 (skiplist_entry::skip_function_p): ... this new method.
3490 (function_name_is_marked_for_skip): Now returns bool, and takes
3491 the function sal by const reference. Adjust to use range-for and
3492 skiplist_entry methods.
3493 (_initialize_step_skip): Remove references to
3494 skiplist_entry_chain, skiplist_entry_count.
3495 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3496 takes the function sal by const reference.
3497
3498 2017-08-11 Yao Qi <yao.qi@linaro.org>
3499
3500 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3501 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3502 (dwarf2_frame_cache):
3503 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3504 RETURN_MASK_ALL and set *this_case to NULL.
3505 * frame-unwind.h: Update comments.
3506
3507 2017-08-11 Yao Qi <yao.qi@linaro.org>
3508
3509 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3510 (dwarf2_frame_state_copy_regs): Remove.
3511 (dwarf2_frame_state_free_regs): Remove.
3512 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3513 (dwarf2_restore_rule): Call method .alloc_regs instead of
3514 dwarf2_frame_state_alloc_regs.
3515 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3516 constructor. Call std::move.
3517 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3518 (dwarf2_frame_cache): Likewise.
3519
3520 [GDB_SELF_TEST]: Include selftest.h and
3521 selftest-arch.h.
3522 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3523 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3524 execute_cfa_program_test.
3525
3526 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3527 copy ctor, assignment operator, move assignment.
3528 <alloc_regs>: New method.
3529 <swap>: New method.
3530 (struct dwarf2_frame_state): Delete dtor.
3531 (dwarf2_frame_state_alloc_regs): Remove declaration.
3532 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3533 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3534
3535 2017-08-11 Yao Qi <yao.qi@linaro.org>
3536
3537 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3538 (dwarf2_frame_state::dwarf2_frame_state): New.
3539 (dwarf2_frame_state::~dwarf2_frame_state): New.
3540 (dwarf2_fetch_cfa_info): Update.
3541 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3542 rather than a pointer. Update code.
3543 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3544 dtor.
3545 <data_align, code_align, retaddr_column>: Change them to const.
3546 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3547 to bool.
3548
3549 2017-08-11 Yao Qi <yao.qi@linaro.org>
3550
3551 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3552 <loc.exp>: New field.
3553 * dwarf2-frame.c (execute_cfa_program): Update.
3554 (dwarf2_frame_prev_register): Update.
3555
3556 2017-08-10 Pedro Alves <palves@redhat.com>
3557
3558 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3559
3560 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3561
3562 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3563 (fbsd_pending_children): Use std::list.
3564 (fbsd_remember_child): Likewise.
3565 (fbsd_is_child_pending): Likewise.
3566 (fbsd_pending_vfork_done): Use std::forward_list.
3567 (fbsd_add_vfork_done): Likewise.
3568 (fbsd_is_vfork_done_pending): Likewise.
3569 (fbsd_next_vfork_done): Likewise.
3570
3571 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3572
3573 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3574 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3575 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3576 for `mapfilename'.
3577 (fbsd_xfer_partial): Use gdb::byte_vector.
3578 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
3579
3580 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3581
3582 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3583 "filestuff.h".
3584 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3585
3586 2017-08-09 Tom Tromey <tom@tromey.com>
3587
3588 * skip.c (skiplist_entry): New constructor.
3589 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3590 (skiplist_entry::file_is_glob): Now bool.
3591 (skiplist_entry::file, skiplist_entry::function): Now
3592 std::string.
3593 (make_skip_entry): Return a unique_ptr. Use new.
3594 (free_skiplist_entry, free_skiplist_entry_cleanup)
3595 (make_free_skiplist_entry_cleanup): Remove.
3596 (skip_command, skip_disable_command, add_skiplist_entry)
3597 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3598 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3599 (function_name_is_marked_for_skip): Update.
3600 (skip_delete_command): Update. Use delete.
3601
3602 2017-08-09 Jiong Wang <jiong.wang@arm.com>
3603
3604 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3605 (aarch64_linux_core_read_description): New function.
3606 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3607
3608 2017-08-09 Pedro Alves <palves@redhat.com>
3609
3610 * cp-name-parser.y (cp_comp_to_string): Return a
3611 gdb::unique_xmalloc_ptr<char>.
3612 * cp-support.c (replace_typedefs_qualified_name)
3613 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3614 (cp_canonicalize_string_full): Use op= instead of explicit
3615 convertion.
3616 (cp_class_name_from_physname, method_name_from_physname)
3617 (cp_func_name, cp_remove_params): Adjust to use
3618 gdb::unique_xmalloc_ptr<char>.
3619 * cp-support.h (cp_comp_to_string): Return a
3620 gdb::unique_xmalloc_ptr<char>.
3621 * python/py-type.c (typy_lookup_type): Adjust to use
3622 gdb::unique_xmalloc_ptr<char>.
3623
3624 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3625
3626 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3627
3628 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3629 Yao Qi <yao.qi@linaro.org>
3630
3631 * cp-support.c (cp_canonicalize_string_full): Use
3632 gdb::unique_xmalloc_ptr<char>.
3633 (cp_canonicalize_string): Likewise.
3634
3635 2017-08-09 Yao Qi <yao.qi@linaro.org>
3636
3637 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3638 * regformats/i386/amd64-avx-avx512.dat: Remove.
3639 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3640 * regformats/i386/amd64-avx-mpx.dat:Remove.
3641 * regformats/i386/amd64-avx.dat: Remove.
3642 * regformats/i386/amd64-mpx.dat: Remove.
3643 * regformats/i386/i386-avx-avx512.dat: Remove.
3644 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3645 * regformats/i386/i386-avx-mpx.dat: Remove.
3646 * regformats/i386/i386-mmx.dat: Remove.
3647 * regformats/i386/i386-mpx.dat: Remove.
3648
3649 2017-08-09 Yao Qi <yao.qi@linaro.org>
3650
3651 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3652 * amd64-tdep.c: Don't include features/i386/x32*.c.
3653 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3654 functions.
3655 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3656 and i386/x32-avx-avx512.
3657 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3658 and i386/x32.xml.
3659 * features/i386/x32-avx-avx512.c: Removed.
3660 * features/i386/x32-avx-avx512.xml: Removed.
3661 * features/i386/x32-avx.c: Removed.
3662 * features/i386/x32-avx.xml: Removed.
3663 * features/i386/x32.c: Removed.
3664 * features/i386/x32.xml: Removed.
3665 * regformats/i386/x32-avx-avx512.dat: Removed.
3666 * regformats/i386/x32-avx.dat: Removed.
3667 * regformats/i386/x32.dat: Removed.
3668
3669 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3670
3671 PR breakpoints/21886
3672 * mem-break.c (default_memory_insert_breakpoint): Use
3673 `->placed_address' rather than `->reqstd_address' for the
3674 breakpoint location.
3675
3676 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3677
3678 * arch-utils.c (default_print_insn): Remove arch/mach/endian
3679 assertions.
3680
3681 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3682
3683 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
3684 a union of `tdep_info', `tdesc_data' and `id'.
3685 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
3686 rather than `info.tdep_info'.
3687 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
3688 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
3689 * i386-tdep.c (i386_gdbarch_init): Likewise.
3690 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
3691 * mips-tdep.c (mips_gdbarch_init): Likewise.
3692 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
3693 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
3694 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
3695 `info.tdep_info'.
3696 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
3697 `info.tdep_info'.
3698 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
3699 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
3700 `info.tdep_info'.
3701 * spu-tdep.c (spu_gdbarch_init): Likewise.
3702 * gdbarch.h: Regenerate.
3703
3704 2017-08-07 Leszek Swirski <leszeks@google.com>
3705
3706 PR symtab/20899
3707 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
3708
3709 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
3710
3711 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
3712 (gdbsim_open): Rename gdb_argv args object to argv.
3713
3714 2017-08-05 Tom Tromey <tom@tromey.com>
3715
3716 * compile/compile-object-load.c (compile_object_load): Use
3717 gdb::unique_xmalloc_ptr.
3718 * cli/cli-dump.c (scan_filename): Rename from
3719 scan_filename_with_cleanup. Change return type.
3720 (scan_expression): Rename from scan_expression_with_cleanup.
3721 Change return type.
3722 (dump_memory_to_file, dump_value_to_file, restore_command):
3723 Use gdb::unique_xmalloc_ptr. Update.
3724 * cli/cli-cmds.c (find_and_open_script): Use
3725 gdb::unique_xmalloc_ptr.
3726 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
3727 * symmisc.c (maintenance_print_symbols)
3728 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
3729 * symfile.c (symfile_bfd_open, generic_load)
3730 (add_symbol_file_command, remove_symbol_file_command): Use
3731 gdb::unique_xmalloc_ptr.
3732 * source.c (openp): Use gdb::unique_xmalloc_ptr.
3733 * psymtab.c (maintenance_print_psymbols): Use
3734 gdb::unique_xmalloc_ptr.
3735 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
3736 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
3737 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
3738 (reload_shared_libraries_1): Likewise.
3739
3740 2017-08-05 Tom Tromey <tom@tromey.com>
3741
3742 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
3743 (rust_op_vector, rust_set_vector): New typedefs.
3744 (current_parser): New global.
3745 (work_obstack): Change to pointer type. Update all users.
3746 (rust_ast, pstate): Remove globals.
3747 (struct rust_parser): New.
3748 (%union) <params, field_inits>: Change type.
3749 (start, tuple_expr, unit_expr, struct_expr_list, literal)
3750 (field_expr, expr_list, maybe_expr_list, type_list): Update.
3751 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
3752 (convert_params_to_types, convert_params_to_expression): Change
3753 type of "params".
3754 (ast_string): Change type of "fields".
3755 (rust_parse): Make a rust_parser. Remove cleanups.
3756 (rust_lex_tests): Make and install an auto_obstack.
3757
3758 2017-08-04 Yao Qi <yao.qi@linaro.org>
3759
3760 * configure.srv (ipa_x32_linux_regobj): New.
3761 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
3762 instead of X86_TDESC_AVX512.
3763 (initialize_low_tracepoint): Call
3764 init_registers_x32_avx_avx512_linux.
3765
3766 2017-08-04 Yao Qi <yao.qi@linaro.org>
3767
3768 * utils.h (gdb_argv): Add namespace std for nullptr_t.
3769
3770 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
3771
3772 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
3773
3774 2017-08-03 Tom Tromey <tom@tromey.com>
3775
3776 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
3777 Remove.
3778 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
3779
3780 2017-08-03 Tom Tromey <tom@tromey.com>
3781
3782 * python/py-param.c (compute_enum_values): Use gdb_argv.
3783
3784 2017-08-03 Tom Tromey <tom@tromey.com>
3785
3786 * utils.h (struct gdb_argv_deleter): New.
3787 (gdb_argv): New class.
3788 * utils.c (gdb_argv::reset): New method.
3789 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
3790 * tracefile.c (tsave_command): Use gdb_argv.
3791 * top.c (new_ui_command): Use gdb_argv.
3792 * symmisc.c (maintenance_print_symbols)
3793 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
3794 * symfile.c (symbol_file_command, generic_load)
3795 (remove_symbol_file_command): Use gdb_argv.
3796 * stack.c (backtrace_command): Use gdb_argv.
3797 * source.c (add_path, show_substitute_path_command)
3798 (unset_substitute_path_command, set_substitute_path_command):
3799 Use gdb_argv.
3800 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
3801 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
3802 * remote.c (extended_remote_run, remote_put_command)
3803 (remote_get_command, remote_delete_command): Use gdb_argv.
3804 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
3805 (gdbsim_open): Use gdb_argv.
3806 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
3807 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
3808 * procfs.c (procfs_info_proc): Use gdb_argv.
3809 * interps.c (interpreter_exec_cmd): Use gdb_argv.
3810 * infrun.c (handle_command): Use gdb_argv.
3811 * inferior.c (add_inferior_command, clone_inferior_command):
3812 Use gdb_argv.
3813 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
3814 * exec.c (exec_file_command): Use gdb_argv.
3815 * cli/cli-cmds.c (alias_command): Use gdb_argv.
3816 * compile/compile.c (build_argc_argv): Use gdb_argv.
3817
3818 2017-08-03 Tom Tromey <tom@tromey.com>
3819
3820 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
3821
3822 2017-08-03 Tom Tromey <tom@tromey.com>
3823
3824 * python/python.c (compute_python_string): Return std::string.
3825 (gdbpy_eval_from_control_command): Update.
3826 (do_start_initialization): Use std::string.
3827 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
3828 xstrprintf.
3829 * python/py-breakpoint.c (local_setattro): Use string_printf, not
3830 xstrprintf.
3831
3832 2017-08-03 Tom Tromey <tom@tromey.com>
3833
3834 * top.h (do_restore_instream_cleanup): Remove.
3835 * top.c (do_restore_instream_cleanup): Remove.
3836 (read_command_file): Use scoped_restore.
3837 * cli/cli-script.c (execute_user_command): Use scoped_restore.
3838
3839 2017-08-03 Tom Tromey <tom@tromey.com>
3840
3841 * cli/cli-script.c (execute_user_command)
3842 (execute_control_command): Use scoped_restore.
3843
3844 2017-08-03 Tom Tromey <tom@tromey.com>
3845
3846 * cli/cli-script.c (do_restore_user_call_depth): Remove.
3847 (execute_user_command): Remove user_call_depth; use
3848 user_args_stack's size instead.
3849
3850 2017-08-03 Tom Tromey <tom@tromey.com>
3851
3852 * top.h (in_user_command): Remove.
3853 * top.c (in_user_command): Remove.
3854 * cli/cli-script.c (do_restore_user_call_depth)
3855 (execute_user_command): Update.
3856
3857 2017-08-03 Tom Tromey <tom@tromey.com>
3858
3859 * valops.c (search_struct_method): Use gdb::byte_vector.
3860 * valarith.c (value_concat): Use std::vector.
3861 * target.c (memory_xfer_partial): Use gdb::byte_vector.
3862 (simple_search_memory): Likewise.
3863 * printcmd.c (find_string_backward): Use gdb::byte_vector.
3864 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
3865 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
3866 * elfread.c (elf_rel_plt_read): Use std::string.
3867 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
3868 * cli/cli-dump.c (restore_section_callback): Use
3869 gdb::byte_vector.
3870
3871 2017-08-03 Tom Tromey <tom@tromey.com>
3872
3873 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
3874
3875 2017-08-03 Tom Tromey <tom@tromey.com>
3876
3877 * tui/tui-regs.c (tui_restore_gdbout): Remove.
3878 (tui_register_format): Use scoped_restore.
3879
3880 2017-08-03 Tom Tromey <tom@tromey.com>
3881
3882 * reverse.c (exec_direction_default): Remove.
3883 (exec_reverse_once): Use scoped_restore.
3884 * remote.c (restore_remote_timeout): Remove.
3885 (remote_flash_erase, remote_flash_write, remote_flash_done)
3886 (readchar, remote_serial_write): Use scoped_restore.
3887 * cli/cli-script.c (struct source_cleanup_lines_args)
3888 (source_cleanup_lines): Remove.
3889 (script_from_file): Use scoped_restore.
3890 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
3891 (source_command): Use scoped_restore.
3892
3893 2017-08-03 Tom Tromey <tom@tromey.com>
3894
3895 * utils.h (make_cleanup_free_so): Remove.
3896 * utils.c (do_free_so, make_cleanup_free_so): Remove.
3897 * solist.h (struct so_deleter): New.
3898 (so_list_up): New typedef.
3899 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
3900
3901 2017-08-03 Tom Tromey <tom@tromey.com>
3902
3903 * utils.h (make_cleanup_restore_current_language): Remove.
3904 * utils.c (do_restore_current_language)
3905 (make_cleanup_restore_current_language): Remove.
3906 * parse.c (parse_exp_in_context_1)
3907 (parse_expression_with_language): Use
3908 scoped_restore_current_language.
3909 * mi/mi-main.c (mi_cmd_execute): Use
3910 scoped_restore_current_language.
3911 * language.h (scoped_restore_current_language): New class.
3912
3913 2017-08-03 Tom Tromey <tom@tromey.com>
3914
3915 * compile/compile.c (cleanup_unlink_file): Remove.
3916 (compile_to_object): Use gdb::unlinker.
3917 (eval_compile_command): Likewise.
3918
3919 2017-08-03 Tom Tromey <tom@tromey.com>
3920
3921 * utils.h (make_cleanup_fclose): Remove.
3922 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
3923
3924 2017-08-03 Tom Tromey <tom@tromey.com>
3925
3926 * top.c (open_terminal_stream): Return gdb_file_up.
3927 (new_ui_command): Update.
3928
3929 2017-08-03 Tom Tromey <tom@tromey.com>
3930
3931 * source.c (print_source_lines_base, forward_search_command)
3932 (reverse_search_command): Use gdb_file_up.
3933
3934 2017-08-03 Tom Tromey <tom@tromey.com>
3935
3936 * fbsd-nat.c (fbsd_find_memory_regions): Update.
3937
3938 2017-08-03 Tom Tromey <tom@tromey.com>
3939
3940 * cli/cli-cmds.c (find_and_open_script): Change return type.
3941 Remove "streamp" and "full_path" parameters.
3942 (source_script_with_search): Update.
3943 * auto-load.c (source_script_file): Update.
3944 * cli/cli-cmds.h (find_and_open_script): Change type.
3945 (open_script): New struct.
3946
3947 2017-08-03 Tom Tromey <tom@tromey.com>
3948
3949 * xml-support.c (xml_fetch_content_from_file): Update.
3950 * ui-file.c (stdio_file::open): Update.
3951 * tracefile-tfile.c (tfile_start): Update.
3952 * remote.c (remote_file_put, remote_file_get): Update.
3953 * nat/linux-procfs.c (linux_proc_get_int)
3954 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
3955 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
3956 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
3957 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
3958 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
3959 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
3960 * linux-nat.c (linux_proc_pending_signals): Update.
3961 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
3962 (file_closer): Remove.
3963 * compile/compile.c (compile_to_object): Update.
3964 * common/filestuff.h (struct gdb_file_deleter): New.
3965 (gdb_file_up): New typedef.
3966 (gdb_fopen_cloexec): Change return type.
3967 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
3968 * cli/cli-dump.c (fopen_with_cleanup): Remove.
3969 (dump_binary_file, restore_binary_file): Update.
3970 * auto-load.c (auto_load_objfile_script_1): Update.
3971
3972 2017-08-03 Tom Tromey <tom@tromey.com>
3973
3974 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
3975 (info_static_tracepoint_markers_command): Likewise.
3976 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
3977 * skip.c (skip_info): Use ui_out_emit_table.
3978 * progspace.c (print_program_space): Use ui_out_emit_table.
3979 * osdata.c (info_osdata): Use ui_out_emit_table.
3980 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
3981 ui_out_emit_table.
3982 * linux-thread-db.c (info_auto_load_libthread_db): Use
3983 ui_out_emit_table.
3984 * inferior.c (print_inferior): Use ui_out_emit_table.
3985 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
3986 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
3987 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
3988 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
3989 * ui-out.h (class ui_out_emit_table): New.
3990
3991 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
3992
3993 * mips-tdep.c (mips_fpu_type_str): New function.
3994 (mips_dump_tdep): Call it.
3995
3996 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
3997
3998 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
3999 `->mips_fpu_type'.
4000
4001 2017-07-31 Xavier Roirand <roirand@adacore.com>
4002
4003 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
4004
4005 2017-07-27 Xavier Roirand <roirand@adacore.com>
4006
4007 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
4008
4009 2017-07-26 Yao Qi <yao.qi@linaro.org>
4010
4011 * cli/cli-cmds.c (maintenancechecklist): New variable.
4012 * gdbcmd.h (maintenancechecklist): Declare it.
4013 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
4014 Call i386_linux_read_description with different masks.
4015 * maint.c (maintenance_check_command): New function.
4016 (_initialize_maint_cmds): Call add_prefix_cmd.
4017 * target-descriptions.c (tdesc_reg): override operator != and ==.
4018 (tdesc_type): Likewise.
4019 (tdesc_feature): Likewise.
4020 (target_desc): Likewise.
4021 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
4022 (maintenance_check_xml_descriptions): New function.
4023 (_initialize_target_descriptions) Add command "xml-descriptions".
4024 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
4025
4026 2017-07-26 Yao Qi <yao.qi@linaro.org>
4027
4028 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
4029 Include features/i386/32bit-*.c.
4030 (i386_linux_read_description): Generate target description if it
4031 doesn't exist.
4032 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
4033 functions.
4034 * features/i386/32bit-linux.c: Re-generated.
4035 * features/i386/32bit-sse.c: Likewise.
4036 * target-descriptions.c (print_c_feature::visit): Print code to
4037 set register number if needed.
4038 (print_c_feature) <m_next_regnum>: New field.
4039
4040 2017-07-26 Yao Qi <yao.qi@linaro.org>
4041
4042 * features/Makefile (CFILES): Rename with TDESC_CFILES.
4043 (FEATURE_XMLFILES): New.
4044 (FEATURE_CFILES): New.
4045 New rules.
4046 (clean-cfiles): Remove generated c files.
4047 * features/i386/32bit-avx.c: Generated.
4048 * features/i386/32bit-avx512.c: Generated.
4049 * features/i386/32bit-core.c: Generated.
4050 * features/i386/32bit-linux.c: Generated.
4051 * features/i386/32bit-mpx.c: Generated.
4052 * features/i386/32bit-pkeys.c: Generated.
4053 * features/i386/32bit-sse.c: Generated.
4054 * target-descriptions.c: Include algorithm.
4055 (tdesc_element_visitor): Add method visit_end.
4056 (print_c_tdesc): Implement visit_end.
4057 (print_c_tdesc:: m_filename_after_features): Move it to
4058 protected.
4059 (print_c_feature): New class.
4060 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
4061 name starts with "i386/32bit-".
4062
4063 2017-07-26 Yao Qi <yao.qi@linaro.org>
4064
4065 * target-descriptions.c (tdesc_element_visitor): New class.
4066 (tdesc_element): New class.
4067 (tdesc_reg): Inherit from tdesc_element.
4068 (tdesc_reg::accept): New function.
4069 (tdesc_type): Inherit from tdesc_element.
4070 (tdesc_type::accept): New function.
4071 (tdesc_feature): Inherit from tdesc_element.
4072 (tdesc_feature::accept): New function.
4073 (target_desc): Inherit from tdesc_element.
4074 (target_desc::target_desc): New.
4075 (target_desc::~target_desc): New.
4076 (target_desc::accept): New.
4077 (allocate_target_description): Use new.
4078 (free_target_description): Use delete.
4079 (print_c_tdesc): New class.
4080 (maint_print_c_tdesc_cmd): Adjust.
4081
4082 * features/aarch64.c: Re-generated.
4083 * features/arc-arcompact.c: Re-generated.
4084 * features/arc-v2.c: Re-generated.
4085 * features/arm/arm-with-iwmmxt.c: Re-generated.
4086 * features/arm/arm-with-m.c: Re-generated.
4087 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
4088 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
4089 * features/arm/arm-with-neon.c: Re-generated.
4090 * features/arm/arm-with-vfpv2.c: Re-generated.
4091 * features/arm/arm-with-vfpv3.c: Re-generated.
4092 * features/i386/amd64-avx-avx512.c: Re-generated.
4093 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4094 * features/i386/amd64-avx.c: Re-generated.
4095 * features/i386/amd64-avx-linux.c: Re-generated.
4096 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
4097 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4098 * features/i386/amd64-avx-mpx.c: Re-generated.
4099 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
4100 * features/i386/amd64.c: Re-generated.
4101 * features/i386/amd64-linux.c: Re-generated.
4102 * features/i386/amd64-mpx.c: Re-generated.
4103 * features/i386/amd64-mpx-linux.c: Re-generated.
4104 * features/i386/i386-avx-avx512.c: Re-generated.
4105 * features/i386/i386-avx-avx512-linux.c: Re-generated.
4106 * features/i386/i386-avx.c: Re-generated.
4107 * features/i386/i386-avx-linux.c: Re-generated.
4108 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
4109 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
4110 * features/i386/i386-avx-mpx.c: Re-generated.
4111 * features/i386/i386-avx-mpx-linux.c: Re-generated.
4112 * features/i386/i386.c: Re-generated.
4113 * features/i386/i386-linux.c: Re-generated.
4114 * features/i386/i386-mmx.c: Re-generated.
4115 * features/i386/i386-mmx-linux.c: Re-generated.
4116 * features/i386/i386-mpx.c: Re-generated.
4117 * features/i386/i386-mpx-linux.c: Re-generated.
4118 * features/i386/x32-avx-avx512.c: Re-generated.
4119 * features/i386/x32-avx-avx512-linux.c: Re-generated.
4120 * features/i386/x32-avx.c: Re-generated.
4121 * features/i386/x32-avx-linux.c: Re-generated.
4122 * features/i386/x32.c: Re-generated.
4123 * features/i386/x32-linux.c: Re-generated.
4124 * features/microblaze.c: Re-generated.
4125 * features/microblaze-with-stack-protect.c: Re-generated.
4126 * features/mips64-dsp-linux.c: Re-generated.
4127 * features/mips64-linux.c: Re-generated.
4128 * features/mips-dsp-linux.c: Re-generated.
4129 * features/mips-linux.c: Re-generated.
4130 * features/nds32.c: Re-generated.
4131 * features/nios2.c: Re-generated.
4132 * features/nios2-linux.c: Re-generated.
4133 * features/rs6000/powerpc-32.c: Re-generated.
4134 * features/rs6000/powerpc-32l.c: Re-generated.
4135 * features/rs6000/powerpc-403.c: Re-generated.
4136 * features/rs6000/powerpc-403gc.c : Re-generated.
4137 * features/rs6000/powerpc-405.c: Re-generated.
4138 * features/rs6000/powerpc-505.c: Re-generated.
4139 * features/rs6000/powerpc-601.c: Re-generated.
4140 * features/rs6000/powerpc-602.c: Re-generated.
4141 * features/rs6000/powerpc-603.c: Re-generated.
4142 * features/rs6000/powerpc-604.c: Re-generated.
4143 * features/rs6000/powerpc-64.c: Re-generated.
4144 * features/rs6000/powerpc-64l.c: Re-generated.
4145 * features/rs6000/powerpc-7400.c: Re-generated.
4146 * features/rs6000/powerpc-750.c: Re-generated.
4147 * features/rs6000/powerpc-860.c: Re-generated.
4148 * features/rs6000/powerpc-altivec32.c: Re-generated.
4149 * features/rs6000/powerpc-altivec32l.c: Re-generated.
4150 * features/rs6000/powerpc-altivec64.c: Re-generated.
4151 * features/rs6000/powerpc-altivec64l.c: Re-generated.
4152 * features/rs6000/powerpc-cell32l.c: Re-generated.
4153 * features/rs6000/powerpc-cell64l.c: Re-generated.
4154 * features/rs6000/powerpc-e500.c: Re-generated.
4155 * features/rs6000/powerpc-e500l.c: Re-generated.
4156 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
4157 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
4158 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
4159 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
4160 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
4161 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
4162 * features/rs6000/powerpc-vsx32.c: Re-generated.
4163 * features/rs6000/powerpc-vsx32l.c: Re-generated.
4164 * features/rs6000/powerpc-vsx64.c: Re-generated.
4165 * features/rs6000/powerpc-vsx64l.c: Re-generated.
4166 * features/rs6000/rs6000.c: Re-generated.
4167 * features/s390-linux32.c: Re-generated.
4168 * features/s390-linux32v1.c: Re-generated.
4169 * features/s390-linux32v2.c: Re-generated.
4170 * features/s390-linux64.c: Re-generated.
4171 * features/s390-linux64v1.c: Re-generated.
4172 * features/s390-linux64v2.c: Re-generated.
4173 * features/s390-te-linux64.c: Re-generated.
4174 * features/s390-tevx-linux64.c: Re-generated.
4175 * features/s390-vx-linux64.c: Re-generated.
4176 * features/s390x-linux64.c: Re-generated.
4177 * features/s390x-linux64v1.c: Re-generated.
4178 * features/s390x-linux64v2.c: Re-generated.
4179 * features/s390x-te-linux64.c: Re-generated.
4180 * features/s390x-tevx-linux64.c: Re-generated.
4181 * features/s390x-vx-linux64.c: Re-generated.
4182 * features/sparc/sparc32-solaris.c: Re-generated.
4183 * features/sparc/sparc64-solaris.c: Re-generated.
4184 * features/tic6x-c62x.c: Re-generated.
4185 * features/tic6x-c62x-linux.c: Re-generated.
4186 * features/tic6x-c64x.c: Re-generated.
4187 * features/tic6x-c64x-linux.c: Re-generated.
4188 * features/tic6x-c64xp.c: Re-generated.
4189 * features/tic6x-c64xp-linux.c: Re-generated.
4190
4191 2017-07-26 Yao Qi <yao.qi@linaro.org>
4192
4193 * i386-linux-tdep.c (i386_linux_read_description): New function.
4194 (i386_linux_core_read_description): Call
4195 i386_linux_read_description.
4196 * i386-linux-tdep.h (i386_linux_read_description): Declare.
4197 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
4198 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
4199 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
4200 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
4201 * x86-linux-nat.c (x86_linux_read_description): Call
4202 i386_linux_read_description.
4203
4204 2017-07-26 Yao Qi <yao.qi@linaro.org>
4205
4206 * NEWS: Mention it.
4207 * features/Makefile (%.c: %.xml): Pass the xml file name to
4208 command "maint print c-tdesc".
4209 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
4210 name from 'arg'.
4211
4212 2017-07-26 Yao Qi <yao.qi@linaro.org>
4213
4214 * target-descriptions.c (target_desc): Add ctor and dtor. Do
4215 in-class initialization.
4216 (tdesc_create_feature): Call new instead of XCNEW.
4217 (free_target_description): Ue delete.
4218
4219 2017-07-25 John Baldwin <jhb@FreeBSD.org>
4220
4221 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
4222
4223 2017-07-25 Yao Qi <yao.qi@linaro.org>
4224
4225 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
4226 constant.
4227 (amd64_x32_init_abi): Likewise.
4228 * amd64-tdep.h (amd64_init_abi): Update declaration.
4229 (amd64_x32_init_abi): Likewise.
4230
4231 2017-07-25 Yao Qi <yao.qi@linaro.org>
4232
4233 PR tdep/21717
4234 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
4235 condition for FPSCR.
4236 (arm_linux_store_inferior_registers): Likewise.
4237
4238 2017-07-22 Tom Tromey <tom@tromey.com>
4239
4240 * break-catch-syscall.c (struct catch_syscall_inferior_data)
4241 <syscalls_counts>: Now a std::vector.
4242 (get_catch_syscall_inferior_data): Use "new".
4243 (catch_syscall_inferior_data_cleanup): Use "delete".
4244 (insert_catch_syscall, remove_catch_syscall)
4245 (clear_syscall_counts): Update.
4246
4247 2017-07-22 Tom Tromey <tom@tromey.com>
4248
4249 * break-catch-syscall.c (syscall_catchpoint)
4250 <syscalls_to_be_caught>: Now a std::vector<int>
4251 (~syscall_catchpoint): Remove.
4252 (insert_catch_syscall, remove_catch_syscall)
4253 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
4254 (print_mention_catch_syscall, print_recreate_catch_syscall):
4255 Update.
4256 (create_syscall_event_catchpoint): Change type of "filter"
4257 parameter.
4258 (catch_syscall_split_args): Return a std::vector.
4259 (catch_syscall_command_1, catching_syscall_number_1): Update.
4260
4261 2017-07-22 Tom Tromey <tom@tromey.com>
4262
4263 * break-catch-throw.c (struct exception_catchpoint)
4264 <exception_rx>: Now a std::string.
4265 (~exception_catchpoint): Remove.
4266 (print_one_detail_exception_catchpoint): Update.
4267 (handle_gnu_v3_exceptions): Change type of except_rx.
4268 (extract_exception_regexp): Return a std::string.
4269 (catch_exception_command_1): Update.
4270
4271 2017-07-22 Tom Tromey <tom@tromey.com>
4272
4273 * break-catch-sig.c (gdb_signal_type): Remove typedef.
4274 (struct signal_catchpoint) <signals_to_be_caught>: Now a
4275 std::vector.
4276 <catch_all>: Now a bool.
4277 (~signal_catchpoint): Remove.
4278 (signal_catchpoint_insert_location)
4279 (signal_catchpoint_remove_location)
4280 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
4281 (signal_catchpoint_print_mention)
4282 (signal_catchpoint_print_recreate)
4283 (signal_catchpoint_explains_signal): Update.
4284 (create_signal_catchpoint): Change type of "filter" and
4285 "catch_all".
4286 (catch_signal_split_args): Return a std::vector. Change type of
4287 "catch_all".
4288 (catch_signal_command): Update.
4289
4290 2017-07-20 Pedro Alves <palves@redhat.com>
4291
4292 * ada-lang.c (ada_language_defn): Make extern.
4293 (_initialize_ada_language): Remove add_language call.
4294 * c-lang.c (c_language_defn, cplus_language_defn)
4295 (asm_language_defn, minimal_language_defn): Make extern.
4296 (_initialize_c_language): Delete.
4297 * completer.c (compare_cstrings): Delete, moved to utils.h.
4298 * d-lang.c (d_language_defn): Make extern.
4299 (_initialize_d_language): Remove add_language calls.
4300 * defs.h (enum language): Add comment.
4301 * f-lang.c (f_language_defn): Make extern.
4302 (_initialize_f_language): Remove add_language call.
4303 * go-lang.c (go_language_defn): Make extern.
4304 (_initialize_go_language): Remove add_language call.
4305 * language.c: Include <algorithm>.
4306 (languages): Redefine as const array.
4307 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
4308 (set_language_command): Handle "local". Use for-range loop.
4309 (set_language): Remove loop.
4310 (language_enum): Rewrite.
4311 (language_def, language_str): Remove loops.
4312 (add_language): Delete.
4313 (add_set_language_command): New, based on add_languages.
4314 (skip_language_trampoline): Adjust.
4315 (local_language_defn): Delete.
4316 (language_gdbarch_post_init): Adjust.
4317 (_initialize_language): Remove add_language calls. Call
4318 add_set_language_command.
4319 * language.h (add_language): Delete.
4320 (auto_language_defn)
4321 (unknown_language_defn, minimal_language_defn, ada_language_defn)
4322 (asm_language_defn, c_language_defn, cplus_language_defn)
4323 (d_language_defn, f_language_defn, go_language_defn)
4324 (m2_language_defn, objc_language_defn, opencl_language_defn)
4325 (pascal_language_defn, rust_language_defn): Declare.
4326 * m2-lang.c (m2_language_defn): Make extern.
4327 (_initialize_m2_language): Remove add_language call.
4328 * objc-lang.c (objc_language_defn): Make extern.
4329 (_initialize_objc_language): Remove add_language call.
4330 * opencl-lang.c (opencl_language_defn): Make extern.
4331 (_initialize_opencl_language): Remove add_language call.
4332 * p-lang.c (pascal_language_defn): Make extern.
4333 (_initialize_pascal_language): Delete.
4334 * rust-lang.c (rust_language_defn): Make extern.
4335 (_initialize_rust_language): Delete.
4336 * utils.h (compare_cstrings): New static inline function.
4337
4338 2017-07-20 Pedro Alves <palves@redhat.com>
4339
4340 * ada-lang.c (ada_to_fixed_type_1): Adjust.
4341 (get_var_value): Constify parameters.
4342 (get_int_var_value): Change prototype.
4343 (to_fixed_range_type): Adjust.
4344 * ada-lang.h (get_int_var_value): Change prototype.
4345
4346 2017-07-20 Pedro Alves <palves@redhat.com>
4347
4348 * dwarf2read.c (dw2_lookup_symbol): Use
4349 SYMBOL_MATCHES_SEARCH_NAME.
4350 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
4351
4352 2017-07-20 Pedro Alves <palves@redhat.com>
4353
4354 * block.c (block_iter_name_step, block_iter_name_first)
4355 (block_iter_name_next): Delete.
4356 (block_lookup_symbol_primary): Adjust to use
4357 dict_iter_match_first/dict_iter_match_next.
4358 * block.h (block_iter_name_first, block_iter_name_next): Delete
4359 declarations.
4360 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
4361 dict_iter_match_first/dict_iter_match_next.
4362
4363 2017-07-20 Pedro Alves <palves@redhat.com>
4364
4365 * cp-support.c (cp_find_first_component_aux): Add missing case for
4366 end of string.
4367
4368 2017-07-18 David Blaikie <dblaikie@gmail.com>
4369
4370 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
4371 of dwo_cu's dwo_file.
4372
4373 2017-07-18 Yao Qi <yao.qi@linaro.org>
4374
4375 * remote.c (store_registers_using_G): Remove one line comment.
4376
4377 2017-07-18 Yao Qi <yao.qi@linaro.org>
4378
4379 * regcache.c (regcache_cpy): Simplify it.
4380 (regcache::cpy_no_passthrough): Remove it.
4381 * regcache.h (cpy_no_passthrough): Remove it.
4382 (regcache_dup, regcache_cpy): Update comments.
4383
4384 2017-07-18 Pedro Alves <palves@redhat.com>
4385
4386 * remote-sim.c (sim_command_completer): Adjust to work with a
4387 completion_tracker instead of a VEC.
4388
4389 2017-07-17 Pedro Alves <palves@redhat.com>
4390
4391 * completer.c (complete_source_filenames): New function.
4392 (complete_address_and_linespec_locations): New function.
4393 (location_completer): Use complete_address_and_linespec_locations.
4394 (completion_tracker::build_completion_result): Honor the tracker's
4395 request to suppress append.
4396 * completer.h (completion_tracker::suppress_append_ws)
4397 (completion_tracker::set_suppress_append_ws): New methods.
4398 (completion_tracker::m_suppress_append_ws): New field.
4399 (complete_source_filenames): New declaration.
4400 * linespec.c (linespec_complete_what): New.
4401 (struct ls_parser) <complete_what, completion_word,
4402 completion_quote_char, completion_quote_end, completion_tracker>:
4403 New fields.
4404 (string_find_incomplete_keyword_at_end): New.
4405 (linespec_lexer_lex_string): Record quote char. If in completion
4406 mode, don't throw.
4407 (linespec_lexer_consume_token): Advance the completion word point.
4408 (linespec_lexer_peek_token): Save/restore completion info.
4409 (save_stream_and_consume_token): New.
4410 (set_completion_after_number): New.
4411 (linespec_parse_basic): Set what to complete next depending on
4412 token. Handle function and label completions specially.
4413 (parse_linespec): Disable objc shortcut in completion mode. Set
4414 what to complete next depending on token type. Skip keyword if in
4415 completion mode.
4416 (complete_linespec_component, linespec_complete): New.
4417 * linespec.h (linespec_complete): Declare.
4418
4419 2017-07-17 Pedro Alves <palves@redhat.com>
4420
4421 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4422 Handle 'operator<' / 'operator<<'.
4423
4424 2017-07-17 Pedro Alves <palves@redhat.com>
4425
4426 * completer.c (collect_explicit_location_matches): Handle
4427 MATCH_LABEL.
4428 (convert_explicit_location_to_linespec): New, factored out from
4429 ...
4430 (convert_explicit_location_to_sals): ... this.
4431 (complete_label): New.
4432 (linespec_complete_label, find_label_symbols_in_block): New.
4433 (find_label_symbols): Add completion_mode parameter and adjust to
4434 call find_label_symbols_in_block.
4435 * linespec.h (linespec_complete_label): Declare.
4436
4437 2017-07-17 Pedro Alves <palves@redhat.com>
4438
4439 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4440 complete_symbol_mode parameter.
4441 * cli/cli-cmds.c (complete_command): Get the completion result out
4442 of the handle_brkchars tracker if used a custom word point.
4443 * completer.c: Include "linespec.h".
4444 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4445 (advance_to_expression_complete_word_point): New.
4446 (completion_tracker::completes_to_completion_word): New.
4447 (complete_files_symbols): Pass down
4448 complete_symbol_mode::EXPRESSION.
4449 (explicit_options, probe_options): New.
4450 (collect_explicit_location_matches): Complete on the
4451 explictit_loc->foo instead of word. Use
4452 linespec_complete_function. Handle MATCH_LINE. Handle offering
4453 keyword and options completions.
4454 (backup_text_ptr): Delete.
4455 (skip_keyword): New.
4456 (complete_explicit_location): Remove 'word' parameter. Add
4457 language, quoted_arg_start and quoted_arg_end parameters.
4458 Rewrite, parsing left to right.
4459 (location_completer): Rewrite.
4460 (location_completer_handle_brkchars): New function.
4461 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4462 (enum complete_line_internal_reason): Adjust comments.
4463 (completion_tracker::discard_completions): New.
4464 (completer_handle_brkchars_func_for_completer): Handle
4465 location_completer.
4466 (gdb_custom_word_point_brkchars)
4467 (gdb_org_rl_basic_quote_characters): New.
4468 (gdb_completion_word_break_characters_throw)
4469 (completion_find_completion_word): Handle trackers that use a
4470 custom word point.
4471 (completion_tracker::advance_custom_word_point_by): New.
4472 (completion_tracker::build_completion_result): Don't rely on
4473 readline appending the quote char.
4474 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4475 use a custom word point.
4476 (gdb_rl_attempted_completion_function): Restore
4477 rl_basic_quote_characters.
4478 * completer.h (class completion_tracker): Extend intro comment.
4479 (completion_tracker::set_quote_char)
4480 (completion_tracker::quote_char)
4481 (completion_tracker::set_use_custom_word_point)
4482 (completion_tracker::use_custom_word_point)
4483 (completion_tracker::custom_word_point)
4484 (completion_tracker::set_custom_word_point)
4485 (completion_tracker::advance_custom_word_point_by)
4486 (completion_tracker::completes_to_completion_word)
4487 (completion_tracker::discard_completions): New methods.
4488 (completion_tracker::m_quote_char)
4489 (completion_tracker::m_use_custom_word_point)
4490 (completion_tracker::m_custom_word_point): New fields.
4491 (advance_to_expression_complete_word_point): Declare.
4492 * f-lang.c (f_collect_symbol_completion_matches): Add
4493 complete_symbol_mode parameter.
4494 * language.h (struct language_defn)
4495 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4496 parameter.
4497 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4498 (linespec_complete_function): New function.
4499 (linespec_lexer_lex_keyword): Adjust.
4500 * linespec.h (linespec_keywords, linespec_complete_function): New
4501 declarations.
4502 * location.c (find_end_quote): New function.
4503 (explicit_location_lex_one): Add explicit_completion_info
4504 parameter. Save quoting info. Don't throw if being called for
4505 completion. Don't handle Ada operators here.
4506 (is_cp_operator, skip_op_false_positives, first_of)
4507 (explicit_location_lex_one_function): New function.
4508 (string_to_explicit_location): Replace 'dont_throw' parameter with
4509 an explicit_completion_info pointer parameter. Handle it. Don't
4510 use explicit_location_lex_one to lex function names. Use
4511 explicit_location_lex_one_function instead.
4512 * location.h (struct explicit_completion_info): New.
4513 (string_to_explicit_location): Replace 'dont_throw' parameter with
4514 an explicit_completion_info pointer parameter.
4515 * symtab.c (default_collect_symbol_completion_matches_break_on):
4516 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4517 (default_collect_symbol_completion_matches)
4518 (collect_symbol_completion_matches): Add complete_symbol_mode
4519 parameter.
4520 (collect_symbol_completion_matches_type): Pass down
4521 complete_symbol_mode::EXPRESSION.
4522 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4523 parameter. Handle LINESPEC mode.
4524 * symtab.h (complete_symbol_mode): New.
4525 (default_collect_symbol_completion_matches_break_on)
4526 (default_collect_symbol_completion_matches)
4527 (collect_symbol_completion_matches)
4528 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4529 parameter.
4530
4531 2017-07-17 Pedro Alves <palves@redhat.com>
4532
4533 * utils.c (enum class strncmp_iw_mode): New.
4534 (strcmp_iw): Rename to ...
4535 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4536 parameters. Handle them.
4537 (strncmp_iw): New.
4538 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4539 * utils.h (strncmp_iw): Declare.
4540 (strcmp_iw): Move describing comments here.
4541
4542 2017-07-17 Pedro Alves <palves@redhat.com>
4543
4544 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4545 CP_OPERATOR_STR.
4546 * c-typeprint.c (is_type_conversion_operator): Use
4547 CP_OPERATOR_STR.
4548 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4549 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4550 CP_OPERATOR_LEN.
4551 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4552 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4553 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4554 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4555 CP_OPERATOR_STR.
4556 * location.c: Include "cp-support.h".
4557 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4558 CP_OPERATOR_STR.
4559 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4560 CP_OPERATOR_LEN.
4561
4562 2017-07-17 Pedro Alves <palves@redhat.com>
4563
4564 * cli/cli-cmds.c (complete_command): Use a completion tracker
4565 along with completion_find_completion_word for handle_brkchars
4566 phase.
4567 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4568 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4569 (struct gdb_rl_completion_word_info): New.
4570 (gdb_rl_find_completion_word): New.
4571 (completion_find_completion_word): New.
4572 * completer.h (completion_find_completion_word): Declare.
4573
4574 2017-07-17 Pedro Alves <palves@redhat.com>
4575
4576 * ada-lang.c (symbol_completion_match): Adjust comments.
4577 (symbol_completion_add): Replace vector parameter with
4578 completion_tracker parameter. Use it.
4579 (ada_make_symbol_completion_list): Rename to...
4580 (ada_collect_symbol_completion_matches): ... this. Add
4581 completion_tracker parameter and use it.
4582 (ada_language_defn): Adjust.
4583 * break-catch-syscall.c (catch_syscall_completer): Adjust
4584 prototype and work with completion_tracker instead of VEC.
4585 * breakpoint.c (condition_completer): Adjust prototype and work
4586 with completion_tracker instead of VEC.
4587 * c-lang.c (c_language_defn, cplus_language_defn)
4588 (asm_language_defn, minimal_language_defn): Adjust to renames.
4589 * cli/cli-cmds.c (complete_command): Rework using
4590 completion_tracker. Catch exceptions when completing.
4591 * cli/cli-decode.c (integer_unlimited_completer)
4592 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4593 with completion_tracker instead of VEC.
4594 * command.h (struct completion_tracker): Forward declare.
4595 (completer_ftype, completer_handle_brkchars_ftype): Change
4596 types.
4597 (complete_on_cmdlist, complete_on_enum): Adjust.
4598 * completer.c: Include <algorithm>.
4599 (struct gdb_completer_state): New.
4600 (current_completion): New global.
4601 (readline_line_completion_function): Delete.
4602 (noop_completer, filename_completer)
4603 (filename_completer_handle_brkchars, complete_files_symbols)
4604 (linespec_location_completer): Adjust to work with a
4605 completion_tracker instead of a VEC.
4606 (string_or_empty): New.
4607 (collect_explicit_location_matches): Adjust to work with a
4608 completion_tracker instead of a VEC.
4609 (explicit_location_completer): Rename to ...
4610 (complete_explicit_location): ... this and adjust to work with a
4611 completion_tracker instead of a VEC.
4612 (location_completer): Adjust to work with a completion_tracker
4613 instead of a VEC.
4614 (add_struct_fields): Adjust to work with a completion_list instead
4615 of VEC.
4616 (expression_completer): Rename to ...
4617 (complete_expression): ... this and adjust to work with a
4618 completion_tracker instead of a VEC. Use complete_files_symbols.
4619 (expression_completer): Reimplement on top of complete_expression.
4620 (symbol_completer): Adjust to work with a completion_tracker
4621 instead of a VEC.
4622 (enum complete_line_internal_reason): Add describing comments.
4623 (complete_line_internal_normal_command): Adjust to work with a
4624 completion_tracker instead of a VEC.
4625 (complete_line_internal): Rename to ...
4626 (complete_line_internal_1): ... this and adjust to work with a
4627 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4628 handle_brkchars phase.
4629 (new_completion_tracker): Delete.
4630 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4631 complete_line_internal_1.
4632 (free_completion_tracker): Delete.
4633 (INITIAL_COMPLETION_HTAB_SIZE): New.
4634 (completion_tracker::completion_tracker)
4635 (completion_tracker::~completion_tracker): New.
4636 (maybe_add_completion): Delete.
4637 (completion_tracker::maybe_add_completion)
4638 (completion_tracker::add_completion)
4639 (completion_tracker::add_completions): New.
4640 (throw_max_completions_reached_error): Delete.
4641 (complete_line): Adjust to work with a completion_tracker instead
4642 of a VEC. Don't create a completion_tracker_t or check for max
4643 completions here.
4644 (command_completer, command_completer_handle_brkchars)
4645 (signal_completer, reg_or_group_completer_1)
4646 (reg_or_group_completer, default_completer_handle_brkchars):
4647 Adjust to work with a completion_tracker.
4648 (gdb_completion_word_break_characters_throw): New.
4649 (gdb_completion_word_break_characters): Reimplement.
4650 (line_completion_function): Delete.
4651 (completion_tracker::recompute_lowest_common_denominator)
4652 (expand_preserving_ws)
4653 (completion_tracker::build_completion_result)
4654 (completion_result::completion_result)
4655 (completion_result::completion_result)
4656 (completion_result::~completion_result)
4657 (completion_result::completion_result)
4658 (completion_result::release_match_list, compare_cstrings)
4659 (completion_result::sort_match_list)
4660 (completion_result::reset_match_list)
4661 (gdb_rl_attempted_completion_function_throw)
4662 (gdb_rl_attempted_completion_function): New.
4663 * completer.h (completion_list, struct completion_result)
4664 (class completion_tracker): New.
4665 (complete_line): Add completion_tracker parameter.
4666 (readline_line_completion_function): Delete.
4667 (gdb_rl_attempted_completion_function): New.
4668 (noop_completer, filename_completer, expression_completer)
4669 (location_completer, symbol_completer, command_completer)
4670 (signal_completer, reg_or_group_completer): Update prototypes.
4671 (completion_tracker_t, new_completion_tracker)
4672 (make_cleanup_free_completion_tracker): Delete.
4673 (enum maybe_add_completion_enum): Delete.
4674 (maybe_add_completion): Delete.
4675 (throw_max_completions_reached_error): Delete.
4676 * corefile.c (complete_set_gnutarget): Adjust to work with a
4677 completion_tracker instead of a VEC.
4678 * cp-abi.c (cp_abi_completer): Adjust to work with a
4679 completion_tracker instead of a VEC.
4680 * d-lang.c (d_language_defn): Adjust.
4681 * disasm.c (disassembler_options_completer): Adjust to work with a
4682 completion_tracker instead of a VEC.
4683 * f-lang.c (f_make_symbol_completion_list): Rename to ...
4684 (f_collect_symbol_completion_matches): ... this. Adjust to work
4685 with a completion_tracker instead of a VEC.
4686 (f_language_defn): Adjust.
4687 * go-lang.c (go_language_defn): Adjust.
4688 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
4689 Adjust to work with a completion_tracker instead of a VEC.
4690 * infrun.c (handle_completer): Likewise.
4691 * interps.c (interpreter_completer): Likewise.
4692 * interps.h (interpreter_completer): Likewise.
4693 * language.c (unknown_language_defn, auto_language_defn)
4694 (local_language_defn): Adjust.
4695 * language.h (language_defn::la_make_symbol_completion_list):
4696 Rename to ...
4697 (language_defn::la_collect_symbol_completion_matches): ... this
4698 and adjust to work with a completion_tracker instead of a VEC.
4699 * m2-lang.c (m2_language_defn): Adjust.
4700 * objc-lang.c (objc_language_defn): Adjust.
4701 * opencl-lang.c (opencl_language_defn): Adjust.
4702 * p-lang.c (pascal_language_defn): Adjust.
4703 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
4704 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
4705 with a completion_tracker.
4706 * rust-lang.c (rust_language_defn): Adjust.
4707 * symtab.c (free_completion_list, do_free_completion_list)
4708 (return_val, completion_tracker): Delete.
4709 (completion_list_add_name, completion_list_add_symbol)
4710 (completion_list_add_msymbol, completion_list_objc_symbol)
4711 (completion_list_add_fields, add_symtab_completions): Add
4712 completion_tracker parameter and use it.
4713 (default_make_symbol_completion_list_break_on_1): Rename to...
4714 (default_collect_symbol_completion_matches_break_on): ... this.
4715 Add completion_tracker parameter and use it instead of allocating
4716 a completion tracker here.
4717 (default_make_symbol_completion_list_break_on): Delete old
4718 implementation.
4719 (default_make_symbol_completion_list): Delete.
4720 (default_collect_symbol_completion_matches): New.
4721 (make_symbol_completion_list): Delete.
4722 (collect_symbol_completion_matches): New.
4723 (make_symbol_completion_type): Rename to ...
4724 (collect_symbol_completion_matches_type): ... this. Add
4725 completion_tracker parameter and use it instead of VEC.
4726 (make_file_symbol_completion_list_1): Rename to...
4727 (collect_file_symbol_completion_matches): ... this. Add
4728 completion_tracker parameter and use it instead of VEC.
4729 (make_file_symbol_completion_list): Delete.
4730 (add_filename_to_list): Use completion_list instead of a VEC.
4731 (add_partial_filename_data::list): Now a completion_list.
4732 (make_source_files_completion_list): Work with a completion_list
4733 instead of a VEC.
4734 * symtab.h: Include "completer.h".
4735 (default_make_symbol_completion_list_break_on)
4736 (default_make_symbol_completion_list, make_symbol_completion_list)
4737 (make_symbol_completion_type, make_file_symbol_completion_list)
4738 (make_source_files_completion_list): Delete.
4739 (default_collect_symbol_completion_matches_break_on)
4740 (default_collect_symbol_completion_matches)
4741 (collect_symbol_completion_matches)
4742 (collect_symbol_completion_matches_type)
4743 (collect_file_symbol_completion_matches)
4744 (make_source_files_completion_list): New.
4745 * top.c (init_main): Don't install a rl_completion_entry_function
4746 hook. Install a rl_attempted_completion_function hook instead.
4747 * tui/tui-layout.c (layout_completer): Adjust to work with a
4748 completion_tracker.
4749 * tui/tui-regs.c (tui_reggroup_completer):
4750 * tui/tui-win.c (window_name_completer, focus_completer)
4751 (winheight_completer): Adjust to work with a completion_tracker.
4752 * value.c: Include "completer.h".
4753 (complete_internalvar): Adjust to work with a completion_tracker.
4754 * value.h (complete_internalvar): Likewise.
4755
4756 2017-07-17 Pedro Alves <palves@redhat.com>
4757
4758 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
4759 renames.
4760 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
4761 comments to completer_ftype's declaration.
4762 <completer_handle_brkchars>: Change type to
4763 completer_handle_brkchars_ftype.
4764 * command.h (completer_ftype): Add describing comment and give
4765 names to parameters.
4766 (completer_ftype_void): Rename to ...
4767 (completer_handle_brkchars_ftype) ... this. Add describing comment.
4768 (set_cmd_completer_handle_brkchars): Adjust.
4769 * completer.c (filename_completer_handle_brkchars): New function.
4770 (complete_line_internal_normal_command): New function, factored
4771 out from ...
4772 (complete_line_internal): ... here.
4773 (command_completer_handle_brkchars)
4774 (default_completer_handle_brkchars)
4775 (completer_handle_brkchars_func_for_completer): New functions.
4776 * completer.h (set_gdb_completion_word_break_characters): Delete
4777 declaration.
4778 (completer_handle_brkchars_func_for_completer): New declaration.
4779 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
4780 completer_handle_brkchars_func_for_completer.
4781
4782 2017-07-17 Pedro Alves <palves@redhat.com>
4783
4784 * completer.c (symbol_completer): New function, based on
4785 make_symbol_completion_list_fn.
4786 * completer.h (symbol_completer): New declaration.
4787 * guile/scm-cmd.c (cmdscm_completers): Adjust.
4788 * python/py-cmd.c (completers): Adjust.
4789 * symtab.c (make_symbol_completion_list_fn): Delete.
4790 * symtab.h (make_symbol_completion_list_fn): Delete.
4791 * cli/cli-decode.c (add_cmd): Adjust.
4792
4793 2017-07-17 Pedro Alves <palves@redhat.com>
4794
4795 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
4796 * dwarf2read.c: Include "filename-seen-cache.h".
4797 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
4798 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
4799 * filename-seen-cache.c: New file.
4800 * filename-seen-cache.h: New file.
4801 * symtab.c: Include "filename-seen-cache.h".
4802 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
4803 (create_filename_seen_cache, clear_filename_seen_cache)
4804 (delete_filename_seen_cache, filename_seen): Delete, parts moved
4805 to filename-seen-cache.h/filename-seen-cache.c.
4806 (output_source_filename, sources_info)
4807 (maybe_add_partial_symtab_filename)
4808 (make_source_files_completion_list): Adjust to use
4809 filename_seen_cache.
4810
4811 2017-07-17 Pedro Alves <palves@redhat.com>
4812
4813 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
4814 fields.
4815 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
4816 dwarf2_debug_sections*)): New.
4817 (dwarf2_per_objfile::dwarf2_per_objfile(const
4818 dwarf2_per_objfile&)): Declare as deleted.
4819 (dwarf2_per_objfile::operator=): Declare as deleted.
4820 (dwarf2_per_objfile::dwarf2_per_objfile)
4821 (dwarf2_per_objfile::~dwarf2_per_objfile)
4822 (dwarf2_per_objfile::free_cached_comp_units): New.
4823 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
4824 ctor. Call dwarf2_per_objfile's ctor manually.
4825 (dwarf2_locate_sections): Deleted/refactored as ...
4826 (dwarf2_per_objfile::locate_sections): ... this new method.
4827 (free_cached_comp_units): Defer to
4828 dwarf2_per_objfile::free_cached_comp_units.
4829 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
4830
4831 2017-07-14 Tom Tromey <tom@tromey.com>
4832
4833 PR rust/21764:
4834 * rust-exp.y (convert_ast_to_expression): Add "want_type"
4835 parameter.
4836 <UNOP_SIZEOF>: Split into separate case.
4837 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
4838
4839 2017-07-14 Tom Tromey <tom@tromey.com>
4840
4841 PR rust/21763:
4842 * symtab.c (symbol_matches_domain): Add language_rust to special
4843 case.
4844 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
4845 treat LOC_TYPEDEF symbols as variables.
4846
4847 2017-07-14 Pedro Alves <palves@redhat.com>
4848
4849 * symtab.c (make_file_symbol_completion_list_1): Iterate over
4850 symtabs matching all symtabs with SRCFILE as file name instead of
4851 only considering the first hit, with lookup_symtab.
4852
4853 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4854
4855 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
4856 operator_name parameters.
4857 (gen_expr): Update function call.
4858
4859 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4860
4861 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
4862 parameter.
4863 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
4864 Likewise.
4865 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
4866 parameter, use agent_expr::gdbarch instead, update function
4867 calls.
4868 (locexpr_tracepoint_var_ref): Likewise.
4869 (loclist_tracepoint_var_ref): Likewise.
4870 * ax-gdb.c (gen_trace_static_fields): Likewise.
4871 (gen_traced_pop): Likewise.
4872 (gen_frame_args_address): Likewise.
4873 (gen_frame_locals_address): Likewise.
4874 (gen_var_ref): Likewise.
4875 (gen_struct_ref_recursive): Likewise.
4876 (gen_static_field): Likewise.
4877 (gen_maybe_namespace_elt): Likewise.
4878 (gen_expr): Likewise.
4879 (gen_trace_for_var): Likewise.
4880 (gen_trace_for_expr): Likewise.
4881 (gen_trace_for_return_address): Likewise.
4882
4883 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4884
4885 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
4886 parameter.
4887 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
4888
4889 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4890
4891 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
4892 from ax, update calls.
4893 (gen_usual_arithmetic): Likewise.
4894 (gen_integral_promotions): Likewise.
4895 (gen_bitfield_ref): Likewise.
4896 (gen_primitive_field): Likewise.
4897 (gen_struct_ref_recursive): Likewise.
4898 (gen_struct_ref): Likewise.
4899 (gen_maybe_namespace_elt): Likewise.
4900 (gen_struct_elt_for_reference): Likewise.
4901 (gen_namespace_elt): Likewise.
4902 (gen_aggregate_elt_ref): Likewise.
4903 (gen_expr): Get gdbarch from ax, update calls.
4904 (gen_expr_binop_rest): Likewise.
4905
4906 2017-07-13 Pedro Alves <palves@redhat.com>
4907
4908 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
4909 as default tdesc.
4910 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
4911 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
4912 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
4913 tdesc_amd64_linux as default tdesc. Get final tdesc from the
4914 tdep.
4915 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
4916 Get final tdesc from the tdep.
4917 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
4918 default tdesc.
4919 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4920 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4921 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
4922 Use it as default tdesc.
4923 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
4924 down to amd_init_abi. No longer handle fallback tdesc here.
4925 * amd64-tdep.h (tdesc_x32): Declare.
4926 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
4927 parameter.
4928 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
4929 as default tdesc.
4930
4931 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4932
4933 * s390-linux-tdep.c (s390_process_record): Add support for
4934 instructions new in arch12.
4935
4936 2017-07-11 John Baldwin <jhb@FreeBSD.org>
4937
4938 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
4939 PT_GETFSBASE and PT_GETGSBASE.
4940 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
4941 PT_SETGSBASE.
4942
4943 2017-07-11 John Baldwin <jhb@FreeBSD.org>
4944
4945 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
4946 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
4947 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
4948 those rules.
4949 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
4950 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
4951 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
4952 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
4953 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
4954 * features/i386/amd64.xml: Add 64bit-segments.xml.
4955 * features/i386/amd64-avx-avx512.c: Regenerated.
4956 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
4957 * features/i386/amd64-avx-mpx.c: Regenerated.
4958 * features/i386/amd64-avx.c: Regenerated.
4959 * features/i386/amd64-mpx.c: Regenerated.
4960 * features/i386/amd64.c: Regenerated.
4961 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
4962 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4963 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
4964 * regformats/i386/amd64-avx.dat: Regenerated.
4965 * regformats/i386/amd64-mpx.dat: Regenerated.
4966 * regformats/i386/amd64.dat: Regenerated.
4967
4968 2017-07-10 Yao Qi <yao.qi@linaro.org>
4969
4970 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4971 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4972
4973 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
4974
4975 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
4976 unsetenv.
4977 * gnulib/aclocal.m4: Regenerate.
4978 * gnulib/config.in: Regenerate.
4979 * gnulib/configure: Regenerate.
4980 * gnulib/import/Makefile.am: Regenerate.
4981 * gnulib/import/Makefile.in: Regenerate.
4982 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4983 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4984 * gnulib/import/m4/environ.m4: New file.
4985 * gnulib/import/m4/setenv.m4: New file.
4986 * gnulib/import/setenv.c: New file.
4987 * gnulib/import/unsetenv.c: New file.
4988
4989 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
4990
4991 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
4992 address when op is DW_OP_addr.
4993
4994 2017-07-09 Tom Tromey <tom@tromey.com>
4995
4996 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
4997 check and apply to outer type.
4998
4999 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5000
5001 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
5002 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
5003 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
5004 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
5005
5006 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5007
5008 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
5009
5010 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5011
5012 * corelow.c (get_core_siginfo): Remove.
5013 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
5014 instead of get_core_siginfo.
5015 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
5016 * gdbarch.h: Re-generate.
5017 * gdbarch.c: Re-generate.
5018 * linux-tdep.c (linux_core_xfer_siginfo): New.
5019 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
5020
5021 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5022
5023 * corelow.c (thread_section_name): Move to ...
5024 * gdbcore.h (thread_section_name): ... here.
5025
5026 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5027
5028 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
5029 (struct siginfo32): New.
5030 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
5031 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
5032 via ptrace(PT_LWPINFO).
5033
5034 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5035
5036 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
5037 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
5038 (fbsd_get_siginfo_type): New.
5039 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
5040 (_initialize_fbsd_tdep): New.
5041
5042 2017-07-06 David Blaikie <dblaikie@gmail.com>
5043
5044 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
5045 a singular dwo_unit*) to support multiple CUs in the same way that
5046 multiple TUs are supported.
5047 (create_cus_hash_table): Replace create_dwo_cu with a function for
5048 parsing multiple CUs from a DWO file.
5049 (open_and_init_dwo_file): Use create_cus_hash_table rather than
5050 create_dwo_cu.
5051 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
5052 htab_find, rather than comparing the signature to a singleton CU in
5053 the dwo_file.
5054
5055 2017-07-06 Pedro Alves <palves@redhat.com>
5056
5057 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
5058
5059 2017-07-04 Pedro Alves <palves@redhat.com>
5060
5061 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
5062 * gdbtypes.h (TYPE_STATIC): Delete.
5063 (struct fn_field) <is_public, is_abstract, is_static, is_final,
5064 is_synchronized, is_native>: Delete.
5065 <dummy>: Bump.
5066 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
5067 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
5068 (TYPE_FN_FIELD_ABSTRACT): Delete.
5069
5070 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
5071
5072 * buffer.h (buffer_finish): Fix spelling mistakes.
5073
5074 2017-07-01 Eli Zaretskii <eliz@gnu.org>
5075
5076 * .dir-locals.el: Automatically switch to C-style comments in
5077 versions of Emacs that support the feature.
5078
5079 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5080 Pedro Alves <palves@redhat.com>
5081
5082 PR cli/21688
5083 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
5084 (process_next_line): New variable 'inline_cmd'.
5085 Adjust 'if' clauses for "python", "compile" and "guile" to use
5086 'command_name_equals' and check for '!inline_cmd'.
5087
5088 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5089
5090 PR cli/21688
5091 * cli/cli-script.c (command_name_equals_not_inline): New function.
5092 (process_next_line): Adjust 'if' clauses for "python", "compile"
5093 and "guile" to use command_name_equals_not_inline.
5094
5095 2017-06-29 Pedro Alves <palves@redhat.com>
5096
5097 * completer.c (expression_completer): Call
5098 linespec_location_completer instead of location_completer.
5099
5100 2017-06-29 Pedro Alves <palves@redhat.com>
5101
5102 * completer.c (expression_completer): Remove code that recomputes
5103 'text' from 'word'.
5104
5105 2017-06-29 Yao Qi <yao.qi@linaro.org>
5106
5107 * regformats/regdat.sh: Generate code with
5108 "ifndef IN_PROCESS_AGENT".
5109
5110 2017-06-28 Pedro Alves <palves@redhat.com>
5111
5112 * command.h: Include "common/scoped_restore.h".
5113
5114 2017-06-28 Yao Qi <yao.qi@linaro.org>
5115
5116 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
5117 instead of obstack_grow.
5118
5119 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
5120
5121 PR gdb/21337
5122 * symfile.c (reread_symbols): Call objfiles_changed just before
5123 read_symbols.
5124
5125 2017-06-27 Pedro Alves <palves@redhat.com>
5126
5127 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
5128 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
5129 (completion_list_add_symbol, completion_list_add_msymbol):
5130 ... these new functions.
5131 (add_symtab_completions)
5132 (default_make_symbol_completion_list_break_on_1): Adjust.
5133
5134 2017-06-27 Pedro Alves <palves@redhat.com>
5135
5136 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
5137 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
5138 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
5139 dtor.
5140 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
5141 'storage_obstack' field an auto_obstack. In-class initialize all
5142 non-bitfield fields. Make minsyms_read bool.
5143 * symfile.c (read_symbols): Adjust.
5144
5145 2017-06-27 Alan Hayward <alan.hayward@arm.com>
5146
5147 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
5148 (gdbsim_store_register): Likewise.
5149
5150 2017-06-27 Pedro Alves <palves@redhat.com>
5151
5152 * c-exp.y (name_obstack): Now an auto_obstack.
5153 (yylex): Use auto_obstack::clear.
5154 (c_parse): Use auto_obstack::clear instead of reinitializing and
5155 freeing the obstack.
5156 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
5157 * d-exp.y (name_obstack): Now an auto_obstack.
5158 (yylex): Use auto_obstack::clear.
5159 (d_parse): Use auto_obstack::clear instead of reinitializing and
5160 freeing the obstack.
5161 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
5162 auto_obstack.
5163 * dwarf2read.c (create_addrmap_from_index)
5164 (dwarf2_build_psymtabs_hard)
5165 (update_enumeration_type_from_children): Likewise.
5166 * gdb_obstack.h (auto_obstack): New type.
5167 * go-exp.y (name_obstack): Now an auto_obstack.
5168 (build_packaged_name): Use auto_obstack::clear.
5169 (go_parse): Use auto_obstack::clear instead of reinitializing and
5170 freeing the obstack.
5171 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
5172 auto_obstack.
5173 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
5174 * rust-exp.y (work_obstack): Now an auto_obstack.
5175 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
5176 reinitializing and freeing the obstack.
5177 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
5178 (host_char_to_target): Use auto_obstack.
5179 * utils.h (make_cleanup_obstack_free): Delete declaration.
5180 * valprint.c (generic_emit_char, generic_printstr): Use
5181 auto_obstack.
5182
5183 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
5184
5185 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
5186 thread.
5187 (darwin_init_thread_list): Don't update dummy thread.
5188 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
5189
5190 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5191
5192 * record-full.c (netorder16): Remove.
5193
5194 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5195
5196 * common/diagnostics.h: Define macros for GCC.
5197 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
5198 * common/vec.h: Include diagnostics.h.
5199 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
5200 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
5201 warning.
5202
5203 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5204
5205 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
5206 New macro.
5207 * ada-lex.l: Ignore deprecated register warnings.
5208
5209 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5210
5211 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
5212 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
5213
5214 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5215
5216 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
5217 its own line.
5218
5219 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5220
5221 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
5222
5223 2017-06-23 Alan Hayward <alan.hayward@arm.com>
5224
5225 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
5226 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
5227 (xtensa_register_read_masked): Likewise.
5228
5229 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
5230
5231 * common/environ.c (gdb_environ::unset): Update comment.
5232
5233 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5234
5235 * python/py-unwind.c (pyuw_sniffer): Allocate space for
5236 registers.
5237
5238 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5239
5240 * record-full.c (record_full_exec_insn): Use byte_vector.
5241
5242 2017-06-22 Yao Qi <yao.qi@linaro.org>
5243
5244 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
5245 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5246
5247 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5248
5249 * remote.c (cached_reg): Move from here...
5250 * regcache.h (cached_reg): ...to here.
5251 * python/py-unwind.c (struct reg_info): Remove.
5252 (cached_frame_info): Use cached_reg_t.
5253 (pyuw_prev_register): Likewise.
5254 (pyuw_sniffer): Use cached_reg_t and allocate registers.
5255 (pyuw_dealloc_cache): Free all registers.
5256
5257 2017-06-22 Pedro Alves <palves@redhat.com>
5258 Simon Marchi <simon.marchi@ericsson.com>
5259
5260 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
5261 warning.
5262 * common/diagnostics.h: New file.
5263
5264 2017-06-22 Pedro Alves <palves@redhat.com>
5265
5266 * common/agent.h: Add include guards.
5267
5268 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
5269
5270 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
5271 talk about addressable units instead of bytes.
5272
5273 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5274
5275 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
5276 of '::const_iterator'.
5277
5278 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5279
5280 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5281 'unittests/environ-selftests.c'.
5282 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
5283 * charset.c (find_charset_names): Declare object 'iconv_env'.
5284 Update code to use 'iconv_env' object. Remove call to
5285 'free_environ'.
5286 * common/environ.c: Include <utility>.
5287 (make_environ): Delete function.
5288 (free_environ): Delete function.
5289 (gdb_environ::clear): New function.
5290 (gdb_environ::operator=): New function.
5291 (gdb_environ::get): Likewise.
5292 (environ_vector): Delete function.
5293 (set_in_environ): Delete function.
5294 (gdb_environ::set): New function.
5295 (unset_in_environ): Delete function.
5296 (gdb_environ::unset): New function.
5297 (gdb_environ::envp): Likewise.
5298 * common/environ.h: Include <vector>.
5299 (struct gdb_environ): Delete; transform into...
5300 (class gdb_environ): ... this class.
5301 (free_environ): Delete prototype.
5302 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
5303 environ_vector): Likewise.
5304 * infcmd.c (run_command_1): Update code to call
5305 'envp' from 'gdb_environ' class.
5306 (environment_info): Update code to call methods from 'gdb_environ'
5307 class.
5308 (unset_environment_command): Likewise.
5309 (path_info): Likewise.
5310 (path_command): Likewise.
5311 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
5312 (inferior::inferior): Initialize 'environment' using the host's
5313 information.
5314 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
5315 Include "environ.h".
5316 (class inferior) <environment>: Change type from 'struct
5317 gdb_environ' to 'gdb_environ'.
5318 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
5319 methods from 'gdb_environ' class.
5320 * solib.c (solib_find_1): Likewise
5321 * unittests/environ-selftests.c: New file.
5322
5323 2017-06-20 Yao Qi <yao.qi@linaro.org>
5324
5325 * features/i386/i386-linux.xml: Exchange the order of including
5326 32bit-linux.xml and 32bit-sse.xml.
5327 * features/i386/i386-linux.c: Regenerated.
5328
5329 2017-06-20 Yao Qi <yao.qi@linaro.org>
5330
5331 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
5332 Delete copy ctor and assignment operator.
5333 (tdesc_type): Likewise.
5334 (tdesc_feature): Likewise.
5335 (tdesc_free_reg): Remove.
5336 (tdesc_create_reg): Use new.
5337 (tdesc_free_type): Remove.
5338 (tdesc_create_vector): Use new.
5339 (tdesc_create_union): Likewise.
5340 (tdesc_create_flags): Likewise.
5341 (tdesc_create_enum): Likewise.
5342 (tdesc_free_feature): Delete.
5343 (free_target_description): Use delete.
5344
5345 2017-06-19 John Baldwin <jhb@FreeBSD.org>
5346
5347 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
5348 registers.
5349
5350 2017-06-19 Pedro Alves <palves@redhat.com>
5351
5352 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
5353 after gdb::unlinker.
5354
5355 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
5356
5357 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
5358 gdb_environ to access an environment variable.
5359
5360 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5361
5362 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
5363 gdb_byte*.
5364
5365 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5366
5367 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
5368
5369 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5370
5371 * configure: Re-generate.
5372 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
5373
5374 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5375
5376 * configure: Re-generate.
5377 * warning.m4: Pass -Werror to compiler when checking for
5378 supported warning flags.
5379
5380 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5381
5382 * Makefile.in (COMPILE.pre): Add "-x c++".
5383
5384 2017-06-16 Alan Hayward <alan.hayward@arm.com>
5385 Pedro Alves <palves@redhat.com>
5386 Yao Qi <yao.qi@linaro.org>
5387
5388 * defs.h (RequireLongest): New.
5389 (extract_integer): Declare function template.
5390 (extract_signed_integer): Remove the declaration, but define it
5391 static inline.
5392 (extract_unsigned_integer): Likewise.
5393 (store_integer): Declare function template.
5394 (store_signed_integer): Remove the declaration, but define it
5395 static inline.
5396 (store_unsigned_integer): Likewise.
5397 * findvar.c (extract_integer): New function template.
5398 (extract_signed_integer): Remove.
5399 (extract_unsigned_integer): Remove.
5400 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5401 instantiations.
5402 (store_integer): New function template.
5403 (store_signed_integer): Remove.
5404 (store_unsigned_integer): Remove.
5405 (store_integer): Explicit instantiations.
5406 * regcache.c (regcache_raw_read_signed): Update.
5407 (regcache::raw_read): New function.
5408 (regcache::raw_read_signed): Remove.
5409 (regcache::raw_read_unsigned): Remove.
5410 (regcache_raw_read_unsigned): Update.
5411 (regcache_raw_write_unsigned): Update.
5412 (regcache::raw_write_signed): Remove.
5413 (regcache::raw_write): New function.
5414 (regcache_cooked_read_signed): Update.
5415 (regcache::raw_write_unsigned): Remove.
5416 (regcache::cooked_read_signed): Remove.
5417 (regcache_cooked_read_unsigned): Update.
5418 (regcache::cooked_read_unsigned): Remove.
5419 (regcache_cooked_write_signed): Update.
5420 (regcache_cooked_write_unsigned): Update.
5421 * regcache.h (regcache) <raw_read_signed>: Remove.
5422 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5423 <raw_read, raw_write>: New.
5424 <cooked_read_signed, cooked_write_signed>: Remove.
5425 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5426 <cooked_read, cooked_write>: New.
5427 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5428 (sh64_pseudo_register_write): Update.
5429
5430 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5431
5432 * arc-tdep.c (arc_disassembler_options): New variable.
5433 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5434 of default_print_insn.
5435 (arc_delayed_print_insn): Set info->section when needed,
5436 use default_print_insn to retrieve a disassembler.
5437
5438 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5439
5440 PR gdb/21574
5441 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5442 to mention $SHELL and startup-with-shell.
5443
5444 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5445
5446 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5447
5448 2017-06-14 Yao Qi <yao.qi@linaro.org>
5449
5450 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5451 default_print_insn instead of print_insn_aarch64.
5452 * arm-tdep.c (gdb_print_insn_arm): Call
5453 default_print_insn instead of print_insn_big_arm
5454 and print_insn_little_arm.
5455 * i386-tdep.c (i386_print_insn): Call default_print_insn
5456 instead of print_insn_i386.
5457 * ia64-tdep.c (ia64_print_insn): Call
5458 default_print_insn instead of print_insn_ia64.
5459 * mips-tdep.c (gdb_print_insn_mips): Call
5460 default_print_insn instead of print_insn_big_mips
5461 and print_insn_little_mips.
5462 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5463 instead of print_insn_spu.
5464
5465 2017-06-14 Pedro Alves <palves@redhat.com>
5466
5467 * ada-lang.c: Include "common/byte-vector.h".
5468 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5469 * charset.c (wchar_iterator::iterate): Resize the vector instead
5470 of reserving it.
5471 * common/byte-vector.h: Include "common/def-vector.h".
5472 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5473 * cli/cli-dump.c: Include "common/byte-vector.h".
5474 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5475 * common/byte-vector.h: New file.
5476 * common/def-vector.h: New file.
5477 * common/default-init-alloc.h: New file.
5478 * dwarf2loc.c: Include "common/byte-vector.h".
5479 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5480 instead of reserving it.
5481 * dwarf2read.c: Include "common/byte-vector.h".
5482 (data_buf::m_vec): Now a gdb::byte_vector.
5483 * gdb_regex.c: Include "common/def-vector.h".
5484 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5485 * mi/mi-main.c: Include "common/byte-vector.h".
5486 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5487 * printcmd.c: Include "common/byte-vector.h".
5488 (print_scalar_formatted): Use gdb::byte_vector.
5489 * valprint.c: Include "common/byte-vector.h".
5490 (maybe_negate_by_bytes, print_decimal_chars): Use
5491 gdb::byte_vector.
5492
5493 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5494
5495 * darwin-nat.c: Include "nat/fork-inferior.h".
5496
5497 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5498
5499 * configure.nat: Factor out Darwin bits that are not
5500 architecture-specific. Add fork-inferior.o.
5501
5502 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5503
5504 * configure.nat: Factor out AIX bits that are not
5505 architecture-specific. Add fork-inferior.o.
5506
5507 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5508
5509 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5510 (read_pieced_value, write_pieced_value): ...here. Reduce to
5511 wrappers that just call rw_pieced_value.
5512
5513 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5514
5515 * dwarf2loc.c (write_pieced_value): When writing the data for a
5516 memory piece, use write_memory_with_notification instead of
5517 write_memory.
5518
5519 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5520
5521 * valops.c (read_value_memory): Change embedded_offset to
5522 represent a bit offset instead of a byte offset.
5523 * value.h (read_value_memory): Adjust comment.
5524
5525 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5526
5527 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5528 dest_offset_bits and source_offset_bits.
5529 (write_pieced_value): Likewise.
5530
5531 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5532
5533 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5534 given by DW_OP_bit_piece.
5535 (write_pieced_value): Likewise.
5536
5537 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5538
5539 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5540 some other preparations to the places where sufficient information
5541 is available.
5542 (write_pieced_value): Likewise.
5543
5544 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5545
5546 * dwarf2loc.c (bits_to_bytes): New function.
5547 (read_pieced_value): Fix offset calculations for register pieces
5548 on big-endian targets.
5549 (write_pieced_value): Likewise.
5550
5551 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5552
5553 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5554 (write_pieced_value): Likewise.
5555
5556 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5557
5558 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5559 transfer the source value's least significant bits, instead of its
5560 lowest-addressed ones. Rename type_len to max_offset.
5561 (read_pieced_value): Mirror above changes to write_pieced_value as
5562 applicable.
5563
5564 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5565
5566 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5567 truncate full bytes from dest_offset_bits before using it as an
5568 offset into the buffer.
5569
5570 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5571
5572 * dwarf2loc.c (write_pieced_value): Include transfer size in
5573 byte-wise check.
5574
5575 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5576
5577 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5578 calculation of this_size.
5579
5580 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5581
5582 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5583 when targeting a bit-field.
5584 (write_pieced_value): Likewise.
5585
5586 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5587
5588 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5589 (allocate_piece_closure): Drop addr_size parameter.
5590 (dwarf2_evaluate_loc_desc_full): Adjust call to
5591 allocate_piece_closure.
5592
5593 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5594
5595 PR gdb/21226
5596 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5597 the LSB end, independent of endianness.
5598
5599 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5600
5601 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5602 size capping.
5603
5604 2017-06-13 Yao Qi <yao.qi@linaro.org>
5605
5606 * mips-linux-nat.c: Move include features/mips*-linux.c to
5607 mips-linux-tdep.c.
5608 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5609 to mips-linux-tdep.c.
5610 * mips-linux-tdep.c: Include features/mips*-linux.c
5611 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5612 functions.
5613 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5614 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5615 (tdesc_mips64_dsp_linux): Declare.
5616
5617 2017-06-12 Tom Tromey <tom@tromey.com>
5618
5619 * valprint.h (val_print_type_code_int): Remove.
5620 * valprint.c (generic_val_print_int): Always call
5621 val_print_scalar_formatted.
5622 (val_print_type_code_int): Remove.
5623 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5624 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5625 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5626 * ada-valprint.c (ada_val_print_num): Use
5627 val_print_scalar_formatted.
5628
5629 2017-06-12 Tom Tromey <tom@tromey.com>
5630
5631 * printcmd.c (print_scalar_formatted): Unify the two switches.
5632 Don't convert scalars to LONGEST.
5633
5634 2017-06-12 Tom Tromey <tom@tromey.com>
5635
5636 PR exp/16225:
5637 * valprint.h (print_decimal_chars): Update.
5638 * valprint.c (maybe_negate_by_bytes): New function.
5639 (print_decimal_chars): Add "is_signed" argument.
5640 * printcmd.c (print_scalar_formatted): Update.
5641
5642 2017-06-12 Tom Tromey <tom@tromey.com>
5643
5644 PR exp/16225:
5645 * valprint.h (print_binary_chars, print_hex_chars): Update.
5646 * valprint.c (val_print_type_code_int): Update.
5647 (print_binary_chars): Add "zero_pad" argument.
5648 (emit_octal_digit): New function.
5649 (print_octal_chars): Don't zero-pad.
5650 (print_decimal_chars): Likewise.
5651 (print_hex_chars): Add "zero_pad" argument.
5652 * sh64-tdep.c (sh64_do_fp_register): Update.
5653 * regcache.c (regcache::dump): Update.
5654 * printcmd.c (print_scalar_formatted): Update.
5655 * infcmd.c (default_print_one_register_info): Update.
5656
5657 2017-06-12 Pedro Alves <palves@redhat.com>
5658 Alan Hayward <alan.hayward@arm.com>
5659
5660 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5661 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5662 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5663 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5664 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5665
5666 2017-06-12 Pedro Alves <palves@redhat.com>
5667
5668 * dwarf2read.c (mapped_symtab::data): Now a vector of
5669 symtab_index_entry instead of vector of
5670 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5671 whether an element's name is NULL instead of checking whether the
5672 element itself is NULL.
5673 (find_slot): Change return type. Adjust.
5674 (hash_expand, , add_index_entry, uniquify_cu_indices)
5675 (write_hash_table): Adjust.
5676
5677 2017-06-12 Pedro Alves <palves@redhat.com>
5678
5679 * dwarf2read.c (recursively_count_psymbols): New function.
5680 (write_psymtabs_to_index): Call it to compute number of psyms and
5681 pass estimate size of psyms_seen to unordered_set's ctor.
5682
5683 2017-06-12 Pedro Alves <palves@redhat.com>
5684
5685 * dwarf2read.c (write_hash_table): Check if key already exists
5686 before emplacing.
5687
5688 2017-06-12 Pedro Alves <palves@redhat.com>
5689
5690 * dwarf2read.c (data_buf::append_space): Rename to...
5691 (data_buf::grow): ... this, and make private. Adjust all callers.
5692 (data_buf::append_uint): New method.
5693 (add_address_entry, write_one_signatured_type)
5694 (write_psymtabs_to_index): Use it.
5695
5696 2017-06-12 Pedro Alves <palves@redhat.com>
5697
5698 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
5699 (file_write (FILE *, const std::vector<Elem>&)): Delete.
5700 (data_buf::file_write): Call ::fwrite directly.
5701
5702 2017-06-12 Pedro Alves <palves@redhat.com>
5703
5704 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
5705 std::vector::erase.
5706
5707 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5708
5709 Code cleanup: C++ify .gdb_index producer.
5710 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
5711 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
5712 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
5713 (create_strtab, add_string): Remove.
5714 (file_write, data_buf): New.
5715 (struct symtab_index_entry): Use std::vector for cu_indices.
5716 (struct mapped_symtab): Use std::vector for data.
5717 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
5718 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
5719 Remove.
5720 (find_slot): Change return type. Update it to the new data structures.
5721 (hash_expand, add_index_entry): Update it to the new data structures.
5722 (offset_type_compare): Remove.
5723 (uniquify_cu_indices): Update it to the new data structures.
5724 (c_str_view, c_str_view_hasher, vector_hasher): New.
5725 (add_indices_to_cpool): Remove.
5726 (write_hash_table): Update it to the new data structures.
5727 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
5728 (eq_psymtab_cu_index): Remove.
5729 (psym_index_map): New typedef.
5730 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
5731 reference and std::unordered_map for cu_index_htab.
5732 (add_address_entry, add_address_entry_worker, write_address_map)
5733 (write_psymbols): Update it to the new data structures.
5734 (write_obstack): Remove.
5735 (struct signatured_type_index_data): Change types_list to a data_buf
5736 reference and psyms_seen to a std::unordered_set reference.
5737 (write_one_signatured_type, recursively_write_psymbols)
5738 (write_psymtabs_to_index): Update it to the new data structures.
5739
5740 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
5741
5742 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
5743 separate-debug-file commands.
5744 * symfile.h (separate_debug_file_debug): New global.
5745 * symfile.c (separate_debug_file_debug): New global.
5746 (separate_debug_file_exists, find_separate_debug_file): Add
5747 debug output.
5748 (_initialize_symfile): Add "set debug separate-debug-file"
5749 command.
5750 * build-id.c (build_id_to_debug_bfd,
5751 find_separate_debug_file_by_buildid): Add debug output.
5752
5753 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5754
5755 * gdbarch.sh (displaced_step_free_closure): Remove.
5756 * gdbarch.h, gdbarch.c: Re-generate.
5757 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
5758 displaced_step_free_closure.
5759 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
5760 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
5761 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5762 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
5763 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5764 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5765 * arch-utils.h (simple_displaced_step_free_closure): Remove.
5766 * arch-utils.c (simple_displaced_step_free_closure): Remove.
5767 * infrun.c (displaced_step_clear): Call xfree instead of
5768 gdbarch_displaced_step_free_closure.
5769
5770 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
5771
5772 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
5773 NULL".
5774
5775 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5776
5777 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
5778 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
5779 (mn10300_push_dummy_call): Likewise.
5780
5781 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5782
5783 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
5784
5785 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5786
5787 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
5788
5789 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5790
5791 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
5792 able to start inferiors using a shell.
5793 (New remote packets): Announce new packet "QStartupWithShell".
5794 * remote.c: Add PACKET_QStartupWithShell.
5795 (extended_remote_create_inferior): Handle new
5796 PACKET_QStartupWithShell.
5797 (remote_protocol_features) <QStartupWithShell>: New entry for
5798 PACKET_QStartupWithShell.
5799 (_initialize_remote): Call "add_packet_config_cmd" for
5800 QStartupShell.
5801
5802 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5803 Pedro Alves <palves@redhat.com>
5804
5805 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
5806 and "nat/fork-inferior.h".
5807 * common/common-inferior.h: New file, with contents from
5808 "gdb/inferior.h".
5809 * commom/common-utils.c: Include "common-utils.h".
5810 (stringify_argv): New function.
5811 * common/common-utils.h (stringify_argv): New prototype.
5812 * configure.nat: Add "fork-inferior.o" as a dependency for
5813 "*linux*", "fbsd*" and "nbsd*" hosts.
5814 * corefile.c (get_exec_file): Update comment.
5815 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
5816 instead of "startup_inferior".
5817 (darwin_create_inferior): Call "add_thread_silent" after
5818 "fork_inferior".
5819 * fork-child.c: Cleanup unnecessary includes.
5820 (SHELL_FILE): Move to "common/common-fork-child.c".
5821 (environ): Likewise.
5822 (exec_wrapper): Initialize.
5823 (get_exec_wrapper): New function.
5824 (breakup_args): Move to "common/common-fork-child.c"; rename to
5825 "breakup_args_for_exec".
5826 (escape_bang_in_quoted_argument): Move to
5827 "common/common-fork-child.c".
5828 (saved_ui): New variable.
5829 (prefork_hook): New function.
5830 (postfork_hook): Likewise.
5831 (postfork_child_hook): Likewise.
5832 (gdb_startup_inferior): Likewise.
5833 (fork_inferior): Move to "common/common-fork-child.c". Update
5834 function to support gdbserver.
5835 (startup_inferior): Likewise.
5836 * gdbcore.h (get_exec_file): Remove declaration.
5837 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
5838 instead of "startup_inferior". Call "add_thread_silent" after
5839 "fork_inferior".
5840 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
5841 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
5842 instead of "startup_inferior". Call "add_thread_silent" after
5843 "fork_inferior".
5844 * inferior.h: Include "common-inferior.h".
5845 (trace_start_error): Move to "common/common-utils.h".
5846 (trace_start_error_with_name): Likewise.
5847 (fork_inferior): Move prototype to "nat/fork-inferior.h".
5848 (startup_inferior): Likewise.
5849 (gdb_startup_inferior): New prototype.
5850 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
5851 * nat/fork-inferior.h: New file.
5852 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
5853 instead of "startup_inferior". Call "add_thread_silent" after
5854 "fork_inferior".
5855 * target.h (target_terminal_init): Move prototype to
5856 "target/target.h".
5857 (target_terminal_inferior): Likewise.
5858 (target_terminal_ours): Likewise.
5859 * target/target.h (target_terminal_init): New prototype, moved
5860 from "target.h".
5861 (target_terminal_inferior): Likewise.
5862 (target_terminal_ours): Likewise.
5863 * utils.c (gdb_flush_out_err): New function.
5864
5865 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5866
5867 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
5868 * common/common-gdbthread.h: New file, with parts from
5869 "gdb/gdbthread.h".
5870 * gdbthread.h: Include "common-gdbthread.h".
5871 (switch_to_thread): Moved to "common/common-gdbthread.h".
5872
5873 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5874
5875 * Makefile.in (SFILES): Add "common/job-control.c".
5876 (HFILES_NO_SRCDIR): Add "common/job-control.h".
5877 (COMMON_OBS): Add "job-control.o".
5878 * common/job-control.c: New file, with contents from
5879 "gdb/inflow.c".
5880 * common/job-control.h: New file, with contents from "terminal.h".
5881 * fork-child.c: Include "job-control.h".
5882 * inflow.c: Include "job-control.h".
5883 (gdb_setpgid): Move to "common/common-inflow.c".
5884 (_initialize_inflow): Move setting of "job_control" to
5885 "handle_job_control".
5886 * terminal.h (job_control): Moved to "common/common-terminal.h".
5887 (gdb_setpgid): Likewise.
5888 * top.c: Include "job_control.h".
5889 * utils.c: Likewise.
5890 (job_control): Moved to "job-control.c".
5891
5892 2017-06-07 Pedro Alves <palves@redhat.com>
5893
5894 * Makefile.in (SFILES): Add gdb_regex.c.
5895 (COMMON_OBS): Add gdb_regex.o.
5896 * ada-lang.c (ada_add_standard_exceptions)
5897 (ada_add_exceptions_from_frame, name_matches_regex)
5898 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
5899 parameter type to compiled_regex. Adjust.
5900 (ada_exceptions_list): Use compiled_regex.
5901 * break-catch-throw.c (exception_catchpoint::pattern): Now a
5902 std::unique_ptr<compiled_regex>.
5903 (exception_catchpoint::~exception_catchpoint): Remove regfree
5904 call.
5905 (check_status_exception_catchpoint): Adjust to use compiled_regex.
5906 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
5907 * breakpoint.c (solib_catchpoint::compiled): Now a
5908 std::unique_ptr<compiled_regex>.
5909 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
5910 (check_status_catch_solib): Adjust to use compiled_regex.
5911 (add_solib_catchpoint): Adjust to use compiled_regex.
5912 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
5913 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
5914 compiled_regex reference. Adjust to use it.
5915 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
5916 declaration. Include "gdb_regex.h".
5917 (apropos_cmd): Change regex parameter to compiled_regex reference.
5918 * gdb_regex.c: New file.
5919 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
5920 declarations.
5921 (class compiled_regex): New.
5922 * linux-tdep.c: Include "common/gdb_optional.h".
5923 (struct mapping_regexes): New, factored out from
5924 mapping_is_anonymous_p, and adjusted to use compiled_regex.
5925 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
5926 gdb::optional and remove cleanups. Adjust to compiled_regex.
5927 * probe.c: Include "common/gdb_optional.h".
5928 (collect_probes): Use compiled_regex and gdb::optional and remove
5929 cleanups.
5930 * skip.c: Include "common/gdb_optional.h".
5931 (skiplist_entry::compiled_function_regexp): Now a
5932 gdb::optional<compiled_regex>.
5933 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
5934 (free_skiplist_entry): Remove regfree call.
5935 (compile_skip_regexp, skip_rfunction_p): Adjust to use
5936 compiled_regex and gdb::optional.
5937 * symtab.c: Include "common/gdb_optional.h".
5938 (search_symbols): Use compiled_regex and gdb::optional.
5939 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
5940 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
5941 to gdb_regex.c.
5942
5943 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5944
5945 * regcache.c (regcache::save): Avoid buffer use.
5946 (regcache::dump): Likewise.
5947
5948 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5949
5950 * sh-tdep.c (sh_pseudo_register_read): Remove
5951 MAX_REGISTER_SIZE.
5952 (sh_pseudo_register_write): Likewise.
5953 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
5954 (sh64_pseudo_register_write): Likewise
5955
5956 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5957
5958 * aarch64-tdep.c (aarch64_store_return_value): Use
5959 V_REGISTER_SIZE.
5960 (aarch64_pseudo_read_value): Likewise.
5961 (aarch64_pseudo_write): Likewise.
5962
5963 2017-06-06 Yao Qi <yao.qi@linaro.org>
5964
5965 * regformats/regdef.h (set_register_cache): Remove the
5966 declaration.
5967
5968 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5969
5970 * frame.c (frame_unwind_register_signed): Use
5971 frame_unwind_register_value.
5972
5973 2017-06-06 Pedro Alves <palves@redhat.com>
5974
5975 PR breakpoints/21553
5976 * breakpoint.c (create_breakpoints_sal_default)
5977 (init_breakpoint_sal, create_breakpoint_sal): Use
5978 gdb::unique_xmalloc_ptr for string parameters.
5979 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5980 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
5981 (base_breakpoint_create_breakpoints_sal)
5982 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
5983 (strace_marker_create_breakpoints_sal)
5984 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
5985 string parameters.
5986 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
5987 gdb::unique_xmalloc_ptr for string parameters.
5988 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5989 parameters.
5990
5991 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5992
5993 * alpha-tdep.c (alpha_register_to_value): Use
5994 get_frame_register_value.
5995 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
5996
5997 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5998
5999 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
6000 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
6001 (ia64_value_to_register): Likewise.
6002 (ia64_extract_return_value): Likewise.
6003 (ia64_store_return_value): Likewise.
6004 (ia64_push_dummy_call): Likewise.
6005
6006 2017-06-04 Joel Brobecker <brobecker@adacore.com>
6007
6008 GDB 8.0 released.
6009
6010 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
6011
6012 * x86-linux-nat.c (struct arch_lwp_info): Remove.
6013
6014 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
6015
6016 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
6017 parameter.
6018 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
6019
6020 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
6021
6022 * event-loop.c (poll_timers): Unallocate timer using delete
6023 instead of xfree.
6024
6025 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6026
6027 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
6028 (struct breakpoint) <~breakpoint>: New.
6029 (struct watchpoint): Inherit from breakpoint.
6030 <~watchpoint>: New.
6031 <base>: Remove.
6032 (struct tracepoint): Inherit from breakpoint.
6033 <base>: Remove.
6034 * breakpoint.c (longjmp_breakpoint_ops): Remove.
6035 (struct longjmp_breakpoint): Inherit from breakpoint.
6036 <~longjmp_breakpoint>: New.
6037 <base>: Remove.
6038 (new_breakpoint_from_type): Remove casts.
6039 (watchpoint_in_thread_scope): Remove reference to base field.
6040 (watchpoint_del_at_next_stop): Likewise.
6041 (update_watchpoint): Likewise.
6042 (watchpoint_check): Likewise.
6043 (bpstat_check_watchpoint): Likewise.
6044 (set_longjmp_breakpoint): Likewise.
6045 (struct fork_catchpoint): Inherit from breakpoint.
6046 <base>: Remove.
6047 (struct solib_catchpoint): Inherit from breakpoint.
6048 <~solib_catchpoint>: New.
6049 <base>: Remove.
6050 (dtor_catch_solib): Change to ...
6051 (solib_catchpoint::~solib_catchpoint): ... this.
6052 (breakpoint_hit_catch_solib): Remove reference to base field.
6053 (add_solib_catchpoint): Likewise.
6054 (create_fork_vfork_event_catchpoint): Likewise.
6055 (struct exec_catchpoint): Inherit from breakpoint.
6056 <~exec_catchpoint>: New.
6057 <base>: Remove.
6058 (dtor_catch_exec): Change to ...
6059 (exec_catchpoint::~exec_catchpoint): ... this.
6060 (dtor_watchpoint): Change to ...
6061 (watchpoint::~watchpoint): ... this.
6062 (watch_command_1): Remove reference to base field.
6063 (catch_exec_command_1): Likewise.
6064 (base_breakpoint_dtor): Change to ...
6065 (breakpoint::~breakpoint): ... this.
6066 (base_breakpoint_ops): Remove dtor field value.
6067 (longjmp_bkpt_dtor): Change to ...
6068 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
6069 (strace_marker_create_breakpoints_sal): Remove reference to base
6070 field.
6071 (delete_breakpoint): Don't manually call breakpoint destructor.
6072 (create_tracepoint_from_upload): Remove reference to base field.
6073 (trace_pass_set_count): Likewise.
6074 (initialize_breakpoint_ops): Don't initialize
6075 momentary_breakpoint_ops, don't set dtors.
6076 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
6077 <~ada_catchpoint>: New.
6078 <base>: Remove.
6079 (create_excep_cond_exprs): Remove reference to base field.
6080 (dtor_exception): Change to ...
6081 (ada_catchpoint::~ada_catchpoint): ... this.
6082 (dtor_catch_exception): Remove.
6083 (dtor_catch_exception_unhandled): Remove.
6084 (dtor_catch_assert): Remove.
6085 (create_ada_exception_catchpoint): Remove reference to base
6086 field.
6087 (initialize_ada_catchpoint_ops): Don't set dtors.
6088 * break-catch-sig.c (struct signal_catchpoint): Inherit from
6089 breakpoint.
6090 <~signal_catchpoint>: New.
6091 <base>: Remove.
6092 (signal_catchpoint_dtor): Change to ...
6093 (signal_catchpoint::~signal_catchpoint): ... this.
6094 (create_signal_catchpoint): Remove reference to base field.
6095 (initialize_signal_catchpoint_ops): Don't set dtor.
6096 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
6097 from breakpoint.
6098 <~syscall_catchpoint>: New.
6099 <base>: Remove.
6100 (dtor_catch_syscall): Change to ...
6101 (syscall_catchpoint::~syscall_catchpoint): ... this.
6102 (create_syscall_event_catchpoint): Remove reference to base
6103 field.
6104 (initialize_syscall_catchpoint_ops): Don't set dtor.
6105 * break-catch-throw.c (struct exception_catchpoint): Inherit
6106 from breakpoint.
6107 <~exception_catchpoint>: New.
6108 <base>: Remove.
6109 (dtor_exception_catchpoint): Change to ...
6110 (exception_catchpoint::~exception_catchpoint): ... this.
6111 (handle_gnu_v3_exceptions): Remove reference to base field.
6112 (initialize_throw_catchpoint_ops): Don't set dtor.
6113 * ctf.c (ctf_get_traceframe_address): Remove reference to base
6114 field.
6115 * remote.c (remote_get_tracepoint_status): Likewise.
6116 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
6117 * tracefile.c (tracefile_fetch_registers): Likewise.
6118 * tracepoint.c (actions_command): Likewise.
6119 (validate_actionline): Likewise.
6120 (tfind_1): Likewise.
6121 (get_traceframe_location): Likewise.
6122 (find_matching_tracepoint_location): Likewise.
6123 (parse_tracepoint_status): Likewise.
6124 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
6125
6126 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6127
6128 * breakpoint.c (struct longjmp_breakpoint): New struct.
6129 (is_tracepoint_type): Change return type to bool.
6130 (is_longjmp_type): New function.
6131 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
6132 (set_raw_breakpoint_without_location): Use
6133 new_breakpoint_from_type.
6134 (set_raw_breakpoint): Likewise.
6135
6136 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6137
6138 * breakpoint.c (new_breakpoint_from_type): New function.
6139 (create_breakpoint_sal): Use new_breakpoint_from_type and
6140 unique_ptr.
6141 (create_breakpoint): Likewise.
6142
6143 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
6144
6145 * memattr.c (mem_info_command): Rename to ...
6146 (info_mem_command): ... this.
6147 (mem_enable_command): Rename to ...
6148 (enable_mem_command): ... this.
6149 (mem_disable_command): Rename to ...
6150 (disable_mem_command): ... this.
6151 (mem_delete_command): Rename to ...
6152 (delete_mem_command): ... this.
6153 (_initialize_mem): Adjust function names.
6154
6155 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6156
6157 * btrace.c (handle_pt_insn_events): New.
6158 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
6159 STATUS. Split into this and ...
6160 (handle_pt_insn_event_flags): ... this.
6161
6162 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6163
6164 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
6165 and struct pt_insn.resynced.
6166 * configure: Regenerated.
6167 * config.in: Regenerated.
6168
6169 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6170
6171 * btrace.c (ftrace_find_call_by_number): New function.
6172 (ftrace_new_function): Store objects, not pointers.
6173 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
6174 ftrace_new_gap, ftrace_update_function,
6175 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
6176 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
6177 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
6178 btrace_ends_with_single_insn, btrace_call_get): Account for
6179 btrace_thread_info::functions now storing objects.
6180 * btrace.h (struct btrace_thread_info): Add constructor.
6181 (struct btrace_thread_info) <functions>: Make std::vector.
6182 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
6183 Initialize with default values.
6184 * record-btrace.c (record_btrace_frame_sniffer): Account for
6185 btrace_thread_info::functions now storing objects.
6186
6187 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6188
6189 * btrace.c: Remove typedef bfun_s.
6190 (ftrace_new_gap): Directly add gaps to the list of gaps.
6191 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
6192 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
6193 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
6194 instead of gdb VEC.
6195
6196 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6197
6198 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
6199 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
6200 with btrace_thread_info::next_segment and
6201 btrace_thread_info::prev_segment.
6202 * btrace.h: Remove struct btrace_func_link.
6203 (struct btrace_function): Replace pair of function segment pointers
6204 with pair of indices.
6205 * python/py-record-btrace.c (btpy_call_prev_sibling,
6206 btpy_call_next_sibling): Replace references to
6207 btrace_thread_info::segment with btrace_thread_info::next_segment and
6208 btrace_thread_info::prev_segment.
6209 * record-btrace.c (record_btrace_frame_this_id): Use
6210 btrace_find_call_by_number.
6211
6212 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6213
6214 * btrace.c (ftrace_new_function, ftrace_fixup_level,
6215 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
6216 btrace_insn_next, btrace_insn_prev): Remove references to
6217 btrace_thread_info::flow.
6218 * btrace.h (struct btrace_function): Remove FLOW.
6219
6220 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6221
6222 * btrace.c (ftrace_find_call_by_number): New function.
6223 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
6224 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
6225 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
6226 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
6227 index.
6228 * btrace.h (struct btrace_function): Turn UP into an index.
6229 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
6230 as an index.
6231 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
6232 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
6233 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
6234
6235 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6236
6237 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6238 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6239 ftrace_update_function, ftrace_compute_global_level_offset,
6240 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
6241 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
6242 btrace_insn_end, btrace_is_empty): Remove references to
6243 btrace_thread_info::begin and btrace_thread_info::end.
6244 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
6245 (struct btrace_thread_info) <functions>: Adjust comment.
6246 * record-btrace.c (record_btrace_start_replaying): Remove reference to
6247 btrace_thread_info::begin.
6248
6249 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6250
6251 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6252 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6253 ftrace_update_function): Remove arguments that implicitly were always
6254 BTINFO->END.
6255 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
6256 Don't pass BTINFO->END.
6257
6258 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6259
6260 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
6261 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
6262 btrace_find_insn_by_number): Replace function segment pointer with
6263 index.
6264 (btrace_insn_cmp): Simplify.
6265 * btrace.h: (struct btrace_insn_iterator) Rename index to
6266 insn_index. Replace function segment pointer with index into function
6267 segment vector.
6268 * record-btrace.c (record_btrace_call_history): Replace function
6269 segment pointer use with index.
6270 (record_btrace_frame_sniffer): Retrieve function call segment through
6271 vector.
6272 (record_btrace_set_replay): Remove defunc't safety check.
6273
6274 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6275
6276 * btrace.c (btrace_ends_with_single_insn): New function.
6277 (btrace_call_get, btrace_call_number, btrace_call_begin,
6278 btrace_call_end, btrace_call_next, btrace_call_prev,
6279 btrace_find_call_by_number): Use index into call segment vector
6280 instead of pointer.
6281 (btrace_call_cmp): Simplify.
6282 * btrace.h (struct btrace_call_iterator): Replace function call segment
6283 pointer with index into vector.
6284 * record-btrace.c (record_btrace_call_history): Use index instead of
6285 pointer.
6286
6287 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6288
6289 * btrace.c (btrace_insn_begin, btrace_insn_end,
6290 btrace_find_insn_by_number): Add btinfo to iterator.
6291 * btrace.h (struct btrace_insn_iterator): Add btinfo.
6292
6293 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6294
6295 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
6296 and save pointers directly.
6297 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
6298 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
6299 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
6300 changed signature of functions.
6301 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
6302 (btrace_fetch): Remove code that adds btrace_function pointers to
6303 vector of btrace_functions.
6304 (btrace_clear): Simplify freeing vector of btrace_functions.
6305
6306 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6307
6308 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
6309 Replace VEC_* with std::vector functions.
6310 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
6311 (struct btrace_thread_info)<functions>: Change type to std::vector.
6312
6313 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
6314
6315 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
6316 "Removed targets and native configurations" up. Merge duplicate
6317 "New commands" sub-sections. Add "New options" sub-sections.
6318
6319 2017-05-26 Alan Hayward <alan.hayward@arm.com>
6320
6321 * defs.h (copy_integer_to_size): New declaration.
6322 * findvar.c (copy_integer_to_size): New function.
6323 (do_cint_test): New selftest function.
6324 (copy_integer_to_size_test): Likewise.
6325 (_initialize_findvar): Likewise.
6326 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
6327 (mips_fbsd_collect_reg): Use raw_collect_integer.
6328 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
6329 (mips64_fill_gregset): Use raw_collect_integer
6330 (mips64_fill_fpregset): Use raw_supply_integer.
6331 * regcache.c (regcache::raw_supply_integer): New function.
6332 (regcache::raw_collect_integer): Likewise.
6333 * regcache.h: (regcache::raw_supply_integer): New declaration.
6334 (regcache::raw_collect_integer): Likewise.
6335
6336 2017-05-24 Yao Qi <yao.qi@linaro.org>
6337
6338 * Makefile.in (SFILES): Add gdbarch-selftests.c.
6339 (COMMON_OBS): Add gdbarch-selftests.o.
6340 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
6341 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
6342 * gdbarch-selftests.c: New file.
6343 * regcache.h (regcache) <~regcache>: Mark it virtual if
6344 GDB_SELF_TEST.
6345 <raw_write>: Likewise.
6346
6347 2017-05-24 Yao Qi <yao.qi@linaro.org>
6348
6349 * regcache.c (current_regcache): Change it to
6350 regcache::current_regcache.
6351 (regcache_observer_target_changed): Update.
6352 (regcache_thread_ptid_changed): Make it a regcache static
6353 method.
6354 (regcache_thread_ptid_changed): Update.
6355 (class regcache_access): New.
6356 (current_regcache_test): Update.
6357 (_initialize_regcache): Update.
6358 * regcache.h: Include forward_list.
6359 (regcache): Declare regcache_thread_ptid_changed and declare
6360 registers_changed_ptid as friend.
6361
6362 2017-05-24 Yao Qi <yao.qi@linaro.org>
6363
6364 * i387-tdep.c (i387_register_to_value): Use register_size
6365 instead of TYPE_LENGTH.
6366 * m68k-tdep.c (m68k_register_to_value): Likewise.
6367
6368 2017-05-24 Yao Qi <yao.qi@linaro.org>
6369
6370 * i387-tdep.c (i387_convert_register_p): Return false if type
6371 code isn't TYPE_CODE_FLT.
6372
6373 2017-05-24 Yao Qi <yao.qi@linaro.org>
6374
6375 * alpha-tdep.c (alpha_convert_register_p): Return true if type
6376 length is 4.
6377 (alpha_register_to_value): Remove type length check.
6378 (alpha_value_to_register): Likewise.
6379
6380 2017-05-24 Yao Qi <yao.qi@linaro.org>
6381
6382 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
6383 TYPE_CODE_FLT.
6384
6385 2017-05-24 Yao Qi <yao.qi@linaro.org>
6386
6387 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
6388 TYPE_CODE_FLT or not.
6389
6390 2017-05-24 Yao Qi <yao.qi@linaro.org>
6391
6392 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6393 * avr-tdep.c (avr_gdbarch_init): Likewise.
6394 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6395 * cris-tdep.c (cris_gdbarch_init): Likewise.
6396 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6397 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6398 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6399 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6400 * mep-tdep.c (mep_gdbarch_init): Likewise.
6401 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6402 * mips-tdep.c (mips_gdbarch_init): Likewise.
6403 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6404 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6405 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6406 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6407 * v850-tdep.c (v850_gdbarch_init): Likewise.
6408
6409 2017-05-24 Yao Qi <yao.qi@linaro.org>
6410
6411 * selftest-arch.c (tests_with_arch): Call registers_changed
6412 and reinit_frame_cache.
6413 * selftest.c (run_self_tests): Likewise.
6414
6415 2017-05-24 Yao Qi <yao.qi@linaro.org>
6416
6417 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6418 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6419
6420 2017-05-24 Yao Qi <yao.qi@linaro.org>
6421
6422 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6423 set_gdbarch_print_insn.
6424
6425 2017-05-24 Yao Qi <yao.qi@linaro.org>
6426
6427 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6428 set_gdbarch_print_insn.
6429
6430 2017-05-24 Yao Qi <yao.qi@linaro.org>
6431
6432 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6433 set_gdbarch_print_insn.
6434 * arc-tdep.c (arc_gdbarch_init): Likewise.
6435 * arch-utils.c: include dis-asm.h.
6436 (default_print_insn): New function.
6437 * arch-utils.h (default_print_insn): Declare.
6438 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6439 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6440 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6441 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6442 * frv-tdep.c (frv_gdbarch_init): Likewise.
6443 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6444 * gdbarch.sh (print_insn): Use default_print_insn.
6445 * gdbarch.c: Regenerated.
6446 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6447 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6448 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6449 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6450 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6451 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6452 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6453 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6454 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6455 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6456 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6457 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6458 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6459 * mt-tdep.c (mt_gdbarch_init): Likewise.
6460 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6461 * nios2-tdep.c (nios2_print_insn): Remove.
6462 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6463 * rx-tdep.c (rx_gdbarch_init): Likewise.
6464 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6465 * score-tdep.c (score_print_insn): Remove.
6466 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6467 * sh-tdep.c (sh_gdbarch_init): Likewise.
6468 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6469 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6470 * tic6x-tdep.c (tic6x_print_insn): Remove.
6471 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6472 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6473 * v850-tdep.c (v850_gdbarch_init): Likewise.
6474 * vax-tdep.c (vax_gdbarch_init): Likewise.
6475 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6476 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6477
6478 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6479
6480 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6481 (MIPS_FP0_REGNUM): Remove.
6482 (MIPS_FSR_REGNUM): Remove.
6483 (mips_fbsd_supply_fpregs): Use mips_regnum.
6484 (mips_fbsd_supply_gregs): Likewise.
6485 (mips_fbsd_collect_fpregs): Likewise.
6486 (mips_fbsd_collect_gregs): Likewise.
6487
6488 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6489
6490 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6491 (getpfpregs_supplies): New function.
6492 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6493 getfpregs_supplies.
6494 (mips_fbsd_store_inferior_registers): Likewise.
6495
6496 2017-05-22 Pedro Alves <palves@redhat.com>
6497
6498 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6499 maintainer.
6500
6501 2017-05-22 Alan Hayward <alan.hayward@arm.com>
6502
6503 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6504 (store_register): Likewise.
6505 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6506 (get_decimal_float_return_value): Likewise.
6507 (do_ppc_sysv_return_value): Likewise.
6508 (ppc64_sysv_abi_push_integer): Likewise.
6509 (ppc64_sysv_abi_push_freg): Likewise.
6510 (ppc64_sysv_abi_return_value_base): Likewise.
6511 (ppc64_sysv_abi_return_value): Likewise.
6512 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6513 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6514 * rs6000-nat.c: Likewise.
6515 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6516 (rs6000_value_to_register): Likewise.
6517 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6518
6519 2017-05-21 Tom Tromey <tom@tromey.com>
6520
6521 PR rust/21466:
6522 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6523 arrays as "[T]", not "[T; ]".
6524
6525 2017-05-19 Tom Tromey <tom@tromey.com>
6526
6527 PR rust/21484:
6528 * rust-lang.c (exp_descriptor_rust): New function.
6529 (rust_language_defn): Use it.
6530 * p-lang.c (pascal_language_defn): Update.
6531 * opencl-lang.c (opencl_language_defn): Update.
6532 * objc-lang.c (objc_language_defn): Update.
6533 * m2-lang.c (m2_language_defn): Update.
6534 * language.h (struct language_defn)
6535 <la_watch_location_expression>: New member.
6536 * language.c (unknown_language_defn, auto_language_defn)
6537 (local_language_defn): Update.
6538 * go-lang.c (go_language_defn): Update.
6539 * f-lang.c (f_language_defn): Update.
6540 * d-lang.c (d_language_defn): Update.
6541 * c-lang.h (c_watch_location_expression): Declare.
6542 * c-lang.c (c_watch_location_expression): New function.
6543 (c_language_defn, cplus_language_defn, asm_language_defn)
6544 (minimal_language_defn): Use it.
6545 * breakpoint.c (watch_command_1): Call
6546 la_watch_location_expression.
6547 * ada-lang.c (ada_language_defn): Update.
6548
6549 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6550
6551 PR tui/21482
6552 * gdb_curses.h (NOMACROS): Define.
6553 (NCURSES_NOMACROS): Define.
6554
6555 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6556
6557 PR tui/21482
6558 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6559 arg to char *.
6560 * tui/tui-wingeneral.c (box_win): Likewise.
6561 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6562 (tui_show_source_line): Likewise.
6563 (tui_show_exec_info_content): Likewise.
6564
6565 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6566
6567 * sparc-tdep.c (sparc_structure_return_p)
6568 (sparc_arg_on_registers_p): New functions.
6569 (sparc32_store_arguments): Use them.
6570 * sparc64-tdep.c (sparc64_16_byte_align_p)
6571 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6572 Handle TYPE_CODE_ARRAY.
6573
6574 2017-05-17 Yao Qi <yao.qi@linaro.org>
6575
6576 * cli/cli-decode.c (add_alias_cmd): New function.
6577 * command.h (add_alias_cmd): Declare.
6578 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6579 instead call add_alias_cmd.
6580
6581 2017-05-17 Pedro Alves <palves@redhat.com>
6582
6583 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6584 (nat_makefile_frag): ... this. All references updated.
6585 * configure.ac: Likewise.
6586 * configure.nat: Likewise. Enhance comments.
6587 * configure: Regenerate.
6588
6589 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6590
6591 * procfs.c (procfs_create_inferior): Change prototype to match
6592 definition.
6593
6594 2017-05-13 Eli Zaretskii <eliz@gnu.org>
6595
6596 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6597 C++ compiler warning.
6598
6599 2017-05-12 Tom Tromey <tom@tromey.com>
6600
6601 PR rust/21483:
6602 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6603 recurse, just call value_struct_elt directly.
6604
6605 2017-05-12 Tom Tromey <tom@tromey.com>
6606
6607 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6608 OP_RUST_ARRAY>: Fix.
6609
6610 2017-05-12 Tom Tromey <tom@tromey.com>
6611
6612 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6613
6614 2017-05-09 Yao Qi <yao.qi@linaro.org>
6615
6616 * regcache.c: Include <forward_list>.
6617 (struct regcache_list): Remove.
6618 (current_regcache): Update.
6619 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6620 (regcache_thread_ptid_changed): Likewise.
6621 (registers_changed_ptid): Likewise.
6622 (current_regcache_size): Likewise.
6623
6624 2017-05-09 Yao Qi <yao.qi@linaro.org>
6625
6626 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6627 (current_regcache_size): New function.
6628 (current_regcache_test): New function.
6629 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6630
6631 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6632
6633 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6634 (print_gp_register_row): Use get_frame_register_value.
6635
6636 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6637
6638 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6639 (mips_supply_fpregset): Likewise.
6640 (mips64_supply_gregset): Likewise.
6641
6642 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6643
6644 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6645 regcache->raw_supply_zeroed.
6646
6647 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6648
6649 * configure.nat: Rearrange 'case' statements to match
6650 host before cpu.
6651
6652 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6653
6654 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6655 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6656 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6657 "@nat_extra_makefile_frag@".
6658 (Makefile): Remove dependency on "@frags@".
6659 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6660 (data-directory/Makefile): Likewise.
6661 * config/aarch64/linux.mh: Deleted; moved contents to
6662 "gdb/configure.nat".
6663 * config/alpha/alpha-linux.mh: Likewise.
6664 * config/alpha/nbsd.mh: Likewise.
6665 * config/arm/linux.mh: Likewise.
6666 * config/arm/nbsdelf.mh: Likewise.
6667 * config/i386/cygwin.mh: Likewise.
6668 * config/i386/cygwin64.mh: Likewise.
6669 * config/i386/darwin.mh: Likewise.
6670 * config/i386/fbsd.mh: Likewise.
6671 * config/i386/fbsd64.mh: Likewise.
6672 * config/i386/go32.mh: Likewise.
6673 * config/i386/i386gnu.mh: Likewise.
6674 * config/i386/i386sol2.mh: Likewise.
6675 * config/i386/linux.mh: Likewise.
6676 * config/i386/linux64.mh: Likewise.
6677 * config/i386/mingw.mh: Likewise.
6678 * config/i386/mingw64.mh: Likewise.
6679 * config/i386/nbsd64.mh: Likewise.
6680 * config/i386/nbsdelf.mh: Likewise.
6681 * config/i386/nto.mh: Likewise.
6682 * config/i386/obsd.mh: Likewise.
6683 * config/i386/obsd64.mh: Likewise.
6684 * config/i386/sol2-64.mh: Likewise.
6685 * config/ia64/linux.mh: Likewise.
6686 * config/m32r/linux.mh: Likewise.
6687 * config/m68k/linux.mh: Likewise.
6688 * config/m68k/nbsdelf.mh: Likewise.
6689 * config/m68k/obsd.mh: Likewise.
6690 * config/m88k/obsd.mh: Likewise.
6691 * config/mips/fbsd.mh: Likewise.
6692 * config/mips/linux.mh: Likewise.
6693 * config/mips/nbsd.mh: Likewise.
6694 * config/mips/obsd64.mh: Likewise.
6695 * config/pa/linux.mh: Likewise.
6696 * config/pa/nbsd.mh: Likewise.
6697 * config/pa/obsd.mh: Likewise.
6698 * config/powerpc/aix.mh: Likewise.
6699 * config/powerpc/fbsd.mh: Likewise.
6700 * config/powerpc/linux.mh: Likewise.
6701 * config/powerpc/nbsd.mh: Likewise.
6702 * config/powerpc/obsd.mh: Likewise.
6703 * config/powerpc/ppc64-linux.mh: Likewise.
6704 * config/powerpc/spu-linux.mh: Likewise.
6705 * config/s390/linux.mh: Likewise.
6706 * config/sh/nbsd.mh: Likewise.
6707 * config/sparc/fbsd.mh: Likewise.
6708 * config/sparc/linux.mh: Likewise.
6709 * config/sparc/linux64.mh: Likewise.
6710 * config/sparc/nbsd64.mh: Likewise.
6711 * config/sparc/nbsdelf.mh: Likewise.
6712 * config/sparc/obsd64.mh: Likewise.
6713 * config/sparc/sol2.mh: Likewise.
6714 * config/tilegx/linux.mh: Likewise.
6715 * config/vax/nbsdelf.mh: Likewise.
6716 * config/vax/obsd.mh: Likewise.
6717 * config/xtensa/linux.mh: Likewise.
6718 * config/i386/i386gnu.mn: New file, with excerpts from
6719 "config/i386/i386gnu.mh".
6720 * configure: Regenerate.
6721 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
6722 *.mh files under "gdb/config".
6723 * configure.nat: New file, with contents from the
6724 "gdb/config/*/*.mh" files.
6725
6726 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
6727
6728 * btrace.c (btrace_clear): Free insn vector.
6729
6730 2017-05-05 Pedro Alves <palves@redhat.com>
6731
6732 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
6733 * configure: Regenerate.
6734
6735 2017-05-04 Pedro Alves <palves@redhat.com>
6736
6737 * Makefile.in (SFILES): Add progspace-and-thread.c.
6738 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
6739 (COMMON_OBS): Add progspace-and-thread.o.
6740 * breakpoint.c: Include "progspace-and-thread.h".
6741 (update_inserted_breakpoint_locations)
6742 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
6743 Use scoped_restore_current_pspace_and_thread.
6744 (create_std_terminate_master_breakpoint): Use
6745 scoped_restore_current_program_space.
6746 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
6747 (print_breakpoint_location): Use
6748 scoped_restore_current_program_space.
6749 (bp_loc_is_permanent): Use
6750 scoped_restore_current_pspace_and_thread.
6751 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
6752 (download_tracepoint_locations): Use
6753 scoped_restore_current_pspace_and_thread.
6754 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
6755 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
6756 (enum step_over_calls_kind): Moved from inferior.h.
6757 (class scoped_restore_current_thread): New class.
6758 * gdbthread.h (make_cleanup_restore_current_thread): Delete
6759 declaration.
6760 (scoped_restore_current_thread): New class.
6761 * infcmd.c: Include "common/gdb_optional.h".
6762 (continue_1, proceed_after_attach): Use
6763 scoped_restore_current_thread.
6764 (notice_new_inferior): Use scoped_restore_current_thread.
6765 * inferior.c: Include "progspace-and-thread.h".
6766 (restore_inferior, save_current_inferior): Delete.
6767 (add_inferior_command, clone_inferior_command): Use
6768 scoped_restore_current_pspace_and_thread.
6769 * inferior.h (scoped_restore_current_inferior): New class.
6770 * infrun.c: Include "progspace-and-thread.h" and
6771 "common/gdb_optional.h".
6772 (follow_fork_inferior): Use
6773 scoped_restore_current_pspace_and_thread.
6774 (scoped_restore_exited_inferior): New class.
6775 (handle_vfork_child_exec_or_exit): Use
6776 scoped_restore_exited_inferior,
6777 scoped_restore_current_pspace_and_thread,
6778 scoped_restore_current_thread and scoped_restore.
6779 (fetch_inferior_event): Use scoped_restore_current_thread.
6780 * linespec.c (decode_line_full, decode_line_1): Use
6781 scoped_restore_current_program_space.
6782 * mi/mi-main.c: Include "progspace-and-thread.h".
6783 (exec_continue): Use scoped_restore_current_thread.
6784 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
6785 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
6786 * proc-service.c (ps_pglobal_lookup): Use
6787 scoped_restore_current_program_space.
6788 * progspace-and-thread.c: New file.
6789 * progspace-and-thread.h: New file.
6790 * progspace.c (release_program_space, clone_program_space): Use
6791 scoped_restore_current_program_space.
6792 (restore_program_space, save_current_program_space)
6793 (save_current_space_and_thread): Delete.
6794 (switch_to_program_space_and_thread): Moved to
6795 progspace-and-thread.c.
6796 * progspace.h (save_current_program_space)
6797 (save_current_space_and_thread): Delete declarations.
6798 (scoped_restore_current_program_space): New class.
6799 * remote.c (remote_btrace_maybe_reopen): Use
6800 scoped_restore_current_thread.
6801 * symtab.c: Include "progspace-and-thread.h".
6802 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
6803 * thread.c (print_thread_info_1): Use
6804 scoped_restore_current_thread.
6805 (struct current_thread_cleanup): Delete.
6806 (do_restore_current_thread_cleanup)
6807 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
6808 (scoped_restore_current_thread::~scoped_restore_current_thread):
6809 ... this new dtor.
6810 (make_cleanup_restore_current_thread): Rename/convert to ...
6811 (scoped_restore_current_thread::scoped_restore_current_thread):
6812 ... this new ctor.
6813 (thread_apply_all_command): Use scoped_restore_current_thread.
6814 (thread_apply_command): Use scoped_restore_current_thread.
6815 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
6816 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
6817
6818 2017-05-04 Pedro Alves <palves@redhat.com>
6819
6820 * thread.c (make_cleanup_restore_current_thread): Move
6821 find_thread_ptid call before the is_stopped call. Assert that the
6822 thread is found. Replace is_stopped call by checking the thread's
6823 state directly. Remove unnecessary NULL-thread check.
6824
6825 2017-05-04 Pedro Alves <palves@redhat.com>
6826
6827 * corelow.c (thread_section_name): New class.
6828 (get_core_register_section, get_core_siginfo): Use it.
6829
6830 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
6831
6832 * corelow.c (sniff_core_bfd): Remove extra semicolon.
6833 (get_core_register_section): Remove xfree of NULL pointer.
6834
6835 2017-05-03 Alan Hayward <alan.hayward@arm.com>
6836
6837 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
6838 * regcache.c (regcache::raw_supply_zeroed): New function.
6839 * regcache.h (regcache::raw_supply_zeroed): New declaration.
6840
6841 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
6842
6843 * gdbarch.sh: Remove commented out definition of
6844 TARGET_CHAR_BIT.
6845 * gdbarch.h: Re-generate.
6846
6847 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6848
6849 * configure: Regenerate.
6850
6851 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
6852
6853 * solib-target.c (solib_target_relocate_section_addresses):
6854 Remove num_section_bases, num_bases, segment_bases variables.
6855
6856 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6857
6858 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
6859
6860 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6861
6862 * solib-target.c: Include <vector>
6863 (struct lm_info_target) <~lm_info_target>: Remove.
6864 <segment_bases, section_bases>: Change type to
6865 std::vector<CORE_ADDR>.
6866 (library_list_start_segment, library_list_start_section,
6867 library_list_end_library,
6868 solib_target_relocate_section_addresses): Adjust.
6869
6870 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6871
6872 * gdbarch.sh (software_single_step): Change return type to
6873 std::vector<CORE_ADDR>.
6874 * gdbarch.c, gdbarch.h: Re-generate.
6875 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
6876 Adjust.
6877 (arm_deal_with_atomic_sequence_raw): Adjust.
6878 (thumb_get_next_pcs_raw): Adjust.
6879 (arm_get_next_pcs_raw): Adjust.
6880 (arm_get_next_pcs): Adjust.
6881 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
6882 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
6883 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
6884 (alpha_software_single_step): Adjust.
6885 * alpha-tdep.h (alpha_software_single_step): Adjust.
6886 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
6887 * arm-tdep.c (arm_software_single_step): Adjust.
6888 (arm_breakpoint_kind_from_current_state): Adjust.
6889 * arm-tdep.h (arm_software_single_step): Adjust.
6890 * breakpoint.c (insert_single_step_breakpoint): Adjust.
6891 * cris-tdep.c (cris_software_single_step): Adjust.
6892 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
6893 (micromips_deal_with_atomic_sequence): Adjust.
6894 (deal_with_atomic_sequence): Adjust.
6895 (mips_software_single_step): Adjust.
6896 * mips-tdep.h (mips_software_single_step): Adjust.
6897 * moxie-tdep.c (moxie_software_single_step): Adjust.
6898 * nios2-tdep.c (nios2_software_single_step): Adjust.
6899 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
6900 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
6901 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
6902 * s390-linux-tdep.c (s390_software_single_step): Adjust.
6903 * sparc-tdep.c (sparc_software_single_step): Adjust.
6904 * spu-tdep.c (spu_software_single_step): Adjust.
6905 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
6906
6907 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6908
6909 * gdbarch.sh: Use semi-colon as field separator instead of colon.
6910 * gdbarch.h: Re-generate.
6911
6912 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6913
6914 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
6915 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
6916 * python/py-instruction.c, python/py-instruction.h: New file.
6917 * python/py-record.c: Add py-instruction.h include.
6918 (gdbpy_initialize_record): Make gdb.Instruction a super class of
6919 gdb.RecordInstruction.
6920 * python/python-internal.h: Add gdbpy_initialize_instruction
6921 declaration.
6922 * python/python.c (do_start_initialization): Add
6923 gdbpy_initialize_instruction.
6924
6925 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6926
6927 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
6928 Remove.
6929 (btrace_func_from_recpy_func): New function.
6930 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
6931 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
6932 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
6933 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
6934 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
6935 Also, use new helper functions.
6936 (btpy_list_item): Use new helper functions.
6937 (recpy_bt_function_call_history): Use new type name.
6938 (btpy_call_getset): Remove.
6939 (gdbpy_initialize_btrace): Remove code to initialize
6940 gdb.BtraceFunctionCall.
6941 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
6942 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
6943 recpy_bt_func_prev, recpy_bt_func_next): New export.
6944 * python/py-record.c (recpy_func_type): New static object.
6945 (recpy_func_new, recpy_func_level, recpy_func_symbol,
6946 recpy_func_instructions, recpy_func_up, recpy_func_prev,
6947 recpy_func_next): New function.
6948 (recpy_element_hash, recpy_element_richcompare): Updated comment.
6949 (recpy_func_getset): New static object.
6950 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
6951 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
6952
6953 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6954
6955 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
6956 (btpy_object, btpy_insn_type, btpy_new): Remove.
6957 (btpy_list_object): Use gdb.RecordInstruction type instead of
6958 gdb.BtraceInstruction type.
6959 (btrace_insn_from_recpy_insn): New function.
6960 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
6961 btpy_new.
6962 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
6963 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
6964 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
6965 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
6966 instead of btpy_object.
6967 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6968 btpy_insn_data, btpy_insn_decode): Rename to ...
6969 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
6970 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
6971 recpy_bt_insn_decode): This. Also, use new helper functions.
6972 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
6973 recpy_insn_type.
6974 (btpy_insn_getset): Remove.
6975 (gdbpy_initialize_btrace): Remove code to initialize
6976 gdb.BtraceInstruction. Use recpy_element_object.
6977 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
6978 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
6979 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
6980 * python/py-record.c (recpy_insn_type): New static object.
6981 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
6982 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
6983 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
6984 New function.
6985 (recpy_insn_getset): New static object.
6986 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
6987 * python/py-record.h (recpy_element_object): New typedef.
6988 (recpy_insn_type, recpy_insn_new): New export.
6989
6990 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6991
6992 * py-record-btrace.c (btpy_insn_new): Removed.
6993 (btpy_insn_or_gap_new): New function.
6994 (btpy_insn_error): Removed.
6995 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6996 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
6997 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
6998 btpy_insn_or_gap_new instead of btpy_insn_new.
6999 (btpy_insn_getset): Remove btpy_insn_error.
7000 * py-record.c (recpy_gap_type): New static object.
7001 (recpy_gap_object): New typedef.
7002 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
7003 recpy_gap_reason_string): New function.
7004 (recpy_gap_getset): New static object.
7005 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
7006 * py-record.h (recpy_gap_new): New export.
7007
7008 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7009
7010 * python/py-record.c (recpy_ptid): Remove.
7011 (recpy_record_getset): Remove recpy_ptid.
7012
7013 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7014
7015 * btrace.c (btrace_fetch): Set inferior_ptid.
7016 * python/py-record-btrace.c: Add "py-record.h" include.
7017 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
7018 recpy_bt_end, recpy_bt_instruction_history,
7019 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
7020 in gdb.Record object instead of current ptid.
7021 * python/py-record.c: Include new "py-record.h" file.
7022 (recpy_record_object): Moved to py-record.h.
7023 * python/py-record.h: New file.
7024
7025 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7026
7027 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
7028 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
7029 indentation.
7030
7031 2017-05-01 Joel Brobecker <brobecker@adacore.com>
7032
7033 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
7034 the past maintainers section.
7035
7036 2017-04-28 Yao Qi <yao.qi@linaro.org>
7037
7038 * infcmd.c (get_return_value): Use regcache ctor, and remove
7039 cleanup.
7040
7041 2017-04-28 Yao Qi <yao.qi@linaro.org>
7042 Pedro Alves <palves@redhat.com>
7043
7044 * regcache.c (regcache::regcache): New tag dispatch ctor.
7045 (do_cooked_read): Moved above.
7046 (regcache_dup): Use the tag dispatch ctor..
7047 * regcache.h (regcache): Declare ctor, delete copy ctor and
7048 assignment operator, remove friend regcache_dup.
7049
7050 2017-04-28 Yao Qi <yao.qi@linaro.org>
7051
7052 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
7053 call method save instead of regcache_cpy.
7054 * regcache.h (struct regcache): Make regcache_dup a friend.
7055
7056 2017-04-28 Yao Qi <yao.qi@linaro.org>
7057
7058 * regcache.c (struct regcache): Move to regcache.h
7059 (regcache::arch): New method.
7060 (regcache_get_ptid): Update.
7061 (get_regcache_arch): Call arch method.
7062 (get_regcache_aspace): Call method aspace.
7063 (register_buffer): Change it to method.
7064 (regcache_save): Change it to regcache::save.
7065 (regcache_restore): Likewise.
7066 (regcache_cpy_no_passthrough): Remove the declaration.
7067 (regcache_cpy): Call methods restore and cpy_no_passthrough.
7068 (regcache_cpy_no_passthrough): Change it to method
7069 cpy_no_passthrough.
7070 (regcache_register_status): Change it to method
7071 get_register_status.
7072 (regcache_invalidate): Change it to method invalidate.
7073 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
7074 (regcache_raw_update): Change it to method raw_update.
7075 (regcache_raw_read): Likewise.
7076 (regcache_raw_read_signed): Likewise.
7077 (regcache_raw_read_unsigned): Likewise.
7078 (regcache_raw_write_signed): Likewise.
7079 (regcache_raw_write_unsigned): Likewise.
7080 (regcache_cooked_read): Likewise.
7081 (regcache_cooked_read_value): Likewise.
7082 (regcache_cooked_read_signed): Likewise.
7083 (regcache_cooked_read_unsigned): Likewise.
7084 (regcache_cooked_write_signed): Likewise.
7085 (regcache_cooked_write_unsigned): Likewise.
7086 (regcache_raw_set_cached_value): Likewise.
7087 (regcache_raw_write): Likewise.
7088 (regcache_cooked_write): Likewise.
7089 (regcache_xfer_part): Likewise.
7090 (regcache_raw_read_part): Likewise.
7091 (regcache_raw_write_part): Likewise.
7092 (regcache_cooked_read_part): Likewise.
7093 (regcache_cooked_write_part): Likewise.
7094 (regcache_raw_supply): Likewise.
7095 (regcache_raw_collect): Likewise.
7096 (regcache_transfer_regset): Likewise.
7097 (regcache_supply_regset): Likewise.
7098 (regcache_collect_regset): Likewise.
7099 (regcache_debug_print_register): Likewise.
7100 (enum regcache_dump_what): Move it to regcache.h.
7101 (regcache_dump): Change it to method dump.
7102 * regcache.h (enum regcache_dump_what): New.
7103 (class regcache): New.
7104 * target.c (target_fetch_registers): Call method
7105 debug_print_register.
7106 (target_store_registers): Likewise.
7107
7108 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7109
7110 * windows-nat.c (struct lm_info_windows): Initialize field.
7111 (windows_make_so): Allocate lm_info_windows with new.
7112 (windows_free_so): Free lm_info_windows with delete.
7113
7114 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7115
7116 * solib-darwin.c (struct lm_info_darwin): Initialize field.
7117 (darwin_current_sos): Allocate lm_info_darwin with new, remove
7118 cleanup.
7119 (darwin_free_so): Free lm_info_darwin with delete.
7120
7121 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7122
7123 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
7124 <l_addr_p>: Change type to bool.
7125 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
7126 (svr4_free_so): Free lm_info_svr4 with delete.
7127 (svr4_copy_library_list): Replace memcpy with call to copy
7128 constructor.
7129 (library_list_start_library, svr4_default_sos): Allocate
7130 lm_info_svr4 with new.
7131
7132 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7133
7134 * solib-target.c (struct lm_info_target): Add destructor,
7135 initialize fields.
7136 <name>: Change type to std::string.
7137 (library_list_start_library): Allocate lm_info_target with new.
7138 (solib_target_free_library_list): Free lm_info_target with
7139 delete.
7140 (solib_target_current_sos): Adapt to std::string.
7141 (solib_target_free_so): Free lm_info_target with delete.
7142
7143 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7144
7145 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
7146 fields.
7147 (frv_current_sos): Allocate lm_info_frv with new.
7148 (frv_relocate_main_executable): Free lm_info_frv with delete,
7149 allocate with new.
7150 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
7151
7152 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7153
7154 * solib-frv.c (struct lm_info_frv): Fix indentation.
7155
7156 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7157
7158 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
7159 map field.
7160 (dsbt_current_sos): Allocate lm_info_dsbt with new.
7161 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
7162 and allocate with new.
7163 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
7164
7165 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7166
7167 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
7168 <filename, member_name>: Change type to std::string.
7169 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
7170 (library_list_start_library): Allocate lm_info_aix with new.
7171 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
7172 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
7173 with copy constructor.
7174
7175 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7176
7177 * solist.h (struct lm_info): Remove.
7178 (struct lm_info_base): New class.
7179 (struct so_list) <lm_info>: Change type to lm_info_base *.
7180 * nto-tdep.c (struct lm_info): Remove.
7181 (lm_addr): Adjust.
7182 * solib-aix.c (struct lm_info): Rename to ...
7183 (struct lm_info_aix): ... this. Extend lm_info_base.
7184 (lm_info_p): Rename to ...
7185 (lm_info_aix_p): ... this, and adjust.
7186 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
7187 solib_aix_parse_libraries, library_list_start_library,
7188 solib_aix_free_library_list, solib_aix_parse_libraries,
7189 solib_aix_get_library_list,
7190 solib_aix_relocate_section_addresses, solib_aix_free_so,
7191 solib_aix_get_section_offsets,
7192 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
7193 Adjust.
7194 (struct solib_aix_inferior_data) <library_list>: Adjust.
7195 * solib-darwin.c (struct lm_info): Rename to ...
7196 (struct lm_info_darwin): ... this. Extend lm_info_base.
7197 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
7198 * solib-dsbt.c (struct lm_info): Rename to ...
7199 (struct lm_info_dsbt): ... this. Extend lm_info_base.
7200 (struct dsbt_info) <main_executable_lm_info): Adjust.
7201 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
7202 dsbt_relocate_section_addresses): Adjust.
7203 * solib-frv.c (struct lm_info): Rename to ...
7204 (struct lm_info_frv): ... this. Extend lm_info_base.
7205 (main_executable_lm_info): Adjust.
7206 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
7207 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
7208 find_canonical_descriptor_in_load_object,
7209 frv_fdpic_find_canonical_descriptor): Adjust.
7210 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
7211 to lm_info_svr4.
7212 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
7213 svr4_clear_so, svr4_copy_library_list,
7214 library_list_start_library, svr4_default_sos, svr4_read_so_list,
7215 svr4_current_sos, svr4_fetch_objfile_link_map,
7216 solist_update_incremental): Adjust.
7217 * solib-svr4.h (struct lm_info_svr4): Move here from
7218 solib-svr4.c.
7219 * solib-target.c (struct lm_info): Rename to ...
7220 (struct lm_info_target): ... this. Extend lm_info_base.
7221 (lm_info_p): Rename to ...
7222 (lm_info_target_p): ... this.
7223 (solib_target_parse_libraries, library_list_start_segment,
7224 library_list_start_section, library_list_start_library,
7225 library_list_end_library, solib_target_free_library_list,
7226 solib_target_current_sos, solib_target_free_so,
7227 solib_target_relocate_section_addresses): Adjust.
7228 * windows-nat.c (struct lm_info): Rename to ...
7229 (struct lm_info_windows): ... this. Extend lm_info_base.
7230 (windows_make_so, handle_load_dll, handle_unload_dll,
7231 windows_xfer_shared_libraries): Adjust.
7232
7233 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7234
7235 * solib-darwin.c (struct darwin_so_list): Remove.
7236 (darwin_current_sos): Allocate an so_list object instead of a
7237 darwin_so_list, separately allocate an lm_info object.
7238 (darwin_free_so): Free lm_info.
7239
7240 2017-04-28 John Baldwin <jhb@FreeBSD.org>
7241
7242 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
7243 with fprintf_filtered.
7244
7245 2017-04-28 Yao Qi <yao.qi@linaro.org>
7246
7247 * regcache.c (regcache::regcache): New function.
7248 (regcache::~regcache): New function.
7249 (regcache_xmalloc_1): Remove.
7250 (regcache_xmalloc): Call new regcache.
7251 (regcache_xfree): Call delete regcache.
7252 (get_thread_arch_aspace_regcache): Call new regcache.
7253
7254 2017-04-28 Yao Qi <yao.qi@linaro.org>
7255
7256 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
7257 lwp instead of ptid_get_lwp.
7258
7259 2017-04-28 Yao Qi <yao.qi@linaro.org>
7260
7261 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
7262 lwp_info instead of getting from inferior_ptid.
7263
7264 2017-04-27 Keith Seitz <keiths@redhat.com>
7265
7266 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
7267 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
7268 (CV_CONVERSION_BADNESS): Define.
7269 (rank_one_type): Remove overly restrictive rvalue reference
7270 rank checks.
7271 Add cv-qualifier checks and subranks for type equality.
7272 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
7273 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
7274 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
7275
7276 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
7277
7278 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
7279 count when creating the object.
7280
7281 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
7282 Ulrich Weigand <uweigand@de.ibm.com>
7283
7284 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
7285 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
7286 is used in AIX.
7287 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
7288 (process_xcoff_symbol): Likewise.
7289 (scan_xcoff_symtab): Likewise.
7290
7291 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7292
7293 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
7294 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
7295 (ia64_access_reg): Use get_frame_register_unsigned.
7296 (ia64_access_rse_reg): Likewise.
7297 (ia64_libunwind_frame_prev_register): Likewise.
7298
7299 2017-04-26 Jiong Wang <jiong.wang@arm.com>
7300
7301 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
7302 * gdbarch.c: Regenerated.
7303 * gdbarch.h: Regenerated.
7304 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
7305 visibility external.
7306 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
7307 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
7308 (enum cfa_how_kind): Move to ...
7309 (struct dwarf2_frame_state_reg_info): Likewise.
7310 (struct dwarf2_frame_state): Likewise.
7311 * dwarf2-frame.h: ... here.
7312 (dwarf2_frame_state_alloc_regs): New declaration.
7313 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
7314 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
7315
7316 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7317
7318 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
7319 regcache_raw_read_unsigned.
7320 (xtensa_pseudo_register_write): Likewise.
7321
7322 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7323
7324 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
7325 (nds32_pseudo_register_write): Likewise.
7326
7327 2017-04-25 Yao Qi <yao.qi@linaro.org>
7328
7329 * regcache.c (struct regcache) <readonly_p>: Change its type
7330 to bool.
7331 (regcache_xmalloc_1): Update parameter type and callers update.
7332
7333 2017-04-25 Yao Qi <yao.qi@linaro.org>
7334
7335 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
7336 set_gdbarch_wchar_bit.
7337 * arm-tdep.c (arm_gdbarch_init): Likewise.
7338
7339 2017-04-25 Pedro Alves <palves@redhat.com>
7340
7341 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
7342 (BothAreRelocatable, memcopy, memmove): Don't define.
7343 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
7344 macros.
7345
7346 2017-04-25 Pedro Alves <palves@redhat.com>
7347
7348 * common/common-defs.h: Include "common/poison.h".
7349 * common/function-view.h: (Not, Or, Requires): Move to traits.h
7350 and adjust.
7351 * common/poison.h: New file.
7352 * common/traits.h: Include <type_traits>.
7353 (Not, Or, Requires): New, moved from common/function-view.h.
7354
7355 2017-04-25 Pedro Alves <palves@redhat.com>
7356
7357 * breakpoint.h (struct breakpoint): In-class initialize all
7358 fields. Make boolean fields "bool".
7359 * breakpoint.c (init_raw_breakpoint_without_location): Remove
7360 memset call and initializations no longer necessary.
7361
7362 2017-04-25 Pedro Alves <palves@redhat.com>
7363
7364 * btrace.c (pt_btrace_insn_flags): Change parameter type to
7365 reference.
7366 (pt_btrace_insn): New function.
7367 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
7368
7369 2017-04-25 Pedro Alves <palves@redhat.com>
7370
7371 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
7372 "base" field and inherit from "bp_location" instead. Add
7373 non-default ctor.
7374 (allocate_location_exception): Use new non-default ctor.
7375 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
7376 (init_bp_location): Convert to ...
7377 (bp_location::bp_location): ... this new ctor, and remove memset
7378 call.
7379 (base_breakpoint_allocate_location): Use the new non-default ctor.
7380 * breakpoint.h (bp_location): Now a class. Declare default and
7381 non-default ctors. In-class initialize all members.
7382 (init_bp_location): Remove declaration.
7383
7384 2017-04-25 Pedro Alves <palves@redhat.com>
7385
7386 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
7387 assignment operator.
7388
7389 2017-04-24 Yao Qi <yao.qi@linaro.org>
7390
7391 * doublest.c (convert_doublest_to_floatformat): Call
7392 floatformat_totalsize_bytes.
7393
7394 2017-04-22 Tom Tromey <tom@tromey.com>
7395
7396 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7397 ui_out_emit_list.
7398 * stack.c (print_frame): Use ui_out_emit_list.
7399 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7400 ui_out_emit_list.
7401 * mi/mi-main.c (print_one_inferior)
7402 (mi_cmd_data_list_register_names)
7403 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7404 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7405 ui_out_emit_list.
7406 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7407 (mi_output_solib_attribs): Use ui_out_emit_list,
7408 ui_out_emit_tuple.
7409 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7410 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7411 (mi_cmd_stack_list_args, list_args_or_locals): Use
7412 ui_out_emit_list.
7413 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7414 * breakpoint.c (print_solib_event, output_thread_groups): Use
7415 ui_out_emit_list.
7416
7417 2017-04-22 Tom Tromey <tom@tromey.com>
7418
7419 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7420 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7421 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7422
7423 2017-04-22 Tom Tromey <tom@tromey.com>
7424
7425 * tracepoint.c (tvariables_info_1)
7426 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7427
7428 2017-04-22 Tom Tromey <tom@tromey.com>
7429
7430 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7431 annotate_arg_emitter.
7432 * breakpoint.c (print_mention_watchpoint)
7433 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7434 * annotate.h (struct annotate_arg_emitter): New.
7435
7436 2017-04-22 Tom Tromey <tom@tromey.com>
7437
7438 * record-btrace.c (record_btrace_insn_history)
7439 (record_btrace_insn_history_range, record_btrace_call_history)
7440 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7441 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7442 ui_out_emit_tuple.
7443 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7444 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7445 * skip.c (skip_info): Use ui_out_emit_tuple.
7446 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7447 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7448 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7449 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7450 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7451 ui_out_emit_tuple.
7452 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7453 (output_register, mi_cmd_data_read_memory)
7454 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7455 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7456 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7457 Use ui_out_emit_tuple.
7458 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7459 ui_out_emit_tuple.
7460 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7461 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7462 * linux-thread-db.c (info_auto_load_libthread_db): Use
7463 ui_out_emit_tuple.
7464 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7465 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7466 * disasm.c (do_mixed_source_and_assembly_deprecated)
7467 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7468 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7469 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7470 * breakpoint.c (print_one_breakpoint_location)
7471 (print_one_breakpoint): Use ui_out_emit_tuple.
7472 * auto-load.c (print_script, info_auto_load_cmd): Use
7473 ui_out_emit_tuple.
7474 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7475
7476 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7477
7478 * thread.c (print_thread_info_1): Remove dead code.
7479
7480 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7481
7482 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7483 GDB_SELF_TEST.
7484 * arm-tdep.c (selftests::arm_record_test): Likewise.
7485
7486 2017-04-21 Yao Qi <yao.qi@linaro.org>
7487
7488 * regcache.c (regcache_restore): Remove argument 2. Replace
7489 argument 3 with regcache. Get register status from
7490 src->register_status and get register contents from
7491 register_buffer (src, regnum).
7492 (regcache_cpy): Update.
7493
7494 2017-04-19 Pedro Alves <palves@redhat.com>
7495
7496 * gdbthread.h (thread): Add missing closing parenthesis in
7497 comment.
7498
7499 2017-04-19 Pedro Alves <palves@redhat.com>
7500
7501 * common/refcounted-object.h: New file.
7502 * gdbthread.h: Include "common/refcounted-object.h".
7503 (thread_info): Inherit from refcounted_object and add comments.
7504 (thread_info::incref, thread_info::decref)
7505 (thread_info::m_refcount): Delete.
7506 (thread_info::deletable): Use the refcounted_object::refcount()
7507 method.
7508 * inferior.c (current_inferior_): Add comment.
7509 (set_current_inferior): Increment/decrement refcounts.
7510 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7511 not-deletable instead of comparing with the current inferior.
7512 (initialize_inferiors): Increment the initial inferior's refcount.
7513 * inferior.h (struct inferior): Forward declare.
7514 Include "common/refcounted-object.h".
7515 (current_inferior, set_current_inferior): Move declaration to
7516 before struct inferior's definition, and fix comment.
7517 (inferior): Inherit from refcounted_object. Add comments.
7518 * thread.c (switch_to_thread_no_regs): Reference the thread's
7519 inferior pointer directly instead of doing a ptid lookup.
7520 (switch_to_no_thread): New function.
7521 (switch_to_thread(thread_info *)): New function, factored out
7522 from ...
7523 (switch_to_thread(ptid_t)): ... this.
7524 (restore_current_thread): Delete.
7525 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7526 fields, and add 'inf' field.
7527 (do_restore_current_thread_cleanup): Check whether old->inf is
7528 alive instead of looking up an inferior by ptid. Use
7529 switch_to_thread and switch_to_no_thread.
7530 (restore_current_thread_cleanup_dtor): Use old->inf directly
7531 instead of lookup up an inferior by id. Decref the inferior.
7532 Don't restore 'removable'.
7533 (make_cleanup_restore_current_thread): Same the inferior pointer
7534 in old, instead of the inferior number. Incref the inferior.
7535 Don't save/clear 'removable'.
7536
7537 2017-04-19 Pedro Alves <palves@redhat.com>
7538
7539 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7540 unittests/scoped_restore-selftests.c.
7541 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7542 * common/scoped_restore.h (scoped_restore_base): Make "class".
7543 (scoped_restore_base::release): New public method.
7544 (scoped_restore_base::scoped_restore_base): New protected ctor.
7545 (scoped_restore_base::m_saved_var): New protected field.
7546 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7547 scoped_restore_base base class instead of m_saved_var directly.
7548 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7549 (scoped_restore_tmpl::scoped_restore_tmpl(const
7550 scoped_restore_tmpl<T>&)): Likewise.
7551 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7552 method.
7553 (scoped_restore_tmpl::saved_var): New method.
7554 (scoped_restore_tmpl::m_saved_var): Delete.
7555 * inferior.h (inferior::detaching): Now a bool.
7556 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7557 cleanup.
7558 * unittests/scoped_restore-selftests.c: New file.
7559
7560 2017-04-19 Pedro Alves <palves@redhat.com>
7561
7562 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7563 Re-sort in alphabetic order.
7564
7565 2017-04-18 Pedro Alves <palves@redhat.com>
7566
7567 * xml-support.c (obstack_xml_printf): Delete.
7568 * xml-support.h (obstack_xml_printf): Delete.
7569
7570 2017-04-18 Pedro Alves <palves@redhat.com>
7571
7572 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7573 vdebug, verror, body_text, start_element, end_element, name,
7574 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7575 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7576 is_xinclude>: Make private and add m_ prefix.
7577 (gdb_xml_parser::body_text): New method, based on ...
7578 (gdb_xml_body_text): ... this. Adjust.
7579 (gdb_xml_parser::vdebug): New method, based on ...
7580 (gdb_xml_debug): ... this. Adjust.
7581 (gdb_xml_parser::verror): New method, based on ...
7582 (gdb_xml_error): ... this. Adjust.
7583 (gdb_xml_parser::start_element): New method, based on ...
7584 (gdb_xml_start_element): ... this. Adjust.
7585 (gdb_xml_start_element_wrapper): Defer to
7586 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7587 (gdb_xml_parser::end_element): New method, based on ...
7588 (gdb_xml_end_element_wrapper): ... this. Adjust.
7589 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7590 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7591 (gdb_xml_parser::use_dtd): New method, based on ...
7592 (gdb_xml_use_dtd): ... this. Adjust.
7593 (gdb_xml_parser::parse): New method, based on ...
7594 (gdb_xml_parse): ... this. Adjust.
7595 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7596 (xinclude_start_include): Adjust to call the parser's name method.
7597 (xml_xinclude_default, xml_xinclude_start_doctype)
7598 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7599 method.
7600 (xml_process_xincludes): Adjust to call parser methods.
7601 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7602 declarations.
7603
7604 2017-04-18 Pedro Alves <palves@redhat.com>
7605
7606 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7607 gdb::optional<std::string>.
7608 * xml-support.c: Include <string>.
7609 (scope_level::scope_level(scope_level &&))
7610 (scope_level::~scope_level): Delete.
7611 (scope_level::body): Now a std::string.
7612 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7613 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7614 parameter.
7615 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7616 (xinclude_parsing_data::output): Now a std::string reference.
7617 (xinclude_start_include): Adjust.
7618 (xml_xinclude_default): Adjust.
7619 (xml_process_xincludes): Add 'output' parameter, and return bool.
7620 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7621 and return bool.
7622 * xml-tdesc.c: Include <unordered_map> and <string>.
7623 (tdesc_xml_cache): Delete.
7624 (tdesc_xml_cache_s): Delete.
7625 (xml_cache): Now an std::unordered_map.
7626 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7627 (target_fetch_description_xml): Change return type to
7628 gdb::optional<std::string>, and adjust.
7629 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7630 (target_fetch_description_xml): Change return type to
7631 gdb::optional<std::string>.
7632
7633 2017-04-18 Pedro Alves <palves@redhat.com>
7634
7635 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7636 unittests/optional-selftests.c.
7637 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7638 * unittests/optional-selftests.c: New file.
7639 * unittests/optional/assignment/1.cc: New file.
7640 * unittests/optional/assignment/2.cc: New file.
7641 * unittests/optional/assignment/3.cc: New file.
7642 * unittests/optional/assignment/4.cc: New file.
7643 * unittests/optional/assignment/5.cc: New file.
7644 * unittests/optional/assignment/6.cc: New file.
7645 * unittests/optional/assignment/7.cc: New file.
7646 * unittests/optional/cons/copy.cc: New file.
7647 * unittests/optional/cons/default.cc: New file.
7648 * unittests/optional/cons/move.cc: New file.
7649 * unittests/optional/cons/value.cc: New file.
7650 * unittests/optional/in_place.cc: New file.
7651 * unittests/optional/observers/1.cc: New file.
7652 * unittests/optional/observers/2.cc: New file.
7653
7654 2017-04-18 Pedro Alves <palves@redhat.com>
7655
7656 * common/gdb_optional.h: Include common/traits.h.
7657 (in_place_t): New type.
7658 (in_place): New constexpr variable.
7659 (optional::optional): Remove member initialization of
7660 m_instantiated.
7661 (optional::optional(in_place_t...)): New constructor.
7662 (optional::~optional): Use reset.
7663 (optional::optional(const optional&)): New.
7664 (optional::optional(const optional&&)): New.
7665 (optional::optional(T &)): New.
7666 (optional::optional(T &&)): New.
7667 (operator::operator=(const optional &)): New.
7668 (operator::operator=(optional &&)): New.
7669 (operator::operator= (const T &))
7670 (operator::operator= (T &&))
7671 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7672 (operator::reset): New.
7673 (operator::m_instantiated):: Add in-class initializer.
7674 * common/traits.h: Include <type_traits>.
7675 (struct And): New types.
7676
7677 2017-04-18 Pedro Alves <palves@redhat.com>
7678
7679 * xml-support.c: Include <vector>.
7680 (scope_level::scope_level(const gdb_xml_element *))
7681 (scope_level::scope_level(scope_level&&)): New.
7682 (scope_level::~scope_level): New.
7683 (scope_level_s): Delete.
7684 (gdb_xml_parser::scopes): Now a std::vector.
7685 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
7686 Use std::vector.
7687 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
7688 scope cleanup code.
7689 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
7690 of the scopes member. Use std::vector::emplace_back.
7691
7692 2017-04-18 Pedro Alves <palves@redhat.com>
7693
7694 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
7695 a bool.
7696 (gdb_xml_end_element): Change type of first parameter.
7697 (gdb_xml_cleanup): Rename to ...
7698 (gdb_xml_parser::~gdb_xml_parser): ... this.
7699 (gdb_xml_create_parser_and_cleanup): Delete with ...
7700 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
7701 to this new ctor.
7702 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
7703 using gdb_xml_create_parser_and_cleanup.
7704 (xinclude_parsing_data): Add ctor/dtor.
7705 (xml_xinclude_cleanup): Delete.
7706 (xml_process_xincludes): Create a local xinclude_parsing_data
7707 instead of heap-allocating one. Create a local gdb_xml_parser
7708 instead of heap-allocating one with
7709 gdb_xml_create_parser_and_cleanup.
7710
7711 2017-04-18 John Baldwin <jhb@FreeBSD.org>
7712
7713 PR threads/20743
7714 * fbsd-nat.c (resume_one_thread_cb): Remove.
7715 (resume_all_threads_cb): Remove.
7716 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
7717 iterate_over_threads.
7718
7719 2017-04-17 Joel Brobecker <brobecker@adacore.com>
7720
7721 * NEWS: Create a new section for the next release branch.
7722 Rename the section of the current branch, now that it has
7723 been cut.
7724
7725 2017-04-17 Joel Brobecker <brobecker@adacore.com>
7726
7727 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
7728 * version.in: Bump version to 8.0.50.DATE-git.
7729
7730 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
7731
7732 PR gdb/21385
7733 * windows-nat.c (windows_create_inferior): Declare 'allargs'
7734 independently of the host, and fix build breakage on Cygwin.
7735
7736 2017-04-13 Pedro Alves <palves@redhat.com>
7737
7738 * inferior.c (free_inferior): Convert to ...
7739 (inferior::~inferior): ... this dtor.
7740 (inferior::inferior): New ctor, factored out from ...
7741 (add_inferior_silent): ... here. Allocate the inferior with a new
7742 expression.
7743 (delete_inferior): Call delete instead of free_inferior.
7744 * inferior.h (gdb_environ, continuation): Forward declare.
7745 (inferior): Now a class. Add in-class initialization to all
7746 members. Make boolean fields bool, except 'detaching'.
7747 (inferior::inferior): New explicit ctor.
7748 (inferior::~inferior): New.
7749
7750 2017-04-13 Pedro Alves <palves@redhat.com>
7751
7752 * inferior.c (init_inferior_list): Delete.
7753 * inferior.h (init_inferior_list): Delete.
7754
7755 2017-04-13 Pedro Alves <palves@redhat.com>
7756
7757 PR threads/13217
7758 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
7759 (top level): Call it twice, with different thread sets.
7760
7761 2017-04-13 Pedro Alves <palves@redhat.com>
7762
7763 * thread.c: Include <algorithm>.
7764 (thread_array_cleanup): Delete.
7765 (scoped_inc_dec_ref): New class.
7766 (live_threads_count): New function.
7767 (set_thread_refcount): Delete.
7768 (tp_array_compar_ascending): Now a bool.
7769 (tp_array_compar): Convert to a std::sort comparison function.
7770 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
7771 and live_threads_count.
7772
7773 2017-04-13 Pedro Alves <palves@redhat.com>
7774
7775 * infrun.c (follow_fork_inferior): Also switch the current
7776 inferior.
7777
7778 2017-04-13 Pedro Alves <palves@redhat.com>
7779
7780 * breakpoint.c (watch_command_1): Save watchpoint-frame info
7781 before calling create_internal_breakpoint.
7782
7783 2017-04-13 Pedro Alves <palves@redhat.com>
7784
7785 * fork-child.c (execv_argv): New class.
7786 (breakup_args): Refactored as ...
7787 (execv_argv::init_for_no_shell): .. this method of execv_argv.
7788 Copy arguments to storage and replace separators with NULL
7789 terminators in place.
7790 (escape_bang_in_quoted_argument): Adjust to return bool.
7791 (execv_argv::execv_argv): New ctor.
7792 (execv_argv::init_for_shell): New method, factored out from
7793 fork_inferior. Don't strdup strings into the vector.
7794 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
7795 Remove free_vector_argv call.
7796
7797 2017-04-13 Yao Qi <yao.qi@linaro.org>
7798
7799 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
7800 tdep->rx_psw_type.
7801
7802 2017-04-13 Yao Qi <yao.qi@linaro.org>
7803
7804 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
7805 * rx-tdep.c (rx_gdbarch_init): Likewise.
7806
7807 2017-04-13 Pedro Alves <palves@redhat.com>
7808
7809 * breakpoint.h (struct breakpoint): Reindent.
7810
7811 2017-04-13 Pedro Alves <palves@redhat.com>
7812
7813 * breakpoint.c (bp_location): Rename to ...
7814 (bp_locations): ... this. All references updated.
7815 (bp_location_count): Rename to ...
7816 (bp_locations_count): ... this. All references updated.
7817 (bp_location_placed_address_before_address_max): Rename to ...
7818 (bp_locations_placed_address_before_address_max): ... this. All
7819 references updated.
7820 (bp_location_shadow_len_after_address_max): Rename to ...
7821 (bp_locations_shadow_len_after_address_max): ... this. All
7822 references updated.
7823 (bp_location_compare_addrs): Rename to ...
7824 (bp_locations_compare_addrs): ... this. All references updated.
7825 (bp_location_compare):Rename to ...
7826 (bp_locations_compare): ... this. All references updated.
7827 (bp_location_target_extensions_update): Rename to ...
7828 (bp_locations_target_extensions_update): ... this. All references
7829 updated.
7830
7831 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7832
7833 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
7834 * common/common.m4: Check headers 'termios.h', 'termio.h' and
7835 'sgtty.h'.
7836 * common/gdb_termios.h: New file, with parts of "terminal.h".
7837 * inflow.c: Include "gdb_termios.h".
7838 * ser-unix.c: Include "gdb_termios.h".
7839 * terminal.h: Move terminal-related defines to
7840 "common/gdb_termios.h".
7841
7842 2017-04-12 Tom Tromey <tom@tromey.com>
7843
7844 * probe.c (parse_probes): Update.
7845 * location.h (delete_event_location): Don't declare.
7846 (event_location_deleter::operator()): Update.
7847 * location.c (event_location_deleter::operator()): Rename from
7848 delete_event_location.
7849 * linespec.h (linespec_result) <location>: Change type to
7850 event_location_up.
7851 * linespec.c (canonicalize_linespec, event_location_to_sals)
7852 (decode_objc): Update.
7853 (linespec_result): Don't call delete_event_location.
7854 * breakpoint.c (create_breakpoints_sal)
7855 (bkpt_probe_create_sals_from_location)
7856 (strace_marker_create_sals_from_location): Update.
7857
7858 2017-04-12 Tom Tromey <tom@tromey.com>
7859
7860 * linespec.h (struct linespec_result): Add constructor and
7861 destructor.
7862 (init_linespec_result, destroy_linespec_result)
7863 (make_cleanup_destroy_linespec_result): Don't declare.
7864 * linespec.c (init_linespec_result): Remove.
7865 (linespec_result::~linespec_result): Rename from
7866 destroy_linespec_result. Update.
7867 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
7868 Remove.
7869 * breakpoint.c (create_breakpoint, break_range_command)
7870 (decode_location_default): Update.
7871 * ax-gdb.c (agent_command_1): Update.
7872
7873 2017-04-12 Tom Tromey <tom@tromey.com>
7874
7875 * remote.c (remote_download_tracepoint): Update.
7876 * python/py-breakpoint.c (bppy_get_location): Update.
7877 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
7878 (gdbscm_breakpoint_location): Update.
7879 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
7880 * breakpoint.h (struct breakpoint) <location, location_range_end>:
7881 Change type to event_location_up.
7882 * breakpoint.c (create_overlay_event_breakpoint)
7883 (create_longjmp_master_breakpoint)
7884 (create_std_terminate_master_breakpoint)
7885 (create_exception_master_breakpoint)
7886 (breakpoint_event_location_empty_p, print_breakpoint_location)
7887 (print_one_breakpoint_location, create_thread_event_breakpoint)
7888 (init_breakpoint_sal, create_breakpoint)
7889 (print_recreate_ranged_breakpoint, break_range_command)
7890 (init_ada_exception_breakpoint, say_where): Update.
7891 (base_breakpoint_dtor): Don't call delete_event_location.
7892 (bkpt_print_recreate, tracepoint_print_recreate)
7893 (dprintf_print_recreate, update_static_tracepoint)
7894 (breakpoint_re_set_default): Update.
7895
7896 2017-04-12 Tom Tromey <tom@tromey.com>
7897
7898 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
7899 type of "to_do". Update.
7900 (compute_stack_depth): Use std::vector.
7901
7902 2017-04-12 Tom Tromey <tom@tromey.com>
7903
7904 * printcmd.c (find_instruction_backward): Use std::vector.
7905
7906 2017-04-12 Tom Tromey <tom@tromey.com>
7907
7908 * symfile.c (objfilep): Remove typedef.
7909 (reread_symbols): Use a std::vector.
7910
7911 2017-04-12 Tom Tromey <tom@tromey.com>
7912
7913 * mi/mi-main.c (exec_direction_forward): Remove.
7914 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
7915 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7916 scoped_restore.
7917 * guile/guile.c (guile_repl_command, guile_command)
7918 (gdbscm_execute_gdb_command): Use scoped_restore.
7919 * go-exp.y (go_parse): Use scoped_restore.
7920 * d-exp.y (d_parse): Use scoped_restore.
7921 * cli/cli-decode.c (cmd_func): Use scoped_restore.
7922 * c-exp.y (c_parse): Use scoped_restore.
7923
7924 2017-04-12 Tom Tromey <tom@tromey.com>
7925
7926 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
7927 (mi_parse): Update return type.
7928 (mi_parse_free): Remove.
7929 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
7930 (mi_parse::~mi_parse): Rename from mi_parse_free.
7931 (mi_parse_cleanup): Remove.
7932 (mi_parse): Return a unique_ptr. Use new.
7933 * mi/mi-main.c (mi_execute_command): Update.
7934
7935 2017-04-12 Tom Tromey <tom@tromey.com>
7936
7937 * location.c (explicit_location_lex_one): Return a
7938 unique_xmalloc_ptr.
7939 (string_to_explicit_location): Update. Remove cleanups.
7940
7941 2017-04-12 Tom Tromey <tom@tromey.com>
7942
7943 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
7944 (compare_value_and_voffset): Change type. Update.
7945 (compute_vtable_size): Change type of "offset_vec".
7946 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
7947 (gnuv3_get_typeid): Remove extraneous declaration.
7948
7949 2017-04-12 Tom Tromey <tom@tromey.com>
7950
7951 * charset.h (wchar_iterator): Fix comment.
7952
7953 2017-04-12 Tom Tromey <tom@tromey.com>
7954
7955 * charset.c (iconv_wrapper): New class.
7956 (cleanup_iconv): Remove.
7957 (convert_between_encodings): Use it.
7958
7959 2017-04-12 Tom Tromey <tom@tromey.com>
7960
7961 * symfile.h (increment_reading_symtab): Update type.
7962 * symfile.c (decrement_reading_symtab): Remove.
7963 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
7964 * psymtab.c (psymtab_to_symtab): Update.
7965 * dwarf2read.c (dw2_instantiate_symtab): Update.
7966
7967 2017-04-12 Tom Tromey <tom@tromey.com>
7968
7969 * jit.c (struct jit_reader): Declare separately. Add constructor
7970 and destructor. Change type of "handle".
7971 (loaded_jit_reader): Define separately.
7972 (jit_reader_load): Update. New "new".
7973 (jit_reader_unload_command): Use "delete".
7974 * gdb-dlfcn.h (struct dlclose_deleter): New.
7975 (gdb_dlhandle_up): New typedef.
7976 (gdb_dlopen, gdb_dlsym): Update types.
7977 (gdb_dlclose): Remove.
7978 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
7979 (gdb_dlsym): Change type of "handle".
7980 (make_cleanup_dlclose): Remove.
7981 (dlclose_deleter::operator()): Rename from gdb_dlclose.
7982 * compile/compile-c-support.c (load_libcc): Update.
7983
7984 2017-04-12 Tom Tromey <tom@tromey.com>
7985
7986 * symtab.h (find_pcs_for_symtab_line): Change return type.
7987 * symtab.c (find_pcs_for_symtab_line): Change return type.
7988 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
7989 type of "vec". Update.
7990 (ltpy_get_pcs_for_line): Update.
7991 * linespec.c (decode_digits_ordinary): Update.
7992
7993 2017-04-12 Tom Tromey <tom@tromey.com>
7994
7995 * tracepoint.c (actions_command): Update.
7996 * python/python.c (python_command, python_interactive_command):
7997 Update.
7998 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7999 * guile/guile.c (guile_command): Update.
8000 * defs.h (read_command_lines, read_command_lines_1): Return
8001 command_line_up.
8002 (command_lines_deleter): New struct.
8003 (command_line_up): New typedef.
8004 * compile/compile.c (compile_code_command)
8005 (compile_print_command): Update.
8006 * cli/cli-script.h (get_command_line, copy_command_lines): Return
8007 command_line_up.
8008 (make_cleanup_free_command_lines): Remove.
8009 * cli/cli-script.c (get_command_line, read_command_lines_1)
8010 (copy_command_lines): Return command_line_up.
8011 (while_command, if_command, read_command_lines, define_command)
8012 (document_command): Update.
8013 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
8014 Remove.
8015 * breakpoint.h (breakpoint_set_commands): Change type of
8016 "commands".
8017 * breakpoint.c (breakpoint_set_commands): Change type of
8018 "commands". Update.
8019 (do_map_commands_command, update_dprintf_command_list)
8020 (create_tracepoint_from_upload): Update.
8021
8022 2017-04-12 Tom Tromey <tom@tromey.com>
8023
8024 * tracepoint.c (scope_info): Update.
8025 * spu-tdep.c (spu_catch_start): Update.
8026 * python/python.c (gdbpy_decode_line): Update.
8027 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
8028 * python/py-breakpoint.c (bppy_init): Update.
8029 * probe.c (parse_probes): Update.
8030 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
8031 * location.h (event_location_deleter): New struct.
8032 (event_location_up): New typedef.
8033 (new_linespec_location, new_address_location, new_probe_location)
8034 (new_explicit_location, copy_event_location)
8035 (string_to_event_location, string_to_event_location_basic)
8036 (string_to_explicit_location): Update return type.
8037 (make_cleanup_delete_event_location): Remove.
8038 * location.c (new_linespec_location, new_address_location)
8039 (new_probe_location, new_explicit_location, copy_event_location):
8040 Return event_location_up.
8041 (delete_event_location_cleanup)
8042 (make_cleanup_delete_event_location): Remove.
8043 (string_to_explicit_location, string_to_event_location_basic)
8044 (string_to_event_location): Return event_location_up.
8045 * linespec.c (canonicalize_linespec, event_location_to_sals)
8046 (decode_line_with_current_source)
8047 (decode_line_with_last_displayed, decode_objc): Update.
8048 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
8049 * completer.c (location_completer): Update.
8050 * cli/cli-cmds.c (edit_command, list_command): Update.
8051 * breakpoint.c (create_overlay_event_breakpoint)
8052 (create_longjmp_master_breakpoint)
8053 (create_std_terminate_master_breakpoint)
8054 (create_exception_master_breakpoint)
8055 (create_thread_event_breakpoint): Update.
8056 (init_breakpoint_sal): Update. Remove some dead code.
8057 (create_breakpoint_sal): Change type of "location". Update.
8058 (create_breakpoints_sal, create_breakpoint, break_command_1)
8059 (dprintf_command, break_range_command, until_break_command)
8060 (init_ada_exception_breakpoint)
8061 (strace_marker_create_sals_from_location)
8062 (update_static_tracepoint, trace_command, ftrace_command)
8063 (strace_command, create_tracepoint_from_upload): Update.
8064 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8065 * ax-gdb.c (agent_command_1): Update.
8066
8067 2017-04-12 Pedro Alves <palves@redhat.com>
8068
8069 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
8070 * configure.tgt: Handle i[34567]86-*-go32* and
8071 i[34567]86-*-msdosdjgpp*.
8072 * i386-tdep.c (i386_svr4_reg_to_regnum):
8073 Make extern.
8074 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
8075 i386-go32-tdep.c.
8076 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
8077 * i386-go32-tdep.c: New file.
8078 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
8079 declarations.
8080
8081 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
8082
8083 * aix-thread.c (pd_status2str): Change return type to const char *.
8084
8085 2017-04-12 Pedro Alves <palves@redhat.com>
8086
8087 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
8088 calls to set_gdbarch_gnu_triplet_regexp.
8089
8090 2017-04-12 Pedro Alves <palves@redhat.com>
8091
8092 PR gdb/21323
8093 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
8094 New enum value.
8095 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
8096 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
8097 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
8098 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
8099 * gdbarch.h, gdbarch.c: Regenerate.
8100 * aarch64-tdep.c (aarch64_gdbarch_init): Override
8101 gdbarch_wchar_bit and gdbarch_wchar_signed.
8102 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
8103 * arm-tdep.c (arm_gdbarch_init): Likewise.
8104 * avr-tdep.c (avr_gdbarch_init): Likewise.
8105 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
8106 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
8107 * i386-tdep.c (i386_go32_init_abi): Likewise.
8108 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8109 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8110 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8111 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8112 * sh-tdep.c (sh_gdbarch_init): Likewise.
8113 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8114 * sparc64-tdep.c (sparc64_init_abi): Likewise.
8115 * windows-tdep.c (windows_init_abi): Likewise.
8116 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8117
8118 2017-04-12 Pedro Alves <palves@redhat.com>
8119
8120 PR c++/21323
8121 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
8122 cplus_primitive_type_char32_t>: New enum values.
8123 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
8124 and cplus_primitive_type_char32_t.
8125 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
8126 32, use the archtecture's built-in type for char16_t and char32_t,
8127 respectively. Otherwise, fallback to init_integer_type as before,
8128 but make the type unsigned, and issue a complaint.
8129 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
8130
8131 2017-04-12 Alan Hayward <alan.hayward@arm.com>
8132
8133 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
8134 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
8135
8136 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8137
8138 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
8139 'const char *'.
8140
8141 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8142
8143 * common/common-utils.c (free_vector_argv): New function.
8144 * common/common-utils.h: Include <vector>.
8145 (free_vector_argv): New prototype.
8146 * darwin-nat.c (darwin_create_inferior): Rewrite function
8147 prototype in order to constify "exec_file" and accept a
8148 "std::string" for "allargs".
8149 * fork-child.c: Include <vector>.
8150 (breakup_args): Rewrite function, using C++.
8151 (fork_inferior): Rewrite function header, constify "exec_file_arg"
8152 and accept "std::string" for "allargs". Update the code to
8153 calculate "argv" based on "allargs". Update calls to "exec_fun"
8154 and "execvp".
8155 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
8156 order to constify "exec_file" and accept a "std::string" for
8157 "allargs".
8158 * go32-nat.c (go32_create_inferior): Likewise.
8159 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
8160 * infcmd.c (run_command_1): Constify "exec_file". Use
8161 "std::string" for inferior arguments.
8162 * inferior.h (fork_inferior): Update prototype.
8163 * linux-nat.c (linux_nat_create_inferior): Rewrite function
8164 prototype in order to constify "exec_file" and accept a
8165 "std::string" for "allargs".
8166 * nto-procfs.c (procfs_create_inferior): Likewise.
8167 * procfs.c (procfs_create_inferior): Likewise.
8168 * remote-sim.c (gdbsim_create_inferior): Likewise.
8169 * remote.c (extended_remote_run): Update code to accept
8170 "std::string" as argument.
8171 (extended_remote_create_inferior): Rewrite function prototype in
8172 order to constify "exec_file" and accept a "std::string" for
8173 "allargs".
8174 * rs6000-nat.c (super_create_inferior): Likewise.
8175 (rs6000_create_inferior): Likewise.
8176 * target.h (struct target_ops) <to_create_inferior>: Likewise.
8177 * windows-nat.c (windows_create_inferior): Likewise.
8178
8179 2017-04-11 Pedro Alves <palves@redhat.com>
8180
8181 * thread.c: Fix whitespace throughout.
8182
8183 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
8184
8185 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
8186
8187 2017-04-11 Alan Hayward <alan.hayward@arm.com>
8188
8189 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
8190
8191 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
8192
8193 PR gdb/21364
8194 * osdata.c (info_osdata): Check if 'type' is an empty string
8195 instead of NULL.
8196
8197 2017-04-10 Pedro Alves <palves@redhat.com>
8198
8199 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
8200 (ptid_to_global_thread_id, in_thread_list)
8201 (do_captured_list_thread_ids, set_resumed, set_running)
8202 (set_executing, set_stop_requested, finish_thread_state)
8203 (validate_registers_access, can_access_registers_ptid)
8204 (print_thread_info_1, switch_to_thread)
8205 (do_restore_current_thread_cleanup)
8206 (make_cleanup_restore_current_thread, thread_command)
8207 (thread_name_command): Use operator== instead of ptid_equal.
8208
8209 2017-04-10 Pedro Alves <palves@redhat.com>
8210
8211 * thread.c (struct current_thread_cleanup) <next>: Delete field.
8212 (current_thread_cleanup_chain): Delete.
8213 (restore_current_thread_cleanup_dtor)
8214 (make_cleanup_restore_current_thread): Remove references to
8215 current_thread_cleanup_chain.
8216
8217 2017-04-10 Alan Hayward <alan.hayward@arm.com>
8218
8219 * msp430-tdep.c (msp430_pseudo_register_read): Never return
8220 REG_UNKNOWN.
8221
8222 2017-04-10 Yao Qi <yao.qi@linaro.org>
8223
8224 PR gdb/19942
8225 * gdbthread.h (thread_info::deletable): New method.
8226 (thread_info::incref): New method.
8227 (thread_info::decref): New method.
8228 (thread_info::refcount): Move it to private.
8229 * infrun.c (save_stop_context): Call inc_refcount.
8230 (release_stop_context_cleanup): Likewise.
8231 * thread.c (set_thread_exited): New function.
8232 (init_thread_list): Delete "tp" only it is deletable, otherwise
8233 call set_thread_exited.
8234 (delete_thread_1): Call set_thread_exited.
8235 (current_thread_cleanup) <inferior_pid>: Remove.
8236 <thread>: New field.
8237 (restore_current_thread_ptid_changed): Removed.
8238 (do_restore_current_thread_cleanup): Adjust.
8239 (restore_current_thread_cleanup_dtor): Don't call
8240 find_thread_ptid.
8241 (set_thread_refcount): Use dec_refcount.
8242 (make_cleanup_restore_current_thread): Adjust.
8243 (thread_apply_all_command): Call inc_refcount.
8244 (_initialize_thread): Don't call
8245 observer_attach_thread_ptid_changed.
8246
8247 2017-04-10 Yao Qi <yao.qi@linaro.org>
8248
8249 * thread.c (delete_thread_1): Hoist code on marking thread as
8250 exited.
8251
8252 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8253
8254 * windows-nat.c (windows_detach): Initialize ptid with
8255 minus_one_ptid.
8256
8257 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
8258
8259 * unittests/ptid-selftests.c: Fix erroneous assert messages.
8260
8261 2017-04-07 Alan Hayward <alan.hayward@arm.com>
8262
8263 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
8264 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
8265 (bfin_pseudo_register_write): Likewise
8266
8267 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
8268
8269 * common/ptid.h (struct ptid): Change to...
8270 (class ptid_t): ... this.
8271 <ptid_t>: New constructors.
8272 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
8273 matches>: New methods.
8274 <make_null, make_minus_one>: New static methods.
8275 <pid>: Rename to...
8276 <m_pid>: ...this.
8277 <lwp>: Rename to...
8278 <m_lwp>: ...this.
8279 <tid>: Rename to...
8280 <m_tid>: ...this.
8281 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
8282 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
8283 as references, move comment to class ptid_t.
8284 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
8285 ptid_t static methods.
8286 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
8287 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
8288 Take ptid arguments as references, implement using ptid_t methods.
8289 * unittests/ptid-selftests.c: New file.
8290 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8291 unittests/ptid-selftests.c.
8292 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
8293
8294 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
8295
8296 * python/python.c (python_run_simple_file): Cast mode literal to
8297 non-const char pointer as expected by PyFile_FromString.
8298
8299 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
8300
8301 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
8302 minus_one_ptid and null_ptid.
8303
8304 2017-04-05 Pedro Alves <palves@redhat.com>
8305
8306 * warning.m4 (build_warnings): Remove -Wno-write-strings.
8307 * configure: Regenerate.
8308
8309 2017-04-05 Pedro Alves <palves@redhat.com>
8310
8311 * ada-exp.y (yyerror): Constify.
8312 * ada-lang.c (bound_name, get_selections)
8313 (ada_variant_discrim_type)
8314 (ada_variant_discrim_name, ada_value_struct_elt)
8315 (ada_lookup_struct_elt_type, is_unchecked_variant)
8316 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
8317 (catch_ada_exception_command_split)
8318 (catch_ada_assert_command_split, catch_assert_command)
8319 (ada_op_name): Constify.
8320 * ada-lang.h (ada_yyerror, get_selections)
8321 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
8322 * arc-tdep.c (arc_print_frame_cache): Constify.
8323 * arm-tdep.c (arm_skip_stub): Constify.
8324 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
8325 (gen_aggregate_elt_ref): Constify.
8326 * bcache.c (print_bcache_statistics): Constify.
8327 * bcache.h (print_bcache_statistics): Constify.
8328 * break-catch-throw.c (catch_exception_command_1):
8329 * breakpoint.c (struct ep_type_description::description):
8330 Constify.
8331 (add_solib_catchpoint): Constify.
8332 (catch_fork_command_1): Add cast.
8333 (add_catch_command): Constify.
8334 * breakpoint.h (add_catch_command, add_solib_catchpoint):
8335 Constify.
8336 * bsd-uthread.c (bsd_uthread_state): Constify.
8337 * buildsym.c (patch_subfile_names): Constify.
8338 * buildsym.h (next_symbol_text_func, patch_subfile_names):
8339 Constify.
8340 * c-exp.y (yyerror): Constify.
8341 (token::oper): Constify.
8342 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
8343 * c-varobj.c (cplus_describe_child): Constify.
8344 * charset.c (find_charset_names): Add cast.
8345 (find_charset_names): Constify array and add const_cast.
8346 * cli/cli-cmds.c (complete_command, cd_command): Constify.
8347 (edit_command): Constify.
8348 * cli/cli-decode.c (lookup_cmd): Constify.
8349 * cli/cli-dump.c (dump_memory_command, dump_value_command):
8350 Constify.
8351 (struct dump_context): Constify.
8352 (add_dump_command, restore_command): Constify.
8353 * cli/cli-script.c (get_command_line): Constify.
8354 * cli/cli-script.h (get_command_line): Constify.
8355 * cli/cli-utils.c (check_for_argument): Constify.
8356 * cli/cli-utils.h (check_for_argument): Constify.
8357 * coff-pe-read.c (struct read_pe_section_data): Constify.
8358 * command.h (lookup_cmd): Constify.
8359 * common/print-utils.c (decimal2str): Constify.
8360 * completer.c (gdb_print_filename): Constify.
8361 * corefile.c (set_gnutarget): Constify.
8362 * cp-name-parser.y (yyerror): Constify.
8363 * cp-valprint.c (cp_print_class_member): Constify.
8364 * cris-tdep.c (cris_register_name, crisv32_register_name):
8365 Constify.
8366 * d-exp.y (yyerror): Constify.
8367 (struct token::oper): Constify.
8368 * d-lang.h (d_yyerror): Constify.
8369 * dbxread.c (struct header_file_location::name): Constify.
8370 (add_old_header_file, add_new_header_file, last_function_name)
8371 (dbx_next_symbol_text, add_bincl_to_list)
8372 (find_corresponding_bincl_psymtab, set_namestring)
8373 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
8374 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
8375 * defs.h (command_line_input, print_address_symbolic)
8376 (deprecated_readline_begin_hook): Constify.
8377 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
8378 Constify.
8379 * event-top.c (handle_line_of_input): Constify and add cast.
8380 * exceptions.c (catch_errors): Constify.
8381 * exceptions.h (catch_errors): Constify.
8382 * expprint.c (print_subexp_standard, op_string, op_name)
8383 (op_name_standard, dump_raw_expression, dump_raw_expression):
8384 * expression.h (op_name, op_string, dump_raw_expression):
8385 Constify.
8386 * f-exp.y (yyerror): Constify.
8387 (struct token::oper): Constify.
8388 (struct f77_boolean_val::name): Constify.
8389 * f-lang.c (f_word_break_characters): Constify.
8390 * f-lang.h (f_yyerror): Constify.
8391 * fork-child.c (fork_inferior): Add cast.
8392 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8393 (new_variant): Constify.
8394 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8395 * gdbarch.c: Regenerate.
8396 * gdbcore.h (set_gnutarget): Constify.
8397 * go-exp.y (yyerror): Constify.
8398 (token::oper): Constify.
8399 * go-lang.h (go_yyerror): Constify.
8400 * go32-nat.c (go32_sysinfo): Constify.
8401 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8402 * guile/scm-cmd.c (cmdscm_function): Constify.
8403 * guile/scm-param.c (pascm_param_value): Constify.
8404 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8405 (h8300sx_register_name): Constify.
8406 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8407 Constify.
8408 * ia64-tdep.c (ia64_register_names): Constify.
8409 * infcmd.c (construct_inferior_arguments): Constify.
8410 (path_command, attach_post_wait): Constify.
8411 * language.c (show_range_command, show_case_command)
8412 (unk_lang_error): Constify.
8413 * language.h (language_defn::la_error)
8414 (language_defn::la_name_of_this): Constify.
8415 * linespec.c (decode_line_2): Constify.
8416 * linux-thread-db.c (thread_db_err_str): Constify.
8417 * lm32-tdep.c (lm32_register_name): Constify.
8418 * m2-exp.y (yyerror): Constify.
8419 * m2-lang.h (m2_yyerror): Constify.
8420 * m32r-tdep.c (m32r_register_names): Constify and make static.
8421 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8422 * m88k-tdep.c (m88k_register_name): Constify.
8423 * macroexp.c (appendmem): Constify.
8424 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8425 (upgrade_type, parse_external, parse_partial_symbols)
8426 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8427 (new_symbol): Constify.
8428 * memattr.c (mem_info_command): Constify.
8429 * mep-tdep.c (register_name_from_keyword): Constify.
8430 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8431 Constify.
8432 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8433 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8434 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8435 cast.
8436 (mi_execute_async_cli_command): Constify.
8437 * mips-tdep.c (mips_register_name): Constify.
8438 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8439 (am33_register_name, am33_2_register_name)
8440 * moxie-tdep.c (moxie_register_names): Constify.
8441 * nat/linux-osdata.c (osdata_type): Constify fields.
8442 * nto-tdep.c (nto_parse_redirection): Constify.
8443 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8444 (lookup_child_selector): Constify.
8445 (objc_methcall::name): Constify.
8446 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8447 (lookup_struct_typedef): Constify.
8448 * objfiles.c (pc_in_section): Constify.
8449 * objfiles.h (pc_in_section): Constify.
8450 * p-exp.y (struct token::oper): Constify.
8451 (yyerror): Constify.
8452 * p-lang.h (pascal_yyerror): Constify.
8453 * parser-defs.h (op_name_standard): Constify.
8454 (op_print::string): Constify.
8455 (exp_descriptor::op_name): Constify.
8456 * printcmd.c (print_address_symbolic): Constify.
8457 * psymtab.c (print_partial_symbols): Constify.
8458 * python/py-breakpoint.c (stop_func): Constify.
8459 (bppy_get_expression): Constify.
8460 * python/py-cmd.c (cmdpy_completer::name): Constify.
8461 (cmdpy_function): Constify.
8462 * python/py-event.c (evpy_add_attribute)
8463 (gdbpy_initialize_event_generic): Constify.
8464 * python/py-event.h (evpy_add_attribute)
8465 (gdbpy_initialize_event_generic): Constify.
8466 * python/py-evts.c (add_new_registry): Constify.
8467 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8468 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8469 * python/py-inferior.c (get_buffer): Add cast.
8470 * python/py-param.c (parm_constant::name): Constify.
8471 * python/py-unwind.c (fprint_frame_id): Constify.
8472 * python/python.c (gdbpy_parameter_value): Constify.
8473 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8474 * remote.c (memory_packet_config::name): Constify.
8475 (show_packet_config_cmd, remote_write_bytes)
8476 (remote_buffer_add_string):
8477 * reverse.c (exec_reverse_once): Constify.
8478 * rs6000-tdep.c (variant::name, variant::description): Constify.
8479 * rust-exp.y (rustyyerror): Constify.
8480 * rust-lang.c (rust_op_name): Constify.
8481 * rust-lang.h (rustyyerror): Constify.
8482 * serial.h (serial_ops::name): Constify.
8483 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8484 (sh_sh3e_register_name, sh_sh2e_register_name)
8485 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8486 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8487 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8488 (sh_sh4al_dsp_register_name): Constify.
8489 * sh64-tdep.c (sh64_register_name): Constify.
8490 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8491 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8492 * stabsread.c (patch_block_stabs, read_type_number)
8493 (ref_map::stabs, ref_add, process_reference)
8494 (symbol_reference_defined, define_symbol, define_symbol)
8495 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8496 (read_one_struct_field, read_struct_fields, read_baseclasses)
8497 (read_tilde_fields, read_struct_type, read_array_type)
8498 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8499 (read_huge_number, read_range_type, read_args, common_block_start)
8500 (find_name_end): Constify.
8501 * stabsread.h (common_block_start, define_symbol)
8502 (process_one_symbol, symbol_reference_defined, ref_add):
8503 * symfile.c (get_section_index, add_symbol_file_command):
8504 * symfile.h (get_section_index): Constify.
8505 * target-descriptions.c (tdesc_type::name): Constify.
8506 (tdesc_free_type): Add cast.
8507 * target.c (find_default_run_target):
8508 (add_deprecated_target_alias, find_default_run_target)
8509 (target_announce_detach): Constify.
8510 (do_option): Constify.
8511 * target.h (add_deprecated_target_alias): Constify.
8512 * thread.c (print_thread_info_1): Constify.
8513 * top.c (deprecated_readline_begin_hook, command_line_input):
8514 Constify.
8515 (init_main): Add casts.
8516 * top.h (handle_line_of_input): Constify.
8517 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8518 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8519 (tfind_command): Rename to ...
8520 (tfind_command_1): ... this and constify.
8521 (tfind_command): New function.
8522 (tfind_end_command, tfind_start_command): Adjust.
8523 (encode_source_string): Constify.
8524 * tracepoint.h (encode_source_string): Constify.
8525 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8526 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8527 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8528 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8529 * tui/tui-win.c (parse_scrolling_args): Constify.
8530 * tui/tui-windata.c (tui_erase_data_content): Constify.
8531 * tui/tui-windata.h (tui_erase_data_content): Constify.
8532 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8533 * tui/tui.c (tui_enable): Add cast.
8534 * utils.c (defaulted_query): Constify.
8535 (init_page_info): Add cast.
8536 (puts_debug, subset_compare): Constify.
8537 * utils.h (subset_compare): Constify.
8538 * varobj.c (varobj_format_string): Constify.
8539 * varobj.h (varobj_format_string): Constify.
8540 * vax-tdep.c (vax_register_name): Constify.
8541 * windows-nat.c (windows_detach): Constify.
8542 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8543 * xml-support.c (gdb_xml_end_element): Constify.
8544 * xml-tdesc.c (tdesc_start_reg): Constify.
8545 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8546 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8547 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8548
8549 2017-04-05 Pedro Alves <palves@redhat.com>
8550
8551 * proc-api.c (struct trans): Constify.
8552 (procfs_note): Constify.
8553 * proc-events.c (struct trans, syscall_table):
8554 * proc-flags.c (struct trans): Constify.
8555 * proc-utils.h (procfs_note): Constify.
8556 * proc-why.c (struct trans): Constify.
8557 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8558 (procfs_detach): Constify.
8559 * sol-thread.c (struct string_map): Constify.
8560 (td_err_string, td_state_string): Constify.
8561
8562 2017-04-05 Pedro Alves <palves@redhat.com>
8563
8564 * proc-api.c (procfs_filename): Don't initialize
8565 procfs_filename.
8566 (prepare_to_trace): Assume procfs_filename is non-NULL.
8567 (_initialize_proc_api): Give procfs_filename a default value here.
8568
8569 2017-04-05 Pedro Alves <palves@redhat.com>
8570
8571 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8572 'cond_string' parameter.
8573 (extract_exception_regexp): Constify 'string' parameter.
8574 (catch_exception_command_1): Constify.
8575 * breakpoint.c (init_catchpoint)
8576 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8577 parameter.
8578 (ep_parse_optional_if_clause, catch_fork_command_1)
8579 (catch_exec_command_1): Constify.
8580 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8581 parameter.
8582 (ep_parse_optional_if_clause): Constify.
8583 * cli/cli-utils.c (remove_trailing_whitespace)
8584 (check_for_argument): Constify.
8585 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8586 non-const overload.
8587 (check_for_argument): Likewise.
8588
8589 2017-04-05 Pedro Alves <palves@redhat.com>
8590
8591 * event-top.c (command_line_handler): Add cast to execute_command
8592 call.
8593 * record-btrace.c (cmd_record_btrace_bts_start)
8594 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8595 (cmd_record_btrace_start): Add cast to execute_command call.
8596 * record-full.c (record_full_goto_insn):
8597 * record.c (record_start, record_stop): Add cast to
8598 execute_command_to_string calls.
8599 (cmd_record_start): Add cast to execute_command calls.
8600
8601 2017-04-05 Pedro Alves <palves@redhat.com>
8602
8603 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8604 static inline function.
8605 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8606 array and use gdb_PyArg_ParseTupleAndKeywords.
8607 * python/py-cmd.c (cmdpy_init): Likewise.
8608 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8609 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8610 (infpy_search_memory): Likewise.
8611 * python/py-objfile.c (objfpy_add_separate_debug_file)
8612 (gdbpy_lookup_objfile): Likewise.
8613 * python/py-symbol.c (gdbpy_lookup_symbol)
8614 (gdbpy_lookup_global_symbol): Likewise.
8615 * python/py-type.c (gdbpy_lookup_type): Likewise.
8616 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8617 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8618 Likewise.
8619
8620 2017-04-05 Pedro Alves <palves@redhat.com>
8621
8622 * python/python-internal.h (gdb_PyGetSetDef): New type.
8623 * python/py-block.c (block_object_getset)
8624 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8625 * python/py-event.c (event_object_getset)
8626 (finish_breakpoint_object_getset): Likewise.
8627 * python/py-inferior.c (inferior_object_getset): Likewise.
8628 * python/py-infthread.c (thread_object_getset): Likewise.
8629 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8630 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8631 * python/py-objfile.c (objfile_getset): Likewise.
8632 * python/py-progspace.c (pspace_getset): Likewise.
8633 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8634 Likewise.
8635 * python/py-record.c (recpy_record_getset): Likewise.
8636 * python/py-symbol.c (symbol_object_getset): Likewise.
8637 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8638 Likewise.
8639 * python/py-type.c (type_object_getset, field_object_getset):
8640 Likewise.
8641 * python/py-value.c (value_object_getset): Likewise.
8642
8643 2017-04-05 Pedro Alves <palves@redhat.com>
8644
8645 * python/python-internal.h (gdb_PyObject_CallMethod)
8646 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8647 New functions.
8648 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8649 (PySys_GetObject, PySys_SetPath): New macros.
8650
8651 2017-04-05 Pedro Alves <palves@redhat.com>
8652
8653 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8654 info_osdata_command.
8655 * osdata.c (info_osdata_command): Rename to ...
8656 (info_osdata): ... this. Constify 'type' parameter, and remove
8657 the 'from_tty' parameter. Accept NULL TYPE.
8658 (info_osdata_command): New function.
8659 * osdata.h (info_osdata_command): Remove declaration.
8660 (info_osdata): New declaration.
8661
8662 2017-04-05 Pedro Alves <palves@redhat.com>
8663
8664 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8665 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8666 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8667 parameter.
8668 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8669 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8670 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8671 parameter.
8672 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8673 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
8674 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
8675 (mi_cmd_file_list_exec_source_files)
8676 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
8677 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8678 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
8679 parameter.
8680 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
8681 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
8682 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
8683 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
8684 (mi_cmd_stack_info_frame): Constify 'command' parameter.
8685 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
8686 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
8687 'command' parameter.
8688 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
8689 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
8690 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
8691 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
8692 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
8693 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
8694 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
8695 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
8696 (mi_cmd_var_set_update_range): Constify 'command' parameter.
8697 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
8698 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
8699 parameter.
8700 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
8701 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
8702 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
8703 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
8704 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
8705 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
8706 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
8707 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
8708 (mi_cmd_data_list_changed_registers)
8709 (mi_cmd_data_write_register_values)
8710 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
8711 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
8712 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
8713 (mi_cmd_list_features, mi_cmd_list_target_features)
8714 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
8715 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
8716 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
8717 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
8718 (mi_cmd_trace_frame_collected): Constify 'command'
8719 parameter.
8720 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
8721 'command' parameter.
8722
8723 2017-04-05 Pedro Alves <palves@redhat.com>
8724
8725 * ada-lang.c (ada_completer_word_break_characters): Now a const
8726 array.
8727 (ada_get_gdb_completer_word_break_characters): Constify.
8728 * completer.c (gdb_completer_command_word_break_characters)
8729 (gdb_completer_file_name_break_characters)
8730 (gdb_completer_quote_characters): Now const arrays.
8731 (get_gdb_completer_quote_characters): Constify.
8732 (set_rl_completer_word_break_characters): New function.
8733 (set_gdb_completion_word_break_characters)
8734 (complete_line_internal): Use it.
8735 * completer.h (get_gdb_completer_quote_characters): Constify.
8736 (set_rl_completer_word_break_characters): Declare.
8737 * f-lang.c (f_word_break_characters): Constify.
8738 * language.c (default_word_break_characters): Constify.
8739 * language.h (language_defn::la_word_break_characters): Constify.
8740 (default_word_break_characters): Constify.
8741 * top.c (init_main): Use set_rl_completer_word_break_characters.
8742
8743 2017-04-05 Pedro Alves <palves@redhat.com>
8744
8745 * aix-thread.c (aix_thread_pid_to_str)
8746 (aix_thread_extra_thread_info): Constify.
8747 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
8748 * bsd-uthread.c (bsd_uthread_extra_thread_info)
8749 (bsd_uthread_pid_to_str): Constify.
8750 * corelow.c (core_pid_to_str): Constify.
8751 * darwin-nat.c (darwin_pid_to_str): Constify.
8752 * fbsd-nat.c (fbsd_pid_to_str): Constify.
8753 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
8754 Constify.
8755 * gnu-nat.c (gnu_pid_to_str): Constify.
8756 * go32-nat.c (go32_pid_to_str): Constify.
8757 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
8758 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
8759 * inferior.c (inferior_pid_to_str): Constify.
8760 * linux-nat.c (linux_nat_pid_to_str): Constify.
8761 * linux-tdep.c (linux_core_pid_to_str): Constify.
8762 * linux-thread-db.c (thread_db_pid_to_str)
8763 (thread_db_extra_thread_info): Constify.
8764 * nto-tdep.c (nto_extra_thread_info): Constify.
8765 * nto-tdep.h (nto_extra_thread_info): Constify.
8766 * obsd-nat.c (obsd_pid_to_str): Constify.
8767 * procfs.c (procfs_pid_to_str): Constify.
8768 * ravenscar-thread.c (ravenscar_extra_thread_info)
8769 (ravenscar_pid_to_str): Constify.
8770 * remote-sim.c (gdbsim_pid_to_str): Constify.
8771 * remote.c (remote_threads_extra_info, remote_pid_to_str):
8772 Constify.
8773 * sol-thread.c (solaris_pid_to_str): Constify.
8774 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
8775 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
8776 * target.c (default_pid_to_str, target_pid_to_str)
8777 (normal_pid_to_str, default_pid_to_str): Constify.
8778 * target.h (target_ops::to_pid_to_str)
8779 (target_ops::to_extra_thread_info): Constify.
8780 (target_pid_to_str, normal_pid_to_str): Constify.
8781 * windows-nat.c (windows_pid_to_str): Constify.
8782 * gdbarch.sh (core_pid_to_str): Constify.
8783 * target-delegates.c: Regenerate.
8784 * gdbarch.h, gdbarch.c: Regenerate.
8785
8786 2017-04-05 Pedro Alves <palves@redhat.com>
8787
8788 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
8789 the memory of the temporary warning_pre_print override.
8790 * utils.c (warning_pre_print): Constify.
8791 * utils.h (warning_pre_print): Constify.
8792
8793 2017-04-05 Pedro Alves <palves@redhat.com>
8794
8795 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
8796 (shell_command): New function.
8797 (make_command): Use std::string.
8798 (init_cli_cmds): Register shell_command instead of shell_escape.
8799
8800 2017-04-05 Pedro Alves <palves@redhat.com>
8801
8802 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
8803 * tracepoint.c (default_collect): Don't initialize.
8804
8805 2017-04-05 Pedro Alves <palves@redhat.com>
8806
8807 * macroexp.c (macro_buffer::shared): Now a bool.
8808 (init_buffer): Update.
8809 (init_shared_buffer): Constify 'addr' parameter.
8810 (substitute_args, expand, macro_expand, macro_expand_next): Remove
8811 casts.
8812
8813 2017-04-05 Pedro Alves <palves@redhat.com>
8814
8815 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
8816 * disasm.c (set_disassembler_options): Constify local.
8817 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
8818
8819 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
8820
8821 PR gdb/21352
8822 * tracefile.c (tsave_command): Fix argument parsing for '-r'
8823 option.
8824
8825 2017-04-05 Yao Qi <yao.qi@linaro.org>
8826
8827 * frame.c (frame_unwind_register_unsigned): Call
8828 frame_unwind_register_value.
8829
8830 2017-04-05 Yao Qi <yao.qi@linaro.org>
8831
8832 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
8833 Use gdb_test_multiple, and don't match anchor.
8834
8835 2017-04-05 Pedro Alves <palves@redhat.com>
8836
8837 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
8838 (Write After Approval): Remove Simon Marchi.
8839
8840 2017-04-05 Pedro Alves <palves@redhat.com>
8841
8842 * common/gdb_optional.h (optional::optional): Make constexpr and
8843 initialize m_dummy.
8844
8845 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8846
8847 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8848 (amd64fbsd_jmp_buf_reg_offset): Remove.
8849 (amd64fbsd_supply_uthread): Remove function.
8850 (amd64fbsd_collect_uthread): Remove function.
8851 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
8852 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
8853 (x86_64-*-freebsd*): Remove bsd-uthread.o.
8854 (fbsd-nat.c): Update comment.
8855 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8856 (i386fbsd_jmp_buf_reg_offset): Remove.
8857 (i386fbsd_supply_uthread): Remove function.
8858 (i386fbsd_collect_uthread): Remove function.
8859 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
8860
8861 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8862
8863 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
8864 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
8865 * NEWS: Mention that support for FreeBSD/alpha was removed.
8866 * alpha-fbsd-tdep.c: Delete file.
8867 * config/alpha/fbsd.mh: Delete file.
8868 * configure.host: Delete alpha*-*-freebsd* and
8869 alpha*-*-kfreebsd*-gnu.
8870 * configure.tgt: Delete alpha*-*-freebsd* and
8871 alpha*-*-kfreebsd*-gnu.
8872
8873 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8874
8875 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
8876 amd64bsd_store_inferior_registers): Use ptid from regcache.
8877
8878 2017-04-04 Pedro Alves <palves@redhat.com>
8879
8880 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
8881 data fields, make them private and add "m_" prefixes.
8882 (lnp_state_machine::lnp_state_machine): New ctor.
8883 (record_line, check_line_address, handle_set_discriminator)
8884 (handle_set_address, handle_advance_pc, handle_special_opcode)
8885 (handle_advance_line, handle_set_file, handle_negate_stmt)
8886 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
8887 (end_sequence, advance_line): New methods.
8888 (m_gdbarch, m_record_lines_p): New fields.
8889 (lnp_reader_state): Delete.
8890 (dwarf_record_line): Rename to ...
8891 (lnp_state_machine::record_line): ... adjust.
8892 (init_lnp_state_machine): Delete.
8893 (lnp_state_machine::lnp_state_machine): New.
8894 (check_line_address): Rename to ...
8895 (lnp_state_machine::check_line_address): This.
8896 (dwarf_decode_lines_1): Remove reference to "reader_state".
8897 Adjust lnp_state_machine having a non-default ctor. Use bool.
8898 State machine internal state manipulation moved to
8899 lnp_state_machine methods.
8900
8901 2017-04-04 Pedro Alves <palves@redhat.com>
8902
8903 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8904 unittests/offset-type-selftests.c.
8905 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
8906 * common/offset-type.h: New file.
8907 * common/preprocessor.h: New file.
8908 * common/traits.h: New file.
8909 * common/valid-expr.h: New file.
8910 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
8911 sect_offset and cu_offset strong typedefs throughout.
8912 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
8913 typedefs throughout.
8914 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
8915 sect_offset and cu_offset strong typedefs throughout.
8916 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
8917 typedefs throughout.
8918 * gdbtypes.h: Include "common/offset-type.h".
8919 (cu_offset): Now an offset type (strong typedef) instead of a
8920 struct.
8921 (sect_offset): Likewise.
8922 (union call_site_parameter_u): Rename "param_offset" field to
8923 "param_cu_off".
8924 * unittests/offset-type-selftests.c: New file.
8925
8926 2017-04-04 Pedro Alves <palves@redhat.com>
8927
8928 * common/underlying.h: New file.
8929 * dwarf2read.c: Include "common/gdb_optional.h" and
8930 "common/underlying.h".
8931 (dir_index, file_name_index): New types.
8932 (file_entry): Use them.
8933 (file_entry::include): Use to_underlying.
8934 (line_header::add_file_name): Use dir_index.
8935 (read_formatted_entries): Use gdb::optional. Read form before
8936 writting to file_entry.
8937 (dwarf_decode_line_header): Use dir_index.
8938 (lnp_state_machine::current_file): Use to_underlying.
8939 (lnp_state_machine::file): Change type to file_name_index.
8940 (dwarf_record_line): Use to_underlying.
8941 (init_lnp_state_machine): Use file_name_index.
8942 (dwarf_decode_lines_1): Use dir_index and file_name_index.
8943
8944 2017-04-04 Pedro Alves <palves@redhat.com>
8945
8946 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
8947 operator bool, has_value and get methods.
8948
8949 2017-04-04 Pedro Alves <palves@redhat.com>
8950
8951 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
8952 fields.
8953 (line_header): Initialize all data fields. Change type of
8954 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
8955 Change type of include_dirs to std::vector<const char *>. Remove
8956 num_include_dirs, include_dirs_size. Change type of file_names to
8957 std::vector<file_entry>. Remove num_file_names, file_names_size.
8958 (line_header::line_header): New.
8959 (line_header::add_include_dir, line_header::add_file_name): New
8960 methods.
8961 (line_header::include_dir_at): Remove NULL check.
8962 (line_header::file_name_at): Add const overload.
8963 (line_header_up): New unique_ptr typedef.
8964 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
8965 std::vector. Remove free_line_header call.
8966 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
8967 free_line_header call.
8968 (free_cu_line_header): Delete.
8969 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
8970 (setup_type_unit_groups): Use line_header_up instead of cleanups.
8971 Adjust to use std::vector.
8972 (free_line_header): Delete.
8973 (free_line_header_voidp): Use delete.
8974 (add_include_dir): Replace with ...
8975 (line_header::add_include_dir): ... this method. Use std::vector.
8976 (add_file_name): Replace with ...
8977 (line_header::add_file_name): ... this method. Use std::vector.
8978 (add_include_dir_stub): Delete.
8979 (read_formatted_entries): Remove memset.
8980 (dwarf_decode_line_header): Return a line_header_up instead of a
8981 raw pointer. Remove cleanup handling. Pass lambdas to
8982 read_formatted_entries. Adjust to use line_header methods.
8983 (dwarf_decode_lines_1): Adjust to use line_header methods.
8984 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
8985 use std::vector.
8986
8987 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
8988
8989 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
8990 instead of struct ptid.
8991
8992 2017-05-04 Alan Hayward <alan.hayward@arm.com>
8993
8994 * frame.c (get_frame_register_bytes): Unwind using value.
8995 (put_frame_register_bytes): Likewise.
8996
8997 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
8998
8999 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
9000 aggregate-like.
9001
9002 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
9003
9004 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
9005
9006 2017-03-29 Yao Qi <yao.qi@linaro.org>
9007
9008 * gdbthread.h (struct thread_info): Declare constructor and
9009 destructor. Add some in-class member initializers.
9010 * thread.c (free_thread): Remove.
9011 (init_thread_list): Call delete instead of free_thread.
9012 (new_thread): Call thread_info constructor.
9013 (thread_info::thread_info): New function.
9014 (thread_info::~thread_info): New function.
9015 (delete_thread_1): Call delete instead of free_thread.
9016 (make_cleanup_restore_current_thread): Move tp and frame to
9017 inner block.
9018
9019 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9020
9021 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
9022 (arc_skip_prologue): Likewise.
9023 (arc_make_frame_cache): Likewise.
9024 (arc_pv_get_operand): New function.
9025 (arc_is_in_prologue): Likewise.
9026 (arc_analyze_prologue): Likewise.
9027 (arc_print_frame_cache): Likewise.
9028 (MAX_PROLOGUE_LENGTH): New constant.
9029
9030 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9031
9032 * configure.tgt: Add arc-insn.o.
9033 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
9034 (dump_arc_instruction_command): New function.
9035 (arc_fprintf_disasm): Likewise.
9036 (arc_disassemble_info): Likewise.
9037 (arc_insn_get_operand_value): Likewise.
9038 (arc_insn_get_operand_value_signed): Likewise.
9039 (arc_insn_get_memory_base_reg): Likewise.
9040 (arc_insn_get_memory_offset): Likewise.
9041 (arc_insn_get_branch_target): Likewise.
9042 (arc_insn_dump): Likewise.
9043 (arc_insn_get_linear_next_pc): Likewise.
9044 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
9045 (arc_disassemble_info): Likewise.
9046 (arc_insn_get_branch_target): Likewise.
9047 (arc_insn_get_linear_next_pc): Likewise.
9048 * NEWS: Mention new "maint print arc arc-instruction".
9049
9050 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9051
9052 * arc-tdep (maintenance_print_arc_list): New variable.
9053 (maintenance_print_arc_command): New function.
9054
9055 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9056
9057 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
9058 Add "limm" and "reserved".
9059 (arc_cannot_fetch_register, arc_cannot_store_register): Add
9060 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
9061 * arc-tdep.h (arc_regnum): Likewise.
9062
9063 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9064
9065 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9066 for THREADPTR register.
9067 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
9068 register.
9069 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
9070 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
9071 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
9072
9073 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9074
9075 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
9076 registers above gdbarch_num_regs (gdbarch) as privileged in
9077 call0 ABI.
9078
9079 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9080
9081 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9082 for a single specified register or for all registers in
9083 a0_base..a0_base + C0_NREGS range.
9084 (supply_gregset_reg): Call regcache_raw_supply for a single
9085 specified register or for all registers in a0_base..a0_base +
9086 C0_NREGS range.
9087
9088 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9089
9090 * arch/xtensa.h (C0_NREGS): Add definition.
9091 * xtensa-tdep.c (C0_NREGS): Remove definition.
9092
9093 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9094
9095 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
9096 Drop xtensa_default_isa initialization.
9097 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
9098
9099 2017-03-27 Pedro Alves <palves@redhat.com>
9100
9101 * dwarf2read.c (file_entry) <dir_index>: Add comment.
9102 (file_entry::include_dir): New method.
9103 (line_header::include_dir_at, line_header::file_name_at): New
9104 methods.
9105 (setup_type_unit_groups, setup_type_unit_groups)
9106 (psymtab_include_file_name): Simplify using the new methods.
9107 (lnp_state_machine) <the_line_header>: New field.
9108 <file>: Add comment.
9109 (lnp_state_machine::current_file): New method.
9110 (dwarf_record_line): Simplify using the new methods.
9111 (init_lnp_state_machine): Initialize the "the_line_header" field.
9112 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
9113 Simplify using the new methods.
9114
9115 2017-03-27 Pedro Alves <palves@redhat.com>
9116
9117 * cp-name-parser.y (make_empty): Delete.
9118 (demangler_special, nested_name, ptr_operator, array_indicator)
9119 (direct_declarator, declarator_1): Use fill_comp instead of
9120 make_empty.
9121
9122 2017-03-27 Pedro Alves <palves@redhat.com>
9123
9124 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
9125 to ATTRIBUTE_PRINTF.
9126 * solib-target.c (library_list_start_list): Print "string" not
9127 "version".
9128 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
9129 gdb_xml_error call.
9130
9131 2017-03-27 Pedro Alves <palves@redhat.com>
9132
9133 * dwarf2read.c (struct file_and_directory): New.
9134 (dwarf2_get_dwz_file): Adjust to use std::string.
9135 (dw2_get_file_names_reader): Adjust to use file_and_directory.
9136 (find_file_and_directory): Adjust to return a file_and_directory
9137 object.
9138 (read_file_scope): Adjust to use file_and_directory. Remove
9139 make_cleanup/do_cleanups calls.
9140 (open_and_init_dwp_file): Adjust to use std::string. Remove
9141 make_cleanup/do_cleanups calls.
9142 * python/python.c (do_start_initialization): Adjust to ldirname
9143 returning a std::string.
9144 * utils.c (ldirname): Now returns a std::string.
9145 * utils.h (ldirname): Change return type to std::string.
9146 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
9147 returning a std::string.
9148 * xml-tdesc.c (file_read_description_xml): Likewise.
9149
9150 2017-03-24 Alan Hayward <alan.hayward@arm.com>
9151
9152 * regcache.c (regcache_debug_print_register): New function.
9153 * regcache.h (regcache_debug_print_register): New declaration.
9154 * target.c (debug_print_register): Remove.
9155 (target_fetch_registers): Call regcache_debug_print_register.
9156 (target_store_registers): Likewise.
9157
9158 2017-03-24 Pádraig Brady <pbrady@fb.com>
9159
9160 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
9161 reference beyond the 'lh->include_dirs' array before accessing to
9162 it.
9163 (psymtab_include_file_name): Likewise.
9164 (dwarf_decode_lines_1): Likewise.
9165 (dwarf_decode_lines): Likewise.
9166 (file_file_name): Likewise.
9167
9168 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
9169
9170 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
9171 inferior_ptid.
9172 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9173 ps_lsetfpregs): Likewise.
9174 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
9175 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9176 ps_lsetfpregs): Likewise.
9177 * target.c (target_fetch_registers, target_store_registers):
9178 Remove asserts.
9179
9180 2017-03-23 Alan Hayward <alan.hayward@arm.com>
9181
9182 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
9183
9184 2017-03-23 Yao Qi <yao.qi@linaro.org>
9185
9186 * aarch64-tdep.c (aarch64_process_record_test): Declare.
9187 (_initialize_aarch64_tdep): Register it.
9188 (aarch64_record_load_store): Handle PRFM instruction.
9189 (aarch64_process_record_test): New function.
9190
9191 2017-03-23 Yao Qi <yao.qi@linaro.org>
9192
9193 * aarch64-tdep.c (aarch64_record_load_store): Fix code
9194 indentation.
9195
9196 2017-03-23 Yao Qi <yao.qi@linaro.org>
9197
9198 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
9199
9200 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9201
9202 python/python.c (do_start_initialization): Fix memory leak.
9203
9204 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9205
9206 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
9207 using get_ptrace_pid.
9208 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
9209 inferior_ptid.
9210 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
9211 inferior_ptid instead of pid.
9212
9213 2017-03-22 Yao Qi <yao.qi@linaro.org>
9214
9215 * aarch64-tdep.c: Wrap locally used classes in anonymous
9216 namespace.
9217 * arm-tdep.c: Likewise.
9218 * linespec.c: Likewise.
9219 * ui-out.c: Likewise.
9220
9221 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
9222
9223 PR gdb/19637
9224 * python/lib/gdb/printer/bound_registers.py: Import sys.
9225
9226 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9227
9228 * windows-nat.c (do_windows_fetch_inferior_registers): Add
9229 windows_thread_info parameter and use it instead of
9230 current_thread.
9231 (windows_fetch_inferior_registers): Don't set current_thread,
9232 pass the thread to do_windows_fetch_inferior_registers. Use
9233 ptid from regcache instead of inferior_ptid.
9234 (do_windows_store_inferior_registers): Add windows_thread_info
9235 parameter and use it instead of current_thread.
9236 (windows_store_inferior_registers): Don't set current_thread,
9237 pass the thread to do_windows_store_inferior_registers. Use
9238 ptid from regcache instead of inferior_ptid.
9239
9240 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9241
9242 * ser-mingw.c (ser_windows_raw): Remove reference to
9243 struct serial::current_timeout.
9244
9245 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
9246
9247 PR tdep/20928
9248 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
9249 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
9250 (sparc64_fsr_type): Fix %fsr decoding.
9251
9252 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
9253
9254 * python/py-record-btrace.c (btpy_insn_data): Change return type
9255 for Python 2.
9256
9257 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9258
9259 * spu-linux-nat.c (spu_fetch_inferior_registers,
9260 spu_store_inferior_registers): Use ptid from regcache, set and
9261 restore inferior_ptid.
9262 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
9263 Likewise.
9264
9265 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9266
9267 * i386-linux-nat.c (fetch_register, store_register,
9268 i386_linux_fetch_inferior_registers,
9269 i386_linux_store_inferior_registers): Use ptid from regcache.
9270 * ia64-linux-nat.c (ia64_linux_fetch_register,
9271 ia64_linux_store_register): Likewise.
9272 * inf-ptrace.c (inf_ptrace_fetch_register,
9273 inf_ptrace_store_register): Likewise.
9274 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
9275 m32r_linux_store_inferior_registers): Likewise.
9276 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
9277 m68kbsd_store_inferior_registers): Likewise.
9278 * m68k-linux-nat.c (fetch_register, store_register,
9279 m68k_linux_fetch_inferior_registers,
9280 m68k_linux_store_inferior_registers): Likewise.
9281 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
9282 m88kbsd_store_inferior_registers): Likewise.
9283 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
9284 mips_fbsd_store_inferior_registers): Likewise.
9285 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
9286 mips64_linux_regsets_store_registers): Likewise.
9287 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
9288 mipsnbsd_store_inferior_registers): Likewise.
9289 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
9290 mips64obsd_store_inferior_registers): Likewise.
9291 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
9292 Likewise.
9293 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
9294 ppcfbsd_store_inferior_registers): Likewise.
9295 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
9296 ppc_linux_store_inferior_registers): Likewise.
9297 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
9298 ppcnbsd_store_inferior_registers): Likewise.
9299 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
9300 ppcobsd_store_registers): Likewise.
9301 * procfs.c (procfs_fetch_registers, procfs_store_registers):
9302 Likewise.
9303 * ravenscar-thread.c (ravenscar_fetch_registers,
9304 ravenscar_store_registers, ravenscar_prepare_to_store):
9305 Likewise.
9306 * record-btrace.c (record_btrace_fetch_registers,
9307 record_btrace_store_registers, record_btrace_prepare_to_store):
9308 Likewise.
9309 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
9310 Lookup inferior using ptid from regcache, instead of
9311 current_inferior.
9312 * remote.c (remote_fetch_registers, remote_store_registers): Use
9313 ptid from regcache.
9314 * rs6000-nat.c (fetch_register, store_register): Likewise.
9315 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
9316 s390_linux_store_inferior_registers): Likewise.
9317 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
9318 shnbsd_store_inferior_registers): Likewise.
9319 * sol-thread.c (sol_thread_fetch_registers,
9320 sol_thread_store_registers): Likewise.
9321 * sparc-nat.c (sparc_fetch_inferior_registers,
9322 sparc_store_inferior_registers): Likewise.
9323 * tilegx-linux-nat.c (fetch_inferior_registers,
9324 store_inferior_registers): Likewise.
9325 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
9326 vaxbsd_store_inferior_registers): Likewise.
9327 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
9328 store_xtregs): Likewise.
9329
9330 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9331
9332 PR gdb/14441
9333 * NEWS: Mention support for rvalue references in GDB and python.
9334 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
9335 supports both lvalue and rvalue references.
9336
9337 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9338
9339 PR gdb/14441
9340 * gdbtypes.c (rank_one_type): Implement overloading
9341 resolution rules regarding rvalue references.
9342
9343 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9344
9345 PR gdb/14441
9346 * aarch64-tdep.c (aarch64_type_align)
9347 (aarch64_extract_return_value, aarch64_store_return_value): Change
9348 lvalue reference type checks to general reference type checks.
9349 * amd64-tdep.c (amd64_classify): Likewise.
9350 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
9351 Likewise.
9352 * arm-tdep.c (arm_type_align, arm_extract_return_value)
9353 (arm_store_return_value): Likewise.
9354 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
9355 * c-typeprint.c (c_print_type): Likewise.
9356 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
9357 (cplus_number_of_children, cplus_describe_child): Likewise.
9358 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
9359 * completer.c (expression_completer): Likewise.
9360 * cp-support.c (make_symbol_overload_list_adl_namespace):
9361 Likewise.
9362 * darwin-nat-info.c (info_mach_region_command): Likewise.
9363 * dwarf2loc.c (entry_data_value_coerce_ref)
9364 (value_of_dwarf_reg_entry): Likewise.
9365 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
9366 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
9367 Likewise.
9368 * findvar.c (extract_typed_address, store_typed_address):
9369 Likewise.
9370 * gdbtypes.c (rank_one_type): Likewise.
9371 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
9372 * infcall.c (value_arg_coerce): Likewise.
9373 * language.c (pointer_type): Likewise.
9374 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
9375 Likewise.
9376 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
9377 * mn10300-tdep.c (mn10300_type_align): Likewise.
9378 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
9379 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
9380 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
9381 Likewise.
9382 * printcmd.c (print_formatted, x_command): Likewise.
9383 * python/py-type.c (typy_get_composite, typy_template_argument):
9384 Likewise.
9385 * python/py-value.c (valpy_referenced_value)
9386 (valpy_get_dynamic_type, value_has_field): Likewise.
9387 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
9388 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
9389 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
9390 * spu-tdep.c (spu_scalar_value_p): Likewise.
9391 * symtab.c (lookup_symbol_aux): Likewise.
9392 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9393 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9394 Likewise.
9395 * valops.c (value_cast_pointers, value_cast)
9396 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9397 (value_struct_elt, value_struct_elt_bitpos)
9398 (value_find_oload_method_list, find_overload_match)
9399 (value_rtti_indirect_type): Likewise.
9400 * valprint.c (val_print_scalar_type_p, generic_val_print):
9401 Likewise.
9402 * value.c (value_actual_type, value_as_address, unpack_long)
9403 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9404 (coerce_ref): Likewise.
9405 * varobj.c (varobj_get_value_type): Likewise.
9406
9407 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9408
9409 PR gdb/14441
9410 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9411 table of constants.
9412 * python/lib/gdb/command/explore.py: Support exploring values
9413 of rvalue reference types.
9414 * python/lib/gdb/types.py: Implement get_basic_type() for
9415 rvalue reference types.
9416 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9417 constant.
9418 * python/py-value.c (valpy_getitem): Add an rvalue reference
9419 check.
9420 (valpy_reference_value): Add new parameter "refcode".
9421 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9422 New wrappers for valpy_reference_value().
9423 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9424 (gdbpy_invoke_xmethod): Likewise.
9425
9426 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9427
9428 PR gdb/14441
9429 * dwarf2read.c (process_die, read_type_die_1): Handle the
9430 DW_TAG_rvalue_reference_type DIE.
9431 (read_tag_reference_type): Add new parameter "refcode".
9432
9433 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9434
9435 PR gdb/14441
9436 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9437 (c_type_print_modifier, c_type_print_varspec_suffix)
9438 (c_type_print_base): Support printing rvalue reference types.
9439 * c-valprint.c (c_val_print, c_value_print): Support printing
9440 rvalue reference values.
9441
9442 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9443
9444 PR gdb/14441
9445 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9446 typename.
9447 * cp-support.c (replace_typedefs): Handle
9448 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9449 * python/py-type.c (typy_lookup_type): Likewise.
9450
9451 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9452
9453 PR gdb/14441
9454 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9455 * parse.c (insert_type): Change assert statement.
9456 (follow_types): Handle rvalue reference types.
9457 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9458 constant.
9459
9460 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9461
9462 PR gdb/14441
9463 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9464 value_ref() interface.
9465 * c-valprint.c (c_value_print): Likewise.
9466 * infcall.c (value_arg_coerce): Likewise.
9467 * python/py-value.c (valpy_reference_value): Likewise.
9468 * valops.c (value_cast, value_reinterpret_cast)
9469 (value_dynamic_cast, typecmp): Likewise.
9470 (value_ref): Parameterize by kind of return value reference type.
9471 * value.h (value_ref): Add new parameter "refcode".
9472
9473 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9474
9475 PR gdb/14441
9476 * dwarf2read.c (read_tag_reference_type): Use
9477 lookup_lvalue_reference_type() instead of lookup_reference_type().
9478 * eval.c (evaluate_subexp_standard): Likewise.
9479 * f-exp.y: Likewise.
9480 * gdbtypes.c (make_reference_type, lookup_reference_type):
9481 Generalize with rvalue reference types.
9482 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9483 convenience wrappers for lookup_reference_type().
9484 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9485 reference kind parameter.
9486 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9487 wrappers for lookup_reference_type().
9488 * guile/scm-type.c (gdbscm_type_reference): Use
9489 lookup_lvalue_reference_type() instead of lookup_reference_type().
9490 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9491 * parse.c (follow_types): Likewise.
9492 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9493 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9494 Likewise.
9495 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9496 (gdbpy_invoke_xmethod): Likewise.
9497 * stabsread.c: Provide extra argument to make_reference_type()
9498 call.
9499 * valops.c (value_ref, value_rtti_indirect_type): Use
9500 lookup_lvalue_reference_type() instead of lookup_reference_type().
9501
9502 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9503
9504 PR gdb/14441
9505 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9506 (TYPE_IS_REFERENCE): New macro.
9507 (struct type): Add rvalue_reference_type field.
9508 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9509
9510 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9511
9512 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9513 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9514 New function definition.
9515 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9516 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9517 New function declaration.
9518 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9519 * mi/mi-interp.h: New file.
9520 * solib.c (info_sharedlibrary_command): Replace for loop with
9521 ALL_SO_LIBS macro
9522 * solib.h (update_solib_list): New function declaration.
9523 (so_list_head): Move macro.
9524 * solist.h (ALL_SO_LIBS): New macro.
9525
9526 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9527
9528 * infcmd.c (post_create_inferior): Remove unused argument in
9529 call to solib_add.
9530 * remote.c (remote_start_remote): Likewise.
9531 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9532 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9533 (enable_break): Likewise.
9534 * solib.c (update_solib_list): Remove unused target argument
9535 and its documentation.
9536 (solib_add): Remove unused target argument. Remove unused
9537 argument in call to update_solib_list.
9538 (info_sharedlibrary_command): Remove unused argument in call
9539 to update_solib_list.
9540 (sharedlibrary_command): Remove unused argument in call to
9541 solib_add.
9542 (handle_solib_event): Likewise.
9543 (reload_shared_libraries): Likewise.
9544 * solib.h (solib_add): Remove unused target argument.
9545
9546 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9547
9548 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9549 (s390_displaced_step_fixup): Cover relative branches with the
9550 default fixup handling. This fixes lack of support for some
9551 relative branch instructions.
9552
9553 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9554
9555 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9556 ptid from regcache.
9557
9558 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9559
9560 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9561 i386_darwin_store_inferior_registers): Use ptid from regcache.
9562
9563 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9564
9565 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9566 i386bsd_store_inferior_registers): Use ptid from regcache.
9567
9568 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9569
9570 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9571 hppaobsd_store_registers): Use ptid from regcache.
9572
9573 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9574
9575 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9576 hppanbsd_store_registers): Use ptid from regcache.
9577
9578 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9579
9580 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9581 from regcache. Use get_ptrace_pid.
9582
9583 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9584
9585 * corelow.c (get_core_register_section): Use ptid from regcache,
9586 update doc.
9587
9588 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9589
9590 * bsd-uthread.c (bsd_uthread_fetch_registers,
9591 bsd_uthread_store_registers): Use ptid from regcache, set and
9592 restore inferior_ptid.
9593
9594 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9595
9596 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9597 fetch_fp_regs, store_register, store_regs, store_fp_register,
9598 store_fp_regs): Use ptid from regcache.
9599
9600 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9601
9602 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9603 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9604 store_vfp_regs): Use ptid from regcache.
9605
9606 2017-03-17 Pedro Alves <palves@redhat.com>
9607
9608 PR remote/21188
9609 * ser-base.c (ser_base_wait_for): Add comment.
9610 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9611 version.
9612 * ser-unix.c (hardwire_raw): Remove reference to
9613 scb->current_timeout.
9614 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9615 (hardwire_ops): Install ser_base_readchar instead of
9616 hardwire_readchar.
9617 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9618 Remove fields.
9619
9620 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
9621
9622 PR gdb/19637
9623 * python/lib/gdb/printer/bound_registers.py: Add support for
9624 Python 3.
9625
9626 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9627
9628 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9629 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9630 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9631 byte_offset to subobj_byte_offset. Fix the handling of
9632 DWARF_VALUE_STACK on big-endian targets when coming via an
9633 implicit pointer.
9634 (dwarf2_evaluate_loc_desc): Adjust call to
9635 dwarf2_evaluate_loc_desc_full.
9636 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9637 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9638
9639 2017-03-16 Yao Qi <yao.qi@linaro.org>
9640
9641 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9642 and REVSH instructions.
9643
9644 2017-03-16 Yao Qi <yao.qi@linaro.org>
9645
9646 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9647 (arm_record_test): Declare.
9648 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9649 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9650 align with the manual.
9651 (thumb_record_misc): Adjust the code order to align with the
9652 manual.
9653 (thumb2_record_decode_insn_handler): Fix instruction matching.
9654 (instruction_reader_thumb): New class.
9655 (arm_record_test): New function.
9656
9657 2017-03-16 Yao Qi <yao.qi@linaro.org>
9658
9659 * arm-tdep.c (abstract_memory_reader): New class.
9660 (instruction_reader): New class.
9661 (extract_arm_insn): Add argument 'reader'. Callers updated.
9662 (decode_insn): Likewise.
9663
9664 2017-03-16 Doug Evans <dje@google.com>
9665
9666 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9667 member. Change type of TYPE member to SCM. All uses updated.
9668 (lsscm_make_lazy_string_smob): Add assert.
9669 (lsscm_make_lazy_string): Flag bad length values.
9670 (lsscm_elt_type): New function.
9671 (gdbscm_lazy_string_to_value): Rewrite to use
9672 lsscm_safe_lazy_string_to_value.
9673 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
9674 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
9675 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
9676 in incoming type.
9677 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9678 * guile/scm-type.c (tyscm_scm_to_type): New function.
9679
9680 2017-03-15 Doug Evans <dje@google.com>
9681
9682 PR python/17728, python/18439, python/18779
9683 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
9684 member. Change type of TYPE member to PyObject *. All uses updated.
9685 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
9686 (gdbpy_create_lazy_string_object): Flag bad length values.
9687 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
9688 Handle typedefs in incoming type.
9689 (stpy_lazy_string_elt_type): New function.
9690 (gdbpy_extract_lazy_string): Call it.
9691 * python/py-value.c (valpy_lazy_string): Flag bad length values.
9692 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
9693 typedefs in incoming type.
9694
9695 2017-03-16 Doug Evans <dje@google.com>
9696
9697 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9698 * guile/scm-type.c (tyscm_scm_to_type): New function.
9699
9700 2017-03-16 Jiong Wang <jiong.wang@arm.com>
9701
9702 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
9703 "ULONGEST" for "skip".
9704
9705 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9706
9707 PR gdb/21220
9708 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
9709 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
9710 (inf_ptrace_peek_poke): ...here. New function. Now also loop
9711 over ptrace peek/poke until end of buffer or error.
9712
9713 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
9714
9715 * parse.c (length_of_subexp): Make static.
9716 * parser-defs.h (length_of_subexp): Remove.
9717
9718 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9719
9720 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
9721 as well.
9722
9723 2017-03-14 Pedro Alves <palves@redhat.com>
9724
9725 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
9726 (main): Use std::unique_ptr. Remove calls to
9727 cp_demangled_name_parse_free.
9728
9729 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9730
9731 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
9732 alphabsd_store_inferior_registers): Use regcache->ptid instead
9733 of inferior_ptid.
9734
9735 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9736
9737 * aix-thread.c (aix_thread_fetch_registers,
9738 aix_thread_store_registers): Use regcache->ptid instead of
9739 inferior_ptid.
9740
9741 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9742
9743 * aarch64-linux-nat.c (fetch_gregs_from_thread,
9744 store_gregs_to_thread, fetch_fpregs_from_thread,
9745 store_fpregs_to_thread): Use regcache->ptid instead of
9746 inferior_ptid.
9747
9748 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9749
9750 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
9751 amd64_linux_fetch_inferior_registers): Use regcache->ptid
9752 instead of inferior_ptid.
9753
9754 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9755
9756 * target.c (target_fetch_registers, target_store_registers): Add
9757 assert.
9758
9759 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9760
9761 * regcache.h (regcache_get_ptid): New function.
9762 * regcache.c (regcache_get_ptid): New function.
9763
9764 2017-03-13 Mark Wielaard <mark@klomp.org>
9765
9766 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
9767
9768 2017-03-10 Keith Seitz <keiths@redhat.com>
9769
9770 PR c++/8218
9771 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
9772
9773 2017-03-08 Pedro Alves <palves@redhat.com>
9774
9775 PR gdb/18360
9776 * infrun.c (start_step_over, do_target_resume, resume)
9777 (restart_threads): Assert we're not resuming a thread that is
9778 meant to be stopped.
9779 (infrun_thread_stop_requested_callback): Delete.
9780 (infrun_thread_stop_requested): If the thread is internally
9781 stopped, queue a pending stop event and clear the thread's
9782 inline-frame state.
9783 (handle_stop_requested): New function.
9784 (handle_syscall_event, handle_inferior_event_1): Use
9785 handle_stop_requested.
9786 (handle_stop_requested): New function.
9787 (handle_signal_stop): Set the thread's stop_signal here instead of
9788 at caller.
9789 (finish_step_over): Clear step over info unconditionally.
9790 (handle_signal_stop): If the user had interrupted the event
9791 thread, consider the stop a random signal.
9792 (handle_signal_stop) <signal arrived while stepping over
9793 breakpoint>: Don't restart threads here.
9794 (stop_waiting): Don't clear step-over info here.
9795
9796 2017-03-08 Pedro Alves <palves@redhat.com>
9797
9798 PR 21206
9799 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
9800 goes to argument 2, not 1.
9801
9802 2017-03-08 Pedro Alves <palves@redhat.com>
9803
9804 PR cli/21218
9805 * top.c (gdb_readline_wrapper): Avoid passing NULL to
9806 display_gdb_prompt.
9807 (command_line_input): Add comment.
9808
9809 2017-03-08 Pedro Alves <palves@redhat.com>
9810
9811 PR tui/21216
9812 * tui/tui-file.c (tui_file::write): New.
9813 * tui/tui-file.h (tui_file): Override "write".
9814 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
9815 factored out from ...
9816 (tui_puts): ... here.
9817 (tui_putc): Use them.
9818 (tui_write): New function.
9819 * tui/tui-io.h (tui_write): Declare.
9820
9821 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
9822
9823 * Makefile.in (SFILES): Replace "environ.c" with
9824 "common/environ.c".
9825 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
9826 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
9827 to...
9828 * common/environ.c: ... here.
9829 * environ.h: Moved to...
9830 * common/environ.h: ... here.
9831
9832 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9833
9834 * gdbarch.sh (pstring_ptr): New static function.
9835 (gdbarch_disassembler_options): Use it.
9836 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
9837 not valid_disassembler_option->name.
9838 * gdbarch.c: Regenerate.
9839
9840 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9841
9842 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
9843
9844 2017-03-07 Pedro Alves <palves@redhat.com>
9845
9846 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
9847
9848 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
9849
9850 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
9851 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
9852 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
9853 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
9854
9855 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
9856
9857 * xtensa-linux-nat.c (fetch_gregs): Remove const.
9858
9859 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
9860
9861 * remote.c (remote_add_target_side_commands): Use range-based
9862 for loop.
9863
9864 2017-03-03 Yao Qi <yao.qi@linaro.org>
9865
9866 PR gdb/21165
9867 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
9868 value is lazy.
9869 * valprint.c (common_val_print): Likewise.
9870
9871 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
9872
9873 * NEWS: Mention new set/show disassembler-options commands.
9874 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
9875 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
9876 (prospective_options): New static variable.
9877 (gdb_disassembler::gdb_disassembler): Initialize
9878 m_di.disassembler_options.
9879 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
9880 (get_disassembler_options): New function.
9881 (set_disassembler_options): Likewise.
9882 (set_disassembler_options_sfunc): Likewise.
9883 (show_disassembler_options_sfunc): Likewise.
9884 (disassembler_options_completer): Likewise.
9885 (_initialize_disasm): Likewise.
9886 * disasm.h (get_disassembler_options): New prototype.
9887 (set_disassembler_options): Likewise.
9888 * gdbarch.sh (gdbarch_disassembler_options): New variable.
9889 (gdbarch_verify_disassembler_options): Likewise.
9890 * gdbarch.c: Regenerate.
9891 * gdbarch.h: Likewise.
9892 * arm-tdep.c (num_disassembly_options): Delete.
9893 (set_disassembly_style): Likewise.
9894 (arm_disassembler_options): New static variable.
9895 (set_disassembly_style_sfunc): Convert short style name into long
9896 option name. Call set_disassembler_options.
9897 (show_disassembly_style_sfunc): New function.
9898 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
9899 set_gdbarch_verify_disassembler_options.
9900 (_initialize_arm_tdep): Delete regnames variable and update callers.
9901 (arm_disassembler_options): Initialize.
9902 (disasm_options): New variable.
9903 (num_disassembly_options): Rename from this...
9904 (num_disassembly_styles): ...to this. Compute by scanning through
9905 disasm_options.
9906 (valid_disassembly_styles): Initialize using disasm_options.
9907 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
9908 set_arm_regname_option.
9909 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
9910 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
9911 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
9912 set_gdbarch_verify_disassembler_options.
9913 * s390-tdep.c (s390_disassembler_options): New static variable.
9914 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
9915 set_gdbarch_verify_disassembler_options.
9916
9917 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9918
9919 * remote.c (remote_add_target_side_condition): Remove "struct"
9920 keyword from range-based for loop.
9921
9922 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9923
9924 * remote.c (remote_add_target_side_condition): Use range-based
9925 for loop. Update comment.
9926
9927 2017-02-27 Yao Qi <yao.qi@linaro.org>
9928
9929 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
9930
9931 2017-02-26 Alan Hayward <alan.hayward@arm.com>
9932
9933 * regcache.c (regcache_raw_update): New function.
9934 (regcache_raw_read): Move code to regcache_raw_update.
9935 * regcache.h (regcache_raw_update): New declaration.
9936 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
9937
9938 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
9939
9940 * dwarf2read.c (create_debug_type_hash_table): Initialize
9941 header.signature and header.type_offset_in_tu.
9942
9943 2017-02-24 Pedro Alves <palves@redhat.com>
9944
9945 * symtab.c (make_file_symbol_completion_list_1): Use
9946 add_symtab_completions.
9947
9948 2017-02-24 Alan Hayward <alan.hayward@arm.com>
9949
9950 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
9951
9952 2017-02-24 Alan Hayward <alan.hayward@arm.com>
9953
9954 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
9955 I386_MAX_REGISTER_SIZE.
9956 (i386_pseudo_register_write): Likewise.
9957 (i386_process_record): Likewise.
9958 * i387-tdep.c (i387_supply_xsave): Likewise.
9959 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
9960 (store_register): Likewise.
9961
9962 2017-02-23 Pedro Alves <palves@redhat.com>
9963
9964 * ada-lang.c: Include "common/function-view.h".
9965 (ada_iterate_over_symbols): Adjust to use function_view as
9966 callback type.
9967 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
9968 (ada_make_symbol_completion_list): Use a lambda.
9969 (ada_exc_search_name_matches): Delete.
9970 (name_matches_regex): New.
9971 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
9972 * compile/compile-c-support.c: Include "common/function-view.h".
9973 (print_one_macro): Change prototype to accept a ui_file pointer.
9974 (write_macro_definitions): Use a lambda.
9975 * dwarf2read.c: Include "common/function-view.h".
9976 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
9977 (dw2_expand_symtabs_matching): Adjust to use function_view as
9978 callback type.
9979 * language.h: Include "common/function-view.h".
9980 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
9981 function_view as callback type.
9982 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
9983 * linespec.c: Include "common/function-view.h".
9984 (collect_info::add_symbol): New method.
9985 (struct symbol_and_data_callback, iterate_inline_only, struct
9986 symbol_matcher_data, iterate_name_matcher): Delete.
9987 (iterate_over_all_matching_symtabs): Adjust to use function_view
9988 as callback type and lambdas.
9989 (iterate_over_file_blocks): Adjust to use function_view as
9990 callback type.
9991 (decode_compound_collector): Now a class with private fields.
9992 (decode_compound_collector::release_symbols): New method.
9993 (collect_one_symbol): Rename to...
9994 (decode_compound_collector::operator()): ... this and adjust.
9995 (lookup_prefix_sym): decode_compound_collector construction bits
9996 move to decode_compound_collector ctor. Pass the
9997 decode_compound_collector object directly as callback. Remove
9998 cleanups and use decode_compound_collector::release_symbols
9999 instead.
10000 (symtab_collector): Now a class with private fields.
10001 (symtab_collector::release_symtabs): New method.
10002 (add_symtabs_to_list): Rename to...
10003 (symtab_collector::operator()): ... this and adjust.
10004 (collect_symtabs_from_filename): symtab_collector construction
10005 bits move to symtab_collector ctor. Pass the symtab_collector
10006 object directly as callback. Remove cleanups and use
10007 symtab_collector::release_symtabs instead.
10008 (collect_symbols): Delete.
10009 (add_matching_symbols_to_info): Use lambdas.
10010 * macrocmd.c (print_macro_callback): Delete.
10011 (info_macro_command): Use a lambda.
10012 (info_macros_command): Pass print_macro_definition as callable
10013 directly.
10014 (print_one_macro): Remove 'ignore' parameter.
10015 (macro_list_command): Adjust.
10016 * macrotab.c (macro_for_each_data::fn): Now a function_view.
10017 (macro_for_each_data::user_data): Delete field.
10018 (foreach_macro): Adjust to call the function_view.
10019 (macro_for_each): Adjust to use function_view as callback type.
10020 (foreach_macro_in_scope): Adjust to call the function_view.
10021 (macro_for_each_in_scope): Adjust to use function_view as callback
10022 type.
10023 * macrotab.h: Include "common/function-view.h".
10024 (macro_callback_fn): Declare a prototype instead of a pointer.
10025 Remove "user_data" parameter.
10026 (macro_for_each, macro_for_each_in_scope): Adjust to use
10027 function_view as callback type.
10028 * psymtab.c (partial_map_expand_apply)
10029 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
10030 Adjust to use function_view as callback type and to return bool.
10031 (psym_expand_symtabs_matching): Adjust to use function_view as
10032 callback types.
10033 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
10034 to use function_view as callback type and to return bool.
10035 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
10036 callback types.
10037 * symfile.c (expand_symtabs_matching): Adjust to use function_view
10038 as callback types.
10039 * symfile.h: Include "common/function-view.h".
10040 (expand_symtabs_file_matcher_ftype)
10041 (expand_symtabs_symbol_matcher_ftype)
10042 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
10043 return bool.
10044 (quick_symbol_functions::map_symtabs_matching_filename)
10045 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
10046 function_view as callback type and return bool.
10047 (expand_symtabs_matching): Adjust to use function_view as callback
10048 type.
10049 (maintenance_expand_name_matcher)
10050 (maintenance_expand_file_matcher): Delete.
10051 (maintenance_expand_symtabs): Use lambdas.
10052 * symtab.c (iterate_over_some_symtabs): Adjust to use
10053 function_view as callback types and return bool.
10054 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
10055 of a cleanup.
10056 (lookup_symtab_callback): Delete.
10057 (lookup_symtab): Use a lambda.
10058 (iterate_over_symbols): Adjust to use function_view as callback
10059 type.
10060 (struct search_symbols_data, search_symbols_file_matches)
10061 (search_symbols_name_matches): Delete.
10062 (search_symbols): Use a pair of lambdas.
10063 (struct add_name_data, add_macro_name, symbol_completion_matcher)
10064 (symtab_expansion_callback): Delete.
10065 (default_make_symbol_completion_list_break_on_1): Use lambdas.
10066 * symtab.h: Include "common/function-view.h".
10067 (iterate_over_some_symtabs): Adjust to use function_view as
10068 callback type and return bool.
10069 (iterate_over_symtabs): Adjust to use function_view as callback
10070 type.
10071 (symbol_found_callback_ftype): Remove 'data' parameter and return
10072 bool.
10073 (iterate_over_symbols): Adjust to use function_view as callback
10074 type.
10075
10076 2017-02-23 Pedro Alves <palves@redhat.com>
10077
10078 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
10079 (%.o) <unittests/%.c>: New pattern.
10080 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
10081 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
10082 * common/function-view.h: New file.
10083 * unittests/function-view-selftests.c: New file.
10084 * configure: Regenerate.
10085
10086 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
10087
10088 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
10089 inferior_ptid.
10090 * go32-nat.c (go32_thread_alive): Likewise.
10091
10092 2017-02-23 Yao Qi <yao.qi@linaro.org>
10093
10094 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
10095 delete.
10096
10097 2017-02-23 Yao Qi <yao.qi@linaro.org>
10098
10099 * varobj.c (varobj_clear_saved_item): Use delete instead of
10100 xfree.
10101 (update_dynamic_varobj_children): Likewise.
10102
10103 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10104
10105 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
10106
10107 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
10108
10109 * common/enum-flags.h (enum_flags::enum_flags): Initialize
10110 m_enum_value to 0 in default constructor.
10111
10112 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10113
10114 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
10115 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
10116 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
10117 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
10118 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
10119 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
10120 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
10121 IS_STORE_CONDITIONAL_INSN.
10122
10123 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10124
10125 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
10126
10127 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10128
10129 * NEWS (Changes since GDB 7.12): Add DWARF-5.
10130
10131 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10132
10133 * dwarf2read.c (skip_one_die, read_attribute_value)
10134 (dwarf2_const_value_attr, dump_die_shallow)
10135 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
10136 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
10137
10138 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10139
10140 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
10141 (dwarf_parse_macro_header): Accept DWARF version 5.
10142 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
10143
10144 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10145
10146 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
10147 DW_AT_GNU_*.
10148 * common/common-exceptions.h (enum errors): Likewise.
10149 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
10150 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
10151 (dwarf_expr_context::execute_stack_op): Likewise.
10152 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
10153 Likewise.
10154 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
10155 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
10156 (show_entry_values_debug, call_site_to_target_addr)
10157 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
10158 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
10159 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
10160 (value_of_dwarf_block_entry, indirect_pieced_value)
10161 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
10162 (disassemble_dwarf_expression): Likewise.
10163 * dwarf2read.c (process_die, inherit_abstract_dies)
10164 (read_call_site_scope): Likewise.
10165 * gdbtypes.h (struct func_type, struct call_site_parameter)
10166 (struct call_site): Likewise.
10167 * stack.c (read_frame_arg): Likewise.
10168 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
10169
10170 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10171
10172 * defs.h (read_unsigned_leb128): New declaration.
10173 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
10174 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
10175 (dwarf2_find_location_expression): Call also
10176 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
10177 * dwarf2loc.h (dwarf2_version): New declaration.
10178 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
10179 rnglists.
10180 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
10181 .debug_rnglists.
10182 (struct dwop_section_names): Add loclists_dwo.
10183 (dwop_section_names): Add .debug_loclists.dwo.
10184 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
10185 (struct dwarf2_per_cu_data): Add dwarf_version.
10186 (struct dwo_sections): Add loclists.
10187 (struct attr_abbrev): Add implicit_const.
10188 (read_indirect_line_string): New declaration.
10189 (read_unsigned_leb128): Delete declaration.
10190 (rcuh_kind): New definition.
10191 (read_and_check_comp_unit_head): Change parameter
10192 is_debug_types_section to section_kind.
10193 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
10194 (read_comp_unit_head): Change parameter abfd to section, add parameter
10195 section_kind. Handle DWARF-5.
10196 (error_check_comp_unit_head): Accept also DWARF version 5.
10197 (read_and_check_comp_unit_head): Change parameter
10198 is_debug_types_section to section_kind.
10199 (read_and_check_type_unit_head): Delete function.
10200 (read_abbrev_offset): Handle DWARF-5.
10201 (create_debug_type_hash_table): Add parameter section_kind. Process
10202 only DW_UT_type. Use signature and type_offset_in_tu from struct
10203 comp_unit_head.
10204 (create_debug_types_hash_table): Update create_debug_type_hash_table
10205 caller.
10206 (create_all_type_units): Call create_debug_type_hash_table.
10207 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
10208 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
10209 caller.
10210 (skip_one_die): Handle DW_FORM_implicit_const.
10211 (dwarf2_rnglists_process): New function.
10212 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
10213 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
10214 (read_attribute_value): Handle DW_FORM_implicit_const,
10215 DW_FORM_line_strp.
10216 (read_attribute): Handle DW_FORM_implicit_const.
10217 (read_indirect_string_at_offset_from): New function from
10218 read_indirect_string_at_offset.
10219 (read_indirect_string_at_offset): Call
10220 read_indirect_string_at_offset_from.
10221 (read_indirect_line_string_at_offset): New function.
10222 (read_indirect_string): New function comment.
10223 (read_indirect_line_string): New function.
10224 (read_unsigned_leb128): Make it global.
10225 (dwarf2_string_attr): Handle DWARF-5.
10226 (add_include_dir_stub, read_formatted_entries): New functions.
10227 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
10228 Handle DWARF-5.
10229 (per_cu_header_read_in): Update read_comp_unit_head caller.
10230 (dwarf2_version): New function.
10231 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
10232 rnglists.
10233 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
10234 fields.
10235
10236 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10237
10238 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
10239
10240 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10241
10242 * dwarf2read.c (dwarf2_ranges_process): New function from
10243 dwarf2_ranges_read.
10244 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
10245 dwarf2_ranges_process.
10246
10247 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10248
10249 * dwarf2read.c (create_debug_type_hash_table): New function from
10250 create_debug_types_hash_table.
10251 (create_debug_types_hash_table): Call create_debug_type_hash_table.
10252 (create_all_type_units, open_and_init_dwo_file): Update
10253 create_debug_types_hash_table callers.
10254
10255 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10256
10257 PR gdb/16188
10258 * fork-child.c (trace_start_error): Fix thinko. va_end should
10259 refer to 'ap', not 'args'.
10260
10261 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10262 Pedro Alves <palves@redhat.com>
10263
10264 PR gdb/16188
10265 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
10266 calls succeeded.
10267 * fork-child.c (trace_start_error): New function.
10268 (trace_start_error_with_name): Likewise.
10269 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
10270 * inf-ptrace.c (inf_ptrace_me): Likewise.
10271 * inferior.h (trace_start_error): New prototype.
10272 (trace_start_error_with_name): Likewise.
10273
10274 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
10275
10276 PR gdb/21164
10277 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
10278 NULL before using it.
10279 * symmisc.c (maintenance_print_symbols): Likewise.
10280 (maintenance_print_msymbols): Likewise.
10281
10282 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10283
10284 * NEWS: Add record Python bindings entry.
10285
10286 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10287
10288 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
10289 py-record-full.o.
10290 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
10291 * python/py-record-btrace.c, python/py-record-btrace.h,
10292 python/py-record-full.c, python/py-record-full.h: New file.
10293 * python/py-record.c: Add include for py-record-btrace.h and
10294 py-record-full.h.
10295 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
10296 recpy_instruction_history, recpy_function_call_history, recpy_begin,
10297 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
10298 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
10299 New definition.
10300 (gdbpy_initialize_btrace): New export.
10301 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
10302
10303 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10304
10305 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
10306 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
10307 * python/py-record.c: New file.
10308 * python/python-internal.h (gdbpy_start_recording,
10309 gdbpy_current_recording, gdpy_stop_recording,
10310 gdbpy_initialize_record): New export.
10311 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
10312 (python_GdbMethods): Add gdbpy_start_recording,
10313 gdbpy_current_recording and gdbpy_stop_recording.
10314
10315 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10316
10317 * record-btrace.c (record_btrace_record_method): New function.
10318 (init_record_btrace_ops): Initialize to_record_method.
10319 * record-full.c (record_full_record_method): New function.
10320 (init_record_full_ops, init_record_full_core_ops): Add
10321 record_full_record_method.
10322 * record.h (enum record_method): New enum.
10323 * target-debug.h (target_debug_print_enum_record_method: New define.
10324 * target-delegates.c: Regenerate.
10325 * target.c (target_record_method): New function.
10326 * target.h: Include record.h.
10327 (struct target_ops) <to_record_method>: New field.
10328 (target_record_method): New export.
10329
10330 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10331
10332 * record.h (record_start, record_stop): New export.
10333 * record.c (record_start, record_stop): New function.
10334
10335 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10336
10337 * btrace.c (btrace_fetch): Copy function call segments pointer
10338 into a vector.
10339 (btrace_clear): Clear the vector.
10340 (btrace_find_insn_by_number): Use binary search to find the correct
10341 function call segment.
10342 * btrace.h (brace_fun_p): New typedef.
10343 (struct btrace_thread_info) <functions>: New field.
10344
10345 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10346
10347 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
10348 * btrace.c (btrace_decode_error): ... here. New function.
10349 * btrace.h (btrace_decode_error): New export.
10350
10351 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10352
10353 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
10354 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
10355 btrace_find_insn_by_number): Remove special case for gaps.
10356 * btrace.h (btrace_insn_get_error): New export.
10357 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
10358 * record-btrace.c (btrace_insn_history): Print number for gaps.
10359 (record_btrace_info, record_btrace_goto): Handle gaps.
10360
10361 2017-02-14 Tom Tromey <tom@tromey.com>
10362
10363 PR python/13598:
10364 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
10365 event.
10366 * python/py-evts.c (gdbpy_initialize_py_events): Add
10367 before_prompt registry.
10368 * python/py-events.h (events_object) <before_prompt>: New field.
10369
10370 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
10371
10372 * btrace.c (ftrace_new_switch): Preserve up link and flags.
10373
10374 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
10375
10376 * symfile (_initialize_symfile): Add usage text to the load command's
10377 help text.
10378
10379 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
10380
10381 * utils.c (defaulted_query): Don't query on secondary UIs.
10382
10383 2017-02-10 Tom Tromey <tom@tromey.com>
10384
10385 * rust-lang.c (rust_get_disr_info): Remove unused variable.
10386
10387 2017-02-10 Tom Tromey <tom@tromey.com>
10388
10389 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
10390 "cleanup" local.
10391 * python/py-type.c (typy_legacy_template_argument): Remove
10392 unnecessary "cleanup" local.
10393
10394 2017-02-10 Tom Tromey <tom@tromey.com>
10395
10396 * python/python.c (do_start_initialization): New function, from
10397 _initialize_python.
10398 (_initialize_python): Call do_start_initialization.
10399 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10400 goto.
10401
10402 2017-02-10 Tom Tromey <tom@tromey.com>
10403
10404 * python/py-prettyprint.c (pretty_print_one_value): Use
10405 gdbpy_ref.
10406
10407 2017-02-10 Tom Tromey <tom@tromey.com>
10408
10409 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10410 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10411 gdbpy_ref.
10412 * python/py-type.c (field_new): Use gdbpy_ref.
10413 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10414 gdbpy_ref.
10415 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10416 (py_free_pspace): Likewise.
10417 (pspace_to_pspace_object): Likewise.
10418 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10419 (py_free_objfile): Likewise.
10420 (objfile_to_objfile_object): Likewise.
10421 * python/py-inferior.c (delete_thread_object): Use
10422 gdbpy_ref.
10423 (infpy_read_memory): Likewise.
10424 (py_free_inferior): Likewise.
10425 * python/py-evtregistry.c (create_eventregistry_object): Use
10426 gdbpy_ref.
10427 * python/py-event.c (create_event_object): Use gdbpy_ref.
10428
10429 2017-02-10 Tom Tromey <tom@tromey.com>
10430
10431 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10432 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10433 used.
10434 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10435 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10436 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10437 python/py-framefilter.c, python/py-function.c,
10438 python/py-inferior.c, python/py-infevents.c,
10439 python/py-linetable.c, python/py-newobjfileevent.c,
10440 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10441 python/py-signalevent.c, python/py-stopevent.c,
10442 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10443 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10444 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10445 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10446
10447 2017-02-10 Tom Tromey <tom@tromey.com>
10448
10449 * ui-out.h (ui_out_emit_type): New class.
10450 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10451 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10452 and ui_out_emit_tuple.
10453 (enumerate_locals): Likewise.
10454 (py_mi_print_variables, py_print_locals, py_print_args): Use
10455 ui_out_emit_list.
10456 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10457 ui_out_emit_list.
10458 * common/gdb_optional.h: New file.
10459
10460 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10461
10462 * MAINTAINERS (Write After Approval): Update my e-mail address.
10463
10464 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10465
10466 PR gdb/21122
10467 * breakpoint.c (_initialize_breakpoint): Update the help description
10468 of the 'commands' command to indicate that it takes a list argument.
10469
10470 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10471
10472 * interps.c (current_interp_set_logging): Remove "return".
10473
10474 2017-02-09 Gary Benson <gbenson@redhat.com>
10475
10476 * symtab.c (add_symtab_completions): Prevent NULL pointer
10477 dereference.
10478
10479 2017-02-08 Pedro Alves <palves@redhat.com>
10480
10481 * interps.c (interp::interp): Remove reference to quiet_p.
10482 (interp_set): Make static. Remove dead "Switching to" output
10483 code.
10484 (interp_quiet_p, interp_set_quiet): Delete.
10485 (interpreter_exec_cmd): Don't set the interpreter quiet.
10486 * interps.h (interp_quiet_p): Make static.
10487 (class interp) <quiet_p>: Remove field
10488
10489 2017-02-08 Jerome Guitton <guitton@adacore.com>
10490
10491 * cli/cli-decode.c (find_command_name_length): Make it extern.
10492 * cli/cli-decode.h (find_command_name_length): Declare.
10493 * cli/cli-script.c (command_name_equals, line_first_arg):
10494 New functions.
10495 (process_next_line): Use cli-decode to parse command names.
10496 (build_command_line): Make args a constant pointer.
10497
10498 2017-02-08 Jerome Guitton <guitton@adacore.com>
10499
10500 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10501 Remove case-insensitive search.
10502
10503 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10504
10505 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10506 at the end of the line. Avoids an ARI warning.
10507
10508 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
10509
10510 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10511 rdseed instructions.
10512 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10513
10514 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10515
10516 PR tdep/20936
10517 Provide and use sparc32 and sparc64 target description XML files.
10518 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10519 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10520 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10521 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10522 * features/sparc/sparc32-solaris.xml: New file.
10523 * features/sparc/sparc64-solaris.xml: New file.
10524 * features/sparc/sparc32-solaris.c: Generated.
10525 * features/sparc/sparc64-solaris.c: Generated.
10526 * sparc-tdep.h: Account for differences in target descriptions.
10527 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10528 (sparc32_register_type): Use target provided registers.
10529 (validate_tdesc_registers): New function.
10530 (sparc32_gdbarch_init): Use tdesc_has_registers.
10531 Set pseudoregister functions.
10532 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10533 (sparc64_register_type): Use target provided registers.
10534 (sparc64_init_abi): Set pseudoregister functions.
10535
10536 2017-02-03 Tom Tromey <tom@tromey.com>
10537
10538 PR rust/21097:
10539 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10540 with a single member.
10541
10542 2017-02-03 Pedro Alves <palves@redhat.com>
10543
10544 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10545 (cli_interp_base::~cli_interp_base): New.
10546 (cli_interp): New struct.
10547 (as_cli_interp): Cast the interp itself to cli_interp.
10548 (cli_interpreter_pre_command_loop): Rename to ...
10549 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10550 parameter.
10551 (cli_interpreter_init): Rename to ...
10552 (cli_interp::init): ... this. Remove 'self' parameter. Use
10553 boolean. Make extern.
10554 (cli_interpreter_resume): Rename to ...
10555 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10556 extern.
10557 (cli_interpreter_suspend): Rename to ...
10558 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10559 extern.
10560 (cli_interpreter_exec): Rename to ...
10561 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10562 extern.
10563 (cli_interpreter_supports_command_editing): Rename to ...
10564 (cli_interp_base::supports_command_editing): ... this. Remove
10565 'interp' parameter. Make extern.
10566 (cli_ui_out): Rename to ...
10567 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10568 Make extern.
10569 (cli_set_logging): Rename to ...
10570 (cli_interp_base::set_logging): ... this. Remove 'interp'
10571 parameter. Make extern.
10572 (cli_interp_procs): Delete.
10573 (cli_interp_factory): Adjust to use "new".
10574 * cli/cli-interp.h: Include "interps.h".
10575 (struct cli_interp_base): New struct.
10576 * interps.c (struct interp): Delete. Fields moved to interps.h.
10577 (interp_new): Delete.
10578 (interp::interp, interp::~interp): New.
10579 (interp_set): Use bool, and return void. Assume the interpreter
10580 has suspend, init and resume methods, and that the all return
10581 void.
10582 (set_top_level_interpreter): interp_set returns void.
10583 (interp_ui_out): Adapt.
10584 (current_interp_set_logging): Adapt.
10585 (interp_data): Delete.
10586 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10587 (interp_exec): Adapt.
10588 (top_level_interpreter_data): Delete.
10589 * interps.h (interp_init_ftype, interp_resume_ftype)
10590 (interp_suspend_ftype, interp_exec_ftype)
10591 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10592 (class interp): New.
10593 (interp_new): Delete.
10594 (interp_set): Now returns void. Use bool.
10595 (interp_data, top_level_interpreter_data): Delete.
10596 * mi/mi-common.h: Include interps.h.
10597 (class mi_interp): Inherit from interp. Define a ctor. Declare
10598 init, resume, suspect, exec, interp_ui_out, set_logging and
10599 pre_command_loop methods.
10600 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10601 (mi_interpreter_init): Rename to ...
10602 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10603 bool, return void and make extern. Adjust.
10604 (mi_interpreter_resume): ... Rename to ...
10605 (mi_interp::resume): ... this. Remove the 'data' parameter,
10606 return void and make extern. Adjust.
10607 (mi_interpreter_suspend): ... Rename to ...
10608 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10609 return void and make extern. Adjust.
10610 (mi_interpreter_exec): ... Rename to ...
10611 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10612 extern. Adjust.
10613 (mi_interpreter_pre_command_loop): ... Rename to ...
10614 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10615 parameter and make extern.
10616 (mi_on_normal_stop_1): Adjust.
10617 (mi_ui_out): Rename to ...
10618 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10619 parameter and make extern. Adjust.
10620 (mi_set_logging): Rename to ...
10621 (mi_interp::set_logging): ... this. Remove the 'interp'
10622 parameter and make extern. Adjust.
10623 (mi_interp_procs): Delete.
10624 (mi_interp_factory): Adjust to use 'new'.
10625 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10626 (mi_print_exception, mi_execute_command, mi_load_progress):
10627 Adjust.
10628 * tui/tui-interp.c (tui_interp): New class.
10629 (as_tui_interp): Return a tui_interp pointer.
10630 (tui_on_normal_stop, tui_on_signal_received)
10631 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10632 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10633 to use interp::interp_ui_out.
10634 (tui_init): Rename to ...
10635 (tui_interp::init): ... this. Remove the 'self' parameter, use
10636 bool, return void and make extern. Adjust.
10637 (tui_resume): Rename to ...
10638 (tui_interp::resume): ... this. Remove the 'data' parameter,
10639 return void and make extern. Adjust.
10640 (tui_suspend): Rename to ...
10641 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10642 return void and make extern. Adjust.
10643 (tui_ui_out): Rename to ...
10644 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10645 parameter, and make extern. Adjust.
10646 (tui_exec): Rename to ...
10647 (tui_interp::exec): ... this. Remove the 'data' parameter and
10648 make extern.
10649 (tui_interp_procs): Delete.
10650 (tui_interp_factory): Use "new".
10651
10652 2017-02-02 Tom Tromey <tom@tromey.com>
10653
10654 * rust-exp.y (ends_raw_string, space_then_number)
10655 (rust_identifier_start_p): Return bool.
10656 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10657 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10658 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10659 (rust_chartype_p): Return bool.
10660 (val_print_struct, rust_print_struct_def, rust_print_type):
10661 Update.
10662 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10663 Return bool.
10664
10665 2017-02-02 Tom Tromey <tom@tromey.com>
10666
10667 * rust-lang.c: Reindent.
10668
10669 2017-02-02 Tom Tromey <tom@tromey.com>
10670
10671 * rust-lang.h (rust_crate_for_block): Update.
10672 * rust-lang.c (rust_crate_for_block): Return std::string.
10673 (rust_get_disr_info): Use std:;string, not
10674 gdb::unique_xmalloc_ptr.
10675 * rust-exp.y (crate_name): Update.
10676
10677 2017-02-02 Pedro Alves <palves@redhat.com>
10678
10679 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
10680 field out of gdb_disassembler_test and make it static.
10681
10682 2017-02-02 Pedro Alves <palves@redhat.com>
10683
10684 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
10685 mi1_interp and mi_interp fields.
10686
10687 2017-02-02 Pedro Alves <palves@redhat.com>
10688
10689 * cli/cli-interp.c (struct saved_output_files, saved_output):
10690 Moved from cli/cli-logging.c.
10691 (cli_set_logging): New function.
10692 (cli_interp_procs): Install cli_set_logging.
10693 * cli/cli-interp.h (make_logging_output, cli_set_logging):
10694 Declare.
10695 * cli/cli-logging.c (struct saved_output_files, saved_output):
10696 Moved to cli/cli-interp.c.
10697 (pop_output_files): Don't save outputs here.
10698 (make_logging_output): New function.
10699 (handle_redirections): Don't build tee nor save previous outputs
10700 here.
10701 * interps.c (current_interp_set_logging): Change prototype.
10702 Assume there's always a set_logging_proc method installed.
10703 * interps.h (interp_set_logging_ftype): Change prototype.
10704 (current_interp_set_logging): Change prototype and adjust comment.
10705 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
10706 use make_logging_output.
10707 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
10708 2017-02-02 Pedro Alves <palves@redhat.com>
10709
10710 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
10711 from ...
10712 (set_logging_overwrite): ... here.
10713 (logging_no_redirect_file): Delete.
10714 (set_logging_redirect): Don't handle redirection on the fly.
10715 Instead warn that "logging off" / "logging on" is necessary.
10716 (pop_output_files): Delete references to logging_no_redirect_file.
10717 (show_logging_command): Always speak in terms of what will happen
10718 once logging is reenabled.
10719
10720 2017-02-02 Pedro Alves <palves@redhat.com>
10721
10722 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
10723
10724 2017-02-02 Pedro Alves <palves@redhat.com>
10725
10726 * disasm.c (gdb_pretty_print_insn): Rename to ...
10727 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
10728 Remove gdbarch parameter. Adapt to clear the object's buffers
10729 instead of allocating new buffers, and to print using the object's
10730 gdb_disassembler instead of calling gdb_print_insn.
10731 (dump_insns): Use gdb_pretty_print_disassembler.
10732 * disasm.h (gdb_pretty_print_insn): Delete declaration.
10733 (gdb_pretty_print_disassembler): New class.
10734 * record-btrace.c (btrace_insn_history): Use
10735 gdb_pretty_print_disassembler.
10736
10737 2017-02-02 Pedro Alves <palves@redhat.com>
10738
10739 * ada-lang.c (type_as_string): Use string_file.
10740 * ada-valprint.c (ada_print_floating): Use string_file.
10741 * ada-varobj.c (ada_varobj_scalar_image)
10742 (ada_varobj_get_value_image): Use string_file.
10743 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
10744 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
10745 * breakpoint.c (update_inserted_breakpoint_locations)
10746 (insert_breakpoint_locations, reattach_breakpoints)
10747 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
10748 (print_it_watchpoint): Use string_file.
10749 (save_breakpoints): Use stdio_file.
10750 * c-exp.y (oper): Use string_file.
10751 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
10752 tee_file.
10753 (pop_output_files): Use delete.
10754 (handle_redirections): Use stdio_file and tee_file.
10755 * cli/cli-setshow.c (do_show_command): Use string_file.
10756 * compile/compile-c-support.c (c_compute_program): Use
10757 string_file.
10758 * compile/compile-c-symbols.c (generate_vla_size): Take a
10759 'string_file &' instead of a 'ui_file *'.
10760 (generate_c_for_for_one_variable): Take a 'string_file &' instead
10761 of a 'ui_file *'. Use string_file.
10762 (generate_c_for_variable_locations): Take a 'string_file &'
10763 instead of a 'ui_file *'.
10764 * compile/compile-internal.h (generate_c_for_for_one_variable):
10765 Take a 'string_file &' instead of a 'ui_file *'.
10766 * compile/compile-loc2c.c (push, pushf, unary, binary)
10767 (print_label, pushf_register_address, pushf_register)
10768 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
10769 'ui_file *'. Adjust.
10770 * compile/compile.c (compile_to_object): Use string_file.
10771 * compile/compile.h (compile_dwarf_expr_to_c)
10772 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
10773 'ui_file *'.
10774 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
10775 (replace_typedefs_qualified_name): Use string_file and
10776 obstack_copy0.
10777 * disasm.c (gdb_pretty_print_insn): Use string_file.
10778 (gdb_disassembly): Adjust reference the null_stream global.
10779 (do_ui_file_delete): Delete.
10780 (gdb_insn_length): Use null_stream.
10781 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
10782 * dwarf2loc.c (dwarf2_compile_property_to_c)
10783 (locexpr_generate_c_location, loclist_generate_c_location): Take a
10784 'string_file &' instead of a 'ui_file *'.
10785 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
10786 * dwarf2read.c (do_ui_file_peek_last): Delete.
10787 (dwarf2_compute_name): Use string_file.
10788 * event-top.c (gdb_setup_readline): Use stdio_file.
10789 * gdbarch.sh (verify_gdbarch): Use string_file.
10790 * gdbtypes.c (safe_parse_type): Use null_stream.
10791 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
10792 string_file.
10793 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
10794 'string_file *' instead of a 'ui_file *'.
10795 (gdbscm_arch_disassemble): Use string_file.
10796 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
10797 * guile/scm-ports.c (class ioscm_file_port): Now a class that
10798 inherits from ui_file.
10799 (ioscm_file_port_delete, ioscm_file_port_rewind)
10800 (ioscm_file_port_put): Delete.
10801 (ioscm_file_port_write): Rename to ...
10802 (ioscm_file_port::write): ... this. Remove file_port_magic
10803 checks.
10804 (ioscm_file_port_new): Delete.
10805 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
10806 ui_file_up.
10807 * guile/scm-type.c (tyscm_type_name): Use string_file.
10808 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
10809 Use string_file.
10810 * infcmd.c (print_return_value_1): Use string_file.
10811 * infrun.c (print_target_wait_results): Use string_file.
10812 * language.c (add_language): Use string_file.
10813 * location.c (explicit_to_string_internal): Use string_file.
10814 * main.c (captured_main_1): Use null_file.
10815 * maint.c (maintenance_print_architecture): Use stdio_file.
10816 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
10817 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
10818 event_channel>: Change type to mi_console_file pointer.
10819 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
10820 (mi_console_file_delete): Delete.
10821 (struct mi_console_file): Delete.
10822 (mi_console_file_magic): Delete.
10823 (mi_console_file_new): Delete.
10824 (mi_console_file::mi_console_file): New.
10825 (mi_console_file_delete): Delete.
10826 (mi_console_file_fputs): Delete.
10827 (mi_console_file::write): New.
10828 (mi_console_raw_packet): Delete.
10829 (mi_console_file::flush): New.
10830 (mi_console_file_flush): Delete.
10831 (mi_console_set_raw): Rename to ...
10832 (mi_console_file::set_raw): ... this.
10833 * mi/mi-console.h (class mi_console_file): New class.
10834 (mi_console_file_new, mi_console_set_raw): Delete.
10835 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
10836 (mi_set_logging): Use delete and tee_file. Adjust.
10837 * mi/mi-main.c (output_register): Use string_file.
10838 (mi_cmd_data_evaluate_expression): Use string_file.
10839 (mi_cmd_data_read_memory): Use string_file.
10840 (mi_cmd_execute, print_variable_or_computed): Use string_file.
10841 * mi/mi-out.c (mi_ui_out::main_stream): New.
10842 (mi_ui_out::rewind): Use main_stream and
10843 string_file.
10844 (mi_ui_out::put): Use main_stream and string_file.
10845 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10846 Allocate a 'string_file' instead.
10847 (mi_out_new): Don't allocate a mem_fileopen stream here.
10848 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10849 (mi_ui_out::main_stream): Declare method.
10850 * printcmd.c (eval_command): Use string_file.
10851 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
10852 * python/py-arch.c (archpy_disassemble): Use string_file.
10853 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
10854 * python/py-frame.c (frapy_str): Use string_file.
10855 * python/py-framefilter.c (py_print_type, py_print_single_arg):
10856 Use string_file.
10857 * python/py-type.c (typy_str): Use string_file.
10858 * python/py-unwind.c (unwind_infopy_str): Use string_file.
10859 * python/py-value.c (valpy_str): Use string_file.
10860 * record-btrace.c (btrace_insn_history): Use string_file.
10861 * regcache.c (regcache_print): Use stdio_file.
10862 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
10863 * remote.c (escape_buffer): Use string_file.
10864 * rust-lang.c (rust_get_disr_info): Use string_file.
10865 * serial.c (serial_open_ops_1): Use stdio_file.
10866 (do_serial_close): Use delete.
10867 * stack.c (print_frame_arg): Use string_file.
10868 (print_frame_args): Remove local mem_fileopen stream, not used.
10869 (print_frame): Use string_file.
10870 * symmisc.c (maintenance_print_symbols): Use stdio_file.
10871 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
10872 Take a 'string_file *' instead of a 'ui_file *'.
10873 * top.c (new_ui): Use stdio_file and stderr_file.
10874 (free_ui): Use delete.
10875 (execute_command_to_string): Use string_file.
10876 (quit_confirm): Use string_file.
10877 * tracepoint.c (collection_list::append_exp): Use string_file.
10878 * tui/tui-disasm.c (tui_disassemble): Use string_file.
10879 * tui/tui-file.c: Don't include "ui-file.h".
10880 (enum streamtype, struct tui_stream): Delete.
10881 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
10882 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
10883 (tui_file::tui_file): New method.
10884 (tui_file_fputs): Delete.
10885 (tui_file_get_strbuf): Delete.
10886 (tui_file::puts): New method.
10887 (tui_file_adjust_strbuf): Delete.
10888 (tui_file_flush): Delete.
10889 (tui_file::flush): New method.
10890 * tui/tui-file.h: Tweak intro comment.
10891 Include ui-file.h.
10892 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
10893 (tui_file_adjust_strbuf): Delete declarations.
10894 (class tui_file): New class.
10895 * tui/tui-io.c (tui_initialize_io): Use tui_file.
10896 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
10897 (tui_register_format): Use string_stream.
10898 * tui/tui-stack.c (tui_make_status_line): Use string_file.
10899 (tui_get_function_from_frame): Use string_file.
10900 * typeprint.c (type_to_string): Use string_file.
10901 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
10902 (null_stream): New global.
10903 (ui_file_delete): Delete.
10904 (ui_file::ui_file): New.
10905 (null_file_isatty): Delete.
10906 (ui_file::~ui_file): New.
10907 (null_file_rewind): Delete.
10908 (ui_file::printf): New.
10909 (null_file_put): Delete.
10910 (null_file_flush): Delete.
10911 (ui_file::putstr): New.
10912 (null_file_write): Delete.
10913 (ui_file::putstrn): New.
10914 (null_file_read): Delete.
10915 (ui_file::putc): New.
10916 (null_file_fputs): Delete.
10917 (null_file_write_async_safe): Delete.
10918 (ui_file::vprintf): New.
10919 (null_file_delete): Delete.
10920 (null_file::write): New.
10921 (null_file_fseek): Delete.
10922 (null_file::puts): New.
10923 (ui_file_data): Delete.
10924 (null_file::write_async_safe): New.
10925 (gdb_flush, ui_file_isatty): Adjust.
10926 (ui_file_put, ui_file_rewind): Delete.
10927 (ui_file_write): Adjust.
10928 (ui_file_write_for_put): Delete.
10929 (ui_file_write_async_safe, ui_file_read): Adjust.
10930 (ui_file_fseek): Delete.
10931 (fputs_unfiltered): Adjust.
10932 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
10933 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
10934 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
10935 (set_ui_file_data): Delete.
10936 (string_file::~string_file, string_file::write)
10937 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
10938 (do_ui_file_as_string, ui_file_as_string): Delete.
10939 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
10940 (struct mem_file): Delete.
10941 (mem_file_new): Delete.
10942 (stdio_file::stdio_file): New.
10943 (mem_file_delete): Delete.
10944 (stdio_file::stdio_file): New.
10945 (mem_fileopen): Delete.
10946 (stdio_file::~stdio_file): New.
10947 (mem_file_rewind): Delete.
10948 (stdio_file::set_stream): New.
10949 (mem_file_put): Delete.
10950 (stdio_file::open): New.
10951 (mem_file_write): Delete.
10952 (stdio_file_magic, struct stdio_file): Delete.
10953 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
10954 (stdio_file::flush): New.
10955 (stdio_file_read): Rename to ...
10956 (stdio_file::read): ... this. Adjust.
10957 (stdio_file_write): Rename to ...
10958 (stdio_file::write): ... this. Adjust.
10959 (stdio_file_write_async_safe): Rename to ...
10960 (stdio_file::write_async_safe) ... this. Adjust.
10961 (stdio_file_fputs): Rename to ...
10962 (stdio_file::puts) ... this. Adjust.
10963 (stdio_file_isatty): Delete.
10964 (stdio_file_fseek): Delete.
10965 (stdio_file::isatty): New.
10966 (stderr_file_write): Rename to ...
10967 (stderr_file::write) ... this. Adjust.
10968 (stderr_file_fputs): Rename to ...
10969 (stderr_file::puts) ... this. Adjust.
10970 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
10971 (stderr_file::stderr_file): New.
10972 (tee_file_magic): Delete.
10973 (struct tee_file): Delete.
10974 (tee_file::tee_file): New.
10975 (tee_file_new): Delete.
10976 (tee_file::~tee_file): New.
10977 (tee_file_delete): Delete.
10978 (tee_file_flush): Rename to ...
10979 (tee_file::flush): ... this. Adjust.
10980 (tee_file_write): Rename to ...
10981 (tee_file::write): ... this. Adjust.
10982 (tee_file::write_async_safe): New.
10983 (tee_file_fputs): Rename to ...
10984 (tee_file::puts): ... this. Adjust.
10985 (tee_file_isatty): Rename to ...
10986 (tee_file::isatty): ... this. Adjust.
10987 * ui-file.h (struct obstack, struct ui_file): Don't
10988 forward-declare.
10989 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
10990 (ui_file_write_ftype)
10991 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
10992 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
10993 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
10994 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
10995 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
10996 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
10997 (set_ui_file_fseek): Delete.
10998 (ui_file_data, ui_file_delete, ui_file_rewind)
10999 (struct ui_file): New.
11000 (ui_file_up): New.
11001 (class null_file): New.
11002 (null_stream): Declare.
11003 (ui_file_write_for_put, ui_file_put): Delete.
11004 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
11005 Delete.
11006 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
11007 (gdb_fopen, tee_file_new): Delete.
11008 (struct string_file): New.
11009 (struct stdio_file): New.
11010 (stdio_file_up): New.
11011 (struct stderr_file): New.
11012 (class tee_file): New.
11013 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
11014 of a 'ui_file *'. Adjust.
11015 * ui-out.h (class ui_out) <field_stream>: Likewise.
11016 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
11017 (null_stream): Delete.
11018 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
11019 Adjust.
11020 * utils.h (struct ui_file): Delete forward declaration..
11021 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
11022 (error_stream): Take a 'string_file &' instead of a
11023 'ui_file *'.
11024 * varobj.c (varobj_value_get_print_value): Use string_file.
11025 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
11026 * gdbarch.c: Regenerate.
11027
11028 2017-02-02 Pedro Alves <palves@redhat.com>
11029
11030 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
11031 (gdb_pretty_print_insn): ... this. Now a free function. Add back
11032 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
11033 Adjust to call gdb_print_insn instead of
11034 gdb_disassembler::print_insn.
11035 (dump_insns, do_mixed_source_and_assembly_deprecated)
11036 (do_mixed_source_and_assembly, do_assembly_only): Add back a
11037 'gdbarch' parameter. Remove gdb_disassembler parameter.
11038 (gdb_disassembly): Don't allocate a gdb_disassembler here.
11039 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
11040 declaration.
11041 (gdb_pretty_print_insn): Re-add declaration.
11042 * record-btrace.c (btrace_insn_history): Don't allocate a
11043 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
11044
11045 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
11046
11047 * disasm.h (gdb_disassembly): Remove file_string parameter.
11048 * disasm.c (gdb_disassembly): Likewise.
11049 * cli/cli-cmds.c (print_disassembly): Adapt.
11050 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
11051 * stack.c (do_gdb_disassembly): Likewise.
11052
11053 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
11054
11055 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
11056 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
11057 targets. And if the implicit value is longer than needed, extract
11058 the first bytes instead of the "least significant" ones.
11059
11060 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11061
11062 * btrace.c (btrace_enable): Do not call btrace_add_pc for
11063 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
11064 (btrace_fetch): Assert can_access_registers_ptid.
11065 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
11066 validate_registers_access.
11067
11068 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11069
11070 * gdbthread.h (can_access_registers_ptid): New.
11071 * thread.c (can_access_registers_ptid): New.
11072
11073 2017-02-01 Pedro Alves <palves@redhat.com>
11074
11075 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
11076
11077 2017-01-31 Pedro Alves <palves@redhat.com>
11078
11079 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
11080 Fix typos.
11081
11082 2017-01-31 Pedro Alves <palves@redhat.com>
11083
11084 * stack.c (print_frame_args): Remove local mem_fileopen stream,
11085 not used.
11086
11087 2017-01-31 Pedro Alves <palves@redhat.com>
11088
11089 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
11090
11091 2017-01-31 Pedro Alves <palves@redhat.com>
11092
11093 * common/scoped_restore.h
11094 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
11095 change the value's parameter type to T2.
11096 (make_scoped_restore): Likewise.
11097
11098 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11099 Richard Henderson <rth@redhat.com>
11100
11101 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
11102 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
11103 GS_BASE for older kernels.
11104 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
11105 GS_BASE for older kernels.
11106 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
11107 and GS_BASE to the offset table.
11108 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
11109 system register group.
11110 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
11111 for older kernels.
11112 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
11113 amd64 ABI.
11114 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
11115 AMD64_GSBASE_REGNUM.
11116 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
11117 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
11118 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
11119 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
11120 i386/64bit-segments.xml in those rules.
11121 * features/i386/64bit-segments.xml: New file.
11122 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
11123 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
11124 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
11125 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
11126 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
11127 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
11128 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
11129 * features/i386/amd64-avx-linux.c: Regenerated.
11130 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
11131 * features/i386/amd64-avx-mpx.c: Regenerated.
11132 * features/i386/amd64-avx512-linux.c: Regenerated.
11133 * features/i386/amd64-linux.c: Regenerated.
11134 * features/i386/amd64-mpx-linux.c: Regenerated.
11135 * features/i386/i386-avx-mpx-linux.c: Regenerated.
11136 * features/i386/i386-avx-mpx.c: Regenerated.
11137 * features/i386/x32-avx-linux.c: Regenerated.
11138 * features/i386/x32-avx512-linux.c: Regenerated.
11139 * regformats/i386/amd64-avx-linux.dat: Regenerated.
11140 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
11141 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
11142 * regformats/i386/amd64-linux.dat: Regenerated.
11143 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
11144 * regformats/i386/x32-avx-linux.dat: Regenerated.
11145 * regformats/i386/x32-avx512-linux.dat: Regenerated.
11146 * regformats/i386/x32-linux.dat: Regenerated.
11147
11148 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11149
11150 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
11151 Set to AMD64_NUM_REGS.
11152
11153 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11154
11155 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
11156 that checks validity of a register number.
11157
11158 2017-01-27 Kees Cook <keescook@google.com>
11159
11160 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
11161 fetch_fpregs if target has fpa registers.
11162 (arm_linux_store_inferior_registers): Call store_fpregs if target
11163 has fpa registers.
11164
11165 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
11166
11167 * cris-tdep.c (cris_gdbarch_init): Remove check for
11168 info.byte_order and force it to BFD_ENDIAN_LITTLE.
11169
11170 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
11171
11172 * corelow.c (get_core_register_section): Check for regset
11173 existence before checking for REGSET_VARIABLE_SIZE.
11174
11175 2017-01-26 Yao Qi <yao.qi@linaro.org>
11176 Pedro Alves <palves@redhat.com>
11177
11178 PR gdb/20939
11179 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
11180 call memory_error, save memaddr instead.
11181 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
11182 negative, cal memory_error.
11183 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
11184
11185 2017-01-26 Yao Qi <yao.qi@linaro.org>
11186
11187 * disasm-selftests.c (memory_error_test): New function.
11188 (_initialize_disasm_selftests): Register memory_error_test.
11189
11190 2017-01-26 Yao Qi <yao.qi@linaro.org>
11191
11192 * Makefile.in (SFILES): Add disasm-selftests.c and
11193 selftest-arch.c.
11194 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
11195 * disasm-selftests.c: New file.
11196 * selftest-arch.c: New file.
11197 * selftest-arch.h: New file.
11198
11199 2017-01-26 Yao Qi <yao.qi@linaro.org>
11200
11201 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
11202 to bfd_arch_mep. Don't return 0 if section is not
11203 found. Call print_insn_mep.
11204
11205 2017-01-26 Pedro Alves <palves@redhat.com>
11206 Yao Qi <yao.qi@linaro.org>
11207
11208 * arm-tdep.c: Include "disasm.h".
11209 (gdb_print_insn_arm): Update code to get gdbarch.
11210 * disasm.c (dis_asm_read_memory): Change it to
11211 gdb_disassembler::dis_asm_read_memory.
11212 (dis_asm_memory_error): Likewise.
11213 (dis_asm_print_address): Likewise.
11214 (gdb_pretty_print_insn): Change it to
11215 gdb_disassembler::pretty_print_insn.
11216 (dump_insns): Add one argument gdb_disassemlber. All
11217 callers updated.
11218 (do_mixed_source_and_assembly_deprecated): Likewise.
11219 (do_mixed_source_and_assembly): Likewise.
11220 (do_assembly_only): Likewise.
11221 (gdb_disassembler::gdb_disassembler): New.
11222 (gdb_disassembler::print_insn): New.
11223 * disasm.h (class gdb_disassembler): New.
11224 (gdb_pretty_print_insn): Remove declaration.
11225 (gdb_disassemble_info): Likewise.
11226 * guile/scm-disasm.c (class gdbscm_disassembler): New.
11227 (gdbscm_disasm_read_memory_worker): Update.
11228 (gdbscm_disasm_read_memory): Update.
11229 (gdbscm_disasm_memory_error): Remove.
11230 (gdbscm_disasm_print_address): Remove.
11231 (gdbscm_disassembler::gdbscm_disassembler): New.
11232 (gdbscm_print_insn_from_port): Update.
11233 * mips-tdep.c: Include disasm.h.
11234 (gdb_print_insn_mips): Update code to get gdbarch.
11235 * record-btrace.c (btrace_insn_history): Update.
11236 * spu-tdep.c: Include disasm.h.
11237 (struct spu_dis_asm_data): Remove.
11238 (struct spu_dis_asm_info): New.
11239 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
11240 SPU id.
11241 (gdb_print_insn_spu): Cast disassemble_info to
11242 spu_dis_asm_info.
11243
11244 2017-01-26 Yao Qi <yao.qi@linaro.org>
11245
11246 * disasm.c (do_ui_file_delete): Delete.
11247 (gdb_insn_length): Move code creating stream to ...
11248 * utils.c (null_stream): ... here. New function.
11249 * utils.h (null_stream): Declare.
11250
11251 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
11252
11253 * python/py-inferior.c (find_thread_object): Return directly
11254 from the loop. Remove "found" variable.
11255
11256 2017-01-21 Joel Brobecker <brobecker@adacore.com>
11257
11258 GDB 7.12.1 released.
11259
11260 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11261
11262 * python/py-function.c (fnpy_call): Reorder declarations to have
11263 the gdbpy_enter object declared first.
11264 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
11265
11266 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11267
11268 PR python/21068
11269 * python/python-internal.h (PyMem_RawMalloc): Define for
11270 Python < 3.4.
11271 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
11272 PyMem_RawMalloc instead of PyMem_Malloc.
11273
11274 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
11275 Luis Machado <lgustavo@codesourcery.com>
11276
11277 * NEWS (New commands): Mention flash-erase.
11278 (New MI commands): Mention target-flash-erase.
11279 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
11280 command.
11281 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
11282 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
11283 * target.c (flash_erase_command): New function.
11284 (initialize_targets): Add new flash-erase command.
11285 * target.h (flash_erase_command): New declaration.
11286
11287 2017-01-20 Joel Brobecker <brobecker@adacore.com>
11288
11289 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
11290 HAVE_SYS_PROCFS_H is defined.
11291
11292 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11293
11294 * remote.c (struct cached_reg): Change data into a pointer.
11295 * (stop_reply_dtr): Free data pointers before deleting vector.
11296 (process_stop_reply): Likewise.
11297 (remote_parse_stop_reply): Allocate space for data
11298
11299 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11300
11301 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
11302 MAX_REGISTER_SIZE.
11303 (amd64_pseudo_register_read_value): Likewise.
11304 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
11305 (store_register_using_P): Likewise.
11306 * regcache.c (regcache_xfer_part): Likewise.
11307
11308 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
11309
11310 Split real and pseudo registers.
11311 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
11312 (sparc32_pseudo_regnum): New enum.
11313 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
11314 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
11315 (SPARC32_CP0_REGISTERS): New macro.
11316 (sparc32_pseudo_register_name): New function.
11317 (sparc32_register_name): Use sparc32_pseudo_register_name.
11318 (sparc32_pseudo_register_type): New function.
11319 (sparc32_register_type): Use sparc32_pseudo_register_type.
11320 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
11321 pseudo register numbers.
11322 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
11323 (SPARC64_CP0_REGISTERS): New macro.
11324 (sparc64_pseudo_register_name): New function.
11325 (sparc64_register_name): Use sparc64_pseudo_register_name.
11326 (sparc64_pseudo_register_type): New function.
11327 (sparc64_register_type): Use sparc64_pseudo_register_type.
11328 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
11329 pseudo register numbers.
11330 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
11331 sparc64_store_arguments): Handle pseudo register numbers.
11332
11333 2017-01-13 Yao Qi <yao.qi@linaro.org>
11334
11335 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
11336 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
11337 output.
11338 (getpkt_or_notif_sane_1): Likewise.
11339
11340 2017-01-13 Yao Qi <yao.qi@linaro.org>
11341
11342 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
11343 of CC. Pass "-x c++-header" instead of "-x c".
11344
11345 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11346
11347 * remote.c (remote_can_async_p): Update comment.
11348
11349 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11350
11351 * linux-nat.c (linux_nat_can_async_p): Update comment.
11352
11353 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11354
11355 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
11356
11357 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
11358
11359 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
11360
11361 2017-01-10 Tom Tromey <tom@tromey.com>
11362
11363 * python/py-type.c (typy_legacy_template_argument): Update.
11364 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
11365 ~demangle_parse_info): Declare new members.
11366 (cp_demangled_name_to_comp): Return unique_ptr.
11367 (cp_demangled_name_parse_free)
11368 (make_cleanup_cp_demangled_name_parse_free)
11369 (cp_new_demangle_parse_info): Remove.
11370 * cp-support.c (do_demangled_name_parse_free_cleanup)
11371 (make_cleanup_cp_demangled_name_parse_free): Remove.
11372 (inspect_type, cp_canonicalize_string_full)
11373 (cp_canonicalize_string): Update.
11374 (mangled_name_to_comp): Change return type.
11375 (cp_class_name_from_physname, method_name_from_physname)
11376 (cp_func_name, cp_remove_params): Update.
11377 * cp-name-parser.y (demangle_parse_info): New constructor, from
11378 cp_new_demangle_parse_info.
11379 (~demangle_parse_info): New destructor, from
11380 cp_demangled_name_parse_free.
11381 (cp_merge_demangle_parse_infos): Update.
11382 (cp_demangled_name_to_comp): Change return type.
11383
11384 2017-01-10 Tom Tromey <tom@tromey.com>
11385
11386 * top.c (prevent_dont_repeat): Change return type.
11387 * python/python.c (execute_gdb_command): Use std::string.
11388 Update.
11389 * guile/guile.c (gdbscm_execute_gdb_command): Update.
11390 * command.h (prevent_dont_repeat): Change return type.
11391 * breakpoint.c (bpstat_do_actions_1): Update.
11392
11393 2017-01-10 Tom Tromey <tom@tromey.com>
11394
11395 * value.h (scoped_value_mark::~scoped_value_mark): Call
11396 free_to_mark.
11397 (scoped_value_mark::free_to_mark): New method.
11398 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11399 scoped_value_mark.
11400
11401 2017-01-10 Tom Tromey <tom@tromey.com>
11402
11403 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11404 (valpy_reference_value, valpy_const_value, valpy_get_address)
11405 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11406 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11407 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11408 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11409 scoped_value_mark.
11410 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11411 * value.h (scoped_value_mark): New class.
11412
11413 2017-01-10 Tom Tromey <tom@tromey.com>
11414
11415 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11416 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11417 * psymtab.c (discard_psymtabs_upto): Remove.
11418 (make_cleanup_discard_psymtabs): Remove.
11419 (struct psymtab_state): Remove.
11420
11421 2017-01-10 Tom Tromey <tom@tromey.com>
11422
11423 * record-full.c (record_full_save_cleanups): Remove.
11424 (record_full_save): Use gdb::unlinker.
11425 * gcore.c (do_bfd_delete_cleanup): Remove.
11426 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11427 cleanups.
11428 * dwarf2read.c (unlink_if_set): Remove.
11429 (write_psymtabs_to_index): Use gdb::unlinker.
11430 * common/gdb_unlinker.h: New file.
11431
11432 2017-01-10 Tom Tromey <tom@tromey.com>
11433
11434 * windows-tdep.c (windows_xfer_shared_library): Update.
11435 * windows-nat.c (windows_make_so): Update.
11436 * utils.h (make_cleanup_bfd_unref): Remove.
11437 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11438 * symfile.h (symfile_bfd_open)
11439 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11440 * symfile.c (read_symbols, symbol_file_add)
11441 (separate_debug_file_exists): Update.
11442 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11443 (generic_load, reread_symbols): Update.
11444 * symfile-mem.c (symbol_file_add_from_memory): Update.
11445 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11446 (spu_symbol_file_add_from_memory): Update.
11447 * solist.h (struct target_so_ops) <bfd_open>: Return
11448 gdb_bfd_ref_ptr.
11449 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11450 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11451 gdb_bfd_ref_ptr.
11452 (solib_map_sections, reload_shared_libraries_1): Update.
11453 * solib-svr4.c (enable_break): Update.
11454 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11455 * solib-frv.c (enable_break2): Update.
11456 * solib-dsbt.c (enable_break): Update.
11457 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11458 gdb_bfd_ref_ptr.
11459 (darwin_solib_get_all_image_info_addr_at_init): Update.
11460 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11461 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11462 * record-full.c (record_full_save): Update.
11463 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11464 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11465 * minidebug.c (find_separate_debug_file_in_section): Return
11466 gdb_bfd_ref_ptr.
11467 * machoread.c (macho_add_oso_symfile): Change abfd to
11468 gdb_bfd_ref_ptr.
11469 (macho_symfile_read_all_oso): Update.
11470 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11471 (macho_symfile_read): Update.
11472 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11473 (jit_bfd_try_read_symtab): Update.
11474 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11475 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11476 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11477 gdb_bfd_ref_ptr.
11478 (gdb_bfd_ref_policy): New struct.
11479 (gdb_bfd_ref_ptr): New typedef.
11480 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11481 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11482 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11483 gdb_bfd_ref_ptr.
11484 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11485 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11486 (gcore_command): Update.
11487 * exec.c (exec_file_attach): Update.
11488 * elfread.c (elf_symfile_read): Update.
11489 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11490 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11491 (open_and_init_dwo_file): Update.
11492 (open_dwp_file): Return gdb_bfd_ref_ptr.
11493 (open_and_init_dwp_file): Update.
11494 * corelow.c (core_open): Update.
11495 * compile/compile-object-load.c (compile_object_load): Update.
11496 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11497 * coffread.c (coff_symfile_read): Update.
11498 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11499 gdb_bfd_ref_ptr. Rename.
11500 (dump_bfd_file, restore_command): Update.
11501 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11502 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11503 (find_separate_debug_file_by_buildid): Update.
11504
11505 2017-01-10 Tom Tromey <tom@tromey.com>
11506
11507 * common/gdb_ref_ptr.h: New file.
11508 * python/py-ref.h (struct gdbpy_ref_policy): New.
11509 (gdbpy_ref): Now a typedef.
11510
11511 2017-01-10 Tom Tromey <tom@tromey.com>
11512
11513 * utils.h (make_cleanup_htab_delete): Don't declare.
11514 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11515 Remove.
11516 * linespec.c (decode_compound_collector): Add constructor,
11517 destructor.
11518 (lookup_prefix_sym): Remove cleanup.
11519 (symtab_collector): Add constructor, destructor.
11520 (collect_symtabs_from_filename): Remove cleanup.
11521 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11522 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11523 Use htab_up.
11524 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11525 * dwarf2read.c (dw2_expand_symtabs_matching)
11526 (dw2_map_symbol_filenames, dwarf_decode_macros)
11527 (write_psymtabs_to_index): Use htab_up.
11528 * dwarf2loc.c (func_verify_no_selftailcall)
11529 (call_site_find_chain_1, func_verify_no_selftailcall)
11530 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11531 std::vector, gdb::unique_xmalloc_ptr.
11532 (call_sitep): Remove typedef.
11533 (dwarf2_locexpr_baton_eval): Remove unused variable.
11534
11535 2017-01-10 Tom Tromey <tom@tromey.com>
11536
11537 * python/python-internal.h (make_cleanup_py_decref)
11538 (make_cleanup_py_xdecref): Don't declare.
11539 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11540 (py_xdecref, make_cleanup_py_xdecref): Remove.
11541
11542 2017-01-10 Tom Tromey <tom@tromey.com>
11543
11544 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11545 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11546
11547 2017-01-10 Tom Tromey <tom@tromey.com>
11548
11549 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11550
11551 2017-01-10 Tom Tromey <tom@tromey.com>
11552
11553 * python/py-utils.c (unicode_to_encoded_string)
11554 (python_string_to_target_string)
11555 (python_string_to_target_python_string)
11556 (python_string_to_host_string, gdbpy_obj_to_string)
11557 (get_addr_from_python): Use gdbpy_ref.
11558
11559 2017-01-10 Tom Tromey <tom@tromey.com>
11560
11561 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11562 gdbpy_ref.
11563
11564 2017-01-10 Tom Tromey <tom@tromey.com>
11565
11566 * python/python.c (eval_python_command, gdbpy_decode_line)
11567 (gdbpy_run_events, gdbpy_start_type_printers)
11568 (gdbpy_apply_type_printers): Use gdbpy_ref.
11569
11570 2017-01-10 Tom Tromey <tom@tromey.com>
11571
11572 * python/py-param.c (get_doc_string, compute_enum_values): Use
11573 gdbpy_ref.
11574
11575 2017-01-10 Tom Tromey <tom@tromey.com>
11576
11577 * python/py-inferior.c (find_thread_object, build_inferior_list):
11578 Use gdbpy_ref.
11579
11580 2017-01-10 Tom Tromey <tom@tromey.com>
11581
11582 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11583
11584 2017-01-10 Tom Tromey <tom@tromey.com>
11585
11586 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11587 gdbpy_ref.
11588
11589 2017-01-10 Tom Tromey <tom@tromey.com>
11590
11591 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11592 extra incref.
11593 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11594 Use gdbpy_ref.
11595
11596 2017-01-10 Tom Tromey <tom@tromey.com>
11597
11598 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11599 gdbpy_ref.
11600
11601 2017-01-10 Tom Tromey <tom@tromey.com>
11602
11603 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11604 decref results of PyArg_ParseTupleAndKeywords.
11605
11606 2017-01-10 Tom Tromey <tom@tromey.com>
11607
11608 * python/python.c (python_run_simple_file): Use
11609 unique_xmalloc_ptr, gdbpy_ref.
11610
11611 2017-01-10 Tom Tromey <tom@tromey.com>
11612
11613 * python/py-prettyprint.c (print_stack_unless_memory_error)
11614 (print_string_repr, print_children): Use gdbpy_ref.
11615 (dummy_python_frame): New class.
11616 (dummy_python_frame::dummy_python_frame): Rename from
11617 push_dummy_python_frame.
11618 (py_restore_tstate): Remove.
11619
11620 2017-01-10 Tom Tromey <tom@tromey.com>
11621
11622 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11623
11624 2017-01-10 Tom Tromey <tom@tromey.com>
11625
11626 * python/python.c (ensure_python_env, restore_python_env):
11627 Remove.
11628 * python/python-internal.h (ensure_python_env): Don't declare.
11629 * varobj.h (varobj_ensure_python_env): Don't declare.
11630 * varobj.c (varobj_ensure_python_env): Remove.
11631
11632 2017-01-10 Tom Tromey <tom@tromey.com>
11633
11634 * varobj.c (varobj_value_get_print_value): Use
11635 gdbpy_enter_varobj.
11636
11637 2017-01-10 Tom Tromey <tom@tromey.com>
11638
11639 * python/py-prettyprint.c (print_string_repr, print_children):
11640 Update.
11641 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11642 of "encoding".
11643 * varobj.c (varobj_value_get_print_value): Update.
11644 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11645
11646 2017-01-10 Tom Tromey <tom@tromey.com>
11647
11648 * varobj.c (varobj_get_display_hint)
11649 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11650 (varobj_set_visualizer, free_variable): Use
11651 gdbpy_enter_varobj.
11652
11653 2017-01-10 Tom Tromey <tom@tromey.com>
11654
11655 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11656 (do_finish_initialization): New function. Use gdbpy_ref.
11657 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11658 do_finish_initialization.
11659
11660 2017-01-10 Tom Tromey <tom@tromey.com>
11661
11662 * python/py-param.c (get_set_value, get_show_value): Use
11663 gdbpy_enter, gdbpy_ref.
11664
11665 2017-01-10 Tom Tromey <tom@tromey.com>
11666
11667 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11668
11669 2017-01-10 Tom Tromey <tom@tromey.com>
11670
11671 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11672
11673 2017-01-10 Tom Tromey <tom@tromey.com>
11674
11675 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
11676 Use gdbpy_enter_varobj.
11677
11678 2017-01-10 Tom Tromey <tom@tromey.com>
11679
11680 * varobj.c (gdbpy_enter_varobj): New constructor.
11681 * python/python-internal.h (gdbpy_enter_varobj): New class.
11682 * python/py-varobj.c (py_varobj_get_iterator): Use
11683 gdbpy_enter_varobj.
11684
11685 2017-01-10 Tom Tromey <tom@tromey.com>
11686
11687 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
11688 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11689 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
11690 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
11691 unique_xmalloc_ptr.
11692 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
11693
11694 2017-01-10 Tom Tromey <tom@tromey.com>
11695
11696 * python/py-xmethods.c (invoke_match_method): Use
11697 gdbpy_ref.
11698
11699 2017-01-10 Tom Tromey <tom@tromey.com>
11700
11701 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
11702 gdbpy_enter, gdbpy_ref.
11703
11704 2017-01-10 Tom Tromey <tom@tromey.com>
11705
11706 * python/python.c (python_interactive_command): Use gdbpy_enter.
11707
11708 2017-01-10 Tom Tromey <tom@tromey.com>
11709
11710 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
11711 gdbpy_ref.
11712
11713 2017-01-10 Tom Tromey <tom@tromey.com>
11714
11715 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
11716 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11717
11718 2017-01-10 Tom Tromey <tom@tromey.com>
11719
11720 * utils.h (htab_deleter): New struct.
11721 (htab_up): New typedef.
11722 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
11723 gdbpy_enter, gdbpy_ref, htab_up.
11724
11725 2017-01-10 Tom Tromey <tom@tromey.com>
11726
11727 * python/py-unwind.c (pending_frame_invalidate): Remove.
11728 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
11729
11730 2017-01-10 Tom Tromey <tom@tromey.com>
11731
11732 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
11733 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
11734
11735 2017-01-10 Tom Tromey <tom@tromey.com>
11736
11737 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
11738
11739 2017-01-10 Tom Tromey <tom@tromey.com>
11740
11741 * python/python.c (gdbpy_eval_from_control_command)
11742 (gdbpy_source_script, gdbpy_run_events)
11743 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
11744 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
11745 gdbpy_enter.
11746
11747 2017-01-10 Tom Tromey <tom@tromey.com>
11748
11749 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
11750
11751 2017-01-10 Tom Tromey <tom@tromey.com>
11752
11753 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
11754
11755 2017-01-10 Tom Tromey <tom@tromey.com>
11756
11757 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
11758 (python_on_inferior_call_pre, python_on_inferior_call_post)
11759 (python_on_memory_change, python_on_register_change)
11760 (python_inferior_exit, python_new_objfile, add_thread_object)
11761 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
11762
11763 2017-01-10 Tom Tromey <tom@tromey.com>
11764
11765 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
11766 (bpfinishpy_handle_exit): Use gdbpy_enter.
11767
11768 2017-01-10 Tom Tromey <tom@tromey.com>
11769
11770 * python/py-cmd.c (cmdpy_destroyer)
11771 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
11772 gdbpy_enter.
11773
11774 2017-01-10 Tom Tromey <tom@tromey.com>
11775
11776 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11777 gdbpy_enter.
11778 (gdbpy_breakpoint_has_cond): Likewise.
11779
11780 2017-01-10 Tom Tromey <tom@tromey.com>
11781
11782 * python/python.c (gdbpy_enter): New constructor.
11783 (~gdbpy_enter): New destructor.
11784 (restore_python_env, ensure_python_env): Rewrite.
11785 * python/python-internal.h (gdbpy_enter): New class.
11786
11787 2017-01-10 Tom Tromey <tom@tromey.com>
11788
11789 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
11790
11791 2017-01-10 Tom Tromey <tom@tromey.com>
11792
11793 * python/py-value.c (value_has_field, get_field_flag)
11794 (get_field_type, valpy_getitem, convert_value_from_python): Use
11795 gdbpy_ref.
11796
11797 2017-01-10 Tom Tromey <tom@tromey.com>
11798
11799 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
11800 gdbpy_ref.
11801
11802 2017-01-10 Tom Tromey <tom@tromey.com>
11803
11804 * python/py-prettyprint.c (search_pp_list)
11805 (find_pretty_printer_from_objfiles)
11806 (find_pretty_printer_from_progspace)
11807 (find_pretty_printer_from_gdb, find_pretty_printer)
11808 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
11809 gdbpy_ref.
11810
11811 2017-01-10 Tom Tromey <tom@tromey.com>
11812
11813 * python/py-param.c (call_doc_function): Use gdbpy_ref.
11814
11815 2017-01-10 Tom Tromey <tom@tromey.com>
11816
11817 * python/py-linetable.c (build_line_table_tuple_from_pcs)
11818 (ltpy_get_all_source_lines): Use gdbpy_ref.
11819
11820 2017-01-10 Tom Tromey <tom@tromey.com>
11821
11822 * python/py-framefilter.c (extract_sym, extract_value)
11823 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
11824 gdbpy_ref.
11825
11826 2017-01-10 Tom Tromey <tom@tromey.com>
11827
11828 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
11829
11830 2017-01-10 Tom Tromey <tom@tromey.com>
11831
11832 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
11833
11834 2017-01-10 Tom Tromey <tom@tromey.com>
11835
11836 * python/py-function.c (convert_values_to_python, fnpy_init): Use
11837 gdbpy_ref.
11838
11839 2017-01-10 Tom Tromey <tom@tromey.com>
11840
11841 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
11842
11843 2017-01-10 Tom Tromey <tom@tromey.com>
11844
11845 * python/py-type.c (convert_field, make_fielditem, typy_fields)
11846 (typy_range): Use gdbpy_ref.
11847
11848 2017-01-10 Tom Tromey <tom@tromey.com>
11849
11850 * python/py-threadevent.c (create_thread_event_object): Use
11851 gdbpy_ref.
11852 * python/py-stopevent.c (create_stop_event_object): Simplify.
11853 (emit_stop_event): Use gdbpy_ref.
11854 * python/py-signalevent.c (create_signal_event_object): Use
11855 gdbpy_ref.
11856 * python/py-newobjfileevent.c (create_new_objfile_event_object)
11857 (emit_new_objfile_event, create_clear_objfiles_event_object)
11858 (emit_clear_objfiles_event): Use gdbpy_ref.
11859 * python/py-infevents.c (create_inferior_call_event_object)
11860 (create_register_changed_event_object)
11861 (create_memory_changed_event_object, emit_inferior_call_event)
11862 (emit_memory_changed_event, emit_register_changed_event): Use
11863 gdbpy_ref.
11864 * python/py-exitedevent.c (create_exited_event_object)
11865 (emit_exited_event): Use gdbpy_ref.
11866 * python/py-event.h (evpy_emit_event): Remove
11867 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
11868 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
11869 * python/py-continueevent.c (emit_continue_event): Use
11870 gdbpy_ref.
11871 * python/py-breakpoint.c (gdbpy_breakpoint_created)
11872 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
11873 gdbpy_ref.
11874 * python/py-bpevent.c (create_breakpoint_event_object): Use
11875 gdbpy_ref.
11876
11877 2017-01-10 Tom Tromey <tom@tromey.com>
11878
11879 * python/py-ref.h: New file.
11880
11881 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11882
11883 * cli-out.c (cli_ui_out::do_redirect): Change return type to
11884 void.
11885 * cli-out.h (cli_ui_out::do_redirect): Likewise.
11886 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
11887 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
11888 * ui-out.c (ui_out::redirect): Likewise.
11889 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
11890 * cli/cli-logging.c (set_logging_redirect): Update call site of
11891 ui_out::redirect.
11892 (handle_redirections): Likewise.
11893 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
11894 * top.c (execute_command_to_string): Likewise.
11895 * utils.c (do_ui_out_redirect_pop): Likewise.
11896
11897 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11898
11899 * stack.c (_initialize_stack): Update "frame" command help message.
11900
11901 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
11902
11903 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
11904
11905 2017-01-06 Yao Qi <yao.qi@linaro.org>
11906
11907 * x86-linux-nat.h: Include gdb_proc_service.h.
11908
11909 2017-01-06 Yao Qi <yao.qi@linaro.org>
11910
11911 * ser-base.h: Include serial.h.
11912
11913 2017-01-06 Yao Qi <yao.qi@linaro.org>
11914
11915 * ppc-linux-tdep.h: Include ppc-tdep.h.
11916
11917 2017-01-06 Yao Qi <yao.qi@linaro.org>
11918
11919 * nat/amd64-linux-siginfo.h: Include signal.h.
11920
11921 2017-01-06 Yao Qi <yao.qi@linaro.org>
11922
11923 * nat/aarch64-linux-hw-point.h: Include break-common.h.
11924
11925 2017-01-06 Yao Qi <yao.qi@linaro.org>
11926
11927 * mi/mi-parse.h: Include mi-cmds.h.
11928
11929 2017-01-06 Yao Qi <yao.qi@linaro.org>
11930
11931 * inf-loop.c: Don't include "target.h".
11932 * inf-loop.h: Include it here.
11933
11934 2017-01-06 Yao Qi <yao.qi@linaro.org>
11935
11936 * dfp.h: Include "dboulest.h" and "expression.h".
11937
11938 2017-01-06 Yao Qi <yao.qi@linaro.org>
11939
11940 * ax-gdb.h: Include "ax.h".
11941
11942 2017-01-06 Yao Qi <yao.qi@linaro.org>
11943
11944 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
11945 with nat/gdb_ptrace.h.
11946
11947 2017-01-05 Yao Qi <yao.qi@linaro.org>
11948
11949 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
11950 new line.
11951 (mips64_fbsd_sigframe_init): Likewise.
11952
11953 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11954
11955 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
11956 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
11957
11958 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11959
11960 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
11961 * NEWS: Mention new FreeBSD/mips native configuration.
11962 * config/mips/fbsd.mh: New file.
11963 * configure.host: Add mips*-*-freebsd*.
11964 * mips-fbsd-nat.c: New file.
11965
11966 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11967
11968 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
11969 (ALLDEPFILES): Add mips-fbsd-tdep.c.
11970 * NEWS: Mention new FreeBSD/mips target.
11971 * configure.tgt: Add mips*-*-freebsd*.
11972 * mips-fbsd-tdep.c: New file.
11973 * mips-fbsd-tdep.h: New file.
11974
11975 2017-01-04 Yao Qi <yao.qi@linaro.org>
11976
11977 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
11978 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
11979
11980 2017-01-01 Joel Brobecker <brobecker@adacore.com>
11981
11982 Update copyright year range in all GDB files.
11983
11984 2017-01-01 Joel Brobecker <brobecker@adacore.com>
11985
11986 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
11987
11988 For older changes see ChangeLog-2016.
11989 \f
11990 Local Variables:
11991 mode: change-log
11992 left-margin: 8
11993 fill-column: 74
11994 version-control: never
11995 coding: utf-8
11996 End:
This page took 0.28886 seconds and 5 git commands to generate.