141e811c5d3795fa7a8f926c0bcd7b952b75f666
[deliverable/binutils-gdb.git] / gdb / ChangeLog
1 2017-09-27 Tom Tromey <tom@tromey.com>
2
3 * stap-probe.c (info_probes_stap_command): Constify.
4
5 2017-09-27 Tom Tromey <tom@tromey.com>
6
7 * fork-child.c (unset_exec_wrapper_command): Constify.
8
9 2017-09-27 Tom Tromey <tom@tromey.com>
10
11 * btrace.c (get_uint, get_context_size, no_chunk)
12 (maint_btrace_packet_history_cmd)
13 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
14 (maint_info_btrace_cmd): Constify.
15
16 2017-09-27 Tom Tromey <tom@tromey.com>
17
18 * reverse.c (delete_bookmark_command): Constify.
19
20 2017-09-27 Tom Tromey <tom@tromey.com>
21
22 * remote.c (set_memory_packet_size)
23 (set_memory_write_packet_size, show_memory_write_packet_size)
24 (set_memory_read_packet_size, show_memory_read_packet_size)
25 (compare_sections_command, packet_command, remote_put_command)
26 (remote_get_command, remote_delete_command): Constify.
27
28 2017-09-27 Tom Tromey <tom@tromey.com>
29
30 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
31 (set_mipsfpu_double_command, set_mipsfpu_none_command)
32 (set_mipsfpu_auto_command): Constify.
33
34 2017-09-27 Tom Tromey <tom@tromey.com>
35
36 * cli/cli-cmds.h (cd_command): Constify.
37 * cli/cli-cmds.c (cd_command): Constify.
38
39 2017-09-27 Tom Tromey <tom@tromey.com>
40
41 * thread.c (thread_name_command, thread_find_command): Constify.
42
43 2017-09-27 Tom Tromey <tom@tromey.com>
44
45 * probe.c (enable_probes_command, disable_probes_command):
46 Constify.
47
48 2017-09-27 Tom Tromey <tom@tromey.com>
49
50 * symfile.c (symbol_file_command): Constify.
51 * gdbcore.h (deprecated_file_changed_hook): Constify.
52 * exec.c (deprecated_file_changed_hook, exec_file_command)
53 (file_command): Constify.
54 * defs.h (symbol_file_command): Constify.
55
56 2017-09-27 Tom Tromey <tom@tromey.com>
57
58 * remote-fileio.c (set_system_call_allowed)
59 (show_system_call_allowed): Constify.
60
61 2017-09-27 Tom Tromey <tom@tromey.com>
62
63 * tracepoint.c (delete_trace_variable_command)
64 (tfind_end_command, tfind_start_command, tfind_pc_command)
65 (tfind_tracepoint_command, tfind_line_command)
66 (tfind_range_command, tfind_outside_command): Constify.
67
68 2017-09-27 Tom Tromey <tom@tromey.com>
69
70 * ax-gdb.c (maint_agent_printf_command, agent_command)
71 (agent_eval_command): Constify.
72
73 2017-09-27 Tom Tromey <tom@tromey.com>
74
75 * tracepoint.c (info_scope_command): Constify.
76 * python/python.c (gdbpy_decode_line): Constify.
77 * python/py-breakpoint.c (bppy_init): Constify.
78 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
79 * location.h: (new_linespec_location)
80 (string_to_event_location_basic, string_to_event_location):
81 Constify.
82 * location.c (new_linespec_location)
83 (string_to_event_location_basic, string_to_event_location):
84 Constify.
85 * linespec.h (decode_line_with_current_source)
86 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
87 * linespec.c (linespec_lex_to_end)
88 (decode_line_with_current_source)
89 (decode_line_with_last_displayed): Constify.
90 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
91 Constify.
92 * cli/cli-cmds.c (edit_command, list_command): Constify.
93 * breakpoint.h (until_break_command, watch_command_wrapper)
94 (awatch_command_wrapper, rwatch_command_wrapper)
95 (init_ada_exception_breakpoint): Constify.
96 * breakpoint.c (break_command_1, dprintf_command)
97 (break_range_command, watch_command_wrapper)
98 (rwatch_command_wrapper, awatch_command_wrapper)
99 (until_break_command, init_ada_exception_breakpoint)
100 (strace_marker_create_sals_from_location, trace_command)
101 (ftrace_command, strace_command, struct tracepoint): Constify.
102 * ax-gdb.c (agent_command_1): Constify.
103 * ada-lang.c (ada_exception_sal): Constify.
104
105 2017-09-27 Tom Tromey <tom@tromey.com>
106
107 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
108 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
109 (get_context_size, no_chunk, get_insn_history_modifiers)
110 (cmd_record_insn_history, get_call_history_modifiers)
111 (cmd_record_call_history): Constify.
112
113 2017-09-27 Tom Tromey <tom@tromey.com>
114
115 * source.c (show_substitute_path_command)
116 (unset_substitute_path_command, set_substitute_path_command):
117 Constify.
118
119 2017-09-27 Tom Tromey <tom@tromey.com>
120
121 * typeprint.c (maintenance_print_type): Constify.
122 * maint.c (maintenance_dump_me, maintenance_demangle)
123 (maintenance_time_display, maintenance_info_sections)
124 (maintenance_print_statistics, maintenance_deprecate)
125 (maintenance_undeprecate): Constify.
126 (maintenance_do_deprecate): Constify. Use std::string.
127 (maintenance_selftest): Constify.
128 * gdbtypes.h (maintenance_print_type): Constify.
129
130 2017-09-27 Tom Tromey <tom@tromey.com>
131
132 * hppa-tdep.c (unwind_command): Constify.
133
134 2017-09-27 Tom Tromey <tom@tromey.com>
135
136 * target-descriptions.c (unset_tdesc_filename_cmd)
137 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
138 Constify.
139
140 2017-09-27 Tom Tromey <tom@tromey.com>
141
142 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
143
144 2017-09-27 Tom Tromey <tom@tromey.com>
145
146 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
147
148 2017-09-27 Tom Tromey <tom@tromey.com>
149
150 * tui/tui-regs.c (tui_reg_command): Constify.
151
152 2017-09-27 Tom Tromey <tom@tromey.com>
153
154 * skip.c (skip_file_command, skip_function_command)
155 (skip_enable_command, skip_disable_command, skip_delete_command):
156 Constify.
157
158 2017-09-27 Tom Tromey <tom@tromey.com>
159
160 * record-btrace.c (cmd_record_btrace_bts_start)
161 (cmd_record_btrace_pt_start): Constify.
162
163 2017-09-27 Tom Tromey <tom@tromey.com>
164
165 * symmisc.c (maintenance_print_symbols)
166 (maintenance_print_msymbols, maintenance_print_objfiles)
167 (maintenance_info_symtabs, maintenance_check_symtabs)
168 (maintenance_expand_symtabs, maintenance_info_line_tables):
169 Constify.
170
171 2017-09-27 Tom Tromey <tom@tromey.com>
172
173 * top.c (new_ui_command): Constify.
174
175 2017-09-27 Tom Tromey <tom@tromey.com>
176
177 * symfile.c (add_symbol_file_command)
178 (remove_symbol_file_command, list_overlays_command)
179 (map_overlay_command, unmap_overlay_command)
180 (overlay_auto_command, overlay_manual_command)
181 (overlay_off_command, overlay_load_command): Constify.
182
183 2017-09-27 Tom Tromey <tom@tromey.com>
184
185 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
186 (info_spu_mailbox_command, info_spu_dma_command)
187 (info_spu_proxydma_command): Constify.
188
189 2017-09-27 Tom Tromey <tom@tromey.com>
190
191 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
192
193 2017-09-27 Tom Tromey <tom@tromey.com>
194
195 * cli/cli-script.c (user_defined_command): Constify.
196
197 2017-09-27 Tom Tromey <tom@tromey.com>
198
199 * cli/cli-dump.c (dump_memory_command, dump_value_command)
200 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
201 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
202 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
203 (dump_binary_value, append_binary_memory, append_binary_value):
204 Constify.
205 (struct dump_context) <func>: Constify.
206 (add_dump_command): Update.
207
208 2017-09-27 Tom Tromey <tom@tromey.com>
209
210 * cli/cli-cmds.c (show_version, show_configuration)
211 (source_command, show_user): Constify.
212
213 2017-09-27 Tom Tromey <tom@tromey.com>
214
215 * target.c (maintenance_print_target_stack): Constify.
216
217 2017-09-27 Tom Tromey <tom@tromey.com>
218
219 * interps.c (interpreter_exec_cmd): Constify.
220
221 2017-09-27 Tom Tromey <tom@tromey.com>
222
223 * record-full.c (cmd_record_full_restore): Constify.
224
225 2017-09-27 Tom Tromey <tom@tromey.com>
226
227 * memattr.c (enable_mem_command, disable_mem_command)
228 (delete_mem_command): Constify.
229
230 2017-09-27 Tom Tromey <tom@tromey.com>
231
232 * value.c (show_convenience): Constify.
233
234 2017-09-27 Tom Tromey <tom@tromey.com>
235
236 * gdbcore.h (core_file_command): Update.
237 * corefile.c (core_file_command): Constify.
238
239 2017-09-27 Tom Tromey <tom@tromey.com>
240
241 * user-regs.c (maintenance_print_user_registers): Constify.
242
243 2017-09-27 Tom Tromey <tom@tromey.com>
244
245 * cp-namespace.c (maintenance_cplus_namespace): Constify.
246
247 2017-09-27 Tom Tromey <tom@tromey.com>
248
249 * cp-support.c (first_component_command): Constify.
250
251 2017-09-27 Tom Tromey <tom@tromey.com>
252
253 * psymtab.c (maintenance_print_psymbols)
254 (maintenance_info_psymtabs, maintenance_check_psymtabs):
255 Constify.
256
257 2017-09-27 Tom Tromey <tom@tromey.com>
258
259 * windows-tdep.c (display_tib): Constify.
260
261 2017-09-27 Tom Tromey <tom@tromey.com>
262
263 * linux-fork.c (delete_checkpoint_command)
264 (detach_checkpoint_command): Constify.
265
266 2017-09-27 Tom Tromey <tom@tromey.com>
267
268 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
269
270 2017-09-27 Tom Tromey <tom@tromey.com>
271
272 * arc-tdep.c (dump_arc_instruction_command): Constify.
273
274 2017-09-27 Tom Tromey <tom@tromey.com>
275
276 * valprint.c (set_radix, show_radix): Constify.
277
278 2017-09-27 Tom Tromey <tom@tromey.com>
279
280 * dtrace-probe.c (info_probes_dtrace_command): Constify.
281
282 2017-09-27 Tom Tromey <tom@tromey.com>
283
284 * command.h (not_just_help_class_command): Update.
285 * cli/cli-decode.h (not_just_help_class_command): Update.
286 * cli/cli-decode.c (not_just_help_class_command): Constify.
287
288 2017-09-27 Tom Tromey <tom@tromey.com>
289
290 * gdb_bfd.c (maintenance_info_bfds): Constify.
291
292 2017-09-27 Tom Tromey <tom@tromey.com>
293
294 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
295 overloads.
296 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
297 (do_const_cfunc): New function.
298 (cmd_cfunc_eq): New overload.
299 (cli_user_command_p): Check do_const_cfunc.
300 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
301 const_cfunc.
302 * command.h (add_cmd): Add const overload and no-function
303 overload.
304 (set_cmd_cfunc): Add const overload.
305 (cmd_const_cfunc_ftype): Declare.
306 (cmd_cfunc_eq): Add const overload.
307 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
308 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
309 overload.
310
311 2017-09-27 Tom Tromey <tom@tromey.com>
312
313 * macroexp.c (get_next_token_for_substitution): New function.
314 (substitute_args): Call it. Check for __VA_OPT__.
315
316 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
317 Pedro Alves <palves@redhat.com>
318
319 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
320 producer_is_icc_lt_14.
321 (producer_is_icc_lt_14): New function.
322 (check_producer): Add code for checking version of ICC.
323 (producer_is_icc): Move to producer.c.
324 (read_structure_type): Restrict ICC workaround to ICC<14.
325 * producer.c: Include selftest.h.
326 (producer_is_icc, producer_parsing_tests, _initialize_producer):
327 New functions.
328 * producer.h (producer_is_icc): New declaration.
329
330 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
331
332 * Makefile.in (SFILES): Add producer.c.
333 (COMMON_OBS): Add producer.o
334 * amd64-tdep.c (producer.h): Add new include.
335 * dwarf2read.c (producer.h): Add new include.
336 * producer.c: New file.
337 * producer.h: New file.
338 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
339 producer.c.
340 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
341 producer.h.
342
343 2017-09-26 Matthias Klose <doko@ubuntu.com>
344
345 * configure.ac: Search ncursesw before ncurses.
346 Check ncursesw/ncurses.h before ncurses/ncurses.h.
347 * gdb_curses.h: Include <ncursesw/ncurses.h>
348 * config.in, configure: Regenerate.
349
350 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
351
352 PR gdb/22185
353 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
354 obsolete.
355 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
356 Remove i386sol2 support.
357 * configure.nat <i386sol2>: Remove.
358 <sol2-64>: Fold into ...
359 <sol2>: ... this.
360 Move common settings to default section.
361 Add sol-thread.o.
362 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
363 x86_64-*-solaris2.1[0-9]*>: Rename to ...
364 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
365 <i[34567]86-*-solaris*>: Remove.
366 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
367
368 * configure.ac: Remove wctype in libw check.
369 (_MSE_INT_H): Don't define on Solaris 7-9.
370 <solaris*>: Remove libthread_db.so.1 check.
371 * configure: Regenerate.
372 * config.in: Regenerate.
373
374 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
375 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
376 (gdb_ps_size_t): Remove.
377 Use base types in users.
378 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
379
380 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
381
382 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
383
384 PR build/22206
385 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
386 (adi_is_addr_mapped): Likewise.
387 (PSR_ICC): Don't redefine.
388 (PSR_IMPL): Likewise.
389
390 2017-09-25 Tom Tromey <tom@tromey.com>
391
392 * regcache.c (regcache::dump): Use string_printf.
393
394 2017-09-25 Tom Tromey <tom@tromey.com>
395
396 * regcache.c (class regcache_invalidator): New.
397 (struct register_to_invalidate): Remove.
398 (make_cleanup_regcache_invalidate): Remove.
399 (regcache::raw_write): Use regcache_invalidator.
400
401 2017-09-25 Tom Tromey <tom@tromey.com>
402
403 * spu-tdep.c (spu2ppu_sniffer): Update.
404 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
405 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
406 Remove.
407 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
408 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
409 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
410 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
411 (frame_pop): Update.
412
413 2017-09-25 Tom Tromey <tom@tromey.com>
414
415 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
416 * regcache.h (regcache_xfree): Don't declare.
417 * regcache.c (regcache_xfree): Remove.
418 (do_regcache_xfree): Use delete.
419 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
420 * linux-fork.c (free_fork): Use delete.
421 (fork_save_infrun_state): Likewise.
422 * jit.c (jit_dealloc_cache): Use delete.
423 * infrun.c (discard_infcall_suspend_state): Use delete.
424
425 2017-09-25 Tom Tromey <tom@tromey.com>
426
427 * regcache.h (regcache_xmalloc): Don't declare.
428 (regcache_raw_set_cached_value): Update comment.
429 * regcache.c (regcache_xmalloc): Remove.
430 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
431 * jit.c (jit_frame_sniffer): Use new.
432 * frame.c (frame_save_as_regcache): Use new.
433
434 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
435
436 * NEWS: Advertise support for guarded-storage registers on IBM z.
437
438 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
439
440 * s390-linux-nat.c (have_regset_gs): New static variable.
441 (s390_linux_fetch_inferior_registers): Handle guarded-storage
442 control block and guarded-storage broadcast control regsets.
443 (s390_read_description): Detect whether the target has
444 guarded-storage support, return appropriate tdesc.
445 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
446 (features/s390x-gs-linux64.c): Likewise.
447 (struct gdbarch_tdep) <have_gs>: New field.
448 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
449 (s390_gsbc_regset): New variables.
450 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
451 and s390_gsbc_regset, if applicable.
452 (s390_core_read_description): Check whether core file was from a
453 target with guarded-storage support; include appropriate regsets.
454 (s390_gdbarch_init): Add registers for guarded-storage support.
455 (_initialize_s390_tdep): Initialize new target descriptions that
456 include registers for guarded-storage support.
457 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
458 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
459 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
460 (S390_NUM_REGS): Adjust macro definition.
461 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
462 (tdesc_s390x_gs_linux64): New declarations.
463
464 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
465
466 * features/s390-gs-linux64.xml: New file.
467 * features/s390-gs.xml: New file.
468 * features/s390-gsbc.xml: New file.
469 * features/s390x-gs-linux64.xml: New file.
470 * features/Makefile (WHICH): Add s390-gs-linux64 and
471 s390x-gs-linux64.
472 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
473 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
474 * features/s390-gs-linux64.c: New generated file.
475 * features/s390x-gs-linux64.c: New file.
476 * regformats/s390-gs-linux64.dat: New file.
477 * regformats/s390x-gs-linux64.dat: New file.
478
479 2017-09-23 Tom Tromey <tom@tromey.com>
480
481 * defs.h (make_cleanup_override_quit_handler): Don't declare.
482
483 2017-09-22 Tom Tromey <tom@tromey.com>
484
485 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
486 type to scoped_restore_tmpl.
487 <scoped_input_handler>: Initialize m_quit_handler directly.
488
489 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
490
491 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
492 (cd_command): Likewise. Free "current_directory" before
493 assigning to it.
494 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
495 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
496 * top.c (gdb_dirbuf): Remove global declaration.
497 * top.h (gdb_dirbuf): Likewise.
498
499 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
500
501 * gnulib/aclocal.m4: Regenerate.
502 * gnulib/config.in: Regenerate.
503 * gnulib/configure: Regenerate.
504 * gnulib/import/Makefile.am: Regenerate.
505 * gnulib/import/Makefile.in: Regenerate.
506 * gnulib/import/assure.h: New file.
507 * gnulib/import/at-func.c: Likewise
508 * gnulib/import/chdir-long.c: New file.
509 * gnulib/import/chdir-long.h: New file.
510 * gnulib/import/cloexec.c: New file.
511 * gnulib/import/cloexec.h: New file.
512 * gnulib/import/close.c: New file.
513 * gnulib/import/closedir.c: New file.
514 * gnulib/import/dirent-private.h: New file.
515 * gnulib/import/dup-safer.c: New file.
516 * gnulib/import/dup.c: New file.
517 * gnulib/import/dup2.c: New file.
518 * gnulib/import/error.c: New file.
519 * gnulib/import/error.h: New file.
520 * gnulib/import/exitfail.c: New file.
521 * gnulib/import/exitfail.h: New file.
522 * gnulib/import/fchdir.c: New file.
523 * gnulib/import/fcntl.c: New file.
524 * gnulib/import/fcntl.in.h: New file.
525 * gnulib/import/fd-hook.c: New file.
526 * gnulib/import/fd-hook.h: New file.
527 * gnulib/import/fd-safer.c: New file.
528 * gnulib/import/fdopendir.c: New file.
529 * gnulib/import/filename.h: New file.
530 * gnulib/import/filenamecat-lgpl.c: New file.
531 * gnulib/import/filenamecat.h: New file.
532 * gnulib/import/fstat.c: New file.
533 * gnulib/import/fstatat.c: New file.
534 * gnulib/import/getcwd-lgpl.c: New file.
535 * gnulib/import/getcwd.c: New file.
536 * gnulib/import/getdtablesize.c: New file.
537 * gnulib/import/getlogin_r.c: New file.
538 * gnulib/import/getprogname.c: New file.
539 * gnulib/import/getprogname.h: New file.
540 * gnulib/import/gettext.h: New file.
541 * gnulib/import/glob-libc.h: New file.
542 * gnulib/import/glob.c: New file.
543 * gnulib/import/glob.in.h: New file.
544 * gnulib/import/intprops.h: New file.
545 * gnulib/import/m4/chdir-long.m4: New file.
546 * gnulib/import/m4/close.m4: New file.
547 * gnulib/import/m4/closedir.m4: New file.
548 * gnulib/import/m4/d-ino.m4: New file.
549 * gnulib/import/m4/d-type.m4: New file.
550 * gnulib/import/m4/dup.m4: New file.
551 * gnulib/import/m4/dup2.m4: New file.
552 * gnulib/import/m4/error.m4: New file.
553 * gnulib/import/m4/fchdir.m4: New file.
554 * gnulib/import/m4/fcntl.m4: New file.
555 * gnulib/import/m4/fcntl_h.m4: New file.
556 * gnulib/import/m4/fdopendir.m4: New file.
557 * gnulib/import/m4/filenamecat.m4: New file.
558 * gnulib/import/m4/fstat.m4: New file.
559 * gnulib/import/m4/fstatat.m4: New file.
560 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
561 * gnulib/import/m4/getcwd-path-max.m4: New file.
562 * gnulib/import/m4/getcwd.m4: New file.
563 * gnulib/import/m4/getdtablesize.m4: New file.
564 * gnulib/import/m4/getlogin_r.m4: New file.
565 * gnulib/import/m4/getprogname.m4: New file.
566 * gnulib/import/m4/glob.m4: New file.
567 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
568 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
569 * gnulib/import/m4/mempcpy.m4: New file.
570 * gnulib/import/m4/memrchr.m4: New file.
571 * gnulib/import/m4/mode_t.m4: New file.
572 * gnulib/import/m4/msvc-inval.m4: New file.
573 * gnulib/import/m4/msvc-nothrow.m4: New file.
574 * gnulib/import/m4/open.m4: New file.
575 * gnulib/import/m4/openat.m4: New file.
576 * gnulib/import/m4/opendir.m4: New file.
577 * gnulib/import/m4/readdir.m4: New file.
578 * gnulib/import/m4/realloc.m4: New file.
579 * gnulib/import/m4/rewinddir.m4: New file.
580 * gnulib/import/m4/save-cwd.m4: New file.
581 * gnulib/import/m4/strdup.m4: New file.
582 * gnulib/import/m4/strerror.m4: New file.
583 * gnulib/import/m4/unistd-safer.m4: New file.
584 * gnulib/import/mempcpy.c: New file.
585 * gnulib/import/memrchr.c: New file.
586 * gnulib/import/msvc-inval.c: New file.
587 * gnulib/import/msvc-inval.h: New file.
588 * gnulib/import/msvc-nothrow.c: New file.
589 * gnulib/import/msvc-nothrow.h: New file.
590 * gnulib/import/open.c: New file.
591 * gnulib/import/openat-die.c: New file.
592 * gnulib/import/openat-priv.h: New file.
593 * gnulib/import/openat-proc.c: New file.
594 * gnulib/import/openat.c: New file.
595 * gnulib/import/openat.h: New file.
596 * gnulib/import/opendir.c: New file.
597 * gnulib/import/pipe-safer.c: New file.
598 * gnulib/import/readdir.c: New file.
599 * gnulib/import/realloc.c: New file.
600 * gnulib/import/rewinddir.c: New file.
601 * gnulib/import/save-cwd.c: New file.
602 * gnulib/import/save-cwd.h: New file.
603 * gnulib/import/strdup.c: New file.
604 * gnulib/import/strerror-override.c: New file.
605 * gnulib/import/strerror-override.h: New file.
606 * gnulib/import/strerror.c: New file.
607 * gnulib/import/unistd--.h: New file.
608 * gnulib/import/unistd-safer.h: New file.
609 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
610 "getcwd" and "glob".
611 * ser-tcp.c: Undefine "close" before redefining it.
612
613 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
614
615 * guile/scm-value.c (gdbscm_value_address): Initialize address,
616 get rid of res_val.
617
618 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
619
620 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
621 <sol2,sparc>: Likewise.
622 <sol2-64,i386>: Likewise.
623
624 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
625 -Wdeprecated-declarations on *-*-solaris*.
626 * configure: Regenerate.
627
628 * procfs.c: Include "nat/inferior.h".
629 (procfs_info_proc): Fix typo.
630
631 2017-09-21 Kevin Buettner <kevinb@redhat.com>
632
633 * remote.c (vector): Include.
634 (struct private_thread_info): Add field, thread_handle.
635 (free_private_thread_info): Deallocate storage associated with
636 thread handle.
637 (get_private_info_thread): Initialize `thread_handle' field.
638 (struct thread_item): Add field, thread_handle.
639 (clear_threads_listing_context): Deallocate storage associated
640 with thread handle.
641 (start_thread): Add support for "handle" attribute.
642 (thread_attributes): Add "handle".
643 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
644 field.
645 (remote_update_thread_list): Update thread_handle.
646 (remote_thread_handle_to_thread_info): New function.
647 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
648
649 2017-09-21 Kevin Buettner <kevinb@redhat.com>
650
651 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
652 function.
653 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
654 * python/python-internal.h (thread_object_type): Declare.
655
656 2017-09-21 Kevin Buettner <kevinb@redhat.com>
657
658 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
659 (target_thread_handle_to_thread_info): Declare.
660 * target.c (target_thread_handle_to_thread_info): New function.
661 * target-delegates.c: Regenerate.
662 * gdbthread.h (find_thread_by_handle): Declare.
663 * thread.c (find_thread_by_handle): New function.
664 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
665 function.
666 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
667
668 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
669
670 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
671
672 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
673
674 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
675
676 2017-09-21 Yao Qi <yao.qi@linaro.org>
677
678 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
679 to gdb_target_obs.
680
681 2017-09-20 Tom Tromey <tom@tromey.com>
682
683 * breakpoint.c (struct counted_command_line): Remove.
684 (breakpoint_commands): Update.
685 (alloc_counted_command_line, incref_counted_command_line)
686 (decref_counted_command_line, do_cleanup_counted_command_line)
687 (make_cleanup_decref_counted_command_line): Remove.
688 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
689 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
690 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
691 (save_breakpoints): Update.
692 * breakpoint.h (counted_command_line): Now a typedef to
693 shared_ptr.
694 (struct breakpoint) <commands>: Now a counted_command_line.
695 (struct bpstats) <command>: Likewise.
696
697 2017-09-20 Tom Tromey <tom@tromey.com>
698
699 * breakpoint.c (struct commands_info, do_map_commands_command):
700 Remove.
701 (commands_command_1): Update.
702 (iterate_over_related_breakpoints): Take a function_view.
703 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
704 (delete_command): Update.
705 (map_breakpoint_numbers): Take a function_view.
706 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
707 (disable_command): Update.
708 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
709 (enable_command): Update.
710 (struct disp_data, do_enable_breakpoint_disp)
711 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
712 (do_map_enable_delete_breakpoint): Remove.
713 (enable_once_command, enable_count_command, enable_delete_command)
714 (delete_trace_variable_command): Update.
715
716 2017-09-20 Tom Tromey <tom@tromey.com>
717
718 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
719 (bpstat_clear): Use delete.
720 (bpstats): New constructors.
721 (bpstat_copy, bpstat_stop_status): Use new.
722 (dprintf_after_condition_true): Update.
723 * breakpoint.h (bpstats::bpstats): Add constructors.
724 (bpstats::~bpstats): Add destructor.
725
726 2017-09-20 Pedro Alves <palves@redhat.com>
727
728 * eval.c (make_params): Delete, refactored as ...
729 (class fake_method): ... this new type's ctor.
730 (fake_method::~fake_method): New.
731 (evaluate_subexp_standard): Use 'fake_method'.
732
733 2017-09-20 Tom Tromey <tom@tromey.com>
734
735 * windows-nat.c (get_windows_debug_event, windows_wait)
736 (do_initial_windows_stuff, windows_attach): Update.
737 * utils.c (vwarning, internal_vproblem): Update.
738 (ui_unregister_input_event_handler_cleanup)
739 (prepare_to_handle_input): Remove.
740 (class scoped_input_handler): New.
741 (defaulted_query, prompt_for_continue): Update.
742 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
743 Update.
744 * top.c (undo_terminal_modifications_before_exit): Update.
745 * target/target.h (target_terminal_init, target_terminal_inferior)
746 (target_terminal_ours): Don't declare.
747 (class target_terminal): New.
748 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
749 (target_terminal_ours_for_output)
750 (make_cleanup_restore_target_terminal): Don't declare.
751 (target_terminal_info): Remove.
752 * target.c (enum terminal_state, terminal_state): Remove.
753 (target_terminal::terminal_state): Define.
754 (target_terminal::init): Rename from target_terminal_init.
755 (target_terminal::inferior): Rename from
756 target_terminal_inferior.
757 (target_terminal::ours): Rename from target_terminal_ours.
758 (target_terminal::ours_for_output): Rename from
759 target_terminal_ours_for_output.
760 (target_terminal::info): New method.
761 (cleanup_restore_target_terminal)
762 (make_cleanup_restore_target_terminal): Remove.
763 * solib.c (handle_solib_event): Update.
764 * remote.c (remote_serial_quit_handler): Update.
765 (remote_terminal_inferior, remote_wait_as): Update.
766 * record-full.c (record_full_wait_1): Update.
767 * nto-procfs.c (procfs_create_inferior): Update.
768 * nat/fork-inferior.c (startup_inferior): Update.
769 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
770 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
771 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
772 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
773 (mi_breakpoint_created, mi_breakpoint_deleted)
774 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
775 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
776 (mi_user_selected_context_changed, report_initial_inferior):
777 Update.
778 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
779 (linux_nat_terminal_inferior): Update.
780 * infrun.c (follow_fork_inferior)
781 (handle_vfork_child_exec_or_exit, do_target_resume)
782 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
783 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
784 Update.
785 * inflow.c (child_terminal_init, info_terminal_command): Update.
786 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
787 (attach_command): Update.
788 * infcall.c (call_thread_fsm_should_stop): Update.
789 * gnu-nat.c (gnu_attach): Update.
790 * extension.c (struct active_ext_lang_state)
791 (restore_active_ext_lang): Update.
792 * exceptions.c (print_flush): Update.
793 * event-top.c (async_enable_stdin, default_quit_handler): Update.
794 (struct quit_handler_cleanup_data, restore_quit_handler)
795 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
796 Remove.
797 * cp-support.c (gdb_demangle): Update.
798 * breakpoint.c (update_inserted_breakpoint_locations)
799 (insert_breakpoint_locations, handle_jit_event)
800 (disable_breakpoints_in_unloaded_shlib): Update.
801 * annotate.c (annotate_breakpoints_invalid)
802 (annotate_frames_invalid): Update.
803
804 2017-09-20 Tom Tromey <tom@tromey.com>
805
806 * main.c (catch_command_errors): Rename from
807 catch_command_errors_const.
808 (captured_main_1): Update.
809
810 2017-09-20 Pedro Alves <palves@redhat.com>
811
812 * cli/cli-cmds.c (list_command): Use print_sal_location.
813 (print_sal_location): New function.
814 (ambiguous_line_spec): Use print_sal_location.
815 * linespec.c (symbol_to_sal): Record the symbol in the sal.
816 * symtab.c (find_function_start_sal): Likewise.
817 * symtab.h (symtab_and_line::symbol): New field.
818
819 2017-09-20 Pedro Alves <palves@redhat.com>
820
821 * linespec.c (minsym_found): Handle non-text minsyms.
822 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
823
824 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
825
826 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
827 backslash.
828
829 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
830
831 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
832 vmovups instead vmovaps.
833 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
834
835 2017-09-19 John Baldwin <jhb@FreeBSD.org>
836
837 * NEWS (Changes since GDB 8.0): Add starti.
838 * infcmd.c (enum run_break): New.
839 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
840 case.
841 (run_command): Use enum run_how.
842 (start_command): Likewise.
843 (starti_command): New function.
844 (RUN_ARGS_HELP): New macro.
845 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
846 commands. Add starti command.
847
848 2017-09-19 Yao Qi <yao.qi@linaro.org>
849
850 * Makefile.in (monitor.o): Remove the rule.
851
852 2017-09-19 Yao Qi <yao.qi@linaro.org>
853
854 * annotate.h (struct annotate_arg_emitter): Use
855 DISABLE_COPY_AND_ASSIGN.
856 * common/refcounted-object.h (refcounted_object): Likewise.
857 * completer.h (struct completion_result): Likewise.
858 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
859 * filename-seen-cache.h (filename_seen_cache): Likewise.
860 * gdbcore.h (thread_section_name): Likewise.
861 * gdb_regex.h (compiled_regex): Likewise.
862 * gdbthread.h (scoped_restore_current_thread): Likewise.
863 * inferior.h (scoped_restore_current_inferior): Likewise.
864 * jit.c (jit_reader): Likewise.
865 * linespec.h (struct linespec_result): Likewise.
866 * mi/mi-parse.h (struct mi_parse): Likewise.
867 * nat/fork-inferior.c (execv_argv): Likewise.
868 * progspace.h (scoped_restore_current_program_space): Likewise.
869 * python/python-internal.h (class gdbpy_enter): Likewise.
870 * regcache.h (regcache): Likewise.
871 * target-descriptions.c (struct tdesc_reg): Likewise.
872 (struct tdesc_type): Likewise.
873 (struct tdesc_feature): Likewise.
874 * ui-out.h (ui_out_emit_type): Likewise.
875
876 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
877
878 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
879 label abort_expression.
880
881 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
882
883 * common/buffer.c (buffer_xml_printf): Adjust.
884 * common/xml-utils.c (xml_escape_text): Change return type to
885 std::string, update code accordingly.
886 * common/xml-utils.h (xml_escape_text): Change return type to
887 std::string.
888 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
889 * windows-tdep.c (windows_xfer_shared_library): Adjust.
890 * unittests/xml-utils-selftests.c (test_xml_escape_text):
891 Adjust.
892
893 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
894
895 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
896 (SUBDIR_UNITTESTS_OBS): Add new object file.
897 * unittests/xml-utils-selftests.c: New file.
898
899 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
900
901 * common/selftest.h (selftest): New struct/interface.
902 (register_test): Add name parameter, add new overload.
903 (run_tests): Add filter parameter.
904 (for_each_selftest_ftype): New typedef.
905 (for_each_selftest): New declaration.
906 * common/selftest.c (tests): Change type to
907 map<string, unique_ptr<selftest>>.
908 (simple_selftest): New struct.
909 (register_test): New function.
910 (register_test): Add name parameter and use it.
911 (run_tests): Add filter parameter and use it. Add prints.
912 Adjust to vector -> map change.
913 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
914 registering selftests.
915 * arm-tdep.c (_initialize_arm_tdep): Likewise.
916 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
917 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
918 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
919 * findvar.c (_initialize_findvar): Likewise.
920 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
921 * maint.c (maintenance_selftest): Update call to run_tests.
922 (maintenance_info_selftests): New function.
923 (_initialize_maint_cmds): Register "maintenance info selftests"
924 command. Update "maintenance selftest" doc.
925 * regcache.c (_initialize_regcache): Add names when registering
926 selftests.
927 * rust-exp.y (_initialize_rust_exp): Likewise.
928 * selftest-arch.c (gdbarch_selftest): New struct.
929 (gdbarch_tests): Remove.
930 (register_test_foreach_arch): Add name parameter. Call
931 register_test.
932 (tests_with_arch): Remove, move most content to
933 gdbarch_selftest::operator().
934 (_initialize_selftests_foreach_arch): Remove.
935 * selftest-arch.h (register_test_foreach_arch): Add name
936 parameter.
937 (run_tests_with_arch): New declaration.
938 * utils-selftests.c (_initialize_utils_selftests): Add names
939 when registering selftests.
940 * utils.c (_initialize_utils): Likewise.
941 * unittests/array-view-selftests.c
942 (_initialize_array_view_selftests): Likewise.
943 * unittests/environ-selftests.c (_initialize_environ_selftests):
944 Likewise.
945 * unittests/function-view-selftests.c
946 (_initialize_function_view_selftests): Likewise.
947 * unittests/offset-type-selftests.c
948 (_initialize_offset_type_selftests): Likewise.
949 * unittests/optional-selftests.c
950 (_initialize_optional_selftests): Likewise.
951 * unittests/scoped_restore-selftests.c
952 (_initialize_scoped_restore_selftests): Likewise.
953 * NEWS: Document "maintenance selftest" and "maint info
954 selftests".
955
956 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
957
958 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
959 scoped_restore.
960
961 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
962
963 * mi/mi-main.c (mi_load_progress): Make uiout variable
964 a unique_ptr.
965
966 2017-09-15 Pedro Alves <palves@redhat.com>
967
968 * compile/compile-c-types.c (convert_enum, convert_int)
969 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
970
971 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
972
973 * dwarf2read.c (copy_string): Remove.
974 (parse_macro_definition): Replace copy_string with savestring.
975
976 2017-09-15 Yao Qi <yao.qi@linaro.org>
977
978 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
979 gdb_target_obs.
980 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
981 Likewise.
982 (i[34567]86-*-linux*): Likewise.
983
984 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
985
986 * dwarf2expr.h (dwarf_stack_value): Add constructor.
987 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
988 <stack>: Change type to std::vector.
989 <stack_len, stack_allocated>: Remove.
990 <grow_stack>: Remove.
991 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
992 (dwarf_expr_context::~dwarf_expr_context): Remove.
993 (dwarf_expr_context::grow_stack): Remove.
994 (dwarf_expr_context::push): Adjust.
995 (dwarf_expr_context::pop): Adjust.
996 (dwarf_expr_context::fetch): Adjust.
997 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
998 (dwarf_expr_context::stack_empty_p): Adjust.
999 (dwarf_expr_context::execute_stack_op): Adjust.
1000
1001 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1002
1003 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
1004 return type to bool.
1005 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
1006
1007 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1008
1009 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
1010 Change type to bool.
1011 (dwarf_stack_value) <in_stack_memory>: Likewise.
1012 (dwarf_expr_context) <push_address>: Change parameter type to
1013 bool.
1014 <fetch_in_stack_memory>: Change return type to bool.
1015 <push>: Change parameter type to bool.
1016 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
1017 to bool.
1018 (dwarf_expr_context::push_address): Likewise.
1019 (dwarf_expr_context::fetch_in_stack_memory): Change return type
1020 to bool.
1021 (dwarf_expr_context::execute_stack_op): Adjust.
1022 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
1023
1024 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1025
1026 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
1027 (struct dwarf_expr_context) <n_pieces>: Remove.
1028 <pieces>: Change type to std::vector.
1029 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1030 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
1031 pieces.
1032 (dwarf_expr_context::add_piece): Adjust.
1033 * dwarf2loc.c (struct piece_closure): Initialize fields.
1034 <n_pieces>: Remove.
1035 <pieces>: Change type to std::vector.
1036 (allocate_piece_closure): Adjust, change parameter to
1037 std::vector rvalue and std::move it to piece_closure.
1038 (rw_pieced_value): Adjust.
1039 (check_pieced_synthetic_pointer): Adjust.
1040 (indirect_synthetic_pointer): Adjust.
1041 (coerce_pieced_ref): Adjust.
1042 (free_pieced_value_closure): Adjust. Use delete to free
1043 piece_closure.
1044 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
1045 to allocate_piece_closure.
1046 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
1047
1048 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1049
1050 * probe.h (probe_ops_cp): Remove typedef.
1051 (DEF_VEC_P (probe_ops_cp)): Remove.
1052 (all_probe_ops): Change type to std::vector.
1053 * probe.c (info_probes_for_ops): Adjust to vector change.
1054 (probe_linespec_to_ops): Likewise.
1055 (all_probe_ops): Change type to std::vector.
1056 (_initialize_probe): Adjust to vector change.
1057 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
1058 * elfread.c (elf_get_probes): Likewise.
1059 * stap-probe.c (_initialize_stap_probe): Likewise.
1060
1061 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1062
1063 * probe.h (struct bound_probe): Define constructors.
1064 * probe.c (bound_probe_s): Remove typedef.
1065 (DEF_VEC_O (bound_probe_s)): Remove VEC.
1066 (collect_probes): Change return type to std::vector, remove
1067 cleanup.
1068 (compare_probes): Return bool, change parameter type. Change
1069 semantic to "less than".
1070 (gen_ui_out_table_header_info): Change parameter to std::vector
1071 and update.
1072 (exists_probe_with_pops): Likewise.
1073 (info_probes_for_ops): Update to std::vector change.
1074 (enable_probes_command): Likewise.
1075 (disable_probes_command): Likewise.
1076
1077 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1078
1079 * probe.h (struct probe_ops) <get_probes>: Change parameter from
1080 vec to std::vector.
1081 * probe.c (parse_probes_in_pspace): Update.
1082 (find_probes_in_objfile): Update.
1083 (find_probe_by_pc): Update.
1084 (collect_probes): Update.
1085 (probe_any_get_probes): Update.
1086 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
1087 return type to reference to std::vector.
1088 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
1089 std::vector and update.
1090 (dtrace_process_dof): Likewise.
1091 (dtrace_get_probes): Likewise.
1092 * elfread.c (elf_get_probes): Change return type to std::vector,
1093 store an std::vector in bfd_data.
1094 (probe_key_free): Update to std::vector.
1095 * stap-probe.c (handle_stap_probe): Change parameter to
1096 std::vector and update.
1097 (stap_get_probes): Likewise.
1098 * symfile-debug.c (debug_sym_get_probes): Change return type to
1099 std::vector and update.
1100
1101 2017-09-11 Tom Tromey <tom@tromey.com>
1102
1103 * breakpoint.c (program_breakpoint_here_p): Update.
1104 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
1105 from make_show_memory_breakpoints_cleanup. Return a
1106 scoped_restore_tmpl<int>.
1107 (restore_show_memory_breakpoints): Remove.
1108 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
1109 * mem-break.c (memory_validate_breakpoint): Update.
1110 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
1111 (ia64_memory_remove_breakpoint): Update.
1112 (ia64_breakpoint_from_pc): Update.
1113 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
1114 from make_show_memory_breakpoints_cleanup.
1115
1116 2017-09-11 Tom Tromey <tom@tromey.com>
1117
1118 * d-namespace.c (d_lookup_symbol): Use std::string.
1119 (find_symbol_in_baseclass): Likewise.
1120
1121 2017-09-11 Tom Tromey <tom@tromey.com>
1122
1123 * ctf.c (ctf_start): Use std::string.
1124
1125 2017-09-11 Tom Tromey <tom@tromey.com>
1126
1127 * ada-lang.c (is_known_support_routine): Update.
1128 (ada_unhandled_exception_name_addr_from_raise): Update.
1129 * guile/scm-frame.c (gdbscm_frame_name): Update.
1130 * python/py-frame.c (frapy_name): Update.
1131 (frapy_function): Update.
1132 * stack.h (find_frame_funname): Update.
1133 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1134 (print_frame): Update.
1135
1136 2017-09-11 Tom Tromey <tom@tromey.com>
1137
1138 * findcmd.c (put_bits): Take a gdb::byte_vector.
1139 (parse_find_args): Return gdb::byte_vector. "args" now const.
1140 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1141 cleanups.
1142 (find_command): Update.
1143
1144 2017-09-11 Tom Tromey <tom@tromey.com>
1145
1146 * cli/cli-script.c (class scoped_restore_hook_in): New.
1147 (clear_hook_in_cleanup): Remove.
1148 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1149 scoped_restore_hook_in.
1150
1151 2017-09-11 Tom Tromey <tom@tromey.com>
1152
1153 * cli/cli-script.c (restore_interp): Remove.
1154 (read_command_lines): Use scoped_restore_interp.
1155 * interps.c (scoped_restore_interp::set_temp): Rename from
1156 interp_set_temp.
1157 * interps.h (class scoped_restore_interp): New.
1158 (interp_set_temp): Remove.
1159
1160 2017-09-11 Tom Tromey <tom@tromey.com>
1161
1162 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1163 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1164 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1165 scoped_restore.
1166 (mi_cmd_break_insert_1): Update.
1167 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1168 scoped_restore.
1169
1170 2017-09-11 Tom Tromey <tom@tromey.com>
1171
1172 * demangle.c (demangle_command): Update.
1173 * breakpoint.c (disable_command): Update.
1174 (enable_command): Update.
1175 (find_location_by_number): Make "number" const. Use
1176 get_number_trailer.
1177 * cli/cli-utils.c (extract_arg): Return std::string.
1178 * probe.c (parse_probe_linespec): Update. Change types.
1179 (collect_probes): Take string arguments.
1180 (parse_probe_linespec): Likewise.
1181 (info_probes_for_ops): Update.
1182 (enable_probes_command): Update.
1183 (disable_probes_command): Update.
1184 * break-catch-sig.c (catch_signal_split_args): Update.
1185 * mi/mi-parse.c (mi_parse): Update.
1186
1187 2017-09-11 Tom Tromey <tom@tromey.com>
1188
1189 * language.h (language_enum): Make argument const.
1190 * language.c (language_enum): Make argument const.
1191
1192 2017-09-11 Tom Tromey <tom@tromey.com>
1193
1194 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1195 as function.
1196 (skip_to_space): Rename from skip_to_space_const.
1197 * common/common-utils.c (skip_to_space): New function.
1198 (skip_to_space): Rename from skip_to_space_const.
1199 * cli/cli-utils.h (get_number): Rename from get_number_const.
1200 (extract_arg): Rename from extract_arg_const.
1201 * cli/cli-utils.c (get_number): Rename from get_number_const.
1202 (extract_arg): Rename from extract_arg_const.
1203 (number_or_range_parser::get_number): Use ::get_number.
1204 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1205 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1206 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1207 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1208 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1209 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1210 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1211 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1212
1213 2017-09-11 Tom Tromey <tom@tromey.com>
1214
1215 * python/python.c (do_start_initialization): Use
1216 py-event-types.def to initialize types.
1217 Define all object type structures.
1218 * python/python-internal.h: Don't declare event initialization
1219 functions.
1220 * python/py-threadevent.c (thread_event_object_type): Don't
1221 define.
1222 * python/py-stopevent.c (stop_event_object_type): Don't define.
1223 * python/py-signalevent.c (signal_event_object_type): Don't
1224 declare or define.
1225 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1226 (clear_objfiles_event_object_type): Don't declare or define.
1227 * python/py-infevents.c (inferior_call_pre_event_object_type)
1228 (inferior_call_post_event_object_type)
1229 (register_changed_event_object_type)
1230 (memory_changed_event_object_type): Don't declare or define.
1231 * python/py-inferior.c (new_thread_event_object_type)
1232 (new_inferior_event_object_type)
1233 (inferior_deleted_event_object_type): Don't declare or define.
1234 * python/py-exitedevent.c (exited_event_object_type): Don't
1235 declare or define.
1236 * python/py-evts.c (gdbpy_initialize_py_events): Use
1237 py-all-events.def.
1238 * python/py-events.h (thread_event_object_type): Don't declare.
1239 (events_object): Use py-all-events.def.
1240 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1241 py-event-types.def.
1242 * python/py-event-types.def: New file.
1243 * python/py-continueevent.c (create_continue_event_object): Don't
1244 declare or define.
1245 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1246 declare or define.
1247 * python/py-all-events.def: New file.
1248
1249 2017-09-11 Tom Tromey <tom@tromey.com>
1250
1251 * python/py-threadevent.c (create_thread_event_object): Return
1252 gdbpy_ref.
1253 * python/py-stopevent.h (create_stop_event_object)
1254 (create_breakpoint_event_object, create_signal_event_object):
1255 Update.
1256 * python/py-stopevent.c (create_stop_event_object): Return
1257 gdbpy_ref.
1258 (emit_stop_event): Update.
1259 * python/py-signalevent.c (create_signal_event_object): Return
1260 gdbpy_ref.
1261 * python/py-infevents.c (create_inferior_call_event_object):
1262 Update.
1263 * python/py-event.h (create_event_object)
1264 (create_thread_event_object): Update.
1265 * python/py-event.c (create_event_object): Return gdbpy_ref.
1266 * python/py-continueevent.c: Return gdbpy_ref.
1267 * python/py-bpevent.c (create_breakpoint_event_object): Return
1268 gdbpy_ref.
1269
1270 2017-09-11 Tom Tromey <tom@tromey.com>
1271
1272 PR python/15622:
1273 * NEWS: Add entry.
1274 * python/python.c (do_start_initialization): Initialize new event
1275 types.
1276 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1277 (gdbpy_initialize_inferior_deleted_event)
1278 (gdbpy_initialize_new_thread_event): Declare.
1279 * python/py-threadevent.c (create_thread_event_object): Add option
1280 "thread" parameter.
1281 * python/py-inferior.c (new_thread_event_object_type)
1282 (new_inferior_event_object_type)
1283 (inferior_deleted_event_object_type): Declare.
1284 (python_new_inferior, python_inferior_deleted): New functions.
1285 (add_thread_object): Emit new_thread event.
1286 (gdbpy_initialize_inferior): Attach new functions to corresponding
1287 observers.
1288 (new_thread, new_inferior, inferior_deleted): Define new event
1289 types.
1290 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1291 registries.
1292 * python/py-events.h (events_object) <new_inferior,
1293 inferior_deleted, new_thread>: New fields.
1294 * python/py-event.h (create_thread_event_breakpoint): Add optional
1295 "thread" parameter.
1296
1297 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1298
1299 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1300 check current_ui instead.
1301 (internal_vproblem): Likewise.
1302
1303 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1304
1305 * thread.c (print_thread_info_1): Remove unnecessary calls to
1306 uiout->is_mi_like_p.
1307
1308 2017-09-09 Tom Tromey <tom@tromey.com>
1309
1310 * namespace.h (add_using_directive): Update.
1311 * namespace.c (add_using_directive): Change type of excludes to
1312 std::vector.
1313 * dwarf2read.c (read_import_statement): Use std::vector.
1314 (read_namespace): Update.
1315 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1316
1317 2017-09-09 Tom Tromey <tom@tromey.com>
1318
1319 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1320
1321 2017-09-09 Tom Tromey <tom@tromey.com>
1322
1323 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1324
1325 2017-09-09 Tom Tromey <tom@tromey.com>
1326
1327 * stack.c (func_command): Use gdb::def_vector.
1328
1329 2017-09-09 Tom Tromey <tom@tromey.com>
1330
1331 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1332 ui_out_emit_list, ui_out_emit_tuple.
1333 (mi_cmd_var_update): Likewise.
1334
1335 2017-09-09 Tom Tromey <tom@tromey.com>
1336
1337 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1338 ui_out_redirect_pop.
1339 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1340 ui_out_redirect_pop.
1341 * utils.c (do_ui_out_redirect_pop)
1342 (make_cleanup_ui_out_redirect_pop): Remove.
1343 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1344 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1345 * ui-out.h (ui_out_redirect_pop): New class.
1346
1347 2017-09-09 Tom Tromey <tom@tromey.com>
1348
1349 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1350 (list_available_thread_groups, mi_cmd_list_thread_groups)
1351 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1352 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1353 Likewise.
1354
1355 2017-09-09 Tom Tromey <tom@tromey.com>
1356
1357 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1358 ui_out_emit_tuple.
1359
1360 2017-09-09 Tom Tromey <tom@tromey.com>
1361
1362 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1363 * stack.c (print_frame): Use ui_out_emit_tuple.
1364 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1365 (info_spu_mailbox_command, info_spu_dma_command)
1366 (info_spu_proxydma_command): Likewise.
1367 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1368 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1369 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1370 ui_out_emit_tuple.
1371 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1372
1373 2017-09-09 Tom Tromey <tom@tromey.com>
1374
1375 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1376 (class ui_out_emit_table): Update comment.
1377 * ui-out.c (do_cleanup_table_end)
1378 (make_cleanup_ui_out_table_begin_end): Remove.
1379 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1380 (info_spu_dma_cmdlist): Likewise.
1381 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1382 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1383 ui_out_emit_table.
1384
1385 2017-09-09 Tom Tromey <tom@tromey.com>
1386
1387 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1388 ui_out_emit_list, gdb::optional.
1389
1390 2017-09-09 John Baldwin <jhb@FreeBSD.org>
1391
1392 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1393 prototype.
1394 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1395 prototype.
1396 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1397 prototype.
1398 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1399 * ada-exp.y: Remove _initialize_ada_exp prototype.
1400 * ada-lang.c: Remove _initialize_ada_language prototype.
1401 * ada-tasks.c: Remove _initialize_tasks prototype.
1402 * addrmap.c: Remove _initialize_addrmap prototype.
1403 * agent.c: Remove _initialize_agent prototype.
1404 * aix-thread.c: Remove _initialize_aix_thread prototype.
1405 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
1406 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
1407 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
1408 prototype.
1409 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
1410 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
1411 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
1412 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
1413 prototype.
1414 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
1415 prototype.
1416 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
1417 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
1418 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
1419 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
1420 prototype.
1421 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
1422 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
1423 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
1424 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
1425 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1426 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
1427 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
1428 prototype.
1429 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
1430 prototype.
1431 * annotate.c: Remove _initialize_annotate prototype.
1432 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
1433 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
1434 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
1435 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
1436 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
1437 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
1438 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
1439 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
1440 prototype.
1441 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
1442 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
1443 * auto-load.c: Remove _initialize_auto_load prototype.
1444 * auxv.c: Remove _initialize_auxv prototype.
1445 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
1446 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
1447 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
1448 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
1449 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
1450 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
1451 prototype.
1452 * break-catch-throw.c: Remove _initialize_break_catch_throw
1453 prototype.
1454 * breakpoint.c: Remove _initialize_breakpoint prototype.
1455 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
1456 * btrace.c: Remove _initialize_btrace prototype.
1457 * charset.c: Remove _initialize_charset prototype.
1458 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
1459 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
1460 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
1461 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
1462 * cli/cli-script.c: Remove _initialize_cli_script prototype.
1463 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
1464 * coffread.c: Remove _initialize_coffread prototype.
1465 * compile/compile.c: Remove _initialize_compile prototype.
1466 * complaints.c: Remove _initialize_complaints prototype.
1467 * completer.c: Remove _initialize_completer prototype.
1468 * copying.awk: Remove _initialize_copying prototype.
1469 * copying.c: Regenerate.
1470 * core-regset.c: Remove _initialize_core_regset prototype.
1471 * corefile.c: Remove _initialize_core prototype.
1472 * corelow.c: Remove _initialize_corelow prototype.
1473 * cp-abi.c: Remove _initialize_cp_abi prototype.
1474 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
1475 * cp-support.c: Remove _initialize_cp_support prototype.
1476 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
1477 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
1478 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
1479 * ctf.c: Remove _initialize_ctf prototype.
1480 * d-lang.c: Remove _initialize_d_language prototype.
1481 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
1482 prototype.
1483 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
1484 * dbxread.c: Remove _initialize_dbxread prototype.
1485 * dcache.c: Remove _initialize_dcache prototype.
1486 * demangle.c: Remove _initialize_demangler prototype.
1487 * disasm-selftests.c: Remove _initialize_disasm_selftests
1488 prototype.
1489 * disasm.c: Remove _initialize_disasm prototype.
1490 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
1491 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
1492 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
1493 prototype.
1494 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
1495 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
1496 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
1497 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
1498 * elfread.c: Remove _initialize_elfread prototype.
1499 * exec.c: Remove _initialize_exec prototype.
1500 * extension.c: Remove _initialize_extension prototype.
1501 * f-lang.c: Remove _initialize_f_language prototype.
1502 * f-valprint.c: Remove _initialize_f_valprint prototype.
1503 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
1504 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
1505 * filesystem.c: Remove _initialize_filesystem prototype.
1506 * findcmd.c: Remove _initialize_mem_search prototype.
1507 * fork-child.c: Remove _initialize_fork_child prototype.
1508 * frame-base.c: Remove _initialize_frame_base prototype.
1509 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
1510 * frame.c: Remove _initialize_frame prototype.
1511 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
1512 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
1513 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
1514 * gcore.c: Remove _initialize_gcore prototype.
1515 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
1516 * gdbarch.c: Regenerate.
1517 * gdbarch.sh: Remove _initialize_gdbarch prototype.
1518 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
1519 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
1520 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
1521 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
1522 * go-lang.c: Remove _initialize_go_language prototype.
1523 * go32-nat.c: Remove _initialize_go32_nat prototype.
1524 * guile/guile.c: Remove _initialize_guile prototype.
1525 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
1526 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
1527 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
1528 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
1529 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
1530 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
1531 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
1532 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
1533 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
1534 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
1535 prototype.
1536 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
1537 prototype.
1538 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
1539 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
1540 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
1541 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
1542 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
1543 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
1544 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
1545 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
1546 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
1547 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
1548 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
1549 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
1550 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
1551 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1552 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
1553 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
1554 prototype.
1555 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
1556 prototype.
1557 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
1558 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
1559 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
1560 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
1561 * infcall.c: Remove _initialize_infcall prototype.
1562 * infcmd.c: Remove _initialize_infcmd prototype.
1563 * inferior.c: Remove _initialize_inferiors prototype.
1564 * inflow.c: Remove _initialize_inflow prototype.
1565 * infrun.c: Remove _initialize_infrun prototype.
1566 * interps.c: Remove _initialize_interpreter prototype.
1567 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
1568 * jit.c: Remove _initialize_jit prototype.
1569 * language.c: Remove _initialize_language prototype.
1570 * linux-fork.c: Remove _initialize_linux_fork prototype.
1571 * linux-nat.c: Remove _initialize_linux_nat prototype.
1572 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
1573 * linux-thread-db.c: Remove _initialize_thread_db prototype.
1574 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
1575 * m2-lang.c: Remove _initialize_m2_language prototype.
1576 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
1577 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
1578 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
1579 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
1580 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
1581 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1582 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1583 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
1584 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
1585 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
1586 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1587 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1588 * machoread.c: Remove _initialize_machoread prototype.
1589 * macrocmd.c: Remove _initialize_macrocmd prototype.
1590 * macroscope.c: Remove _initialize_macroscope prototype.
1591 * maint.c: Remove _initialize_maint_cmds prototype.
1592 * mdebugread.c: Remove _initialize_mdebugread prototype.
1593 * memattr.c: Remove _initialize_mem prototype.
1594 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
1595 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
1596 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
1597 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
1598 * mi/mi-main.c: Remove _initialize_mi_main prototype.
1599 * microblaze-linux-tdep.c: Remove
1600 _initialize_microblaze_linux_tdep prototype.
1601 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
1602 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
1603 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
1604 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
1605 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
1606 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
1607 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
1608 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
1609 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
1610 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
1611 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
1612 prototype.
1613 * mipsread.c: Remove _initialize_mipsread prototype.
1614 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
1615 prototype.
1616 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
1617 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
1618 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
1619 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
1620 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
1621 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
1622 prototype.
1623 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
1624 * nto-procfs.c: Remove _initialize_procfs prototype.
1625 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
1626 * objc-lang.c: Remove _initialize_objc_language prototype.
1627 * objfiles.c: Remove _initialize_objfiles prototype.
1628 * observer.c: Remove observer_test_first_notification_function,
1629 observer_test_second_notification_function,
1630 observer_test_third_notification_function, and
1631 _initialize_observer prototypes.
1632 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
1633 * osabi.c: Remove _initialize_gdb_osabi prototype.
1634 * osdata.c: Remove _initialize_osdata prototype.
1635 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
1636 * parse.c: Remove _initialize_parse prototype.
1637 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
1638 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
1639 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
1640 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
1641 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
1642 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
1643 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
1644 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
1645 * printcmd.c: Remove _initialize_printcmd prototype.
1646 * probe.c: Remove _initialize_probe prototype.
1647 * proc-api.c: Remove _initialize_proc_api prototype.
1648 * proc-events.c: Remove _initialize_proc_events prototype.
1649 * proc-service.c: Remove _initialize_proc_service prototype.
1650 * procfs.c: Remove _initialize_procfs prototype.
1651 * psymtab.c: Remove _initialize_psymtab prototype.
1652 * python/python.c: Remove _initialize_python prototype.
1653 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
1654 * record-btrace.c: Remove _initialize_record_btrace prototype.
1655 * record-full.c: Remove _initialize_record_full prototype.
1656 * record.c: Remove _initialize_record prototype.
1657 * regcache.c: Remove _initialize_regcache prototype.
1658 * reggroups.c: Remove _initialize_reggroup prototype.
1659 * remote-notif.c: Remove _initialize_notif prototype.
1660 * remote-sim.c: Remove _initialize_remote_sim prototype.
1661 * remote.c: Remove _initialize_remote prototype.
1662 * reverse.c: Remove _initialize_reverse prototype.
1663 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
1664 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
1665 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
1666 prototype.
1667 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
1668 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
1669 * rust-exp.y: Remove _initialize_rust_exp prototype.
1670 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
1671 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
1672 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
1673 * score-tdep.c: Remove _initialize_score_tdep prototype.
1674 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
1675 prototype.
1676 * ser-go32.c: Remove _initialize_ser_dos prototype.
1677 * ser-mingw.c: Remove _initialize_ser_windows prototype.
1678 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
1679 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
1680 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
1681 * serial.c: Remove _initialize_serial prototype.
1682 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
1683 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
1684 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
1685 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
1686 * skip.c: Remove _initialize_step_skip prototype.
1687 * sol-thread.c: Remove _initialize_sol_thread prototype.
1688 * solib-aix.c: Remove _initialize_solib_aix prototype.
1689 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
1690 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
1691 * solib-frv.c: Remove _initialize_frv_solib prototype.
1692 * solib-spu.c: Remove _initialize_spu_solib prototype.
1693 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
1694 * solib-target.c: Remove _initialize_solib_target prototype.
1695 * solib.c: Remove _initialize_solib prototype.
1696 * source.c: Remove _initialize_source prototype.
1697 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
1698 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
1699 prototype.
1700 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
1701 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
1702 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
1703 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
1704 prototype.
1705 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
1706 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
1707 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
1708 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
1709 prototype.
1710 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
1711 prototype.
1712 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
1713 prototype.
1714 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
1715 prototype.
1716 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
1717 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
1718 prototype.
1719 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
1720 prototype.
1721 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
1722 prototype.
1723 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
1724 prototype.
1725 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
1726 prototype.
1727 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
1728 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
1729 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
1730 * stabsread.c: Remove _initialize_stabsread prototype.
1731 * stack.c: Remove _initialize_stack prototype.
1732 * stap-probe.c: Remove _initialize_stap_probe prototype.
1733 * std-regs.c: Remove _initialize_frame_reg prototype.
1734 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
1735 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
1736 * symfile.c: Remove _initialize_symfile prototype.
1737 * symmisc.c: Remove _initialize_symmisc prototype.
1738 * symtab.c: Remove _initialize_symtab prototype.
1739 * target-dcache.c: Remove _initialize_target_dcache prototype.
1740 * target-descriptions.c: Remove _initialize_target_descriptions
1741 prototype.
1742 * thread.c: Remove _initialize_thread prototype.
1743 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
1744 prototype.
1745 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
1746 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
1747 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
1748 prototype.
1749 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
1750 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
1751 * tracefile.c: Remove _initialize_tracefile prototype.
1752 * tracepoint.c: Remove _initialize_tracepoint prototype.
1753 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
1754 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
1755 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
1756 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
1757 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
1758 * tui/tui-win.c: Remove _initialize_tui_win prototype.
1759 * tui/tui.c: Remove _initialize_tui prototype.
1760 * typeprint.c: Remove _initialize_typeprint prototype.
1761 * user-regs.c: Remove _initialize_user_regs prototype.
1762 * utils.c: Remove _initialize_utils prototype.
1763 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
1764 * valarith.c: Remove _initialize_valarith prototype.
1765 * valops.c: Remove _initialize_valops prototype.
1766 * valprint.c: Remove _initialize_valprint prototype.
1767 * value.c: Remove _initialize_values prototype.
1768 * varobj.c: Remove _initialize_varobj prototype.
1769 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
1770 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
1771 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
1772 * windows-nat.c: Remove _initialize_windows_nat,
1773 _initialize_check_for_gdb_ini, and _initialize_loadable
1774 prototypes.
1775 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
1776 * xcoffread.c: Remove _initialize_xcoffread prototype.
1777 * xml-support.c: Remove _initialize_xml_support prototype.
1778 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
1779 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
1780 prototype.
1781 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
1782 prototype.
1783 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
1784
1785 2017-09-08 Keith Seitz <keiths@redhat.com>
1786
1787 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
1788 field.
1789
1790 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
1791
1792 * f-valprint.c (f_val_print): Remove check for one byte
1793 sized integers. Remove printing of character type.
1794
1795 2017-09-08 Frank Penczek <frank.penczek@intel.com>
1796 Christoph Weinmann <christoph.t.weinmann@intel.com>
1797 Bernhard Heckel <bernhard.heckel@intel.com>
1798
1799 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
1800 to maintain proper indentation when printing pointers/refs.
1801
1802 2017-09-07 Joel Brobecker <brobecker@adacore.com>
1803
1804 GDB 8.0.1 released.
1805
1806 2017-09-07 Joel Brobecker <brobecker@adacore.com>
1807
1808 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
1809
1810 2017-09-05 Tom Tromey <tom@tromey.com>
1811
1812 * parse.c (funcall_chain): Now a std::vector.
1813 (start_arglist, end_arglist): Simplify.
1814 (free_funcalls): Remove.
1815 (parse_exp_in_context_1): Remove cleanup.
1816
1817 2017-09-05 Tom Tromey <tom@tromey.com>
1818
1819 * go-exp.y (go_parse): Don't create a cleanup.
1820
1821 2017-09-05 Tom Tromey <tom@tromey.com>
1822
1823 * d-exp.y (PrimaryExpression): Use std::string.
1824 (d_parse): Don't create a cleanup.
1825
1826 2017-09-05 Tom Tromey <tom@tromey.com>
1827
1828 * utils.c (do_clear_parser_state): Remove.
1829 (make_cleanup_clear_parser_state): Remove.
1830 * p-exp.y (pascal_parse): Use scoped_restore.
1831 * m2-exp.y (m2_parse): Use scoped_restore.
1832 * f-exp.y (f_parse): Use scoped_restore.
1833 * d-exp.y (d_parse): Use scoped_restore.
1834 * c-exp.y (c_parse): Use scoped_restore.
1835 * ada-exp.y (ada_parse): Use scoped_restore.
1836 * utils.h (make_cleanup_clear_parser_state): Remove.
1837
1838 2017-09-06 Keith Seitz <keiths@redhat.com>
1839
1840 * dwarf2read.c (dw2_linkage_name_attr): New function.
1841 (dw2_linkage_name): New function.
1842 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
1843 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
1844 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
1845
1846 2017-09-06 Kamil Rytarowski <n54@gmx.com>
1847
1848 * config/djgpp/djconfig.sh: Correct shell portability issue.
1849
1850 2017-09-06 Kamil Rytarowski <n54@gmx.com>
1851
1852 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
1853
1854 2017-09-06 John Baldwin <jhb@FreeBSD.org>
1855
1856 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
1857 * NEWS: Mention new FreeBSD/mips native configuration.
1858 * configure.host: Add aarch64*-*-freebsd*.
1859 * configure.nat: Likewise.
1860 * aarch64-fbsd-nat.c: New file.
1861
1862 2017-09-06 John Baldwin <jhb@FreeBSD.org>
1863
1864 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
1865 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
1866 * NEWS: Mention new FreeBSD/aarch64 target.
1867 * configure.tgt: Add aarch64*-*-freebsd*.
1868 * aarch64-fbsd-tdep.c: New file.
1869 * aarch64-fbsd-tdep.h: New file.
1870
1871 2017-09-06 Kamil Rytarowski <n54@gmx.com>
1872
1873 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
1874
1875 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
1876
1877 * parse.c (find_minsym_type_and_address): Don't relocate addresses
1878 of TLS symbols.
1879
1880 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1881
1882 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
1883 call.
1884
1885 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1886
1887 * infrun.c (follow_exec): Call add_thread after
1888 target_find_description.
1889
1890 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1891
1892 * infrun.c (handle_inferior_event_1): When exec'ing, read
1893 stop_pc after follow_exec.
1894
1895 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1896
1897 * remote.c (process_g_packet): Update error message.
1898
1899 2017-09-05 Yao Qi <yao.qi@linaro.org>
1900
1901 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
1902 targets.
1903
1904 2017-09-05 Pedro Alves <palves@redhat.com>
1905
1906 * eval.c (eval_call, evaluate_funcall): New functions, factored
1907 out from ...
1908 (evaluate_subexp_standard): ... this.
1909
1910 2017-09-05 Yao Qi <yao.qi@linaro.org>
1911
1912 * amd64-tdep.c (amd64_target_description): Create target
1913 descriptions.
1914 (_initialize_amd64_tdep): Don't call functions
1915 initialize_tdesc_amd64_*. Add self tests.
1916 * arch/amd64.c (amd64_create_target_description): Add parameter
1917 is_linux. Call set_tdesc_osabi if is_linux is true.
1918 * arch/amd64.h (amd64_create_target_description): Update the
1919 declaration.
1920 * arch/i386.c (i386_create_target_description): Add parameter
1921 is_linux. Call set_tdesc_osabi if is_linux is true.
1922 * arch/i386.h (i386_create_target_description): Update
1923 declaration.
1924 * configure.tgt: Add i386.o to gdb_target_obs.
1925 * features/Makefile (XMLTOC): Remove i386/*.xml.
1926 * features/i386/amd64-avx-avx512.c: Remove.
1927 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
1928 * features/i386/amd64-avx-mpx.c: Remove.
1929 * features/i386/amd64-avx.c: Remove.
1930 * features/i386/amd64-mpx.c: Remove.
1931 * features/i386/amd64.c: Remove.
1932 * features/i386/i386-avx-avx512.c: Remove.
1933 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
1934 * features/i386/i386-avx-mpx.c: Remove.
1935 * features/i386/i386-avx.c: Remove.
1936 * features/i386/i386-mmx.c: Remove.
1937 * features/i386/i386-mpx.c: Remove.
1938 * features/i386/i386.c: Remove.
1939 * i386-tdep.c: Don't include features/i386/i386*.c., include
1940 target-descriptions.h and arch/i386.h.
1941 (i386_target_description): Create target descriptions.
1942 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
1943 functions. Do self tests.
1944
1945 2017-09-05 Yao Qi <yao.qi@linaro.org>
1946
1947 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
1948 * features/i386/amd64-avx-avx512-linux.c: Removed.
1949 * features/i386/amd64-avx-linux.c: Removed.
1950 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
1951 * features/i386/amd64-avx-mpx-linux.c: Removed.
1952 * features/i386/amd64-linux.c: Removed.
1953 * features/i386/amd64-mpx-linux.c: Removed.
1954 * features/i386/x32-avx-avx512-linux.c: Removed.
1955 * features/i386/x32-avx-linux.c: Removed.
1956 * features/i386/x32-linux.c: Removed.
1957
1958 2017-09-05 Yao Qi <yao.qi@linaro.org>
1959
1960 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
1961 features/i386/*.c.
1962 (amd64_linux_read_description): Call
1963 amd64_create_target_description.
1964 * arch/amd64.c: New file.
1965 * arch/amd64.h: New file.
1966 * configure.tgt (x86_64-*-linux*): Append amd64.o.
1967 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
1968
1969 2017-09-05 Yao Qi <yao.qi@linaro.org>
1970
1971 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
1972 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
1973 (amd64_linux_read_description): Create target descriptions.
1974 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
1975 functions. Add unit tests.
1976 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
1977 x32-core.xml.
1978 * features/i386/64bit-avx.c: Generated.
1979 * features/i386/64bit-avx512.c: Generated.
1980 * features/i386/64bit-core.c: Generated.
1981 * features/i386/64bit-linux.c: Generated.
1982 * features/i386/64bit-mpx.c: Generated.
1983 * features/i386/64bit-pkeys.c: Generated.
1984 * features/i386/64bit-segments.c: Generated.
1985 * features/i386/64bit-sse.c: Generated.
1986 * features/i386/x32-core.c: Generated.
1987 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
1988 c files for amd64-linux and x32-linux.
1989
1990 2017-09-05 Yao Qi <yao.qi@linaro.org>
1991
1992 * amd64-linux-tdep.c (amd64_linux_read_description): New
1993 function.
1994 (amd64_linux_core_read_description): Call
1995 amd64_linux_read_description.
1996 (amd64_linux_init_abi): Likewise.
1997 (amd64_x32_linux_init_abi): Likewise.
1998 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
1999 * x86-linux-nat.c (x86_linux_read_description): Call
2000 amd64_linux_read_description.
2001
2002 2017-09-05 Yao Qi <yao.qi@linaro.org>
2003
2004 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
2005 comments.
2006
2007 2017-09-05 Yao Qi <yao.qi@linaro.org>
2008
2009 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
2010 * features/i386/i386-avx-avx512-linux.c: Remove.
2011 * features/i386/i386-avx-linux.c: Remove.
2012 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
2013 * features/i386/i386-avx-mpx-linux.c: Remove.
2014 * features/i386/i386-linux.c: Remove.
2015 * features/i386/i386-mmx-linux.c: Remove.
2016 * features/i386/i386-mpx-linux.c: Remove.
2017
2018 2017-09-05 Yao Qi <yao.qi@linaro.org>
2019
2020 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
2021 (SFILES): Add arch/i386.c.
2022 (HFILES_NO_SRCDIR): Add arch/i386.h.
2023 * arch/i386.c: New file.
2024 * arch/i386.h: New file.
2025 * arch/tdesc.h (allocate_target_description): Declare.
2026 (set_tdesc_architecture): Declare.
2027 (set_tdesc_osabi): Declare.
2028 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
2029 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
2030 include arch/i386.h.
2031 (i386_linux_read_description): Remove code and call
2032 i386_create_target_description.
2033 (set_tdesc_architecture): New function.
2034 (set_tdesc_osabi): New function.
2035 * target-descriptions.h (allocate_target_description): Remove.
2036
2037 2017-09-05 Yao Qi <yao.qi@linaro.org>
2038
2039 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
2040 * target-descriptions.c (tdesc_create_feature): Likewise, and
2041 adjust code.
2042 * features/i386/32bit-avx.c: Re-generated.
2043 * features/i386/32bit-avx512.c: Re-generated.
2044 * features/i386/32bit-core.c: Re-generated.
2045 * features/i386/32bit-linux.c: Re-generated.
2046 * features/i386/32bit-mpx.c: Re-generated.
2047 * features/i386/32bit-pkeys.c: Re-generated.
2048 * features/i386/32bit-sse.c: Re-generated.
2049
2050 2017-09-05 Yao Qi <yao.qi@linaro.org>
2051
2052 * regformats/regdef.h (struct reg): Override operator == and !=.
2053
2054 2017-09-05 Yao Qi <yao.qi@linaro.org>
2055
2056 * arch/tdesc.h: New file.
2057 * regformats/regdat.sh: Generate code using tdesc_create_reg.
2058 * target-descriptions.c: Update comments.
2059 * target-descriptions.h: Include "arch/tdesc.h". Remove the
2060 declarations.
2061 * features/i386/32bit-avx.c: Re-generated.
2062 * features/i386/32bit-avx512.c: Re-generated.
2063 * features/i386/32bit-core.c: Re-generated.
2064 * features/i386/32bit-linux.c: Re-generated.
2065 * features/i386/32bit-mpx.c: Re-generated.
2066 * features/i386/32bit-pkeys.c: Re-generated.
2067 * features/i386/32bit-sse.c: Re-generated.
2068
2069 2017-09-05 Yao Qi <yao.qi@linaro.org>
2070
2071 * regformats/regdat.sh: Update generated code.
2072
2073 2017-09-05 Yao Qi <yao.qi@linaro.org>
2074
2075 * regformats/regdat.sh: Adjust code order.
2076
2077 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2078
2079 * expprint.c (dump_subexp_body_standard): Use constant format
2080 string in fprintf_filtered call.
2081
2082 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2083
2084 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
2085 NetBSD/i386.
2086 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
2087
2088 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2089
2090 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
2091
2092 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2093
2094 * bsd-kvm.o: Define _KMEMUSER.
2095 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
2096 * configure: Regenerate.
2097
2098 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2099
2100 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
2101 * i386-fbsd-nat.c: Likewise.
2102
2103 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2104
2105 * unittests/array-view-selftests.c: Add include of <array>.
2106
2107 2017-09-04 John Baldwin <jhb@FreeBSD.org>
2108
2109 * spu-tdep.c (flush_ea_cache): Add missing argument to
2110 call_function_by_hand.
2111
2112 2017-09-04 Pedro Alves <palves@redhat.com>
2113
2114 * NEWS (Safer support for debugging with no debug info): New.
2115
2116 2017-09-04 Pedro Alves <palves@redhat.com>
2117
2118 * c-exp.y (function_method, function_method_void): Add current
2119 instance flags to TYPE_INSTANCE.
2120 * dwarf2read.c (check_modifier): New.
2121 (compute_delayed_physnames): Assert that only C++ adds delayed
2122 physnames. Mark fn_fields as const/volatile depending on
2123 physname.
2124 * eval.c (make_params): New type_instance_flags parameter. Use
2125 it as the new type's instance flags.
2126 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2127 flags element and pass it to make_params.
2128 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2129 instance flags element.
2130 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2131 * gdbtypes.h: Include "enum-flags.h".
2132 (type_instance_flags): New enum-flags type.
2133 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2134 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2135 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2136 (follow_type_instance_flags): New function.
2137 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2138 * parser-defs.h (follow_type_instance_flags): Declare.
2139 * valops.c (value_struct_elt_for_reference): const/volatile must
2140 match too.
2141
2142 2017-09-04 Pedro Alves <palves@redhat.com>
2143
2144 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2145 function/method scopes; lookup the nested name as a function local
2146 static variable.
2147
2148 2017-09-04 Pedro Alves <palves@redhat.com>
2149
2150 (%type <voidval>): Add function_method.
2151 * c-exp.y (exp): New production for calls with no arguments.
2152 (function_method, function_method_void_or_typelist): New
2153 productions.
2154 (exp): New production for "method()::static_var".
2155 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2156 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2157 Handle OP_FUNC_STATIC_VAR.
2158 * parse.c (operator_length_standard):
2159 Handle OP_FUNC_STATIC_VAR.
2160
2161 2017-09-04 Pedro Alves <palves@redhat.com>
2162
2163 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2164 handling.
2165 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2166 Ditto.
2167 * parse.c (operator_length_standard, operator_check_standard):
2168 Ditto.
2169 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2170
2171 2017-09-04 Pedro Alves <palves@redhat.com>
2172
2173 * ax-gdb.c: Include "typeprint.h".
2174 (gen_expr_for_cast): New function.
2175 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2176 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2177 type is unknown.
2178 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2179 nodebug_data_symbol.
2180 * eval.c: Include "typeprint.h".
2181 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2182 Error out if symbol has unknown type.
2183 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2184 evaluate_subexp_for_cast.
2185 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2186 OP_VAR_MSYM_VALUE.
2187 (evaluate_subexp_for_cast): New function.
2188 * gdbtypes.c (init_nodebug_var_type): New function.
2189 (objfile_type): Use it to initialize types of variables with no
2190 debug info.
2191 * typeprint.c (error_unknown_type): New.
2192 * typeprint.h (error_unknown_type): New declaration.
2193 * compile/compile-c-types.c (convert_type_basic): Handle
2194 TYPE_CODE_ERROR; warn and fallback to int for variables with
2195 unknown type.
2196
2197 2017-09-04 Pedro Alves <palves@redhat.com>
2198
2199 * eval.c (evaluate_var_value): New function, factored out from ...
2200 (evaluate_subexp_standard): ... here.
2201
2202 2017-09-04 Pedro Alves <palves@redhat.com>
2203
2204 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2205 Remove useless assignments to 'op'.
2206
2207 2017-09-04 Pedro Alves <palves@redhat.com>
2208
2209 * eval.c (eval_skip_value): New function.
2210 (evaluate_subexp_standard): Use it.
2211
2212 2017-09-04 Pedro Alves <palves@redhat.com>
2213
2214 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2215 function name from symbol/minsym and pass it to
2216 error_call_unknown_return_type.
2217
2218 2017-09-04 Pedro Alves <palves@redhat.com>
2219
2220 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2221 * ax-gdb.c (gen_msym_var_ref): New function.
2222 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2223 * eval.c (evaluate_var_msym_value): New function.
2224 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2225 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2226 to call_function_by_hand.
2227 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2228 Handle OP_VAR_MSYM_VALUE.
2229 (union exp_element) <msymbol>: New field.
2230 * minsyms.h (struct type): Forward declare.
2231 (find_minsym_type_and_address): Declare.
2232 * parse.c (write_exp_elt_msym): New function.
2233 (write_exp_msymbol): Delete, refactored as ...
2234 (find_minsym_type_and_address): ... this new function.
2235 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2236 (operator_length_standard, operator_check_standard): Handle
2237 OP_VAR_MSYM_VALUE.
2238 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2239
2240 2017-09-04 Pedro Alves <palves@redhat.com>
2241
2242 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2243 TYPE_GNU_IFUNC specially here. Throw error if return type is
2244 unknown.
2245 * ada-typeprint.c (print_func_type): Handle functions with unknown
2246 return type.
2247 * c-typeprint.c (c_type_print_base): Handle functions and methods
2248 with unknown return type.
2249 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2250 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2251 * compile/compile-c-types.c: Include "objfiles.h".
2252 (convert_func): For functions with unknown return type, warn and
2253 default to int.
2254 * compile/compile-object-run.c (compile_object_run): Adjust call
2255 to call_function_by_hand_dummy.
2256 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2257 call_function_by_hand.
2258 * eval.c (evaluate_subexp_standard): Adjust calls to
2259 call_function_by_hand. Handle functions and methods with unknown
2260 return type. Pass expect_type to call_function_by_hand.
2261 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2262 return type.
2263 * gcore.c (call_target_sbrk): Adjust call to
2264 call_function_by_hand.
2265 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2266 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2267 an integer address type instead of nodebug.
2268 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2269 call_function_by_hand.
2270 * infcall.c (error_call_unknown_return_type): New function.
2271 (call_function_by_hand): New "default_return_type" parameter.
2272 Pass it down.
2273 (call_function_by_hand_dummy): New "default_return_type"
2274 parameter. Use it instead of defaulting to int. If there's no
2275 default and the return type is unknown, throw an error. If
2276 there's a default return type, and the called function has no
2277 debug info, then assume the function is prototyped.
2278 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2279 New "default_return_type" parameter.
2280 (error_call_unknown_return_type): New declaration.
2281 * linux-fork.c (call_lseek): Cast return type of lseek.
2282 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2283 call_function_by_hand.
2284 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2285 calls to call_function_by_hand.
2286 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2287 return type.
2288 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2289 (value_nsstring, print_object_command): Adjust calls to
2290 call_function_by_hand.
2291 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2292 functions with unknown return type.
2293 (pascal_type_print_func_varspec_suffix): New function.
2294 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2295 TYPE_CODE_METHOD>: Use it.
2296 * python/py-value.c (valpy_call): Adjust call to
2297 call_function_by_hand.
2298 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2299 call_function_by_hand.
2300 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2301 call_function_by_hand.
2302 * valops.c (value_allocate_space_in_inferior): Adjust call to
2303 call_function_by_hand.
2304 * typeprint.c (type_print_unknown_return_type): New function.
2305 * typeprint.h (type_print_unknown_return_type): New declaration.
2306
2307 2017-09-04 Pedro Alves <palves@redhat.com>
2308
2309 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2310 types with more than one parameter as prototyped.
2311
2312 2017-09-04 Pedro Alves <palves@redhat.com>
2313
2314 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2315 (disassemble_command): Use gdb_disassembly_flags instead of bare
2316 int.
2317 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2318 (dump_insns, do_mixed_source_and_assembly_deprecated)
2319 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2320 Use gdb_disassembly_flags instead of bare int.
2321 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2322 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2323 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2324 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2325 (enum gdb_disassembly_flag): ... values of this new enumeration.
2326 (gdb_disassembly_flags): Define.
2327 (gdb_disassembly)
2328 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2329 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2330 gdb_disassembly_flags instead of bare int.
2331 * record-btrace.c (btrace_insn_history)
2332 (record_btrace_insn_history, record_btrace_insn_history_range)
2333 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2334 instead of bare int.
2335 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2336 Use gdb_disassembly_flags instead of bare int.
2337 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2338 Define.
2339 * target-delegates.c: Regenerate.
2340 * target.c (target_insn_history, target_insn_history_from)
2341 (target_insn_history_range): Use gdb_disassembly_flags instead of
2342 bare int.
2343 * target.h: Include "disasm.h".
2344 (struct target_ops) <to_insn_history, to_insn_history_from,
2345 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2346 int.
2347 (target_insn_history, target_insn_history_from)
2348 (target_insn_history_range): Use gdb_disassembly_flags instead of
2349 bare int.
2350
2351 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2352
2353 * cli/cli-script.c (build_command_line): For if/while commands,
2354 check whether args is empty.
2355
2356 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2357
2358 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2359 (enum command_control_type): Likewise.
2360 (struct command_line): Likewise.
2361 (free_command_lines): Likewise.
2362 (struct command_lines_deleter): Likewise.
2363 (command_line_up): Likewise.
2364 (read_command_lines): Likewise.
2365 (read_command_lines_1): Likewise.
2366 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2367 (enum command_control_type): Likewise.
2368 (struct command_line): Likewise.
2369 (free_command_lines): Likewise.
2370 (struct command_lines_deleter): Likewise.
2371 (command_line_up): Likewise.
2372 (read_command_lines): Likewise.
2373 (read_command_lines_1): Likewise.
2374 * breakpoint.h: Include cli/cli-script.h.
2375 * extension-priv.h: Likewise.
2376 * gdbcmd.h: Likewise.
2377
2378 2017-09-04 Pedro Alves <palves@redhat.com>
2379
2380 * ada-lang.c (is_known_support_routine): Move sal declaration to
2381 where it is initialized.
2382 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2383 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2384 (clear_command, update_static_tracepoint): Remove init_sal
2385 references. Move declarations closer to initializations.
2386 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2387 initializations.
2388 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2389 references. Move sal declarations closer to initializations.
2390 * frame.c (find_frame_sal): Return a symtab_and_line via function
2391 return instead of output parameter. Remove init_sal references.
2392 * frame.h (find_frame_sal): Return a symtab_and_line via function
2393 return instead of output parameter.
2394 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2395 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2396 instead of memset.
2397 (gdbscm_find_pc_line): Remove init_sal reference.
2398 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2399 references. Move declarations closer to initializations.
2400 * infcmd.c (set_step_frame): Update. Move declarations closer to
2401 initializations.
2402 (finish_backward): Remove init_sal references. Move declarations
2403 closer to initializations.
2404 * infrun.c (process_event_stop_test, handle_step_into_function)
2405 (insert_hp_step_resume_breakpoint_at_frame)
2406 (insert_step_resume_breakpoint_at_caller): Likewise.
2407 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
2408 (symbol_to_sal): Likewise.
2409 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
2410 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
2411 to its initialization.
2412 * reverse.c (save_bookmark_command): Use new/delete. Remove
2413 init_sal references. Move declarations closer to initializations.
2414 * source.c (get_current_source_symtab_and_line): Remove brace
2415 initialization.
2416 (set_current_source_symtab_and_line): Now takes the sal by const
2417 reference. Remove brace initialization.
2418 (line_info): Remove init_sal reference.
2419 * source.h (set_current_source_symtab_and_line): Now takes a
2420 symtab_and_line via const reference.
2421 * stack.c (set_current_sal_from_frame): Adjust.
2422 (print_frame_info): Adjust.
2423 (get_last_displayed_sal): Return the sal via function return
2424 instead of via output parameter. Simplify.
2425 (frame_info): Adjust.
2426 * stack.h (get_last_displayed_sal): Return the sal via function
2427 return instead of via output parameter.
2428 * symtab.c (init_sal): Delete.
2429 (find_pc_sect_line): Remove init_sal references. Move
2430 declarations closer to initializations.
2431 (find_function_start_sal): Remove init_sal references. Move
2432 declarations closer to initializations.
2433 * symtab.h (struct symtab_and_line): In-class initialize all
2434 fields.
2435 * tracepoint.c (set_traceframe_context)
2436 (print_one_static_tracepoint_marker): Remove init_sal references.
2437 Move declarations closer to initializations.
2438 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
2439 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
2440 declarations closer to initializations.
2441 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
2442 init_sal references. Adjust.
2443
2444 2017-09-04 Pedro Alves <palves@redhat.com>
2445
2446 * ax-gdb.c (agent_command_1): Use range-for.
2447 * break-catch-throw.c (re_set_exception_catchpoint): Update.
2448 * breakpoint.c: Include "common/array-view.h".
2449 (init_breakpoint_sal, create_breakpoint_sal): Change sals
2450 parameter from struct symtabs_and_lines to
2451 array_view<symtab_and_line>. Adjust. Use range-for. Update.
2452 (breakpoint_sals_to_pc): Change sals parameter from struct
2453 symtabs_and_lines to std::vector reference.
2454 (check_fast_tracepoint_sals): Change sals parameter from struct
2455 symtabs_and_lines to std::array_view. Use range-for.
2456 (decode_static_tracepoint_spec): Return a std::vector instead of
2457 symtabs_and_lines. Update.
2458 (create_breakpoint): Update.
2459 (break_range_command, until_break_command, clear_command): Update.
2460 (base_breakpoint_decode_location, bkpt_decode_location)
2461 (bkpt_probe_create_sals_from_location)
2462 (bkpt_probe_decode_location, tracepoint_decode_location)
2463 (tracepoint_probe_decode_location)
2464 (strace_marker_create_sals_from_location): Return a std::vector
2465 instead of symtabs_and_lines.
2466 (strace_marker_create_breakpoints_sal): Update.
2467 (strace_marker_decode_location): Return a std::vector instead of
2468 symtabs_and_lines. Update.
2469 (update_breakpoint_locations): Change struct symtabs_and_lines
2470 parameters to gdb::array_view. Adjust.
2471 (location_to_sals): Return a std::vector instead of
2472 symtabs_and_lines. Update.
2473 (breakpoint_re_set_default): Use std::vector instead of struct
2474 symtabs_and_lines.
2475 (decode_location_default): Return a std::vector instead of
2476 symtabs_and_lines. Update.
2477 * breakpoint.h: Include "common/array-view.h".
2478 (struct breakpoint_ops) <decode_location>: Now returns a
2479 std::vector instead of returning a symtabs_and_lines via output
2480 parameter.
2481 (update_breakpoint_locations): Change sals parameters to use
2482 gdb::array_view.
2483 * cli/cli-cmds.c (edit_command, list_command): Update to use
2484 std::vector and gdb::array_view.
2485 (ambiguous_line_spec): Adjust to use gdb::array_view and
2486 range-for.
2487 (compare_symtabs): Rename to ...
2488 (cmp_symtabs): ... this. Change parameters to symtab_and_line
2489 const reference and adjust.
2490 (filter_sals): Rewrite using std::vector and standard algorithms.
2491 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
2492 (jump_command): Update to use std::vector.
2493 * linespec.c (struct linespec_state) <canonical_names>: Update
2494 comment.
2495 (add_sal_to_sals_basic): Delete.
2496 (add_sal_to_sals, filter_results, convert_results_to_lsals)
2497 (decode_line_2, create_sals_line_offset)
2498 (convert_address_location_to_sals, convert_linespec_to_sals)
2499 (convert_explicit_location_to_sals, parse_linespec)
2500 (event_location_to_sals, decode_line_full, decode_line_1)
2501 (decode_line_with_current_source)
2502 (decode_line_with_last_displayed, decode_objc)
2503 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
2504 (linespec_result::~linespec_result): Adjust to use std::vector
2505 instead of symtabs_and_lines.
2506 * linespec.h (linespec_sals::sals): Now a std::vector.
2507 (struct linespec_result): Use std::vector, bool, and in-class
2508 initialization.
2509 (decode_line_1, decode_line_with_current_source)
2510 (decode_line_with_last_displayed): Return std::vector.
2511 * macrocmd.c (info_macros_command): Use std::vector.
2512 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
2513 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
2514 std::vector.
2515 * probe.h (parse_probes): Return a std::vector.
2516 * python/python.c (gdbpy_decode_line): Use std::vector and
2517 gdb::array_view.
2518 * source.c (select_source_symtab, line_info): Use std::vector.
2519 * stack.c (func_command): Use std::vector.
2520 * symtab.h (struct symtabs_and_lines): Delete.
2521 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
2522
2523 2017-09-04 Pedro Alves <palves@redhat.com>
2524
2525 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2526 unittests/array-view-selftests.c.
2527 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
2528 * common/array-view.h: New file.
2529 * unittests/array-view-selftests.c: New file.
2530
2531 2017-09-04 Pedro Alves <palves@redhat.com>
2532
2533 * cli/cli-cmds.c (edit_command): Pass message to
2534 ambiguous_line_spec.
2535 (list_command): Pass message to ambiguous_line_spec. Say
2536 "first"/"last" instead of "start" and "end" to be consistent with
2537 the manual.
2538 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
2539 them to print formatted message.
2540
2541 2017-09-04 Pedro Alves <palves@redhat.com>
2542
2543 * btrace.c (ftrace_add_pt): Pass btrace_insn to
2544 ftrace_update_insns by reference instead of pointer.
2545
2546 2017-09-04 Yao Qi <yao.qi@linaro.org>
2547
2548 * i386-go32-tdep.c: Include x86-xstate.h.
2549 (i386_go32_init_abi): Call i386_target_description.
2550 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
2551 if xcr0 is X86_XSTATE_X87_MASK.
2552 * i386-tdep.h (tdesc_i386): Remove the declaration.
2553 (tdesc_i386_mmx): Likewise.
2554
2555 2017-09-04 Yao Qi <yao.qi@linaro.org>
2556
2557 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
2558 X86_XSTATE_SSE_MASK instead of 0.
2559
2560 2017-09-04 Yao Qi <yao.qi@linaro.org>
2561
2562 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
2563 i386_target_description.
2564 * i386-fbsd-nat.c (i386fbsd_read_description): Call
2565 i386_target_description.
2566 * i386-tdep.c (i386_gdbarch_init): Likewise.
2567
2568 2017-09-04 Yao Qi <yao.qi@linaro.org>
2569
2570 * amd64-darwin-tdep.c: Include "x86-xstate.h".
2571 (x86_darwin_init_abi_64): Call amd64_target_description.
2572 * amd64-dicos-tdep.c: Likewise.
2573 * amd64-fbsd-nat.c: Likewise.
2574 * amd64-fbsd-tdep.c: Likewise.
2575 * amd64-nbsd-tdep.c: Likewise.
2576 * amd64-obsd-tdep.c: Likewise.
2577 * amd64-sol2-tdep.c: Likewise.
2578 * amd64-windows-tdep.c: Likewise.
2579 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
2580
2581 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2582
2583 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
2584 (btrace_function) <insn>: Change type to use std::vector.
2585 * btrace.c (ftrace_debug, ftrace_call_num_insn,
2586 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
2587 ftrace_update_insns, ftrace_compute_global_level_offset,
2588 btrace_stitch_bts, btrace_clear, btrace_insn_get,
2589 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
2590 change to std::vector.
2591 (ftrace_update_insns): Adjust to change to std::vector, change
2592 type of INSN parameter.
2593 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
2594 * record-btrace.c (btrace_call_history_insn_range,
2595 btrace_compute_src_line_range,
2596 record_btrace_frame_prev_register): Adjust to change to
2597 std::vector.
2598 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
2599 to change to std::vector.
2600
2601 2017-09-03 Tom Tromey <tom@tromey.com>
2602
2603 * corefile.c (reopen_exec_file): Use std::string.
2604
2605 2017-09-03 Tom Tromey <tom@tromey.com>
2606
2607 * compile/compile.c (compile_register_name_mangled): Return
2608 std::string.
2609 * compile/compile-loc2c.c (pushf_register_address): Update.
2610 (pushf_register): Update.
2611 * compile/compile-c-types.c (convert_array): Update.
2612 * compile/compile-c-symbols.c (generate_vla_size): Update.
2613 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
2614 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
2615 (convert_one_symbol): Update.
2616 (generate_c_for_for_one_variable): Update.
2617 * compile/compile-c-support.c (c_get_range_decl_name): Return a
2618 std::string.
2619 (generate_register_struct): Update.
2620 * compile/compile-internal.h (c_get_range_decl_name): Return a
2621 std::string.
2622 (compile_register_name_mangled): Return std::string.
2623
2624 2017-09-03 Tom Tromey <tom@tromey.com>
2625
2626 * utils.c (perror_string): Return a std::string.
2627 (throw_perror_with_name, perror_warning_with_name): Update.
2628
2629 2017-09-03 Tom Tromey <tom@tromey.com>
2630
2631 * demangle.c (demangle_command): Use std::string,
2632 unique_xmalloc_ptr.
2633
2634 2017-09-03 Tom Tromey <tom@tromey.com>
2635
2636 * cli/cli-setshow.c (do_set_command): Use std::string.
2637
2638 2017-09-03 Tom Tromey <tom@tromey.com>
2639
2640 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
2641
2642 2017-09-03 Tom Tromey <tom@tromey.com>
2643
2644 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
2645
2646 2017-09-03 Tom Tromey <tom@tromey.com>
2647
2648 * mi/mi-cmd-env.c (env_execute_cli_command): Use
2649 gdb::unique_xmalloc_ptr.
2650
2651 2017-09-03 Tom Tromey <tom@tromey.com>
2652
2653 * thread.c (print_thread_info_1): Use string_printf.
2654 (thread_apply_command, thread_apply_all_command): Use
2655 std::string.
2656
2657 2017-09-03 Tom Tromey <tom@tromey.com>
2658
2659 * valprint.c (val_print_string): Update.
2660 * gdbcore.h (memory_error_message): Return std::string.
2661 * corefile.c (memory_error_message): Return std::string.
2662 (memory_error): Update.
2663 * breakpoint.c (insert_bp_location): Update.
2664
2665 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2666
2667 * target/waitstatus.h (target_waitstatus_to_string): Change
2668 return type to std::string.
2669 * target/waitstatus.c (target_waitstatus_to_string): Return
2670 std::string.
2671 * target.h (target_waitstatus_to_string): Remove declaration.
2672 * infrun.c (resume, clear_proceed_status_thread,
2673 print_target_wait_results, do_target_wait, save_waitstatus,
2674 stop_all_threads): Adjust.
2675 * record-btrace.c (record_btrace_wait): Adjust.
2676 * target-debug.h
2677 (target_debug_print_struct_target_waitstatus_p): Adjust.
2678
2679 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2680
2681 PR gdb/22046
2682 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
2683 detection.
2684
2685 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2686
2687 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
2688 for setting/unsetting environment variables on the remote target.
2689 (New remote packets): Add entries for QEnvironmentHexEncoded,
2690 QEnvironmentUnset and QEnvironmentReset.
2691 * common/environ.c (gdb_environ::operator=): Extend method to
2692 handle m_user_set_env_list and m_user_unset_env_list.
2693 (gdb_environ::clear): Likewise.
2694 (match_var_in_string): Change type of first parameter from 'char
2695 *' to 'const char *'.
2696 (gdb_environ::set): Extend method to handle
2697 m_user_set_env_list and m_user_unset_env_list.
2698 (gdb_environ::unset): Likewise.
2699 (gdb_environ::clear_user_set_env): New method.
2700 (gdb_environ::user_set_envp): Likewise.
2701 (gdb_environ::user_unset_envp): Likewise.
2702 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
2703 m_user_unset_env_list on move constructor/assignment.
2704 (unset): Add new default parameter 'update_unset_list = true'.
2705 (clear_user_set_env): New method.
2706 (user_set_envp): Likewise.
2707 (user_unset_envp): Likewise.
2708 (m_user_set_env_list): New std::set.
2709 (m_user_unset_env_list): Likewise.
2710 * common/rsp-low.c (hex2str): New function.
2711 (bin2hex): New overload for bin2hex function.
2712 * common/rsp-low.c (hex2str): New prototype.
2713 (str2hex): New overload prototype.
2714 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
2715 QEnvironmentUnset and QEnvironmentReset.
2716 (remote_protocol_features): Add QEnvironmentHexEncoded,
2717 QEnvironmentUnset and QEnvironmentReset packets.
2718 (send_environment_packet): New function.
2719 (extended_remote_environment_support): Likewise.
2720 (extended_remote_create_inferior): Call
2721 extended_remote_environment_support.
2722 (_initialize_remote): Add QEnvironmentHexEncoded,
2723 QEnvironmentUnset and QEnvironmentReset packet configs.
2724 * unittests/environ-selftests.c (gdb_selftest_env_var):
2725 New variable.
2726 (test_vector_initialization): New function.
2727 (test_init_from_host_environ): Likewise.
2728 (test_reinit_from_host_environ): Likewise.
2729 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
2730 Likewise.
2731 (test_unset_set_empty_vector): Likewise.
2732 (test_vector_clear): Likewise.
2733 (test_std_move): Likewise.
2734 (test_move_constructor):
2735 (test_self_move): Likewise.
2736 (test_set_unset_reset): Likewise.
2737 (run_tests): Rewrite in terms of the functions above.
2738
2739 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
2740
2741 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
2742 (adi_available): Use a temp variable of type CORE_ADDR as argument
2743 3 when calling target_auxv_search.
2744 (adi_normalize_address): Use masks and xor operators to calculate
2745 normalized address.
2746 (adi_read_versions, adi_write_versions, adi_print_versions)
2747 (do_examine, do_assign): Use paddress.
2748
2749 2017-08-29 John Baldwin <jhb@FreeBSD.org>
2750
2751 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
2752 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
2753 out of loop and add supply of FIR.
2754 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
2755 add collect of FIR.
2756
2757 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
2758
2759 PR gdb/21827
2760 * cli/cli-script.c (define_command): Don't convert command name
2761 to lower case.
2762
2763 2017-08-25 Joel Brobecker <brobecker@adacore.com>
2764
2765 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
2766 Update all callers accordingly. Remove all code blocks handling
2767 the case where DISPP is not NULL.
2768
2769 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2770
2771 PR symtab/22003
2772 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
2773 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2774 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
2775
2776 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2777
2778 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
2779 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
2780 (read_comp_units_from_section): New parameter abbrev_section, use
2781 read_and_check_comp_unit_head, allocate signatured_type if needed.
2782 (create_all_comp_units): Update read_comp_units_from_section caller.
2783
2784 2017-08-23 Pedro Alves <palves@redhat.com>
2785
2786 PR remote/21852
2787 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
2788 to null_ptid and switch to thread without reading the registers
2789 after adding the inferior.
2790
2791 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2792
2793 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
2794 compile-gcc.
2795 * compile/compile.c (compile_gcc, show_compile_gcc): New.
2796 (compile_to_object): Implement compile_gcc.
2797 (_initialize_compile): Install "set compile-gcc". Initialize
2798 compile_gcc.
2799
2800 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2801
2802 * compile/compile.c (compile_to_object): Conditionally call
2803 set_verbose. Conditionally call compile or compile_v0.
2804
2805 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
2806
2807 * sparc64-tdep.h: (adi_normalize_address): New export.
2808 * sparc-nat.h: (open_adi_tag_fd): New export.
2809 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
2810 * sparc64-linux-tdep.c:
2811 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
2812 (sparc64_linux_handle_segmentation_fault): New function.
2813 (sparc64_linux_init_abi): Register
2814 sparc64_linux_handle_segmentation_fault
2815 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
2816 (sparc64_addr_bits_remove): New function.
2817 (sparc64_init_abi): Register sparc64_addr_bits_remove.
2818 (MAX_PROC_NAME_SIZE): New macro.
2819 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
2820 (sparc64adilist): New variable.
2821 (adi_proc_list): New variable.
2822 (find_adi_info): New function.
2823 (add_adi_info): New function.
2824 (get_adi_info_proc): New function.
2825 (get_adi_info): New function.
2826 (info_adi_command): New function.
2827 (read_maps_entry): New function.
2828 (adi_available): New function.
2829 (adi_normalize_address): New function.
2830 (adi_align_address): New function.
2831 (adi_convert_byte_count): New function.
2832 (adi_tag_fd): New function.
2833 (adi_is_addr_mapped): New function.
2834 (adi_read_versions): New function.
2835 (adi_write_versions): New function.
2836 (adi_print_versions): New function.
2837 (do_examine): New function.
2838 (do_assign): New function.
2839 (adi_examine_command): New function.
2840 (adi_assign_command): New function.
2841 (_initialize_sparc64_adi_tdep): New function.
2842
2843 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
2844
2845 * breakpoint.c (breakpoints_info): Rename to ...
2846 (info_breakpoints_command): ... this.
2847 (watchpoints_info): Rename to ...
2848 (info_watchpoints_command): ... this.
2849 (tracepoints_info): Rename to ...
2850 (info_tracepoints_command): ... this.
2851 (_initialize_breakpoint): Adjust.
2852 * dcache.c (dcache_info): Rename to ...
2853 (info_display_command): ... this.
2854 (_initialize_dcache): Adjust.
2855 * frame.h (args_info): Rename to ...
2856 (info_args_command): ... this.
2857 (locals_info): Rename to ...
2858 (info_locals_command): ... this.
2859 * infcmd.c (nofp_registers_info): Rename to ...
2860 (info_registers_command): ... this.
2861 (float_info): Rename to ...
2862 (info_float_command): ... this.
2863 (program_info): Rename to ...
2864 (info_program_command): ... this.
2865 (all_registers_info): Rename to ...
2866 (info_all_registers_command): ... this.
2867 (vector_info): Rename to ...
2868 (info_vector_command): ... this.
2869 (float_info): Rename to ...
2870 (info_float_command): ... this.
2871 (_initialize_infcmd): Adjust.
2872 * inferior.h (term_info): Rename to ...
2873 (info_terminal_command): ... this.
2874 * inflow.c (term_info): Rename to ...
2875 (info_terminal_command): ... this.
2876 (_initialize_inflow): Adjust.
2877 * infrun.c (signals_info): Rename to ...
2878 (info_signals_command): ... this.
2879 (_initialize_infrun): Adjust.
2880 * objc-lang.c (classes_info): Rename to ...
2881 (info_classes_command): ... this.
2882 (selectors_info): Rename to ...
2883 (info_selectors_command): ... this.
2884 (_initialize_objc_language): Adjust.
2885 * printcmd.c (sym_info): Rename to ...
2886 (info_symbol_command): ... this.
2887 (address_info): Rename to ...
2888 (info_address_command): ... this.
2889 (display_info): Rename to ...
2890 (info_display_command): ... this.
2891 (_initialize_printcmd): Adjust.
2892 * reverse.c (bookmarks_info): Rename to ...
2893 (info_breakpoints_command): ... this.
2894 (_initialize_reverse): Adjust.
2895 * ser-go32.c (dos_info): Rename to ...
2896 (info_serial_command): ... this.
2897 (_initialize_ser_dos): Adjust.
2898 * skip.c (skip_info): Rename to ...
2899 (info_skip_command): ... this.
2900 (_initialize_step_skip): Adjust.
2901 * source.c (line_info): Rename to ...
2902 (info_line_command): ... this.
2903 (source_info): Rename to ...
2904 (info_source_command)
2905 * stack.c (frame_info): Rename to ...
2906 (info_frame_command): ... this.
2907 (locals_info): Rename to ...
2908 (info_locals_command): ... this.
2909 (args_info): Rename to ...
2910 (info_args_command): ... this.
2911 (_initialize_stack): Adjust.
2912 * symtab.c (sources_info): Rename to ...
2913 (info_sources_command): ... this.
2914 (variables_info): Rename to ...
2915 (info_variables_command): ... this.
2916 (functions_info): Rename to ...
2917 (info_functions_command): ... this.
2918 (types_info): Rename to ...
2919 (info_types_command): ... this.
2920 (_initialize_symtab): Adjust.
2921 * target.c (target_info): Rename to ...
2922 (info_target_command): ... this.
2923 (initialize_targets): Adjust.
2924 * tracepoint.c (tvariables_info): Rename to ...
2925 (info_tvariables_command): ... this.
2926 (scope_info): Rename to ...
2927 (info_scope_command): ... this.
2928 (trace_dump_actions): Adjust.
2929 (_initialize_tracepoint): Adjust.
2930
2931 2017-08-22 Tom Tromey <tom@tromey.com>
2932
2933 * breakpoint.h (install_breakpoint): Update.
2934 * breakpoint.c (add_solib_catchpoint): Update.
2935 (install_breakpoint): Change argument to a std::unique_ptr.
2936 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
2937 (create_breakpoint_sal, create_breakpoint): Update.
2938 (watch_command_1, catch_exec_command_1)
2939 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
2940 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
2941 Return the breakpoint.
2942 (set_raw_breakpoint_without_location, set_raw_breakpoint)
2943 (new_single_step_breakpoint): Update.
2944 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
2945 std::unique_ptr.
2946 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
2947 std::unique_ptr.
2948 * break-catch-sig.c (create_signal_catchpoint): Use
2949 std::unique_ptr.
2950 * ada-lang.c (create_ada_exception_catchpoint): Use
2951 std::unique_ptr.
2952
2953 2017-08-22 Tom Tromey <tom@tromey.com>
2954
2955 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
2956
2957 2017-08-22 Tom Tromey <tom@tromey.com>
2958
2959 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
2960 (lookup_partial_symbol): Update.
2961
2962 2017-08-22 Tom Tromey <tom@tromey.com>
2963
2964 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
2965 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
2966 (find_and_open_source, symtab_to_fullname): Update.
2967 * psymtab.c (psymtab_to_fullname): Update.
2968
2969 2017-08-22 Tom Tromey <tom@tromey.com>
2970
2971 * exec.c (exec_file_attach): Update.
2972 * linux-thread-db.c (try_thread_db_load): Update.
2973 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
2974 * utils.c (gdb_realpath): Change return type.
2975 (gdb_realpath_keepfile): Update.
2976 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
2977 (_initialize_utils): Register the new self test.
2978 * source.c (openp): Update.
2979 (find_and_open_source): Update.
2980 * nto-tdep.c (nto_find_and_open_solib): Update.
2981 * main.c (set_gdb_data_directory): Update.
2982 (captured_main_1): Update.
2983 * dwarf2read.c (dwarf2_get_dwz_file): Update
2984 (dw2_map_symbol_filenames): Update.
2985 * auto-load.c (auto_load_safe_path_vec_update): Update.
2986 (filename_is_in_auto_load_safe_path_vec): Change type of
2987 "filename_realp".
2988 (auto_load_objfile_script): Update.
2989 (file_is_auto_load_safe): Update. Use std::string.
2990 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
2991
2992 2017-08-22 Tom Tromey <tom@tromey.com>
2993
2994 * utils.c (gdb_realpath_keepfile): Return a
2995 gdb::unique_xmalloc_ptr.
2996 * exec.c (exec_file_attach): Update.
2997 * utils.h (gdb_realpath_keepfile): Return a
2998 gdb::unique_xmalloc_ptr.
2999
3000 2017-08-22 Tom Tromey <tom@tromey.com>
3001
3002 * compile/compile.c (compile_file_command): Use
3003 gdb::unique_xmalloc_ptr, std::string.
3004 * utils.c (gdb_abspath): Change return type.
3005 * source.c (openp): Update.
3006 * objfiles.c (allocate_objfile): Update.
3007 * main.c (set_gdb_data_directory): Update.
3008 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
3009
3010 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
3011
3012 * cli-cmds.c (list_commands): List actual code around more than
3013 one location.
3014
3015 2017-08-21 John Baldwin <jhb@FreeBSD.org>
3016
3017 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
3018
3019 2017-08-21 Pedro Alves <palves@redhat.com>
3020
3021 PR gdb/19487
3022 * c-exp.y (variable production): Handle function aliases.
3023 * minsyms.c (msymbol_is_text): New function.
3024 * minsyms.h (msymbol_is_text): Declare.
3025 * symtab.c (find_function_alias_target): New function.
3026 * symtab.h (find_function_alias_target): Declare.
3027
3028 2017-08-21 Pedro Alves <palves@redhat.com>
3029
3030 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
3031 typedefs.
3032 * typeprint.c (whatis_exp): If handling "whatis", and expression
3033 is OP_TYPE, strip one typedef level. Otherwise don't strip
3034 typedefs here.
3035 * valops.c (value_cast): Save "to" type before resolving
3036 stubs/typedefs. Use that type as resulting value's type.
3037
3038 2017-08-18 Tom Tromey <tom@tromey.com>
3039 Pedro Alves <palves@redhat.com>
3040
3041 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
3042 * sol-thread.c (sol_thread_resume, sol_thread_wait)
3043 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
3044 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
3045 * proc-service.c (ps_xfer_memory): Use scoped_restore.
3046 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
3047 (linux_get_siginfo_data): Add "thread" argument. Use
3048 scoped_restore.
3049 * linux-nat.c (linux_child_follow_fork)
3050 (check_stopped_by_watchpoint): Use scoped_restore.
3051 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
3052 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
3053 (restore_inferior_ptid, save_inferior_ptid): Remove.
3054 * btrace.c (btrace_fetch): Use scoped_restore.
3055 * bsd-uthread.c (bsd_uthread_fetch_registers)
3056 (bsd_uthread_store_registers): Use scoped_restore.
3057 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
3058 scoped_restore.
3059 * aix-thread.c (aix_thread_resume, aix_thread_wait)
3060 (aix_thread_xfer_partial): Use scoped_restore.
3061 * inferior.h (save_inferior_ptid): Remove.
3062
3063 2017-08-18 Yao Qi <yao.qi@linaro.org>
3064
3065 PR tdep/21818
3066 * arm-tdep.c (gdb_print_insn_arm): Mark
3067 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
3068
3069 2017-08-18 Yao Qi <yao.qi@linaro.org>
3070
3071 * NEWS: Mention GDBserver's new option "--selftest".
3072 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
3073 * selftest.c: Move it to common/selftest.c.
3074 * selftest.h: Move it to common/selftest.h.
3075 * selftest-arch.c (reset): New function.
3076 (tests_with_arch): Call reset.
3077
3078 2017-08-18 Yao Qi <yao.qi@linaro.org>
3079
3080 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
3081 instead of exception_fprintf and printf_filtered.
3082
3083 2017-08-18 Yao Qi <yao.qi@linaro.org>
3084
3085 * selftest.c (register_self_test): Rename it to
3086 selftests::register_test.
3087 (run_self_tests): selftest::run_tests.
3088 * selftest.h: Update declarations.
3089 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
3090 selftests::register_test_foreach_arch.
3091 * selftest-arch.h: Update declaration.
3092 * aarch64-tdep.c: Update.
3093 * arm-tdep.c: Likewise.
3094 * disasm-selftests.c: Likewise.
3095 * dwarf2loc.c: Likewise.
3096 * dwarf2-frame.c: Likewise.
3097 * findvar.c: Likewise.
3098 * gdbarch-selftests.c: Likewise.
3099 * maint.c (maintenance_selftest): Likewise.
3100 * regcache.c: Likewise.
3101 * rust-exp.y: Likewise.
3102 * selftest-arch.c: Likewise.
3103 * unittests/environ-selftests.c: Likewise.
3104 * unittests/function-view-selftests.c: Likewise.
3105 * unittests/offset-type-selftests.c: Likewise.
3106 * unittests/optional-selftests.c: Likewise.
3107 * unittests/scoped_restore-selftests.c: Likewise.
3108 * utils-selftests.c: Likewise.
3109
3110 2017-08-17 Pedro Alves <palves@redhat.com>
3111
3112 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
3113 local.
3114
3115 2017-08-17 Pedro Alves <palves@redhat.com>
3116
3117 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3118 field.
3119 (reset_die_in_process): Delete, replaced by ...
3120 (process_die_scope): ... this new class. Make it responsible for
3121 freeing cu->line_header too.
3122 (process_die): Use process_die_scope.
3123 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3124 cu->line_header_die_owner. Don't release the line header if it's
3125 owned by the CU.
3126 (setup_type_unit_groups): Make the CU/DIE own the line header.
3127 Don't release the line header here.
3128
3129 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3130
3131 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3132
3133 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3134
3135 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3136 Single-Key mode
3137
3138 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3139
3140 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3141 mode command list.
3142
3143 2017-08-15 Stafford Horne <shorne@gmail.com>
3144
3145 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3146
3147 2017-08-15 Stafford Horne <shorne@gmail.com>
3148
3149 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3150
3151 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3152
3153 PR gdb/21954
3154 * infcmd.c (unset_environment_command): Use the 'clear' method on
3155 the environment instead of resetting it.
3156
3157 2017-08-15 John Baldwin <jhb@FreeBSD.org>
3158
3159 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3160 platforms.
3161
3162 2017-08-14 Tom Tromey <tom@tromey.com>
3163
3164 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3165 (print_binary_chars): Likewise.
3166 (BITS_IN_BYTES): Remove.
3167
3168 2017-08-14 Tom Tromey <tom@tromey.com>
3169
3170 PR gdb/21675
3171 * valprint.c (LOW_ZERO): Change value to 034.
3172 (print_octal_chars): Add static_asserts for octal constants.
3173 * printcmd.c (print_scalar_formatted): Add 'd' case.
3174
3175 2017-08-11 Tom Tromey <tom@tromey.com>
3176
3177 * symfile.c (add_symbol_file_command): Use std::vector.
3178
3179 2017-08-14 Tom Tromey <tom@tromey.com>
3180
3181 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3182 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3183 std::move.
3184 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3185
3186 2017-08-11 Pedro Alves <palves@redhat.com>
3187
3188 * infrun.c (process_event_stop_test): Adjust
3189 function_name_is_marked_for_skip call.
3190 * skip.c: Include <list>.
3191 (skiplist_entry): Make it a class with private fields, and
3192 getters/setters.
3193 (skiplist_entry_chain): Delete.
3194 (skiplist_entries): New.
3195 (skiplist_entry_count): Delete.
3196 (highest_skiplist_entry_num): New.
3197 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3198 (add_skiplist_entry): Delete.
3199 (skiplist_entry::skiplist_entry): New.
3200 (skiplist_entry::add_entry): New.
3201 (skip_file_command, skip_function): Adjust.
3202 (compile_skip_regexp): Delete.
3203 (skip_command): Don't compile regexp here. Adjust to use
3204 skiplist_entry::add_entry.
3205 (skip_info): Adjust to use range-for and getters.
3206 (skip_enable_command, skip_disable_command): Adjust to use
3207 range-for and setters.
3208 (skip_delete_command): Adjust to use std::list.
3209 (add_skiplist_entry): Delete.
3210 (skip_file_p): Delete, refactored as ...
3211 (skiplist_entry::do_skip_file_p): ... this new method.
3212 (skip_gfile_p): Delete, refactored as ...
3213 (skiplist_entry::do_gskip_file_p): ... this new method.
3214 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3215 (skiplist_entry::skip_function_p): ... this new method.
3216 (function_name_is_marked_for_skip): Now returns bool, and takes
3217 the function sal by const reference. Adjust to use range-for and
3218 skiplist_entry methods.
3219 (_initialize_step_skip): Remove references to
3220 skiplist_entry_chain, skiplist_entry_count.
3221 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3222 takes the function sal by const reference.
3223
3224 2017-08-11 Yao Qi <yao.qi@linaro.org>
3225
3226 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3227 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3228 (dwarf2_frame_cache):
3229 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3230 RETURN_MASK_ALL and set *this_case to NULL.
3231 * frame-unwind.h: Update comments.
3232
3233 2017-08-11 Yao Qi <yao.qi@linaro.org>
3234
3235 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3236 (dwarf2_frame_state_copy_regs): Remove.
3237 (dwarf2_frame_state_free_regs): Remove.
3238 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3239 (dwarf2_restore_rule): Call method .alloc_regs instead of
3240 dwarf2_frame_state_alloc_regs.
3241 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3242 constructor. Call std::move.
3243 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3244 (dwarf2_frame_cache): Likewise.
3245
3246 [GDB_SELF_TEST]: Include selftest.h and
3247 selftest-arch.h.
3248 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3249 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3250 execute_cfa_program_test.
3251
3252 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3253 copy ctor, assignment operator, move assignment.
3254 <alloc_regs>: New method.
3255 <swap>: New method.
3256 (struct dwarf2_frame_state): Delete dtor.
3257 (dwarf2_frame_state_alloc_regs): Remove declaration.
3258 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3259 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3260
3261 2017-08-11 Yao Qi <yao.qi@linaro.org>
3262
3263 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3264 (dwarf2_frame_state::dwarf2_frame_state): New.
3265 (dwarf2_frame_state::~dwarf2_frame_state): New.
3266 (dwarf2_fetch_cfa_info): Update.
3267 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3268 rather than a pointer. Update code.
3269 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3270 dtor.
3271 <data_align, code_align, retaddr_column>: Change them to const.
3272 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3273 to bool.
3274
3275 2017-08-11 Yao Qi <yao.qi@linaro.org>
3276
3277 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3278 <loc.exp>: New field.
3279 * dwarf2-frame.c (execute_cfa_program): Update.
3280 (dwarf2_frame_prev_register): Update.
3281
3282 2017-08-10 Pedro Alves <palves@redhat.com>
3283
3284 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3285
3286 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3287
3288 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3289 (fbsd_pending_children): Use std::list.
3290 (fbsd_remember_child): Likewise.
3291 (fbsd_is_child_pending): Likewise.
3292 (fbsd_pending_vfork_done): Use std::forward_list.
3293 (fbsd_add_vfork_done): Likewise.
3294 (fbsd_is_vfork_done_pending): Likewise.
3295 (fbsd_next_vfork_done): Likewise.
3296
3297 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3298
3299 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3300 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3301 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3302 for `mapfilename'.
3303 (fbsd_xfer_partial): Use gdb::byte_vector.
3304 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
3305
3306 2017-08-09 John Baldwin <jhb@FreeBSD.org>
3307
3308 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3309 "filestuff.h".
3310 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3311
3312 2017-08-09 Tom Tromey <tom@tromey.com>
3313
3314 * skip.c (skiplist_entry): New constructor.
3315 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3316 (skiplist_entry::file_is_glob): Now bool.
3317 (skiplist_entry::file, skiplist_entry::function): Now
3318 std::string.
3319 (make_skip_entry): Return a unique_ptr. Use new.
3320 (free_skiplist_entry, free_skiplist_entry_cleanup)
3321 (make_free_skiplist_entry_cleanup): Remove.
3322 (skip_command, skip_disable_command, add_skiplist_entry)
3323 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3324 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3325 (function_name_is_marked_for_skip): Update.
3326 (skip_delete_command): Update. Use delete.
3327
3328 2017-08-09 Jiong Wang <jiong.wang@arm.com>
3329
3330 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3331 (aarch64_linux_core_read_description): New function.
3332 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3333
3334 2017-08-09 Pedro Alves <palves@redhat.com>
3335
3336 * cp-name-parser.y (cp_comp_to_string): Return a
3337 gdb::unique_xmalloc_ptr<char>.
3338 * cp-support.c (replace_typedefs_qualified_name)
3339 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3340 (cp_canonicalize_string_full): Use op= instead of explicit
3341 convertion.
3342 (cp_class_name_from_physname, method_name_from_physname)
3343 (cp_func_name, cp_remove_params): Adjust to use
3344 gdb::unique_xmalloc_ptr<char>.
3345 * cp-support.h (cp_comp_to_string): Return a
3346 gdb::unique_xmalloc_ptr<char>.
3347 * python/py-type.c (typy_lookup_type): Adjust to use
3348 gdb::unique_xmalloc_ptr<char>.
3349
3350 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3351
3352 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3353
3354 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3355 Yao Qi <yao.qi@linaro.org>
3356
3357 * cp-support.c (cp_canonicalize_string_full): Use
3358 gdb::unique_xmalloc_ptr<char>.
3359 (cp_canonicalize_string): Likewise.
3360
3361 2017-08-09 Yao Qi <yao.qi@linaro.org>
3362
3363 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3364 * regformats/i386/amd64-avx-avx512.dat: Remove.
3365 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3366 * regformats/i386/amd64-avx-mpx.dat:Remove.
3367 * regformats/i386/amd64-avx.dat: Remove.
3368 * regformats/i386/amd64-mpx.dat: Remove.
3369 * regformats/i386/i386-avx-avx512.dat: Remove.
3370 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3371 * regformats/i386/i386-avx-mpx.dat: Remove.
3372 * regformats/i386/i386-mmx.dat: Remove.
3373 * regformats/i386/i386-mpx.dat: Remove.
3374
3375 2017-08-09 Yao Qi <yao.qi@linaro.org>
3376
3377 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3378 * amd64-tdep.c: Don't include features/i386/x32*.c.
3379 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3380 functions.
3381 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3382 and i386/x32-avx-avx512.
3383 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3384 and i386/x32.xml.
3385 * features/i386/x32-avx-avx512.c: Removed.
3386 * features/i386/x32-avx-avx512.xml: Removed.
3387 * features/i386/x32-avx.c: Removed.
3388 * features/i386/x32-avx.xml: Removed.
3389 * features/i386/x32.c: Removed.
3390 * features/i386/x32.xml: Removed.
3391 * regformats/i386/x32-avx-avx512.dat: Removed.
3392 * regformats/i386/x32-avx.dat: Removed.
3393 * regformats/i386/x32.dat: Removed.
3394
3395 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3396
3397 PR breakpoints/21886
3398 * mem-break.c (default_memory_insert_breakpoint): Use
3399 `->placed_address' rather than `->reqstd_address' for the
3400 breakpoint location.
3401
3402 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3403
3404 * arch-utils.c (default_print_insn): Remove arch/mach/endian
3405 assertions.
3406
3407 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3408
3409 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
3410 a union of `tdep_info', `tdesc_data' and `id'.
3411 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
3412 rather than `info.tdep_info'.
3413 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
3414 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
3415 * i386-tdep.c (i386_gdbarch_init): Likewise.
3416 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
3417 * mips-tdep.c (mips_gdbarch_init): Likewise.
3418 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
3419 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
3420 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
3421 `info.tdep_info'.
3422 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
3423 `info.tdep_info'.
3424 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
3425 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
3426 `info.tdep_info'.
3427 * spu-tdep.c (spu_gdbarch_init): Likewise.
3428 * gdbarch.h: Regenerate.
3429
3430 2017-08-07 Leszek Swirski <leszeks@google.com>
3431
3432 PR symtab/20899
3433 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
3434
3435 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
3436
3437 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
3438 (gdbsim_open): Rename gdb_argv args object to argv.
3439
3440 2017-08-05 Tom Tromey <tom@tromey.com>
3441
3442 * compile/compile-object-load.c (compile_object_load): Use
3443 gdb::unique_xmalloc_ptr.
3444 * cli/cli-dump.c (scan_filename): Rename from
3445 scan_filename_with_cleanup. Change return type.
3446 (scan_expression): Rename from scan_expression_with_cleanup.
3447 Change return type.
3448 (dump_memory_to_file, dump_value_to_file, restore_command):
3449 Use gdb::unique_xmalloc_ptr. Update.
3450 * cli/cli-cmds.c (find_and_open_script): Use
3451 gdb::unique_xmalloc_ptr.
3452 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
3453 * symmisc.c (maintenance_print_symbols)
3454 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
3455 * symfile.c (symfile_bfd_open, generic_load)
3456 (add_symbol_file_command, remove_symbol_file_command): Use
3457 gdb::unique_xmalloc_ptr.
3458 * source.c (openp): Use gdb::unique_xmalloc_ptr.
3459 * psymtab.c (maintenance_print_psymbols): Use
3460 gdb::unique_xmalloc_ptr.
3461 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
3462 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
3463 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
3464 (reload_shared_libraries_1): Likewise.
3465
3466 2017-08-05 Tom Tromey <tom@tromey.com>
3467
3468 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
3469 (rust_op_vector, rust_set_vector): New typedefs.
3470 (current_parser): New global.
3471 (work_obstack): Change to pointer type. Update all users.
3472 (rust_ast, pstate): Remove globals.
3473 (struct rust_parser): New.
3474 (%union) <params, field_inits>: Change type.
3475 (start, tuple_expr, unit_expr, struct_expr_list, literal)
3476 (field_expr, expr_list, maybe_expr_list, type_list): Update.
3477 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
3478 (convert_params_to_types, convert_params_to_expression): Change
3479 type of "params".
3480 (ast_string): Change type of "fields".
3481 (rust_parse): Make a rust_parser. Remove cleanups.
3482 (rust_lex_tests): Make and install an auto_obstack.
3483
3484 2017-08-04 Yao Qi <yao.qi@linaro.org>
3485
3486 * configure.srv (ipa_x32_linux_regobj): New.
3487 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
3488 instead of X86_TDESC_AVX512.
3489 (initialize_low_tracepoint): Call
3490 init_registers_x32_avx_avx512_linux.
3491
3492 2017-08-04 Yao Qi <yao.qi@linaro.org>
3493
3494 * utils.h (gdb_argv): Add namespace std for nullptr_t.
3495
3496 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
3497
3498 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
3499
3500 2017-08-03 Tom Tromey <tom@tromey.com>
3501
3502 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
3503 Remove.
3504 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
3505
3506 2017-08-03 Tom Tromey <tom@tromey.com>
3507
3508 * python/py-param.c (compute_enum_values): Use gdb_argv.
3509
3510 2017-08-03 Tom Tromey <tom@tromey.com>
3511
3512 * utils.h (struct gdb_argv_deleter): New.
3513 (gdb_argv): New class.
3514 * utils.c (gdb_argv::reset): New method.
3515 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
3516 * tracefile.c (tsave_command): Use gdb_argv.
3517 * top.c (new_ui_command): Use gdb_argv.
3518 * symmisc.c (maintenance_print_symbols)
3519 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
3520 * symfile.c (symbol_file_command, generic_load)
3521 (remove_symbol_file_command): Use gdb_argv.
3522 * stack.c (backtrace_command): Use gdb_argv.
3523 * source.c (add_path, show_substitute_path_command)
3524 (unset_substitute_path_command, set_substitute_path_command):
3525 Use gdb_argv.
3526 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
3527 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
3528 * remote.c (extended_remote_run, remote_put_command)
3529 (remote_get_command, remote_delete_command): Use gdb_argv.
3530 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
3531 (gdbsim_open): Use gdb_argv.
3532 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
3533 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
3534 * procfs.c (procfs_info_proc): Use gdb_argv.
3535 * interps.c (interpreter_exec_cmd): Use gdb_argv.
3536 * infrun.c (handle_command): Use gdb_argv.
3537 * inferior.c (add_inferior_command, clone_inferior_command):
3538 Use gdb_argv.
3539 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
3540 * exec.c (exec_file_command): Use gdb_argv.
3541 * cli/cli-cmds.c (alias_command): Use gdb_argv.
3542 * compile/compile.c (build_argc_argv): Use gdb_argv.
3543
3544 2017-08-03 Tom Tromey <tom@tromey.com>
3545
3546 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
3547
3548 2017-08-03 Tom Tromey <tom@tromey.com>
3549
3550 * python/python.c (compute_python_string): Return std::string.
3551 (gdbpy_eval_from_control_command): Update.
3552 (do_start_initialization): Use std::string.
3553 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
3554 xstrprintf.
3555 * python/py-breakpoint.c (local_setattro): Use string_printf, not
3556 xstrprintf.
3557
3558 2017-08-03 Tom Tromey <tom@tromey.com>
3559
3560 * top.h (do_restore_instream_cleanup): Remove.
3561 * top.c (do_restore_instream_cleanup): Remove.
3562 (read_command_file): Use scoped_restore.
3563 * cli/cli-script.c (execute_user_command): Use scoped_restore.
3564
3565 2017-08-03 Tom Tromey <tom@tromey.com>
3566
3567 * cli/cli-script.c (execute_user_command)
3568 (execute_control_command): Use scoped_restore.
3569
3570 2017-08-03 Tom Tromey <tom@tromey.com>
3571
3572 * cli/cli-script.c (do_restore_user_call_depth): Remove.
3573 (execute_user_command): Remove user_call_depth; use
3574 user_args_stack's size instead.
3575
3576 2017-08-03 Tom Tromey <tom@tromey.com>
3577
3578 * top.h (in_user_command): Remove.
3579 * top.c (in_user_command): Remove.
3580 * cli/cli-script.c (do_restore_user_call_depth)
3581 (execute_user_command): Update.
3582
3583 2017-08-03 Tom Tromey <tom@tromey.com>
3584
3585 * valops.c (search_struct_method): Use gdb::byte_vector.
3586 * valarith.c (value_concat): Use std::vector.
3587 * target.c (memory_xfer_partial): Use gdb::byte_vector.
3588 (simple_search_memory): Likewise.
3589 * printcmd.c (find_string_backward): Use gdb::byte_vector.
3590 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
3591 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
3592 * elfread.c (elf_rel_plt_read): Use std::string.
3593 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
3594 * cli/cli-dump.c (restore_section_callback): Use
3595 gdb::byte_vector.
3596
3597 2017-08-03 Tom Tromey <tom@tromey.com>
3598
3599 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
3600
3601 2017-08-03 Tom Tromey <tom@tromey.com>
3602
3603 * tui/tui-regs.c (tui_restore_gdbout): Remove.
3604 (tui_register_format): Use scoped_restore.
3605
3606 2017-08-03 Tom Tromey <tom@tromey.com>
3607
3608 * reverse.c (exec_direction_default): Remove.
3609 (exec_reverse_once): Use scoped_restore.
3610 * remote.c (restore_remote_timeout): Remove.
3611 (remote_flash_erase, remote_flash_write, remote_flash_done)
3612 (readchar, remote_serial_write): Use scoped_restore.
3613 * cli/cli-script.c (struct source_cleanup_lines_args)
3614 (source_cleanup_lines): Remove.
3615 (script_from_file): Use scoped_restore.
3616 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
3617 (source_command): Use scoped_restore.
3618
3619 2017-08-03 Tom Tromey <tom@tromey.com>
3620
3621 * utils.h (make_cleanup_free_so): Remove.
3622 * utils.c (do_free_so, make_cleanup_free_so): Remove.
3623 * solist.h (struct so_deleter): New.
3624 (so_list_up): New typedef.
3625 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
3626
3627 2017-08-03 Tom Tromey <tom@tromey.com>
3628
3629 * utils.h (make_cleanup_restore_current_language): Remove.
3630 * utils.c (do_restore_current_language)
3631 (make_cleanup_restore_current_language): Remove.
3632 * parse.c (parse_exp_in_context_1)
3633 (parse_expression_with_language): Use
3634 scoped_restore_current_language.
3635 * mi/mi-main.c (mi_cmd_execute): Use
3636 scoped_restore_current_language.
3637 * language.h (scoped_restore_current_language): New class.
3638
3639 2017-08-03 Tom Tromey <tom@tromey.com>
3640
3641 * compile/compile.c (cleanup_unlink_file): Remove.
3642 (compile_to_object): Use gdb::unlinker.
3643 (eval_compile_command): Likewise.
3644
3645 2017-08-03 Tom Tromey <tom@tromey.com>
3646
3647 * utils.h (make_cleanup_fclose): Remove.
3648 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
3649
3650 2017-08-03 Tom Tromey <tom@tromey.com>
3651
3652 * top.c (open_terminal_stream): Return gdb_file_up.
3653 (new_ui_command): Update.
3654
3655 2017-08-03 Tom Tromey <tom@tromey.com>
3656
3657 * source.c (print_source_lines_base, forward_search_command)
3658 (reverse_search_command): Use gdb_file_up.
3659
3660 2017-08-03 Tom Tromey <tom@tromey.com>
3661
3662 * fbsd-nat.c (fbsd_find_memory_regions): Update.
3663
3664 2017-08-03 Tom Tromey <tom@tromey.com>
3665
3666 * cli/cli-cmds.c (find_and_open_script): Change return type.
3667 Remove "streamp" and "full_path" parameters.
3668 (source_script_with_search): Update.
3669 * auto-load.c (source_script_file): Update.
3670 * cli/cli-cmds.h (find_and_open_script): Change type.
3671 (open_script): New struct.
3672
3673 2017-08-03 Tom Tromey <tom@tromey.com>
3674
3675 * xml-support.c (xml_fetch_content_from_file): Update.
3676 * ui-file.c (stdio_file::open): Update.
3677 * tracefile-tfile.c (tfile_start): Update.
3678 * remote.c (remote_file_put, remote_file_get): Update.
3679 * nat/linux-procfs.c (linux_proc_get_int)
3680 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
3681 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
3682 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
3683 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
3684 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
3685 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
3686 * linux-nat.c (linux_proc_pending_signals): Update.
3687 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
3688 (file_closer): Remove.
3689 * compile/compile.c (compile_to_object): Update.
3690 * common/filestuff.h (struct gdb_file_deleter): New.
3691 (gdb_file_up): New typedef.
3692 (gdb_fopen_cloexec): Change return type.
3693 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
3694 * cli/cli-dump.c (fopen_with_cleanup): Remove.
3695 (dump_binary_file, restore_binary_file): Update.
3696 * auto-load.c (auto_load_objfile_script_1): Update.
3697
3698 2017-08-03 Tom Tromey <tom@tromey.com>
3699
3700 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
3701 (info_static_tracepoint_markers_command): Likewise.
3702 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
3703 * skip.c (skip_info): Use ui_out_emit_table.
3704 * progspace.c (print_program_space): Use ui_out_emit_table.
3705 * osdata.c (info_osdata): Use ui_out_emit_table.
3706 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
3707 ui_out_emit_table.
3708 * linux-thread-db.c (info_auto_load_libthread_db): Use
3709 ui_out_emit_table.
3710 * inferior.c (print_inferior): Use ui_out_emit_table.
3711 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
3712 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
3713 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
3714 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
3715 * ui-out.h (class ui_out_emit_table): New.
3716
3717 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
3718
3719 * mips-tdep.c (mips_fpu_type_str): New function.
3720 (mips_dump_tdep): Call it.
3721
3722 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
3723
3724 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
3725 `->mips_fpu_type'.
3726
3727 2017-07-31 Xavier Roirand <roirand@adacore.com>
3728
3729 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
3730
3731 2017-07-27 Xavier Roirand <roirand@adacore.com>
3732
3733 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
3734
3735 2017-07-26 Yao Qi <yao.qi@linaro.org>
3736
3737 * cli/cli-cmds.c (maintenancechecklist): New variable.
3738 * gdbcmd.h (maintenancechecklist): Declare it.
3739 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
3740 Call i386_linux_read_description with different masks.
3741 * maint.c (maintenance_check_command): New function.
3742 (_initialize_maint_cmds): Call add_prefix_cmd.
3743 * target-descriptions.c (tdesc_reg): override operator != and ==.
3744 (tdesc_type): Likewise.
3745 (tdesc_feature): Likewise.
3746 (target_desc): Likewise.
3747 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
3748 (maintenance_check_xml_descriptions): New function.
3749 (_initialize_target_descriptions) Add command "xml-descriptions".
3750 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
3751
3752 2017-07-26 Yao Qi <yao.qi@linaro.org>
3753
3754 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
3755 Include features/i386/32bit-*.c.
3756 (i386_linux_read_description): Generate target description if it
3757 doesn't exist.
3758 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
3759 functions.
3760 * features/i386/32bit-linux.c: Re-generated.
3761 * features/i386/32bit-sse.c: Likewise.
3762 * target-descriptions.c (print_c_feature::visit): Print code to
3763 set register number if needed.
3764 (print_c_feature) <m_next_regnum>: New field.
3765
3766 2017-07-26 Yao Qi <yao.qi@linaro.org>
3767
3768 * features/Makefile (CFILES): Rename with TDESC_CFILES.
3769 (FEATURE_XMLFILES): New.
3770 (FEATURE_CFILES): New.
3771 New rules.
3772 (clean-cfiles): Remove generated c files.
3773 * features/i386/32bit-avx.c: Generated.
3774 * features/i386/32bit-avx512.c: Generated.
3775 * features/i386/32bit-core.c: Generated.
3776 * features/i386/32bit-linux.c: Generated.
3777 * features/i386/32bit-mpx.c: Generated.
3778 * features/i386/32bit-pkeys.c: Generated.
3779 * features/i386/32bit-sse.c: Generated.
3780 * target-descriptions.c: Include algorithm.
3781 (tdesc_element_visitor): Add method visit_end.
3782 (print_c_tdesc): Implement visit_end.
3783 (print_c_tdesc:: m_filename_after_features): Move it to
3784 protected.
3785 (print_c_feature): New class.
3786 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
3787 name starts with "i386/32bit-".
3788
3789 2017-07-26 Yao Qi <yao.qi@linaro.org>
3790
3791 * target-descriptions.c (tdesc_element_visitor): New class.
3792 (tdesc_element): New class.
3793 (tdesc_reg): Inherit from tdesc_element.
3794 (tdesc_reg::accept): New function.
3795 (tdesc_type): Inherit from tdesc_element.
3796 (tdesc_type::accept): New function.
3797 (tdesc_feature): Inherit from tdesc_element.
3798 (tdesc_feature::accept): New function.
3799 (target_desc): Inherit from tdesc_element.
3800 (target_desc::target_desc): New.
3801 (target_desc::~target_desc): New.
3802 (target_desc::accept): New.
3803 (allocate_target_description): Use new.
3804 (free_target_description): Use delete.
3805 (print_c_tdesc): New class.
3806 (maint_print_c_tdesc_cmd): Adjust.
3807
3808 * features/aarch64.c: Re-generated.
3809 * features/arc-arcompact.c: Re-generated.
3810 * features/arc-v2.c: Re-generated.
3811 * features/arm/arm-with-iwmmxt.c: Re-generated.
3812 * features/arm/arm-with-m.c: Re-generated.
3813 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
3814 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
3815 * features/arm/arm-with-neon.c: Re-generated.
3816 * features/arm/arm-with-vfpv2.c: Re-generated.
3817 * features/arm/arm-with-vfpv3.c: Re-generated.
3818 * features/i386/amd64-avx-avx512.c: Re-generated.
3819 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
3820 * features/i386/amd64-avx.c: Re-generated.
3821 * features/i386/amd64-avx-linux.c: Re-generated.
3822 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
3823 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
3824 * features/i386/amd64-avx-mpx.c: Re-generated.
3825 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
3826 * features/i386/amd64.c: Re-generated.
3827 * features/i386/amd64-linux.c: Re-generated.
3828 * features/i386/amd64-mpx.c: Re-generated.
3829 * features/i386/amd64-mpx-linux.c: Re-generated.
3830 * features/i386/i386-avx-avx512.c: Re-generated.
3831 * features/i386/i386-avx-avx512-linux.c: Re-generated.
3832 * features/i386/i386-avx.c: Re-generated.
3833 * features/i386/i386-avx-linux.c: Re-generated.
3834 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
3835 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
3836 * features/i386/i386-avx-mpx.c: Re-generated.
3837 * features/i386/i386-avx-mpx-linux.c: Re-generated.
3838 * features/i386/i386.c: Re-generated.
3839 * features/i386/i386-linux.c: Re-generated.
3840 * features/i386/i386-mmx.c: Re-generated.
3841 * features/i386/i386-mmx-linux.c: Re-generated.
3842 * features/i386/i386-mpx.c: Re-generated.
3843 * features/i386/i386-mpx-linux.c: Re-generated.
3844 * features/i386/x32-avx-avx512.c: Re-generated.
3845 * features/i386/x32-avx-avx512-linux.c: Re-generated.
3846 * features/i386/x32-avx.c: Re-generated.
3847 * features/i386/x32-avx-linux.c: Re-generated.
3848 * features/i386/x32.c: Re-generated.
3849 * features/i386/x32-linux.c: Re-generated.
3850 * features/microblaze.c: Re-generated.
3851 * features/microblaze-with-stack-protect.c: Re-generated.
3852 * features/mips64-dsp-linux.c: Re-generated.
3853 * features/mips64-linux.c: Re-generated.
3854 * features/mips-dsp-linux.c: Re-generated.
3855 * features/mips-linux.c: Re-generated.
3856 * features/nds32.c: Re-generated.
3857 * features/nios2.c: Re-generated.
3858 * features/nios2-linux.c: Re-generated.
3859 * features/rs6000/powerpc-32.c: Re-generated.
3860 * features/rs6000/powerpc-32l.c: Re-generated.
3861 * features/rs6000/powerpc-403.c: Re-generated.
3862 * features/rs6000/powerpc-403gc.c : Re-generated.
3863 * features/rs6000/powerpc-405.c: Re-generated.
3864 * features/rs6000/powerpc-505.c: Re-generated.
3865 * features/rs6000/powerpc-601.c: Re-generated.
3866 * features/rs6000/powerpc-602.c: Re-generated.
3867 * features/rs6000/powerpc-603.c: Re-generated.
3868 * features/rs6000/powerpc-604.c: Re-generated.
3869 * features/rs6000/powerpc-64.c: Re-generated.
3870 * features/rs6000/powerpc-64l.c: Re-generated.
3871 * features/rs6000/powerpc-7400.c: Re-generated.
3872 * features/rs6000/powerpc-750.c: Re-generated.
3873 * features/rs6000/powerpc-860.c: Re-generated.
3874 * features/rs6000/powerpc-altivec32.c: Re-generated.
3875 * features/rs6000/powerpc-altivec32l.c: Re-generated.
3876 * features/rs6000/powerpc-altivec64.c: Re-generated.
3877 * features/rs6000/powerpc-altivec64l.c: Re-generated.
3878 * features/rs6000/powerpc-cell32l.c: Re-generated.
3879 * features/rs6000/powerpc-cell64l.c: Re-generated.
3880 * features/rs6000/powerpc-e500.c: Re-generated.
3881 * features/rs6000/powerpc-e500l.c: Re-generated.
3882 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
3883 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
3884 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
3885 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
3886 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
3887 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
3888 * features/rs6000/powerpc-vsx32.c: Re-generated.
3889 * features/rs6000/powerpc-vsx32l.c: Re-generated.
3890 * features/rs6000/powerpc-vsx64.c: Re-generated.
3891 * features/rs6000/powerpc-vsx64l.c: Re-generated.
3892 * features/rs6000/rs6000.c: Re-generated.
3893 * features/s390-linux32.c: Re-generated.
3894 * features/s390-linux32v1.c: Re-generated.
3895 * features/s390-linux32v2.c: Re-generated.
3896 * features/s390-linux64.c: Re-generated.
3897 * features/s390-linux64v1.c: Re-generated.
3898 * features/s390-linux64v2.c: Re-generated.
3899 * features/s390-te-linux64.c: Re-generated.
3900 * features/s390-tevx-linux64.c: Re-generated.
3901 * features/s390-vx-linux64.c: Re-generated.
3902 * features/s390x-linux64.c: Re-generated.
3903 * features/s390x-linux64v1.c: Re-generated.
3904 * features/s390x-linux64v2.c: Re-generated.
3905 * features/s390x-te-linux64.c: Re-generated.
3906 * features/s390x-tevx-linux64.c: Re-generated.
3907 * features/s390x-vx-linux64.c: Re-generated.
3908 * features/sparc/sparc32-solaris.c: Re-generated.
3909 * features/sparc/sparc64-solaris.c: Re-generated.
3910 * features/tic6x-c62x.c: Re-generated.
3911 * features/tic6x-c62x-linux.c: Re-generated.
3912 * features/tic6x-c64x.c: Re-generated.
3913 * features/tic6x-c64x-linux.c: Re-generated.
3914 * features/tic6x-c64xp.c: Re-generated.
3915 * features/tic6x-c64xp-linux.c: Re-generated.
3916
3917 2017-07-26 Yao Qi <yao.qi@linaro.org>
3918
3919 * i386-linux-tdep.c (i386_linux_read_description): New function.
3920 (i386_linux_core_read_description): Call
3921 i386_linux_read_description.
3922 * i386-linux-tdep.h (i386_linux_read_description): Declare.
3923 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
3924 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
3925 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
3926 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
3927 * x86-linux-nat.c (x86_linux_read_description): Call
3928 i386_linux_read_description.
3929
3930 2017-07-26 Yao Qi <yao.qi@linaro.org>
3931
3932 * NEWS: Mention it.
3933 * features/Makefile (%.c: %.xml): Pass the xml file name to
3934 command "maint print c-tdesc".
3935 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
3936 name from 'arg'.
3937
3938 2017-07-26 Yao Qi <yao.qi@linaro.org>
3939
3940 * target-descriptions.c (target_desc): Add ctor and dtor. Do
3941 in-class initialization.
3942 (tdesc_create_feature): Call new instead of XCNEW.
3943 (free_target_description): Ue delete.
3944
3945 2017-07-25 John Baldwin <jhb@FreeBSD.org>
3946
3947 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
3948
3949 2017-07-25 Yao Qi <yao.qi@linaro.org>
3950
3951 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
3952 constant.
3953 (amd64_x32_init_abi): Likewise.
3954 * amd64-tdep.h (amd64_init_abi): Update declaration.
3955 (amd64_x32_init_abi): Likewise.
3956
3957 2017-07-25 Yao Qi <yao.qi@linaro.org>
3958
3959 PR tdep/21717
3960 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
3961 condition for FPSCR.
3962 (arm_linux_store_inferior_registers): Likewise.
3963
3964 2017-07-22 Tom Tromey <tom@tromey.com>
3965
3966 * break-catch-syscall.c (struct catch_syscall_inferior_data)
3967 <syscalls_counts>: Now a std::vector.
3968 (get_catch_syscall_inferior_data): Use "new".
3969 (catch_syscall_inferior_data_cleanup): Use "delete".
3970 (insert_catch_syscall, remove_catch_syscall)
3971 (clear_syscall_counts): Update.
3972
3973 2017-07-22 Tom Tromey <tom@tromey.com>
3974
3975 * break-catch-syscall.c (syscall_catchpoint)
3976 <syscalls_to_be_caught>: Now a std::vector<int>
3977 (~syscall_catchpoint): Remove.
3978 (insert_catch_syscall, remove_catch_syscall)
3979 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
3980 (print_mention_catch_syscall, print_recreate_catch_syscall):
3981 Update.
3982 (create_syscall_event_catchpoint): Change type of "filter"
3983 parameter.
3984 (catch_syscall_split_args): Return a std::vector.
3985 (catch_syscall_command_1, catching_syscall_number_1): Update.
3986
3987 2017-07-22 Tom Tromey <tom@tromey.com>
3988
3989 * break-catch-throw.c (struct exception_catchpoint)
3990 <exception_rx>: Now a std::string.
3991 (~exception_catchpoint): Remove.
3992 (print_one_detail_exception_catchpoint): Update.
3993 (handle_gnu_v3_exceptions): Change type of except_rx.
3994 (extract_exception_regexp): Return a std::string.
3995 (catch_exception_command_1): Update.
3996
3997 2017-07-22 Tom Tromey <tom@tromey.com>
3998
3999 * break-catch-sig.c (gdb_signal_type): Remove typedef.
4000 (struct signal_catchpoint) <signals_to_be_caught>: Now a
4001 std::vector.
4002 <catch_all>: Now a bool.
4003 (~signal_catchpoint): Remove.
4004 (signal_catchpoint_insert_location)
4005 (signal_catchpoint_remove_location)
4006 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
4007 (signal_catchpoint_print_mention)
4008 (signal_catchpoint_print_recreate)
4009 (signal_catchpoint_explains_signal): Update.
4010 (create_signal_catchpoint): Change type of "filter" and
4011 "catch_all".
4012 (catch_signal_split_args): Return a std::vector. Change type of
4013 "catch_all".
4014 (catch_signal_command): Update.
4015
4016 2017-07-20 Pedro Alves <palves@redhat.com>
4017
4018 * ada-lang.c (ada_language_defn): Make extern.
4019 (_initialize_ada_language): Remove add_language call.
4020 * c-lang.c (c_language_defn, cplus_language_defn)
4021 (asm_language_defn, minimal_language_defn): Make extern.
4022 (_initialize_c_language): Delete.
4023 * completer.c (compare_cstrings): Delete, moved to utils.h.
4024 * d-lang.c (d_language_defn): Make extern.
4025 (_initialize_d_language): Remove add_language calls.
4026 * defs.h (enum language): Add comment.
4027 * f-lang.c (f_language_defn): Make extern.
4028 (_initialize_f_language): Remove add_language call.
4029 * go-lang.c (go_language_defn): Make extern.
4030 (_initialize_go_language): Remove add_language call.
4031 * language.c: Include <algorithm>.
4032 (languages): Redefine as const array.
4033 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
4034 (set_language_command): Handle "local". Use for-range loop.
4035 (set_language): Remove loop.
4036 (language_enum): Rewrite.
4037 (language_def, language_str): Remove loops.
4038 (add_language): Delete.
4039 (add_set_language_command): New, based on add_languages.
4040 (skip_language_trampoline): Adjust.
4041 (local_language_defn): Delete.
4042 (language_gdbarch_post_init): Adjust.
4043 (_initialize_language): Remove add_language calls. Call
4044 add_set_language_command.
4045 * language.h (add_language): Delete.
4046 (auto_language_defn)
4047 (unknown_language_defn, minimal_language_defn, ada_language_defn)
4048 (asm_language_defn, c_language_defn, cplus_language_defn)
4049 (d_language_defn, f_language_defn, go_language_defn)
4050 (m2_language_defn, objc_language_defn, opencl_language_defn)
4051 (pascal_language_defn, rust_language_defn): Declare.
4052 * m2-lang.c (m2_language_defn): Make extern.
4053 (_initialize_m2_language): Remove add_language call.
4054 * objc-lang.c (objc_language_defn): Make extern.
4055 (_initialize_objc_language): Remove add_language call.
4056 * opencl-lang.c (opencl_language_defn): Make extern.
4057 (_initialize_opencl_language): Remove add_language call.
4058 * p-lang.c (pascal_language_defn): Make extern.
4059 (_initialize_pascal_language): Delete.
4060 * rust-lang.c (rust_language_defn): Make extern.
4061 (_initialize_rust_language): Delete.
4062 * utils.h (compare_cstrings): New static inline function.
4063
4064 2017-07-20 Pedro Alves <palves@redhat.com>
4065
4066 * ada-lang.c (ada_to_fixed_type_1): Adjust.
4067 (get_var_value): Constify parameters.
4068 (get_int_var_value): Change prototype.
4069 (to_fixed_range_type): Adjust.
4070 * ada-lang.h (get_int_var_value): Change prototype.
4071
4072 2017-07-20 Pedro Alves <palves@redhat.com>
4073
4074 * dwarf2read.c (dw2_lookup_symbol): Use
4075 SYMBOL_MATCHES_SEARCH_NAME.
4076 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
4077
4078 2017-07-20 Pedro Alves <palves@redhat.com>
4079
4080 * block.c (block_iter_name_step, block_iter_name_first)
4081 (block_iter_name_next): Delete.
4082 (block_lookup_symbol_primary): Adjust to use
4083 dict_iter_match_first/dict_iter_match_next.
4084 * block.h (block_iter_name_first, block_iter_name_next): Delete
4085 declarations.
4086 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
4087 dict_iter_match_first/dict_iter_match_next.
4088
4089 2017-07-20 Pedro Alves <palves@redhat.com>
4090
4091 * cp-support.c (cp_find_first_component_aux): Add missing case for
4092 end of string.
4093
4094 2017-07-18 David Blaikie <dblaikie@gmail.com>
4095
4096 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
4097 of dwo_cu's dwo_file.
4098
4099 2017-07-18 Yao Qi <yao.qi@linaro.org>
4100
4101 * remote.c (store_registers_using_G): Remove one line comment.
4102
4103 2017-07-18 Yao Qi <yao.qi@linaro.org>
4104
4105 * regcache.c (regcache_cpy): Simplify it.
4106 (regcache::cpy_no_passthrough): Remove it.
4107 * regcache.h (cpy_no_passthrough): Remove it.
4108 (regcache_dup, regcache_cpy): Update comments.
4109
4110 2017-07-18 Pedro Alves <palves@redhat.com>
4111
4112 * remote-sim.c (sim_command_completer): Adjust to work with a
4113 completion_tracker instead of a VEC.
4114
4115 2017-07-17 Pedro Alves <palves@redhat.com>
4116
4117 * completer.c (complete_source_filenames): New function.
4118 (complete_address_and_linespec_locations): New function.
4119 (location_completer): Use complete_address_and_linespec_locations.
4120 (completion_tracker::build_completion_result): Honor the tracker's
4121 request to suppress append.
4122 * completer.h (completion_tracker::suppress_append_ws)
4123 (completion_tracker::set_suppress_append_ws): New methods.
4124 (completion_tracker::m_suppress_append_ws): New field.
4125 (complete_source_filenames): New declaration.
4126 * linespec.c (linespec_complete_what): New.
4127 (struct ls_parser) <complete_what, completion_word,
4128 completion_quote_char, completion_quote_end, completion_tracker>:
4129 New fields.
4130 (string_find_incomplete_keyword_at_end): New.
4131 (linespec_lexer_lex_string): Record quote char. If in completion
4132 mode, don't throw.
4133 (linespec_lexer_consume_token): Advance the completion word point.
4134 (linespec_lexer_peek_token): Save/restore completion info.
4135 (save_stream_and_consume_token): New.
4136 (set_completion_after_number): New.
4137 (linespec_parse_basic): Set what to complete next depending on
4138 token. Handle function and label completions specially.
4139 (parse_linespec): Disable objc shortcut in completion mode. Set
4140 what to complete next depending on token type. Skip keyword if in
4141 completion mode.
4142 (complete_linespec_component, linespec_complete): New.
4143 * linespec.h (linespec_complete): Declare.
4144
4145 2017-07-17 Pedro Alves <palves@redhat.com>
4146
4147 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4148 Handle 'operator<' / 'operator<<'.
4149
4150 2017-07-17 Pedro Alves <palves@redhat.com>
4151
4152 * completer.c (collect_explicit_location_matches): Handle
4153 MATCH_LABEL.
4154 (convert_explicit_location_to_linespec): New, factored out from
4155 ...
4156 (convert_explicit_location_to_sals): ... this.
4157 (complete_label): New.
4158 (linespec_complete_label, find_label_symbols_in_block): New.
4159 (find_label_symbols): Add completion_mode parameter and adjust to
4160 call find_label_symbols_in_block.
4161 * linespec.h (linespec_complete_label): Declare.
4162
4163 2017-07-17 Pedro Alves <palves@redhat.com>
4164
4165 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4166 complete_symbol_mode parameter.
4167 * cli/cli-cmds.c (complete_command): Get the completion result out
4168 of the handle_brkchars tracker if used a custom word point.
4169 * completer.c: Include "linespec.h".
4170 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4171 (advance_to_expression_complete_word_point): New.
4172 (completion_tracker::completes_to_completion_word): New.
4173 (complete_files_symbols): Pass down
4174 complete_symbol_mode::EXPRESSION.
4175 (explicit_options, probe_options): New.
4176 (collect_explicit_location_matches): Complete on the
4177 explictit_loc->foo instead of word. Use
4178 linespec_complete_function. Handle MATCH_LINE. Handle offering
4179 keyword and options completions.
4180 (backup_text_ptr): Delete.
4181 (skip_keyword): New.
4182 (complete_explicit_location): Remove 'word' parameter. Add
4183 language, quoted_arg_start and quoted_arg_end parameters.
4184 Rewrite, parsing left to right.
4185 (location_completer): Rewrite.
4186 (location_completer_handle_brkchars): New function.
4187 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4188 (enum complete_line_internal_reason): Adjust comments.
4189 (completion_tracker::discard_completions): New.
4190 (completer_handle_brkchars_func_for_completer): Handle
4191 location_completer.
4192 (gdb_custom_word_point_brkchars)
4193 (gdb_org_rl_basic_quote_characters): New.
4194 (gdb_completion_word_break_characters_throw)
4195 (completion_find_completion_word): Handle trackers that use a
4196 custom word point.
4197 (completion_tracker::advance_custom_word_point_by): New.
4198 (completion_tracker::build_completion_result): Don't rely on
4199 readline appending the quote char.
4200 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4201 use a custom word point.
4202 (gdb_rl_attempted_completion_function): Restore
4203 rl_basic_quote_characters.
4204 * completer.h (class completion_tracker): Extend intro comment.
4205 (completion_tracker::set_quote_char)
4206 (completion_tracker::quote_char)
4207 (completion_tracker::set_use_custom_word_point)
4208 (completion_tracker::use_custom_word_point)
4209 (completion_tracker::custom_word_point)
4210 (completion_tracker::set_custom_word_point)
4211 (completion_tracker::advance_custom_word_point_by)
4212 (completion_tracker::completes_to_completion_word)
4213 (completion_tracker::discard_completions): New methods.
4214 (completion_tracker::m_quote_char)
4215 (completion_tracker::m_use_custom_word_point)
4216 (completion_tracker::m_custom_word_point): New fields.
4217 (advance_to_expression_complete_word_point): Declare.
4218 * f-lang.c (f_collect_symbol_completion_matches): Add
4219 complete_symbol_mode parameter.
4220 * language.h (struct language_defn)
4221 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4222 parameter.
4223 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4224 (linespec_complete_function): New function.
4225 (linespec_lexer_lex_keyword): Adjust.
4226 * linespec.h (linespec_keywords, linespec_complete_function): New
4227 declarations.
4228 * location.c (find_end_quote): New function.
4229 (explicit_location_lex_one): Add explicit_completion_info
4230 parameter. Save quoting info. Don't throw if being called for
4231 completion. Don't handle Ada operators here.
4232 (is_cp_operator, skip_op_false_positives, first_of)
4233 (explicit_location_lex_one_function): New function.
4234 (string_to_explicit_location): Replace 'dont_throw' parameter with
4235 an explicit_completion_info pointer parameter. Handle it. Don't
4236 use explicit_location_lex_one to lex function names. Use
4237 explicit_location_lex_one_function instead.
4238 * location.h (struct explicit_completion_info): New.
4239 (string_to_explicit_location): Replace 'dont_throw' parameter with
4240 an explicit_completion_info pointer parameter.
4241 * symtab.c (default_collect_symbol_completion_matches_break_on):
4242 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4243 (default_collect_symbol_completion_matches)
4244 (collect_symbol_completion_matches): Add complete_symbol_mode
4245 parameter.
4246 (collect_symbol_completion_matches_type): Pass down
4247 complete_symbol_mode::EXPRESSION.
4248 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4249 parameter. Handle LINESPEC mode.
4250 * symtab.h (complete_symbol_mode): New.
4251 (default_collect_symbol_completion_matches_break_on)
4252 (default_collect_symbol_completion_matches)
4253 (collect_symbol_completion_matches)
4254 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4255 parameter.
4256
4257 2017-07-17 Pedro Alves <palves@redhat.com>
4258
4259 * utils.c (enum class strncmp_iw_mode): New.
4260 (strcmp_iw): Rename to ...
4261 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4262 parameters. Handle them.
4263 (strncmp_iw): New.
4264 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4265 * utils.h (strncmp_iw): Declare.
4266 (strcmp_iw): Move describing comments here.
4267
4268 2017-07-17 Pedro Alves <palves@redhat.com>
4269
4270 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4271 CP_OPERATOR_STR.
4272 * c-typeprint.c (is_type_conversion_operator): Use
4273 CP_OPERATOR_STR.
4274 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4275 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4276 CP_OPERATOR_LEN.
4277 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4278 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4279 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4280 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4281 CP_OPERATOR_STR.
4282 * location.c: Include "cp-support.h".
4283 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4284 CP_OPERATOR_STR.
4285 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4286 CP_OPERATOR_LEN.
4287
4288 2017-07-17 Pedro Alves <palves@redhat.com>
4289
4290 * cli/cli-cmds.c (complete_command): Use a completion tracker
4291 along with completion_find_completion_word for handle_brkchars
4292 phase.
4293 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4294 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4295 (struct gdb_rl_completion_word_info): New.
4296 (gdb_rl_find_completion_word): New.
4297 (completion_find_completion_word): New.
4298 * completer.h (completion_find_completion_word): Declare.
4299
4300 2017-07-17 Pedro Alves <palves@redhat.com>
4301
4302 * ada-lang.c (symbol_completion_match): Adjust comments.
4303 (symbol_completion_add): Replace vector parameter with
4304 completion_tracker parameter. Use it.
4305 (ada_make_symbol_completion_list): Rename to...
4306 (ada_collect_symbol_completion_matches): ... this. Add
4307 completion_tracker parameter and use it.
4308 (ada_language_defn): Adjust.
4309 * break-catch-syscall.c (catch_syscall_completer): Adjust
4310 prototype and work with completion_tracker instead of VEC.
4311 * breakpoint.c (condition_completer): Adjust prototype and work
4312 with completion_tracker instead of VEC.
4313 * c-lang.c (c_language_defn, cplus_language_defn)
4314 (asm_language_defn, minimal_language_defn): Adjust to renames.
4315 * cli/cli-cmds.c (complete_command): Rework using
4316 completion_tracker. Catch exceptions when completing.
4317 * cli/cli-decode.c (integer_unlimited_completer)
4318 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4319 with completion_tracker instead of VEC.
4320 * command.h (struct completion_tracker): Forward declare.
4321 (completer_ftype, completer_handle_brkchars_ftype): Change
4322 types.
4323 (complete_on_cmdlist, complete_on_enum): Adjust.
4324 * completer.c: Include <algorithm>.
4325 (struct gdb_completer_state): New.
4326 (current_completion): New global.
4327 (readline_line_completion_function): Delete.
4328 (noop_completer, filename_completer)
4329 (filename_completer_handle_brkchars, complete_files_symbols)
4330 (linespec_location_completer): Adjust to work with a
4331 completion_tracker instead of a VEC.
4332 (string_or_empty): New.
4333 (collect_explicit_location_matches): Adjust to work with a
4334 completion_tracker instead of a VEC.
4335 (explicit_location_completer): Rename to ...
4336 (complete_explicit_location): ... this and adjust to work with a
4337 completion_tracker instead of a VEC.
4338 (location_completer): Adjust to work with a completion_tracker
4339 instead of a VEC.
4340 (add_struct_fields): Adjust to work with a completion_list instead
4341 of VEC.
4342 (expression_completer): Rename to ...
4343 (complete_expression): ... this and adjust to work with a
4344 completion_tracker instead of a VEC. Use complete_files_symbols.
4345 (expression_completer): Reimplement on top of complete_expression.
4346 (symbol_completer): Adjust to work with a completion_tracker
4347 instead of a VEC.
4348 (enum complete_line_internal_reason): Add describing comments.
4349 (complete_line_internal_normal_command): Adjust to work with a
4350 completion_tracker instead of a VEC.
4351 (complete_line_internal): Rename to ...
4352 (complete_line_internal_1): ... this and adjust to work with a
4353 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4354 handle_brkchars phase.
4355 (new_completion_tracker): Delete.
4356 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4357 complete_line_internal_1.
4358 (free_completion_tracker): Delete.
4359 (INITIAL_COMPLETION_HTAB_SIZE): New.
4360 (completion_tracker::completion_tracker)
4361 (completion_tracker::~completion_tracker): New.
4362 (maybe_add_completion): Delete.
4363 (completion_tracker::maybe_add_completion)
4364 (completion_tracker::add_completion)
4365 (completion_tracker::add_completions): New.
4366 (throw_max_completions_reached_error): Delete.
4367 (complete_line): Adjust to work with a completion_tracker instead
4368 of a VEC. Don't create a completion_tracker_t or check for max
4369 completions here.
4370 (command_completer, command_completer_handle_brkchars)
4371 (signal_completer, reg_or_group_completer_1)
4372 (reg_or_group_completer, default_completer_handle_brkchars):
4373 Adjust to work with a completion_tracker.
4374 (gdb_completion_word_break_characters_throw): New.
4375 (gdb_completion_word_break_characters): Reimplement.
4376 (line_completion_function): Delete.
4377 (completion_tracker::recompute_lowest_common_denominator)
4378 (expand_preserving_ws)
4379 (completion_tracker::build_completion_result)
4380 (completion_result::completion_result)
4381 (completion_result::completion_result)
4382 (completion_result::~completion_result)
4383 (completion_result::completion_result)
4384 (completion_result::release_match_list, compare_cstrings)
4385 (completion_result::sort_match_list)
4386 (completion_result::reset_match_list)
4387 (gdb_rl_attempted_completion_function_throw)
4388 (gdb_rl_attempted_completion_function): New.
4389 * completer.h (completion_list, struct completion_result)
4390 (class completion_tracker): New.
4391 (complete_line): Add completion_tracker parameter.
4392 (readline_line_completion_function): Delete.
4393 (gdb_rl_attempted_completion_function): New.
4394 (noop_completer, filename_completer, expression_completer)
4395 (location_completer, symbol_completer, command_completer)
4396 (signal_completer, reg_or_group_completer): Update prototypes.
4397 (completion_tracker_t, new_completion_tracker)
4398 (make_cleanup_free_completion_tracker): Delete.
4399 (enum maybe_add_completion_enum): Delete.
4400 (maybe_add_completion): Delete.
4401 (throw_max_completions_reached_error): Delete.
4402 * corefile.c (complete_set_gnutarget): Adjust to work with a
4403 completion_tracker instead of a VEC.
4404 * cp-abi.c (cp_abi_completer): Adjust to work with a
4405 completion_tracker instead of a VEC.
4406 * d-lang.c (d_language_defn): Adjust.
4407 * disasm.c (disassembler_options_completer): Adjust to work with a
4408 completion_tracker instead of a VEC.
4409 * f-lang.c (f_make_symbol_completion_list): Rename to ...
4410 (f_collect_symbol_completion_matches): ... this. Adjust to work
4411 with a completion_tracker instead of a VEC.
4412 (f_language_defn): Adjust.
4413 * go-lang.c (go_language_defn): Adjust.
4414 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
4415 Adjust to work with a completion_tracker instead of a VEC.
4416 * infrun.c (handle_completer): Likewise.
4417 * interps.c (interpreter_completer): Likewise.
4418 * interps.h (interpreter_completer): Likewise.
4419 * language.c (unknown_language_defn, auto_language_defn)
4420 (local_language_defn): Adjust.
4421 * language.h (language_defn::la_make_symbol_completion_list):
4422 Rename to ...
4423 (language_defn::la_collect_symbol_completion_matches): ... this
4424 and adjust to work with a completion_tracker instead of a VEC.
4425 * m2-lang.c (m2_language_defn): Adjust.
4426 * objc-lang.c (objc_language_defn): Adjust.
4427 * opencl-lang.c (opencl_language_defn): Adjust.
4428 * p-lang.c (pascal_language_defn): Adjust.
4429 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
4430 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
4431 with a completion_tracker.
4432 * rust-lang.c (rust_language_defn): Adjust.
4433 * symtab.c (free_completion_list, do_free_completion_list)
4434 (return_val, completion_tracker): Delete.
4435 (completion_list_add_name, completion_list_add_symbol)
4436 (completion_list_add_msymbol, completion_list_objc_symbol)
4437 (completion_list_add_fields, add_symtab_completions): Add
4438 completion_tracker parameter and use it.
4439 (default_make_symbol_completion_list_break_on_1): Rename to...
4440 (default_collect_symbol_completion_matches_break_on): ... this.
4441 Add completion_tracker parameter and use it instead of allocating
4442 a completion tracker here.
4443 (default_make_symbol_completion_list_break_on): Delete old
4444 implementation.
4445 (default_make_symbol_completion_list): Delete.
4446 (default_collect_symbol_completion_matches): New.
4447 (make_symbol_completion_list): Delete.
4448 (collect_symbol_completion_matches): New.
4449 (make_symbol_completion_type): Rename to ...
4450 (collect_symbol_completion_matches_type): ... this. Add
4451 completion_tracker parameter and use it instead of VEC.
4452 (make_file_symbol_completion_list_1): Rename to...
4453 (collect_file_symbol_completion_matches): ... this. Add
4454 completion_tracker parameter and use it instead of VEC.
4455 (make_file_symbol_completion_list): Delete.
4456 (add_filename_to_list): Use completion_list instead of a VEC.
4457 (add_partial_filename_data::list): Now a completion_list.
4458 (make_source_files_completion_list): Work with a completion_list
4459 instead of a VEC.
4460 * symtab.h: Include "completer.h".
4461 (default_make_symbol_completion_list_break_on)
4462 (default_make_symbol_completion_list, make_symbol_completion_list)
4463 (make_symbol_completion_type, make_file_symbol_completion_list)
4464 (make_source_files_completion_list): Delete.
4465 (default_collect_symbol_completion_matches_break_on)
4466 (default_collect_symbol_completion_matches)
4467 (collect_symbol_completion_matches)
4468 (collect_symbol_completion_matches_type)
4469 (collect_file_symbol_completion_matches)
4470 (make_source_files_completion_list): New.
4471 * top.c (init_main): Don't install a rl_completion_entry_function
4472 hook. Install a rl_attempted_completion_function hook instead.
4473 * tui/tui-layout.c (layout_completer): Adjust to work with a
4474 completion_tracker.
4475 * tui/tui-regs.c (tui_reggroup_completer):
4476 * tui/tui-win.c (window_name_completer, focus_completer)
4477 (winheight_completer): Adjust to work with a completion_tracker.
4478 * value.c: Include "completer.h".
4479 (complete_internalvar): Adjust to work with a completion_tracker.
4480 * value.h (complete_internalvar): Likewise.
4481
4482 2017-07-17 Pedro Alves <palves@redhat.com>
4483
4484 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
4485 renames.
4486 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
4487 comments to completer_ftype's declaration.
4488 <completer_handle_brkchars>: Change type to
4489 completer_handle_brkchars_ftype.
4490 * command.h (completer_ftype): Add describing comment and give
4491 names to parameters.
4492 (completer_ftype_void): Rename to ...
4493 (completer_handle_brkchars_ftype) ... this. Add describing comment.
4494 (set_cmd_completer_handle_brkchars): Adjust.
4495 * completer.c (filename_completer_handle_brkchars): New function.
4496 (complete_line_internal_normal_command): New function, factored
4497 out from ...
4498 (complete_line_internal): ... here.
4499 (command_completer_handle_brkchars)
4500 (default_completer_handle_brkchars)
4501 (completer_handle_brkchars_func_for_completer): New functions.
4502 * completer.h (set_gdb_completion_word_break_characters): Delete
4503 declaration.
4504 (completer_handle_brkchars_func_for_completer): New declaration.
4505 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
4506 completer_handle_brkchars_func_for_completer.
4507
4508 2017-07-17 Pedro Alves <palves@redhat.com>
4509
4510 * completer.c (symbol_completer): New function, based on
4511 make_symbol_completion_list_fn.
4512 * completer.h (symbol_completer): New declaration.
4513 * guile/scm-cmd.c (cmdscm_completers): Adjust.
4514 * python/py-cmd.c (completers): Adjust.
4515 * symtab.c (make_symbol_completion_list_fn): Delete.
4516 * symtab.h (make_symbol_completion_list_fn): Delete.
4517 * cli/cli-decode.c (add_cmd): Adjust.
4518
4519 2017-07-17 Pedro Alves <palves@redhat.com>
4520
4521 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
4522 * dwarf2read.c: Include "filename-seen-cache.h".
4523 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
4524 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
4525 * filename-seen-cache.c: New file.
4526 * filename-seen-cache.h: New file.
4527 * symtab.c: Include "filename-seen-cache.h".
4528 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
4529 (create_filename_seen_cache, clear_filename_seen_cache)
4530 (delete_filename_seen_cache, filename_seen): Delete, parts moved
4531 to filename-seen-cache.h/filename-seen-cache.c.
4532 (output_source_filename, sources_info)
4533 (maybe_add_partial_symtab_filename)
4534 (make_source_files_completion_list): Adjust to use
4535 filename_seen_cache.
4536
4537 2017-07-17 Pedro Alves <palves@redhat.com>
4538
4539 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
4540 fields.
4541 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
4542 dwarf2_debug_sections*)): New.
4543 (dwarf2_per_objfile::dwarf2_per_objfile(const
4544 dwarf2_per_objfile&)): Declare as deleted.
4545 (dwarf2_per_objfile::operator=): Declare as deleted.
4546 (dwarf2_per_objfile::dwarf2_per_objfile)
4547 (dwarf2_per_objfile::~dwarf2_per_objfile)
4548 (dwarf2_per_objfile::free_cached_comp_units): New.
4549 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
4550 ctor. Call dwarf2_per_objfile's ctor manually.
4551 (dwarf2_locate_sections): Deleted/refactored as ...
4552 (dwarf2_per_objfile::locate_sections): ... this new method.
4553 (free_cached_comp_units): Defer to
4554 dwarf2_per_objfile::free_cached_comp_units.
4555 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
4556
4557 2017-07-14 Tom Tromey <tom@tromey.com>
4558
4559 PR rust/21764:
4560 * rust-exp.y (convert_ast_to_expression): Add "want_type"
4561 parameter.
4562 <UNOP_SIZEOF>: Split into separate case.
4563 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
4564
4565 2017-07-14 Tom Tromey <tom@tromey.com>
4566
4567 PR rust/21763:
4568 * symtab.c (symbol_matches_domain): Add language_rust to special
4569 case.
4570 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
4571 treat LOC_TYPEDEF symbols as variables.
4572
4573 2017-07-14 Pedro Alves <palves@redhat.com>
4574
4575 * symtab.c (make_file_symbol_completion_list_1): Iterate over
4576 symtabs matching all symtabs with SRCFILE as file name instead of
4577 only considering the first hit, with lookup_symtab.
4578
4579 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4580
4581 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
4582 operator_name parameters.
4583 (gen_expr): Update function call.
4584
4585 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4586
4587 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
4588 parameter.
4589 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
4590 Likewise.
4591 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
4592 parameter, use agent_expr::gdbarch instead, update function
4593 calls.
4594 (locexpr_tracepoint_var_ref): Likewise.
4595 (loclist_tracepoint_var_ref): Likewise.
4596 * ax-gdb.c (gen_trace_static_fields): Likewise.
4597 (gen_traced_pop): Likewise.
4598 (gen_frame_args_address): Likewise.
4599 (gen_frame_locals_address): Likewise.
4600 (gen_var_ref): Likewise.
4601 (gen_struct_ref_recursive): Likewise.
4602 (gen_static_field): Likewise.
4603 (gen_maybe_namespace_elt): Likewise.
4604 (gen_expr): Likewise.
4605 (gen_trace_for_var): Likewise.
4606 (gen_trace_for_expr): Likewise.
4607 (gen_trace_for_return_address): Likewise.
4608
4609 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4610
4611 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
4612 parameter.
4613 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
4614
4615 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4616
4617 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
4618 from ax, update calls.
4619 (gen_usual_arithmetic): Likewise.
4620 (gen_integral_promotions): Likewise.
4621 (gen_bitfield_ref): Likewise.
4622 (gen_primitive_field): Likewise.
4623 (gen_struct_ref_recursive): Likewise.
4624 (gen_struct_ref): Likewise.
4625 (gen_maybe_namespace_elt): Likewise.
4626 (gen_struct_elt_for_reference): Likewise.
4627 (gen_namespace_elt): Likewise.
4628 (gen_aggregate_elt_ref): Likewise.
4629 (gen_expr): Get gdbarch from ax, update calls.
4630 (gen_expr_binop_rest): Likewise.
4631
4632 2017-07-13 Pedro Alves <palves@redhat.com>
4633
4634 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
4635 as default tdesc.
4636 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
4637 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
4638 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
4639 tdesc_amd64_linux as default tdesc. Get final tdesc from the
4640 tdep.
4641 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
4642 Get final tdesc from the tdep.
4643 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
4644 default tdesc.
4645 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4646 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4647 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
4648 Use it as default tdesc.
4649 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
4650 down to amd_init_abi. No longer handle fallback tdesc here.
4651 * amd64-tdep.h (tdesc_x32): Declare.
4652 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
4653 parameter.
4654 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
4655 as default tdesc.
4656
4657 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4658
4659 * s390-linux-tdep.c (s390_process_record): Add support for
4660 instructions new in arch12.
4661
4662 2017-07-11 John Baldwin <jhb@FreeBSD.org>
4663
4664 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
4665 PT_GETFSBASE and PT_GETGSBASE.
4666 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
4667 PT_SETGSBASE.
4668
4669 2017-07-11 John Baldwin <jhb@FreeBSD.org>
4670
4671 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
4672 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
4673 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
4674 those rules.
4675 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
4676 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
4677 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
4678 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
4679 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
4680 * features/i386/amd64.xml: Add 64bit-segments.xml.
4681 * features/i386/amd64-avx-avx512.c: Regenerated.
4682 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
4683 * features/i386/amd64-avx-mpx.c: Regenerated.
4684 * features/i386/amd64-avx.c: Regenerated.
4685 * features/i386/amd64-mpx.c: Regenerated.
4686 * features/i386/amd64.c: Regenerated.
4687 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
4688 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4689 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
4690 * regformats/i386/amd64-avx.dat: Regenerated.
4691 * regformats/i386/amd64-mpx.dat: Regenerated.
4692 * regformats/i386/amd64.dat: Regenerated.
4693
4694 2017-07-10 Yao Qi <yao.qi@linaro.org>
4695
4696 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4697 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4698
4699 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
4700
4701 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
4702 unsetenv.
4703 * gnulib/aclocal.m4: Regenerate.
4704 * gnulib/config.in: Regenerate.
4705 * gnulib/configure: Regenerate.
4706 * gnulib/import/Makefile.am: Regenerate.
4707 * gnulib/import/Makefile.in: Regenerate.
4708 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4709 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4710 * gnulib/import/m4/environ.m4: New file.
4711 * gnulib/import/m4/setenv.m4: New file.
4712 * gnulib/import/setenv.c: New file.
4713 * gnulib/import/unsetenv.c: New file.
4714
4715 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
4716
4717 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
4718 address when op is DW_OP_addr.
4719
4720 2017-07-09 Tom Tromey <tom@tromey.com>
4721
4722 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
4723 check and apply to outer type.
4724
4725 2017-07-07 John Baldwin <jhb@FreeBSD.org>
4726
4727 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
4728 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
4729 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
4730 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
4731
4732 2017-07-07 John Baldwin <jhb@FreeBSD.org>
4733
4734 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
4735
4736 2017-07-07 John Baldwin <jhb@FreeBSD.org>
4737
4738 * corelow.c (get_core_siginfo): Remove.
4739 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
4740 instead of get_core_siginfo.
4741 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
4742 * gdbarch.h: Re-generate.
4743 * gdbarch.c: Re-generate.
4744 * linux-tdep.c (linux_core_xfer_siginfo): New.
4745 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
4746
4747 2017-07-07 John Baldwin <jhb@FreeBSD.org>
4748
4749 * corelow.c (thread_section_name): Move to ...
4750 * gdbcore.h (thread_section_name): ... here.
4751
4752 2017-07-07 John Baldwin <jhb@FreeBSD.org>
4753
4754 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
4755 (struct siginfo32): New.
4756 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
4757 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
4758 via ptrace(PT_LWPINFO).
4759
4760 2017-07-07 John Baldwin <jhb@FreeBSD.org>
4761
4762 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
4763 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
4764 (fbsd_get_siginfo_type): New.
4765 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
4766 (_initialize_fbsd_tdep): New.
4767
4768 2017-07-06 David Blaikie <dblaikie@gmail.com>
4769
4770 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
4771 a singular dwo_unit*) to support multiple CUs in the same way that
4772 multiple TUs are supported.
4773 (create_cus_hash_table): Replace create_dwo_cu with a function for
4774 parsing multiple CUs from a DWO file.
4775 (open_and_init_dwo_file): Use create_cus_hash_table rather than
4776 create_dwo_cu.
4777 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
4778 htab_find, rather than comparing the signature to a singleton CU in
4779 the dwo_file.
4780
4781 2017-07-06 Pedro Alves <palves@redhat.com>
4782
4783 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
4784
4785 2017-07-04 Pedro Alves <palves@redhat.com>
4786
4787 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
4788 * gdbtypes.h (TYPE_STATIC): Delete.
4789 (struct fn_field) <is_public, is_abstract, is_static, is_final,
4790 is_synchronized, is_native>: Delete.
4791 <dummy>: Bump.
4792 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
4793 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
4794 (TYPE_FN_FIELD_ABSTRACT): Delete.
4795
4796 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
4797
4798 * buffer.h (buffer_finish): Fix spelling mistakes.
4799
4800 2017-07-01 Eli Zaretskii <eliz@gnu.org>
4801
4802 * .dir-locals.el: Automatically switch to C-style comments in
4803 versions of Emacs that support the feature.
4804
4805 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
4806 Pedro Alves <palves@redhat.com>
4807
4808 PR cli/21688
4809 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
4810 (process_next_line): New variable 'inline_cmd'.
4811 Adjust 'if' clauses for "python", "compile" and "guile" to use
4812 'command_name_equals' and check for '!inline_cmd'.
4813
4814 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
4815
4816 PR cli/21688
4817 * cli/cli-script.c (command_name_equals_not_inline): New function.
4818 (process_next_line): Adjust 'if' clauses for "python", "compile"
4819 and "guile" to use command_name_equals_not_inline.
4820
4821 2017-06-29 Pedro Alves <palves@redhat.com>
4822
4823 * completer.c (expression_completer): Call
4824 linespec_location_completer instead of location_completer.
4825
4826 2017-06-29 Pedro Alves <palves@redhat.com>
4827
4828 * completer.c (expression_completer): Remove code that recomputes
4829 'text' from 'word'.
4830
4831 2017-06-29 Yao Qi <yao.qi@linaro.org>
4832
4833 * regformats/regdat.sh: Generate code with
4834 "ifndef IN_PROCESS_AGENT".
4835
4836 2017-06-28 Pedro Alves <palves@redhat.com>
4837
4838 * command.h: Include "common/scoped_restore.h".
4839
4840 2017-06-28 Yao Qi <yao.qi@linaro.org>
4841
4842 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
4843 instead of obstack_grow.
4844
4845 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
4846
4847 PR gdb/21337
4848 * symfile.c (reread_symbols): Call objfiles_changed just before
4849 read_symbols.
4850
4851 2017-06-27 Pedro Alves <palves@redhat.com>
4852
4853 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
4854 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
4855 (completion_list_add_symbol, completion_list_add_msymbol):
4856 ... these new functions.
4857 (add_symtab_completions)
4858 (default_make_symbol_completion_list_break_on_1): Adjust.
4859
4860 2017-06-27 Pedro Alves <palves@redhat.com>
4861
4862 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
4863 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
4864 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
4865 dtor.
4866 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
4867 'storage_obstack' field an auto_obstack. In-class initialize all
4868 non-bitfield fields. Make minsyms_read bool.
4869 * symfile.c (read_symbols): Adjust.
4870
4871 2017-06-27 Alan Hayward <alan.hayward@arm.com>
4872
4873 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
4874 (gdbsim_store_register): Likewise.
4875
4876 2017-06-27 Pedro Alves <palves@redhat.com>
4877
4878 * c-exp.y (name_obstack): Now an auto_obstack.
4879 (yylex): Use auto_obstack::clear.
4880 (c_parse): Use auto_obstack::clear instead of reinitializing and
4881 freeing the obstack.
4882 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
4883 * d-exp.y (name_obstack): Now an auto_obstack.
4884 (yylex): Use auto_obstack::clear.
4885 (d_parse): Use auto_obstack::clear instead of reinitializing and
4886 freeing the obstack.
4887 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
4888 auto_obstack.
4889 * dwarf2read.c (create_addrmap_from_index)
4890 (dwarf2_build_psymtabs_hard)
4891 (update_enumeration_type_from_children): Likewise.
4892 * gdb_obstack.h (auto_obstack): New type.
4893 * go-exp.y (name_obstack): Now an auto_obstack.
4894 (build_packaged_name): Use auto_obstack::clear.
4895 (go_parse): Use auto_obstack::clear instead of reinitializing and
4896 freeing the obstack.
4897 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
4898 auto_obstack.
4899 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
4900 * rust-exp.y (work_obstack): Now an auto_obstack.
4901 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
4902 reinitializing and freeing the obstack.
4903 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
4904 (host_char_to_target): Use auto_obstack.
4905 * utils.h (make_cleanup_obstack_free): Delete declaration.
4906 * valprint.c (generic_emit_char, generic_printstr): Use
4907 auto_obstack.
4908
4909 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
4910
4911 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
4912 thread.
4913 (darwin_init_thread_list): Don't update dummy thread.
4914 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
4915
4916 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4917
4918 * record-full.c (netorder16): Remove.
4919
4920 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4921
4922 * common/diagnostics.h: Define macros for GCC.
4923 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
4924 * common/vec.h: Include diagnostics.h.
4925 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
4926 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
4927 warning.
4928
4929 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4930
4931 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
4932 New macro.
4933 * ada-lex.l: Ignore deprecated register warnings.
4934
4935 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4936
4937 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
4938 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
4939
4940 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4941
4942 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
4943 its own line.
4944
4945 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4946
4947 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
4948
4949 2017-06-23 Alan Hayward <alan.hayward@arm.com>
4950
4951 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
4952 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
4953 (xtensa_register_read_masked): Likewise.
4954
4955 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
4956
4957 * common/environ.c (gdb_environ::unset): Update comment.
4958
4959 2017-06-22 Alan Hayward <alan.hayward@arm.com>
4960
4961 * python/py-unwind.c (pyuw_sniffer): Allocate space for
4962 registers.
4963
4964 2017-06-22 Alan Hayward <alan.hayward@arm.com>
4965
4966 * record-full.c (record_full_exec_insn): Use byte_vector.
4967
4968 2017-06-22 Yao Qi <yao.qi@linaro.org>
4969
4970 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
4971 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4972
4973 2017-06-22 Alan Hayward <alan.hayward@arm.com>
4974
4975 * remote.c (cached_reg): Move from here...
4976 * regcache.h (cached_reg): ...to here.
4977 * python/py-unwind.c (struct reg_info): Remove.
4978 (cached_frame_info): Use cached_reg_t.
4979 (pyuw_prev_register): Likewise.
4980 (pyuw_sniffer): Use cached_reg_t and allocate registers.
4981 (pyuw_dealloc_cache): Free all registers.
4982
4983 2017-06-22 Pedro Alves <palves@redhat.com>
4984 Simon Marchi <simon.marchi@ericsson.com>
4985
4986 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
4987 warning.
4988 * common/diagnostics.h: New file.
4989
4990 2017-06-22 Pedro Alves <palves@redhat.com>
4991
4992 * common/agent.h: Add include guards.
4993
4994 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
4995
4996 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
4997 talk about addressable units instead of bytes.
4998
4999 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5000
5001 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
5002 of '::const_iterator'.
5003
5004 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5005
5006 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5007 'unittests/environ-selftests.c'.
5008 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
5009 * charset.c (find_charset_names): Declare object 'iconv_env'.
5010 Update code to use 'iconv_env' object. Remove call to
5011 'free_environ'.
5012 * common/environ.c: Include <utility>.
5013 (make_environ): Delete function.
5014 (free_environ): Delete function.
5015 (gdb_environ::clear): New function.
5016 (gdb_environ::operator=): New function.
5017 (gdb_environ::get): Likewise.
5018 (environ_vector): Delete function.
5019 (set_in_environ): Delete function.
5020 (gdb_environ::set): New function.
5021 (unset_in_environ): Delete function.
5022 (gdb_environ::unset): New function.
5023 (gdb_environ::envp): Likewise.
5024 * common/environ.h: Include <vector>.
5025 (struct gdb_environ): Delete; transform into...
5026 (class gdb_environ): ... this class.
5027 (free_environ): Delete prototype.
5028 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
5029 environ_vector): Likewise.
5030 * infcmd.c (run_command_1): Update code to call
5031 'envp' from 'gdb_environ' class.
5032 (environment_info): Update code to call methods from 'gdb_environ'
5033 class.
5034 (unset_environment_command): Likewise.
5035 (path_info): Likewise.
5036 (path_command): Likewise.
5037 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
5038 (inferior::inferior): Initialize 'environment' using the host's
5039 information.
5040 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
5041 Include "environ.h".
5042 (class inferior) <environment>: Change type from 'struct
5043 gdb_environ' to 'gdb_environ'.
5044 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
5045 methods from 'gdb_environ' class.
5046 * solib.c (solib_find_1): Likewise
5047 * unittests/environ-selftests.c: New file.
5048
5049 2017-06-20 Yao Qi <yao.qi@linaro.org>
5050
5051 * features/i386/i386-linux.xml: Exchange the order of including
5052 32bit-linux.xml and 32bit-sse.xml.
5053 * features/i386/i386-linux.c: Regenerated.
5054
5055 2017-06-20 Yao Qi <yao.qi@linaro.org>
5056
5057 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
5058 Delete copy ctor and assignment operator.
5059 (tdesc_type): Likewise.
5060 (tdesc_feature): Likewise.
5061 (tdesc_free_reg): Remove.
5062 (tdesc_create_reg): Use new.
5063 (tdesc_free_type): Remove.
5064 (tdesc_create_vector): Use new.
5065 (tdesc_create_union): Likewise.
5066 (tdesc_create_flags): Likewise.
5067 (tdesc_create_enum): Likewise.
5068 (tdesc_free_feature): Delete.
5069 (free_target_description): Use delete.
5070
5071 2017-06-19 John Baldwin <jhb@FreeBSD.org>
5072
5073 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
5074 registers.
5075
5076 2017-06-19 Pedro Alves <palves@redhat.com>
5077
5078 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
5079 after gdb::unlinker.
5080
5081 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
5082
5083 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
5084 gdb_environ to access an environment variable.
5085
5086 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5087
5088 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
5089 gdb_byte*.
5090
5091 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5092
5093 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
5094
5095 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5096
5097 * configure: Re-generate.
5098 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
5099
5100 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5101
5102 * configure: Re-generate.
5103 * warning.m4: Pass -Werror to compiler when checking for
5104 supported warning flags.
5105
5106 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5107
5108 * Makefile.in (COMPILE.pre): Add "-x c++".
5109
5110 2017-06-16 Alan Hayward <alan.hayward@arm.com>
5111 Pedro Alves <palves@redhat.com>
5112 Yao Qi <yao.qi@linaro.org>
5113
5114 * defs.h (RequireLongest): New.
5115 (extract_integer): Declare function template.
5116 (extract_signed_integer): Remove the declaration, but define it
5117 static inline.
5118 (extract_unsigned_integer): Likewise.
5119 (store_integer): Declare function template.
5120 (store_signed_integer): Remove the declaration, but define it
5121 static inline.
5122 (store_unsigned_integer): Likewise.
5123 * findvar.c (extract_integer): New function template.
5124 (extract_signed_integer): Remove.
5125 (extract_unsigned_integer): Remove.
5126 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5127 instantiations.
5128 (store_integer): New function template.
5129 (store_signed_integer): Remove.
5130 (store_unsigned_integer): Remove.
5131 (store_integer): Explicit instantiations.
5132 * regcache.c (regcache_raw_read_signed): Update.
5133 (regcache::raw_read): New function.
5134 (regcache::raw_read_signed): Remove.
5135 (regcache::raw_read_unsigned): Remove.
5136 (regcache_raw_read_unsigned): Update.
5137 (regcache_raw_write_unsigned): Update.
5138 (regcache::raw_write_signed): Remove.
5139 (regcache::raw_write): New function.
5140 (regcache_cooked_read_signed): Update.
5141 (regcache::raw_write_unsigned): Remove.
5142 (regcache::cooked_read_signed): Remove.
5143 (regcache_cooked_read_unsigned): Update.
5144 (regcache::cooked_read_unsigned): Remove.
5145 (regcache_cooked_write_signed): Update.
5146 (regcache_cooked_write_unsigned): Update.
5147 * regcache.h (regcache) <raw_read_signed>: Remove.
5148 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5149 <raw_read, raw_write>: New.
5150 <cooked_read_signed, cooked_write_signed>: Remove.
5151 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5152 <cooked_read, cooked_write>: New.
5153 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5154 (sh64_pseudo_register_write): Update.
5155
5156 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5157
5158 * arc-tdep.c (arc_disassembler_options): New variable.
5159 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5160 of default_print_insn.
5161 (arc_delayed_print_insn): Set info->section when needed,
5162 use default_print_insn to retrieve a disassembler.
5163
5164 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5165
5166 PR gdb/21574
5167 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5168 to mention $SHELL and startup-with-shell.
5169
5170 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5171
5172 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5173
5174 2017-06-14 Yao Qi <yao.qi@linaro.org>
5175
5176 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5177 default_print_insn instead of print_insn_aarch64.
5178 * arm-tdep.c (gdb_print_insn_arm): Call
5179 default_print_insn instead of print_insn_big_arm
5180 and print_insn_little_arm.
5181 * i386-tdep.c (i386_print_insn): Call default_print_insn
5182 instead of print_insn_i386.
5183 * ia64-tdep.c (ia64_print_insn): Call
5184 default_print_insn instead of print_insn_ia64.
5185 * mips-tdep.c (gdb_print_insn_mips): Call
5186 default_print_insn instead of print_insn_big_mips
5187 and print_insn_little_mips.
5188 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5189 instead of print_insn_spu.
5190
5191 2017-06-14 Pedro Alves <palves@redhat.com>
5192
5193 * ada-lang.c: Include "common/byte-vector.h".
5194 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5195 * charset.c (wchar_iterator::iterate): Resize the vector instead
5196 of reserving it.
5197 * common/byte-vector.h: Include "common/def-vector.h".
5198 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5199 * cli/cli-dump.c: Include "common/byte-vector.h".
5200 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5201 * common/byte-vector.h: New file.
5202 * common/def-vector.h: New file.
5203 * common/default-init-alloc.h: New file.
5204 * dwarf2loc.c: Include "common/byte-vector.h".
5205 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5206 instead of reserving it.
5207 * dwarf2read.c: Include "common/byte-vector.h".
5208 (data_buf::m_vec): Now a gdb::byte_vector.
5209 * gdb_regex.c: Include "common/def-vector.h".
5210 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5211 * mi/mi-main.c: Include "common/byte-vector.h".
5212 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5213 * printcmd.c: Include "common/byte-vector.h".
5214 (print_scalar_formatted): Use gdb::byte_vector.
5215 * valprint.c: Include "common/byte-vector.h".
5216 (maybe_negate_by_bytes, print_decimal_chars): Use
5217 gdb::byte_vector.
5218
5219 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5220
5221 * darwin-nat.c: Include "nat/fork-inferior.h".
5222
5223 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5224
5225 * configure.nat: Factor out Darwin bits that are not
5226 architecture-specific. Add fork-inferior.o.
5227
5228 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5229
5230 * configure.nat: Factor out AIX bits that are not
5231 architecture-specific. Add fork-inferior.o.
5232
5233 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5234
5235 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5236 (read_pieced_value, write_pieced_value): ...here. Reduce to
5237 wrappers that just call rw_pieced_value.
5238
5239 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5240
5241 * dwarf2loc.c (write_pieced_value): When writing the data for a
5242 memory piece, use write_memory_with_notification instead of
5243 write_memory.
5244
5245 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5246
5247 * valops.c (read_value_memory): Change embedded_offset to
5248 represent a bit offset instead of a byte offset.
5249 * value.h (read_value_memory): Adjust comment.
5250
5251 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5252
5253 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5254 dest_offset_bits and source_offset_bits.
5255 (write_pieced_value): Likewise.
5256
5257 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5258
5259 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5260 given by DW_OP_bit_piece.
5261 (write_pieced_value): Likewise.
5262
5263 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5264
5265 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5266 some other preparations to the places where sufficient information
5267 is available.
5268 (write_pieced_value): Likewise.
5269
5270 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5271
5272 * dwarf2loc.c (bits_to_bytes): New function.
5273 (read_pieced_value): Fix offset calculations for register pieces
5274 on big-endian targets.
5275 (write_pieced_value): Likewise.
5276
5277 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5278
5279 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5280 (write_pieced_value): Likewise.
5281
5282 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5283
5284 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5285 transfer the source value's least significant bits, instead of its
5286 lowest-addressed ones. Rename type_len to max_offset.
5287 (read_pieced_value): Mirror above changes to write_pieced_value as
5288 applicable.
5289
5290 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5291
5292 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5293 truncate full bytes from dest_offset_bits before using it as an
5294 offset into the buffer.
5295
5296 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5297
5298 * dwarf2loc.c (write_pieced_value): Include transfer size in
5299 byte-wise check.
5300
5301 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5302
5303 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5304 calculation of this_size.
5305
5306 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5307
5308 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5309 when targeting a bit-field.
5310 (write_pieced_value): Likewise.
5311
5312 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5313
5314 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5315 (allocate_piece_closure): Drop addr_size parameter.
5316 (dwarf2_evaluate_loc_desc_full): Adjust call to
5317 allocate_piece_closure.
5318
5319 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5320
5321 PR gdb/21226
5322 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5323 the LSB end, independent of endianness.
5324
5325 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5326
5327 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5328 size capping.
5329
5330 2017-06-13 Yao Qi <yao.qi@linaro.org>
5331
5332 * mips-linux-nat.c: Move include features/mips*-linux.c to
5333 mips-linux-tdep.c.
5334 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5335 to mips-linux-tdep.c.
5336 * mips-linux-tdep.c: Include features/mips*-linux.c
5337 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5338 functions.
5339 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5340 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5341 (tdesc_mips64_dsp_linux): Declare.
5342
5343 2017-06-12 Tom Tromey <tom@tromey.com>
5344
5345 * valprint.h (val_print_type_code_int): Remove.
5346 * valprint.c (generic_val_print_int): Always call
5347 val_print_scalar_formatted.
5348 (val_print_type_code_int): Remove.
5349 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5350 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5351 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5352 * ada-valprint.c (ada_val_print_num): Use
5353 val_print_scalar_formatted.
5354
5355 2017-06-12 Tom Tromey <tom@tromey.com>
5356
5357 * printcmd.c (print_scalar_formatted): Unify the two switches.
5358 Don't convert scalars to LONGEST.
5359
5360 2017-06-12 Tom Tromey <tom@tromey.com>
5361
5362 PR exp/16225:
5363 * valprint.h (print_decimal_chars): Update.
5364 * valprint.c (maybe_negate_by_bytes): New function.
5365 (print_decimal_chars): Add "is_signed" argument.
5366 * printcmd.c (print_scalar_formatted): Update.
5367
5368 2017-06-12 Tom Tromey <tom@tromey.com>
5369
5370 PR exp/16225:
5371 * valprint.h (print_binary_chars, print_hex_chars): Update.
5372 * valprint.c (val_print_type_code_int): Update.
5373 (print_binary_chars): Add "zero_pad" argument.
5374 (emit_octal_digit): New function.
5375 (print_octal_chars): Don't zero-pad.
5376 (print_decimal_chars): Likewise.
5377 (print_hex_chars): Add "zero_pad" argument.
5378 * sh64-tdep.c (sh64_do_fp_register): Update.
5379 * regcache.c (regcache::dump): Update.
5380 * printcmd.c (print_scalar_formatted): Update.
5381 * infcmd.c (default_print_one_register_info): Update.
5382
5383 2017-06-12 Pedro Alves <palves@redhat.com>
5384 Alan Hayward <alan.hayward@arm.com>
5385
5386 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5387 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5388 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5389 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5390 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5391
5392 2017-06-12 Pedro Alves <palves@redhat.com>
5393
5394 * dwarf2read.c (mapped_symtab::data): Now a vector of
5395 symtab_index_entry instead of vector of
5396 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5397 whether an element's name is NULL instead of checking whether the
5398 element itself is NULL.
5399 (find_slot): Change return type. Adjust.
5400 (hash_expand, , add_index_entry, uniquify_cu_indices)
5401 (write_hash_table): Adjust.
5402
5403 2017-06-12 Pedro Alves <palves@redhat.com>
5404
5405 * dwarf2read.c (recursively_count_psymbols): New function.
5406 (write_psymtabs_to_index): Call it to compute number of psyms and
5407 pass estimate size of psyms_seen to unordered_set's ctor.
5408
5409 2017-06-12 Pedro Alves <palves@redhat.com>
5410
5411 * dwarf2read.c (write_hash_table): Check if key already exists
5412 before emplacing.
5413
5414 2017-06-12 Pedro Alves <palves@redhat.com>
5415
5416 * dwarf2read.c (data_buf::append_space): Rename to...
5417 (data_buf::grow): ... this, and make private. Adjust all callers.
5418 (data_buf::append_uint): New method.
5419 (add_address_entry, write_one_signatured_type)
5420 (write_psymtabs_to_index): Use it.
5421
5422 2017-06-12 Pedro Alves <palves@redhat.com>
5423
5424 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
5425 (file_write (FILE *, const std::vector<Elem>&)): Delete.
5426 (data_buf::file_write): Call ::fwrite directly.
5427
5428 2017-06-12 Pedro Alves <palves@redhat.com>
5429
5430 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
5431 std::vector::erase.
5432
5433 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5434
5435 Code cleanup: C++ify .gdb_index producer.
5436 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
5437 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
5438 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
5439 (create_strtab, add_string): Remove.
5440 (file_write, data_buf): New.
5441 (struct symtab_index_entry): Use std::vector for cu_indices.
5442 (struct mapped_symtab): Use std::vector for data.
5443 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
5444 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
5445 Remove.
5446 (find_slot): Change return type. Update it to the new data structures.
5447 (hash_expand, add_index_entry): Update it to the new data structures.
5448 (offset_type_compare): Remove.
5449 (uniquify_cu_indices): Update it to the new data structures.
5450 (c_str_view, c_str_view_hasher, vector_hasher): New.
5451 (add_indices_to_cpool): Remove.
5452 (write_hash_table): Update it to the new data structures.
5453 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
5454 (eq_psymtab_cu_index): Remove.
5455 (psym_index_map): New typedef.
5456 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
5457 reference and std::unordered_map for cu_index_htab.
5458 (add_address_entry, add_address_entry_worker, write_address_map)
5459 (write_psymbols): Update it to the new data structures.
5460 (write_obstack): Remove.
5461 (struct signatured_type_index_data): Change types_list to a data_buf
5462 reference and psyms_seen to a std::unordered_set reference.
5463 (write_one_signatured_type, recursively_write_psymbols)
5464 (write_psymtabs_to_index): Update it to the new data structures.
5465
5466 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
5467
5468 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
5469 separate-debug-file commands.
5470 * symfile.h (separate_debug_file_debug): New global.
5471 * symfile.c (separate_debug_file_debug): New global.
5472 (separate_debug_file_exists, find_separate_debug_file): Add
5473 debug output.
5474 (_initialize_symfile): Add "set debug separate-debug-file"
5475 command.
5476 * build-id.c (build_id_to_debug_bfd,
5477 find_separate_debug_file_by_buildid): Add debug output.
5478
5479 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5480
5481 * gdbarch.sh (displaced_step_free_closure): Remove.
5482 * gdbarch.h, gdbarch.c: Re-generate.
5483 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
5484 displaced_step_free_closure.
5485 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
5486 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
5487 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5488 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
5489 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5490 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5491 * arch-utils.h (simple_displaced_step_free_closure): Remove.
5492 * arch-utils.c (simple_displaced_step_free_closure): Remove.
5493 * infrun.c (displaced_step_clear): Call xfree instead of
5494 gdbarch_displaced_step_free_closure.
5495
5496 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
5497
5498 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
5499 NULL".
5500
5501 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5502
5503 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
5504 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
5505 (mn10300_push_dummy_call): Likewise.
5506
5507 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5508
5509 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
5510
5511 2017-06-08 Alan Hayward <alan.hayward@arm.com>
5512
5513 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
5514
5515 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5516
5517 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
5518 able to start inferiors using a shell.
5519 (New remote packets): Announce new packet "QStartupWithShell".
5520 * remote.c: Add PACKET_QStartupWithShell.
5521 (extended_remote_create_inferior): Handle new
5522 PACKET_QStartupWithShell.
5523 (remote_protocol_features) <QStartupWithShell>: New entry for
5524 PACKET_QStartupWithShell.
5525 (_initialize_remote): Call "add_packet_config_cmd" for
5526 QStartupShell.
5527
5528 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5529 Pedro Alves <palves@redhat.com>
5530
5531 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
5532 and "nat/fork-inferior.h".
5533 * common/common-inferior.h: New file, with contents from
5534 "gdb/inferior.h".
5535 * commom/common-utils.c: Include "common-utils.h".
5536 (stringify_argv): New function.
5537 * common/common-utils.h (stringify_argv): New prototype.
5538 * configure.nat: Add "fork-inferior.o" as a dependency for
5539 "*linux*", "fbsd*" and "nbsd*" hosts.
5540 * corefile.c (get_exec_file): Update comment.
5541 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
5542 instead of "startup_inferior".
5543 (darwin_create_inferior): Call "add_thread_silent" after
5544 "fork_inferior".
5545 * fork-child.c: Cleanup unnecessary includes.
5546 (SHELL_FILE): Move to "common/common-fork-child.c".
5547 (environ): Likewise.
5548 (exec_wrapper): Initialize.
5549 (get_exec_wrapper): New function.
5550 (breakup_args): Move to "common/common-fork-child.c"; rename to
5551 "breakup_args_for_exec".
5552 (escape_bang_in_quoted_argument): Move to
5553 "common/common-fork-child.c".
5554 (saved_ui): New variable.
5555 (prefork_hook): New function.
5556 (postfork_hook): Likewise.
5557 (postfork_child_hook): Likewise.
5558 (gdb_startup_inferior): Likewise.
5559 (fork_inferior): Move to "common/common-fork-child.c". Update
5560 function to support gdbserver.
5561 (startup_inferior): Likewise.
5562 * gdbcore.h (get_exec_file): Remove declaration.
5563 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
5564 instead of "startup_inferior". Call "add_thread_silent" after
5565 "fork_inferior".
5566 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
5567 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
5568 instead of "startup_inferior". Call "add_thread_silent" after
5569 "fork_inferior".
5570 * inferior.h: Include "common-inferior.h".
5571 (trace_start_error): Move to "common/common-utils.h".
5572 (trace_start_error_with_name): Likewise.
5573 (fork_inferior): Move prototype to "nat/fork-inferior.h".
5574 (startup_inferior): Likewise.
5575 (gdb_startup_inferior): New prototype.
5576 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
5577 * nat/fork-inferior.h: New file.
5578 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
5579 instead of "startup_inferior". Call "add_thread_silent" after
5580 "fork_inferior".
5581 * target.h (target_terminal_init): Move prototype to
5582 "target/target.h".
5583 (target_terminal_inferior): Likewise.
5584 (target_terminal_ours): Likewise.
5585 * target/target.h (target_terminal_init): New prototype, moved
5586 from "target.h".
5587 (target_terminal_inferior): Likewise.
5588 (target_terminal_ours): Likewise.
5589 * utils.c (gdb_flush_out_err): New function.
5590
5591 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5592
5593 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
5594 * common/common-gdbthread.h: New file, with parts from
5595 "gdb/gdbthread.h".
5596 * gdbthread.h: Include "common-gdbthread.h".
5597 (switch_to_thread): Moved to "common/common-gdbthread.h".
5598
5599 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5600
5601 * Makefile.in (SFILES): Add "common/job-control.c".
5602 (HFILES_NO_SRCDIR): Add "common/job-control.h".
5603 (COMMON_OBS): Add "job-control.o".
5604 * common/job-control.c: New file, with contents from
5605 "gdb/inflow.c".
5606 * common/job-control.h: New file, with contents from "terminal.h".
5607 * fork-child.c: Include "job-control.h".
5608 * inflow.c: Include "job-control.h".
5609 (gdb_setpgid): Move to "common/common-inflow.c".
5610 (_initialize_inflow): Move setting of "job_control" to
5611 "handle_job_control".
5612 * terminal.h (job_control): Moved to "common/common-terminal.h".
5613 (gdb_setpgid): Likewise.
5614 * top.c: Include "job_control.h".
5615 * utils.c: Likewise.
5616 (job_control): Moved to "job-control.c".
5617
5618 2017-06-07 Pedro Alves <palves@redhat.com>
5619
5620 * Makefile.in (SFILES): Add gdb_regex.c.
5621 (COMMON_OBS): Add gdb_regex.o.
5622 * ada-lang.c (ada_add_standard_exceptions)
5623 (ada_add_exceptions_from_frame, name_matches_regex)
5624 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
5625 parameter type to compiled_regex. Adjust.
5626 (ada_exceptions_list): Use compiled_regex.
5627 * break-catch-throw.c (exception_catchpoint::pattern): Now a
5628 std::unique_ptr<compiled_regex>.
5629 (exception_catchpoint::~exception_catchpoint): Remove regfree
5630 call.
5631 (check_status_exception_catchpoint): Adjust to use compiled_regex.
5632 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
5633 * breakpoint.c (solib_catchpoint::compiled): Now a
5634 std::unique_ptr<compiled_regex>.
5635 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
5636 (check_status_catch_solib): Adjust to use compiled_regex.
5637 (add_solib_catchpoint): Adjust to use compiled_regex.
5638 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
5639 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
5640 compiled_regex reference. Adjust to use it.
5641 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
5642 declaration. Include "gdb_regex.h".
5643 (apropos_cmd): Change regex parameter to compiled_regex reference.
5644 * gdb_regex.c: New file.
5645 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
5646 declarations.
5647 (class compiled_regex): New.
5648 * linux-tdep.c: Include "common/gdb_optional.h".
5649 (struct mapping_regexes): New, factored out from
5650 mapping_is_anonymous_p, and adjusted to use compiled_regex.
5651 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
5652 gdb::optional and remove cleanups. Adjust to compiled_regex.
5653 * probe.c: Include "common/gdb_optional.h".
5654 (collect_probes): Use compiled_regex and gdb::optional and remove
5655 cleanups.
5656 * skip.c: Include "common/gdb_optional.h".
5657 (skiplist_entry::compiled_function_regexp): Now a
5658 gdb::optional<compiled_regex>.
5659 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
5660 (free_skiplist_entry): Remove regfree call.
5661 (compile_skip_regexp, skip_rfunction_p): Adjust to use
5662 compiled_regex and gdb::optional.
5663 * symtab.c: Include "common/gdb_optional.h".
5664 (search_symbols): Use compiled_regex and gdb::optional.
5665 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
5666 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
5667 to gdb_regex.c.
5668
5669 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5670
5671 * regcache.c (regcache::save): Avoid buffer use.
5672 (regcache::dump): Likewise.
5673
5674 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5675
5676 * sh-tdep.c (sh_pseudo_register_read): Remove
5677 MAX_REGISTER_SIZE.
5678 (sh_pseudo_register_write): Likewise.
5679 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
5680 (sh64_pseudo_register_write): Likewise
5681
5682 2017-06-07 Alan Hayward <alan.hayward@arm.com>
5683
5684 * aarch64-tdep.c (aarch64_store_return_value): Use
5685 V_REGISTER_SIZE.
5686 (aarch64_pseudo_read_value): Likewise.
5687 (aarch64_pseudo_write): Likewise.
5688
5689 2017-06-06 Yao Qi <yao.qi@linaro.org>
5690
5691 * regformats/regdef.h (set_register_cache): Remove the
5692 declaration.
5693
5694 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5695
5696 * frame.c (frame_unwind_register_signed): Use
5697 frame_unwind_register_value.
5698
5699 2017-06-06 Pedro Alves <palves@redhat.com>
5700
5701 PR breakpoints/21553
5702 * breakpoint.c (create_breakpoints_sal_default)
5703 (init_breakpoint_sal, create_breakpoint_sal): Use
5704 gdb::unique_xmalloc_ptr for string parameters.
5705 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5706 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
5707 (base_breakpoint_create_breakpoints_sal)
5708 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
5709 (strace_marker_create_breakpoints_sal)
5710 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
5711 string parameters.
5712 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
5713 gdb::unique_xmalloc_ptr for string parameters.
5714 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5715 parameters.
5716
5717 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5718
5719 * alpha-tdep.c (alpha_register_to_value): Use
5720 get_frame_register_value.
5721 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
5722
5723 2017-06-06 Alan Hayward <alan.hayward@arm.com>
5724
5725 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
5726 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
5727 (ia64_value_to_register): Likewise.
5728 (ia64_extract_return_value): Likewise.
5729 (ia64_store_return_value): Likewise.
5730 (ia64_push_dummy_call): Likewise.
5731
5732 2017-06-04 Joel Brobecker <brobecker@adacore.com>
5733
5734 GDB 8.0 released.
5735
5736 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
5737
5738 * x86-linux-nat.c (struct arch_lwp_info): Remove.
5739
5740 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
5741
5742 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
5743 parameter.
5744 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
5745
5746 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
5747
5748 * event-loop.c (poll_timers): Unallocate timer using delete
5749 instead of xfree.
5750
5751 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5752
5753 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
5754 (struct breakpoint) <~breakpoint>: New.
5755 (struct watchpoint): Inherit from breakpoint.
5756 <~watchpoint>: New.
5757 <base>: Remove.
5758 (struct tracepoint): Inherit from breakpoint.
5759 <base>: Remove.
5760 * breakpoint.c (longjmp_breakpoint_ops): Remove.
5761 (struct longjmp_breakpoint): Inherit from breakpoint.
5762 <~longjmp_breakpoint>: New.
5763 <base>: Remove.
5764 (new_breakpoint_from_type): Remove casts.
5765 (watchpoint_in_thread_scope): Remove reference to base field.
5766 (watchpoint_del_at_next_stop): Likewise.
5767 (update_watchpoint): Likewise.
5768 (watchpoint_check): Likewise.
5769 (bpstat_check_watchpoint): Likewise.
5770 (set_longjmp_breakpoint): Likewise.
5771 (struct fork_catchpoint): Inherit from breakpoint.
5772 <base>: Remove.
5773 (struct solib_catchpoint): Inherit from breakpoint.
5774 <~solib_catchpoint>: New.
5775 <base>: Remove.
5776 (dtor_catch_solib): Change to ...
5777 (solib_catchpoint::~solib_catchpoint): ... this.
5778 (breakpoint_hit_catch_solib): Remove reference to base field.
5779 (add_solib_catchpoint): Likewise.
5780 (create_fork_vfork_event_catchpoint): Likewise.
5781 (struct exec_catchpoint): Inherit from breakpoint.
5782 <~exec_catchpoint>: New.
5783 <base>: Remove.
5784 (dtor_catch_exec): Change to ...
5785 (exec_catchpoint::~exec_catchpoint): ... this.
5786 (dtor_watchpoint): Change to ...
5787 (watchpoint::~watchpoint): ... this.
5788 (watch_command_1): Remove reference to base field.
5789 (catch_exec_command_1): Likewise.
5790 (base_breakpoint_dtor): Change to ...
5791 (breakpoint::~breakpoint): ... this.
5792 (base_breakpoint_ops): Remove dtor field value.
5793 (longjmp_bkpt_dtor): Change to ...
5794 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
5795 (strace_marker_create_breakpoints_sal): Remove reference to base
5796 field.
5797 (delete_breakpoint): Don't manually call breakpoint destructor.
5798 (create_tracepoint_from_upload): Remove reference to base field.
5799 (trace_pass_set_count): Likewise.
5800 (initialize_breakpoint_ops): Don't initialize
5801 momentary_breakpoint_ops, don't set dtors.
5802 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
5803 <~ada_catchpoint>: New.
5804 <base>: Remove.
5805 (create_excep_cond_exprs): Remove reference to base field.
5806 (dtor_exception): Change to ...
5807 (ada_catchpoint::~ada_catchpoint): ... this.
5808 (dtor_catch_exception): Remove.
5809 (dtor_catch_exception_unhandled): Remove.
5810 (dtor_catch_assert): Remove.
5811 (create_ada_exception_catchpoint): Remove reference to base
5812 field.
5813 (initialize_ada_catchpoint_ops): Don't set dtors.
5814 * break-catch-sig.c (struct signal_catchpoint): Inherit from
5815 breakpoint.
5816 <~signal_catchpoint>: New.
5817 <base>: Remove.
5818 (signal_catchpoint_dtor): Change to ...
5819 (signal_catchpoint::~signal_catchpoint): ... this.
5820 (create_signal_catchpoint): Remove reference to base field.
5821 (initialize_signal_catchpoint_ops): Don't set dtor.
5822 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
5823 from breakpoint.
5824 <~syscall_catchpoint>: New.
5825 <base>: Remove.
5826 (dtor_catch_syscall): Change to ...
5827 (syscall_catchpoint::~syscall_catchpoint): ... this.
5828 (create_syscall_event_catchpoint): Remove reference to base
5829 field.
5830 (initialize_syscall_catchpoint_ops): Don't set dtor.
5831 * break-catch-throw.c (struct exception_catchpoint): Inherit
5832 from breakpoint.
5833 <~exception_catchpoint>: New.
5834 <base>: Remove.
5835 (dtor_exception_catchpoint): Change to ...
5836 (exception_catchpoint::~exception_catchpoint): ... this.
5837 (handle_gnu_v3_exceptions): Remove reference to base field.
5838 (initialize_throw_catchpoint_ops): Don't set dtor.
5839 * ctf.c (ctf_get_traceframe_address): Remove reference to base
5840 field.
5841 * remote.c (remote_get_tracepoint_status): Likewise.
5842 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
5843 * tracefile.c (tracefile_fetch_registers): Likewise.
5844 * tracepoint.c (actions_command): Likewise.
5845 (validate_actionline): Likewise.
5846 (tfind_1): Likewise.
5847 (get_traceframe_location): Likewise.
5848 (find_matching_tracepoint_location): Likewise.
5849 (parse_tracepoint_status): Likewise.
5850 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
5851
5852 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5853
5854 * breakpoint.c (struct longjmp_breakpoint): New struct.
5855 (is_tracepoint_type): Change return type to bool.
5856 (is_longjmp_type): New function.
5857 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
5858 (set_raw_breakpoint_without_location): Use
5859 new_breakpoint_from_type.
5860 (set_raw_breakpoint): Likewise.
5861
5862 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5863
5864 * breakpoint.c (new_breakpoint_from_type): New function.
5865 (create_breakpoint_sal): Use new_breakpoint_from_type and
5866 unique_ptr.
5867 (create_breakpoint): Likewise.
5868
5869 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
5870
5871 * memattr.c (mem_info_command): Rename to ...
5872 (info_mem_command): ... this.
5873 (mem_enable_command): Rename to ...
5874 (enable_mem_command): ... this.
5875 (mem_disable_command): Rename to ...
5876 (disable_mem_command): ... this.
5877 (mem_delete_command): Rename to ...
5878 (delete_mem_command): ... this.
5879 (_initialize_mem): Adjust function names.
5880
5881 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
5882
5883 * btrace.c (handle_pt_insn_events): New.
5884 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
5885 STATUS. Split into this and ...
5886 (handle_pt_insn_event_flags): ... this.
5887
5888 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
5889
5890 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
5891 and struct pt_insn.resynced.
5892 * configure: Regenerated.
5893 * config.in: Regenerated.
5894
5895 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5896
5897 * btrace.c (ftrace_find_call_by_number): New function.
5898 (ftrace_new_function): Store objects, not pointers.
5899 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
5900 ftrace_new_gap, ftrace_update_function,
5901 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
5902 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
5903 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
5904 btrace_ends_with_single_insn, btrace_call_get): Account for
5905 btrace_thread_info::functions now storing objects.
5906 * btrace.h (struct btrace_thread_info): Add constructor.
5907 (struct btrace_thread_info) <functions>: Make std::vector.
5908 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
5909 Initialize with default values.
5910 * record-btrace.c (record_btrace_frame_sniffer): Account for
5911 btrace_thread_info::functions now storing objects.
5912
5913 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5914
5915 * btrace.c: Remove typedef bfun_s.
5916 (ftrace_new_gap): Directly add gaps to the list of gaps.
5917 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
5918 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
5919 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
5920 instead of gdb VEC.
5921
5922 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5923
5924 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
5925 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
5926 with btrace_thread_info::next_segment and
5927 btrace_thread_info::prev_segment.
5928 * btrace.h: Remove struct btrace_func_link.
5929 (struct btrace_function): Replace pair of function segment pointers
5930 with pair of indices.
5931 * python/py-record-btrace.c (btpy_call_prev_sibling,
5932 btpy_call_next_sibling): Replace references to
5933 btrace_thread_info::segment with btrace_thread_info::next_segment and
5934 btrace_thread_info::prev_segment.
5935 * record-btrace.c (record_btrace_frame_this_id): Use
5936 btrace_find_call_by_number.
5937
5938 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5939
5940 * btrace.c (ftrace_new_function, ftrace_fixup_level,
5941 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
5942 btrace_insn_next, btrace_insn_prev): Remove references to
5943 btrace_thread_info::flow.
5944 * btrace.h (struct btrace_function): Remove FLOW.
5945
5946 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5947
5948 * btrace.c (ftrace_find_call_by_number): New function.
5949 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
5950 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
5951 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
5952 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
5953 index.
5954 * btrace.h (struct btrace_function): Turn UP into an index.
5955 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
5956 as an index.
5957 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
5958 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
5959 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
5960
5961 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5962
5963 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
5964 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
5965 ftrace_update_function, ftrace_compute_global_level_offset,
5966 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
5967 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
5968 btrace_insn_end, btrace_is_empty): Remove references to
5969 btrace_thread_info::begin and btrace_thread_info::end.
5970 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
5971 (struct btrace_thread_info) <functions>: Adjust comment.
5972 * record-btrace.c (record_btrace_start_replaying): Remove reference to
5973 btrace_thread_info::begin.
5974
5975 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5976
5977 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
5978 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
5979 ftrace_update_function): Remove arguments that implicitly were always
5980 BTINFO->END.
5981 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
5982 Don't pass BTINFO->END.
5983
5984 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5985
5986 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
5987 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
5988 btrace_find_insn_by_number): Replace function segment pointer with
5989 index.
5990 (btrace_insn_cmp): Simplify.
5991 * btrace.h: (struct btrace_insn_iterator) Rename index to
5992 insn_index. Replace function segment pointer with index into function
5993 segment vector.
5994 * record-btrace.c (record_btrace_call_history): Replace function
5995 segment pointer use with index.
5996 (record_btrace_frame_sniffer): Retrieve function call segment through
5997 vector.
5998 (record_btrace_set_replay): Remove defunc't safety check.
5999
6000 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6001
6002 * btrace.c (btrace_ends_with_single_insn): New function.
6003 (btrace_call_get, btrace_call_number, btrace_call_begin,
6004 btrace_call_end, btrace_call_next, btrace_call_prev,
6005 btrace_find_call_by_number): Use index into call segment vector
6006 instead of pointer.
6007 (btrace_call_cmp): Simplify.
6008 * btrace.h (struct btrace_call_iterator): Replace function call segment
6009 pointer with index into vector.
6010 * record-btrace.c (record_btrace_call_history): Use index instead of
6011 pointer.
6012
6013 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6014
6015 * btrace.c (btrace_insn_begin, btrace_insn_end,
6016 btrace_find_insn_by_number): Add btinfo to iterator.
6017 * btrace.h (struct btrace_insn_iterator): Add btinfo.
6018
6019 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6020
6021 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
6022 and save pointers directly.
6023 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
6024 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
6025 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
6026 changed signature of functions.
6027 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
6028 (btrace_fetch): Remove code that adds btrace_function pointers to
6029 vector of btrace_functions.
6030 (btrace_clear): Simplify freeing vector of btrace_functions.
6031
6032 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6033
6034 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
6035 Replace VEC_* with std::vector functions.
6036 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
6037 (struct btrace_thread_info)<functions>: Change type to std::vector.
6038
6039 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
6040
6041 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
6042 "Removed targets and native configurations" up. Merge duplicate
6043 "New commands" sub-sections. Add "New options" sub-sections.
6044
6045 2017-05-26 Alan Hayward <alan.hayward@arm.com>
6046
6047 * defs.h (copy_integer_to_size): New declaration.
6048 * findvar.c (copy_integer_to_size): New function.
6049 (do_cint_test): New selftest function.
6050 (copy_integer_to_size_test): Likewise.
6051 (_initialize_findvar): Likewise.
6052 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
6053 (mips_fbsd_collect_reg): Use raw_collect_integer.
6054 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
6055 (mips64_fill_gregset): Use raw_collect_integer
6056 (mips64_fill_fpregset): Use raw_supply_integer.
6057 * regcache.c (regcache::raw_supply_integer): New function.
6058 (regcache::raw_collect_integer): Likewise.
6059 * regcache.h: (regcache::raw_supply_integer): New declaration.
6060 (regcache::raw_collect_integer): Likewise.
6061
6062 2017-05-24 Yao Qi <yao.qi@linaro.org>
6063
6064 * Makefile.in (SFILES): Add gdbarch-selftests.c.
6065 (COMMON_OBS): Add gdbarch-selftests.o.
6066 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
6067 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
6068 * gdbarch-selftests.c: New file.
6069 * regcache.h (regcache) <~regcache>: Mark it virtual if
6070 GDB_SELF_TEST.
6071 <raw_write>: Likewise.
6072
6073 2017-05-24 Yao Qi <yao.qi@linaro.org>
6074
6075 * regcache.c (current_regcache): Change it to
6076 regcache::current_regcache.
6077 (regcache_observer_target_changed): Update.
6078 (regcache_thread_ptid_changed): Make it a regcache static
6079 method.
6080 (regcache_thread_ptid_changed): Update.
6081 (class regcache_access): New.
6082 (current_regcache_test): Update.
6083 (_initialize_regcache): Update.
6084 * regcache.h: Include forward_list.
6085 (regcache): Declare regcache_thread_ptid_changed and declare
6086 registers_changed_ptid as friend.
6087
6088 2017-05-24 Yao Qi <yao.qi@linaro.org>
6089
6090 * i387-tdep.c (i387_register_to_value): Use register_size
6091 instead of TYPE_LENGTH.
6092 * m68k-tdep.c (m68k_register_to_value): Likewise.
6093
6094 2017-05-24 Yao Qi <yao.qi@linaro.org>
6095
6096 * i387-tdep.c (i387_convert_register_p): Return false if type
6097 code isn't TYPE_CODE_FLT.
6098
6099 2017-05-24 Yao Qi <yao.qi@linaro.org>
6100
6101 * alpha-tdep.c (alpha_convert_register_p): Return true if type
6102 length is 4.
6103 (alpha_register_to_value): Remove type length check.
6104 (alpha_value_to_register): Likewise.
6105
6106 2017-05-24 Yao Qi <yao.qi@linaro.org>
6107
6108 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
6109 TYPE_CODE_FLT.
6110
6111 2017-05-24 Yao Qi <yao.qi@linaro.org>
6112
6113 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
6114 TYPE_CODE_FLT or not.
6115
6116 2017-05-24 Yao Qi <yao.qi@linaro.org>
6117
6118 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6119 * avr-tdep.c (avr_gdbarch_init): Likewise.
6120 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6121 * cris-tdep.c (cris_gdbarch_init): Likewise.
6122 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6123 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6124 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6125 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6126 * mep-tdep.c (mep_gdbarch_init): Likewise.
6127 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6128 * mips-tdep.c (mips_gdbarch_init): Likewise.
6129 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6130 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6131 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6132 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6133 * v850-tdep.c (v850_gdbarch_init): Likewise.
6134
6135 2017-05-24 Yao Qi <yao.qi@linaro.org>
6136
6137 * selftest-arch.c (tests_with_arch): Call registers_changed
6138 and reinit_frame_cache.
6139 * selftest.c (run_self_tests): Likewise.
6140
6141 2017-05-24 Yao Qi <yao.qi@linaro.org>
6142
6143 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6144 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6145
6146 2017-05-24 Yao Qi <yao.qi@linaro.org>
6147
6148 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6149 set_gdbarch_print_insn.
6150
6151 2017-05-24 Yao Qi <yao.qi@linaro.org>
6152
6153 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6154 set_gdbarch_print_insn.
6155
6156 2017-05-24 Yao Qi <yao.qi@linaro.org>
6157
6158 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6159 set_gdbarch_print_insn.
6160 * arc-tdep.c (arc_gdbarch_init): Likewise.
6161 * arch-utils.c: include dis-asm.h.
6162 (default_print_insn): New function.
6163 * arch-utils.h (default_print_insn): Declare.
6164 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6165 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6166 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6167 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6168 * frv-tdep.c (frv_gdbarch_init): Likewise.
6169 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6170 * gdbarch.sh (print_insn): Use default_print_insn.
6171 * gdbarch.c: Regenerated.
6172 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6173 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6174 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6175 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6176 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6177 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6178 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6179 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6180 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6181 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6182 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6183 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6184 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6185 * mt-tdep.c (mt_gdbarch_init): Likewise.
6186 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6187 * nios2-tdep.c (nios2_print_insn): Remove.
6188 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6189 * rx-tdep.c (rx_gdbarch_init): Likewise.
6190 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6191 * score-tdep.c (score_print_insn): Remove.
6192 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6193 * sh-tdep.c (sh_gdbarch_init): Likewise.
6194 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6195 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6196 * tic6x-tdep.c (tic6x_print_insn): Remove.
6197 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6198 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6199 * v850-tdep.c (v850_gdbarch_init): Likewise.
6200 * vax-tdep.c (vax_gdbarch_init): Likewise.
6201 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6202 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6203
6204 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6205
6206 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6207 (MIPS_FP0_REGNUM): Remove.
6208 (MIPS_FSR_REGNUM): Remove.
6209 (mips_fbsd_supply_fpregs): Use mips_regnum.
6210 (mips_fbsd_supply_gregs): Likewise.
6211 (mips_fbsd_collect_fpregs): Likewise.
6212 (mips_fbsd_collect_gregs): Likewise.
6213
6214 2017-05-23 John Baldwin <jhb@FreeBSD.org>
6215
6216 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6217 (getpfpregs_supplies): New function.
6218 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6219 getfpregs_supplies.
6220 (mips_fbsd_store_inferior_registers): Likewise.
6221
6222 2017-05-22 Pedro Alves <palves@redhat.com>
6223
6224 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6225 maintainer.
6226
6227 2017-05-22 Alan Hayward <alan.hayward@arm.com>
6228
6229 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6230 (store_register): Likewise.
6231 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6232 (get_decimal_float_return_value): Likewise.
6233 (do_ppc_sysv_return_value): Likewise.
6234 (ppc64_sysv_abi_push_integer): Likewise.
6235 (ppc64_sysv_abi_push_freg): Likewise.
6236 (ppc64_sysv_abi_return_value_base): Likewise.
6237 (ppc64_sysv_abi_return_value): Likewise.
6238 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6239 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6240 * rs6000-nat.c: Likewise.
6241 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6242 (rs6000_value_to_register): Likewise.
6243 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6244
6245 2017-05-21 Tom Tromey <tom@tromey.com>
6246
6247 PR rust/21466:
6248 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6249 arrays as "[T]", not "[T; ]".
6250
6251 2017-05-19 Tom Tromey <tom@tromey.com>
6252
6253 PR rust/21484:
6254 * rust-lang.c (exp_descriptor_rust): New function.
6255 (rust_language_defn): Use it.
6256 * p-lang.c (pascal_language_defn): Update.
6257 * opencl-lang.c (opencl_language_defn): Update.
6258 * objc-lang.c (objc_language_defn): Update.
6259 * m2-lang.c (m2_language_defn): Update.
6260 * language.h (struct language_defn)
6261 <la_watch_location_expression>: New member.
6262 * language.c (unknown_language_defn, auto_language_defn)
6263 (local_language_defn): Update.
6264 * go-lang.c (go_language_defn): Update.
6265 * f-lang.c (f_language_defn): Update.
6266 * d-lang.c (d_language_defn): Update.
6267 * c-lang.h (c_watch_location_expression): Declare.
6268 * c-lang.c (c_watch_location_expression): New function.
6269 (c_language_defn, cplus_language_defn, asm_language_defn)
6270 (minimal_language_defn): Use it.
6271 * breakpoint.c (watch_command_1): Call
6272 la_watch_location_expression.
6273 * ada-lang.c (ada_language_defn): Update.
6274
6275 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6276
6277 PR tui/21482
6278 * gdb_curses.h (NOMACROS): Define.
6279 (NCURSES_NOMACROS): Define.
6280
6281 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6282
6283 PR tui/21482
6284 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6285 arg to char *.
6286 * tui/tui-wingeneral.c (box_win): Likewise.
6287 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6288 (tui_show_source_line): Likewise.
6289 (tui_show_exec_info_content): Likewise.
6290
6291 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6292
6293 * sparc-tdep.c (sparc_structure_return_p)
6294 (sparc_arg_on_registers_p): New functions.
6295 (sparc32_store_arguments): Use them.
6296 * sparc64-tdep.c (sparc64_16_byte_align_p)
6297 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6298 Handle TYPE_CODE_ARRAY.
6299
6300 2017-05-17 Yao Qi <yao.qi@linaro.org>
6301
6302 * cli/cli-decode.c (add_alias_cmd): New function.
6303 * command.h (add_alias_cmd): Declare.
6304 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6305 instead call add_alias_cmd.
6306
6307 2017-05-17 Pedro Alves <palves@redhat.com>
6308
6309 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6310 (nat_makefile_frag): ... this. All references updated.
6311 * configure.ac: Likewise.
6312 * configure.nat: Likewise. Enhance comments.
6313 * configure: Regenerate.
6314
6315 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6316
6317 * procfs.c (procfs_create_inferior): Change prototype to match
6318 definition.
6319
6320 2017-05-13 Eli Zaretskii <eliz@gnu.org>
6321
6322 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6323 C++ compiler warning.
6324
6325 2017-05-12 Tom Tromey <tom@tromey.com>
6326
6327 PR rust/21483:
6328 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6329 recurse, just call value_struct_elt directly.
6330
6331 2017-05-12 Tom Tromey <tom@tromey.com>
6332
6333 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6334 OP_RUST_ARRAY>: Fix.
6335
6336 2017-05-12 Tom Tromey <tom@tromey.com>
6337
6338 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6339
6340 2017-05-09 Yao Qi <yao.qi@linaro.org>
6341
6342 * regcache.c: Include <forward_list>.
6343 (struct regcache_list): Remove.
6344 (current_regcache): Update.
6345 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6346 (regcache_thread_ptid_changed): Likewise.
6347 (registers_changed_ptid): Likewise.
6348 (current_regcache_size): Likewise.
6349
6350 2017-05-09 Yao Qi <yao.qi@linaro.org>
6351
6352 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6353 (current_regcache_size): New function.
6354 (current_regcache_test): New function.
6355 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6356
6357 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6358
6359 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6360 (print_gp_register_row): Use get_frame_register_value.
6361
6362 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6363
6364 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6365 (mips_supply_fpregset): Likewise.
6366 (mips64_supply_gregset): Likewise.
6367
6368 2017-05-08 Alan Hayward <alan.hayward@arm.com>
6369
6370 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6371 regcache->raw_supply_zeroed.
6372
6373 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6374
6375 * configure.nat: Rearrange 'case' statements to match
6376 host before cpu.
6377
6378 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6379
6380 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6381 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6382 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6383 "@nat_extra_makefile_frag@".
6384 (Makefile): Remove dependency on "@frags@".
6385 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6386 (data-directory/Makefile): Likewise.
6387 * config/aarch64/linux.mh: Deleted; moved contents to
6388 "gdb/configure.nat".
6389 * config/alpha/alpha-linux.mh: Likewise.
6390 * config/alpha/nbsd.mh: Likewise.
6391 * config/arm/linux.mh: Likewise.
6392 * config/arm/nbsdelf.mh: Likewise.
6393 * config/i386/cygwin.mh: Likewise.
6394 * config/i386/cygwin64.mh: Likewise.
6395 * config/i386/darwin.mh: Likewise.
6396 * config/i386/fbsd.mh: Likewise.
6397 * config/i386/fbsd64.mh: Likewise.
6398 * config/i386/go32.mh: Likewise.
6399 * config/i386/i386gnu.mh: Likewise.
6400 * config/i386/i386sol2.mh: Likewise.
6401 * config/i386/linux.mh: Likewise.
6402 * config/i386/linux64.mh: Likewise.
6403 * config/i386/mingw.mh: Likewise.
6404 * config/i386/mingw64.mh: Likewise.
6405 * config/i386/nbsd64.mh: Likewise.
6406 * config/i386/nbsdelf.mh: Likewise.
6407 * config/i386/nto.mh: Likewise.
6408 * config/i386/obsd.mh: Likewise.
6409 * config/i386/obsd64.mh: Likewise.
6410 * config/i386/sol2-64.mh: Likewise.
6411 * config/ia64/linux.mh: Likewise.
6412 * config/m32r/linux.mh: Likewise.
6413 * config/m68k/linux.mh: Likewise.
6414 * config/m68k/nbsdelf.mh: Likewise.
6415 * config/m68k/obsd.mh: Likewise.
6416 * config/m88k/obsd.mh: Likewise.
6417 * config/mips/fbsd.mh: Likewise.
6418 * config/mips/linux.mh: Likewise.
6419 * config/mips/nbsd.mh: Likewise.
6420 * config/mips/obsd64.mh: Likewise.
6421 * config/pa/linux.mh: Likewise.
6422 * config/pa/nbsd.mh: Likewise.
6423 * config/pa/obsd.mh: Likewise.
6424 * config/powerpc/aix.mh: Likewise.
6425 * config/powerpc/fbsd.mh: Likewise.
6426 * config/powerpc/linux.mh: Likewise.
6427 * config/powerpc/nbsd.mh: Likewise.
6428 * config/powerpc/obsd.mh: Likewise.
6429 * config/powerpc/ppc64-linux.mh: Likewise.
6430 * config/powerpc/spu-linux.mh: Likewise.
6431 * config/s390/linux.mh: Likewise.
6432 * config/sh/nbsd.mh: Likewise.
6433 * config/sparc/fbsd.mh: Likewise.
6434 * config/sparc/linux.mh: Likewise.
6435 * config/sparc/linux64.mh: Likewise.
6436 * config/sparc/nbsd64.mh: Likewise.
6437 * config/sparc/nbsdelf.mh: Likewise.
6438 * config/sparc/obsd64.mh: Likewise.
6439 * config/sparc/sol2.mh: Likewise.
6440 * config/tilegx/linux.mh: Likewise.
6441 * config/vax/nbsdelf.mh: Likewise.
6442 * config/vax/obsd.mh: Likewise.
6443 * config/xtensa/linux.mh: Likewise.
6444 * config/i386/i386gnu.mn: New file, with excerpts from
6445 "config/i386/i386gnu.mh".
6446 * configure: Regenerate.
6447 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
6448 *.mh files under "gdb/config".
6449 * configure.nat: New file, with contents from the
6450 "gdb/config/*/*.mh" files.
6451
6452 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
6453
6454 * btrace.c (btrace_clear): Free insn vector.
6455
6456 2017-05-05 Pedro Alves <palves@redhat.com>
6457
6458 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
6459 * configure: Regenerate.
6460
6461 2017-05-04 Pedro Alves <palves@redhat.com>
6462
6463 * Makefile.in (SFILES): Add progspace-and-thread.c.
6464 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
6465 (COMMON_OBS): Add progspace-and-thread.o.
6466 * breakpoint.c: Include "progspace-and-thread.h".
6467 (update_inserted_breakpoint_locations)
6468 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
6469 Use scoped_restore_current_pspace_and_thread.
6470 (create_std_terminate_master_breakpoint): Use
6471 scoped_restore_current_program_space.
6472 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
6473 (print_breakpoint_location): Use
6474 scoped_restore_current_program_space.
6475 (bp_loc_is_permanent): Use
6476 scoped_restore_current_pspace_and_thread.
6477 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
6478 (download_tracepoint_locations): Use
6479 scoped_restore_current_pspace_and_thread.
6480 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
6481 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
6482 (enum step_over_calls_kind): Moved from inferior.h.
6483 (class scoped_restore_current_thread): New class.
6484 * gdbthread.h (make_cleanup_restore_current_thread): Delete
6485 declaration.
6486 (scoped_restore_current_thread): New class.
6487 * infcmd.c: Include "common/gdb_optional.h".
6488 (continue_1, proceed_after_attach): Use
6489 scoped_restore_current_thread.
6490 (notice_new_inferior): Use scoped_restore_current_thread.
6491 * inferior.c: Include "progspace-and-thread.h".
6492 (restore_inferior, save_current_inferior): Delete.
6493 (add_inferior_command, clone_inferior_command): Use
6494 scoped_restore_current_pspace_and_thread.
6495 * inferior.h (scoped_restore_current_inferior): New class.
6496 * infrun.c: Include "progspace-and-thread.h" and
6497 "common/gdb_optional.h".
6498 (follow_fork_inferior): Use
6499 scoped_restore_current_pspace_and_thread.
6500 (scoped_restore_exited_inferior): New class.
6501 (handle_vfork_child_exec_or_exit): Use
6502 scoped_restore_exited_inferior,
6503 scoped_restore_current_pspace_and_thread,
6504 scoped_restore_current_thread and scoped_restore.
6505 (fetch_inferior_event): Use scoped_restore_current_thread.
6506 * linespec.c (decode_line_full, decode_line_1): Use
6507 scoped_restore_current_program_space.
6508 * mi/mi-main.c: Include "progspace-and-thread.h".
6509 (exec_continue): Use scoped_restore_current_thread.
6510 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
6511 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
6512 * proc-service.c (ps_pglobal_lookup): Use
6513 scoped_restore_current_program_space.
6514 * progspace-and-thread.c: New file.
6515 * progspace-and-thread.h: New file.
6516 * progspace.c (release_program_space, clone_program_space): Use
6517 scoped_restore_current_program_space.
6518 (restore_program_space, save_current_program_space)
6519 (save_current_space_and_thread): Delete.
6520 (switch_to_program_space_and_thread): Moved to
6521 progspace-and-thread.c.
6522 * progspace.h (save_current_program_space)
6523 (save_current_space_and_thread): Delete declarations.
6524 (scoped_restore_current_program_space): New class.
6525 * remote.c (remote_btrace_maybe_reopen): Use
6526 scoped_restore_current_thread.
6527 * symtab.c: Include "progspace-and-thread.h".
6528 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
6529 * thread.c (print_thread_info_1): Use
6530 scoped_restore_current_thread.
6531 (struct current_thread_cleanup): Delete.
6532 (do_restore_current_thread_cleanup)
6533 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
6534 (scoped_restore_current_thread::~scoped_restore_current_thread):
6535 ... this new dtor.
6536 (make_cleanup_restore_current_thread): Rename/convert to ...
6537 (scoped_restore_current_thread::scoped_restore_current_thread):
6538 ... this new ctor.
6539 (thread_apply_all_command): Use scoped_restore_current_thread.
6540 (thread_apply_command): Use scoped_restore_current_thread.
6541 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
6542 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
6543
6544 2017-05-04 Pedro Alves <palves@redhat.com>
6545
6546 * thread.c (make_cleanup_restore_current_thread): Move
6547 find_thread_ptid call before the is_stopped call. Assert that the
6548 thread is found. Replace is_stopped call by checking the thread's
6549 state directly. Remove unnecessary NULL-thread check.
6550
6551 2017-05-04 Pedro Alves <palves@redhat.com>
6552
6553 * corelow.c (thread_section_name): New class.
6554 (get_core_register_section, get_core_siginfo): Use it.
6555
6556 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
6557
6558 * corelow.c (sniff_core_bfd): Remove extra semicolon.
6559 (get_core_register_section): Remove xfree of NULL pointer.
6560
6561 2017-05-03 Alan Hayward <alan.hayward@arm.com>
6562
6563 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
6564 * regcache.c (regcache::raw_supply_zeroed): New function.
6565 * regcache.h (regcache::raw_supply_zeroed): New declaration.
6566
6567 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
6568
6569 * gdbarch.sh: Remove commented out definition of
6570 TARGET_CHAR_BIT.
6571 * gdbarch.h: Re-generate.
6572
6573 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6574
6575 * configure: Regenerate.
6576
6577 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
6578
6579 * solib-target.c (solib_target_relocate_section_addresses):
6580 Remove num_section_bases, num_bases, segment_bases variables.
6581
6582 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6583
6584 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
6585
6586 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6587
6588 * solib-target.c: Include <vector>
6589 (struct lm_info_target) <~lm_info_target>: Remove.
6590 <segment_bases, section_bases>: Change type to
6591 std::vector<CORE_ADDR>.
6592 (library_list_start_segment, library_list_start_section,
6593 library_list_end_library,
6594 solib_target_relocate_section_addresses): Adjust.
6595
6596 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6597
6598 * gdbarch.sh (software_single_step): Change return type to
6599 std::vector<CORE_ADDR>.
6600 * gdbarch.c, gdbarch.h: Re-generate.
6601 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
6602 Adjust.
6603 (arm_deal_with_atomic_sequence_raw): Adjust.
6604 (thumb_get_next_pcs_raw): Adjust.
6605 (arm_get_next_pcs_raw): Adjust.
6606 (arm_get_next_pcs): Adjust.
6607 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
6608 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
6609 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
6610 (alpha_software_single_step): Adjust.
6611 * alpha-tdep.h (alpha_software_single_step): Adjust.
6612 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
6613 * arm-tdep.c (arm_software_single_step): Adjust.
6614 (arm_breakpoint_kind_from_current_state): Adjust.
6615 * arm-tdep.h (arm_software_single_step): Adjust.
6616 * breakpoint.c (insert_single_step_breakpoint): Adjust.
6617 * cris-tdep.c (cris_software_single_step): Adjust.
6618 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
6619 (micromips_deal_with_atomic_sequence): Adjust.
6620 (deal_with_atomic_sequence): Adjust.
6621 (mips_software_single_step): Adjust.
6622 * mips-tdep.h (mips_software_single_step): Adjust.
6623 * moxie-tdep.c (moxie_software_single_step): Adjust.
6624 * nios2-tdep.c (nios2_software_single_step): Adjust.
6625 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
6626 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
6627 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
6628 * s390-linux-tdep.c (s390_software_single_step): Adjust.
6629 * sparc-tdep.c (sparc_software_single_step): Adjust.
6630 * spu-tdep.c (spu_software_single_step): Adjust.
6631 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
6632
6633 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6634
6635 * gdbarch.sh: Use semi-colon as field separator instead of colon.
6636 * gdbarch.h: Re-generate.
6637
6638 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6639
6640 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
6641 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
6642 * python/py-instruction.c, python/py-instruction.h: New file.
6643 * python/py-record.c: Add py-instruction.h include.
6644 (gdbpy_initialize_record): Make gdb.Instruction a super class of
6645 gdb.RecordInstruction.
6646 * python/python-internal.h: Add gdbpy_initialize_instruction
6647 declaration.
6648 * python/python.c (do_start_initialization): Add
6649 gdbpy_initialize_instruction.
6650
6651 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6652
6653 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
6654 Remove.
6655 (btrace_func_from_recpy_func): New function.
6656 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
6657 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
6658 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
6659 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
6660 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
6661 Also, use new helper functions.
6662 (btpy_list_item): Use new helper functions.
6663 (recpy_bt_function_call_history): Use new type name.
6664 (btpy_call_getset): Remove.
6665 (gdbpy_initialize_btrace): Remove code to initialize
6666 gdb.BtraceFunctionCall.
6667 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
6668 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
6669 recpy_bt_func_prev, recpy_bt_func_next): New export.
6670 * python/py-record.c (recpy_func_type): New static object.
6671 (recpy_func_new, recpy_func_level, recpy_func_symbol,
6672 recpy_func_instructions, recpy_func_up, recpy_func_prev,
6673 recpy_func_next): New function.
6674 (recpy_element_hash, recpy_element_richcompare): Updated comment.
6675 (recpy_func_getset): New static object.
6676 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
6677 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
6678
6679 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6680
6681 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
6682 (btpy_object, btpy_insn_type, btpy_new): Remove.
6683 (btpy_list_object): Use gdb.RecordInstruction type instead of
6684 gdb.BtraceInstruction type.
6685 (btrace_insn_from_recpy_insn): New function.
6686 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
6687 btpy_new.
6688 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
6689 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
6690 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
6691 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
6692 instead of btpy_object.
6693 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6694 btpy_insn_data, btpy_insn_decode): Rename to ...
6695 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
6696 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
6697 recpy_bt_insn_decode): This. Also, use new helper functions.
6698 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
6699 recpy_insn_type.
6700 (btpy_insn_getset): Remove.
6701 (gdbpy_initialize_btrace): Remove code to initialize
6702 gdb.BtraceInstruction. Use recpy_element_object.
6703 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
6704 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
6705 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
6706 * python/py-record.c (recpy_insn_type): New static object.
6707 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
6708 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
6709 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
6710 New function.
6711 (recpy_insn_getset): New static object.
6712 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
6713 * python/py-record.h (recpy_element_object): New typedef.
6714 (recpy_insn_type, recpy_insn_new): New export.
6715
6716 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6717
6718 * py-record-btrace.c (btpy_insn_new): Removed.
6719 (btpy_insn_or_gap_new): New function.
6720 (btpy_insn_error): Removed.
6721 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6722 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
6723 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
6724 btpy_insn_or_gap_new instead of btpy_insn_new.
6725 (btpy_insn_getset): Remove btpy_insn_error.
6726 * py-record.c (recpy_gap_type): New static object.
6727 (recpy_gap_object): New typedef.
6728 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
6729 recpy_gap_reason_string): New function.
6730 (recpy_gap_getset): New static object.
6731 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
6732 * py-record.h (recpy_gap_new): New export.
6733
6734 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6735
6736 * python/py-record.c (recpy_ptid): Remove.
6737 (recpy_record_getset): Remove recpy_ptid.
6738
6739 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6740
6741 * btrace.c (btrace_fetch): Set inferior_ptid.
6742 * python/py-record-btrace.c: Add "py-record.h" include.
6743 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
6744 recpy_bt_end, recpy_bt_instruction_history,
6745 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
6746 in gdb.Record object instead of current ptid.
6747 * python/py-record.c: Include new "py-record.h" file.
6748 (recpy_record_object): Moved to py-record.h.
6749 * python/py-record.h: New file.
6750
6751 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6752
6753 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
6754 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
6755 indentation.
6756
6757 2017-05-01 Joel Brobecker <brobecker@adacore.com>
6758
6759 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
6760 the past maintainers section.
6761
6762 2017-04-28 Yao Qi <yao.qi@linaro.org>
6763
6764 * infcmd.c (get_return_value): Use regcache ctor, and remove
6765 cleanup.
6766
6767 2017-04-28 Yao Qi <yao.qi@linaro.org>
6768 Pedro Alves <palves@redhat.com>
6769
6770 * regcache.c (regcache::regcache): New tag dispatch ctor.
6771 (do_cooked_read): Moved above.
6772 (regcache_dup): Use the tag dispatch ctor..
6773 * regcache.h (regcache): Declare ctor, delete copy ctor and
6774 assignment operator, remove friend regcache_dup.
6775
6776 2017-04-28 Yao Qi <yao.qi@linaro.org>
6777
6778 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
6779 call method save instead of regcache_cpy.
6780 * regcache.h (struct regcache): Make regcache_dup a friend.
6781
6782 2017-04-28 Yao Qi <yao.qi@linaro.org>
6783
6784 * regcache.c (struct regcache): Move to regcache.h
6785 (regcache::arch): New method.
6786 (regcache_get_ptid): Update.
6787 (get_regcache_arch): Call arch method.
6788 (get_regcache_aspace): Call method aspace.
6789 (register_buffer): Change it to method.
6790 (regcache_save): Change it to regcache::save.
6791 (regcache_restore): Likewise.
6792 (regcache_cpy_no_passthrough): Remove the declaration.
6793 (regcache_cpy): Call methods restore and cpy_no_passthrough.
6794 (regcache_cpy_no_passthrough): Change it to method
6795 cpy_no_passthrough.
6796 (regcache_register_status): Change it to method
6797 get_register_status.
6798 (regcache_invalidate): Change it to method invalidate.
6799 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
6800 (regcache_raw_update): Change it to method raw_update.
6801 (regcache_raw_read): Likewise.
6802 (regcache_raw_read_signed): Likewise.
6803 (regcache_raw_read_unsigned): Likewise.
6804 (regcache_raw_write_signed): Likewise.
6805 (regcache_raw_write_unsigned): Likewise.
6806 (regcache_cooked_read): Likewise.
6807 (regcache_cooked_read_value): Likewise.
6808 (regcache_cooked_read_signed): Likewise.
6809 (regcache_cooked_read_unsigned): Likewise.
6810 (regcache_cooked_write_signed): Likewise.
6811 (regcache_cooked_write_unsigned): Likewise.
6812 (regcache_raw_set_cached_value): Likewise.
6813 (regcache_raw_write): Likewise.
6814 (regcache_cooked_write): Likewise.
6815 (regcache_xfer_part): Likewise.
6816 (regcache_raw_read_part): Likewise.
6817 (regcache_raw_write_part): Likewise.
6818 (regcache_cooked_read_part): Likewise.
6819 (regcache_cooked_write_part): Likewise.
6820 (regcache_raw_supply): Likewise.
6821 (regcache_raw_collect): Likewise.
6822 (regcache_transfer_regset): Likewise.
6823 (regcache_supply_regset): Likewise.
6824 (regcache_collect_regset): Likewise.
6825 (regcache_debug_print_register): Likewise.
6826 (enum regcache_dump_what): Move it to regcache.h.
6827 (regcache_dump): Change it to method dump.
6828 * regcache.h (enum regcache_dump_what): New.
6829 (class regcache): New.
6830 * target.c (target_fetch_registers): Call method
6831 debug_print_register.
6832 (target_store_registers): Likewise.
6833
6834 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6835
6836 * windows-nat.c (struct lm_info_windows): Initialize field.
6837 (windows_make_so): Allocate lm_info_windows with new.
6838 (windows_free_so): Free lm_info_windows with delete.
6839
6840 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6841
6842 * solib-darwin.c (struct lm_info_darwin): Initialize field.
6843 (darwin_current_sos): Allocate lm_info_darwin with new, remove
6844 cleanup.
6845 (darwin_free_so): Free lm_info_darwin with delete.
6846
6847 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6848
6849 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
6850 <l_addr_p>: Change type to bool.
6851 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
6852 (svr4_free_so): Free lm_info_svr4 with delete.
6853 (svr4_copy_library_list): Replace memcpy with call to copy
6854 constructor.
6855 (library_list_start_library, svr4_default_sos): Allocate
6856 lm_info_svr4 with new.
6857
6858 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6859
6860 * solib-target.c (struct lm_info_target): Add destructor,
6861 initialize fields.
6862 <name>: Change type to std::string.
6863 (library_list_start_library): Allocate lm_info_target with new.
6864 (solib_target_free_library_list): Free lm_info_target with
6865 delete.
6866 (solib_target_current_sos): Adapt to std::string.
6867 (solib_target_free_so): Free lm_info_target with delete.
6868
6869 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6870
6871 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
6872 fields.
6873 (frv_current_sos): Allocate lm_info_frv with new.
6874 (frv_relocate_main_executable): Free lm_info_frv with delete,
6875 allocate with new.
6876 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
6877
6878 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6879
6880 * solib-frv.c (struct lm_info_frv): Fix indentation.
6881
6882 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6883
6884 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
6885 map field.
6886 (dsbt_current_sos): Allocate lm_info_dsbt with new.
6887 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
6888 and allocate with new.
6889 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
6890
6891 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6892
6893 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
6894 <filename, member_name>: Change type to std::string.
6895 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
6896 (library_list_start_library): Allocate lm_info_aix with new.
6897 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
6898 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
6899 with copy constructor.
6900
6901 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6902
6903 * solist.h (struct lm_info): Remove.
6904 (struct lm_info_base): New class.
6905 (struct so_list) <lm_info>: Change type to lm_info_base *.
6906 * nto-tdep.c (struct lm_info): Remove.
6907 (lm_addr): Adjust.
6908 * solib-aix.c (struct lm_info): Rename to ...
6909 (struct lm_info_aix): ... this. Extend lm_info_base.
6910 (lm_info_p): Rename to ...
6911 (lm_info_aix_p): ... this, and adjust.
6912 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
6913 solib_aix_parse_libraries, library_list_start_library,
6914 solib_aix_free_library_list, solib_aix_parse_libraries,
6915 solib_aix_get_library_list,
6916 solib_aix_relocate_section_addresses, solib_aix_free_so,
6917 solib_aix_get_section_offsets,
6918 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
6919 Adjust.
6920 (struct solib_aix_inferior_data) <library_list>: Adjust.
6921 * solib-darwin.c (struct lm_info): Rename to ...
6922 (struct lm_info_darwin): ... this. Extend lm_info_base.
6923 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
6924 * solib-dsbt.c (struct lm_info): Rename to ...
6925 (struct lm_info_dsbt): ... this. Extend lm_info_base.
6926 (struct dsbt_info) <main_executable_lm_info): Adjust.
6927 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
6928 dsbt_relocate_section_addresses): Adjust.
6929 * solib-frv.c (struct lm_info): Rename to ...
6930 (struct lm_info_frv): ... this. Extend lm_info_base.
6931 (main_executable_lm_info): Adjust.
6932 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
6933 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
6934 find_canonical_descriptor_in_load_object,
6935 frv_fdpic_find_canonical_descriptor): Adjust.
6936 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
6937 to lm_info_svr4.
6938 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
6939 svr4_clear_so, svr4_copy_library_list,
6940 library_list_start_library, svr4_default_sos, svr4_read_so_list,
6941 svr4_current_sos, svr4_fetch_objfile_link_map,
6942 solist_update_incremental): Adjust.
6943 * solib-svr4.h (struct lm_info_svr4): Move here from
6944 solib-svr4.c.
6945 * solib-target.c (struct lm_info): Rename to ...
6946 (struct lm_info_target): ... this. Extend lm_info_base.
6947 (lm_info_p): Rename to ...
6948 (lm_info_target_p): ... this.
6949 (solib_target_parse_libraries, library_list_start_segment,
6950 library_list_start_section, library_list_start_library,
6951 library_list_end_library, solib_target_free_library_list,
6952 solib_target_current_sos, solib_target_free_so,
6953 solib_target_relocate_section_addresses): Adjust.
6954 * windows-nat.c (struct lm_info): Rename to ...
6955 (struct lm_info_windows): ... this. Extend lm_info_base.
6956 (windows_make_so, handle_load_dll, handle_unload_dll,
6957 windows_xfer_shared_libraries): Adjust.
6958
6959 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6960
6961 * solib-darwin.c (struct darwin_so_list): Remove.
6962 (darwin_current_sos): Allocate an so_list object instead of a
6963 darwin_so_list, separately allocate an lm_info object.
6964 (darwin_free_so): Free lm_info.
6965
6966 2017-04-28 John Baldwin <jhb@FreeBSD.org>
6967
6968 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
6969 with fprintf_filtered.
6970
6971 2017-04-28 Yao Qi <yao.qi@linaro.org>
6972
6973 * regcache.c (regcache::regcache): New function.
6974 (regcache::~regcache): New function.
6975 (regcache_xmalloc_1): Remove.
6976 (regcache_xmalloc): Call new regcache.
6977 (regcache_xfree): Call delete regcache.
6978 (get_thread_arch_aspace_regcache): Call new regcache.
6979
6980 2017-04-28 Yao Qi <yao.qi@linaro.org>
6981
6982 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
6983 lwp instead of ptid_get_lwp.
6984
6985 2017-04-28 Yao Qi <yao.qi@linaro.org>
6986
6987 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
6988 lwp_info instead of getting from inferior_ptid.
6989
6990 2017-04-27 Keith Seitz <keiths@redhat.com>
6991
6992 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
6993 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
6994 (CV_CONVERSION_BADNESS): Define.
6995 (rank_one_type): Remove overly restrictive rvalue reference
6996 rank checks.
6997 Add cv-qualifier checks and subranks for type equality.
6998 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
6999 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
7000 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
7001
7002 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
7003
7004 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
7005 count when creating the object.
7006
7007 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
7008 Ulrich Weigand <uweigand@de.ibm.com>
7009
7010 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
7011 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
7012 is used in AIX.
7013 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
7014 (process_xcoff_symbol): Likewise.
7015 (scan_xcoff_symtab): Likewise.
7016
7017 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7018
7019 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
7020 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
7021 (ia64_access_reg): Use get_frame_register_unsigned.
7022 (ia64_access_rse_reg): Likewise.
7023 (ia64_libunwind_frame_prev_register): Likewise.
7024
7025 2017-04-26 Jiong Wang <jiong.wang@arm.com>
7026
7027 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
7028 * gdbarch.c: Regenerated.
7029 * gdbarch.h: Regenerated.
7030 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
7031 visibility external.
7032 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
7033 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
7034 (enum cfa_how_kind): Move to ...
7035 (struct dwarf2_frame_state_reg_info): Likewise.
7036 (struct dwarf2_frame_state): Likewise.
7037 * dwarf2-frame.h: ... here.
7038 (dwarf2_frame_state_alloc_regs): New declaration.
7039 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
7040 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
7041
7042 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7043
7044 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
7045 regcache_raw_read_unsigned.
7046 (xtensa_pseudo_register_write): Likewise.
7047
7048 2017-04-26 Alan Hayward <alan.hayward@arm.com>
7049
7050 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
7051 (nds32_pseudo_register_write): Likewise.
7052
7053 2017-04-25 Yao Qi <yao.qi@linaro.org>
7054
7055 * regcache.c (struct regcache) <readonly_p>: Change its type
7056 to bool.
7057 (regcache_xmalloc_1): Update parameter type and callers update.
7058
7059 2017-04-25 Yao Qi <yao.qi@linaro.org>
7060
7061 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
7062 set_gdbarch_wchar_bit.
7063 * arm-tdep.c (arm_gdbarch_init): Likewise.
7064
7065 2017-04-25 Pedro Alves <palves@redhat.com>
7066
7067 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
7068 (BothAreRelocatable, memcopy, memmove): Don't define.
7069 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
7070 macros.
7071
7072 2017-04-25 Pedro Alves <palves@redhat.com>
7073
7074 * common/common-defs.h: Include "common/poison.h".
7075 * common/function-view.h: (Not, Or, Requires): Move to traits.h
7076 and adjust.
7077 * common/poison.h: New file.
7078 * common/traits.h: Include <type_traits>.
7079 (Not, Or, Requires): New, moved from common/function-view.h.
7080
7081 2017-04-25 Pedro Alves <palves@redhat.com>
7082
7083 * breakpoint.h (struct breakpoint): In-class initialize all
7084 fields. Make boolean fields "bool".
7085 * breakpoint.c (init_raw_breakpoint_without_location): Remove
7086 memset call and initializations no longer necessary.
7087
7088 2017-04-25 Pedro Alves <palves@redhat.com>
7089
7090 * btrace.c (pt_btrace_insn_flags): Change parameter type to
7091 reference.
7092 (pt_btrace_insn): New function.
7093 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
7094
7095 2017-04-25 Pedro Alves <palves@redhat.com>
7096
7097 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
7098 "base" field and inherit from "bp_location" instead. Add
7099 non-default ctor.
7100 (allocate_location_exception): Use new non-default ctor.
7101 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
7102 (init_bp_location): Convert to ...
7103 (bp_location::bp_location): ... this new ctor, and remove memset
7104 call.
7105 (base_breakpoint_allocate_location): Use the new non-default ctor.
7106 * breakpoint.h (bp_location): Now a class. Declare default and
7107 non-default ctors. In-class initialize all members.
7108 (init_bp_location): Remove declaration.
7109
7110 2017-04-25 Pedro Alves <palves@redhat.com>
7111
7112 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
7113 assignment operator.
7114
7115 2017-04-24 Yao Qi <yao.qi@linaro.org>
7116
7117 * doublest.c (convert_doublest_to_floatformat): Call
7118 floatformat_totalsize_bytes.
7119
7120 2017-04-22 Tom Tromey <tom@tromey.com>
7121
7122 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7123 ui_out_emit_list.
7124 * stack.c (print_frame): Use ui_out_emit_list.
7125 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7126 ui_out_emit_list.
7127 * mi/mi-main.c (print_one_inferior)
7128 (mi_cmd_data_list_register_names)
7129 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7130 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7131 ui_out_emit_list.
7132 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7133 (mi_output_solib_attribs): Use ui_out_emit_list,
7134 ui_out_emit_tuple.
7135 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7136 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7137 (mi_cmd_stack_list_args, list_args_or_locals): Use
7138 ui_out_emit_list.
7139 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7140 * breakpoint.c (print_solib_event, output_thread_groups): Use
7141 ui_out_emit_list.
7142
7143 2017-04-22 Tom Tromey <tom@tromey.com>
7144
7145 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7146 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7147 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7148
7149 2017-04-22 Tom Tromey <tom@tromey.com>
7150
7151 * tracepoint.c (tvariables_info_1)
7152 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7153
7154 2017-04-22 Tom Tromey <tom@tromey.com>
7155
7156 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7157 annotate_arg_emitter.
7158 * breakpoint.c (print_mention_watchpoint)
7159 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7160 * annotate.h (struct annotate_arg_emitter): New.
7161
7162 2017-04-22 Tom Tromey <tom@tromey.com>
7163
7164 * record-btrace.c (record_btrace_insn_history)
7165 (record_btrace_insn_history_range, record_btrace_call_history)
7166 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7167 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7168 ui_out_emit_tuple.
7169 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7170 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7171 * skip.c (skip_info): Use ui_out_emit_tuple.
7172 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7173 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7174 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7175 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7176 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7177 ui_out_emit_tuple.
7178 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7179 (output_register, mi_cmd_data_read_memory)
7180 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7181 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7182 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7183 Use ui_out_emit_tuple.
7184 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7185 ui_out_emit_tuple.
7186 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7187 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7188 * linux-thread-db.c (info_auto_load_libthread_db): Use
7189 ui_out_emit_tuple.
7190 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7191 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7192 * disasm.c (do_mixed_source_and_assembly_deprecated)
7193 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7194 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7195 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7196 * breakpoint.c (print_one_breakpoint_location)
7197 (print_one_breakpoint): Use ui_out_emit_tuple.
7198 * auto-load.c (print_script, info_auto_load_cmd): Use
7199 ui_out_emit_tuple.
7200 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7201
7202 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7203
7204 * thread.c (print_thread_info_1): Remove dead code.
7205
7206 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7207
7208 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7209 GDB_SELF_TEST.
7210 * arm-tdep.c (selftests::arm_record_test): Likewise.
7211
7212 2017-04-21 Yao Qi <yao.qi@linaro.org>
7213
7214 * regcache.c (regcache_restore): Remove argument 2. Replace
7215 argument 3 with regcache. Get register status from
7216 src->register_status and get register contents from
7217 register_buffer (src, regnum).
7218 (regcache_cpy): Update.
7219
7220 2017-04-19 Pedro Alves <palves@redhat.com>
7221
7222 * gdbthread.h (thread): Add missing closing parenthesis in
7223 comment.
7224
7225 2017-04-19 Pedro Alves <palves@redhat.com>
7226
7227 * common/refcounted-object.h: New file.
7228 * gdbthread.h: Include "common/refcounted-object.h".
7229 (thread_info): Inherit from refcounted_object and add comments.
7230 (thread_info::incref, thread_info::decref)
7231 (thread_info::m_refcount): Delete.
7232 (thread_info::deletable): Use the refcounted_object::refcount()
7233 method.
7234 * inferior.c (current_inferior_): Add comment.
7235 (set_current_inferior): Increment/decrement refcounts.
7236 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7237 not-deletable instead of comparing with the current inferior.
7238 (initialize_inferiors): Increment the initial inferior's refcount.
7239 * inferior.h (struct inferior): Forward declare.
7240 Include "common/refcounted-object.h".
7241 (current_inferior, set_current_inferior): Move declaration to
7242 before struct inferior's definition, and fix comment.
7243 (inferior): Inherit from refcounted_object. Add comments.
7244 * thread.c (switch_to_thread_no_regs): Reference the thread's
7245 inferior pointer directly instead of doing a ptid lookup.
7246 (switch_to_no_thread): New function.
7247 (switch_to_thread(thread_info *)): New function, factored out
7248 from ...
7249 (switch_to_thread(ptid_t)): ... this.
7250 (restore_current_thread): Delete.
7251 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7252 fields, and add 'inf' field.
7253 (do_restore_current_thread_cleanup): Check whether old->inf is
7254 alive instead of looking up an inferior by ptid. Use
7255 switch_to_thread and switch_to_no_thread.
7256 (restore_current_thread_cleanup_dtor): Use old->inf directly
7257 instead of lookup up an inferior by id. Decref the inferior.
7258 Don't restore 'removable'.
7259 (make_cleanup_restore_current_thread): Same the inferior pointer
7260 in old, instead of the inferior number. Incref the inferior.
7261 Don't save/clear 'removable'.
7262
7263 2017-04-19 Pedro Alves <palves@redhat.com>
7264
7265 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7266 unittests/scoped_restore-selftests.c.
7267 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7268 * common/scoped_restore.h (scoped_restore_base): Make "class".
7269 (scoped_restore_base::release): New public method.
7270 (scoped_restore_base::scoped_restore_base): New protected ctor.
7271 (scoped_restore_base::m_saved_var): New protected field.
7272 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7273 scoped_restore_base base class instead of m_saved_var directly.
7274 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7275 (scoped_restore_tmpl::scoped_restore_tmpl(const
7276 scoped_restore_tmpl<T>&)): Likewise.
7277 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7278 method.
7279 (scoped_restore_tmpl::saved_var): New method.
7280 (scoped_restore_tmpl::m_saved_var): Delete.
7281 * inferior.h (inferior::detaching): Now a bool.
7282 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7283 cleanup.
7284 * unittests/scoped_restore-selftests.c: New file.
7285
7286 2017-04-19 Pedro Alves <palves@redhat.com>
7287
7288 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7289 Re-sort in alphabetic order.
7290
7291 2017-04-18 Pedro Alves <palves@redhat.com>
7292
7293 * xml-support.c (obstack_xml_printf): Delete.
7294 * xml-support.h (obstack_xml_printf): Delete.
7295
7296 2017-04-18 Pedro Alves <palves@redhat.com>
7297
7298 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7299 vdebug, verror, body_text, start_element, end_element, name,
7300 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7301 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7302 is_xinclude>: Make private and add m_ prefix.
7303 (gdb_xml_parser::body_text): New method, based on ...
7304 (gdb_xml_body_text): ... this. Adjust.
7305 (gdb_xml_parser::vdebug): New method, based on ...
7306 (gdb_xml_debug): ... this. Adjust.
7307 (gdb_xml_parser::verror): New method, based on ...
7308 (gdb_xml_error): ... this. Adjust.
7309 (gdb_xml_parser::start_element): New method, based on ...
7310 (gdb_xml_start_element): ... this. Adjust.
7311 (gdb_xml_start_element_wrapper): Defer to
7312 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7313 (gdb_xml_parser::end_element): New method, based on ...
7314 (gdb_xml_end_element_wrapper): ... this. Adjust.
7315 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7316 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7317 (gdb_xml_parser::use_dtd): New method, based on ...
7318 (gdb_xml_use_dtd): ... this. Adjust.
7319 (gdb_xml_parser::parse): New method, based on ...
7320 (gdb_xml_parse): ... this. Adjust.
7321 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7322 (xinclude_start_include): Adjust to call the parser's name method.
7323 (xml_xinclude_default, xml_xinclude_start_doctype)
7324 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7325 method.
7326 (xml_process_xincludes): Adjust to call parser methods.
7327 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7328 declarations.
7329
7330 2017-04-18 Pedro Alves <palves@redhat.com>
7331
7332 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7333 gdb::optional<std::string>.
7334 * xml-support.c: Include <string>.
7335 (scope_level::scope_level(scope_level &&))
7336 (scope_level::~scope_level): Delete.
7337 (scope_level::body): Now a std::string.
7338 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7339 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7340 parameter.
7341 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7342 (xinclude_parsing_data::output): Now a std::string reference.
7343 (xinclude_start_include): Adjust.
7344 (xml_xinclude_default): Adjust.
7345 (xml_process_xincludes): Add 'output' parameter, and return bool.
7346 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7347 and return bool.
7348 * xml-tdesc.c: Include <unordered_map> and <string>.
7349 (tdesc_xml_cache): Delete.
7350 (tdesc_xml_cache_s): Delete.
7351 (xml_cache): Now an std::unordered_map.
7352 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7353 (target_fetch_description_xml): Change return type to
7354 gdb::optional<std::string>, and adjust.
7355 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7356 (target_fetch_description_xml): Change return type to
7357 gdb::optional<std::string>.
7358
7359 2017-04-18 Pedro Alves <palves@redhat.com>
7360
7361 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7362 unittests/optional-selftests.c.
7363 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7364 * unittests/optional-selftests.c: New file.
7365 * unittests/optional/assignment/1.cc: New file.
7366 * unittests/optional/assignment/2.cc: New file.
7367 * unittests/optional/assignment/3.cc: New file.
7368 * unittests/optional/assignment/4.cc: New file.
7369 * unittests/optional/assignment/5.cc: New file.
7370 * unittests/optional/assignment/6.cc: New file.
7371 * unittests/optional/assignment/7.cc: New file.
7372 * unittests/optional/cons/copy.cc: New file.
7373 * unittests/optional/cons/default.cc: New file.
7374 * unittests/optional/cons/move.cc: New file.
7375 * unittests/optional/cons/value.cc: New file.
7376 * unittests/optional/in_place.cc: New file.
7377 * unittests/optional/observers/1.cc: New file.
7378 * unittests/optional/observers/2.cc: New file.
7379
7380 2017-04-18 Pedro Alves <palves@redhat.com>
7381
7382 * common/gdb_optional.h: Include common/traits.h.
7383 (in_place_t): New type.
7384 (in_place): New constexpr variable.
7385 (optional::optional): Remove member initialization of
7386 m_instantiated.
7387 (optional::optional(in_place_t...)): New constructor.
7388 (optional::~optional): Use reset.
7389 (optional::optional(const optional&)): New.
7390 (optional::optional(const optional&&)): New.
7391 (optional::optional(T &)): New.
7392 (optional::optional(T &&)): New.
7393 (operator::operator=(const optional &)): New.
7394 (operator::operator=(optional &&)): New.
7395 (operator::operator= (const T &))
7396 (operator::operator= (T &&))
7397 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7398 (operator::reset): New.
7399 (operator::m_instantiated):: Add in-class initializer.
7400 * common/traits.h: Include <type_traits>.
7401 (struct And): New types.
7402
7403 2017-04-18 Pedro Alves <palves@redhat.com>
7404
7405 * xml-support.c: Include <vector>.
7406 (scope_level::scope_level(const gdb_xml_element *))
7407 (scope_level::scope_level(scope_level&&)): New.
7408 (scope_level::~scope_level): New.
7409 (scope_level_s): Delete.
7410 (gdb_xml_parser::scopes): Now a std::vector.
7411 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
7412 Use std::vector.
7413 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
7414 scope cleanup code.
7415 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
7416 of the scopes member. Use std::vector::emplace_back.
7417
7418 2017-04-18 Pedro Alves <palves@redhat.com>
7419
7420 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
7421 a bool.
7422 (gdb_xml_end_element): Change type of first parameter.
7423 (gdb_xml_cleanup): Rename to ...
7424 (gdb_xml_parser::~gdb_xml_parser): ... this.
7425 (gdb_xml_create_parser_and_cleanup): Delete with ...
7426 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
7427 to this new ctor.
7428 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
7429 using gdb_xml_create_parser_and_cleanup.
7430 (xinclude_parsing_data): Add ctor/dtor.
7431 (xml_xinclude_cleanup): Delete.
7432 (xml_process_xincludes): Create a local xinclude_parsing_data
7433 instead of heap-allocating one. Create a local gdb_xml_parser
7434 instead of heap-allocating one with
7435 gdb_xml_create_parser_and_cleanup.
7436
7437 2017-04-18 John Baldwin <jhb@FreeBSD.org>
7438
7439 PR threads/20743
7440 * fbsd-nat.c (resume_one_thread_cb): Remove.
7441 (resume_all_threads_cb): Remove.
7442 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
7443 iterate_over_threads.
7444
7445 2017-04-17 Joel Brobecker <brobecker@adacore.com>
7446
7447 * NEWS: Create a new section for the next release branch.
7448 Rename the section of the current branch, now that it has
7449 been cut.
7450
7451 2017-04-17 Joel Brobecker <brobecker@adacore.com>
7452
7453 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
7454 * version.in: Bump version to 8.0.50.DATE-git.
7455
7456 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
7457
7458 PR gdb/21385
7459 * windows-nat.c (windows_create_inferior): Declare 'allargs'
7460 independently of the host, and fix build breakage on Cygwin.
7461
7462 2017-04-13 Pedro Alves <palves@redhat.com>
7463
7464 * inferior.c (free_inferior): Convert to ...
7465 (inferior::~inferior): ... this dtor.
7466 (inferior::inferior): New ctor, factored out from ...
7467 (add_inferior_silent): ... here. Allocate the inferior with a new
7468 expression.
7469 (delete_inferior): Call delete instead of free_inferior.
7470 * inferior.h (gdb_environ, continuation): Forward declare.
7471 (inferior): Now a class. Add in-class initialization to all
7472 members. Make boolean fields bool, except 'detaching'.
7473 (inferior::inferior): New explicit ctor.
7474 (inferior::~inferior): New.
7475
7476 2017-04-13 Pedro Alves <palves@redhat.com>
7477
7478 * inferior.c (init_inferior_list): Delete.
7479 * inferior.h (init_inferior_list): Delete.
7480
7481 2017-04-13 Pedro Alves <palves@redhat.com>
7482
7483 PR threads/13217
7484 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
7485 (top level): Call it twice, with different thread sets.
7486
7487 2017-04-13 Pedro Alves <palves@redhat.com>
7488
7489 * thread.c: Include <algorithm>.
7490 (thread_array_cleanup): Delete.
7491 (scoped_inc_dec_ref): New class.
7492 (live_threads_count): New function.
7493 (set_thread_refcount): Delete.
7494 (tp_array_compar_ascending): Now a bool.
7495 (tp_array_compar): Convert to a std::sort comparison function.
7496 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
7497 and live_threads_count.
7498
7499 2017-04-13 Pedro Alves <palves@redhat.com>
7500
7501 * infrun.c (follow_fork_inferior): Also switch the current
7502 inferior.
7503
7504 2017-04-13 Pedro Alves <palves@redhat.com>
7505
7506 * breakpoint.c (watch_command_1): Save watchpoint-frame info
7507 before calling create_internal_breakpoint.
7508
7509 2017-04-13 Pedro Alves <palves@redhat.com>
7510
7511 * fork-child.c (execv_argv): New class.
7512 (breakup_args): Refactored as ...
7513 (execv_argv::init_for_no_shell): .. this method of execv_argv.
7514 Copy arguments to storage and replace separators with NULL
7515 terminators in place.
7516 (escape_bang_in_quoted_argument): Adjust to return bool.
7517 (execv_argv::execv_argv): New ctor.
7518 (execv_argv::init_for_shell): New method, factored out from
7519 fork_inferior. Don't strdup strings into the vector.
7520 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
7521 Remove free_vector_argv call.
7522
7523 2017-04-13 Yao Qi <yao.qi@linaro.org>
7524
7525 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
7526 tdep->rx_psw_type.
7527
7528 2017-04-13 Yao Qi <yao.qi@linaro.org>
7529
7530 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
7531 * rx-tdep.c (rx_gdbarch_init): Likewise.
7532
7533 2017-04-13 Pedro Alves <palves@redhat.com>
7534
7535 * breakpoint.h (struct breakpoint): Reindent.
7536
7537 2017-04-13 Pedro Alves <palves@redhat.com>
7538
7539 * breakpoint.c (bp_location): Rename to ...
7540 (bp_locations): ... this. All references updated.
7541 (bp_location_count): Rename to ...
7542 (bp_locations_count): ... this. All references updated.
7543 (bp_location_placed_address_before_address_max): Rename to ...
7544 (bp_locations_placed_address_before_address_max): ... this. All
7545 references updated.
7546 (bp_location_shadow_len_after_address_max): Rename to ...
7547 (bp_locations_shadow_len_after_address_max): ... this. All
7548 references updated.
7549 (bp_location_compare_addrs): Rename to ...
7550 (bp_locations_compare_addrs): ... this. All references updated.
7551 (bp_location_compare):Rename to ...
7552 (bp_locations_compare): ... this. All references updated.
7553 (bp_location_target_extensions_update): Rename to ...
7554 (bp_locations_target_extensions_update): ... this. All references
7555 updated.
7556
7557 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7558
7559 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
7560 * common/common.m4: Check headers 'termios.h', 'termio.h' and
7561 'sgtty.h'.
7562 * common/gdb_termios.h: New file, with parts of "terminal.h".
7563 * inflow.c: Include "gdb_termios.h".
7564 * ser-unix.c: Include "gdb_termios.h".
7565 * terminal.h: Move terminal-related defines to
7566 "common/gdb_termios.h".
7567
7568 2017-04-12 Tom Tromey <tom@tromey.com>
7569
7570 * probe.c (parse_probes): Update.
7571 * location.h (delete_event_location): Don't declare.
7572 (event_location_deleter::operator()): Update.
7573 * location.c (event_location_deleter::operator()): Rename from
7574 delete_event_location.
7575 * linespec.h (linespec_result) <location>: Change type to
7576 event_location_up.
7577 * linespec.c (canonicalize_linespec, event_location_to_sals)
7578 (decode_objc): Update.
7579 (linespec_result): Don't call delete_event_location.
7580 * breakpoint.c (create_breakpoints_sal)
7581 (bkpt_probe_create_sals_from_location)
7582 (strace_marker_create_sals_from_location): Update.
7583
7584 2017-04-12 Tom Tromey <tom@tromey.com>
7585
7586 * linespec.h (struct linespec_result): Add constructor and
7587 destructor.
7588 (init_linespec_result, destroy_linespec_result)
7589 (make_cleanup_destroy_linespec_result): Don't declare.
7590 * linespec.c (init_linespec_result): Remove.
7591 (linespec_result::~linespec_result): Rename from
7592 destroy_linespec_result. Update.
7593 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
7594 Remove.
7595 * breakpoint.c (create_breakpoint, break_range_command)
7596 (decode_location_default): Update.
7597 * ax-gdb.c (agent_command_1): Update.
7598
7599 2017-04-12 Tom Tromey <tom@tromey.com>
7600
7601 * remote.c (remote_download_tracepoint): Update.
7602 * python/py-breakpoint.c (bppy_get_location): Update.
7603 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
7604 (gdbscm_breakpoint_location): Update.
7605 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
7606 * breakpoint.h (struct breakpoint) <location, location_range_end>:
7607 Change type to event_location_up.
7608 * breakpoint.c (create_overlay_event_breakpoint)
7609 (create_longjmp_master_breakpoint)
7610 (create_std_terminate_master_breakpoint)
7611 (create_exception_master_breakpoint)
7612 (breakpoint_event_location_empty_p, print_breakpoint_location)
7613 (print_one_breakpoint_location, create_thread_event_breakpoint)
7614 (init_breakpoint_sal, create_breakpoint)
7615 (print_recreate_ranged_breakpoint, break_range_command)
7616 (init_ada_exception_breakpoint, say_where): Update.
7617 (base_breakpoint_dtor): Don't call delete_event_location.
7618 (bkpt_print_recreate, tracepoint_print_recreate)
7619 (dprintf_print_recreate, update_static_tracepoint)
7620 (breakpoint_re_set_default): Update.
7621
7622 2017-04-12 Tom Tromey <tom@tromey.com>
7623
7624 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
7625 type of "to_do". Update.
7626 (compute_stack_depth): Use std::vector.
7627
7628 2017-04-12 Tom Tromey <tom@tromey.com>
7629
7630 * printcmd.c (find_instruction_backward): Use std::vector.
7631
7632 2017-04-12 Tom Tromey <tom@tromey.com>
7633
7634 * symfile.c (objfilep): Remove typedef.
7635 (reread_symbols): Use a std::vector.
7636
7637 2017-04-12 Tom Tromey <tom@tromey.com>
7638
7639 * mi/mi-main.c (exec_direction_forward): Remove.
7640 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
7641 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7642 scoped_restore.
7643 * guile/guile.c (guile_repl_command, guile_command)
7644 (gdbscm_execute_gdb_command): Use scoped_restore.
7645 * go-exp.y (go_parse): Use scoped_restore.
7646 * d-exp.y (d_parse): Use scoped_restore.
7647 * cli/cli-decode.c (cmd_func): Use scoped_restore.
7648 * c-exp.y (c_parse): Use scoped_restore.
7649
7650 2017-04-12 Tom Tromey <tom@tromey.com>
7651
7652 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
7653 (mi_parse): Update return type.
7654 (mi_parse_free): Remove.
7655 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
7656 (mi_parse::~mi_parse): Rename from mi_parse_free.
7657 (mi_parse_cleanup): Remove.
7658 (mi_parse): Return a unique_ptr. Use new.
7659 * mi/mi-main.c (mi_execute_command): Update.
7660
7661 2017-04-12 Tom Tromey <tom@tromey.com>
7662
7663 * location.c (explicit_location_lex_one): Return a
7664 unique_xmalloc_ptr.
7665 (string_to_explicit_location): Update. Remove cleanups.
7666
7667 2017-04-12 Tom Tromey <tom@tromey.com>
7668
7669 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
7670 (compare_value_and_voffset): Change type. Update.
7671 (compute_vtable_size): Change type of "offset_vec".
7672 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
7673 (gnuv3_get_typeid): Remove extraneous declaration.
7674
7675 2017-04-12 Tom Tromey <tom@tromey.com>
7676
7677 * charset.h (wchar_iterator): Fix comment.
7678
7679 2017-04-12 Tom Tromey <tom@tromey.com>
7680
7681 * charset.c (iconv_wrapper): New class.
7682 (cleanup_iconv): Remove.
7683 (convert_between_encodings): Use it.
7684
7685 2017-04-12 Tom Tromey <tom@tromey.com>
7686
7687 * symfile.h (increment_reading_symtab): Update type.
7688 * symfile.c (decrement_reading_symtab): Remove.
7689 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
7690 * psymtab.c (psymtab_to_symtab): Update.
7691 * dwarf2read.c (dw2_instantiate_symtab): Update.
7692
7693 2017-04-12 Tom Tromey <tom@tromey.com>
7694
7695 * jit.c (struct jit_reader): Declare separately. Add constructor
7696 and destructor. Change type of "handle".
7697 (loaded_jit_reader): Define separately.
7698 (jit_reader_load): Update. New "new".
7699 (jit_reader_unload_command): Use "delete".
7700 * gdb-dlfcn.h (struct dlclose_deleter): New.
7701 (gdb_dlhandle_up): New typedef.
7702 (gdb_dlopen, gdb_dlsym): Update types.
7703 (gdb_dlclose): Remove.
7704 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
7705 (gdb_dlsym): Change type of "handle".
7706 (make_cleanup_dlclose): Remove.
7707 (dlclose_deleter::operator()): Rename from gdb_dlclose.
7708 * compile/compile-c-support.c (load_libcc): Update.
7709
7710 2017-04-12 Tom Tromey <tom@tromey.com>
7711
7712 * symtab.h (find_pcs_for_symtab_line): Change return type.
7713 * symtab.c (find_pcs_for_symtab_line): Change return type.
7714 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
7715 type of "vec". Update.
7716 (ltpy_get_pcs_for_line): Update.
7717 * linespec.c (decode_digits_ordinary): Update.
7718
7719 2017-04-12 Tom Tromey <tom@tromey.com>
7720
7721 * tracepoint.c (actions_command): Update.
7722 * python/python.c (python_command, python_interactive_command):
7723 Update.
7724 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7725 * guile/guile.c (guile_command): Update.
7726 * defs.h (read_command_lines, read_command_lines_1): Return
7727 command_line_up.
7728 (command_lines_deleter): New struct.
7729 (command_line_up): New typedef.
7730 * compile/compile.c (compile_code_command)
7731 (compile_print_command): Update.
7732 * cli/cli-script.h (get_command_line, copy_command_lines): Return
7733 command_line_up.
7734 (make_cleanup_free_command_lines): Remove.
7735 * cli/cli-script.c (get_command_line, read_command_lines_1)
7736 (copy_command_lines): Return command_line_up.
7737 (while_command, if_command, read_command_lines, define_command)
7738 (document_command): Update.
7739 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
7740 Remove.
7741 * breakpoint.h (breakpoint_set_commands): Change type of
7742 "commands".
7743 * breakpoint.c (breakpoint_set_commands): Change type of
7744 "commands". Update.
7745 (do_map_commands_command, update_dprintf_command_list)
7746 (create_tracepoint_from_upload): Update.
7747
7748 2017-04-12 Tom Tromey <tom@tromey.com>
7749
7750 * tracepoint.c (scope_info): Update.
7751 * spu-tdep.c (spu_catch_start): Update.
7752 * python/python.c (gdbpy_decode_line): Update.
7753 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
7754 * python/py-breakpoint.c (bppy_init): Update.
7755 * probe.c (parse_probes): Update.
7756 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
7757 * location.h (event_location_deleter): New struct.
7758 (event_location_up): New typedef.
7759 (new_linespec_location, new_address_location, new_probe_location)
7760 (new_explicit_location, copy_event_location)
7761 (string_to_event_location, string_to_event_location_basic)
7762 (string_to_explicit_location): Update return type.
7763 (make_cleanup_delete_event_location): Remove.
7764 * location.c (new_linespec_location, new_address_location)
7765 (new_probe_location, new_explicit_location, copy_event_location):
7766 Return event_location_up.
7767 (delete_event_location_cleanup)
7768 (make_cleanup_delete_event_location): Remove.
7769 (string_to_explicit_location, string_to_event_location_basic)
7770 (string_to_event_location): Return event_location_up.
7771 * linespec.c (canonicalize_linespec, event_location_to_sals)
7772 (decode_line_with_current_source)
7773 (decode_line_with_last_displayed, decode_objc): Update.
7774 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
7775 * completer.c (location_completer): Update.
7776 * cli/cli-cmds.c (edit_command, list_command): Update.
7777 * breakpoint.c (create_overlay_event_breakpoint)
7778 (create_longjmp_master_breakpoint)
7779 (create_std_terminate_master_breakpoint)
7780 (create_exception_master_breakpoint)
7781 (create_thread_event_breakpoint): Update.
7782 (init_breakpoint_sal): Update. Remove some dead code.
7783 (create_breakpoint_sal): Change type of "location". Update.
7784 (create_breakpoints_sal, create_breakpoint, break_command_1)
7785 (dprintf_command, break_range_command, until_break_command)
7786 (init_ada_exception_breakpoint)
7787 (strace_marker_create_sals_from_location)
7788 (update_static_tracepoint, trace_command, ftrace_command)
7789 (strace_command, create_tracepoint_from_upload): Update.
7790 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7791 * ax-gdb.c (agent_command_1): Update.
7792
7793 2017-04-12 Pedro Alves <palves@redhat.com>
7794
7795 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
7796 * configure.tgt: Handle i[34567]86-*-go32* and
7797 i[34567]86-*-msdosdjgpp*.
7798 * i386-tdep.c (i386_svr4_reg_to_regnum):
7799 Make extern.
7800 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
7801 i386-go32-tdep.c.
7802 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
7803 * i386-go32-tdep.c: New file.
7804 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
7805 declarations.
7806
7807 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
7808
7809 * aix-thread.c (pd_status2str): Change return type to const char *.
7810
7811 2017-04-12 Pedro Alves <palves@redhat.com>
7812
7813 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
7814 calls to set_gdbarch_gnu_triplet_regexp.
7815
7816 2017-04-12 Pedro Alves <palves@redhat.com>
7817
7818 PR gdb/21323
7819 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
7820 New enum value.
7821 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
7822 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
7823 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
7824 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
7825 * gdbarch.h, gdbarch.c: Regenerate.
7826 * aarch64-tdep.c (aarch64_gdbarch_init): Override
7827 gdbarch_wchar_bit and gdbarch_wchar_signed.
7828 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
7829 * arm-tdep.c (arm_gdbarch_init): Likewise.
7830 * avr-tdep.c (avr_gdbarch_init): Likewise.
7831 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
7832 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
7833 * i386-tdep.c (i386_go32_init_abi): Likewise.
7834 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
7835 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
7836 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7837 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
7838 * sh-tdep.c (sh_gdbarch_init): Likewise.
7839 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7840 * sparc64-tdep.c (sparc64_init_abi): Likewise.
7841 * windows-tdep.c (windows_init_abi): Likewise.
7842 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
7843
7844 2017-04-12 Pedro Alves <palves@redhat.com>
7845
7846 PR c++/21323
7847 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
7848 cplus_primitive_type_char32_t>: New enum values.
7849 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
7850 and cplus_primitive_type_char32_t.
7851 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
7852 32, use the archtecture's built-in type for char16_t and char32_t,
7853 respectively. Otherwise, fallback to init_integer_type as before,
7854 but make the type unsigned, and issue a complaint.
7855 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
7856
7857 2017-04-12 Alan Hayward <alan.hayward@arm.com>
7858
7859 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
7860 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
7861
7862 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7863
7864 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
7865 'const char *'.
7866
7867 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7868
7869 * common/common-utils.c (free_vector_argv): New function.
7870 * common/common-utils.h: Include <vector>.
7871 (free_vector_argv): New prototype.
7872 * darwin-nat.c (darwin_create_inferior): Rewrite function
7873 prototype in order to constify "exec_file" and accept a
7874 "std::string" for "allargs".
7875 * fork-child.c: Include <vector>.
7876 (breakup_args): Rewrite function, using C++.
7877 (fork_inferior): Rewrite function header, constify "exec_file_arg"
7878 and accept "std::string" for "allargs". Update the code to
7879 calculate "argv" based on "allargs". Update calls to "exec_fun"
7880 and "execvp".
7881 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
7882 order to constify "exec_file" and accept a "std::string" for
7883 "allargs".
7884 * go32-nat.c (go32_create_inferior): Likewise.
7885 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
7886 * infcmd.c (run_command_1): Constify "exec_file". Use
7887 "std::string" for inferior arguments.
7888 * inferior.h (fork_inferior): Update prototype.
7889 * linux-nat.c (linux_nat_create_inferior): Rewrite function
7890 prototype in order to constify "exec_file" and accept a
7891 "std::string" for "allargs".
7892 * nto-procfs.c (procfs_create_inferior): Likewise.
7893 * procfs.c (procfs_create_inferior): Likewise.
7894 * remote-sim.c (gdbsim_create_inferior): Likewise.
7895 * remote.c (extended_remote_run): Update code to accept
7896 "std::string" as argument.
7897 (extended_remote_create_inferior): Rewrite function prototype in
7898 order to constify "exec_file" and accept a "std::string" for
7899 "allargs".
7900 * rs6000-nat.c (super_create_inferior): Likewise.
7901 (rs6000_create_inferior): Likewise.
7902 * target.h (struct target_ops) <to_create_inferior>: Likewise.
7903 * windows-nat.c (windows_create_inferior): Likewise.
7904
7905 2017-04-11 Pedro Alves <palves@redhat.com>
7906
7907 * thread.c: Fix whitespace throughout.
7908
7909 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
7910
7911 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
7912
7913 2017-04-11 Alan Hayward <alan.hayward@arm.com>
7914
7915 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
7916
7917 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
7918
7919 PR gdb/21364
7920 * osdata.c (info_osdata): Check if 'type' is an empty string
7921 instead of NULL.
7922
7923 2017-04-10 Pedro Alves <palves@redhat.com>
7924
7925 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
7926 (ptid_to_global_thread_id, in_thread_list)
7927 (do_captured_list_thread_ids, set_resumed, set_running)
7928 (set_executing, set_stop_requested, finish_thread_state)
7929 (validate_registers_access, can_access_registers_ptid)
7930 (print_thread_info_1, switch_to_thread)
7931 (do_restore_current_thread_cleanup)
7932 (make_cleanup_restore_current_thread, thread_command)
7933 (thread_name_command): Use operator== instead of ptid_equal.
7934
7935 2017-04-10 Pedro Alves <palves@redhat.com>
7936
7937 * thread.c (struct current_thread_cleanup) <next>: Delete field.
7938 (current_thread_cleanup_chain): Delete.
7939 (restore_current_thread_cleanup_dtor)
7940 (make_cleanup_restore_current_thread): Remove references to
7941 current_thread_cleanup_chain.
7942
7943 2017-04-10 Alan Hayward <alan.hayward@arm.com>
7944
7945 * msp430-tdep.c (msp430_pseudo_register_read): Never return
7946 REG_UNKNOWN.
7947
7948 2017-04-10 Yao Qi <yao.qi@linaro.org>
7949
7950 PR gdb/19942
7951 * gdbthread.h (thread_info::deletable): New method.
7952 (thread_info::incref): New method.
7953 (thread_info::decref): New method.
7954 (thread_info::refcount): Move it to private.
7955 * infrun.c (save_stop_context): Call inc_refcount.
7956 (release_stop_context_cleanup): Likewise.
7957 * thread.c (set_thread_exited): New function.
7958 (init_thread_list): Delete "tp" only it is deletable, otherwise
7959 call set_thread_exited.
7960 (delete_thread_1): Call set_thread_exited.
7961 (current_thread_cleanup) <inferior_pid>: Remove.
7962 <thread>: New field.
7963 (restore_current_thread_ptid_changed): Removed.
7964 (do_restore_current_thread_cleanup): Adjust.
7965 (restore_current_thread_cleanup_dtor): Don't call
7966 find_thread_ptid.
7967 (set_thread_refcount): Use dec_refcount.
7968 (make_cleanup_restore_current_thread): Adjust.
7969 (thread_apply_all_command): Call inc_refcount.
7970 (_initialize_thread): Don't call
7971 observer_attach_thread_ptid_changed.
7972
7973 2017-04-10 Yao Qi <yao.qi@linaro.org>
7974
7975 * thread.c (delete_thread_1): Hoist code on marking thread as
7976 exited.
7977
7978 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7979
7980 * windows-nat.c (windows_detach): Initialize ptid with
7981 minus_one_ptid.
7982
7983 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
7984
7985 * unittests/ptid-selftests.c: Fix erroneous assert messages.
7986
7987 2017-04-07 Alan Hayward <alan.hayward@arm.com>
7988
7989 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
7990 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
7991 (bfin_pseudo_register_write): Likewise
7992
7993 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
7994
7995 * common/ptid.h (struct ptid): Change to...
7996 (class ptid_t): ... this.
7997 <ptid_t>: New constructors.
7998 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
7999 matches>: New methods.
8000 <make_null, make_minus_one>: New static methods.
8001 <pid>: Rename to...
8002 <m_pid>: ...this.
8003 <lwp>: Rename to...
8004 <m_lwp>: ...this.
8005 <tid>: Rename to...
8006 <m_tid>: ...this.
8007 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
8008 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
8009 as references, move comment to class ptid_t.
8010 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
8011 ptid_t static methods.
8012 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
8013 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
8014 Take ptid arguments as references, implement using ptid_t methods.
8015 * unittests/ptid-selftests.c: New file.
8016 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8017 unittests/ptid-selftests.c.
8018 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
8019
8020 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
8021
8022 * python/python.c (python_run_simple_file): Cast mode literal to
8023 non-const char pointer as expected by PyFile_FromString.
8024
8025 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
8026
8027 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
8028 minus_one_ptid and null_ptid.
8029
8030 2017-04-05 Pedro Alves <palves@redhat.com>
8031
8032 * warning.m4 (build_warnings): Remove -Wno-write-strings.
8033 * configure: Regenerate.
8034
8035 2017-04-05 Pedro Alves <palves@redhat.com>
8036
8037 * ada-exp.y (yyerror): Constify.
8038 * ada-lang.c (bound_name, get_selections)
8039 (ada_variant_discrim_type)
8040 (ada_variant_discrim_name, ada_value_struct_elt)
8041 (ada_lookup_struct_elt_type, is_unchecked_variant)
8042 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
8043 (catch_ada_exception_command_split)
8044 (catch_ada_assert_command_split, catch_assert_command)
8045 (ada_op_name): Constify.
8046 * ada-lang.h (ada_yyerror, get_selections)
8047 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
8048 * arc-tdep.c (arc_print_frame_cache): Constify.
8049 * arm-tdep.c (arm_skip_stub): Constify.
8050 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
8051 (gen_aggregate_elt_ref): Constify.
8052 * bcache.c (print_bcache_statistics): Constify.
8053 * bcache.h (print_bcache_statistics): Constify.
8054 * break-catch-throw.c (catch_exception_command_1):
8055 * breakpoint.c (struct ep_type_description::description):
8056 Constify.
8057 (add_solib_catchpoint): Constify.
8058 (catch_fork_command_1): Add cast.
8059 (add_catch_command): Constify.
8060 * breakpoint.h (add_catch_command, add_solib_catchpoint):
8061 Constify.
8062 * bsd-uthread.c (bsd_uthread_state): Constify.
8063 * buildsym.c (patch_subfile_names): Constify.
8064 * buildsym.h (next_symbol_text_func, patch_subfile_names):
8065 Constify.
8066 * c-exp.y (yyerror): Constify.
8067 (token::oper): Constify.
8068 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
8069 * c-varobj.c (cplus_describe_child): Constify.
8070 * charset.c (find_charset_names): Add cast.
8071 (find_charset_names): Constify array and add const_cast.
8072 * cli/cli-cmds.c (complete_command, cd_command): Constify.
8073 (edit_command): Constify.
8074 * cli/cli-decode.c (lookup_cmd): Constify.
8075 * cli/cli-dump.c (dump_memory_command, dump_value_command):
8076 Constify.
8077 (struct dump_context): Constify.
8078 (add_dump_command, restore_command): Constify.
8079 * cli/cli-script.c (get_command_line): Constify.
8080 * cli/cli-script.h (get_command_line): Constify.
8081 * cli/cli-utils.c (check_for_argument): Constify.
8082 * cli/cli-utils.h (check_for_argument): Constify.
8083 * coff-pe-read.c (struct read_pe_section_data): Constify.
8084 * command.h (lookup_cmd): Constify.
8085 * common/print-utils.c (decimal2str): Constify.
8086 * completer.c (gdb_print_filename): Constify.
8087 * corefile.c (set_gnutarget): Constify.
8088 * cp-name-parser.y (yyerror): Constify.
8089 * cp-valprint.c (cp_print_class_member): Constify.
8090 * cris-tdep.c (cris_register_name, crisv32_register_name):
8091 Constify.
8092 * d-exp.y (yyerror): Constify.
8093 (struct token::oper): Constify.
8094 * d-lang.h (d_yyerror): Constify.
8095 * dbxread.c (struct header_file_location::name): Constify.
8096 (add_old_header_file, add_new_header_file, last_function_name)
8097 (dbx_next_symbol_text, add_bincl_to_list)
8098 (find_corresponding_bincl_psymtab, set_namestring)
8099 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
8100 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
8101 * defs.h (command_line_input, print_address_symbolic)
8102 (deprecated_readline_begin_hook): Constify.
8103 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
8104 Constify.
8105 * event-top.c (handle_line_of_input): Constify and add cast.
8106 * exceptions.c (catch_errors): Constify.
8107 * exceptions.h (catch_errors): Constify.
8108 * expprint.c (print_subexp_standard, op_string, op_name)
8109 (op_name_standard, dump_raw_expression, dump_raw_expression):
8110 * expression.h (op_name, op_string, dump_raw_expression):
8111 Constify.
8112 * f-exp.y (yyerror): Constify.
8113 (struct token::oper): Constify.
8114 (struct f77_boolean_val::name): Constify.
8115 * f-lang.c (f_word_break_characters): Constify.
8116 * f-lang.h (f_yyerror): Constify.
8117 * fork-child.c (fork_inferior): Add cast.
8118 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8119 (new_variant): Constify.
8120 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8121 * gdbarch.c: Regenerate.
8122 * gdbcore.h (set_gnutarget): Constify.
8123 * go-exp.y (yyerror): Constify.
8124 (token::oper): Constify.
8125 * go-lang.h (go_yyerror): Constify.
8126 * go32-nat.c (go32_sysinfo): Constify.
8127 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8128 * guile/scm-cmd.c (cmdscm_function): Constify.
8129 * guile/scm-param.c (pascm_param_value): Constify.
8130 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8131 (h8300sx_register_name): Constify.
8132 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8133 Constify.
8134 * ia64-tdep.c (ia64_register_names): Constify.
8135 * infcmd.c (construct_inferior_arguments): Constify.
8136 (path_command, attach_post_wait): Constify.
8137 * language.c (show_range_command, show_case_command)
8138 (unk_lang_error): Constify.
8139 * language.h (language_defn::la_error)
8140 (language_defn::la_name_of_this): Constify.
8141 * linespec.c (decode_line_2): Constify.
8142 * linux-thread-db.c (thread_db_err_str): Constify.
8143 * lm32-tdep.c (lm32_register_name): Constify.
8144 * m2-exp.y (yyerror): Constify.
8145 * m2-lang.h (m2_yyerror): Constify.
8146 * m32r-tdep.c (m32r_register_names): Constify and make static.
8147 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8148 * m88k-tdep.c (m88k_register_name): Constify.
8149 * macroexp.c (appendmem): Constify.
8150 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8151 (upgrade_type, parse_external, parse_partial_symbols)
8152 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8153 (new_symbol): Constify.
8154 * memattr.c (mem_info_command): Constify.
8155 * mep-tdep.c (register_name_from_keyword): Constify.
8156 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8157 Constify.
8158 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8159 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8160 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8161 cast.
8162 (mi_execute_async_cli_command): Constify.
8163 * mips-tdep.c (mips_register_name): Constify.
8164 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8165 (am33_register_name, am33_2_register_name)
8166 * moxie-tdep.c (moxie_register_names): Constify.
8167 * nat/linux-osdata.c (osdata_type): Constify fields.
8168 * nto-tdep.c (nto_parse_redirection): Constify.
8169 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8170 (lookup_child_selector): Constify.
8171 (objc_methcall::name): Constify.
8172 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8173 (lookup_struct_typedef): Constify.
8174 * objfiles.c (pc_in_section): Constify.
8175 * objfiles.h (pc_in_section): Constify.
8176 * p-exp.y (struct token::oper): Constify.
8177 (yyerror): Constify.
8178 * p-lang.h (pascal_yyerror): Constify.
8179 * parser-defs.h (op_name_standard): Constify.
8180 (op_print::string): Constify.
8181 (exp_descriptor::op_name): Constify.
8182 * printcmd.c (print_address_symbolic): Constify.
8183 * psymtab.c (print_partial_symbols): Constify.
8184 * python/py-breakpoint.c (stop_func): Constify.
8185 (bppy_get_expression): Constify.
8186 * python/py-cmd.c (cmdpy_completer::name): Constify.
8187 (cmdpy_function): Constify.
8188 * python/py-event.c (evpy_add_attribute)
8189 (gdbpy_initialize_event_generic): Constify.
8190 * python/py-event.h (evpy_add_attribute)
8191 (gdbpy_initialize_event_generic): Constify.
8192 * python/py-evts.c (add_new_registry): Constify.
8193 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8194 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8195 * python/py-inferior.c (get_buffer): Add cast.
8196 * python/py-param.c (parm_constant::name): Constify.
8197 * python/py-unwind.c (fprint_frame_id): Constify.
8198 * python/python.c (gdbpy_parameter_value): Constify.
8199 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8200 * remote.c (memory_packet_config::name): Constify.
8201 (show_packet_config_cmd, remote_write_bytes)
8202 (remote_buffer_add_string):
8203 * reverse.c (exec_reverse_once): Constify.
8204 * rs6000-tdep.c (variant::name, variant::description): Constify.
8205 * rust-exp.y (rustyyerror): Constify.
8206 * rust-lang.c (rust_op_name): Constify.
8207 * rust-lang.h (rustyyerror): Constify.
8208 * serial.h (serial_ops::name): Constify.
8209 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8210 (sh_sh3e_register_name, sh_sh2e_register_name)
8211 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8212 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8213 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8214 (sh_sh4al_dsp_register_name): Constify.
8215 * sh64-tdep.c (sh64_register_name): Constify.
8216 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8217 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8218 * stabsread.c (patch_block_stabs, read_type_number)
8219 (ref_map::stabs, ref_add, process_reference)
8220 (symbol_reference_defined, define_symbol, define_symbol)
8221 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8222 (read_one_struct_field, read_struct_fields, read_baseclasses)
8223 (read_tilde_fields, read_struct_type, read_array_type)
8224 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8225 (read_huge_number, read_range_type, read_args, common_block_start)
8226 (find_name_end): Constify.
8227 * stabsread.h (common_block_start, define_symbol)
8228 (process_one_symbol, symbol_reference_defined, ref_add):
8229 * symfile.c (get_section_index, add_symbol_file_command):
8230 * symfile.h (get_section_index): Constify.
8231 * target-descriptions.c (tdesc_type::name): Constify.
8232 (tdesc_free_type): Add cast.
8233 * target.c (find_default_run_target):
8234 (add_deprecated_target_alias, find_default_run_target)
8235 (target_announce_detach): Constify.
8236 (do_option): Constify.
8237 * target.h (add_deprecated_target_alias): Constify.
8238 * thread.c (print_thread_info_1): Constify.
8239 * top.c (deprecated_readline_begin_hook, command_line_input):
8240 Constify.
8241 (init_main): Add casts.
8242 * top.h (handle_line_of_input): Constify.
8243 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8244 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8245 (tfind_command): Rename to ...
8246 (tfind_command_1): ... this and constify.
8247 (tfind_command): New function.
8248 (tfind_end_command, tfind_start_command): Adjust.
8249 (encode_source_string): Constify.
8250 * tracepoint.h (encode_source_string): Constify.
8251 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8252 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8253 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8254 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8255 * tui/tui-win.c (parse_scrolling_args): Constify.
8256 * tui/tui-windata.c (tui_erase_data_content): Constify.
8257 * tui/tui-windata.h (tui_erase_data_content): Constify.
8258 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8259 * tui/tui.c (tui_enable): Add cast.
8260 * utils.c (defaulted_query): Constify.
8261 (init_page_info): Add cast.
8262 (puts_debug, subset_compare): Constify.
8263 * utils.h (subset_compare): Constify.
8264 * varobj.c (varobj_format_string): Constify.
8265 * varobj.h (varobj_format_string): Constify.
8266 * vax-tdep.c (vax_register_name): Constify.
8267 * windows-nat.c (windows_detach): Constify.
8268 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8269 * xml-support.c (gdb_xml_end_element): Constify.
8270 * xml-tdesc.c (tdesc_start_reg): Constify.
8271 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8272 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8273 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8274
8275 2017-04-05 Pedro Alves <palves@redhat.com>
8276
8277 * proc-api.c (struct trans): Constify.
8278 (procfs_note): Constify.
8279 * proc-events.c (struct trans, syscall_table):
8280 * proc-flags.c (struct trans): Constify.
8281 * proc-utils.h (procfs_note): Constify.
8282 * proc-why.c (struct trans): Constify.
8283 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8284 (procfs_detach): Constify.
8285 * sol-thread.c (struct string_map): Constify.
8286 (td_err_string, td_state_string): Constify.
8287
8288 2017-04-05 Pedro Alves <palves@redhat.com>
8289
8290 * proc-api.c (procfs_filename): Don't initialize
8291 procfs_filename.
8292 (prepare_to_trace): Assume procfs_filename is non-NULL.
8293 (_initialize_proc_api): Give procfs_filename a default value here.
8294
8295 2017-04-05 Pedro Alves <palves@redhat.com>
8296
8297 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8298 'cond_string' parameter.
8299 (extract_exception_regexp): Constify 'string' parameter.
8300 (catch_exception_command_1): Constify.
8301 * breakpoint.c (init_catchpoint)
8302 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8303 parameter.
8304 (ep_parse_optional_if_clause, catch_fork_command_1)
8305 (catch_exec_command_1): Constify.
8306 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8307 parameter.
8308 (ep_parse_optional_if_clause): Constify.
8309 * cli/cli-utils.c (remove_trailing_whitespace)
8310 (check_for_argument): Constify.
8311 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8312 non-const overload.
8313 (check_for_argument): Likewise.
8314
8315 2017-04-05 Pedro Alves <palves@redhat.com>
8316
8317 * event-top.c (command_line_handler): Add cast to execute_command
8318 call.
8319 * record-btrace.c (cmd_record_btrace_bts_start)
8320 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8321 (cmd_record_btrace_start): Add cast to execute_command call.
8322 * record-full.c (record_full_goto_insn):
8323 * record.c (record_start, record_stop): Add cast to
8324 execute_command_to_string calls.
8325 (cmd_record_start): Add cast to execute_command calls.
8326
8327 2017-04-05 Pedro Alves <palves@redhat.com>
8328
8329 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8330 static inline function.
8331 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8332 array and use gdb_PyArg_ParseTupleAndKeywords.
8333 * python/py-cmd.c (cmdpy_init): Likewise.
8334 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8335 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8336 (infpy_search_memory): Likewise.
8337 * python/py-objfile.c (objfpy_add_separate_debug_file)
8338 (gdbpy_lookup_objfile): Likewise.
8339 * python/py-symbol.c (gdbpy_lookup_symbol)
8340 (gdbpy_lookup_global_symbol): Likewise.
8341 * python/py-type.c (gdbpy_lookup_type): Likewise.
8342 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8343 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8344 Likewise.
8345
8346 2017-04-05 Pedro Alves <palves@redhat.com>
8347
8348 * python/python-internal.h (gdb_PyGetSetDef): New type.
8349 * python/py-block.c (block_object_getset)
8350 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8351 * python/py-event.c (event_object_getset)
8352 (finish_breakpoint_object_getset): Likewise.
8353 * python/py-inferior.c (inferior_object_getset): Likewise.
8354 * python/py-infthread.c (thread_object_getset): Likewise.
8355 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8356 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8357 * python/py-objfile.c (objfile_getset): Likewise.
8358 * python/py-progspace.c (pspace_getset): Likewise.
8359 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8360 Likewise.
8361 * python/py-record.c (recpy_record_getset): Likewise.
8362 * python/py-symbol.c (symbol_object_getset): Likewise.
8363 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8364 Likewise.
8365 * python/py-type.c (type_object_getset, field_object_getset):
8366 Likewise.
8367 * python/py-value.c (value_object_getset): Likewise.
8368
8369 2017-04-05 Pedro Alves <palves@redhat.com>
8370
8371 * python/python-internal.h (gdb_PyObject_CallMethod)
8372 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8373 New functions.
8374 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8375 (PySys_GetObject, PySys_SetPath): New macros.
8376
8377 2017-04-05 Pedro Alves <palves@redhat.com>
8378
8379 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8380 info_osdata_command.
8381 * osdata.c (info_osdata_command): Rename to ...
8382 (info_osdata): ... this. Constify 'type' parameter, and remove
8383 the 'from_tty' parameter. Accept NULL TYPE.
8384 (info_osdata_command): New function.
8385 * osdata.h (info_osdata_command): Remove declaration.
8386 (info_osdata): New declaration.
8387
8388 2017-04-05 Pedro Alves <palves@redhat.com>
8389
8390 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8391 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8392 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8393 parameter.
8394 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8395 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8396 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8397 parameter.
8398 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8399 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
8400 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
8401 (mi_cmd_file_list_exec_source_files)
8402 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
8403 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8404 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
8405 parameter.
8406 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
8407 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
8408 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
8409 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
8410 (mi_cmd_stack_info_frame): Constify 'command' parameter.
8411 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
8412 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
8413 'command' parameter.
8414 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
8415 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
8416 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
8417 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
8418 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
8419 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
8420 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
8421 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
8422 (mi_cmd_var_set_update_range): Constify 'command' parameter.
8423 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
8424 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
8425 parameter.
8426 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
8427 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
8428 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
8429 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
8430 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
8431 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
8432 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
8433 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
8434 (mi_cmd_data_list_changed_registers)
8435 (mi_cmd_data_write_register_values)
8436 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
8437 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
8438 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
8439 (mi_cmd_list_features, mi_cmd_list_target_features)
8440 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
8441 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
8442 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
8443 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
8444 (mi_cmd_trace_frame_collected): Constify 'command'
8445 parameter.
8446 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
8447 'command' parameter.
8448
8449 2017-04-05 Pedro Alves <palves@redhat.com>
8450
8451 * ada-lang.c (ada_completer_word_break_characters): Now a const
8452 array.
8453 (ada_get_gdb_completer_word_break_characters): Constify.
8454 * completer.c (gdb_completer_command_word_break_characters)
8455 (gdb_completer_file_name_break_characters)
8456 (gdb_completer_quote_characters): Now const arrays.
8457 (get_gdb_completer_quote_characters): Constify.
8458 (set_rl_completer_word_break_characters): New function.
8459 (set_gdb_completion_word_break_characters)
8460 (complete_line_internal): Use it.
8461 * completer.h (get_gdb_completer_quote_characters): Constify.
8462 (set_rl_completer_word_break_characters): Declare.
8463 * f-lang.c (f_word_break_characters): Constify.
8464 * language.c (default_word_break_characters): Constify.
8465 * language.h (language_defn::la_word_break_characters): Constify.
8466 (default_word_break_characters): Constify.
8467 * top.c (init_main): Use set_rl_completer_word_break_characters.
8468
8469 2017-04-05 Pedro Alves <palves@redhat.com>
8470
8471 * aix-thread.c (aix_thread_pid_to_str)
8472 (aix_thread_extra_thread_info): Constify.
8473 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
8474 * bsd-uthread.c (bsd_uthread_extra_thread_info)
8475 (bsd_uthread_pid_to_str): Constify.
8476 * corelow.c (core_pid_to_str): Constify.
8477 * darwin-nat.c (darwin_pid_to_str): Constify.
8478 * fbsd-nat.c (fbsd_pid_to_str): Constify.
8479 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
8480 Constify.
8481 * gnu-nat.c (gnu_pid_to_str): Constify.
8482 * go32-nat.c (go32_pid_to_str): Constify.
8483 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
8484 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
8485 * inferior.c (inferior_pid_to_str): Constify.
8486 * linux-nat.c (linux_nat_pid_to_str): Constify.
8487 * linux-tdep.c (linux_core_pid_to_str): Constify.
8488 * linux-thread-db.c (thread_db_pid_to_str)
8489 (thread_db_extra_thread_info): Constify.
8490 * nto-tdep.c (nto_extra_thread_info): Constify.
8491 * nto-tdep.h (nto_extra_thread_info): Constify.
8492 * obsd-nat.c (obsd_pid_to_str): Constify.
8493 * procfs.c (procfs_pid_to_str): Constify.
8494 * ravenscar-thread.c (ravenscar_extra_thread_info)
8495 (ravenscar_pid_to_str): Constify.
8496 * remote-sim.c (gdbsim_pid_to_str): Constify.
8497 * remote.c (remote_threads_extra_info, remote_pid_to_str):
8498 Constify.
8499 * sol-thread.c (solaris_pid_to_str): Constify.
8500 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
8501 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
8502 * target.c (default_pid_to_str, target_pid_to_str)
8503 (normal_pid_to_str, default_pid_to_str): Constify.
8504 * target.h (target_ops::to_pid_to_str)
8505 (target_ops::to_extra_thread_info): Constify.
8506 (target_pid_to_str, normal_pid_to_str): Constify.
8507 * windows-nat.c (windows_pid_to_str): Constify.
8508 * gdbarch.sh (core_pid_to_str): Constify.
8509 * target-delegates.c: Regenerate.
8510 * gdbarch.h, gdbarch.c: Regenerate.
8511
8512 2017-04-05 Pedro Alves <palves@redhat.com>
8513
8514 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
8515 the memory of the temporary warning_pre_print override.
8516 * utils.c (warning_pre_print): Constify.
8517 * utils.h (warning_pre_print): Constify.
8518
8519 2017-04-05 Pedro Alves <palves@redhat.com>
8520
8521 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
8522 (shell_command): New function.
8523 (make_command): Use std::string.
8524 (init_cli_cmds): Register shell_command instead of shell_escape.
8525
8526 2017-04-05 Pedro Alves <palves@redhat.com>
8527
8528 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
8529 * tracepoint.c (default_collect): Don't initialize.
8530
8531 2017-04-05 Pedro Alves <palves@redhat.com>
8532
8533 * macroexp.c (macro_buffer::shared): Now a bool.
8534 (init_buffer): Update.
8535 (init_shared_buffer): Constify 'addr' parameter.
8536 (substitute_args, expand, macro_expand, macro_expand_next): Remove
8537 casts.
8538
8539 2017-04-05 Pedro Alves <palves@redhat.com>
8540
8541 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
8542 * disasm.c (set_disassembler_options): Constify local.
8543 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
8544
8545 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
8546
8547 PR gdb/21352
8548 * tracefile.c (tsave_command): Fix argument parsing for '-r'
8549 option.
8550
8551 2017-04-05 Yao Qi <yao.qi@linaro.org>
8552
8553 * frame.c (frame_unwind_register_unsigned): Call
8554 frame_unwind_register_value.
8555
8556 2017-04-05 Yao Qi <yao.qi@linaro.org>
8557
8558 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
8559 Use gdb_test_multiple, and don't match anchor.
8560
8561 2017-04-05 Pedro Alves <palves@redhat.com>
8562
8563 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
8564 (Write After Approval): Remove Simon Marchi.
8565
8566 2017-04-05 Pedro Alves <palves@redhat.com>
8567
8568 * common/gdb_optional.h (optional::optional): Make constexpr and
8569 initialize m_dummy.
8570
8571 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8572
8573 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8574 (amd64fbsd_jmp_buf_reg_offset): Remove.
8575 (amd64fbsd_supply_uthread): Remove function.
8576 (amd64fbsd_collect_uthread): Remove function.
8577 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
8578 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
8579 (x86_64-*-freebsd*): Remove bsd-uthread.o.
8580 (fbsd-nat.c): Update comment.
8581 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8582 (i386fbsd_jmp_buf_reg_offset): Remove.
8583 (i386fbsd_supply_uthread): Remove function.
8584 (i386fbsd_collect_uthread): Remove function.
8585 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
8586
8587 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8588
8589 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
8590 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
8591 * NEWS: Mention that support for FreeBSD/alpha was removed.
8592 * alpha-fbsd-tdep.c: Delete file.
8593 * config/alpha/fbsd.mh: Delete file.
8594 * configure.host: Delete alpha*-*-freebsd* and
8595 alpha*-*-kfreebsd*-gnu.
8596 * configure.tgt: Delete alpha*-*-freebsd* and
8597 alpha*-*-kfreebsd*-gnu.
8598
8599 2017-04-04 John Baldwin <jhb@FreeBSD.org>
8600
8601 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
8602 amd64bsd_store_inferior_registers): Use ptid from regcache.
8603
8604 2017-04-04 Pedro Alves <palves@redhat.com>
8605
8606 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
8607 data fields, make them private and add "m_" prefixes.
8608 (lnp_state_machine::lnp_state_machine): New ctor.
8609 (record_line, check_line_address, handle_set_discriminator)
8610 (handle_set_address, handle_advance_pc, handle_special_opcode)
8611 (handle_advance_line, handle_set_file, handle_negate_stmt)
8612 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
8613 (end_sequence, advance_line): New methods.
8614 (m_gdbarch, m_record_lines_p): New fields.
8615 (lnp_reader_state): Delete.
8616 (dwarf_record_line): Rename to ...
8617 (lnp_state_machine::record_line): ... adjust.
8618 (init_lnp_state_machine): Delete.
8619 (lnp_state_machine::lnp_state_machine): New.
8620 (check_line_address): Rename to ...
8621 (lnp_state_machine::check_line_address): This.
8622 (dwarf_decode_lines_1): Remove reference to "reader_state".
8623 Adjust lnp_state_machine having a non-default ctor. Use bool.
8624 State machine internal state manipulation moved to
8625 lnp_state_machine methods.
8626
8627 2017-04-04 Pedro Alves <palves@redhat.com>
8628
8629 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8630 unittests/offset-type-selftests.c.
8631 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
8632 * common/offset-type.h: New file.
8633 * common/preprocessor.h: New file.
8634 * common/traits.h: New file.
8635 * common/valid-expr.h: New file.
8636 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
8637 sect_offset and cu_offset strong typedefs throughout.
8638 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
8639 typedefs throughout.
8640 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
8641 sect_offset and cu_offset strong typedefs throughout.
8642 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
8643 typedefs throughout.
8644 * gdbtypes.h: Include "common/offset-type.h".
8645 (cu_offset): Now an offset type (strong typedef) instead of a
8646 struct.
8647 (sect_offset): Likewise.
8648 (union call_site_parameter_u): Rename "param_offset" field to
8649 "param_cu_off".
8650 * unittests/offset-type-selftests.c: New file.
8651
8652 2017-04-04 Pedro Alves <palves@redhat.com>
8653
8654 * common/underlying.h: New file.
8655 * dwarf2read.c: Include "common/gdb_optional.h" and
8656 "common/underlying.h".
8657 (dir_index, file_name_index): New types.
8658 (file_entry): Use them.
8659 (file_entry::include): Use to_underlying.
8660 (line_header::add_file_name): Use dir_index.
8661 (read_formatted_entries): Use gdb::optional. Read form before
8662 writting to file_entry.
8663 (dwarf_decode_line_header): Use dir_index.
8664 (lnp_state_machine::current_file): Use to_underlying.
8665 (lnp_state_machine::file): Change type to file_name_index.
8666 (dwarf_record_line): Use to_underlying.
8667 (init_lnp_state_machine): Use file_name_index.
8668 (dwarf_decode_lines_1): Use dir_index and file_name_index.
8669
8670 2017-04-04 Pedro Alves <palves@redhat.com>
8671
8672 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
8673 operator bool, has_value and get methods.
8674
8675 2017-04-04 Pedro Alves <palves@redhat.com>
8676
8677 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
8678 fields.
8679 (line_header): Initialize all data fields. Change type of
8680 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
8681 Change type of include_dirs to std::vector<const char *>. Remove
8682 num_include_dirs, include_dirs_size. Change type of file_names to
8683 std::vector<file_entry>. Remove num_file_names, file_names_size.
8684 (line_header::line_header): New.
8685 (line_header::add_include_dir, line_header::add_file_name): New
8686 methods.
8687 (line_header::include_dir_at): Remove NULL check.
8688 (line_header::file_name_at): Add const overload.
8689 (line_header_up): New unique_ptr typedef.
8690 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
8691 std::vector. Remove free_line_header call.
8692 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
8693 free_line_header call.
8694 (free_cu_line_header): Delete.
8695 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
8696 (setup_type_unit_groups): Use line_header_up instead of cleanups.
8697 Adjust to use std::vector.
8698 (free_line_header): Delete.
8699 (free_line_header_voidp): Use delete.
8700 (add_include_dir): Replace with ...
8701 (line_header::add_include_dir): ... this method. Use std::vector.
8702 (add_file_name): Replace with ...
8703 (line_header::add_file_name): ... this method. Use std::vector.
8704 (add_include_dir_stub): Delete.
8705 (read_formatted_entries): Remove memset.
8706 (dwarf_decode_line_header): Return a line_header_up instead of a
8707 raw pointer. Remove cleanup handling. Pass lambdas to
8708 read_formatted_entries. Adjust to use line_header methods.
8709 (dwarf_decode_lines_1): Adjust to use line_header methods.
8710 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
8711 use std::vector.
8712
8713 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
8714
8715 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
8716 instead of struct ptid.
8717
8718 2017-05-04 Alan Hayward <alan.hayward@arm.com>
8719
8720 * frame.c (get_frame_register_bytes): Unwind using value.
8721 (put_frame_register_bytes): Likewise.
8722
8723 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
8724
8725 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
8726 aggregate-like.
8727
8728 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
8729
8730 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
8731
8732 2017-03-29 Yao Qi <yao.qi@linaro.org>
8733
8734 * gdbthread.h (struct thread_info): Declare constructor and
8735 destructor. Add some in-class member initializers.
8736 * thread.c (free_thread): Remove.
8737 (init_thread_list): Call delete instead of free_thread.
8738 (new_thread): Call thread_info constructor.
8739 (thread_info::thread_info): New function.
8740 (thread_info::~thread_info): New function.
8741 (delete_thread_1): Call delete instead of free_thread.
8742 (make_cleanup_restore_current_thread): Move tp and frame to
8743 inner block.
8744
8745 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8746
8747 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
8748 (arc_skip_prologue): Likewise.
8749 (arc_make_frame_cache): Likewise.
8750 (arc_pv_get_operand): New function.
8751 (arc_is_in_prologue): Likewise.
8752 (arc_analyze_prologue): Likewise.
8753 (arc_print_frame_cache): Likewise.
8754 (MAX_PROLOGUE_LENGTH): New constant.
8755
8756 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8757
8758 * configure.tgt: Add arc-insn.o.
8759 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
8760 (dump_arc_instruction_command): New function.
8761 (arc_fprintf_disasm): Likewise.
8762 (arc_disassemble_info): Likewise.
8763 (arc_insn_get_operand_value): Likewise.
8764 (arc_insn_get_operand_value_signed): Likewise.
8765 (arc_insn_get_memory_base_reg): Likewise.
8766 (arc_insn_get_memory_offset): Likewise.
8767 (arc_insn_get_branch_target): Likewise.
8768 (arc_insn_dump): Likewise.
8769 (arc_insn_get_linear_next_pc): Likewise.
8770 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
8771 (arc_disassemble_info): Likewise.
8772 (arc_insn_get_branch_target): Likewise.
8773 (arc_insn_get_linear_next_pc): Likewise.
8774 * NEWS: Mention new "maint print arc arc-instruction".
8775
8776 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8777
8778 * arc-tdep (maintenance_print_arc_list): New variable.
8779 (maintenance_print_arc_command): New function.
8780
8781 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8782
8783 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
8784 Add "limm" and "reserved".
8785 (arc_cannot_fetch_register, arc_cannot_store_register): Add
8786 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
8787 * arc-tdep.h (arc_regnum): Likewise.
8788
8789 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8790
8791 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
8792 for THREADPTR register.
8793 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
8794 register.
8795 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
8796 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
8797 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
8798
8799 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8800
8801 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
8802 registers above gdbarch_num_regs (gdbarch) as privileged in
8803 call0 ABI.
8804
8805 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8806
8807 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
8808 for a single specified register or for all registers in
8809 a0_base..a0_base + C0_NREGS range.
8810 (supply_gregset_reg): Call regcache_raw_supply for a single
8811 specified register or for all registers in a0_base..a0_base +
8812 C0_NREGS range.
8813
8814 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8815
8816 * arch/xtensa.h (C0_NREGS): Add definition.
8817 * xtensa-tdep.c (C0_NREGS): Remove definition.
8818
8819 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8820
8821 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
8822 Drop xtensa_default_isa initialization.
8823 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
8824
8825 2017-03-27 Pedro Alves <palves@redhat.com>
8826
8827 * dwarf2read.c (file_entry) <dir_index>: Add comment.
8828 (file_entry::include_dir): New method.
8829 (line_header::include_dir_at, line_header::file_name_at): New
8830 methods.
8831 (setup_type_unit_groups, setup_type_unit_groups)
8832 (psymtab_include_file_name): Simplify using the new methods.
8833 (lnp_state_machine) <the_line_header>: New field.
8834 <file>: Add comment.
8835 (lnp_state_machine::current_file): New method.
8836 (dwarf_record_line): Simplify using the new methods.
8837 (init_lnp_state_machine): Initialize the "the_line_header" field.
8838 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
8839 Simplify using the new methods.
8840
8841 2017-03-27 Pedro Alves <palves@redhat.com>
8842
8843 * cp-name-parser.y (make_empty): Delete.
8844 (demangler_special, nested_name, ptr_operator, array_indicator)
8845 (direct_declarator, declarator_1): Use fill_comp instead of
8846 make_empty.
8847
8848 2017-03-27 Pedro Alves <palves@redhat.com>
8849
8850 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
8851 to ATTRIBUTE_PRINTF.
8852 * solib-target.c (library_list_start_list): Print "string" not
8853 "version".
8854 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
8855 gdb_xml_error call.
8856
8857 2017-03-27 Pedro Alves <palves@redhat.com>
8858
8859 * dwarf2read.c (struct file_and_directory): New.
8860 (dwarf2_get_dwz_file): Adjust to use std::string.
8861 (dw2_get_file_names_reader): Adjust to use file_and_directory.
8862 (find_file_and_directory): Adjust to return a file_and_directory
8863 object.
8864 (read_file_scope): Adjust to use file_and_directory. Remove
8865 make_cleanup/do_cleanups calls.
8866 (open_and_init_dwp_file): Adjust to use std::string. Remove
8867 make_cleanup/do_cleanups calls.
8868 * python/python.c (do_start_initialization): Adjust to ldirname
8869 returning a std::string.
8870 * utils.c (ldirname): Now returns a std::string.
8871 * utils.h (ldirname): Change return type to std::string.
8872 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
8873 returning a std::string.
8874 * xml-tdesc.c (file_read_description_xml): Likewise.
8875
8876 2017-03-24 Alan Hayward <alan.hayward@arm.com>
8877
8878 * regcache.c (regcache_debug_print_register): New function.
8879 * regcache.h (regcache_debug_print_register): New declaration.
8880 * target.c (debug_print_register): Remove.
8881 (target_fetch_registers): Call regcache_debug_print_register.
8882 (target_store_registers): Likewise.
8883
8884 2017-03-24 Pádraig Brady <pbrady@fb.com>
8885
8886 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
8887 reference beyond the 'lh->include_dirs' array before accessing to
8888 it.
8889 (psymtab_include_file_name): Likewise.
8890 (dwarf_decode_lines_1): Likewise.
8891 (dwarf_decode_lines): Likewise.
8892 (file_file_name): Likewise.
8893
8894 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
8895
8896 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
8897 inferior_ptid.
8898 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8899 ps_lsetfpregs): Likewise.
8900 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
8901 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8902 ps_lsetfpregs): Likewise.
8903 * target.c (target_fetch_registers, target_store_registers):
8904 Remove asserts.
8905
8906 2017-03-23 Alan Hayward <alan.hayward@arm.com>
8907
8908 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
8909
8910 2017-03-23 Yao Qi <yao.qi@linaro.org>
8911
8912 * aarch64-tdep.c (aarch64_process_record_test): Declare.
8913 (_initialize_aarch64_tdep): Register it.
8914 (aarch64_record_load_store): Handle PRFM instruction.
8915 (aarch64_process_record_test): New function.
8916
8917 2017-03-23 Yao Qi <yao.qi@linaro.org>
8918
8919 * aarch64-tdep.c (aarch64_record_load_store): Fix code
8920 indentation.
8921
8922 2017-03-23 Yao Qi <yao.qi@linaro.org>
8923
8924 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
8925
8926 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8927
8928 python/python.c (do_start_initialization): Fix memory leak.
8929
8930 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8931
8932 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
8933 using get_ptrace_pid.
8934 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
8935 inferior_ptid.
8936 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
8937 inferior_ptid instead of pid.
8938
8939 2017-03-22 Yao Qi <yao.qi@linaro.org>
8940
8941 * aarch64-tdep.c: Wrap locally used classes in anonymous
8942 namespace.
8943 * arm-tdep.c: Likewise.
8944 * linespec.c: Likewise.
8945 * ui-out.c: Likewise.
8946
8947 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
8948
8949 PR gdb/19637
8950 * python/lib/gdb/printer/bound_registers.py: Import sys.
8951
8952 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
8953
8954 * windows-nat.c (do_windows_fetch_inferior_registers): Add
8955 windows_thread_info parameter and use it instead of
8956 current_thread.
8957 (windows_fetch_inferior_registers): Don't set current_thread,
8958 pass the thread to do_windows_fetch_inferior_registers. Use
8959 ptid from regcache instead of inferior_ptid.
8960 (do_windows_store_inferior_registers): Add windows_thread_info
8961 parameter and use it instead of current_thread.
8962 (windows_store_inferior_registers): Don't set current_thread,
8963 pass the thread to do_windows_store_inferior_registers. Use
8964 ptid from regcache instead of inferior_ptid.
8965
8966 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
8967
8968 * ser-mingw.c (ser_windows_raw): Remove reference to
8969 struct serial::current_timeout.
8970
8971 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
8972
8973 PR tdep/20928
8974 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
8975 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
8976 (sparc64_fsr_type): Fix %fsr decoding.
8977
8978 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
8979
8980 * python/py-record-btrace.c (btpy_insn_data): Change return type
8981 for Python 2.
8982
8983 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
8984
8985 * spu-linux-nat.c (spu_fetch_inferior_registers,
8986 spu_store_inferior_registers): Use ptid from regcache, set and
8987 restore inferior_ptid.
8988 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
8989 Likewise.
8990
8991 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
8992
8993 * i386-linux-nat.c (fetch_register, store_register,
8994 i386_linux_fetch_inferior_registers,
8995 i386_linux_store_inferior_registers): Use ptid from regcache.
8996 * ia64-linux-nat.c (ia64_linux_fetch_register,
8997 ia64_linux_store_register): Likewise.
8998 * inf-ptrace.c (inf_ptrace_fetch_register,
8999 inf_ptrace_store_register): Likewise.
9000 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
9001 m32r_linux_store_inferior_registers): Likewise.
9002 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
9003 m68kbsd_store_inferior_registers): Likewise.
9004 * m68k-linux-nat.c (fetch_register, store_register,
9005 m68k_linux_fetch_inferior_registers,
9006 m68k_linux_store_inferior_registers): Likewise.
9007 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
9008 m88kbsd_store_inferior_registers): Likewise.
9009 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
9010 mips_fbsd_store_inferior_registers): Likewise.
9011 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
9012 mips64_linux_regsets_store_registers): Likewise.
9013 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
9014 mipsnbsd_store_inferior_registers): Likewise.
9015 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
9016 mips64obsd_store_inferior_registers): Likewise.
9017 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
9018 Likewise.
9019 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
9020 ppcfbsd_store_inferior_registers): Likewise.
9021 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
9022 ppc_linux_store_inferior_registers): Likewise.
9023 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
9024 ppcnbsd_store_inferior_registers): Likewise.
9025 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
9026 ppcobsd_store_registers): Likewise.
9027 * procfs.c (procfs_fetch_registers, procfs_store_registers):
9028 Likewise.
9029 * ravenscar-thread.c (ravenscar_fetch_registers,
9030 ravenscar_store_registers, ravenscar_prepare_to_store):
9031 Likewise.
9032 * record-btrace.c (record_btrace_fetch_registers,
9033 record_btrace_store_registers, record_btrace_prepare_to_store):
9034 Likewise.
9035 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
9036 Lookup inferior using ptid from regcache, instead of
9037 current_inferior.
9038 * remote.c (remote_fetch_registers, remote_store_registers): Use
9039 ptid from regcache.
9040 * rs6000-nat.c (fetch_register, store_register): Likewise.
9041 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
9042 s390_linux_store_inferior_registers): Likewise.
9043 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
9044 shnbsd_store_inferior_registers): Likewise.
9045 * sol-thread.c (sol_thread_fetch_registers,
9046 sol_thread_store_registers): Likewise.
9047 * sparc-nat.c (sparc_fetch_inferior_registers,
9048 sparc_store_inferior_registers): Likewise.
9049 * tilegx-linux-nat.c (fetch_inferior_registers,
9050 store_inferior_registers): Likewise.
9051 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
9052 vaxbsd_store_inferior_registers): Likewise.
9053 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
9054 store_xtregs): Likewise.
9055
9056 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9057
9058 PR gdb/14441
9059 * NEWS: Mention support for rvalue references in GDB and python.
9060 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
9061 supports both lvalue and rvalue references.
9062
9063 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9064
9065 PR gdb/14441
9066 * gdbtypes.c (rank_one_type): Implement overloading
9067 resolution rules regarding rvalue references.
9068
9069 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9070
9071 PR gdb/14441
9072 * aarch64-tdep.c (aarch64_type_align)
9073 (aarch64_extract_return_value, aarch64_store_return_value): Change
9074 lvalue reference type checks to general reference type checks.
9075 * amd64-tdep.c (amd64_classify): Likewise.
9076 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
9077 Likewise.
9078 * arm-tdep.c (arm_type_align, arm_extract_return_value)
9079 (arm_store_return_value): Likewise.
9080 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
9081 * c-typeprint.c (c_print_type): Likewise.
9082 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
9083 (cplus_number_of_children, cplus_describe_child): Likewise.
9084 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
9085 * completer.c (expression_completer): Likewise.
9086 * cp-support.c (make_symbol_overload_list_adl_namespace):
9087 Likewise.
9088 * darwin-nat-info.c (info_mach_region_command): Likewise.
9089 * dwarf2loc.c (entry_data_value_coerce_ref)
9090 (value_of_dwarf_reg_entry): Likewise.
9091 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
9092 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
9093 Likewise.
9094 * findvar.c (extract_typed_address, store_typed_address):
9095 Likewise.
9096 * gdbtypes.c (rank_one_type): Likewise.
9097 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
9098 * infcall.c (value_arg_coerce): Likewise.
9099 * language.c (pointer_type): Likewise.
9100 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
9101 Likewise.
9102 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
9103 * mn10300-tdep.c (mn10300_type_align): Likewise.
9104 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
9105 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
9106 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
9107 Likewise.
9108 * printcmd.c (print_formatted, x_command): Likewise.
9109 * python/py-type.c (typy_get_composite, typy_template_argument):
9110 Likewise.
9111 * python/py-value.c (valpy_referenced_value)
9112 (valpy_get_dynamic_type, value_has_field): Likewise.
9113 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
9114 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
9115 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
9116 * spu-tdep.c (spu_scalar_value_p): Likewise.
9117 * symtab.c (lookup_symbol_aux): Likewise.
9118 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9119 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9120 Likewise.
9121 * valops.c (value_cast_pointers, value_cast)
9122 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9123 (value_struct_elt, value_struct_elt_bitpos)
9124 (value_find_oload_method_list, find_overload_match)
9125 (value_rtti_indirect_type): Likewise.
9126 * valprint.c (val_print_scalar_type_p, generic_val_print):
9127 Likewise.
9128 * value.c (value_actual_type, value_as_address, unpack_long)
9129 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9130 (coerce_ref): Likewise.
9131 * varobj.c (varobj_get_value_type): Likewise.
9132
9133 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9134
9135 PR gdb/14441
9136 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9137 table of constants.
9138 * python/lib/gdb/command/explore.py: Support exploring values
9139 of rvalue reference types.
9140 * python/lib/gdb/types.py: Implement get_basic_type() for
9141 rvalue reference types.
9142 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9143 constant.
9144 * python/py-value.c (valpy_getitem): Add an rvalue reference
9145 check.
9146 (valpy_reference_value): Add new parameter "refcode".
9147 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9148 New wrappers for valpy_reference_value().
9149 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9150 (gdbpy_invoke_xmethod): Likewise.
9151
9152 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9153
9154 PR gdb/14441
9155 * dwarf2read.c (process_die, read_type_die_1): Handle the
9156 DW_TAG_rvalue_reference_type DIE.
9157 (read_tag_reference_type): Add new parameter "refcode".
9158
9159 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9160
9161 PR gdb/14441
9162 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9163 (c_type_print_modifier, c_type_print_varspec_suffix)
9164 (c_type_print_base): Support printing rvalue reference types.
9165 * c-valprint.c (c_val_print, c_value_print): Support printing
9166 rvalue reference values.
9167
9168 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9169
9170 PR gdb/14441
9171 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9172 typename.
9173 * cp-support.c (replace_typedefs): Handle
9174 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9175 * python/py-type.c (typy_lookup_type): Likewise.
9176
9177 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9178
9179 PR gdb/14441
9180 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9181 * parse.c (insert_type): Change assert statement.
9182 (follow_types): Handle rvalue reference types.
9183 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9184 constant.
9185
9186 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9187
9188 PR gdb/14441
9189 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9190 value_ref() interface.
9191 * c-valprint.c (c_value_print): Likewise.
9192 * infcall.c (value_arg_coerce): Likewise.
9193 * python/py-value.c (valpy_reference_value): Likewise.
9194 * valops.c (value_cast, value_reinterpret_cast)
9195 (value_dynamic_cast, typecmp): Likewise.
9196 (value_ref): Parameterize by kind of return value reference type.
9197 * value.h (value_ref): Add new parameter "refcode".
9198
9199 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9200
9201 PR gdb/14441
9202 * dwarf2read.c (read_tag_reference_type): Use
9203 lookup_lvalue_reference_type() instead of lookup_reference_type().
9204 * eval.c (evaluate_subexp_standard): Likewise.
9205 * f-exp.y: Likewise.
9206 * gdbtypes.c (make_reference_type, lookup_reference_type):
9207 Generalize with rvalue reference types.
9208 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9209 convenience wrappers for lookup_reference_type().
9210 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9211 reference kind parameter.
9212 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9213 wrappers for lookup_reference_type().
9214 * guile/scm-type.c (gdbscm_type_reference): Use
9215 lookup_lvalue_reference_type() instead of lookup_reference_type().
9216 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9217 * parse.c (follow_types): Likewise.
9218 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9219 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9220 Likewise.
9221 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9222 (gdbpy_invoke_xmethod): Likewise.
9223 * stabsread.c: Provide extra argument to make_reference_type()
9224 call.
9225 * valops.c (value_ref, value_rtti_indirect_type): Use
9226 lookup_lvalue_reference_type() instead of lookup_reference_type().
9227
9228 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
9229
9230 PR gdb/14441
9231 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9232 (TYPE_IS_REFERENCE): New macro.
9233 (struct type): Add rvalue_reference_type field.
9234 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9235
9236 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9237
9238 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9239 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9240 New function definition.
9241 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9242 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9243 New function declaration.
9244 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9245 * mi/mi-interp.h: New file.
9246 * solib.c (info_sharedlibrary_command): Replace for loop with
9247 ALL_SO_LIBS macro
9248 * solib.h (update_solib_list): New function declaration.
9249 (so_list_head): Move macro.
9250 * solist.h (ALL_SO_LIBS): New macro.
9251
9252 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9253
9254 * infcmd.c (post_create_inferior): Remove unused argument in
9255 call to solib_add.
9256 * remote.c (remote_start_remote): Likewise.
9257 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9258 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9259 (enable_break): Likewise.
9260 * solib.c (update_solib_list): Remove unused target argument
9261 and its documentation.
9262 (solib_add): Remove unused target argument. Remove unused
9263 argument in call to update_solib_list.
9264 (info_sharedlibrary_command): Remove unused argument in call
9265 to update_solib_list.
9266 (sharedlibrary_command): Remove unused argument in call to
9267 solib_add.
9268 (handle_solib_event): Likewise.
9269 (reload_shared_libraries): Likewise.
9270 * solib.h (solib_add): Remove unused target argument.
9271
9272 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9273
9274 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9275 (s390_displaced_step_fixup): Cover relative branches with the
9276 default fixup handling. This fixes lack of support for some
9277 relative branch instructions.
9278
9279 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9280
9281 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9282 ptid from regcache.
9283
9284 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9285
9286 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9287 i386_darwin_store_inferior_registers): Use ptid from regcache.
9288
9289 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9290
9291 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9292 i386bsd_store_inferior_registers): Use ptid from regcache.
9293
9294 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9295
9296 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9297 hppaobsd_store_registers): Use ptid from regcache.
9298
9299 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9300
9301 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9302 hppanbsd_store_registers): Use ptid from regcache.
9303
9304 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9305
9306 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9307 from regcache. Use get_ptrace_pid.
9308
9309 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9310
9311 * corelow.c (get_core_register_section): Use ptid from regcache,
9312 update doc.
9313
9314 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9315
9316 * bsd-uthread.c (bsd_uthread_fetch_registers,
9317 bsd_uthread_store_registers): Use ptid from regcache, set and
9318 restore inferior_ptid.
9319
9320 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9321
9322 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9323 fetch_fp_regs, store_register, store_regs, store_fp_register,
9324 store_fp_regs): Use ptid from regcache.
9325
9326 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9327
9328 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9329 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9330 store_vfp_regs): Use ptid from regcache.
9331
9332 2017-03-17 Pedro Alves <palves@redhat.com>
9333
9334 PR remote/21188
9335 * ser-base.c (ser_base_wait_for): Add comment.
9336 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9337 version.
9338 * ser-unix.c (hardwire_raw): Remove reference to
9339 scb->current_timeout.
9340 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9341 (hardwire_ops): Install ser_base_readchar instead of
9342 hardwire_readchar.
9343 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9344 Remove fields.
9345
9346 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
9347
9348 PR gdb/19637
9349 * python/lib/gdb/printer/bound_registers.py: Add support for
9350 Python 3.
9351
9352 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9353
9354 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9355 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9356 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9357 byte_offset to subobj_byte_offset. Fix the handling of
9358 DWARF_VALUE_STACK on big-endian targets when coming via an
9359 implicit pointer.
9360 (dwarf2_evaluate_loc_desc): Adjust call to
9361 dwarf2_evaluate_loc_desc_full.
9362 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9363 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9364
9365 2017-03-16 Yao Qi <yao.qi@linaro.org>
9366
9367 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9368 and REVSH instructions.
9369
9370 2017-03-16 Yao Qi <yao.qi@linaro.org>
9371
9372 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9373 (arm_record_test): Declare.
9374 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9375 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9376 align with the manual.
9377 (thumb_record_misc): Adjust the code order to align with the
9378 manual.
9379 (thumb2_record_decode_insn_handler): Fix instruction matching.
9380 (instruction_reader_thumb): New class.
9381 (arm_record_test): New function.
9382
9383 2017-03-16 Yao Qi <yao.qi@linaro.org>
9384
9385 * arm-tdep.c (abstract_memory_reader): New class.
9386 (instruction_reader): New class.
9387 (extract_arm_insn): Add argument 'reader'. Callers updated.
9388 (decode_insn): Likewise.
9389
9390 2017-03-16 Doug Evans <dje@google.com>
9391
9392 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9393 member. Change type of TYPE member to SCM. All uses updated.
9394 (lsscm_make_lazy_string_smob): Add assert.
9395 (lsscm_make_lazy_string): Flag bad length values.
9396 (lsscm_elt_type): New function.
9397 (gdbscm_lazy_string_to_value): Rewrite to use
9398 lsscm_safe_lazy_string_to_value.
9399 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
9400 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
9401 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
9402 in incoming type.
9403 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9404 * guile/scm-type.c (tyscm_scm_to_type): New function.
9405
9406 2017-03-15 Doug Evans <dje@google.com>
9407
9408 PR python/17728, python/18439, python/18779
9409 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
9410 member. Change type of TYPE member to PyObject *. All uses updated.
9411 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
9412 (gdbpy_create_lazy_string_object): Flag bad length values.
9413 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
9414 Handle typedefs in incoming type.
9415 (stpy_lazy_string_elt_type): New function.
9416 (gdbpy_extract_lazy_string): Call it.
9417 * python/py-value.c (valpy_lazy_string): Flag bad length values.
9418 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
9419 typedefs in incoming type.
9420
9421 2017-03-16 Doug Evans <dje@google.com>
9422
9423 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9424 * guile/scm-type.c (tyscm_scm_to_type): New function.
9425
9426 2017-03-16 Jiong Wang <jiong.wang@arm.com>
9427
9428 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
9429 "ULONGEST" for "skip".
9430
9431 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9432
9433 PR gdb/21220
9434 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
9435 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
9436 (inf_ptrace_peek_poke): ...here. New function. Now also loop
9437 over ptrace peek/poke until end of buffer or error.
9438
9439 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
9440
9441 * parse.c (length_of_subexp): Make static.
9442 * parser-defs.h (length_of_subexp): Remove.
9443
9444 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9445
9446 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
9447 as well.
9448
9449 2017-03-14 Pedro Alves <palves@redhat.com>
9450
9451 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
9452 (main): Use std::unique_ptr. Remove calls to
9453 cp_demangled_name_parse_free.
9454
9455 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9456
9457 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
9458 alphabsd_store_inferior_registers): Use regcache->ptid instead
9459 of inferior_ptid.
9460
9461 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9462
9463 * aix-thread.c (aix_thread_fetch_registers,
9464 aix_thread_store_registers): Use regcache->ptid instead of
9465 inferior_ptid.
9466
9467 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9468
9469 * aarch64-linux-nat.c (fetch_gregs_from_thread,
9470 store_gregs_to_thread, fetch_fpregs_from_thread,
9471 store_fpregs_to_thread): Use regcache->ptid instead of
9472 inferior_ptid.
9473
9474 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9475
9476 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
9477 amd64_linux_fetch_inferior_registers): Use regcache->ptid
9478 instead of inferior_ptid.
9479
9480 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9481
9482 * target.c (target_fetch_registers, target_store_registers): Add
9483 assert.
9484
9485 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9486
9487 * regcache.h (regcache_get_ptid): New function.
9488 * regcache.c (regcache_get_ptid): New function.
9489
9490 2017-03-13 Mark Wielaard <mark@klomp.org>
9491
9492 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
9493
9494 2017-03-10 Keith Seitz <keiths@redhat.com>
9495
9496 PR c++/8218
9497 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
9498
9499 2017-03-08 Pedro Alves <palves@redhat.com>
9500
9501 PR gdb/18360
9502 * infrun.c (start_step_over, do_target_resume, resume)
9503 (restart_threads): Assert we're not resuming a thread that is
9504 meant to be stopped.
9505 (infrun_thread_stop_requested_callback): Delete.
9506 (infrun_thread_stop_requested): If the thread is internally
9507 stopped, queue a pending stop event and clear the thread's
9508 inline-frame state.
9509 (handle_stop_requested): New function.
9510 (handle_syscall_event, handle_inferior_event_1): Use
9511 handle_stop_requested.
9512 (handle_stop_requested): New function.
9513 (handle_signal_stop): Set the thread's stop_signal here instead of
9514 at caller.
9515 (finish_step_over): Clear step over info unconditionally.
9516 (handle_signal_stop): If the user had interrupted the event
9517 thread, consider the stop a random signal.
9518 (handle_signal_stop) <signal arrived while stepping over
9519 breakpoint>: Don't restart threads here.
9520 (stop_waiting): Don't clear step-over info here.
9521
9522 2017-03-08 Pedro Alves <palves@redhat.com>
9523
9524 PR 21206
9525 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
9526 goes to argument 2, not 1.
9527
9528 2017-03-08 Pedro Alves <palves@redhat.com>
9529
9530 PR cli/21218
9531 * top.c (gdb_readline_wrapper): Avoid passing NULL to
9532 display_gdb_prompt.
9533 (command_line_input): Add comment.
9534
9535 2017-03-08 Pedro Alves <palves@redhat.com>
9536
9537 PR tui/21216
9538 * tui/tui-file.c (tui_file::write): New.
9539 * tui/tui-file.h (tui_file): Override "write".
9540 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
9541 factored out from ...
9542 (tui_puts): ... here.
9543 (tui_putc): Use them.
9544 (tui_write): New function.
9545 * tui/tui-io.h (tui_write): Declare.
9546
9547 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
9548
9549 * Makefile.in (SFILES): Replace "environ.c" with
9550 "common/environ.c".
9551 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
9552 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
9553 to...
9554 * common/environ.c: ... here.
9555 * environ.h: Moved to...
9556 * common/environ.h: ... here.
9557
9558 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9559
9560 * gdbarch.sh (pstring_ptr): New static function.
9561 (gdbarch_disassembler_options): Use it.
9562 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
9563 not valid_disassembler_option->name.
9564 * gdbarch.c: Regenerate.
9565
9566 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9567
9568 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
9569
9570 2017-03-07 Pedro Alves <palves@redhat.com>
9571
9572 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
9573
9574 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
9575
9576 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
9577 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
9578 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
9579 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
9580
9581 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
9582
9583 * xtensa-linux-nat.c (fetch_gregs): Remove const.
9584
9585 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
9586
9587 * remote.c (remote_add_target_side_commands): Use range-based
9588 for loop.
9589
9590 2017-03-03 Yao Qi <yao.qi@linaro.org>
9591
9592 PR gdb/21165
9593 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
9594 value is lazy.
9595 * valprint.c (common_val_print): Likewise.
9596
9597 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
9598
9599 * NEWS: Mention new set/show disassembler-options commands.
9600 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
9601 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
9602 (prospective_options): New static variable.
9603 (gdb_disassembler::gdb_disassembler): Initialize
9604 m_di.disassembler_options.
9605 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
9606 (get_disassembler_options): New function.
9607 (set_disassembler_options): Likewise.
9608 (set_disassembler_options_sfunc): Likewise.
9609 (show_disassembler_options_sfunc): Likewise.
9610 (disassembler_options_completer): Likewise.
9611 (_initialize_disasm): Likewise.
9612 * disasm.h (get_disassembler_options): New prototype.
9613 (set_disassembler_options): Likewise.
9614 * gdbarch.sh (gdbarch_disassembler_options): New variable.
9615 (gdbarch_verify_disassembler_options): Likewise.
9616 * gdbarch.c: Regenerate.
9617 * gdbarch.h: Likewise.
9618 * arm-tdep.c (num_disassembly_options): Delete.
9619 (set_disassembly_style): Likewise.
9620 (arm_disassembler_options): New static variable.
9621 (set_disassembly_style_sfunc): Convert short style name into long
9622 option name. Call set_disassembler_options.
9623 (show_disassembly_style_sfunc): New function.
9624 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
9625 set_gdbarch_verify_disassembler_options.
9626 (_initialize_arm_tdep): Delete regnames variable and update callers.
9627 (arm_disassembler_options): Initialize.
9628 (disasm_options): New variable.
9629 (num_disassembly_options): Rename from this...
9630 (num_disassembly_styles): ...to this. Compute by scanning through
9631 disasm_options.
9632 (valid_disassembly_styles): Initialize using disasm_options.
9633 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
9634 set_arm_regname_option.
9635 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
9636 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
9637 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
9638 set_gdbarch_verify_disassembler_options.
9639 * s390-tdep.c (s390_disassembler_options): New static variable.
9640 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
9641 set_gdbarch_verify_disassembler_options.
9642
9643 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9644
9645 * remote.c (remote_add_target_side_condition): Remove "struct"
9646 keyword from range-based for loop.
9647
9648 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9649
9650 * remote.c (remote_add_target_side_condition): Use range-based
9651 for loop. Update comment.
9652
9653 2017-02-27 Yao Qi <yao.qi@linaro.org>
9654
9655 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
9656
9657 2017-02-26 Alan Hayward <alan.hayward@arm.com>
9658
9659 * regcache.c (regcache_raw_update): New function.
9660 (regcache_raw_read): Move code to regcache_raw_update.
9661 * regcache.h (regcache_raw_update): New declaration.
9662 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
9663
9664 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
9665
9666 * dwarf2read.c (create_debug_type_hash_table): Initialize
9667 header.signature and header.type_offset_in_tu.
9668
9669 2017-02-24 Pedro Alves <palves@redhat.com>
9670
9671 * symtab.c (make_file_symbol_completion_list_1): Use
9672 add_symtab_completions.
9673
9674 2017-02-24 Alan Hayward <alan.hayward@arm.com>
9675
9676 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
9677
9678 2017-02-24 Alan Hayward <alan.hayward@arm.com>
9679
9680 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
9681 I386_MAX_REGISTER_SIZE.
9682 (i386_pseudo_register_write): Likewise.
9683 (i386_process_record): Likewise.
9684 * i387-tdep.c (i387_supply_xsave): Likewise.
9685 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
9686 (store_register): Likewise.
9687
9688 2017-02-23 Pedro Alves <palves@redhat.com>
9689
9690 * ada-lang.c: Include "common/function-view.h".
9691 (ada_iterate_over_symbols): Adjust to use function_view as
9692 callback type.
9693 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
9694 (ada_make_symbol_completion_list): Use a lambda.
9695 (ada_exc_search_name_matches): Delete.
9696 (name_matches_regex): New.
9697 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
9698 * compile/compile-c-support.c: Include "common/function-view.h".
9699 (print_one_macro): Change prototype to accept a ui_file pointer.
9700 (write_macro_definitions): Use a lambda.
9701 * dwarf2read.c: Include "common/function-view.h".
9702 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
9703 (dw2_expand_symtabs_matching): Adjust to use function_view as
9704 callback type.
9705 * language.h: Include "common/function-view.h".
9706 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
9707 function_view as callback type.
9708 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
9709 * linespec.c: Include "common/function-view.h".
9710 (collect_info::add_symbol): New method.
9711 (struct symbol_and_data_callback, iterate_inline_only, struct
9712 symbol_matcher_data, iterate_name_matcher): Delete.
9713 (iterate_over_all_matching_symtabs): Adjust to use function_view
9714 as callback type and lambdas.
9715 (iterate_over_file_blocks): Adjust to use function_view as
9716 callback type.
9717 (decode_compound_collector): Now a class with private fields.
9718 (decode_compound_collector::release_symbols): New method.
9719 (collect_one_symbol): Rename to...
9720 (decode_compound_collector::operator()): ... this and adjust.
9721 (lookup_prefix_sym): decode_compound_collector construction bits
9722 move to decode_compound_collector ctor. Pass the
9723 decode_compound_collector object directly as callback. Remove
9724 cleanups and use decode_compound_collector::release_symbols
9725 instead.
9726 (symtab_collector): Now a class with private fields.
9727 (symtab_collector::release_symtabs): New method.
9728 (add_symtabs_to_list): Rename to...
9729 (symtab_collector::operator()): ... this and adjust.
9730 (collect_symtabs_from_filename): symtab_collector construction
9731 bits move to symtab_collector ctor. Pass the symtab_collector
9732 object directly as callback. Remove cleanups and use
9733 symtab_collector::release_symtabs instead.
9734 (collect_symbols): Delete.
9735 (add_matching_symbols_to_info): Use lambdas.
9736 * macrocmd.c (print_macro_callback): Delete.
9737 (info_macro_command): Use a lambda.
9738 (info_macros_command): Pass print_macro_definition as callable
9739 directly.
9740 (print_one_macro): Remove 'ignore' parameter.
9741 (macro_list_command): Adjust.
9742 * macrotab.c (macro_for_each_data::fn): Now a function_view.
9743 (macro_for_each_data::user_data): Delete field.
9744 (foreach_macro): Adjust to call the function_view.
9745 (macro_for_each): Adjust to use function_view as callback type.
9746 (foreach_macro_in_scope): Adjust to call the function_view.
9747 (macro_for_each_in_scope): Adjust to use function_view as callback
9748 type.
9749 * macrotab.h: Include "common/function-view.h".
9750 (macro_callback_fn): Declare a prototype instead of a pointer.
9751 Remove "user_data" parameter.
9752 (macro_for_each, macro_for_each_in_scope): Adjust to use
9753 function_view as callback type.
9754 * psymtab.c (partial_map_expand_apply)
9755 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
9756 Adjust to use function_view as callback type and to return bool.
9757 (psym_expand_symtabs_matching): Adjust to use function_view as
9758 callback types.
9759 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
9760 to use function_view as callback type and to return bool.
9761 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
9762 callback types.
9763 * symfile.c (expand_symtabs_matching): Adjust to use function_view
9764 as callback types.
9765 * symfile.h: Include "common/function-view.h".
9766 (expand_symtabs_file_matcher_ftype)
9767 (expand_symtabs_symbol_matcher_ftype)
9768 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
9769 return bool.
9770 (quick_symbol_functions::map_symtabs_matching_filename)
9771 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
9772 function_view as callback type and return bool.
9773 (expand_symtabs_matching): Adjust to use function_view as callback
9774 type.
9775 (maintenance_expand_name_matcher)
9776 (maintenance_expand_file_matcher): Delete.
9777 (maintenance_expand_symtabs): Use lambdas.
9778 * symtab.c (iterate_over_some_symtabs): Adjust to use
9779 function_view as callback types and return bool.
9780 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
9781 of a cleanup.
9782 (lookup_symtab_callback): Delete.
9783 (lookup_symtab): Use a lambda.
9784 (iterate_over_symbols): Adjust to use function_view as callback
9785 type.
9786 (struct search_symbols_data, search_symbols_file_matches)
9787 (search_symbols_name_matches): Delete.
9788 (search_symbols): Use a pair of lambdas.
9789 (struct add_name_data, add_macro_name, symbol_completion_matcher)
9790 (symtab_expansion_callback): Delete.
9791 (default_make_symbol_completion_list_break_on_1): Use lambdas.
9792 * symtab.h: Include "common/function-view.h".
9793 (iterate_over_some_symtabs): Adjust to use function_view as
9794 callback type and return bool.
9795 (iterate_over_symtabs): Adjust to use function_view as callback
9796 type.
9797 (symbol_found_callback_ftype): Remove 'data' parameter and return
9798 bool.
9799 (iterate_over_symbols): Adjust to use function_view as callback
9800 type.
9801
9802 2017-02-23 Pedro Alves <palves@redhat.com>
9803
9804 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
9805 (%.o) <unittests/%.c>: New pattern.
9806 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
9807 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
9808 * common/function-view.h: New file.
9809 * unittests/function-view-selftests.c: New file.
9810 * configure: Regenerate.
9811
9812 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
9813
9814 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
9815 inferior_ptid.
9816 * go32-nat.c (go32_thread_alive): Likewise.
9817
9818 2017-02-23 Yao Qi <yao.qi@linaro.org>
9819
9820 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
9821 delete.
9822
9823 2017-02-23 Yao Qi <yao.qi@linaro.org>
9824
9825 * varobj.c (varobj_clear_saved_item): Use delete instead of
9826 xfree.
9827 (update_dynamic_varobj_children): Likewise.
9828
9829 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9830
9831 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
9832
9833 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
9834
9835 * common/enum-flags.h (enum_flags::enum_flags): Initialize
9836 m_enum_value to 0 in default constructor.
9837
9838 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9839
9840 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
9841 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
9842 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
9843 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
9844 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
9845 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
9846 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
9847 IS_STORE_CONDITIONAL_INSN.
9848
9849 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9850
9851 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
9852
9853 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9854
9855 * NEWS (Changes since GDB 7.12): Add DWARF-5.
9856
9857 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9858
9859 * dwarf2read.c (skip_one_die, read_attribute_value)
9860 (dwarf2_const_value_attr, dump_die_shallow)
9861 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9862 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
9863
9864 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9865
9866 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
9867 (dwarf_parse_macro_header): Accept DWARF version 5.
9868 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
9869
9870 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9871
9872 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
9873 DW_AT_GNU_*.
9874 * common/common-exceptions.h (enum errors): Likewise.
9875 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
9876 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
9877 (dwarf_expr_context::execute_stack_op): Likewise.
9878 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
9879 Likewise.
9880 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
9881 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
9882 (show_entry_values_debug, call_site_to_target_addr)
9883 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
9884 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
9885 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
9886 (value_of_dwarf_block_entry, indirect_pieced_value)
9887 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
9888 (disassemble_dwarf_expression): Likewise.
9889 * dwarf2read.c (process_die, inherit_abstract_dies)
9890 (read_call_site_scope): Likewise.
9891 * gdbtypes.h (struct func_type, struct call_site_parameter)
9892 (struct call_site): Likewise.
9893 * stack.c (read_frame_arg): Likewise.
9894 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
9895
9896 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9897
9898 * defs.h (read_unsigned_leb128): New declaration.
9899 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
9900 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
9901 (dwarf2_find_location_expression): Call also
9902 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
9903 * dwarf2loc.h (dwarf2_version): New declaration.
9904 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
9905 rnglists.
9906 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
9907 .debug_rnglists.
9908 (struct dwop_section_names): Add loclists_dwo.
9909 (dwop_section_names): Add .debug_loclists.dwo.
9910 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
9911 (struct dwarf2_per_cu_data): Add dwarf_version.
9912 (struct dwo_sections): Add loclists.
9913 (struct attr_abbrev): Add implicit_const.
9914 (read_indirect_line_string): New declaration.
9915 (read_unsigned_leb128): Delete declaration.
9916 (rcuh_kind): New definition.
9917 (read_and_check_comp_unit_head): Change parameter
9918 is_debug_types_section to section_kind.
9919 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
9920 (read_comp_unit_head): Change parameter abfd to section, add parameter
9921 section_kind. Handle DWARF-5.
9922 (error_check_comp_unit_head): Accept also DWARF version 5.
9923 (read_and_check_comp_unit_head): Change parameter
9924 is_debug_types_section to section_kind.
9925 (read_and_check_type_unit_head): Delete function.
9926 (read_abbrev_offset): Handle DWARF-5.
9927 (create_debug_type_hash_table): Add parameter section_kind. Process
9928 only DW_UT_type. Use signature and type_offset_in_tu from struct
9929 comp_unit_head.
9930 (create_debug_types_hash_table): Update create_debug_type_hash_table
9931 caller.
9932 (create_all_type_units): Call create_debug_type_hash_table.
9933 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
9934 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
9935 caller.
9936 (skip_one_die): Handle DW_FORM_implicit_const.
9937 (dwarf2_rnglists_process): New function.
9938 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
9939 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
9940 (read_attribute_value): Handle DW_FORM_implicit_const,
9941 DW_FORM_line_strp.
9942 (read_attribute): Handle DW_FORM_implicit_const.
9943 (read_indirect_string_at_offset_from): New function from
9944 read_indirect_string_at_offset.
9945 (read_indirect_string_at_offset): Call
9946 read_indirect_string_at_offset_from.
9947 (read_indirect_line_string_at_offset): New function.
9948 (read_indirect_string): New function comment.
9949 (read_indirect_line_string): New function.
9950 (read_unsigned_leb128): Make it global.
9951 (dwarf2_string_attr): Handle DWARF-5.
9952 (add_include_dir_stub, read_formatted_entries): New functions.
9953 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
9954 Handle DWARF-5.
9955 (per_cu_header_read_in): Update read_comp_unit_head caller.
9956 (dwarf2_version): New function.
9957 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
9958 rnglists.
9959 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
9960 fields.
9961
9962 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9963
9964 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
9965
9966 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9967
9968 * dwarf2read.c (dwarf2_ranges_process): New function from
9969 dwarf2_ranges_read.
9970 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
9971 dwarf2_ranges_process.
9972
9973 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9974
9975 * dwarf2read.c (create_debug_type_hash_table): New function from
9976 create_debug_types_hash_table.
9977 (create_debug_types_hash_table): Call create_debug_type_hash_table.
9978 (create_all_type_units, open_and_init_dwo_file): Update
9979 create_debug_types_hash_table callers.
9980
9981 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9982
9983 PR gdb/16188
9984 * fork-child.c (trace_start_error): Fix thinko. va_end should
9985 refer to 'ap', not 'args'.
9986
9987 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
9988 Pedro Alves <palves@redhat.com>
9989
9990 PR gdb/16188
9991 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
9992 calls succeeded.
9993 * fork-child.c (trace_start_error): New function.
9994 (trace_start_error_with_name): Likewise.
9995 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
9996 * inf-ptrace.c (inf_ptrace_me): Likewise.
9997 * inferior.h (trace_start_error): New prototype.
9998 (trace_start_error_with_name): Likewise.
9999
10000 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
10001
10002 PR gdb/21164
10003 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
10004 NULL before using it.
10005 * symmisc.c (maintenance_print_symbols): Likewise.
10006 (maintenance_print_msymbols): Likewise.
10007
10008 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10009
10010 * NEWS: Add record Python bindings entry.
10011
10012 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10013
10014 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
10015 py-record-full.o.
10016 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
10017 * python/py-record-btrace.c, python/py-record-btrace.h,
10018 python/py-record-full.c, python/py-record-full.h: New file.
10019 * python/py-record.c: Add include for py-record-btrace.h and
10020 py-record-full.h.
10021 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
10022 recpy_instruction_history, recpy_function_call_history, recpy_begin,
10023 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
10024 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
10025 New definition.
10026 (gdbpy_initialize_btrace): New export.
10027 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
10028
10029 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10030
10031 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
10032 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
10033 * python/py-record.c: New file.
10034 * python/python-internal.h (gdbpy_start_recording,
10035 gdbpy_current_recording, gdpy_stop_recording,
10036 gdbpy_initialize_record): New export.
10037 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
10038 (python_GdbMethods): Add gdbpy_start_recording,
10039 gdbpy_current_recording and gdbpy_stop_recording.
10040
10041 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10042
10043 * record-btrace.c (record_btrace_record_method): New function.
10044 (init_record_btrace_ops): Initialize to_record_method.
10045 * record-full.c (record_full_record_method): New function.
10046 (init_record_full_ops, init_record_full_core_ops): Add
10047 record_full_record_method.
10048 * record.h (enum record_method): New enum.
10049 * target-debug.h (target_debug_print_enum_record_method: New define.
10050 * target-delegates.c: Regenerate.
10051 * target.c (target_record_method): New function.
10052 * target.h: Include record.h.
10053 (struct target_ops) <to_record_method>: New field.
10054 (target_record_method): New export.
10055
10056 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10057
10058 * record.h (record_start, record_stop): New export.
10059 * record.c (record_start, record_stop): New function.
10060
10061 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10062
10063 * btrace.c (btrace_fetch): Copy function call segments pointer
10064 into a vector.
10065 (btrace_clear): Clear the vector.
10066 (btrace_find_insn_by_number): Use binary search to find the correct
10067 function call segment.
10068 * btrace.h (brace_fun_p): New typedef.
10069 (struct btrace_thread_info) <functions>: New field.
10070
10071 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10072
10073 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
10074 * btrace.c (btrace_decode_error): ... here. New function.
10075 * btrace.h (btrace_decode_error): New export.
10076
10077 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10078
10079 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
10080 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
10081 btrace_find_insn_by_number): Remove special case for gaps.
10082 * btrace.h (btrace_insn_get_error): New export.
10083 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
10084 * record-btrace.c (btrace_insn_history): Print number for gaps.
10085 (record_btrace_info, record_btrace_goto): Handle gaps.
10086
10087 2017-02-14 Tom Tromey <tom@tromey.com>
10088
10089 PR python/13598:
10090 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
10091 event.
10092 * python/py-evts.c (gdbpy_initialize_py_events): Add
10093 before_prompt registry.
10094 * python/py-events.h (events_object) <before_prompt>: New field.
10095
10096 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
10097
10098 * btrace.c (ftrace_new_switch): Preserve up link and flags.
10099
10100 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
10101
10102 * symfile (_initialize_symfile): Add usage text to the load command's
10103 help text.
10104
10105 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
10106
10107 * utils.c (defaulted_query): Don't query on secondary UIs.
10108
10109 2017-02-10 Tom Tromey <tom@tromey.com>
10110
10111 * rust-lang.c (rust_get_disr_info): Remove unused variable.
10112
10113 2017-02-10 Tom Tromey <tom@tromey.com>
10114
10115 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
10116 "cleanup" local.
10117 * python/py-type.c (typy_legacy_template_argument): Remove
10118 unnecessary "cleanup" local.
10119
10120 2017-02-10 Tom Tromey <tom@tromey.com>
10121
10122 * python/python.c (do_start_initialization): New function, from
10123 _initialize_python.
10124 (_initialize_python): Call do_start_initialization.
10125 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10126 goto.
10127
10128 2017-02-10 Tom Tromey <tom@tromey.com>
10129
10130 * python/py-prettyprint.c (pretty_print_one_value): Use
10131 gdbpy_ref.
10132
10133 2017-02-10 Tom Tromey <tom@tromey.com>
10134
10135 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10136 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10137 gdbpy_ref.
10138 * python/py-type.c (field_new): Use gdbpy_ref.
10139 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10140 gdbpy_ref.
10141 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10142 (py_free_pspace): Likewise.
10143 (pspace_to_pspace_object): Likewise.
10144 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10145 (py_free_objfile): Likewise.
10146 (objfile_to_objfile_object): Likewise.
10147 * python/py-inferior.c (delete_thread_object): Use
10148 gdbpy_ref.
10149 (infpy_read_memory): Likewise.
10150 (py_free_inferior): Likewise.
10151 * python/py-evtregistry.c (create_eventregistry_object): Use
10152 gdbpy_ref.
10153 * python/py-event.c (create_event_object): Use gdbpy_ref.
10154
10155 2017-02-10 Tom Tromey <tom@tromey.com>
10156
10157 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10158 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10159 used.
10160 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10161 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10162 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10163 python/py-framefilter.c, python/py-function.c,
10164 python/py-inferior.c, python/py-infevents.c,
10165 python/py-linetable.c, python/py-newobjfileevent.c,
10166 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10167 python/py-signalevent.c, python/py-stopevent.c,
10168 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10169 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10170 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10171 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10172
10173 2017-02-10 Tom Tromey <tom@tromey.com>
10174
10175 * ui-out.h (ui_out_emit_type): New class.
10176 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10177 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10178 and ui_out_emit_tuple.
10179 (enumerate_locals): Likewise.
10180 (py_mi_print_variables, py_print_locals, py_print_args): Use
10181 ui_out_emit_list.
10182 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10183 ui_out_emit_list.
10184 * common/gdb_optional.h: New file.
10185
10186 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10187
10188 * MAINTAINERS (Write After Approval): Update my e-mail address.
10189
10190 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
10191
10192 PR gdb/21122
10193 * breakpoint.c (_initialize_breakpoint): Update the help description
10194 of the 'commands' command to indicate that it takes a list argument.
10195
10196 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10197
10198 * interps.c (current_interp_set_logging): Remove "return".
10199
10200 2017-02-09 Gary Benson <gbenson@redhat.com>
10201
10202 * symtab.c (add_symtab_completions): Prevent NULL pointer
10203 dereference.
10204
10205 2017-02-08 Pedro Alves <palves@redhat.com>
10206
10207 * interps.c (interp::interp): Remove reference to quiet_p.
10208 (interp_set): Make static. Remove dead "Switching to" output
10209 code.
10210 (interp_quiet_p, interp_set_quiet): Delete.
10211 (interpreter_exec_cmd): Don't set the interpreter quiet.
10212 * interps.h (interp_quiet_p): Make static.
10213 (class interp) <quiet_p>: Remove field
10214
10215 2017-02-08 Jerome Guitton <guitton@adacore.com>
10216
10217 * cli/cli-decode.c (find_command_name_length): Make it extern.
10218 * cli/cli-decode.h (find_command_name_length): Declare.
10219 * cli/cli-script.c (command_name_equals, line_first_arg):
10220 New functions.
10221 (process_next_line): Use cli-decode to parse command names.
10222 (build_command_line): Make args a constant pointer.
10223
10224 2017-02-08 Jerome Guitton <guitton@adacore.com>
10225
10226 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10227 Remove case-insensitive search.
10228
10229 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10230
10231 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10232 at the end of the line. Avoids an ARI warning.
10233
10234 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
10235
10236 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10237 rdseed instructions.
10238 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10239
10240 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10241
10242 PR tdep/20936
10243 Provide and use sparc32 and sparc64 target description XML files.
10244 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10245 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10246 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10247 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10248 * features/sparc/sparc32-solaris.xml: New file.
10249 * features/sparc/sparc64-solaris.xml: New file.
10250 * features/sparc/sparc32-solaris.c: Generated.
10251 * features/sparc/sparc64-solaris.c: Generated.
10252 * sparc-tdep.h: Account for differences in target descriptions.
10253 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10254 (sparc32_register_type): Use target provided registers.
10255 (validate_tdesc_registers): New function.
10256 (sparc32_gdbarch_init): Use tdesc_has_registers.
10257 Set pseudoregister functions.
10258 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10259 (sparc64_register_type): Use target provided registers.
10260 (sparc64_init_abi): Set pseudoregister functions.
10261
10262 2017-02-03 Tom Tromey <tom@tromey.com>
10263
10264 PR rust/21097:
10265 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10266 with a single member.
10267
10268 2017-02-03 Pedro Alves <palves@redhat.com>
10269
10270 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10271 (cli_interp_base::~cli_interp_base): New.
10272 (cli_interp): New struct.
10273 (as_cli_interp): Cast the interp itself to cli_interp.
10274 (cli_interpreter_pre_command_loop): Rename to ...
10275 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10276 parameter.
10277 (cli_interpreter_init): Rename to ...
10278 (cli_interp::init): ... this. Remove 'self' parameter. Use
10279 boolean. Make extern.
10280 (cli_interpreter_resume): Rename to ...
10281 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10282 extern.
10283 (cli_interpreter_suspend): Rename to ...
10284 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10285 extern.
10286 (cli_interpreter_exec): Rename to ...
10287 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10288 extern.
10289 (cli_interpreter_supports_command_editing): Rename to ...
10290 (cli_interp_base::supports_command_editing): ... this. Remove
10291 'interp' parameter. Make extern.
10292 (cli_ui_out): Rename to ...
10293 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10294 Make extern.
10295 (cli_set_logging): Rename to ...
10296 (cli_interp_base::set_logging): ... this. Remove 'interp'
10297 parameter. Make extern.
10298 (cli_interp_procs): Delete.
10299 (cli_interp_factory): Adjust to use "new".
10300 * cli/cli-interp.h: Include "interps.h".
10301 (struct cli_interp_base): New struct.
10302 * interps.c (struct interp): Delete. Fields moved to interps.h.
10303 (interp_new): Delete.
10304 (interp::interp, interp::~interp): New.
10305 (interp_set): Use bool, and return void. Assume the interpreter
10306 has suspend, init and resume methods, and that the all return
10307 void.
10308 (set_top_level_interpreter): interp_set returns void.
10309 (interp_ui_out): Adapt.
10310 (current_interp_set_logging): Adapt.
10311 (interp_data): Delete.
10312 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10313 (interp_exec): Adapt.
10314 (top_level_interpreter_data): Delete.
10315 * interps.h (interp_init_ftype, interp_resume_ftype)
10316 (interp_suspend_ftype, interp_exec_ftype)
10317 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10318 (class interp): New.
10319 (interp_new): Delete.
10320 (interp_set): Now returns void. Use bool.
10321 (interp_data, top_level_interpreter_data): Delete.
10322 * mi/mi-common.h: Include interps.h.
10323 (class mi_interp): Inherit from interp. Define a ctor. Declare
10324 init, resume, suspect, exec, interp_ui_out, set_logging and
10325 pre_command_loop methods.
10326 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10327 (mi_interpreter_init): Rename to ...
10328 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10329 bool, return void and make extern. Adjust.
10330 (mi_interpreter_resume): ... Rename to ...
10331 (mi_interp::resume): ... this. Remove the 'data' parameter,
10332 return void and make extern. Adjust.
10333 (mi_interpreter_suspend): ... Rename to ...
10334 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10335 return void and make extern. Adjust.
10336 (mi_interpreter_exec): ... Rename to ...
10337 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10338 extern. Adjust.
10339 (mi_interpreter_pre_command_loop): ... Rename to ...
10340 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10341 parameter and make extern.
10342 (mi_on_normal_stop_1): Adjust.
10343 (mi_ui_out): Rename to ...
10344 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10345 parameter and make extern. Adjust.
10346 (mi_set_logging): Rename to ...
10347 (mi_interp::set_logging): ... this. Remove the 'interp'
10348 parameter and make extern. Adjust.
10349 (mi_interp_procs): Delete.
10350 (mi_interp_factory): Adjust to use 'new'.
10351 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10352 (mi_print_exception, mi_execute_command, mi_load_progress):
10353 Adjust.
10354 * tui/tui-interp.c (tui_interp): New class.
10355 (as_tui_interp): Return a tui_interp pointer.
10356 (tui_on_normal_stop, tui_on_signal_received)
10357 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10358 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10359 to use interp::interp_ui_out.
10360 (tui_init): Rename to ...
10361 (tui_interp::init): ... this. Remove the 'self' parameter, use
10362 bool, return void and make extern. Adjust.
10363 (tui_resume): Rename to ...
10364 (tui_interp::resume): ... this. Remove the 'data' parameter,
10365 return void and make extern. Adjust.
10366 (tui_suspend): Rename to ...
10367 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10368 return void and make extern. Adjust.
10369 (tui_ui_out): Rename to ...
10370 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10371 parameter, and make extern. Adjust.
10372 (tui_exec): Rename to ...
10373 (tui_interp::exec): ... this. Remove the 'data' parameter and
10374 make extern.
10375 (tui_interp_procs): Delete.
10376 (tui_interp_factory): Use "new".
10377
10378 2017-02-02 Tom Tromey <tom@tromey.com>
10379
10380 * rust-exp.y (ends_raw_string, space_then_number)
10381 (rust_identifier_start_p): Return bool.
10382 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10383 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10384 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10385 (rust_chartype_p): Return bool.
10386 (val_print_struct, rust_print_struct_def, rust_print_type):
10387 Update.
10388 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10389 Return bool.
10390
10391 2017-02-02 Tom Tromey <tom@tromey.com>
10392
10393 * rust-lang.c: Reindent.
10394
10395 2017-02-02 Tom Tromey <tom@tromey.com>
10396
10397 * rust-lang.h (rust_crate_for_block): Update.
10398 * rust-lang.c (rust_crate_for_block): Return std::string.
10399 (rust_get_disr_info): Use std:;string, not
10400 gdb::unique_xmalloc_ptr.
10401 * rust-exp.y (crate_name): Update.
10402
10403 2017-02-02 Pedro Alves <palves@redhat.com>
10404
10405 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
10406 field out of gdb_disassembler_test and make it static.
10407
10408 2017-02-02 Pedro Alves <palves@redhat.com>
10409
10410 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
10411 mi1_interp and mi_interp fields.
10412
10413 2017-02-02 Pedro Alves <palves@redhat.com>
10414
10415 * cli/cli-interp.c (struct saved_output_files, saved_output):
10416 Moved from cli/cli-logging.c.
10417 (cli_set_logging): New function.
10418 (cli_interp_procs): Install cli_set_logging.
10419 * cli/cli-interp.h (make_logging_output, cli_set_logging):
10420 Declare.
10421 * cli/cli-logging.c (struct saved_output_files, saved_output):
10422 Moved to cli/cli-interp.c.
10423 (pop_output_files): Don't save outputs here.
10424 (make_logging_output): New function.
10425 (handle_redirections): Don't build tee nor save previous outputs
10426 here.
10427 * interps.c (current_interp_set_logging): Change prototype.
10428 Assume there's always a set_logging_proc method installed.
10429 * interps.h (interp_set_logging_ftype): Change prototype.
10430 (current_interp_set_logging): Change prototype and adjust comment.
10431 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
10432 use make_logging_output.
10433 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
10434 2017-02-02 Pedro Alves <palves@redhat.com>
10435
10436 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
10437 from ...
10438 (set_logging_overwrite): ... here.
10439 (logging_no_redirect_file): Delete.
10440 (set_logging_redirect): Don't handle redirection on the fly.
10441 Instead warn that "logging off" / "logging on" is necessary.
10442 (pop_output_files): Delete references to logging_no_redirect_file.
10443 (show_logging_command): Always speak in terms of what will happen
10444 once logging is reenabled.
10445
10446 2017-02-02 Pedro Alves <palves@redhat.com>
10447
10448 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
10449
10450 2017-02-02 Pedro Alves <palves@redhat.com>
10451
10452 * disasm.c (gdb_pretty_print_insn): Rename to ...
10453 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
10454 Remove gdbarch parameter. Adapt to clear the object's buffers
10455 instead of allocating new buffers, and to print using the object's
10456 gdb_disassembler instead of calling gdb_print_insn.
10457 (dump_insns): Use gdb_pretty_print_disassembler.
10458 * disasm.h (gdb_pretty_print_insn): Delete declaration.
10459 (gdb_pretty_print_disassembler): New class.
10460 * record-btrace.c (btrace_insn_history): Use
10461 gdb_pretty_print_disassembler.
10462
10463 2017-02-02 Pedro Alves <palves@redhat.com>
10464
10465 * ada-lang.c (type_as_string): Use string_file.
10466 * ada-valprint.c (ada_print_floating): Use string_file.
10467 * ada-varobj.c (ada_varobj_scalar_image)
10468 (ada_varobj_get_value_image): Use string_file.
10469 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
10470 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
10471 * breakpoint.c (update_inserted_breakpoint_locations)
10472 (insert_breakpoint_locations, reattach_breakpoints)
10473 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
10474 (print_it_watchpoint): Use string_file.
10475 (save_breakpoints): Use stdio_file.
10476 * c-exp.y (oper): Use string_file.
10477 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
10478 tee_file.
10479 (pop_output_files): Use delete.
10480 (handle_redirections): Use stdio_file and tee_file.
10481 * cli/cli-setshow.c (do_show_command): Use string_file.
10482 * compile/compile-c-support.c (c_compute_program): Use
10483 string_file.
10484 * compile/compile-c-symbols.c (generate_vla_size): Take a
10485 'string_file &' instead of a 'ui_file *'.
10486 (generate_c_for_for_one_variable): Take a 'string_file &' instead
10487 of a 'ui_file *'. Use string_file.
10488 (generate_c_for_variable_locations): Take a 'string_file &'
10489 instead of a 'ui_file *'.
10490 * compile/compile-internal.h (generate_c_for_for_one_variable):
10491 Take a 'string_file &' instead of a 'ui_file *'.
10492 * compile/compile-loc2c.c (push, pushf, unary, binary)
10493 (print_label, pushf_register_address, pushf_register)
10494 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
10495 'ui_file *'. Adjust.
10496 * compile/compile.c (compile_to_object): Use string_file.
10497 * compile/compile.h (compile_dwarf_expr_to_c)
10498 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
10499 'ui_file *'.
10500 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
10501 (replace_typedefs_qualified_name): Use string_file and
10502 obstack_copy0.
10503 * disasm.c (gdb_pretty_print_insn): Use string_file.
10504 (gdb_disassembly): Adjust reference the null_stream global.
10505 (do_ui_file_delete): Delete.
10506 (gdb_insn_length): Use null_stream.
10507 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
10508 * dwarf2loc.c (dwarf2_compile_property_to_c)
10509 (locexpr_generate_c_location, loclist_generate_c_location): Take a
10510 'string_file &' instead of a 'ui_file *'.
10511 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
10512 * dwarf2read.c (do_ui_file_peek_last): Delete.
10513 (dwarf2_compute_name): Use string_file.
10514 * event-top.c (gdb_setup_readline): Use stdio_file.
10515 * gdbarch.sh (verify_gdbarch): Use string_file.
10516 * gdbtypes.c (safe_parse_type): Use null_stream.
10517 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
10518 string_file.
10519 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
10520 'string_file *' instead of a 'ui_file *'.
10521 (gdbscm_arch_disassemble): Use string_file.
10522 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
10523 * guile/scm-ports.c (class ioscm_file_port): Now a class that
10524 inherits from ui_file.
10525 (ioscm_file_port_delete, ioscm_file_port_rewind)
10526 (ioscm_file_port_put): Delete.
10527 (ioscm_file_port_write): Rename to ...
10528 (ioscm_file_port::write): ... this. Remove file_port_magic
10529 checks.
10530 (ioscm_file_port_new): Delete.
10531 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
10532 ui_file_up.
10533 * guile/scm-type.c (tyscm_type_name): Use string_file.
10534 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
10535 Use string_file.
10536 * infcmd.c (print_return_value_1): Use string_file.
10537 * infrun.c (print_target_wait_results): Use string_file.
10538 * language.c (add_language): Use string_file.
10539 * location.c (explicit_to_string_internal): Use string_file.
10540 * main.c (captured_main_1): Use null_file.
10541 * maint.c (maintenance_print_architecture): Use stdio_file.
10542 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
10543 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
10544 event_channel>: Change type to mi_console_file pointer.
10545 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
10546 (mi_console_file_delete): Delete.
10547 (struct mi_console_file): Delete.
10548 (mi_console_file_magic): Delete.
10549 (mi_console_file_new): Delete.
10550 (mi_console_file::mi_console_file): New.
10551 (mi_console_file_delete): Delete.
10552 (mi_console_file_fputs): Delete.
10553 (mi_console_file::write): New.
10554 (mi_console_raw_packet): Delete.
10555 (mi_console_file::flush): New.
10556 (mi_console_file_flush): Delete.
10557 (mi_console_set_raw): Rename to ...
10558 (mi_console_file::set_raw): ... this.
10559 * mi/mi-console.h (class mi_console_file): New class.
10560 (mi_console_file_new, mi_console_set_raw): Delete.
10561 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
10562 (mi_set_logging): Use delete and tee_file. Adjust.
10563 * mi/mi-main.c (output_register): Use string_file.
10564 (mi_cmd_data_evaluate_expression): Use string_file.
10565 (mi_cmd_data_read_memory): Use string_file.
10566 (mi_cmd_execute, print_variable_or_computed): Use string_file.
10567 * mi/mi-out.c (mi_ui_out::main_stream): New.
10568 (mi_ui_out::rewind): Use main_stream and
10569 string_file.
10570 (mi_ui_out::put): Use main_stream and string_file.
10571 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10572 Allocate a 'string_file' instead.
10573 (mi_out_new): Don't allocate a mem_fileopen stream here.
10574 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10575 (mi_ui_out::main_stream): Declare method.
10576 * printcmd.c (eval_command): Use string_file.
10577 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
10578 * python/py-arch.c (archpy_disassemble): Use string_file.
10579 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
10580 * python/py-frame.c (frapy_str): Use string_file.
10581 * python/py-framefilter.c (py_print_type, py_print_single_arg):
10582 Use string_file.
10583 * python/py-type.c (typy_str): Use string_file.
10584 * python/py-unwind.c (unwind_infopy_str): Use string_file.
10585 * python/py-value.c (valpy_str): Use string_file.
10586 * record-btrace.c (btrace_insn_history): Use string_file.
10587 * regcache.c (regcache_print): Use stdio_file.
10588 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
10589 * remote.c (escape_buffer): Use string_file.
10590 * rust-lang.c (rust_get_disr_info): Use string_file.
10591 * serial.c (serial_open_ops_1): Use stdio_file.
10592 (do_serial_close): Use delete.
10593 * stack.c (print_frame_arg): Use string_file.
10594 (print_frame_args): Remove local mem_fileopen stream, not used.
10595 (print_frame): Use string_file.
10596 * symmisc.c (maintenance_print_symbols): Use stdio_file.
10597 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
10598 Take a 'string_file *' instead of a 'ui_file *'.
10599 * top.c (new_ui): Use stdio_file and stderr_file.
10600 (free_ui): Use delete.
10601 (execute_command_to_string): Use string_file.
10602 (quit_confirm): Use string_file.
10603 * tracepoint.c (collection_list::append_exp): Use string_file.
10604 * tui/tui-disasm.c (tui_disassemble): Use string_file.
10605 * tui/tui-file.c: Don't include "ui-file.h".
10606 (enum streamtype, struct tui_stream): Delete.
10607 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
10608 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
10609 (tui_file::tui_file): New method.
10610 (tui_file_fputs): Delete.
10611 (tui_file_get_strbuf): Delete.
10612 (tui_file::puts): New method.
10613 (tui_file_adjust_strbuf): Delete.
10614 (tui_file_flush): Delete.
10615 (tui_file::flush): New method.
10616 * tui/tui-file.h: Tweak intro comment.
10617 Include ui-file.h.
10618 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
10619 (tui_file_adjust_strbuf): Delete declarations.
10620 (class tui_file): New class.
10621 * tui/tui-io.c (tui_initialize_io): Use tui_file.
10622 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
10623 (tui_register_format): Use string_stream.
10624 * tui/tui-stack.c (tui_make_status_line): Use string_file.
10625 (tui_get_function_from_frame): Use string_file.
10626 * typeprint.c (type_to_string): Use string_file.
10627 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
10628 (null_stream): New global.
10629 (ui_file_delete): Delete.
10630 (ui_file::ui_file): New.
10631 (null_file_isatty): Delete.
10632 (ui_file::~ui_file): New.
10633 (null_file_rewind): Delete.
10634 (ui_file::printf): New.
10635 (null_file_put): Delete.
10636 (null_file_flush): Delete.
10637 (ui_file::putstr): New.
10638 (null_file_write): Delete.
10639 (ui_file::putstrn): New.
10640 (null_file_read): Delete.
10641 (ui_file::putc): New.
10642 (null_file_fputs): Delete.
10643 (null_file_write_async_safe): Delete.
10644 (ui_file::vprintf): New.
10645 (null_file_delete): Delete.
10646 (null_file::write): New.
10647 (null_file_fseek): Delete.
10648 (null_file::puts): New.
10649 (ui_file_data): Delete.
10650 (null_file::write_async_safe): New.
10651 (gdb_flush, ui_file_isatty): Adjust.
10652 (ui_file_put, ui_file_rewind): Delete.
10653 (ui_file_write): Adjust.
10654 (ui_file_write_for_put): Delete.
10655 (ui_file_write_async_safe, ui_file_read): Adjust.
10656 (ui_file_fseek): Delete.
10657 (fputs_unfiltered): Adjust.
10658 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
10659 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
10660 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
10661 (set_ui_file_data): Delete.
10662 (string_file::~string_file, string_file::write)
10663 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
10664 (do_ui_file_as_string, ui_file_as_string): Delete.
10665 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
10666 (struct mem_file): Delete.
10667 (mem_file_new): Delete.
10668 (stdio_file::stdio_file): New.
10669 (mem_file_delete): Delete.
10670 (stdio_file::stdio_file): New.
10671 (mem_fileopen): Delete.
10672 (stdio_file::~stdio_file): New.
10673 (mem_file_rewind): Delete.
10674 (stdio_file::set_stream): New.
10675 (mem_file_put): Delete.
10676 (stdio_file::open): New.
10677 (mem_file_write): Delete.
10678 (stdio_file_magic, struct stdio_file): Delete.
10679 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
10680 (stdio_file::flush): New.
10681 (stdio_file_read): Rename to ...
10682 (stdio_file::read): ... this. Adjust.
10683 (stdio_file_write): Rename to ...
10684 (stdio_file::write): ... this. Adjust.
10685 (stdio_file_write_async_safe): Rename to ...
10686 (stdio_file::write_async_safe) ... this. Adjust.
10687 (stdio_file_fputs): Rename to ...
10688 (stdio_file::puts) ... this. Adjust.
10689 (stdio_file_isatty): Delete.
10690 (stdio_file_fseek): Delete.
10691 (stdio_file::isatty): New.
10692 (stderr_file_write): Rename to ...
10693 (stderr_file::write) ... this. Adjust.
10694 (stderr_file_fputs): Rename to ...
10695 (stderr_file::puts) ... this. Adjust.
10696 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
10697 (stderr_file::stderr_file): New.
10698 (tee_file_magic): Delete.
10699 (struct tee_file): Delete.
10700 (tee_file::tee_file): New.
10701 (tee_file_new): Delete.
10702 (tee_file::~tee_file): New.
10703 (tee_file_delete): Delete.
10704 (tee_file_flush): Rename to ...
10705 (tee_file::flush): ... this. Adjust.
10706 (tee_file_write): Rename to ...
10707 (tee_file::write): ... this. Adjust.
10708 (tee_file::write_async_safe): New.
10709 (tee_file_fputs): Rename to ...
10710 (tee_file::puts): ... this. Adjust.
10711 (tee_file_isatty): Rename to ...
10712 (tee_file::isatty): ... this. Adjust.
10713 * ui-file.h (struct obstack, struct ui_file): Don't
10714 forward-declare.
10715 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
10716 (ui_file_write_ftype)
10717 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
10718 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
10719 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
10720 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
10721 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
10722 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
10723 (set_ui_file_fseek): Delete.
10724 (ui_file_data, ui_file_delete, ui_file_rewind)
10725 (struct ui_file): New.
10726 (ui_file_up): New.
10727 (class null_file): New.
10728 (null_stream): Declare.
10729 (ui_file_write_for_put, ui_file_put): Delete.
10730 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
10731 Delete.
10732 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
10733 (gdb_fopen, tee_file_new): Delete.
10734 (struct string_file): New.
10735 (struct stdio_file): New.
10736 (stdio_file_up): New.
10737 (struct stderr_file): New.
10738 (class tee_file): New.
10739 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
10740 of a 'ui_file *'. Adjust.
10741 * ui-out.h (class ui_out) <field_stream>: Likewise.
10742 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
10743 (null_stream): Delete.
10744 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
10745 Adjust.
10746 * utils.h (struct ui_file): Delete forward declaration..
10747 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
10748 (error_stream): Take a 'string_file &' instead of a
10749 'ui_file *'.
10750 * varobj.c (varobj_value_get_print_value): Use string_file.
10751 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
10752 * gdbarch.c: Regenerate.
10753
10754 2017-02-02 Pedro Alves <palves@redhat.com>
10755
10756 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
10757 (gdb_pretty_print_insn): ... this. Now a free function. Add back
10758 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
10759 Adjust to call gdb_print_insn instead of
10760 gdb_disassembler::print_insn.
10761 (dump_insns, do_mixed_source_and_assembly_deprecated)
10762 (do_mixed_source_and_assembly, do_assembly_only): Add back a
10763 'gdbarch' parameter. Remove gdb_disassembler parameter.
10764 (gdb_disassembly): Don't allocate a gdb_disassembler here.
10765 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
10766 declaration.
10767 (gdb_pretty_print_insn): Re-add declaration.
10768 * record-btrace.c (btrace_insn_history): Don't allocate a
10769 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
10770
10771 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
10772
10773 * disasm.h (gdb_disassembly): Remove file_string parameter.
10774 * disasm.c (gdb_disassembly): Likewise.
10775 * cli/cli-cmds.c (print_disassembly): Adapt.
10776 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
10777 * stack.c (do_gdb_disassembly): Likewise.
10778
10779 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
10780
10781 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
10782 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
10783 targets. And if the implicit value is longer than needed, extract
10784 the first bytes instead of the "least significant" ones.
10785
10786 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
10787
10788 * btrace.c (btrace_enable): Do not call btrace_add_pc for
10789 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
10790 (btrace_fetch): Assert can_access_registers_ptid.
10791 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
10792 validate_registers_access.
10793
10794 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
10795
10796 * gdbthread.h (can_access_registers_ptid): New.
10797 * thread.c (can_access_registers_ptid): New.
10798
10799 2017-02-01 Pedro Alves <palves@redhat.com>
10800
10801 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
10802
10803 2017-01-31 Pedro Alves <palves@redhat.com>
10804
10805 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
10806 Fix typos.
10807
10808 2017-01-31 Pedro Alves <palves@redhat.com>
10809
10810 * stack.c (print_frame_args): Remove local mem_fileopen stream,
10811 not used.
10812
10813 2017-01-31 Pedro Alves <palves@redhat.com>
10814
10815 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
10816
10817 2017-01-31 Pedro Alves <palves@redhat.com>
10818
10819 * common/scoped_restore.h
10820 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
10821 change the value's parameter type to T2.
10822 (make_scoped_restore): Likewise.
10823
10824 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10825 Richard Henderson <rth@redhat.com>
10826
10827 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
10828 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
10829 GS_BASE for older kernels.
10830 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
10831 GS_BASE for older kernels.
10832 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
10833 and GS_BASE to the offset table.
10834 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
10835 system register group.
10836 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
10837 for older kernels.
10838 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
10839 amd64 ABI.
10840 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
10841 AMD64_GSBASE_REGNUM.
10842 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
10843 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
10844 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
10845 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
10846 i386/64bit-segments.xml in those rules.
10847 * features/i386/64bit-segments.xml: New file.
10848 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
10849 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
10850 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
10851 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
10852 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
10853 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
10854 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
10855 * features/i386/amd64-avx-linux.c: Regenerated.
10856 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
10857 * features/i386/amd64-avx-mpx.c: Regenerated.
10858 * features/i386/amd64-avx512-linux.c: Regenerated.
10859 * features/i386/amd64-linux.c: Regenerated.
10860 * features/i386/amd64-mpx-linux.c: Regenerated.
10861 * features/i386/i386-avx-mpx-linux.c: Regenerated.
10862 * features/i386/i386-avx-mpx.c: Regenerated.
10863 * features/i386/x32-avx-linux.c: Regenerated.
10864 * features/i386/x32-avx512-linux.c: Regenerated.
10865 * regformats/i386/amd64-avx-linux.dat: Regenerated.
10866 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
10867 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
10868 * regformats/i386/amd64-linux.dat: Regenerated.
10869 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
10870 * regformats/i386/x32-avx-linux.dat: Regenerated.
10871 * regformats/i386/x32-avx512-linux.dat: Regenerated.
10872 * regformats/i386/x32-linux.dat: Regenerated.
10873
10874 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10875
10876 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
10877 Set to AMD64_NUM_REGS.
10878
10879 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10880
10881 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
10882 that checks validity of a register number.
10883
10884 2017-01-27 Kees Cook <keescook@google.com>
10885
10886 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
10887 fetch_fpregs if target has fpa registers.
10888 (arm_linux_store_inferior_registers): Call store_fpregs if target
10889 has fpa registers.
10890
10891 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
10892
10893 * cris-tdep.c (cris_gdbarch_init): Remove check for
10894 info.byte_order and force it to BFD_ENDIAN_LITTLE.
10895
10896 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
10897
10898 * corelow.c (get_core_register_section): Check for regset
10899 existence before checking for REGSET_VARIABLE_SIZE.
10900
10901 2017-01-26 Yao Qi <yao.qi@linaro.org>
10902 Pedro Alves <palves@redhat.com>
10903
10904 PR gdb/20939
10905 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
10906 call memory_error, save memaddr instead.
10907 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
10908 negative, cal memory_error.
10909 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
10910
10911 2017-01-26 Yao Qi <yao.qi@linaro.org>
10912
10913 * disasm-selftests.c (memory_error_test): New function.
10914 (_initialize_disasm_selftests): Register memory_error_test.
10915
10916 2017-01-26 Yao Qi <yao.qi@linaro.org>
10917
10918 * Makefile.in (SFILES): Add disasm-selftests.c and
10919 selftest-arch.c.
10920 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
10921 * disasm-selftests.c: New file.
10922 * selftest-arch.c: New file.
10923 * selftest-arch.h: New file.
10924
10925 2017-01-26 Yao Qi <yao.qi@linaro.org>
10926
10927 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
10928 to bfd_arch_mep. Don't return 0 if section is not
10929 found. Call print_insn_mep.
10930
10931 2017-01-26 Pedro Alves <palves@redhat.com>
10932 Yao Qi <yao.qi@linaro.org>
10933
10934 * arm-tdep.c: Include "disasm.h".
10935 (gdb_print_insn_arm): Update code to get gdbarch.
10936 * disasm.c (dis_asm_read_memory): Change it to
10937 gdb_disassembler::dis_asm_read_memory.
10938 (dis_asm_memory_error): Likewise.
10939 (dis_asm_print_address): Likewise.
10940 (gdb_pretty_print_insn): Change it to
10941 gdb_disassembler::pretty_print_insn.
10942 (dump_insns): Add one argument gdb_disassemlber. All
10943 callers updated.
10944 (do_mixed_source_and_assembly_deprecated): Likewise.
10945 (do_mixed_source_and_assembly): Likewise.
10946 (do_assembly_only): Likewise.
10947 (gdb_disassembler::gdb_disassembler): New.
10948 (gdb_disassembler::print_insn): New.
10949 * disasm.h (class gdb_disassembler): New.
10950 (gdb_pretty_print_insn): Remove declaration.
10951 (gdb_disassemble_info): Likewise.
10952 * guile/scm-disasm.c (class gdbscm_disassembler): New.
10953 (gdbscm_disasm_read_memory_worker): Update.
10954 (gdbscm_disasm_read_memory): Update.
10955 (gdbscm_disasm_memory_error): Remove.
10956 (gdbscm_disasm_print_address): Remove.
10957 (gdbscm_disassembler::gdbscm_disassembler): New.
10958 (gdbscm_print_insn_from_port): Update.
10959 * mips-tdep.c: Include disasm.h.
10960 (gdb_print_insn_mips): Update code to get gdbarch.
10961 * record-btrace.c (btrace_insn_history): Update.
10962 * spu-tdep.c: Include disasm.h.
10963 (struct spu_dis_asm_data): Remove.
10964 (struct spu_dis_asm_info): New.
10965 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
10966 SPU id.
10967 (gdb_print_insn_spu): Cast disassemble_info to
10968 spu_dis_asm_info.
10969
10970 2017-01-26 Yao Qi <yao.qi@linaro.org>
10971
10972 * disasm.c (do_ui_file_delete): Delete.
10973 (gdb_insn_length): Move code creating stream to ...
10974 * utils.c (null_stream): ... here. New function.
10975 * utils.h (null_stream): Declare.
10976
10977 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
10978
10979 * python/py-inferior.c (find_thread_object): Return directly
10980 from the loop. Remove "found" variable.
10981
10982 2017-01-21 Joel Brobecker <brobecker@adacore.com>
10983
10984 GDB 7.12.1 released.
10985
10986 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
10987
10988 * python/py-function.c (fnpy_call): Reorder declarations to have
10989 the gdbpy_enter object declared first.
10990 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
10991
10992 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
10993
10994 PR python/21068
10995 * python/python-internal.h (PyMem_RawMalloc): Define for
10996 Python < 3.4.
10997 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
10998 PyMem_RawMalloc instead of PyMem_Malloc.
10999
11000 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
11001 Luis Machado <lgustavo@codesourcery.com>
11002
11003 * NEWS (New commands): Mention flash-erase.
11004 (New MI commands): Mention target-flash-erase.
11005 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
11006 command.
11007 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
11008 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
11009 * target.c (flash_erase_command): New function.
11010 (initialize_targets): Add new flash-erase command.
11011 * target.h (flash_erase_command): New declaration.
11012
11013 2017-01-20 Joel Brobecker <brobecker@adacore.com>
11014
11015 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
11016 HAVE_SYS_PROCFS_H is defined.
11017
11018 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11019
11020 * remote.c (struct cached_reg): Change data into a pointer.
11021 * (stop_reply_dtr): Free data pointers before deleting vector.
11022 (process_stop_reply): Likewise.
11023 (remote_parse_stop_reply): Allocate space for data
11024
11025 2017-01-18 Alan Hayward <alan.hayward@arm.com>
11026
11027 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
11028 MAX_REGISTER_SIZE.
11029 (amd64_pseudo_register_read_value): Likewise.
11030 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
11031 (store_register_using_P): Likewise.
11032 * regcache.c (regcache_xfer_part): Likewise.
11033
11034 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
11035
11036 Split real and pseudo registers.
11037 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
11038 (sparc32_pseudo_regnum): New enum.
11039 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
11040 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
11041 (SPARC32_CP0_REGISTERS): New macro.
11042 (sparc32_pseudo_register_name): New function.
11043 (sparc32_register_name): Use sparc32_pseudo_register_name.
11044 (sparc32_pseudo_register_type): New function.
11045 (sparc32_register_type): Use sparc32_pseudo_register_type.
11046 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
11047 pseudo register numbers.
11048 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
11049 (SPARC64_CP0_REGISTERS): New macro.
11050 (sparc64_pseudo_register_name): New function.
11051 (sparc64_register_name): Use sparc64_pseudo_register_name.
11052 (sparc64_pseudo_register_type): New function.
11053 (sparc64_register_type): Use sparc64_pseudo_register_type.
11054 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
11055 pseudo register numbers.
11056 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
11057 sparc64_store_arguments): Handle pseudo register numbers.
11058
11059 2017-01-13 Yao Qi <yao.qi@linaro.org>
11060
11061 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
11062 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
11063 output.
11064 (getpkt_or_notif_sane_1): Likewise.
11065
11066 2017-01-13 Yao Qi <yao.qi@linaro.org>
11067
11068 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
11069 of CC. Pass "-x c++-header" instead of "-x c".
11070
11071 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11072
11073 * remote.c (remote_can_async_p): Update comment.
11074
11075 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11076
11077 * linux-nat.c (linux_nat_can_async_p): Update comment.
11078
11079 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11080
11081 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
11082
11083 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
11084
11085 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
11086
11087 2017-01-10 Tom Tromey <tom@tromey.com>
11088
11089 * python/py-type.c (typy_legacy_template_argument): Update.
11090 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
11091 ~demangle_parse_info): Declare new members.
11092 (cp_demangled_name_to_comp): Return unique_ptr.
11093 (cp_demangled_name_parse_free)
11094 (make_cleanup_cp_demangled_name_parse_free)
11095 (cp_new_demangle_parse_info): Remove.
11096 * cp-support.c (do_demangled_name_parse_free_cleanup)
11097 (make_cleanup_cp_demangled_name_parse_free): Remove.
11098 (inspect_type, cp_canonicalize_string_full)
11099 (cp_canonicalize_string): Update.
11100 (mangled_name_to_comp): Change return type.
11101 (cp_class_name_from_physname, method_name_from_physname)
11102 (cp_func_name, cp_remove_params): Update.
11103 * cp-name-parser.y (demangle_parse_info): New constructor, from
11104 cp_new_demangle_parse_info.
11105 (~demangle_parse_info): New destructor, from
11106 cp_demangled_name_parse_free.
11107 (cp_merge_demangle_parse_infos): Update.
11108 (cp_demangled_name_to_comp): Change return type.
11109
11110 2017-01-10 Tom Tromey <tom@tromey.com>
11111
11112 * top.c (prevent_dont_repeat): Change return type.
11113 * python/python.c (execute_gdb_command): Use std::string.
11114 Update.
11115 * guile/guile.c (gdbscm_execute_gdb_command): Update.
11116 * command.h (prevent_dont_repeat): Change return type.
11117 * breakpoint.c (bpstat_do_actions_1): Update.
11118
11119 2017-01-10 Tom Tromey <tom@tromey.com>
11120
11121 * value.h (scoped_value_mark::~scoped_value_mark): Call
11122 free_to_mark.
11123 (scoped_value_mark::free_to_mark): New method.
11124 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11125 scoped_value_mark.
11126
11127 2017-01-10 Tom Tromey <tom@tromey.com>
11128
11129 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11130 (valpy_reference_value, valpy_const_value, valpy_get_address)
11131 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11132 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11133 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11134 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11135 scoped_value_mark.
11136 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11137 * value.h (scoped_value_mark): New class.
11138
11139 2017-01-10 Tom Tromey <tom@tromey.com>
11140
11141 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11142 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11143 * psymtab.c (discard_psymtabs_upto): Remove.
11144 (make_cleanup_discard_psymtabs): Remove.
11145 (struct psymtab_state): Remove.
11146
11147 2017-01-10 Tom Tromey <tom@tromey.com>
11148
11149 * record-full.c (record_full_save_cleanups): Remove.
11150 (record_full_save): Use gdb::unlinker.
11151 * gcore.c (do_bfd_delete_cleanup): Remove.
11152 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11153 cleanups.
11154 * dwarf2read.c (unlink_if_set): Remove.
11155 (write_psymtabs_to_index): Use gdb::unlinker.
11156 * common/gdb_unlinker.h: New file.
11157
11158 2017-01-10 Tom Tromey <tom@tromey.com>
11159
11160 * windows-tdep.c (windows_xfer_shared_library): Update.
11161 * windows-nat.c (windows_make_so): Update.
11162 * utils.h (make_cleanup_bfd_unref): Remove.
11163 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11164 * symfile.h (symfile_bfd_open)
11165 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11166 * symfile.c (read_symbols, symbol_file_add)
11167 (separate_debug_file_exists): Update.
11168 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11169 (generic_load, reread_symbols): Update.
11170 * symfile-mem.c (symbol_file_add_from_memory): Update.
11171 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11172 (spu_symbol_file_add_from_memory): Update.
11173 * solist.h (struct target_so_ops) <bfd_open>: Return
11174 gdb_bfd_ref_ptr.
11175 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11176 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11177 gdb_bfd_ref_ptr.
11178 (solib_map_sections, reload_shared_libraries_1): Update.
11179 * solib-svr4.c (enable_break): Update.
11180 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11181 * solib-frv.c (enable_break2): Update.
11182 * solib-dsbt.c (enable_break): Update.
11183 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11184 gdb_bfd_ref_ptr.
11185 (darwin_solib_get_all_image_info_addr_at_init): Update.
11186 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11187 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11188 * record-full.c (record_full_save): Update.
11189 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11190 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11191 * minidebug.c (find_separate_debug_file_in_section): Return
11192 gdb_bfd_ref_ptr.
11193 * machoread.c (macho_add_oso_symfile): Change abfd to
11194 gdb_bfd_ref_ptr.
11195 (macho_symfile_read_all_oso): Update.
11196 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11197 (macho_symfile_read): Update.
11198 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11199 (jit_bfd_try_read_symtab): Update.
11200 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11201 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11202 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11203 gdb_bfd_ref_ptr.
11204 (gdb_bfd_ref_policy): New struct.
11205 (gdb_bfd_ref_ptr): New typedef.
11206 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11207 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11208 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11209 gdb_bfd_ref_ptr.
11210 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11211 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11212 (gcore_command): Update.
11213 * exec.c (exec_file_attach): Update.
11214 * elfread.c (elf_symfile_read): Update.
11215 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11216 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11217 (open_and_init_dwo_file): Update.
11218 (open_dwp_file): Return gdb_bfd_ref_ptr.
11219 (open_and_init_dwp_file): Update.
11220 * corelow.c (core_open): Update.
11221 * compile/compile-object-load.c (compile_object_load): Update.
11222 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11223 * coffread.c (coff_symfile_read): Update.
11224 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11225 gdb_bfd_ref_ptr. Rename.
11226 (dump_bfd_file, restore_command): Update.
11227 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11228 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11229 (find_separate_debug_file_by_buildid): Update.
11230
11231 2017-01-10 Tom Tromey <tom@tromey.com>
11232
11233 * common/gdb_ref_ptr.h: New file.
11234 * python/py-ref.h (struct gdbpy_ref_policy): New.
11235 (gdbpy_ref): Now a typedef.
11236
11237 2017-01-10 Tom Tromey <tom@tromey.com>
11238
11239 * utils.h (make_cleanup_htab_delete): Don't declare.
11240 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11241 Remove.
11242 * linespec.c (decode_compound_collector): Add constructor,
11243 destructor.
11244 (lookup_prefix_sym): Remove cleanup.
11245 (symtab_collector): Add constructor, destructor.
11246 (collect_symtabs_from_filename): Remove cleanup.
11247 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11248 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11249 Use htab_up.
11250 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11251 * dwarf2read.c (dw2_expand_symtabs_matching)
11252 (dw2_map_symbol_filenames, dwarf_decode_macros)
11253 (write_psymtabs_to_index): Use htab_up.
11254 * dwarf2loc.c (func_verify_no_selftailcall)
11255 (call_site_find_chain_1, func_verify_no_selftailcall)
11256 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11257 std::vector, gdb::unique_xmalloc_ptr.
11258 (call_sitep): Remove typedef.
11259 (dwarf2_locexpr_baton_eval): Remove unused variable.
11260
11261 2017-01-10 Tom Tromey <tom@tromey.com>
11262
11263 * python/python-internal.h (make_cleanup_py_decref)
11264 (make_cleanup_py_xdecref): Don't declare.
11265 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11266 (py_xdecref, make_cleanup_py_xdecref): Remove.
11267
11268 2017-01-10 Tom Tromey <tom@tromey.com>
11269
11270 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11271 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11272
11273 2017-01-10 Tom Tromey <tom@tromey.com>
11274
11275 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11276
11277 2017-01-10 Tom Tromey <tom@tromey.com>
11278
11279 * python/py-utils.c (unicode_to_encoded_string)
11280 (python_string_to_target_string)
11281 (python_string_to_target_python_string)
11282 (python_string_to_host_string, gdbpy_obj_to_string)
11283 (get_addr_from_python): Use gdbpy_ref.
11284
11285 2017-01-10 Tom Tromey <tom@tromey.com>
11286
11287 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11288 gdbpy_ref.
11289
11290 2017-01-10 Tom Tromey <tom@tromey.com>
11291
11292 * python/python.c (eval_python_command, gdbpy_decode_line)
11293 (gdbpy_run_events, gdbpy_start_type_printers)
11294 (gdbpy_apply_type_printers): Use gdbpy_ref.
11295
11296 2017-01-10 Tom Tromey <tom@tromey.com>
11297
11298 * python/py-param.c (get_doc_string, compute_enum_values): Use
11299 gdbpy_ref.
11300
11301 2017-01-10 Tom Tromey <tom@tromey.com>
11302
11303 * python/py-inferior.c (find_thread_object, build_inferior_list):
11304 Use gdbpy_ref.
11305
11306 2017-01-10 Tom Tromey <tom@tromey.com>
11307
11308 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11309
11310 2017-01-10 Tom Tromey <tom@tromey.com>
11311
11312 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11313 gdbpy_ref.
11314
11315 2017-01-10 Tom Tromey <tom@tromey.com>
11316
11317 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11318 extra incref.
11319 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11320 Use gdbpy_ref.
11321
11322 2017-01-10 Tom Tromey <tom@tromey.com>
11323
11324 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11325 gdbpy_ref.
11326
11327 2017-01-10 Tom Tromey <tom@tromey.com>
11328
11329 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11330 decref results of PyArg_ParseTupleAndKeywords.
11331
11332 2017-01-10 Tom Tromey <tom@tromey.com>
11333
11334 * python/python.c (python_run_simple_file): Use
11335 unique_xmalloc_ptr, gdbpy_ref.
11336
11337 2017-01-10 Tom Tromey <tom@tromey.com>
11338
11339 * python/py-prettyprint.c (print_stack_unless_memory_error)
11340 (print_string_repr, print_children): Use gdbpy_ref.
11341 (dummy_python_frame): New class.
11342 (dummy_python_frame::dummy_python_frame): Rename from
11343 push_dummy_python_frame.
11344 (py_restore_tstate): Remove.
11345
11346 2017-01-10 Tom Tromey <tom@tromey.com>
11347
11348 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11349
11350 2017-01-10 Tom Tromey <tom@tromey.com>
11351
11352 * python/python.c (ensure_python_env, restore_python_env):
11353 Remove.
11354 * python/python-internal.h (ensure_python_env): Don't declare.
11355 * varobj.h (varobj_ensure_python_env): Don't declare.
11356 * varobj.c (varobj_ensure_python_env): Remove.
11357
11358 2017-01-10 Tom Tromey <tom@tromey.com>
11359
11360 * varobj.c (varobj_value_get_print_value): Use
11361 gdbpy_enter_varobj.
11362
11363 2017-01-10 Tom Tromey <tom@tromey.com>
11364
11365 * python/py-prettyprint.c (print_string_repr, print_children):
11366 Update.
11367 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11368 of "encoding".
11369 * varobj.c (varobj_value_get_print_value): Update.
11370 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11371
11372 2017-01-10 Tom Tromey <tom@tromey.com>
11373
11374 * varobj.c (varobj_get_display_hint)
11375 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11376 (varobj_set_visualizer, free_variable): Use
11377 gdbpy_enter_varobj.
11378
11379 2017-01-10 Tom Tromey <tom@tromey.com>
11380
11381 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11382 (do_finish_initialization): New function. Use gdbpy_ref.
11383 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11384 do_finish_initialization.
11385
11386 2017-01-10 Tom Tromey <tom@tromey.com>
11387
11388 * python/py-param.c (get_set_value, get_show_value): Use
11389 gdbpy_enter, gdbpy_ref.
11390
11391 2017-01-10 Tom Tromey <tom@tromey.com>
11392
11393 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11394
11395 2017-01-10 Tom Tromey <tom@tromey.com>
11396
11397 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11398
11399 2017-01-10 Tom Tromey <tom@tromey.com>
11400
11401 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
11402 Use gdbpy_enter_varobj.
11403
11404 2017-01-10 Tom Tromey <tom@tromey.com>
11405
11406 * varobj.c (gdbpy_enter_varobj): New constructor.
11407 * python/python-internal.h (gdbpy_enter_varobj): New class.
11408 * python/py-varobj.c (py_varobj_get_iterator): Use
11409 gdbpy_enter_varobj.
11410
11411 2017-01-10 Tom Tromey <tom@tromey.com>
11412
11413 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
11414 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11415 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
11416 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
11417 unique_xmalloc_ptr.
11418 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
11419
11420 2017-01-10 Tom Tromey <tom@tromey.com>
11421
11422 * python/py-xmethods.c (invoke_match_method): Use
11423 gdbpy_ref.
11424
11425 2017-01-10 Tom Tromey <tom@tromey.com>
11426
11427 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
11428 gdbpy_enter, gdbpy_ref.
11429
11430 2017-01-10 Tom Tromey <tom@tromey.com>
11431
11432 * python/python.c (python_interactive_command): Use gdbpy_enter.
11433
11434 2017-01-10 Tom Tromey <tom@tromey.com>
11435
11436 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
11437 gdbpy_ref.
11438
11439 2017-01-10 Tom Tromey <tom@tromey.com>
11440
11441 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
11442 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11443
11444 2017-01-10 Tom Tromey <tom@tromey.com>
11445
11446 * utils.h (htab_deleter): New struct.
11447 (htab_up): New typedef.
11448 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
11449 gdbpy_enter, gdbpy_ref, htab_up.
11450
11451 2017-01-10 Tom Tromey <tom@tromey.com>
11452
11453 * python/py-unwind.c (pending_frame_invalidate): Remove.
11454 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
11455
11456 2017-01-10 Tom Tromey <tom@tromey.com>
11457
11458 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
11459 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
11460
11461 2017-01-10 Tom Tromey <tom@tromey.com>
11462
11463 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
11464
11465 2017-01-10 Tom Tromey <tom@tromey.com>
11466
11467 * python/python.c (gdbpy_eval_from_control_command)
11468 (gdbpy_source_script, gdbpy_run_events)
11469 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
11470 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
11471 gdbpy_enter.
11472
11473 2017-01-10 Tom Tromey <tom@tromey.com>
11474
11475 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
11476
11477 2017-01-10 Tom Tromey <tom@tromey.com>
11478
11479 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
11480
11481 2017-01-10 Tom Tromey <tom@tromey.com>
11482
11483 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
11484 (python_on_inferior_call_pre, python_on_inferior_call_post)
11485 (python_on_memory_change, python_on_register_change)
11486 (python_inferior_exit, python_new_objfile, add_thread_object)
11487 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
11488
11489 2017-01-10 Tom Tromey <tom@tromey.com>
11490
11491 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
11492 (bpfinishpy_handle_exit): Use gdbpy_enter.
11493
11494 2017-01-10 Tom Tromey <tom@tromey.com>
11495
11496 * python/py-cmd.c (cmdpy_destroyer)
11497 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
11498 gdbpy_enter.
11499
11500 2017-01-10 Tom Tromey <tom@tromey.com>
11501
11502 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11503 gdbpy_enter.
11504 (gdbpy_breakpoint_has_cond): Likewise.
11505
11506 2017-01-10 Tom Tromey <tom@tromey.com>
11507
11508 * python/python.c (gdbpy_enter): New constructor.
11509 (~gdbpy_enter): New destructor.
11510 (restore_python_env, ensure_python_env): Rewrite.
11511 * python/python-internal.h (gdbpy_enter): New class.
11512
11513 2017-01-10 Tom Tromey <tom@tromey.com>
11514
11515 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
11516
11517 2017-01-10 Tom Tromey <tom@tromey.com>
11518
11519 * python/py-value.c (value_has_field, get_field_flag)
11520 (get_field_type, valpy_getitem, convert_value_from_python): Use
11521 gdbpy_ref.
11522
11523 2017-01-10 Tom Tromey <tom@tromey.com>
11524
11525 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
11526 gdbpy_ref.
11527
11528 2017-01-10 Tom Tromey <tom@tromey.com>
11529
11530 * python/py-prettyprint.c (search_pp_list)
11531 (find_pretty_printer_from_objfiles)
11532 (find_pretty_printer_from_progspace)
11533 (find_pretty_printer_from_gdb, find_pretty_printer)
11534 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
11535 gdbpy_ref.
11536
11537 2017-01-10 Tom Tromey <tom@tromey.com>
11538
11539 * python/py-param.c (call_doc_function): Use gdbpy_ref.
11540
11541 2017-01-10 Tom Tromey <tom@tromey.com>
11542
11543 * python/py-linetable.c (build_line_table_tuple_from_pcs)
11544 (ltpy_get_all_source_lines): Use gdbpy_ref.
11545
11546 2017-01-10 Tom Tromey <tom@tromey.com>
11547
11548 * python/py-framefilter.c (extract_sym, extract_value)
11549 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
11550 gdbpy_ref.
11551
11552 2017-01-10 Tom Tromey <tom@tromey.com>
11553
11554 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
11555
11556 2017-01-10 Tom Tromey <tom@tromey.com>
11557
11558 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
11559
11560 2017-01-10 Tom Tromey <tom@tromey.com>
11561
11562 * python/py-function.c (convert_values_to_python, fnpy_init): Use
11563 gdbpy_ref.
11564
11565 2017-01-10 Tom Tromey <tom@tromey.com>
11566
11567 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
11568
11569 2017-01-10 Tom Tromey <tom@tromey.com>
11570
11571 * python/py-type.c (convert_field, make_fielditem, typy_fields)
11572 (typy_range): Use gdbpy_ref.
11573
11574 2017-01-10 Tom Tromey <tom@tromey.com>
11575
11576 * python/py-threadevent.c (create_thread_event_object): Use
11577 gdbpy_ref.
11578 * python/py-stopevent.c (create_stop_event_object): Simplify.
11579 (emit_stop_event): Use gdbpy_ref.
11580 * python/py-signalevent.c (create_signal_event_object): Use
11581 gdbpy_ref.
11582 * python/py-newobjfileevent.c (create_new_objfile_event_object)
11583 (emit_new_objfile_event, create_clear_objfiles_event_object)
11584 (emit_clear_objfiles_event): Use gdbpy_ref.
11585 * python/py-infevents.c (create_inferior_call_event_object)
11586 (create_register_changed_event_object)
11587 (create_memory_changed_event_object, emit_inferior_call_event)
11588 (emit_memory_changed_event, emit_register_changed_event): Use
11589 gdbpy_ref.
11590 * python/py-exitedevent.c (create_exited_event_object)
11591 (emit_exited_event): Use gdbpy_ref.
11592 * python/py-event.h (evpy_emit_event): Remove
11593 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
11594 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
11595 * python/py-continueevent.c (emit_continue_event): Use
11596 gdbpy_ref.
11597 * python/py-breakpoint.c (gdbpy_breakpoint_created)
11598 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
11599 gdbpy_ref.
11600 * python/py-bpevent.c (create_breakpoint_event_object): Use
11601 gdbpy_ref.
11602
11603 2017-01-10 Tom Tromey <tom@tromey.com>
11604
11605 * python/py-ref.h: New file.
11606
11607 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11608
11609 * cli-out.c (cli_ui_out::do_redirect): Change return type to
11610 void.
11611 * cli-out.h (cli_ui_out::do_redirect): Likewise.
11612 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
11613 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
11614 * ui-out.c (ui_out::redirect): Likewise.
11615 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
11616 * cli/cli-logging.c (set_logging_redirect): Update call site of
11617 ui_out::redirect.
11618 (handle_redirections): Likewise.
11619 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
11620 * top.c (execute_command_to_string): Likewise.
11621 * utils.c (do_ui_out_redirect_pop): Likewise.
11622
11623 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11624
11625 * stack.c (_initialize_stack): Update "frame" command help message.
11626
11627 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
11628
11629 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
11630
11631 2017-01-06 Yao Qi <yao.qi@linaro.org>
11632
11633 * x86-linux-nat.h: Include gdb_proc_service.h.
11634
11635 2017-01-06 Yao Qi <yao.qi@linaro.org>
11636
11637 * ser-base.h: Include serial.h.
11638
11639 2017-01-06 Yao Qi <yao.qi@linaro.org>
11640
11641 * ppc-linux-tdep.h: Include ppc-tdep.h.
11642
11643 2017-01-06 Yao Qi <yao.qi@linaro.org>
11644
11645 * nat/amd64-linux-siginfo.h: Include signal.h.
11646
11647 2017-01-06 Yao Qi <yao.qi@linaro.org>
11648
11649 * nat/aarch64-linux-hw-point.h: Include break-common.h.
11650
11651 2017-01-06 Yao Qi <yao.qi@linaro.org>
11652
11653 * mi/mi-parse.h: Include mi-cmds.h.
11654
11655 2017-01-06 Yao Qi <yao.qi@linaro.org>
11656
11657 * inf-loop.c: Don't include "target.h".
11658 * inf-loop.h: Include it here.
11659
11660 2017-01-06 Yao Qi <yao.qi@linaro.org>
11661
11662 * dfp.h: Include "dboulest.h" and "expression.h".
11663
11664 2017-01-06 Yao Qi <yao.qi@linaro.org>
11665
11666 * ax-gdb.h: Include "ax.h".
11667
11668 2017-01-06 Yao Qi <yao.qi@linaro.org>
11669
11670 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
11671 with nat/gdb_ptrace.h.
11672
11673 2017-01-05 Yao Qi <yao.qi@linaro.org>
11674
11675 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
11676 new line.
11677 (mips64_fbsd_sigframe_init): Likewise.
11678
11679 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11680
11681 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
11682 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
11683
11684 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11685
11686 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
11687 * NEWS: Mention new FreeBSD/mips native configuration.
11688 * config/mips/fbsd.mh: New file.
11689 * configure.host: Add mips*-*-freebsd*.
11690 * mips-fbsd-nat.c: New file.
11691
11692 2017-01-04 John Baldwin <jhb@FreeBSD.org>
11693
11694 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
11695 (ALLDEPFILES): Add mips-fbsd-tdep.c.
11696 * NEWS: Mention new FreeBSD/mips target.
11697 * configure.tgt: Add mips*-*-freebsd*.
11698 * mips-fbsd-tdep.c: New file.
11699 * mips-fbsd-tdep.h: New file.
11700
11701 2017-01-04 Yao Qi <yao.qi@linaro.org>
11702
11703 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
11704 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
11705
11706 2017-01-01 Joel Brobecker <brobecker@adacore.com>
11707
11708 Update copyright year range in all GDB files.
11709
11710 2017-01-01 Joel Brobecker <brobecker@adacore.com>
11711
11712 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
11713
11714 For older changes see ChangeLog-2016.
11715 \f
11716 Local Variables:
11717 mode: change-log
11718 left-margin: 8
11719 fill-column: 74
11720 version-control: never
11721 coding: utf-8
11722 End:
This page took 0.284118 seconds and 4 git commands to generate.