6227a8e24477de51194d71fd48193b896e919a58
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-09-29 Tom Tromey <tom@tromey.com>
2
3 * symtab.c (search_symbols): Remove unused outer cleanup.
4 (make_source_files_completion_list): Remove unused declaration.
5
6 2017-09-29 Tom Tromey <tom@tromey.com>
7
8 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
9
10 2017-09-29 Tom Tromey <tom@tromey.com>
11
12 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
13 gdb::byte_vector.
14
15 2017-09-29 Tom Tromey <tom@tromey.com>
16
17 * complaints.c (vcomplaint): Use std::string.
18
19 2017-09-29 Tom Tromey <tom@tromey.com>
20
21 * tracepoint.c (trace_variable_command): Use std::string.
22 (encode_actions_1): Remove unused declarations.
23 (create_tsv_from_upload): Use std::string.
24
25 2017-09-29 Tom Tromey <tom@tromey.com>
26
27 * cp-support.c (gdb_demangle): Use std::string.
28
29 2017-09-29 Tom Tromey <tom@tromey.com>
30
31 * stack.c (parse_frame_specification): Use std::string
32 (info_frame_command): Use gdb::unique_xmalloc_ptr.
33
34 2017-09-29 Tom Tromey <tom@tromey.com>
35
36 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
37
38 2017-09-29 Tom Tromey <tom@tromey.com>
39
40 * utils.c (vfprintf_maybe_filtered): Use std::string.
41 (vfprintf_unfiltered): Likewise.
42
43 2017-09-29 Tom Tromey <tom@tromey.com>
44
45 * event-top.c (top_level_prompt): Return std::string.
46 (display_gdb_prompt): Update.
47
48 2017-09-29 Tom Tromey <tom@tromey.com>
49
50 * unittests/common-utils-selftests.c (format): New function.
51 (string_vprintf_tests): New function.
52 (_initialize_common_utils_selftests): Register new tests.
53 * common/common-utils.c (string_vprintf): New function.
54 * common/common-utils.h (string_vprintf): Declare.
55
56 2017-09-29 Pedro Alves <palves@redhat.com>
57
58 * common/rsp-low.c (unpack_varlen_hex): Constify.
59 * common/rsp-low.h (unpack_varlen_hex): Constify.
60 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
61 Constify.
62 * remote.c (remote_set_permissions, read_ptid)
63 (remote_current_thread, remote_get_threads_with_qthreadinfo)
64 (remote_static_tracepoint_marker_at)
65 (remote_static_tracepoint_markers_by_strid)
66 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
67 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
68 (parse_tracepoint_definition, parse_tsv_definition)
69 (parse_static_tracepoint_marker_definition): Constify.
70 * tracepoint.h (parse_static_tracepoint_marker_definition)
71 (parse_trace_status, parse_tracepoint_status)
72 (parse_tracepoint_definition, parse_tsv_definition): Constify.
73
74 2017-09-29 Pedro Alves <palves@redhat.com>
75
76 * remote.c (target_buf, target_buf_size): Delete.
77 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
78 Use the connection's packet buffer instead.
79 All callers adjusted.
80 (_initialize_remote): Remove references to target_buf and
81 target_buf_size.
82
83 2017-09-28 Pedro Alves <palves@redhat.com>
84
85 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
86 unittests/common-utils-selftests.c.
87 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
88 (COMMON_OBS): Remove utils-selftests.o.
89 * utils-selftests.c: Move to ...
90 * unittests/common-utils-selftests.c: ... here and rename self
91 test to "string_printf".
92
93 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
94
95 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
96 having NULL cus or tus.
97
98 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
99
100 * arm-tdep.c: (convert_from_extended): Remove.
101 (convert_to_extended): Likewise.
102 (arm_extract_return_value): Use convert_typed_floating.
103 (arm_store_return_value): Likewise.
104
105 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
106 * sh-tdep.c: Do not include "floatformat.h".
107 (sh_littlebyte_bigword_type): New function.
108 (sh_register_convert_to_virtual): Use convert_typed_floating.
109 (sh_register_convert_to_raw): Likewise.
110 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
111 (sh64_littlebyte_bigword_type): New function.
112 (sh64_extract_return_value): Use convert_typed_floating.
113 (sh64_register_convert_to_virtual): Likewise.
114 (sh64_register_convert_to_raw): Likewise.
115
116 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
117
118 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
119 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
120
121 * gdbtypes.h (union type_specific): Make field floatformat hold
122 just a single struct floatformat, not an array.
123 (floatformat_from_type): Move here.
124 * gdbtypes.c (floatformat_from_type): Move here. Update to
125 changed TYPE_FLOATFORMAT definition.
126 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
127 (recursive_dump_type): Likewise.
128 (init_float_type): Install correct floatformat for byte order.
129 (arch_float_type): Likewise.
130
131 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
132
133 * gdbtypes.c (init_type): Change incoming argument from
134 length-in-bytes to length-in-bits. Assert length is a
135 multiple of TARGET_CHAR_BITS.
136 (arch_type, arch_flags_type): Likewise.
137 (init_integer_type): Update call to init_type.
138 (init_character_type): Likewise.
139 (init_boolean_type): Likewise.
140 (init_float_type): Likewise.
141 (init_decfloat_type): Likewise.
142 (init_complex_type): Likewise.
143 (init_pointer_type): Likewise.
144 (objfile_type): Likewise.
145 (arch_integer_type): Update call to arch_type.
146 (arch_character_type): Likewise.
147 (arch_boolean_type): Likewise.
148 (arch_float_type): Likewise.
149 (arch_decfloat_type): Likewise.
150 (arch_complex_type): Likewise.
151 (arch_pointer_type): Likewise.
152 (gdbtypes_post_init): Likewise.
153
154 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
155 (read_base_type): Likewise.
156 * mdebugread.c (basic_type): Likewise.
157 * stabsread.c (dbx_init_float_type): Likewise.
158 (rs6000_builtin_type): Likewise.
159 (read_range_type): Likewise. Also, fix call to init_integer_type
160 with erroneous length argument.
161
162 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
163 * d-lang.c (build_d_types): Likewise.
164 * f-lang.c (build_fortran_types): Likewise.
165 * go-lang.c (build_go_types): Likewise.
166 * opencl-lang.c (build_opencl_types): Likewise.
167 * jit.c (finalize_symtab): Likewise.
168 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
169 (build_std_type_info_type): Likewise.
170 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
171 update call to arch_flags_type.
172
173 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
174 arch_type.
175 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
176 * windows-tdep.c (windows_get_tlb_type): Likewise.
177
178 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
179 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
180 * m32c-tdep.c (make_types): Likewise.
181 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
182 (rl78_psw_type): Update call to arch_flags_type.
183 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
184 * rx-tdep.c (rx_psw_type): Likewise.
185 (rx_fpsw_type): Likewise.
186 * sparc-tdep.c (sparc_psr_type): Likewise.
187 (sparc_fsr_type): Likewise.
188 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
189 (sparc64_ccr_type): Likewise.
190 (sparc64_fsr_type): Likewise.
191 (sparc64_fprs_type): Likewise.
192
193 2017-09-27 Tom Tromey <tom@tromey.com>
194
195 * findcmd.c (find_command): Constify.
196
197 2017-09-27 Tom Tromey <tom@tromey.com>
198
199 * ada-tasks.c (task_command_1, task_command): Constify.
200
201 2017-09-27 Tom Tromey <tom@tromey.com>
202
203 * symtab.c (maintenance_print_symbol_cache)
204 (maintenance_flush_symbol_cache)
205 (maintenance_print_symbol_cache_statistics): Constify.
206
207 2017-09-27 Tom Tromey <tom@tromey.com>
208
209 * inferior.c (detach_inferior_command, kill_inferior_command)
210 (inferior_command): Constify.
211
212 2017-09-27 Tom Tromey <tom@tromey.com>
213
214 * regcache.c (regcache_print, maintenance_print_registers)
215 (maintenance_print_raw_registers)
216 (maintenance_print_cooked_registers)
217 (maintenance_print_register_groups)
218 (maintenance_print_remote_registers): Constify.
219
220 2017-09-27 Tom Tromey <tom@tromey.com>
221
222 * printcmd.c (map_display_numbers, undisplay_command)
223 (enable_disable_display_command, enable_display_command)
224 (disable_display_command): Constify.
225
226 2017-09-27 Tom Tromey <tom@tromey.com>
227
228 * breakpoint.h (delete_command): Don't declare.
229 * breakpoint.c (delete_command, enable_once_command)
230 (enable_count_command, enable_delete_command, breakpoint_1)
231 (maintenance_info_breakpoints, stopin_command, stopat_command)
232 (delete_command, delete_trace_command, save_breakpoints)
233 (save_breakpoints_command, save_tracepoints_command): Constify.
234
235 2017-09-27 Tom Tromey <tom@tromey.com>
236
237 * macrocmd.c (macro_expand_command, macro_expand_once_command)
238 (skip_ws, extract_identifier, macro_define_command)
239 (macro_undef_command, macro_list_command): Constify.
240
241 2017-09-27 Tom Tromey <tom@tromey.com>
242
243 * infcmd.c (environment_info, set_environment_command)
244 (unset_environment_command, path_info, info_proc_cmd_1)
245 (info_proc_cmd_mappings, info_proc_cmd_stat)
246 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
247 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
248
249 2017-09-27 Tom Tromey <tom@tromey.com>
250
251 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
252 Constify.
253
254 2017-09-27 Tom Tromey <tom@tromey.com>
255
256 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
257
258 2017-09-27 Tom Tromey <tom@tromey.com>
259
260 * demangle.c (demangle_command): Constify.
261
262 2017-09-27 Tom Tromey <tom@tromey.com>
263
264 * progspace.c (maintenance_info_program_spaces_command):
265 Constify.
266
267 2017-09-27 Tom Tromey <tom@tromey.com>
268
269 * compile/compile.c (check_raw_argument, compile_file_command)
270 (compile_code_command, compile_print_command): Constify.
271
272 2017-09-27 Tom Tromey <tom@tromey.com>
273
274 * reggroups.c (maintenance_print_reggroups): Constify.
275
276 2017-09-27 Tom Tromey <tom@tromey.com>
277
278 * dwarf2read.c (save_gdb_index_command): Constify.
279
280 2017-09-27 Tom Tromey <tom@tromey.com>
281
282 * stap-probe.c (info_probes_stap_command): Constify.
283
284 2017-09-27 Tom Tromey <tom@tromey.com>
285
286 * fork-child.c (unset_exec_wrapper_command): Constify.
287
288 2017-09-27 Tom Tromey <tom@tromey.com>
289
290 * btrace.c (get_uint, get_context_size, no_chunk)
291 (maint_btrace_packet_history_cmd)
292 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
293 (maint_info_btrace_cmd): Constify.
294
295 2017-09-27 Tom Tromey <tom@tromey.com>
296
297 * reverse.c (delete_bookmark_command): Constify.
298
299 2017-09-27 Tom Tromey <tom@tromey.com>
300
301 * remote.c (set_memory_packet_size)
302 (set_memory_write_packet_size, show_memory_write_packet_size)
303 (set_memory_read_packet_size, show_memory_read_packet_size)
304 (compare_sections_command, packet_command, remote_put_command)
305 (remote_get_command, remote_delete_command): Constify.
306
307 2017-09-27 Tom Tromey <tom@tromey.com>
308
309 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
310 (set_mipsfpu_double_command, set_mipsfpu_none_command)
311 (set_mipsfpu_auto_command): Constify.
312
313 2017-09-27 Tom Tromey <tom@tromey.com>
314
315 * cli/cli-cmds.h (cd_command): Constify.
316 * cli/cli-cmds.c (cd_command): Constify.
317
318 2017-09-27 Tom Tromey <tom@tromey.com>
319
320 * thread.c (thread_name_command, thread_find_command): Constify.
321
322 2017-09-27 Tom Tromey <tom@tromey.com>
323
324 * probe.c (enable_probes_command, disable_probes_command):
325 Constify.
326
327 2017-09-27 Tom Tromey <tom@tromey.com>
328
329 * symfile.c (symbol_file_command): Constify.
330 * gdbcore.h (deprecated_file_changed_hook): Constify.
331 * exec.c (deprecated_file_changed_hook, exec_file_command)
332 (file_command): Constify.
333 * defs.h (symbol_file_command): Constify.
334
335 2017-09-27 Tom Tromey <tom@tromey.com>
336
337 * remote-fileio.c (set_system_call_allowed)
338 (show_system_call_allowed): Constify.
339
340 2017-09-27 Tom Tromey <tom@tromey.com>
341
342 * tracepoint.c (delete_trace_variable_command)
343 (tfind_end_command, tfind_start_command, tfind_pc_command)
344 (tfind_tracepoint_command, tfind_line_command)
345 (tfind_range_command, tfind_outside_command): Constify.
346
347 2017-09-27 Tom Tromey <tom@tromey.com>
348
349 * ax-gdb.c (maint_agent_printf_command, agent_command)
350 (agent_eval_command): Constify.
351
352 2017-09-27 Tom Tromey <tom@tromey.com>
353
354 * tracepoint.c (info_scope_command): Constify.
355 * python/python.c (gdbpy_decode_line): Constify.
356 * python/py-breakpoint.c (bppy_init): Constify.
357 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
358 * location.h: (new_linespec_location)
359 (string_to_event_location_basic, string_to_event_location):
360 Constify.
361 * location.c (new_linespec_location)
362 (string_to_event_location_basic, string_to_event_location):
363 Constify.
364 * linespec.h (decode_line_with_current_source)
365 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
366 * linespec.c (linespec_lex_to_end)
367 (decode_line_with_current_source)
368 (decode_line_with_last_displayed): Constify.
369 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
370 Constify.
371 * cli/cli-cmds.c (edit_command, list_command): Constify.
372 * breakpoint.h (until_break_command, watch_command_wrapper)
373 (awatch_command_wrapper, rwatch_command_wrapper)
374 (init_ada_exception_breakpoint): Constify.
375 * breakpoint.c (break_command_1, dprintf_command)
376 (break_range_command, watch_command_wrapper)
377 (rwatch_command_wrapper, awatch_command_wrapper)
378 (until_break_command, init_ada_exception_breakpoint)
379 (strace_marker_create_sals_from_location, trace_command)
380 (ftrace_command, strace_command, struct tracepoint): Constify.
381 * ax-gdb.c (agent_command_1): Constify.
382 * ada-lang.c (ada_exception_sal): Constify.
383
384 2017-09-27 Tom Tromey <tom@tromey.com>
385
386 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
387 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
388 (get_context_size, no_chunk, get_insn_history_modifiers)
389 (cmd_record_insn_history, get_call_history_modifiers)
390 (cmd_record_call_history): Constify.
391
392 2017-09-27 Tom Tromey <tom@tromey.com>
393
394 * source.c (show_substitute_path_command)
395 (unset_substitute_path_command, set_substitute_path_command):
396 Constify.
397
398 2017-09-27 Tom Tromey <tom@tromey.com>
399
400 * typeprint.c (maintenance_print_type): Constify.
401 * maint.c (maintenance_dump_me, maintenance_demangle)
402 (maintenance_time_display, maintenance_info_sections)
403 (maintenance_print_statistics, maintenance_deprecate)
404 (maintenance_undeprecate): Constify.
405 (maintenance_do_deprecate): Constify. Use std::string.
406 (maintenance_selftest): Constify.
407 * gdbtypes.h (maintenance_print_type): Constify.
408
409 2017-09-27 Tom Tromey <tom@tromey.com>
410
411 * hppa-tdep.c (unwind_command): Constify.
412
413 2017-09-27 Tom Tromey <tom@tromey.com>
414
415 * target-descriptions.c (unset_tdesc_filename_cmd)
416 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
417 Constify.
418
419 2017-09-27 Tom Tromey <tom@tromey.com>
420
421 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
422
423 2017-09-27 Tom Tromey <tom@tromey.com>
424
425 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
426
427 2017-09-27 Tom Tromey <tom@tromey.com>
428
429 * tui/tui-regs.c (tui_reg_command): Constify.
430
431 2017-09-27 Tom Tromey <tom@tromey.com>
432
433 * skip.c (skip_file_command, skip_function_command)
434 (skip_enable_command, skip_disable_command, skip_delete_command):
435 Constify.
436
437 2017-09-27 Tom Tromey <tom@tromey.com>
438
439 * record-btrace.c (cmd_record_btrace_bts_start)
440 (cmd_record_btrace_pt_start): Constify.
441
442 2017-09-27 Tom Tromey <tom@tromey.com>
443
444 * symmisc.c (maintenance_print_symbols)
445 (maintenance_print_msymbols, maintenance_print_objfiles)
446 (maintenance_info_symtabs, maintenance_check_symtabs)
447 (maintenance_expand_symtabs, maintenance_info_line_tables):
448 Constify.
449
450 2017-09-27 Tom Tromey <tom@tromey.com>
451
452 * top.c (new_ui_command): Constify.
453
454 2017-09-27 Tom Tromey <tom@tromey.com>
455
456 * symfile.c (add_symbol_file_command)
457 (remove_symbol_file_command, list_overlays_command)
458 (map_overlay_command, unmap_overlay_command)
459 (overlay_auto_command, overlay_manual_command)
460 (overlay_off_command, overlay_load_command): Constify.
461
462 2017-09-27 Tom Tromey <tom@tromey.com>
463
464 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
465 (info_spu_mailbox_command, info_spu_dma_command)
466 (info_spu_proxydma_command): Constify.
467
468 2017-09-27 Tom Tromey <tom@tromey.com>
469
470 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
471
472 2017-09-27 Tom Tromey <tom@tromey.com>
473
474 * cli/cli-script.c (user_defined_command): Constify.
475
476 2017-09-27 Tom Tromey <tom@tromey.com>
477
478 * cli/cli-dump.c (dump_memory_command, dump_value_command)
479 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
480 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
481 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
482 (dump_binary_value, append_binary_memory, append_binary_value):
483 Constify.
484 (struct dump_context) <func>: Constify.
485 (add_dump_command): Update.
486
487 2017-09-27 Tom Tromey <tom@tromey.com>
488
489 * cli/cli-cmds.c (show_version, show_configuration)
490 (source_command, show_user): Constify.
491
492 2017-09-27 Tom Tromey <tom@tromey.com>
493
494 * target.c (maintenance_print_target_stack): Constify.
495
496 2017-09-27 Tom Tromey <tom@tromey.com>
497
498 * interps.c (interpreter_exec_cmd): Constify.
499
500 2017-09-27 Tom Tromey <tom@tromey.com>
501
502 * record-full.c (cmd_record_full_restore): Constify.
503
504 2017-09-27 Tom Tromey <tom@tromey.com>
505
506 * memattr.c (enable_mem_command, disable_mem_command)
507 (delete_mem_command): Constify.
508
509 2017-09-27 Tom Tromey <tom@tromey.com>
510
511 * value.c (show_convenience): Constify.
512
513 2017-09-27 Tom Tromey <tom@tromey.com>
514
515 * gdbcore.h (core_file_command): Update.
516 * corefile.c (core_file_command): Constify.
517
518 2017-09-27 Tom Tromey <tom@tromey.com>
519
520 * user-regs.c (maintenance_print_user_registers): Constify.
521
522 2017-09-27 Tom Tromey <tom@tromey.com>
523
524 * cp-namespace.c (maintenance_cplus_namespace): Constify.
525
526 2017-09-27 Tom Tromey <tom@tromey.com>
527
528 * cp-support.c (first_component_command): Constify.
529
530 2017-09-27 Tom Tromey <tom@tromey.com>
531
532 * psymtab.c (maintenance_print_psymbols)
533 (maintenance_info_psymtabs, maintenance_check_psymtabs):
534 Constify.
535
536 2017-09-27 Tom Tromey <tom@tromey.com>
537
538 * windows-tdep.c (display_tib): Constify.
539
540 2017-09-27 Tom Tromey <tom@tromey.com>
541
542 * linux-fork.c (delete_checkpoint_command)
543 (detach_checkpoint_command): Constify.
544
545 2017-09-27 Tom Tromey <tom@tromey.com>
546
547 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
548
549 2017-09-27 Tom Tromey <tom@tromey.com>
550
551 * arc-tdep.c (dump_arc_instruction_command): Constify.
552
553 2017-09-27 Tom Tromey <tom@tromey.com>
554
555 * valprint.c (set_radix, show_radix): Constify.
556
557 2017-09-27 Tom Tromey <tom@tromey.com>
558
559 * dtrace-probe.c (info_probes_dtrace_command): Constify.
560
561 2017-09-27 Tom Tromey <tom@tromey.com>
562
563 * command.h (not_just_help_class_command): Update.
564 * cli/cli-decode.h (not_just_help_class_command): Update.
565 * cli/cli-decode.c (not_just_help_class_command): Constify.
566
567 2017-09-27 Tom Tromey <tom@tromey.com>
568
569 * gdb_bfd.c (maintenance_info_bfds): Constify.
570
571 2017-09-27 Tom Tromey <tom@tromey.com>
572
573 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
574 overloads.
575 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
576 (do_const_cfunc): New function.
577 (cmd_cfunc_eq): New overload.
578 (cli_user_command_p): Check do_const_cfunc.
579 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
580 const_cfunc.
581 * command.h (add_cmd): Add const overload and no-function
582 overload.
583 (set_cmd_cfunc): Add const overload.
584 (cmd_const_cfunc_ftype): Declare.
585 (cmd_cfunc_eq): Add const overload.
586 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
587 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
588 overload.
589
590 2017-09-27 Tom Tromey <tom@tromey.com>
591
592 * macroexp.c (get_next_token_for_substitution): New function.
593 (substitute_args): Call it. Check for __VA_OPT__.
594
595 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
596 Pedro Alves <palves@redhat.com>
597
598 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
599 producer_is_icc_lt_14.
600 (producer_is_icc_lt_14): New function.
601 (check_producer): Add code for checking version of ICC.
602 (producer_is_icc): Move to producer.c.
603 (read_structure_type): Restrict ICC workaround to ICC<14.
604 * producer.c: Include selftest.h.
605 (producer_is_icc, producer_parsing_tests, _initialize_producer):
606 New functions.
607 * producer.h (producer_is_icc): New declaration.
608
609 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
610
611 * Makefile.in (SFILES): Add producer.c.
612 (COMMON_OBS): Add producer.o
613 * amd64-tdep.c (producer.h): Add new include.
614 * dwarf2read.c (producer.h): Add new include.
615 * producer.c: New file.
616 * producer.h: New file.
617 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
618 producer.c.
619 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
620 producer.h.
621
622 2017-09-26 Matthias Klose <doko@ubuntu.com>
623
624 * configure.ac: Search ncursesw before ncurses.
625 Check ncursesw/ncurses.h before ncurses/ncurses.h.
626 * gdb_curses.h: Include <ncursesw/ncurses.h>
627 * config.in, configure: Regenerate.
628
629 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
630
631 PR gdb/22185
632 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
633 obsolete.
634 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
635 Remove i386sol2 support.
636 * configure.nat <i386sol2>: Remove.
637 <sol2-64>: Fold into ...
638 <sol2>: ... this.
639 Move common settings to default section.
640 Add sol-thread.o.
641 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
642 x86_64-*-solaris2.1[0-9]*>: Rename to ...
643 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
644 <i[34567]86-*-solaris*>: Remove.
645 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
646
647 * configure.ac: Remove wctype in libw check.
648 (_MSE_INT_H): Don't define on Solaris 7-9.
649 <solaris*>: Remove libthread_db.so.1 check.
650 * configure: Regenerate.
651 * config.in: Regenerate.
652
653 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
654 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
655 (gdb_ps_size_t): Remove.
656 Use base types in users.
657 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
658
659 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
660
661 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
662
663 PR build/22206
664 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
665 (adi_is_addr_mapped): Likewise.
666 (PSR_ICC): Don't redefine.
667 (PSR_IMPL): Likewise.
668
669 2017-09-25 Tom Tromey <tom@tromey.com>
670
671 * regcache.c (regcache::dump): Use string_printf.
672
673 2017-09-25 Tom Tromey <tom@tromey.com>
674
675 * regcache.c (class regcache_invalidator): New.
676 (struct register_to_invalidate): Remove.
677 (make_cleanup_regcache_invalidate): Remove.
678 (regcache::raw_write): Use regcache_invalidator.
679
680 2017-09-25 Tom Tromey <tom@tromey.com>
681
682 * spu-tdep.c (spu2ppu_sniffer): Update.
683 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
684 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
685 Remove.
686 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
687 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
688 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
689 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
690 (frame_pop): Update.
691
692 2017-09-25 Tom Tromey <tom@tromey.com>
693
694 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
695 * regcache.h (regcache_xfree): Don't declare.
696 * regcache.c (regcache_xfree): Remove.
697 (do_regcache_xfree): Use delete.
698 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
699 * linux-fork.c (free_fork): Use delete.
700 (fork_save_infrun_state): Likewise.
701 * jit.c (jit_dealloc_cache): Use delete.
702 * infrun.c (discard_infcall_suspend_state): Use delete.
703
704 2017-09-25 Tom Tromey <tom@tromey.com>
705
706 * regcache.h (regcache_xmalloc): Don't declare.
707 (regcache_raw_set_cached_value): Update comment.
708 * regcache.c (regcache_xmalloc): Remove.
709 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
710 * jit.c (jit_frame_sniffer): Use new.
711 * frame.c (frame_save_as_regcache): Use new.
712
713 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
714
715 * NEWS: Advertise support for guarded-storage registers on IBM z.
716
717 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
718
719 * s390-linux-nat.c (have_regset_gs): New static variable.
720 (s390_linux_fetch_inferior_registers): Handle guarded-storage
721 control block and guarded-storage broadcast control regsets.
722 (s390_read_description): Detect whether the target has
723 guarded-storage support, return appropriate tdesc.
724 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
725 (features/s390x-gs-linux64.c): Likewise.
726 (struct gdbarch_tdep) <have_gs>: New field.
727 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
728 (s390_gsbc_regset): New variables.
729 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
730 and s390_gsbc_regset, if applicable.
731 (s390_core_read_description): Check whether core file was from a
732 target with guarded-storage support; include appropriate regsets.
733 (s390_gdbarch_init): Add registers for guarded-storage support.
734 (_initialize_s390_tdep): Initialize new target descriptions that
735 include registers for guarded-storage support.
736 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
737 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
738 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
739 (S390_NUM_REGS): Adjust macro definition.
740 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
741 (tdesc_s390x_gs_linux64): New declarations.
742
743 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
744
745 * features/s390-gs-linux64.xml: New file.
746 * features/s390-gs.xml: New file.
747 * features/s390-gsbc.xml: New file.
748 * features/s390x-gs-linux64.xml: New file.
749 * features/Makefile (WHICH): Add s390-gs-linux64 and
750 s390x-gs-linux64.
751 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
752 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
753 * features/s390-gs-linux64.c: New generated file.
754 * features/s390x-gs-linux64.c: New file.
755 * regformats/s390-gs-linux64.dat: New file.
756 * regformats/s390x-gs-linux64.dat: New file.
757
758 2017-09-23 Tom Tromey <tom@tromey.com>
759
760 * defs.h (make_cleanup_override_quit_handler): Don't declare.
761
762 2017-09-22 Tom Tromey <tom@tromey.com>
763
764 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
765 type to scoped_restore_tmpl.
766 <scoped_input_handler>: Initialize m_quit_handler directly.
767
768 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
769
770 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
771 (cd_command): Likewise. Free "current_directory" before
772 assigning to it.
773 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
774 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
775 * top.c (gdb_dirbuf): Remove global declaration.
776 * top.h (gdb_dirbuf): Likewise.
777
778 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
779
780 * gnulib/aclocal.m4: Regenerate.
781 * gnulib/config.in: Regenerate.
782 * gnulib/configure: Regenerate.
783 * gnulib/import/Makefile.am: Regenerate.
784 * gnulib/import/Makefile.in: Regenerate.
785 * gnulib/import/assure.h: New file.
786 * gnulib/import/at-func.c: Likewise
787 * gnulib/import/chdir-long.c: New file.
788 * gnulib/import/chdir-long.h: New file.
789 * gnulib/import/cloexec.c: New file.
790 * gnulib/import/cloexec.h: New file.
791 * gnulib/import/close.c: New file.
792 * gnulib/import/closedir.c: New file.
793 * gnulib/import/dirent-private.h: New file.
794 * gnulib/import/dup-safer.c: New file.
795 * gnulib/import/dup.c: New file.
796 * gnulib/import/dup2.c: New file.
797 * gnulib/import/error.c: New file.
798 * gnulib/import/error.h: New file.
799 * gnulib/import/exitfail.c: New file.
800 * gnulib/import/exitfail.h: New file.
801 * gnulib/import/fchdir.c: New file.
802 * gnulib/import/fcntl.c: New file.
803 * gnulib/import/fcntl.in.h: New file.
804 * gnulib/import/fd-hook.c: New file.
805 * gnulib/import/fd-hook.h: New file.
806 * gnulib/import/fd-safer.c: New file.
807 * gnulib/import/fdopendir.c: New file.
808 * gnulib/import/filename.h: New file.
809 * gnulib/import/filenamecat-lgpl.c: New file.
810 * gnulib/import/filenamecat.h: New file.
811 * gnulib/import/fstat.c: New file.
812 * gnulib/import/fstatat.c: New file.
813 * gnulib/import/getcwd-lgpl.c: New file.
814 * gnulib/import/getcwd.c: New file.
815 * gnulib/import/getdtablesize.c: New file.
816 * gnulib/import/getlogin_r.c: New file.
817 * gnulib/import/getprogname.c: New file.
818 * gnulib/import/getprogname.h: New file.
819 * gnulib/import/gettext.h: New file.
820 * gnulib/import/glob-libc.h: New file.
821 * gnulib/import/glob.c: New file.
822 * gnulib/import/glob.in.h: New file.
823 * gnulib/import/intprops.h: New file.
824 * gnulib/import/m4/chdir-long.m4: New file.
825 * gnulib/import/m4/close.m4: New file.
826 * gnulib/import/m4/closedir.m4: New file.
827 * gnulib/import/m4/d-ino.m4: New file.
828 * gnulib/import/m4/d-type.m4: New file.
829 * gnulib/import/m4/dup.m4: New file.
830 * gnulib/import/m4/dup2.m4: New file.
831 * gnulib/import/m4/error.m4: New file.
832 * gnulib/import/m4/fchdir.m4: New file.
833 * gnulib/import/m4/fcntl.m4: New file.
834 * gnulib/import/m4/fcntl_h.m4: New file.
835 * gnulib/import/m4/fdopendir.m4: New file.
836 * gnulib/import/m4/filenamecat.m4: New file.
837 * gnulib/import/m4/fstat.m4: New file.
838 * gnulib/import/m4/fstatat.m4: New file.
839 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
840 * gnulib/import/m4/getcwd-path-max.m4: New file.
841 * gnulib/import/m4/getcwd.m4: New file.
842 * gnulib/import/m4/getdtablesize.m4: New file.
843 * gnulib/import/m4/getlogin_r.m4: New file.
844 * gnulib/import/m4/getprogname.m4: New file.
845 * gnulib/import/m4/glob.m4: New file.
846 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
847 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
848 * gnulib/import/m4/mempcpy.m4: New file.
849 * gnulib/import/m4/memrchr.m4: New file.
850 * gnulib/import/m4/mode_t.m4: New file.
851 * gnulib/import/m4/msvc-inval.m4: New file.
852 * gnulib/import/m4/msvc-nothrow.m4: New file.
853 * gnulib/import/m4/open.m4: New file.
854 * gnulib/import/m4/openat.m4: New file.
855 * gnulib/import/m4/opendir.m4: New file.
856 * gnulib/import/m4/readdir.m4: New file.
857 * gnulib/import/m4/realloc.m4: New file.
858 * gnulib/import/m4/rewinddir.m4: New file.
859 * gnulib/import/m4/save-cwd.m4: New file.
860 * gnulib/import/m4/strdup.m4: New file.
861 * gnulib/import/m4/strerror.m4: New file.
862 * gnulib/import/m4/unistd-safer.m4: New file.
863 * gnulib/import/mempcpy.c: New file.
864 * gnulib/import/memrchr.c: New file.
865 * gnulib/import/msvc-inval.c: New file.
866 * gnulib/import/msvc-inval.h: New file.
867 * gnulib/import/msvc-nothrow.c: New file.
868 * gnulib/import/msvc-nothrow.h: New file.
869 * gnulib/import/open.c: New file.
870 * gnulib/import/openat-die.c: New file.
871 * gnulib/import/openat-priv.h: New file.
872 * gnulib/import/openat-proc.c: New file.
873 * gnulib/import/openat.c: New file.
874 * gnulib/import/openat.h: New file.
875 * gnulib/import/opendir.c: New file.
876 * gnulib/import/pipe-safer.c: New file.
877 * gnulib/import/readdir.c: New file.
878 * gnulib/import/realloc.c: New file.
879 * gnulib/import/rewinddir.c: New file.
880 * gnulib/import/save-cwd.c: New file.
881 * gnulib/import/save-cwd.h: New file.
882 * gnulib/import/strdup.c: New file.
883 * gnulib/import/strerror-override.c: New file.
884 * gnulib/import/strerror-override.h: New file.
885 * gnulib/import/strerror.c: New file.
886 * gnulib/import/unistd--.h: New file.
887 * gnulib/import/unistd-safer.h: New file.
888 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
889 "getcwd" and "glob".
890 * ser-tcp.c: Undefine "close" before redefining it.
891
892 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
893
894 * guile/scm-value.c (gdbscm_value_address): Initialize address,
895 get rid of res_val.
896
897 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
898
899 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
900 <sol2,sparc>: Likewise.
901 <sol2-64,i386>: Likewise.
902
903 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
904 -Wdeprecated-declarations on *-*-solaris*.
905 * configure: Regenerate.
906
907 * procfs.c: Include "nat/inferior.h".
908 (procfs_info_proc): Fix typo.
909
910 2017-09-21 Kevin Buettner <kevinb@redhat.com>
911
912 * remote.c (vector): Include.
913 (struct private_thread_info): Add field, thread_handle.
914 (free_private_thread_info): Deallocate storage associated with
915 thread handle.
916 (get_private_info_thread): Initialize `thread_handle' field.
917 (struct thread_item): Add field, thread_handle.
918 (clear_threads_listing_context): Deallocate storage associated
919 with thread handle.
920 (start_thread): Add support for "handle" attribute.
921 (thread_attributes): Add "handle".
922 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
923 field.
924 (remote_update_thread_list): Update thread_handle.
925 (remote_thread_handle_to_thread_info): New function.
926 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
927
928 2017-09-21 Kevin Buettner <kevinb@redhat.com>
929
930 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
931 function.
932 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
933 * python/python-internal.h (thread_object_type): Declare.
934
935 2017-09-21 Kevin Buettner <kevinb@redhat.com>
936
937 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
938 (target_thread_handle_to_thread_info): Declare.
939 * target.c (target_thread_handle_to_thread_info): New function.
940 * target-delegates.c: Regenerate.
941 * gdbthread.h (find_thread_by_handle): Declare.
942 * thread.c (find_thread_by_handle): New function.
943 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
944 function.
945 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
946
947 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
948
949 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
950
951 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
952
953 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
954
955 2017-09-21 Yao Qi <yao.qi@linaro.org>
956
957 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
958 to gdb_target_obs.
959
960 2017-09-20 Tom Tromey <tom@tromey.com>
961
962 * breakpoint.c (struct counted_command_line): Remove.
963 (breakpoint_commands): Update.
964 (alloc_counted_command_line, incref_counted_command_line)
965 (decref_counted_command_line, do_cleanup_counted_command_line)
966 (make_cleanup_decref_counted_command_line): Remove.
967 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
968 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
969 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
970 (save_breakpoints): Update.
971 * breakpoint.h (counted_command_line): Now a typedef to
972 shared_ptr.
973 (struct breakpoint) <commands>: Now a counted_command_line.
974 (struct bpstats) <command>: Likewise.
975
976 2017-09-20 Tom Tromey <tom@tromey.com>
977
978 * breakpoint.c (struct commands_info, do_map_commands_command):
979 Remove.
980 (commands_command_1): Update.
981 (iterate_over_related_breakpoints): Take a function_view.
982 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
983 (delete_command): Update.
984 (map_breakpoint_numbers): Take a function_view.
985 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
986 (disable_command): Update.
987 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
988 (enable_command): Update.
989 (struct disp_data, do_enable_breakpoint_disp)
990 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
991 (do_map_enable_delete_breakpoint): Remove.
992 (enable_once_command, enable_count_command, enable_delete_command)
993 (delete_trace_variable_command): Update.
994
995 2017-09-20 Tom Tromey <tom@tromey.com>
996
997 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
998 (bpstat_clear): Use delete.
999 (bpstats): New constructors.
1000 (bpstat_copy, bpstat_stop_status): Use new.
1001 (dprintf_after_condition_true): Update.
1002 * breakpoint.h (bpstats::bpstats): Add constructors.
1003 (bpstats::~bpstats): Add destructor.
1004
1005 2017-09-20 Pedro Alves <palves@redhat.com>
1006
1007 * eval.c (make_params): Delete, refactored as ...
1008 (class fake_method): ... this new type's ctor.
1009 (fake_method::~fake_method): New.
1010 (evaluate_subexp_standard): Use 'fake_method'.
1011
1012 2017-09-20 Tom Tromey <tom@tromey.com>
1013
1014 * windows-nat.c (get_windows_debug_event, windows_wait)
1015 (do_initial_windows_stuff, windows_attach): Update.
1016 * utils.c (vwarning, internal_vproblem): Update.
1017 (ui_unregister_input_event_handler_cleanup)
1018 (prepare_to_handle_input): Remove.
1019 (class scoped_input_handler): New.
1020 (defaulted_query, prompt_for_continue): Update.
1021 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
1022 Update.
1023 * top.c (undo_terminal_modifications_before_exit): Update.
1024 * target/target.h (target_terminal_init, target_terminal_inferior)
1025 (target_terminal_ours): Don't declare.
1026 (class target_terminal): New.
1027 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
1028 (target_terminal_ours_for_output)
1029 (make_cleanup_restore_target_terminal): Don't declare.
1030 (target_terminal_info): Remove.
1031 * target.c (enum terminal_state, terminal_state): Remove.
1032 (target_terminal::terminal_state): Define.
1033 (target_terminal::init): Rename from target_terminal_init.
1034 (target_terminal::inferior): Rename from
1035 target_terminal_inferior.
1036 (target_terminal::ours): Rename from target_terminal_ours.
1037 (target_terminal::ours_for_output): Rename from
1038 target_terminal_ours_for_output.
1039 (target_terminal::info): New method.
1040 (cleanup_restore_target_terminal)
1041 (make_cleanup_restore_target_terminal): Remove.
1042 * solib.c (handle_solib_event): Update.
1043 * remote.c (remote_serial_quit_handler): Update.
1044 (remote_terminal_inferior, remote_wait_as): Update.
1045 * record-full.c (record_full_wait_1): Update.
1046 * nto-procfs.c (procfs_create_inferior): Update.
1047 * nat/fork-inferior.c (startup_inferior): Update.
1048 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
1049 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
1050 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
1051 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
1052 (mi_breakpoint_created, mi_breakpoint_deleted)
1053 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
1054 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
1055 (mi_user_selected_context_changed, report_initial_inferior):
1056 Update.
1057 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
1058 (linux_nat_terminal_inferior): Update.
1059 * infrun.c (follow_fork_inferior)
1060 (handle_vfork_child_exec_or_exit, do_target_resume)
1061 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
1062 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
1063 Update.
1064 * inflow.c (child_terminal_init, info_terminal_command): Update.
1065 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
1066 (attach_command): Update.
1067 * infcall.c (call_thread_fsm_should_stop): Update.
1068 * gnu-nat.c (gnu_attach): Update.
1069 * extension.c (struct active_ext_lang_state)
1070 (restore_active_ext_lang): Update.
1071 * exceptions.c (print_flush): Update.
1072 * event-top.c (async_enable_stdin, default_quit_handler): Update.
1073 (struct quit_handler_cleanup_data, restore_quit_handler)
1074 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
1075 Remove.
1076 * cp-support.c (gdb_demangle): Update.
1077 * breakpoint.c (update_inserted_breakpoint_locations)
1078 (insert_breakpoint_locations, handle_jit_event)
1079 (disable_breakpoints_in_unloaded_shlib): Update.
1080 * annotate.c (annotate_breakpoints_invalid)
1081 (annotate_frames_invalid): Update.
1082
1083 2017-09-20 Tom Tromey <tom@tromey.com>
1084
1085 * main.c (catch_command_errors): Rename from
1086 catch_command_errors_const.
1087 (captured_main_1): Update.
1088
1089 2017-09-20 Pedro Alves <palves@redhat.com>
1090
1091 * cli/cli-cmds.c (list_command): Use print_sal_location.
1092 (print_sal_location): New function.
1093 (ambiguous_line_spec): Use print_sal_location.
1094 * linespec.c (symbol_to_sal): Record the symbol in the sal.
1095 * symtab.c (find_function_start_sal): Likewise.
1096 * symtab.h (symtab_and_line::symbol): New field.
1097
1098 2017-09-20 Pedro Alves <palves@redhat.com>
1099
1100 * linespec.c (minsym_found): Handle non-text minsyms.
1101 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
1102
1103 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1104
1105 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
1106 backslash.
1107
1108 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1109
1110 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
1111 vmovups instead vmovaps.
1112 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
1113
1114 2017-09-19 John Baldwin <jhb@FreeBSD.org>
1115
1116 * NEWS (Changes since GDB 8.0): Add starti.
1117 * infcmd.c (enum run_break): New.
1118 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
1119 case.
1120 (run_command): Use enum run_how.
1121 (start_command): Likewise.
1122 (starti_command): New function.
1123 (RUN_ARGS_HELP): New macro.
1124 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
1125 commands. Add starti command.
1126
1127 2017-09-19 Yao Qi <yao.qi@linaro.org>
1128
1129 * Makefile.in (monitor.o): Remove the rule.
1130
1131 2017-09-19 Yao Qi <yao.qi@linaro.org>
1132
1133 * annotate.h (struct annotate_arg_emitter): Use
1134 DISABLE_COPY_AND_ASSIGN.
1135 * common/refcounted-object.h (refcounted_object): Likewise.
1136 * completer.h (struct completion_result): Likewise.
1137 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
1138 * filename-seen-cache.h (filename_seen_cache): Likewise.
1139 * gdbcore.h (thread_section_name): Likewise.
1140 * gdb_regex.h (compiled_regex): Likewise.
1141 * gdbthread.h (scoped_restore_current_thread): Likewise.
1142 * inferior.h (scoped_restore_current_inferior): Likewise.
1143 * jit.c (jit_reader): Likewise.
1144 * linespec.h (struct linespec_result): Likewise.
1145 * mi/mi-parse.h (struct mi_parse): Likewise.
1146 * nat/fork-inferior.c (execv_argv): Likewise.
1147 * progspace.h (scoped_restore_current_program_space): Likewise.
1148 * python/python-internal.h (class gdbpy_enter): Likewise.
1149 * regcache.h (regcache): Likewise.
1150 * target-descriptions.c (struct tdesc_reg): Likewise.
1151 (struct tdesc_type): Likewise.
1152 (struct tdesc_feature): Likewise.
1153 * ui-out.h (ui_out_emit_type): Likewise.
1154
1155 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
1156
1157 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
1158 label abort_expression.
1159
1160 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1161
1162 * common/buffer.c (buffer_xml_printf): Adjust.
1163 * common/xml-utils.c (xml_escape_text): Change return type to
1164 std::string, update code accordingly.
1165 * common/xml-utils.h (xml_escape_text): Change return type to
1166 std::string.
1167 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
1168 * windows-tdep.c (windows_xfer_shared_library): Adjust.
1169 * unittests/xml-utils-selftests.c (test_xml_escape_text):
1170 Adjust.
1171
1172 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1173
1174 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
1175 (SUBDIR_UNITTESTS_OBS): Add new object file.
1176 * unittests/xml-utils-selftests.c: New file.
1177
1178 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1179
1180 * common/selftest.h (selftest): New struct/interface.
1181 (register_test): Add name parameter, add new overload.
1182 (run_tests): Add filter parameter.
1183 (for_each_selftest_ftype): New typedef.
1184 (for_each_selftest): New declaration.
1185 * common/selftest.c (tests): Change type to
1186 map<string, unique_ptr<selftest>>.
1187 (simple_selftest): New struct.
1188 (register_test): New function.
1189 (register_test): Add name parameter and use it.
1190 (run_tests): Add filter parameter and use it. Add prints.
1191 Adjust to vector -> map change.
1192 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
1193 registering selftests.
1194 * arm-tdep.c (_initialize_arm_tdep): Likewise.
1195 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
1196 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
1197 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
1198 * findvar.c (_initialize_findvar): Likewise.
1199 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
1200 * maint.c (maintenance_selftest): Update call to run_tests.
1201 (maintenance_info_selftests): New function.
1202 (_initialize_maint_cmds): Register "maintenance info selftests"
1203 command. Update "maintenance selftest" doc.
1204 * regcache.c (_initialize_regcache): Add names when registering
1205 selftests.
1206 * rust-exp.y (_initialize_rust_exp): Likewise.
1207 * selftest-arch.c (gdbarch_selftest): New struct.
1208 (gdbarch_tests): Remove.
1209 (register_test_foreach_arch): Add name parameter. Call
1210 register_test.
1211 (tests_with_arch): Remove, move most content to
1212 gdbarch_selftest::operator().
1213 (_initialize_selftests_foreach_arch): Remove.
1214 * selftest-arch.h (register_test_foreach_arch): Add name
1215 parameter.
1216 (run_tests_with_arch): New declaration.
1217 * utils-selftests.c (_initialize_utils_selftests): Add names
1218 when registering selftests.
1219 * utils.c (_initialize_utils): Likewise.
1220 * unittests/array-view-selftests.c
1221 (_initialize_array_view_selftests): Likewise.
1222 * unittests/environ-selftests.c (_initialize_environ_selftests):
1223 Likewise.
1224 * unittests/function-view-selftests.c
1225 (_initialize_function_view_selftests): Likewise.
1226 * unittests/offset-type-selftests.c
1227 (_initialize_offset_type_selftests): Likewise.
1228 * unittests/optional-selftests.c
1229 (_initialize_optional_selftests): Likewise.
1230 * unittests/scoped_restore-selftests.c
1231 (_initialize_scoped_restore_selftests): Likewise.
1232 * NEWS: Document "maintenance selftest" and "maint info
1233 selftests".
1234
1235 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1236
1237 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
1238 scoped_restore.
1239
1240 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1241
1242 * mi/mi-main.c (mi_load_progress): Make uiout variable
1243 a unique_ptr.
1244
1245 2017-09-15 Pedro Alves <palves@redhat.com>
1246
1247 * compile/compile-c-types.c (convert_enum, convert_int)
1248 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
1249
1250 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1251
1252 * dwarf2read.c (copy_string): Remove.
1253 (parse_macro_definition): Replace copy_string with savestring.
1254
1255 2017-09-15 Yao Qi <yao.qi@linaro.org>
1256
1257 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
1258 gdb_target_obs.
1259 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
1260 Likewise.
1261 (i[34567]86-*-linux*): Likewise.
1262
1263 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1264
1265 * dwarf2expr.h (dwarf_stack_value): Add constructor.
1266 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
1267 <stack>: Change type to std::vector.
1268 <stack_len, stack_allocated>: Remove.
1269 <grow_stack>: Remove.
1270 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1271 (dwarf_expr_context::~dwarf_expr_context): Remove.
1272 (dwarf_expr_context::grow_stack): Remove.
1273 (dwarf_expr_context::push): Adjust.
1274 (dwarf_expr_context::pop): Adjust.
1275 (dwarf_expr_context::fetch): Adjust.
1276 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
1277 (dwarf_expr_context::stack_empty_p): Adjust.
1278 (dwarf_expr_context::execute_stack_op): Adjust.
1279
1280 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1281
1282 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
1283 return type to bool.
1284 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
1285
1286 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1287
1288 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
1289 Change type to bool.
1290 (dwarf_stack_value) <in_stack_memory>: Likewise.
1291 (dwarf_expr_context) <push_address>: Change parameter type to
1292 bool.
1293 <fetch_in_stack_memory>: Change return type to bool.
1294 <push>: Change parameter type to bool.
1295 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
1296 to bool.
1297 (dwarf_expr_context::push_address): Likewise.
1298 (dwarf_expr_context::fetch_in_stack_memory): Change return type
1299 to bool.
1300 (dwarf_expr_context::execute_stack_op): Adjust.
1301 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
1302
1303 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1304
1305 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
1306 (struct dwarf_expr_context) <n_pieces>: Remove.
1307 <pieces>: Change type to std::vector.
1308 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1309 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
1310 pieces.
1311 (dwarf_expr_context::add_piece): Adjust.
1312 * dwarf2loc.c (struct piece_closure): Initialize fields.
1313 <n_pieces>: Remove.
1314 <pieces>: Change type to std::vector.
1315 (allocate_piece_closure): Adjust, change parameter to
1316 std::vector rvalue and std::move it to piece_closure.
1317 (rw_pieced_value): Adjust.
1318 (check_pieced_synthetic_pointer): Adjust.
1319 (indirect_synthetic_pointer): Adjust.
1320 (coerce_pieced_ref): Adjust.
1321 (free_pieced_value_closure): Adjust. Use delete to free
1322 piece_closure.
1323 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
1324 to allocate_piece_closure.
1325 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
1326
1327 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1328
1329 * probe.h (probe_ops_cp): Remove typedef.
1330 (DEF_VEC_P (probe_ops_cp)): Remove.
1331 (all_probe_ops): Change type to std::vector.
1332 * probe.c (info_probes_for_ops): Adjust to vector change.
1333 (probe_linespec_to_ops): Likewise.
1334 (all_probe_ops): Change type to std::vector.
1335 (_initialize_probe): Adjust to vector change.
1336 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
1337 * elfread.c (elf_get_probes): Likewise.
1338 * stap-probe.c (_initialize_stap_probe): Likewise.
1339
1340 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1341
1342 * probe.h (struct bound_probe): Define constructors.
1343 * probe.c (bound_probe_s): Remove typedef.
1344 (DEF_VEC_O (bound_probe_s)): Remove VEC.
1345 (collect_probes): Change return type to std::vector, remove
1346 cleanup.
1347 (compare_probes): Return bool, change parameter type. Change
1348 semantic to "less than".
1349 (gen_ui_out_table_header_info): Change parameter to std::vector
1350 and update.
1351 (exists_probe_with_pops): Likewise.
1352 (info_probes_for_ops): Update to std::vector change.
1353 (enable_probes_command): Likewise.
1354 (disable_probes_command): Likewise.
1355
1356 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1357
1358 * probe.h (struct probe_ops) <get_probes>: Change parameter from
1359 vec to std::vector.
1360 * probe.c (parse_probes_in_pspace): Update.
1361 (find_probes_in_objfile): Update.
1362 (find_probe_by_pc): Update.
1363 (collect_probes): Update.
1364 (probe_any_get_probes): Update.
1365 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
1366 return type to reference to std::vector.
1367 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
1368 std::vector and update.
1369 (dtrace_process_dof): Likewise.
1370 (dtrace_get_probes): Likewise.
1371 * elfread.c (elf_get_probes): Change return type to std::vector,
1372 store an std::vector in bfd_data.
1373 (probe_key_free): Update to std::vector.
1374 * stap-probe.c (handle_stap_probe): Change parameter to
1375 std::vector and update.
1376 (stap_get_probes): Likewise.
1377 * symfile-debug.c (debug_sym_get_probes): Change return type to
1378 std::vector and update.
1379
1380 2017-09-11 Tom Tromey <tom@tromey.com>
1381
1382 * breakpoint.c (program_breakpoint_here_p): Update.
1383 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
1384 from make_show_memory_breakpoints_cleanup. Return a
1385 scoped_restore_tmpl<int>.
1386 (restore_show_memory_breakpoints): Remove.
1387 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
1388 * mem-break.c (memory_validate_breakpoint): Update.
1389 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
1390 (ia64_memory_remove_breakpoint): Update.
1391 (ia64_breakpoint_from_pc): Update.
1392 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
1393 from make_show_memory_breakpoints_cleanup.
1394
1395 2017-09-11 Tom Tromey <tom@tromey.com>
1396
1397 * d-namespace.c (d_lookup_symbol): Use std::string.
1398 (find_symbol_in_baseclass): Likewise.
1399
1400 2017-09-11 Tom Tromey <tom@tromey.com>
1401
1402 * ctf.c (ctf_start): Use std::string.
1403
1404 2017-09-11 Tom Tromey <tom@tromey.com>
1405
1406 * ada-lang.c (is_known_support_routine): Update.
1407 (ada_unhandled_exception_name_addr_from_raise): Update.
1408 * guile/scm-frame.c (gdbscm_frame_name): Update.
1409 * python/py-frame.c (frapy_name): Update.
1410 (frapy_function): Update.
1411 * stack.h (find_frame_funname): Update.
1412 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1413 (print_frame): Update.
1414
1415 2017-09-11 Tom Tromey <tom@tromey.com>
1416
1417 * findcmd.c (put_bits): Take a gdb::byte_vector.
1418 (parse_find_args): Return gdb::byte_vector. "args" now const.
1419 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1420 cleanups.
1421 (find_command): Update.
1422
1423 2017-09-11 Tom Tromey <tom@tromey.com>
1424
1425 * cli/cli-script.c (class scoped_restore_hook_in): New.
1426 (clear_hook_in_cleanup): Remove.
1427 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1428 scoped_restore_hook_in.
1429
1430 2017-09-11 Tom Tromey <tom@tromey.com>
1431
1432 * cli/cli-script.c (restore_interp): Remove.
1433 (read_command_lines): Use scoped_restore_interp.
1434 * interps.c (scoped_restore_interp::set_temp): Rename from
1435 interp_set_temp.
1436 * interps.h (class scoped_restore_interp): New.
1437 (interp_set_temp): Remove.
1438
1439 2017-09-11 Tom Tromey <tom@tromey.com>
1440
1441 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1442 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1443 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1444 scoped_restore.
1445 (mi_cmd_break_insert_1): Update.
1446 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1447 scoped_restore.
1448
1449 2017-09-11 Tom Tromey <tom@tromey.com>
1450
1451 * demangle.c (demangle_command): Update.
1452 * breakpoint.c (disable_command): Update.
1453 (enable_command): Update.
1454 (find_location_by_number): Make "number" const. Use
1455 get_number_trailer.
1456 * cli/cli-utils.c (extract_arg): Return std::string.
1457 * probe.c (parse_probe_linespec): Update. Change types.
1458 (collect_probes): Take string arguments.
1459 (parse_probe_linespec): Likewise.
1460 (info_probes_for_ops): Update.
1461 (enable_probes_command): Update.
1462 (disable_probes_command): Update.
1463 * break-catch-sig.c (catch_signal_split_args): Update.
1464 * mi/mi-parse.c (mi_parse): Update.
1465
1466 2017-09-11 Tom Tromey <tom@tromey.com>
1467
1468 * language.h (language_enum): Make argument const.
1469 * language.c (language_enum): Make argument const.
1470
1471 2017-09-11 Tom Tromey <tom@tromey.com>
1472
1473 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1474 as function.
1475 (skip_to_space): Rename from skip_to_space_const.
1476 * common/common-utils.c (skip_to_space): New function.
1477 (skip_to_space): Rename from skip_to_space_const.
1478 * cli/cli-utils.h (get_number): Rename from get_number_const.
1479 (extract_arg): Rename from extract_arg_const.
1480 * cli/cli-utils.c (get_number): Rename from get_number_const.
1481 (extract_arg): Rename from extract_arg_const.
1482 (number_or_range_parser::get_number): Use ::get_number.
1483 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1484 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1485 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1486 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1487 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1488 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1489 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1490 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1491
1492 2017-09-11 Tom Tromey <tom@tromey.com>
1493
1494 * python/python.c (do_start_initialization): Use
1495 py-event-types.def to initialize types.
1496 Define all object type structures.
1497 * python/python-internal.h: Don't declare event initialization
1498 functions.
1499 * python/py-threadevent.c (thread_event_object_type): Don't
1500 define.
1501 * python/py-stopevent.c (stop_event_object_type): Don't define.
1502 * python/py-signalevent.c (signal_event_object_type): Don't
1503 declare or define.
1504 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1505 (clear_objfiles_event_object_type): Don't declare or define.
1506 * python/py-infevents.c (inferior_call_pre_event_object_type)
1507 (inferior_call_post_event_object_type)
1508 (register_changed_event_object_type)
1509 (memory_changed_event_object_type): Don't declare or define.
1510 * python/py-inferior.c (new_thread_event_object_type)
1511 (new_inferior_event_object_type)
1512 (inferior_deleted_event_object_type): Don't declare or define.
1513 * python/py-exitedevent.c (exited_event_object_type): Don't
1514 declare or define.
1515 * python/py-evts.c (gdbpy_initialize_py_events): Use
1516 py-all-events.def.
1517 * python/py-events.h (thread_event_object_type): Don't declare.
1518 (events_object): Use py-all-events.def.
1519 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1520 py-event-types.def.
1521 * python/py-event-types.def: New file.
1522 * python/py-continueevent.c (create_continue_event_object): Don't
1523 declare or define.
1524 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1525 declare or define.
1526 * python/py-all-events.def: New file.
1527
1528 2017-09-11 Tom Tromey <tom@tromey.com>
1529
1530 * python/py-threadevent.c (create_thread_event_object): Return
1531 gdbpy_ref.
1532 * python/py-stopevent.h (create_stop_event_object)
1533 (create_breakpoint_event_object, create_signal_event_object):
1534 Update.
1535 * python/py-stopevent.c (create_stop_event_object): Return
1536 gdbpy_ref.
1537 (emit_stop_event): Update.
1538 * python/py-signalevent.c (create_signal_event_object): Return
1539 gdbpy_ref.
1540 * python/py-infevents.c (create_inferior_call_event_object):
1541 Update.
1542 * python/py-event.h (create_event_object)
1543 (create_thread_event_object): Update.
1544 * python/py-event.c (create_event_object): Return gdbpy_ref.
1545 * python/py-continueevent.c: Return gdbpy_ref.
1546 * python/py-bpevent.c (create_breakpoint_event_object): Return
1547 gdbpy_ref.
1548
1549 2017-09-11 Tom Tromey <tom@tromey.com>
1550
1551 PR python/15622:
1552 * NEWS: Add entry.
1553 * python/python.c (do_start_initialization): Initialize new event
1554 types.
1555 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1556 (gdbpy_initialize_inferior_deleted_event)
1557 (gdbpy_initialize_new_thread_event): Declare.
1558 * python/py-threadevent.c (create_thread_event_object): Add option
1559 "thread" parameter.
1560 * python/py-inferior.c (new_thread_event_object_type)
1561 (new_inferior_event_object_type)
1562 (inferior_deleted_event_object_type): Declare.
1563 (python_new_inferior, python_inferior_deleted): New functions.
1564 (add_thread_object): Emit new_thread event.
1565 (gdbpy_initialize_inferior): Attach new functions to corresponding
1566 observers.
1567 (new_thread, new_inferior, inferior_deleted): Define new event
1568 types.
1569 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1570 registries.
1571 * python/py-events.h (events_object) <new_inferior,
1572 inferior_deleted, new_thread>: New fields.
1573 * python/py-event.h (create_thread_event_breakpoint): Add optional
1574 "thread" parameter.
1575
1576 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1577
1578 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1579 check current_ui instead.
1580 (internal_vproblem): Likewise.
1581
1582 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1583
1584 * thread.c (print_thread_info_1): Remove unnecessary calls to
1585 uiout->is_mi_like_p.
1586
1587 2017-09-09 Tom Tromey <tom@tromey.com>
1588
1589 * namespace.h (add_using_directive): Update.
1590 * namespace.c (add_using_directive): Change type of excludes to
1591 std::vector.
1592 * dwarf2read.c (read_import_statement): Use std::vector.
1593 (read_namespace): Update.
1594 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1595
1596 2017-09-09 Tom Tromey <tom@tromey.com>
1597
1598 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1599
1600 2017-09-09 Tom Tromey <tom@tromey.com>
1601
1602 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1603
1604 2017-09-09 Tom Tromey <tom@tromey.com>
1605
1606 * stack.c (func_command): Use gdb::def_vector.
1607
1608 2017-09-09 Tom Tromey <tom@tromey.com>
1609
1610 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1611 ui_out_emit_list, ui_out_emit_tuple.
1612 (mi_cmd_var_update): Likewise.
1613
1614 2017-09-09 Tom Tromey <tom@tromey.com>
1615
1616 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1617 ui_out_redirect_pop.
1618 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1619 ui_out_redirect_pop.
1620 * utils.c (do_ui_out_redirect_pop)
1621 (make_cleanup_ui_out_redirect_pop): Remove.
1622 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1623 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1624 * ui-out.h (ui_out_redirect_pop): New class.
1625
1626 2017-09-09 Tom Tromey <tom@tromey.com>
1627
1628 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1629 (list_available_thread_groups, mi_cmd_list_thread_groups)
1630 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1631 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1632 Likewise.
1633
1634 2017-09-09 Tom Tromey <tom@tromey.com>
1635
1636 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1637 ui_out_emit_tuple.
1638
1639 2017-09-09 Tom Tromey <tom@tromey.com>
1640
1641 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1642 * stack.c (print_frame): Use ui_out_emit_tuple.
1643 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1644 (info_spu_mailbox_command, info_spu_dma_command)
1645 (info_spu_proxydma_command): Likewise.
1646 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1647 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1648 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1649 ui_out_emit_tuple.
1650 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1651
1652 2017-09-09 Tom Tromey <tom@tromey.com>
1653
1654 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1655 (class ui_out_emit_table): Update comment.
1656 * ui-out.c (do_cleanup_table_end)
1657 (make_cleanup_ui_out_table_begin_end): Remove.
1658 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1659 (info_spu_dma_cmdlist): Likewise.
1660 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1661 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1662 ui_out_emit_table.
1663
1664 2017-09-09 Tom Tromey <tom@tromey.com>
1665
1666 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1667 ui_out_emit_list, gdb::optional.
1668
1669 2017-09-09 John Baldwin <jhb@FreeBSD.org>
1670
1671 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1672 prototype.
1673 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1674 prototype.
1675 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1676 prototype.
1677 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1678 * ada-exp.y: Remove _initialize_ada_exp prototype.
1679 * ada-lang.c: Remove _initialize_ada_language prototype.
1680 * ada-tasks.c: Remove _initialize_tasks prototype.
1681 * addrmap.c: Remove _initialize_addrmap prototype.
1682 * agent.c: Remove _initialize_agent prototype.
1683 * aix-thread.c: Remove _initialize_aix_thread prototype.
1684 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
1685 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
1686 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
1687 prototype.
1688 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
1689 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
1690 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
1691 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
1692 prototype.
1693 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
1694 prototype.
1695 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
1696 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
1697 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
1698 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
1699 prototype.
1700 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
1701 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
1702 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
1703 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
1704 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1705 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
1706 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
1707 prototype.
1708 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
1709 prototype.
1710 * annotate.c: Remove _initialize_annotate prototype.
1711 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
1712 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
1713 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
1714 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
1715 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
1716 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
1717 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
1718 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
1719 prototype.
1720 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
1721 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
1722 * auto-load.c: Remove _initialize_auto_load prototype.
1723 * auxv.c: Remove _initialize_auxv prototype.
1724 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
1725 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
1726 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
1727 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
1728 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
1729 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
1730 prototype.
1731 * break-catch-throw.c: Remove _initialize_break_catch_throw
1732 prototype.
1733 * breakpoint.c: Remove _initialize_breakpoint prototype.
1734 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
1735 * btrace.c: Remove _initialize_btrace prototype.
1736 * charset.c: Remove _initialize_charset prototype.
1737 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
1738 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
1739 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
1740 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
1741 * cli/cli-script.c: Remove _initialize_cli_script prototype.
1742 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
1743 * coffread.c: Remove _initialize_coffread prototype.
1744 * compile/compile.c: Remove _initialize_compile prototype.
1745 * complaints.c: Remove _initialize_complaints prototype.
1746 * completer.c: Remove _initialize_completer prototype.
1747 * copying.awk: Remove _initialize_copying prototype.
1748 * copying.c: Regenerate.
1749 * core-regset.c: Remove _initialize_core_regset prototype.
1750 * corefile.c: Remove _initialize_core prototype.
1751 * corelow.c: Remove _initialize_corelow prototype.
1752 * cp-abi.c: Remove _initialize_cp_abi prototype.
1753 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
1754 * cp-support.c: Remove _initialize_cp_support prototype.
1755 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
1756 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
1757 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
1758 * ctf.c: Remove _initialize_ctf prototype.
1759 * d-lang.c: Remove _initialize_d_language prototype.
1760 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
1761 prototype.
1762 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
1763 * dbxread.c: Remove _initialize_dbxread prototype.
1764 * dcache.c: Remove _initialize_dcache prototype.
1765 * demangle.c: Remove _initialize_demangler prototype.
1766 * disasm-selftests.c: Remove _initialize_disasm_selftests
1767 prototype.
1768 * disasm.c: Remove _initialize_disasm prototype.
1769 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
1770 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
1771 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
1772 prototype.
1773 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
1774 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
1775 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
1776 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
1777 * elfread.c: Remove _initialize_elfread prototype.
1778 * exec.c: Remove _initialize_exec prototype.
1779 * extension.c: Remove _initialize_extension prototype.
1780 * f-lang.c: Remove _initialize_f_language prototype.
1781 * f-valprint.c: Remove _initialize_f_valprint prototype.
1782 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
1783 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
1784 * filesystem.c: Remove _initialize_filesystem prototype.
1785 * findcmd.c: Remove _initialize_mem_search prototype.
1786 * fork-child.c: Remove _initialize_fork_child prototype.
1787 * frame-base.c: Remove _initialize_frame_base prototype.
1788 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
1789 * frame.c: Remove _initialize_frame prototype.
1790 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
1791 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
1792 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
1793 * gcore.c: Remove _initialize_gcore prototype.
1794 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
1795 * gdbarch.c: Regenerate.
1796 * gdbarch.sh: Remove _initialize_gdbarch prototype.
1797 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
1798 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
1799 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
1800 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
1801 * go-lang.c: Remove _initialize_go_language prototype.
1802 * go32-nat.c: Remove _initialize_go32_nat prototype.
1803 * guile/guile.c: Remove _initialize_guile prototype.
1804 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
1805 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
1806 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
1807 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
1808 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
1809 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
1810 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
1811 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
1812 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
1813 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
1814 prototype.
1815 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
1816 prototype.
1817 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
1818 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
1819 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
1820 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
1821 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
1822 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
1823 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
1824 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
1825 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
1826 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
1827 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
1828 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
1829 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
1830 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1831 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
1832 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
1833 prototype.
1834 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
1835 prototype.
1836 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
1837 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
1838 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
1839 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
1840 * infcall.c: Remove _initialize_infcall prototype.
1841 * infcmd.c: Remove _initialize_infcmd prototype.
1842 * inferior.c: Remove _initialize_inferiors prototype.
1843 * inflow.c: Remove _initialize_inflow prototype.
1844 * infrun.c: Remove _initialize_infrun prototype.
1845 * interps.c: Remove _initialize_interpreter prototype.
1846 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
1847 * jit.c: Remove _initialize_jit prototype.
1848 * language.c: Remove _initialize_language prototype.
1849 * linux-fork.c: Remove _initialize_linux_fork prototype.
1850 * linux-nat.c: Remove _initialize_linux_nat prototype.
1851 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
1852 * linux-thread-db.c: Remove _initialize_thread_db prototype.
1853 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
1854 * m2-lang.c: Remove _initialize_m2_language prototype.
1855 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
1856 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
1857 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
1858 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
1859 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
1860 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1861 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1862 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
1863 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
1864 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
1865 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1866 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1867 * machoread.c: Remove _initialize_machoread prototype.
1868 * macrocmd.c: Remove _initialize_macrocmd prototype.
1869 * macroscope.c: Remove _initialize_macroscope prototype.
1870 * maint.c: Remove _initialize_maint_cmds prototype.
1871 * mdebugread.c: Remove _initialize_mdebugread prototype.
1872 * memattr.c: Remove _initialize_mem prototype.
1873 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
1874 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
1875 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
1876 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
1877 * mi/mi-main.c: Remove _initialize_mi_main prototype.
1878 * microblaze-linux-tdep.c: Remove
1879 _initialize_microblaze_linux_tdep prototype.
1880 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
1881 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
1882 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
1883 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
1884 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
1885 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
1886 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
1887 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
1888 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
1889 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
1890 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
1891 prototype.
1892 * mipsread.c: Remove _initialize_mipsread prototype.
1893 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
1894 prototype.
1895 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
1896 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
1897 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
1898 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
1899 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
1900 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
1901 prototype.
1902 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
1903 * nto-procfs.c: Remove _initialize_procfs prototype.
1904 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
1905 * objc-lang.c: Remove _initialize_objc_language prototype.
1906 * objfiles.c: Remove _initialize_objfiles prototype.
1907 * observer.c: Remove observer_test_first_notification_function,
1908 observer_test_second_notification_function,
1909 observer_test_third_notification_function, and
1910 _initialize_observer prototypes.
1911 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
1912 * osabi.c: Remove _initialize_gdb_osabi prototype.
1913 * osdata.c: Remove _initialize_osdata prototype.
1914 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
1915 * parse.c: Remove _initialize_parse prototype.
1916 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
1917 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
1918 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
1919 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
1920 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
1921 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
1922 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
1923 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
1924 * printcmd.c: Remove _initialize_printcmd prototype.
1925 * probe.c: Remove _initialize_probe prototype.
1926 * proc-api.c: Remove _initialize_proc_api prototype.
1927 * proc-events.c: Remove _initialize_proc_events prototype.
1928 * proc-service.c: Remove _initialize_proc_service prototype.
1929 * procfs.c: Remove _initialize_procfs prototype.
1930 * psymtab.c: Remove _initialize_psymtab prototype.
1931 * python/python.c: Remove _initialize_python prototype.
1932 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
1933 * record-btrace.c: Remove _initialize_record_btrace prototype.
1934 * record-full.c: Remove _initialize_record_full prototype.
1935 * record.c: Remove _initialize_record prototype.
1936 * regcache.c: Remove _initialize_regcache prototype.
1937 * reggroups.c: Remove _initialize_reggroup prototype.
1938 * remote-notif.c: Remove _initialize_notif prototype.
1939 * remote-sim.c: Remove _initialize_remote_sim prototype.
1940 * remote.c: Remove _initialize_remote prototype.
1941 * reverse.c: Remove _initialize_reverse prototype.
1942 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
1943 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
1944 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
1945 prototype.
1946 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
1947 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
1948 * rust-exp.y: Remove _initialize_rust_exp prototype.
1949 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
1950 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
1951 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
1952 * score-tdep.c: Remove _initialize_score_tdep prototype.
1953 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
1954 prototype.
1955 * ser-go32.c: Remove _initialize_ser_dos prototype.
1956 * ser-mingw.c: Remove _initialize_ser_windows prototype.
1957 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
1958 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
1959 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
1960 * serial.c: Remove _initialize_serial prototype.
1961 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
1962 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
1963 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
1964 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
1965 * skip.c: Remove _initialize_step_skip prototype.
1966 * sol-thread.c: Remove _initialize_sol_thread prototype.
1967 * solib-aix.c: Remove _initialize_solib_aix prototype.
1968 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
1969 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
1970 * solib-frv.c: Remove _initialize_frv_solib prototype.
1971 * solib-spu.c: Remove _initialize_spu_solib prototype.
1972 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
1973 * solib-target.c: Remove _initialize_solib_target prototype.
1974 * solib.c: Remove _initialize_solib prototype.
1975 * source.c: Remove _initialize_source prototype.
1976 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
1977 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
1978 prototype.
1979 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
1980 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
1981 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
1982 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
1983 prototype.
1984 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
1985 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
1986 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
1987 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
1988 prototype.
1989 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
1990 prototype.
1991 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
1992 prototype.
1993 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
1994 prototype.
1995 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
1996 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
1997 prototype.
1998 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
1999 prototype.
2000 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
2001 prototype.
2002 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
2003 prototype.
2004 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
2005 prototype.
2006 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
2007 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
2008 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
2009 * stabsread.c: Remove _initialize_stabsread prototype.
2010 * stack.c: Remove _initialize_stack prototype.
2011 * stap-probe.c: Remove _initialize_stap_probe prototype.
2012 * std-regs.c: Remove _initialize_frame_reg prototype.
2013 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
2014 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
2015 * symfile.c: Remove _initialize_symfile prototype.
2016 * symmisc.c: Remove _initialize_symmisc prototype.
2017 * symtab.c: Remove _initialize_symtab prototype.
2018 * target-dcache.c: Remove _initialize_target_dcache prototype.
2019 * target-descriptions.c: Remove _initialize_target_descriptions
2020 prototype.
2021 * thread.c: Remove _initialize_thread prototype.
2022 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
2023 prototype.
2024 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
2025 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
2026 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
2027 prototype.
2028 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
2029 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
2030 * tracefile.c: Remove _initialize_tracefile prototype.
2031 * tracepoint.c: Remove _initialize_tracepoint prototype.
2032 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
2033 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
2034 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
2035 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
2036 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
2037 * tui/tui-win.c: Remove _initialize_tui_win prototype.
2038 * tui/tui.c: Remove _initialize_tui prototype.
2039 * typeprint.c: Remove _initialize_typeprint prototype.
2040 * user-regs.c: Remove _initialize_user_regs prototype.
2041 * utils.c: Remove _initialize_utils prototype.
2042 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
2043 * valarith.c: Remove _initialize_valarith prototype.
2044 * valops.c: Remove _initialize_valops prototype.
2045 * valprint.c: Remove _initialize_valprint prototype.
2046 * value.c: Remove _initialize_values prototype.
2047 * varobj.c: Remove _initialize_varobj prototype.
2048 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
2049 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
2050 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
2051 * windows-nat.c: Remove _initialize_windows_nat,
2052 _initialize_check_for_gdb_ini, and _initialize_loadable
2053 prototypes.
2054 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
2055 * xcoffread.c: Remove _initialize_xcoffread prototype.
2056 * xml-support.c: Remove _initialize_xml_support prototype.
2057 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
2058 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
2059 prototype.
2060 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
2061 prototype.
2062 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
2063
2064 2017-09-08 Keith Seitz <keiths@redhat.com>
2065
2066 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
2067 field.
2068
2069 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
2070
2071 * f-valprint.c (f_val_print): Remove check for one byte
2072 sized integers. Remove printing of character type.
2073
2074 2017-09-08 Frank Penczek <frank.penczek@intel.com>
2075 Christoph Weinmann <christoph.t.weinmann@intel.com>
2076 Bernhard Heckel <bernhard.heckel@intel.com>
2077
2078 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
2079 to maintain proper indentation when printing pointers/refs.
2080
2081 2017-09-07 Joel Brobecker <brobecker@adacore.com>
2082
2083 GDB 8.0.1 released.
2084
2085 2017-09-07 Joel Brobecker <brobecker@adacore.com>
2086
2087 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
2088
2089 2017-09-05 Tom Tromey <tom@tromey.com>
2090
2091 * parse.c (funcall_chain): Now a std::vector.
2092 (start_arglist, end_arglist): Simplify.
2093 (free_funcalls): Remove.
2094 (parse_exp_in_context_1): Remove cleanup.
2095
2096 2017-09-05 Tom Tromey <tom@tromey.com>
2097
2098 * go-exp.y (go_parse): Don't create a cleanup.
2099
2100 2017-09-05 Tom Tromey <tom@tromey.com>
2101
2102 * d-exp.y (PrimaryExpression): Use std::string.
2103 (d_parse): Don't create a cleanup.
2104
2105 2017-09-05 Tom Tromey <tom@tromey.com>
2106
2107 * utils.c (do_clear_parser_state): Remove.
2108 (make_cleanup_clear_parser_state): Remove.
2109 * p-exp.y (pascal_parse): Use scoped_restore.
2110 * m2-exp.y (m2_parse): Use scoped_restore.
2111 * f-exp.y (f_parse): Use scoped_restore.
2112 * d-exp.y (d_parse): Use scoped_restore.
2113 * c-exp.y (c_parse): Use scoped_restore.
2114 * ada-exp.y (ada_parse): Use scoped_restore.
2115 * utils.h (make_cleanup_clear_parser_state): Remove.
2116
2117 2017-09-06 Keith Seitz <keiths@redhat.com>
2118
2119 * dwarf2read.c (dw2_linkage_name_attr): New function.
2120 (dw2_linkage_name): New function.
2121 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
2122 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
2123 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
2124
2125 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2126
2127 * config/djgpp/djconfig.sh: Correct shell portability issue.
2128
2129 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2130
2131 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
2132
2133 2017-09-06 John Baldwin <jhb@FreeBSD.org>
2134
2135 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
2136 * NEWS: Mention new FreeBSD/mips native configuration.
2137 * configure.host: Add aarch64*-*-freebsd*.
2138 * configure.nat: Likewise.
2139 * aarch64-fbsd-nat.c: New file.
2140
2141 2017-09-06 John Baldwin <jhb@FreeBSD.org>
2142
2143 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
2144 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
2145 * NEWS: Mention new FreeBSD/aarch64 target.
2146 * configure.tgt: Add aarch64*-*-freebsd*.
2147 * aarch64-fbsd-tdep.c: New file.
2148 * aarch64-fbsd-tdep.h: New file.
2149
2150 2017-09-06 Kamil Rytarowski <n54@gmx.com>
2151
2152 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
2153
2154 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
2155
2156 * parse.c (find_minsym_type_and_address): Don't relocate addresses
2157 of TLS symbols.
2158
2159 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2160
2161 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
2162 call.
2163
2164 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2165
2166 * infrun.c (follow_exec): Call add_thread after
2167 target_find_description.
2168
2169 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2170
2171 * infrun.c (handle_inferior_event_1): When exec'ing, read
2172 stop_pc after follow_exec.
2173
2174 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2175
2176 * remote.c (process_g_packet): Update error message.
2177
2178 2017-09-05 Yao Qi <yao.qi@linaro.org>
2179
2180 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
2181 targets.
2182
2183 2017-09-05 Pedro Alves <palves@redhat.com>
2184
2185 * eval.c (eval_call, evaluate_funcall): New functions, factored
2186 out from ...
2187 (evaluate_subexp_standard): ... this.
2188
2189 2017-09-05 Yao Qi <yao.qi@linaro.org>
2190
2191 * amd64-tdep.c (amd64_target_description): Create target
2192 descriptions.
2193 (_initialize_amd64_tdep): Don't call functions
2194 initialize_tdesc_amd64_*. Add self tests.
2195 * arch/amd64.c (amd64_create_target_description): Add parameter
2196 is_linux. Call set_tdesc_osabi if is_linux is true.
2197 * arch/amd64.h (amd64_create_target_description): Update the
2198 declaration.
2199 * arch/i386.c (i386_create_target_description): Add parameter
2200 is_linux. Call set_tdesc_osabi if is_linux is true.
2201 * arch/i386.h (i386_create_target_description): Update
2202 declaration.
2203 * configure.tgt: Add i386.o to gdb_target_obs.
2204 * features/Makefile (XMLTOC): Remove i386/*.xml.
2205 * features/i386/amd64-avx-avx512.c: Remove.
2206 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
2207 * features/i386/amd64-avx-mpx.c: Remove.
2208 * features/i386/amd64-avx.c: Remove.
2209 * features/i386/amd64-mpx.c: Remove.
2210 * features/i386/amd64.c: Remove.
2211 * features/i386/i386-avx-avx512.c: Remove.
2212 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
2213 * features/i386/i386-avx-mpx.c: Remove.
2214 * features/i386/i386-avx.c: Remove.
2215 * features/i386/i386-mmx.c: Remove.
2216 * features/i386/i386-mpx.c: Remove.
2217 * features/i386/i386.c: Remove.
2218 * i386-tdep.c: Don't include features/i386/i386*.c., include
2219 target-descriptions.h and arch/i386.h.
2220 (i386_target_description): Create target descriptions.
2221 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
2222 functions. Do self tests.
2223
2224 2017-09-05 Yao Qi <yao.qi@linaro.org>
2225
2226 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
2227 * features/i386/amd64-avx-avx512-linux.c: Removed.
2228 * features/i386/amd64-avx-linux.c: Removed.
2229 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
2230 * features/i386/amd64-avx-mpx-linux.c: Removed.
2231 * features/i386/amd64-linux.c: Removed.
2232 * features/i386/amd64-mpx-linux.c: Removed.
2233 * features/i386/x32-avx-avx512-linux.c: Removed.
2234 * features/i386/x32-avx-linux.c: Removed.
2235 * features/i386/x32-linux.c: Removed.
2236
2237 2017-09-05 Yao Qi <yao.qi@linaro.org>
2238
2239 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
2240 features/i386/*.c.
2241 (amd64_linux_read_description): Call
2242 amd64_create_target_description.
2243 * arch/amd64.c: New file.
2244 * arch/amd64.h: New file.
2245 * configure.tgt (x86_64-*-linux*): Append amd64.o.
2246 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
2247
2248 2017-09-05 Yao Qi <yao.qi@linaro.org>
2249
2250 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
2251 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
2252 (amd64_linux_read_description): Create target descriptions.
2253 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
2254 functions. Add unit tests.
2255 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
2256 x32-core.xml.
2257 * features/i386/64bit-avx.c: Generated.
2258 * features/i386/64bit-avx512.c: Generated.
2259 * features/i386/64bit-core.c: Generated.
2260 * features/i386/64bit-linux.c: Generated.
2261 * features/i386/64bit-mpx.c: Generated.
2262 * features/i386/64bit-pkeys.c: Generated.
2263 * features/i386/64bit-segments.c: Generated.
2264 * features/i386/64bit-sse.c: Generated.
2265 * features/i386/x32-core.c: Generated.
2266 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
2267 c files for amd64-linux and x32-linux.
2268
2269 2017-09-05 Yao Qi <yao.qi@linaro.org>
2270
2271 * amd64-linux-tdep.c (amd64_linux_read_description): New
2272 function.
2273 (amd64_linux_core_read_description): Call
2274 amd64_linux_read_description.
2275 (amd64_linux_init_abi): Likewise.
2276 (amd64_x32_linux_init_abi): Likewise.
2277 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
2278 * x86-linux-nat.c (x86_linux_read_description): Call
2279 amd64_linux_read_description.
2280
2281 2017-09-05 Yao Qi <yao.qi@linaro.org>
2282
2283 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
2284 comments.
2285
2286 2017-09-05 Yao Qi <yao.qi@linaro.org>
2287
2288 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
2289 * features/i386/i386-avx-avx512-linux.c: Remove.
2290 * features/i386/i386-avx-linux.c: Remove.
2291 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
2292 * features/i386/i386-avx-mpx-linux.c: Remove.
2293 * features/i386/i386-linux.c: Remove.
2294 * features/i386/i386-mmx-linux.c: Remove.
2295 * features/i386/i386-mpx-linux.c: Remove.
2296
2297 2017-09-05 Yao Qi <yao.qi@linaro.org>
2298
2299 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
2300 (SFILES): Add arch/i386.c.
2301 (HFILES_NO_SRCDIR): Add arch/i386.h.
2302 * arch/i386.c: New file.
2303 * arch/i386.h: New file.
2304 * arch/tdesc.h (allocate_target_description): Declare.
2305 (set_tdesc_architecture): Declare.
2306 (set_tdesc_osabi): Declare.
2307 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
2308 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
2309 include arch/i386.h.
2310 (i386_linux_read_description): Remove code and call
2311 i386_create_target_description.
2312 (set_tdesc_architecture): New function.
2313 (set_tdesc_osabi): New function.
2314 * target-descriptions.h (allocate_target_description): Remove.
2315
2316 2017-09-05 Yao Qi <yao.qi@linaro.org>
2317
2318 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
2319 * target-descriptions.c (tdesc_create_feature): Likewise, and
2320 adjust code.
2321 * features/i386/32bit-avx.c: Re-generated.
2322 * features/i386/32bit-avx512.c: Re-generated.
2323 * features/i386/32bit-core.c: Re-generated.
2324 * features/i386/32bit-linux.c: Re-generated.
2325 * features/i386/32bit-mpx.c: Re-generated.
2326 * features/i386/32bit-pkeys.c: Re-generated.
2327 * features/i386/32bit-sse.c: Re-generated.
2328
2329 2017-09-05 Yao Qi <yao.qi@linaro.org>
2330
2331 * regformats/regdef.h (struct reg): Override operator == and !=.
2332
2333 2017-09-05 Yao Qi <yao.qi@linaro.org>
2334
2335 * arch/tdesc.h: New file.
2336 * regformats/regdat.sh: Generate code using tdesc_create_reg.
2337 * target-descriptions.c: Update comments.
2338 * target-descriptions.h: Include "arch/tdesc.h". Remove the
2339 declarations.
2340 * features/i386/32bit-avx.c: Re-generated.
2341 * features/i386/32bit-avx512.c: Re-generated.
2342 * features/i386/32bit-core.c: Re-generated.
2343 * features/i386/32bit-linux.c: Re-generated.
2344 * features/i386/32bit-mpx.c: Re-generated.
2345 * features/i386/32bit-pkeys.c: Re-generated.
2346 * features/i386/32bit-sse.c: Re-generated.
2347
2348 2017-09-05 Yao Qi <yao.qi@linaro.org>
2349
2350 * regformats/regdat.sh: Update generated code.
2351
2352 2017-09-05 Yao Qi <yao.qi@linaro.org>
2353
2354 * regformats/regdat.sh: Adjust code order.
2355
2356 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2357
2358 * expprint.c (dump_subexp_body_standard): Use constant format
2359 string in fprintf_filtered call.
2360
2361 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2362
2363 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
2364 NetBSD/i386.
2365 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
2366
2367 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2368
2369 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
2370
2371 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2372
2373 * bsd-kvm.o: Define _KMEMUSER.
2374 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
2375 * configure: Regenerate.
2376
2377 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2378
2379 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
2380 * i386-fbsd-nat.c: Likewise.
2381
2382 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2383
2384 * unittests/array-view-selftests.c: Add include of <array>.
2385
2386 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2387
2388 * spu-tdep.c (flush_ea_cache): Add missing argument to
2389 call_function_by_hand.
2390
2391 2017-09-04 Pedro Alves <palves@redhat.com>
2392
2393 * NEWS (Safer support for debugging with no debug info): New.
2394
2395 2017-09-04 Pedro Alves <palves@redhat.com>
2396
2397 * c-exp.y (function_method, function_method_void): Add current
2398 instance flags to TYPE_INSTANCE.
2399 * dwarf2read.c (check_modifier): New.
2400 (compute_delayed_physnames): Assert that only C++ adds delayed
2401 physnames. Mark fn_fields as const/volatile depending on
2402 physname.
2403 * eval.c (make_params): New type_instance_flags parameter. Use
2404 it as the new type's instance flags.
2405 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2406 flags element and pass it to make_params.
2407 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2408 instance flags element.
2409 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2410 * gdbtypes.h: Include "enum-flags.h".
2411 (type_instance_flags): New enum-flags type.
2412 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2413 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2414 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2415 (follow_type_instance_flags): New function.
2416 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2417 * parser-defs.h (follow_type_instance_flags): Declare.
2418 * valops.c (value_struct_elt_for_reference): const/volatile must
2419 match too.
2420
2421 2017-09-04 Pedro Alves <palves@redhat.com>
2422
2423 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2424 function/method scopes; lookup the nested name as a function local
2425 static variable.
2426
2427 2017-09-04 Pedro Alves <palves@redhat.com>
2428
2429 (%type <voidval>): Add function_method.
2430 * c-exp.y (exp): New production for calls with no arguments.
2431 (function_method, function_method_void_or_typelist): New
2432 productions.
2433 (exp): New production for "method()::static_var".
2434 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2435 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2436 Handle OP_FUNC_STATIC_VAR.
2437 * parse.c (operator_length_standard):
2438 Handle OP_FUNC_STATIC_VAR.
2439
2440 2017-09-04 Pedro Alves <palves@redhat.com>
2441
2442 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2443 handling.
2444 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2445 Ditto.
2446 * parse.c (operator_length_standard, operator_check_standard):
2447 Ditto.
2448 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2449
2450 2017-09-04 Pedro Alves <palves@redhat.com>
2451
2452 * ax-gdb.c: Include "typeprint.h".
2453 (gen_expr_for_cast): New function.
2454 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2455 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2456 type is unknown.
2457 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2458 nodebug_data_symbol.
2459 * eval.c: Include "typeprint.h".
2460 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2461 Error out if symbol has unknown type.
2462 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2463 evaluate_subexp_for_cast.
2464 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2465 OP_VAR_MSYM_VALUE.
2466 (evaluate_subexp_for_cast): New function.
2467 * gdbtypes.c (init_nodebug_var_type): New function.
2468 (objfile_type): Use it to initialize types of variables with no
2469 debug info.
2470 * typeprint.c (error_unknown_type): New.
2471 * typeprint.h (error_unknown_type): New declaration.
2472 * compile/compile-c-types.c (convert_type_basic): Handle
2473 TYPE_CODE_ERROR; warn and fallback to int for variables with
2474 unknown type.
2475
2476 2017-09-04 Pedro Alves <palves@redhat.com>
2477
2478 * eval.c (evaluate_var_value): New function, factored out from ...
2479 (evaluate_subexp_standard): ... here.
2480
2481 2017-09-04 Pedro Alves <palves@redhat.com>
2482
2483 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2484 Remove useless assignments to 'op'.
2485
2486 2017-09-04 Pedro Alves <palves@redhat.com>
2487
2488 * eval.c (eval_skip_value): New function.
2489 (evaluate_subexp_standard): Use it.
2490
2491 2017-09-04 Pedro Alves <palves@redhat.com>
2492
2493 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2494 function name from symbol/minsym and pass it to
2495 error_call_unknown_return_type.
2496
2497 2017-09-04 Pedro Alves <palves@redhat.com>
2498
2499 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2500 * ax-gdb.c (gen_msym_var_ref): New function.
2501 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2502 * eval.c (evaluate_var_msym_value): New function.
2503 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2504 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2505 to call_function_by_hand.
2506 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2507 Handle OP_VAR_MSYM_VALUE.
2508 (union exp_element) <msymbol>: New field.
2509 * minsyms.h (struct type): Forward declare.
2510 (find_minsym_type_and_address): Declare.
2511 * parse.c (write_exp_elt_msym): New function.
2512 (write_exp_msymbol): Delete, refactored as ...
2513 (find_minsym_type_and_address): ... this new function.
2514 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2515 (operator_length_standard, operator_check_standard): Handle
2516 OP_VAR_MSYM_VALUE.
2517 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2518
2519 2017-09-04 Pedro Alves <palves@redhat.com>
2520
2521 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2522 TYPE_GNU_IFUNC specially here. Throw error if return type is
2523 unknown.
2524 * ada-typeprint.c (print_func_type): Handle functions with unknown
2525 return type.
2526 * c-typeprint.c (c_type_print_base): Handle functions and methods
2527 with unknown return type.
2528 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2529 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2530 * compile/compile-c-types.c: Include "objfiles.h".
2531 (convert_func): For functions with unknown return type, warn and
2532 default to int.
2533 * compile/compile-object-run.c (compile_object_run): Adjust call
2534 to call_function_by_hand_dummy.
2535 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2536 call_function_by_hand.
2537 * eval.c (evaluate_subexp_standard): Adjust calls to
2538 call_function_by_hand. Handle functions and methods with unknown
2539 return type. Pass expect_type to call_function_by_hand.
2540 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2541 return type.
2542 * gcore.c (call_target_sbrk): Adjust call to
2543 call_function_by_hand.
2544 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2545 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2546 an integer address type instead of nodebug.
2547 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2548 call_function_by_hand.
2549 * infcall.c (error_call_unknown_return_type): New function.
2550 (call_function_by_hand): New "default_return_type" parameter.
2551 Pass it down.
2552 (call_function_by_hand_dummy): New "default_return_type"
2553 parameter. Use it instead of defaulting to int. If there's no
2554 default and the return type is unknown, throw an error. If
2555 there's a default return type, and the called function has no
2556 debug info, then assume the function is prototyped.
2557 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2558 New "default_return_type" parameter.
2559 (error_call_unknown_return_type): New declaration.
2560 * linux-fork.c (call_lseek): Cast return type of lseek.
2561 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2562 call_function_by_hand.
2563 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2564 calls to call_function_by_hand.
2565 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2566 return type.
2567 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2568 (value_nsstring, print_object_command): Adjust calls to
2569 call_function_by_hand.
2570 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2571 functions with unknown return type.
2572 (pascal_type_print_func_varspec_suffix): New function.
2573 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2574 TYPE_CODE_METHOD>: Use it.
2575 * python/py-value.c (valpy_call): Adjust call to
2576 call_function_by_hand.
2577 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2578 call_function_by_hand.
2579 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2580 call_function_by_hand.
2581 * valops.c (value_allocate_space_in_inferior): Adjust call to
2582 call_function_by_hand.
2583 * typeprint.c (type_print_unknown_return_type): New function.
2584 * typeprint.h (type_print_unknown_return_type): New declaration.
2585
2586 2017-09-04 Pedro Alves <palves@redhat.com>
2587
2588 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2589 types with more than one parameter as prototyped.
2590
2591 2017-09-04 Pedro Alves <palves@redhat.com>
2592
2593 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2594 (disassemble_command): Use gdb_disassembly_flags instead of bare
2595 int.
2596 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2597 (dump_insns, do_mixed_source_and_assembly_deprecated)
2598 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2599 Use gdb_disassembly_flags instead of bare int.
2600 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2601 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2602 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2603 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2604 (enum gdb_disassembly_flag): ... values of this new enumeration.
2605 (gdb_disassembly_flags): Define.
2606 (gdb_disassembly)
2607 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2608 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2609 gdb_disassembly_flags instead of bare int.
2610 * record-btrace.c (btrace_insn_history)
2611 (record_btrace_insn_history, record_btrace_insn_history_range)
2612 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2613 instead of bare int.
2614 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2615 Use gdb_disassembly_flags instead of bare int.
2616 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2617 Define.
2618 * target-delegates.c: Regenerate.
2619 * target.c (target_insn_history, target_insn_history_from)
2620 (target_insn_history_range): Use gdb_disassembly_flags instead of
2621 bare int.
2622 * target.h: Include "disasm.h".
2623 (struct target_ops) <to_insn_history, to_insn_history_from,
2624 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2625 int.
2626 (target_insn_history, target_insn_history_from)
2627 (target_insn_history_range): Use gdb_disassembly_flags instead of
2628 bare int.
2629
2630 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2631
2632 * cli/cli-script.c (build_command_line): For if/while commands,
2633 check whether args is empty.
2634
2635 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2636
2637 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2638 (enum command_control_type): Likewise.
2639 (struct command_line): Likewise.
2640 (free_command_lines): Likewise.
2641 (struct command_lines_deleter): Likewise.
2642 (command_line_up): Likewise.
2643 (read_command_lines): Likewise.
2644 (read_command_lines_1): Likewise.
2645 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2646 (enum command_control_type): Likewise.
2647 (struct command_line): Likewise.
2648 (free_command_lines): Likewise.
2649 (struct command_lines_deleter): Likewise.
2650 (command_line_up): Likewise.
2651 (read_command_lines): Likewise.
2652 (read_command_lines_1): Likewise.
2653 * breakpoint.h: Include cli/cli-script.h.
2654 * extension-priv.h: Likewise.
2655 * gdbcmd.h: Likewise.
2656
2657 2017-09-04 Pedro Alves <palves@redhat.com>
2658
2659 * ada-lang.c (is_known_support_routine): Move sal declaration to
2660 where it is initialized.
2661 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2662 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2663 (clear_command, update_static_tracepoint): Remove init_sal
2664 references. Move declarations closer to initializations.
2665 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2666 initializations.
2667 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2668 references. Move sal declarations closer to initializations.
2669 * frame.c (find_frame_sal): Return a symtab_and_line via function
2670 return instead of output parameter. Remove init_sal references.
2671 * frame.h (find_frame_sal): Return a symtab_and_line via function
2672 return instead of output parameter.
2673 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2674 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2675 instead of memset.
2676 (gdbscm_find_pc_line): Remove init_sal reference.
2677 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2678 references. Move declarations closer to initializations.
2679 * infcmd.c (set_step_frame): Update. Move declarations closer to
2680 initializations.
2681 (finish_backward): Remove init_sal references. Move declarations
2682 closer to initializations.
2683 * infrun.c (process_event_stop_test, handle_step_into_function)
2684 (insert_hp_step_resume_breakpoint_at_frame)
2685 (insert_step_resume_breakpoint_at_caller): Likewise.
2686 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
2687 (symbol_to_sal): Likewise.
2688 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
2689 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
2690 to its initialization.
2691 * reverse.c (save_bookmark_command): Use new/delete. Remove
2692 init_sal references. Move declarations closer to initializations.
2693 * source.c (get_current_source_symtab_and_line): Remove brace
2694 initialization.
2695 (set_current_source_symtab_and_line): Now takes the sal by const
2696 reference. Remove brace initialization.
2697 (line_info): Remove init_sal reference.
2698 * source.h (set_current_source_symtab_and_line): Now takes a
2699 symtab_and_line via const reference.
2700 * stack.c (set_current_sal_from_frame): Adjust.
2701 (print_frame_info): Adjust.
2702 (get_last_displayed_sal): Return the sal via function return
2703 instead of via output parameter. Simplify.
2704 (frame_info): Adjust.
2705 * stack.h (get_last_displayed_sal): Return the sal via function
2706 return instead of via output parameter.
2707 * symtab.c (init_sal): Delete.
2708 (find_pc_sect_line): Remove init_sal references. Move
2709 declarations closer to initializations.
2710 (find_function_start_sal): Remove init_sal references. Move
2711 declarations closer to initializations.
2712 * symtab.h (struct symtab_and_line): In-class initialize all
2713 fields.
2714 * tracepoint.c (set_traceframe_context)
2715 (print_one_static_tracepoint_marker): Remove init_sal references.
2716 Move declarations closer to initializations.
2717 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
2718 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
2719 declarations closer to initializations.
2720 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
2721 init_sal references. Adjust.
2722
2723 2017-09-04 Pedro Alves <palves@redhat.com>
2724
2725 * ax-gdb.c (agent_command_1): Use range-for.
2726 * break-catch-throw.c (re_set_exception_catchpoint): Update.
2727 * breakpoint.c: Include "common/array-view.h".
2728 (init_breakpoint_sal, create_breakpoint_sal): Change sals
2729 parameter from struct symtabs_and_lines to
2730 array_view<symtab_and_line>. Adjust. Use range-for. Update.
2731 (breakpoint_sals_to_pc): Change sals parameter from struct
2732 symtabs_and_lines to std::vector reference.
2733 (check_fast_tracepoint_sals): Change sals parameter from struct
2734 symtabs_and_lines to std::array_view. Use range-for.
2735 (decode_static_tracepoint_spec): Return a std::vector instead of
2736 symtabs_and_lines. Update.
2737 (create_breakpoint): Update.
2738 (break_range_command, until_break_command, clear_command): Update.
2739 (base_breakpoint_decode_location, bkpt_decode_location)
2740 (bkpt_probe_create_sals_from_location)
2741 (bkpt_probe_decode_location, tracepoint_decode_location)
2742 (tracepoint_probe_decode_location)
2743 (strace_marker_create_sals_from_location): Return a std::vector
2744 instead of symtabs_and_lines.
2745 (strace_marker_create_breakpoints_sal): Update.
2746 (strace_marker_decode_location): Return a std::vector instead of
2747 symtabs_and_lines. Update.
2748 (update_breakpoint_locations): Change struct symtabs_and_lines
2749 parameters to gdb::array_view. Adjust.
2750 (location_to_sals): Return a std::vector instead of
2751 symtabs_and_lines. Update.
2752 (breakpoint_re_set_default): Use std::vector instead of struct
2753 symtabs_and_lines.
2754 (decode_location_default): Return a std::vector instead of
2755 symtabs_and_lines. Update.
2756 * breakpoint.h: Include "common/array-view.h".
2757 (struct breakpoint_ops) <decode_location>: Now returns a
2758 std::vector instead of returning a symtabs_and_lines via output
2759 parameter.
2760 (update_breakpoint_locations): Change sals parameters to use
2761 gdb::array_view.
2762 * cli/cli-cmds.c (edit_command, list_command): Update to use
2763 std::vector and gdb::array_view.
2764 (ambiguous_line_spec): Adjust to use gdb::array_view and
2765 range-for.
2766 (compare_symtabs): Rename to ...
2767 (cmp_symtabs): ... this. Change parameters to symtab_and_line
2768 const reference and adjust.
2769 (filter_sals): Rewrite using std::vector and standard algorithms.
2770 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
2771 (jump_command): Update to use std::vector.
2772 * linespec.c (struct linespec_state) <canonical_names>: Update
2773 comment.
2774 (add_sal_to_sals_basic): Delete.
2775 (add_sal_to_sals, filter_results, convert_results_to_lsals)
2776 (decode_line_2, create_sals_line_offset)
2777 (convert_address_location_to_sals, convert_linespec_to_sals)
2778 (convert_explicit_location_to_sals, parse_linespec)
2779 (event_location_to_sals, decode_line_full, decode_line_1)
2780 (decode_line_with_current_source)
2781 (decode_line_with_last_displayed, decode_objc)
2782 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
2783 (linespec_result::~linespec_result): Adjust to use std::vector
2784 instead of symtabs_and_lines.
2785 * linespec.h (linespec_sals::sals): Now a std::vector.
2786 (struct linespec_result): Use std::vector, bool, and in-class
2787 initialization.
2788 (decode_line_1, decode_line_with_current_source)
2789 (decode_line_with_last_displayed): Return std::vector.
2790 * macrocmd.c (info_macros_command): Use std::vector.
2791 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
2792 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
2793 std::vector.
2794 * probe.h (parse_probes): Return a std::vector.
2795 * python/python.c (gdbpy_decode_line): Use std::vector and
2796 gdb::array_view.
2797 * source.c (select_source_symtab, line_info): Use std::vector.
2798 * stack.c (func_command): Use std::vector.
2799 * symtab.h (struct symtabs_and_lines): Delete.
2800 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
2801
2802 2017-09-04 Pedro Alves <palves@redhat.com>
2803
2804 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2805 unittests/array-view-selftests.c.
2806 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
2807 * common/array-view.h: New file.
2808 * unittests/array-view-selftests.c: New file.
2809
2810 2017-09-04 Pedro Alves <palves@redhat.com>
2811
2812 * cli/cli-cmds.c (edit_command): Pass message to
2813 ambiguous_line_spec.
2814 (list_command): Pass message to ambiguous_line_spec. Say
2815 "first"/"last" instead of "start" and "end" to be consistent with
2816 the manual.
2817 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
2818 them to print formatted message.
2819
2820 2017-09-04 Pedro Alves <palves@redhat.com>
2821
2822 * btrace.c (ftrace_add_pt): Pass btrace_insn to
2823 ftrace_update_insns by reference instead of pointer.
2824
2825 2017-09-04 Yao Qi <yao.qi@linaro.org>
2826
2827 * i386-go32-tdep.c: Include x86-xstate.h.
2828 (i386_go32_init_abi): Call i386_target_description.
2829 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
2830 if xcr0 is X86_XSTATE_X87_MASK.
2831 * i386-tdep.h (tdesc_i386): Remove the declaration.
2832 (tdesc_i386_mmx): Likewise.
2833
2834 2017-09-04 Yao Qi <yao.qi@linaro.org>
2835
2836 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
2837 X86_XSTATE_SSE_MASK instead of 0.
2838
2839 2017-09-04 Yao Qi <yao.qi@linaro.org>
2840
2841 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
2842 i386_target_description.
2843 * i386-fbsd-nat.c (i386fbsd_read_description): Call
2844 i386_target_description.
2845 * i386-tdep.c (i386_gdbarch_init): Likewise.
2846
2847 2017-09-04 Yao Qi <yao.qi@linaro.org>
2848
2849 * amd64-darwin-tdep.c: Include "x86-xstate.h".
2850 (x86_darwin_init_abi_64): Call amd64_target_description.
2851 * amd64-dicos-tdep.c: Likewise.
2852 * amd64-fbsd-nat.c: Likewise.
2853 * amd64-fbsd-tdep.c: Likewise.
2854 * amd64-nbsd-tdep.c: Likewise.
2855 * amd64-obsd-tdep.c: Likewise.
2856 * amd64-sol2-tdep.c: Likewise.
2857 * amd64-windows-tdep.c: Likewise.
2858 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
2859
2860 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2861
2862 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
2863 (btrace_function) <insn>: Change type to use std::vector.
2864 * btrace.c (ftrace_debug, ftrace_call_num_insn,
2865 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
2866 ftrace_update_insns, ftrace_compute_global_level_offset,
2867 btrace_stitch_bts, btrace_clear, btrace_insn_get,
2868 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
2869 change to std::vector.
2870 (ftrace_update_insns): Adjust to change to std::vector, change
2871 type of INSN parameter.
2872 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
2873 * record-btrace.c (btrace_call_history_insn_range,
2874 btrace_compute_src_line_range,
2875 record_btrace_frame_prev_register): Adjust to change to
2876 std::vector.
2877 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
2878 to change to std::vector.
2879
2880 2017-09-03 Tom Tromey <tom@tromey.com>
2881
2882 * corefile.c (reopen_exec_file): Use std::string.
2883
2884 2017-09-03 Tom Tromey <tom@tromey.com>
2885
2886 * compile/compile.c (compile_register_name_mangled): Return
2887 std::string.
2888 * compile/compile-loc2c.c (pushf_register_address): Update.
2889 (pushf_register): Update.
2890 * compile/compile-c-types.c (convert_array): Update.
2891 * compile/compile-c-symbols.c (generate_vla_size): Update.
2892 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
2893 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
2894 (convert_one_symbol): Update.
2895 (generate_c_for_for_one_variable): Update.
2896 * compile/compile-c-support.c (c_get_range_decl_name): Return a
2897 std::string.
2898 (generate_register_struct): Update.
2899 * compile/compile-internal.h (c_get_range_decl_name): Return a
2900 std::string.
2901 (compile_register_name_mangled): Return std::string.
2902
2903 2017-09-03 Tom Tromey <tom@tromey.com>
2904
2905 * utils.c (perror_string): Return a std::string.
2906 (throw_perror_with_name, perror_warning_with_name): Update.
2907
2908 2017-09-03 Tom Tromey <tom@tromey.com>
2909
2910 * demangle.c (demangle_command): Use std::string,
2911 unique_xmalloc_ptr.
2912
2913 2017-09-03 Tom Tromey <tom@tromey.com>
2914
2915 * cli/cli-setshow.c (do_set_command): Use std::string.
2916
2917 2017-09-03 Tom Tromey <tom@tromey.com>
2918
2919 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
2920
2921 2017-09-03 Tom Tromey <tom@tromey.com>
2922
2923 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
2924
2925 2017-09-03 Tom Tromey <tom@tromey.com>
2926
2927 * mi/mi-cmd-env.c (env_execute_cli_command): Use
2928 gdb::unique_xmalloc_ptr.
2929
2930 2017-09-03 Tom Tromey <tom@tromey.com>
2931
2932 * thread.c (print_thread_info_1): Use string_printf.
2933 (thread_apply_command, thread_apply_all_command): Use
2934 std::string.
2935
2936 2017-09-03 Tom Tromey <tom@tromey.com>
2937
2938 * valprint.c (val_print_string): Update.
2939 * gdbcore.h (memory_error_message): Return std::string.
2940 * corefile.c (memory_error_message): Return std::string.
2941 (memory_error): Update.
2942 * breakpoint.c (insert_bp_location): Update.
2943
2944 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2945
2946 * target/waitstatus.h (target_waitstatus_to_string): Change
2947 return type to std::string.
2948 * target/waitstatus.c (target_waitstatus_to_string): Return
2949 std::string.
2950 * target.h (target_waitstatus_to_string): Remove declaration.
2951 * infrun.c (resume, clear_proceed_status_thread,
2952 print_target_wait_results, do_target_wait, save_waitstatus,
2953 stop_all_threads): Adjust.
2954 * record-btrace.c (record_btrace_wait): Adjust.
2955 * target-debug.h
2956 (target_debug_print_struct_target_waitstatus_p): Adjust.
2957
2958 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2959
2960 PR gdb/22046
2961 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
2962 detection.
2963
2964 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2965
2966 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
2967 for setting/unsetting environment variables on the remote target.
2968 (New remote packets): Add entries for QEnvironmentHexEncoded,
2969 QEnvironmentUnset and QEnvironmentReset.
2970 * common/environ.c (gdb_environ::operator=): Extend method to
2971 handle m_user_set_env_list and m_user_unset_env_list.
2972 (gdb_environ::clear): Likewise.
2973 (match_var_in_string): Change type of first parameter from 'char
2974 *' to 'const char *'.
2975 (gdb_environ::set): Extend method to handle
2976 m_user_set_env_list and m_user_unset_env_list.
2977 (gdb_environ::unset): Likewise.
2978 (gdb_environ::clear_user_set_env): New method.
2979 (gdb_environ::user_set_envp): Likewise.
2980 (gdb_environ::user_unset_envp): Likewise.
2981 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
2982 m_user_unset_env_list on move constructor/assignment.
2983 (unset): Add new default parameter 'update_unset_list = true'.
2984 (clear_user_set_env): New method.
2985 (user_set_envp): Likewise.
2986 (user_unset_envp): Likewise.
2987 (m_user_set_env_list): New std::set.
2988 (m_user_unset_env_list): Likewise.
2989 * common/rsp-low.c (hex2str): New function.
2990 (bin2hex): New overload for bin2hex function.
2991 * common/rsp-low.c (hex2str): New prototype.
2992 (str2hex): New overload prototype.
2993 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
2994 QEnvironmentUnset and QEnvironmentReset.
2995 (remote_protocol_features): Add QEnvironmentHexEncoded,
2996 QEnvironmentUnset and QEnvironmentReset packets.
2997 (send_environment_packet): New function.
2998 (extended_remote_environment_support): Likewise.
2999 (extended_remote_create_inferior): Call
3000 extended_remote_environment_support.
3001 (_initialize_remote): Add QEnvironmentHexEncoded,
3002 QEnvironmentUnset and QEnvironmentReset packet configs.
3003 * unittests/environ-selftests.c (gdb_selftest_env_var):
3004 New variable.
3005 (test_vector_initialization): New function.
3006 (test_init_from_host_environ): Likewise.
3007 (test_reinit_from_host_environ): Likewise.
3008 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
3009 Likewise.
3010 (test_unset_set_empty_vector): Likewise.
3011 (test_vector_clear): Likewise.
3012 (test_std_move): Likewise.
3013 (test_move_constructor):
3014 (test_self_move): Likewise.
3015 (test_set_unset_reset): Likewise.
3016 (run_tests): Rewrite in terms of the functions above.
3017
3018 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
3019
3020 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
3021 (adi_available): Use a temp variable of type CORE_ADDR as argument
3022 3 when calling target_auxv_search.
3023 (adi_normalize_address): Use masks and xor operators to calculate
3024 normalized address.
3025 (adi_read_versions, adi_write_versions, adi_print_versions)
3026 (do_examine, do_assign): Use paddress.
3027
3028 2017-08-29 John Baldwin <jhb@FreeBSD.org>
3029
3030 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
3031 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
3032 out of loop and add supply of FIR.
3033 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
3034 add collect of FIR.
3035
3036 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
3037
3038 PR gdb/21827
3039 * cli/cli-script.c (define_command): Don't convert command name
3040 to lower case.
3041
3042 2017-08-25 Joel Brobecker <brobecker@adacore.com>
3043
3044 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
3045 Update all callers accordingly. Remove all code blocks handling
3046 the case where DISPP is not NULL.
3047
3048 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3049
3050 PR symtab/22003
3051 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
3052 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3053 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
3054
3055 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3056
3057 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
3058 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
3059 (read_comp_units_from_section): New parameter abbrev_section, use
3060 read_and_check_comp_unit_head, allocate signatured_type if needed.
3061 (create_all_comp_units): Update read_comp_units_from_section caller.
3062
3063 2017-08-23 Pedro Alves <palves@redhat.com>
3064
3065 PR remote/21852
3066 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
3067 to null_ptid and switch to thread without reading the registers
3068 after adding the inferior.
3069
3070 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3071
3072 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
3073 compile-gcc.
3074 * compile/compile.c (compile_gcc, show_compile_gcc): New.
3075 (compile_to_object): Implement compile_gcc.
3076 (_initialize_compile): Install "set compile-gcc". Initialize
3077 compile_gcc.
3078
3079 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3080
3081 * compile/compile.c (compile_to_object): Conditionally call
3082 set_verbose. Conditionally call compile or compile_v0.
3083
3084 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
3085
3086 * sparc64-tdep.h: (adi_normalize_address): New export.
3087 * sparc-nat.h: (open_adi_tag_fd): New export.
3088 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
3089 * sparc64-linux-tdep.c:
3090 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
3091 (sparc64_linux_handle_segmentation_fault): New function.
3092 (sparc64_linux_init_abi): Register
3093 sparc64_linux_handle_segmentation_fault
3094 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
3095 (sparc64_addr_bits_remove): New function.
3096 (sparc64_init_abi): Register sparc64_addr_bits_remove.
3097 (MAX_PROC_NAME_SIZE): New macro.
3098 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
3099 (sparc64adilist): New variable.
3100 (adi_proc_list): New variable.
3101 (find_adi_info): New function.
3102 (add_adi_info): New function.
3103 (get_adi_info_proc): New function.
3104 (get_adi_info): New function.
3105 (info_adi_command): New function.
3106 (read_maps_entry): New function.
3107 (adi_available): New function.
3108 (adi_normalize_address): New function.
3109 (adi_align_address): New function.
3110 (adi_convert_byte_count): New function.
3111 (adi_tag_fd): New function.
3112 (adi_is_addr_mapped): New function.
3113 (adi_read_versions): New function.
3114 (adi_write_versions): New function.
3115 (adi_print_versions): New function.
3116 (do_examine): New function.
3117 (do_assign): New function.
3118 (adi_examine_command): New function.
3119 (adi_assign_command): New function.
3120 (_initialize_sparc64_adi_tdep): New function.
3121
3122 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
3123
3124 * breakpoint.c (breakpoints_info): Rename to ...
3125 (info_breakpoints_command): ... this.
3126 (watchpoints_info): Rename to ...
3127 (info_watchpoints_command): ... this.
3128 (tracepoints_info): Rename to ...
3129 (info_tracepoints_command): ... this.
3130 (_initialize_breakpoint): Adjust.
3131 * dcache.c (dcache_info): Rename to ...
3132 (info_display_command): ... this.
3133 (_initialize_dcache): Adjust.
3134 * frame.h (args_info): Rename to ...
3135 (info_args_command): ... this.
3136 (locals_info): Rename to ...
3137 (info_locals_command): ... this.
3138 * infcmd.c (nofp_registers_info): Rename to ...
3139 (info_registers_command): ... this.
3140 (float_info): Rename to ...
3141 (info_float_command): ... this.
3142 (program_info): Rename to ...
3143 (info_program_command): ... this.
3144 (all_registers_info): Rename to ...
3145 (info_all_registers_command): ... this.
3146 (vector_info): Rename to ...
3147 (info_vector_command): ... this.
3148 (float_info): Rename to ...
3149 (info_float_command): ... this.
3150 (_initialize_infcmd): Adjust.
3151 * inferior.h (term_info): Rename to ...
3152 (info_terminal_command): ... this.
3153 * inflow.c (term_info): Rename to ...
3154 (info_terminal_command): ... this.
3155 (_initialize_inflow): Adjust.
3156 * infrun.c (signals_info): Rename to ...
3157 (info_signals_command): ... this.
3158 (_initialize_infrun): Adjust.
3159 * objc-lang.c (classes_info): Rename to ...
3160 (info_classes_command): ... this.
3161 (selectors_info): Rename to ...
3162 (info_selectors_command): ... this.
3163 (_initialize_objc_language): Adjust.
3164 * printcmd.c (sym_info): Rename to ...
3165 (info_symbol_command): ... this.
3166 (address_info): Rename to ...
3167 (info_address_command): ... this.
3168 (display_info): Rename to ...
3169 (info_display_command): ... this.
3170 (_initialize_printcmd): Adjust.
3171 * reverse.c (bookmarks_info): Rename to ...
3172 (info_breakpoints_command): ... this.
3173 (_initialize_reverse): Adjust.
3174 * ser-go32.c (dos_info): Rename to ...
3175 (info_serial_command): ... this.
3176 (_initialize_ser_dos): Adjust.
3177 * skip.c (skip_info): Rename to ...
3178 (info_skip_command): ... this.
3179 (_initialize_step_skip): Adjust.
3180 * source.c (line_info): Rename to ...
3181 (info_line_command): ... this.
3182 (source_info): Rename to ...
3183 (info_source_command)
3184 * stack.c (frame_info): Rename to ...
3185 (info_frame_command): ... this.
3186 (locals_info): Rename to ...
3187 (info_locals_command): ... this.
3188 (args_info): Rename to ...
3189 (info_args_command): ... this.
3190 (_initialize_stack): Adjust.
3191 * symtab.c (sources_info): Rename to ...
3192 (info_sources_command): ... this.
3193 (variables_info): Rename to ...
3194 (info_variables_command): ... this.
3195 (functions_info): Rename to ...
3196 (info_functions_command): ... this.
3197 (types_info): Rename to ...
3198 (info_types_command): ... this.
3199 (_initialize_symtab): Adjust.
3200 * target.c (target_info): Rename to ...
3201 (info_target_command): ... this.
3202 (initialize_targets): Adjust.
3203 * tracepoint.c (tvariables_info): Rename to ...
3204 (info_tvariables_command): ... this.
3205 (scope_info): Rename to ...
3206 (info_scope_command): ... this.
3207 (trace_dump_actions): Adjust.
3208 (_initialize_tracepoint): Adjust.
3209
3210 2017-08-22 Tom Tromey <tom@tromey.com>
3211
3212 * breakpoint.h (install_breakpoint): Update.
3213 * breakpoint.c (add_solib_catchpoint): Update.
3214 (install_breakpoint): Change argument to a std::unique_ptr.
3215 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
3216 (create_breakpoint_sal, create_breakpoint): Update.
3217 (watch_command_1, catch_exec_command_1)
3218 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
3219 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
3220 Return the breakpoint.
3221 (set_raw_breakpoint_without_location, set_raw_breakpoint)
3222 (new_single_step_breakpoint): Update.
3223 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
3224 std::unique_ptr.
3225 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3226 std::unique_ptr.
3227 * break-catch-sig.c (create_signal_catchpoint): Use
3228 std::unique_ptr.
3229 * ada-lang.c (create_ada_exception_catchpoint): Use
3230 std::unique_ptr.
3231
3232 2017-08-22 Tom Tromey <tom@tromey.com>
3233
3234 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
3235
3236 2017-08-22 Tom Tromey <tom@tromey.com>
3237
3238 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
3239 (lookup_partial_symbol): Update.
3240
3241 2017-08-22 Tom Tromey <tom@tromey.com>
3242
3243 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
3244 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
3245 (find_and_open_source, symtab_to_fullname): Update.
3246 * psymtab.c (psymtab_to_fullname): Update.
3247
3248 2017-08-22 Tom Tromey <tom@tromey.com>
3249
3250 * exec.c (exec_file_attach): Update.
3251 * linux-thread-db.c (try_thread_db_load): Update.
3252 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
3253 * utils.c (gdb_realpath): Change return type.
3254 (gdb_realpath_keepfile): Update.
3255 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
3256 (_initialize_utils): Register the new self test.
3257 * source.c (openp): Update.
3258 (find_and_open_source): Update.
3259 * nto-tdep.c (nto_find_and_open_solib): Update.
3260 * main.c (set_gdb_data_directory): Update.
3261 (captured_main_1): Update.
3262 * dwarf2read.c (dwarf2_get_dwz_file): Update
3263 (dw2_map_symbol_filenames): Update.
3264 * auto-load.c (auto_load_safe_path_vec_update): Update.
3265 (filename_is_in_auto_load_safe_path_vec): Change type of
3266 "filename_realp".
3267 (auto_load_objfile_script): Update.
3268 (file_is_auto_load_safe): Update. Use std::string.
3269 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
3270
3271 2017-08-22 Tom Tromey <tom@tromey.com>
3272
3273 * utils.c (gdb_realpath_keepfile): Return a
3274 gdb::unique_xmalloc_ptr.
3275 * exec.c (exec_file_attach): Update.
3276 * utils.h (gdb_realpath_keepfile): Return a
3277 gdb::unique_xmalloc_ptr.
3278
3279 2017-08-22 Tom Tromey <tom@tromey.com>
3280
3281 * compile/compile.c (compile_file_command): Use
3282 gdb::unique_xmalloc_ptr, std::string.
3283 * utils.c (gdb_abspath): Change return type.
3284 * source.c (openp): Update.
3285 * objfiles.c (allocate_objfile): Update.
3286 * main.c (set_gdb_data_directory): Update.
3287 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
3288
3289 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
3290
3291 * cli-cmds.c (list_commands): List actual code around more than
3292 one location.
3293
3294 2017-08-21 John Baldwin <jhb@FreeBSD.org>
3295
3296 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
3297
3298 2017-08-21 Pedro Alves <palves@redhat.com>
3299
3300 PR gdb/19487
3301 * c-exp.y (variable production): Handle function aliases.
3302 * minsyms.c (msymbol_is_text): New function.
3303 * minsyms.h (msymbol_is_text): Declare.
3304 * symtab.c (find_function_alias_target): New function.
3305 * symtab.h (find_function_alias_target): Declare.
3306
3307 2017-08-21 Pedro Alves <palves@redhat.com>
3308
3309 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
3310 typedefs.
3311 * typeprint.c (whatis_exp): If handling "whatis", and expression
3312 is OP_TYPE, strip one typedef level. Otherwise don't strip
3313 typedefs here.
3314 * valops.c (value_cast): Save "to" type before resolving
3315 stubs/typedefs. Use that type as resulting value's type.
3316
3317 2017-08-18 Tom Tromey <tom@tromey.com>
3318 Pedro Alves <palves@redhat.com>
3319
3320 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
3321 * sol-thread.c (sol_thread_resume, sol_thread_wait)
3322 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
3323 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
3324 * proc-service.c (ps_xfer_memory): Use scoped_restore.
3325 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
3326 (linux_get_siginfo_data): Add "thread" argument. Use
3327 scoped_restore.
3328 * linux-nat.c (linux_child_follow_fork)
3329 (check_stopped_by_watchpoint): Use scoped_restore.
3330 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
3331 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
3332 (restore_inferior_ptid, save_inferior_ptid): Remove.
3333 * btrace.c (btrace_fetch): Use scoped_restore.
3334 * bsd-uthread.c (bsd_uthread_fetch_registers)
3335 (bsd_uthread_store_registers): Use scoped_restore.
3336 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
3337 scoped_restore.
3338 * aix-thread.c (aix_thread_resume, aix_thread_wait)
3339 (aix_thread_xfer_partial): Use scoped_restore.
3340 * inferior.h (save_inferior_ptid): Remove.
3341
3342 2017-08-18 Yao Qi <yao.qi@linaro.org>
3343
3344 PR tdep/21818
3345 * arm-tdep.c (gdb_print_insn_arm): Mark
3346 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
3347
3348 2017-08-18 Yao Qi <yao.qi@linaro.org>
3349
3350 * NEWS: Mention GDBserver's new option "--selftest".
3351 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
3352 * selftest.c: Move it to common/selftest.c.
3353 * selftest.h: Move it to common/selftest.h.
3354 * selftest-arch.c (reset): New function.
3355 (tests_with_arch): Call reset.
3356
3357 2017-08-18 Yao Qi <yao.qi@linaro.org>
3358
3359 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
3360 instead of exception_fprintf and printf_filtered.
3361
3362 2017-08-18 Yao Qi <yao.qi@linaro.org>
3363
3364 * selftest.c (register_self_test): Rename it to
3365 selftests::register_test.
3366 (run_self_tests): selftest::run_tests.
3367 * selftest.h: Update declarations.
3368 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
3369 selftests::register_test_foreach_arch.
3370 * selftest-arch.h: Update declaration.
3371 * aarch64-tdep.c: Update.
3372 * arm-tdep.c: Likewise.
3373 * disasm-selftests.c: Likewise.
3374 * dwarf2loc.c: Likewise.
3375 * dwarf2-frame.c: Likewise.
3376 * findvar.c: Likewise.
3377 * gdbarch-selftests.c: Likewise.
3378 * maint.c (maintenance_selftest): Likewise.
3379 * regcache.c: Likewise.
3380 * rust-exp.y: Likewise.
3381 * selftest-arch.c: Likewise.
3382 * unittests/environ-selftests.c: Likewise.
3383 * unittests/function-view-selftests.c: Likewise.
3384 * unittests/offset-type-selftests.c: Likewise.
3385 * unittests/optional-selftests.c: Likewise.
3386 * unittests/scoped_restore-selftests.c: Likewise.
3387 * utils-selftests.c: Likewise.
3388
3389 2017-08-17 Pedro Alves <palves@redhat.com>
3390
3391 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
3392 local.
3393
3394 2017-08-17 Pedro Alves <palves@redhat.com>
3395
3396 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3397 field.
3398 (reset_die_in_process): Delete, replaced by ...
3399 (process_die_scope): ... this new class. Make it responsible for
3400 freeing cu->line_header too.
3401 (process_die): Use process_die_scope.
3402 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3403 cu->line_header_die_owner. Don't release the line header if it's
3404 owned by the CU.
3405 (setup_type_unit_groups): Make the CU/DIE own the line header.
3406 Don't release the line header here.
3407
3408 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3409
3410 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3411
3412 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3413
3414 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3415 Single-Key mode
3416
3417 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3418
3419 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3420 mode command list.
3421
3422 2017-08-15 Stafford Horne <shorne@gmail.com>
3423
3424 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3425
3426 2017-08-15 Stafford Horne <shorne@gmail.com>
3427
3428 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3429
3430 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3431
3432 PR gdb/21954
3433 * infcmd.c (unset_environment_command): Use the 'clear' method on
3434 the environment instead of resetting it.
3435
3436 2017-08-15 John Baldwin <jhb@FreeBSD.org>
3437
3438 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3439 platforms.
3440
3441 2017-08-14 Tom Tromey <tom@tromey.com>
3442
3443 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3444 (print_binary_chars): Likewise.
3445 (BITS_IN_BYTES): Remove.
3446
3447 2017-08-14 Tom Tromey <tom@tromey.com>
3448
3449 PR gdb/21675
3450 * valprint.c (LOW_ZERO): Change value to 034.
3451 (print_octal_chars): Add static_asserts for octal constants.
3452 * printcmd.c (print_scalar_formatted): Add 'd' case.
3453
3454 2017-08-11 Tom Tromey <tom@tromey.com>
3455
3456 * symfile.c (add_symbol_file_command): Use std::vector.
3457
3458 2017-08-14 Tom Tromey <tom@tromey.com>
3459
3460 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3461 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3462 std::move.
3463 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3464
3465 2017-08-11 Pedro Alves <palves@redhat.com>
3466
3467 * infrun.c (process_event_stop_test): Adjust
3468 function_name_is_marked_for_skip call.
3469 * skip.c: Include <list>.
3470 (skiplist_entry): Make it a class with private fields, and
3471 getters/setters.
3472 (skiplist_entry_chain): Delete.
3473 (skiplist_entries): New.
3474 (skiplist_entry_count): Delete.
3475 (highest_skiplist_entry_num): New.
3476 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3477 (add_skiplist_entry): Delete.
3478 (skiplist_entry::skiplist_entry): New.
3479 (skiplist_entry::add_entry): New.
3480 (skip_file_command, skip_function): Adjust.
3481 (compile_skip_regexp): Delete.
3482 (skip_command): Don't compile regexp here. Adjust to use
3483 skiplist_entry::add_entry.
3484 (skip_info): Adjust to use range-for and getters.
3485 (skip_enable_command, skip_disable_command): Adjust to use
3486 range-for and setters.
3487 (skip_delete_command): Adjust to use std::list.
3488 (add_skiplist_entry): Delete.
3489 (skip_file_p): Delete, refactored as ...
3490 (skiplist_entry::do_skip_file_p): ... this new method.
3491 (skip_gfile_p): Delete, refactored as ...
3492 (skiplist_entry::do_gskip_file_p): ... this new method.
3493 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3494 (skiplist_entry::skip_function_p): ... this new method.
3495 (function_name_is_marked_for_skip): Now returns bool, and takes
3496 the function sal by const reference. Adjust to use range-for and
3497 skiplist_entry methods.
3498 (_initialize_step_skip): Remove references to
3499 skiplist_entry_chain, skiplist_entry_count.
3500 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3501 takes the function sal by const reference.
3502
3503 2017-08-11 Yao Qi <yao.qi@linaro.org>
3504
3505 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3506 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3507 (dwarf2_frame_cache):
3508 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3509 RETURN_MASK_ALL and set *this_case to NULL.
3510 * frame-unwind.h: Update comments.
3511
3512 2017-08-11 Yao Qi <yao.qi@linaro.org>
3513
3514 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3515 (dwarf2_frame_state_copy_regs): Remove.
3516 (dwarf2_frame_state_free_regs): Remove.
3517 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3518 (dwarf2_restore_rule): Call method .alloc_regs instead of
3519 dwarf2_frame_state_alloc_regs.
3520 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3521 constructor. Call std::move.
3522 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3523 (dwarf2_frame_cache): Likewise.
3524
3525 [GDB_SELF_TEST]: Include selftest.h and
3526 selftest-arch.h.
3527 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3528 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3529 execute_cfa_program_test.
3530
3531 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3532 copy ctor, assignment operator, move assignment.
3533 <alloc_regs>: New method.
3534 <swap>: New method.
3535 (struct dwarf2_frame_state): Delete dtor.
3536 (dwarf2_frame_state_alloc_regs): Remove declaration.
3537 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3538 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3539
3540 2017-08-11 Yao Qi <yao.qi@linaro.org>
3541
3542 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3543 (dwarf2_frame_state::dwarf2_frame_state): New.
3544 (dwarf2_frame_state::~dwarf2_frame_state): New.
3545 (dwarf2_fetch_cfa_info): Update.
3546 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3547 rather than a pointer. Update code.
3548 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3549 dtor.
3550 <data_align, code_align, retaddr_column>: Change them to const.
3551 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3552 to bool.
3553
3554 2017-08-11 Yao Qi <yao.qi@linaro.org>
3555
3556 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3557 <loc.exp>: New field.
3558 * dwarf2-frame.c (execute_cfa_program): Update.
3559 (dwarf2_frame_prev_register): Update.
3560
3561 2017-08-10 Pedro Alves <palves@redhat.com>
3562
3563 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3564
3565 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3566
3567 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3568 (fbsd_pending_children): Use std::list.
3569 (fbsd_remember_child): Likewise.
3570 (fbsd_is_child_pending): Likewise.
3571 (fbsd_pending_vfork_done): Use std::forward_list.
3572 (fbsd_add_vfork_done): Likewise.
3573 (fbsd_is_vfork_done_pending): Likewise.
3574 (fbsd_next_vfork_done): Likewise.
3575
3576 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3577
3578 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3579 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3580 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3581 for `mapfilename'.
3582 (fbsd_xfer_partial): Use gdb::byte_vector.
3583 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
3584
3585 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3586
3587 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3588 "filestuff.h".
3589 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3590
3591 2017-08-09 Tom Tromey <tom@tromey.com>
3592
3593 * skip.c (skiplist_entry): New constructor.
3594 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3595 (skiplist_entry::file_is_glob): Now bool.
3596 (skiplist_entry::file, skiplist_entry::function): Now
3597 std::string.
3598 (make_skip_entry): Return a unique_ptr. Use new.
3599 (free_skiplist_entry, free_skiplist_entry_cleanup)
3600 (make_free_skiplist_entry_cleanup): Remove.
3601 (skip_command, skip_disable_command, add_skiplist_entry)
3602 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3603 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3604 (function_name_is_marked_for_skip): Update.
3605 (skip_delete_command): Update. Use delete.
3606
3607 2017-08-09 Jiong Wang <jiong.wang@arm.com>
3608
3609 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3610 (aarch64_linux_core_read_description): New function.
3611 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3612
3613 2017-08-09 Pedro Alves <palves@redhat.com>
3614
3615 * cp-name-parser.y (cp_comp_to_string): Return a
3616 gdb::unique_xmalloc_ptr<char>.
3617 * cp-support.c (replace_typedefs_qualified_name)
3618 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3619 (cp_canonicalize_string_full): Use op= instead of explicit
3620 convertion.
3621 (cp_class_name_from_physname, method_name_from_physname)
3622 (cp_func_name, cp_remove_params): Adjust to use
3623 gdb::unique_xmalloc_ptr<char>.
3624 * cp-support.h (cp_comp_to_string): Return a
3625 gdb::unique_xmalloc_ptr<char>.
3626 * python/py-type.c (typy_lookup_type): Adjust to use
3627 gdb::unique_xmalloc_ptr<char>.
3628
3629 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3630
3631 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3632
3633 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3634 Yao Qi <yao.qi@linaro.org>
3635
3636 * cp-support.c (cp_canonicalize_string_full): Use
3637 gdb::unique_xmalloc_ptr<char>.
3638 (cp_canonicalize_string): Likewise.
3639
3640 2017-08-09 Yao Qi <yao.qi@linaro.org>
3641
3642 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3643 * regformats/i386/amd64-avx-avx512.dat: Remove.
3644 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3645 * regformats/i386/amd64-avx-mpx.dat:Remove.
3646 * regformats/i386/amd64-avx.dat: Remove.
3647 * regformats/i386/amd64-mpx.dat: Remove.
3648 * regformats/i386/i386-avx-avx512.dat: Remove.
3649 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3650 * regformats/i386/i386-avx-mpx.dat: Remove.
3651 * regformats/i386/i386-mmx.dat: Remove.
3652 * regformats/i386/i386-mpx.dat: Remove.
3653
3654 2017-08-09 Yao Qi <yao.qi@linaro.org>
3655
3656 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3657 * amd64-tdep.c: Don't include features/i386/x32*.c.
3658 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3659 functions.
3660 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3661 and i386/x32-avx-avx512.
3662 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3663 and i386/x32.xml.
3664 * features/i386/x32-avx-avx512.c: Removed.
3665 * features/i386/x32-avx-avx512.xml: Removed.
3666 * features/i386/x32-avx.c: Removed.
3667 * features/i386/x32-avx.xml: Removed.
3668 * features/i386/x32.c: Removed.
3669 * features/i386/x32.xml: Removed.
3670 * regformats/i386/x32-avx-avx512.dat: Removed.
3671 * regformats/i386/x32-avx.dat: Removed.
3672 * regformats/i386/x32.dat: Removed.
3673
3674 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3675
3676 PR breakpoints/21886
3677 * mem-break.c (default_memory_insert_breakpoint): Use
3678 `->placed_address' rather than `->reqstd_address' for the
3679 breakpoint location.
3680
3681 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3682
3683 * arch-utils.c (default_print_insn): Remove arch/mach/endian
3684 assertions.
3685
3686 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3687
3688 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
3689 a union of `tdep_info', `tdesc_data' and `id'.
3690 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
3691 rather than `info.tdep_info'.
3692 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
3693 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
3694 * i386-tdep.c (i386_gdbarch_init): Likewise.
3695 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
3696 * mips-tdep.c (mips_gdbarch_init): Likewise.
3697 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
3698 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
3699 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
3700 `info.tdep_info'.
3701 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
3702 `info.tdep_info'.
3703 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
3704 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
3705 `info.tdep_info'.
3706 * spu-tdep.c (spu_gdbarch_init): Likewise.
3707 * gdbarch.h: Regenerate.
3708
3709 2017-08-07 Leszek Swirski <leszeks@google.com>
3710
3711 PR symtab/20899
3712 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
3713
3714 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
3715
3716 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
3717 (gdbsim_open): Rename gdb_argv args object to argv.
3718
3719 2017-08-05 Tom Tromey <tom@tromey.com>
3720
3721 * compile/compile-object-load.c (compile_object_load): Use
3722 gdb::unique_xmalloc_ptr.
3723 * cli/cli-dump.c (scan_filename): Rename from
3724 scan_filename_with_cleanup. Change return type.
3725 (scan_expression): Rename from scan_expression_with_cleanup.
3726 Change return type.
3727 (dump_memory_to_file, dump_value_to_file, restore_command):
3728 Use gdb::unique_xmalloc_ptr. Update.
3729 * cli/cli-cmds.c (find_and_open_script): Use
3730 gdb::unique_xmalloc_ptr.
3731 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
3732 * symmisc.c (maintenance_print_symbols)
3733 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
3734 * symfile.c (symfile_bfd_open, generic_load)
3735 (add_symbol_file_command, remove_symbol_file_command): Use
3736 gdb::unique_xmalloc_ptr.
3737 * source.c (openp): Use gdb::unique_xmalloc_ptr.
3738 * psymtab.c (maintenance_print_psymbols): Use
3739 gdb::unique_xmalloc_ptr.
3740 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
3741 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
3742 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
3743 (reload_shared_libraries_1): Likewise.
3744
3745 2017-08-05 Tom Tromey <tom@tromey.com>
3746
3747 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
3748 (rust_op_vector, rust_set_vector): New typedefs.
3749 (current_parser): New global.
3750 (work_obstack): Change to pointer type. Update all users.
3751 (rust_ast, pstate): Remove globals.
3752 (struct rust_parser): New.
3753 (%union) <params, field_inits>: Change type.
3754 (start, tuple_expr, unit_expr, struct_expr_list, literal)
3755 (field_expr, expr_list, maybe_expr_list, type_list): Update.
3756 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
3757 (convert_params_to_types, convert_params_to_expression): Change
3758 type of "params".
3759 (ast_string): Change type of "fields".
3760 (rust_parse): Make a rust_parser. Remove cleanups.
3761 (rust_lex_tests): Make and install an auto_obstack.
3762
3763 2017-08-04 Yao Qi <yao.qi@linaro.org>
3764
3765 * configure.srv (ipa_x32_linux_regobj): New.
3766 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
3767 instead of X86_TDESC_AVX512.
3768 (initialize_low_tracepoint): Call
3769 init_registers_x32_avx_avx512_linux.
3770
3771 2017-08-04 Yao Qi <yao.qi@linaro.org>
3772
3773 * utils.h (gdb_argv): Add namespace std for nullptr_t.
3774
3775 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
3776
3777 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
3778
3779 2017-08-03 Tom Tromey <tom@tromey.com>
3780
3781 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
3782 Remove.
3783 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
3784
3785 2017-08-03 Tom Tromey <tom@tromey.com>
3786
3787 * python/py-param.c (compute_enum_values): Use gdb_argv.
3788
3789 2017-08-03 Tom Tromey <tom@tromey.com>
3790
3791 * utils.h (struct gdb_argv_deleter): New.
3792 (gdb_argv): New class.
3793 * utils.c (gdb_argv::reset): New method.
3794 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
3795 * tracefile.c (tsave_command): Use gdb_argv.
3796 * top.c (new_ui_command): Use gdb_argv.
3797 * symmisc.c (maintenance_print_symbols)
3798 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
3799 * symfile.c (symbol_file_command, generic_load)
3800 (remove_symbol_file_command): Use gdb_argv.
3801 * stack.c (backtrace_command): Use gdb_argv.
3802 * source.c (add_path, show_substitute_path_command)
3803 (unset_substitute_path_command, set_substitute_path_command):
3804 Use gdb_argv.
3805 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
3806 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
3807 * remote.c (extended_remote_run, remote_put_command)
3808 (remote_get_command, remote_delete_command): Use gdb_argv.
3809 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
3810 (gdbsim_open): Use gdb_argv.
3811 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
3812 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
3813 * procfs.c (procfs_info_proc): Use gdb_argv.
3814 * interps.c (interpreter_exec_cmd): Use gdb_argv.
3815 * infrun.c (handle_command): Use gdb_argv.
3816 * inferior.c (add_inferior_command, clone_inferior_command):
3817 Use gdb_argv.
3818 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
3819 * exec.c (exec_file_command): Use gdb_argv.
3820 * cli/cli-cmds.c (alias_command): Use gdb_argv.
3821 * compile/compile.c (build_argc_argv): Use gdb_argv.
3822
3823 2017-08-03 Tom Tromey <tom@tromey.com>
3824
3825 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
3826
3827 2017-08-03 Tom Tromey <tom@tromey.com>
3828
3829 * python/python.c (compute_python_string): Return std::string.
3830 (gdbpy_eval_from_control_command): Update.
3831 (do_start_initialization): Use std::string.
3832 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
3833 xstrprintf.
3834 * python/py-breakpoint.c (local_setattro): Use string_printf, not
3835 xstrprintf.
3836
3837 2017-08-03 Tom Tromey <tom@tromey.com>
3838
3839 * top.h (do_restore_instream_cleanup): Remove.
3840 * top.c (do_restore_instream_cleanup): Remove.
3841 (read_command_file): Use scoped_restore.
3842 * cli/cli-script.c (execute_user_command): Use scoped_restore.
3843
3844 2017-08-03 Tom Tromey <tom@tromey.com>
3845
3846 * cli/cli-script.c (execute_user_command)
3847 (execute_control_command): Use scoped_restore.
3848
3849 2017-08-03 Tom Tromey <tom@tromey.com>
3850
3851 * cli/cli-script.c (do_restore_user_call_depth): Remove.
3852 (execute_user_command): Remove user_call_depth; use
3853 user_args_stack's size instead.
3854
3855 2017-08-03 Tom Tromey <tom@tromey.com>
3856
3857 * top.h (in_user_command): Remove.
3858 * top.c (in_user_command): Remove.
3859 * cli/cli-script.c (do_restore_user_call_depth)
3860 (execute_user_command): Update.
3861
3862 2017-08-03 Tom Tromey <tom@tromey.com>
3863
3864 * valops.c (search_struct_method): Use gdb::byte_vector.
3865 * valarith.c (value_concat): Use std::vector.
3866 * target.c (memory_xfer_partial): Use gdb::byte_vector.
3867 (simple_search_memory): Likewise.
3868 * printcmd.c (find_string_backward): Use gdb::byte_vector.
3869 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
3870 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
3871 * elfread.c (elf_rel_plt_read): Use std::string.
3872 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
3873 * cli/cli-dump.c (restore_section_callback): Use
3874 gdb::byte_vector.
3875
3876 2017-08-03 Tom Tromey <tom@tromey.com>
3877
3878 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
3879
3880 2017-08-03 Tom Tromey <tom@tromey.com>
3881
3882 * tui/tui-regs.c (tui_restore_gdbout): Remove.
3883 (tui_register_format): Use scoped_restore.
3884
3885 2017-08-03 Tom Tromey <tom@tromey.com>
3886
3887 * reverse.c (exec_direction_default): Remove.
3888 (exec_reverse_once): Use scoped_restore.
3889 * remote.c (restore_remote_timeout): Remove.
3890 (remote_flash_erase, remote_flash_write, remote_flash_done)
3891 (readchar, remote_serial_write): Use scoped_restore.
3892 * cli/cli-script.c (struct source_cleanup_lines_args)
3893 (source_cleanup_lines): Remove.
3894 (script_from_file): Use scoped_restore.
3895 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
3896 (source_command): Use scoped_restore.
3897
3898 2017-08-03 Tom Tromey <tom@tromey.com>
3899
3900 * utils.h (make_cleanup_free_so): Remove.
3901 * utils.c (do_free_so, make_cleanup_free_so): Remove.
3902 * solist.h (struct so_deleter): New.
3903 (so_list_up): New typedef.
3904 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
3905
3906 2017-08-03 Tom Tromey <tom@tromey.com>
3907
3908 * utils.h (make_cleanup_restore_current_language): Remove.
3909 * utils.c (do_restore_current_language)
3910 (make_cleanup_restore_current_language): Remove.
3911 * parse.c (parse_exp_in_context_1)
3912 (parse_expression_with_language): Use
3913 scoped_restore_current_language.
3914 * mi/mi-main.c (mi_cmd_execute): Use
3915 scoped_restore_current_language.
3916 * language.h (scoped_restore_current_language): New class.
3917
3918 2017-08-03 Tom Tromey <tom@tromey.com>
3919
3920 * compile/compile.c (cleanup_unlink_file): Remove.
3921 (compile_to_object): Use gdb::unlinker.
3922 (eval_compile_command): Likewise.
3923
3924 2017-08-03 Tom Tromey <tom@tromey.com>
3925
3926 * utils.h (make_cleanup_fclose): Remove.
3927 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
3928
3929 2017-08-03 Tom Tromey <tom@tromey.com>
3930
3931 * top.c (open_terminal_stream): Return gdb_file_up.
3932 (new_ui_command): Update.
3933
3934 2017-08-03 Tom Tromey <tom@tromey.com>
3935
3936 * source.c (print_source_lines_base, forward_search_command)
3937 (reverse_search_command): Use gdb_file_up.
3938
3939 2017-08-03 Tom Tromey <tom@tromey.com>
3940
3941 * fbsd-nat.c (fbsd_find_memory_regions): Update.
3942
3943 2017-08-03 Tom Tromey <tom@tromey.com>
3944
3945 * cli/cli-cmds.c (find_and_open_script): Change return type.
3946 Remove "streamp" and "full_path" parameters.
3947 (source_script_with_search): Update.
3948 * auto-load.c (source_script_file): Update.
3949 * cli/cli-cmds.h (find_and_open_script): Change type.
3950 (open_script): New struct.
3951
3952 2017-08-03 Tom Tromey <tom@tromey.com>
3953
3954 * xml-support.c (xml_fetch_content_from_file): Update.
3955 * ui-file.c (stdio_file::open): Update.
3956 * tracefile-tfile.c (tfile_start): Update.
3957 * remote.c (remote_file_put, remote_file_get): Update.
3958 * nat/linux-procfs.c (linux_proc_get_int)
3959 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
3960 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
3961 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
3962 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
3963 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
3964 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
3965 * linux-nat.c (linux_proc_pending_signals): Update.
3966 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
3967 (file_closer): Remove.
3968 * compile/compile.c (compile_to_object): Update.
3969 * common/filestuff.h (struct gdb_file_deleter): New.
3970 (gdb_file_up): New typedef.
3971 (gdb_fopen_cloexec): Change return type.
3972 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
3973 * cli/cli-dump.c (fopen_with_cleanup): Remove.
3974 (dump_binary_file, restore_binary_file): Update.
3975 * auto-load.c (auto_load_objfile_script_1): Update.
3976
3977 2017-08-03 Tom Tromey <tom@tromey.com>
3978
3979 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
3980 (info_static_tracepoint_markers_command): Likewise.
3981 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
3982 * skip.c (skip_info): Use ui_out_emit_table.
3983 * progspace.c (print_program_space): Use ui_out_emit_table.
3984 * osdata.c (info_osdata): Use ui_out_emit_table.
3985 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
3986 ui_out_emit_table.
3987 * linux-thread-db.c (info_auto_load_libthread_db): Use
3988 ui_out_emit_table.
3989 * inferior.c (print_inferior): Use ui_out_emit_table.
3990 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
3991 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
3992 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
3993 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
3994 * ui-out.h (class ui_out_emit_table): New.
3995
3996 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
3997
3998 * mips-tdep.c (mips_fpu_type_str): New function.
3999 (mips_dump_tdep): Call it.
4000
4001 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
4002
4003 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
4004 `->mips_fpu_type'.
4005
4006 2017-07-31 Xavier Roirand <roirand@adacore.com>
4007
4008 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
4009
4010 2017-07-27 Xavier Roirand <roirand@adacore.com>
4011
4012 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
4013
4014 2017-07-26 Yao Qi <yao.qi@linaro.org>
4015
4016 * cli/cli-cmds.c (maintenancechecklist): New variable.
4017 * gdbcmd.h (maintenancechecklist): Declare it.
4018 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
4019 Call i386_linux_read_description with different masks.
4020 * maint.c (maintenance_check_command): New function.
4021 (_initialize_maint_cmds): Call add_prefix_cmd.
4022 * target-descriptions.c (tdesc_reg): override operator != and ==.
4023 (tdesc_type): Likewise.
4024 (tdesc_feature): Likewise.
4025 (target_desc): Likewise.
4026 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
4027 (maintenance_check_xml_descriptions): New function.
4028 (_initialize_target_descriptions) Add command "xml-descriptions".
4029 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
4030
4031 2017-07-26 Yao Qi <yao.qi@linaro.org>
4032
4033 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
4034 Include features/i386/32bit-*.c.
4035 (i386_linux_read_description): Generate target description if it
4036 doesn't exist.
4037 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
4038 functions.
4039 * features/i386/32bit-linux.c: Re-generated.
4040 * features/i386/32bit-sse.c: Likewise.
4041 * target-descriptions.c (print_c_feature::visit): Print code to
4042 set register number if needed.
4043 (print_c_feature) <m_next_regnum>: New field.
4044
4045 2017-07-26 Yao Qi <yao.qi@linaro.org>
4046
4047 * features/Makefile (CFILES): Rename with TDESC_CFILES.
4048 (FEATURE_XMLFILES): New.
4049 (FEATURE_CFILES): New.
4050 New rules.
4051 (clean-cfiles): Remove generated c files.
4052 * features/i386/32bit-avx.c: Generated.
4053 * features/i386/32bit-avx512.c: Generated.
4054 * features/i386/32bit-core.c: Generated.
4055 * features/i386/32bit-linux.c: Generated.
4056 * features/i386/32bit-mpx.c: Generated.
4057 * features/i386/32bit-pkeys.c: Generated.
4058 * features/i386/32bit-sse.c: Generated.
4059 * target-descriptions.c: Include algorithm.
4060 (tdesc_element_visitor): Add method visit_end.
4061 (print_c_tdesc): Implement visit_end.
4062 (print_c_tdesc:: m_filename_after_features): Move it to
4063 protected.
4064 (print_c_feature): New class.
4065 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
4066 name starts with "i386/32bit-".
4067
4068 2017-07-26 Yao Qi <yao.qi@linaro.org>
4069
4070 * target-descriptions.c (tdesc_element_visitor): New class.
4071 (tdesc_element): New class.
4072 (tdesc_reg): Inherit from tdesc_element.
4073 (tdesc_reg::accept): New function.
4074 (tdesc_type): Inherit from tdesc_element.
4075 (tdesc_type::accept): New function.
4076 (tdesc_feature): Inherit from tdesc_element.
4077 (tdesc_feature::accept): New function.
4078 (target_desc): Inherit from tdesc_element.
4079 (target_desc::target_desc): New.
4080 (target_desc::~target_desc): New.
4081 (target_desc::accept): New.
4082 (allocate_target_description): Use new.
4083 (free_target_description): Use delete.
4084 (print_c_tdesc): New class.
4085 (maint_print_c_tdesc_cmd): Adjust.
4086
4087 * features/aarch64.c: Re-generated.
4088 * features/arc-arcompact.c: Re-generated.
4089 * features/arc-v2.c: Re-generated.
4090 * features/arm/arm-with-iwmmxt.c: Re-generated.
4091 * features/arm/arm-with-m.c: Re-generated.
4092 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
4093 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
4094 * features/arm/arm-with-neon.c: Re-generated.
4095 * features/arm/arm-with-vfpv2.c: Re-generated.
4096 * features/arm/arm-with-vfpv3.c: Re-generated.
4097 * features/i386/amd64-avx-avx512.c: Re-generated.
4098 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4099 * features/i386/amd64-avx.c: Re-generated.
4100 * features/i386/amd64-avx-linux.c: Re-generated.
4101 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
4102 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4103 * features/i386/amd64-avx-mpx.c: Re-generated.
4104 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
4105 * features/i386/amd64.c: Re-generated.
4106 * features/i386/amd64-linux.c: Re-generated.
4107 * features/i386/amd64-mpx.c: Re-generated.
4108 * features/i386/amd64-mpx-linux.c: Re-generated.
4109 * features/i386/i386-avx-avx512.c: Re-generated.
4110 * features/i386/i386-avx-avx512-linux.c: Re-generated.
4111 * features/i386/i386-avx.c: Re-generated.
4112 * features/i386/i386-avx-linux.c: Re-generated.
4113 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
4114 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
4115 * features/i386/i386-avx-mpx.c: Re-generated.
4116 * features/i386/i386-avx-mpx-linux.c: Re-generated.
4117 * features/i386/i386.c: Re-generated.
4118 * features/i386/i386-linux.c: Re-generated.
4119 * features/i386/i386-mmx.c: Re-generated.
4120 * features/i386/i386-mmx-linux.c: Re-generated.
4121 * features/i386/i386-mpx.c: Re-generated.
4122 * features/i386/i386-mpx-linux.c: Re-generated.
4123 * features/i386/x32-avx-avx512.c: Re-generated.
4124 * features/i386/x32-avx-avx512-linux.c: Re-generated.
4125 * features/i386/x32-avx.c: Re-generated.
4126 * features/i386/x32-avx-linux.c: Re-generated.
4127 * features/i386/x32.c: Re-generated.
4128 * features/i386/x32-linux.c: Re-generated.
4129 * features/microblaze.c: Re-generated.
4130 * features/microblaze-with-stack-protect.c: Re-generated.
4131 * features/mips64-dsp-linux.c: Re-generated.
4132 * features/mips64-linux.c: Re-generated.
4133 * features/mips-dsp-linux.c: Re-generated.
4134 * features/mips-linux.c: Re-generated.
4135 * features/nds32.c: Re-generated.
4136 * features/nios2.c: Re-generated.
4137 * features/nios2-linux.c: Re-generated.
4138 * features/rs6000/powerpc-32.c: Re-generated.
4139 * features/rs6000/powerpc-32l.c: Re-generated.
4140 * features/rs6000/powerpc-403.c: Re-generated.
4141 * features/rs6000/powerpc-403gc.c : Re-generated.
4142 * features/rs6000/powerpc-405.c: Re-generated.
4143 * features/rs6000/powerpc-505.c: Re-generated.
4144 * features/rs6000/powerpc-601.c: Re-generated.
4145 * features/rs6000/powerpc-602.c: Re-generated.
4146 * features/rs6000/powerpc-603.c: Re-generated.
4147 * features/rs6000/powerpc-604.c: Re-generated.
4148 * features/rs6000/powerpc-64.c: Re-generated.
4149 * features/rs6000/powerpc-64l.c: Re-generated.
4150 * features/rs6000/powerpc-7400.c: Re-generated.
4151 * features/rs6000/powerpc-750.c: Re-generated.
4152 * features/rs6000/powerpc-860.c: Re-generated.
4153 * features/rs6000/powerpc-altivec32.c: Re-generated.
4154 * features/rs6000/powerpc-altivec32l.c: Re-generated.
4155 * features/rs6000/powerpc-altivec64.c: Re-generated.
4156 * features/rs6000/powerpc-altivec64l.c: Re-generated.
4157 * features/rs6000/powerpc-cell32l.c: Re-generated.
4158 * features/rs6000/powerpc-cell64l.c: Re-generated.
4159 * features/rs6000/powerpc-e500.c: Re-generated.
4160 * features/rs6000/powerpc-e500l.c: Re-generated.
4161 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
4162 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
4163 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
4164 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
4165 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
4166 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
4167 * features/rs6000/powerpc-vsx32.c: Re-generated.
4168 * features/rs6000/powerpc-vsx32l.c: Re-generated.
4169 * features/rs6000/powerpc-vsx64.c: Re-generated.
4170 * features/rs6000/powerpc-vsx64l.c: Re-generated.
4171 * features/rs6000/rs6000.c: Re-generated.
4172 * features/s390-linux32.c: Re-generated.
4173 * features/s390-linux32v1.c: Re-generated.
4174 * features/s390-linux32v2.c: Re-generated.
4175 * features/s390-linux64.c: Re-generated.
4176 * features/s390-linux64v1.c: Re-generated.
4177 * features/s390-linux64v2.c: Re-generated.
4178 * features/s390-te-linux64.c: Re-generated.
4179 * features/s390-tevx-linux64.c: Re-generated.
4180 * features/s390-vx-linux64.c: Re-generated.
4181 * features/s390x-linux64.c: Re-generated.
4182 * features/s390x-linux64v1.c: Re-generated.
4183 * features/s390x-linux64v2.c: Re-generated.
4184 * features/s390x-te-linux64.c: Re-generated.
4185 * features/s390x-tevx-linux64.c: Re-generated.
4186 * features/s390x-vx-linux64.c: Re-generated.
4187 * features/sparc/sparc32-solaris.c: Re-generated.
4188 * features/sparc/sparc64-solaris.c: Re-generated.
4189 * features/tic6x-c62x.c: Re-generated.
4190 * features/tic6x-c62x-linux.c: Re-generated.
4191 * features/tic6x-c64x.c: Re-generated.
4192 * features/tic6x-c64x-linux.c: Re-generated.
4193 * features/tic6x-c64xp.c: Re-generated.
4194 * features/tic6x-c64xp-linux.c: Re-generated.
4195
4196 2017-07-26 Yao Qi <yao.qi@linaro.org>
4197
4198 * i386-linux-tdep.c (i386_linux_read_description): New function.
4199 (i386_linux_core_read_description): Call
4200 i386_linux_read_description.
4201 * i386-linux-tdep.h (i386_linux_read_description): Declare.
4202 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
4203 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
4204 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
4205 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
4206 * x86-linux-nat.c (x86_linux_read_description): Call
4207 i386_linux_read_description.
4208
4209 2017-07-26 Yao Qi <yao.qi@linaro.org>
4210
4211 * NEWS: Mention it.
4212 * features/Makefile (%.c: %.xml): Pass the xml file name to
4213 command "maint print c-tdesc".
4214 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
4215 name from 'arg'.
4216
4217 2017-07-26 Yao Qi <yao.qi@linaro.org>
4218
4219 * target-descriptions.c (target_desc): Add ctor and dtor. Do
4220 in-class initialization.
4221 (tdesc_create_feature): Call new instead of XCNEW.
4222 (free_target_description): Ue delete.
4223
4224 2017-07-25 John Baldwin <jhb@FreeBSD.org>
4225
4226 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
4227
4228 2017-07-25 Yao Qi <yao.qi@linaro.org>
4229
4230 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
4231 constant.
4232 (amd64_x32_init_abi): Likewise.
4233 * amd64-tdep.h (amd64_init_abi): Update declaration.
4234 (amd64_x32_init_abi): Likewise.
4235
4236 2017-07-25 Yao Qi <yao.qi@linaro.org>
4237
4238 PR tdep/21717
4239 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
4240 condition for FPSCR.
4241 (arm_linux_store_inferior_registers): Likewise.
4242
4243 2017-07-22 Tom Tromey <tom@tromey.com>
4244
4245 * break-catch-syscall.c (struct catch_syscall_inferior_data)
4246 <syscalls_counts>: Now a std::vector.
4247 (get_catch_syscall_inferior_data): Use "new".
4248 (catch_syscall_inferior_data_cleanup): Use "delete".
4249 (insert_catch_syscall, remove_catch_syscall)
4250 (clear_syscall_counts): Update.
4251
4252 2017-07-22 Tom Tromey <tom@tromey.com>
4253
4254 * break-catch-syscall.c (syscall_catchpoint)
4255 <syscalls_to_be_caught>: Now a std::vector<int>
4256 (~syscall_catchpoint): Remove.
4257 (insert_catch_syscall, remove_catch_syscall)
4258 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
4259 (print_mention_catch_syscall, print_recreate_catch_syscall):
4260 Update.
4261 (create_syscall_event_catchpoint): Change type of "filter"
4262 parameter.
4263 (catch_syscall_split_args): Return a std::vector.
4264 (catch_syscall_command_1, catching_syscall_number_1): Update.
4265
4266 2017-07-22 Tom Tromey <tom@tromey.com>
4267
4268 * break-catch-throw.c (struct exception_catchpoint)
4269 <exception_rx>: Now a std::string.
4270 (~exception_catchpoint): Remove.
4271 (print_one_detail_exception_catchpoint): Update.
4272 (handle_gnu_v3_exceptions): Change type of except_rx.
4273 (extract_exception_regexp): Return a std::string.
4274 (catch_exception_command_1): Update.
4275
4276 2017-07-22 Tom Tromey <tom@tromey.com>
4277
4278 * break-catch-sig.c (gdb_signal_type): Remove typedef.
4279 (struct signal_catchpoint) <signals_to_be_caught>: Now a
4280 std::vector.
4281 <catch_all>: Now a bool.
4282 (~signal_catchpoint): Remove.
4283 (signal_catchpoint_insert_location)
4284 (signal_catchpoint_remove_location)
4285 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
4286 (signal_catchpoint_print_mention)
4287 (signal_catchpoint_print_recreate)
4288 (signal_catchpoint_explains_signal): Update.
4289 (create_signal_catchpoint): Change type of "filter" and
4290 "catch_all".
4291 (catch_signal_split_args): Return a std::vector. Change type of
4292 "catch_all".
4293 (catch_signal_command): Update.
4294
4295 2017-07-20 Pedro Alves <palves@redhat.com>
4296
4297 * ada-lang.c (ada_language_defn): Make extern.
4298 (_initialize_ada_language): Remove add_language call.
4299 * c-lang.c (c_language_defn, cplus_language_defn)
4300 (asm_language_defn, minimal_language_defn): Make extern.
4301 (_initialize_c_language): Delete.
4302 * completer.c (compare_cstrings): Delete, moved to utils.h.
4303 * d-lang.c (d_language_defn): Make extern.
4304 (_initialize_d_language): Remove add_language calls.
4305 * defs.h (enum language): Add comment.
4306 * f-lang.c (f_language_defn): Make extern.
4307 (_initialize_f_language): Remove add_language call.
4308 * go-lang.c (go_language_defn): Make extern.
4309 (_initialize_go_language): Remove add_language call.
4310 * language.c: Include <algorithm>.
4311 (languages): Redefine as const array.
4312 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
4313 (set_language_command): Handle "local". Use for-range loop.
4314 (set_language): Remove loop.
4315 (language_enum): Rewrite.
4316 (language_def, language_str): Remove loops.
4317 (add_language): Delete.
4318 (add_set_language_command): New, based on add_languages.
4319 (skip_language_trampoline): Adjust.
4320 (local_language_defn): Delete.
4321 (language_gdbarch_post_init): Adjust.
4322 (_initialize_language): Remove add_language calls. Call
4323 add_set_language_command.
4324 * language.h (add_language): Delete.
4325 (auto_language_defn)
4326 (unknown_language_defn, minimal_language_defn, ada_language_defn)
4327 (asm_language_defn, c_language_defn, cplus_language_defn)
4328 (d_language_defn, f_language_defn, go_language_defn)
4329 (m2_language_defn, objc_language_defn, opencl_language_defn)
4330 (pascal_language_defn, rust_language_defn): Declare.
4331 * m2-lang.c (m2_language_defn): Make extern.
4332 (_initialize_m2_language): Remove add_language call.
4333 * objc-lang.c (objc_language_defn): Make extern.
4334 (_initialize_objc_language): Remove add_language call.
4335 * opencl-lang.c (opencl_language_defn): Make extern.
4336 (_initialize_opencl_language): Remove add_language call.
4337 * p-lang.c (pascal_language_defn): Make extern.
4338 (_initialize_pascal_language): Delete.
4339 * rust-lang.c (rust_language_defn): Make extern.
4340 (_initialize_rust_language): Delete.
4341 * utils.h (compare_cstrings): New static inline function.
4342
4343 2017-07-20 Pedro Alves <palves@redhat.com>
4344
4345 * ada-lang.c (ada_to_fixed_type_1): Adjust.
4346 (get_var_value): Constify parameters.
4347 (get_int_var_value): Change prototype.
4348 (to_fixed_range_type): Adjust.
4349 * ada-lang.h (get_int_var_value): Change prototype.
4350
4351 2017-07-20 Pedro Alves <palves@redhat.com>
4352
4353 * dwarf2read.c (dw2_lookup_symbol): Use
4354 SYMBOL_MATCHES_SEARCH_NAME.
4355 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
4356
4357 2017-07-20 Pedro Alves <palves@redhat.com>
4358
4359 * block.c (block_iter_name_step, block_iter_name_first)
4360 (block_iter_name_next): Delete.
4361 (block_lookup_symbol_primary): Adjust to use
4362 dict_iter_match_first/dict_iter_match_next.
4363 * block.h (block_iter_name_first, block_iter_name_next): Delete
4364 declarations.
4365 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
4366 dict_iter_match_first/dict_iter_match_next.
4367
4368 2017-07-20 Pedro Alves <palves@redhat.com>
4369
4370 * cp-support.c (cp_find_first_component_aux): Add missing case for
4371 end of string.
4372
4373 2017-07-18 David Blaikie <dblaikie@gmail.com>
4374
4375 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
4376 of dwo_cu's dwo_file.
4377
4378 2017-07-18 Yao Qi <yao.qi@linaro.org>
4379
4380 * remote.c (store_registers_using_G): Remove one line comment.
4381
4382 2017-07-18 Yao Qi <yao.qi@linaro.org>
4383
4384 * regcache.c (regcache_cpy): Simplify it.
4385 (regcache::cpy_no_passthrough): Remove it.
4386 * regcache.h (cpy_no_passthrough): Remove it.
4387 (regcache_dup, regcache_cpy): Update comments.
4388
4389 2017-07-18 Pedro Alves <palves@redhat.com>
4390
4391 * remote-sim.c (sim_command_completer): Adjust to work with a
4392 completion_tracker instead of a VEC.
4393
4394 2017-07-17 Pedro Alves <palves@redhat.com>
4395
4396 * completer.c (complete_source_filenames): New function.
4397 (complete_address_and_linespec_locations): New function.
4398 (location_completer): Use complete_address_and_linespec_locations.
4399 (completion_tracker::build_completion_result): Honor the tracker's
4400 request to suppress append.
4401 * completer.h (completion_tracker::suppress_append_ws)
4402 (completion_tracker::set_suppress_append_ws): New methods.
4403 (completion_tracker::m_suppress_append_ws): New field.
4404 (complete_source_filenames): New declaration.
4405 * linespec.c (linespec_complete_what): New.
4406 (struct ls_parser) <complete_what, completion_word,
4407 completion_quote_char, completion_quote_end, completion_tracker>:
4408 New fields.
4409 (string_find_incomplete_keyword_at_end): New.
4410 (linespec_lexer_lex_string): Record quote char. If in completion
4411 mode, don't throw.
4412 (linespec_lexer_consume_token): Advance the completion word point.
4413 (linespec_lexer_peek_token): Save/restore completion info.
4414 (save_stream_and_consume_token): New.
4415 (set_completion_after_number): New.
4416 (linespec_parse_basic): Set what to complete next depending on
4417 token. Handle function and label completions specially.
4418 (parse_linespec): Disable objc shortcut in completion mode. Set
4419 what to complete next depending on token type. Skip keyword if in
4420 completion mode.
4421 (complete_linespec_component, linespec_complete): New.
4422 * linespec.h (linespec_complete): Declare.
4423
4424 2017-07-17 Pedro Alves <palves@redhat.com>
4425
4426 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4427 Handle 'operator<' / 'operator<<'.
4428
4429 2017-07-17 Pedro Alves <palves@redhat.com>
4430
4431 * completer.c (collect_explicit_location_matches): Handle
4432 MATCH_LABEL.
4433 (convert_explicit_location_to_linespec): New, factored out from
4434 ...
4435 (convert_explicit_location_to_sals): ... this.
4436 (complete_label): New.
4437 (linespec_complete_label, find_label_symbols_in_block): New.
4438 (find_label_symbols): Add completion_mode parameter and adjust to
4439 call find_label_symbols_in_block.
4440 * linespec.h (linespec_complete_label): Declare.
4441
4442 2017-07-17 Pedro Alves <palves@redhat.com>
4443
4444 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4445 complete_symbol_mode parameter.
4446 * cli/cli-cmds.c (complete_command): Get the completion result out
4447 of the handle_brkchars tracker if used a custom word point.
4448 * completer.c: Include "linespec.h".
4449 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4450 (advance_to_expression_complete_word_point): New.
4451 (completion_tracker::completes_to_completion_word): New.
4452 (complete_files_symbols): Pass down
4453 complete_symbol_mode::EXPRESSION.
4454 (explicit_options, probe_options): New.
4455 (collect_explicit_location_matches): Complete on the
4456 explictit_loc->foo instead of word. Use
4457 linespec_complete_function. Handle MATCH_LINE. Handle offering
4458 keyword and options completions.
4459 (backup_text_ptr): Delete.
4460 (skip_keyword): New.
4461 (complete_explicit_location): Remove 'word' parameter. Add
4462 language, quoted_arg_start and quoted_arg_end parameters.
4463 Rewrite, parsing left to right.
4464 (location_completer): Rewrite.
4465 (location_completer_handle_brkchars): New function.
4466 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4467 (enum complete_line_internal_reason): Adjust comments.
4468 (completion_tracker::discard_completions): New.
4469 (completer_handle_brkchars_func_for_completer): Handle
4470 location_completer.
4471 (gdb_custom_word_point_brkchars)
4472 (gdb_org_rl_basic_quote_characters): New.
4473 (gdb_completion_word_break_characters_throw)
4474 (completion_find_completion_word): Handle trackers that use a
4475 custom word point.
4476 (completion_tracker::advance_custom_word_point_by): New.
4477 (completion_tracker::build_completion_result): Don't rely on
4478 readline appending the quote char.
4479 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4480 use a custom word point.
4481 (gdb_rl_attempted_completion_function): Restore
4482 rl_basic_quote_characters.
4483 * completer.h (class completion_tracker): Extend intro comment.
4484 (completion_tracker::set_quote_char)
4485 (completion_tracker::quote_char)
4486 (completion_tracker::set_use_custom_word_point)
4487 (completion_tracker::use_custom_word_point)
4488 (completion_tracker::custom_word_point)
4489 (completion_tracker::set_custom_word_point)
4490 (completion_tracker::advance_custom_word_point_by)
4491 (completion_tracker::completes_to_completion_word)
4492 (completion_tracker::discard_completions): New methods.
4493 (completion_tracker::m_quote_char)
4494 (completion_tracker::m_use_custom_word_point)
4495 (completion_tracker::m_custom_word_point): New fields.
4496 (advance_to_expression_complete_word_point): Declare.
4497 * f-lang.c (f_collect_symbol_completion_matches): Add
4498 complete_symbol_mode parameter.
4499 * language.h (struct language_defn)
4500 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4501 parameter.
4502 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4503 (linespec_complete_function): New function.
4504 (linespec_lexer_lex_keyword): Adjust.
4505 * linespec.h (linespec_keywords, linespec_complete_function): New
4506 declarations.
4507 * location.c (find_end_quote): New function.
4508 (explicit_location_lex_one): Add explicit_completion_info
4509 parameter. Save quoting info. Don't throw if being called for
4510 completion. Don't handle Ada operators here.
4511 (is_cp_operator, skip_op_false_positives, first_of)
4512 (explicit_location_lex_one_function): New function.
4513 (string_to_explicit_location): Replace 'dont_throw' parameter with
4514 an explicit_completion_info pointer parameter. Handle it. Don't
4515 use explicit_location_lex_one to lex function names. Use
4516 explicit_location_lex_one_function instead.
4517 * location.h (struct explicit_completion_info): New.
4518 (string_to_explicit_location): Replace 'dont_throw' parameter with
4519 an explicit_completion_info pointer parameter.
4520 * symtab.c (default_collect_symbol_completion_matches_break_on):
4521 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4522 (default_collect_symbol_completion_matches)
4523 (collect_symbol_completion_matches): Add complete_symbol_mode
4524 parameter.
4525 (collect_symbol_completion_matches_type): Pass down
4526 complete_symbol_mode::EXPRESSION.
4527 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4528 parameter. Handle LINESPEC mode.
4529 * symtab.h (complete_symbol_mode): New.
4530 (default_collect_symbol_completion_matches_break_on)
4531 (default_collect_symbol_completion_matches)
4532 (collect_symbol_completion_matches)
4533 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4534 parameter.
4535
4536 2017-07-17 Pedro Alves <palves@redhat.com>
4537
4538 * utils.c (enum class strncmp_iw_mode): New.
4539 (strcmp_iw): Rename to ...
4540 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4541 parameters. Handle them.
4542 (strncmp_iw): New.
4543 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4544 * utils.h (strncmp_iw): Declare.
4545 (strcmp_iw): Move describing comments here.
4546
4547 2017-07-17 Pedro Alves <palves@redhat.com>
4548
4549 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4550 CP_OPERATOR_STR.
4551 * c-typeprint.c (is_type_conversion_operator): Use
4552 CP_OPERATOR_STR.
4553 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4554 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4555 CP_OPERATOR_LEN.
4556 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4557 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4558 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4559 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4560 CP_OPERATOR_STR.
4561 * location.c: Include "cp-support.h".
4562 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4563 CP_OPERATOR_STR.
4564 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4565 CP_OPERATOR_LEN.
4566
4567 2017-07-17 Pedro Alves <palves@redhat.com>
4568
4569 * cli/cli-cmds.c (complete_command): Use a completion tracker
4570 along with completion_find_completion_word for handle_brkchars
4571 phase.
4572 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4573 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4574 (struct gdb_rl_completion_word_info): New.
4575 (gdb_rl_find_completion_word): New.
4576 (completion_find_completion_word): New.
4577 * completer.h (completion_find_completion_word): Declare.
4578
4579 2017-07-17 Pedro Alves <palves@redhat.com>
4580
4581 * ada-lang.c (symbol_completion_match): Adjust comments.
4582 (symbol_completion_add): Replace vector parameter with
4583 completion_tracker parameter. Use it.
4584 (ada_make_symbol_completion_list): Rename to...
4585 (ada_collect_symbol_completion_matches): ... this. Add
4586 completion_tracker parameter and use it.
4587 (ada_language_defn): Adjust.
4588 * break-catch-syscall.c (catch_syscall_completer): Adjust
4589 prototype and work with completion_tracker instead of VEC.
4590 * breakpoint.c (condition_completer): Adjust prototype and work
4591 with completion_tracker instead of VEC.
4592 * c-lang.c (c_language_defn, cplus_language_defn)
4593 (asm_language_defn, minimal_language_defn): Adjust to renames.
4594 * cli/cli-cmds.c (complete_command): Rework using
4595 completion_tracker. Catch exceptions when completing.
4596 * cli/cli-decode.c (integer_unlimited_completer)
4597 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4598 with completion_tracker instead of VEC.
4599 * command.h (struct completion_tracker): Forward declare.
4600 (completer_ftype, completer_handle_brkchars_ftype): Change
4601 types.
4602 (complete_on_cmdlist, complete_on_enum): Adjust.
4603 * completer.c: Include <algorithm>.
4604 (struct gdb_completer_state): New.
4605 (current_completion): New global.
4606 (readline_line_completion_function): Delete.
4607 (noop_completer, filename_completer)
4608 (filename_completer_handle_brkchars, complete_files_symbols)
4609 (linespec_location_completer): Adjust to work with a
4610 completion_tracker instead of a VEC.
4611 (string_or_empty): New.
4612 (collect_explicit_location_matches): Adjust to work with a
4613 completion_tracker instead of a VEC.
4614 (explicit_location_completer): Rename to ...
4615 (complete_explicit_location): ... this and adjust to work with a
4616 completion_tracker instead of a VEC.
4617 (location_completer): Adjust to work with a completion_tracker
4618 instead of a VEC.
4619 (add_struct_fields): Adjust to work with a completion_list instead
4620 of VEC.
4621 (expression_completer): Rename to ...
4622 (complete_expression): ... this and adjust to work with a
4623 completion_tracker instead of a VEC. Use complete_files_symbols.
4624 (expression_completer): Reimplement on top of complete_expression.
4625 (symbol_completer): Adjust to work with a completion_tracker
4626 instead of a VEC.
4627 (enum complete_line_internal_reason): Add describing comments.
4628 (complete_line_internal_normal_command): Adjust to work with a
4629 completion_tracker instead of a VEC.
4630 (complete_line_internal): Rename to ...
4631 (complete_line_internal_1): ... this and adjust to work with a
4632 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4633 handle_brkchars phase.
4634 (new_completion_tracker): Delete.
4635 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4636 complete_line_internal_1.
4637 (free_completion_tracker): Delete.
4638 (INITIAL_COMPLETION_HTAB_SIZE): New.
4639 (completion_tracker::completion_tracker)
4640 (completion_tracker::~completion_tracker): New.
4641 (maybe_add_completion): Delete.
4642 (completion_tracker::maybe_add_completion)
4643 (completion_tracker::add_completion)
4644 (completion_tracker::add_completions): New.
4645 (throw_max_completions_reached_error): Delete.
4646 (complete_line): Adjust to work with a completion_tracker instead
4647 of a VEC. Don't create a completion_tracker_t or check for max
4648 completions here.
4649 (command_completer, command_completer_handle_brkchars)
4650 (signal_completer, reg_or_group_completer_1)
4651 (reg_or_group_completer, default_completer_handle_brkchars):
4652 Adjust to work with a completion_tracker.
4653 (gdb_completion_word_break_characters_throw): New.
4654 (gdb_completion_word_break_characters): Reimplement.
4655 (line_completion_function): Delete.
4656 (completion_tracker::recompute_lowest_common_denominator)
4657 (expand_preserving_ws)
4658 (completion_tracker::build_completion_result)
4659 (completion_result::completion_result)
4660 (completion_result::completion_result)
4661 (completion_result::~completion_result)
4662 (completion_result::completion_result)
4663 (completion_result::release_match_list, compare_cstrings)
4664 (completion_result::sort_match_list)
4665 (completion_result::reset_match_list)
4666 (gdb_rl_attempted_completion_function_throw)
4667 (gdb_rl_attempted_completion_function): New.
4668 * completer.h (completion_list, struct completion_result)
4669 (class completion_tracker): New.
4670 (complete_line): Add completion_tracker parameter.
4671 (readline_line_completion_function): Delete.
4672 (gdb_rl_attempted_completion_function): New.
4673 (noop_completer, filename_completer, expression_completer)
4674 (location_completer, symbol_completer, command_completer)
4675 (signal_completer, reg_or_group_completer): Update prototypes.
4676 (completion_tracker_t, new_completion_tracker)
4677 (make_cleanup_free_completion_tracker): Delete.
4678 (enum maybe_add_completion_enum): Delete.
4679 (maybe_add_completion): Delete.
4680 (throw_max_completions_reached_error): Delete.
4681 * corefile.c (complete_set_gnutarget): Adjust to work with a
4682 completion_tracker instead of a VEC.
4683 * cp-abi.c (cp_abi_completer): Adjust to work with a
4684 completion_tracker instead of a VEC.
4685 * d-lang.c (d_language_defn): Adjust.
4686 * disasm.c (disassembler_options_completer): Adjust to work with a
4687 completion_tracker instead of a VEC.
4688 * f-lang.c (f_make_symbol_completion_list): Rename to ...
4689 (f_collect_symbol_completion_matches): ... this. Adjust to work
4690 with a completion_tracker instead of a VEC.
4691 (f_language_defn): Adjust.
4692 * go-lang.c (go_language_defn): Adjust.
4693 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
4694 Adjust to work with a completion_tracker instead of a VEC.
4695 * infrun.c (handle_completer): Likewise.
4696 * interps.c (interpreter_completer): Likewise.
4697 * interps.h (interpreter_completer): Likewise.
4698 * language.c (unknown_language_defn, auto_language_defn)
4699 (local_language_defn): Adjust.
4700 * language.h (language_defn::la_make_symbol_completion_list):
4701 Rename to ...
4702 (language_defn::la_collect_symbol_completion_matches): ... this
4703 and adjust to work with a completion_tracker instead of a VEC.
4704 * m2-lang.c (m2_language_defn): Adjust.
4705 * objc-lang.c (objc_language_defn): Adjust.
4706 * opencl-lang.c (opencl_language_defn): Adjust.
4707 * p-lang.c (pascal_language_defn): Adjust.
4708 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
4709 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
4710 with a completion_tracker.
4711 * rust-lang.c (rust_language_defn): Adjust.
4712 * symtab.c (free_completion_list, do_free_completion_list)
4713 (return_val, completion_tracker): Delete.
4714 (completion_list_add_name, completion_list_add_symbol)
4715 (completion_list_add_msymbol, completion_list_objc_symbol)
4716 (completion_list_add_fields, add_symtab_completions): Add
4717 completion_tracker parameter and use it.
4718 (default_make_symbol_completion_list_break_on_1): Rename to...
4719 (default_collect_symbol_completion_matches_break_on): ... this.
4720 Add completion_tracker parameter and use it instead of allocating
4721 a completion tracker here.
4722 (default_make_symbol_completion_list_break_on): Delete old
4723 implementation.
4724 (default_make_symbol_completion_list): Delete.
4725 (default_collect_symbol_completion_matches): New.
4726 (make_symbol_completion_list): Delete.
4727 (collect_symbol_completion_matches): New.
4728 (make_symbol_completion_type): Rename to ...
4729 (collect_symbol_completion_matches_type): ... this. Add
4730 completion_tracker parameter and use it instead of VEC.
4731 (make_file_symbol_completion_list_1): Rename to...
4732 (collect_file_symbol_completion_matches): ... this. Add
4733 completion_tracker parameter and use it instead of VEC.
4734 (make_file_symbol_completion_list): Delete.
4735 (add_filename_to_list): Use completion_list instead of a VEC.
4736 (add_partial_filename_data::list): Now a completion_list.
4737 (make_source_files_completion_list): Work with a completion_list
4738 instead of a VEC.
4739 * symtab.h: Include "completer.h".
4740 (default_make_symbol_completion_list_break_on)
4741 (default_make_symbol_completion_list, make_symbol_completion_list)
4742 (make_symbol_completion_type, make_file_symbol_completion_list)
4743 (make_source_files_completion_list): Delete.
4744 (default_collect_symbol_completion_matches_break_on)
4745 (default_collect_symbol_completion_matches)
4746 (collect_symbol_completion_matches)
4747 (collect_symbol_completion_matches_type)
4748 (collect_file_symbol_completion_matches)
4749 (make_source_files_completion_list): New.
4750 * top.c (init_main): Don't install a rl_completion_entry_function
4751 hook. Install a rl_attempted_completion_function hook instead.
4752 * tui/tui-layout.c (layout_completer): Adjust to work with a
4753 completion_tracker.
4754 * tui/tui-regs.c (tui_reggroup_completer):
4755 * tui/tui-win.c (window_name_completer, focus_completer)
4756 (winheight_completer): Adjust to work with a completion_tracker.
4757 * value.c: Include "completer.h".
4758 (complete_internalvar): Adjust to work with a completion_tracker.
4759 * value.h (complete_internalvar): Likewise.
4760
4761 2017-07-17 Pedro Alves <palves@redhat.com>
4762
4763 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
4764 renames.
4765 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
4766 comments to completer_ftype's declaration.
4767 <completer_handle_brkchars>: Change type to
4768 completer_handle_brkchars_ftype.
4769 * command.h (completer_ftype): Add describing comment and give
4770 names to parameters.
4771 (completer_ftype_void): Rename to ...
4772 (completer_handle_brkchars_ftype) ... this. Add describing comment.
4773 (set_cmd_completer_handle_brkchars): Adjust.
4774 * completer.c (filename_completer_handle_brkchars): New function.
4775 (complete_line_internal_normal_command): New function, factored
4776 out from ...
4777 (complete_line_internal): ... here.
4778 (command_completer_handle_brkchars)
4779 (default_completer_handle_brkchars)
4780 (completer_handle_brkchars_func_for_completer): New functions.
4781 * completer.h (set_gdb_completion_word_break_characters): Delete
4782 declaration.
4783 (completer_handle_brkchars_func_for_completer): New declaration.
4784 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
4785 completer_handle_brkchars_func_for_completer.
4786
4787 2017-07-17 Pedro Alves <palves@redhat.com>
4788
4789 * completer.c (symbol_completer): New function, based on
4790 make_symbol_completion_list_fn.
4791 * completer.h (symbol_completer): New declaration.
4792 * guile/scm-cmd.c (cmdscm_completers): Adjust.
4793 * python/py-cmd.c (completers): Adjust.
4794 * symtab.c (make_symbol_completion_list_fn): Delete.
4795 * symtab.h (make_symbol_completion_list_fn): Delete.
4796 * cli/cli-decode.c (add_cmd): Adjust.
4797
4798 2017-07-17 Pedro Alves <palves@redhat.com>
4799
4800 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
4801 * dwarf2read.c: Include "filename-seen-cache.h".
4802 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
4803 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
4804 * filename-seen-cache.c: New file.
4805 * filename-seen-cache.h: New file.
4806 * symtab.c: Include "filename-seen-cache.h".
4807 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
4808 (create_filename_seen_cache, clear_filename_seen_cache)
4809 (delete_filename_seen_cache, filename_seen): Delete, parts moved
4810 to filename-seen-cache.h/filename-seen-cache.c.
4811 (output_source_filename, sources_info)
4812 (maybe_add_partial_symtab_filename)
4813 (make_source_files_completion_list): Adjust to use
4814 filename_seen_cache.
4815
4816 2017-07-17 Pedro Alves <palves@redhat.com>
4817
4818 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
4819 fields.
4820 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
4821 dwarf2_debug_sections*)): New.
4822 (dwarf2_per_objfile::dwarf2_per_objfile(const
4823 dwarf2_per_objfile&)): Declare as deleted.
4824 (dwarf2_per_objfile::operator=): Declare as deleted.
4825 (dwarf2_per_objfile::dwarf2_per_objfile)
4826 (dwarf2_per_objfile::~dwarf2_per_objfile)
4827 (dwarf2_per_objfile::free_cached_comp_units): New.
4828 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
4829 ctor. Call dwarf2_per_objfile's ctor manually.
4830 (dwarf2_locate_sections): Deleted/refactored as ...
4831 (dwarf2_per_objfile::locate_sections): ... this new method.
4832 (free_cached_comp_units): Defer to
4833 dwarf2_per_objfile::free_cached_comp_units.
4834 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
4835
4836 2017-07-14 Tom Tromey <tom@tromey.com>
4837
4838 PR rust/21764:
4839 * rust-exp.y (convert_ast_to_expression): Add "want_type"
4840 parameter.
4841 <UNOP_SIZEOF>: Split into separate case.
4842 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
4843
4844 2017-07-14 Tom Tromey <tom@tromey.com>
4845
4846 PR rust/21763:
4847 * symtab.c (symbol_matches_domain): Add language_rust to special
4848 case.
4849 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
4850 treat LOC_TYPEDEF symbols as variables.
4851
4852 2017-07-14 Pedro Alves <palves@redhat.com>
4853
4854 * symtab.c (make_file_symbol_completion_list_1): Iterate over
4855 symtabs matching all symtabs with SRCFILE as file name instead of
4856 only considering the first hit, with lookup_symtab.
4857
4858 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4859
4860 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
4861 operator_name parameters.
4862 (gen_expr): Update function call.
4863
4864 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4865
4866 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
4867 parameter.
4868 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
4869 Likewise.
4870 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
4871 parameter, use agent_expr::gdbarch instead, update function
4872 calls.
4873 (locexpr_tracepoint_var_ref): Likewise.
4874 (loclist_tracepoint_var_ref): Likewise.
4875 * ax-gdb.c (gen_trace_static_fields): Likewise.
4876 (gen_traced_pop): Likewise.
4877 (gen_frame_args_address): Likewise.
4878 (gen_frame_locals_address): Likewise.
4879 (gen_var_ref): Likewise.
4880 (gen_struct_ref_recursive): Likewise.
4881 (gen_static_field): Likewise.
4882 (gen_maybe_namespace_elt): Likewise.
4883 (gen_expr): Likewise.
4884 (gen_trace_for_var): Likewise.
4885 (gen_trace_for_expr): Likewise.
4886 (gen_trace_for_return_address): Likewise.
4887
4888 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4889
4890 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
4891 parameter.
4892 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
4893
4894 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4895
4896 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
4897 from ax, update calls.
4898 (gen_usual_arithmetic): Likewise.
4899 (gen_integral_promotions): Likewise.
4900 (gen_bitfield_ref): Likewise.
4901 (gen_primitive_field): Likewise.
4902 (gen_struct_ref_recursive): Likewise.
4903 (gen_struct_ref): Likewise.
4904 (gen_maybe_namespace_elt): Likewise.
4905 (gen_struct_elt_for_reference): Likewise.
4906 (gen_namespace_elt): Likewise.
4907 (gen_aggregate_elt_ref): Likewise.
4908 (gen_expr): Get gdbarch from ax, update calls.
4909 (gen_expr_binop_rest): Likewise.
4910
4911 2017-07-13 Pedro Alves <palves@redhat.com>
4912
4913 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
4914 as default tdesc.
4915 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
4916 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
4917 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
4918 tdesc_amd64_linux as default tdesc. Get final tdesc from the
4919 tdep.
4920 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
4921 Get final tdesc from the tdep.
4922 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
4923 default tdesc.
4924 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4925 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4926 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
4927 Use it as default tdesc.
4928 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
4929 down to amd_init_abi. No longer handle fallback tdesc here.
4930 * amd64-tdep.h (tdesc_x32): Declare.
4931 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
4932 parameter.
4933 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
4934 as default tdesc.
4935
4936 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4937
4938 * s390-linux-tdep.c (s390_process_record): Add support for
4939 instructions new in arch12.
4940
4941 2017-07-11 John Baldwin <jhb@FreeBSD.org>
4942
4943 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
4944 PT_GETFSBASE and PT_GETGSBASE.
4945 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
4946 PT_SETGSBASE.
4947
4948 2017-07-11 John Baldwin <jhb@FreeBSD.org>
4949
4950 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
4951 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
4952 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
4953 those rules.
4954 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
4955 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
4956 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
4957 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
4958 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
4959 * features/i386/amd64.xml: Add 64bit-segments.xml.
4960 * features/i386/amd64-avx-avx512.c: Regenerated.
4961 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
4962 * features/i386/amd64-avx-mpx.c: Regenerated.
4963 * features/i386/amd64-avx.c: Regenerated.
4964 * features/i386/amd64-mpx.c: Regenerated.
4965 * features/i386/amd64.c: Regenerated.
4966 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
4967 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4968 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
4969 * regformats/i386/amd64-avx.dat: Regenerated.
4970 * regformats/i386/amd64-mpx.dat: Regenerated.
4971 * regformats/i386/amd64.dat: Regenerated.
4972
4973 2017-07-10 Yao Qi <yao.qi@linaro.org>
4974
4975 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4976 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4977
4978 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
4979
4980 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
4981 unsetenv.
4982 * gnulib/aclocal.m4: Regenerate.
4983 * gnulib/config.in: Regenerate.
4984 * gnulib/configure: Regenerate.
4985 * gnulib/import/Makefile.am: Regenerate.
4986 * gnulib/import/Makefile.in: Regenerate.
4987 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4988 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4989 * gnulib/import/m4/environ.m4: New file.
4990 * gnulib/import/m4/setenv.m4: New file.
4991 * gnulib/import/setenv.c: New file.
4992 * gnulib/import/unsetenv.c: New file.
4993
4994 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
4995
4996 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
4997 address when op is DW_OP_addr.
4998
4999 2017-07-09 Tom Tromey <tom@tromey.com>
5000
5001 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
5002 check and apply to outer type.
5003
5004 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5005
5006 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
5007 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
5008 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
5009 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
5010
5011 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5012
5013 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
5014
5015 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5016
5017 * corelow.c (get_core_siginfo): Remove.
5018 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
5019 instead of get_core_siginfo.
5020 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
5021 * gdbarch.h: Re-generate.
5022 * gdbarch.c: Re-generate.
5023 * linux-tdep.c (linux_core_xfer_siginfo): New.
5024 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
5025
5026 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5027
5028 * corelow.c (thread_section_name): Move to ...
5029 * gdbcore.h (thread_section_name): ... here.
5030
5031 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5032
5033 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
5034 (struct siginfo32): New.
5035 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
5036 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
5037 via ptrace(PT_LWPINFO).
5038
5039 2017-07-07 John Baldwin <jhb@FreeBSD.org>
5040
5041 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
5042 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
5043 (fbsd_get_siginfo_type): New.
5044 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
5045 (_initialize_fbsd_tdep): New.
5046
5047 2017-07-06 David Blaikie <dblaikie@gmail.com>
5048
5049 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
5050 a singular dwo_unit*) to support multiple CUs in the same way that
5051 multiple TUs are supported.
5052 (create_cus_hash_table): Replace create_dwo_cu with a function for
5053 parsing multiple CUs from a DWO file.
5054 (open_and_init_dwo_file): Use create_cus_hash_table rather than
5055 create_dwo_cu.
5056 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
5057 htab_find, rather than comparing the signature to a singleton CU in
5058 the dwo_file.
5059
5060 2017-07-06 Pedro Alves <palves@redhat.com>
5061
5062 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
5063
5064 2017-07-04 Pedro Alves <palves@redhat.com>
5065
5066 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
5067 * gdbtypes.h (TYPE_STATIC): Delete.
5068 (struct fn_field) <is_public, is_abstract, is_static, is_final,
5069 is_synchronized, is_native>: Delete.
5070 <dummy>: Bump.
5071 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
5072 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
5073 (TYPE_FN_FIELD_ABSTRACT): Delete.
5074
5075 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
5076
5077 * buffer.h (buffer_finish): Fix spelling mistakes.
5078
5079 2017-07-01 Eli Zaretskii <eliz@gnu.org>
5080
5081 * .dir-locals.el: Automatically switch to C-style comments in
5082 versions of Emacs that support the feature.
5083
5084 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5085 Pedro Alves <palves@redhat.com>
5086
5087 PR cli/21688
5088 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
5089 (process_next_line): New variable 'inline_cmd'.
5090 Adjust 'if' clauses for "python", "compile" and "guile" to use
5091 'command_name_equals' and check for '!inline_cmd'.
5092
5093 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5094
5095 PR cli/21688
5096 * cli/cli-script.c (command_name_equals_not_inline): New function.
5097 (process_next_line): Adjust 'if' clauses for "python", "compile"
5098 and "guile" to use command_name_equals_not_inline.
5099
5100 2017-06-29 Pedro Alves <palves@redhat.com>
5101
5102 * completer.c (expression_completer): Call
5103 linespec_location_completer instead of location_completer.
5104
5105 2017-06-29 Pedro Alves <palves@redhat.com>
5106
5107 * completer.c (expression_completer): Remove code that recomputes
5108 'text' from 'word'.
5109
5110 2017-06-29 Yao Qi <yao.qi@linaro.org>
5111
5112 * regformats/regdat.sh: Generate code with
5113 "ifndef IN_PROCESS_AGENT".
5114
5115 2017-06-28 Pedro Alves <palves@redhat.com>
5116
5117 * command.h: Include "common/scoped_restore.h".
5118
5119 2017-06-28 Yao Qi <yao.qi@linaro.org>
5120
5121 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
5122 instead of obstack_grow.
5123
5124 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
5125
5126 PR gdb/21337
5127 * symfile.c (reread_symbols): Call objfiles_changed just before
5128 read_symbols.
5129
5130 2017-06-27 Pedro Alves <palves@redhat.com>
5131
5132 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
5133 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
5134 (completion_list_add_symbol, completion_list_add_msymbol):
5135 ... these new functions.
5136 (add_symtab_completions)
5137 (default_make_symbol_completion_list_break_on_1): Adjust.
5138
5139 2017-06-27 Pedro Alves <palves@redhat.com>
5140
5141 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
5142 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
5143 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
5144 dtor.
5145 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
5146 'storage_obstack' field an auto_obstack. In-class initialize all
5147 non-bitfield fields. Make minsyms_read bool.
5148 * symfile.c (read_symbols): Adjust.
5149
5150 2017-06-27 Alan Hayward <alan.hayward@arm.com>
5151
5152 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
5153 (gdbsim_store_register): Likewise.
5154
5155 2017-06-27 Pedro Alves <palves@redhat.com>
5156
5157 * c-exp.y (name_obstack): Now an auto_obstack.
5158 (yylex): Use auto_obstack::clear.
5159 (c_parse): Use auto_obstack::clear instead of reinitializing and
5160 freeing the obstack.
5161 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
5162 * d-exp.y (name_obstack): Now an auto_obstack.
5163 (yylex): Use auto_obstack::clear.
5164 (d_parse): Use auto_obstack::clear instead of reinitializing and
5165 freeing the obstack.
5166 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
5167 auto_obstack.
5168 * dwarf2read.c (create_addrmap_from_index)
5169 (dwarf2_build_psymtabs_hard)
5170 (update_enumeration_type_from_children): Likewise.
5171 * gdb_obstack.h (auto_obstack): New type.
5172 * go-exp.y (name_obstack): Now an auto_obstack.
5173 (build_packaged_name): Use auto_obstack::clear.
5174 (go_parse): Use auto_obstack::clear instead of reinitializing and
5175 freeing the obstack.
5176 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
5177 auto_obstack.
5178 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
5179 * rust-exp.y (work_obstack): Now an auto_obstack.
5180 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
5181 reinitializing and freeing the obstack.
5182 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
5183 (host_char_to_target): Use auto_obstack.
5184 * utils.h (make_cleanup_obstack_free): Delete declaration.
5185 * valprint.c (generic_emit_char, generic_printstr): Use
5186 auto_obstack.
5187
5188 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
5189
5190 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
5191 thread.
5192 (darwin_init_thread_list): Don't update dummy thread.
5193 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
5194
5195 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5196
5197 * record-full.c (netorder16): Remove.
5198
5199 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5200
5201 * common/diagnostics.h: Define macros for GCC.
5202 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
5203 * common/vec.h: Include diagnostics.h.
5204 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
5205 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
5206 warning.
5207
5208 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5209
5210 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
5211 New macro.
5212 * ada-lex.l: Ignore deprecated register warnings.
5213
5214 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5215
5216 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
5217 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
5218
5219 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5220
5221 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
5222 its own line.
5223
5224 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5225
5226 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
5227
5228 2017-06-23 Alan Hayward <alan.hayward@arm.com>
5229
5230 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
5231 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
5232 (xtensa_register_read_masked): Likewise.
5233
5234 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
5235
5236 * common/environ.c (gdb_environ::unset): Update comment.
5237
5238 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5239
5240 * python/py-unwind.c (pyuw_sniffer): Allocate space for
5241 registers.
5242
5243 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5244
5245 * record-full.c (record_full_exec_insn): Use byte_vector.
5246
5247 2017-06-22 Yao Qi <yao.qi@linaro.org>
5248
5249 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
5250 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5251
5252 2017-06-22 Alan Hayward <alan.hayward@arm.com>
5253
5254 * remote.c (cached_reg): Move from here...
5255 * regcache.h (cached_reg): ...to here.
5256 * python/py-unwind.c (struct reg_info): Remove.
5257 (cached_frame_info): Use cached_reg_t.
5258 (pyuw_prev_register): Likewise.
5259 (pyuw_sniffer): Use cached_reg_t and allocate registers.
5260 (pyuw_dealloc_cache): Free all registers.
5261
5262 2017-06-22 Pedro Alves <palves@redhat.com>
5263 Simon Marchi <simon.marchi@ericsson.com>
5264
5265 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
5266 warning.
5267 * common/diagnostics.h: New file.
5268
5269 2017-06-22 Pedro Alves <palves@redhat.com>
5270
5271 * common/agent.h: Add include guards.
5272
5273 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
5274
5275 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
5276 talk about addressable units instead of bytes.
5277
5278 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5279
5280 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
5281 of '::const_iterator'.
5282
5283 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5284
5285 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5286 'unittests/environ-selftests.c'.
5287 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
5288 * charset.c (find_charset_names): Declare object 'iconv_env'.
5289 Update code to use 'iconv_env' object. Remove call to
5290 'free_environ'.
5291 * common/environ.c: Include <utility>.
5292 (make_environ): Delete function.
5293 (free_environ): Delete function.
5294 (gdb_environ::clear): New function.
5295 (gdb_environ::operator=): New function.
5296 (gdb_environ::get): Likewise.
5297 (environ_vector): Delete function.
5298 (set_in_environ): Delete function.
5299 (gdb_environ::set): New function.
5300 (unset_in_environ): Delete function.
5301 (gdb_environ::unset): New function.
5302 (gdb_environ::envp): Likewise.
5303 * common/environ.h: Include <vector>.
5304 (struct gdb_environ): Delete; transform into...
5305 (class gdb_environ): ... this class.
5306 (free_environ): Delete prototype.
5307 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
5308 environ_vector): Likewise.
5309 * infcmd.c (run_command_1): Update code to call
5310 'envp' from 'gdb_environ' class.
5311 (environment_info): Update code to call methods from 'gdb_environ'
5312 class.
5313 (unset_environment_command): Likewise.
5314 (path_info): Likewise.
5315 (path_command): Likewise.
5316 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
5317 (inferior::inferior): Initialize 'environment' using the host's
5318 information.
5319 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
5320 Include "environ.h".
5321 (class inferior) <environment>: Change type from 'struct
5322 gdb_environ' to 'gdb_environ'.
5323 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
5324 methods from 'gdb_environ' class.
5325 * solib.c (solib_find_1): Likewise
5326 * unittests/environ-selftests.c: New file.
5327
5328 2017-06-20 Yao Qi <yao.qi@linaro.org>
5329
5330 * features/i386/i386-linux.xml: Exchange the order of including
5331 32bit-linux.xml and 32bit-sse.xml.
5332 * features/i386/i386-linux.c: Regenerated.
5333
5334 2017-06-20 Yao Qi <yao.qi@linaro.org>
5335
5336 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
5337 Delete copy ctor and assignment operator.
5338 (tdesc_type): Likewise.
5339 (tdesc_feature): Likewise.
5340 (tdesc_free_reg): Remove.
5341 (tdesc_create_reg): Use new.
5342 (tdesc_free_type): Remove.
5343 (tdesc_create_vector): Use new.
5344 (tdesc_create_union): Likewise.
5345 (tdesc_create_flags): Likewise.
5346 (tdesc_create_enum): Likewise.
5347 (tdesc_free_feature): Delete.
5348 (free_target_description): Use delete.
5349
5350 2017-06-19 John Baldwin <jhb@FreeBSD.org>
5351
5352 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
5353 registers.
5354
5355 2017-06-19 Pedro Alves <palves@redhat.com>
5356
5357 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
5358 after gdb::unlinker.
5359
5360 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
5361
5362 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
5363 gdb_environ to access an environment variable.
5364
5365 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5366
5367 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
5368 gdb_byte*.
5369
5370 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5371
5372 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
5373
5374 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5375
5376 * configure: Re-generate.
5377 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
5378
5379 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5380
5381 * configure: Re-generate.
5382 * warning.m4: Pass -Werror to compiler when checking for
5383 supported warning flags.
5384
5385 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5386
5387 * Makefile.in (COMPILE.pre): Add "-x c++".
5388
5389 2017-06-16 Alan Hayward <alan.hayward@arm.com>
5390 Pedro Alves <palves@redhat.com>
5391 Yao Qi <yao.qi@linaro.org>
5392
5393 * defs.h (RequireLongest): New.
5394 (extract_integer): Declare function template.
5395 (extract_signed_integer): Remove the declaration, but define it
5396 static inline.
5397 (extract_unsigned_integer): Likewise.
5398 (store_integer): Declare function template.
5399 (store_signed_integer): Remove the declaration, but define it
5400 static inline.
5401 (store_unsigned_integer): Likewise.
5402 * findvar.c (extract_integer): New function template.
5403 (extract_signed_integer): Remove.
5404 (extract_unsigned_integer): Remove.
5405 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5406 instantiations.
5407 (store_integer): New function template.
5408 (store_signed_integer): Remove.
5409 (store_unsigned_integer): Remove.
5410 (store_integer): Explicit instantiations.
5411 * regcache.c (regcache_raw_read_signed): Update.
5412 (regcache::raw_read): New function.
5413 (regcache::raw_read_signed): Remove.
5414 (regcache::raw_read_unsigned): Remove.
5415 (regcache_raw_read_unsigned): Update.
5416 (regcache_raw_write_unsigned): Update.
5417 (regcache::raw_write_signed): Remove.
5418 (regcache::raw_write): New function.
5419 (regcache_cooked_read_signed): Update.
5420 (regcache::raw_write_unsigned): Remove.
5421 (regcache::cooked_read_signed): Remove.
5422 (regcache_cooked_read_unsigned): Update.
5423 (regcache::cooked_read_unsigned): Remove.
5424 (regcache_cooked_write_signed): Update.
5425 (regcache_cooked_write_unsigned): Update.
5426 * regcache.h (regcache) <raw_read_signed>: Remove.
5427 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5428 <raw_read, raw_write>: New.
5429 <cooked_read_signed, cooked_write_signed>: Remove.
5430 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5431 <cooked_read, cooked_write>: New.
5432 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5433 (sh64_pseudo_register_write): Update.
5434
5435 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5436
5437 * arc-tdep.c (arc_disassembler_options): New variable.
5438 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5439 of default_print_insn.
5440 (arc_delayed_print_insn): Set info->section when needed,
5441 use default_print_insn to retrieve a disassembler.
5442
5443 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5444
5445 PR gdb/21574
5446 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5447 to mention $SHELL and startup-with-shell.
5448
5449 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5450
5451 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5452
5453 2017-06-14 Yao Qi <yao.qi@linaro.org>
5454
5455 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5456 default_print_insn instead of print_insn_aarch64.
5457 * arm-tdep.c (gdb_print_insn_arm): Call
5458 default_print_insn instead of print_insn_big_arm
5459 and print_insn_little_arm.
5460 * i386-tdep.c (i386_print_insn): Call default_print_insn
5461 instead of print_insn_i386.
5462 * ia64-tdep.c (ia64_print_insn): Call
5463 default_print_insn instead of print_insn_ia64.
5464 * mips-tdep.c (gdb_print_insn_mips): Call
5465 default_print_insn instead of print_insn_big_mips
5466 and print_insn_little_mips.
5467 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5468 instead of print_insn_spu.
5469
5470 2017-06-14 Pedro Alves <palves@redhat.com>
5471
5472 * ada-lang.c: Include "common/byte-vector.h".
5473 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5474 * charset.c (wchar_iterator::iterate): Resize the vector instead
5475 of reserving it.
5476 * common/byte-vector.h: Include "common/def-vector.h".
5477 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5478 * cli/cli-dump.c: Include "common/byte-vector.h".
5479 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5480 * common/byte-vector.h: New file.
5481 * common/def-vector.h: New file.
5482 * common/default-init-alloc.h: New file.
5483 * dwarf2loc.c: Include "common/byte-vector.h".
5484 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5485 instead of reserving it.
5486 * dwarf2read.c: Include "common/byte-vector.h".
5487 (data_buf::m_vec): Now a gdb::byte_vector.
5488 * gdb_regex.c: Include "common/def-vector.h".
5489 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5490 * mi/mi-main.c: Include "common/byte-vector.h".
5491 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5492 * printcmd.c: Include "common/byte-vector.h".
5493 (print_scalar_formatted): Use gdb::byte_vector.
5494 * valprint.c: Include "common/byte-vector.h".
5495 (maybe_negate_by_bytes, print_decimal_chars): Use
5496 gdb::byte_vector.
5497
5498 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5499
5500 * darwin-nat.c: Include "nat/fork-inferior.h".
5501
5502 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5503
5504 * configure.nat: Factor out Darwin bits that are not
5505 architecture-specific. Add fork-inferior.o.
5506
5507 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5508
5509 * configure.nat: Factor out AIX bits that are not
5510 architecture-specific. Add fork-inferior.o.
5511
5512 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5513
5514 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5515 (read_pieced_value, write_pieced_value): ...here. Reduce to
5516 wrappers that just call rw_pieced_value.
5517
5518 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5519
5520 * dwarf2loc.c (write_pieced_value): When writing the data for a
5521 memory piece, use write_memory_with_notification instead of
5522 write_memory.
5523
5524 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5525
5526 * valops.c (read_value_memory): Change embedded_offset to
5527 represent a bit offset instead of a byte offset.
5528 * value.h (read_value_memory): Adjust comment.
5529
5530 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5531
5532 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5533 dest_offset_bits and source_offset_bits.
5534 (write_pieced_value): Likewise.
5535
5536 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5537
5538 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5539 given by DW_OP_bit_piece.
5540 (write_pieced_value): Likewise.
5541
5542 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5543
5544 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5545 some other preparations to the places where sufficient information
5546 is available.
5547 (write_pieced_value): Likewise.
5548
5549 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5550
5551 * dwarf2loc.c (bits_to_bytes): New function.
5552 (read_pieced_value): Fix offset calculations for register pieces
5553 on big-endian targets.
5554 (write_pieced_value): Likewise.
5555
5556 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5557
5558 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5559 (write_pieced_value): Likewise.
5560
5561 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5562
5563 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5564 transfer the source value's least significant bits, instead of its
5565 lowest-addressed ones. Rename type_len to max_offset.
5566 (read_pieced_value): Mirror above changes to write_pieced_value as
5567 applicable.
5568
5569 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5570
5571 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5572 truncate full bytes from dest_offset_bits before using it as an
5573 offset into the buffer.
5574
5575 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5576
5577 * dwarf2loc.c (write_pieced_value): Include transfer size in
5578 byte-wise check.
5579
5580 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5581
5582 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5583 calculation of this_size.
5584
5585 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5586
5587 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5588 when targeting a bit-field.
5589 (write_pieced_value): Likewise.
5590
5591 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5592
5593 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5594 (allocate_piece_closure): Drop addr_size parameter.
5595 (dwarf2_evaluate_loc_desc_full): Adjust call to
5596 allocate_piece_closure.
5597
5598 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5599
5600 PR gdb/21226
5601 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5602 the LSB end, independent of endianness.
5603
5604 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5605
5606 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5607 size capping.
5608
5609 2017-06-13 Yao Qi <yao.qi@linaro.org>
5610
5611 * mips-linux-nat.c: Move include features/mips*-linux.c to
5612 mips-linux-tdep.c.
5613 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5614 to mips-linux-tdep.c.
5615 * mips-linux-tdep.c: Include features/mips*-linux.c
5616 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5617 functions.
5618 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5619 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5620 (tdesc_mips64_dsp_linux): Declare.
5621
5622 2017-06-12 Tom Tromey <tom@tromey.com>
5623
5624 * valprint.h (val_print_type_code_int): Remove.
5625 * valprint.c (generic_val_print_int): Always call
5626 val_print_scalar_formatted.
5627 (val_print_type_code_int): Remove.
5628 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5629 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5630 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5631 * ada-valprint.c (ada_val_print_num): Use
5632 val_print_scalar_formatted.
5633
5634 2017-06-12 Tom Tromey <tom@tromey.com>
5635
5636 * printcmd.c (print_scalar_formatted): Unify the two switches.
5637 Don't convert scalars to LONGEST.
5638
5639 2017-06-12 Tom Tromey <tom@tromey.com>
5640
5641 PR exp/16225:
5642 * valprint.h (print_decimal_chars): Update.
5643 * valprint.c (maybe_negate_by_bytes): New function.
5644 (print_decimal_chars): Add "is_signed" argument.
5645 * printcmd.c (print_scalar_formatted): Update.
5646
5647 2017-06-12 Tom Tromey <tom@tromey.com>
5648
5649 PR exp/16225:
5650 * valprint.h (print_binary_chars, print_hex_chars): Update.
5651 * valprint.c (val_print_type_code_int): Update.
5652 (print_binary_chars): Add "zero_pad" argument.
5653 (emit_octal_digit): New function.
5654 (print_octal_chars): Don't zero-pad.
5655 (print_decimal_chars): Likewise.
5656 (print_hex_chars): Add "zero_pad" argument.
5657 * sh64-tdep.c (sh64_do_fp_register): Update.
5658 * regcache.c (regcache::dump): Update.
5659 * printcmd.c (print_scalar_formatted): Update.
5660 * infcmd.c (default_print_one_register_info): Update.
5661
5662 2017-06-12 Pedro Alves <palves@redhat.com>
5663 Alan Hayward <alan.hayward@arm.com>
5664
5665 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5666 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5667 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5668 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5669 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5670
5671 2017-06-12 Pedro Alves <palves@redhat.com>
5672
5673 * dwarf2read.c (mapped_symtab::data): Now a vector of
5674 symtab_index_entry instead of vector of
5675 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5676 whether an element's name is NULL instead of checking whether the
5677 element itself is NULL.
5678 (find_slot): Change return type. Adjust.
5679 (hash_expand, , add_index_entry, uniquify_cu_indices)
5680 (write_hash_table): Adjust.
5681
5682 2017-06-12 Pedro Alves <palves@redhat.com>
5683
5684 * dwarf2read.c (recursively_count_psymbols): New function.
5685 (write_psymtabs_to_index): Call it to compute number of psyms and
5686 pass estimate size of psyms_seen to unordered_set's ctor.
5687
5688 2017-06-12 Pedro Alves <palves@redhat.com>
5689
5690 * dwarf2read.c (write_hash_table): Check if key already exists
5691 before emplacing.
5692
5693 2017-06-12 Pedro Alves <palves@redhat.com>
5694
5695 * dwarf2read.c (data_buf::append_space): Rename to...
5696 (data_buf::grow): ... this, and make private. Adjust all callers.
5697 (data_buf::append_uint): New method.
5698 (add_address_entry, write_one_signatured_type)
5699 (write_psymtabs_to_index): Use it.
5700
5701 2017-06-12 Pedro Alves <palves@redhat.com>
5702
5703 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
5704 (file_write (FILE *, const std::vector<Elem>&)): Delete.
5705 (data_buf::file_write): Call ::fwrite directly.
5706
5707 2017-06-12 Pedro Alves <palves@redhat.com>
5708
5709 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
5710 std::vector::erase.
5711
5712 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5713
5714 Code cleanup: C++ify .gdb_index producer.
5715 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
5716 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
5717 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
5718 (create_strtab, add_string): Remove.
5719 (file_write, data_buf): New.
5720 (struct symtab_index_entry): Use std::vector for cu_indices.
5721 (struct mapped_symtab): Use std::vector for data.
5722 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
5723 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
5724 Remove.
5725 (find_slot): Change return type. Update it to the new data structures.
5726 (hash_expand, add_index_entry): Update it to the new data structures.
5727 (offset_type_compare): Remove.
5728 (uniquify_cu_indices): Update it to the new data structures.
5729 (c_str_view, c_str_view_hasher, vector_hasher): New.
5730 (add_indices_to_cpool): Remove.
5731 (write_hash_table): Update it to the new data structures.
5732 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
5733 (eq_psymtab_cu_index): Remove.
5734 (psym_index_map): New typedef.
5735 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
5736 reference and std::unordered_map for cu_index_htab.
5737 (add_address_entry, add_address_entry_worker, write_address_map)
5738 (write_psymbols): Update it to the new data structures.
5739 (write_obstack): Remove.
5740 (struct signatured_type_index_data): Change types_list to a data_buf
5741 reference and psyms_seen to a std::unordered_set reference.
5742 (write_one_signatured_type, recursively_write_psymbols)
5743 (write_psymtabs_to_index): Update it to the new data structures.
5744
5745 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
5746
5747 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
5748 separate-debug-file commands.
5749 * symfile.h (separate_debug_file_debug): New global.
5750 * symfile.c (separate_debug_file_debug): New global.
5751 (separate_debug_file_exists, find_separate_debug_file): Add
5752 debug output.
5753 (_initialize_symfile): Add "set debug separate-debug-file"
5754 command.
5755 * build-id.c (build_id_to_debug_bfd,
5756 find_separate_debug_file_by_buildid): Add debug output.
5757
5758 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5759
5760 * gdbarch.sh (displaced_step_free_closure): Remove.
5761 * gdbarch.h, gdbarch.c: Re-generate.
5762 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
5763 displaced_step_free_closure.
5764 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
5765 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
5766 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5767 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
5768 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5769 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5770 * arch-utils.h (simple_displaced_step_free_closure): Remove.
5771 * arch-utils.c (simple_displaced_step_free_closure): Remove.
5772 * infrun.c (displaced_step_clear): Call xfree instead of
5773 gdbarch_displaced_step_free_closure.
5774
5775 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
5776
5777 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
5778 NULL".
5779
5780 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5781
5782 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
5783 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
5784 (mn10300_push_dummy_call): Likewise.
5785
5786 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5787
5788 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
5789
5790 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5791
5792 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
5793
5794 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5795
5796 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
5797 able to start inferiors using a shell.
5798 (New remote packets): Announce new packet "QStartupWithShell".
5799 * remote.c: Add PACKET_QStartupWithShell.
5800 (extended_remote_create_inferior): Handle new
5801 PACKET_QStartupWithShell.
5802 (remote_protocol_features) <QStartupWithShell>: New entry for
5803 PACKET_QStartupWithShell.
5804 (_initialize_remote): Call "add_packet_config_cmd" for
5805 QStartupShell.
5806
5807 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5808 Pedro Alves <palves@redhat.com>
5809
5810 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
5811 and "nat/fork-inferior.h".
5812 * common/common-inferior.h: New file, with contents from
5813 "gdb/inferior.h".
5814 * commom/common-utils.c: Include "common-utils.h".
5815 (stringify_argv): New function.
5816 * common/common-utils.h (stringify_argv): New prototype.
5817 * configure.nat: Add "fork-inferior.o" as a dependency for
5818 "*linux*", "fbsd*" and "nbsd*" hosts.
5819 * corefile.c (get_exec_file): Update comment.
5820 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
5821 instead of "startup_inferior".
5822 (darwin_create_inferior): Call "add_thread_silent" after
5823 "fork_inferior".
5824 * fork-child.c: Cleanup unnecessary includes.
5825 (SHELL_FILE): Move to "common/common-fork-child.c".
5826 (environ): Likewise.
5827 (exec_wrapper): Initialize.
5828 (get_exec_wrapper): New function.
5829 (breakup_args): Move to "common/common-fork-child.c"; rename to
5830 "breakup_args_for_exec".
5831 (escape_bang_in_quoted_argument): Move to
5832 "common/common-fork-child.c".
5833 (saved_ui): New variable.
5834 (prefork_hook): New function.
5835 (postfork_hook): Likewise.
5836 (postfork_child_hook): Likewise.
5837 (gdb_startup_inferior): Likewise.
5838 (fork_inferior): Move to "common/common-fork-child.c". Update
5839 function to support gdbserver.
5840 (startup_inferior): Likewise.
5841 * gdbcore.h (get_exec_file): Remove declaration.
5842 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
5843 instead of "startup_inferior". Call "add_thread_silent" after
5844 "fork_inferior".
5845 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
5846 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
5847 instead of "startup_inferior". Call "add_thread_silent" after
5848 "fork_inferior".
5849 * inferior.h: Include "common-inferior.h".
5850 (trace_start_error): Move to "common/common-utils.h".
5851 (trace_start_error_with_name): Likewise.
5852 (fork_inferior): Move prototype to "nat/fork-inferior.h".
5853 (startup_inferior): Likewise.
5854 (gdb_startup_inferior): New prototype.
5855 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
5856 * nat/fork-inferior.h: New file.
5857 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
5858 instead of "startup_inferior". Call "add_thread_silent" after
5859 "fork_inferior".
5860 * target.h (target_terminal_init): Move prototype to
5861 "target/target.h".
5862 (target_terminal_inferior): Likewise.
5863 (target_terminal_ours): Likewise.
5864 * target/target.h (target_terminal_init): New prototype, moved
5865 from "target.h".
5866 (target_terminal_inferior): Likewise.
5867 (target_terminal_ours): Likewise.
5868 * utils.c (gdb_flush_out_err): New function.
5869
5870 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5871
5872 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
5873 * common/common-gdbthread.h: New file, with parts from
5874 "gdb/gdbthread.h".
5875 * gdbthread.h: Include "common-gdbthread.h".
5876 (switch_to_thread): Moved to "common/common-gdbthread.h".
5877
5878 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5879
5880 * Makefile.in (SFILES): Add "common/job-control.c".
5881 (HFILES_NO_SRCDIR): Add "common/job-control.h".
5882 (COMMON_OBS): Add "job-control.o".
5883 * common/job-control.c: New file, with contents from
5884 "gdb/inflow.c".
5885 * common/job-control.h: New file, with contents from "terminal.h".
5886 * fork-child.c: Include "job-control.h".
5887 * inflow.c: Include "job-control.h".
5888 (gdb_setpgid): Move to "common/common-inflow.c".
5889 (_initialize_inflow): Move setting of "job_control" to
5890 "handle_job_control".
5891 * terminal.h (job_control): Moved to "common/common-terminal.h".
5892 (gdb_setpgid): Likewise.
5893 * top.c: Include "job_control.h".
5894 * utils.c: Likewise.
5895 (job_control): Moved to "job-control.c".
5896
5897 2017-06-07 Pedro Alves <palves@redhat.com>
5898
5899 * Makefile.in (SFILES): Add gdb_regex.c.
5900 (COMMON_OBS): Add gdb_regex.o.
5901 * ada-lang.c (ada_add_standard_exceptions)
5902 (ada_add_exceptions_from_frame, name_matches_regex)
5903 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
5904 parameter type to compiled_regex. Adjust.
5905 (ada_exceptions_list): Use compiled_regex.
5906 * break-catch-throw.c (exception_catchpoint::pattern): Now a
5907 std::unique_ptr<compiled_regex>.
5908 (exception_catchpoint::~exception_catchpoint): Remove regfree
5909 call.
5910 (check_status_exception_catchpoint): Adjust to use compiled_regex.
5911 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
5912 * breakpoint.c (solib_catchpoint::compiled): Now a
5913 std::unique_ptr<compiled_regex>.
5914 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
5915 (check_status_catch_solib): Adjust to use compiled_regex.
5916 (add_solib_catchpoint): Adjust to use compiled_regex.
5917 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
5918 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
5919 compiled_regex reference. Adjust to use it.
5920 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
5921 declaration. Include "gdb_regex.h".
5922 (apropos_cmd): Change regex parameter to compiled_regex reference.
5923 * gdb_regex.c: New file.
5924 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
5925 declarations.
5926 (class compiled_regex): New.
5927 * linux-tdep.c: Include "common/gdb_optional.h".
5928 (struct mapping_regexes): New, factored out from
5929 mapping_is_anonymous_p, and adjusted to use compiled_regex.
5930 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
5931 gdb::optional and remove cleanups. Adjust to compiled_regex.
5932 * probe.c: Include "common/gdb_optional.h".
5933 (collect_probes): Use compiled_regex and gdb::optional and remove
5934 cleanups.
5935 * skip.c: Include "common/gdb_optional.h".
5936 (skiplist_entry::compiled_function_regexp): Now a
5937 gdb::optional<compiled_regex>.
5938 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
5939 (free_skiplist_entry): Remove regfree call.
5940 (compile_skip_regexp, skip_rfunction_p): Adjust to use
5941 compiled_regex and gdb::optional.
5942 * symtab.c: Include "common/gdb_optional.h".
5943 (search_symbols): Use compiled_regex and gdb::optional.
5944 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
5945 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
5946 to gdb_regex.c.
5947
5948 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5949
5950 * regcache.c (regcache::save): Avoid buffer use.
5951 (regcache::dump): Likewise.
5952
5953 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5954
5955 * sh-tdep.c (sh_pseudo_register_read): Remove
5956 MAX_REGISTER_SIZE.
5957 (sh_pseudo_register_write): Likewise.
5958 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
5959 (sh64_pseudo_register_write): Likewise
5960
5961 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5962
5963 * aarch64-tdep.c (aarch64_store_return_value): Use
5964 V_REGISTER_SIZE.
5965 (aarch64_pseudo_read_value): Likewise.
5966 (aarch64_pseudo_write): Likewise.
5967
5968 2017-06-06 Yao Qi <yao.qi@linaro.org>
5969
5970 * regformats/regdef.h (set_register_cache): Remove the
5971 declaration.
5972
5973 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5974
5975 * frame.c (frame_unwind_register_signed): Use
5976 frame_unwind_register_value.
5977
5978 2017-06-06 Pedro Alves <palves@redhat.com>
5979
5980 PR breakpoints/21553
5981 * breakpoint.c (create_breakpoints_sal_default)
5982 (init_breakpoint_sal, create_breakpoint_sal): Use
5983 gdb::unique_xmalloc_ptr for string parameters.
5984 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5985 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
5986 (base_breakpoint_create_breakpoints_sal)
5987 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
5988 (strace_marker_create_breakpoints_sal)
5989 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
5990 string parameters.
5991 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
5992 gdb::unique_xmalloc_ptr for string parameters.
5993 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5994 parameters.
5995
5996 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5997
5998 * alpha-tdep.c (alpha_register_to_value): Use
5999 get_frame_register_value.
6000 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
6001
6002 2017-06-06 Alan Hayward <alan.hayward@arm.com>
6003
6004 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
6005 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
6006 (ia64_value_to_register): Likewise.
6007 (ia64_extract_return_value): Likewise.
6008 (ia64_store_return_value): Likewise.
6009 (ia64_push_dummy_call): Likewise.
6010
6011 2017-06-04 Joel Brobecker <brobecker@adacore.com>
6012
6013 GDB 8.0 released.
6014
6015 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
6016
6017 * x86-linux-nat.c (struct arch_lwp_info): Remove.
6018
6019 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
6020
6021 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
6022 parameter.
6023 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
6024
6025 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
6026
6027 * event-loop.c (poll_timers): Unallocate timer using delete
6028 instead of xfree.
6029
6030 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6031
6032 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
6033 (struct breakpoint) <~breakpoint>: New.
6034 (struct watchpoint): Inherit from breakpoint.
6035 <~watchpoint>: New.
6036 <base>: Remove.
6037 (struct tracepoint): Inherit from breakpoint.
6038 <base>: Remove.
6039 * breakpoint.c (longjmp_breakpoint_ops): Remove.
6040 (struct longjmp_breakpoint): Inherit from breakpoint.
6041 <~longjmp_breakpoint>: New.
6042 <base>: Remove.
6043 (new_breakpoint_from_type): Remove casts.
6044 (watchpoint_in_thread_scope): Remove reference to base field.
6045 (watchpoint_del_at_next_stop): Likewise.
6046 (update_watchpoint): Likewise.
6047 (watchpoint_check): Likewise.
6048 (bpstat_check_watchpoint): Likewise.
6049 (set_longjmp_breakpoint): Likewise.
6050 (struct fork_catchpoint): Inherit from breakpoint.
6051 <base>: Remove.
6052 (struct solib_catchpoint): Inherit from breakpoint.
6053 <~solib_catchpoint>: New.
6054 <base>: Remove.
6055 (dtor_catch_solib): Change to ...
6056 (solib_catchpoint::~solib_catchpoint): ... this.
6057 (breakpoint_hit_catch_solib): Remove reference to base field.
6058 (add_solib_catchpoint): Likewise.
6059 (create_fork_vfork_event_catchpoint): Likewise.
6060 (struct exec_catchpoint): Inherit from breakpoint.
6061 <~exec_catchpoint>: New.
6062 <base>: Remove.
6063 (dtor_catch_exec): Change to ...
6064 (exec_catchpoint::~exec_catchpoint): ... this.
6065 (dtor_watchpoint): Change to ...
6066 (watchpoint::~watchpoint): ... this.
6067 (watch_command_1): Remove reference to base field.
6068 (catch_exec_command_1): Likewise.
6069 (base_breakpoint_dtor): Change to ...
6070 (breakpoint::~breakpoint): ... this.
6071 (base_breakpoint_ops): Remove dtor field value.
6072 (longjmp_bkpt_dtor): Change to ...
6073 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
6074 (strace_marker_create_breakpoints_sal): Remove reference to base
6075 field.
6076 (delete_breakpoint): Don't manually call breakpoint destructor.
6077 (create_tracepoint_from_upload): Remove reference to base field.
6078 (trace_pass_set_count): Likewise.
6079 (initialize_breakpoint_ops): Don't initialize
6080 momentary_breakpoint_ops, don't set dtors.
6081 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
6082 <~ada_catchpoint>: New.
6083 <base>: Remove.
6084 (create_excep_cond_exprs): Remove reference to base field.
6085 (dtor_exception): Change to ...
6086 (ada_catchpoint::~ada_catchpoint): ... this.
6087 (dtor_catch_exception): Remove.
6088 (dtor_catch_exception_unhandled): Remove.
6089 (dtor_catch_assert): Remove.
6090 (create_ada_exception_catchpoint): Remove reference to base
6091 field.
6092 (initialize_ada_catchpoint_ops): Don't set dtors.
6093 * break-catch-sig.c (struct signal_catchpoint): Inherit from
6094 breakpoint.
6095 <~signal_catchpoint>: New.
6096 <base>: Remove.
6097 (signal_catchpoint_dtor): Change to ...
6098 (signal_catchpoint::~signal_catchpoint): ... this.
6099 (create_signal_catchpoint): Remove reference to base field.
6100 (initialize_signal_catchpoint_ops): Don't set dtor.
6101 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
6102 from breakpoint.
6103 <~syscall_catchpoint>: New.
6104 <base>: Remove.
6105 (dtor_catch_syscall): Change to ...
6106 (syscall_catchpoint::~syscall_catchpoint): ... this.
6107 (create_syscall_event_catchpoint): Remove reference to base
6108 field.
6109 (initialize_syscall_catchpoint_ops): Don't set dtor.
6110 * break-catch-throw.c (struct exception_catchpoint): Inherit
6111 from breakpoint.
6112 <~exception_catchpoint>: New.
6113 <base>: Remove.
6114 (dtor_exception_catchpoint): Change to ...
6115 (exception_catchpoint::~exception_catchpoint): ... this.
6116 (handle_gnu_v3_exceptions): Remove reference to base field.
6117 (initialize_throw_catchpoint_ops): Don't set dtor.
6118 * ctf.c (ctf_get_traceframe_address): Remove reference to base
6119 field.
6120 * remote.c (remote_get_tracepoint_status): Likewise.
6121 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
6122 * tracefile.c (tracefile_fetch_registers): Likewise.
6123 * tracepoint.c (actions_command): Likewise.
6124 (validate_actionline): Likewise.
6125 (tfind_1): Likewise.
6126 (get_traceframe_location): Likewise.
6127 (find_matching_tracepoint_location): Likewise.
6128 (parse_tracepoint_status): Likewise.
6129 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
6130
6131 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6132
6133 * breakpoint.c (struct longjmp_breakpoint): New struct.
6134 (is_tracepoint_type): Change return type to bool.
6135 (is_longjmp_type): New function.
6136 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
6137 (set_raw_breakpoint_without_location): Use
6138 new_breakpoint_from_type.
6139 (set_raw_breakpoint): Likewise.
6140
6141 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6142
6143 * breakpoint.c (new_breakpoint_from_type): New function.
6144 (create_breakpoint_sal): Use new_breakpoint_from_type and
6145 unique_ptr.
6146 (create_breakpoint): Likewise.
6147
6148 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
6149
6150 * memattr.c (mem_info_command): Rename to ...
6151 (info_mem_command): ... this.
6152 (mem_enable_command): Rename to ...
6153 (enable_mem_command): ... this.
6154 (mem_disable_command): Rename to ...
6155 (disable_mem_command): ... this.
6156 (mem_delete_command): Rename to ...
6157 (delete_mem_command): ... this.
6158 (_initialize_mem): Adjust function names.
6159
6160 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6161
6162 * btrace.c (handle_pt_insn_events): New.
6163 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
6164 STATUS. Split into this and ...
6165 (handle_pt_insn_event_flags): ... this.
6166
6167 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6168
6169 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
6170 and struct pt_insn.resynced.
6171 * configure: Regenerated.
6172 * config.in: Regenerated.
6173
6174 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6175
6176 * btrace.c (ftrace_find_call_by_number): New function.
6177 (ftrace_new_function): Store objects, not pointers.
6178 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
6179 ftrace_new_gap, ftrace_update_function,
6180 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
6181 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
6182 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
6183 btrace_ends_with_single_insn, btrace_call_get): Account for
6184 btrace_thread_info::functions now storing objects.
6185 * btrace.h (struct btrace_thread_info): Add constructor.
6186 (struct btrace_thread_info) <functions>: Make std::vector.
6187 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
6188 Initialize with default values.
6189 * record-btrace.c (record_btrace_frame_sniffer): Account for
6190 btrace_thread_info::functions now storing objects.
6191
6192 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6193
6194 * btrace.c: Remove typedef bfun_s.
6195 (ftrace_new_gap): Directly add gaps to the list of gaps.
6196 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
6197 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
6198 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
6199 instead of gdb VEC.
6200
6201 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6202
6203 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
6204 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
6205 with btrace_thread_info::next_segment and
6206 btrace_thread_info::prev_segment.
6207 * btrace.h: Remove struct btrace_func_link.
6208 (struct btrace_function): Replace pair of function segment pointers
6209 with pair of indices.
6210 * python/py-record-btrace.c (btpy_call_prev_sibling,
6211 btpy_call_next_sibling): Replace references to
6212 btrace_thread_info::segment with btrace_thread_info::next_segment and
6213 btrace_thread_info::prev_segment.
6214 * record-btrace.c (record_btrace_frame_this_id): Use
6215 btrace_find_call_by_number.
6216
6217 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6218
6219 * btrace.c (ftrace_new_function, ftrace_fixup_level,
6220 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
6221 btrace_insn_next, btrace_insn_prev): Remove references to
6222 btrace_thread_info::flow.
6223 * btrace.h (struct btrace_function): Remove FLOW.
6224
6225 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6226
6227 * btrace.c (ftrace_find_call_by_number): New function.
6228 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
6229 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
6230 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
6231 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
6232 index.
6233 * btrace.h (struct btrace_function): Turn UP into an index.
6234 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
6235 as an index.
6236 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
6237 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
6238 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
6239
6240 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6241
6242 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6243 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6244 ftrace_update_function, ftrace_compute_global_level_offset,
6245 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
6246 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
6247 btrace_insn_end, btrace_is_empty): Remove references to
6248 btrace_thread_info::begin and btrace_thread_info::end.
6249 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
6250 (struct btrace_thread_info) <functions>: Adjust comment.
6251 * record-btrace.c (record_btrace_start_replaying): Remove reference to
6252 btrace_thread_info::begin.
6253
6254 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6255
6256 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6257 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6258 ftrace_update_function): Remove arguments that implicitly were always
6259 BTINFO->END.
6260 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
6261 Don't pass BTINFO->END.
6262
6263 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6264
6265 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
6266 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
6267 btrace_find_insn_by_number): Replace function segment pointer with
6268 index.
6269 (btrace_insn_cmp): Simplify.
6270 * btrace.h: (struct btrace_insn_iterator) Rename index to
6271 insn_index. Replace function segment pointer with index into function
6272 segment vector.
6273 * record-btrace.c (record_btrace_call_history): Replace function
6274 segment pointer use with index.
6275 (record_btrace_frame_sniffer): Retrieve function call segment through
6276 vector.
6277 (record_btrace_set_replay): Remove defunc't safety check.
6278
6279 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6280
6281 * btrace.c (btrace_ends_with_single_insn): New function.
6282 (btrace_call_get, btrace_call_number, btrace_call_begin,
6283 btrace_call_end, btrace_call_next, btrace_call_prev,
6284 btrace_find_call_by_number): Use index into call segment vector
6285 instead of pointer.
6286 (btrace_call_cmp): Simplify.
6287 * btrace.h (struct btrace_call_iterator): Replace function call segment
6288 pointer with index into vector.
6289 * record-btrace.c (record_btrace_call_history): Use index instead of
6290 pointer.
6291
6292 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6293
6294 * btrace.c (btrace_insn_begin, btrace_insn_end,
6295 btrace_find_insn_by_number): Add btinfo to iterator.
6296 * btrace.h (struct btrace_insn_iterator): Add btinfo.
6297
6298 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6299
6300 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
6301 and save pointers directly.
6302 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
6303 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
6304 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
6305 changed signature of functions.
6306 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
6307 (btrace_fetch): Remove code that adds btrace_function pointers to
6308 vector of btrace_functions.
6309 (btrace_clear): Simplify freeing vector of btrace_functions.
6310
6311 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6312
6313 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
6314 Replace VEC_* with std::vector functions.
6315 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
6316 (struct btrace_thread_info)<functions>: Change type to std::vector.
6317
6318 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
6319
6320 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
6321 "Removed targets and native configurations" up. Merge duplicate
6322 "New commands" sub-sections. Add "New options" sub-sections.
6323
6324 2017-05-26 Alan Hayward <alan.hayward@arm.com>
6325
6326 * defs.h (copy_integer_to_size): New declaration.
6327 * findvar.c (copy_integer_to_size): New function.
6328 (do_cint_test): New selftest function.
6329 (copy_integer_to_size_test): Likewise.
6330 (_initialize_findvar): Likewise.
6331 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
6332 (mips_fbsd_collect_reg): Use raw_collect_integer.
6333 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
6334 (mips64_fill_gregset): Use raw_collect_integer
6335 (mips64_fill_fpregset): Use raw_supply_integer.
6336 * regcache.c (regcache::raw_supply_integer): New function.
6337 (regcache::raw_collect_integer): Likewise.
6338 * regcache.h: (regcache::raw_supply_integer): New declaration.
6339 (regcache::raw_collect_integer): Likewise.
6340
6341 2017-05-24 Yao Qi <yao.qi@linaro.org>
6342
6343 * Makefile.in (SFILES): Add gdbarch-selftests.c.
6344 (COMMON_OBS): Add gdbarch-selftests.o.
6345 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
6346 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
6347 * gdbarch-selftests.c: New file.
6348 * regcache.h (regcache) <~regcache>: Mark it virtual if
6349 GDB_SELF_TEST.
6350 <raw_write>: Likewise.
6351
6352 2017-05-24 Yao Qi <yao.qi@linaro.org>
6353
6354 * regcache.c (current_regcache): Change it to
6355 regcache::current_regcache.
6356 (regcache_observer_target_changed): Update.
6357 (regcache_thread_ptid_changed): Make it a regcache static
6358 method.
6359 (regcache_thread_ptid_changed): Update.
6360 (class regcache_access): New.
6361 (current_regcache_test): Update.
6362 (_initialize_regcache): Update.
6363 * regcache.h: Include forward_list.
6364 (regcache): Declare regcache_thread_ptid_changed and declare
6365 registers_changed_ptid as friend.
6366
6367 2017-05-24 Yao Qi <yao.qi@linaro.org>
6368
6369 * i387-tdep.c (i387_register_to_value): Use register_size
6370 instead of TYPE_LENGTH.
6371 * m68k-tdep.c (m68k_register_to_value): Likewise.
6372
6373 2017-05-24 Yao Qi <yao.qi@linaro.org>
6374
6375 * i387-tdep.c (i387_convert_register_p): Return false if type
6376 code isn't TYPE_CODE_FLT.
6377
6378 2017-05-24 Yao Qi <yao.qi@linaro.org>
6379
6380 * alpha-tdep.c (alpha_convert_register_p): Return true if type
6381 length is 4.
6382 (alpha_register_to_value): Remove type length check.
6383 (alpha_value_to_register): Likewise.
6384
6385 2017-05-24 Yao Qi <yao.qi@linaro.org>
6386
6387 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
6388 TYPE_CODE_FLT.
6389
6390 2017-05-24 Yao Qi <yao.qi@linaro.org>
6391
6392 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
6393 TYPE_CODE_FLT or not.
6394
6395 2017-05-24 Yao Qi <yao.qi@linaro.org>
6396
6397 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6398 * avr-tdep.c (avr_gdbarch_init): Likewise.
6399 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6400 * cris-tdep.c (cris_gdbarch_init): Likewise.
6401 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6402 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6403 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6404 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6405 * mep-tdep.c (mep_gdbarch_init): Likewise.
6406 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6407 * mips-tdep.c (mips_gdbarch_init): Likewise.
6408 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6409 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6410 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6411 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6412 * v850-tdep.c (v850_gdbarch_init): Likewise.
6413
6414 2017-05-24 Yao Qi <yao.qi@linaro.org>
6415
6416 * selftest-arch.c (tests_with_arch): Call registers_changed
6417 and reinit_frame_cache.
6418 * selftest.c (run_self_tests): Likewise.
6419
6420 2017-05-24 Yao Qi <yao.qi@linaro.org>
6421
6422 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6423 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6424
6425 2017-05-24 Yao Qi <yao.qi@linaro.org>
6426
6427 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6428 set_gdbarch_print_insn.
6429
6430 2017-05-24 Yao Qi <yao.qi@linaro.org>
6431
6432 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6433 set_gdbarch_print_insn.
6434
6435 2017-05-24 Yao Qi <yao.qi@linaro.org>
6436
6437 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6438 set_gdbarch_print_insn.
6439 * arc-tdep.c (arc_gdbarch_init): Likewise.
6440 * arch-utils.c: include dis-asm.h.
6441 (default_print_insn): New function.
6442 * arch-utils.h (default_print_insn): Declare.
6443 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6444 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6445 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6446 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6447 * frv-tdep.c (frv_gdbarch_init): Likewise.
6448 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6449 * gdbarch.sh (print_insn): Use default_print_insn.
6450 * gdbarch.c: Regenerated.
6451 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6452 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6453 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6454 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6455 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6456 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6457 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6458 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6459 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6460 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6461 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6462 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6463 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6464 * mt-tdep.c (mt_gdbarch_init): Likewise.
6465 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6466 * nios2-tdep.c (nios2_print_insn): Remove.
6467 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6468 * rx-tdep.c (rx_gdbarch_init): Likewise.
6469 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6470 * score-tdep.c (score_print_insn): Remove.
6471 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6472 * sh-tdep.c (sh_gdbarch_init): Likewise.
6473 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6474 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6475 * tic6x-tdep.c (tic6x_print_insn): Remove.
6476 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6477 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6478 * v850-tdep.c (v850_gdbarch_init): Likewise.
6479 * vax-tdep.c (vax_gdbarch_init): Likewise.
6480 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6481 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6482
6483 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6484
6485 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6486 (MIPS_FP0_REGNUM): Remove.
6487 (MIPS_FSR_REGNUM): Remove.
6488 (mips_fbsd_supply_fpregs): Use mips_regnum.
6489 (mips_fbsd_supply_gregs): Likewise.
6490 (mips_fbsd_collect_fpregs): Likewise.
6491 (mips_fbsd_collect_gregs): Likewise.
6492
6493 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6494
6495 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6496 (getpfpregs_supplies): New function.
6497 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6498 getfpregs_supplies.
6499 (mips_fbsd_store_inferior_registers): Likewise.
6500
6501 2017-05-22 Pedro Alves <palves@redhat.com>
6502
6503 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6504 maintainer.
6505
6506 2017-05-22 Alan Hayward <alan.hayward@arm.com>
6507
6508 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6509 (store_register): Likewise.
6510 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6511 (get_decimal_float_return_value): Likewise.
6512 (do_ppc_sysv_return_value): Likewise.
6513 (ppc64_sysv_abi_push_integer): Likewise.
6514 (ppc64_sysv_abi_push_freg): Likewise.
6515 (ppc64_sysv_abi_return_value_base): Likewise.
6516 (ppc64_sysv_abi_return_value): Likewise.
6517 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6518 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6519 * rs6000-nat.c: Likewise.
6520 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6521 (rs6000_value_to_register): Likewise.
6522 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6523
6524 2017-05-21 Tom Tromey <tom@tromey.com>
6525
6526 PR rust/21466:
6527 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6528 arrays as "[T]", not "[T; ]".
6529
6530 2017-05-19 Tom Tromey <tom@tromey.com>
6531
6532 PR rust/21484:
6533 * rust-lang.c (exp_descriptor_rust): New function.
6534 (rust_language_defn): Use it.
6535 * p-lang.c (pascal_language_defn): Update.
6536 * opencl-lang.c (opencl_language_defn): Update.
6537 * objc-lang.c (objc_language_defn): Update.
6538 * m2-lang.c (m2_language_defn): Update.
6539 * language.h (struct language_defn)
6540 <la_watch_location_expression>: New member.
6541 * language.c (unknown_language_defn, auto_language_defn)
6542 (local_language_defn): Update.
6543 * go-lang.c (go_language_defn): Update.
6544 * f-lang.c (f_language_defn): Update.
6545 * d-lang.c (d_language_defn): Update.
6546 * c-lang.h (c_watch_location_expression): Declare.
6547 * c-lang.c (c_watch_location_expression): New function.
6548 (c_language_defn, cplus_language_defn, asm_language_defn)
6549 (minimal_language_defn): Use it.
6550 * breakpoint.c (watch_command_1): Call
6551 la_watch_location_expression.
6552 * ada-lang.c (ada_language_defn): Update.
6553
6554 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6555
6556 PR tui/21482
6557 * gdb_curses.h (NOMACROS): Define.
6558 (NCURSES_NOMACROS): Define.
6559
6560 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6561
6562 PR tui/21482
6563 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6564 arg to char *.
6565 * tui/tui-wingeneral.c (box_win): Likewise.
6566 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6567 (tui_show_source_line): Likewise.
6568 (tui_show_exec_info_content): Likewise.
6569
6570 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6571
6572 * sparc-tdep.c (sparc_structure_return_p)
6573 (sparc_arg_on_registers_p): New functions.
6574 (sparc32_store_arguments): Use them.
6575 * sparc64-tdep.c (sparc64_16_byte_align_p)
6576 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6577 Handle TYPE_CODE_ARRAY.
6578
6579 2017-05-17 Yao Qi <yao.qi@linaro.org>
6580
6581 * cli/cli-decode.c (add_alias_cmd): New function.
6582 * command.h (add_alias_cmd): Declare.
6583 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6584 instead call add_alias_cmd.
6585
6586 2017-05-17 Pedro Alves <palves@redhat.com>
6587
6588 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6589 (nat_makefile_frag): ... this. All references updated.
6590 * configure.ac: Likewise.
6591 * configure.nat: Likewise. Enhance comments.
6592 * configure: Regenerate.
6593
6594 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6595
6596 * procfs.c (procfs_create_inferior): Change prototype to match
6597 definition.
6598
6599 2017-05-13 Eli Zaretskii <eliz@gnu.org>
6600
6601 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6602 C++ compiler warning.
6603
6604 2017-05-12 Tom Tromey <tom@tromey.com>
6605
6606 PR rust/21483:
6607 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6608 recurse, just call value_struct_elt directly.
6609
6610 2017-05-12 Tom Tromey <tom@tromey.com>
6611
6612 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6613 OP_RUST_ARRAY>: Fix.
6614
6615 2017-05-12 Tom Tromey <tom@tromey.com>
6616
6617 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6618
6619 2017-05-09 Yao Qi <yao.qi@linaro.org>
6620
6621 * regcache.c: Include <forward_list>.
6622 (struct regcache_list): Remove.
6623 (current_regcache): Update.
6624 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6625 (regcache_thread_ptid_changed): Likewise.
6626 (registers_changed_ptid): Likewise.
6627 (current_regcache_size): Likewise.
6628
6629 2017-05-09 Yao Qi <yao.qi@linaro.org>
6630
6631 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6632 (current_regcache_size): New function.
6633 (current_regcache_test): New function.
6634 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6635
6636 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6637
6638 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6639 (print_gp_register_row): Use get_frame_register_value.
6640
6641 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6642
6643 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6644 (mips_supply_fpregset): Likewise.
6645 (mips64_supply_gregset): Likewise.
6646
6647 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6648
6649 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6650 regcache->raw_supply_zeroed.
6651
6652 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6653
6654 * configure.nat: Rearrange 'case' statements to match
6655 host before cpu.
6656
6657 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6658
6659 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6660 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6661 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6662 "@nat_extra_makefile_frag@".
6663 (Makefile): Remove dependency on "@frags@".
6664 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6665 (data-directory/Makefile): Likewise.
6666 * config/aarch64/linux.mh: Deleted; moved contents to
6667 "gdb/configure.nat".
6668 * config/alpha/alpha-linux.mh: Likewise.
6669 * config/alpha/nbsd.mh: Likewise.
6670 * config/arm/linux.mh: Likewise.
6671 * config/arm/nbsdelf.mh: Likewise.
6672 * config/i386/cygwin.mh: Likewise.
6673 * config/i386/cygwin64.mh: Likewise.
6674 * config/i386/darwin.mh: Likewise.
6675 * config/i386/fbsd.mh: Likewise.
6676 * config/i386/fbsd64.mh: Likewise.
6677 * config/i386/go32.mh: Likewise.
6678 * config/i386/i386gnu.mh: Likewise.
6679 * config/i386/i386sol2.mh: Likewise.
6680 * config/i386/linux.mh: Likewise.
6681 * config/i386/linux64.mh: Likewise.
6682 * config/i386/mingw.mh: Likewise.
6683 * config/i386/mingw64.mh: Likewise.
6684 * config/i386/nbsd64.mh: Likewise.
6685 * config/i386/nbsdelf.mh: Likewise.
6686 * config/i386/nto.mh: Likewise.
6687 * config/i386/obsd.mh: Likewise.
6688 * config/i386/obsd64.mh: Likewise.
6689 * config/i386/sol2-64.mh: Likewise.
6690 * config/ia64/linux.mh: Likewise.
6691 * config/m32r/linux.mh: Likewise.
6692 * config/m68k/linux.mh: Likewise.
6693 * config/m68k/nbsdelf.mh: Likewise.
6694 * config/m68k/obsd.mh: Likewise.
6695 * config/m88k/obsd.mh: Likewise.
6696 * config/mips/fbsd.mh: Likewise.
6697 * config/mips/linux.mh: Likewise.
6698 * config/mips/nbsd.mh: Likewise.
6699 * config/mips/obsd64.mh: Likewise.
6700 * config/pa/linux.mh: Likewise.
6701 * config/pa/nbsd.mh: Likewise.
6702 * config/pa/obsd.mh: Likewise.
6703 * config/powerpc/aix.mh: Likewise.
6704 * config/powerpc/fbsd.mh: Likewise.
6705 * config/powerpc/linux.mh: Likewise.
6706 * config/powerpc/nbsd.mh: Likewise.
6707 * config/powerpc/obsd.mh: Likewise.
6708 * config/powerpc/ppc64-linux.mh: Likewise.
6709 * config/powerpc/spu-linux.mh: Likewise.
6710 * config/s390/linux.mh: Likewise.
6711 * config/sh/nbsd.mh: Likewise.
6712 * config/sparc/fbsd.mh: Likewise.
6713 * config/sparc/linux.mh: Likewise.
6714 * config/sparc/linux64.mh: Likewise.
6715 * config/sparc/nbsd64.mh: Likewise.
6716 * config/sparc/nbsdelf.mh: Likewise.
6717 * config/sparc/obsd64.mh: Likewise.
6718 * config/sparc/sol2.mh: Likewise.
6719 * config/tilegx/linux.mh: Likewise.
6720 * config/vax/nbsdelf.mh: Likewise.
6721 * config/vax/obsd.mh: Likewise.
6722 * config/xtensa/linux.mh: Likewise.
6723 * config/i386/i386gnu.mn: New file, with excerpts from
6724 "config/i386/i386gnu.mh".
6725 * configure: Regenerate.
6726 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
6727 *.mh files under "gdb/config".
6728 * configure.nat: New file, with contents from the
6729 "gdb/config/*/*.mh" files.
6730
6731 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
6732
6733 * btrace.c (btrace_clear): Free insn vector.
6734
6735 2017-05-05 Pedro Alves <palves@redhat.com>
6736
6737 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
6738 * configure: Regenerate.
6739
6740 2017-05-04 Pedro Alves <palves@redhat.com>
6741
6742 * Makefile.in (SFILES): Add progspace-and-thread.c.
6743 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
6744 (COMMON_OBS): Add progspace-and-thread.o.
6745 * breakpoint.c: Include "progspace-and-thread.h".
6746 (update_inserted_breakpoint_locations)
6747 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
6748 Use scoped_restore_current_pspace_and_thread.
6749 (create_std_terminate_master_breakpoint): Use
6750 scoped_restore_current_program_space.
6751 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
6752 (print_breakpoint_location): Use
6753 scoped_restore_current_program_space.
6754 (bp_loc_is_permanent): Use
6755 scoped_restore_current_pspace_and_thread.
6756 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
6757 (download_tracepoint_locations): Use
6758 scoped_restore_current_pspace_and_thread.
6759 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
6760 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
6761 (enum step_over_calls_kind): Moved from inferior.h.
6762 (class scoped_restore_current_thread): New class.
6763 * gdbthread.h (make_cleanup_restore_current_thread): Delete
6764 declaration.
6765 (scoped_restore_current_thread): New class.
6766 * infcmd.c: Include "common/gdb_optional.h".
6767 (continue_1, proceed_after_attach): Use
6768 scoped_restore_current_thread.
6769 (notice_new_inferior): Use scoped_restore_current_thread.
6770 * inferior.c: Include "progspace-and-thread.h".
6771 (restore_inferior, save_current_inferior): Delete.
6772 (add_inferior_command, clone_inferior_command): Use
6773 scoped_restore_current_pspace_and_thread.
6774 * inferior.h (scoped_restore_current_inferior): New class.
6775 * infrun.c: Include "progspace-and-thread.h" and
6776 "common/gdb_optional.h".
6777 (follow_fork_inferior): Use
6778 scoped_restore_current_pspace_and_thread.
6779 (scoped_restore_exited_inferior): New class.
6780 (handle_vfork_child_exec_or_exit): Use
6781 scoped_restore_exited_inferior,
6782 scoped_restore_current_pspace_and_thread,
6783 scoped_restore_current_thread and scoped_restore.
6784 (fetch_inferior_event): Use scoped_restore_current_thread.
6785 * linespec.c (decode_line_full, decode_line_1): Use
6786 scoped_restore_current_program_space.
6787 * mi/mi-main.c: Include "progspace-and-thread.h".
6788 (exec_continue): Use scoped_restore_current_thread.
6789 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
6790 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
6791 * proc-service.c (ps_pglobal_lookup): Use
6792 scoped_restore_current_program_space.
6793 * progspace-and-thread.c: New file.
6794 * progspace-and-thread.h: New file.
6795 * progspace.c (release_program_space, clone_program_space): Use
6796 scoped_restore_current_program_space.
6797 (restore_program_space, save_current_program_space)
6798 (save_current_space_and_thread): Delete.
6799 (switch_to_program_space_and_thread): Moved to
6800 progspace-and-thread.c.
6801 * progspace.h (save_current_program_space)
6802 (save_current_space_and_thread): Delete declarations.
6803 (scoped_restore_current_program_space): New class.
6804 * remote.c (remote_btrace_maybe_reopen): Use
6805 scoped_restore_current_thread.
6806 * symtab.c: Include "progspace-and-thread.h".
6807 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
6808 * thread.c (print_thread_info_1): Use
6809 scoped_restore_current_thread.
6810 (struct current_thread_cleanup): Delete.
6811 (do_restore_current_thread_cleanup)
6812 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
6813 (scoped_restore_current_thread::~scoped_restore_current_thread):
6814 ... this new dtor.
6815 (make_cleanup_restore_current_thread): Rename/convert to ...
6816 (scoped_restore_current_thread::scoped_restore_current_thread):
6817 ... this new ctor.
6818 (thread_apply_all_command): Use scoped_restore_current_thread.
6819 (thread_apply_command): Use scoped_restore_current_thread.
6820 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
6821 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
6822
6823 2017-05-04 Pedro Alves <palves@redhat.com>
6824
6825 * thread.c (make_cleanup_restore_current_thread): Move
6826 find_thread_ptid call before the is_stopped call. Assert that the
6827 thread is found. Replace is_stopped call by checking the thread's
6828 state directly. Remove unnecessary NULL-thread check.
6829
6830 2017-05-04 Pedro Alves <palves@redhat.com>
6831
6832 * corelow.c (thread_section_name): New class.
6833 (get_core_register_section, get_core_siginfo): Use it.
6834
6835 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
6836
6837 * corelow.c (sniff_core_bfd): Remove extra semicolon.
6838 (get_core_register_section): Remove xfree of NULL pointer.
6839
6840 2017-05-03 Alan Hayward <alan.hayward@arm.com>
6841
6842 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
6843 * regcache.c (regcache::raw_supply_zeroed): New function.
6844 * regcache.h (regcache::raw_supply_zeroed): New declaration.
6845
6846 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
6847
6848 * gdbarch.sh: Remove commented out definition of
6849 TARGET_CHAR_BIT.
6850 * gdbarch.h: Re-generate.
6851
6852 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6853
6854 * configure: Regenerate.
6855
6856 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
6857
6858 * solib-target.c (solib_target_relocate_section_addresses):
6859 Remove num_section_bases, num_bases, segment_bases variables.
6860
6861 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6862
6863 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
6864
6865 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6866
6867 * solib-target.c: Include <vector>
6868 (struct lm_info_target) <~lm_info_target>: Remove.
6869 <segment_bases, section_bases>: Change type to
6870 std::vector<CORE_ADDR>.
6871 (library_list_start_segment, library_list_start_section,
6872 library_list_end_library,
6873 solib_target_relocate_section_addresses): Adjust.
6874
6875 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6876
6877 * gdbarch.sh (software_single_step): Change return type to
6878 std::vector<CORE_ADDR>.
6879 * gdbarch.c, gdbarch.h: Re-generate.
6880 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
6881 Adjust.
6882 (arm_deal_with_atomic_sequence_raw): Adjust.
6883 (thumb_get_next_pcs_raw): Adjust.
6884 (arm_get_next_pcs_raw): Adjust.
6885 (arm_get_next_pcs): Adjust.
6886 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
6887 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
6888 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
6889 (alpha_software_single_step): Adjust.
6890 * alpha-tdep.h (alpha_software_single_step): Adjust.
6891 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
6892 * arm-tdep.c (arm_software_single_step): Adjust.
6893 (arm_breakpoint_kind_from_current_state): Adjust.
6894 * arm-tdep.h (arm_software_single_step): Adjust.
6895 * breakpoint.c (insert_single_step_breakpoint): Adjust.
6896 * cris-tdep.c (cris_software_single_step): Adjust.
6897 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
6898 (micromips_deal_with_atomic_sequence): Adjust.
6899 (deal_with_atomic_sequence): Adjust.
6900 (mips_software_single_step): Adjust.
6901 * mips-tdep.h (mips_software_single_step): Adjust.
6902 * moxie-tdep.c (moxie_software_single_step): Adjust.
6903 * nios2-tdep.c (nios2_software_single_step): Adjust.
6904 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
6905 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
6906 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
6907 * s390-linux-tdep.c (s390_software_single_step): Adjust.
6908 * sparc-tdep.c (sparc_software_single_step): Adjust.
6909 * spu-tdep.c (spu_software_single_step): Adjust.
6910 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
6911
6912 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6913
6914 * gdbarch.sh: Use semi-colon as field separator instead of colon.
6915 * gdbarch.h: Re-generate.
6916
6917 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6918
6919 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
6920 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
6921 * python/py-instruction.c, python/py-instruction.h: New file.
6922 * python/py-record.c: Add py-instruction.h include.
6923 (gdbpy_initialize_record): Make gdb.Instruction a super class of
6924 gdb.RecordInstruction.
6925 * python/python-internal.h: Add gdbpy_initialize_instruction
6926 declaration.
6927 * python/python.c (do_start_initialization): Add
6928 gdbpy_initialize_instruction.
6929
6930 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6931
6932 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
6933 Remove.
6934 (btrace_func_from_recpy_func): New function.
6935 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
6936 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
6937 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
6938 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
6939 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
6940 Also, use new helper functions.
6941 (btpy_list_item): Use new helper functions.
6942 (recpy_bt_function_call_history): Use new type name.
6943 (btpy_call_getset): Remove.
6944 (gdbpy_initialize_btrace): Remove code to initialize
6945 gdb.BtraceFunctionCall.
6946 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
6947 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
6948 recpy_bt_func_prev, recpy_bt_func_next): New export.
6949 * python/py-record.c (recpy_func_type): New static object.
6950 (recpy_func_new, recpy_func_level, recpy_func_symbol,
6951 recpy_func_instructions, recpy_func_up, recpy_func_prev,
6952 recpy_func_next): New function.
6953 (recpy_element_hash, recpy_element_richcompare): Updated comment.
6954 (recpy_func_getset): New static object.
6955 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
6956 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
6957
6958 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6959
6960 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
6961 (btpy_object, btpy_insn_type, btpy_new): Remove.
6962 (btpy_list_object): Use gdb.RecordInstruction type instead of
6963 gdb.BtraceInstruction type.
6964 (btrace_insn_from_recpy_insn): New function.
6965 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
6966 btpy_new.
6967 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
6968 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
6969 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
6970 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
6971 instead of btpy_object.
6972 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6973 btpy_insn_data, btpy_insn_decode): Rename to ...
6974 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
6975 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
6976 recpy_bt_insn_decode): This. Also, use new helper functions.
6977 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
6978 recpy_insn_type.
6979 (btpy_insn_getset): Remove.
6980 (gdbpy_initialize_btrace): Remove code to initialize
6981 gdb.BtraceInstruction. Use recpy_element_object.
6982 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
6983 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
6984 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
6985 * python/py-record.c (recpy_insn_type): New static object.
6986 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
6987 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
6988 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
6989 New function.
6990 (recpy_insn_getset): New static object.
6991 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
6992 * python/py-record.h (recpy_element_object): New typedef.
6993 (recpy_insn_type, recpy_insn_new): New export.
6994
6995 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6996
6997 * py-record-btrace.c (btpy_insn_new): Removed.
6998 (btpy_insn_or_gap_new): New function.
6999 (btpy_insn_error): Removed.
7000 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
7001 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
7002 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
7003 btpy_insn_or_gap_new instead of btpy_insn_new.
7004 (btpy_insn_getset): Remove btpy_insn_error.
7005 * py-record.c (recpy_gap_type): New static object.
7006 (recpy_gap_object): New typedef.
7007 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
7008 recpy_gap_reason_string): New function.
7009 (recpy_gap_getset): New static object.
7010 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
7011 * py-record.h (recpy_gap_new): New export.
7012
7013 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7014
7015 * python/py-record.c (recpy_ptid): Remove.
7016 (recpy_record_getset): Remove recpy_ptid.
7017
7018 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7019
7020 * btrace.c (btrace_fetch): Set inferior_ptid.
7021 * python/py-record-btrace.c: Add "py-record.h" include.
7022 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
7023 recpy_bt_end, recpy_bt_instruction_history,
7024 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
7025 in gdb.Record object instead of current ptid.
7026 * python/py-record.c: Include new "py-record.h" file.
7027 (recpy_record_object): Moved to py-record.h.
7028 * python/py-record.h: New file.
7029
7030 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7031
7032 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
7033 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
7034 indentation.
7035
7036 2017-05-01 Joel Brobecker <brobecker@adacore.com>
7037
7038 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
7039 the past maintainers section.
7040
7041 2017-04-28 Yao Qi <yao.qi@linaro.org>
7042
7043 * infcmd.c (get_return_value): Use regcache ctor, and remove
7044 cleanup.
7045
7046 2017-04-28 Yao Qi <yao.qi@linaro.org>
7047 Pedro Alves <palves@redhat.com>
7048
7049 * regcache.c (regcache::regcache): New tag dispatch ctor.
7050 (do_cooked_read): Moved above.
7051 (regcache_dup): Use the tag dispatch ctor..
7052 * regcache.h (regcache): Declare ctor, delete copy ctor and
7053 assignment operator, remove friend regcache_dup.
7054
7055 2017-04-28 Yao Qi <yao.qi@linaro.org>
7056
7057 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
7058 call method save instead of regcache_cpy.
7059 * regcache.h (struct regcache): Make regcache_dup a friend.
7060
7061 2017-04-28 Yao Qi <yao.qi@linaro.org>
7062
7063 * regcache.c (struct regcache): Move to regcache.h
7064 (regcache::arch): New method.
7065 (regcache_get_ptid): Update.
7066 (get_regcache_arch): Call arch method.
7067 (get_regcache_aspace): Call method aspace.
7068 (register_buffer): Change it to method.
7069 (regcache_save): Change it to regcache::save.
7070 (regcache_restore): Likewise.
7071 (regcache_cpy_no_passthrough): Remove the declaration.
7072 (regcache_cpy): Call methods restore and cpy_no_passthrough.
7073 (regcache_cpy_no_passthrough): Change it to method
7074 cpy_no_passthrough.
7075 (regcache_register_status): Change it to method
7076 get_register_status.
7077 (regcache_invalidate): Change it to method invalidate.
7078 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
7079 (regcache_raw_update): Change it to method raw_update.
7080 (regcache_raw_read): Likewise.
7081 (regcache_raw_read_signed): Likewise.
7082 (regcache_raw_read_unsigned): Likewise.
7083 (regcache_raw_write_signed): Likewise.
7084 (regcache_raw_write_unsigned): Likewise.
7085 (regcache_cooked_read): Likewise.
7086 (regcache_cooked_read_value): Likewise.
7087 (regcache_cooked_read_signed): Likewise.
7088 (regcache_cooked_read_unsigned): Likewise.
7089 (regcache_cooked_write_signed): Likewise.
7090 (regcache_cooked_write_unsigned): Likewise.
7091 (regcache_raw_set_cached_value): Likewise.
7092 (regcache_raw_write): Likewise.
7093 (regcache_cooked_write): Likewise.
7094 (regcache_xfer_part): Likewise.
7095 (regcache_raw_read_part): Likewise.
7096 (regcache_raw_write_part): Likewise.
7097 (regcache_cooked_read_part): Likewise.
7098 (regcache_cooked_write_part): Likewise.
7099 (regcache_raw_supply): Likewise.
7100 (regcache_raw_collect): Likewise.
7101 (regcache_transfer_regset): Likewise.
7102 (regcache_supply_regset): Likewise.
7103 (regcache_collect_regset): Likewise.
7104 (regcache_debug_print_register): Likewise.
7105 (enum regcache_dump_what): Move it to regcache.h.
7106 (regcache_dump): Change it to method dump.
7107 * regcache.h (enum regcache_dump_what): New.
7108 (class regcache): New.
7109 * target.c (target_fetch_registers): Call method
7110 debug_print_register.
7111 (target_store_registers): Likewise.
7112
7113 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7114
7115 * windows-nat.c (struct lm_info_windows): Initialize field.
7116 (windows_make_so): Allocate lm_info_windows with new.
7117 (windows_free_so): Free lm_info_windows with delete.
7118
7119 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7120
7121 * solib-darwin.c (struct lm_info_darwin): Initialize field.
7122 (darwin_current_sos): Allocate lm_info_darwin with new, remove
7123 cleanup.
7124 (darwin_free_so): Free lm_info_darwin with delete.
7125
7126 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7127
7128 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
7129 <l_addr_p>: Change type to bool.
7130 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
7131 (svr4_free_so): Free lm_info_svr4 with delete.
7132 (svr4_copy_library_list): Replace memcpy with call to copy
7133 constructor.
7134 (library_list_start_library, svr4_default_sos): Allocate
7135 lm_info_svr4 with new.
7136
7137 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7138
7139 * solib-target.c (struct lm_info_target): Add destructor,
7140 initialize fields.
7141 <name>: Change type to std::string.
7142 (library_list_start_library): Allocate lm_info_target with new.
7143 (solib_target_free_library_list): Free lm_info_target with
7144 delete.
7145 (solib_target_current_sos): Adapt to std::string.
7146 (solib_target_free_so): Free lm_info_target with delete.
7147
7148 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7149
7150 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
7151 fields.
7152 (frv_current_sos): Allocate lm_info_frv with new.
7153 (frv_relocate_main_executable): Free lm_info_frv with delete,
7154 allocate with new.
7155 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
7156
7157 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7158
7159 * solib-frv.c (struct lm_info_frv): Fix indentation.
7160
7161 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7162
7163 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
7164 map field.
7165 (dsbt_current_sos): Allocate lm_info_dsbt with new.
7166 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
7167 and allocate with new.
7168 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
7169
7170 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7171
7172 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
7173 <filename, member_name>: Change type to std::string.
7174 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
7175 (library_list_start_library): Allocate lm_info_aix with new.
7176 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
7177 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
7178 with copy constructor.
7179
7180 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7181
7182 * solist.h (struct lm_info): Remove.
7183 (struct lm_info_base): New class.
7184 (struct so_list) <lm_info>: Change type to lm_info_base *.
7185 * nto-tdep.c (struct lm_info): Remove.
7186 (lm_addr): Adjust.
7187 * solib-aix.c (struct lm_info): Rename to ...
7188 (struct lm_info_aix): ... this. Extend lm_info_base.
7189 (lm_info_p): Rename to ...
7190 (lm_info_aix_p): ... this, and adjust.
7191 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
7192 solib_aix_parse_libraries, library_list_start_library,
7193 solib_aix_free_library_list, solib_aix_parse_libraries,
7194 solib_aix_get_library_list,
7195 solib_aix_relocate_section_addresses, solib_aix_free_so,
7196 solib_aix_get_section_offsets,
7197 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
7198 Adjust.
7199 (struct solib_aix_inferior_data) <library_list>: Adjust.
7200 * solib-darwin.c (struct lm_info): Rename to ...
7201 (struct lm_info_darwin): ... this. Extend lm_info_base.
7202 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
7203 * solib-dsbt.c (struct lm_info): Rename to ...
7204 (struct lm_info_dsbt): ... this. Extend lm_info_base.
7205 (struct dsbt_info) <main_executable_lm_info): Adjust.
7206 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
7207 dsbt_relocate_section_addresses): Adjust.
7208 * solib-frv.c (struct lm_info): Rename to ...
7209 (struct lm_info_frv): ... this. Extend lm_info_base.
7210 (main_executable_lm_info): Adjust.
7211 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
7212 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
7213 find_canonical_descriptor_in_load_object,
7214 frv_fdpic_find_canonical_descriptor): Adjust.
7215 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
7216 to lm_info_svr4.
7217 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
7218 svr4_clear_so, svr4_copy_library_list,
7219 library_list_start_library, svr4_default_sos, svr4_read_so_list,
7220 svr4_current_sos, svr4_fetch_objfile_link_map,
7221 solist_update_incremental): Adjust.
7222 * solib-svr4.h (struct lm_info_svr4): Move here from
7223 solib-svr4.c.
7224 * solib-target.c (struct lm_info): Rename to ...
7225 (struct lm_info_target): ... this. Extend lm_info_base.
7226 (lm_info_p): Rename to ...
7227 (lm_info_target_p): ... this.
7228 (solib_target_parse_libraries, library_list_start_segment,
7229 library_list_start_section, library_list_start_library,
7230 library_list_end_library, solib_target_free_library_list,
7231 solib_target_current_sos, solib_target_free_so,
7232 solib_target_relocate_section_addresses): Adjust.
7233 * windows-nat.c (struct lm_info): Rename to ...
7234 (struct lm_info_windows): ... this. Extend lm_info_base.
7235 (windows_make_so, handle_load_dll, handle_unload_dll,
7236 windows_xfer_shared_libraries): Adjust.
7237
7238 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7239
7240 * solib-darwin.c (struct darwin_so_list): Remove.
7241 (darwin_current_sos): Allocate an so_list object instead of a
7242 darwin_so_list, separately allocate an lm_info object.
7243 (darwin_free_so): Free lm_info.
7244
7245 2017-04-28 John Baldwin <jhb@FreeBSD.org>
7246
7247 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
7248 with fprintf_filtered.
7249
7250 2017-04-28 Yao Qi <yao.qi@linaro.org>
7251
7252 * regcache.c (regcache::regcache): New function.
7253 (regcache::~regcache): New function.
7254 (regcache_xmalloc_1): Remove.
7255 (regcache_xmalloc): Call new regcache.
7256 (regcache_xfree): Call delete regcache.
7257 (get_thread_arch_aspace_regcache): Call new regcache.
7258
7259 2017-04-28 Yao Qi <yao.qi@linaro.org>
7260
7261 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
7262 lwp instead of ptid_get_lwp.
7263
7264 2017-04-28 Yao Qi <yao.qi@linaro.org>
7265
7266 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
7267 lwp_info instead of getting from inferior_ptid.
7268
7269 2017-04-27 Keith Seitz <keiths@redhat.com>
7270
7271 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
7272 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
7273 (CV_CONVERSION_BADNESS): Define.
7274 (rank_one_type): Remove overly restrictive rvalue reference
7275 rank checks.
7276 Add cv-qualifier checks and subranks for type equality.
7277 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
7278 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
7279 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
7280
7281 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
7282
7283 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
7284 count when creating the object.
7285
7286 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
7287 Ulrich Weigand <uweigand@de.ibm.com>
7288
7289 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
7290 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
7291 is used in AIX.
7292 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
7293 (process_xcoff_symbol): Likewise.
7294 (scan_xcoff_symtab): Likewise.
7295
7296 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7297
7298 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
7299 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
7300 (ia64_access_reg): Use get_frame_register_unsigned.
7301 (ia64_access_rse_reg): Likewise.
7302 (ia64_libunwind_frame_prev_register): Likewise.
7303
7304 2017-04-26 Jiong Wang <jiong.wang@arm.com>
7305
7306 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
7307 * gdbarch.c: Regenerated.
7308 * gdbarch.h: Regenerated.
7309 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
7310 visibility external.
7311 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
7312 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
7313 (enum cfa_how_kind): Move to ...
7314 (struct dwarf2_frame_state_reg_info): Likewise.
7315 (struct dwarf2_frame_state): Likewise.
7316 * dwarf2-frame.h: ... here.
7317 (dwarf2_frame_state_alloc_regs): New declaration.
7318 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
7319 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
7320
7321 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7322
7323 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
7324 regcache_raw_read_unsigned.
7325 (xtensa_pseudo_register_write): Likewise.
7326
7327 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7328
7329 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
7330 (nds32_pseudo_register_write): Likewise.
7331
7332 2017-04-25 Yao Qi <yao.qi@linaro.org>
7333
7334 * regcache.c (struct regcache) <readonly_p>: Change its type
7335 to bool.
7336 (regcache_xmalloc_1): Update parameter type and callers update.
7337
7338 2017-04-25 Yao Qi <yao.qi@linaro.org>
7339
7340 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
7341 set_gdbarch_wchar_bit.
7342 * arm-tdep.c (arm_gdbarch_init): Likewise.
7343
7344 2017-04-25 Pedro Alves <palves@redhat.com>
7345
7346 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
7347 (BothAreRelocatable, memcopy, memmove): Don't define.
7348 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
7349 macros.
7350
7351 2017-04-25 Pedro Alves <palves@redhat.com>
7352
7353 * common/common-defs.h: Include "common/poison.h".
7354 * common/function-view.h: (Not, Or, Requires): Move to traits.h
7355 and adjust.
7356 * common/poison.h: New file.
7357 * common/traits.h: Include <type_traits>.
7358 (Not, Or, Requires): New, moved from common/function-view.h.
7359
7360 2017-04-25 Pedro Alves <palves@redhat.com>
7361
7362 * breakpoint.h (struct breakpoint): In-class initialize all
7363 fields. Make boolean fields "bool".
7364 * breakpoint.c (init_raw_breakpoint_without_location): Remove
7365 memset call and initializations no longer necessary.
7366
7367 2017-04-25 Pedro Alves <palves@redhat.com>
7368
7369 * btrace.c (pt_btrace_insn_flags): Change parameter type to
7370 reference.
7371 (pt_btrace_insn): New function.
7372 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
7373
7374 2017-04-25 Pedro Alves <palves@redhat.com>
7375
7376 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
7377 "base" field and inherit from "bp_location" instead. Add
7378 non-default ctor.
7379 (allocate_location_exception): Use new non-default ctor.
7380 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
7381 (init_bp_location): Convert to ...
7382 (bp_location::bp_location): ... this new ctor, and remove memset
7383 call.
7384 (base_breakpoint_allocate_location): Use the new non-default ctor.
7385 * breakpoint.h (bp_location): Now a class. Declare default and
7386 non-default ctors. In-class initialize all members.
7387 (init_bp_location): Remove declaration.
7388
7389 2017-04-25 Pedro Alves <palves@redhat.com>
7390
7391 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
7392 assignment operator.
7393
7394 2017-04-24 Yao Qi <yao.qi@linaro.org>
7395
7396 * doublest.c (convert_doublest_to_floatformat): Call
7397 floatformat_totalsize_bytes.
7398
7399 2017-04-22 Tom Tromey <tom@tromey.com>
7400
7401 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7402 ui_out_emit_list.
7403 * stack.c (print_frame): Use ui_out_emit_list.
7404 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7405 ui_out_emit_list.
7406 * mi/mi-main.c (print_one_inferior)
7407 (mi_cmd_data_list_register_names)
7408 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7409 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7410 ui_out_emit_list.
7411 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7412 (mi_output_solib_attribs): Use ui_out_emit_list,
7413 ui_out_emit_tuple.
7414 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7415 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7416 (mi_cmd_stack_list_args, list_args_or_locals): Use
7417 ui_out_emit_list.
7418 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7419 * breakpoint.c (print_solib_event, output_thread_groups): Use
7420 ui_out_emit_list.
7421
7422 2017-04-22 Tom Tromey <tom@tromey.com>
7423
7424 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7425 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7426 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7427
7428 2017-04-22 Tom Tromey <tom@tromey.com>
7429
7430 * tracepoint.c (tvariables_info_1)
7431 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7432
7433 2017-04-22 Tom Tromey <tom@tromey.com>
7434
7435 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7436 annotate_arg_emitter.
7437 * breakpoint.c (print_mention_watchpoint)
7438 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7439 * annotate.h (struct annotate_arg_emitter): New.
7440
7441 2017-04-22 Tom Tromey <tom@tromey.com>
7442
7443 * record-btrace.c (record_btrace_insn_history)
7444 (record_btrace_insn_history_range, record_btrace_call_history)
7445 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7446 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7447 ui_out_emit_tuple.
7448 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7449 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7450 * skip.c (skip_info): Use ui_out_emit_tuple.
7451 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7452 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7453 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7454 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7455 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7456 ui_out_emit_tuple.
7457 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7458 (output_register, mi_cmd_data_read_memory)
7459 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7460 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7461 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7462 Use ui_out_emit_tuple.
7463 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7464 ui_out_emit_tuple.
7465 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7466 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7467 * linux-thread-db.c (info_auto_load_libthread_db): Use
7468 ui_out_emit_tuple.
7469 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7470 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7471 * disasm.c (do_mixed_source_and_assembly_deprecated)
7472 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7473 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7474 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7475 * breakpoint.c (print_one_breakpoint_location)
7476 (print_one_breakpoint): Use ui_out_emit_tuple.
7477 * auto-load.c (print_script, info_auto_load_cmd): Use
7478 ui_out_emit_tuple.
7479 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7480
7481 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7482
7483 * thread.c (print_thread_info_1): Remove dead code.
7484
7485 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7486
7487 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7488 GDB_SELF_TEST.
7489 * arm-tdep.c (selftests::arm_record_test): Likewise.
7490
7491 2017-04-21 Yao Qi <yao.qi@linaro.org>
7492
7493 * regcache.c (regcache_restore): Remove argument 2. Replace
7494 argument 3 with regcache. Get register status from
7495 src->register_status and get register contents from
7496 register_buffer (src, regnum).
7497 (regcache_cpy): Update.
7498
7499 2017-04-19 Pedro Alves <palves@redhat.com>
7500
7501 * gdbthread.h (thread): Add missing closing parenthesis in
7502 comment.
7503
7504 2017-04-19 Pedro Alves <palves@redhat.com>
7505
7506 * common/refcounted-object.h: New file.
7507 * gdbthread.h: Include "common/refcounted-object.h".
7508 (thread_info): Inherit from refcounted_object and add comments.
7509 (thread_info::incref, thread_info::decref)
7510 (thread_info::m_refcount): Delete.
7511 (thread_info::deletable): Use the refcounted_object::refcount()
7512 method.
7513 * inferior.c (current_inferior_): Add comment.
7514 (set_current_inferior): Increment/decrement refcounts.
7515 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7516 not-deletable instead of comparing with the current inferior.
7517 (initialize_inferiors): Increment the initial inferior's refcount.
7518 * inferior.h (struct inferior): Forward declare.
7519 Include "common/refcounted-object.h".
7520 (current_inferior, set_current_inferior): Move declaration to
7521 before struct inferior's definition, and fix comment.
7522 (inferior): Inherit from refcounted_object. Add comments.
7523 * thread.c (switch_to_thread_no_regs): Reference the thread's
7524 inferior pointer directly instead of doing a ptid lookup.
7525 (switch_to_no_thread): New function.
7526 (switch_to_thread(thread_info *)): New function, factored out
7527 from ...
7528 (switch_to_thread(ptid_t)): ... this.
7529 (restore_current_thread): Delete.
7530 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7531 fields, and add 'inf' field.
7532 (do_restore_current_thread_cleanup): Check whether old->inf is
7533 alive instead of looking up an inferior by ptid. Use
7534 switch_to_thread and switch_to_no_thread.
7535 (restore_current_thread_cleanup_dtor): Use old->inf directly
7536 instead of lookup up an inferior by id. Decref the inferior.
7537 Don't restore 'removable'.
7538 (make_cleanup_restore_current_thread): Same the inferior pointer
7539 in old, instead of the inferior number. Incref the inferior.
7540 Don't save/clear 'removable'.
7541
7542 2017-04-19 Pedro Alves <palves@redhat.com>
7543
7544 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7545 unittests/scoped_restore-selftests.c.
7546 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7547 * common/scoped_restore.h (scoped_restore_base): Make "class".
7548 (scoped_restore_base::release): New public method.
7549 (scoped_restore_base::scoped_restore_base): New protected ctor.
7550 (scoped_restore_base::m_saved_var): New protected field.
7551 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7552 scoped_restore_base base class instead of m_saved_var directly.
7553 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7554 (scoped_restore_tmpl::scoped_restore_tmpl(const
7555 scoped_restore_tmpl<T>&)): Likewise.
7556 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7557 method.
7558 (scoped_restore_tmpl::saved_var): New method.
7559 (scoped_restore_tmpl::m_saved_var): Delete.
7560 * inferior.h (inferior::detaching): Now a bool.
7561 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7562 cleanup.
7563 * unittests/scoped_restore-selftests.c: New file.
7564
7565 2017-04-19 Pedro Alves <palves@redhat.com>
7566
7567 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7568 Re-sort in alphabetic order.
7569
7570 2017-04-18 Pedro Alves <palves@redhat.com>
7571
7572 * xml-support.c (obstack_xml_printf): Delete.
7573 * xml-support.h (obstack_xml_printf): Delete.
7574
7575 2017-04-18 Pedro Alves <palves@redhat.com>
7576
7577 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7578 vdebug, verror, body_text, start_element, end_element, name,
7579 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7580 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7581 is_xinclude>: Make private and add m_ prefix.
7582 (gdb_xml_parser::body_text): New method, based on ...
7583 (gdb_xml_body_text): ... this. Adjust.
7584 (gdb_xml_parser::vdebug): New method, based on ...
7585 (gdb_xml_debug): ... this. Adjust.
7586 (gdb_xml_parser::verror): New method, based on ...
7587 (gdb_xml_error): ... this. Adjust.
7588 (gdb_xml_parser::start_element): New method, based on ...
7589 (gdb_xml_start_element): ... this. Adjust.
7590 (gdb_xml_start_element_wrapper): Defer to
7591 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7592 (gdb_xml_parser::end_element): New method, based on ...
7593 (gdb_xml_end_element_wrapper): ... this. Adjust.
7594 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7595 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7596 (gdb_xml_parser::use_dtd): New method, based on ...
7597 (gdb_xml_use_dtd): ... this. Adjust.
7598 (gdb_xml_parser::parse): New method, based on ...
7599 (gdb_xml_parse): ... this. Adjust.
7600 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7601 (xinclude_start_include): Adjust to call the parser's name method.
7602 (xml_xinclude_default, xml_xinclude_start_doctype)
7603 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7604 method.
7605 (xml_process_xincludes): Adjust to call parser methods.
7606 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7607 declarations.
7608
7609 2017-04-18 Pedro Alves <palves@redhat.com>
7610
7611 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7612 gdb::optional<std::string>.
7613 * xml-support.c: Include <string>.
7614 (scope_level::scope_level(scope_level &&))
7615 (scope_level::~scope_level): Delete.
7616 (scope_level::body): Now a std::string.
7617 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7618 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7619 parameter.
7620 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7621 (xinclude_parsing_data::output): Now a std::string reference.
7622 (xinclude_start_include): Adjust.
7623 (xml_xinclude_default): Adjust.
7624 (xml_process_xincludes): Add 'output' parameter, and return bool.
7625 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7626 and return bool.
7627 * xml-tdesc.c: Include <unordered_map> and <string>.
7628 (tdesc_xml_cache): Delete.
7629 (tdesc_xml_cache_s): Delete.
7630 (xml_cache): Now an std::unordered_map.
7631 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7632 (target_fetch_description_xml): Change return type to
7633 gdb::optional<std::string>, and adjust.
7634 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7635 (target_fetch_description_xml): Change return type to
7636 gdb::optional<std::string>.
7637
7638 2017-04-18 Pedro Alves <palves@redhat.com>
7639
7640 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7641 unittests/optional-selftests.c.
7642 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7643 * unittests/optional-selftests.c: New file.
7644 * unittests/optional/assignment/1.cc: New file.
7645 * unittests/optional/assignment/2.cc: New file.
7646 * unittests/optional/assignment/3.cc: New file.
7647 * unittests/optional/assignment/4.cc: New file.
7648 * unittests/optional/assignment/5.cc: New file.
7649 * unittests/optional/assignment/6.cc: New file.
7650 * unittests/optional/assignment/7.cc: New file.
7651 * unittests/optional/cons/copy.cc: New file.
7652 * unittests/optional/cons/default.cc: New file.
7653 * unittests/optional/cons/move.cc: New file.
7654 * unittests/optional/cons/value.cc: New file.
7655 * unittests/optional/in_place.cc: New file.
7656 * unittests/optional/observers/1.cc: New file.
7657 * unittests/optional/observers/2.cc: New file.
7658
7659 2017-04-18 Pedro Alves <palves@redhat.com>
7660
7661 * common/gdb_optional.h: Include common/traits.h.
7662 (in_place_t): New type.
7663 (in_place): New constexpr variable.
7664 (optional::optional): Remove member initialization of
7665 m_instantiated.
7666 (optional::optional(in_place_t...)): New constructor.
7667 (optional::~optional): Use reset.
7668 (optional::optional(const optional&)): New.
7669 (optional::optional(const optional&&)): New.
7670 (optional::optional(T &)): New.
7671 (optional::optional(T &&)): New.
7672 (operator::operator=(const optional &)): New.
7673 (operator::operator=(optional &&)): New.
7674 (operator::operator= (const T &))
7675 (operator::operator= (T &&))
7676 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7677 (operator::reset): New.
7678 (operator::m_instantiated):: Add in-class initializer.
7679 * common/traits.h: Include <type_traits>.
7680 (struct And): New types.
7681
7682 2017-04-18 Pedro Alves <palves@redhat.com>
7683
7684 * xml-support.c: Include <vector>.
7685 (scope_level::scope_level(const gdb_xml_element *))
7686 (scope_level::scope_level(scope_level&&)): New.
7687 (scope_level::~scope_level): New.
7688 (scope_level_s): Delete.
7689 (gdb_xml_parser::scopes): Now a std::vector.
7690 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
7691 Use std::vector.
7692 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
7693 scope cleanup code.
7694 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
7695 of the scopes member. Use std::vector::emplace_back.
7696
7697 2017-04-18 Pedro Alves <palves@redhat.com>
7698
7699 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
7700 a bool.
7701 (gdb_xml_end_element): Change type of first parameter.
7702 (gdb_xml_cleanup): Rename to ...
7703 (gdb_xml_parser::~gdb_xml_parser): ... this.
7704 (gdb_xml_create_parser_and_cleanup): Delete with ...
7705 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
7706 to this new ctor.
7707 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
7708 using gdb_xml_create_parser_and_cleanup.
7709 (xinclude_parsing_data): Add ctor/dtor.
7710 (xml_xinclude_cleanup): Delete.
7711 (xml_process_xincludes): Create a local xinclude_parsing_data
7712 instead of heap-allocating one. Create a local gdb_xml_parser
7713 instead of heap-allocating one with
7714 gdb_xml_create_parser_and_cleanup.
7715
7716 2017-04-18 John Baldwin <jhb@FreeBSD.org>
7717
7718 PR threads/20743
7719 * fbsd-nat.c (resume_one_thread_cb): Remove.
7720 (resume_all_threads_cb): Remove.
7721 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
7722 iterate_over_threads.
7723
7724 2017-04-17 Joel Brobecker <brobecker@adacore.com>
7725
7726 * NEWS: Create a new section for the next release branch.
7727 Rename the section of the current branch, now that it has
7728 been cut.
7729
7730 2017-04-17 Joel Brobecker <brobecker@adacore.com>
7731
7732 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
7733 * version.in: Bump version to 8.0.50.DATE-git.
7734
7735 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
7736
7737 PR gdb/21385
7738 * windows-nat.c (windows_create_inferior): Declare 'allargs'
7739 independently of the host, and fix build breakage on Cygwin.
7740
7741 2017-04-13 Pedro Alves <palves@redhat.com>
7742
7743 * inferior.c (free_inferior): Convert to ...
7744 (inferior::~inferior): ... this dtor.
7745 (inferior::inferior): New ctor, factored out from ...
7746 (add_inferior_silent): ... here. Allocate the inferior with a new
7747 expression.
7748 (delete_inferior): Call delete instead of free_inferior.
7749 * inferior.h (gdb_environ, continuation): Forward declare.
7750 (inferior): Now a class. Add in-class initialization to all
7751 members. Make boolean fields bool, except 'detaching'.
7752 (inferior::inferior): New explicit ctor.
7753 (inferior::~inferior): New.
7754
7755 2017-04-13 Pedro Alves <palves@redhat.com>
7756
7757 * inferior.c (init_inferior_list): Delete.
7758 * inferior.h (init_inferior_list): Delete.
7759
7760 2017-04-13 Pedro Alves <palves@redhat.com>
7761
7762 PR threads/13217
7763 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
7764 (top level): Call it twice, with different thread sets.
7765
7766 2017-04-13 Pedro Alves <palves@redhat.com>
7767
7768 * thread.c: Include <algorithm>.
7769 (thread_array_cleanup): Delete.
7770 (scoped_inc_dec_ref): New class.
7771 (live_threads_count): New function.
7772 (set_thread_refcount): Delete.
7773 (tp_array_compar_ascending): Now a bool.
7774 (tp_array_compar): Convert to a std::sort comparison function.
7775 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
7776 and live_threads_count.
7777
7778 2017-04-13 Pedro Alves <palves@redhat.com>
7779
7780 * infrun.c (follow_fork_inferior): Also switch the current
7781 inferior.
7782
7783 2017-04-13 Pedro Alves <palves@redhat.com>
7784
7785 * breakpoint.c (watch_command_1): Save watchpoint-frame info
7786 before calling create_internal_breakpoint.
7787
7788 2017-04-13 Pedro Alves <palves@redhat.com>
7789
7790 * fork-child.c (execv_argv): New class.
7791 (breakup_args): Refactored as ...
7792 (execv_argv::init_for_no_shell): .. this method of execv_argv.
7793 Copy arguments to storage and replace separators with NULL
7794 terminators in place.
7795 (escape_bang_in_quoted_argument): Adjust to return bool.
7796 (execv_argv::execv_argv): New ctor.
7797 (execv_argv::init_for_shell): New method, factored out from
7798 fork_inferior. Don't strdup strings into the vector.
7799 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
7800 Remove free_vector_argv call.
7801
7802 2017-04-13 Yao Qi <yao.qi@linaro.org>
7803
7804 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
7805 tdep->rx_psw_type.
7806
7807 2017-04-13 Yao Qi <yao.qi@linaro.org>
7808
7809 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
7810 * rx-tdep.c (rx_gdbarch_init): Likewise.
7811
7812 2017-04-13 Pedro Alves <palves@redhat.com>
7813
7814 * breakpoint.h (struct breakpoint): Reindent.
7815
7816 2017-04-13 Pedro Alves <palves@redhat.com>
7817
7818 * breakpoint.c (bp_location): Rename to ...
7819 (bp_locations): ... this. All references updated.
7820 (bp_location_count): Rename to ...
7821 (bp_locations_count): ... this. All references updated.
7822 (bp_location_placed_address_before_address_max): Rename to ...
7823 (bp_locations_placed_address_before_address_max): ... this. All
7824 references updated.
7825 (bp_location_shadow_len_after_address_max): Rename to ...
7826 (bp_locations_shadow_len_after_address_max): ... this. All
7827 references updated.
7828 (bp_location_compare_addrs): Rename to ...
7829 (bp_locations_compare_addrs): ... this. All references updated.
7830 (bp_location_compare):Rename to ...
7831 (bp_locations_compare): ... this. All references updated.
7832 (bp_location_target_extensions_update): Rename to ...
7833 (bp_locations_target_extensions_update): ... this. All references
7834 updated.
7835
7836 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7837
7838 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
7839 * common/common.m4: Check headers 'termios.h', 'termio.h' and
7840 'sgtty.h'.
7841 * common/gdb_termios.h: New file, with parts of "terminal.h".
7842 * inflow.c: Include "gdb_termios.h".
7843 * ser-unix.c: Include "gdb_termios.h".
7844 * terminal.h: Move terminal-related defines to
7845 "common/gdb_termios.h".
7846
7847 2017-04-12 Tom Tromey <tom@tromey.com>
7848
7849 * probe.c (parse_probes): Update.
7850 * location.h (delete_event_location): Don't declare.
7851 (event_location_deleter::operator()): Update.
7852 * location.c (event_location_deleter::operator()): Rename from
7853 delete_event_location.
7854 * linespec.h (linespec_result) <location>: Change type to
7855 event_location_up.
7856 * linespec.c (canonicalize_linespec, event_location_to_sals)
7857 (decode_objc): Update.
7858 (linespec_result): Don't call delete_event_location.
7859 * breakpoint.c (create_breakpoints_sal)
7860 (bkpt_probe_create_sals_from_location)
7861 (strace_marker_create_sals_from_location): Update.
7862
7863 2017-04-12 Tom Tromey <tom@tromey.com>
7864
7865 * linespec.h (struct linespec_result): Add constructor and
7866 destructor.
7867 (init_linespec_result, destroy_linespec_result)
7868 (make_cleanup_destroy_linespec_result): Don't declare.
7869 * linespec.c (init_linespec_result): Remove.
7870 (linespec_result::~linespec_result): Rename from
7871 destroy_linespec_result. Update.
7872 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
7873 Remove.
7874 * breakpoint.c (create_breakpoint, break_range_command)
7875 (decode_location_default): Update.
7876 * ax-gdb.c (agent_command_1): Update.
7877
7878 2017-04-12 Tom Tromey <tom@tromey.com>
7879
7880 * remote.c (remote_download_tracepoint): Update.
7881 * python/py-breakpoint.c (bppy_get_location): Update.
7882 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
7883 (gdbscm_breakpoint_location): Update.
7884 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
7885 * breakpoint.h (struct breakpoint) <location, location_range_end>:
7886 Change type to event_location_up.
7887 * breakpoint.c (create_overlay_event_breakpoint)
7888 (create_longjmp_master_breakpoint)
7889 (create_std_terminate_master_breakpoint)
7890 (create_exception_master_breakpoint)
7891 (breakpoint_event_location_empty_p, print_breakpoint_location)
7892 (print_one_breakpoint_location, create_thread_event_breakpoint)
7893 (init_breakpoint_sal, create_breakpoint)
7894 (print_recreate_ranged_breakpoint, break_range_command)
7895 (init_ada_exception_breakpoint, say_where): Update.
7896 (base_breakpoint_dtor): Don't call delete_event_location.
7897 (bkpt_print_recreate, tracepoint_print_recreate)
7898 (dprintf_print_recreate, update_static_tracepoint)
7899 (breakpoint_re_set_default): Update.
7900
7901 2017-04-12 Tom Tromey <tom@tromey.com>
7902
7903 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
7904 type of "to_do". Update.
7905 (compute_stack_depth): Use std::vector.
7906
7907 2017-04-12 Tom Tromey <tom@tromey.com>
7908
7909 * printcmd.c (find_instruction_backward): Use std::vector.
7910
7911 2017-04-12 Tom Tromey <tom@tromey.com>
7912
7913 * symfile.c (objfilep): Remove typedef.
7914 (reread_symbols): Use a std::vector.
7915
7916 2017-04-12 Tom Tromey <tom@tromey.com>
7917
7918 * mi/mi-main.c (exec_direction_forward): Remove.
7919 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
7920 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7921 scoped_restore.
7922 * guile/guile.c (guile_repl_command, guile_command)
7923 (gdbscm_execute_gdb_command): Use scoped_restore.
7924 * go-exp.y (go_parse): Use scoped_restore.
7925 * d-exp.y (d_parse): Use scoped_restore.
7926 * cli/cli-decode.c (cmd_func): Use scoped_restore.
7927 * c-exp.y (c_parse): Use scoped_restore.
7928
7929 2017-04-12 Tom Tromey <tom@tromey.com>
7930
7931 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
7932 (mi_parse): Update return type.
7933 (mi_parse_free): Remove.
7934 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
7935 (mi_parse::~mi_parse): Rename from mi_parse_free.
7936 (mi_parse_cleanup): Remove.
7937 (mi_parse): Return a unique_ptr. Use new.
7938 * mi/mi-main.c (mi_execute_command): Update.
7939
7940 2017-04-12 Tom Tromey <tom@tromey.com>
7941
7942 * location.c (explicit_location_lex_one): Return a
7943 unique_xmalloc_ptr.
7944 (string_to_explicit_location): Update. Remove cleanups.
7945
7946 2017-04-12 Tom Tromey <tom@tromey.com>
7947
7948 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
7949 (compare_value_and_voffset): Change type. Update.
7950 (compute_vtable_size): Change type of "offset_vec".
7951 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
7952 (gnuv3_get_typeid): Remove extraneous declaration.
7953
7954 2017-04-12 Tom Tromey <tom@tromey.com>
7955
7956 * charset.h (wchar_iterator): Fix comment.
7957
7958 2017-04-12 Tom Tromey <tom@tromey.com>
7959
7960 * charset.c (iconv_wrapper): New class.
7961 (cleanup_iconv): Remove.
7962 (convert_between_encodings): Use it.
7963
7964 2017-04-12 Tom Tromey <tom@tromey.com>
7965
7966 * symfile.h (increment_reading_symtab): Update type.
7967 * symfile.c (decrement_reading_symtab): Remove.
7968 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
7969 * psymtab.c (psymtab_to_symtab): Update.
7970 * dwarf2read.c (dw2_instantiate_symtab): Update.
7971
7972 2017-04-12 Tom Tromey <tom@tromey.com>
7973
7974 * jit.c (struct jit_reader): Declare separately. Add constructor
7975 and destructor. Change type of "handle".
7976 (loaded_jit_reader): Define separately.
7977 (jit_reader_load): Update. New "new".
7978 (jit_reader_unload_command): Use "delete".
7979 * gdb-dlfcn.h (struct dlclose_deleter): New.
7980 (gdb_dlhandle_up): New typedef.
7981 (gdb_dlopen, gdb_dlsym): Update types.
7982 (gdb_dlclose): Remove.
7983 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
7984 (gdb_dlsym): Change type of "handle".
7985 (make_cleanup_dlclose): Remove.
7986 (dlclose_deleter::operator()): Rename from gdb_dlclose.
7987 * compile/compile-c-support.c (load_libcc): Update.
7988
7989 2017-04-12 Tom Tromey <tom@tromey.com>
7990
7991 * symtab.h (find_pcs_for_symtab_line): Change return type.
7992 * symtab.c (find_pcs_for_symtab_line): Change return type.
7993 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
7994 type of "vec". Update.
7995 (ltpy_get_pcs_for_line): Update.
7996 * linespec.c (decode_digits_ordinary): Update.
7997
7998 2017-04-12 Tom Tromey <tom@tromey.com>
7999
8000 * tracepoint.c (actions_command): Update.
8001 * python/python.c (python_command, python_interactive_command):
8002 Update.
8003 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8004 * guile/guile.c (guile_command): Update.
8005 * defs.h (read_command_lines, read_command_lines_1): Return
8006 command_line_up.
8007 (command_lines_deleter): New struct.
8008 (command_line_up): New typedef.
8009 * compile/compile.c (compile_code_command)
8010 (compile_print_command): Update.
8011 * cli/cli-script.h (get_command_line, copy_command_lines): Return
8012 command_line_up.
8013 (make_cleanup_free_command_lines): Remove.
8014 * cli/cli-script.c (get_command_line, read_command_lines_1)
8015 (copy_command_lines): Return command_line_up.
8016 (while_command, if_command, read_command_lines, define_command)
8017 (document_command): Update.
8018 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
8019 Remove.
8020 * breakpoint.h (breakpoint_set_commands): Change type of
8021 "commands".
8022 * breakpoint.c (breakpoint_set_commands): Change type of
8023 "commands". Update.
8024 (do_map_commands_command, update_dprintf_command_list)
8025 (create_tracepoint_from_upload): Update.
8026
8027 2017-04-12 Tom Tromey <tom@tromey.com>
8028
8029 * tracepoint.c (scope_info): Update.
8030 * spu-tdep.c (spu_catch_start): Update.
8031 * python/python.c (gdbpy_decode_line): Update.
8032 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
8033 * python/py-breakpoint.c (bppy_init): Update.
8034 * probe.c (parse_probes): Update.
8035 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
8036 * location.h (event_location_deleter): New struct.
8037 (event_location_up): New typedef.
8038 (new_linespec_location, new_address_location, new_probe_location)
8039 (new_explicit_location, copy_event_location)
8040 (string_to_event_location, string_to_event_location_basic)
8041 (string_to_explicit_location): Update return type.
8042 (make_cleanup_delete_event_location): Remove.
8043 * location.c (new_linespec_location, new_address_location)
8044 (new_probe_location, new_explicit_location, copy_event_location):
8045 Return event_location_up.
8046 (delete_event_location_cleanup)
8047 (make_cleanup_delete_event_location): Remove.
8048 (string_to_explicit_location, string_to_event_location_basic)
8049 (string_to_event_location): Return event_location_up.
8050 * linespec.c (canonicalize_linespec, event_location_to_sals)
8051 (decode_line_with_current_source)
8052 (decode_line_with_last_displayed, decode_objc): Update.
8053 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
8054 * completer.c (location_completer): Update.
8055 * cli/cli-cmds.c (edit_command, list_command): Update.
8056 * breakpoint.c (create_overlay_event_breakpoint)
8057 (create_longjmp_master_breakpoint)
8058 (create_std_terminate_master_breakpoint)
8059 (create_exception_master_breakpoint)
8060 (create_thread_event_breakpoint): Update.
8061 (init_breakpoint_sal): Update. Remove some dead code.
8062 (create_breakpoint_sal): Change type of "location". Update.
8063 (create_breakpoints_sal, create_breakpoint, break_command_1)
8064 (dprintf_command, break_range_command, until_break_command)
8065 (init_ada_exception_breakpoint)
8066 (strace_marker_create_sals_from_location)
8067 (update_static_tracepoint, trace_command, ftrace_command)
8068 (strace_command, create_tracepoint_from_upload): Update.
8069 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8070 * ax-gdb.c (agent_command_1): Update.
8071
8072 2017-04-12 Pedro Alves <palves@redhat.com>
8073
8074 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
8075 * configure.tgt: Handle i[34567]86-*-go32* and
8076 i[34567]86-*-msdosdjgpp*.
8077 * i386-tdep.c (i386_svr4_reg_to_regnum):
8078 Make extern.
8079 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
8080 i386-go32-tdep.c.
8081 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
8082 * i386-go32-tdep.c: New file.
8083 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
8084 declarations.
8085
8086 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
8087
8088 * aix-thread.c (pd_status2str): Change return type to const char *.
8089
8090 2017-04-12 Pedro Alves <palves@redhat.com>
8091
8092 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
8093 calls to set_gdbarch_gnu_triplet_regexp.
8094
8095 2017-04-12 Pedro Alves <palves@redhat.com>
8096
8097 PR gdb/21323
8098 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
8099 New enum value.
8100 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
8101 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
8102 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
8103 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
8104 * gdbarch.h, gdbarch.c: Regenerate.
8105 * aarch64-tdep.c (aarch64_gdbarch_init): Override
8106 gdbarch_wchar_bit and gdbarch_wchar_signed.
8107 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
8108 * arm-tdep.c (arm_gdbarch_init): Likewise.
8109 * avr-tdep.c (avr_gdbarch_init): Likewise.
8110 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
8111 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
8112 * i386-tdep.c (i386_go32_init_abi): Likewise.
8113 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8114 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8115 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8116 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8117 * sh-tdep.c (sh_gdbarch_init): Likewise.
8118 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8119 * sparc64-tdep.c (sparc64_init_abi): Likewise.
8120 * windows-tdep.c (windows_init_abi): Likewise.
8121 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8122
8123 2017-04-12 Pedro Alves <palves@redhat.com>
8124
8125 PR c++/21323
8126 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
8127 cplus_primitive_type_char32_t>: New enum values.
8128 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
8129 and cplus_primitive_type_char32_t.
8130 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
8131 32, use the archtecture's built-in type for char16_t and char32_t,
8132 respectively. Otherwise, fallback to init_integer_type as before,
8133 but make the type unsigned, and issue a complaint.
8134 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
8135
8136 2017-04-12 Alan Hayward <alan.hayward@arm.com>
8137
8138 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
8139 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
8140
8141 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8142
8143 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
8144 'const char *'.
8145
8146 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8147
8148 * common/common-utils.c (free_vector_argv): New function.
8149 * common/common-utils.h: Include <vector>.
8150 (free_vector_argv): New prototype.
8151 * darwin-nat.c (darwin_create_inferior): Rewrite function
8152 prototype in order to constify "exec_file" and accept a
8153 "std::string" for "allargs".
8154 * fork-child.c: Include <vector>.
8155 (breakup_args): Rewrite function, using C++.
8156 (fork_inferior): Rewrite function header, constify "exec_file_arg"
8157 and accept "std::string" for "allargs". Update the code to
8158 calculate "argv" based on "allargs". Update calls to "exec_fun"
8159 and "execvp".
8160 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
8161 order to constify "exec_file" and accept a "std::string" for
8162 "allargs".
8163 * go32-nat.c (go32_create_inferior): Likewise.
8164 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
8165 * infcmd.c (run_command_1): Constify "exec_file". Use
8166 "std::string" for inferior arguments.
8167 * inferior.h (fork_inferior): Update prototype.
8168 * linux-nat.c (linux_nat_create_inferior): Rewrite function
8169 prototype in order to constify "exec_file" and accept a
8170 "std::string" for "allargs".
8171 * nto-procfs.c (procfs_create_inferior): Likewise.
8172 * procfs.c (procfs_create_inferior): Likewise.
8173 * remote-sim.c (gdbsim_create_inferior): Likewise.
8174 * remote.c (extended_remote_run): Update code to accept
8175 "std::string" as argument.
8176 (extended_remote_create_inferior): Rewrite function prototype in
8177 order to constify "exec_file" and accept a "std::string" for
8178 "allargs".
8179 * rs6000-nat.c (super_create_inferior): Likewise.
8180 (rs6000_create_inferior): Likewise.
8181 * target.h (struct target_ops) <to_create_inferior>: Likewise.
8182 * windows-nat.c (windows_create_inferior): Likewise.
8183
8184 2017-04-11 Pedro Alves <palves@redhat.com>
8185
8186 * thread.c: Fix whitespace throughout.
8187
8188 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
8189
8190 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
8191
8192 2017-04-11 Alan Hayward <alan.hayward@arm.com>
8193
8194 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
8195
8196 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
8197
8198 PR gdb/21364
8199 * osdata.c (info_osdata): Check if 'type' is an empty string
8200 instead of NULL.
8201
8202 2017-04-10 Pedro Alves <palves@redhat.com>
8203
8204 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
8205 (ptid_to_global_thread_id, in_thread_list)
8206 (do_captured_list_thread_ids, set_resumed, set_running)
8207 (set_executing, set_stop_requested, finish_thread_state)
8208 (validate_registers_access, can_access_registers_ptid)
8209 (print_thread_info_1, switch_to_thread)
8210 (do_restore_current_thread_cleanup)
8211 (make_cleanup_restore_current_thread, thread_command)
8212 (thread_name_command): Use operator== instead of ptid_equal.
8213
8214 2017-04-10 Pedro Alves <palves@redhat.com>
8215
8216 * thread.c (struct current_thread_cleanup) <next>: Delete field.
8217 (current_thread_cleanup_chain): Delete.
8218 (restore_current_thread_cleanup_dtor)
8219 (make_cleanup_restore_current_thread): Remove references to
8220 current_thread_cleanup_chain.
8221
8222 2017-04-10 Alan Hayward <alan.hayward@arm.com>
8223
8224 * msp430-tdep.c (msp430_pseudo_register_read): Never return
8225 REG_UNKNOWN.
8226
8227 2017-04-10 Yao Qi <yao.qi@linaro.org>
8228
8229 PR gdb/19942
8230 * gdbthread.h (thread_info::deletable): New method.
8231 (thread_info::incref): New method.
8232 (thread_info::decref): New method.
8233 (thread_info::refcount): Move it to private.
8234 * infrun.c (save_stop_context): Call inc_refcount.
8235 (release_stop_context_cleanup): Likewise.
8236 * thread.c (set_thread_exited): New function.
8237 (init_thread_list): Delete "tp" only it is deletable, otherwise
8238 call set_thread_exited.
8239 (delete_thread_1): Call set_thread_exited.
8240 (current_thread_cleanup) <inferior_pid>: Remove.
8241 <thread>: New field.
8242 (restore_current_thread_ptid_changed): Removed.
8243 (do_restore_current_thread_cleanup): Adjust.
8244 (restore_current_thread_cleanup_dtor): Don't call
8245 find_thread_ptid.
8246 (set_thread_refcount): Use dec_refcount.
8247 (make_cleanup_restore_current_thread): Adjust.
8248 (thread_apply_all_command): Call inc_refcount.
8249 (_initialize_thread): Don't call
8250 observer_attach_thread_ptid_changed.
8251
8252 2017-04-10 Yao Qi <yao.qi@linaro.org>
8253
8254 * thread.c (delete_thread_1): Hoist code on marking thread as
8255 exited.
8256
8257 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8258
8259 * windows-nat.c (windows_detach): Initialize ptid with
8260 minus_one_ptid.
8261
8262 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
8263
8264 * unittests/ptid-selftests.c: Fix erroneous assert messages.
8265
8266 2017-04-07 Alan Hayward <alan.hayward@arm.com>
8267
8268 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
8269 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
8270 (bfin_pseudo_register_write): Likewise
8271
8272 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
8273
8274 * common/ptid.h (struct ptid): Change to...
8275 (class ptid_t): ... this.
8276 <ptid_t>: New constructors.
8277 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
8278 matches>: New methods.
8279 <make_null, make_minus_one>: New static methods.
8280 <pid>: Rename to...
8281 <m_pid>: ...this.
8282 <lwp>: Rename to...
8283 <m_lwp>: ...this.
8284 <tid>: Rename to...
8285 <m_tid>: ...this.
8286 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
8287 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
8288 as references, move comment to class ptid_t.
8289 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
8290 ptid_t static methods.
8291 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
8292 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
8293 Take ptid arguments as references, implement using ptid_t methods.
8294 * unittests/ptid-selftests.c: New file.
8295 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8296 unittests/ptid-selftests.c.
8297 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
8298
8299 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
8300
8301 * python/python.c (python_run_simple_file): Cast mode literal to
8302 non-const char pointer as expected by PyFile_FromString.
8303
8304 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
8305
8306 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
8307 minus_one_ptid and null_ptid.
8308
8309 2017-04-05 Pedro Alves <palves@redhat.com>
8310
8311 * warning.m4 (build_warnings): Remove -Wno-write-strings.
8312 * configure: Regenerate.
8313
8314 2017-04-05 Pedro Alves <palves@redhat.com>
8315
8316 * ada-exp.y (yyerror): Constify.
8317 * ada-lang.c (bound_name, get_selections)
8318 (ada_variant_discrim_type)
8319 (ada_variant_discrim_name, ada_value_struct_elt)
8320 (ada_lookup_struct_elt_type, is_unchecked_variant)
8321 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
8322 (catch_ada_exception_command_split)
8323 (catch_ada_assert_command_split, catch_assert_command)
8324 (ada_op_name): Constify.
8325 * ada-lang.h (ada_yyerror, get_selections)
8326 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
8327 * arc-tdep.c (arc_print_frame_cache): Constify.
8328 * arm-tdep.c (arm_skip_stub): Constify.
8329 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
8330 (gen_aggregate_elt_ref): Constify.
8331 * bcache.c (print_bcache_statistics): Constify.
8332 * bcache.h (print_bcache_statistics): Constify.
8333 * break-catch-throw.c (catch_exception_command_1):
8334 * breakpoint.c (struct ep_type_description::description):
8335 Constify.
8336 (add_solib_catchpoint): Constify.
8337 (catch_fork_command_1): Add cast.
8338 (add_catch_command): Constify.
8339 * breakpoint.h (add_catch_command, add_solib_catchpoint):
8340 Constify.
8341 * bsd-uthread.c (bsd_uthread_state): Constify.
8342 * buildsym.c (patch_subfile_names): Constify.
8343 * buildsym.h (next_symbol_text_func, patch_subfile_names):
8344 Constify.
8345 * c-exp.y (yyerror): Constify.
8346 (token::oper): Constify.
8347 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
8348 * c-varobj.c (cplus_describe_child): Constify.
8349 * charset.c (find_charset_names): Add cast.
8350 (find_charset_names): Constify array and add const_cast.
8351 * cli/cli-cmds.c (complete_command, cd_command): Constify.
8352 (edit_command): Constify.
8353 * cli/cli-decode.c (lookup_cmd): Constify.
8354 * cli/cli-dump.c (dump_memory_command, dump_value_command):
8355 Constify.
8356 (struct dump_context): Constify.
8357 (add_dump_command, restore_command): Constify.
8358 * cli/cli-script.c (get_command_line): Constify.
8359 * cli/cli-script.h (get_command_line): Constify.
8360 * cli/cli-utils.c (check_for_argument): Constify.
8361 * cli/cli-utils.h (check_for_argument): Constify.
8362 * coff-pe-read.c (struct read_pe_section_data): Constify.
8363 * command.h (lookup_cmd): Constify.
8364 * common/print-utils.c (decimal2str): Constify.
8365 * completer.c (gdb_print_filename): Constify.
8366 * corefile.c (set_gnutarget): Constify.
8367 * cp-name-parser.y (yyerror): Constify.
8368 * cp-valprint.c (cp_print_class_member): Constify.
8369 * cris-tdep.c (cris_register_name, crisv32_register_name):
8370 Constify.
8371 * d-exp.y (yyerror): Constify.
8372 (struct token::oper): Constify.
8373 * d-lang.h (d_yyerror): Constify.
8374 * dbxread.c (struct header_file_location::name): Constify.
8375 (add_old_header_file, add_new_header_file, last_function_name)
8376 (dbx_next_symbol_text, add_bincl_to_list)
8377 (find_corresponding_bincl_psymtab, set_namestring)
8378 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
8379 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
8380 * defs.h (command_line_input, print_address_symbolic)
8381 (deprecated_readline_begin_hook): Constify.
8382 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
8383 Constify.
8384 * event-top.c (handle_line_of_input): Constify and add cast.
8385 * exceptions.c (catch_errors): Constify.
8386 * exceptions.h (catch_errors): Constify.
8387 * expprint.c (print_subexp_standard, op_string, op_name)
8388 (op_name_standard, dump_raw_expression, dump_raw_expression):
8389 * expression.h (op_name, op_string, dump_raw_expression):
8390 Constify.
8391 * f-exp.y (yyerror): Constify.
8392 (struct token::oper): Constify.
8393 (struct f77_boolean_val::name): Constify.
8394 * f-lang.c (f_word_break_characters): Constify.
8395 * f-lang.h (f_yyerror): Constify.
8396 * fork-child.c (fork_inferior): Add cast.
8397 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8398 (new_variant): Constify.
8399 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8400 * gdbarch.c: Regenerate.
8401 * gdbcore.h (set_gnutarget): Constify.
8402 * go-exp.y (yyerror): Constify.
8403 (token::oper): Constify.
8404 * go-lang.h (go_yyerror): Constify.
8405 * go32-nat.c (go32_sysinfo): Constify.
8406 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8407 * guile/scm-cmd.c (cmdscm_function): Constify.
8408 * guile/scm-param.c (pascm_param_value): Constify.
8409 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8410 (h8300sx_register_name): Constify.
8411 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8412 Constify.
8413 * ia64-tdep.c (ia64_register_names): Constify.
8414 * infcmd.c (construct_inferior_arguments): Constify.
8415 (path_command, attach_post_wait): Constify.
8416 * language.c (show_range_command, show_case_command)
8417 (unk_lang_error): Constify.
8418 * language.h (language_defn::la_error)
8419 (language_defn::la_name_of_this): Constify.
8420 * linespec.c (decode_line_2): Constify.
8421 * linux-thread-db.c (thread_db_err_str): Constify.
8422 * lm32-tdep.c (lm32_register_name): Constify.
8423 * m2-exp.y (yyerror): Constify.
8424 * m2-lang.h (m2_yyerror): Constify.
8425 * m32r-tdep.c (m32r_register_names): Constify and make static.
8426 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8427 * m88k-tdep.c (m88k_register_name): Constify.
8428 * macroexp.c (appendmem): Constify.
8429 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8430 (upgrade_type, parse_external, parse_partial_symbols)
8431 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8432 (new_symbol): Constify.
8433 * memattr.c (mem_info_command): Constify.
8434 * mep-tdep.c (register_name_from_keyword): Constify.
8435 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8436 Constify.
8437 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8438 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8439 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8440 cast.
8441 (mi_execute_async_cli_command): Constify.
8442 * mips-tdep.c (mips_register_name): Constify.
8443 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8444 (am33_register_name, am33_2_register_name)
8445 * moxie-tdep.c (moxie_register_names): Constify.
8446 * nat/linux-osdata.c (osdata_type): Constify fields.
8447 * nto-tdep.c (nto_parse_redirection): Constify.
8448 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8449 (lookup_child_selector): Constify.
8450 (objc_methcall::name): Constify.
8451 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8452 (lookup_struct_typedef): Constify.
8453 * objfiles.c (pc_in_section): Constify.
8454 * objfiles.h (pc_in_section): Constify.
8455 * p-exp.y (struct token::oper): Constify.
8456 (yyerror): Constify.
8457 * p-lang.h (pascal_yyerror): Constify.
8458 * parser-defs.h (op_name_standard): Constify.
8459 (op_print::string): Constify.
8460 (exp_descriptor::op_name): Constify.
8461 * printcmd.c (print_address_symbolic): Constify.
8462 * psymtab.c (print_partial_symbols): Constify.
8463 * python/py-breakpoint.c (stop_func): Constify.
8464 (bppy_get_expression): Constify.
8465 * python/py-cmd.c (cmdpy_completer::name): Constify.
8466 (cmdpy_function): Constify.
8467 * python/py-event.c (evpy_add_attribute)
8468 (gdbpy_initialize_event_generic): Constify.
8469 * python/py-event.h (evpy_add_attribute)
8470 (gdbpy_initialize_event_generic): Constify.
8471 * python/py-evts.c (add_new_registry): Constify.
8472 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8473 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8474 * python/py-inferior.c (get_buffer): Add cast.
8475 * python/py-param.c (parm_constant::name): Constify.
8476 * python/py-unwind.c (fprint_frame_id): Constify.
8477 * python/python.c (gdbpy_parameter_value): Constify.
8478 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8479 * remote.c (memory_packet_config::name): Constify.
8480 (show_packet_config_cmd, remote_write_bytes)
8481 (remote_buffer_add_string):
8482 * reverse.c (exec_reverse_once): Constify.
8483 * rs6000-tdep.c (variant::name, variant::description): Constify.
8484 * rust-exp.y (rustyyerror): Constify.
8485 * rust-lang.c (rust_op_name): Constify.
8486 * rust-lang.h (rustyyerror): Constify.
8487 * serial.h (serial_ops::name): Constify.
8488 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8489 (sh_sh3e_register_name, sh_sh2e_register_name)
8490 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8491 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8492 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8493 (sh_sh4al_dsp_register_name): Constify.
8494 * sh64-tdep.c (sh64_register_name): Constify.
8495 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8496 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8497 * stabsread.c (patch_block_stabs, read_type_number)
8498 (ref_map::stabs, ref_add, process_reference)
8499 (symbol_reference_defined, define_symbol, define_symbol)
8500 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8501 (read_one_struct_field, read_struct_fields, read_baseclasses)
8502 (read_tilde_fields, read_struct_type, read_array_type)
8503 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8504 (read_huge_number, read_range_type, read_args, common_block_start)
8505 (find_name_end): Constify.
8506 * stabsread.h (common_block_start, define_symbol)
8507 (process_one_symbol, symbol_reference_defined, ref_add):
8508 * symfile.c (get_section_index, add_symbol_file_command):
8509 * symfile.h (get_section_index): Constify.
8510 * target-descriptions.c (tdesc_type::name): Constify.
8511 (tdesc_free_type): Add cast.
8512 * target.c (find_default_run_target):
8513 (add_deprecated_target_alias, find_default_run_target)
8514 (target_announce_detach): Constify.
8515 (do_option): Constify.
8516 * target.h (add_deprecated_target_alias): Constify.
8517 * thread.c (print_thread_info_1): Constify.
8518 * top.c (deprecated_readline_begin_hook, command_line_input):
8519 Constify.
8520 (init_main): Add casts.
8521 * top.h (handle_line_of_input): Constify.
8522 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8523 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8524 (tfind_command): Rename to ...
8525 (tfind_command_1): ... this and constify.
8526 (tfind_command): New function.
8527 (tfind_end_command, tfind_start_command): Adjust.
8528 (encode_source_string): Constify.
8529 * tracepoint.h (encode_source_string): Constify.
8530 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8531 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8532 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8533 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8534 * tui/tui-win.c (parse_scrolling_args): Constify.
8535 * tui/tui-windata.c (tui_erase_data_content): Constify.
8536 * tui/tui-windata.h (tui_erase_data_content): Constify.
8537 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8538 * tui/tui.c (tui_enable): Add cast.
8539 * utils.c (defaulted_query): Constify.
8540 (init_page_info): Add cast.
8541 (puts_debug, subset_compare): Constify.
8542 * utils.h (subset_compare): Constify.
8543 * varobj.c (varobj_format_string): Constify.
8544 * varobj.h (varobj_format_string): Constify.
8545 * vax-tdep.c (vax_register_name): Constify.
8546 * windows-nat.c (windows_detach): Constify.
8547 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8548 * xml-support.c (gdb_xml_end_element): Constify.
8549 * xml-tdesc.c (tdesc_start_reg): Constify.
8550 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8551 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8552 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8553
8554 2017-04-05 Pedro Alves <palves@redhat.com>
8555
8556 * proc-api.c (struct trans): Constify.
8557 (procfs_note): Constify.
8558 * proc-events.c (struct trans, syscall_table):
8559 * proc-flags.c (struct trans): Constify.
8560 * proc-utils.h (procfs_note): Constify.
8561 * proc-why.c (struct trans): Constify.
8562 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8563 (procfs_detach): Constify.
8564 * sol-thread.c (struct string_map): Constify.
8565 (td_err_string, td_state_string): Constify.
8566
8567 2017-04-05 Pedro Alves <palves@redhat.com>
8568
8569 * proc-api.c (procfs_filename): Don't initialize
8570 procfs_filename.
8571 (prepare_to_trace): Assume procfs_filename is non-NULL.
8572 (_initialize_proc_api): Give procfs_filename a default value here.
8573
8574 2017-04-05 Pedro Alves <palves@redhat.com>
8575
8576 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8577 'cond_string' parameter.
8578 (extract_exception_regexp): Constify 'string' parameter.
8579 (catch_exception_command_1): Constify.
8580 * breakpoint.c (init_catchpoint)
8581 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8582 parameter.
8583 (ep_parse_optional_if_clause, catch_fork_command_1)
8584 (catch_exec_command_1): Constify.
8585 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8586 parameter.
8587 (ep_parse_optional_if_clause): Constify.
8588 * cli/cli-utils.c (remove_trailing_whitespace)
8589 (check_for_argument): Constify.
8590 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8591 non-const overload.
8592 (check_for_argument): Likewise.
8593
8594 2017-04-05 Pedro Alves <palves@redhat.com>
8595
8596 * event-top.c (command_line_handler): Add cast to execute_command
8597 call.
8598 * record-btrace.c (cmd_record_btrace_bts_start)
8599 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8600 (cmd_record_btrace_start): Add cast to execute_command call.
8601 * record-full.c (record_full_goto_insn):
8602 * record.c (record_start, record_stop): Add cast to
8603 execute_command_to_string calls.
8604 (cmd_record_start): Add cast to execute_command calls.
8605
8606 2017-04-05 Pedro Alves <palves@redhat.com>
8607
8608 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8609 static inline function.
8610 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8611 array and use gdb_PyArg_ParseTupleAndKeywords.
8612 * python/py-cmd.c (cmdpy_init): Likewise.
8613 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8614 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8615 (infpy_search_memory): Likewise.
8616 * python/py-objfile.c (objfpy_add_separate_debug_file)
8617 (gdbpy_lookup_objfile): Likewise.
8618 * python/py-symbol.c (gdbpy_lookup_symbol)
8619 (gdbpy_lookup_global_symbol): Likewise.
8620 * python/py-type.c (gdbpy_lookup_type): Likewise.
8621 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8622 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8623 Likewise.
8624
8625 2017-04-05 Pedro Alves <palves@redhat.com>
8626
8627 * python/python-internal.h (gdb_PyGetSetDef): New type.
8628 * python/py-block.c (block_object_getset)
8629 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8630 * python/py-event.c (event_object_getset)
8631 (finish_breakpoint_object_getset): Likewise.
8632 * python/py-inferior.c (inferior_object_getset): Likewise.
8633 * python/py-infthread.c (thread_object_getset): Likewise.
8634 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8635 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8636 * python/py-objfile.c (objfile_getset): Likewise.
8637 * python/py-progspace.c (pspace_getset): Likewise.
8638 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8639 Likewise.
8640 * python/py-record.c (recpy_record_getset): Likewise.
8641 * python/py-symbol.c (symbol_object_getset): Likewise.
8642 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8643 Likewise.
8644 * python/py-type.c (type_object_getset, field_object_getset):
8645 Likewise.
8646 * python/py-value.c (value_object_getset): Likewise.
8647
8648 2017-04-05 Pedro Alves <palves@redhat.com>
8649
8650 * python/python-internal.h (gdb_PyObject_CallMethod)
8651 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8652 New functions.
8653 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8654 (PySys_GetObject, PySys_SetPath): New macros.
8655
8656 2017-04-05 Pedro Alves <palves@redhat.com>
8657
8658 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8659 info_osdata_command.
8660 * osdata.c (info_osdata_command): Rename to ...
8661 (info_osdata): ... this. Constify 'type' parameter, and remove
8662 the 'from_tty' parameter. Accept NULL TYPE.
8663 (info_osdata_command): New function.
8664 * osdata.h (info_osdata_command): Remove declaration.
8665 (info_osdata): New declaration.
8666
8667 2017-04-05 Pedro Alves <palves@redhat.com>
8668
8669 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8670 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8671 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8672 parameter.
8673 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8674 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8675 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8676 parameter.
8677 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8678 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
8679 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
8680 (mi_cmd_file_list_exec_source_files)
8681 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
8682 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8683 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
8684 parameter.
8685 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
8686 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
8687 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
8688 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
8689 (mi_cmd_stack_info_frame): Constify 'command' parameter.
8690 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
8691 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
8692 'command' parameter.
8693 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
8694 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
8695 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
8696 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
8697 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
8698 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
8699 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
8700 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
8701 (mi_cmd_var_set_update_range): Constify 'command' parameter.
8702 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
8703 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
8704 parameter.
8705 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
8706 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
8707 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
8708 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
8709 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
8710 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
8711 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
8712 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
8713 (mi_cmd_data_list_changed_registers)
8714 (mi_cmd_data_write_register_values)
8715 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
8716 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
8717 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
8718 (mi_cmd_list_features, mi_cmd_list_target_features)
8719 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
8720 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
8721 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
8722 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
8723 (mi_cmd_trace_frame_collected): Constify 'command'
8724 parameter.
8725 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
8726 'command' parameter.
8727
8728 2017-04-05 Pedro Alves <palves@redhat.com>
8729
8730 * ada-lang.c (ada_completer_word_break_characters): Now a const
8731 array.
8732 (ada_get_gdb_completer_word_break_characters): Constify.
8733 * completer.c (gdb_completer_command_word_break_characters)
8734 (gdb_completer_file_name_break_characters)
8735 (gdb_completer_quote_characters): Now const arrays.
8736 (get_gdb_completer_quote_characters): Constify.
8737 (set_rl_completer_word_break_characters): New function.
8738 (set_gdb_completion_word_break_characters)
8739 (complete_line_internal): Use it.
8740 * completer.h (get_gdb_completer_quote_characters): Constify.
8741 (set_rl_completer_word_break_characters): Declare.
8742 * f-lang.c (f_word_break_characters): Constify.
8743 * language.c (default_word_break_characters): Constify.
8744 * language.h (language_defn::la_word_break_characters): Constify.
8745 (default_word_break_characters): Constify.
8746 * top.c (init_main): Use set_rl_completer_word_break_characters.
8747
8748 2017-04-05 Pedro Alves <palves@redhat.com>
8749
8750 * aix-thread.c (aix_thread_pid_to_str)
8751 (aix_thread_extra_thread_info): Constify.
8752 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
8753 * bsd-uthread.c (bsd_uthread_extra_thread_info)
8754 (bsd_uthread_pid_to_str): Constify.
8755 * corelow.c (core_pid_to_str): Constify.
8756 * darwin-nat.c (darwin_pid_to_str): Constify.
8757 * fbsd-nat.c (fbsd_pid_to_str): Constify.
8758 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
8759 Constify.
8760 * gnu-nat.c (gnu_pid_to_str): Constify.
8761 * go32-nat.c (go32_pid_to_str): Constify.
8762 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
8763 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
8764 * inferior.c (inferior_pid_to_str): Constify.
8765 * linux-nat.c (linux_nat_pid_to_str): Constify.
8766 * linux-tdep.c (linux_core_pid_to_str): Constify.
8767 * linux-thread-db.c (thread_db_pid_to_str)
8768 (thread_db_extra_thread_info): Constify.
8769 * nto-tdep.c (nto_extra_thread_info): Constify.
8770 * nto-tdep.h (nto_extra_thread_info): Constify.
8771 * obsd-nat.c (obsd_pid_to_str): Constify.
8772 * procfs.c (procfs_pid_to_str): Constify.
8773 * ravenscar-thread.c (ravenscar_extra_thread_info)
8774 (ravenscar_pid_to_str): Constify.
8775 * remote-sim.c (gdbsim_pid_to_str): Constify.
8776 * remote.c (remote_threads_extra_info, remote_pid_to_str):
8777 Constify.
8778 * sol-thread.c (solaris_pid_to_str): Constify.
8779 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
8780 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
8781 * target.c (default_pid_to_str, target_pid_to_str)
8782 (normal_pid_to_str, default_pid_to_str): Constify.
8783 * target.h (target_ops::to_pid_to_str)
8784 (target_ops::to_extra_thread_info): Constify.
8785 (target_pid_to_str, normal_pid_to_str): Constify.
8786 * windows-nat.c (windows_pid_to_str): Constify.
8787 * gdbarch.sh (core_pid_to_str): Constify.
8788 * target-delegates.c: Regenerate.
8789 * gdbarch.h, gdbarch.c: Regenerate.
8790
8791 2017-04-05 Pedro Alves <palves@redhat.com>
8792
8793 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
8794 the memory of the temporary warning_pre_print override.
8795 * utils.c (warning_pre_print): Constify.
8796 * utils.h (warning_pre_print): Constify.
8797
8798 2017-04-05 Pedro Alves <palves@redhat.com>
8799
8800 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
8801 (shell_command): New function.
8802 (make_command): Use std::string.
8803 (init_cli_cmds): Register shell_command instead of shell_escape.
8804
8805 2017-04-05 Pedro Alves <palves@redhat.com>
8806
8807 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
8808 * tracepoint.c (default_collect): Don't initialize.
8809
8810 2017-04-05 Pedro Alves <palves@redhat.com>
8811
8812 * macroexp.c (macro_buffer::shared): Now a bool.
8813 (init_buffer): Update.
8814 (init_shared_buffer): Constify 'addr' parameter.
8815 (substitute_args, expand, macro_expand, macro_expand_next): Remove
8816 casts.
8817
8818 2017-04-05 Pedro Alves <palves@redhat.com>
8819
8820 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
8821 * disasm.c (set_disassembler_options): Constify local.
8822 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
8823
8824 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
8825
8826 PR gdb/21352
8827 * tracefile.c (tsave_command): Fix argument parsing for '-r'
8828 option.
8829
8830 2017-04-05 Yao Qi <yao.qi@linaro.org>
8831
8832 * frame.c (frame_unwind_register_unsigned): Call
8833 frame_unwind_register_value.
8834
8835 2017-04-05 Yao Qi <yao.qi@linaro.org>
8836
8837 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
8838 Use gdb_test_multiple, and don't match anchor.
8839
8840 2017-04-05 Pedro Alves <palves@redhat.com>
8841
8842 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
8843 (Write After Approval): Remove Simon Marchi.
8844
8845 2017-04-05 Pedro Alves <palves@redhat.com>
8846
8847 * common/gdb_optional.h (optional::optional): Make constexpr and
8848 initialize m_dummy.
8849
8850 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8851
8852 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8853 (amd64fbsd_jmp_buf_reg_offset): Remove.
8854 (amd64fbsd_supply_uthread): Remove function.
8855 (amd64fbsd_collect_uthread): Remove function.
8856 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
8857 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
8858 (x86_64-*-freebsd*): Remove bsd-uthread.o.
8859 (fbsd-nat.c): Update comment.
8860 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8861 (i386fbsd_jmp_buf_reg_offset): Remove.
8862 (i386fbsd_supply_uthread): Remove function.
8863 (i386fbsd_collect_uthread): Remove function.
8864 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
8865
8866 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8867
8868 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
8869 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
8870 * NEWS: Mention that support for FreeBSD/alpha was removed.
8871 * alpha-fbsd-tdep.c: Delete file.
8872 * config/alpha/fbsd.mh: Delete file.
8873 * configure.host: Delete alpha*-*-freebsd* and
8874 alpha*-*-kfreebsd*-gnu.
8875 * configure.tgt: Delete alpha*-*-freebsd* and
8876 alpha*-*-kfreebsd*-gnu.
8877
8878 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8879
8880 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
8881 amd64bsd_store_inferior_registers): Use ptid from regcache.
8882
8883 2017-04-04 Pedro Alves <palves@redhat.com>
8884
8885 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
8886 data fields, make them private and add "m_" prefixes.
8887 (lnp_state_machine::lnp_state_machine): New ctor.
8888 (record_line, check_line_address, handle_set_discriminator)
8889 (handle_set_address, handle_advance_pc, handle_special_opcode)
8890 (handle_advance_line, handle_set_file, handle_negate_stmt)
8891 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
8892 (end_sequence, advance_line): New methods.
8893 (m_gdbarch, m_record_lines_p): New fields.
8894 (lnp_reader_state): Delete.
8895 (dwarf_record_line): Rename to ...
8896 (lnp_state_machine::record_line): ... adjust.
8897 (init_lnp_state_machine): Delete.
8898 (lnp_state_machine::lnp_state_machine): New.
8899 (check_line_address): Rename to ...
8900 (lnp_state_machine::check_line_address): This.
8901 (dwarf_decode_lines_1): Remove reference to "reader_state".
8902 Adjust lnp_state_machine having a non-default ctor. Use bool.
8903 State machine internal state manipulation moved to
8904 lnp_state_machine methods.
8905
8906 2017-04-04 Pedro Alves <palves@redhat.com>
8907
8908 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8909 unittests/offset-type-selftests.c.
8910 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
8911 * common/offset-type.h: New file.
8912 * common/preprocessor.h: New file.
8913 * common/traits.h: New file.
8914 * common/valid-expr.h: New file.
8915 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
8916 sect_offset and cu_offset strong typedefs throughout.
8917 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
8918 typedefs throughout.
8919 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
8920 sect_offset and cu_offset strong typedefs throughout.
8921 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
8922 typedefs throughout.
8923 * gdbtypes.h: Include "common/offset-type.h".
8924 (cu_offset): Now an offset type (strong typedef) instead of a
8925 struct.
8926 (sect_offset): Likewise.
8927 (union call_site_parameter_u): Rename "param_offset" field to
8928 "param_cu_off".
8929 * unittests/offset-type-selftests.c: New file.
8930
8931 2017-04-04 Pedro Alves <palves@redhat.com>
8932
8933 * common/underlying.h: New file.
8934 * dwarf2read.c: Include "common/gdb_optional.h" and
8935 "common/underlying.h".
8936 (dir_index, file_name_index): New types.
8937 (file_entry): Use them.
8938 (file_entry::include): Use to_underlying.
8939 (line_header::add_file_name): Use dir_index.
8940 (read_formatted_entries): Use gdb::optional. Read form before
8941 writting to file_entry.
8942 (dwarf_decode_line_header): Use dir_index.
8943 (lnp_state_machine::current_file): Use to_underlying.
8944 (lnp_state_machine::file): Change type to file_name_index.
8945 (dwarf_record_line): Use to_underlying.
8946 (init_lnp_state_machine): Use file_name_index.
8947 (dwarf_decode_lines_1): Use dir_index and file_name_index.
8948
8949 2017-04-04 Pedro Alves <palves@redhat.com>
8950
8951 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
8952 operator bool, has_value and get methods.
8953
8954 2017-04-04 Pedro Alves <palves@redhat.com>
8955
8956 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
8957 fields.
8958 (line_header): Initialize all data fields. Change type of
8959 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
8960 Change type of include_dirs to std::vector<const char *>. Remove
8961 num_include_dirs, include_dirs_size. Change type of file_names to
8962 std::vector<file_entry>. Remove num_file_names, file_names_size.
8963 (line_header::line_header): New.
8964 (line_header::add_include_dir, line_header::add_file_name): New
8965 methods.
8966 (line_header::include_dir_at): Remove NULL check.
8967 (line_header::file_name_at): Add const overload.
8968 (line_header_up): New unique_ptr typedef.
8969 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
8970 std::vector. Remove free_line_header call.
8971 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
8972 free_line_header call.
8973 (free_cu_line_header): Delete.
8974 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
8975 (setup_type_unit_groups): Use line_header_up instead of cleanups.
8976 Adjust to use std::vector.
8977 (free_line_header): Delete.
8978 (free_line_header_voidp): Use delete.
8979 (add_include_dir): Replace with ...
8980 (line_header::add_include_dir): ... this method. Use std::vector.
8981 (add_file_name): Replace with ...
8982 (line_header::add_file_name): ... this method. Use std::vector.
8983 (add_include_dir_stub): Delete.
8984 (read_formatted_entries): Remove memset.
8985 (dwarf_decode_line_header): Return a line_header_up instead of a
8986 raw pointer. Remove cleanup handling. Pass lambdas to
8987 read_formatted_entries. Adjust to use line_header methods.
8988 (dwarf_decode_lines_1): Adjust to use line_header methods.
8989 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
8990 use std::vector.
8991
8992 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
8993
8994 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
8995 instead of struct ptid.
8996
8997 2017-05-04 Alan Hayward <alan.hayward@arm.com>
8998
8999 * frame.c (get_frame_register_bytes): Unwind using value.
9000 (put_frame_register_bytes): Likewise.
9001
9002 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
9003
9004 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
9005 aggregate-like.
9006
9007 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
9008
9009 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
9010
9011 2017-03-29 Yao Qi <yao.qi@linaro.org>
9012
9013 * gdbthread.h (struct thread_info): Declare constructor and
9014 destructor. Add some in-class member initializers.
9015 * thread.c (free_thread): Remove.
9016 (init_thread_list): Call delete instead of free_thread.
9017 (new_thread): Call thread_info constructor.
9018 (thread_info::thread_info): New function.
9019 (thread_info::~thread_info): New function.
9020 (delete_thread_1): Call delete instead of free_thread.
9021 (make_cleanup_restore_current_thread): Move tp and frame to
9022 inner block.
9023
9024 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9025
9026 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
9027 (arc_skip_prologue): Likewise.
9028 (arc_make_frame_cache): Likewise.
9029 (arc_pv_get_operand): New function.
9030 (arc_is_in_prologue): Likewise.
9031 (arc_analyze_prologue): Likewise.
9032 (arc_print_frame_cache): Likewise.
9033 (MAX_PROLOGUE_LENGTH): New constant.
9034
9035 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9036
9037 * configure.tgt: Add arc-insn.o.
9038 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
9039 (dump_arc_instruction_command): New function.
9040 (arc_fprintf_disasm): Likewise.
9041 (arc_disassemble_info): Likewise.
9042 (arc_insn_get_operand_value): Likewise.
9043 (arc_insn_get_operand_value_signed): Likewise.
9044 (arc_insn_get_memory_base_reg): Likewise.
9045 (arc_insn_get_memory_offset): Likewise.
9046 (arc_insn_get_branch_target): Likewise.
9047 (arc_insn_dump): Likewise.
9048 (arc_insn_get_linear_next_pc): Likewise.
9049 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
9050 (arc_disassemble_info): Likewise.
9051 (arc_insn_get_branch_target): Likewise.
9052 (arc_insn_get_linear_next_pc): Likewise.
9053 * NEWS: Mention new "maint print arc arc-instruction".
9054
9055 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9056
9057 * arc-tdep (maintenance_print_arc_list): New variable.
9058 (maintenance_print_arc_command): New function.
9059
9060 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9061
9062 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
9063 Add "limm" and "reserved".
9064 (arc_cannot_fetch_register, arc_cannot_store_register): Add
9065 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
9066 * arc-tdep.h (arc_regnum): Likewise.
9067
9068 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9069
9070 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9071 for THREADPTR register.
9072 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
9073 register.
9074 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
9075 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
9076 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
9077
9078 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9079
9080 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
9081 registers above gdbarch_num_regs (gdbarch) as privileged in
9082 call0 ABI.
9083
9084 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9085
9086 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9087 for a single specified register or for all registers in
9088 a0_base..a0_base + C0_NREGS range.
9089 (supply_gregset_reg): Call regcache_raw_supply for a single
9090 specified register or for all registers in a0_base..a0_base +
9091 C0_NREGS range.
9092
9093 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9094
9095 * arch/xtensa.h (C0_NREGS): Add definition.
9096 * xtensa-tdep.c (C0_NREGS): Remove definition.
9097
9098 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9099
9100 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
9101 Drop xtensa_default_isa initialization.
9102 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
9103
9104 2017-03-27 Pedro Alves <palves@redhat.com>
9105
9106 * dwarf2read.c (file_entry) <dir_index>: Add comment.
9107 (file_entry::include_dir): New method.
9108 (line_header::include_dir_at, line_header::file_name_at): New
9109 methods.
9110 (setup_type_unit_groups, setup_type_unit_groups)
9111 (psymtab_include_file_name): Simplify using the new methods.
9112 (lnp_state_machine) <the_line_header>: New field.
9113 <file>: Add comment.
9114 (lnp_state_machine::current_file): New method.
9115 (dwarf_record_line): Simplify using the new methods.
9116 (init_lnp_state_machine): Initialize the "the_line_header" field.
9117 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
9118 Simplify using the new methods.
9119
9120 2017-03-27 Pedro Alves <palves@redhat.com>
9121
9122 * cp-name-parser.y (make_empty): Delete.
9123 (demangler_special, nested_name, ptr_operator, array_indicator)
9124 (direct_declarator, declarator_1): Use fill_comp instead of
9125 make_empty.
9126
9127 2017-03-27 Pedro Alves <palves@redhat.com>
9128
9129 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
9130 to ATTRIBUTE_PRINTF.
9131 * solib-target.c (library_list_start_list): Print "string" not
9132 "version".
9133 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
9134 gdb_xml_error call.
9135
9136 2017-03-27 Pedro Alves <palves@redhat.com>
9137
9138 * dwarf2read.c (struct file_and_directory): New.
9139 (dwarf2_get_dwz_file): Adjust to use std::string.
9140 (dw2_get_file_names_reader): Adjust to use file_and_directory.
9141 (find_file_and_directory): Adjust to return a file_and_directory
9142 object.
9143 (read_file_scope): Adjust to use file_and_directory. Remove
9144 make_cleanup/do_cleanups calls.
9145 (open_and_init_dwp_file): Adjust to use std::string. Remove
9146 make_cleanup/do_cleanups calls.
9147 * python/python.c (do_start_initialization): Adjust to ldirname
9148 returning a std::string.
9149 * utils.c (ldirname): Now returns a std::string.
9150 * utils.h (ldirname): Change return type to std::string.
9151 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
9152 returning a std::string.
9153 * xml-tdesc.c (file_read_description_xml): Likewise.
9154
9155 2017-03-24 Alan Hayward <alan.hayward@arm.com>
9156
9157 * regcache.c (regcache_debug_print_register): New function.
9158 * regcache.h (regcache_debug_print_register): New declaration.
9159 * target.c (debug_print_register): Remove.
9160 (target_fetch_registers): Call regcache_debug_print_register.
9161 (target_store_registers): Likewise.
9162
9163 2017-03-24 Pádraig Brady <pbrady@fb.com>
9164
9165 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
9166 reference beyond the 'lh->include_dirs' array before accessing to
9167 it.
9168 (psymtab_include_file_name): Likewise.
9169 (dwarf_decode_lines_1): Likewise.
9170 (dwarf_decode_lines): Likewise.
9171 (file_file_name): Likewise.
9172
9173 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
9174
9175 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
9176 inferior_ptid.
9177 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9178 ps_lsetfpregs): Likewise.
9179 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
9180 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9181 ps_lsetfpregs): Likewise.
9182 * target.c (target_fetch_registers, target_store_registers):
9183 Remove asserts.
9184
9185 2017-03-23 Alan Hayward <alan.hayward@arm.com>
9186
9187 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
9188
9189 2017-03-23 Yao Qi <yao.qi@linaro.org>
9190
9191 * aarch64-tdep.c (aarch64_process_record_test): Declare.
9192 (_initialize_aarch64_tdep): Register it.
9193 (aarch64_record_load_store): Handle PRFM instruction.
9194 (aarch64_process_record_test): New function.
9195
9196 2017-03-23 Yao Qi <yao.qi@linaro.org>
9197
9198 * aarch64-tdep.c (aarch64_record_load_store): Fix code
9199 indentation.
9200
9201 2017-03-23 Yao Qi <yao.qi@linaro.org>
9202
9203 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
9204
9205 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9206
9207 python/python.c (do_start_initialization): Fix memory leak.
9208
9209 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9210
9211 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
9212 using get_ptrace_pid.
9213 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
9214 inferior_ptid.
9215 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
9216 inferior_ptid instead of pid.
9217
9218 2017-03-22 Yao Qi <yao.qi@linaro.org>
9219
9220 * aarch64-tdep.c: Wrap locally used classes in anonymous
9221 namespace.
9222 * arm-tdep.c: Likewise.
9223 * linespec.c: Likewise.
9224 * ui-out.c: Likewise.
9225
9226 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
9227
9228 PR gdb/19637
9229 * python/lib/gdb/printer/bound_registers.py: Import sys.
9230
9231 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9232
9233 * windows-nat.c (do_windows_fetch_inferior_registers): Add
9234 windows_thread_info parameter and use it instead of
9235 current_thread.
9236 (windows_fetch_inferior_registers): Don't set current_thread,
9237 pass the thread to do_windows_fetch_inferior_registers. Use
9238 ptid from regcache instead of inferior_ptid.
9239 (do_windows_store_inferior_registers): Add windows_thread_info
9240 parameter and use it instead of current_thread.
9241 (windows_store_inferior_registers): Don't set current_thread,
9242 pass the thread to do_windows_store_inferior_registers. Use
9243 ptid from regcache instead of inferior_ptid.
9244
9245 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9246
9247 * ser-mingw.c (ser_windows_raw): Remove reference to
9248 struct serial::current_timeout.
9249
9250 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
9251
9252 PR tdep/20928
9253 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
9254 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
9255 (sparc64_fsr_type): Fix %fsr decoding.
9256
9257 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
9258
9259 * python/py-record-btrace.c (btpy_insn_data): Change return type
9260 for Python 2.
9261
9262 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9263
9264 * spu-linux-nat.c (spu_fetch_inferior_registers,
9265 spu_store_inferior_registers): Use ptid from regcache, set and
9266 restore inferior_ptid.
9267 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
9268 Likewise.
9269
9270 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9271
9272 * i386-linux-nat.c (fetch_register, store_register,
9273 i386_linux_fetch_inferior_registers,
9274 i386_linux_store_inferior_registers): Use ptid from regcache.
9275 * ia64-linux-nat.c (ia64_linux_fetch_register,
9276 ia64_linux_store_register): Likewise.
9277 * inf-ptrace.c (inf_ptrace_fetch_register,
9278 inf_ptrace_store_register): Likewise.
9279 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
9280 m32r_linux_store_inferior_registers): Likewise.
9281 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
9282 m68kbsd_store_inferior_registers): Likewise.
9283 * m68k-linux-nat.c (fetch_register, store_register,
9284 m68k_linux_fetch_inferior_registers,
9285 m68k_linux_store_inferior_registers): Likewise.
9286 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
9287 m88kbsd_store_inferior_registers): Likewise.
9288 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
9289 mips_fbsd_store_inferior_registers): Likewise.
9290 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
9291 mips64_linux_regsets_store_registers): Likewise.
9292 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
9293 mipsnbsd_store_inferior_registers): Likewise.
9294 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
9295 mips64obsd_store_inferior_registers): Likewise.
9296 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
9297 Likewise.
9298 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
9299 ppcfbsd_store_inferior_registers): Likewise.
9300 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
9301 ppc_linux_store_inferior_registers): Likewise.
9302 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
9303 ppcnbsd_store_inferior_registers): Likewise.
9304 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
9305 ppcobsd_store_registers): Likewise.
9306 * procfs.c (procfs_fetch_registers, procfs_store_registers):
9307 Likewise.
9308 * ravenscar-thread.c (ravenscar_fetch_registers,
9309 ravenscar_store_registers, ravenscar_prepare_to_store):
9310 Likewise.
9311 * record-btrace.c (record_btrace_fetch_registers,
9312 record_btrace_store_registers, record_btrace_prepare_to_store):
9313 Likewise.
9314 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
9315 Lookup inferior using ptid from regcache, instead of
9316 current_inferior.
9317 * remote.c (remote_fetch_registers, remote_store_registers): Use
9318 ptid from regcache.
9319 * rs6000-nat.c (fetch_register, store_register): Likewise.
9320 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
9321 s390_linux_store_inferior_registers): Likewise.
9322 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
9323 shnbsd_store_inferior_registers): Likewise.
9324 * sol-thread.c (sol_thread_fetch_registers,
9325 sol_thread_store_registers): Likewise.
9326 * sparc-nat.c (sparc_fetch_inferior_registers,
9327 sparc_store_inferior_registers): Likewise.
9328 * tilegx-linux-nat.c (fetch_inferior_registers,
9329 store_inferior_registers): Likewise.
9330 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
9331 vaxbsd_store_inferior_registers): Likewise.
9332 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
9333 store_xtregs): Likewise.
9334
9335 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9336
9337 PR gdb/14441
9338 * NEWS: Mention support for rvalue references in GDB and python.
9339 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
9340 supports both lvalue and rvalue references.
9341
9342 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9343
9344 PR gdb/14441
9345 * gdbtypes.c (rank_one_type): Implement overloading
9346 resolution rules regarding rvalue references.
9347
9348 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9349
9350 PR gdb/14441
9351 * aarch64-tdep.c (aarch64_type_align)
9352 (aarch64_extract_return_value, aarch64_store_return_value): Change
9353 lvalue reference type checks to general reference type checks.
9354 * amd64-tdep.c (amd64_classify): Likewise.
9355 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
9356 Likewise.
9357 * arm-tdep.c (arm_type_align, arm_extract_return_value)
9358 (arm_store_return_value): Likewise.
9359 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
9360 * c-typeprint.c (c_print_type): Likewise.
9361 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
9362 (cplus_number_of_children, cplus_describe_child): Likewise.
9363 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
9364 * completer.c (expression_completer): Likewise.
9365 * cp-support.c (make_symbol_overload_list_adl_namespace):
9366 Likewise.
9367 * darwin-nat-info.c (info_mach_region_command): Likewise.
9368 * dwarf2loc.c (entry_data_value_coerce_ref)
9369 (value_of_dwarf_reg_entry): Likewise.
9370 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
9371 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
9372 Likewise.
9373 * findvar.c (extract_typed_address, store_typed_address):
9374 Likewise.
9375 * gdbtypes.c (rank_one_type): Likewise.
9376 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
9377 * infcall.c (value_arg_coerce): Likewise.
9378 * language.c (pointer_type): Likewise.
9379 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
9380 Likewise.
9381 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
9382 * mn10300-tdep.c (mn10300_type_align): Likewise.
9383 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
9384 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
9385 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
9386 Likewise.
9387 * printcmd.c (print_formatted, x_command): Likewise.
9388 * python/py-type.c (typy_get_composite, typy_template_argument):
9389 Likewise.
9390 * python/py-value.c (valpy_referenced_value)
9391 (valpy_get_dynamic_type, value_has_field): Likewise.
9392 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
9393 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
9394 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
9395 * spu-tdep.c (spu_scalar_value_p): Likewise.
9396 * symtab.c (lookup_symbol_aux): Likewise.
9397 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9398 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9399 Likewise.
9400 * valops.c (value_cast_pointers, value_cast)
9401 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9402 (value_struct_elt, value_struct_elt_bitpos)
9403 (value_find_oload_method_list, find_overload_match)
9404 (value_rtti_indirect_type): Likewise.
9405 * valprint.c (val_print_scalar_type_p, generic_val_print):
9406 Likewise.
9407 * value.c (value_actual_type, value_as_address, unpack_long)
9408 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9409 (coerce_ref): Likewise.
9410 * varobj.c (varobj_get_value_type): Likewise.
9411
9412 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9413
9414 PR gdb/14441
9415 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9416 table of constants.
9417 * python/lib/gdb/command/explore.py: Support exploring values
9418 of rvalue reference types.
9419 * python/lib/gdb/types.py: Implement get_basic_type() for
9420 rvalue reference types.
9421 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9422 constant.
9423 * python/py-value.c (valpy_getitem): Add an rvalue reference
9424 check.
9425 (valpy_reference_value): Add new parameter "refcode".
9426 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9427 New wrappers for valpy_reference_value().
9428 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9429 (gdbpy_invoke_xmethod): Likewise.
9430
9431 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9432
9433 PR gdb/14441
9434 * dwarf2read.c (process_die, read_type_die_1): Handle the
9435 DW_TAG_rvalue_reference_type DIE.
9436 (read_tag_reference_type): Add new parameter "refcode".
9437
9438 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9439
9440 PR gdb/14441
9441 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9442 (c_type_print_modifier, c_type_print_varspec_suffix)
9443 (c_type_print_base): Support printing rvalue reference types.
9444 * c-valprint.c (c_val_print, c_value_print): Support printing
9445 rvalue reference values.
9446
9447 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9448
9449 PR gdb/14441
9450 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9451 typename.
9452 * cp-support.c (replace_typedefs): Handle
9453 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9454 * python/py-type.c (typy_lookup_type): Likewise.
9455
9456 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9457
9458 PR gdb/14441
9459 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9460 * parse.c (insert_type): Change assert statement.
9461 (follow_types): Handle rvalue reference types.
9462 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9463 constant.
9464
9465 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9466
9467 PR gdb/14441
9468 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9469 value_ref() interface.
9470 * c-valprint.c (c_value_print): Likewise.
9471 * infcall.c (value_arg_coerce): Likewise.
9472 * python/py-value.c (valpy_reference_value): Likewise.
9473 * valops.c (value_cast, value_reinterpret_cast)
9474 (value_dynamic_cast, typecmp): Likewise.
9475 (value_ref): Parameterize by kind of return value reference type.
9476 * value.h (value_ref): Add new parameter "refcode".
9477
9478 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9479
9480 PR gdb/14441
9481 * dwarf2read.c (read_tag_reference_type): Use
9482 lookup_lvalue_reference_type() instead of lookup_reference_type().
9483 * eval.c (evaluate_subexp_standard): Likewise.
9484 * f-exp.y: Likewise.
9485 * gdbtypes.c (make_reference_type, lookup_reference_type):
9486 Generalize with rvalue reference types.
9487 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9488 convenience wrappers for lookup_reference_type().
9489 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9490 reference kind parameter.
9491 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9492 wrappers for lookup_reference_type().
9493 * guile/scm-type.c (gdbscm_type_reference): Use
9494 lookup_lvalue_reference_type() instead of lookup_reference_type().
9495 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9496 * parse.c (follow_types): Likewise.
9497 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9498 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9499 Likewise.
9500 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9501 (gdbpy_invoke_xmethod): Likewise.
9502 * stabsread.c: Provide extra argument to make_reference_type()
9503 call.
9504 * valops.c (value_ref, value_rtti_indirect_type): Use
9505 lookup_lvalue_reference_type() instead of lookup_reference_type().
9506
9507 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9508
9509 PR gdb/14441
9510 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9511 (TYPE_IS_REFERENCE): New macro.
9512 (struct type): Add rvalue_reference_type field.
9513 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9514
9515 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9516
9517 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9518 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9519 New function definition.
9520 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9521 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9522 New function declaration.
9523 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9524 * mi/mi-interp.h: New file.
9525 * solib.c (info_sharedlibrary_command): Replace for loop with
9526 ALL_SO_LIBS macro
9527 * solib.h (update_solib_list): New function declaration.
9528 (so_list_head): Move macro.
9529 * solist.h (ALL_SO_LIBS): New macro.
9530
9531 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9532
9533 * infcmd.c (post_create_inferior): Remove unused argument in
9534 call to solib_add.
9535 * remote.c (remote_start_remote): Likewise.
9536 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9537 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9538 (enable_break): Likewise.
9539 * solib.c (update_solib_list): Remove unused target argument
9540 and its documentation.
9541 (solib_add): Remove unused target argument. Remove unused
9542 argument in call to update_solib_list.
9543 (info_sharedlibrary_command): Remove unused argument in call
9544 to update_solib_list.
9545 (sharedlibrary_command): Remove unused argument in call to
9546 solib_add.
9547 (handle_solib_event): Likewise.
9548 (reload_shared_libraries): Likewise.
9549 * solib.h (solib_add): Remove unused target argument.
9550
9551 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9552
9553 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9554 (s390_displaced_step_fixup): Cover relative branches with the
9555 default fixup handling. This fixes lack of support for some
9556 relative branch instructions.
9557
9558 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9559
9560 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9561 ptid from regcache.
9562
9563 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9564
9565 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9566 i386_darwin_store_inferior_registers): Use ptid from regcache.
9567
9568 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9569
9570 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9571 i386bsd_store_inferior_registers): Use ptid from regcache.
9572
9573 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9574
9575 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9576 hppaobsd_store_registers): Use ptid from regcache.
9577
9578 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9579
9580 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9581 hppanbsd_store_registers): Use ptid from regcache.
9582
9583 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9584
9585 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9586 from regcache. Use get_ptrace_pid.
9587
9588 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9589
9590 * corelow.c (get_core_register_section): Use ptid from regcache,
9591 update doc.
9592
9593 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9594
9595 * bsd-uthread.c (bsd_uthread_fetch_registers,
9596 bsd_uthread_store_registers): Use ptid from regcache, set and
9597 restore inferior_ptid.
9598
9599 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9600
9601 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9602 fetch_fp_regs, store_register, store_regs, store_fp_register,
9603 store_fp_regs): Use ptid from regcache.
9604
9605 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9606
9607 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9608 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9609 store_vfp_regs): Use ptid from regcache.
9610
9611 2017-03-17 Pedro Alves <palves@redhat.com>
9612
9613 PR remote/21188
9614 * ser-base.c (ser_base_wait_for): Add comment.
9615 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9616 version.
9617 * ser-unix.c (hardwire_raw): Remove reference to
9618 scb->current_timeout.
9619 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9620 (hardwire_ops): Install ser_base_readchar instead of
9621 hardwire_readchar.
9622 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9623 Remove fields.
9624
9625 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
9626
9627 PR gdb/19637
9628 * python/lib/gdb/printer/bound_registers.py: Add support for
9629 Python 3.
9630
9631 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9632
9633 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9634 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9635 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9636 byte_offset to subobj_byte_offset. Fix the handling of
9637 DWARF_VALUE_STACK on big-endian targets when coming via an
9638 implicit pointer.
9639 (dwarf2_evaluate_loc_desc): Adjust call to
9640 dwarf2_evaluate_loc_desc_full.
9641 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9642 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9643
9644 2017-03-16 Yao Qi <yao.qi@linaro.org>
9645
9646 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9647 and REVSH instructions.
9648
9649 2017-03-16 Yao Qi <yao.qi@linaro.org>
9650
9651 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9652 (arm_record_test): Declare.
9653 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9654 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9655 align with the manual.
9656 (thumb_record_misc): Adjust the code order to align with the
9657 manual.
9658 (thumb2_record_decode_insn_handler): Fix instruction matching.
9659 (instruction_reader_thumb): New class.
9660 (arm_record_test): New function.
9661
9662 2017-03-16 Yao Qi <yao.qi@linaro.org>
9663
9664 * arm-tdep.c (abstract_memory_reader): New class.
9665 (instruction_reader): New class.
9666 (extract_arm_insn): Add argument 'reader'. Callers updated.
9667 (decode_insn): Likewise.
9668
9669 2017-03-16 Doug Evans <dje@google.com>
9670
9671 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9672 member. Change type of TYPE member to SCM. All uses updated.
9673 (lsscm_make_lazy_string_smob): Add assert.
9674 (lsscm_make_lazy_string): Flag bad length values.
9675 (lsscm_elt_type): New function.
9676 (gdbscm_lazy_string_to_value): Rewrite to use
9677 lsscm_safe_lazy_string_to_value.
9678 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
9679 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
9680 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
9681 in incoming type.
9682 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9683 * guile/scm-type.c (tyscm_scm_to_type): New function.
9684
9685 2017-03-15 Doug Evans <dje@google.com>
9686
9687 PR python/17728, python/18439, python/18779
9688 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
9689 member. Change type of TYPE member to PyObject *. All uses updated.
9690 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
9691 (gdbpy_create_lazy_string_object): Flag bad length values.
9692 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
9693 Handle typedefs in incoming type.
9694 (stpy_lazy_string_elt_type): New function.
9695 (gdbpy_extract_lazy_string): Call it.
9696 * python/py-value.c (valpy_lazy_string): Flag bad length values.
9697 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
9698 typedefs in incoming type.
9699
9700 2017-03-16 Doug Evans <dje@google.com>
9701
9702 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9703 * guile/scm-type.c (tyscm_scm_to_type): New function.
9704
9705 2017-03-16 Jiong Wang <jiong.wang@arm.com>
9706
9707 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
9708 "ULONGEST" for "skip".
9709
9710 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9711
9712 PR gdb/21220
9713 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
9714 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
9715 (inf_ptrace_peek_poke): ...here. New function. Now also loop
9716 over ptrace peek/poke until end of buffer or error.
9717
9718 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
9719
9720 * parse.c (length_of_subexp): Make static.
9721 * parser-defs.h (length_of_subexp): Remove.
9722
9723 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9724
9725 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
9726 as well.
9727
9728 2017-03-14 Pedro Alves <palves@redhat.com>
9729
9730 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
9731 (main): Use std::unique_ptr. Remove calls to
9732 cp_demangled_name_parse_free.
9733
9734 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9735
9736 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
9737 alphabsd_store_inferior_registers): Use regcache->ptid instead
9738 of inferior_ptid.
9739
9740 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9741
9742 * aix-thread.c (aix_thread_fetch_registers,
9743 aix_thread_store_registers): Use regcache->ptid instead of
9744 inferior_ptid.
9745
9746 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9747
9748 * aarch64-linux-nat.c (fetch_gregs_from_thread,
9749 store_gregs_to_thread, fetch_fpregs_from_thread,
9750 store_fpregs_to_thread): Use regcache->ptid instead of
9751 inferior_ptid.
9752
9753 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9754
9755 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
9756 amd64_linux_fetch_inferior_registers): Use regcache->ptid
9757 instead of inferior_ptid.
9758
9759 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9760
9761 * target.c (target_fetch_registers, target_store_registers): Add
9762 assert.
9763
9764 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9765
9766 * regcache.h (regcache_get_ptid): New function.
9767 * regcache.c (regcache_get_ptid): New function.
9768
9769 2017-03-13 Mark Wielaard <mark@klomp.org>
9770
9771 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
9772
9773 2017-03-10 Keith Seitz <keiths@redhat.com>
9774
9775 PR c++/8218
9776 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
9777
9778 2017-03-08 Pedro Alves <palves@redhat.com>
9779
9780 PR gdb/18360
9781 * infrun.c (start_step_over, do_target_resume, resume)
9782 (restart_threads): Assert we're not resuming a thread that is
9783 meant to be stopped.
9784 (infrun_thread_stop_requested_callback): Delete.
9785 (infrun_thread_stop_requested): If the thread is internally
9786 stopped, queue a pending stop event and clear the thread's
9787 inline-frame state.
9788 (handle_stop_requested): New function.
9789 (handle_syscall_event, handle_inferior_event_1): Use
9790 handle_stop_requested.
9791 (handle_stop_requested): New function.
9792 (handle_signal_stop): Set the thread's stop_signal here instead of
9793 at caller.
9794 (finish_step_over): Clear step over info unconditionally.
9795 (handle_signal_stop): If the user had interrupted the event
9796 thread, consider the stop a random signal.
9797 (handle_signal_stop) <signal arrived while stepping over
9798 breakpoint>: Don't restart threads here.
9799 (stop_waiting): Don't clear step-over info here.
9800
9801 2017-03-08 Pedro Alves <palves@redhat.com>
9802
9803 PR 21206
9804 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
9805 goes to argument 2, not 1.
9806
9807 2017-03-08 Pedro Alves <palves@redhat.com>
9808
9809 PR cli/21218
9810 * top.c (gdb_readline_wrapper): Avoid passing NULL to
9811 display_gdb_prompt.
9812 (command_line_input): Add comment.
9813
9814 2017-03-08 Pedro Alves <palves@redhat.com>
9815
9816 PR tui/21216
9817 * tui/tui-file.c (tui_file::write): New.
9818 * tui/tui-file.h (tui_file): Override "write".
9819 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
9820 factored out from ...
9821 (tui_puts): ... here.
9822 (tui_putc): Use them.
9823 (tui_write): New function.
9824 * tui/tui-io.h (tui_write): Declare.
9825
9826 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
9827
9828 * Makefile.in (SFILES): Replace "environ.c" with
9829 "common/environ.c".
9830 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
9831 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
9832 to...
9833 * common/environ.c: ... here.
9834 * environ.h: Moved to...
9835 * common/environ.h: ... here.
9836
9837 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9838
9839 * gdbarch.sh (pstring_ptr): New static function.
9840 (gdbarch_disassembler_options): Use it.
9841 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
9842 not valid_disassembler_option->name.
9843 * gdbarch.c: Regenerate.
9844
9845 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9846
9847 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
9848
9849 2017-03-07 Pedro Alves <palves@redhat.com>
9850
9851 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
9852
9853 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
9854
9855 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
9856 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
9857 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
9858 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
9859
9860 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
9861
9862 * xtensa-linux-nat.c (fetch_gregs): Remove const.
9863
9864 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
9865
9866 * remote.c (remote_add_target_side_commands): Use range-based
9867 for loop.
9868
9869 2017-03-03 Yao Qi <yao.qi@linaro.org>
9870
9871 PR gdb/21165
9872 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
9873 value is lazy.
9874 * valprint.c (common_val_print): Likewise.
9875
9876 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
9877
9878 * NEWS: Mention new set/show disassembler-options commands.
9879 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
9880 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
9881 (prospective_options): New static variable.
9882 (gdb_disassembler::gdb_disassembler): Initialize
9883 m_di.disassembler_options.
9884 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
9885 (get_disassembler_options): New function.
9886 (set_disassembler_options): Likewise.
9887 (set_disassembler_options_sfunc): Likewise.
9888 (show_disassembler_options_sfunc): Likewise.
9889 (disassembler_options_completer): Likewise.
9890 (_initialize_disasm): Likewise.
9891 * disasm.h (get_disassembler_options): New prototype.
9892 (set_disassembler_options): Likewise.
9893 * gdbarch.sh (gdbarch_disassembler_options): New variable.
9894 (gdbarch_verify_disassembler_options): Likewise.
9895 * gdbarch.c: Regenerate.
9896 * gdbarch.h: Likewise.
9897 * arm-tdep.c (num_disassembly_options): Delete.
9898 (set_disassembly_style): Likewise.
9899 (arm_disassembler_options): New static variable.
9900 (set_disassembly_style_sfunc): Convert short style name into long
9901 option name. Call set_disassembler_options.
9902 (show_disassembly_style_sfunc): New function.
9903 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
9904 set_gdbarch_verify_disassembler_options.
9905 (_initialize_arm_tdep): Delete regnames variable and update callers.
9906 (arm_disassembler_options): Initialize.
9907 (disasm_options): New variable.
9908 (num_disassembly_options): Rename from this...
9909 (num_disassembly_styles): ...to this. Compute by scanning through
9910 disasm_options.
9911 (valid_disassembly_styles): Initialize using disasm_options.
9912 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
9913 set_arm_regname_option.
9914 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
9915 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
9916 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
9917 set_gdbarch_verify_disassembler_options.
9918 * s390-tdep.c (s390_disassembler_options): New static variable.
9919 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
9920 set_gdbarch_verify_disassembler_options.
9921
9922 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9923
9924 * remote.c (remote_add_target_side_condition): Remove "struct"
9925 keyword from range-based for loop.
9926
9927 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9928
9929 * remote.c (remote_add_target_side_condition): Use range-based
9930 for loop. Update comment.
9931
9932 2017-02-27 Yao Qi <yao.qi@linaro.org>
9933
9934 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
9935
9936 2017-02-26 Alan Hayward <alan.hayward@arm.com>
9937
9938 * regcache.c (regcache_raw_update): New function.
9939 (regcache_raw_read): Move code to regcache_raw_update.
9940 * regcache.h (regcache_raw_update): New declaration.
9941 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
9942
9943 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
9944
9945 * dwarf2read.c (create_debug_type_hash_table): Initialize
9946 header.signature and header.type_offset_in_tu.
9947
9948 2017-02-24 Pedro Alves <palves@redhat.com>
9949
9950 * symtab.c (make_file_symbol_completion_list_1): Use
9951 add_symtab_completions.
9952
9953 2017-02-24 Alan Hayward <alan.hayward@arm.com>
9954
9955 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
9956
9957 2017-02-24 Alan Hayward <alan.hayward@arm.com>
9958
9959 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
9960 I386_MAX_REGISTER_SIZE.
9961 (i386_pseudo_register_write): Likewise.
9962 (i386_process_record): Likewise.
9963 * i387-tdep.c (i387_supply_xsave): Likewise.
9964 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
9965 (store_register): Likewise.
9966
9967 2017-02-23 Pedro Alves <palves@redhat.com>
9968
9969 * ada-lang.c: Include "common/function-view.h".
9970 (ada_iterate_over_symbols): Adjust to use function_view as
9971 callback type.
9972 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
9973 (ada_make_symbol_completion_list): Use a lambda.
9974 (ada_exc_search_name_matches): Delete.
9975 (name_matches_regex): New.
9976 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
9977 * compile/compile-c-support.c: Include "common/function-view.h".
9978 (print_one_macro): Change prototype to accept a ui_file pointer.
9979 (write_macro_definitions): Use a lambda.
9980 * dwarf2read.c: Include "common/function-view.h".
9981 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
9982 (dw2_expand_symtabs_matching): Adjust to use function_view as
9983 callback type.
9984 * language.h: Include "common/function-view.h".
9985 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
9986 function_view as callback type.
9987 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
9988 * linespec.c: Include "common/function-view.h".
9989 (collect_info::add_symbol): New method.
9990 (struct symbol_and_data_callback, iterate_inline_only, struct
9991 symbol_matcher_data, iterate_name_matcher): Delete.
9992 (iterate_over_all_matching_symtabs): Adjust to use function_view
9993 as callback type and lambdas.
9994 (iterate_over_file_blocks): Adjust to use function_view as
9995 callback type.
9996 (decode_compound_collector): Now a class with private fields.
9997 (decode_compound_collector::release_symbols): New method.
9998 (collect_one_symbol): Rename to...
9999 (decode_compound_collector::operator()): ... this and adjust.
10000 (lookup_prefix_sym): decode_compound_collector construction bits
10001 move to decode_compound_collector ctor. Pass the
10002 decode_compound_collector object directly as callback. Remove
10003 cleanups and use decode_compound_collector::release_symbols
10004 instead.
10005 (symtab_collector): Now a class with private fields.
10006 (symtab_collector::release_symtabs): New method.
10007 (add_symtabs_to_list): Rename to...
10008 (symtab_collector::operator()): ... this and adjust.
10009 (collect_symtabs_from_filename): symtab_collector construction
10010 bits move to symtab_collector ctor. Pass the symtab_collector
10011 object directly as callback. Remove cleanups and use
10012 symtab_collector::release_symtabs instead.
10013 (collect_symbols): Delete.
10014 (add_matching_symbols_to_info): Use lambdas.
10015 * macrocmd.c (print_macro_callback): Delete.
10016 (info_macro_command): Use a lambda.
10017 (info_macros_command): Pass print_macro_definition as callable
10018 directly.
10019 (print_one_macro): Remove 'ignore' parameter.
10020 (macro_list_command): Adjust.
10021 * macrotab.c (macro_for_each_data::fn): Now a function_view.
10022 (macro_for_each_data::user_data): Delete field.
10023 (foreach_macro): Adjust to call the function_view.
10024 (macro_for_each): Adjust to use function_view as callback type.
10025 (foreach_macro_in_scope): Adjust to call the function_view.
10026 (macro_for_each_in_scope): Adjust to use function_view as callback
10027 type.
10028 * macrotab.h: Include "common/function-view.h".
10029 (macro_callback_fn): Declare a prototype instead of a pointer.
10030 Remove "user_data" parameter.
10031 (macro_for_each, macro_for_each_in_scope): Adjust to use
10032 function_view as callback type.
10033 * psymtab.c (partial_map_expand_apply)
10034 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
10035 Adjust to use function_view as callback type and to return bool.
10036 (psym_expand_symtabs_matching): Adjust to use function_view as
10037 callback types.
10038 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
10039 to use function_view as callback type and to return bool.
10040 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
10041 callback types.
10042 * symfile.c (expand_symtabs_matching): Adjust to use function_view
10043 as callback types.
10044 * symfile.h: Include "common/function-view.h".
10045 (expand_symtabs_file_matcher_ftype)
10046 (expand_symtabs_symbol_matcher_ftype)
10047 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
10048 return bool.
10049 (quick_symbol_functions::map_symtabs_matching_filename)
10050 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
10051 function_view as callback type and return bool.
10052 (expand_symtabs_matching): Adjust to use function_view as callback
10053 type.
10054 (maintenance_expand_name_matcher)
10055 (maintenance_expand_file_matcher): Delete.
10056 (maintenance_expand_symtabs): Use lambdas.
10057 * symtab.c (iterate_over_some_symtabs): Adjust to use
10058 function_view as callback types and return bool.
10059 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
10060 of a cleanup.
10061 (lookup_symtab_callback): Delete.
10062 (lookup_symtab): Use a lambda.
10063 (iterate_over_symbols): Adjust to use function_view as callback
10064 type.
10065 (struct search_symbols_data, search_symbols_file_matches)
10066 (search_symbols_name_matches): Delete.
10067 (search_symbols): Use a pair of lambdas.
10068 (struct add_name_data, add_macro_name, symbol_completion_matcher)
10069 (symtab_expansion_callback): Delete.
10070 (default_make_symbol_completion_list_break_on_1): Use lambdas.
10071 * symtab.h: Include "common/function-view.h".
10072 (iterate_over_some_symtabs): Adjust to use function_view as
10073 callback type and return bool.
10074 (iterate_over_symtabs): Adjust to use function_view as callback
10075 type.
10076 (symbol_found_callback_ftype): Remove 'data' parameter and return
10077 bool.
10078 (iterate_over_symbols): Adjust to use function_view as callback
10079 type.
10080
10081 2017-02-23 Pedro Alves <palves@redhat.com>
10082
10083 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
10084 (%.o) <unittests/%.c>: New pattern.
10085 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
10086 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
10087 * common/function-view.h: New file.
10088 * unittests/function-view-selftests.c: New file.
10089 * configure: Regenerate.
10090
10091 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
10092
10093 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
10094 inferior_ptid.
10095 * go32-nat.c (go32_thread_alive): Likewise.
10096
10097 2017-02-23 Yao Qi <yao.qi@linaro.org>
10098
10099 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
10100 delete.
10101
10102 2017-02-23 Yao Qi <yao.qi@linaro.org>
10103
10104 * varobj.c (varobj_clear_saved_item): Use delete instead of
10105 xfree.
10106 (update_dynamic_varobj_children): Likewise.
10107
10108 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10109
10110 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
10111
10112 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
10113
10114 * common/enum-flags.h (enum_flags::enum_flags): Initialize
10115 m_enum_value to 0 in default constructor.
10116
10117 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10118
10119 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
10120 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
10121 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
10122 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
10123 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
10124 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
10125 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
10126 IS_STORE_CONDITIONAL_INSN.
10127
10128 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10129
10130 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
10131
10132 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10133
10134 * NEWS (Changes since GDB 7.12): Add DWARF-5.
10135
10136 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10137
10138 * dwarf2read.c (skip_one_die, read_attribute_value)
10139 (dwarf2_const_value_attr, dump_die_shallow)
10140 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
10141 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
10142
10143 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10144
10145 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
10146 (dwarf_parse_macro_header): Accept DWARF version 5.
10147 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
10148
10149 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10150
10151 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
10152 DW_AT_GNU_*.
10153 * common/common-exceptions.h (enum errors): Likewise.
10154 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
10155 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
10156 (dwarf_expr_context::execute_stack_op): Likewise.
10157 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
10158 Likewise.
10159 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
10160 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
10161 (show_entry_values_debug, call_site_to_target_addr)
10162 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
10163 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
10164 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
10165 (value_of_dwarf_block_entry, indirect_pieced_value)
10166 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
10167 (disassemble_dwarf_expression): Likewise.
10168 * dwarf2read.c (process_die, inherit_abstract_dies)
10169 (read_call_site_scope): Likewise.
10170 * gdbtypes.h (struct func_type, struct call_site_parameter)
10171 (struct call_site): Likewise.
10172 * stack.c (read_frame_arg): Likewise.
10173 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
10174
10175 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10176
10177 * defs.h (read_unsigned_leb128): New declaration.
10178 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
10179 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
10180 (dwarf2_find_location_expression): Call also
10181 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
10182 * dwarf2loc.h (dwarf2_version): New declaration.
10183 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
10184 rnglists.
10185 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
10186 .debug_rnglists.
10187 (struct dwop_section_names): Add loclists_dwo.
10188 (dwop_section_names): Add .debug_loclists.dwo.
10189 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
10190 (struct dwarf2_per_cu_data): Add dwarf_version.
10191 (struct dwo_sections): Add loclists.
10192 (struct attr_abbrev): Add implicit_const.
10193 (read_indirect_line_string): New declaration.
10194 (read_unsigned_leb128): Delete declaration.
10195 (rcuh_kind): New definition.
10196 (read_and_check_comp_unit_head): Change parameter
10197 is_debug_types_section to section_kind.
10198 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
10199 (read_comp_unit_head): Change parameter abfd to section, add parameter
10200 section_kind. Handle DWARF-5.
10201 (error_check_comp_unit_head): Accept also DWARF version 5.
10202 (read_and_check_comp_unit_head): Change parameter
10203 is_debug_types_section to section_kind.
10204 (read_and_check_type_unit_head): Delete function.
10205 (read_abbrev_offset): Handle DWARF-5.
10206 (create_debug_type_hash_table): Add parameter section_kind. Process
10207 only DW_UT_type. Use signature and type_offset_in_tu from struct
10208 comp_unit_head.
10209 (create_debug_types_hash_table): Update create_debug_type_hash_table
10210 caller.
10211 (create_all_type_units): Call create_debug_type_hash_table.
10212 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
10213 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
10214 caller.
10215 (skip_one_die): Handle DW_FORM_implicit_const.
10216 (dwarf2_rnglists_process): New function.
10217 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
10218 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
10219 (read_attribute_value): Handle DW_FORM_implicit_const,
10220 DW_FORM_line_strp.
10221 (read_attribute): Handle DW_FORM_implicit_const.
10222 (read_indirect_string_at_offset_from): New function from
10223 read_indirect_string_at_offset.
10224 (read_indirect_string_at_offset): Call
10225 read_indirect_string_at_offset_from.
10226 (read_indirect_line_string_at_offset): New function.
10227 (read_indirect_string): New function comment.
10228 (read_indirect_line_string): New function.
10229 (read_unsigned_leb128): Make it global.
10230 (dwarf2_string_attr): Handle DWARF-5.
10231 (add_include_dir_stub, read_formatted_entries): New functions.
10232 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
10233 Handle DWARF-5.
10234 (per_cu_header_read_in): Update read_comp_unit_head caller.
10235 (dwarf2_version): New function.
10236 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
10237 rnglists.
10238 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
10239 fields.
10240
10241 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10242
10243 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
10244
10245 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10246
10247 * dwarf2read.c (dwarf2_ranges_process): New function from
10248 dwarf2_ranges_read.
10249 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
10250 dwarf2_ranges_process.
10251
10252 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10253
10254 * dwarf2read.c (create_debug_type_hash_table): New function from
10255 create_debug_types_hash_table.
10256 (create_debug_types_hash_table): Call create_debug_type_hash_table.
10257 (create_all_type_units, open_and_init_dwo_file): Update
10258 create_debug_types_hash_table callers.
10259
10260 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10261
10262 PR gdb/16188
10263 * fork-child.c (trace_start_error): Fix thinko. va_end should
10264 refer to 'ap', not 'args'.
10265
10266 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10267 Pedro Alves <palves@redhat.com>
10268
10269 PR gdb/16188
10270 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
10271 calls succeeded.
10272 * fork-child.c (trace_start_error): New function.
10273 (trace_start_error_with_name): Likewise.
10274 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
10275 * inf-ptrace.c (inf_ptrace_me): Likewise.
10276 * inferior.h (trace_start_error): New prototype.
10277 (trace_start_error_with_name): Likewise.
10278
10279 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
10280
10281 PR gdb/21164
10282 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
10283 NULL before using it.
10284 * symmisc.c (maintenance_print_symbols): Likewise.
10285 (maintenance_print_msymbols): Likewise.
10286
10287 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10288
10289 * NEWS: Add record Python bindings entry.
10290
10291 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10292
10293 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
10294 py-record-full.o.
10295 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
10296 * python/py-record-btrace.c, python/py-record-btrace.h,
10297 python/py-record-full.c, python/py-record-full.h: New file.
10298 * python/py-record.c: Add include for py-record-btrace.h and
10299 py-record-full.h.
10300 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
10301 recpy_instruction_history, recpy_function_call_history, recpy_begin,
10302 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
10303 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
10304 New definition.
10305 (gdbpy_initialize_btrace): New export.
10306 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
10307
10308 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10309
10310 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
10311 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
10312 * python/py-record.c: New file.
10313 * python/python-internal.h (gdbpy_start_recording,
10314 gdbpy_current_recording, gdpy_stop_recording,
10315 gdbpy_initialize_record): New export.
10316 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
10317 (python_GdbMethods): Add gdbpy_start_recording,
10318 gdbpy_current_recording and gdbpy_stop_recording.
10319
10320 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10321
10322 * record-btrace.c (record_btrace_record_method): New function.
10323 (init_record_btrace_ops): Initialize to_record_method.
10324 * record-full.c (record_full_record_method): New function.
10325 (init_record_full_ops, init_record_full_core_ops): Add
10326 record_full_record_method.
10327 * record.h (enum record_method): New enum.
10328 * target-debug.h (target_debug_print_enum_record_method: New define.
10329 * target-delegates.c: Regenerate.
10330 * target.c (target_record_method): New function.
10331 * target.h: Include record.h.
10332 (struct target_ops) <to_record_method>: New field.
10333 (target_record_method): New export.
10334
10335 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10336
10337 * record.h (record_start, record_stop): New export.
10338 * record.c (record_start, record_stop): New function.
10339
10340 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10341
10342 * btrace.c (btrace_fetch): Copy function call segments pointer
10343 into a vector.
10344 (btrace_clear): Clear the vector.
10345 (btrace_find_insn_by_number): Use binary search to find the correct
10346 function call segment.
10347 * btrace.h (brace_fun_p): New typedef.
10348 (struct btrace_thread_info) <functions>: New field.
10349
10350 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10351
10352 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
10353 * btrace.c (btrace_decode_error): ... here. New function.
10354 * btrace.h (btrace_decode_error): New export.
10355
10356 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10357
10358 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
10359 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
10360 btrace_find_insn_by_number): Remove special case for gaps.
10361 * btrace.h (btrace_insn_get_error): New export.
10362 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
10363 * record-btrace.c (btrace_insn_history): Print number for gaps.
10364 (record_btrace_info, record_btrace_goto): Handle gaps.
10365
10366 2017-02-14 Tom Tromey <tom@tromey.com>
10367
10368 PR python/13598:
10369 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
10370 event.
10371 * python/py-evts.c (gdbpy_initialize_py_events): Add
10372 before_prompt registry.
10373 * python/py-events.h (events_object) <before_prompt>: New field.
10374
10375 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
10376
10377 * btrace.c (ftrace_new_switch): Preserve up link and flags.
10378
10379 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
10380
10381 * symfile (_initialize_symfile): Add usage text to the load command's
10382 help text.
10383
10384 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
10385
10386 * utils.c (defaulted_query): Don't query on secondary UIs.
10387
10388 2017-02-10 Tom Tromey <tom@tromey.com>
10389
10390 * rust-lang.c (rust_get_disr_info): Remove unused variable.
10391
10392 2017-02-10 Tom Tromey <tom@tromey.com>
10393
10394 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
10395 "cleanup" local.
10396 * python/py-type.c (typy_legacy_template_argument): Remove
10397 unnecessary "cleanup" local.
10398
10399 2017-02-10 Tom Tromey <tom@tromey.com>
10400
10401 * python/python.c (do_start_initialization): New function, from
10402 _initialize_python.
10403 (_initialize_python): Call do_start_initialization.
10404 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10405 goto.
10406
10407 2017-02-10 Tom Tromey <tom@tromey.com>
10408
10409 * python/py-prettyprint.c (pretty_print_one_value): Use
10410 gdbpy_ref.
10411
10412 2017-02-10 Tom Tromey <tom@tromey.com>
10413
10414 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10415 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10416 gdbpy_ref.
10417 * python/py-type.c (field_new): Use gdbpy_ref.
10418 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10419 gdbpy_ref.
10420 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10421 (py_free_pspace): Likewise.
10422 (pspace_to_pspace_object): Likewise.
10423 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10424 (py_free_objfile): Likewise.
10425 (objfile_to_objfile_object): Likewise.
10426 * python/py-inferior.c (delete_thread_object): Use
10427 gdbpy_ref.
10428 (infpy_read_memory): Likewise.
10429 (py_free_inferior): Likewise.
10430 * python/py-evtregistry.c (create_eventregistry_object): Use
10431 gdbpy_ref.
10432 * python/py-event.c (create_event_object): Use gdbpy_ref.
10433
10434 2017-02-10 Tom Tromey <tom@tromey.com>
10435
10436 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10437 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10438 used.
10439 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10440 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10441 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10442 python/py-framefilter.c, python/py-function.c,
10443 python/py-inferior.c, python/py-infevents.c,
10444 python/py-linetable.c, python/py-newobjfileevent.c,
10445 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10446 python/py-signalevent.c, python/py-stopevent.c,
10447 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10448 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10449 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10450 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10451
10452 2017-02-10 Tom Tromey <tom@tromey.com>
10453
10454 * ui-out.h (ui_out_emit_type): New class.
10455 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10456 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10457 and ui_out_emit_tuple.
10458 (enumerate_locals): Likewise.
10459 (py_mi_print_variables, py_print_locals, py_print_args): Use
10460 ui_out_emit_list.
10461 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10462 ui_out_emit_list.
10463 * common/gdb_optional.h: New file.
10464
10465 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10466
10467 * MAINTAINERS (Write After Approval): Update my e-mail address.
10468
10469 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10470
10471 PR gdb/21122
10472 * breakpoint.c (_initialize_breakpoint): Update the help description
10473 of the 'commands' command to indicate that it takes a list argument.
10474
10475 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10476
10477 * interps.c (current_interp_set_logging): Remove "return".
10478
10479 2017-02-09 Gary Benson <gbenson@redhat.com>
10480
10481 * symtab.c (add_symtab_completions): Prevent NULL pointer
10482 dereference.
10483
10484 2017-02-08 Pedro Alves <palves@redhat.com>
10485
10486 * interps.c (interp::interp): Remove reference to quiet_p.
10487 (interp_set): Make static. Remove dead "Switching to" output
10488 code.
10489 (interp_quiet_p, interp_set_quiet): Delete.
10490 (interpreter_exec_cmd): Don't set the interpreter quiet.
10491 * interps.h (interp_quiet_p): Make static.
10492 (class interp) <quiet_p>: Remove field
10493
10494 2017-02-08 Jerome Guitton <guitton@adacore.com>
10495
10496 * cli/cli-decode.c (find_command_name_length): Make it extern.
10497 * cli/cli-decode.h (find_command_name_length): Declare.
10498 * cli/cli-script.c (command_name_equals, line_first_arg):
10499 New functions.
10500 (process_next_line): Use cli-decode to parse command names.
10501 (build_command_line): Make args a constant pointer.
10502
10503 2017-02-08 Jerome Guitton <guitton@adacore.com>
10504
10505 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10506 Remove case-insensitive search.
10507
10508 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10509
10510 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10511 at the end of the line. Avoids an ARI warning.
10512
10513 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
10514
10515 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10516 rdseed instructions.
10517 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10518
10519 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10520
10521 PR tdep/20936
10522 Provide and use sparc32 and sparc64 target description XML files.
10523 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10524 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10525 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10526 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10527 * features/sparc/sparc32-solaris.xml: New file.
10528 * features/sparc/sparc64-solaris.xml: New file.
10529 * features/sparc/sparc32-solaris.c: Generated.
10530 * features/sparc/sparc64-solaris.c: Generated.
10531 * sparc-tdep.h: Account for differences in target descriptions.
10532 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10533 (sparc32_register_type): Use target provided registers.
10534 (validate_tdesc_registers): New function.
10535 (sparc32_gdbarch_init): Use tdesc_has_registers.
10536 Set pseudoregister functions.
10537 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10538 (sparc64_register_type): Use target provided registers.
10539 (sparc64_init_abi): Set pseudoregister functions.
10540
10541 2017-02-03 Tom Tromey <tom@tromey.com>
10542
10543 PR rust/21097:
10544 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10545 with a single member.
10546
10547 2017-02-03 Pedro Alves <palves@redhat.com>
10548
10549 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10550 (cli_interp_base::~cli_interp_base): New.
10551 (cli_interp): New struct.
10552 (as_cli_interp): Cast the interp itself to cli_interp.
10553 (cli_interpreter_pre_command_loop): Rename to ...
10554 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10555 parameter.
10556 (cli_interpreter_init): Rename to ...
10557 (cli_interp::init): ... this. Remove 'self' parameter. Use
10558 boolean. Make extern.
10559 (cli_interpreter_resume): Rename to ...
10560 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10561 extern.
10562 (cli_interpreter_suspend): Rename to ...
10563 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10564 extern.
10565 (cli_interpreter_exec): Rename to ...
10566 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10567 extern.
10568 (cli_interpreter_supports_command_editing): Rename to ...
10569 (cli_interp_base::supports_command_editing): ... this. Remove
10570 'interp' parameter. Make extern.
10571 (cli_ui_out): Rename to ...
10572 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10573 Make extern.
10574 (cli_set_logging): Rename to ...
10575 (cli_interp_base::set_logging): ... this. Remove 'interp'
10576 parameter. Make extern.
10577 (cli_interp_procs): Delete.
10578 (cli_interp_factory): Adjust to use "new".
10579 * cli/cli-interp.h: Include "interps.h".
10580 (struct cli_interp_base): New struct.
10581 * interps.c (struct interp): Delete. Fields moved to interps.h.
10582 (interp_new): Delete.
10583 (interp::interp, interp::~interp): New.
10584 (interp_set): Use bool, and return void. Assume the interpreter
10585 has suspend, init and resume methods, and that the all return
10586 void.
10587 (set_top_level_interpreter): interp_set returns void.
10588 (interp_ui_out): Adapt.
10589 (current_interp_set_logging): Adapt.
10590 (interp_data): Delete.
10591 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10592 (interp_exec): Adapt.
10593 (top_level_interpreter_data): Delete.
10594 * interps.h (interp_init_ftype, interp_resume_ftype)
10595 (interp_suspend_ftype, interp_exec_ftype)
10596 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10597 (class interp): New.
10598 (interp_new): Delete.
10599 (interp_set): Now returns void. Use bool.
10600 (interp_data, top_level_interpreter_data): Delete.
10601 * mi/mi-common.h: Include interps.h.
10602 (class mi_interp): Inherit from interp. Define a ctor. Declare
10603 init, resume, suspect, exec, interp_ui_out, set_logging and
10604 pre_command_loop methods.
10605 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10606 (mi_interpreter_init): Rename to ...
10607 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10608 bool, return void and make extern. Adjust.
10609 (mi_interpreter_resume): ... Rename to ...
10610 (mi_interp::resume): ... this. Remove the 'data' parameter,
10611 return void and make extern. Adjust.
10612 (mi_interpreter_suspend): ... Rename to ...
10613 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10614 return void and make extern. Adjust.
10615 (mi_interpreter_exec): ... Rename to ...
10616 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10617 extern. Adjust.
10618 (mi_interpreter_pre_command_loop): ... Rename to ...
10619 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10620 parameter and make extern.
10621 (mi_on_normal_stop_1): Adjust.
10622 (mi_ui_out): Rename to ...
10623 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10624 parameter and make extern. Adjust.
10625 (mi_set_logging): Rename to ...
10626 (mi_interp::set_logging): ... this. Remove the 'interp'
10627 parameter and make extern. Adjust.
10628 (mi_interp_procs): Delete.
10629 (mi_interp_factory): Adjust to use 'new'.
10630 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10631 (mi_print_exception, mi_execute_command, mi_load_progress):
10632 Adjust.
10633 * tui/tui-interp.c (tui_interp): New class.
10634 (as_tui_interp): Return a tui_interp pointer.
10635 (tui_on_normal_stop, tui_on_signal_received)
10636 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10637 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10638 to use interp::interp_ui_out.
10639 (tui_init): Rename to ...
10640 (tui_interp::init): ... this. Remove the 'self' parameter, use
10641 bool, return void and make extern. Adjust.
10642 (tui_resume): Rename to ...
10643 (tui_interp::resume): ... this. Remove the 'data' parameter,
10644 return void and make extern. Adjust.
10645 (tui_suspend): Rename to ...
10646 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10647 return void and make extern. Adjust.
10648 (tui_ui_out): Rename to ...
10649 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10650 parameter, and make extern. Adjust.
10651 (tui_exec): Rename to ...
10652 (tui_interp::exec): ... this. Remove the 'data' parameter and
10653 make extern.
10654 (tui_interp_procs): Delete.
10655 (tui_interp_factory): Use "new".
10656
10657 2017-02-02 Tom Tromey <tom@tromey.com>
10658
10659 * rust-exp.y (ends_raw_string, space_then_number)
10660 (rust_identifier_start_p): Return bool.
10661 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10662 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10663 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10664 (rust_chartype_p): Return bool.
10665 (val_print_struct, rust_print_struct_def, rust_print_type):
10666 Update.
10667 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10668 Return bool.
10669
10670 2017-02-02 Tom Tromey <tom@tromey.com>
10671
10672 * rust-lang.c: Reindent.
10673
10674 2017-02-02 Tom Tromey <tom@tromey.com>
10675
10676 * rust-lang.h (rust_crate_for_block): Update.
10677 * rust-lang.c (rust_crate_for_block): Return std::string.
10678 (rust_get_disr_info): Use std:;string, not
10679 gdb::unique_xmalloc_ptr.
10680 * rust-exp.y (crate_name): Update.
10681
10682 2017-02-02 Pedro Alves <palves@redhat.com>
10683
10684 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
10685 field out of gdb_disassembler_test and make it static.
10686
10687 2017-02-02 Pedro Alves <palves@redhat.com>
10688
10689 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
10690 mi1_interp and mi_interp fields.
10691
10692 2017-02-02 Pedro Alves <palves@redhat.com>
10693
10694 * cli/cli-interp.c (struct saved_output_files, saved_output):
10695 Moved from cli/cli-logging.c.
10696 (cli_set_logging): New function.
10697 (cli_interp_procs): Install cli_set_logging.
10698 * cli/cli-interp.h (make_logging_output, cli_set_logging):
10699 Declare.
10700 * cli/cli-logging.c (struct saved_output_files, saved_output):
10701 Moved to cli/cli-interp.c.
10702 (pop_output_files): Don't save outputs here.
10703 (make_logging_output): New function.
10704 (handle_redirections): Don't build tee nor save previous outputs
10705 here.
10706 * interps.c (current_interp_set_logging): Change prototype.
10707 Assume there's always a set_logging_proc method installed.
10708 * interps.h (interp_set_logging_ftype): Change prototype.
10709 (current_interp_set_logging): Change prototype and adjust comment.
10710 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
10711 use make_logging_output.
10712 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
10713 2017-02-02 Pedro Alves <palves@redhat.com>
10714
10715 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
10716 from ...
10717 (set_logging_overwrite): ... here.
10718 (logging_no_redirect_file): Delete.
10719 (set_logging_redirect): Don't handle redirection on the fly.
10720 Instead warn that "logging off" / "logging on" is necessary.
10721 (pop_output_files): Delete references to logging_no_redirect_file.
10722 (show_logging_command): Always speak in terms of what will happen
10723 once logging is reenabled.
10724
10725 2017-02-02 Pedro Alves <palves@redhat.com>
10726
10727 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
10728
10729 2017-02-02 Pedro Alves <palves@redhat.com>
10730
10731 * disasm.c (gdb_pretty_print_insn): Rename to ...
10732 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
10733 Remove gdbarch parameter. Adapt to clear the object's buffers
10734 instead of allocating new buffers, and to print using the object's
10735 gdb_disassembler instead of calling gdb_print_insn.
10736 (dump_insns): Use gdb_pretty_print_disassembler.
10737 * disasm.h (gdb_pretty_print_insn): Delete declaration.
10738 (gdb_pretty_print_disassembler): New class.
10739 * record-btrace.c (btrace_insn_history): Use
10740 gdb_pretty_print_disassembler.
10741
10742 2017-02-02 Pedro Alves <palves@redhat.com>
10743
10744 * ada-lang.c (type_as_string): Use string_file.
10745 * ada-valprint.c (ada_print_floating): Use string_file.
10746 * ada-varobj.c (ada_varobj_scalar_image)
10747 (ada_varobj_get_value_image): Use string_file.
10748 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
10749 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
10750 * breakpoint.c (update_inserted_breakpoint_locations)
10751 (insert_breakpoint_locations, reattach_breakpoints)
10752 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
10753 (print_it_watchpoint): Use string_file.
10754 (save_breakpoints): Use stdio_file.
10755 * c-exp.y (oper): Use string_file.
10756 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
10757 tee_file.
10758 (pop_output_files): Use delete.
10759 (handle_redirections): Use stdio_file and tee_file.
10760 * cli/cli-setshow.c (do_show_command): Use string_file.
10761 * compile/compile-c-support.c (c_compute_program): Use
10762 string_file.
10763 * compile/compile-c-symbols.c (generate_vla_size): Take a
10764 'string_file &' instead of a 'ui_file *'.
10765 (generate_c_for_for_one_variable): Take a 'string_file &' instead
10766 of a 'ui_file *'. Use string_file.
10767 (generate_c_for_variable_locations): Take a 'string_file &'
10768 instead of a 'ui_file *'.
10769 * compile/compile-internal.h (generate_c_for_for_one_variable):
10770 Take a 'string_file &' instead of a 'ui_file *'.
10771 * compile/compile-loc2c.c (push, pushf, unary, binary)
10772 (print_label, pushf_register_address, pushf_register)
10773 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
10774 'ui_file *'. Adjust.
10775 * compile/compile.c (compile_to_object): Use string_file.
10776 * compile/compile.h (compile_dwarf_expr_to_c)
10777 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
10778 'ui_file *'.
10779 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
10780 (replace_typedefs_qualified_name): Use string_file and
10781 obstack_copy0.
10782 * disasm.c (gdb_pretty_print_insn): Use string_file.
10783 (gdb_disassembly): Adjust reference the null_stream global.
10784 (do_ui_file_delete): Delete.
10785 (gdb_insn_length): Use null_stream.
10786 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
10787 * dwarf2loc.c (dwarf2_compile_property_to_c)
10788 (locexpr_generate_c_location, loclist_generate_c_location): Take a
10789 'string_file &' instead of a 'ui_file *'.
10790 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
10791 * dwarf2read.c (do_ui_file_peek_last): Delete.
10792 (dwarf2_compute_name): Use string_file.
10793 * event-top.c (gdb_setup_readline): Use stdio_file.
10794 * gdbarch.sh (verify_gdbarch): Use string_file.
10795 * gdbtypes.c (safe_parse_type): Use null_stream.
10796 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
10797 string_file.
10798 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
10799 'string_file *' instead of a 'ui_file *'.
10800 (gdbscm_arch_disassemble): Use string_file.
10801 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
10802 * guile/scm-ports.c (class ioscm_file_port): Now a class that
10803 inherits from ui_file.
10804 (ioscm_file_port_delete, ioscm_file_port_rewind)
10805 (ioscm_file_port_put): Delete.
10806 (ioscm_file_port_write): Rename to ...
10807 (ioscm_file_port::write): ... this. Remove file_port_magic
10808 checks.
10809 (ioscm_file_port_new): Delete.
10810 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
10811 ui_file_up.
10812 * guile/scm-type.c (tyscm_type_name): Use string_file.
10813 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
10814 Use string_file.
10815 * infcmd.c (print_return_value_1): Use string_file.
10816 * infrun.c (print_target_wait_results): Use string_file.
10817 * language.c (add_language): Use string_file.
10818 * location.c (explicit_to_string_internal): Use string_file.
10819 * main.c (captured_main_1): Use null_file.
10820 * maint.c (maintenance_print_architecture): Use stdio_file.
10821 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
10822 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
10823 event_channel>: Change type to mi_console_file pointer.
10824 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
10825 (mi_console_file_delete): Delete.
10826 (struct mi_console_file): Delete.
10827 (mi_console_file_magic): Delete.
10828 (mi_console_file_new): Delete.
10829 (mi_console_file::mi_console_file): New.
10830 (mi_console_file_delete): Delete.
10831 (mi_console_file_fputs): Delete.
10832 (mi_console_file::write): New.
10833 (mi_console_raw_packet): Delete.
10834 (mi_console_file::flush): New.
10835 (mi_console_file_flush): Delete.
10836 (mi_console_set_raw): Rename to ...
10837 (mi_console_file::set_raw): ... this.
10838 * mi/mi-console.h (class mi_console_file): New class.
10839 (mi_console_file_new, mi_console_set_raw): Delete.
10840 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
10841 (mi_set_logging): Use delete and tee_file. Adjust.
10842 * mi/mi-main.c (output_register): Use string_file.
10843 (mi_cmd_data_evaluate_expression): Use string_file.
10844 (mi_cmd_data_read_memory): Use string_file.
10845 (mi_cmd_execute, print_variable_or_computed): Use string_file.
10846 * mi/mi-out.c (mi_ui_out::main_stream): New.
10847 (mi_ui_out::rewind): Use main_stream and
10848 string_file.
10849 (mi_ui_out::put): Use main_stream and string_file.
10850 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10851 Allocate a 'string_file' instead.
10852 (mi_out_new): Don't allocate a mem_fileopen stream here.
10853 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10854 (mi_ui_out::main_stream): Declare method.
10855 * printcmd.c (eval_command): Use string_file.
10856 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
10857 * python/py-arch.c (archpy_disassemble): Use string_file.
10858 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
10859 * python/py-frame.c (frapy_str): Use string_file.
10860 * python/py-framefilter.c (py_print_type, py_print_single_arg):
10861 Use string_file.
10862 * python/py-type.c (typy_str): Use string_file.
10863 * python/py-unwind.c (unwind_infopy_str): Use string_file.
10864 * python/py-value.c (valpy_str): Use string_file.
10865 * record-btrace.c (btrace_insn_history): Use string_file.
10866 * regcache.c (regcache_print): Use stdio_file.
10867 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
10868 * remote.c (escape_buffer): Use string_file.
10869 * rust-lang.c (rust_get_disr_info): Use string_file.
10870 * serial.c (serial_open_ops_1): Use stdio_file.
10871 (do_serial_close): Use delete.
10872 * stack.c (print_frame_arg): Use string_file.
10873 (print_frame_args): Remove local mem_fileopen stream, not used.
10874 (print_frame): Use string_file.
10875 * symmisc.c (maintenance_print_symbols): Use stdio_file.
10876 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
10877 Take a 'string_file *' instead of a 'ui_file *'.
10878 * top.c (new_ui): Use stdio_file and stderr_file.
10879 (free_ui): Use delete.
10880 (execute_command_to_string): Use string_file.
10881 (quit_confirm): Use string_file.
10882 * tracepoint.c (collection_list::append_exp): Use string_file.
10883 * tui/tui-disasm.c (tui_disassemble): Use string_file.
10884 * tui/tui-file.c: Don't include "ui-file.h".
10885 (enum streamtype, struct tui_stream): Delete.
10886 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
10887 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
10888 (tui_file::tui_file): New method.
10889 (tui_file_fputs): Delete.
10890 (tui_file_get_strbuf): Delete.
10891 (tui_file::puts): New method.
10892 (tui_file_adjust_strbuf): Delete.
10893 (tui_file_flush): Delete.
10894 (tui_file::flush): New method.
10895 * tui/tui-file.h: Tweak intro comment.
10896 Include ui-file.h.
10897 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
10898 (tui_file_adjust_strbuf): Delete declarations.
10899 (class tui_file): New class.
10900 * tui/tui-io.c (tui_initialize_io): Use tui_file.
10901 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
10902 (tui_register_format): Use string_stream.
10903 * tui/tui-stack.c (tui_make_status_line): Use string_file.
10904 (tui_get_function_from_frame): Use string_file.
10905 * typeprint.c (type_to_string): Use string_file.
10906 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
10907 (null_stream): New global.
10908 (ui_file_delete): Delete.
10909 (ui_file::ui_file): New.
10910 (null_file_isatty): Delete.
10911 (ui_file::~ui_file): New.
10912 (null_file_rewind): Delete.
10913 (ui_file::printf): New.
10914 (null_file_put): Delete.
10915 (null_file_flush): Delete.
10916 (ui_file::putstr): New.
10917 (null_file_write): Delete.
10918 (ui_file::putstrn): New.
10919 (null_file_read): Delete.
10920 (ui_file::putc): New.
10921 (null_file_fputs): Delete.
10922 (null_file_write_async_safe): Delete.
10923 (ui_file::vprintf): New.
10924 (null_file_delete): Delete.
10925 (null_file::write): New.
10926 (null_file_fseek): Delete.
10927 (null_file::puts): New.
10928 (ui_file_data): Delete.
10929 (null_file::write_async_safe): New.
10930 (gdb_flush, ui_file_isatty): Adjust.
10931 (ui_file_put, ui_file_rewind): Delete.
10932 (ui_file_write): Adjust.
10933 (ui_file_write_for_put): Delete.
10934 (ui_file_write_async_safe, ui_file_read): Adjust.
10935 (ui_file_fseek): Delete.
10936 (fputs_unfiltered): Adjust.
10937 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
10938 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
10939 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
10940 (set_ui_file_data): Delete.
10941 (string_file::~string_file, string_file::write)
10942 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
10943 (do_ui_file_as_string, ui_file_as_string): Delete.
10944 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
10945 (struct mem_file): Delete.
10946 (mem_file_new): Delete.
10947 (stdio_file::stdio_file): New.
10948 (mem_file_delete): Delete.
10949 (stdio_file::stdio_file): New.
10950 (mem_fileopen): Delete.
10951 (stdio_file::~stdio_file): New.
10952 (mem_file_rewind): Delete.
10953 (stdio_file::set_stream): New.
10954 (mem_file_put): Delete.
10955 (stdio_file::open): New.
10956 (mem_file_write): Delete.
10957 (stdio_file_magic, struct stdio_file): Delete.
10958 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
10959 (stdio_file::flush): New.
10960 (stdio_file_read): Rename to ...
10961 (stdio_file::read): ... this. Adjust.
10962 (stdio_file_write): Rename to ...
10963 (stdio_file::write): ... this. Adjust.
10964 (stdio_file_write_async_safe): Rename to ...
10965 (stdio_file::write_async_safe) ... this. Adjust.
10966 (stdio_file_fputs): Rename to ...
10967 (stdio_file::puts) ... this. Adjust.
10968 (stdio_file_isatty): Delete.
10969 (stdio_file_fseek): Delete.
10970 (stdio_file::isatty): New.
10971 (stderr_file_write): Rename to ...
10972 (stderr_file::write) ... this. Adjust.
10973 (stderr_file_fputs): Rename to ...
10974 (stderr_file::puts) ... this. Adjust.
10975 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
10976 (stderr_file::stderr_file): New.
10977 (tee_file_magic): Delete.
10978 (struct tee_file): Delete.
10979 (tee_file::tee_file): New.
10980 (tee_file_new): Delete.
10981 (tee_file::~tee_file): New.
10982 (tee_file_delete): Delete.
10983 (tee_file_flush): Rename to ...
10984 (tee_file::flush): ... this. Adjust.
10985 (tee_file_write): Rename to ...
10986 (tee_file::write): ... this. Adjust.
10987 (tee_file::write_async_safe): New.
10988 (tee_file_fputs): Rename to ...
10989 (tee_file::puts): ... this. Adjust.
10990 (tee_file_isatty): Rename to ...
10991 (tee_file::isatty): ... this. Adjust.
10992 * ui-file.h (struct obstack, struct ui_file): Don't
10993 forward-declare.
10994 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
10995 (ui_file_write_ftype)
10996 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
10997 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
10998 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
10999 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
11000 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
11001 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
11002 (set_ui_file_fseek): Delete.
11003 (ui_file_data, ui_file_delete, ui_file_rewind)
11004 (struct ui_file): New.
11005 (ui_file_up): New.
11006 (class null_file): New.
11007 (null_stream): Declare.
11008 (ui_file_write_for_put, ui_file_put): Delete.
11009 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
11010 Delete.
11011 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
11012 (gdb_fopen, tee_file_new): Delete.
11013 (struct string_file): New.
11014 (struct stdio_file): New.
11015 (stdio_file_up): New.
11016 (struct stderr_file): New.
11017 (class tee_file): New.
11018 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
11019 of a 'ui_file *'. Adjust.
11020 * ui-out.h (class ui_out) <field_stream>: Likewise.
11021 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
11022 (null_stream): Delete.
11023 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
11024 Adjust.
11025 * utils.h (struct ui_file): Delete forward declaration..
11026 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
11027 (error_stream): Take a 'string_file &' instead of a
11028 'ui_file *'.
11029 * varobj.c (varobj_value_get_print_value): Use string_file.
11030 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
11031 * gdbarch.c: Regenerate.
11032
11033 2017-02-02 Pedro Alves <palves@redhat.com>
11034
11035 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
11036 (gdb_pretty_print_insn): ... this. Now a free function. Add back
11037 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
11038 Adjust to call gdb_print_insn instead of
11039 gdb_disassembler::print_insn.
11040 (dump_insns, do_mixed_source_and_assembly_deprecated)
11041 (do_mixed_source_and_assembly, do_assembly_only): Add back a
11042 'gdbarch' parameter. Remove gdb_disassembler parameter.
11043 (gdb_disassembly): Don't allocate a gdb_disassembler here.
11044 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
11045 declaration.
11046 (gdb_pretty_print_insn): Re-add declaration.
11047 * record-btrace.c (btrace_insn_history): Don't allocate a
11048 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
11049
11050 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
11051
11052 * disasm.h (gdb_disassembly): Remove file_string parameter.
11053 * disasm.c (gdb_disassembly): Likewise.
11054 * cli/cli-cmds.c (print_disassembly): Adapt.
11055 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
11056 * stack.c (do_gdb_disassembly): Likewise.
11057
11058 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
11059
11060 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
11061 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
11062 targets. And if the implicit value is longer than needed, extract
11063 the first bytes instead of the "least significant" ones.
11064
11065 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11066
11067 * btrace.c (btrace_enable): Do not call btrace_add_pc for
11068 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
11069 (btrace_fetch): Assert can_access_registers_ptid.
11070 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
11071 validate_registers_access.
11072
11073 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11074
11075 * gdbthread.h (can_access_registers_ptid): New.
11076 * thread.c (can_access_registers_ptid): New.
11077
11078 2017-02-01 Pedro Alves <palves@redhat.com>
11079
11080 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
11081
11082 2017-01-31 Pedro Alves <palves@redhat.com>
11083
11084 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
11085 Fix typos.
11086
11087 2017-01-31 Pedro Alves <palves@redhat.com>
11088
11089 * stack.c (print_frame_args): Remove local mem_fileopen stream,
11090 not used.
11091
11092 2017-01-31 Pedro Alves <palves@redhat.com>
11093
11094 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
11095
11096 2017-01-31 Pedro Alves <palves@redhat.com>
11097
11098 * common/scoped_restore.h
11099 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
11100 change the value's parameter type to T2.
11101 (make_scoped_restore): Likewise.
11102
11103 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11104 Richard Henderson <rth@redhat.com>
11105
11106 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
11107 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
11108 GS_BASE for older kernels.
11109 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
11110 GS_BASE for older kernels.
11111 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
11112 and GS_BASE to the offset table.
11113 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
11114 system register group.
11115 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
11116 for older kernels.
11117 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
11118 amd64 ABI.
11119 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
11120 AMD64_GSBASE_REGNUM.
11121 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
11122 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
11123 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
11124 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
11125 i386/64bit-segments.xml in those rules.
11126 * features/i386/64bit-segments.xml: New file.
11127 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
11128 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
11129 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
11130 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
11131 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
11132 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
11133 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
11134 * features/i386/amd64-avx-linux.c: Regenerated.
11135 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
11136 * features/i386/amd64-avx-mpx.c: Regenerated.
11137 * features/i386/amd64-avx512-linux.c: Regenerated.
11138 * features/i386/amd64-linux.c: Regenerated.
11139 * features/i386/amd64-mpx-linux.c: Regenerated.
11140 * features/i386/i386-avx-mpx-linux.c: Regenerated.
11141 * features/i386/i386-avx-mpx.c: Regenerated.
11142 * features/i386/x32-avx-linux.c: Regenerated.
11143 * features/i386/x32-avx512-linux.c: Regenerated.
11144 * regformats/i386/amd64-avx-linux.dat: Regenerated.
11145 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
11146 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
11147 * regformats/i386/amd64-linux.dat: Regenerated.
11148 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
11149 * regformats/i386/x32-avx-linux.dat: Regenerated.
11150 * regformats/i386/x32-avx512-linux.dat: Regenerated.
11151 * regformats/i386/x32-linux.dat: Regenerated.
11152
11153 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11154
11155 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
11156 Set to AMD64_NUM_REGS.
11157
11158 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11159
11160 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
11161 that checks validity of a register number.
11162
11163 2017-01-27 Kees Cook <keescook@google.com>
11164
11165 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
11166 fetch_fpregs if target has fpa registers.
11167 (arm_linux_store_inferior_registers): Call store_fpregs if target
11168 has fpa registers.
11169
11170 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
11171
11172 * cris-tdep.c (cris_gdbarch_init): Remove check for
11173 info.byte_order and force it to BFD_ENDIAN_LITTLE.
11174
11175 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
11176
11177 * corelow.c (get_core_register_section): Check for regset
11178 existence before checking for REGSET_VARIABLE_SIZE.
11179
11180 2017-01-26 Yao Qi <yao.qi@linaro.org>
11181 Pedro Alves <palves@redhat.com>
11182
11183 PR gdb/20939
11184 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
11185 call memory_error, save memaddr instead.
11186 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
11187 negative, cal memory_error.
11188 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
11189
11190 2017-01-26 Yao Qi <yao.qi@linaro.org>
11191
11192 * disasm-selftests.c (memory_error_test): New function.
11193 (_initialize_disasm_selftests): Register memory_error_test.
11194
11195 2017-01-26 Yao Qi <yao.qi@linaro.org>
11196
11197 * Makefile.in (SFILES): Add disasm-selftests.c and
11198 selftest-arch.c.
11199 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
11200 * disasm-selftests.c: New file.
11201 * selftest-arch.c: New file.
11202 * selftest-arch.h: New file.
11203
11204 2017-01-26 Yao Qi <yao.qi@linaro.org>
11205
11206 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
11207 to bfd_arch_mep. Don't return 0 if section is not
11208 found. Call print_insn_mep.
11209
11210 2017-01-26 Pedro Alves <palves@redhat.com>
11211 Yao Qi <yao.qi@linaro.org>
11212
11213 * arm-tdep.c: Include "disasm.h".
11214 (gdb_print_insn_arm): Update code to get gdbarch.
11215 * disasm.c (dis_asm_read_memory): Change it to
11216 gdb_disassembler::dis_asm_read_memory.
11217 (dis_asm_memory_error): Likewise.
11218 (dis_asm_print_address): Likewise.
11219 (gdb_pretty_print_insn): Change it to
11220 gdb_disassembler::pretty_print_insn.
11221 (dump_insns): Add one argument gdb_disassemlber. All
11222 callers updated.
11223 (do_mixed_source_and_assembly_deprecated): Likewise.
11224 (do_mixed_source_and_assembly): Likewise.
11225 (do_assembly_only): Likewise.
11226 (gdb_disassembler::gdb_disassembler): New.
11227 (gdb_disassembler::print_insn): New.
11228 * disasm.h (class gdb_disassembler): New.
11229 (gdb_pretty_print_insn): Remove declaration.
11230 (gdb_disassemble_info): Likewise.
11231 * guile/scm-disasm.c (class gdbscm_disassembler): New.
11232 (gdbscm_disasm_read_memory_worker): Update.
11233 (gdbscm_disasm_read_memory): Update.
11234 (gdbscm_disasm_memory_error): Remove.
11235 (gdbscm_disasm_print_address): Remove.
11236 (gdbscm_disassembler::gdbscm_disassembler): New.
11237 (gdbscm_print_insn_from_port): Update.
11238 * mips-tdep.c: Include disasm.h.
11239 (gdb_print_insn_mips): Update code to get gdbarch.
11240 * record-btrace.c (btrace_insn_history): Update.
11241 * spu-tdep.c: Include disasm.h.
11242 (struct spu_dis_asm_data): Remove.
11243 (struct spu_dis_asm_info): New.
11244 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
11245 SPU id.
11246 (gdb_print_insn_spu): Cast disassemble_info to
11247 spu_dis_asm_info.
11248
11249 2017-01-26 Yao Qi <yao.qi@linaro.org>
11250
11251 * disasm.c (do_ui_file_delete): Delete.
11252 (gdb_insn_length): Move code creating stream to ...
11253 * utils.c (null_stream): ... here. New function.
11254 * utils.h (null_stream): Declare.
11255
11256 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
11257
11258 * python/py-inferior.c (find_thread_object): Return directly
11259 from the loop. Remove "found" variable.
11260
11261 2017-01-21 Joel Brobecker <brobecker@adacore.com>
11262
11263 GDB 7.12.1 released.
11264
11265 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11266
11267 * python/py-function.c (fnpy_call): Reorder declarations to have
11268 the gdbpy_enter object declared first.
11269 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
11270
11271 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11272
11273 PR python/21068
11274 * python/python-internal.h (PyMem_RawMalloc): Define for
11275 Python < 3.4.
11276 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
11277 PyMem_RawMalloc instead of PyMem_Malloc.
11278
11279 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
11280 Luis Machado <lgustavo@codesourcery.com>
11281
11282 * NEWS (New commands): Mention flash-erase.
11283 (New MI commands): Mention target-flash-erase.
11284 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
11285 command.
11286 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
11287 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
11288 * target.c (flash_erase_command): New function.
11289 (initialize_targets): Add new flash-erase command.
11290 * target.h (flash_erase_command): New declaration.
11291
11292 2017-01-20 Joel Brobecker <brobecker@adacore.com>
11293
11294 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
11295 HAVE_SYS_PROCFS_H is defined.
11296
11297 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11298
11299 * remote.c (struct cached_reg): Change data into a pointer.
11300 * (stop_reply_dtr): Free data pointers before deleting vector.
11301 (process_stop_reply): Likewise.
11302 (remote_parse_stop_reply): Allocate space for data
11303
11304 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11305
11306 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
11307 MAX_REGISTER_SIZE.
11308 (amd64_pseudo_register_read_value): Likewise.
11309 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
11310 (store_register_using_P): Likewise.
11311 * regcache.c (regcache_xfer_part): Likewise.
11312
11313 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
11314
11315 Split real and pseudo registers.
11316 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
11317 (sparc32_pseudo_regnum): New enum.
11318 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
11319 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
11320 (SPARC32_CP0_REGISTERS): New macro.
11321 (sparc32_pseudo_register_name): New function.
11322 (sparc32_register_name): Use sparc32_pseudo_register_name.
11323 (sparc32_pseudo_register_type): New function.
11324 (sparc32_register_type): Use sparc32_pseudo_register_type.
11325 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
11326 pseudo register numbers.
11327 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
11328 (SPARC64_CP0_REGISTERS): New macro.
11329 (sparc64_pseudo_register_name): New function.
11330 (sparc64_register_name): Use sparc64_pseudo_register_name.
11331 (sparc64_pseudo_register_type): New function.
11332 (sparc64_register_type): Use sparc64_pseudo_register_type.
11333 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
11334 pseudo register numbers.
11335 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
11336 sparc64_store_arguments): Handle pseudo register numbers.
11337
11338 2017-01-13 Yao Qi <yao.qi@linaro.org>
11339
11340 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
11341 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
11342 output.
11343 (getpkt_or_notif_sane_1): Likewise.
11344
11345 2017-01-13 Yao Qi <yao.qi@linaro.org>
11346
11347 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
11348 of CC. Pass "-x c++-header" instead of "-x c".
11349
11350 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11351
11352 * remote.c (remote_can_async_p): Update comment.
11353
11354 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11355
11356 * linux-nat.c (linux_nat_can_async_p): Update comment.
11357
11358 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11359
11360 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
11361
11362 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
11363
11364 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
11365
11366 2017-01-10 Tom Tromey <tom@tromey.com>
11367
11368 * python/py-type.c (typy_legacy_template_argument): Update.
11369 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
11370 ~demangle_parse_info): Declare new members.
11371 (cp_demangled_name_to_comp): Return unique_ptr.
11372 (cp_demangled_name_parse_free)
11373 (make_cleanup_cp_demangled_name_parse_free)
11374 (cp_new_demangle_parse_info): Remove.
11375 * cp-support.c (do_demangled_name_parse_free_cleanup)
11376 (make_cleanup_cp_demangled_name_parse_free): Remove.
11377 (inspect_type, cp_canonicalize_string_full)
11378 (cp_canonicalize_string): Update.
11379 (mangled_name_to_comp): Change return type.
11380 (cp_class_name_from_physname, method_name_from_physname)
11381 (cp_func_name, cp_remove_params): Update.
11382 * cp-name-parser.y (demangle_parse_info): New constructor, from
11383 cp_new_demangle_parse_info.
11384 (~demangle_parse_info): New destructor, from
11385 cp_demangled_name_parse_free.
11386 (cp_merge_demangle_parse_infos): Update.
11387 (cp_demangled_name_to_comp): Change return type.
11388
11389 2017-01-10 Tom Tromey <tom@tromey.com>
11390
11391 * top.c (prevent_dont_repeat): Change return type.
11392 * python/python.c (execute_gdb_command): Use std::string.
11393 Update.
11394 * guile/guile.c (gdbscm_execute_gdb_command): Update.
11395 * command.h (prevent_dont_repeat): Change return type.
11396 * breakpoint.c (bpstat_do_actions_1): Update.
11397
11398 2017-01-10 Tom Tromey <tom@tromey.com>
11399
11400 * value.h (scoped_value_mark::~scoped_value_mark): Call
11401 free_to_mark.
11402 (scoped_value_mark::free_to_mark): New method.
11403 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11404 scoped_value_mark.
11405
11406 2017-01-10 Tom Tromey <tom@tromey.com>
11407
11408 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11409 (valpy_reference_value, valpy_const_value, valpy_get_address)
11410 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11411 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11412 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11413 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11414 scoped_value_mark.
11415 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11416 * value.h (scoped_value_mark): New class.
11417
11418 2017-01-10 Tom Tromey <tom@tromey.com>
11419
11420 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11421 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11422 * psymtab.c (discard_psymtabs_upto): Remove.
11423 (make_cleanup_discard_psymtabs): Remove.
11424 (struct psymtab_state): Remove.
11425
11426 2017-01-10 Tom Tromey <tom@tromey.com>
11427
11428 * record-full.c (record_full_save_cleanups): Remove.
11429 (record_full_save): Use gdb::unlinker.
11430 * gcore.c (do_bfd_delete_cleanup): Remove.
11431 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11432 cleanups.
11433 * dwarf2read.c (unlink_if_set): Remove.
11434 (write_psymtabs_to_index): Use gdb::unlinker.
11435 * common/gdb_unlinker.h: New file.
11436
11437 2017-01-10 Tom Tromey <tom@tromey.com>
11438
11439 * windows-tdep.c (windows_xfer_shared_library): Update.
11440 * windows-nat.c (windows_make_so): Update.
11441 * utils.h (make_cleanup_bfd_unref): Remove.
11442 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11443 * symfile.h (symfile_bfd_open)
11444 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11445 * symfile.c (read_symbols, symbol_file_add)
11446 (separate_debug_file_exists): Update.
11447 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11448 (generic_load, reread_symbols): Update.
11449 * symfile-mem.c (symbol_file_add_from_memory): Update.
11450 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11451 (spu_symbol_file_add_from_memory): Update.
11452 * solist.h (struct target_so_ops) <bfd_open>: Return
11453 gdb_bfd_ref_ptr.
11454 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11455 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11456 gdb_bfd_ref_ptr.
11457 (solib_map_sections, reload_shared_libraries_1): Update.
11458 * solib-svr4.c (enable_break): Update.
11459 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11460 * solib-frv.c (enable_break2): Update.
11461 * solib-dsbt.c (enable_break): Update.
11462 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11463 gdb_bfd_ref_ptr.
11464 (darwin_solib_get_all_image_info_addr_at_init): Update.
11465 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11466 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11467 * record-full.c (record_full_save): Update.
11468 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11469 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11470 * minidebug.c (find_separate_debug_file_in_section): Return
11471 gdb_bfd_ref_ptr.
11472 * machoread.c (macho_add_oso_symfile): Change abfd to
11473 gdb_bfd_ref_ptr.
11474 (macho_symfile_read_all_oso): Update.
11475 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11476 (macho_symfile_read): Update.
11477 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11478 (jit_bfd_try_read_symtab): Update.
11479 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11480 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11481 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11482 gdb_bfd_ref_ptr.
11483 (gdb_bfd_ref_policy): New struct.
11484 (gdb_bfd_ref_ptr): New typedef.
11485 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11486 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11487 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11488 gdb_bfd_ref_ptr.
11489 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11490 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11491 (gcore_command): Update.
11492 * exec.c (exec_file_attach): Update.
11493 * elfread.c (elf_symfile_read): Update.
11494 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11495 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11496 (open_and_init_dwo_file): Update.
11497 (open_dwp_file): Return gdb_bfd_ref_ptr.
11498 (open_and_init_dwp_file): Update.
11499 * corelow.c (core_open): Update.
11500 * compile/compile-object-load.c (compile_object_load): Update.
11501 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11502 * coffread.c (coff_symfile_read): Update.
11503 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11504 gdb_bfd_ref_ptr. Rename.
11505 (dump_bfd_file, restore_command): Update.
11506 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11507 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11508 (find_separate_debug_file_by_buildid): Update.
11509
11510 2017-01-10 Tom Tromey <tom@tromey.com>
11511
11512 * common/gdb_ref_ptr.h: New file.
11513 * python/py-ref.h (struct gdbpy_ref_policy): New.
11514 (gdbpy_ref): Now a typedef.
11515
11516 2017-01-10 Tom Tromey <tom@tromey.com>
11517
11518 * utils.h (make_cleanup_htab_delete): Don't declare.
11519 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11520 Remove.
11521 * linespec.c (decode_compound_collector): Add constructor,
11522 destructor.
11523 (lookup_prefix_sym): Remove cleanup.
11524 (symtab_collector): Add constructor, destructor.
11525 (collect_symtabs_from_filename): Remove cleanup.
11526 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11527 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11528 Use htab_up.
11529 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11530 * dwarf2read.c (dw2_expand_symtabs_matching)
11531 (dw2_map_symbol_filenames, dwarf_decode_macros)
11532 (write_psymtabs_to_index): Use htab_up.
11533 * dwarf2loc.c (func_verify_no_selftailcall)
11534 (call_site_find_chain_1, func_verify_no_selftailcall)
11535 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11536 std::vector, gdb::unique_xmalloc_ptr.
11537 (call_sitep): Remove typedef.
11538 (dwarf2_locexpr_baton_eval): Remove unused variable.
11539
11540 2017-01-10 Tom Tromey <tom@tromey.com>
11541
11542 * python/python-internal.h (make_cleanup_py_decref)
11543 (make_cleanup_py_xdecref): Don't declare.
11544 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11545 (py_xdecref, make_cleanup_py_xdecref): Remove.
11546
11547 2017-01-10 Tom Tromey <tom@tromey.com>
11548
11549 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11550 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11551
11552 2017-01-10 Tom Tromey <tom@tromey.com>
11553
11554 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11555
11556 2017-01-10 Tom Tromey <tom@tromey.com>
11557
11558 * python/py-utils.c (unicode_to_encoded_string)
11559 (python_string_to_target_string)
11560 (python_string_to_target_python_string)
11561 (python_string_to_host_string, gdbpy_obj_to_string)
11562 (get_addr_from_python): Use gdbpy_ref.
11563
11564 2017-01-10 Tom Tromey <tom@tromey.com>
11565
11566 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11567 gdbpy_ref.
11568
11569 2017-01-10 Tom Tromey <tom@tromey.com>
11570
11571 * python/python.c (eval_python_command, gdbpy_decode_line)
11572 (gdbpy_run_events, gdbpy_start_type_printers)
11573 (gdbpy_apply_type_printers): Use gdbpy_ref.
11574
11575 2017-01-10 Tom Tromey <tom@tromey.com>
11576
11577 * python/py-param.c (get_doc_string, compute_enum_values): Use
11578 gdbpy_ref.
11579
11580 2017-01-10 Tom Tromey <tom@tromey.com>
11581
11582 * python/py-inferior.c (find_thread_object, build_inferior_list):
11583 Use gdbpy_ref.
11584
11585 2017-01-10 Tom Tromey <tom@tromey.com>
11586
11587 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11588
11589 2017-01-10 Tom Tromey <tom@tromey.com>
11590
11591 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11592 gdbpy_ref.
11593
11594 2017-01-10 Tom Tromey <tom@tromey.com>
11595
11596 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11597 extra incref.
11598 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11599 Use gdbpy_ref.
11600
11601 2017-01-10 Tom Tromey <tom@tromey.com>
11602
11603 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11604 gdbpy_ref.
11605
11606 2017-01-10 Tom Tromey <tom@tromey.com>
11607
11608 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11609 decref results of PyArg_ParseTupleAndKeywords.
11610
11611 2017-01-10 Tom Tromey <tom@tromey.com>
11612
11613 * python/python.c (python_run_simple_file): Use
11614 unique_xmalloc_ptr, gdbpy_ref.
11615
11616 2017-01-10 Tom Tromey <tom@tromey.com>
11617
11618 * python/py-prettyprint.c (print_stack_unless_memory_error)
11619 (print_string_repr, print_children): Use gdbpy_ref.
11620 (dummy_python_frame): New class.
11621 (dummy_python_frame::dummy_python_frame): Rename from
11622 push_dummy_python_frame.
11623 (py_restore_tstate): Remove.
11624
11625 2017-01-10 Tom Tromey <tom@tromey.com>
11626
11627 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11628
11629 2017-01-10 Tom Tromey <tom@tromey.com>
11630
11631 * python/python.c (ensure_python_env, restore_python_env):
11632 Remove.
11633 * python/python-internal.h (ensure_python_env): Don't declare.
11634 * varobj.h (varobj_ensure_python_env): Don't declare.
11635 * varobj.c (varobj_ensure_python_env): Remove.
11636
11637 2017-01-10 Tom Tromey <tom@tromey.com>
11638
11639 * varobj.c (varobj_value_get_print_value): Use
11640 gdbpy_enter_varobj.
11641
11642 2017-01-10 Tom Tromey <tom@tromey.com>
11643
11644 * python/py-prettyprint.c (print_string_repr, print_children):
11645 Update.
11646 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11647 of "encoding".
11648 * varobj.c (varobj_value_get_print_value): Update.
11649 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11650
11651 2017-01-10 Tom Tromey <tom@tromey.com>
11652
11653 * varobj.c (varobj_get_display_hint)
11654 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11655 (varobj_set_visualizer, free_variable): Use
11656 gdbpy_enter_varobj.
11657
11658 2017-01-10 Tom Tromey <tom@tromey.com>
11659
11660 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11661 (do_finish_initialization): New function. Use gdbpy_ref.
11662 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11663 do_finish_initialization.
11664
11665 2017-01-10 Tom Tromey <tom@tromey.com>
11666
11667 * python/py-param.c (get_set_value, get_show_value): Use
11668 gdbpy_enter, gdbpy_ref.
11669
11670 2017-01-10 Tom Tromey <tom@tromey.com>
11671
11672 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11673
11674 2017-01-10 Tom Tromey <tom@tromey.com>
11675
11676 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11677
11678 2017-01-10 Tom Tromey <tom@tromey.com>
11679
11680 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
11681 Use gdbpy_enter_varobj.
11682
11683 2017-01-10 Tom Tromey <tom@tromey.com>
11684
11685 * varobj.c (gdbpy_enter_varobj): New constructor.
11686 * python/python-internal.h (gdbpy_enter_varobj): New class.
11687 * python/py-varobj.c (py_varobj_get_iterator): Use
11688 gdbpy_enter_varobj.
11689
11690 2017-01-10 Tom Tromey <tom@tromey.com>
11691
11692 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
11693 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11694 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
11695 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
11696 unique_xmalloc_ptr.
11697 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
11698
11699 2017-01-10 Tom Tromey <tom@tromey.com>
11700
11701 * python/py-xmethods.c (invoke_match_method): Use
11702 gdbpy_ref.
11703
11704 2017-01-10 Tom Tromey <tom@tromey.com>
11705
11706 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
11707 gdbpy_enter, gdbpy_ref.
11708
11709 2017-01-10 Tom Tromey <tom@tromey.com>
11710
11711 * python/python.c (python_interactive_command): Use gdbpy_enter.
11712
11713 2017-01-10 Tom Tromey <tom@tromey.com>
11714
11715 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
11716 gdbpy_ref.
11717
11718 2017-01-10 Tom Tromey <tom@tromey.com>
11719
11720 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
11721 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11722
11723 2017-01-10 Tom Tromey <tom@tromey.com>
11724
11725 * utils.h (htab_deleter): New struct.
11726 (htab_up): New typedef.
11727 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
11728 gdbpy_enter, gdbpy_ref, htab_up.
11729
11730 2017-01-10 Tom Tromey <tom@tromey.com>
11731
11732 * python/py-unwind.c (pending_frame_invalidate): Remove.
11733 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
11734
11735 2017-01-10 Tom Tromey <tom@tromey.com>
11736
11737 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
11738 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
11739
11740 2017-01-10 Tom Tromey <tom@tromey.com>
11741
11742 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
11743
11744 2017-01-10 Tom Tromey <tom@tromey.com>
11745
11746 * python/python.c (gdbpy_eval_from_control_command)
11747 (gdbpy_source_script, gdbpy_run_events)
11748 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
11749 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
11750 gdbpy_enter.
11751
11752 2017-01-10 Tom Tromey <tom@tromey.com>
11753
11754 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
11755
11756 2017-01-10 Tom Tromey <tom@tromey.com>
11757
11758 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
11759
11760 2017-01-10 Tom Tromey <tom@tromey.com>
11761
11762 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
11763 (python_on_inferior_call_pre, python_on_inferior_call_post)
11764 (python_on_memory_change, python_on_register_change)
11765 (python_inferior_exit, python_new_objfile, add_thread_object)
11766 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
11767
11768 2017-01-10 Tom Tromey <tom@tromey.com>
11769
11770 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
11771 (bpfinishpy_handle_exit): Use gdbpy_enter.
11772
11773 2017-01-10 Tom Tromey <tom@tromey.com>
11774
11775 * python/py-cmd.c (cmdpy_destroyer)
11776 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
11777 gdbpy_enter.
11778
11779 2017-01-10 Tom Tromey <tom@tromey.com>
11780
11781 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11782 gdbpy_enter.
11783 (gdbpy_breakpoint_has_cond): Likewise.
11784
11785 2017-01-10 Tom Tromey <tom@tromey.com>
11786
11787 * python/python.c (gdbpy_enter): New constructor.
11788 (~gdbpy_enter): New destructor.
11789 (restore_python_env, ensure_python_env): Rewrite.
11790 * python/python-internal.h (gdbpy_enter): New class.
11791
11792 2017-01-10 Tom Tromey <tom@tromey.com>
11793
11794 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
11795
11796 2017-01-10 Tom Tromey <tom@tromey.com>
11797
11798 * python/py-value.c (value_has_field, get_field_flag)
11799 (get_field_type, valpy_getitem, convert_value_from_python): Use
11800 gdbpy_ref.
11801
11802 2017-01-10 Tom Tromey <tom@tromey.com>
11803
11804 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
11805 gdbpy_ref.
11806
11807 2017-01-10 Tom Tromey <tom@tromey.com>
11808
11809 * python/py-prettyprint.c (search_pp_list)
11810 (find_pretty_printer_from_objfiles)
11811 (find_pretty_printer_from_progspace)
11812 (find_pretty_printer_from_gdb, find_pretty_printer)
11813 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
11814 gdbpy_ref.
11815
11816 2017-01-10 Tom Tromey <tom@tromey.com>
11817
11818 * python/py-param.c (call_doc_function): Use gdbpy_ref.
11819
11820 2017-01-10 Tom Tromey <tom@tromey.com>
11821
11822 * python/py-linetable.c (build_line_table_tuple_from_pcs)
11823 (ltpy_get_all_source_lines): Use gdbpy_ref.
11824
11825 2017-01-10 Tom Tromey <tom@tromey.com>
11826
11827 * python/py-framefilter.c (extract_sym, extract_value)
11828 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
11829 gdbpy_ref.
11830
11831 2017-01-10 Tom Tromey <tom@tromey.com>
11832
11833 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
11834
11835 2017-01-10 Tom Tromey <tom@tromey.com>
11836
11837 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
11838
11839 2017-01-10 Tom Tromey <tom@tromey.com>
11840
11841 * python/py-function.c (convert_values_to_python, fnpy_init): Use
11842 gdbpy_ref.
11843
11844 2017-01-10 Tom Tromey <tom@tromey.com>
11845
11846 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
11847
11848 2017-01-10 Tom Tromey <tom@tromey.com>
11849
11850 * python/py-type.c (convert_field, make_fielditem, typy_fields)
11851 (typy_range): Use gdbpy_ref.
11852
11853 2017-01-10 Tom Tromey <tom@tromey.com>
11854
11855 * python/py-threadevent.c (create_thread_event_object): Use
11856 gdbpy_ref.
11857 * python/py-stopevent.c (create_stop_event_object): Simplify.
11858 (emit_stop_event): Use gdbpy_ref.
11859 * python/py-signalevent.c (create_signal_event_object): Use
11860 gdbpy_ref.
11861 * python/py-newobjfileevent.c (create_new_objfile_event_object)
11862 (emit_new_objfile_event, create_clear_objfiles_event_object)
11863 (emit_clear_objfiles_event): Use gdbpy_ref.
11864 * python/py-infevents.c (create_inferior_call_event_object)
11865 (create_register_changed_event_object)
11866 (create_memory_changed_event_object, emit_inferior_call_event)
11867 (emit_memory_changed_event, emit_register_changed_event): Use
11868 gdbpy_ref.
11869 * python/py-exitedevent.c (create_exited_event_object)
11870 (emit_exited_event): Use gdbpy_ref.
11871 * python/py-event.h (evpy_emit_event): Remove
11872 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
11873 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
11874 * python/py-continueevent.c (emit_continue_event): Use
11875 gdbpy_ref.
11876 * python/py-breakpoint.c (gdbpy_breakpoint_created)
11877 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
11878 gdbpy_ref.
11879 * python/py-bpevent.c (create_breakpoint_event_object): Use
11880 gdbpy_ref.
11881
11882 2017-01-10 Tom Tromey <tom@tromey.com>
11883
11884 * python/py-ref.h: New file.
11885
11886 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11887
11888 * cli-out.c (cli_ui_out::do_redirect): Change return type to
11889 void.
11890 * cli-out.h (cli_ui_out::do_redirect): Likewise.
11891 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
11892 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
11893 * ui-out.c (ui_out::redirect): Likewise.
11894 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
11895 * cli/cli-logging.c (set_logging_redirect): Update call site of
11896 ui_out::redirect.
11897 (handle_redirections): Likewise.
11898 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
11899 * top.c (execute_command_to_string): Likewise.
11900 * utils.c (do_ui_out_redirect_pop): Likewise.
11901
11902 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11903
11904 * stack.c (_initialize_stack): Update "frame" command help message.
11905
11906 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
11907
11908 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
11909
11910 2017-01-06 Yao Qi <yao.qi@linaro.org>
11911
11912 * x86-linux-nat.h: Include gdb_proc_service.h.
11913
11914 2017-01-06 Yao Qi <yao.qi@linaro.org>
11915
11916 * ser-base.h: Include serial.h.
11917
11918 2017-01-06 Yao Qi <yao.qi@linaro.org>
11919
11920 * ppc-linux-tdep.h: Include ppc-tdep.h.
11921
11922 2017-01-06 Yao Qi <yao.qi@linaro.org>
11923
11924 * nat/amd64-linux-siginfo.h: Include signal.h.
11925
11926 2017-01-06 Yao Qi <yao.qi@linaro.org>
11927
11928 * nat/aarch64-linux-hw-point.h: Include break-common.h.
11929
11930 2017-01-06 Yao Qi <yao.qi@linaro.org>
11931
11932 * mi/mi-parse.h: Include mi-cmds.h.
11933
11934 2017-01-06 Yao Qi <yao.qi@linaro.org>
11935
11936 * inf-loop.c: Don't include "target.h".
11937 * inf-loop.h: Include it here.
11938
11939 2017-01-06 Yao Qi <yao.qi@linaro.org>
11940
11941 * dfp.h: Include "dboulest.h" and "expression.h".
11942
11943 2017-01-06 Yao Qi <yao.qi@linaro.org>
11944
11945 * ax-gdb.h: Include "ax.h".
11946
11947 2017-01-06 Yao Qi <yao.qi@linaro.org>
11948
11949 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
11950 with nat/gdb_ptrace.h.
11951
11952 2017-01-05 Yao Qi <yao.qi@linaro.org>
11953
11954 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
11955 new line.
11956 (mips64_fbsd_sigframe_init): Likewise.
11957
11958 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11959
11960 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
11961 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
11962
11963 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11964
11965 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
11966 * NEWS: Mention new FreeBSD/mips native configuration.
11967 * config/mips/fbsd.mh: New file.
11968 * configure.host: Add mips*-*-freebsd*.
11969 * mips-fbsd-nat.c: New file.
11970
11971 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11972
11973 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
11974 (ALLDEPFILES): Add mips-fbsd-tdep.c.
11975 * NEWS: Mention new FreeBSD/mips target.
11976 * configure.tgt: Add mips*-*-freebsd*.
11977 * mips-fbsd-tdep.c: New file.
11978 * mips-fbsd-tdep.h: New file.
11979
11980 2017-01-04 Yao Qi <yao.qi@linaro.org>
11981
11982 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
11983 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
11984
11985 2017-01-01 Joel Brobecker <brobecker@adacore.com>
11986
11987 Update copyright year range in all GDB files.
11988
11989 2017-01-01 Joel Brobecker <brobecker@adacore.com>
11990
11991 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
11992
11993 For older changes see ChangeLog-2016.
11994 \f
11995 Local Variables:
11996 mode: change-log
11997 left-margin: 8
11998 fill-column: 74
11999 version-control: never
12000 coding: utf-8
12001 End:
This page took 0.267611 seconds and 3 git commands to generate.