Constify some commands in printcmd.c
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
77763700
TT
12017-09-27 Tom Tromey <tom@tromey.com>
2
3 * printcmd.c (map_display_numbers, undisplay_command)
4 (enable_disable_display_command, enable_display_command)
5 (disable_display_command): Constify.
6
4495129a
TT
72017-09-27 Tom Tromey <tom@tromey.com>
8
9 * breakpoint.h (delete_command): Don't declare.
10 * breakpoint.c (delete_command, enable_once_command)
11 (enable_count_command, enable_delete_command, breakpoint_1)
12 (maintenance_info_breakpoints, stopin_command, stopat_command)
13 (delete_command, delete_trace_command, save_breakpoints)
14 (save_breakpoints_command, save_tracepoints_command): Constify.
15
3088cf40
TT
162017-09-27 Tom Tromey <tom@tromey.com>
17
18 * macrocmd.c (macro_expand_command, macro_expand_once_command)
19 (skip_ws, extract_identifier, macro_define_command)
20 (macro_undef_command, macro_list_command): Constify.
21
69f476a3
TT
222017-09-27 Tom Tromey <tom@tromey.com>
23
24 * infcmd.c (environment_info, set_environment_command)
25 (unset_environment_command, path_info, info_proc_cmd_1)
26 (info_proc_cmd_mappings, info_proc_cmd_stat)
27 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
28 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
29
c4a3e68e
TT
302017-09-27 Tom Tromey <tom@tromey.com>
31
32 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
33 Constify.
34
c9d31bd6
TT
352017-09-27 Tom Tromey <tom@tromey.com>
36
37 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
38
1f3f85eb
TT
392017-09-27 Tom Tromey <tom@tromey.com>
40
41 * demangle.c (demangle_command): Constify.
42
9c504b5d
TT
432017-09-27 Tom Tromey <tom@tromey.com>
44
45 * progspace.c (maintenance_info_program_spaces_command):
46 Constify.
47
6663cf91
TT
482017-09-27 Tom Tromey <tom@tromey.com>
49
50 * compile/compile.c (check_raw_argument, compile_file_command)
51 (compile_code_command, compile_print_command): Constify.
52
34e5fa26
TT
532017-09-27 Tom Tromey <tom@tromey.com>
54
55 * reggroups.c (maintenance_print_reggroups): Constify.
56
8384c356
TT
572017-09-27 Tom Tromey <tom@tromey.com>
58
59 * dwarf2read.c (save_gdb_index_command): Constify.
60
884beb0c
TT
612017-09-27 Tom Tromey <tom@tromey.com>
62
63 * stap-probe.c (info_probes_stap_command): Constify.
64
e0b2930c
TT
652017-09-27 Tom Tromey <tom@tromey.com>
66
67 * fork-child.c (unset_exec_wrapper_command): Constify.
68
f938677d
TT
692017-09-27 Tom Tromey <tom@tromey.com>
70
71 * btrace.c (get_uint, get_context_size, no_chunk)
72 (maint_btrace_packet_history_cmd)
73 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
74 (maint_info_btrace_cmd): Constify.
75
8949cb87
TT
762017-09-27 Tom Tromey <tom@tromey.com>
77
78 * reverse.c (delete_bookmark_command): Constify.
79
ac88e2de
TT
802017-09-27 Tom Tromey <tom@tromey.com>
81
82 * remote.c (set_memory_packet_size)
83 (set_memory_write_packet_size, show_memory_write_packet_size)
84 (set_memory_read_packet_size, show_memory_read_packet_size)
85 (compare_sections_command, packet_command, remote_put_command)
86 (remote_get_command, remote_delete_command): Constify.
87
bd4c9dfe
TT
882017-09-27 Tom Tromey <tom@tromey.com>
89
90 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
91 (set_mipsfpu_double_command, set_mipsfpu_none_command)
92 (set_mipsfpu_auto_command): Constify.
93
5e93d4c6
TT
942017-09-27 Tom Tromey <tom@tromey.com>
95
96 * cli/cli-cmds.h (cd_command): Constify.
97 * cli/cli-cmds.c (cd_command): Constify.
98
fc41a75b
TT
992017-09-27 Tom Tromey <tom@tromey.com>
100
101 * thread.c (thread_name_command, thread_find_command): Constify.
102
67810076
TT
1032017-09-27 Tom Tromey <tom@tromey.com>
104
105 * probe.c (enable_probes_command, disable_probes_command):
106 Constify.
107
1d8b34a7
TT
1082017-09-27 Tom Tromey <tom@tromey.com>
109
110 * symfile.c (symbol_file_command): Constify.
111 * gdbcore.h (deprecated_file_changed_hook): Constify.
112 * exec.c (deprecated_file_changed_hook, exec_file_command)
113 (file_command): Constify.
114 * defs.h (symbol_file_command): Constify.
115
442019e1
TT
1162017-09-27 Tom Tromey <tom@tromey.com>
117
118 * remote-fileio.c (set_system_call_allowed)
119 (show_system_call_allowed): Constify.
120
2983f7cb
TT
1212017-09-27 Tom Tromey <tom@tromey.com>
122
123 * tracepoint.c (delete_trace_variable_command)
124 (tfind_end_command, tfind_start_command, tfind_pc_command)
125 (tfind_tracepoint_command, tfind_line_command)
126 (tfind_range_command, tfind_outside_command): Constify.
127
4fd41b24
TT
1282017-09-27 Tom Tromey <tom@tromey.com>
129
130 * ax-gdb.c (maint_agent_printf_command, agent_command)
131 (agent_eval_command): Constify.
132
f2fc3015
TT
1332017-09-27 Tom Tromey <tom@tromey.com>
134
135 * tracepoint.c (info_scope_command): Constify.
136 * python/python.c (gdbpy_decode_line): Constify.
137 * python/py-breakpoint.c (bppy_init): Constify.
138 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
139 * location.h: (new_linespec_location)
140 (string_to_event_location_basic, string_to_event_location):
141 Constify.
142 * location.c (new_linespec_location)
143 (string_to_event_location_basic, string_to_event_location):
144 Constify.
145 * linespec.h (decode_line_with_current_source)
146 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
147 * linespec.c (linespec_lex_to_end)
148 (decode_line_with_current_source)
149 (decode_line_with_last_displayed): Constify.
150 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
151 Constify.
152 * cli/cli-cmds.c (edit_command, list_command): Constify.
153 * breakpoint.h (until_break_command, watch_command_wrapper)
154 (awatch_command_wrapper, rwatch_command_wrapper)
155 (init_ada_exception_breakpoint): Constify.
156 * breakpoint.c (break_command_1, dprintf_command)
157 (break_range_command, watch_command_wrapper)
158 (rwatch_command_wrapper, awatch_command_wrapper)
159 (until_break_command, init_ada_exception_breakpoint)
160 (strace_marker_create_sals_from_location, trace_command)
161 (ftrace_command, strace_command, struct tracepoint): Constify.
162 * ax-gdb.c (agent_command_1): Constify.
163 * ada-lang.c (ada_exception_sal): Constify.
164
8c2f95f4
TT
1652017-09-27 Tom Tromey <tom@tromey.com>
166
167 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
168 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
169 (get_context_size, no_chunk, get_insn_history_modifiers)
170 (cmd_record_insn_history, get_call_history_modifiers)
171 (cmd_record_call_history): Constify.
172
a0d65762
TT
1732017-09-27 Tom Tromey <tom@tromey.com>
174
175 * source.c (show_substitute_path_command)
176 (unset_substitute_path_command, set_substitute_path_command):
177 Constify.
178
58971144
TT
1792017-09-27 Tom Tromey <tom@tromey.com>
180
181 * typeprint.c (maintenance_print_type): Constify.
182 * maint.c (maintenance_dump_me, maintenance_demangle)
183 (maintenance_time_display, maintenance_info_sections)
184 (maintenance_print_statistics, maintenance_deprecate)
185 (maintenance_undeprecate): Constify.
186 (maintenance_do_deprecate): Constify. Use std::string.
187 (maintenance_selftest): Constify.
188 * gdbtypes.h (maintenance_print_type): Constify.
189
c482f52c
TT
1902017-09-27 Tom Tromey <tom@tromey.com>
191
192 * hppa-tdep.c (unwind_command): Constify.
193
e100df1a
TT
1942017-09-27 Tom Tromey <tom@tromey.com>
195
196 * target-descriptions.c (unset_tdesc_filename_cmd)
197 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
198 Constify.
199
31d56ade
TT
2002017-09-27 Tom Tromey <tom@tromey.com>
201
202 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
203
b961da0b
TT
2042017-09-27 Tom Tromey <tom@tromey.com>
205
206 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
207
e2d8ae16
TT
2082017-09-27 Tom Tromey <tom@tromey.com>
209
210 * tui/tui-regs.c (tui_reg_command): Constify.
211
863779b0
TT
2122017-09-27 Tom Tromey <tom@tromey.com>
213
214 * skip.c (skip_file_command, skip_function_command)
215 (skip_enable_command, skip_disable_command, skip_delete_command):
216 Constify.
217
cdb34d4a
TT
2182017-09-27 Tom Tromey <tom@tromey.com>
219
220 * record-btrace.c (cmd_record_btrace_bts_start)
221 (cmd_record_btrace_pt_start): Constify.
222
e99c83e7
TT
2232017-09-27 Tom Tromey <tom@tromey.com>
224
225 * symmisc.c (maintenance_print_symbols)
226 (maintenance_print_msymbols, maintenance_print_objfiles)
227 (maintenance_info_symtabs, maintenance_check_symtabs)
228 (maintenance_expand_symtabs, maintenance_info_line_tables):
229 Constify.
230
32faf971
TT
2312017-09-27 Tom Tromey <tom@tromey.com>
232
233 * top.c (new_ui_command): Constify.
234
2cf311eb
TT
2352017-09-27 Tom Tromey <tom@tromey.com>
236
237 * symfile.c (add_symbol_file_command)
238 (remove_symbol_file_command, list_overlays_command)
239 (map_overlay_command, unmap_overlay_command)
240 (overlay_auto_command, overlay_manual_command)
241 (overlay_off_command, overlay_load_command): Constify.
242
e6738699
TT
2432017-09-27 Tom Tromey <tom@tromey.com>
244
245 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
246 (info_spu_mailbox_command, info_spu_dma_command)
247 (info_spu_proxydma_command): Constify.
248
aa360cd5
TT
2492017-09-27 Tom Tromey <tom@tromey.com>
250
251 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
252
898241a5
TT
2532017-09-27 Tom Tromey <tom@tromey.com>
254
255 * cli/cli-script.c (user_defined_command): Constify.
256
2d0ac106
TT
2572017-09-27 Tom Tromey <tom@tromey.com>
258
259 * cli/cli-dump.c (dump_memory_command, dump_value_command)
260 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
261 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
262 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
263 (dump_binary_value, append_binary_memory, append_binary_value):
264 Constify.
265 (struct dump_context) <func>: Constify.
266 (add_dump_command): Update.
267
dede02ce
TT
2682017-09-27 Tom Tromey <tom@tromey.com>
269
270 * cli/cli-cmds.c (show_version, show_configuration)
271 (source_command, show_user): Constify.
272
d3cb6b99
TT
2732017-09-27 Tom Tromey <tom@tromey.com>
274
275 * target.c (maintenance_print_target_stack): Constify.
276
1970a12f
TT
2772017-09-27 Tom Tromey <tom@tromey.com>
278
279 * interps.c (interpreter_exec_cmd): Constify.
280
41243651
TT
2812017-09-27 Tom Tromey <tom@tromey.com>
282
283 * record-full.c (cmd_record_full_restore): Constify.
284
4465d9db
TT
2852017-09-27 Tom Tromey <tom@tromey.com>
286
287 * memattr.c (enable_mem_command, disable_mem_command)
288 (delete_mem_command): Constify.
289
ad25e423
TT
2902017-09-27 Tom Tromey <tom@tromey.com>
291
292 * value.c (show_convenience): Constify.
293
d64097b1
TT
2942017-09-27 Tom Tromey <tom@tromey.com>
295
296 * gdbcore.h (core_file_command): Update.
297 * corefile.c (core_file_command): Constify.
298
4d4589ef
TT
2992017-09-27 Tom Tromey <tom@tromey.com>
300
301 * user-regs.c (maintenance_print_user_registers): Constify.
302
32a7bf17
TT
3032017-09-27 Tom Tromey <tom@tromey.com>
304
305 * cp-namespace.c (maintenance_cplus_namespace): Constify.
306
4a475551
TT
3072017-09-27 Tom Tromey <tom@tromey.com>
308
309 * cp-support.c (first_component_command): Constify.
310
990b9f9f
TT
3112017-09-27 Tom Tromey <tom@tromey.com>
312
313 * psymtab.c (maintenance_print_psymbols)
314 (maintenance_info_psymtabs, maintenance_check_psymtabs):
315 Constify.
316
c281872e
TT
3172017-09-27 Tom Tromey <tom@tromey.com>
318
319 * windows-tdep.c (display_tib): Constify.
320
5b64bf74
TT
3212017-09-27 Tom Tromey <tom@tromey.com>
322
323 * linux-fork.c (delete_checkpoint_command)
324 (detach_checkpoint_command): Constify.
325
4ada038f
TT
3262017-09-27 Tom Tromey <tom@tromey.com>
327
328 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
329
57f5a81b
TT
3302017-09-27 Tom Tromey <tom@tromey.com>
331
332 * arc-tdep.c (dump_arc_instruction_command): Constify.
333
b0a8e6c4
TT
3342017-09-27 Tom Tromey <tom@tromey.com>
335
336 * valprint.c (set_radix, show_radix): Constify.
337
8d97dc1c
TT
3382017-09-27 Tom Tromey <tom@tromey.com>
339
340 * dtrace-probe.c (info_probes_dtrace_command): Constify.
341
eb7c454d
TT
3422017-09-27 Tom Tromey <tom@tromey.com>
343
344 * command.h (not_just_help_class_command): Update.
345 * cli/cli-decode.h (not_just_help_class_command): Update.
346 * cli/cli-decode.c (not_just_help_class_command): Constify.
347
e4e33335
TT
3482017-09-27 Tom Tromey <tom@tromey.com>
349
350 * gdb_bfd.c (maintenance_info_bfds): Constify.
351
0450cc4c
TT
3522017-09-27 Tom Tromey <tom@tromey.com>
353
354 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
355 overloads.
356 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
357 (do_const_cfunc): New function.
358 (cmd_cfunc_eq): New overload.
359 (cli_user_command_p): Check do_const_cfunc.
360 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
361 const_cfunc.
362 * command.h (add_cmd): Add const overload and no-function
363 overload.
364 (set_cmd_cfunc): Add const overload.
365 (cmd_const_cfunc_ftype): Declare.
366 (cmd_cfunc_eq): Add const overload.
367 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
368 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
369 overload.
370
a9bbfbd8
TT
3712017-09-27 Tom Tromey <tom@tromey.com>
372
373 * macroexp.c (get_next_token_for_substitution): New function.
374 (substitute_args): Call it. Check for __VA_OPT__.
375
5230b05a
WT
3762017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
377 Pedro Alves <palves@redhat.com>
378
379 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
380 producer_is_icc_lt_14.
381 (producer_is_icc_lt_14): New function.
382 (check_producer): Add code for checking version of ICC.
383 (producer_is_icc): Move to producer.c.
384 (read_structure_type): Restrict ICC workaround to ICC<14.
385 * producer.c: Include selftest.h.
386 (producer_is_icc, producer_parsing_tests, _initialize_producer):
387 New functions.
388 * producer.h (producer_is_icc): New declaration.
389
b32b108a
WT
3902017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
391
392 * Makefile.in (SFILES): Add producer.c.
393 (COMMON_OBS): Add producer.o
394 * amd64-tdep.c (producer.h): Add new include.
395 * dwarf2read.c (producer.h): Add new include.
396 * producer.c: New file.
397 * producer.h: New file.
398 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
399 producer.c.
400 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
401 producer.h.
402
5007d765
MK
4032017-09-26 Matthias Klose <doko@ubuntu.com>
404
405 * configure.ac: Search ncursesw before ncurses.
406 Check ncursesw/ncurses.h before ncurses/ncurses.h.
407 * gdb_curses.h: Include <ncursesw/ncurses.h>
408 * config.in, configure: Regenerate.
409
281c4447
RO
4102017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
411
412 PR gdb/22185
413 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
414 obsolete.
415 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
416 Remove i386sol2 support.
417 * configure.nat <i386sol2>: Remove.
418 <sol2-64>: Fold into ...
419 <sol2>: ... this.
420 Move common settings to default section.
421 Add sol-thread.o.
422 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
423 x86_64-*-solaris2.1[0-9]*>: Rename to ...
424 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
425 <i[34567]86-*-solaris*>: Remove.
426 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
427
428 * configure.ac: Remove wctype in libw check.
429 (_MSE_INT_H): Don't define on Solaris 7-9.
430 <solaris*>: Remove libthread_db.so.1 check.
431 * configure: Regenerate.
432 * config.in: Regenerate.
433
434 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
435 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
436 (gdb_ps_size_t): Remove.
437 Use base types in users.
438 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
439
440 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
441
39b06c20
RO
4422017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
443
444 PR build/22206
445 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
446 (adi_is_addr_mapped): Likewise.
447 (PSR_ICC): Don't redefine.
448 (PSR_IMPL): Likewise.
449
6c3e20f1
TT
4502017-09-25 Tom Tromey <tom@tromey.com>
451
452 * regcache.c (regcache::dump): Use string_printf.
453
b292235f
TT
4542017-09-25 Tom Tromey <tom@tromey.com>
455
456 * regcache.c (class regcache_invalidator): New.
457 (struct register_to_invalidate): Remove.
458 (make_cleanup_regcache_invalidate): Remove.
459 (regcache::raw_write): Use regcache_invalidator.
460
9ac86b52
TT
4612017-09-25 Tom Tromey <tom@tromey.com>
462
463 * spu-tdep.c (spu2ppu_sniffer): Update.
464 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
465 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
466 Remove.
467 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
468 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
469 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
470 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
471 (frame_pop): Update.
472
c0e383c6
TT
4732017-09-25 Tom Tromey <tom@tromey.com>
474
475 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
476 * regcache.h (regcache_xfree): Don't declare.
477 * regcache.c (regcache_xfree): Remove.
478 (do_regcache_xfree): Use delete.
479 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
480 * linux-fork.c (free_fork): Use delete.
481 (fork_save_infrun_state): Likewise.
482 * jit.c (jit_dealloc_cache): Use delete.
483 * infrun.c (discard_infcall_suspend_state): Use delete.
484
791199cc
TT
4852017-09-25 Tom Tromey <tom@tromey.com>
486
487 * regcache.h (regcache_xmalloc): Don't declare.
488 (regcache_raw_set_cached_value): Update comment.
489 * regcache.c (regcache_xmalloc): Remove.
490 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
491 * jit.c (jit_frame_sniffer): Use new.
492 * frame.c (frame_save_as_regcache): Use new.
493
289e23aa
AA
4942017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
495
496 * NEWS: Advertise support for guarded-storage registers on IBM z.
497
1b63490c
AA
4982017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
499
500 * s390-linux-nat.c (have_regset_gs): New static variable.
501 (s390_linux_fetch_inferior_registers): Handle guarded-storage
502 control block and guarded-storage broadcast control regsets.
503 (s390_read_description): Detect whether the target has
504 guarded-storage support, return appropriate tdesc.
505 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
506 (features/s390x-gs-linux64.c): Likewise.
507 (struct gdbarch_tdep) <have_gs>: New field.
508 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
509 (s390_gsbc_regset): New variables.
510 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
511 and s390_gsbc_regset, if applicable.
512 (s390_core_read_description): Check whether core file was from a
513 target with guarded-storage support; include appropriate regsets.
514 (s390_gdbarch_init): Add registers for guarded-storage support.
515 (_initialize_s390_tdep): Initialize new target descriptions that
516 include registers for guarded-storage support.
517 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
518 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
519 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
520 (S390_NUM_REGS): Adjust macro definition.
521 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
522 (tdesc_s390x_gs_linux64): New declarations.
523
96235dc1
AA
5242017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
525
526 * features/s390-gs-linux64.xml: New file.
527 * features/s390-gs.xml: New file.
528 * features/s390-gsbc.xml: New file.
529 * features/s390x-gs-linux64.xml: New file.
530 * features/Makefile (WHICH): Add s390-gs-linux64 and
531 s390x-gs-linux64.
532 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
533 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
534 * features/s390-gs-linux64.c: New generated file.
535 * features/s390x-gs-linux64.c: New file.
536 * regformats/s390-gs-linux64.dat: New file.
537 * regformats/s390x-gs-linux64.dat: New file.
538
b4a7c699
TT
5392017-09-23 Tom Tromey <tom@tromey.com>
540
541 * defs.h (make_cleanup_override_quit_handler): Don't declare.
542
c2f97536
TT
5432017-09-22 Tom Tromey <tom@tromey.com>
544
545 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
546 type to scoped_restore_tmpl.
547 <scoped_input_handler>: Initialize m_quit_handler directly.
548
43573013
SDJ
5492017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
550
551 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
552 (cd_command): Likewise. Free "current_directory" before
553 assigning to it.
554 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
555 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
556 * top.c (gdb_dirbuf): Remove global declaration.
557 * top.h (gdb_dirbuf): Likewise.
558
6ec2e0f5
SDJ
5592017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
560
561 * gnulib/aclocal.m4: Regenerate.
562 * gnulib/config.in: Regenerate.
563 * gnulib/configure: Regenerate.
564 * gnulib/import/Makefile.am: Regenerate.
565 * gnulib/import/Makefile.in: Regenerate.
566 * gnulib/import/assure.h: New file.
567 * gnulib/import/at-func.c: Likewise
568 * gnulib/import/chdir-long.c: New file.
569 * gnulib/import/chdir-long.h: New file.
570 * gnulib/import/cloexec.c: New file.
571 * gnulib/import/cloexec.h: New file.
572 * gnulib/import/close.c: New file.
573 * gnulib/import/closedir.c: New file.
574 * gnulib/import/dirent-private.h: New file.
575 * gnulib/import/dup-safer.c: New file.
576 * gnulib/import/dup.c: New file.
577 * gnulib/import/dup2.c: New file.
578 * gnulib/import/error.c: New file.
579 * gnulib/import/error.h: New file.
580 * gnulib/import/exitfail.c: New file.
581 * gnulib/import/exitfail.h: New file.
582 * gnulib/import/fchdir.c: New file.
583 * gnulib/import/fcntl.c: New file.
584 * gnulib/import/fcntl.in.h: New file.
585 * gnulib/import/fd-hook.c: New file.
586 * gnulib/import/fd-hook.h: New file.
587 * gnulib/import/fd-safer.c: New file.
588 * gnulib/import/fdopendir.c: New file.
589 * gnulib/import/filename.h: New file.
590 * gnulib/import/filenamecat-lgpl.c: New file.
591 * gnulib/import/filenamecat.h: New file.
592 * gnulib/import/fstat.c: New file.
593 * gnulib/import/fstatat.c: New file.
594 * gnulib/import/getcwd-lgpl.c: New file.
595 * gnulib/import/getcwd.c: New file.
596 * gnulib/import/getdtablesize.c: New file.
597 * gnulib/import/getlogin_r.c: New file.
598 * gnulib/import/getprogname.c: New file.
599 * gnulib/import/getprogname.h: New file.
600 * gnulib/import/gettext.h: New file.
601 * gnulib/import/glob-libc.h: New file.
602 * gnulib/import/glob.c: New file.
603 * gnulib/import/glob.in.h: New file.
604 * gnulib/import/intprops.h: New file.
605 * gnulib/import/m4/chdir-long.m4: New file.
606 * gnulib/import/m4/close.m4: New file.
607 * gnulib/import/m4/closedir.m4: New file.
608 * gnulib/import/m4/d-ino.m4: New file.
609 * gnulib/import/m4/d-type.m4: New file.
610 * gnulib/import/m4/dup.m4: New file.
611 * gnulib/import/m4/dup2.m4: New file.
612 * gnulib/import/m4/error.m4: New file.
613 * gnulib/import/m4/fchdir.m4: New file.
614 * gnulib/import/m4/fcntl.m4: New file.
615 * gnulib/import/m4/fcntl_h.m4: New file.
616 * gnulib/import/m4/fdopendir.m4: New file.
617 * gnulib/import/m4/filenamecat.m4: New file.
618 * gnulib/import/m4/fstat.m4: New file.
619 * gnulib/import/m4/fstatat.m4: New file.
620 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
621 * gnulib/import/m4/getcwd-path-max.m4: New file.
622 * gnulib/import/m4/getcwd.m4: New file.
623 * gnulib/import/m4/getdtablesize.m4: New file.
624 * gnulib/import/m4/getlogin_r.m4: New file.
625 * gnulib/import/m4/getprogname.m4: New file.
626 * gnulib/import/m4/glob.m4: New file.
627 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
628 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
629 * gnulib/import/m4/mempcpy.m4: New file.
630 * gnulib/import/m4/memrchr.m4: New file.
631 * gnulib/import/m4/mode_t.m4: New file.
632 * gnulib/import/m4/msvc-inval.m4: New file.
633 * gnulib/import/m4/msvc-nothrow.m4: New file.
634 * gnulib/import/m4/open.m4: New file.
635 * gnulib/import/m4/openat.m4: New file.
636 * gnulib/import/m4/opendir.m4: New file.
637 * gnulib/import/m4/readdir.m4: New file.
638 * gnulib/import/m4/realloc.m4: New file.
639 * gnulib/import/m4/rewinddir.m4: New file.
640 * gnulib/import/m4/save-cwd.m4: New file.
641 * gnulib/import/m4/strdup.m4: New file.
642 * gnulib/import/m4/strerror.m4: New file.
643 * gnulib/import/m4/unistd-safer.m4: New file.
644 * gnulib/import/mempcpy.c: New file.
645 * gnulib/import/memrchr.c: New file.
646 * gnulib/import/msvc-inval.c: New file.
647 * gnulib/import/msvc-inval.h: New file.
648 * gnulib/import/msvc-nothrow.c: New file.
649 * gnulib/import/msvc-nothrow.h: New file.
650 * gnulib/import/open.c: New file.
651 * gnulib/import/openat-die.c: New file.
652 * gnulib/import/openat-priv.h: New file.
653 * gnulib/import/openat-proc.c: New file.
654 * gnulib/import/openat.c: New file.
655 * gnulib/import/openat.h: New file.
656 * gnulib/import/opendir.c: New file.
657 * gnulib/import/pipe-safer.c: New file.
658 * gnulib/import/readdir.c: New file.
659 * gnulib/import/realloc.c: New file.
660 * gnulib/import/rewinddir.c: New file.
661 * gnulib/import/save-cwd.c: New file.
662 * gnulib/import/save-cwd.h: New file.
663 * gnulib/import/strdup.c: New file.
664 * gnulib/import/strerror-override.c: New file.
665 * gnulib/import/strerror-override.h: New file.
666 * gnulib/import/strerror.c: New file.
667 * gnulib/import/unistd--.h: New file.
668 * gnulib/import/unistd-safer.h: New file.
669 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
670 "getcwd" and "glob".
671 * ser-tcp.c: Undefine "close" before redefining it.
672
432ae719
SM
6732017-09-21 Simon Marchi <simon.marchi@ericsson.com>
674
675 * guile/scm-value.c (gdbscm_value_address): Initialize address,
676 get rid of res_val.
677
4fa7574e
RO
6782017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
679
680 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
681 <sol2,sparc>: Likewise.
682 <sol2-64,i386>: Likewise.
683
684 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
685 -Wdeprecated-declarations on *-*-solaris*.
686 * configure: Regenerate.
687
688 * procfs.c: Include "nat/inferior.h".
689 (procfs_info_proc): Fix typo.
690
f6327dcb
KB
6912017-09-21 Kevin Buettner <kevinb@redhat.com>
692
693 * remote.c (vector): Include.
694 (struct private_thread_info): Add field, thread_handle.
695 (free_private_thread_info): Deallocate storage associated with
696 thread handle.
697 (get_private_info_thread): Initialize `thread_handle' field.
698 (struct thread_item): Add field, thread_handle.
699 (clear_threads_listing_context): Deallocate storage associated
700 with thread handle.
701 (start_thread): Add support for "handle" attribute.
702 (thread_attributes): Add "handle".
703 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
704 field.
705 (remote_update_thread_list): Update thread_handle.
706 (remote_thread_handle_to_thread_info): New function.
707 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
708
fbbe5337
KB
7092017-09-21 Kevin Buettner <kevinb@redhat.com>
710
711 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
712 function.
713 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
714 * python/python-internal.h (thread_object_type): Declare.
715
e04ee09e
KB
7162017-09-21 Kevin Buettner <kevinb@redhat.com>
717
718 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
719 (target_thread_handle_to_thread_info): Declare.
720 * target.c (target_thread_handle_to_thread_info): New function.
721 * target-delegates.c: Regenerate.
722 * gdbthread.h (find_thread_by_handle): Declare.
723 * thread.c (find_thread_by_handle): New function.
724 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
725 function.
726 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
727
1e5b66ed
SM
7282017-09-21 Simon Marchi <simon.marchi@ericsson.com>
729
730 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
731
ebe48ba0
SM
7322017-09-21 Simon Marchi <simon.marchi@ericsson.com>
733
734 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
735
0a0bf5dc
YQ
7362017-09-21 Yao Qi <yao.qi@linaro.org>
737
738 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
739 to gdb_target_obs.
740
d1b0a7bf
TT
7412017-09-20 Tom Tromey <tom@tromey.com>
742
743 * breakpoint.c (struct counted_command_line): Remove.
744 (breakpoint_commands): Update.
745 (alloc_counted_command_line, incref_counted_command_line)
746 (decref_counted_command_line, do_cleanup_counted_command_line)
747 (make_cleanup_decref_counted_command_line): Remove.
748 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
749 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
750 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
751 (save_breakpoints): Update.
752 * breakpoint.h (counted_command_line): Now a typedef to
753 shared_ptr.
754 (struct breakpoint) <commands>: Now a counted_command_line.
755 (struct bpstats) <command>: Likewise.
756
48649e1b
TT
7572017-09-20 Tom Tromey <tom@tromey.com>
758
759 * breakpoint.c (struct commands_info, do_map_commands_command):
760 Remove.
761 (commands_command_1): Update.
762 (iterate_over_related_breakpoints): Take a function_view.
763 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
764 (delete_command): Update.
765 (map_breakpoint_numbers): Take a function_view.
766 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
767 (disable_command): Update.
768 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
769 (enable_command): Update.
770 (struct disp_data, do_enable_breakpoint_disp)
771 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
772 (do_map_enable_delete_breakpoint): Remove.
773 (enable_once_command, enable_count_command, enable_delete_command)
774 (delete_trace_variable_command): Update.
775
04afa70c
TT
7762017-09-20 Tom Tromey <tom@tromey.com>
777
778 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
779 (bpstat_clear): Use delete.
780 (bpstats): New constructors.
781 (bpstat_copy, bpstat_stop_status): Use new.
782 (dprintf_after_condition_true): Update.
783 * breakpoint.h (bpstats::bpstats): Add constructors.
784 (bpstats::~bpstats): Add destructor.
785
c83833f4
PA
7862017-09-20 Pedro Alves <palves@redhat.com>
787
788 * eval.c (make_params): Delete, refactored as ...
789 (class fake_method): ... this new type's ctor.
790 (fake_method::~fake_method): New.
791 (evaluate_subexp_standard): Use 'fake_method'.
792
223ffa71
TT
7932017-09-20 Tom Tromey <tom@tromey.com>
794
795 * windows-nat.c (get_windows_debug_event, windows_wait)
796 (do_initial_windows_stuff, windows_attach): Update.
797 * utils.c (vwarning, internal_vproblem): Update.
798 (ui_unregister_input_event_handler_cleanup)
799 (prepare_to_handle_input): Remove.
800 (class scoped_input_handler): New.
801 (defaulted_query, prompt_for_continue): Update.
802 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
803 Update.
804 * top.c (undo_terminal_modifications_before_exit): Update.
805 * target/target.h (target_terminal_init, target_terminal_inferior)
806 (target_terminal_ours): Don't declare.
807 (class target_terminal): New.
808 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
809 (target_terminal_ours_for_output)
810 (make_cleanup_restore_target_terminal): Don't declare.
811 (target_terminal_info): Remove.
812 * target.c (enum terminal_state, terminal_state): Remove.
813 (target_terminal::terminal_state): Define.
814 (target_terminal::init): Rename from target_terminal_init.
815 (target_terminal::inferior): Rename from
816 target_terminal_inferior.
817 (target_terminal::ours): Rename from target_terminal_ours.
818 (target_terminal::ours_for_output): Rename from
819 target_terminal_ours_for_output.
820 (target_terminal::info): New method.
821 (cleanup_restore_target_terminal)
822 (make_cleanup_restore_target_terminal): Remove.
823 * solib.c (handle_solib_event): Update.
824 * remote.c (remote_serial_quit_handler): Update.
825 (remote_terminal_inferior, remote_wait_as): Update.
826 * record-full.c (record_full_wait_1): Update.
827 * nto-procfs.c (procfs_create_inferior): Update.
828 * nat/fork-inferior.c (startup_inferior): Update.
829 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
830 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
831 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
832 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
833 (mi_breakpoint_created, mi_breakpoint_deleted)
834 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
835 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
836 (mi_user_selected_context_changed, report_initial_inferior):
837 Update.
838 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
839 (linux_nat_terminal_inferior): Update.
840 * infrun.c (follow_fork_inferior)
841 (handle_vfork_child_exec_or_exit, do_target_resume)
842 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
843 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
844 Update.
845 * inflow.c (child_terminal_init, info_terminal_command): Update.
846 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
847 (attach_command): Update.
848 * infcall.c (call_thread_fsm_should_stop): Update.
849 * gnu-nat.c (gnu_attach): Update.
850 * extension.c (struct active_ext_lang_state)
851 (restore_active_ext_lang): Update.
852 * exceptions.c (print_flush): Update.
853 * event-top.c (async_enable_stdin, default_quit_handler): Update.
854 (struct quit_handler_cleanup_data, restore_quit_handler)
855 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
856 Remove.
857 * cp-support.c (gdb_demangle): Update.
858 * breakpoint.c (update_inserted_breakpoint_locations)
859 (insert_breakpoint_locations, handle_jit_event)
860 (disable_breakpoints_in_unloaded_shlib): Update.
861 * annotate.c (annotate_breakpoints_invalid)
862 (annotate_frames_invalid): Update.
863
013af3fc
TT
8642017-09-20 Tom Tromey <tom@tromey.com>
865
866 * main.c (catch_command_errors): Rename from
867 catch_command_errors_const.
868 (captured_main_1): Update.
869
06871ae8
PA
8702017-09-20 Pedro Alves <palves@redhat.com>
871
872 * cli/cli-cmds.c (list_command): Use print_sal_location.
873 (print_sal_location): New function.
874 (ambiguous_line_spec): Use print_sal_location.
875 * linespec.c (symbol_to_sal): Record the symbol in the sal.
876 * symtab.c (find_function_start_sal): Likewise.
877 * symtab.h (symtab_and_line::symbol): New field.
878
e5f25bc5
PA
8792017-09-20 Pedro Alves <palves@redhat.com>
880
881 * linespec.c (minsym_found): Handle non-text minsyms.
882 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
883
1b7fa39e
WT
8842017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
885
886 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
887 backslash.
888
37dd0825
WT
8892017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
890
891 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
892 vmovups instead vmovaps.
893 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
894
4e5a4f58
JB
8952017-09-19 John Baldwin <jhb@FreeBSD.org>
896
897 * NEWS (Changes since GDB 8.0): Add starti.
898 * infcmd.c (enum run_break): New.
899 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
900 case.
901 (run_command): Use enum run_how.
902 (start_command): Likewise.
903 (starti_command): New function.
904 (RUN_ARGS_HELP): New macro.
905 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
906 commands. Add starti command.
907
aa70c9f1
YQ
9082017-09-19 Yao Qi <yao.qi@linaro.org>
909
910 * Makefile.in (monitor.o): Remove the rule.
911
d6541620
YQ
9122017-09-19 Yao Qi <yao.qi@linaro.org>
913
914 * annotate.h (struct annotate_arg_emitter): Use
915 DISABLE_COPY_AND_ASSIGN.
916 * common/refcounted-object.h (refcounted_object): Likewise.
917 * completer.h (struct completion_result): Likewise.
918 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
919 * filename-seen-cache.h (filename_seen_cache): Likewise.
920 * gdbcore.h (thread_section_name): Likewise.
921 * gdb_regex.h (compiled_regex): Likewise.
922 * gdbthread.h (scoped_restore_current_thread): Likewise.
923 * inferior.h (scoped_restore_current_inferior): Likewise.
924 * jit.c (jit_reader): Likewise.
925 * linespec.h (struct linespec_result): Likewise.
926 * mi/mi-parse.h (struct mi_parse): Likewise.
927 * nat/fork-inferior.c (execv_argv): Likewise.
928 * progspace.h (scoped_restore_current_program_space): Likewise.
929 * python/python-internal.h (class gdbpy_enter): Likewise.
930 * regcache.h (regcache): Likewise.
931 * target-descriptions.c (struct tdesc_reg): Likewise.
932 (struct tdesc_type): Likewise.
933 (struct tdesc_feature): Likewise.
934 * ui-out.h (ui_out_emit_type): Likewise.
935
0615127c
SM
9362017-09-18 Simon Marchi <simon.marchi@ericsson.com>
937
938 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
939 label abort_expression.
940
5e187554
SM
9412017-09-16 Simon Marchi <simon.marchi@ericsson.com>
942
943 * common/buffer.c (buffer_xml_printf): Adjust.
944 * common/xml-utils.c (xml_escape_text): Change return type to
945 std::string, update code accordingly.
946 * common/xml-utils.h (xml_escape_text): Change return type to
947 std::string.
948 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
949 * windows-tdep.c (windows_xfer_shared_library): Adjust.
950 * unittests/xml-utils-selftests.c (test_xml_escape_text):
951 Adjust.
952
c3d7b541
SM
9532017-09-16 Simon Marchi <simon.marchi@ericsson.com>
954
955 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
956 (SUBDIR_UNITTESTS_OBS): Add new object file.
957 * unittests/xml-utils-selftests.c: New file.
958
1526853e
SM
9592017-09-16 Simon Marchi <simon.marchi@ericsson.com>
960
961 * common/selftest.h (selftest): New struct/interface.
962 (register_test): Add name parameter, add new overload.
963 (run_tests): Add filter parameter.
964 (for_each_selftest_ftype): New typedef.
965 (for_each_selftest): New declaration.
966 * common/selftest.c (tests): Change type to
967 map<string, unique_ptr<selftest>>.
968 (simple_selftest): New struct.
969 (register_test): New function.
970 (register_test): Add name parameter and use it.
971 (run_tests): Add filter parameter and use it. Add prints.
972 Adjust to vector -> map change.
973 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
974 registering selftests.
975 * arm-tdep.c (_initialize_arm_tdep): Likewise.
976 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
977 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
978 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
979 * findvar.c (_initialize_findvar): Likewise.
980 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
981 * maint.c (maintenance_selftest): Update call to run_tests.
982 (maintenance_info_selftests): New function.
983 (_initialize_maint_cmds): Register "maintenance info selftests"
984 command. Update "maintenance selftest" doc.
985 * regcache.c (_initialize_regcache): Add names when registering
986 selftests.
987 * rust-exp.y (_initialize_rust_exp): Likewise.
988 * selftest-arch.c (gdbarch_selftest): New struct.
989 (gdbarch_tests): Remove.
990 (register_test_foreach_arch): Add name parameter. Call
991 register_test.
992 (tests_with_arch): Remove, move most content to
993 gdbarch_selftest::operator().
994 (_initialize_selftests_foreach_arch): Remove.
995 * selftest-arch.h (register_test_foreach_arch): Add name
996 parameter.
997 (run_tests_with_arch): New declaration.
998 * utils-selftests.c (_initialize_utils_selftests): Add names
999 when registering selftests.
1000 * utils.c (_initialize_utils): Likewise.
1001 * unittests/array-view-selftests.c
1002 (_initialize_array_view_selftests): Likewise.
1003 * unittests/environ-selftests.c (_initialize_environ_selftests):
1004 Likewise.
1005 * unittests/function-view-selftests.c
1006 (_initialize_function_view_selftests): Likewise.
1007 * unittests/offset-type-selftests.c
1008 (_initialize_offset_type_selftests): Likewise.
1009 * unittests/optional-selftests.c
1010 (_initialize_optional_selftests): Likewise.
1011 * unittests/scoped_restore-selftests.c
1012 (_initialize_scoped_restore_selftests): Likewise.
1013 * NEWS: Document "maintenance selftest" and "maint info
1014 selftests".
1015
5846367a
SM
10162017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1017
1018 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
1019 scoped_restore.
1020
bd77e8ff
SM
10212017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1022
1023 * mi/mi-main.c (mi_load_progress): Make uiout variable
1024 a unique_ptr.
1025
26a67918
PA
10262017-09-15 Pedro Alves <palves@redhat.com>
1027
1028 * compile/compile-c-types.c (convert_enum, convert_int)
1029 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
1030
3f8a7804
SM
10312017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1032
1033 * dwarf2read.c (copy_string): Remove.
1034 (parse_macro_definition): Replace copy_string with savestring.
1035
8d200706
YQ
10362017-09-15 Yao Qi <yao.qi@linaro.org>
1037
1038 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
1039 gdb_target_obs.
1040 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
1041 Likewise.
1042 (i[34567]86-*-linux*): Likewise.
1043
d185219d
SM
10442017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1045
1046 * dwarf2expr.h (dwarf_stack_value): Add constructor.
1047 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
1048 <stack>: Change type to std::vector.
1049 <stack_len, stack_allocated>: Remove.
1050 <grow_stack>: Remove.
1051 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1052 (dwarf_expr_context::~dwarf_expr_context): Remove.
1053 (dwarf_expr_context::grow_stack): Remove.
1054 (dwarf_expr_context::push): Adjust.
1055 (dwarf_expr_context::pop): Adjust.
1056 (dwarf_expr_context::fetch): Adjust.
1057 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
1058 (dwarf_expr_context::stack_empty_p): Adjust.
1059 (dwarf_expr_context::execute_stack_op): Adjust.
1060
eccd80d6
SM
10612017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1062
1063 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
1064 return type to bool.
1065 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
1066
69009882
SM
10672017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1068
1069 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
1070 Change type to bool.
1071 (dwarf_stack_value) <in_stack_memory>: Likewise.
1072 (dwarf_expr_context) <push_address>: Change parameter type to
1073 bool.
1074 <fetch_in_stack_memory>: Change return type to bool.
1075 <push>: Change parameter type to bool.
1076 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
1077 to bool.
1078 (dwarf_expr_context::push_address): Likewise.
1079 (dwarf_expr_context::fetch_in_stack_memory): Change return type
1080 to bool.
1081 (dwarf_expr_context::execute_stack_op): Adjust.
1082 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
1083
1e467161
SM
10842017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1085
1086 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
1087 (struct dwarf_expr_context) <n_pieces>: Remove.
1088 <pieces>: Change type to std::vector.
1089 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1090 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
1091 pieces.
1092 (dwarf_expr_context::add_piece): Adjust.
1093 * dwarf2loc.c (struct piece_closure): Initialize fields.
1094 <n_pieces>: Remove.
1095 <pieces>: Change type to std::vector.
1096 (allocate_piece_closure): Adjust, change parameter to
1097 std::vector rvalue and std::move it to piece_closure.
1098 (rw_pieced_value): Adjust.
1099 (check_pieced_synthetic_pointer): Adjust.
1100 (indirect_synthetic_pointer): Adjust.
1101 (coerce_pieced_ref): Adjust.
1102 (free_pieced_value_closure): Adjust. Use delete to free
1103 piece_closure.
1104 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
1105 to allocate_piece_closure.
1106 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
1107
0782db84
SM
11082017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1109
1110 * probe.h (probe_ops_cp): Remove typedef.
1111 (DEF_VEC_P (probe_ops_cp)): Remove.
1112 (all_probe_ops): Change type to std::vector.
1113 * probe.c (info_probes_for_ops): Adjust to vector change.
1114 (probe_linespec_to_ops): Likewise.
1115 (all_probe_ops): Change type to std::vector.
1116 (_initialize_probe): Adjust to vector change.
1117 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
1118 * elfread.c (elf_get_probes): Likewise.
1119 * stap-probe.c (_initialize_stap_probe): Likewise.
1120
1eac6bea
SM
11212017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1122
1123 * probe.h (struct bound_probe): Define constructors.
1124 * probe.c (bound_probe_s): Remove typedef.
1125 (DEF_VEC_O (bound_probe_s)): Remove VEC.
1126 (collect_probes): Change return type to std::vector, remove
1127 cleanup.
1128 (compare_probes): Return bool, change parameter type. Change
1129 semantic to "less than".
1130 (gen_ui_out_table_header_info): Change parameter to std::vector
1131 and update.
1132 (exists_probe_with_pops): Likewise.
1133 (info_probes_for_ops): Update to std::vector change.
1134 (enable_probes_command): Likewise.
1135 (disable_probes_command): Likewise.
1136
aaa63a31
SM
11372017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1138
1139 * probe.h (struct probe_ops) <get_probes>: Change parameter from
1140 vec to std::vector.
1141 * probe.c (parse_probes_in_pspace): Update.
1142 (find_probes_in_objfile): Update.
1143 (find_probe_by_pc): Update.
1144 (collect_probes): Update.
1145 (probe_any_get_probes): Update.
1146 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
1147 return type to reference to std::vector.
1148 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
1149 std::vector and update.
1150 (dtrace_process_dof): Likewise.
1151 (dtrace_get_probes): Likewise.
1152 * elfread.c (elf_get_probes): Change return type to std::vector,
1153 store an std::vector in bfd_data.
1154 (probe_key_free): Update to std::vector.
1155 * stap-probe.c (handle_stap_probe): Change parameter to
1156 std::vector and update.
1157 (stap_get_probes): Likewise.
1158 * symfile-debug.c (debug_sym_get_probes): Change return type to
1159 std::vector and update.
1160
cb85b21b
TT
11612017-09-11 Tom Tromey <tom@tromey.com>
1162
1163 * breakpoint.c (program_breakpoint_here_p): Update.
1164 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
1165 from make_show_memory_breakpoints_cleanup. Return a
1166 scoped_restore_tmpl<int>.
1167 (restore_show_memory_breakpoints): Remove.
1168 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
1169 * mem-break.c (memory_validate_breakpoint): Update.
1170 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
1171 (ia64_memory_remove_breakpoint): Update.
1172 (ia64_breakpoint_from_pc): Update.
1173 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
1174 from make_show_memory_breakpoints_cleanup.
1175
8fbc99ef
TT
11762017-09-11 Tom Tromey <tom@tromey.com>
1177
1178 * d-namespace.c (d_lookup_symbol): Use std::string.
1179 (find_symbol_in_baseclass): Likewise.
1180
50feb4bd
TT
11812017-09-11 Tom Tromey <tom@tromey.com>
1182
1183 * ctf.c (ctf_start): Use std::string.
1184
c6dc63a1
TT
11852017-09-11 Tom Tromey <tom@tromey.com>
1186
1187 * ada-lang.c (is_known_support_routine): Update.
1188 (ada_unhandled_exception_name_addr_from_raise): Update.
1189 * guile/scm-frame.c (gdbscm_frame_name): Update.
1190 * python/py-frame.c (frapy_name): Update.
1191 (frapy_function): Update.
1192 * stack.h (find_frame_funname): Update.
1193 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1194 (print_frame): Update.
1195
d6b9b80f
TT
11962017-09-11 Tom Tromey <tom@tromey.com>
1197
1198 * findcmd.c (put_bits): Take a gdb::byte_vector.
1199 (parse_find_args): Return gdb::byte_vector. "args" now const.
1200 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1201 cleanups.
1202 (find_command): Update.
1203
a9921622
TT
12042017-09-11 Tom Tromey <tom@tromey.com>
1205
1206 * cli/cli-script.c (class scoped_restore_hook_in): New.
1207 (clear_hook_in_cleanup): Remove.
1208 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1209 scoped_restore_hook_in.
1210
be0d7abb
TT
12112017-09-11 Tom Tromey <tom@tromey.com>
1212
1213 * cli/cli-script.c (restore_interp): Remove.
1214 (read_command_lines): Use scoped_restore_interp.
1215 * interps.c (scoped_restore_interp::set_temp): Rename from
1216 interp_set_temp.
1217 * interps.h (class scoped_restore_interp): New.
1218 (interp_set_temp): Remove.
1219
00f675ff
TT
12202017-09-11 Tom Tromey <tom@tromey.com>
1221
1222 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1223 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1224 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1225 scoped_restore.
1226 (mi_cmd_break_insert_1): Update.
1227 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1228 scoped_restore.
1229
cb791d59
TT
12302017-09-11 Tom Tromey <tom@tromey.com>
1231
1232 * demangle.c (demangle_command): Update.
1233 * breakpoint.c (disable_command): Update.
1234 (enable_command): Update.
1235 (find_location_by_number): Make "number" const. Use
1236 get_number_trailer.
1237 * cli/cli-utils.c (extract_arg): Return std::string.
1238 * probe.c (parse_probe_linespec): Update. Change types.
1239 (collect_probes): Take string arguments.
1240 (parse_probe_linespec): Likewise.
1241 (info_probes_for_ops): Update.
1242 (enable_probes_command): Update.
1243 (disable_probes_command): Update.
1244 * break-catch-sig.c (catch_signal_split_args): Update.
1245 * mi/mi-parse.c (mi_parse): Update.
1246
2039bd9f
TT
12472017-09-11 Tom Tromey <tom@tromey.com>
1248
1249 * language.h (language_enum): Make argument const.
1250 * language.c (language_enum): Make argument const.
1251
f1735a53
TT
12522017-09-11 Tom Tromey <tom@tromey.com>
1253
1254 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1255 as function.
1256 (skip_to_space): Rename from skip_to_space_const.
1257 * common/common-utils.c (skip_to_space): New function.
1258 (skip_to_space): Rename from skip_to_space_const.
1259 * cli/cli-utils.h (get_number): Rename from get_number_const.
1260 (extract_arg): Rename from extract_arg_const.
1261 * cli/cli-utils.c (get_number): Rename from get_number_const.
1262 (extract_arg): Rename from extract_arg_const.
1263 (number_or_range_parser::get_number): Use ::get_number.
1264 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1265 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1266 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1267 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1268 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1269 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1270 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1271 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1272
7d221d74
TT
12732017-09-11 Tom Tromey <tom@tromey.com>
1274
1275 * python/python.c (do_start_initialization): Use
1276 py-event-types.def to initialize types.
1277 Define all object type structures.
1278 * python/python-internal.h: Don't declare event initialization
1279 functions.
1280 * python/py-threadevent.c (thread_event_object_type): Don't
1281 define.
1282 * python/py-stopevent.c (stop_event_object_type): Don't define.
1283 * python/py-signalevent.c (signal_event_object_type): Don't
1284 declare or define.
1285 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1286 (clear_objfiles_event_object_type): Don't declare or define.
1287 * python/py-infevents.c (inferior_call_pre_event_object_type)
1288 (inferior_call_post_event_object_type)
1289 (register_changed_event_object_type)
1290 (memory_changed_event_object_type): Don't declare or define.
1291 * python/py-inferior.c (new_thread_event_object_type)
1292 (new_inferior_event_object_type)
1293 (inferior_deleted_event_object_type): Don't declare or define.
1294 * python/py-exitedevent.c (exited_event_object_type): Don't
1295 declare or define.
1296 * python/py-evts.c (gdbpy_initialize_py_events): Use
1297 py-all-events.def.
1298 * python/py-events.h (thread_event_object_type): Don't declare.
1299 (events_object): Use py-all-events.def.
1300 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1301 py-event-types.def.
1302 * python/py-event-types.def: New file.
1303 * python/py-continueevent.c (create_continue_event_object): Don't
1304 declare or define.
1305 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1306 declare or define.
1307 * python/py-all-events.def: New file.
1308
35c61a1d
TT
13092017-09-11 Tom Tromey <tom@tromey.com>
1310
1311 * python/py-threadevent.c (create_thread_event_object): Return
1312 gdbpy_ref.
1313 * python/py-stopevent.h (create_stop_event_object)
1314 (create_breakpoint_event_object, create_signal_event_object):
1315 Update.
1316 * python/py-stopevent.c (create_stop_event_object): Return
1317 gdbpy_ref.
1318 (emit_stop_event): Update.
1319 * python/py-signalevent.c (create_signal_event_object): Return
1320 gdbpy_ref.
1321 * python/py-infevents.c (create_inferior_call_event_object):
1322 Update.
1323 * python/py-event.h (create_event_object)
1324 (create_thread_event_object): Update.
1325 * python/py-event.c (create_event_object): Return gdbpy_ref.
1326 * python/py-continueevent.c: Return gdbpy_ref.
1327 * python/py-bpevent.c (create_breakpoint_event_object): Return
1328 gdbpy_ref.
1329
7c96f8c1
TT
13302017-09-11 Tom Tromey <tom@tromey.com>
1331
1332 PR python/15622:
1333 * NEWS: Add entry.
1334 * python/python.c (do_start_initialization): Initialize new event
1335 types.
1336 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1337 (gdbpy_initialize_inferior_deleted_event)
1338 (gdbpy_initialize_new_thread_event): Declare.
1339 * python/py-threadevent.c (create_thread_event_object): Add option
1340 "thread" parameter.
1341 * python/py-inferior.c (new_thread_event_object_type)
1342 (new_inferior_event_object_type)
1343 (inferior_deleted_event_object_type): Declare.
1344 (python_new_inferior, python_inferior_deleted): New functions.
1345 (add_thread_object): Emit new_thread event.
1346 (gdbpy_initialize_inferior): Attach new functions to corresponding
1347 observers.
1348 (new_thread, new_inferior, inferior_deleted): Define new event
1349 types.
1350 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1351 registries.
1352 * python/py-events.h (events_object) <new_inferior,
1353 inferior_deleted, new_thread>: New fields.
1354 * python/py-event.h (create_thread_event_breakpoint): Add optional
1355 "thread" parameter.
1356
72542b8e
AB
13572017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1358
1359 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1360 check current_ui instead.
1361 (internal_vproblem): Likewise.
1362
0d64823e
SM
13632017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1364
1365 * thread.c (print_thread_info_1): Remove unnecessary calls to
1366 uiout->is_mi_like_p.
1367
eb1e02fd
TT
13682017-09-09 Tom Tromey <tom@tromey.com>
1369
1370 * namespace.h (add_using_directive): Update.
1371 * namespace.c (add_using_directive): Change type of excludes to
1372 std::vector.
1373 * dwarf2read.c (read_import_statement): Use std::vector.
1374 (read_namespace): Update.
1375 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1376
0fc21fd8
TT
13772017-09-09 Tom Tromey <tom@tromey.com>
1378
1379 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1380
49663d05
TT
13812017-09-09 Tom Tromey <tom@tromey.com>
1382
1383 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1384
0b868b60
TT
13852017-09-09 Tom Tromey <tom@tromey.com>
1386
1387 * stack.c (func_command): Use gdb::def_vector.
1388
c0470d48
TT
13892017-09-09 Tom Tromey <tom@tromey.com>
1390
1391 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1392 ui_out_emit_list, ui_out_emit_tuple.
1393 (mi_cmd_var_update): Likewise.
1394
ca5909c7
TT
13952017-09-09 Tom Tromey <tom@tromey.com>
1396
1397 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1398 ui_out_redirect_pop.
1399 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1400 ui_out_redirect_pop.
1401 * utils.c (do_ui_out_redirect_pop)
1402 (make_cleanup_ui_out_redirect_pop): Remove.
1403 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1404 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1405 * ui-out.h (ui_out_redirect_pop): New class.
1406
e6a2252a
TT
14072017-09-09 Tom Tromey <tom@tromey.com>
1408
1409 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1410 (list_available_thread_groups, mi_cmd_list_thread_groups)
1411 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1412 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1413 Likewise.
1414
393702cd
TT
14152017-09-09 Tom Tromey <tom@tromey.com>
1416
1417 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1418 ui_out_emit_tuple.
1419
76f9c9cf
TT
14202017-09-09 Tom Tromey <tom@tromey.com>
1421
1422 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1423 * stack.c (print_frame): Use ui_out_emit_tuple.
1424 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1425 (info_spu_mailbox_command, info_spu_dma_command)
1426 (info_spu_proxydma_command): Likewise.
1427 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1428 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1429 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1430 ui_out_emit_tuple.
1431 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1432
dc9fe180
TT
14332017-09-09 Tom Tromey <tom@tromey.com>
1434
1435 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1436 (class ui_out_emit_table): Update comment.
1437 * ui-out.c (do_cleanup_table_end)
1438 (make_cleanup_ui_out_table_begin_end): Remove.
1439 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1440 (info_spu_dma_cmdlist): Likewise.
1441 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1442 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1443 ui_out_emit_table.
1444
f8cc3da6
TT
14452017-09-09 Tom Tromey <tom@tromey.com>
1446
1447 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1448 ui_out_emit_list, gdb::optional.
1449
481695ed
JB
14502017-09-09 John Baldwin <jhb@FreeBSD.org>
1451
1452 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1453 prototype.
1454 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1455 prototype.
1456 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1457 prototype.
1458 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1459 * ada-exp.y: Remove _initialize_ada_exp prototype.
1460 * ada-lang.c: Remove _initialize_ada_language prototype.
1461 * ada-tasks.c: Remove _initialize_tasks prototype.
1462 * addrmap.c: Remove _initialize_addrmap prototype.
1463 * agent.c: Remove _initialize_agent prototype.
1464 * aix-thread.c: Remove _initialize_aix_thread prototype.
1465 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
1466 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
1467 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
1468 prototype.
1469 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
1470 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
1471 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
1472 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
1473 prototype.
1474 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
1475 prototype.
1476 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
1477 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
1478 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
1479 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
1480 prototype.
1481 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
1482 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
1483 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
1484 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
1485 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1486 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
1487 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
1488 prototype.
1489 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
1490 prototype.
1491 * annotate.c: Remove _initialize_annotate prototype.
1492 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
1493 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
1494 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
1495 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
1496 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
1497 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
1498 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
1499 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
1500 prototype.
1501 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
1502 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
1503 * auto-load.c: Remove _initialize_auto_load prototype.
1504 * auxv.c: Remove _initialize_auxv prototype.
1505 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
1506 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
1507 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
1508 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
1509 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
1510 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
1511 prototype.
1512 * break-catch-throw.c: Remove _initialize_break_catch_throw
1513 prototype.
1514 * breakpoint.c: Remove _initialize_breakpoint prototype.
1515 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
1516 * btrace.c: Remove _initialize_btrace prototype.
1517 * charset.c: Remove _initialize_charset prototype.
1518 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
1519 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
1520 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
1521 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
1522 * cli/cli-script.c: Remove _initialize_cli_script prototype.
1523 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
1524 * coffread.c: Remove _initialize_coffread prototype.
1525 * compile/compile.c: Remove _initialize_compile prototype.
1526 * complaints.c: Remove _initialize_complaints prototype.
1527 * completer.c: Remove _initialize_completer prototype.
1528 * copying.awk: Remove _initialize_copying prototype.
1529 * copying.c: Regenerate.
1530 * core-regset.c: Remove _initialize_core_regset prototype.
1531 * corefile.c: Remove _initialize_core prototype.
1532 * corelow.c: Remove _initialize_corelow prototype.
1533 * cp-abi.c: Remove _initialize_cp_abi prototype.
1534 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
1535 * cp-support.c: Remove _initialize_cp_support prototype.
1536 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
1537 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
1538 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
1539 * ctf.c: Remove _initialize_ctf prototype.
1540 * d-lang.c: Remove _initialize_d_language prototype.
1541 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
1542 prototype.
1543 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
1544 * dbxread.c: Remove _initialize_dbxread prototype.
1545 * dcache.c: Remove _initialize_dcache prototype.
1546 * demangle.c: Remove _initialize_demangler prototype.
1547 * disasm-selftests.c: Remove _initialize_disasm_selftests
1548 prototype.
1549 * disasm.c: Remove _initialize_disasm prototype.
1550 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
1551 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
1552 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
1553 prototype.
1554 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
1555 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
1556 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
1557 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
1558 * elfread.c: Remove _initialize_elfread prototype.
1559 * exec.c: Remove _initialize_exec prototype.
1560 * extension.c: Remove _initialize_extension prototype.
1561 * f-lang.c: Remove _initialize_f_language prototype.
1562 * f-valprint.c: Remove _initialize_f_valprint prototype.
1563 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
1564 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
1565 * filesystem.c: Remove _initialize_filesystem prototype.
1566 * findcmd.c: Remove _initialize_mem_search prototype.
1567 * fork-child.c: Remove _initialize_fork_child prototype.
1568 * frame-base.c: Remove _initialize_frame_base prototype.
1569 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
1570 * frame.c: Remove _initialize_frame prototype.
1571 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
1572 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
1573 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
1574 * gcore.c: Remove _initialize_gcore prototype.
1575 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
1576 * gdbarch.c: Regenerate.
1577 * gdbarch.sh: Remove _initialize_gdbarch prototype.
1578 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
1579 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
1580 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
1581 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
1582 * go-lang.c: Remove _initialize_go_language prototype.
1583 * go32-nat.c: Remove _initialize_go32_nat prototype.
1584 * guile/guile.c: Remove _initialize_guile prototype.
1585 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
1586 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
1587 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
1588 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
1589 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
1590 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
1591 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
1592 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
1593 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
1594 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
1595 prototype.
1596 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
1597 prototype.
1598 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
1599 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
1600 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
1601 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
1602 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
1603 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
1604 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
1605 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
1606 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
1607 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
1608 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
1609 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
1610 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
1611 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1612 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
1613 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
1614 prototype.
1615 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
1616 prototype.
1617 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
1618 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
1619 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
1620 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
1621 * infcall.c: Remove _initialize_infcall prototype.
1622 * infcmd.c: Remove _initialize_infcmd prototype.
1623 * inferior.c: Remove _initialize_inferiors prototype.
1624 * inflow.c: Remove _initialize_inflow prototype.
1625 * infrun.c: Remove _initialize_infrun prototype.
1626 * interps.c: Remove _initialize_interpreter prototype.
1627 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
1628 * jit.c: Remove _initialize_jit prototype.
1629 * language.c: Remove _initialize_language prototype.
1630 * linux-fork.c: Remove _initialize_linux_fork prototype.
1631 * linux-nat.c: Remove _initialize_linux_nat prototype.
1632 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
1633 * linux-thread-db.c: Remove _initialize_thread_db prototype.
1634 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
1635 * m2-lang.c: Remove _initialize_m2_language prototype.
1636 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
1637 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
1638 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
1639 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
1640 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
1641 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1642 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1643 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
1644 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
1645 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
1646 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
1647 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
1648 * machoread.c: Remove _initialize_machoread prototype.
1649 * macrocmd.c: Remove _initialize_macrocmd prototype.
1650 * macroscope.c: Remove _initialize_macroscope prototype.
1651 * maint.c: Remove _initialize_maint_cmds prototype.
1652 * mdebugread.c: Remove _initialize_mdebugread prototype.
1653 * memattr.c: Remove _initialize_mem prototype.
1654 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
1655 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
1656 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
1657 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
1658 * mi/mi-main.c: Remove _initialize_mi_main prototype.
1659 * microblaze-linux-tdep.c: Remove
1660 _initialize_microblaze_linux_tdep prototype.
1661 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
1662 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
1663 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
1664 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
1665 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
1666 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
1667 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
1668 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
1669 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
1670 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
1671 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
1672 prototype.
1673 * mipsread.c: Remove _initialize_mipsread prototype.
1674 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
1675 prototype.
1676 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
1677 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
1678 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
1679 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
1680 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
1681 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
1682 prototype.
1683 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
1684 * nto-procfs.c: Remove _initialize_procfs prototype.
1685 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
1686 * objc-lang.c: Remove _initialize_objc_language prototype.
1687 * objfiles.c: Remove _initialize_objfiles prototype.
1688 * observer.c: Remove observer_test_first_notification_function,
1689 observer_test_second_notification_function,
1690 observer_test_third_notification_function, and
1691 _initialize_observer prototypes.
1692 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
1693 * osabi.c: Remove _initialize_gdb_osabi prototype.
1694 * osdata.c: Remove _initialize_osdata prototype.
1695 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
1696 * parse.c: Remove _initialize_parse prototype.
1697 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
1698 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
1699 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
1700 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
1701 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
1702 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
1703 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
1704 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
1705 * printcmd.c: Remove _initialize_printcmd prototype.
1706 * probe.c: Remove _initialize_probe prototype.
1707 * proc-api.c: Remove _initialize_proc_api prototype.
1708 * proc-events.c: Remove _initialize_proc_events prototype.
1709 * proc-service.c: Remove _initialize_proc_service prototype.
1710 * procfs.c: Remove _initialize_procfs prototype.
1711 * psymtab.c: Remove _initialize_psymtab prototype.
1712 * python/python.c: Remove _initialize_python prototype.
1713 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
1714 * record-btrace.c: Remove _initialize_record_btrace prototype.
1715 * record-full.c: Remove _initialize_record_full prototype.
1716 * record.c: Remove _initialize_record prototype.
1717 * regcache.c: Remove _initialize_regcache prototype.
1718 * reggroups.c: Remove _initialize_reggroup prototype.
1719 * remote-notif.c: Remove _initialize_notif prototype.
1720 * remote-sim.c: Remove _initialize_remote_sim prototype.
1721 * remote.c: Remove _initialize_remote prototype.
1722 * reverse.c: Remove _initialize_reverse prototype.
1723 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
1724 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
1725 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
1726 prototype.
1727 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
1728 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
1729 * rust-exp.y: Remove _initialize_rust_exp prototype.
1730 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
1731 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
1732 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
1733 * score-tdep.c: Remove _initialize_score_tdep prototype.
1734 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
1735 prototype.
1736 * ser-go32.c: Remove _initialize_ser_dos prototype.
1737 * ser-mingw.c: Remove _initialize_ser_windows prototype.
1738 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
1739 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
1740 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
1741 * serial.c: Remove _initialize_serial prototype.
1742 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
1743 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
1744 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
1745 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
1746 * skip.c: Remove _initialize_step_skip prototype.
1747 * sol-thread.c: Remove _initialize_sol_thread prototype.
1748 * solib-aix.c: Remove _initialize_solib_aix prototype.
1749 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
1750 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
1751 * solib-frv.c: Remove _initialize_frv_solib prototype.
1752 * solib-spu.c: Remove _initialize_spu_solib prototype.
1753 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
1754 * solib-target.c: Remove _initialize_solib_target prototype.
1755 * solib.c: Remove _initialize_solib prototype.
1756 * source.c: Remove _initialize_source prototype.
1757 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
1758 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
1759 prototype.
1760 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
1761 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
1762 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
1763 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
1764 prototype.
1765 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
1766 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
1767 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
1768 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
1769 prototype.
1770 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
1771 prototype.
1772 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
1773 prototype.
1774 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
1775 prototype.
1776 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
1777 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
1778 prototype.
1779 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
1780 prototype.
1781 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
1782 prototype.
1783 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
1784 prototype.
1785 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
1786 prototype.
1787 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
1788 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
1789 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
1790 * stabsread.c: Remove _initialize_stabsread prototype.
1791 * stack.c: Remove _initialize_stack prototype.
1792 * stap-probe.c: Remove _initialize_stap_probe prototype.
1793 * std-regs.c: Remove _initialize_frame_reg prototype.
1794 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
1795 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
1796 * symfile.c: Remove _initialize_symfile prototype.
1797 * symmisc.c: Remove _initialize_symmisc prototype.
1798 * symtab.c: Remove _initialize_symtab prototype.
1799 * target-dcache.c: Remove _initialize_target_dcache prototype.
1800 * target-descriptions.c: Remove _initialize_target_descriptions
1801 prototype.
1802 * thread.c: Remove _initialize_thread prototype.
1803 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
1804 prototype.
1805 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
1806 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
1807 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
1808 prototype.
1809 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
1810 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
1811 * tracefile.c: Remove _initialize_tracefile prototype.
1812 * tracepoint.c: Remove _initialize_tracepoint prototype.
1813 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
1814 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
1815 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
1816 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
1817 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
1818 * tui/tui-win.c: Remove _initialize_tui_win prototype.
1819 * tui/tui.c: Remove _initialize_tui prototype.
1820 * typeprint.c: Remove _initialize_typeprint prototype.
1821 * user-regs.c: Remove _initialize_user_regs prototype.
1822 * utils.c: Remove _initialize_utils prototype.
1823 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
1824 * valarith.c: Remove _initialize_valarith prototype.
1825 * valops.c: Remove _initialize_valops prototype.
1826 * valprint.c: Remove _initialize_valprint prototype.
1827 * value.c: Remove _initialize_values prototype.
1828 * varobj.c: Remove _initialize_varobj prototype.
1829 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
1830 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
1831 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
1832 * windows-nat.c: Remove _initialize_windows_nat,
1833 _initialize_check_for_gdb_ini, and _initialize_loadable
1834 prototypes.
1835 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
1836 * xcoffread.c: Remove _initialize_xcoffread prototype.
1837 * xml-support.c: Remove _initialize_xml_support prototype.
1838 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
1839 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
1840 prototype.
1841 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
1842 prototype.
1843 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
1844
a611b5cb
KS
18452017-09-08 Keith Seitz <keiths@redhat.com>
1846
1847 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
1848 field.
1849
469412dd
CW
18502017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
1851
1852 * f-valprint.c (f_val_print): Remove check for one byte
1853 sized integers. Remove printing of character type.
1854
a5ad232b
FP
18552017-09-08 Frank Penczek <frank.penczek@intel.com>
1856 Christoph Weinmann <christoph.t.weinmann@intel.com>
1857 Bernhard Heckel <bernhard.heckel@intel.com>
1858
1859 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
1860 to maintain proper indentation when printing pointers/refs.
1861
e5014227
JB
18622017-09-07 Joel Brobecker <brobecker@adacore.com>
1863
1864 GDB 8.0.1 released.
1865
63c99141
JB
18662017-09-07 Joel Brobecker <brobecker@adacore.com>
1867
1868 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
1869
69c1e056
TT
18702017-09-05 Tom Tromey <tom@tromey.com>
1871
1872 * parse.c (funcall_chain): Now a std::vector.
1873 (start_arglist, end_arglist): Simplify.
1874 (free_funcalls): Remove.
1875 (parse_exp_in_context_1): Remove cleanup.
1876
fef704bf
TT
18772017-09-05 Tom Tromey <tom@tromey.com>
1878
1879 * go-exp.y (go_parse): Don't create a cleanup.
1880
5613c585
TT
18812017-09-05 Tom Tromey <tom@tromey.com>
1882
1883 * d-exp.y (PrimaryExpression): Use std::string.
1884 (d_parse): Don't create a cleanup.
1885
eae49211
TT
18862017-09-05 Tom Tromey <tom@tromey.com>
1887
1888 * utils.c (do_clear_parser_state): Remove.
1889 (make_cleanup_clear_parser_state): Remove.
1890 * p-exp.y (pascal_parse): Use scoped_restore.
1891 * m2-exp.y (m2_parse): Use scoped_restore.
1892 * f-exp.y (f_parse): Use scoped_restore.
1893 * d-exp.y (d_parse): Use scoped_restore.
1894 * c-exp.y (c_parse): Use scoped_restore.
1895 * ada-exp.y (ada_parse): Use scoped_restore.
1896 * utils.h (make_cleanup_clear_parser_state): Remove.
1897
73b9be8b
KS
18982017-09-06 Keith Seitz <keiths@redhat.com>
1899
1900 * dwarf2read.c (dw2_linkage_name_attr): New function.
1901 (dw2_linkage_name): New function.
1902 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
1903 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
1904 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
1905
a102602b
KR
19062017-09-06 Kamil Rytarowski <n54@gmx.com>
1907
1908 * config/djgpp/djconfig.sh: Correct shell portability issue.
1909
28ad437d
KR
19102017-09-06 Kamil Rytarowski <n54@gmx.com>
1911
1912 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
1913
351787dd
JB
19142017-09-06 John Baldwin <jhb@FreeBSD.org>
1915
1916 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
1917 * NEWS: Mention new FreeBSD/mips native configuration.
1918 * configure.host: Add aarch64*-*-freebsd*.
1919 * configure.nat: Likewise.
1920 * aarch64-fbsd-nat.c: New file.
1921
c0f84956
JB
19222017-09-06 John Baldwin <jhb@FreeBSD.org>
1923
1924 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
1925 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
1926 * NEWS: Mention new FreeBSD/aarch64 target.
1927 * configure.tgt: Add aarch64*-*-freebsd*.
1928 * aarch64-fbsd-tdep.c: New file.
1929 * aarch64-fbsd-tdep.h: New file.
1930
7610297a
KR
19312017-09-06 Kamil Rytarowski <n54@gmx.com>
1932
1933 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
1934
fbd1b771
JK
19352017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
1936
1937 * parse.c (find_minsym_type_and_address): Don't relocate addresses
1938 of TLS symbols.
1939
5ca79eae
PW
19402017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1941
1942 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
1943 call.
1944
bf93d7ba
SM
19452017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1946
1947 * infrun.c (follow_exec): Call add_thread after
1948 target_find_description.
1949
1bb7c059
SM
19502017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1951
1952 * infrun.c (handle_inferior_event_1): When exec'ing, read
1953 stop_pc after follow_exec.
1954
fc809827
SM
19552017-09-05 Simon Marchi <simon.marchi@ericsson.com>
1956
1957 * remote.c (process_g_packet): Update error message.
1958
d2fcdd85
YQ
19592017-09-05 Yao Qi <yao.qi@linaro.org>
1960
1961 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
1962 targets.
1963
e69570ee
PA
19642017-09-05 Pedro Alves <palves@redhat.com>
1965
1966 * eval.c (eval_call, evaluate_funcall): New functions, factored
1967 out from ...
1968 (evaluate_subexp_standard): ... this.
1969
22916b07
YQ
19702017-09-05 Yao Qi <yao.qi@linaro.org>
1971
1972 * amd64-tdep.c (amd64_target_description): Create target
1973 descriptions.
1974 (_initialize_amd64_tdep): Don't call functions
1975 initialize_tdesc_amd64_*. Add self tests.
1976 * arch/amd64.c (amd64_create_target_description): Add parameter
1977 is_linux. Call set_tdesc_osabi if is_linux is true.
1978 * arch/amd64.h (amd64_create_target_description): Update the
1979 declaration.
1980 * arch/i386.c (i386_create_target_description): Add parameter
1981 is_linux. Call set_tdesc_osabi if is_linux is true.
1982 * arch/i386.h (i386_create_target_description): Update
1983 declaration.
1984 * configure.tgt: Add i386.o to gdb_target_obs.
1985 * features/Makefile (XMLTOC): Remove i386/*.xml.
1986 * features/i386/amd64-avx-avx512.c: Remove.
1987 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
1988 * features/i386/amd64-avx-mpx.c: Remove.
1989 * features/i386/amd64-avx.c: Remove.
1990 * features/i386/amd64-mpx.c: Remove.
1991 * features/i386/amd64.c: Remove.
1992 * features/i386/i386-avx-avx512.c: Remove.
1993 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
1994 * features/i386/i386-avx-mpx.c: Remove.
1995 * features/i386/i386-avx.c: Remove.
1996 * features/i386/i386-mmx.c: Remove.
1997 * features/i386/i386-mpx.c: Remove.
1998 * features/i386/i386.c: Remove.
1999 * i386-tdep.c: Don't include features/i386/i386*.c., include
2000 target-descriptions.h and arch/i386.h.
2001 (i386_target_description): Create target descriptions.
2002 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
2003 functions. Do self tests.
2004
0854b7b1
YQ
20052017-09-05 Yao Qi <yao.qi@linaro.org>
2006
2007 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
2008 * features/i386/amd64-avx-avx512-linux.c: Removed.
2009 * features/i386/amd64-avx-linux.c: Removed.
2010 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
2011 * features/i386/amd64-avx-mpx-linux.c: Removed.
2012 * features/i386/amd64-linux.c: Removed.
2013 * features/i386/amd64-mpx-linux.c: Removed.
2014 * features/i386/x32-avx-avx512-linux.c: Removed.
2015 * features/i386/x32-avx-linux.c: Removed.
2016 * features/i386/x32-linux.c: Removed.
2017
b4570e4b
YQ
20182017-09-05 Yao Qi <yao.qi@linaro.org>
2019
2020 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
2021 features/i386/*.c.
2022 (amd64_linux_read_description): Call
2023 amd64_create_target_description.
2024 * arch/amd64.c: New file.
2025 * arch/amd64.h: New file.
2026 * configure.tgt (x86_64-*-linux*): Append amd64.o.
2027 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
2028
6c73f67f
YQ
20292017-09-05 Yao Qi <yao.qi@linaro.org>
2030
2031 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
2032 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
2033 (amd64_linux_read_description): Create target descriptions.
2034 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
2035 functions. Add unit tests.
2036 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
2037 x32-core.xml.
2038 * features/i386/64bit-avx.c: Generated.
2039 * features/i386/64bit-avx512.c: Generated.
2040 * features/i386/64bit-core.c: Generated.
2041 * features/i386/64bit-linux.c: Generated.
2042 * features/i386/64bit-mpx.c: Generated.
2043 * features/i386/64bit-pkeys.c: Generated.
2044 * features/i386/64bit-segments.c: Generated.
2045 * features/i386/64bit-sse.c: Generated.
2046 * features/i386/x32-core.c: Generated.
2047 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
2048 c files for amd64-linux and x32-linux.
2049
9d3d478b
YQ
20502017-09-05 Yao Qi <yao.qi@linaro.org>
2051
2052 * amd64-linux-tdep.c (amd64_linux_read_description): New
2053 function.
2054 (amd64_linux_core_read_description): Call
2055 amd64_linux_read_description.
2056 (amd64_linux_init_abi): Likewise.
2057 (amd64_x32_linux_init_abi): Likewise.
2058 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
2059 * x86-linux-nat.c (x86_linux_read_description): Call
2060 amd64_linux_read_description.
2061
b9f1d50f
YQ
20622017-09-05 Yao Qi <yao.qi@linaro.org>
2063
2064 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
2065 comments.
2066
188c9e6d
YQ
20672017-09-05 Yao Qi <yao.qi@linaro.org>
2068
2069 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
2070 * features/i386/i386-avx-avx512-linux.c: Remove.
2071 * features/i386/i386-avx-linux.c: Remove.
2072 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
2073 * features/i386/i386-avx-mpx-linux.c: Remove.
2074 * features/i386/i386-linux.c: Remove.
2075 * features/i386/i386-mmx-linux.c: Remove.
2076 * features/i386/i386-mpx-linux.c: Remove.
2077
5f035c07
YQ
20782017-09-05 Yao Qi <yao.qi@linaro.org>
2079
2080 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
2081 (SFILES): Add arch/i386.c.
2082 (HFILES_NO_SRCDIR): Add arch/i386.h.
2083 * arch/i386.c: New file.
2084 * arch/i386.h: New file.
2085 * arch/tdesc.h (allocate_target_description): Declare.
2086 (set_tdesc_architecture): Declare.
2087 (set_tdesc_osabi): Declare.
2088 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
2089 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
2090 include arch/i386.h.
2091 (i386_linux_read_description): Remove code and call
2092 i386_create_target_description.
2093 (set_tdesc_architecture): New function.
2094 (set_tdesc_osabi): New function.
2095 * target-descriptions.h (allocate_target_description): Remove.
2096
0abe8a89
YQ
20972017-09-05 Yao Qi <yao.qi@linaro.org>
2098
2099 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
2100 * target-descriptions.c (tdesc_create_feature): Likewise, and
2101 adjust code.
2102 * features/i386/32bit-avx.c: Re-generated.
2103 * features/i386/32bit-avx512.c: Re-generated.
2104 * features/i386/32bit-core.c: Re-generated.
2105 * features/i386/32bit-linux.c: Re-generated.
2106 * features/i386/32bit-mpx.c: Re-generated.
2107 * features/i386/32bit-pkeys.c: Re-generated.
2108 * features/i386/32bit-sse.c: Re-generated.
2109
0a188386
YQ
21102017-09-05 Yao Qi <yao.qi@linaro.org>
2111
2112 * regformats/regdef.h (struct reg): Override operator == and !=.
2113
f49ff000
YQ
21142017-09-05 Yao Qi <yao.qi@linaro.org>
2115
2116 * arch/tdesc.h: New file.
2117 * regformats/regdat.sh: Generate code using tdesc_create_reg.
2118 * target-descriptions.c: Update comments.
2119 * target-descriptions.h: Include "arch/tdesc.h". Remove the
2120 declarations.
2121 * features/i386/32bit-avx.c: Re-generated.
2122 * features/i386/32bit-avx512.c: Re-generated.
2123 * features/i386/32bit-core.c: Re-generated.
2124 * features/i386/32bit-linux.c: Re-generated.
2125 * features/i386/32bit-mpx.c: Re-generated.
2126 * features/i386/32bit-pkeys.c: Re-generated.
2127 * features/i386/32bit-sse.c: Re-generated.
2128
f7000548
YQ
21292017-09-05 Yao Qi <yao.qi@linaro.org>
2130
2131 * regformats/regdat.sh: Update generated code.
2132
c9a5e2a5
YQ
21332017-09-05 Yao Qi <yao.qi@linaro.org>
2134
2135 * regformats/regdat.sh: Adjust code order.
2136
d6b687ac
SM
21372017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2138
2139 * expprint.c (dump_subexp_body_standard): Use constant format
2140 string in fprintf_filtered call.
2141
a379bfd0
JB
21422017-09-04 John Baldwin <jhb@FreeBSD.org>
2143
2144 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
2145 NetBSD/i386.
2146 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
2147
f7efc967
JB
21482017-09-04 John Baldwin <jhb@FreeBSD.org>
2149
2150 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
2151
c49fbc6c
JB
21522017-09-04 John Baldwin <jhb@FreeBSD.org>
2153
2154 * bsd-kvm.o: Define _KMEMUSER.
2155 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
2156 * configure: Regenerate.
2157
26562e73
JB
21582017-09-04 John Baldwin <jhb@FreeBSD.org>
2159
2160 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
2161 * i386-fbsd-nat.c: Likewise.
2162
31cf1487
JB
21632017-09-04 John Baldwin <jhb@FreeBSD.org>
2164
2165 * unittests/array-view-selftests.c: Add include of <array>.
2166
5b9f8a7c
JB
21672017-09-04 John Baldwin <jhb@FreeBSD.org>
2168
2169 * spu-tdep.c (flush_ea_cache): Add missing argument to
2170 call_function_by_hand.
2171
d69cf9b2
PA
21722017-09-04 Pedro Alves <palves@redhat.com>
2173
2174 * NEWS (Safer support for debugging with no debug info): New.
2175
3693fdb3
PA
21762017-09-04 Pedro Alves <palves@redhat.com>
2177
2178 * c-exp.y (function_method, function_method_void): Add current
2179 instance flags to TYPE_INSTANCE.
2180 * dwarf2read.c (check_modifier): New.
2181 (compute_delayed_physnames): Assert that only C++ adds delayed
2182 physnames. Mark fn_fields as const/volatile depending on
2183 physname.
2184 * eval.c (make_params): New type_instance_flags parameter. Use
2185 it as the new type's instance flags.
2186 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2187 flags element and pass it to make_params.
2188 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2189 instance flags element.
2190 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2191 * gdbtypes.h: Include "enum-flags.h".
2192 (type_instance_flags): New enum-flags type.
2193 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2194 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2195 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2196 (follow_type_instance_flags): New function.
2197 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2198 * parser-defs.h (follow_type_instance_flags): Declare.
2199 * valops.c (value_struct_elt_for_reference): const/volatile must
2200 match too.
2201
e68cb8e0
PA
22022017-09-04 Pedro Alves <palves@redhat.com>
2203
2204 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2205 function/method scopes; lookup the nested name as a function local
2206 static variable.
2207
858be34c
PA
22082017-09-04 Pedro Alves <palves@redhat.com>
2209
2210 (%type <voidval>): Add function_method.
2211 * c-exp.y (exp): New production for calls with no arguments.
2212 (function_method, function_method_void_or_typelist): New
2213 productions.
2214 (exp): New production for "method()::static_var".
2215 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2216 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2217 Handle OP_FUNC_STATIC_VAR.
2218 * parse.c (operator_length_standard):
2219 Handle OP_FUNC_STATIC_VAR.
2220
dd5901a6
PA
22212017-09-04 Pedro Alves <palves@redhat.com>
2222
2223 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2224 handling.
2225 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2226 Ditto.
2227 * parse.c (operator_length_standard, operator_check_standard):
2228 Ditto.
2229 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2230
46a4882b
PA
22312017-09-04 Pedro Alves <palves@redhat.com>
2232
2233 * ax-gdb.c: Include "typeprint.h".
2234 (gen_expr_for_cast): New function.
2235 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2236 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2237 type is unknown.
2238 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2239 nodebug_data_symbol.
2240 * eval.c: Include "typeprint.h".
2241 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2242 Error out if symbol has unknown type.
2243 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2244 evaluate_subexp_for_cast.
2245 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2246 OP_VAR_MSYM_VALUE.
2247 (evaluate_subexp_for_cast): New function.
2248 * gdbtypes.c (init_nodebug_var_type): New function.
2249 (objfile_type): Use it to initialize types of variables with no
2250 debug info.
2251 * typeprint.c (error_unknown_type): New.
2252 * typeprint.h (error_unknown_type): New declaration.
2253 * compile/compile-c-types.c (convert_type_basic): Handle
2254 TYPE_CODE_ERROR; warn and fallback to int for variables with
2255 unknown type.
2256
fe13dfec
PA
22572017-09-04 Pedro Alves <palves@redhat.com>
2258
2259 * eval.c (evaluate_var_value): New function, factored out from ...
2260 (evaluate_subexp_standard): ... here.
2261
d008ee21
PA
22622017-09-04 Pedro Alves <palves@redhat.com>
2263
2264 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2265 Remove useless assignments to 'op'.
2266
827d0c51
PA
22672017-09-04 Pedro Alves <palves@redhat.com>
2268
2269 * eval.c (eval_skip_value): New function.
2270 (evaluate_subexp_standard): Use it.
2271
2c5a2be1
PA
22722017-09-04 Pedro Alves <palves@redhat.com>
2273
2274 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2275 function name from symbol/minsym and pass it to
2276 error_call_unknown_return_type.
2277
74ea4be4
PA
22782017-09-04 Pedro Alves <palves@redhat.com>
2279
2280 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2281 * ax-gdb.c (gen_msym_var_ref): New function.
2282 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2283 * eval.c (evaluate_var_msym_value): New function.
2284 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2285 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2286 to call_function_by_hand.
2287 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2288 Handle OP_VAR_MSYM_VALUE.
2289 (union exp_element) <msymbol>: New field.
2290 * minsyms.h (struct type): Forward declare.
2291 (find_minsym_type_and_address): Declare.
2292 * parse.c (write_exp_elt_msym): New function.
2293 (write_exp_msymbol): Delete, refactored as ...
2294 (find_minsym_type_and_address): ... this new function.
2295 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2296 (operator_length_standard, operator_check_standard): Handle
2297 OP_VAR_MSYM_VALUE.
2298 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2299
7022349d
PA
23002017-09-04 Pedro Alves <palves@redhat.com>
2301
2302 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2303 TYPE_GNU_IFUNC specially here. Throw error if return type is
2304 unknown.
2305 * ada-typeprint.c (print_func_type): Handle functions with unknown
2306 return type.
2307 * c-typeprint.c (c_type_print_base): Handle functions and methods
2308 with unknown return type.
2309 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2310 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2311 * compile/compile-c-types.c: Include "objfiles.h".
2312 (convert_func): For functions with unknown return type, warn and
2313 default to int.
2314 * compile/compile-object-run.c (compile_object_run): Adjust call
2315 to call_function_by_hand_dummy.
2316 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2317 call_function_by_hand.
2318 * eval.c (evaluate_subexp_standard): Adjust calls to
2319 call_function_by_hand. Handle functions and methods with unknown
2320 return type. Pass expect_type to call_function_by_hand.
2321 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2322 return type.
2323 * gcore.c (call_target_sbrk): Adjust call to
2324 call_function_by_hand.
2325 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2326 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2327 an integer address type instead of nodebug.
2328 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2329 call_function_by_hand.
2330 * infcall.c (error_call_unknown_return_type): New function.
2331 (call_function_by_hand): New "default_return_type" parameter.
2332 Pass it down.
2333 (call_function_by_hand_dummy): New "default_return_type"
2334 parameter. Use it instead of defaulting to int. If there's no
2335 default and the return type is unknown, throw an error. If
2336 there's a default return type, and the called function has no
2337 debug info, then assume the function is prototyped.
2338 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2339 New "default_return_type" parameter.
2340 (error_call_unknown_return_type): New declaration.
2341 * linux-fork.c (call_lseek): Cast return type of lseek.
2342 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2343 call_function_by_hand.
2344 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2345 calls to call_function_by_hand.
2346 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2347 return type.
2348 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2349 (value_nsstring, print_object_command): Adjust calls to
2350 call_function_by_hand.
2351 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2352 functions with unknown return type.
2353 (pascal_type_print_func_varspec_suffix): New function.
2354 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2355 TYPE_CODE_METHOD>: Use it.
2356 * python/py-value.c (valpy_call): Adjust call to
2357 call_function_by_hand.
2358 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2359 call_function_by_hand.
2360 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2361 call_function_by_hand.
2362 * valops.c (value_allocate_space_in_inferior): Adjust call to
2363 call_function_by_hand.
2364 * typeprint.c (type_print_unknown_return_type): New function.
2365 * typeprint.h (type_print_unknown_return_type): New declaration.
2366
54990598
PA
23672017-09-04 Pedro Alves <palves@redhat.com>
2368
2369 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2370 types with more than one parameter as prototyped.
2371
9a24775b
PA
23722017-09-04 Pedro Alves <palves@redhat.com>
2373
2374 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2375 (disassemble_command): Use gdb_disassembly_flags instead of bare
2376 int.
2377 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2378 (dump_insns, do_mixed_source_and_assembly_deprecated)
2379 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2380 Use gdb_disassembly_flags instead of bare int.
2381 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2382 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2383 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2384 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2385 (enum gdb_disassembly_flag): ... values of this new enumeration.
2386 (gdb_disassembly_flags): Define.
2387 (gdb_disassembly)
2388 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2389 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2390 gdb_disassembly_flags instead of bare int.
2391 * record-btrace.c (btrace_insn_history)
2392 (record_btrace_insn_history, record_btrace_insn_history_range)
2393 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2394 instead of bare int.
2395 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2396 Use gdb_disassembly_flags instead of bare int.
2397 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2398 Define.
2399 * target-delegates.c: Regenerate.
2400 * target.c (target_insn_history, target_insn_history_from)
2401 (target_insn_history_range): Use gdb_disassembly_flags instead of
2402 bare int.
2403 * target.h: Include "disasm.h".
2404 (struct target_ops) <to_insn_history, to_insn_history_from,
2405 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2406 int.
2407 (target_insn_history, target_insn_history_from)
2408 (target_insn_history_range): Use gdb_disassembly_flags instead of
2409 bare int.
2410
80a65e9b
SM
24112017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2412
2413 * cli/cli-script.c (build_command_line): For if/while commands,
2414 check whether args is empty.
2415
6b66338c
SM
24162017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2417
2418 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2419 (enum command_control_type): Likewise.
2420 (struct command_line): Likewise.
2421 (free_command_lines): Likewise.
2422 (struct command_lines_deleter): Likewise.
2423 (command_line_up): Likewise.
2424 (read_command_lines): Likewise.
2425 (read_command_lines_1): Likewise.
2426 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2427 (enum command_control_type): Likewise.
2428 (struct command_line): Likewise.
2429 (free_command_lines): Likewise.
2430 (struct command_lines_deleter): Likewise.
2431 (command_line_up): Likewise.
2432 (read_command_lines): Likewise.
2433 (read_command_lines_1): Likewise.
2434 * breakpoint.h: Include cli/cli-script.h.
2435 * extension-priv.h: Likewise.
2436 * gdbcmd.h: Likewise.
2437
51abb421
PA
24382017-09-04 Pedro Alves <palves@redhat.com>
2439
2440 * ada-lang.c (is_known_support_routine): Move sal declaration to
2441 where it is initialized.
2442 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2443 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2444 (clear_command, update_static_tracepoint): Remove init_sal
2445 references. Move declarations closer to initializations.
2446 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2447 initializations.
2448 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2449 references. Move sal declarations closer to initializations.
2450 * frame.c (find_frame_sal): Return a symtab_and_line via function
2451 return instead of output parameter. Remove init_sal references.
2452 * frame.h (find_frame_sal): Return a symtab_and_line via function
2453 return instead of output parameter.
2454 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2455 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2456 instead of memset.
2457 (gdbscm_find_pc_line): Remove init_sal reference.
2458 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2459 references. Move declarations closer to initializations.
2460 * infcmd.c (set_step_frame): Update. Move declarations closer to
2461 initializations.
2462 (finish_backward): Remove init_sal references. Move declarations
2463 closer to initializations.
2464 * infrun.c (process_event_stop_test, handle_step_into_function)
2465 (insert_hp_step_resume_breakpoint_at_frame)
2466 (insert_step_resume_breakpoint_at_caller): Likewise.
2467 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
2468 (symbol_to_sal): Likewise.
2469 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
2470 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
2471 to its initialization.
2472 * reverse.c (save_bookmark_command): Use new/delete. Remove
2473 init_sal references. Move declarations closer to initializations.
2474 * source.c (get_current_source_symtab_and_line): Remove brace
2475 initialization.
2476 (set_current_source_symtab_and_line): Now takes the sal by const
2477 reference. Remove brace initialization.
2478 (line_info): Remove init_sal reference.
2479 * source.h (set_current_source_symtab_and_line): Now takes a
2480 symtab_and_line via const reference.
2481 * stack.c (set_current_sal_from_frame): Adjust.
2482 (print_frame_info): Adjust.
2483 (get_last_displayed_sal): Return the sal via function return
2484 instead of via output parameter. Simplify.
2485 (frame_info): Adjust.
2486 * stack.h (get_last_displayed_sal): Return the sal via function
2487 return instead of via output parameter.
2488 * symtab.c (init_sal): Delete.
2489 (find_pc_sect_line): Remove init_sal references. Move
2490 declarations closer to initializations.
2491 (find_function_start_sal): Remove init_sal references. Move
2492 declarations closer to initializations.
2493 * symtab.h (struct symtab_and_line): In-class initialize all
2494 fields.
2495 * tracepoint.c (set_traceframe_context)
2496 (print_one_static_tracepoint_marker): Remove init_sal references.
2497 Move declarations closer to initializations.
2498 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
2499 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
2500 declarations closer to initializations.
2501 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
2502 init_sal references. Adjust.
2503
6c5b2ebe
PA
25042017-09-04 Pedro Alves <palves@redhat.com>
2505
2506 * ax-gdb.c (agent_command_1): Use range-for.
2507 * break-catch-throw.c (re_set_exception_catchpoint): Update.
2508 * breakpoint.c: Include "common/array-view.h".
2509 (init_breakpoint_sal, create_breakpoint_sal): Change sals
2510 parameter from struct symtabs_and_lines to
2511 array_view<symtab_and_line>. Adjust. Use range-for. Update.
2512 (breakpoint_sals_to_pc): Change sals parameter from struct
2513 symtabs_and_lines to std::vector reference.
2514 (check_fast_tracepoint_sals): Change sals parameter from struct
2515 symtabs_and_lines to std::array_view. Use range-for.
2516 (decode_static_tracepoint_spec): Return a std::vector instead of
2517 symtabs_and_lines. Update.
2518 (create_breakpoint): Update.
2519 (break_range_command, until_break_command, clear_command): Update.
2520 (base_breakpoint_decode_location, bkpt_decode_location)
2521 (bkpt_probe_create_sals_from_location)
2522 (bkpt_probe_decode_location, tracepoint_decode_location)
2523 (tracepoint_probe_decode_location)
2524 (strace_marker_create_sals_from_location): Return a std::vector
2525 instead of symtabs_and_lines.
2526 (strace_marker_create_breakpoints_sal): Update.
2527 (strace_marker_decode_location): Return a std::vector instead of
2528 symtabs_and_lines. Update.
2529 (update_breakpoint_locations): Change struct symtabs_and_lines
2530 parameters to gdb::array_view. Adjust.
2531 (location_to_sals): Return a std::vector instead of
2532 symtabs_and_lines. Update.
2533 (breakpoint_re_set_default): Use std::vector instead of struct
2534 symtabs_and_lines.
2535 (decode_location_default): Return a std::vector instead of
2536 symtabs_and_lines. Update.
2537 * breakpoint.h: Include "common/array-view.h".
2538 (struct breakpoint_ops) <decode_location>: Now returns a
2539 std::vector instead of returning a symtabs_and_lines via output
2540 parameter.
2541 (update_breakpoint_locations): Change sals parameters to use
2542 gdb::array_view.
2543 * cli/cli-cmds.c (edit_command, list_command): Update to use
2544 std::vector and gdb::array_view.
2545 (ambiguous_line_spec): Adjust to use gdb::array_view and
2546 range-for.
2547 (compare_symtabs): Rename to ...
2548 (cmp_symtabs): ... this. Change parameters to symtab_and_line
2549 const reference and adjust.
2550 (filter_sals): Rewrite using std::vector and standard algorithms.
2551 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
2552 (jump_command): Update to use std::vector.
2553 * linespec.c (struct linespec_state) <canonical_names>: Update
2554 comment.
2555 (add_sal_to_sals_basic): Delete.
2556 (add_sal_to_sals, filter_results, convert_results_to_lsals)
2557 (decode_line_2, create_sals_line_offset)
2558 (convert_address_location_to_sals, convert_linespec_to_sals)
2559 (convert_explicit_location_to_sals, parse_linespec)
2560 (event_location_to_sals, decode_line_full, decode_line_1)
2561 (decode_line_with_current_source)
2562 (decode_line_with_last_displayed, decode_objc)
2563 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
2564 (linespec_result::~linespec_result): Adjust to use std::vector
2565 instead of symtabs_and_lines.
2566 * linespec.h (linespec_sals::sals): Now a std::vector.
2567 (struct linespec_result): Use std::vector, bool, and in-class
2568 initialization.
2569 (decode_line_1, decode_line_with_current_source)
2570 (decode_line_with_last_displayed): Return std::vector.
2571 * macrocmd.c (info_macros_command): Use std::vector.
2572 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
2573 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
2574 std::vector.
2575 * probe.h (parse_probes): Return a std::vector.
2576 * python/python.c (gdbpy_decode_line): Use std::vector and
2577 gdb::array_view.
2578 * source.c (select_source_symtab, line_info): Use std::vector.
2579 * stack.c (func_command): Use std::vector.
2580 * symtab.h (struct symtabs_and_lines): Delete.
2581 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
2582
7c44b49c
PA
25832017-09-04 Pedro Alves <palves@redhat.com>
2584
2585 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2586 unittests/array-view-selftests.c.
2587 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
2588 * common/array-view.h: New file.
2589 * unittests/array-view-selftests.c: New file.
2590
e439fa14
PA
25912017-09-04 Pedro Alves <palves@redhat.com>
2592
2593 * cli/cli-cmds.c (edit_command): Pass message to
2594 ambiguous_line_spec.
2595 (list_command): Pass message to ambiguous_line_spec. Say
2596 "first"/"last" instead of "start" and "end" to be consistent with
2597 the manual.
2598 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
2599 them to print formatted message.
2600
7525b645
PA
26012017-09-04 Pedro Alves <palves@redhat.com>
2602
2603 * btrace.c (ftrace_add_pt): Pass btrace_insn to
2604 ftrace_update_insns by reference instead of pointer.
2605
badc0020
YQ
26062017-09-04 Yao Qi <yao.qi@linaro.org>
2607
2608 * i386-go32-tdep.c: Include x86-xstate.h.
2609 (i386_go32_init_abi): Call i386_target_description.
2610 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
2611 if xcr0 is X86_XSTATE_X87_MASK.
2612 * i386-tdep.h (tdesc_i386): Remove the declaration.
2613 (tdesc_i386_mmx): Likewise.
2614
d78bdb54
YQ
26152017-09-04 Yao Qi <yao.qi@linaro.org>
2616
2617 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
2618 X86_XSTATE_SSE_MASK instead of 0.
2619
ca1fa5ee
YQ
26202017-09-04 Yao Qi <yao.qi@linaro.org>
2621
2622 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
2623 i386_target_description.
2624 * i386-fbsd-nat.c (i386fbsd_read_description): Call
2625 i386_target_description.
2626 * i386-tdep.c (i386_gdbarch_init): Likewise.
2627
2434b019
YQ
26282017-09-04 Yao Qi <yao.qi@linaro.org>
2629
2630 * amd64-darwin-tdep.c: Include "x86-xstate.h".
2631 (x86_darwin_init_abi_64): Call amd64_target_description.
2632 * amd64-dicos-tdep.c: Likewise.
2633 * amd64-fbsd-nat.c: Likewise.
2634 * amd64-fbsd-tdep.c: Likewise.
2635 * amd64-nbsd-tdep.c: Likewise.
2636 * amd64-obsd-tdep.c: Likewise.
2637 * amd64-sol2-tdep.c: Likewise.
2638 * amd64-windows-tdep.c: Likewise.
2639 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
2640
0860c437
SM
26412017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2642
2643 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
2644 (btrace_function) <insn>: Change type to use std::vector.
2645 * btrace.c (ftrace_debug, ftrace_call_num_insn,
2646 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
2647 ftrace_update_insns, ftrace_compute_global_level_offset,
2648 btrace_stitch_bts, btrace_clear, btrace_insn_get,
2649 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
2650 change to std::vector.
2651 (ftrace_update_insns): Adjust to change to std::vector, change
2652 type of INSN parameter.
2653 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
2654 * record-btrace.c (btrace_call_history_insn_range,
2655 btrace_compute_src_line_range,
2656 record_btrace_frame_prev_register): Adjust to change to
2657 std::vector.
2658 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
2659 to change to std::vector.
2660
0638b7f9
TT
26612017-09-03 Tom Tromey <tom@tromey.com>
2662
2663 * corefile.c (reopen_exec_file): Use std::string.
2664
8f84fb0e
TT
26652017-09-03 Tom Tromey <tom@tromey.com>
2666
2667 * compile/compile.c (compile_register_name_mangled): Return
2668 std::string.
2669 * compile/compile-loc2c.c (pushf_register_address): Update.
2670 (pushf_register): Update.
2671 * compile/compile-c-types.c (convert_array): Update.
2672 * compile/compile-c-symbols.c (generate_vla_size): Update.
2673 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
2674 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
2675 (convert_one_symbol): Update.
2676 (generate_c_for_for_one_variable): Update.
2677 * compile/compile-c-support.c (c_get_range_decl_name): Return a
2678 std::string.
2679 (generate_register_struct): Update.
2680 * compile/compile-internal.h (c_get_range_decl_name): Return a
2681 std::string.
2682 (compile_register_name_mangled): Return std::string.
2683
18e9961f
TT
26842017-09-03 Tom Tromey <tom@tromey.com>
2685
2686 * utils.c (perror_string): Return a std::string.
2687 (throw_perror_with_name, perror_warning_with_name): Update.
2688
45343786
TT
26892017-09-03 Tom Tromey <tom@tromey.com>
2690
2691 * demangle.c (demangle_command): Use std::string,
2692 unique_xmalloc_ptr.
2693
b57af503
TT
26942017-09-03 Tom Tromey <tom@tromey.com>
2695
2696 * cli/cli-setshow.c (do_set_command): Use std::string.
2697
6eecf35f
TT
26982017-09-03 Tom Tromey <tom@tromey.com>
2699
2700 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
2701
56496dd4
TT
27022017-09-03 Tom Tromey <tom@tromey.com>
2703
2704 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
2705
e91a1fa7
TT
27062017-09-03 Tom Tromey <tom@tromey.com>
2707
2708 * mi/mi-cmd-env.c (env_execute_cli_command): Use
2709 gdb::unique_xmalloc_ptr.
2710
7ffd83d7
TT
27112017-09-03 Tom Tromey <tom@tromey.com>
2712
2713 * thread.c (print_thread_info_1): Use string_printf.
2714 (thread_apply_command, thread_apply_all_command): Use
2715 std::string.
2716
1ccbe998
TT
27172017-09-03 Tom Tromey <tom@tromey.com>
2718
2719 * valprint.c (val_print_string): Update.
2720 * gdbcore.h (memory_error_message): Return std::string.
2721 * corefile.c (memory_error_message): Return std::string.
2722 (memory_error): Update.
2723 * breakpoint.c (insert_bp_location): Update.
2724
23fdd69e
SM
27252017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2726
2727 * target/waitstatus.h (target_waitstatus_to_string): Change
2728 return type to std::string.
2729 * target/waitstatus.c (target_waitstatus_to_string): Return
2730 std::string.
2731 * target.h (target_waitstatus_to_string): Remove declaration.
2732 * infrun.c (resume, clear_proceed_status_thread,
2733 print_target_wait_results, do_target_wait, save_waitstatus,
2734 stop_all_threads): Adjust.
2735 * record-btrace.c (record_btrace_wait): Adjust.
2736 * target-debug.h
2737 (target_debug_print_struct_target_waitstatus_p): Adjust.
2738
5c811d30
JK
27392017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
2740
2741 PR gdb/22046
2742 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
2743 detection.
2744
0a2dde4a
SDJ
27452017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2746
2747 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
2748 for setting/unsetting environment variables on the remote target.
2749 (New remote packets): Add entries for QEnvironmentHexEncoded,
2750 QEnvironmentUnset and QEnvironmentReset.
2751 * common/environ.c (gdb_environ::operator=): Extend method to
2752 handle m_user_set_env_list and m_user_unset_env_list.
2753 (gdb_environ::clear): Likewise.
2754 (match_var_in_string): Change type of first parameter from 'char
2755 *' to 'const char *'.
2756 (gdb_environ::set): Extend method to handle
2757 m_user_set_env_list and m_user_unset_env_list.
2758 (gdb_environ::unset): Likewise.
2759 (gdb_environ::clear_user_set_env): New method.
2760 (gdb_environ::user_set_envp): Likewise.
2761 (gdb_environ::user_unset_envp): Likewise.
2762 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
2763 m_user_unset_env_list on move constructor/assignment.
2764 (unset): Add new default parameter 'update_unset_list = true'.
2765 (clear_user_set_env): New method.
2766 (user_set_envp): Likewise.
2767 (user_unset_envp): Likewise.
2768 (m_user_set_env_list): New std::set.
2769 (m_user_unset_env_list): Likewise.
2770 * common/rsp-low.c (hex2str): New function.
2771 (bin2hex): New overload for bin2hex function.
2772 * common/rsp-low.c (hex2str): New prototype.
2773 (str2hex): New overload prototype.
2774 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
2775 QEnvironmentUnset and QEnvironmentReset.
2776 (remote_protocol_features): Add QEnvironmentHexEncoded,
2777 QEnvironmentUnset and QEnvironmentReset packets.
2778 (send_environment_packet): New function.
2779 (extended_remote_environment_support): Likewise.
2780 (extended_remote_create_inferior): Call
2781 extended_remote_environment_support.
2782 (_initialize_remote): Add QEnvironmentHexEncoded,
2783 QEnvironmentUnset and QEnvironmentReset packet configs.
2784 * unittests/environ-selftests.c (gdb_selftest_env_var):
2785 New variable.
2786 (test_vector_initialization): New function.
2787 (test_init_from_host_environ): Likewise.
2788 (test_reinit_from_host_environ): Likewise.
2789 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
2790 Likewise.
2791 (test_unset_set_empty_vector): Likewise.
2792 (test_vector_clear): Likewise.
2793 (test_std_move): Likewise.
2794 (test_move_constructor):
2795 (test_self_move): Likewise.
2796 (test_set_unset_reset): Likewise.
2797 (run_tests): Rewrite in terms of the functions above.
2798
654670a4
WP
27992017-08-31 Weimin Pan <weimin.pan@oracle.com>
2800
2801 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
2802 (adi_available): Use a temp variable of type CORE_ADDR as argument
2803 3 when calling target_auxv_search.
2804 (adi_normalize_address): Use masks and xor operators to calculate
2805 normalized address.
2806 (adi_read_versions, adi_write_versions, adi_print_versions)
2807 (do_examine, do_assign): Use paddress.
2808
7755ddb7
JB
28092017-08-29 John Baldwin <jhb@FreeBSD.org>
2810
2811 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
2812 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
2813 out of loop and add supply of FIR.
2814 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
2815 add collect of FIR.
2816
fd437cbc
SM
28172017-08-28 Simon Marchi <simon.marchi@ericsson.com>
2818
3804a343 2819 PR gdb/21827
fd437cbc
SM
2820 * cli/cli-script.c (define_command): Don't convert command name
2821 to lower case.
2822
988f6b3d
JB
28232017-08-25 Joel Brobecker <brobecker@adacore.com>
2824
2825 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
2826 Update all callers accordingly. Remove all code blocks handling
2827 the case where DISPP is not NULL.
2828
663c44ac
JK
28292017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2830
2831 PR symtab/22003
2832 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
2833 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
2834 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
2835
f1902523
JK
28362017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
2837
2838 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
2839 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
2840 (read_comp_units_from_section): New parameter abbrev_section, use
2841 read_and_check_comp_unit_head, allocate signatured_type if needed.
2842 (create_all_comp_units): Update read_comp_units_from_section caller.
2843
87215ad1
SDJ
28442017-08-23 Pedro Alves <palves@redhat.com>
2845
2846 PR remote/21852
2847 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
2848 to null_ptid and switch to thread without reading the registers
2849 after adding the inferior.
2850
6e41ddec
JK
28512017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2852
2853 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
2854 compile-gcc.
2855 * compile/compile.c (compile_gcc, show_compile_gcc): New.
2856 (compile_to_object): Implement compile_gcc.
2857 (_initialize_compile): Install "set compile-gcc". Initialize
2858 compile_gcc.
2859
e68c32d5
JK
28602017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
2861
2862 * compile/compile.c (compile_to_object): Conditionally call
2863 set_verbose. Conditionally call compile or compile_v0.
2864
58afddc6
WP
28652017-08-07 Weimin Pan <weimin.pan@oracle.com>
2866
2867 * sparc64-tdep.h: (adi_normalize_address): New export.
2868 * sparc-nat.h: (open_adi_tag_fd): New export.
2869 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
2870 * sparc64-linux-tdep.c:
2871 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
2872 (sparc64_linux_handle_segmentation_fault): New function.
2873 (sparc64_linux_init_abi): Register
2874 sparc64_linux_handle_segmentation_fault
2875 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
2876 (sparc64_addr_bits_remove): New function.
2877 (sparc64_init_abi): Register sparc64_addr_bits_remove.
2878 (MAX_PROC_NAME_SIZE): New macro.
2879 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
2880 (sparc64adilist): New variable.
2881 (adi_proc_list): New variable.
2882 (find_adi_info): New function.
2883 (add_adi_info): New function.
2884 (get_adi_info_proc): New function.
2885 (get_adi_info): New function.
2886 (info_adi_command): New function.
2887 (read_maps_entry): New function.
2888 (adi_available): New function.
2889 (adi_normalize_address): New function.
2890 (adi_align_address): New function.
2891 (adi_convert_byte_count): New function.
2892 (adi_tag_fd): New function.
2893 (adi_is_addr_mapped): New function.
2894 (adi_read_versions): New function.
2895 (adi_write_versions): New function.
2896 (adi_print_versions): New function.
2897 (do_examine): New function.
2898 (do_assign): New function.
2899 (adi_examine_command): New function.
2900 (adi_assign_command): New function.
2901 (_initialize_sparc64_adi_tdep): New function.
2902
11db9430
SM
29032017-08-22 Simon Marchi <simon.marchi@ericsson.com>
2904
2905 * breakpoint.c (breakpoints_info): Rename to ...
2906 (info_breakpoints_command): ... this.
2907 (watchpoints_info): Rename to ...
2908 (info_watchpoints_command): ... this.
2909 (tracepoints_info): Rename to ...
2910 (info_tracepoints_command): ... this.
2911 (_initialize_breakpoint): Adjust.
2912 * dcache.c (dcache_info): Rename to ...
2913 (info_display_command): ... this.
2914 (_initialize_dcache): Adjust.
2915 * frame.h (args_info): Rename to ...
2916 (info_args_command): ... this.
2917 (locals_info): Rename to ...
2918 (info_locals_command): ... this.
2919 * infcmd.c (nofp_registers_info): Rename to ...
2920 (info_registers_command): ... this.
2921 (float_info): Rename to ...
2922 (info_float_command): ... this.
2923 (program_info): Rename to ...
2924 (info_program_command): ... this.
2925 (all_registers_info): Rename to ...
2926 (info_all_registers_command): ... this.
2927 (vector_info): Rename to ...
2928 (info_vector_command): ... this.
2929 (float_info): Rename to ...
2930 (info_float_command): ... this.
2931 (_initialize_infcmd): Adjust.
2932 * inferior.h (term_info): Rename to ...
2933 (info_terminal_command): ... this.
2934 * inflow.c (term_info): Rename to ...
2935 (info_terminal_command): ... this.
2936 (_initialize_inflow): Adjust.
2937 * infrun.c (signals_info): Rename to ...
2938 (info_signals_command): ... this.
2939 (_initialize_infrun): Adjust.
2940 * objc-lang.c (classes_info): Rename to ...
2941 (info_classes_command): ... this.
2942 (selectors_info): Rename to ...
2943 (info_selectors_command): ... this.
2944 (_initialize_objc_language): Adjust.
2945 * printcmd.c (sym_info): Rename to ...
2946 (info_symbol_command): ... this.
2947 (address_info): Rename to ...
2948 (info_address_command): ... this.
2949 (display_info): Rename to ...
2950 (info_display_command): ... this.
2951 (_initialize_printcmd): Adjust.
2952 * reverse.c (bookmarks_info): Rename to ...
2953 (info_breakpoints_command): ... this.
2954 (_initialize_reverse): Adjust.
2955 * ser-go32.c (dos_info): Rename to ...
2956 (info_serial_command): ... this.
2957 (_initialize_ser_dos): Adjust.
2958 * skip.c (skip_info): Rename to ...
2959 (info_skip_command): ... this.
2960 (_initialize_step_skip): Adjust.
2961 * source.c (line_info): Rename to ...
2962 (info_line_command): ... this.
2963 (source_info): Rename to ...
2964 (info_source_command)
2965 * stack.c (frame_info): Rename to ...
2966 (info_frame_command): ... this.
2967 (locals_info): Rename to ...
2968 (info_locals_command): ... this.
2969 (args_info): Rename to ...
2970 (info_args_command): ... this.
2971 (_initialize_stack): Adjust.
2972 * symtab.c (sources_info): Rename to ...
2973 (info_sources_command): ... this.
2974 (variables_info): Rename to ...
2975 (info_variables_command): ... this.
2976 (functions_info): Rename to ...
2977 (info_functions_command): ... this.
2978 (types_info): Rename to ...
2979 (info_types_command): ... this.
2980 (_initialize_symtab): Adjust.
2981 * target.c (target_info): Rename to ...
2982 (info_target_command): ... this.
2983 (initialize_targets): Adjust.
2984 * tracepoint.c (tvariables_info): Rename to ...
2985 (info_tvariables_command): ... this.
2986 (scope_info): Rename to ...
2987 (info_scope_command): ... this.
2988 (trace_dump_actions): Adjust.
2989 (_initialize_tracepoint): Adjust.
2990
b270e6f9
TT
29912017-08-22 Tom Tromey <tom@tromey.com>
2992
2993 * breakpoint.h (install_breakpoint): Update.
2994 * breakpoint.c (add_solib_catchpoint): Update.
2995 (install_breakpoint): Change argument to a std::unique_ptr.
2996 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
2997 (create_breakpoint_sal, create_breakpoint): Update.
2998 (watch_command_1, catch_exec_command_1)
2999 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
3000 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
3001 Return the breakpoint.
3002 (set_raw_breakpoint_without_location, set_raw_breakpoint)
3003 (new_single_step_breakpoint): Update.
3004 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
3005 std::unique_ptr.
3006 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3007 std::unique_ptr.
3008 * break-catch-sig.c (create_signal_catchpoint): Use
3009 std::unique_ptr.
3010 * ada-lang.c (create_ada_exception_catchpoint): Use
3011 std::unique_ptr.
3012
36bd8eaa
TT
30132017-08-22 Tom Tromey <tom@tromey.com>
3014
3015 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
3016
56f37645
TT
30172017-08-22 Tom Tromey <tom@tromey.com>
3018
3019 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
3020 (lookup_partial_symbol): Update.
3021
0b581c69
TT
30222017-08-22 Tom Tromey <tom@tromey.com>
3023
3024 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
3025 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
3026 (find_and_open_source, symtab_to_fullname): Update.
3027 * psymtab.c (psymtab_to_fullname): Update.
3028
14278e1f
TT
30292017-08-22 Tom Tromey <tom@tromey.com>
3030
3031 * exec.c (exec_file_attach): Update.
3032 * linux-thread-db.c (try_thread_db_load): Update.
3033 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
3034 * utils.c (gdb_realpath): Change return type.
3035 (gdb_realpath_keepfile): Update.
3036 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
3037 (_initialize_utils): Register the new self test.
3038 * source.c (openp): Update.
3039 (find_and_open_source): Update.
3040 * nto-tdep.c (nto_find_and_open_solib): Update.
3041 * main.c (set_gdb_data_directory): Update.
3042 (captured_main_1): Update.
3043 * dwarf2read.c (dwarf2_get_dwz_file): Update
3044 (dw2_map_symbol_filenames): Update.
3045 * auto-load.c (auto_load_safe_path_vec_update): Update.
3046 (filename_is_in_auto_load_safe_path_vec): Change type of
3047 "filename_realp".
3048 (auto_load_objfile_script): Update.
3049 (file_is_auto_load_safe): Update. Use std::string.
3050 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
3051
4971c9a7
TT
30522017-08-22 Tom Tromey <tom@tromey.com>
3053
3054 * utils.c (gdb_realpath_keepfile): Return a
3055 gdb::unique_xmalloc_ptr.
3056 * exec.c (exec_file_attach): Update.
3057 * utils.h (gdb_realpath_keepfile): Return a
3058 gdb::unique_xmalloc_ptr.
3059
e3e41d58
TT
30602017-08-22 Tom Tromey <tom@tromey.com>
3061
3062 * compile/compile.c (compile_file_command): Use
3063 gdb::unique_xmalloc_ptr, std::string.
3064 * utils.c (gdb_abspath): Change return type.
3065 * source.c (openp): Update.
3066 * objfiles.c (allocate_objfile): Update.
3067 * main.c (set_gdb_data_directory): Update.
3068 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
3069
0d999a6e
ZZ
30702017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
3071
3072 * cli-cmds.c (list_commands): List actual code around more than
3073 one location.
3074
329d5e7e
JB
30752017-08-21 John Baldwin <jhb@FreeBSD.org>
3076
3077 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
3078
bf223d3e
PA
30792017-08-21 Pedro Alves <palves@redhat.com>
3080
3081 PR gdb/19487
3082 * c-exp.y (variable production): Handle function aliases.
3083 * minsyms.c (msymbol_is_text): New function.
3084 * minsyms.h (msymbol_is_text): Declare.
3085 * symtab.c (find_function_alias_target): New function.
3086 * symtab.h (find_function_alias_target): Declare.
3087
c973d0aa
PA
30882017-08-21 Pedro Alves <palves@redhat.com>
3089
3090 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
3091 typedefs.
3092 * typeprint.c (whatis_exp): If handling "whatis", and expression
3093 is OP_TYPE, strip one typedef level. Otherwise don't strip
3094 typedefs here.
3095 * valops.c (value_cast): Save "to" type before resolving
3096 stubs/typedefs. Use that type as resulting value's type.
3097
2989a365
TT
30982017-08-18 Tom Tromey <tom@tromey.com>
3099 Pedro Alves <palves@redhat.com>
3100
3101 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
3102 * sol-thread.c (sol_thread_resume, sol_thread_wait)
3103 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
3104 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
3105 * proc-service.c (ps_xfer_memory): Use scoped_restore.
3106 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
3107 (linux_get_siginfo_data): Add "thread" argument. Use
3108 scoped_restore.
3109 * linux-nat.c (linux_child_follow_fork)
3110 (check_stopped_by_watchpoint): Use scoped_restore.
3111 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
3112 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
3113 (restore_inferior_ptid, save_inferior_ptid): Remove.
3114 * btrace.c (btrace_fetch): Use scoped_restore.
3115 * bsd-uthread.c (bsd_uthread_fetch_registers)
3116 (bsd_uthread_store_registers): Use scoped_restore.
3117 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
3118 scoped_restore.
3119 * aix-thread.c (aix_thread_resume, aix_thread_wait)
3120 (aix_thread_xfer_partial): Use scoped_restore.
3121 * inferior.h (save_inferior_ptid): Remove.
3122
e60eb288
YQ
31232017-08-18 Yao Qi <yao.qi@linaro.org>
3124
3125 PR tdep/21818
3126 * arm-tdep.c (gdb_print_insn_arm): Mark
3127 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
3128
6d580b63
YQ
31292017-08-18 Yao Qi <yao.qi@linaro.org>
3130
3131 * NEWS: Mention GDBserver's new option "--selftest".
3132 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
3133 * selftest.c: Move it to common/selftest.c.
3134 * selftest.h: Move it to common/selftest.h.
3135 * selftest-arch.c (reset): New function.
3136 (tests_with_arch): Call reset.
3137
86dcbf50
YQ
31382017-08-18 Yao Qi <yao.qi@linaro.org>
3139
3140 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
3141 instead of exception_fprintf and printf_filtered.
3142
7649770c
YQ
31432017-08-18 Yao Qi <yao.qi@linaro.org>
3144
3145 * selftest.c (register_self_test): Rename it to
3146 selftests::register_test.
3147 (run_self_tests): selftest::run_tests.
3148 * selftest.h: Update declarations.
3149 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
3150 selftests::register_test_foreach_arch.
3151 * selftest-arch.h: Update declaration.
3152 * aarch64-tdep.c: Update.
3153 * arm-tdep.c: Likewise.
3154 * disasm-selftests.c: Likewise.
3155 * dwarf2loc.c: Likewise.
3156 * dwarf2-frame.c: Likewise.
3157 * findvar.c: Likewise.
3158 * gdbarch-selftests.c: Likewise.
3159 * maint.c (maintenance_selftest): Likewise.
3160 * regcache.c: Likewise.
3161 * rust-exp.y: Likewise.
3162 * selftest-arch.c: Likewise.
3163 * unittests/environ-selftests.c: Likewise.
3164 * unittests/function-view-selftests.c: Likewise.
3165 * unittests/offset-type-selftests.c: Likewise.
3166 * unittests/optional-selftests.c: Likewise.
3167 * unittests/scoped_restore-selftests.c: Likewise.
3168 * utils-selftests.c: Likewise.
3169
b0cba12e
PA
31702017-08-17 Pedro Alves <palves@redhat.com>
3171
3172 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
3173 local.
3174
4c8aa72d
PA
31752017-08-17 Pedro Alves <palves@redhat.com>
3176
3177 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3178 field.
3179 (reset_die_in_process): Delete, replaced by ...
3180 (process_die_scope): ... this new class. Make it responsible for
3181 freeing cu->line_header too.
3182 (process_die): Use process_die_scope.
3183 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3184 cu->line_header_die_owner. Don't release the line header if it's
3185 owned by the CU.
3186 (setup_type_unit_groups): Make the CU/DIE own the line header.
3187 Don't release the line header here.
3188
ba713918
AL
31892017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3190
3191 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3192
44d0fb3a
RK
31932017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3194
3195 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3196 Single-Key mode
3197
a5afdb16
RK
31982017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3199
3200 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3201 mode command list.
3202
47613aeb
SH
32032017-08-15 Stafford Horne <shorne@gmail.com>
3204
3205 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3206
9c3cc999
SH
32072017-08-15 Stafford Horne <shorne@gmail.com>
3208
3209 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3210
206726fb
SDJ
32112017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3212
3213 PR gdb/21954
3214 * infcmd.c (unset_environment_command): Use the 'clear' method on
3215 the environment instead of resetting it.
3216
0335ac6d
JB
32172017-08-15 John Baldwin <jhb@FreeBSD.org>
3218
3219 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3220 platforms.
3221
d3abe1c8
TT
32222017-08-14 Tom Tromey <tom@tromey.com>
3223
3224 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3225 (print_binary_chars): Likewise.
3226 (BITS_IN_BYTES): Remove.
3227
d6382fff
TT
32282017-08-14 Tom Tromey <tom@tromey.com>
3229
3230 PR gdb/21675
3231 * valprint.c (LOW_ZERO): Change value to 034.
3232 (print_octal_chars): Add static_asserts for octal constants.
3233 * printcmd.c (print_scalar_formatted): Add 'd' case.
3234
f978cb06
TT
32352017-08-11 Tom Tromey <tom@tromey.com>
3236
3237 * symfile.c (add_symbol_file_command): Use std::vector.
3238
2f5404b3
TT
32392017-08-14 Tom Tromey <tom@tromey.com>
3240
3241 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3242 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3243 std::move.
3244 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3245
de7985c3
PA
32462017-08-11 Pedro Alves <palves@redhat.com>
3247
3248 * infrun.c (process_event_stop_test): Adjust
3249 function_name_is_marked_for_skip call.
3250 * skip.c: Include <list>.
3251 (skiplist_entry): Make it a class with private fields, and
3252 getters/setters.
3253 (skiplist_entry_chain): Delete.
3254 (skiplist_entries): New.
3255 (skiplist_entry_count): Delete.
3256 (highest_skiplist_entry_num): New.
3257 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3258 (add_skiplist_entry): Delete.
3259 (skiplist_entry::skiplist_entry): New.
3260 (skiplist_entry::add_entry): New.
3261 (skip_file_command, skip_function): Adjust.
3262 (compile_skip_regexp): Delete.
3263 (skip_command): Don't compile regexp here. Adjust to use
3264 skiplist_entry::add_entry.
3265 (skip_info): Adjust to use range-for and getters.
3266 (skip_enable_command, skip_disable_command): Adjust to use
3267 range-for and setters.
3268 (skip_delete_command): Adjust to use std::list.
3269 (add_skiplist_entry): Delete.
3270 (skip_file_p): Delete, refactored as ...
3271 (skiplist_entry::do_skip_file_p): ... this new method.
3272 (skip_gfile_p): Delete, refactored as ...
3273 (skiplist_entry::do_gskip_file_p): ... this new method.
3274 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3275 (skiplist_entry::skip_function_p): ... this new method.
3276 (function_name_is_marked_for_skip): Now returns bool, and takes
3277 the function sal by const reference. Adjust to use range-for and
3278 skiplist_entry methods.
3279 (_initialize_step_skip): Remove references to
3280 skiplist_entry_chain, skiplist_entry_count.
3281 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3282 takes the function sal by const reference.
3283
be7d3cd5
YQ
32842017-08-11 Yao Qi <yao.qi@linaro.org>
3285
3286 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3287 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3288 (dwarf2_frame_cache):
3289 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3290 RETURN_MASK_ALL and set *this_case to NULL.
3291 * frame-unwind.h: Update comments.
3292
1c90d9f0
YQ
32932017-08-11 Yao Qi <yao.qi@linaro.org>
3294
3295 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3296 (dwarf2_frame_state_copy_regs): Remove.
3297 (dwarf2_frame_state_free_regs): Remove.
3298 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3299 (dwarf2_restore_rule): Call method .alloc_regs instead of
3300 dwarf2_frame_state_alloc_regs.
3301 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3302 constructor. Call std::move.
3303 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3304 (dwarf2_frame_cache): Likewise.
3305
3306 [GDB_SELF_TEST]: Include selftest.h and
3307 selftest-arch.h.
3308 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3309 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3310 execute_cfa_program_test.
3311
3312 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3313 copy ctor, assignment operator, move assignment.
3314 <alloc_regs>: New method.
3315 <swap>: New method.
3316 (struct dwarf2_frame_state): Delete dtor.
3317 (dwarf2_frame_state_alloc_regs): Remove declaration.
3318 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3319 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3320
afe37d6b
YQ
33212017-08-11 Yao Qi <yao.qi@linaro.org>
3322
3323 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3324 (dwarf2_frame_state::dwarf2_frame_state): New.
3325 (dwarf2_frame_state::~dwarf2_frame_state): New.
3326 (dwarf2_fetch_cfa_info): Update.
3327 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3328 rather than a pointer. Update code.
3329 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3330 dtor.
3331 <data_align, code_align, retaddr_column>: Change them to const.
3332 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3333 to bool.
3334
b348037f
YQ
33352017-08-11 Yao Qi <yao.qi@linaro.org>
3336
3337 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3338 <loc.exp>: New field.
3339 * dwarf2-frame.c (execute_cfa_program): Update.
3340 (dwarf2_frame_prev_register): Update.
3341
e7c9de26
PA
33422017-08-10 Pedro Alves <palves@redhat.com>
3343
3344 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3345
e8c6b620
JB
33462017-08-09 John Baldwin <jhb@FreeBSD.org>
3347
3348 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3349 (fbsd_pending_children): Use std::list.
3350 (fbsd_remember_child): Likewise.
3351 (fbsd_is_child_pending): Likewise.
3352 (fbsd_pending_vfork_done): Use std::forward_list.
3353 (fbsd_add_vfork_done): Likewise.
3354 (fbsd_is_vfork_done_pending): Likewise.
3355 (fbsd_next_vfork_done): Likewise.
3356
e4a26669
JB
33572017-08-09 John Baldwin <jhb@FreeBSD.org>
3358
3359 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3360 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3361 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3362 for `mapfilename'.
3363 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 3364 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 3365
142311d3
JB
33662017-08-09 John Baldwin <jhb@FreeBSD.org>
3367
3368 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3369 "filestuff.h".
3370 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3371
42fa2e0e
TT
33722017-08-09 Tom Tromey <tom@tromey.com>
3373
3374 * skip.c (skiplist_entry): New constructor.
3375 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3376 (skiplist_entry::file_is_glob): Now bool.
3377 (skiplist_entry::file, skiplist_entry::function): Now
3378 std::string.
3379 (make_skip_entry): Return a unique_ptr. Use new.
3380 (free_skiplist_entry, free_skiplist_entry_cleanup)
3381 (make_free_skiplist_entry_cleanup): Remove.
3382 (skip_command, skip_disable_command, add_skiplist_entry)
3383 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3384 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3385 (function_name_is_marked_for_skip): Update.
3386 (skip_delete_command): Update. Use delete.
3387
cd3af38d
JW
33882017-08-09 Jiong Wang <jiong.wang@arm.com>
3389
3390 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3391 (aarch64_linux_core_read_description): New function.
3392 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3393
29592bde
PA
33942017-08-09 Pedro Alves <palves@redhat.com>
3395
3396 * cp-name-parser.y (cp_comp_to_string): Return a
3397 gdb::unique_xmalloc_ptr<char>.
3398 * cp-support.c (replace_typedefs_qualified_name)
3399 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3400 (cp_canonicalize_string_full): Use op= instead of explicit
3401 convertion.
3402 (cp_class_name_from_physname, method_name_from_physname)
3403 (cp_func_name, cp_remove_params): Adjust to use
3404 gdb::unique_xmalloc_ptr<char>.
3405 * cp-support.h (cp_comp_to_string): Return a
3406 gdb::unique_xmalloc_ptr<char>.
3407 * python/py-type.c (typy_lookup_type): Adjust to use
3408 gdb::unique_xmalloc_ptr<char>.
3409
b3340438
L
34102017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3411
3412 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3413
e88e8651
YQ
34142017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3415 Yao Qi <yao.qi@linaro.org>
3416
3417 * cp-support.c (cp_canonicalize_string_full): Use
3418 gdb::unique_xmalloc_ptr<char>.
3419 (cp_canonicalize_string): Likewise.
3420
f5a29eb0
YQ
34212017-08-09 Yao Qi <yao.qi@linaro.org>
3422
3423 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3424 * regformats/i386/amd64-avx-avx512.dat: Remove.
3425 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3426 * regformats/i386/amd64-avx-mpx.dat:Remove.
3427 * regformats/i386/amd64-avx.dat: Remove.
3428 * regformats/i386/amd64-mpx.dat: Remove.
3429 * regformats/i386/i386-avx-avx512.dat: Remove.
3430 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3431 * regformats/i386/i386-avx-mpx.dat: Remove.
3432 * regformats/i386/i386-mmx.dat: Remove.
3433 * regformats/i386/i386-mpx.dat: Remove.
3434
57757c2f
YQ
34352017-08-09 Yao Qi <yao.qi@linaro.org>
3436
3437 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3438 * amd64-tdep.c: Don't include features/i386/x32*.c.
3439 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3440 functions.
3441 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3442 and i386/x32-avx-avx512.
3443 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3444 and i386/x32.xml.
3445 * features/i386/x32-avx-avx512.c: Removed.
3446 * features/i386/x32-avx-avx512.xml: Removed.
3447 * features/i386/x32-avx.c: Removed.
3448 * features/i386/x32-avx.xml: Removed.
3449 * features/i386/x32.c: Removed.
3450 * features/i386/x32.xml: Removed.
3451 * regformats/i386/x32-avx-avx512.dat: Removed.
3452 * regformats/i386/x32-avx.dat: Removed.
3453 * regformats/i386/x32.dat: Removed.
3454
ba7b109b
MR
34552017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3456
3457 PR breakpoints/21886
3458 * mem-break.c (default_memory_insert_breakpoint): Use
3459 `->placed_address' rather than `->reqstd_address' for the
3460 breakpoint location.
3461
e347efc3
MR
34622017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3463
3464 * arch-utils.c (default_print_insn): Remove arch/mach/endian
3465 assertions.
3466
0dba2a6c
MR
34672017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3468
3469 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
3470 a union of `tdep_info', `tdesc_data' and `id'.
3471 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
3472 rather than `info.tdep_info'.
3473 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
3474 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
3475 * i386-tdep.c (i386_gdbarch_init): Likewise.
3476 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
3477 * mips-tdep.c (mips_gdbarch_init): Likewise.
3478 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
3479 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
3480 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
3481 `info.tdep_info'.
3482 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
3483 `info.tdep_info'.
3484 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
3485 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
3486 `info.tdep_info'.
3487 * spu-tdep.c (spu_gdbarch_init): Likewise.
3488 * gdbarch.h: Regenerate.
3489
16eb6b2d
LS
34902017-08-07 Leszek Swirski <leszeks@google.com>
3491
7b005726 3492 PR symtab/20899
16eb6b2d
LS
3493 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
3494
74cbb09e
SM
34952017-08-07 Simon Marchi <simon.marchi@ericsson.com>
3496
3497 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
3498 (gdbsim_open): Rename gdb_argv args object to argv.
3499
ee0c3293
TT
35002017-08-05 Tom Tromey <tom@tromey.com>
3501
3502 * compile/compile-object-load.c (compile_object_load): Use
3503 gdb::unique_xmalloc_ptr.
3504 * cli/cli-dump.c (scan_filename): Rename from
3505 scan_filename_with_cleanup. Change return type.
3506 (scan_expression): Rename from scan_expression_with_cleanup.
3507 Change return type.
3508 (dump_memory_to_file, dump_value_to_file, restore_command):
3509 Use gdb::unique_xmalloc_ptr. Update.
3510 * cli/cli-cmds.c (find_and_open_script): Use
3511 gdb::unique_xmalloc_ptr.
3512 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
3513 * symmisc.c (maintenance_print_symbols)
3514 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
3515 * symfile.c (symfile_bfd_open, generic_load)
3516 (add_symbol_file_command, remove_symbol_file_command): Use
3517 gdb::unique_xmalloc_ptr.
3518 * source.c (openp): Use gdb::unique_xmalloc_ptr.
3519 * psymtab.c (maintenance_print_psymbols): Use
3520 gdb::unique_xmalloc_ptr.
3521 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
3522 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
3523 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
3524 (reload_shared_libraries_1): Likewise.
3525
3232fabd
TT
35262017-08-05 Tom Tromey <tom@tromey.com>
3527
3528 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
3529 (rust_op_vector, rust_set_vector): New typedefs.
3530 (current_parser): New global.
3531 (work_obstack): Change to pointer type. Update all users.
3532 (rust_ast, pstate): Remove globals.
3533 (struct rust_parser): New.
3534 (%union) <params, field_inits>: Change type.
3535 (start, tuple_expr, unit_expr, struct_expr_list, literal)
3536 (field_expr, expr_list, maybe_expr_list, type_list): Update.
3537 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
3538 (convert_params_to_types, convert_params_to_expression): Change
3539 type of "params".
3540 (ast_string): Change type of "fields".
3541 (rust_parse): Make a rust_parser. Remove cleanups.
3542 (rust_lex_tests): Make and install an auto_obstack.
3543
f02fd774
YQ
35442017-08-04 Yao Qi <yao.qi@linaro.org>
3545
3546 * configure.srv (ipa_x32_linux_regobj): New.
3547 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
3548 instead of X86_TDESC_AVX512.
3549 (initialize_low_tracepoint): Call
3550 init_registers_x32_avx_avx512_linux.
3551
91975afd
YQ
35522017-08-04 Yao Qi <yao.qi@linaro.org>
3553
3554 * utils.h (gdb_argv): Add namespace std for nullptr_t.
3555
2331fa3a
RK
35562017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
3557
3558 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
3559
744e4fe1
TT
35602017-08-03 Tom Tromey <tom@tromey.com>
3561
3562 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
3563 Remove.
3564 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
3565
1c034b67
TT
35662017-08-03 Tom Tromey <tom@tromey.com>
3567
3568 * python/py-param.c (compute_enum_values): Use gdb_argv.
3569
773a1edc
TT
35702017-08-03 Tom Tromey <tom@tromey.com>
3571
3572 * utils.h (struct gdb_argv_deleter): New.
3573 (gdb_argv): New class.
3574 * utils.c (gdb_argv::reset): New method.
3575 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
3576 * tracefile.c (tsave_command): Use gdb_argv.
3577 * top.c (new_ui_command): Use gdb_argv.
3578 * symmisc.c (maintenance_print_symbols)
3579 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
3580 * symfile.c (symbol_file_command, generic_load)
3581 (remove_symbol_file_command): Use gdb_argv.
3582 * stack.c (backtrace_command): Use gdb_argv.
3583 * source.c (add_path, show_substitute_path_command)
3584 (unset_substitute_path_command, set_substitute_path_command):
3585 Use gdb_argv.
3586 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
3587 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
3588 * remote.c (extended_remote_run, remote_put_command)
3589 (remote_get_command, remote_delete_command): Use gdb_argv.
3590 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
3591 (gdbsim_open): Use gdb_argv.
3592 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
3593 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
3594 * procfs.c (procfs_info_proc): Use gdb_argv.
3595 * interps.c (interpreter_exec_cmd): Use gdb_argv.
3596 * infrun.c (handle_command): Use gdb_argv.
3597 * inferior.c (add_inferior_command, clone_inferior_command):
3598 Use gdb_argv.
3599 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
3600 * exec.c (exec_file_command): Use gdb_argv.
3601 * cli/cli-cmds.c (alias_command): Use gdb_argv.
3602 * compile/compile.c (build_argc_argv): Use gdb_argv.
3603
0d50bde3
TT
36042017-08-03 Tom Tromey <tom@tromey.com>
3605
3606 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
3607
7f968c89
TT
36082017-08-03 Tom Tromey <tom@tromey.com>
3609
3610 * python/python.c (compute_python_string): Return std::string.
3611 (gdbpy_eval_from_control_command): Update.
3612 (do_start_initialization): Use std::string.
3613 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
3614 xstrprintf.
3615 * python/py-breakpoint.c (local_setattro): Use string_printf, not
3616 xstrprintf.
3617
3c9ebddd
TT
36182017-08-03 Tom Tromey <tom@tromey.com>
3619
3620 * top.h (do_restore_instream_cleanup): Remove.
3621 * top.c (do_restore_instream_cleanup): Remove.
3622 (read_command_file): Use scoped_restore.
3623 * cli/cli-script.c (execute_user_command): Use scoped_restore.
3624
b51b225e
TT
36252017-08-03 Tom Tromey <tom@tromey.com>
3626
3627 * cli/cli-script.c (execute_user_command)
3628 (execute_control_command): Use scoped_restore.
3629
ac991630
TT
36302017-08-03 Tom Tromey <tom@tromey.com>
3631
3632 * cli/cli-script.c (do_restore_user_call_depth): Remove.
3633 (execute_user_command): Remove user_call_depth; use
3634 user_args_stack's size instead.
3635
898e0c8e
TT
36362017-08-03 Tom Tromey <tom@tromey.com>
3637
3638 * top.h (in_user_command): Remove.
3639 * top.c (in_user_command): Remove.
3640 * cli/cli-script.c (do_restore_user_call_depth)
3641 (execute_user_command): Update.
3642
26fcd5d7
TT
36432017-08-03 Tom Tromey <tom@tromey.com>
3644
3645 * valops.c (search_struct_method): Use gdb::byte_vector.
3646 * valarith.c (value_concat): Use std::vector.
3647 * target.c (memory_xfer_partial): Use gdb::byte_vector.
3648 (simple_search_memory): Likewise.
3649 * printcmd.c (find_string_backward): Use gdb::byte_vector.
3650 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
3651 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
3652 * elfread.c (elf_rel_plt_read): Use std::string.
3653 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
3654 * cli/cli-dump.c (restore_section_callback): Use
3655 gdb::byte_vector.
3656
7c218e6c
TT
36572017-08-03 Tom Tromey <tom@tromey.com>
3658
3659 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
3660
31b68d4a
TT
36612017-08-03 Tom Tromey <tom@tromey.com>
3662
3663 * tui/tui-regs.c (tui_restore_gdbout): Remove.
3664 (tui_register_format): Use scoped_restore.
3665
2ec845e7
TT
36662017-08-03 Tom Tromey <tom@tromey.com>
3667
3668 * reverse.c (exec_direction_default): Remove.
3669 (exec_reverse_once): Use scoped_restore.
3670 * remote.c (restore_remote_timeout): Remove.
3671 (remote_flash_erase, remote_flash_write, remote_flash_done)
3672 (readchar, remote_serial_write): Use scoped_restore.
3673 * cli/cli-script.c (struct source_cleanup_lines_args)
3674 (source_cleanup_lines): Remove.
3675 (script_from_file): Use scoped_restore.
3676 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
3677 (source_command): Use scoped_restore.
3678
b3bc8453
TT
36792017-08-03 Tom Tromey <tom@tromey.com>
3680
3681 * utils.h (make_cleanup_free_so): Remove.
3682 * utils.c (do_free_so, make_cleanup_free_so): Remove.
3683 * solist.h (struct so_deleter): New.
3684 (so_list_up): New typedef.
3685 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
3686
e3ad2841
TT
36872017-08-03 Tom Tromey <tom@tromey.com>
3688
3689 * utils.h (make_cleanup_restore_current_language): Remove.
3690 * utils.c (do_restore_current_language)
3691 (make_cleanup_restore_current_language): Remove.
3692 * parse.c (parse_exp_in_context_1)
3693 (parse_expression_with_language): Use
3694 scoped_restore_current_language.
3695 * mi/mi-main.c (mi_cmd_execute): Use
3696 scoped_restore_current_language.
3697 * language.h (scoped_restore_current_language): New class.
3698
b80cf838
TT
36992017-08-03 Tom Tromey <tom@tromey.com>
3700
3701 * compile/compile.c (cleanup_unlink_file): Remove.
3702 (compile_to_object): Use gdb::unlinker.
3703 (eval_compile_command): Likewise.
3704
fad0444a
TT
37052017-08-03 Tom Tromey <tom@tromey.com>
3706
3707 * utils.h (make_cleanup_fclose): Remove.
3708 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
3709
6e7bc05c
TT
37102017-08-03 Tom Tromey <tom@tromey.com>
3711
3712 * top.c (open_terminal_stream): Return gdb_file_up.
3713 (new_ui_command): Update.
3714
4a45905b
TT
37152017-08-03 Tom Tromey <tom@tromey.com>
3716
3717 * source.c (print_source_lines_base, forward_search_command)
3718 (reverse_search_command): Use gdb_file_up.
3719
7cd06d6e
TT
37202017-08-03 Tom Tromey <tom@tromey.com>
3721
3722 * fbsd-nat.c (fbsd_find_memory_regions): Update.
3723
ed166945
TT
37242017-08-03 Tom Tromey <tom@tromey.com>
3725
3726 * cli/cli-cmds.c (find_and_open_script): Change return type.
3727 Remove "streamp" and "full_path" parameters.
3728 (source_script_with_search): Update.
3729 * auto-load.c (source_script_file): Update.
3730 * cli/cli-cmds.h (find_and_open_script): Change type.
3731 (open_script): New struct.
3732
d419f42d
TT
37332017-08-03 Tom Tromey <tom@tromey.com>
3734
3735 * xml-support.c (xml_fetch_content_from_file): Update.
3736 * ui-file.c (stdio_file::open): Update.
3737 * tracefile-tfile.c (tfile_start): Update.
3738 * remote.c (remote_file_put, remote_file_get): Update.
3739 * nat/linux-procfs.c (linux_proc_get_int)
3740 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
3741 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
3742 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
3743 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
3744 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
3745 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
3746 * linux-nat.c (linux_proc_pending_signals): Update.
3747 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
3748 (file_closer): Remove.
3749 * compile/compile.c (compile_to_object): Update.
3750 * common/filestuff.h (struct gdb_file_deleter): New.
3751 (gdb_file_up): New typedef.
3752 (gdb_fopen_cloexec): Change return type.
3753 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
3754 * cli/cli-dump.c (fopen_with_cleanup): Remove.
3755 (dump_binary_file, restore_binary_file): Update.
3756 * auto-load.c (auto_load_objfile_script_1): Update.
3757
4a2b031d
TT
37582017-08-03 Tom Tromey <tom@tromey.com>
3759
3760 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
3761 (info_static_tracepoint_markers_command): Likewise.
3762 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
3763 * skip.c (skip_info): Use ui_out_emit_table.
3764 * progspace.c (print_program_space): Use ui_out_emit_table.
3765 * osdata.c (info_osdata): Use ui_out_emit_table.
3766 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
3767 ui_out_emit_table.
3768 * linux-thread-db.c (info_auto_load_libthread_db): Use
3769 ui_out_emit_table.
3770 * inferior.c (print_inferior): Use ui_out_emit_table.
3771 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
3772 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
3773 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
3774 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
3775 * ui-out.h (class ui_out_emit_table): New.
3776
a4f320fd
MR
37772017-08-02 Maciej W. Rozycki <macro@imgtec.com>
3778
3779 * mips-tdep.c (mips_fpu_type_str): New function.
3780 (mips_dump_tdep): Call it.
3781
a2f1f308
MR
37822017-08-01 Maciej W. Rozycki <macro@imgtec.com>
3783
3784 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
3785 `->mips_fpu_type'.
3786
7e5ed83b
XR
37872017-07-31 Xavier Roirand <roirand@adacore.com>
3788
3789 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
3790
4c9dc811
XR
37912017-07-27 Xavier Roirand <roirand@adacore.com>
3792
3793 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
3794
27d41eac
YQ
37952017-07-26 Yao Qi <yao.qi@linaro.org>
3796
3797 * cli/cli-cmds.c (maintenancechecklist): New variable.
3798 * gdbcmd.h (maintenancechecklist): Declare it.
3799 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
3800 Call i386_linux_read_description with different masks.
3801 * maint.c (maintenance_check_command): New function.
3802 (_initialize_maint_cmds): Call add_prefix_cmd.
3803 * target-descriptions.c (tdesc_reg): override operator != and ==.
3804 (tdesc_type): Likewise.
3805 (tdesc_feature): Likewise.
3806 (target_desc): Likewise.
3807 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
3808 (maintenance_check_xml_descriptions): New function.
3809 (_initialize_target_descriptions) Add command "xml-descriptions".
3810 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
3811
ea03d0d3
YQ
38122017-07-26 Yao Qi <yao.qi@linaro.org>
3813
3814 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
3815 Include features/i386/32bit-*.c.
3816 (i386_linux_read_description): Generate target description if it
3817 doesn't exist.
3818 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
3819 functions.
3820 * features/i386/32bit-linux.c: Re-generated.
3821 * features/i386/32bit-sse.c: Likewise.
3822 * target-descriptions.c (print_c_feature::visit): Print code to
3823 set register number if needed.
3824 (print_c_feature) <m_next_regnum>: New field.
3825
25aa13e5
YQ
38262017-07-26 Yao Qi <yao.qi@linaro.org>
3827
3828 * features/Makefile (CFILES): Rename with TDESC_CFILES.
3829 (FEATURE_XMLFILES): New.
3830 (FEATURE_CFILES): New.
3831 New rules.
3832 (clean-cfiles): Remove generated c files.
3833 * features/i386/32bit-avx.c: Generated.
3834 * features/i386/32bit-avx512.c: Generated.
3835 * features/i386/32bit-core.c: Generated.
3836 * features/i386/32bit-linux.c: Generated.
3837 * features/i386/32bit-mpx.c: Generated.
3838 * features/i386/32bit-pkeys.c: Generated.
3839 * features/i386/32bit-sse.c: Generated.
3840 * target-descriptions.c: Include algorithm.
3841 (tdesc_element_visitor): Add method visit_end.
3842 (print_c_tdesc): Implement visit_end.
3843 (print_c_tdesc:: m_filename_after_features): Move it to
3844 protected.
3845 (print_c_feature): New class.
3846 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
3847 name starts with "i386/32bit-".
3848
6eb1e6a8
YQ
38492017-07-26 Yao Qi <yao.qi@linaro.org>
3850
3851 * target-descriptions.c (tdesc_element_visitor): New class.
3852 (tdesc_element): New class.
3853 (tdesc_reg): Inherit from tdesc_element.
3854 (tdesc_reg::accept): New function.
3855 (tdesc_type): Inherit from tdesc_element.
3856 (tdesc_type::accept): New function.
3857 (tdesc_feature): Inherit from tdesc_element.
3858 (tdesc_feature::accept): New function.
3859 (target_desc): Inherit from tdesc_element.
3860 (target_desc::target_desc): New.
3861 (target_desc::~target_desc): New.
3862 (target_desc::accept): New.
3863 (allocate_target_description): Use new.
3864 (free_target_description): Use delete.
3865 (print_c_tdesc): New class.
3866 (maint_print_c_tdesc_cmd): Adjust.
3867
3868 * features/aarch64.c: Re-generated.
3869 * features/arc-arcompact.c: Re-generated.
3870 * features/arc-v2.c: Re-generated.
3871 * features/arm/arm-with-iwmmxt.c: Re-generated.
3872 * features/arm/arm-with-m.c: Re-generated.
3873 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
3874 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
3875 * features/arm/arm-with-neon.c: Re-generated.
3876 * features/arm/arm-with-vfpv2.c: Re-generated.
3877 * features/arm/arm-with-vfpv3.c: Re-generated.
3878 * features/i386/amd64-avx-avx512.c: Re-generated.
3879 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
3880 * features/i386/amd64-avx.c: Re-generated.
3881 * features/i386/amd64-avx-linux.c: Re-generated.
3882 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
3883 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
3884 * features/i386/amd64-avx-mpx.c: Re-generated.
3885 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
3886 * features/i386/amd64.c: Re-generated.
3887 * features/i386/amd64-linux.c: Re-generated.
3888 * features/i386/amd64-mpx.c: Re-generated.
3889 * features/i386/amd64-mpx-linux.c: Re-generated.
3890 * features/i386/i386-avx-avx512.c: Re-generated.
3891 * features/i386/i386-avx-avx512-linux.c: Re-generated.
3892 * features/i386/i386-avx.c: Re-generated.
3893 * features/i386/i386-avx-linux.c: Re-generated.
3894 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
3895 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
3896 * features/i386/i386-avx-mpx.c: Re-generated.
3897 * features/i386/i386-avx-mpx-linux.c: Re-generated.
3898 * features/i386/i386.c: Re-generated.
3899 * features/i386/i386-linux.c: Re-generated.
3900 * features/i386/i386-mmx.c: Re-generated.
3901 * features/i386/i386-mmx-linux.c: Re-generated.
3902 * features/i386/i386-mpx.c: Re-generated.
3903 * features/i386/i386-mpx-linux.c: Re-generated.
3904 * features/i386/x32-avx-avx512.c: Re-generated.
3905 * features/i386/x32-avx-avx512-linux.c: Re-generated.
3906 * features/i386/x32-avx.c: Re-generated.
3907 * features/i386/x32-avx-linux.c: Re-generated.
3908 * features/i386/x32.c: Re-generated.
3909 * features/i386/x32-linux.c: Re-generated.
3910 * features/microblaze.c: Re-generated.
3911 * features/microblaze-with-stack-protect.c: Re-generated.
3912 * features/mips64-dsp-linux.c: Re-generated.
3913 * features/mips64-linux.c: Re-generated.
3914 * features/mips-dsp-linux.c: Re-generated.
3915 * features/mips-linux.c: Re-generated.
3916 * features/nds32.c: Re-generated.
3917 * features/nios2.c: Re-generated.
3918 * features/nios2-linux.c: Re-generated.
3919 * features/rs6000/powerpc-32.c: Re-generated.
3920 * features/rs6000/powerpc-32l.c: Re-generated.
3921 * features/rs6000/powerpc-403.c: Re-generated.
3922 * features/rs6000/powerpc-403gc.c : Re-generated.
3923 * features/rs6000/powerpc-405.c: Re-generated.
3924 * features/rs6000/powerpc-505.c: Re-generated.
3925 * features/rs6000/powerpc-601.c: Re-generated.
3926 * features/rs6000/powerpc-602.c: Re-generated.
3927 * features/rs6000/powerpc-603.c: Re-generated.
3928 * features/rs6000/powerpc-604.c: Re-generated.
3929 * features/rs6000/powerpc-64.c: Re-generated.
3930 * features/rs6000/powerpc-64l.c: Re-generated.
3931 * features/rs6000/powerpc-7400.c: Re-generated.
3932 * features/rs6000/powerpc-750.c: Re-generated.
3933 * features/rs6000/powerpc-860.c: Re-generated.
3934 * features/rs6000/powerpc-altivec32.c: Re-generated.
3935 * features/rs6000/powerpc-altivec32l.c: Re-generated.
3936 * features/rs6000/powerpc-altivec64.c: Re-generated.
3937 * features/rs6000/powerpc-altivec64l.c: Re-generated.
3938 * features/rs6000/powerpc-cell32l.c: Re-generated.
3939 * features/rs6000/powerpc-cell64l.c: Re-generated.
3940 * features/rs6000/powerpc-e500.c: Re-generated.
3941 * features/rs6000/powerpc-e500l.c: Re-generated.
3942 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
3943 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
3944 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
3945 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
3946 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
3947 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
3948 * features/rs6000/powerpc-vsx32.c: Re-generated.
3949 * features/rs6000/powerpc-vsx32l.c: Re-generated.
3950 * features/rs6000/powerpc-vsx64.c: Re-generated.
3951 * features/rs6000/powerpc-vsx64l.c: Re-generated.
3952 * features/rs6000/rs6000.c: Re-generated.
3953 * features/s390-linux32.c: Re-generated.
3954 * features/s390-linux32v1.c: Re-generated.
3955 * features/s390-linux32v2.c: Re-generated.
3956 * features/s390-linux64.c: Re-generated.
3957 * features/s390-linux64v1.c: Re-generated.
3958 * features/s390-linux64v2.c: Re-generated.
3959 * features/s390-te-linux64.c: Re-generated.
3960 * features/s390-tevx-linux64.c: Re-generated.
3961 * features/s390-vx-linux64.c: Re-generated.
3962 * features/s390x-linux64.c: Re-generated.
3963 * features/s390x-linux64v1.c: Re-generated.
3964 * features/s390x-linux64v2.c: Re-generated.
3965 * features/s390x-te-linux64.c: Re-generated.
3966 * features/s390x-tevx-linux64.c: Re-generated.
3967 * features/s390x-vx-linux64.c: Re-generated.
3968 * features/sparc/sparc32-solaris.c: Re-generated.
3969 * features/sparc/sparc64-solaris.c: Re-generated.
3970 * features/tic6x-c62x.c: Re-generated.
3971 * features/tic6x-c62x-linux.c: Re-generated.
3972 * features/tic6x-c64x.c: Re-generated.
3973 * features/tic6x-c64x-linux.c: Re-generated.
3974 * features/tic6x-c64xp.c: Re-generated.
3975 * features/tic6x-c64xp-linux.c: Re-generated.
3976
35b4818d
YQ
39772017-07-26 Yao Qi <yao.qi@linaro.org>
3978
3979 * i386-linux-tdep.c (i386_linux_read_description): New function.
3980 (i386_linux_core_read_description): Call
3981 i386_linux_read_description.
3982 * i386-linux-tdep.h (i386_linux_read_description): Declare.
3983 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
3984 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
3985 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
3986 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
3987 * x86-linux-nat.c (x86_linux_read_description): Call
3988 i386_linux_read_description.
3989
8e2141c6
YQ
39902017-07-26 Yao Qi <yao.qi@linaro.org>
3991
3992 * NEWS: Mention it.
3993 * features/Makefile (%.c: %.xml): Pass the xml file name to
3994 command "maint print c-tdesc".
3995 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
3996 name from 'arg'.
3997
b468ff4c
YQ
39982017-07-26 Yao Qi <yao.qi@linaro.org>
3999
4000 * target-descriptions.c (target_desc): Add ctor and dtor. Do
4001 in-class initialization.
4002 (tdesc_create_feature): Call new instead of XCNEW.
4003 (free_target_description): Ue delete.
4004
b9c0e1b4
JB
40052017-07-25 John Baldwin <jhb@FreeBSD.org>
4006
4007 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
4008
a04b5337
YQ
40092017-07-25 Yao Qi <yao.qi@linaro.org>
4010
4011 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
4012 constant.
4013 (amd64_x32_init_abi): Likewise.
4014 * amd64-tdep.h (amd64_init_abi): Update declaration.
4015 (amd64_x32_init_abi): Likewise.
4016
02ad7fc2
YQ
40172017-07-25 Yao Qi <yao.qi@linaro.org>
4018
4019 PR tdep/21717
4020 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
4021 condition for FPSCR.
4022 (arm_linux_store_inferior_registers): Likewise.
4023
b6f48cb0
TT
40242017-07-22 Tom Tromey <tom@tromey.com>
4025
4026 * break-catch-syscall.c (struct catch_syscall_inferior_data)
4027 <syscalls_counts>: Now a std::vector.
4028 (get_catch_syscall_inferior_data): Use "new".
4029 (catch_syscall_inferior_data_cleanup): Use "delete".
4030 (insert_catch_syscall, remove_catch_syscall)
4031 (clear_syscall_counts): Update.
4032
e12c9b7a
TT
40332017-07-22 Tom Tromey <tom@tromey.com>
4034
4035 * break-catch-syscall.c (syscall_catchpoint)
4036 <syscalls_to_be_caught>: Now a std::vector<int>
4037 (~syscall_catchpoint): Remove.
4038 (insert_catch_syscall, remove_catch_syscall)
4039 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
4040 (print_mention_catch_syscall, print_recreate_catch_syscall):
4041 Update.
4042 (create_syscall_event_catchpoint): Change type of "filter"
4043 parameter.
4044 (catch_syscall_split_args): Return a std::vector.
4045 (catch_syscall_command_1, catching_syscall_number_1): Update.
4046
4fa8aeac
TT
40472017-07-22 Tom Tromey <tom@tromey.com>
4048
4049 * break-catch-throw.c (struct exception_catchpoint)
4050 <exception_rx>: Now a std::string.
4051 (~exception_catchpoint): Remove.
4052 (print_one_detail_exception_catchpoint): Update.
4053 (handle_gnu_v3_exceptions): Change type of except_rx.
4054 (extract_exception_regexp): Return a std::string.
4055 (catch_exception_command_1): Update.
4056
f746a154
TT
40572017-07-22 Tom Tromey <tom@tromey.com>
4058
4059 * break-catch-sig.c (gdb_signal_type): Remove typedef.
4060 (struct signal_catchpoint) <signals_to_be_caught>: Now a
4061 std::vector.
4062 <catch_all>: Now a bool.
4063 (~signal_catchpoint): Remove.
4064 (signal_catchpoint_insert_location)
4065 (signal_catchpoint_remove_location)
4066 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
4067 (signal_catchpoint_print_mention)
4068 (signal_catchpoint_print_recreate)
4069 (signal_catchpoint_explains_signal): Update.
4070 (create_signal_catchpoint): Change type of "filter" and
4071 "catch_all".
4072 (catch_signal_split_args): Return a std::vector. Change type of
4073 "catch_all".
4074 (catch_signal_command): Update.
4075
47e77640
PA
40762017-07-20 Pedro Alves <palves@redhat.com>
4077
4078 * ada-lang.c (ada_language_defn): Make extern.
4079 (_initialize_ada_language): Remove add_language call.
4080 * c-lang.c (c_language_defn, cplus_language_defn)
4081 (asm_language_defn, minimal_language_defn): Make extern.
4082 (_initialize_c_language): Delete.
4083 * completer.c (compare_cstrings): Delete, moved to utils.h.
4084 * d-lang.c (d_language_defn): Make extern.
4085 (_initialize_d_language): Remove add_language calls.
4086 * defs.h (enum language): Add comment.
4087 * f-lang.c (f_language_defn): Make extern.
4088 (_initialize_f_language): Remove add_language call.
4089 * go-lang.c (go_language_defn): Make extern.
4090 (_initialize_go_language): Remove add_language call.
4091 * language.c: Include <algorithm>.
4092 (languages): Redefine as const array.
4093 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
4094 (set_language_command): Handle "local". Use for-range loop.
4095 (set_language): Remove loop.
4096 (language_enum): Rewrite.
4097 (language_def, language_str): Remove loops.
4098 (add_language): Delete.
4099 (add_set_language_command): New, based on add_languages.
4100 (skip_language_trampoline): Adjust.
4101 (local_language_defn): Delete.
4102 (language_gdbarch_post_init): Adjust.
4103 (_initialize_language): Remove add_language calls. Call
4104 add_set_language_command.
4105 * language.h (add_language): Delete.
4106 (auto_language_defn)
4107 (unknown_language_defn, minimal_language_defn, ada_language_defn)
4108 (asm_language_defn, c_language_defn, cplus_language_defn)
4109 (d_language_defn, f_language_defn, go_language_defn)
4110 (m2_language_defn, objc_language_defn, opencl_language_defn)
4111 (pascal_language_defn, rust_language_defn): Declare.
4112 * m2-lang.c (m2_language_defn): Make extern.
4113 (_initialize_m2_language): Remove add_language call.
4114 * objc-lang.c (objc_language_defn): Make extern.
4115 (_initialize_objc_language): Remove add_language call.
4116 * opencl-lang.c (opencl_language_defn): Make extern.
4117 (_initialize_opencl_language): Remove add_language call.
4118 * p-lang.c (pascal_language_defn): Make extern.
4119 (_initialize_pascal_language): Delete.
4120 * rust-lang.c (rust_language_defn): Make extern.
4121 (_initialize_rust_language): Delete.
4122 * utils.h (compare_cstrings): New static inline function.
4123
edb0c9cb
PA
41242017-07-20 Pedro Alves <palves@redhat.com>
4125
4126 * ada-lang.c (ada_to_fixed_type_1): Adjust.
4127 (get_var_value): Constify parameters.
4128 (get_int_var_value): Change prototype.
4129 (to_fixed_range_type): Adjust.
4130 * ada-lang.h (get_int_var_value): Change prototype.
4131
a778f165
PA
41322017-07-20 Pedro Alves <palves@redhat.com>
4133
4134 * dwarf2read.c (dw2_lookup_symbol): Use
4135 SYMBOL_MATCHES_SEARCH_NAME.
4136 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
4137
42edd901
PA
41382017-07-20 Pedro Alves <palves@redhat.com>
4139
4140 * block.c (block_iter_name_step, block_iter_name_first)
4141 (block_iter_name_next): Delete.
4142 (block_lookup_symbol_primary): Adjust to use
4143 dict_iter_match_first/dict_iter_match_next.
4144 * block.h (block_iter_name_first, block_iter_name_next): Delete
4145 declarations.
4146 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
4147 dict_iter_match_first/dict_iter_match_next.
4148
cf325299
PA
41492017-07-20 Pedro Alves <palves@redhat.com>
4150
4151 * cp-support.c (cp_find_first_component_aux): Add missing case for
4152 end of string.
4153
c5ed0576
DB
41542017-07-18 David Blaikie <dblaikie@gmail.com>
4155
4156 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
4157 of dwo_cu's dwo_file.
4158
27841e76
YQ
41592017-07-18 Yao Qi <yao.qi@linaro.org>
4160
4161 * remote.c (store_registers_using_G): Remove one line comment.
4162
cfb7e58b
YQ
41632017-07-18 Yao Qi <yao.qi@linaro.org>
4164
4165 * regcache.c (regcache_cpy): Simplify it.
4166 (regcache::cpy_no_passthrough): Remove it.
4167 * regcache.h (cpy_no_passthrough): Remove it.
4168 (regcache_dup, regcache_cpy): Update comments.
4169
386535dd
PA
41702017-07-18 Pedro Alves <palves@redhat.com>
4171
4172 * remote-sim.c (sim_command_completer): Adjust to work with a
4173 completion_tracker instead of a VEC.
4174
c45ec17c
PA
41752017-07-17 Pedro Alves <palves@redhat.com>
4176
4177 * completer.c (complete_source_filenames): New function.
4178 (complete_address_and_linespec_locations): New function.
4179 (location_completer): Use complete_address_and_linespec_locations.
4180 (completion_tracker::build_completion_result): Honor the tracker's
4181 request to suppress append.
4182 * completer.h (completion_tracker::suppress_append_ws)
4183 (completion_tracker::set_suppress_append_ws): New methods.
4184 (completion_tracker::m_suppress_append_ws): New field.
4185 (complete_source_filenames): New declaration.
4186 * linespec.c (linespec_complete_what): New.
4187 (struct ls_parser) <complete_what, completion_word,
4188 completion_quote_char, completion_quote_end, completion_tracker>:
4189 New fields.
4190 (string_find_incomplete_keyword_at_end): New.
4191 (linespec_lexer_lex_string): Record quote char. If in completion
4192 mode, don't throw.
4193 (linespec_lexer_consume_token): Advance the completion word point.
4194 (linespec_lexer_peek_token): Save/restore completion info.
4195 (save_stream_and_consume_token): New.
4196 (set_completion_after_number): New.
4197 (linespec_parse_basic): Set what to complete next depending on
4198 token. Handle function and label completions specially.
4199 (parse_linespec): Disable objc shortcut in completion mode. Set
4200 what to complete next depending on token type. Skip keyword if in
4201 completion mode.
4202 (complete_linespec_component, linespec_complete): New.
4203 * linespec.h (linespec_complete): Declare.
4204
be966d42
PA
42052017-07-17 Pedro Alves <palves@redhat.com>
4206
4207 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4208 Handle 'operator<' / 'operator<<'.
4209
a2459270
PA
42102017-07-17 Pedro Alves <palves@redhat.com>
4211
4212 * completer.c (collect_explicit_location_matches): Handle
4213 MATCH_LABEL.
4214 (convert_explicit_location_to_linespec): New, factored out from
4215 ...
4216 (convert_explicit_location_to_sals): ... this.
4217 (complete_label): New.
4218 (linespec_complete_label, find_label_symbols_in_block): New.
4219 (find_label_symbols): Add completion_mode parameter and adjust to
4220 call find_label_symbols_in_block.
4221 * linespec.h (linespec_complete_label): Declare.
4222
c6756f62
PA
42232017-07-17 Pedro Alves <palves@redhat.com>
4224
4225 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4226 complete_symbol_mode parameter.
4227 * cli/cli-cmds.c (complete_command): Get the completion result out
4228 of the handle_brkchars tracker if used a custom word point.
4229 * completer.c: Include "linespec.h".
4230 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4231 (advance_to_expression_complete_word_point): New.
4232 (completion_tracker::completes_to_completion_word): New.
4233 (complete_files_symbols): Pass down
4234 complete_symbol_mode::EXPRESSION.
4235 (explicit_options, probe_options): New.
4236 (collect_explicit_location_matches): Complete on the
4237 explictit_loc->foo instead of word. Use
4238 linespec_complete_function. Handle MATCH_LINE. Handle offering
4239 keyword and options completions.
4240 (backup_text_ptr): Delete.
4241 (skip_keyword): New.
4242 (complete_explicit_location): Remove 'word' parameter. Add
4243 language, quoted_arg_start and quoted_arg_end parameters.
4244 Rewrite, parsing left to right.
4245 (location_completer): Rewrite.
4246 (location_completer_handle_brkchars): New function.
4247 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4248 (enum complete_line_internal_reason): Adjust comments.
4249 (completion_tracker::discard_completions): New.
4250 (completer_handle_brkchars_func_for_completer): Handle
4251 location_completer.
4252 (gdb_custom_word_point_brkchars)
4253 (gdb_org_rl_basic_quote_characters): New.
4254 (gdb_completion_word_break_characters_throw)
4255 (completion_find_completion_word): Handle trackers that use a
4256 custom word point.
4257 (completion_tracker::advance_custom_word_point_by): New.
4258 (completion_tracker::build_completion_result): Don't rely on
4259 readline appending the quote char.
4260 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4261 use a custom word point.
4262 (gdb_rl_attempted_completion_function): Restore
4263 rl_basic_quote_characters.
4264 * completer.h (class completion_tracker): Extend intro comment.
4265 (completion_tracker::set_quote_char)
4266 (completion_tracker::quote_char)
4267 (completion_tracker::set_use_custom_word_point)
4268 (completion_tracker::use_custom_word_point)
4269 (completion_tracker::custom_word_point)
4270 (completion_tracker::set_custom_word_point)
4271 (completion_tracker::advance_custom_word_point_by)
4272 (completion_tracker::completes_to_completion_word)
4273 (completion_tracker::discard_completions): New methods.
4274 (completion_tracker::m_quote_char)
4275 (completion_tracker::m_use_custom_word_point)
4276 (completion_tracker::m_custom_word_point): New fields.
4277 (advance_to_expression_complete_word_point): Declare.
4278 * f-lang.c (f_collect_symbol_completion_matches): Add
4279 complete_symbol_mode parameter.
4280 * language.h (struct language_defn)
4281 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4282 parameter.
4283 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4284 (linespec_complete_function): New function.
4285 (linespec_lexer_lex_keyword): Adjust.
4286 * linespec.h (linespec_keywords, linespec_complete_function): New
4287 declarations.
4288 * location.c (find_end_quote): New function.
4289 (explicit_location_lex_one): Add explicit_completion_info
4290 parameter. Save quoting info. Don't throw if being called for
4291 completion. Don't handle Ada operators here.
4292 (is_cp_operator, skip_op_false_positives, first_of)
4293 (explicit_location_lex_one_function): New function.
4294 (string_to_explicit_location): Replace 'dont_throw' parameter with
4295 an explicit_completion_info pointer parameter. Handle it. Don't
4296 use explicit_location_lex_one to lex function names. Use
4297 explicit_location_lex_one_function instead.
4298 * location.h (struct explicit_completion_info): New.
4299 (string_to_explicit_location): Replace 'dont_throw' parameter with
4300 an explicit_completion_info pointer parameter.
4301 * symtab.c (default_collect_symbol_completion_matches_break_on):
4302 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4303 (default_collect_symbol_completion_matches)
4304 (collect_symbol_completion_matches): Add complete_symbol_mode
4305 parameter.
4306 (collect_symbol_completion_matches_type): Pass down
4307 complete_symbol_mode::EXPRESSION.
4308 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4309 parameter. Handle LINESPEC mode.
4310 * symtab.h (complete_symbol_mode): New.
4311 (default_collect_symbol_completion_matches_break_on)
4312 (default_collect_symbol_completion_matches)
4313 (collect_symbol_completion_matches)
4314 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4315 parameter.
4316
1d550c82
PA
43172017-07-17 Pedro Alves <palves@redhat.com>
4318
4319 * utils.c (enum class strncmp_iw_mode): New.
4320 (strcmp_iw): Rename to ...
4321 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4322 parameters. Handle them.
4323 (strncmp_iw): New.
4324 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4325 * utils.h (strncmp_iw): Declare.
4326 (strcmp_iw): Move describing comments here.
4327
8090b426
PA
43282017-07-17 Pedro Alves <palves@redhat.com>
4329
4330 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4331 CP_OPERATOR_STR.
4332 * c-typeprint.c (is_type_conversion_operator): Use
4333 CP_OPERATOR_STR.
4334 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4335 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4336 CP_OPERATOR_LEN.
4337 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4338 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4339 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4340 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4341 CP_OPERATOR_STR.
4342 * location.c: Include "cp-support.h".
4343 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4344 CP_OPERATOR_STR.
4345 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4346 CP_OPERATOR_LEN.
4347
6a2c1b87
PA
43482017-07-17 Pedro Alves <palves@redhat.com>
4349
4350 * cli/cli-cmds.c (complete_command): Use a completion tracker
4351 along with completion_find_completion_word for handle_brkchars
4352 phase.
4353 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4354 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4355 (struct gdb_rl_completion_word_info): New.
4356 (gdb_rl_find_completion_word): New.
4357 (completion_find_completion_word): New.
4358 * completer.h (completion_find_completion_word): Declare.
4359
eb3ff9a5
PA
43602017-07-17 Pedro Alves <palves@redhat.com>
4361
4362 * ada-lang.c (symbol_completion_match): Adjust comments.
4363 (symbol_completion_add): Replace vector parameter with
4364 completion_tracker parameter. Use it.
4365 (ada_make_symbol_completion_list): Rename to...
4366 (ada_collect_symbol_completion_matches): ... this. Add
4367 completion_tracker parameter and use it.
4368 (ada_language_defn): Adjust.
4369 * break-catch-syscall.c (catch_syscall_completer): Adjust
4370 prototype and work with completion_tracker instead of VEC.
4371 * breakpoint.c (condition_completer): Adjust prototype and work
4372 with completion_tracker instead of VEC.
4373 * c-lang.c (c_language_defn, cplus_language_defn)
4374 (asm_language_defn, minimal_language_defn): Adjust to renames.
4375 * cli/cli-cmds.c (complete_command): Rework using
4376 completion_tracker. Catch exceptions when completing.
4377 * cli/cli-decode.c (integer_unlimited_completer)
4378 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4379 with completion_tracker instead of VEC.
4380 * command.h (struct completion_tracker): Forward declare.
4381 (completer_ftype, completer_handle_brkchars_ftype): Change
4382 types.
4383 (complete_on_cmdlist, complete_on_enum): Adjust.
4384 * completer.c: Include <algorithm>.
4385 (struct gdb_completer_state): New.
4386 (current_completion): New global.
4387 (readline_line_completion_function): Delete.
4388 (noop_completer, filename_completer)
4389 (filename_completer_handle_brkchars, complete_files_symbols)
4390 (linespec_location_completer): Adjust to work with a
4391 completion_tracker instead of a VEC.
4392 (string_or_empty): New.
4393 (collect_explicit_location_matches): Adjust to work with a
4394 completion_tracker instead of a VEC.
4395 (explicit_location_completer): Rename to ...
4396 (complete_explicit_location): ... this and adjust to work with a
4397 completion_tracker instead of a VEC.
4398 (location_completer): Adjust to work with a completion_tracker
4399 instead of a VEC.
4400 (add_struct_fields): Adjust to work with a completion_list instead
4401 of VEC.
4402 (expression_completer): Rename to ...
4403 (complete_expression): ... this and adjust to work with a
4404 completion_tracker instead of a VEC. Use complete_files_symbols.
4405 (expression_completer): Reimplement on top of complete_expression.
4406 (symbol_completer): Adjust to work with a completion_tracker
4407 instead of a VEC.
4408 (enum complete_line_internal_reason): Add describing comments.
4409 (complete_line_internal_normal_command): Adjust to work with a
4410 completion_tracker instead of a VEC.
4411 (complete_line_internal): Rename to ...
4412 (complete_line_internal_1): ... this and adjust to work with a
4413 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4414 handle_brkchars phase.
4415 (new_completion_tracker): Delete.
4416 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4417 complete_line_internal_1.
4418 (free_completion_tracker): Delete.
4419 (INITIAL_COMPLETION_HTAB_SIZE): New.
4420 (completion_tracker::completion_tracker)
4421 (completion_tracker::~completion_tracker): New.
4422 (maybe_add_completion): Delete.
4423 (completion_tracker::maybe_add_completion)
4424 (completion_tracker::add_completion)
4425 (completion_tracker::add_completions): New.
4426 (throw_max_completions_reached_error): Delete.
4427 (complete_line): Adjust to work with a completion_tracker instead
4428 of a VEC. Don't create a completion_tracker_t or check for max
4429 completions here.
4430 (command_completer, command_completer_handle_brkchars)
4431 (signal_completer, reg_or_group_completer_1)
4432 (reg_or_group_completer, default_completer_handle_brkchars):
4433 Adjust to work with a completion_tracker.
4434 (gdb_completion_word_break_characters_throw): New.
4435 (gdb_completion_word_break_characters): Reimplement.
4436 (line_completion_function): Delete.
4437 (completion_tracker::recompute_lowest_common_denominator)
4438 (expand_preserving_ws)
4439 (completion_tracker::build_completion_result)
4440 (completion_result::completion_result)
4441 (completion_result::completion_result)
4442 (completion_result::~completion_result)
4443 (completion_result::completion_result)
4444 (completion_result::release_match_list, compare_cstrings)
4445 (completion_result::sort_match_list)
4446 (completion_result::reset_match_list)
4447 (gdb_rl_attempted_completion_function_throw)
4448 (gdb_rl_attempted_completion_function): New.
4449 * completer.h (completion_list, struct completion_result)
4450 (class completion_tracker): New.
4451 (complete_line): Add completion_tracker parameter.
4452 (readline_line_completion_function): Delete.
4453 (gdb_rl_attempted_completion_function): New.
4454 (noop_completer, filename_completer, expression_completer)
4455 (location_completer, symbol_completer, command_completer)
4456 (signal_completer, reg_or_group_completer): Update prototypes.
4457 (completion_tracker_t, new_completion_tracker)
4458 (make_cleanup_free_completion_tracker): Delete.
4459 (enum maybe_add_completion_enum): Delete.
4460 (maybe_add_completion): Delete.
4461 (throw_max_completions_reached_error): Delete.
4462 * corefile.c (complete_set_gnutarget): Adjust to work with a
4463 completion_tracker instead of a VEC.
4464 * cp-abi.c (cp_abi_completer): Adjust to work with a
4465 completion_tracker instead of a VEC.
4466 * d-lang.c (d_language_defn): Adjust.
4467 * disasm.c (disassembler_options_completer): Adjust to work with a
4468 completion_tracker instead of a VEC.
4469 * f-lang.c (f_make_symbol_completion_list): Rename to ...
4470 (f_collect_symbol_completion_matches): ... this. Adjust to work
4471 with a completion_tracker instead of a VEC.
4472 (f_language_defn): Adjust.
4473 * go-lang.c (go_language_defn): Adjust.
4474 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
4475 Adjust to work with a completion_tracker instead of a VEC.
4476 * infrun.c (handle_completer): Likewise.
4477 * interps.c (interpreter_completer): Likewise.
4478 * interps.h (interpreter_completer): Likewise.
4479 * language.c (unknown_language_defn, auto_language_defn)
4480 (local_language_defn): Adjust.
4481 * language.h (language_defn::la_make_symbol_completion_list):
4482 Rename to ...
4483 (language_defn::la_collect_symbol_completion_matches): ... this
4484 and adjust to work with a completion_tracker instead of a VEC.
4485 * m2-lang.c (m2_language_defn): Adjust.
4486 * objc-lang.c (objc_language_defn): Adjust.
4487 * opencl-lang.c (opencl_language_defn): Adjust.
4488 * p-lang.c (pascal_language_defn): Adjust.
4489 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
4490 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
4491 with a completion_tracker.
4492 * rust-lang.c (rust_language_defn): Adjust.
4493 * symtab.c (free_completion_list, do_free_completion_list)
4494 (return_val, completion_tracker): Delete.
4495 (completion_list_add_name, completion_list_add_symbol)
4496 (completion_list_add_msymbol, completion_list_objc_symbol)
4497 (completion_list_add_fields, add_symtab_completions): Add
4498 completion_tracker parameter and use it.
4499 (default_make_symbol_completion_list_break_on_1): Rename to...
4500 (default_collect_symbol_completion_matches_break_on): ... this.
4501 Add completion_tracker parameter and use it instead of allocating
4502 a completion tracker here.
4503 (default_make_symbol_completion_list_break_on): Delete old
4504 implementation.
4505 (default_make_symbol_completion_list): Delete.
4506 (default_collect_symbol_completion_matches): New.
4507 (make_symbol_completion_list): Delete.
4508 (collect_symbol_completion_matches): New.
4509 (make_symbol_completion_type): Rename to ...
4510 (collect_symbol_completion_matches_type): ... this. Add
4511 completion_tracker parameter and use it instead of VEC.
4512 (make_file_symbol_completion_list_1): Rename to...
4513 (collect_file_symbol_completion_matches): ... this. Add
4514 completion_tracker parameter and use it instead of VEC.
4515 (make_file_symbol_completion_list): Delete.
4516 (add_filename_to_list): Use completion_list instead of a VEC.
4517 (add_partial_filename_data::list): Now a completion_list.
4518 (make_source_files_completion_list): Work with a completion_list
4519 instead of a VEC.
4520 * symtab.h: Include "completer.h".
4521 (default_make_symbol_completion_list_break_on)
4522 (default_make_symbol_completion_list, make_symbol_completion_list)
4523 (make_symbol_completion_type, make_file_symbol_completion_list)
4524 (make_source_files_completion_list): Delete.
4525 (default_collect_symbol_completion_matches_break_on)
4526 (default_collect_symbol_completion_matches)
4527 (collect_symbol_completion_matches)
4528 (collect_symbol_completion_matches_type)
4529 (collect_file_symbol_completion_matches)
4530 (make_source_files_completion_list): New.
4531 * top.c (init_main): Don't install a rl_completion_entry_function
4532 hook. Install a rl_attempted_completion_function hook instead.
4533 * tui/tui-layout.c (layout_completer): Adjust to work with a
4534 completion_tracker.
4535 * tui/tui-regs.c (tui_reggroup_completer):
4536 * tui/tui-win.c (window_name_completer, focus_completer)
4537 (winheight_completer): Adjust to work with a completion_tracker.
4538 * value.c: Include "completer.h".
4539 (complete_internalvar): Adjust to work with a completion_tracker.
4540 * value.h (complete_internalvar): Likewise.
4541
6e1dbf8c
PA
45422017-07-17 Pedro Alves <palves@redhat.com>
4543
4544 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
4545 renames.
4546 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
4547 comments to completer_ftype's declaration.
4548 <completer_handle_brkchars>: Change type to
4549 completer_handle_brkchars_ftype.
4550 * command.h (completer_ftype): Add describing comment and give
4551 names to parameters.
4552 (completer_ftype_void): Rename to ...
4553 (completer_handle_brkchars_ftype) ... this. Add describing comment.
4554 (set_cmd_completer_handle_brkchars): Adjust.
4555 * completer.c (filename_completer_handle_brkchars): New function.
4556 (complete_line_internal_normal_command): New function, factored
4557 out from ...
4558 (complete_line_internal): ... here.
4559 (command_completer_handle_brkchars)
4560 (default_completer_handle_brkchars)
4561 (completer_handle_brkchars_func_for_completer): New functions.
4562 * completer.h (set_gdb_completion_word_break_characters): Delete
4563 declaration.
4564 (completer_handle_brkchars_func_for_completer): New declaration.
4565 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
4566 completer_handle_brkchars_func_for_completer.
4567
78b13106
PA
45682017-07-17 Pedro Alves <palves@redhat.com>
4569
4570 * completer.c (symbol_completer): New function, based on
4571 make_symbol_completion_list_fn.
4572 * completer.h (symbol_completer): New declaration.
4573 * guile/scm-cmd.c (cmdscm_completers): Adjust.
4574 * python/py-cmd.c (completers): Adjust.
4575 * symtab.c (make_symbol_completion_list_fn): Delete.
4576 * symtab.h (make_symbol_completion_list_fn): Delete.
4577 * cli/cli-decode.c (add_cmd): Adjust.
4578
bbf2f4df
PA
45792017-07-17 Pedro Alves <palves@redhat.com>
4580
4581 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
4582 * dwarf2read.c: Include "filename-seen-cache.h".
4583 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
4584 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
4585 * filename-seen-cache.c: New file.
4586 * filename-seen-cache.h: New file.
4587 * symtab.c: Include "filename-seen-cache.h".
4588 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
4589 (create_filename_seen_cache, clear_filename_seen_cache)
4590 (delete_filename_seen_cache, filename_seen): Delete, parts moved
4591 to filename-seen-cache.h/filename-seen-cache.c.
4592 (output_source_filename, sources_info)
4593 (maybe_add_partial_symtab_filename)
4594 (make_source_files_completion_list): Adjust to use
4595 filename_seen_cache.
4596
330cdd98
PA
45972017-07-17 Pedro Alves <palves@redhat.com>
4598
4599 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
4600 fields.
4601 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
4602 dwarf2_debug_sections*)): New.
4603 (dwarf2_per_objfile::dwarf2_per_objfile(const
4604 dwarf2_per_objfile&)): Declare as deleted.
4605 (dwarf2_per_objfile::operator=): Declare as deleted.
4606 (dwarf2_per_objfile::dwarf2_per_objfile)
4607 (dwarf2_per_objfile::~dwarf2_per_objfile)
4608 (dwarf2_per_objfile::free_cached_comp_units): New.
4609 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
4610 ctor. Call dwarf2_per_objfile's ctor manually.
4611 (dwarf2_locate_sections): Deleted/refactored as ...
4612 (dwarf2_per_objfile::locate_sections): ... this new method.
4613 (free_cached_comp_units): Defer to
4614 dwarf2_per_objfile::free_cached_comp_units.
4615 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
4616
8880f2a9
TT
46172017-07-14 Tom Tromey <tom@tromey.com>
4618
4619 PR rust/21764:
4620 * rust-exp.y (convert_ast_to_expression): Add "want_type"
4621 parameter.
4622 <UNOP_SIZEOF>: Split into separate case.
4623 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
4624
65547233
TT
46252017-07-14 Tom Tromey <tom@tromey.com>
4626
4627 PR rust/21763:
4628 * symtab.c (symbol_matches_domain): Add language_rust to special
4629 case.
4630 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
4631 treat LOC_TYPEDEF symbols as variables.
4632
8f14146e
PA
46332017-07-14 Pedro Alves <palves@redhat.com>
4634
4635 * symtab.c (make_file_symbol_completion_list_1): Iterate over
4636 symtabs matching all symtabs with SRCFILE as file name instead of
4637 only considering the first hit, with lookup_symtab.
4638
2347965c
SM
46392017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4640
4641 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
4642 operator_name parameters.
4643 (gen_expr): Update function call.
4644
40f4af28
SM
46452017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4646
4647 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
4648 parameter.
4649 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
4650 Likewise.
4651 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
4652 parameter, use agent_expr::gdbarch instead, update function
4653 calls.
4654 (locexpr_tracepoint_var_ref): Likewise.
4655 (loclist_tracepoint_var_ref): Likewise.
4656 * ax-gdb.c (gen_trace_static_fields): Likewise.
4657 (gen_traced_pop): Likewise.
4658 (gen_frame_args_address): Likewise.
4659 (gen_frame_locals_address): Likewise.
4660 (gen_var_ref): Likewise.
4661 (gen_struct_ref_recursive): Likewise.
4662 (gen_static_field): Likewise.
4663 (gen_maybe_namespace_elt): Likewise.
4664 (gen_expr): Likewise.
4665 (gen_trace_for_var): Likewise.
4666 (gen_trace_for_expr): Likewise.
4667 (gen_trace_for_return_address): Likewise.
4668
053f8057
SM
46692017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4670
4671 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
4672 parameter.
4673 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
4674
6661ad48
SM
46752017-07-14 Simon Marchi <simon.marchi@ericsson.com>
4676
4677 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
4678 from ax, update calls.
4679 (gen_usual_arithmetic): Likewise.
4680 (gen_integral_promotions): Likewise.
4681 (gen_bitfield_ref): Likewise.
4682 (gen_primitive_field): Likewise.
4683 (gen_struct_ref_recursive): Likewise.
4684 (gen_struct_ref): Likewise.
4685 (gen_maybe_namespace_elt): Likewise.
4686 (gen_struct_elt_for_reference): Likewise.
4687 (gen_namespace_elt): Likewise.
4688 (gen_aggregate_elt_ref): Likewise.
4689 (gen_expr): Get gdbarch from ax, update calls.
4690 (gen_expr_binop_rest): Likewise.
4691
c55a47e7
PA
46922017-07-13 Pedro Alves <palves@redhat.com>
4693
4694 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
4695 as default tdesc.
4696 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
4697 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
4698 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
4699 tdesc_amd64_linux as default tdesc. Get final tdesc from the
4700 tdep.
4701 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
4702 Get final tdesc from the tdep.
4703 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
4704 default tdesc.
4705 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
4706 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
4707 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
4708 Use it as default tdesc.
4709 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
4710 down to amd_init_abi. No longer handle fallback tdesc here.
4711 * amd64-tdep.h (tdesc_x32): Declare.
4712 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
4713 parameter.
4714 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
4715 as default tdesc.
4716
55efceab
AA
47172017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4718
4719 * s390-linux-tdep.c (s390_process_record): Add support for
4720 instructions new in arch12.
4721
0aa37b65
JB
47222017-07-11 John Baldwin <jhb@FreeBSD.org>
4723
4724 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
4725 PT_GETFSBASE and PT_GETGSBASE.
4726 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
4727 PT_SETGSBASE.
4728
48aeef91
JB
47292017-07-11 John Baldwin <jhb@FreeBSD.org>
4730
4731 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
4732 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
4733 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
4734 those rules.
4735 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
4736 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
4737 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
4738 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
4739 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
4740 * features/i386/amd64.xml: Add 64bit-segments.xml.
4741 * features/i386/amd64-avx-avx512.c: Regenerated.
4742 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
4743 * features/i386/amd64-avx-mpx.c: Regenerated.
4744 * features/i386/amd64-avx.c: Regenerated.
4745 * features/i386/amd64-mpx.c: Regenerated.
4746 * features/i386/amd64.c: Regenerated.
4747 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
4748 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
4749 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
4750 * regformats/i386/amd64-avx.dat: Regenerated.
4751 * regformats/i386/amd64-mpx.dat: Regenerated.
4752 * regformats/i386/amd64.dat: Regenerated.
4753
77c501bc
YQ
47542017-07-10 Yao Qi <yao.qi@linaro.org>
4755
4756 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4757 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4758
6dc8d757
AK
47592017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
4760
4761 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
4762 unsetenv.
4763 * gnulib/aclocal.m4: Regenerate.
4764 * gnulib/config.in: Regenerate.
4765 * gnulib/configure: Regenerate.
4766 * gnulib/import/Makefile.am: Regenerate.
4767 * gnulib/import/Makefile.in: Regenerate.
4768 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4769 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4770 * gnulib/import/m4/environ.m4: New file.
4771 * gnulib/import/m4/setenv.m4: New file.
4772 * gnulib/import/setenv.c: New file.
4773 * gnulib/import/unsetenv.c: New file.
4774
266934d1
SM
47752017-07-09 Simon Marchi <simon.marchi@ericsson.com>
4776
4777 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
4778 address when op is DW_OP_addr.
4779
03278692
TT
47802017-07-09 Tom Tromey <tom@tromey.com>
4781
4782 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
4783 check and apply to outer type.
4784
4b654465
JB
47852017-07-07 John Baldwin <jhb@FreeBSD.org>
4786
4787 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
4788 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
4789 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
4790 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
4791
2af9fc44
JB
47922017-07-07 John Baldwin <jhb@FreeBSD.org>
4793
4794 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
4795
382b69bb
JB
47962017-07-07 John Baldwin <jhb@FreeBSD.org>
4797
4798 * corelow.c (get_core_siginfo): Remove.
4799 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
4800 instead of get_core_siginfo.
4801 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
4802 * gdbarch.h: Re-generate.
4803 * gdbarch.c: Re-generate.
4804 * linux-tdep.c (linux_core_xfer_siginfo): New.
4805 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
4806
6e5eab33
JB
48072017-07-07 John Baldwin <jhb@FreeBSD.org>
4808
4809 * corelow.c (thread_section_name): Move to ...
4810 * gdbcore.h (thread_section_name): ... here.
4811
929edea9
JB
48122017-07-07 John Baldwin <jhb@FreeBSD.org>
4813
4814 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
4815 (struct siginfo32): New.
4816 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
4817 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
4818 via ptrace(PT_LWPINFO).
4819
762c974a
JB
48202017-07-07 John Baldwin <jhb@FreeBSD.org>
4821
4822 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
4823 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
4824 (fbsd_get_siginfo_type): New.
4825 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
4826 (_initialize_fbsd_tdep): New.
4827
33c5cd75
DB
48282017-07-06 David Blaikie <dblaikie@gmail.com>
4829
4830 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
4831 a singular dwo_unit*) to support multiple CUs in the same way that
4832 multiple TUs are supported.
4833 (create_cus_hash_table): Replace create_dwo_cu with a function for
4834 parsing multiple CUs from a DWO file.
4835 (open_and_init_dwo_file): Use create_cus_hash_table rather than
4836 create_dwo_cu.
4837 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
4838 htab_find, rather than comparing the signature to a singleton CU in
4839 the dwo_file.
4840
8455d262
PA
48412017-07-06 Pedro Alves <palves@redhat.com>
4842
4843 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
4844
4da3eb35
PA
48452017-07-04 Pedro Alves <palves@redhat.com>
4846
4847 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
4848 * gdbtypes.h (TYPE_STATIC): Delete.
4849 (struct fn_field) <is_public, is_abstract, is_static, is_final,
4850 is_synchronized, is_native>: Delete.
4851 <dummy>: Bump.
4852 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
4853 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
4854 (TYPE_FN_FIELD_ABSTRACT): Delete.
4855
5bfd255c
SM
48562017-07-03 Simon Marchi <simon.marchi@ericsson.com>
4857
4858 * buffer.h (buffer_finish): Fix spelling mistakes.
4859
25c54127
EZ
48602017-07-01 Eli Zaretskii <eliz@gnu.org>
4861
4862 * .dir-locals.el: Automatically switch to C-style comments in
4863 versions of Emacs that support the feature.
4864
dc4bde35
SDJ
48652017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
4866 Pedro Alves <palves@redhat.com>
4867
4868 PR cli/21688
4869 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
4870 (process_next_line): New variable 'inline_cmd'.
4871 Adjust 'if' clauses for "python", "compile" and "guile" to use
4872 'command_name_equals' and check for '!inline_cmd'.
4873
51ed89aa
SDJ
48742017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
4875
4876 PR cli/21688
4877 * cli/cli-script.c (command_name_equals_not_inline): New function.
4878 (process_next_line): Adjust 'if' clauses for "python", "compile"
4879 and "guile" to use command_name_equals_not_inline.
4880
eb17d413
PA
48812017-06-29 Pedro Alves <palves@redhat.com>
4882
4883 * completer.c (expression_completer): Call
4884 linespec_location_completer instead of location_completer.
4885
195bcdd5
PA
48862017-06-29 Pedro Alves <palves@redhat.com>
4887
4888 * completer.c (expression_completer): Remove code that recomputes
4889 'text' from 'word'.
4890
adc764e7
YQ
48912017-06-29 Yao Qi <yao.qi@linaro.org>
4892
4893 * regformats/regdat.sh: Generate code with
4894 "ifndef IN_PROCESS_AGENT".
4895
6e75794e
PA
48962017-06-28 Pedro Alves <palves@redhat.com>
4897
4898 * command.h: Include "common/scoped_restore.h".
4899
bc491f2e
YQ
49002017-06-28 Yao Qi <yao.qi@linaro.org>
4901
4902 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
4903 instead of obstack_grow.
4904
41664b45
DG
49052017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
4906
4907 PR gdb/21337
4908 * symfile.c (reread_symbols): Call objfiles_changed just before
4909 read_symbols.
4910
6da67eb1
PA
49112017-06-27 Pedro Alves <palves@redhat.com>
4912
4913 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
4914 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
4915 (completion_list_add_symbol, completion_list_add_msymbol):
4916 ... these new functions.
4917 (add_symtab_completions)
4918 (default_make_symbol_completion_list_break_on_1): Adjust.
4919
23732b1e
PA
49202017-06-27 Pedro Alves <palves@redhat.com>
4921
4922 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
4923 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
4924 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
4925 dtor.
4926 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
4927 'storage_obstack' field an auto_obstack. In-class initialize all
4928 non-bitfield fields. Make minsyms_read bool.
4929 * symfile.c (read_symbols): Adjust.
4930
a4d1e79a
AH
49312017-06-27 Alan Hayward <alan.hayward@arm.com>
4932
4933 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
4934 (gdbsim_store_register): Likewise.
4935
8268c778
PA
49362017-06-27 Pedro Alves <palves@redhat.com>
4937
4938 * c-exp.y (name_obstack): Now an auto_obstack.
4939 (yylex): Use auto_obstack::clear.
4940 (c_parse): Use auto_obstack::clear instead of reinitializing and
4941 freeing the obstack.
4942 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
4943 * d-exp.y (name_obstack): Now an auto_obstack.
4944 (yylex): Use auto_obstack::clear.
4945 (d_parse): Use auto_obstack::clear instead of reinitializing and
4946 freeing the obstack.
4947 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
4948 auto_obstack.
4949 * dwarf2read.c (create_addrmap_from_index)
4950 (dwarf2_build_psymtabs_hard)
4951 (update_enumeration_type_from_children): Likewise.
4952 * gdb_obstack.h (auto_obstack): New type.
4953 * go-exp.y (name_obstack): Now an auto_obstack.
4954 (build_packaged_name): Use auto_obstack::clear.
4955 (go_parse): Use auto_obstack::clear instead of reinitializing and
4956 freeing the obstack.
4957 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
4958 auto_obstack.
4959 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
4960 * rust-exp.y (work_obstack): Now an auto_obstack.
4961 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
4962 reinitializing and freeing the obstack.
4963 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
4964 (host_char_to_target): Use auto_obstack.
4965 * utils.h (make_cleanup_obstack_free): Delete declaration.
4966 * valprint.c (generic_emit_char, generic_printstr): Use
4967 auto_obstack.
4968
db665f42
SM
49692017-06-27 Simon Marchi <simon.marchi@ericsson.com>
4970
4971 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
4972 thread.
4973 (darwin_init_thread_list): Don't update dummy thread.
4974 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
4975
873c0814
SM
49762017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4977
4978 * record-full.c (netorder16): Remove.
4979
8b5a7a6e
SM
49802017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4981
4982 * common/diagnostics.h: Define macros for GCC.
4983 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
4984 * common/vec.h: Include diagnostics.h.
4985 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
4986 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
4987 warning.
4988
d1435379
SM
49892017-06-26 Simon Marchi <simon.marchi@ericsson.com>
4990
4991 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
4992 New macro.
4993 * ada-lex.l: Ignore deprecated register warnings.
4994
cc75e0fd
SM
49952017-06-25 Simon Marchi <simon.marchi@ericsson.com>
4996
4997 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
4998 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
4999
07809eaf
SM
50002017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5001
5002 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
5003 its own line.
5004
f076f034
SM
50052017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5006
5007 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
5008
0dd5cbc5
AH
50092017-06-23 Alan Hayward <alan.hayward@arm.com>
5010
5011 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
5012 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
5013 (xtensa_register_read_masked): Likewise.
5014
d4c6ce5b
SDJ
50152017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
5016
5017 * common/environ.c (gdb_environ::unset): Update comment.
5018
16892a03
AH
50192017-06-22 Alan Hayward <alan.hayward@arm.com>
5020
5021 * python/py-unwind.c (pyuw_sniffer): Allocate space for
5022 registers.
5023
d7dcbefc
AH
50242017-06-22 Alan Hayward <alan.hayward@arm.com>
5025
5026 * record-full.c (record_full_exec_insn): Use byte_vector.
5027
b30ff123
YQ
50282017-06-22 Yao Qi <yao.qi@linaro.org>
5029
5030 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
5031 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5032
4fa847d7
AH
50332017-06-22 Alan Hayward <alan.hayward@arm.com>
5034
5035 * remote.c (cached_reg): Move from here...
5036 * regcache.h (cached_reg): ...to here.
5037 * python/py-unwind.c (struct reg_info): Remove.
5038 (cached_frame_info): Use cached_reg_t.
5039 (pyuw_prev_register): Likewise.
5040 (pyuw_sniffer): Use cached_reg_t and allocate registers.
5041 (pyuw_dealloc_cache): Free all registers.
5042
f4906a9a
PA
50432017-06-22 Pedro Alves <palves@redhat.com>
5044 Simon Marchi <simon.marchi@ericsson.com>
5045
5046 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
5047 warning.
5048 * common/diagnostics.h: New file.
5049
b45a1208
PA
50502017-06-22 Pedro Alves <palves@redhat.com>
5051
5052 * common/agent.h: Add include guards.
5053
e4da2c61
SM
50542017-06-21 Simon Marchi <simon.marchi@ericsson.com>
5055
5056 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
5057 talk about addressable units instead of bytes.
5058
96160d60
SDJ
50592017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5060
5061 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
5062 of '::const_iterator'.
5063
9a6c7d9c
SDJ
50642017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5065
5066 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5067 'unittests/environ-selftests.c'.
5068 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
5069 * charset.c (find_charset_names): Declare object 'iconv_env'.
5070 Update code to use 'iconv_env' object. Remove call to
5071 'free_environ'.
5072 * common/environ.c: Include <utility>.
5073 (make_environ): Delete function.
5074 (free_environ): Delete function.
5075 (gdb_environ::clear): New function.
5076 (gdb_environ::operator=): New function.
5077 (gdb_environ::get): Likewise.
5078 (environ_vector): Delete function.
5079 (set_in_environ): Delete function.
5080 (gdb_environ::set): New function.
5081 (unset_in_environ): Delete function.
5082 (gdb_environ::unset): New function.
5083 (gdb_environ::envp): Likewise.
5084 * common/environ.h: Include <vector>.
5085 (struct gdb_environ): Delete; transform into...
5086 (class gdb_environ): ... this class.
5087 (free_environ): Delete prototype.
5088 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
5089 environ_vector): Likewise.
5090 * infcmd.c (run_command_1): Update code to call
5091 'envp' from 'gdb_environ' class.
5092 (environment_info): Update code to call methods from 'gdb_environ'
5093 class.
5094 (unset_environment_command): Likewise.
5095 (path_info): Likewise.
5096 (path_command): Likewise.
5097 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
5098 (inferior::inferior): Initialize 'environment' using the host's
5099 information.
5100 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
5101 Include "environ.h".
5102 (class inferior) <environment>: Change type from 'struct
5103 gdb_environ' to 'gdb_environ'.
5104 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
5105 methods from 'gdb_environ' class.
5106 * solib.c (solib_find_1): Likewise
5107 * unittests/environ-selftests.c: New file.
5108
75c554cf
YQ
51092017-06-20 Yao Qi <yao.qi@linaro.org>
5110
5111 * features/i386/i386-linux.xml: Exchange the order of including
5112 32bit-linux.xml and 32bit-sse.xml.
5113 * features/i386/i386-linux.c: Regenerated.
5114
72ddacb7
YQ
51152017-06-20 Yao Qi <yao.qi@linaro.org>
5116
5117 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
5118 Delete copy ctor and assignment operator.
5119 (tdesc_type): Likewise.
5120 (tdesc_feature): Likewise.
5121 (tdesc_free_reg): Remove.
5122 (tdesc_create_reg): Use new.
5123 (tdesc_free_type): Remove.
5124 (tdesc_create_vector): Use new.
5125 (tdesc_create_union): Likewise.
5126 (tdesc_create_flags): Likewise.
5127 (tdesc_create_enum): Likewise.
5128 (tdesc_free_feature): Delete.
5129 (free_target_description): Use delete.
5130
325c9fd4
JB
51312017-06-19 John Baldwin <jhb@FreeBSD.org>
5132
5133 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
5134 registers.
5135
16b7a719
PA
51362017-06-19 Pedro Alves <palves@redhat.com>
5137
5138 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
5139 after gdb::unlinker.
5140
1c8e01c9
SDJ
51412017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
5142
5143 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
5144 gdb_environ to access an environment variable.
5145
ffce45d2
TP
51462017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5147
5148 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
5149 gdb_byte*.
5150
1d4fbac9
SM
51512017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5152
5153 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
5154
8465943a
SM
51552017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5156
5157 * configure: Re-generate.
5158 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
5159
3e019bdc
SM
51602017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5161
5162 * configure: Re-generate.
5163 * warning.m4: Pass -Werror to compiler when checking for
5164 supported warning flags.
5165
cf0dd6f0
SM
51662017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5167
5168 * Makefile.in (COMPILE.pre): Add "-x c++".
5169
6f98355c
YQ
51702017-06-16 Alan Hayward <alan.hayward@arm.com>
5171 Pedro Alves <palves@redhat.com>
5172 Yao Qi <yao.qi@linaro.org>
5173
5174 * defs.h (RequireLongest): New.
5175 (extract_integer): Declare function template.
5176 (extract_signed_integer): Remove the declaration, but define it
5177 static inline.
5178 (extract_unsigned_integer): Likewise.
5179 (store_integer): Declare function template.
5180 (store_signed_integer): Remove the declaration, but define it
5181 static inline.
5182 (store_unsigned_integer): Likewise.
5183 * findvar.c (extract_integer): New function template.
5184 (extract_signed_integer): Remove.
5185 (extract_unsigned_integer): Remove.
5186 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5187 instantiations.
5188 (store_integer): New function template.
5189 (store_signed_integer): Remove.
5190 (store_unsigned_integer): Remove.
5191 (store_integer): Explicit instantiations.
5192 * regcache.c (regcache_raw_read_signed): Update.
5193 (regcache::raw_read): New function.
5194 (regcache::raw_read_signed): Remove.
5195 (regcache::raw_read_unsigned): Remove.
5196 (regcache_raw_read_unsigned): Update.
5197 (regcache_raw_write_unsigned): Update.
5198 (regcache::raw_write_signed): Remove.
5199 (regcache::raw_write): New function.
5200 (regcache_cooked_read_signed): Update.
5201 (regcache::raw_write_unsigned): Remove.
5202 (regcache::cooked_read_signed): Remove.
5203 (regcache_cooked_read_unsigned): Update.
5204 (regcache::cooked_read_unsigned): Remove.
5205 (regcache_cooked_write_signed): Update.
5206 (regcache_cooked_write_unsigned): Update.
5207 * regcache.h (regcache) <raw_read_signed>: Remove.
5208 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5209 <raw_read, raw_write>: New.
5210 <cooked_read_signed, cooked_write_signed>: Remove.
5211 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5212 <cooked_read, cooked_write>: New.
5213 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5214 (sh64_pseudo_register_write): Update.
5215
a87dc45a
AK
52162017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5217
5218 * arc-tdep.c (arc_disassembler_options): New variable.
5219 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5220 of default_print_insn.
5221 (arc_delayed_print_insn): Set info->section when needed,
5222 use default_print_insn to retrieve a disassembler.
5223
45159d6a
SDJ
52242017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5225
5226 PR gdb/21574
5227 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5228 to mention $SHELL and startup-with-shell.
5229
b46c4cf0
MF
52302017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5231
5232 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5233
6394c606
YQ
52342017-06-14 Yao Qi <yao.qi@linaro.org>
5235
5236 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5237 default_print_insn instead of print_insn_aarch64.
5238 * arm-tdep.c (gdb_print_insn_arm): Call
5239 default_print_insn instead of print_insn_big_arm
5240 and print_insn_little_arm.
5241 * i386-tdep.c (i386_print_insn): Call default_print_insn
5242 instead of print_insn_i386.
5243 * ia64-tdep.c (ia64_print_insn): Call
5244 default_print_insn instead of print_insn_ia64.
5245 * mips-tdep.c (gdb_print_insn_mips): Call
5246 default_print_insn instead of print_insn_big_mips
5247 and print_insn_little_mips.
5248 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5249 instead of print_insn_spu.
5250
d5722aa2
PA
52512017-06-14 Pedro Alves <palves@redhat.com>
5252
5253 * ada-lang.c: Include "common/byte-vector.h".
5254 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5255 * charset.c (wchar_iterator::iterate): Resize the vector instead
5256 of reserving it.
5257 * common/byte-vector.h: Include "common/def-vector.h".
5258 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5259 * cli/cli-dump.c: Include "common/byte-vector.h".
5260 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5261 * common/byte-vector.h: New file.
5262 * common/def-vector.h: New file.
5263 * common/default-init-alloc.h: New file.
5264 * dwarf2loc.c: Include "common/byte-vector.h".
5265 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5266 instead of reserving it.
5267 * dwarf2read.c: Include "common/byte-vector.h".
5268 (data_buf::m_vec): Now a gdb::byte_vector.
5269 * gdb_regex.c: Include "common/def-vector.h".
5270 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5271 * mi/mi-main.c: Include "common/byte-vector.h".
5272 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5273 * printcmd.c: Include "common/byte-vector.h".
5274 (print_scalar_formatted): Use gdb::byte_vector.
5275 * valprint.c: Include "common/byte-vector.h".
5276 (maybe_negate_by_bytes, print_decimal_chars): Use
5277 gdb::byte_vector.
5278
01ec7a27
SM
52792017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5280
5281 * darwin-nat.c: Include "nat/fork-inferior.h".
5282
848d9074
SM
52832017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5284
5285 * configure.nat: Factor out Darwin bits that are not
5286 architecture-specific. Add fork-inferior.o.
5287
3b912944
SM
52882017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5289
5290 * configure.nat: Factor out AIX bits that are not
5291 architecture-specific. Add fork-inferior.o.
5292
55acdf22
AA
52932017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5294
5295 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5296 (read_pieced_value, write_pieced_value): ...here. Reduce to
5297 wrappers that just call rw_pieced_value.
5298
f65e2044
AA
52992017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5300
5301 * dwarf2loc.c (write_pieced_value): When writing the data for a
5302 memory piece, use write_memory_with_notification instead of
5303 write_memory.
5304
23f945bf
AA
53052017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5306
5307 * valops.c (read_value_memory): Change embedded_offset to
5308 represent a bit offset instead of a byte offset.
5309 * value.h (read_value_memory): Adjust comment.
5310
f236533e
AA
53112017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5312
5313 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5314 dest_offset_bits and source_offset_bits.
5315 (write_pieced_value): Likewise.
5316
65d84b76
AA
53172017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5318
5319 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5320 given by DW_OP_bit_piece.
5321 (write_pieced_value): Likewise.
5322
242d31ab
AA
53232017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5324
5325 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5326 some other preparations to the places where sufficient information
5327 is available.
5328 (write_pieced_value): Likewise.
5329
03c8af18
AA
53302017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5331
5332 * dwarf2loc.c (bits_to_bytes): New function.
5333 (read_pieced_value): Fix offset calculations for register pieces
5334 on big-endian targets.
5335 (write_pieced_value): Likewise.
5336
840989c1
AA
53372017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5338
5339 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5340 (write_pieced_value): Likewise.
5341
359b19bb
AA
53422017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5343
5344 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5345 transfer the source value's least significant bits, instead of its
5346 lowest-addressed ones. Rename type_len to max_offset.
5347 (read_pieced_value): Mirror above changes to write_pieced_value as
5348 applicable.
5349
07c9ca3b
AA
53502017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5351
5352 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5353 truncate full bytes from dest_offset_bits before using it as an
5354 offset into the buffer.
5355
f1cc9874
AA
53562017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5357
5358 * dwarf2loc.c (write_pieced_value): Include transfer size in
5359 byte-wise check.
5360
cdaac320
AA
53612017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5362
5363 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5364 calculation of this_size.
5365
af547a96
AA
53662017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5367
5368 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5369 when targeting a bit-field.
5370 (write_pieced_value): Likewise.
5371
ddd7882a
AA
53722017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5373
5374 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5375 (allocate_piece_closure): Drop addr_size parameter.
5376 (dwarf2_evaluate_loc_desc_full): Adjust call to
5377 allocate_piece_closure.
5378
e9352324
AA
53792017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5380
5381 PR gdb/21226
5382 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5383 the LSB end, independent of endianness.
5384
d5d1163e
AA
53852017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5386
5387 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5388 size capping.
5389
032bb6ea
YQ
53902017-06-13 Yao Qi <yao.qi@linaro.org>
5391
5392 * mips-linux-nat.c: Move include features/mips*-linux.c to
5393 mips-linux-tdep.c.
5394 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5395 to mips-linux-tdep.c.
5396 * mips-linux-tdep.c: Include features/mips*-linux.c
5397 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5398 functions.
5399 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5400 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5401 (tdesc_mips64_dsp_linux): Declare.
5402
f12f6bad
TT
54032017-06-12 Tom Tromey <tom@tromey.com>
5404
5405 * valprint.h (val_print_type_code_int): Remove.
5406 * valprint.c (generic_val_print_int): Always call
5407 val_print_scalar_formatted.
5408 (val_print_type_code_int): Remove.
5409 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5410 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5411 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5412 * ada-valprint.c (ada_val_print_num): Use
5413 val_print_scalar_formatted.
5414
d9109c80
TT
54152017-06-12 Tom Tromey <tom@tromey.com>
5416
5417 * printcmd.c (print_scalar_formatted): Unify the two switches.
5418 Don't convert scalars to LONGEST.
5419
4ac0cb1c
TT
54202017-06-12 Tom Tromey <tom@tromey.com>
5421
5422 PR exp/16225:
5423 * valprint.h (print_decimal_chars): Update.
5424 * valprint.c (maybe_negate_by_bytes): New function.
5425 (print_decimal_chars): Add "is_signed" argument.
5426 * printcmd.c (print_scalar_formatted): Update.
5427
30a25466
TT
54282017-06-12 Tom Tromey <tom@tromey.com>
5429
5430 PR exp/16225:
5431 * valprint.h (print_binary_chars, print_hex_chars): Update.
5432 * valprint.c (val_print_type_code_int): Update.
5433 (print_binary_chars): Add "zero_pad" argument.
5434 (emit_octal_digit): New function.
5435 (print_octal_chars): Don't zero-pad.
5436 (print_decimal_chars): Likewise.
5437 (print_hex_chars): Add "zero_pad" argument.
5438 * sh64-tdep.c (sh64_do_fp_register): Update.
5439 * regcache.c (regcache::dump): Update.
5440 * printcmd.c (print_scalar_formatted): Update.
5441 * infcmd.c (default_print_one_register_info): Update.
5442
b3464d03
PA
54432017-06-12 Pedro Alves <palves@redhat.com>
5444 Alan Hayward <alan.hayward@arm.com>
5445
5446 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5447 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5448 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5449 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5450 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5451
4b76cda9
PA
54522017-06-12 Pedro Alves <palves@redhat.com>
5453
5454 * dwarf2read.c (mapped_symtab::data): Now a vector of
5455 symtab_index_entry instead of vector of
5456 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5457 whether an element's name is NULL instead of checking whether the
5458 element itself is NULL.
5459 (find_slot): Change return type. Adjust.
5460 (hash_expand, , add_index_entry, uniquify_cu_indices)
5461 (write_hash_table): Adjust.
5462
e8f8bcb3
PA
54632017-06-12 Pedro Alves <palves@redhat.com>
5464
5465 * dwarf2read.c (recursively_count_psymbols): New function.
5466 (write_psymtabs_to_index): Call it to compute number of psyms and
5467 pass estimate size of psyms_seen to unordered_set's ctor.
5468
70a1152b
PA
54692017-06-12 Pedro Alves <palves@redhat.com>
5470
5471 * dwarf2read.c (write_hash_table): Check if key already exists
5472 before emplacing.
5473
c2f134ac
PA
54742017-06-12 Pedro Alves <palves@redhat.com>
5475
5476 * dwarf2read.c (data_buf::append_space): Rename to...
5477 (data_buf::grow): ... this, and make private. Adjust all callers.
5478 (data_buf::append_uint): New method.
5479 (add_address_entry, write_one_signatured_type)
5480 (write_psymtabs_to_index): Use it.
5481
a81e6d4d
PA
54822017-06-12 Pedro Alves <palves@redhat.com>
5483
5484 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
5485 (file_write (FILE *, const std::vector<Elem>&)): Delete.
5486 (data_buf::file_write): Call ::fwrite directly.
5487
6fd931f2
PA
54882017-06-12 Pedro Alves <palves@redhat.com>
5489
5490 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
5491 std::vector::erase.
5492
bc8f2430
JK
54932017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5494
5495 Code cleanup: C++ify .gdb_index producer.
5496 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
5497 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
5498 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
5499 (create_strtab, add_string): Remove.
5500 (file_write, data_buf): New.
5501 (struct symtab_index_entry): Use std::vector for cu_indices.
5502 (struct mapped_symtab): Use std::vector for data.
5503 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
5504 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
5505 Remove.
5506 (find_slot): Change return type. Update it to the new data structures.
5507 (hash_expand, add_index_entry): Update it to the new data structures.
5508 (offset_type_compare): Remove.
5509 (uniquify_cu_indices): Update it to the new data structures.
5510 (c_str_view, c_str_view_hasher, vector_hasher): New.
5511 (add_indices_to_cpool): Remove.
5512 (write_hash_table): Update it to the new data structures.
5513 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
5514 (eq_psymtab_cu_index): Remove.
5515 (psym_index_map): New typedef.
5516 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
5517 reference and std::unordered_map for cu_index_htab.
5518 (add_address_entry, add_address_entry_worker, write_address_map)
5519 (write_psymbols): Update it to the new data structures.
5520 (write_obstack): Remove.
5521 (struct signatured_type_index_data): Change types_list to a data_buf
5522 reference and psyms_seen to a std::unordered_set reference.
5523 (write_one_signatured_type, recursively_write_psymbols)
5524 (write_psymtabs_to_index): Update it to the new data structures.
5525
c4dcb155
SM
55262017-06-11 Simon Marchi <simon.marchi@ericsson.com>
5527
5528 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
5529 separate-debug-file commands.
5530 * symfile.h (separate_debug_file_debug): New global.
5531 * symfile.c (separate_debug_file_debug): New global.
5532 (separate_debug_file_exists, find_separate_debug_file): Add
5533 debug output.
5534 (_initialize_symfile): Add "set debug separate-debug-file"
5535 command.
5536 * build-id.c (build_id_to_debug_bfd,
5537 find_separate_debug_file_by_buildid): Add debug output.
5538
6d45d4b4
SM
55392017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5540
5541 * gdbarch.sh (displaced_step_free_closure): Remove.
5542 * gdbarch.h, gdbarch.c: Re-generate.
5543 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
5544 displaced_step_free_closure.
5545 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
5546 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
5547 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5548 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
5549 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5550 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5551 * arch-utils.h (simple_displaced_step_free_closure): Remove.
5552 * arch-utils.c (simple_displaced_step_free_closure): Remove.
5553 * infrun.c (displaced_step_clear): Call xfree instead of
5554 gdbarch_displaced_step_free_closure.
5555
2f91880f
SDJ
55562017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
5557
5558 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
5559 NULL".
5560
b8b6e72f
AH
55612017-06-08 Alan Hayward <alan.hayward@arm.com>
5562
5563 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
5564 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
5565 (mn10300_push_dummy_call): Likewise.
5566
5369082e
AH
55672017-06-08 Alan Hayward <alan.hayward@arm.com>
5568
5569 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
5570
ff4ca5ac
AH
55712017-06-08 Alan Hayward <alan.hayward@arm.com>
5572
5573 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
5574
aefd8b33
SDJ
55752017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5576
5577 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
5578 able to start inferiors using a shell.
5579 (New remote packets): Announce new packet "QStartupWithShell".
5580 * remote.c: Add PACKET_QStartupWithShell.
5581 (extended_remote_create_inferior): Handle new
5582 PACKET_QStartupWithShell.
5583 (remote_protocol_features) <QStartupWithShell>: New entry for
5584 PACKET_QStartupWithShell.
5585 (_initialize_remote): Call "add_packet_config_cmd" for
5586 QStartupShell.
5587
2090129c
SDJ
55882017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5589 Pedro Alves <palves@redhat.com>
5590
5591 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
5592 and "nat/fork-inferior.h".
5593 * common/common-inferior.h: New file, with contents from
5594 "gdb/inferior.h".
5595 * commom/common-utils.c: Include "common-utils.h".
5596 (stringify_argv): New function.
5597 * common/common-utils.h (stringify_argv): New prototype.
5598 * configure.nat: Add "fork-inferior.o" as a dependency for
5599 "*linux*", "fbsd*" and "nbsd*" hosts.
5600 * corefile.c (get_exec_file): Update comment.
5601 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
5602 instead of "startup_inferior".
5603 (darwin_create_inferior): Call "add_thread_silent" after
5604 "fork_inferior".
5605 * fork-child.c: Cleanup unnecessary includes.
5606 (SHELL_FILE): Move to "common/common-fork-child.c".
5607 (environ): Likewise.
5608 (exec_wrapper): Initialize.
5609 (get_exec_wrapper): New function.
5610 (breakup_args): Move to "common/common-fork-child.c"; rename to
5611 "breakup_args_for_exec".
5612 (escape_bang_in_quoted_argument): Move to
5613 "common/common-fork-child.c".
5614 (saved_ui): New variable.
5615 (prefork_hook): New function.
5616 (postfork_hook): Likewise.
5617 (postfork_child_hook): Likewise.
5618 (gdb_startup_inferior): Likewise.
5619 (fork_inferior): Move to "common/common-fork-child.c". Update
5620 function to support gdbserver.
5621 (startup_inferior): Likewise.
5622 * gdbcore.h (get_exec_file): Remove declaration.
5623 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
5624 instead of "startup_inferior". Call "add_thread_silent" after
5625 "fork_inferior".
5626 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
5627 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
5628 instead of "startup_inferior". Call "add_thread_silent" after
5629 "fork_inferior".
5630 * inferior.h: Include "common-inferior.h".
5631 (trace_start_error): Move to "common/common-utils.h".
5632 (trace_start_error_with_name): Likewise.
5633 (fork_inferior): Move prototype to "nat/fork-inferior.h".
5634 (startup_inferior): Likewise.
5635 (gdb_startup_inferior): New prototype.
5636 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
5637 * nat/fork-inferior.h: New file.
5638 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
5639 instead of "startup_inferior". Call "add_thread_silent" after
5640 "fork_inferior".
5641 * target.h (target_terminal_init): Move prototype to
5642 "target/target.h".
5643 (target_terminal_inferior): Likewise.
5644 (target_terminal_ours): Likewise.
5645 * target/target.h (target_terminal_init): New prototype, moved
5646 from "target.h".
5647 (target_terminal_inferior): Likewise.
5648 (target_terminal_ours): Likewise.
5649 * utils.c (gdb_flush_out_err): New function.
5650
043a4934
SDJ
56512017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5652
5653 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
5654 * common/common-gdbthread.h: New file, with parts from
5655 "gdb/gdbthread.h".
5656 * gdbthread.h: Include "common-gdbthread.h".
5657 (switch_to_thread): Moved to "common/common-gdbthread.h".
5658
15652511
SDJ
56592017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5660
5661 * Makefile.in (SFILES): Add "common/job-control.c".
5662 (HFILES_NO_SRCDIR): Add "common/job-control.h".
5663 (COMMON_OBS): Add "job-control.o".
5664 * common/job-control.c: New file, with contents from
5665 "gdb/inflow.c".
5666 * common/job-control.h: New file, with contents from "terminal.h".
5667 * fork-child.c: Include "job-control.h".
5668 * inflow.c: Include "job-control.h".
5669 (gdb_setpgid): Move to "common/common-inflow.c".
5670 (_initialize_inflow): Move setting of "job_control" to
5671 "handle_job_control".
5672 * terminal.h (job_control): Moved to "common/common-terminal.h".
5673 (gdb_setpgid): Likewise.
5674 * top.c: Include "job_control.h".
5675 * utils.c: Likewise.
5676 (job_control): Moved to "job-control.c".
5677
2d7cc5c7
PA
56782017-06-07 Pedro Alves <palves@redhat.com>
5679
5680 * Makefile.in (SFILES): Add gdb_regex.c.
5681 (COMMON_OBS): Add gdb_regex.o.
5682 * ada-lang.c (ada_add_standard_exceptions)
5683 (ada_add_exceptions_from_frame, name_matches_regex)
5684 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
5685 parameter type to compiled_regex. Adjust.
5686 (ada_exceptions_list): Use compiled_regex.
5687 * break-catch-throw.c (exception_catchpoint::pattern): Now a
5688 std::unique_ptr<compiled_regex>.
5689 (exception_catchpoint::~exception_catchpoint): Remove regfree
5690 call.
5691 (check_status_exception_catchpoint): Adjust to use compiled_regex.
5692 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
5693 * breakpoint.c (solib_catchpoint::compiled): Now a
5694 std::unique_ptr<compiled_regex>.
5695 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
5696 (check_status_catch_solib): Adjust to use compiled_regex.
5697 (add_solib_catchpoint): Adjust to use compiled_regex.
5698 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
5699 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
5700 compiled_regex reference. Adjust to use it.
5701 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
5702 declaration. Include "gdb_regex.h".
5703 (apropos_cmd): Change regex parameter to compiled_regex reference.
5704 * gdb_regex.c: New file.
5705 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
5706 declarations.
5707 (class compiled_regex): New.
5708 * linux-tdep.c: Include "common/gdb_optional.h".
5709 (struct mapping_regexes): New, factored out from
5710 mapping_is_anonymous_p, and adjusted to use compiled_regex.
5711 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
5712 gdb::optional and remove cleanups. Adjust to compiled_regex.
5713 * probe.c: Include "common/gdb_optional.h".
5714 (collect_probes): Use compiled_regex and gdb::optional and remove
5715 cleanups.
5716 * skip.c: Include "common/gdb_optional.h".
5717 (skiplist_entry::compiled_function_regexp): Now a
5718 gdb::optional<compiled_regex>.
5719 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
5720 (free_skiplist_entry): Remove regfree call.
5721 (compile_skip_regexp, skip_rfunction_p): Adjust to use
5722 compiled_regex and gdb::optional.
5723 * symtab.c: Include "common/gdb_optional.h".
5724 (search_symbols): Use compiled_regex and gdb::optional.
5725 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
5726 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
5727 to gdb_regex.c.
5728
50d6adef
AH
57292017-06-07 Alan Hayward <alan.hayward@arm.com>
5730
5731 * regcache.c (regcache::save): Avoid buffer use.
5732 (regcache::dump): Likewise.
5733
4a8a33c8
AH
57342017-06-07 Alan Hayward <alan.hayward@arm.com>
5735
5736 * sh-tdep.c (sh_pseudo_register_read): Remove
5737 MAX_REGISTER_SIZE.
5738 (sh_pseudo_register_write): Likewise.
5739 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
5740 (sh64_pseudo_register_write): Likewise
5741
d1be909e
AH
57422017-06-07 Alan Hayward <alan.hayward@arm.com>
5743
5744 * aarch64-tdep.c (aarch64_store_return_value): Use
5745 V_REGISTER_SIZE.
5746 (aarch64_pseudo_read_value): Likewise.
5747 (aarch64_pseudo_write): Likewise.
5748
f4a65042
YQ
57492017-06-06 Yao Qi <yao.qi@linaro.org>
5750
5751 * regformats/regdef.h (set_register_cache): Remove the
5752 declaration.
5753
9f7fb0aa
AH
57542017-06-06 Alan Hayward <alan.hayward@arm.com>
5755
5756 * frame.c (frame_unwind_register_signed): Use
5757 frame_unwind_register_value.
5758
e1e01040
PA
57592017-06-06 Pedro Alves <palves@redhat.com>
5760
5761 PR breakpoints/21553
5762 * breakpoint.c (create_breakpoints_sal_default)
5763 (init_breakpoint_sal, create_breakpoint_sal): Use
5764 gdb::unique_xmalloc_ptr for string parameters.
5765 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5766 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
5767 (base_breakpoint_create_breakpoints_sal)
5768 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
5769 (strace_marker_create_breakpoints_sal)
5770 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
5771 string parameters.
5772 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
5773 gdb::unique_xmalloc_ptr for string parameters.
5774 (create_breakpoint): Constify 'extra_string' and 'cond_string'
5775 parameters.
5776
fbe654c8
AH
57772017-06-06 Alan Hayward <alan.hayward@arm.com>
5778
5779 * alpha-tdep.c (alpha_register_to_value): Use
5780 get_frame_register_value.
5781 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
5782
ae0d01d6
AH
57832017-06-06 Alan Hayward <alan.hayward@arm.com>
5784
5785 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
5786 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
5787 (ia64_value_to_register): Likewise.
5788 (ia64_extract_return_value): Likewise.
5789 (ia64_store_return_value): Likewise.
5790 (ia64_push_dummy_call): Likewise.
5791
49cf576c
JB
57922017-06-04 Joel Brobecker <brobecker@adacore.com>
5793
5794 GDB 8.0 released.
5795
26b6a6ab
SM
57962017-06-03 Simon Marchi <simon.marchi@ericsson.com>
5797
5798 * x86-linux-nat.c (struct arch_lwp_info): Remove.
5799
22827c51
SM
58002017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
5801
5802 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
5803 parameter.
5804 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
5805
0e05cf3a
SM
58062017-06-02 Simon Marchi <simon.marchi@ericsson.com>
5807
5808 * event-loop.c (poll_timers): Unallocate timer using delete
5809 instead of xfree.
5810
c1fc2657
SM
58112017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5812
5813 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
5814 (struct breakpoint) <~breakpoint>: New.
5815 (struct watchpoint): Inherit from breakpoint.
5816 <~watchpoint>: New.
5817 <base>: Remove.
5818 (struct tracepoint): Inherit from breakpoint.
5819 <base>: Remove.
5820 * breakpoint.c (longjmp_breakpoint_ops): Remove.
5821 (struct longjmp_breakpoint): Inherit from breakpoint.
5822 <~longjmp_breakpoint>: New.
5823 <base>: Remove.
5824 (new_breakpoint_from_type): Remove casts.
5825 (watchpoint_in_thread_scope): Remove reference to base field.
5826 (watchpoint_del_at_next_stop): Likewise.
5827 (update_watchpoint): Likewise.
5828 (watchpoint_check): Likewise.
5829 (bpstat_check_watchpoint): Likewise.
5830 (set_longjmp_breakpoint): Likewise.
5831 (struct fork_catchpoint): Inherit from breakpoint.
5832 <base>: Remove.
5833 (struct solib_catchpoint): Inherit from breakpoint.
5834 <~solib_catchpoint>: New.
5835 <base>: Remove.
5836 (dtor_catch_solib): Change to ...
5837 (solib_catchpoint::~solib_catchpoint): ... this.
5838 (breakpoint_hit_catch_solib): Remove reference to base field.
5839 (add_solib_catchpoint): Likewise.
5840 (create_fork_vfork_event_catchpoint): Likewise.
5841 (struct exec_catchpoint): Inherit from breakpoint.
5842 <~exec_catchpoint>: New.
5843 <base>: Remove.
5844 (dtor_catch_exec): Change to ...
5845 (exec_catchpoint::~exec_catchpoint): ... this.
5846 (dtor_watchpoint): Change to ...
5847 (watchpoint::~watchpoint): ... this.
5848 (watch_command_1): Remove reference to base field.
5849 (catch_exec_command_1): Likewise.
5850 (base_breakpoint_dtor): Change to ...
5851 (breakpoint::~breakpoint): ... this.
5852 (base_breakpoint_ops): Remove dtor field value.
5853 (longjmp_bkpt_dtor): Change to ...
5854 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
5855 (strace_marker_create_breakpoints_sal): Remove reference to base
5856 field.
5857 (delete_breakpoint): Don't manually call breakpoint destructor.
5858 (create_tracepoint_from_upload): Remove reference to base field.
5859 (trace_pass_set_count): Likewise.
5860 (initialize_breakpoint_ops): Don't initialize
5861 momentary_breakpoint_ops, don't set dtors.
5862 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
5863 <~ada_catchpoint>: New.
5864 <base>: Remove.
5865 (create_excep_cond_exprs): Remove reference to base field.
5866 (dtor_exception): Change to ...
5867 (ada_catchpoint::~ada_catchpoint): ... this.
5868 (dtor_catch_exception): Remove.
5869 (dtor_catch_exception_unhandled): Remove.
5870 (dtor_catch_assert): Remove.
5871 (create_ada_exception_catchpoint): Remove reference to base
5872 field.
5873 (initialize_ada_catchpoint_ops): Don't set dtors.
5874 * break-catch-sig.c (struct signal_catchpoint): Inherit from
5875 breakpoint.
5876 <~signal_catchpoint>: New.
5877 <base>: Remove.
5878 (signal_catchpoint_dtor): Change to ...
5879 (signal_catchpoint::~signal_catchpoint): ... this.
5880 (create_signal_catchpoint): Remove reference to base field.
5881 (initialize_signal_catchpoint_ops): Don't set dtor.
5882 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
5883 from breakpoint.
5884 <~syscall_catchpoint>: New.
5885 <base>: Remove.
5886 (dtor_catch_syscall): Change to ...
5887 (syscall_catchpoint::~syscall_catchpoint): ... this.
5888 (create_syscall_event_catchpoint): Remove reference to base
5889 field.
5890 (initialize_syscall_catchpoint_ops): Don't set dtor.
5891 * break-catch-throw.c (struct exception_catchpoint): Inherit
5892 from breakpoint.
5893 <~exception_catchpoint>: New.
5894 <base>: Remove.
5895 (dtor_exception_catchpoint): Change to ...
5896 (exception_catchpoint::~exception_catchpoint): ... this.
5897 (handle_gnu_v3_exceptions): Remove reference to base field.
5898 (initialize_throw_catchpoint_ops): Don't set dtor.
5899 * ctf.c (ctf_get_traceframe_address): Remove reference to base
5900 field.
5901 * remote.c (remote_get_tracepoint_status): Likewise.
5902 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
5903 * tracefile.c (tracefile_fetch_registers): Likewise.
5904 * tracepoint.c (actions_command): Likewise.
5905 (validate_actionline): Likewise.
5906 (tfind_1): Likewise.
5907 (get_traceframe_location): Likewise.
5908 (find_matching_tracepoint_location): Likewise.
5909 (parse_tracepoint_status): Likewise.
5910 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
5911
3b0871f4
SM
59122017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5913
5914 * breakpoint.c (struct longjmp_breakpoint): New struct.
5915 (is_tracepoint_type): Change return type to bool.
5916 (is_longjmp_type): New function.
5917 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
5918 (set_raw_breakpoint_without_location): Use
5919 new_breakpoint_from_type.
5920 (set_raw_breakpoint): Likewise.
5921
a5e364af
SM
59222017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
5923
5924 * breakpoint.c (new_breakpoint_from_type): New function.
5925 (create_breakpoint_sal): Use new_breakpoint_from_type and
5926 unique_ptr.
5927 (create_breakpoint): Likewise.
5928
ae3b3f34
SM
59292017-05-31 Simon Marchi <simon.marchi@ericsson.com>
5930
5931 * memattr.c (mem_info_command): Rename to ...
5932 (info_mem_command): ... this.
5933 (mem_enable_command): Rename to ...
5934 (enable_mem_command): ... this.
5935 (mem_disable_command): Rename to ...
5936 (disable_mem_command): ... this.
5937 (mem_delete_command): Rename to ...
5938 (delete_mem_command): ... this.
5939 (_initialize_mem): Adjust function names.
5940
13ace077
MM
59412017-05-31 Markus Metzger <markus.t.metzger@intel.com>
5942
5943 * btrace.c (handle_pt_insn_events): New.
5944 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
5945 STATUS. Split into this and ...
5946 (handle_pt_insn_event_flags): ... this.
5947
c56ccc05
MM
59482017-05-31 Markus Metzger <markus.t.metzger@intel.com>
5949
5950 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
5951 and struct pt_insn.resynced.
5952 * configure: Regenerated.
5953 * config.in: Regenerated.
5954
08c3f6d2
TW
59552017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5956
5957 * btrace.c (ftrace_find_call_by_number): New function.
5958 (ftrace_new_function): Store objects, not pointers.
5959 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
5960 ftrace_new_gap, ftrace_update_function,
5961 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
5962 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
5963 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
5964 btrace_ends_with_single_insn, btrace_call_get): Account for
5965 btrace_thread_info::functions now storing objects.
5966 * btrace.h (struct btrace_thread_info): Add constructor.
5967 (struct btrace_thread_info) <functions>: Make std::vector.
5968 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
5969 Initialize with default values.
5970 * record-btrace.c (record_btrace_frame_sniffer): Account for
5971 btrace_thread_info::functions now storing objects.
5972
8ffd39f2
TW
59732017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5974
5975 * btrace.c: Remove typedef bfun_s.
5976 (ftrace_new_gap): Directly add gaps to the list of gaps.
5977 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
5978 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
5979 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
5980 instead of gdb VEC.
5981
4aeb0dfc
TW
59822017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5983
5984 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
5985 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
5986 with btrace_thread_info::next_segment and
5987 btrace_thread_info::prev_segment.
5988 * btrace.h: Remove struct btrace_func_link.
5989 (struct btrace_function): Replace pair of function segment pointers
5990 with pair of indices.
5991 * python/py-record-btrace.c (btpy_call_prev_sibling,
5992 btpy_call_next_sibling): Replace references to
5993 btrace_thread_info::segment with btrace_thread_info::next_segment and
5994 btrace_thread_info::prev_segment.
5995 * record-btrace.c (record_btrace_frame_this_id): Use
5996 btrace_find_call_by_number.
5997
eb8f2b9c
TW
59982017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
5999
6000 * btrace.c (ftrace_new_function, ftrace_fixup_level,
6001 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
6002 btrace_insn_next, btrace_insn_prev): Remove references to
6003 btrace_thread_info::flow.
6004 * btrace.h (struct btrace_function): Remove FLOW.
6005
42bfe59e
TW
60062017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6007
6008 * btrace.c (ftrace_find_call_by_number): New function.
6009 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
6010 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
6011 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
6012 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
6013 index.
6014 * btrace.h (struct btrace_function): Turn UP into an index.
6015 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
6016 as an index.
6017 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
6018 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
6019 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
6020
b54b03bd
TW
60212017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6022
6023 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6024 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6025 ftrace_update_function, ftrace_compute_global_level_offset,
6026 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
6027 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
6028 btrace_insn_end, btrace_is_empty): Remove references to
6029 btrace_thread_info::begin and btrace_thread_info::end.
6030 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
6031 (struct btrace_thread_info) <functions>: Adjust comment.
6032 * record-btrace.c (record_btrace_start_replaying): Remove reference to
6033 btrace_thread_info::begin.
6034
8286623c
TW
60352017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6036
6037 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6038 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6039 ftrace_update_function): Remove arguments that implicitly were always
6040 BTINFO->END.
6041 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
6042 Don't pass BTINFO->END.
6043
a0f1b963
TW
60442017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6045
6046 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
6047 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
6048 btrace_find_insn_by_number): Replace function segment pointer with
6049 index.
6050 (btrace_insn_cmp): Simplify.
6051 * btrace.h: (struct btrace_insn_iterator) Rename index to
6052 insn_index. Replace function segment pointer with index into function
6053 segment vector.
6054 * record-btrace.c (record_btrace_call_history): Replace function
6055 segment pointer use with index.
6056 (record_btrace_frame_sniffer): Retrieve function call segment through
6057 vector.
6058 (record_btrace_set_replay): Remove defunc't safety check.
6059
f158f208
TW
60602017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6061
6062 * btrace.c (btrace_ends_with_single_insn): New function.
6063 (btrace_call_get, btrace_call_number, btrace_call_begin,
6064 btrace_call_end, btrace_call_next, btrace_call_prev,
6065 btrace_find_call_by_number): Use index into call segment vector
6066 instead of pointer.
6067 (btrace_call_cmp): Simplify.
6068 * btrace.h (struct btrace_call_iterator): Replace function call segment
6069 pointer with index into vector.
6070 * record-btrace.c (record_btrace_call_history): Use index instead of
6071 pointer.
6072
521103fd
TW
60732017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6074
6075 * btrace.c (btrace_insn_begin, btrace_insn_end,
6076 btrace_find_insn_by_number): Add btinfo to iterator.
6077 * btrace.h (struct btrace_insn_iterator): Add btinfo.
6078
17b89b34
TW
60792017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6080
6081 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
6082 and save pointers directly.
6083 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
6084 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
6085 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
6086 changed signature of functions.
6087 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
6088 (btrace_fetch): Remove code that adds btrace_function pointers to
6089 vector of btrace_functions.
6090 (btrace_clear): Simplify freeing vector of btrace_functions.
6091
2b51eddc
TW
60922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6093
6094 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
6095 Replace VEC_* with std::vector functions.
6096 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
6097 (struct btrace_thread_info)<functions>: Change type to std::vector.
6098
db6be0d5
SM
60992017-05-30 Simon Marchi <simon.marchi@ericsson.com>
6100
6101 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
6102 "Removed targets and native configurations" up. Merge duplicate
6103 "New commands" sub-sections. Add "New options" sub-sections.
6104
b057297a
AH
61052017-05-26 Alan Hayward <alan.hayward@arm.com>
6106
6107 * defs.h (copy_integer_to_size): New declaration.
6108 * findvar.c (copy_integer_to_size): New function.
6109 (do_cint_test): New selftest function.
6110 (copy_integer_to_size_test): Likewise.
6111 (_initialize_findvar): Likewise.
6112 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
6113 (mips_fbsd_collect_reg): Use raw_collect_integer.
6114 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
6115 (mips64_fill_gregset): Use raw_collect_integer
6116 (mips64_fill_fpregset): Use raw_supply_integer.
6117 * regcache.c (regcache::raw_supply_integer): New function.
6118 (regcache::raw_collect_integer): Likewise.
6119 * regcache.h: (regcache::raw_supply_integer): New declaration.
6120 (regcache::raw_collect_integer): Likewise.
6121
b77b02a5
YQ
61222017-05-24 Yao Qi <yao.qi@linaro.org>
6123
6124 * Makefile.in (SFILES): Add gdbarch-selftests.c.
6125 (COMMON_OBS): Add gdbarch-selftests.o.
6126 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
6127 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
6128 * gdbarch-selftests.c: New file.
6129 * regcache.h (regcache) <~regcache>: Mark it virtual if
6130 GDB_SELF_TEST.
6131 <raw_write>: Likewise.
6132
e521e87e
YQ
61332017-05-24 Yao Qi <yao.qi@linaro.org>
6134
6135 * regcache.c (current_regcache): Change it to
6136 regcache::current_regcache.
6137 (regcache_observer_target_changed): Update.
6138 (regcache_thread_ptid_changed): Make it a regcache static
6139 method.
6140 (regcache_thread_ptid_changed): Update.
6141 (class regcache_access): New.
6142 (current_regcache_test): Update.
6143 (_initialize_regcache): Update.
6144 * regcache.h: Include forward_list.
6145 (regcache): Declare regcache_thread_ptid_changed and declare
6146 registers_changed_ptid as friend.
6147
d8e07dda
YQ
61482017-05-24 Yao Qi <yao.qi@linaro.org>
6149
6150 * i387-tdep.c (i387_register_to_value): Use register_size
6151 instead of TYPE_LENGTH.
6152 * m68k-tdep.c (m68k_register_to_value): Likewise.
6153
8c8f9122
YQ
61542017-05-24 Yao Qi <yao.qi@linaro.org>
6155
6156 * i387-tdep.c (i387_convert_register_p): Return false if type
6157 code isn't TYPE_CODE_FLT.
6158
68fce50f
YQ
61592017-05-24 Yao Qi <yao.qi@linaro.org>
6160
6161 * alpha-tdep.c (alpha_convert_register_p): Return true if type
6162 length is 4.
6163 (alpha_register_to_value): Remove type length check.
6164 (alpha_value_to_register): Likewise.
6165
88954b49
YQ
61662017-05-24 Yao Qi <yao.qi@linaro.org>
6167
6168 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
6169 TYPE_CODE_FLT.
6170
e3ec9b69
YQ
61712017-05-24 Yao Qi <yao.qi@linaro.org>
6172
6173 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
6174 TYPE_CODE_FLT or not.
6175
cdd238da
YQ
61762017-05-24 Yao Qi <yao.qi@linaro.org>
6177
6178 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6179 * avr-tdep.c (avr_gdbarch_init): Likewise.
6180 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6181 * cris-tdep.c (cris_gdbarch_init): Likewise.
6182 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6183 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6184 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6185 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6186 * mep-tdep.c (mep_gdbarch_init): Likewise.
6187 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6188 * mips-tdep.c (mips_gdbarch_init): Likewise.
6189 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6190 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6191 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6192 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6193 * v850-tdep.c (v850_gdbarch_init): Likewise.
6194
7a3929c4
YQ
61952017-05-24 Yao Qi <yao.qi@linaro.org>
6196
6197 * selftest-arch.c (tests_with_arch): Call registers_changed
6198 and reinit_frame_cache.
6199 * selftest.c (run_self_tests): Likewise.
6200
f4985dba
YQ
62012017-05-24 Yao Qi <yao.qi@linaro.org>
6202
6203 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6204 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6205
ab20fa4a
YQ
62062017-05-24 Yao Qi <yao.qi@linaro.org>
6207
6208 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6209 set_gdbarch_print_insn.
6210
f532ab94
YQ
62112017-05-24 Yao Qi <yao.qi@linaro.org>
6212
6213 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6214 set_gdbarch_print_insn.
6215
39503f82
YQ
62162017-05-24 Yao Qi <yao.qi@linaro.org>
6217
6218 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6219 set_gdbarch_print_insn.
6220 * arc-tdep.c (arc_gdbarch_init): Likewise.
6221 * arch-utils.c: include dis-asm.h.
6222 (default_print_insn): New function.
6223 * arch-utils.h (default_print_insn): Declare.
6224 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6225 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6226 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6227 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6228 * frv-tdep.c (frv_gdbarch_init): Likewise.
6229 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6230 * gdbarch.sh (print_insn): Use default_print_insn.
6231 * gdbarch.c: Regenerated.
6232 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6233 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6234 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6235 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6236 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6237 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6238 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6239 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6240 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6241 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6242 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6243 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6244 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6245 * mt-tdep.c (mt_gdbarch_init): Likewise.
6246 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6247 * nios2-tdep.c (nios2_print_insn): Remove.
6248 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6249 * rx-tdep.c (rx_gdbarch_init): Likewise.
6250 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6251 * score-tdep.c (score_print_insn): Remove.
6252 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6253 * sh-tdep.c (sh_gdbarch_init): Likewise.
6254 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6255 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6256 * tic6x-tdep.c (tic6x_print_insn): Remove.
6257 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6258 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6259 * v850-tdep.c (v850_gdbarch_init): Likewise.
6260 * vax-tdep.c (vax_gdbarch_init): Likewise.
6261 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6262 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6263
f7241d4f
JB
62642017-05-23 John Baldwin <jhb@FreeBSD.org>
6265
6266 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6267 (MIPS_FP0_REGNUM): Remove.
6268 (MIPS_FSR_REGNUM): Remove.
6269 (mips_fbsd_supply_fpregs): Use mips_regnum.
6270 (mips_fbsd_supply_gregs): Likewise.
6271 (mips_fbsd_collect_fpregs): Likewise.
6272 (mips_fbsd_collect_gregs): Likewise.
6273
d489d81d
JB
62742017-05-23 John Baldwin <jhb@FreeBSD.org>
6275
6276 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6277 (getpfpregs_supplies): New function.
6278 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6279 getfpregs_supplies.
6280 (mips_fbsd_store_inferior_registers): Likewise.
6281
e11b3cdc
PA
62822017-05-22 Pedro Alves <palves@redhat.com>
6283
6284 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6285 maintainer.
6286
0f068fb5
AH
62872017-05-22 Alan Hayward <alan.hayward@arm.com>
6288
6289 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6290 (store_register): Likewise.
6291 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6292 (get_decimal_float_return_value): Likewise.
6293 (do_ppc_sysv_return_value): Likewise.
6294 (ppc64_sysv_abi_push_integer): Likewise.
6295 (ppc64_sysv_abi_push_freg): Likewise.
6296 (ppc64_sysv_abi_return_value_base): Likewise.
6297 (ppc64_sysv_abi_return_value): Likewise.
6298 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6299 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6300 * rs6000-nat.c: Likewise.
6301 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6302 (rs6000_value_to_register): Likewise.
6303 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6304
e6cf65f2
TT
63052017-05-21 Tom Tromey <tom@tromey.com>
6306
6307 PR rust/21466:
6308 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6309 arrays as "[T]", not "[T; ]".
6310
43cc5389
TT
63112017-05-19 Tom Tromey <tom@tromey.com>
6312
6313 PR rust/21484:
6314 * rust-lang.c (exp_descriptor_rust): New function.
6315 (rust_language_defn): Use it.
6316 * p-lang.c (pascal_language_defn): Update.
6317 * opencl-lang.c (opencl_language_defn): Update.
6318 * objc-lang.c (objc_language_defn): Update.
6319 * m2-lang.c (m2_language_defn): Update.
6320 * language.h (struct language_defn)
6321 <la_watch_location_expression>: New member.
6322 * language.c (unknown_language_defn, auto_language_defn)
6323 (local_language_defn): Update.
6324 * go-lang.c (go_language_defn): Update.
6325 * f-lang.c (f_language_defn): Update.
6326 * d-lang.c (d_language_defn): Update.
6327 * c-lang.h (c_watch_location_expression): Declare.
6328 * c-lang.c (c_watch_location_expression): New function.
6329 (c_language_defn, cplus_language_defn, asm_language_defn)
6330 (minimal_language_defn): Use it.
6331 * breakpoint.c (watch_command_1): Call
6332 la_watch_location_expression.
6333 * ada-lang.c (ada_language_defn): Update.
6334
7a6e7fcc
RO
63352017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6336
6e7e1744
RO
6337 PR tui/21482
6338 * gdb_curses.h (NOMACROS): Define.
6339 (NCURSES_NOMACROS): Define.
6340
63412017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6342
6343 PR tui/21482
7a6e7fcc
RO
6344 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6345 arg to char *.
6346 * tui/tui-wingeneral.c (box_win): Likewise.
6347 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6348 (tui_show_source_line): Likewise.
6349 (tui_show_exec_info_content): Likewise.
6350
1933fd8e
VM
63512017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6352
6353 * sparc-tdep.c (sparc_structure_return_p)
6354 (sparc_arg_on_registers_p): New functions.
6355 (sparc32_store_arguments): Use them.
6356 * sparc64-tdep.c (sparc64_16_byte_align_p)
6357 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6358 Handle TYPE_CODE_ARRAY.
6359
21873064
YQ
63602017-05-17 Yao Qi <yao.qi@linaro.org>
6361
6362 * cli/cli-decode.c (add_alias_cmd): New function.
6363 * command.h (add_alias_cmd): Declare.
6364 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6365 instead call add_alias_cmd.
6366
2b351b19
PA
63672017-05-17 Pedro Alves <palves@redhat.com>
6368
6369 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6370 (nat_makefile_frag): ... this. All references updated.
6371 * configure.ac: Likewise.
6372 * configure.nat: Likewise. Enhance comments.
6373 * configure: Regenerate.
6374
5f2ad7a3
RO
63752017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6376
6377 * procfs.c (procfs_create_inferior): Change prototype to match
6378 definition.
6379
adf3dde5
EZ
63802017-05-13 Eli Zaretskii <eliz@gnu.org>
6381
6382 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6383 C++ compiler warning.
6384
6830f270
TT
63852017-05-12 Tom Tromey <tom@tromey.com>
6386
6387 PR rust/21483:
6388 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6389 recurse, just call value_struct_elt directly.
6390
68f2f2e3
TT
63912017-05-12 Tom Tromey <tom@tromey.com>
6392
6393 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6394 OP_RUST_ARRAY>: Fix.
6395
256afbc2
TT
63962017-05-12 Tom Tromey <tom@tromey.com>
6397
6398 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6399
94bb8dfe
YQ
64002017-05-09 Yao Qi <yao.qi@linaro.org>
6401
6402 * regcache.c: Include <forward_list>.
6403 (struct regcache_list): Remove.
6404 (current_regcache): Update.
6405 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6406 (regcache_thread_ptid_changed): Likewise.
6407 (registers_changed_ptid): Likewise.
6408 (current_regcache_size): Likewise.
6409
8248946c
YQ
64102017-05-09 Yao Qi <yao.qi@linaro.org>
6411
6412 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6413 (current_regcache_size): New function.
6414 (current_regcache_test): New function.
6415 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6416
313c5961
AH
64172017-05-08 Alan Hayward <alan.hayward@arm.com>
6418
6419 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6420 (print_gp_register_row): Use get_frame_register_value.
6421
27bfc1d1
AH
64222017-05-08 Alan Hayward <alan.hayward@arm.com>
6423
6424 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6425 (mips_supply_fpregset): Likewise.
6426 (mips64_supply_gregset): Likewise.
6427
146e6c5c
AH
64282017-05-08 Alan Hayward <alan.hayward@arm.com>
6429
6430 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6431 regcache->raw_supply_zeroed.
6432
e50f25ec
SDJ
64332017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6434
6435 * configure.nat: Rearrange 'case' statements to match
6436 host before cpu.
6437
21ea5acd
SDJ
64382017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6439
6440 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6441 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6442 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6443 "@nat_extra_makefile_frag@".
6444 (Makefile): Remove dependency on "@frags@".
6445 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6446 (data-directory/Makefile): Likewise.
6447 * config/aarch64/linux.mh: Deleted; moved contents to
6448 "gdb/configure.nat".
6449 * config/alpha/alpha-linux.mh: Likewise.
6450 * config/alpha/nbsd.mh: Likewise.
6451 * config/arm/linux.mh: Likewise.
6452 * config/arm/nbsdelf.mh: Likewise.
6453 * config/i386/cygwin.mh: Likewise.
6454 * config/i386/cygwin64.mh: Likewise.
6455 * config/i386/darwin.mh: Likewise.
6456 * config/i386/fbsd.mh: Likewise.
6457 * config/i386/fbsd64.mh: Likewise.
6458 * config/i386/go32.mh: Likewise.
6459 * config/i386/i386gnu.mh: Likewise.
6460 * config/i386/i386sol2.mh: Likewise.
6461 * config/i386/linux.mh: Likewise.
6462 * config/i386/linux64.mh: Likewise.
6463 * config/i386/mingw.mh: Likewise.
6464 * config/i386/mingw64.mh: Likewise.
6465 * config/i386/nbsd64.mh: Likewise.
6466 * config/i386/nbsdelf.mh: Likewise.
6467 * config/i386/nto.mh: Likewise.
6468 * config/i386/obsd.mh: Likewise.
6469 * config/i386/obsd64.mh: Likewise.
6470 * config/i386/sol2-64.mh: Likewise.
6471 * config/ia64/linux.mh: Likewise.
6472 * config/m32r/linux.mh: Likewise.
6473 * config/m68k/linux.mh: Likewise.
6474 * config/m68k/nbsdelf.mh: Likewise.
6475 * config/m68k/obsd.mh: Likewise.
6476 * config/m88k/obsd.mh: Likewise.
6477 * config/mips/fbsd.mh: Likewise.
6478 * config/mips/linux.mh: Likewise.
6479 * config/mips/nbsd.mh: Likewise.
6480 * config/mips/obsd64.mh: Likewise.
6481 * config/pa/linux.mh: Likewise.
6482 * config/pa/nbsd.mh: Likewise.
6483 * config/pa/obsd.mh: Likewise.
6484 * config/powerpc/aix.mh: Likewise.
6485 * config/powerpc/fbsd.mh: Likewise.
6486 * config/powerpc/linux.mh: Likewise.
6487 * config/powerpc/nbsd.mh: Likewise.
6488 * config/powerpc/obsd.mh: Likewise.
6489 * config/powerpc/ppc64-linux.mh: Likewise.
6490 * config/powerpc/spu-linux.mh: Likewise.
6491 * config/s390/linux.mh: Likewise.
6492 * config/sh/nbsd.mh: Likewise.
6493 * config/sparc/fbsd.mh: Likewise.
6494 * config/sparc/linux.mh: Likewise.
6495 * config/sparc/linux64.mh: Likewise.
6496 * config/sparc/nbsd64.mh: Likewise.
6497 * config/sparc/nbsdelf.mh: Likewise.
6498 * config/sparc/obsd64.mh: Likewise.
6499 * config/sparc/sol2.mh: Likewise.
6500 * config/tilegx/linux.mh: Likewise.
6501 * config/vax/nbsdelf.mh: Likewise.
6502 * config/vax/obsd.mh: Likewise.
6503 * config/xtensa/linux.mh: Likewise.
6504 * config/i386/i386gnu.mn: New file, with excerpts from
6505 "config/i386/i386gnu.mh".
6506 * configure: Regenerate.
6507 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
6508 *.mh files under "gdb/config".
6509 * configure.nat: New file, with contents from the
6510 "gdb/config/*/*.mh" files.
6511
7ed1acaf
TW
65122017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
6513
6514 * btrace.c (btrace_clear): Free insn vector.
6515
e13cb306
PA
65162017-05-05 Pedro Alves <palves@redhat.com>
6517
6518 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
6519 * configure: Regenerate.
6520
5ed8105e
PA
65212017-05-04 Pedro Alves <palves@redhat.com>
6522
6523 * Makefile.in (SFILES): Add progspace-and-thread.c.
6524 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
6525 (COMMON_OBS): Add progspace-and-thread.o.
6526 * breakpoint.c: Include "progspace-and-thread.h".
6527 (update_inserted_breakpoint_locations)
6528 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
6529 Use scoped_restore_current_pspace_and_thread.
6530 (create_std_terminate_master_breakpoint): Use
6531 scoped_restore_current_program_space.
6532 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
6533 (print_breakpoint_location): Use
6534 scoped_restore_current_program_space.
6535 (bp_loc_is_permanent): Use
6536 scoped_restore_current_pspace_and_thread.
6537 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
6538 (download_tracepoint_locations): Use
6539 scoped_restore_current_pspace_and_thread.
6540 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
6541 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
6542 (enum step_over_calls_kind): Moved from inferior.h.
6543 (class scoped_restore_current_thread): New class.
6544 * gdbthread.h (make_cleanup_restore_current_thread): Delete
6545 declaration.
6546 (scoped_restore_current_thread): New class.
6547 * infcmd.c: Include "common/gdb_optional.h".
6548 (continue_1, proceed_after_attach): Use
6549 scoped_restore_current_thread.
6550 (notice_new_inferior): Use scoped_restore_current_thread.
6551 * inferior.c: Include "progspace-and-thread.h".
6552 (restore_inferior, save_current_inferior): Delete.
6553 (add_inferior_command, clone_inferior_command): Use
6554 scoped_restore_current_pspace_and_thread.
6555 * inferior.h (scoped_restore_current_inferior): New class.
6556 * infrun.c: Include "progspace-and-thread.h" and
6557 "common/gdb_optional.h".
6558 (follow_fork_inferior): Use
6559 scoped_restore_current_pspace_and_thread.
6560 (scoped_restore_exited_inferior): New class.
6561 (handle_vfork_child_exec_or_exit): Use
6562 scoped_restore_exited_inferior,
6563 scoped_restore_current_pspace_and_thread,
6564 scoped_restore_current_thread and scoped_restore.
6565 (fetch_inferior_event): Use scoped_restore_current_thread.
6566 * linespec.c (decode_line_full, decode_line_1): Use
6567 scoped_restore_current_program_space.
6568 * mi/mi-main.c: Include "progspace-and-thread.h".
6569 (exec_continue): Use scoped_restore_current_thread.
6570 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
6571 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
6572 * proc-service.c (ps_pglobal_lookup): Use
6573 scoped_restore_current_program_space.
6574 * progspace-and-thread.c: New file.
6575 * progspace-and-thread.h: New file.
6576 * progspace.c (release_program_space, clone_program_space): Use
6577 scoped_restore_current_program_space.
6578 (restore_program_space, save_current_program_space)
6579 (save_current_space_and_thread): Delete.
6580 (switch_to_program_space_and_thread): Moved to
6581 progspace-and-thread.c.
6582 * progspace.h (save_current_program_space)
6583 (save_current_space_and_thread): Delete declarations.
6584 (scoped_restore_current_program_space): New class.
6585 * remote.c (remote_btrace_maybe_reopen): Use
6586 scoped_restore_current_thread.
6587 * symtab.c: Include "progspace-and-thread.h".
6588 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
6589 * thread.c (print_thread_info_1): Use
6590 scoped_restore_current_thread.
6591 (struct current_thread_cleanup): Delete.
6592 (do_restore_current_thread_cleanup)
6593 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
6594 (scoped_restore_current_thread::~scoped_restore_current_thread):
6595 ... this new dtor.
6596 (make_cleanup_restore_current_thread): Rename/convert to ...
6597 (scoped_restore_current_thread::scoped_restore_current_thread):
6598 ... this new ctor.
6599 (thread_apply_all_command): Use scoped_restore_current_thread.
6600 (thread_apply_command): Use scoped_restore_current_thread.
6601 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
6602 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
6603
f6223dbb
PA
66042017-05-04 Pedro Alves <palves@redhat.com>
6605
6606 * thread.c (make_cleanup_restore_current_thread): Move
6607 find_thread_ptid call before the is_stopped call. Assert that the
6608 thread is found. Replace is_stopped call by checking the thread's
6609 state directly. Remove unnecessary NULL-thread check.
6610
3c3ae77e
PA
66112017-05-04 Pedro Alves <palves@redhat.com>
6612
6613 * corelow.c (thread_section_name): New class.
6614 (get_core_register_section, get_core_siginfo): Use it.
6615
45eba0ab
AA
66162017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
6617
6618 * corelow.c (sniff_core_bfd): Remove extra semicolon.
6619 (get_core_register_section): Remove xfree of NULL pointer.
6620
f81fdd35
AH
66212017-05-03 Alan Hayward <alan.hayward@arm.com>
6622
6623 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
6624 * regcache.c (regcache::raw_supply_zeroed): New function.
6625 * regcache.h (regcache::raw_supply_zeroed): New declaration.
6626
35837774
SM
66272017-05-03 Simon Marchi <simon.marchi@ericsson.com>
6628
6629 * gdbarch.sh: Remove commented out definition of
6630 TARGET_CHAR_BIT.
6631 * gdbarch.h: Re-generate.
6632
c94fee56
SDJ
66332017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
6634
6635 * configure: Regenerate.
6636
d17f7b36
SM
66372017-05-02 Simon Marchi <simon.marchi@ericsson.com>
6638
6639 * solib-target.c (solib_target_relocate_section_addresses):
6640 Remove num_section_bases, num_bases, segment_bases variables.
6641
b560ebd6
SM
66422017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6643
6644 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
6645
f2f46dfc
SM
66462017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6647
6648 * solib-target.c: Include <vector>
6649 (struct lm_info_target) <~lm_info_target>: Remove.
6650 <segment_bases, section_bases>: Change type to
6651 std::vector<CORE_ADDR>.
6652 (library_list_start_segment, library_list_start_section,
6653 library_list_end_library,
6654 solib_target_relocate_section_addresses): Adjust.
6655
a0ff9e1a
SM
66562017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6657
6658 * gdbarch.sh (software_single_step): Change return type to
6659 std::vector<CORE_ADDR>.
6660 * gdbarch.c, gdbarch.h: Re-generate.
6661 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
6662 Adjust.
6663 (arm_deal_with_atomic_sequence_raw): Adjust.
6664 (thumb_get_next_pcs_raw): Adjust.
6665 (arm_get_next_pcs_raw): Adjust.
6666 (arm_get_next_pcs): Adjust.
6667 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
6668 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
6669 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
6670 (alpha_software_single_step): Adjust.
6671 * alpha-tdep.h (alpha_software_single_step): Adjust.
6672 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
6673 * arm-tdep.c (arm_software_single_step): Adjust.
6674 (arm_breakpoint_kind_from_current_state): Adjust.
6675 * arm-tdep.h (arm_software_single_step): Adjust.
6676 * breakpoint.c (insert_single_step_breakpoint): Adjust.
6677 * cris-tdep.c (cris_software_single_step): Adjust.
6678 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
6679 (micromips_deal_with_atomic_sequence): Adjust.
6680 (deal_with_atomic_sequence): Adjust.
6681 (mips_software_single_step): Adjust.
6682 * mips-tdep.h (mips_software_single_step): Adjust.
6683 * moxie-tdep.c (moxie_software_single_step): Adjust.
6684 * nios2-tdep.c (nios2_software_single_step): Adjust.
6685 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
6686 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
6687 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
6688 * s390-linux-tdep.c (s390_software_single_step): Adjust.
6689 * sparc-tdep.c (sparc_software_single_step): Adjust.
6690 * spu-tdep.c (spu_software_single_step): Adjust.
6691 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
6692
ea480a30
SM
66932017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
6694
6695 * gdbarch.sh: Use semi-colon as field separator instead of colon.
6696 * gdbarch.h: Re-generate.
6697
d050f7d7
TW
66982017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6699
6700 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
6701 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
6702 * python/py-instruction.c, python/py-instruction.h: New file.
6703 * python/py-record.c: Add py-instruction.h include.
6704 (gdbpy_initialize_record): Make gdb.Instruction a super class of
6705 gdb.RecordInstruction.
6706 * python/python-internal.h: Add gdbpy_initialize_instruction
6707 declaration.
6708 * python/python.c (do_start_initialization): Add
6709 gdbpy_initialize_instruction.
6710
14f819c8
TW
67112017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6712
6713 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
6714 Remove.
6715 (btrace_func_from_recpy_func): New function.
6716 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
6717 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
6718 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
6719 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
6720 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
6721 Also, use new helper functions.
6722 (btpy_list_item): Use new helper functions.
6723 (recpy_bt_function_call_history): Use new type name.
6724 (btpy_call_getset): Remove.
6725 (gdbpy_initialize_btrace): Remove code to initialize
6726 gdb.BtraceFunctionCall.
6727 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
6728 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
6729 recpy_bt_func_prev, recpy_bt_func_next): New export.
6730 * python/py-record.c (recpy_func_type): New static object.
6731 (recpy_func_new, recpy_func_level, recpy_func_symbol,
6732 recpy_func_instructions, recpy_func_up, recpy_func_prev,
6733 recpy_func_next): New function.
6734 (recpy_element_hash, recpy_element_richcompare): Updated comment.
6735 (recpy_func_getset): New static object.
6736 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
6737 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
6738
0ed5da75
TW
67392017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6740
6741 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
6742 (btpy_object, btpy_insn_type, btpy_new): Remove.
6743 (btpy_list_object): Use gdb.RecordInstruction type instead of
6744 gdb.BtraceInstruction type.
6745 (btrace_insn_from_recpy_insn): New function.
6746 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
6747 btpy_new.
6748 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
6749 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
6750 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
6751 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
6752 instead of btpy_object.
6753 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6754 btpy_insn_data, btpy_insn_decode): Rename to ...
6755 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
6756 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
6757 recpy_bt_insn_decode): This. Also, use new helper functions.
6758 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
6759 recpy_insn_type.
6760 (btpy_insn_getset): Remove.
6761 (gdbpy_initialize_btrace): Remove code to initialize
6762 gdb.BtraceInstruction. Use recpy_element_object.
6763 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
6764 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
6765 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
6766 * python/py-record.c (recpy_insn_type): New static object.
6767 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
6768 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
6769 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
6770 New function.
6771 (recpy_insn_getset): New static object.
6772 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
6773 * python/py-record.h (recpy_element_object): New typedef.
6774 (recpy_insn_type, recpy_insn_new): New export.
6775
913aeadd
TW
67762017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6777
6778 * py-record-btrace.c (btpy_insn_new): Removed.
6779 (btpy_insn_or_gap_new): New function.
6780 (btpy_insn_error): Removed.
6781 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
6782 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
6783 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
6784 btpy_insn_or_gap_new instead of btpy_insn_new.
6785 (btpy_insn_getset): Remove btpy_insn_error.
6786 * py-record.c (recpy_gap_type): New static object.
6787 (recpy_gap_object): New typedef.
6788 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
6789 recpy_gap_reason_string): New function.
6790 (recpy_gap_getset): New static object.
6791 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
6792 * py-record.h (recpy_gap_new): New export.
6793
a3be24ad
TW
67942017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6795
6796 * python/py-record.c (recpy_ptid): Remove.
6797 (recpy_record_getset): Remove recpy_ptid.
6798
ae20e79a
TW
67992017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6800
6801 * btrace.c (btrace_fetch): Set inferior_ptid.
6802 * python/py-record-btrace.c: Add "py-record.h" include.
6803 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
6804 recpy_bt_end, recpy_bt_instruction_history,
6805 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
6806 in gdb.Record object instead of current ptid.
6807 * python/py-record.c: Include new "py-record.h" file.
6808 (recpy_record_object): Moved to py-record.h.
6809 * python/py-record.h: New file.
6810
8d0050ea
TW
68112017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
6812
6813 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
6814 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
6815 indentation.
6816
3f380b50
JB
68172017-05-01 Joel Brobecker <brobecker@adacore.com>
6818
6819 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
6820 the past maintainers section.
6821
07495424
YQ
68222017-04-28 Yao Qi <yao.qi@linaro.org>
6823
6824 * infcmd.c (get_return_value): Use regcache ctor, and remove
6825 cleanup.
6826
deb1fa3e
YQ
68272017-04-28 Yao Qi <yao.qi@linaro.org>
6828 Pedro Alves <palves@redhat.com>
6829
6830 * regcache.c (regcache::regcache): New tag dispatch ctor.
6831 (do_cooked_read): Moved above.
6832 (regcache_dup): Use the tag dispatch ctor..
6833 * regcache.h (regcache): Declare ctor, delete copy ctor and
6834 assignment operator, remove friend regcache_dup.
6835
b421c83c
YQ
68362017-04-28 Yao Qi <yao.qi@linaro.org>
6837
6838 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
6839 call method save instead of regcache_cpy.
6840 * regcache.h (struct regcache): Make regcache_dup a friend.
6841
ef79d9a3
YQ
68422017-04-28 Yao Qi <yao.qi@linaro.org>
6843
6844 * regcache.c (struct regcache): Move to regcache.h
6845 (regcache::arch): New method.
6846 (regcache_get_ptid): Update.
6847 (get_regcache_arch): Call arch method.
6848 (get_regcache_aspace): Call method aspace.
6849 (register_buffer): Change it to method.
6850 (regcache_save): Change it to regcache::save.
6851 (regcache_restore): Likewise.
6852 (regcache_cpy_no_passthrough): Remove the declaration.
6853 (regcache_cpy): Call methods restore and cpy_no_passthrough.
6854 (regcache_cpy_no_passthrough): Change it to method
6855 cpy_no_passthrough.
6856 (regcache_register_status): Change it to method
6857 get_register_status.
6858 (regcache_invalidate): Change it to method invalidate.
6859 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
6860 (regcache_raw_update): Change it to method raw_update.
6861 (regcache_raw_read): Likewise.
6862 (regcache_raw_read_signed): Likewise.
6863 (regcache_raw_read_unsigned): Likewise.
6864 (regcache_raw_write_signed): Likewise.
6865 (regcache_raw_write_unsigned): Likewise.
6866 (regcache_cooked_read): Likewise.
6867 (regcache_cooked_read_value): Likewise.
6868 (regcache_cooked_read_signed): Likewise.
6869 (regcache_cooked_read_unsigned): Likewise.
6870 (regcache_cooked_write_signed): Likewise.
6871 (regcache_cooked_write_unsigned): Likewise.
6872 (regcache_raw_set_cached_value): Likewise.
6873 (regcache_raw_write): Likewise.
6874 (regcache_cooked_write): Likewise.
6875 (regcache_xfer_part): Likewise.
6876 (regcache_raw_read_part): Likewise.
6877 (regcache_raw_write_part): Likewise.
6878 (regcache_cooked_read_part): Likewise.
6879 (regcache_cooked_write_part): Likewise.
6880 (regcache_raw_supply): Likewise.
6881 (regcache_raw_collect): Likewise.
6882 (regcache_transfer_regset): Likewise.
6883 (regcache_supply_regset): Likewise.
6884 (regcache_collect_regset): Likewise.
6885 (regcache_debug_print_register): Likewise.
6886 (enum regcache_dump_what): Move it to regcache.h.
6887 (regcache_dump): Change it to method dump.
6888 * regcache.h (enum regcache_dump_what): New.
6889 (class regcache): New.
6890 * target.c (target_fetch_registers): Call method
6891 debug_print_register.
6892 (target_store_registers): Likewise.
6893
f8fdb78e
SM
68942017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6895
6896 * windows-nat.c (struct lm_info_windows): Initialize field.
6897 (windows_make_so): Allocate lm_info_windows with new.
6898 (windows_free_so): Free lm_info_windows with delete.
6899
9ccbfd7b
SM
69002017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6901
6902 * solib-darwin.c (struct lm_info_darwin): Initialize field.
6903 (darwin_current_sos): Allocate lm_info_darwin with new, remove
6904 cleanup.
6905 (darwin_free_so): Free lm_info_darwin with delete.
6906
76e75227
SM
69072017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6908
6909 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
6910 <l_addr_p>: Change type to bool.
6911 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
6912 (svr4_free_so): Free lm_info_svr4 with delete.
6913 (svr4_copy_library_list): Replace memcpy with call to copy
6914 constructor.
6915 (library_list_start_library, svr4_default_sos): Allocate
6916 lm_info_svr4 with new.
6917
51046d9e
SM
69182017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6919
6920 * solib-target.c (struct lm_info_target): Add destructor,
6921 initialize fields.
6922 <name>: Change type to std::string.
6923 (library_list_start_library): Allocate lm_info_target with new.
6924 (solib_target_free_library_list): Free lm_info_target with
6925 delete.
6926 (solib_target_current_sos): Adapt to std::string.
6927 (solib_target_free_so): Free lm_info_target with delete.
6928
4023ae76
SM
69292017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6930
6931 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
6932 fields.
6933 (frv_current_sos): Allocate lm_info_frv with new.
6934 (frv_relocate_main_executable): Free lm_info_frv with delete,
6935 allocate with new.
6936 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
6937
af43057b
SM
69382017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6939
6940 * solib-frv.c (struct lm_info_frv): Fix indentation.
6941
b0911207
SM
69422017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6943
6944 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
6945 map field.
6946 (dsbt_current_sos): Allocate lm_info_dsbt with new.
6947 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
6948 and allocate with new.
6949 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
6950
6c401f72
SM
69512017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6952
6953 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
6954 <filename, member_name>: Change type to std::string.
6955 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
6956 (library_list_start_library): Allocate lm_info_aix with new.
6957 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
6958 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
6959 with copy constructor.
6960
d0e449a1
SM
69612017-04-28 Simon Marchi <simon.marchi@ericsson.com>
6962
6963 * solist.h (struct lm_info): Remove.
6964 (struct lm_info_base): New class.
6965 (struct so_list) <lm_info>: Change type to lm_info_base *.
6966 * nto-tdep.c (struct lm_info): Remove.
6967 (lm_addr): Adjust.
6968 * solib-aix.c (struct lm_info): Rename to ...
6969 (struct lm_info_aix): ... this. Extend lm_info_base.
6970 (lm_info_p): Rename to ...
6971 (lm_info_aix_p): ... this, and adjust.
6972 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
6973 solib_aix_parse_libraries, library_list_start_library,
6974 solib_aix_free_library_list, solib_aix_parse_libraries,
6975 solib_aix_get_library_list,
6976 solib_aix_relocate_section_addresses, solib_aix_free_so,
6977 solib_aix_get_section_offsets,
6978 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
6979 Adjust.
6980 (struct solib_aix_inferior_data) <library_list>: Adjust.
6981 * solib-darwin.c (struct lm_info): Rename to ...
6982 (struct lm_info_darwin): ... this. Extend lm_info_base.
6983 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
6984 * solib-dsbt.c (struct lm_info): Rename to ...
6985 (struct lm_info_dsbt): ... this. Extend lm_info_base.
6986 (struct dsbt_info) <main_executable_lm_info): Adjust.
6987 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
6988 dsbt_relocate_section_addresses): Adjust.
6989 * solib-frv.c (struct lm_info): Rename to ...
6990 (struct lm_info_frv): ... this. Extend lm_info_base.
6991 (main_executable_lm_info): Adjust.
6992 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
6993 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
6994 find_canonical_descriptor_in_load_object,
6995 frv_fdpic_find_canonical_descriptor): Adjust.
6996 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
6997 to lm_info_svr4.
6998 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
6999 svr4_clear_so, svr4_copy_library_list,
7000 library_list_start_library, svr4_default_sos, svr4_read_so_list,
7001 svr4_current_sos, svr4_fetch_objfile_link_map,
7002 solist_update_incremental): Adjust.
7003 * solib-svr4.h (struct lm_info_svr4): Move here from
7004 solib-svr4.c.
7005 * solib-target.c (struct lm_info): Rename to ...
7006 (struct lm_info_target): ... this. Extend lm_info_base.
7007 (lm_info_p): Rename to ...
7008 (lm_info_target_p): ... this.
7009 (solib_target_parse_libraries, library_list_start_segment,
7010 library_list_start_section, library_list_start_library,
7011 library_list_end_library, solib_target_free_library_list,
7012 solib_target_current_sos, solib_target_free_so,
7013 solib_target_relocate_section_addresses): Adjust.
7014 * windows-nat.c (struct lm_info): Rename to ...
7015 (struct lm_info_windows): ... this. Extend lm_info_base.
7016 (windows_make_so, handle_load_dll, handle_unload_dll,
7017 windows_xfer_shared_libraries): Adjust.
7018
434a4023
SM
70192017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7020
7021 * solib-darwin.c (struct darwin_so_list): Remove.
7022 (darwin_current_sos): Allocate an so_list object instead of a
7023 darwin_so_list, separately allocate an lm_info object.
7024 (darwin_free_so): Free lm_info.
7025
428544e8
JB
70262017-04-28 John Baldwin <jhb@FreeBSD.org>
7027
7028 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
7029 with fprintf_filtered.
7030
4621115f
YQ
70312017-04-28 Yao Qi <yao.qi@linaro.org>
7032
7033 * regcache.c (regcache::regcache): New function.
7034 (regcache::~regcache): New function.
7035 (regcache_xmalloc_1): Remove.
7036 (regcache_xmalloc): Call new regcache.
7037 (regcache_xfree): Call delete regcache.
7038 (get_thread_arch_aspace_regcache): Call new regcache.
7039
339053c2
YQ
70402017-04-28 Yao Qi <yao.qi@linaro.org>
7041
7042 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
7043 lwp instead of ptid_get_lwp.
7044
7974a605
YQ
70452017-04-28 Yao Qi <yao.qi@linaro.org>
7046
7047 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
7048 lwp_info instead of getting from inferior_ptid.
7049
e15c3eb4
KS
70502017-04-27 Keith Seitz <keiths@redhat.com>
7051
7052 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
7053 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
7054 (CV_CONVERSION_BADNESS): Define.
7055 (rank_one_type): Remove overly restrictive rvalue reference
7056 rank checks.
7057 Add cv-qualifier checks and subranks for type equality.
7058 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
7059 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
7060 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
7061
72bc1d24
SM
70622017-04-27 Simon Marchi <simon.marchi@ericsson.com>
7063
7064 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
7065 count when creating the object.
7066
55bcecda
UW
70672017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
7068 Ulrich Weigand <uweigand@de.ibm.com>
7069
7070 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
7071 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
7072 is used in AIX.
7073 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
7074 (process_xcoff_symbol): Likewise.
7075 (scan_xcoff_symtab): Likewise.
7076
5c99fcf8
AH
70772017-04-26 Alan Hayward <alan.hayward@arm.com>
7078
7079 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
7080 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
7081 (ia64_access_reg): Use get_frame_register_unsigned.
7082 (ia64_access_rse_reg): Likewise.
7083 (ia64_libunwind_frame_prev_register): Likewise.
7084
b41c5a85
JW
70852017-04-26 Jiong Wang <jiong.wang@arm.com>
7086
7087 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
7088 * gdbarch.c: Regenerated.
7089 * gdbarch.h: Regenerated.
7090 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
7091 visibility external.
7092 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
7093 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
7094 (enum cfa_how_kind): Move to ...
7095 (struct dwarf2_frame_state_reg_info): Likewise.
7096 (struct dwarf2_frame_state): Likewise.
7097 * dwarf2-frame.h: ... here.
7098 (dwarf2_frame_state_alloc_regs): New declaration.
7099 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
7100 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
7101
c185f580
AH
71022017-04-26 Alan Hayward <alan.hayward@arm.com>
7103
7104 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
7105 regcache_raw_read_unsigned.
7106 (xtensa_pseudo_register_write): Likewise.
7107
19c45594
AH
71082017-04-26 Alan Hayward <alan.hayward@arm.com>
7109
7110 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
7111 (nds32_pseudo_register_write): Likewise.
7112
4658f12e
YQ
71132017-04-25 Yao Qi <yao.qi@linaro.org>
7114
7115 * regcache.c (struct regcache) <readonly_p>: Change its type
7116 to bool.
7117 (regcache_xmalloc_1): Update parameter type and callers update.
7118
d581dda8
YQ
71192017-04-25 Yao Qi <yao.qi@linaro.org>
7120
7121 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
7122 set_gdbarch_wchar_bit.
7123 * arm-tdep.c (arm_gdbarch_init): Likewise.
7124
debed3db
PA
71252017-04-25 Pedro Alves <palves@redhat.com>
7126
7127 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
7128 (BothAreRelocatable, memcopy, memmove): Don't define.
7129 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
7130 macros.
7131
b0b92aeb
PA
71322017-04-25 Pedro Alves <palves@redhat.com>
7133
7134 * common/common-defs.h: Include "common/poison.h".
7135 * common/function-view.h: (Not, Or, Requires): Move to traits.h
7136 and adjust.
7137 * common/poison.h: New file.
7138 * common/traits.h: Include <type_traits>.
7139 (Not, Or, Requires): New, moved from common/function-view.h.
7140
16c4d54a
PA
71412017-04-25 Pedro Alves <palves@redhat.com>
7142
7143 * breakpoint.h (struct breakpoint): In-class initialize all
7144 fields. Make boolean fields "bool".
7145 * breakpoint.c (init_raw_breakpoint_without_location): Remove
7146 memset call and initializations no longer necessary.
7147
b5c36682
PA
71482017-04-25 Pedro Alves <palves@redhat.com>
7149
7150 * btrace.c (pt_btrace_insn_flags): Change parameter type to
7151 reference.
7152 (pt_btrace_insn): New function.
7153 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
7154
5625a286
PA
71552017-04-25 Pedro Alves <palves@redhat.com>
7156
7157 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
7158 "base" field and inherit from "bp_location" instead. Add
7159 non-default ctor.
7160 (allocate_location_exception): Use new non-default ctor.
7161 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
7162 (init_bp_location): Convert to ...
7163 (bp_location::bp_location): ... this new ctor, and remove memset
7164 call.
7165 (base_breakpoint_allocate_location): Use the new non-default ctor.
7166 * breakpoint.h (bp_location): Now a class. Declare default and
7167 non-default ctors. In-class initialize all members.
7168 (init_bp_location): Remove declaration.
7169
23bcc18f
PA
71702017-04-25 Pedro Alves <palves@redhat.com>
7171
7172 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
7173 assignment operator.
7174
e1ba3053
YQ
71752017-04-24 Yao Qi <yao.qi@linaro.org>
7176
7177 * doublest.c (convert_doublest_to_floatformat): Call
7178 floatformat_totalsize_bytes.
7179
10f489e5
TT
71802017-04-22 Tom Tromey <tom@tromey.com>
7181
7182 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7183 ui_out_emit_list.
7184 * stack.c (print_frame): Use ui_out_emit_list.
7185 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7186 ui_out_emit_list.
7187 * mi/mi-main.c (print_one_inferior)
7188 (mi_cmd_data_list_register_names)
7189 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7190 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7191 ui_out_emit_list.
7192 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7193 (mi_output_solib_attribs): Use ui_out_emit_list,
7194 ui_out_emit_tuple.
7195 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7196 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7197 (mi_cmd_stack_list_args, list_args_or_locals): Use
7198 ui_out_emit_list.
7199 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7200 * breakpoint.c (print_solib_event, output_thread_groups): Use
7201 ui_out_emit_list.
7202
0092b74d
TT
72032017-04-22 Tom Tromey <tom@tromey.com>
7204
7205 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7206 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7207 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7208
a14a62dd
TT
72092017-04-22 Tom Tromey <tom@tromey.com>
7210
7211 * tracepoint.c (tvariables_info_1)
7212 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7213
46b9c129
TT
72142017-04-22 Tom Tromey <tom@tromey.com>
7215
7216 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7217 annotate_arg_emitter.
7218 * breakpoint.c (print_mention_watchpoint)
7219 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7220 * annotate.h (struct annotate_arg_emitter): New.
7221
2e783024
TT
72222017-04-22 Tom Tromey <tom@tromey.com>
7223
7224 * record-btrace.c (record_btrace_insn_history)
7225 (record_btrace_insn_history_range, record_btrace_call_history)
7226 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7227 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7228 ui_out_emit_tuple.
7229 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7230 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7231 * skip.c (skip_info): Use ui_out_emit_tuple.
7232 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7233 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7234 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7235 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7236 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7237 ui_out_emit_tuple.
7238 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7239 (output_register, mi_cmd_data_read_memory)
7240 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7241 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7242 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7243 Use ui_out_emit_tuple.
7244 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7245 ui_out_emit_tuple.
7246 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7247 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7248 * linux-thread-db.c (info_auto_load_libthread_db): Use
7249 ui_out_emit_tuple.
7250 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7251 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7252 * disasm.c (do_mixed_source_and_assembly_deprecated)
7253 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7254 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7255 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7256 * breakpoint.c (print_one_breakpoint_location)
7257 (print_one_breakpoint): Use ui_out_emit_tuple.
7258 * auto-load.c (print_script, info_auto_load_cmd): Use
7259 ui_out_emit_tuple.
7260 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7261
9be21bb4
SM
72622017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7263
7264 * thread.c (print_thread_info_1): Remove dead code.
7265
0d4c07af
JK
72662017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7267
7268 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7269 GDB_SELF_TEST.
7270 * arm-tdep.c (selftests::arm_record_test): Likewise.
7271
4daf993d
YQ
72722017-04-21 Yao Qi <yao.qi@linaro.org>
7273
7274 * regcache.c (regcache_restore): Remove argument 2. Replace
7275 argument 3 with regcache. Get register status from
7276 src->register_status and get register contents from
7277 register_buffer (src, regnum).
7278 (regcache_cpy): Update.
7279
a6c21d4a
PA
72802017-04-19 Pedro Alves <palves@redhat.com>
7281
7282 * gdbthread.h (thread): Add missing closing parenthesis in
7283 comment.
7284
3a3fd0fd
PA
72852017-04-19 Pedro Alves <palves@redhat.com>
7286
7287 * common/refcounted-object.h: New file.
7288 * gdbthread.h: Include "common/refcounted-object.h".
7289 (thread_info): Inherit from refcounted_object and add comments.
7290 (thread_info::incref, thread_info::decref)
7291 (thread_info::m_refcount): Delete.
7292 (thread_info::deletable): Use the refcounted_object::refcount()
7293 method.
7294 * inferior.c (current_inferior_): Add comment.
7295 (set_current_inferior): Increment/decrement refcounts.
7296 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7297 not-deletable instead of comparing with the current inferior.
7298 (initialize_inferiors): Increment the initial inferior's refcount.
7299 * inferior.h (struct inferior): Forward declare.
7300 Include "common/refcounted-object.h".
7301 (current_inferior, set_current_inferior): Move declaration to
7302 before struct inferior's definition, and fix comment.
7303 (inferior): Inherit from refcounted_object. Add comments.
7304 * thread.c (switch_to_thread_no_regs): Reference the thread's
7305 inferior pointer directly instead of doing a ptid lookup.
7306 (switch_to_no_thread): New function.
7307 (switch_to_thread(thread_info *)): New function, factored out
7308 from ...
7309 (switch_to_thread(ptid_t)): ... this.
7310 (restore_current_thread): Delete.
7311 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7312 fields, and add 'inf' field.
7313 (do_restore_current_thread_cleanup): Check whether old->inf is
7314 alive instead of looking up an inferior by ptid. Use
7315 switch_to_thread and switch_to_no_thread.
7316 (restore_current_thread_cleanup_dtor): Use old->inf directly
7317 instead of lookup up an inferior by id. Decref the inferior.
7318 Don't restore 'removable'.
7319 (make_cleanup_restore_current_thread): Same the inferior pointer
7320 in old, instead of the inferior number. Incref the inferior.
7321 Don't save/clear 'removable'.
7322
9bcb1f16
PA
73232017-04-19 Pedro Alves <palves@redhat.com>
7324
7325 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7326 unittests/scoped_restore-selftests.c.
7327 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7328 * common/scoped_restore.h (scoped_restore_base): Make "class".
7329 (scoped_restore_base::release): New public method.
7330 (scoped_restore_base::scoped_restore_base): New protected ctor.
7331 (scoped_restore_base::m_saved_var): New protected field.
7332 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7333 scoped_restore_base base class instead of m_saved_var directly.
7334 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7335 (scoped_restore_tmpl::scoped_restore_tmpl(const
7336 scoped_restore_tmpl<T>&)): Likewise.
7337 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7338 method.
7339 (scoped_restore_tmpl::saved_var): New method.
7340 (scoped_restore_tmpl::m_saved_var): Delete.
7341 * inferior.h (inferior::detaching): Now a bool.
7342 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7343 cleanup.
7344 * unittests/scoped_restore-selftests.c: New file.
7345
26fcd539
PA
73462017-04-19 Pedro Alves <palves@redhat.com>
7347
7348 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7349 Re-sort in alphabetic order.
7350
fdd243b0
PA
73512017-04-18 Pedro Alves <palves@redhat.com>
7352
7353 * xml-support.c (obstack_xml_printf): Delete.
7354 * xml-support.h (obstack_xml_printf): Delete.
7355
4895cde2
PA
73562017-04-18 Pedro Alves <palves@redhat.com>
7357
7358 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7359 vdebug, verror, body_text, start_element, end_element, name,
7360 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7361 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7362 is_xinclude>: Make private and add m_ prefix.
7363 (gdb_xml_parser::body_text): New method, based on ...
7364 (gdb_xml_body_text): ... this. Adjust.
7365 (gdb_xml_parser::vdebug): New method, based on ...
7366 (gdb_xml_debug): ... this. Adjust.
7367 (gdb_xml_parser::verror): New method, based on ...
7368 (gdb_xml_error): ... this. Adjust.
7369 (gdb_xml_parser::start_element): New method, based on ...
7370 (gdb_xml_start_element): ... this. Adjust.
7371 (gdb_xml_start_element_wrapper): Defer to
7372 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7373 (gdb_xml_parser::end_element): New method, based on ...
7374 (gdb_xml_end_element_wrapper): ... this. Adjust.
7375 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7376 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7377 (gdb_xml_parser::use_dtd): New method, based on ...
7378 (gdb_xml_use_dtd): ... this. Adjust.
7379 (gdb_xml_parser::parse): New method, based on ...
7380 (gdb_xml_parse): ... this. Adjust.
7381 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7382 (xinclude_start_include): Adjust to call the parser's name method.
7383 (xml_xinclude_default, xml_xinclude_start_doctype)
7384 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7385 method.
7386 (xml_process_xincludes): Adjust to call parser methods.
7387 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7388 declarations.
7389
bd8a901f
PA
73902017-04-18 Pedro Alves <palves@redhat.com>
7391
7392 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7393 gdb::optional<std::string>.
7394 * xml-support.c: Include <string>.
7395 (scope_level::scope_level(scope_level &&))
7396 (scope_level::~scope_level): Delete.
7397 (scope_level::body): Now a std::string.
7398 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7399 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7400 parameter.
7401 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7402 (xinclude_parsing_data::output): Now a std::string reference.
7403 (xinclude_start_include): Adjust.
7404 (xml_xinclude_default): Adjust.
7405 (xml_process_xincludes): Add 'output' parameter, and return bool.
7406 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7407 and return bool.
7408 * xml-tdesc.c: Include <unordered_map> and <string>.
7409 (tdesc_xml_cache): Delete.
7410 (tdesc_xml_cache_s): Delete.
7411 (xml_cache): Now an std::unordered_map.
7412 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7413 (target_fetch_description_xml): Change return type to
7414 gdb::optional<std::string>, and adjust.
7415 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7416 (target_fetch_description_xml): Change return type to
7417 gdb::optional<std::string>.
7418
d35d1958
PA
74192017-04-18 Pedro Alves <palves@redhat.com>
7420
7421 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7422 unittests/optional-selftests.c.
7423 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7424 * unittests/optional-selftests.c: New file.
7425 * unittests/optional/assignment/1.cc: New file.
7426 * unittests/optional/assignment/2.cc: New file.
7427 * unittests/optional/assignment/3.cc: New file.
7428 * unittests/optional/assignment/4.cc: New file.
7429 * unittests/optional/assignment/5.cc: New file.
7430 * unittests/optional/assignment/6.cc: New file.
7431 * unittests/optional/assignment/7.cc: New file.
7432 * unittests/optional/cons/copy.cc: New file.
7433 * unittests/optional/cons/default.cc: New file.
7434 * unittests/optional/cons/move.cc: New file.
7435 * unittests/optional/cons/value.cc: New file.
7436 * unittests/optional/in_place.cc: New file.
7437 * unittests/optional/observers/1.cc: New file.
7438 * unittests/optional/observers/2.cc: New file.
7439
22796e97
PA
74402017-04-18 Pedro Alves <palves@redhat.com>
7441
7442 * common/gdb_optional.h: Include common/traits.h.
7443 (in_place_t): New type.
7444 (in_place): New constexpr variable.
7445 (optional::optional): Remove member initialization of
7446 m_instantiated.
7447 (optional::optional(in_place_t...)): New constructor.
7448 (optional::~optional): Use reset.
7449 (optional::optional(const optional&)): New.
7450 (optional::optional(const optional&&)): New.
7451 (optional::optional(T &)): New.
7452 (optional::optional(T &&)): New.
7453 (operator::operator=(const optional &)): New.
7454 (operator::operator=(optional &&)): New.
7455 (operator::operator= (const T &))
7456 (operator::operator= (T &&))
7457 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7458 (operator::reset): New.
7459 (operator::m_instantiated):: Add in-class initializer.
7460 * common/traits.h: Include <type_traits>.
7461 (struct And): New types.
7462
a7fc9b61
PA
74632017-04-18 Pedro Alves <palves@redhat.com>
7464
7465 * xml-support.c: Include <vector>.
7466 (scope_level::scope_level(const gdb_xml_element *))
7467 (scope_level::scope_level(scope_level&&)): New.
7468 (scope_level::~scope_level): New.
7469 (scope_level_s): Delete.
7470 (gdb_xml_parser::scopes): Now a std::vector.
7471 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
7472 Use std::vector.
7473 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
7474 scope cleanup code.
7475 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
7476 of the scopes member. Use std::vector::emplace_back.
7477
010151c9
PA
74782017-04-18 Pedro Alves <palves@redhat.com>
7479
7480 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
7481 a bool.
7482 (gdb_xml_end_element): Change type of first parameter.
7483 (gdb_xml_cleanup): Rename to ...
7484 (gdb_xml_parser::~gdb_xml_parser): ... this.
7485 (gdb_xml_create_parser_and_cleanup): Delete with ...
7486 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
7487 to this new ctor.
7488 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
7489 using gdb_xml_create_parser_and_cleanup.
7490 (xinclude_parsing_data): Add ctor/dtor.
7491 (xml_xinclude_cleanup): Delete.
7492 (xml_process_xincludes): Create a local xinclude_parsing_data
7493 instead of heap-allocating one. Create a local gdb_xml_parser
7494 instead of heap-allocating one with
7495 gdb_xml_create_parser_and_cleanup.
7496
d56060f0
JB
74972017-04-18 John Baldwin <jhb@FreeBSD.org>
7498
7499 PR threads/20743
7500 * fbsd-nat.c (resume_one_thread_cb): Remove.
7501 (resume_all_threads_cb): Remove.
7502 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
7503 iterate_over_threads.
7504
305d16a9
JB
75052017-04-17 Joel Brobecker <brobecker@adacore.com>
7506
7507 * NEWS: Create a new section for the next release branch.
7508 Rename the section of the current branch, now that it has
7509 been cut.
7510
8bb57231
JB
75112017-04-17 Joel Brobecker <brobecker@adacore.com>
7512
7513 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
7514 * version.in: Bump version to 8.0.50.DATE-git.
7515
096c92dd
SDJ
75162017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
7517
7518 PR gdb/21385
7519 * windows-nat.c (windows_create_inferior): Declare 'allargs'
7520 independently of the host, and fix build breakage on Cygwin.
7521
0550c955
PA
75222017-04-13 Pedro Alves <palves@redhat.com>
7523
7524 * inferior.c (free_inferior): Convert to ...
7525 (inferior::~inferior): ... this dtor.
7526 (inferior::inferior): New ctor, factored out from ...
7527 (add_inferior_silent): ... here. Allocate the inferior with a new
7528 expression.
7529 (delete_inferior): Call delete instead of free_inferior.
7530 * inferior.h (gdb_environ, continuation): Forward declare.
7531 (inferior): Now a class. Add in-class initialization to all
7532 members. Make boolean fields bool, except 'detaching'.
7533 (inferior::inferior): New explicit ctor.
7534 (inferior::~inferior): New.
7535
e3d60dfc
PA
75362017-04-13 Pedro Alves <palves@redhat.com>
7537
7538 * inferior.c (init_inferior_list): Delete.
7539 * inferior.h (init_inferior_list): Delete.
7540
5fd69d0a
PA
75412017-04-13 Pedro Alves <palves@redhat.com>
7542
7543 PR threads/13217
7544 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
7545 (top level): Call it twice, with different thread sets.
7546
c6609450
PA
75472017-04-13 Pedro Alves <palves@redhat.com>
7548
7549 * thread.c: Include <algorithm>.
7550 (thread_array_cleanup): Delete.
7551 (scoped_inc_dec_ref): New class.
7552 (live_threads_count): New function.
7553 (set_thread_refcount): Delete.
7554 (tp_array_compar_ascending): Now a bool.
7555 (tp_array_compar): Convert to a std::sort comparison function.
7556 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
7557 and live_threads_count.
7558
2a00d7ce
PA
75592017-04-13 Pedro Alves <palves@redhat.com>
7560
7561 * infrun.c (follow_fork_inferior): Also switch the current
7562 inferior.
7563
441d7c93
PA
75642017-04-13 Pedro Alves <palves@redhat.com>
7565
7566 * breakpoint.c (watch_command_1): Save watchpoint-frame info
7567 before calling create_internal_breakpoint.
7568
808480f6
PA
75692017-04-13 Pedro Alves <palves@redhat.com>
7570
7571 * fork-child.c (execv_argv): New class.
7572 (breakup_args): Refactored as ...
7573 (execv_argv::init_for_no_shell): .. this method of execv_argv.
7574 Copy arguments to storage and replace separators with NULL
7575 terminators in place.
7576 (escape_bang_in_quoted_argument): Adjust to return bool.
7577 (execv_argv::execv_argv): New ctor.
7578 (execv_argv::init_for_shell): New method, factored out from
7579 fork_inferior. Don't strdup strings into the vector.
7580 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
7581 Remove free_vector_argv call.
7582
ad3d022a
YQ
75832017-04-13 Yao Qi <yao.qi@linaro.org>
7584
7585 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
7586 tdep->rx_psw_type.
7587
e6ddc3bf
YQ
75882017-04-13 Yao Qi <yao.qi@linaro.org>
7589
7590 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
7591 * rx-tdep.c (rx_gdbarch_init): Likewise.
7592
bfb8cf90
PA
75932017-04-13 Pedro Alves <palves@redhat.com>
7594
7595 * breakpoint.h (struct breakpoint): Reindent.
7596
f5336ca5
PA
75972017-04-13 Pedro Alves <palves@redhat.com>
7598
7599 * breakpoint.c (bp_location): Rename to ...
7600 (bp_locations): ... this. All references updated.
7601 (bp_location_count): Rename to ...
7602 (bp_locations_count): ... this. All references updated.
7603 (bp_location_placed_address_before_address_max): Rename to ...
7604 (bp_locations_placed_address_before_address_max): ... this. All
7605 references updated.
7606 (bp_location_shadow_len_after_address_max): Rename to ...
7607 (bp_locations_shadow_len_after_address_max): ... this. All
7608 references updated.
7609 (bp_location_compare_addrs): Rename to ...
7610 (bp_locations_compare_addrs): ... this. All references updated.
7611 (bp_location_compare):Rename to ...
7612 (bp_locations_compare): ... this. All references updated.
7613 (bp_location_target_extensions_update): Rename to ...
7614 (bp_locations_target_extensions_update): ... this. All references
7615 updated.
7616
be628ab8
SDJ
76172017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7618
7619 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
7620 * common/common.m4: Check headers 'termios.h', 'termio.h' and
7621 'sgtty.h'.
7622 * common/gdb_termios.h: New file, with parts of "terminal.h".
7623 * inflow.c: Include "gdb_termios.h".
7624 * ser-unix.c: Include "gdb_termios.h".
7625 * terminal.h: Move terminal-related defines to
7626 "common/gdb_termios.h".
7627
8e9e35b1
TT
76282017-04-12 Tom Tromey <tom@tromey.com>
7629
7630 * probe.c (parse_probes): Update.
7631 * location.h (delete_event_location): Don't declare.
7632 (event_location_deleter::operator()): Update.
7633 * location.c (event_location_deleter::operator()): Rename from
7634 delete_event_location.
7635 * linespec.h (linespec_result) <location>: Change type to
7636 event_location_up.
7637 * linespec.c (canonicalize_linespec, event_location_to_sals)
7638 (decode_objc): Update.
7639 (linespec_result): Don't call delete_event_location.
7640 * breakpoint.c (create_breakpoints_sal)
7641 (bkpt_probe_create_sals_from_location)
7642 (strace_marker_create_sals_from_location): Update.
7643
16e802b9
TT
76442017-04-12 Tom Tromey <tom@tromey.com>
7645
7646 * linespec.h (struct linespec_result): Add constructor and
7647 destructor.
7648 (init_linespec_result, destroy_linespec_result)
7649 (make_cleanup_destroy_linespec_result): Don't declare.
7650 * linespec.c (init_linespec_result): Remove.
7651 (linespec_result::~linespec_result): Rename from
7652 destroy_linespec_result. Update.
7653 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
7654 Remove.
7655 * breakpoint.c (create_breakpoint, break_range_command)
7656 (decode_location_default): Update.
7657 * ax-gdb.c (agent_command_1): Update.
7658
d28cd78a
TT
76592017-04-12 Tom Tromey <tom@tromey.com>
7660
7661 * remote.c (remote_download_tracepoint): Update.
7662 * python/py-breakpoint.c (bppy_get_location): Update.
7663 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
7664 (gdbscm_breakpoint_location): Update.
7665 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
7666 * breakpoint.h (struct breakpoint) <location, location_range_end>:
7667 Change type to event_location_up.
7668 * breakpoint.c (create_overlay_event_breakpoint)
7669 (create_longjmp_master_breakpoint)
7670 (create_std_terminate_master_breakpoint)
7671 (create_exception_master_breakpoint)
7672 (breakpoint_event_location_empty_p, print_breakpoint_location)
7673 (print_one_breakpoint_location, create_thread_event_breakpoint)
7674 (init_breakpoint_sal, create_breakpoint)
7675 (print_recreate_ranged_breakpoint, break_range_command)
7676 (init_ada_exception_breakpoint, say_where): Update.
7677 (base_breakpoint_dtor): Don't call delete_event_location.
7678 (bkpt_print_recreate, tracepoint_print_recreate)
7679 (dprintf_print_recreate, update_static_tracepoint)
7680 (breakpoint_re_set_default): Update.
7681
711799d5
TT
76822017-04-12 Tom Tromey <tom@tromey.com>
7683
7684 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
7685 type of "to_do". Update.
7686 (compute_stack_depth): Use std::vector.
7687
52d214d3
TT
76882017-04-12 Tom Tromey <tom@tromey.com>
7689
7690 * printcmd.c (find_instruction_backward): Use std::vector.
7691
4c404b8b
TT
76922017-04-12 Tom Tromey <tom@tromey.com>
7693
7694 * symfile.c (objfilep): Remove typedef.
7695 (reread_symbols): Use a std::vector.
7696
156d9eab
TT
76972017-04-12 Tom Tromey <tom@tromey.com>
7698
7699 * mi/mi-main.c (exec_direction_forward): Remove.
7700 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
7701 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
7702 scoped_restore.
7703 * guile/guile.c (guile_repl_command, guile_command)
7704 (gdbscm_execute_gdb_command): Use scoped_restore.
7705 * go-exp.y (go_parse): Use scoped_restore.
7706 * d-exp.y (d_parse): Use scoped_restore.
7707 * cli/cli-decode.c (cmd_func): Use scoped_restore.
7708 * c-exp.y (c_parse): Use scoped_restore.
7709
4d89769a
TT
77102017-04-12 Tom Tromey <tom@tromey.com>
7711
7712 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
7713 (mi_parse): Update return type.
7714 (mi_parse_free): Remove.
7715 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
7716 (mi_parse::~mi_parse): Rename from mi_parse_free.
7717 (mi_parse_cleanup): Remove.
7718 (mi_parse): Return a unique_ptr. Use new.
7719 * mi/mi-main.c (mi_execute_command): Update.
7720
4b217cc7
TT
77212017-04-12 Tom Tromey <tom@tromey.com>
7722
7723 * location.c (explicit_location_lex_one): Return a
7724 unique_xmalloc_ptr.
7725 (string_to_explicit_location): Update. Remove cleanups.
7726
59d3651b
TT
77272017-04-12 Tom Tromey <tom@tromey.com>
7728
7729 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
7730 (compare_value_and_voffset): Change type. Update.
7731 (compute_vtable_size): Change type of "offset_vec".
7732 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
7733 (gnuv3_get_typeid): Remove extraneous declaration.
7734
b24b0d6c
TT
77352017-04-12 Tom Tromey <tom@tromey.com>
7736
7737 * charset.h (wchar_iterator): Fix comment.
7738
80a3b8c5
TT
77392017-04-12 Tom Tromey <tom@tromey.com>
7740
7741 * charset.c (iconv_wrapper): New class.
7742 (cleanup_iconv): Remove.
7743 (convert_between_encodings): Use it.
7744
c83dd867
TT
77452017-04-12 Tom Tromey <tom@tromey.com>
7746
7747 * symfile.h (increment_reading_symtab): Update type.
7748 * symfile.c (decrement_reading_symtab): Remove.
7749 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
7750 * psymtab.c (psymtab_to_symtab): Update.
7751 * dwarf2read.c (dw2_instantiate_symtab): Update.
7752
0e8621a0
TT
77532017-04-12 Tom Tromey <tom@tromey.com>
7754
7755 * jit.c (struct jit_reader): Declare separately. Add constructor
7756 and destructor. Change type of "handle".
7757 (loaded_jit_reader): Define separately.
7758 (jit_reader_load): Update. New "new".
7759 (jit_reader_unload_command): Use "delete".
7760 * gdb-dlfcn.h (struct dlclose_deleter): New.
7761 (gdb_dlhandle_up): New typedef.
7762 (gdb_dlopen, gdb_dlsym): Update types.
7763 (gdb_dlclose): Remove.
7764 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
7765 (gdb_dlsym): Change type of "handle".
7766 (make_cleanup_dlclose): Remove.
7767 (dlclose_deleter::operator()): Rename from gdb_dlclose.
7768 * compile/compile-c-support.c (load_libcc): Update.
7769
67d89901
TT
77702017-04-12 Tom Tromey <tom@tromey.com>
7771
7772 * symtab.h (find_pcs_for_symtab_line): Change return type.
7773 * symtab.c (find_pcs_for_symtab_line): Change return type.
7774 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
7775 type of "vec". Update.
7776 (ltpy_get_pcs_for_line): Update.
7777 * linespec.c (decode_digits_ordinary): Update.
7778
93921405
TT
77792017-04-12 Tom Tromey <tom@tromey.com>
7780
7781 * tracepoint.c (actions_command): Update.
7782 * python/python.c (python_command, python_interactive_command):
7783 Update.
7784 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
7785 * guile/guile.c (guile_command): Update.
7786 * defs.h (read_command_lines, read_command_lines_1): Return
7787 command_line_up.
7788 (command_lines_deleter): New struct.
7789 (command_line_up): New typedef.
7790 * compile/compile.c (compile_code_command)
7791 (compile_print_command): Update.
7792 * cli/cli-script.h (get_command_line, copy_command_lines): Return
7793 command_line_up.
7794 (make_cleanup_free_command_lines): Remove.
7795 * cli/cli-script.c (get_command_line, read_command_lines_1)
7796 (copy_command_lines): Return command_line_up.
7797 (while_command, if_command, read_command_lines, define_command)
7798 (document_command): Update.
7799 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
7800 Remove.
7801 * breakpoint.h (breakpoint_set_commands): Change type of
7802 "commands".
7803 * breakpoint.c (breakpoint_set_commands): Change type of
7804 "commands". Update.
7805 (do_map_commands_command, update_dprintf_command_list)
7806 (create_tracepoint_from_upload): Update.
7807
ffc2605c
TT
78082017-04-12 Tom Tromey <tom@tromey.com>
7809
7810 * tracepoint.c (scope_info): Update.
7811 * spu-tdep.c (spu_catch_start): Update.
7812 * python/python.c (gdbpy_decode_line): Update.
7813 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
7814 * python/py-breakpoint.c (bppy_init): Update.
7815 * probe.c (parse_probes): Update.
7816 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
7817 * location.h (event_location_deleter): New struct.
7818 (event_location_up): New typedef.
7819 (new_linespec_location, new_address_location, new_probe_location)
7820 (new_explicit_location, copy_event_location)
7821 (string_to_event_location, string_to_event_location_basic)
7822 (string_to_explicit_location): Update return type.
7823 (make_cleanup_delete_event_location): Remove.
7824 * location.c (new_linespec_location, new_address_location)
7825 (new_probe_location, new_explicit_location, copy_event_location):
7826 Return event_location_up.
7827 (delete_event_location_cleanup)
7828 (make_cleanup_delete_event_location): Remove.
7829 (string_to_explicit_location, string_to_event_location_basic)
7830 (string_to_event_location): Return event_location_up.
7831 * linespec.c (canonicalize_linespec, event_location_to_sals)
7832 (decode_line_with_current_source)
7833 (decode_line_with_last_displayed, decode_objc): Update.
7834 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
7835 * completer.c (location_completer): Update.
7836 * cli/cli-cmds.c (edit_command, list_command): Update.
7837 * breakpoint.c (create_overlay_event_breakpoint)
7838 (create_longjmp_master_breakpoint)
7839 (create_std_terminate_master_breakpoint)
7840 (create_exception_master_breakpoint)
7841 (create_thread_event_breakpoint): Update.
7842 (init_breakpoint_sal): Update. Remove some dead code.
7843 (create_breakpoint_sal): Change type of "location". Update.
7844 (create_breakpoints_sal, create_breakpoint, break_command_1)
7845 (dprintf_command, break_range_command, until_break_command)
7846 (init_ada_exception_breakpoint)
7847 (strace_marker_create_sals_from_location)
7848 (update_static_tracepoint, trace_command, ftrace_command)
7849 (strace_command, create_tracepoint_from_upload): Update.
7850 * break-catch-throw.c (re_set_exception_catchpoint): Update.
7851 * ax-gdb.c (agent_command_1): Update.
7852
8f10c932
PA
78532017-04-12 Pedro Alves <palves@redhat.com>
7854
7855 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
7856 * configure.tgt: Handle i[34567]86-*-go32* and
7857 i[34567]86-*-msdosdjgpp*.
7858 * i386-tdep.c (i386_svr4_reg_to_regnum):
7859 Make extern.
7860 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
7861 i386-go32-tdep.c.
7862 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
7863 * i386-go32-tdep.c: New file.
7864 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
7865 declarations.
7866
0a31ccfb
SM
78672017-04-12 Simon Marchi <simon.marchi@ericsson.com>
7868
7869 * aix-thread.c (pd_status2str): Change return type to const char *.
7870
e9bb3fbb
PA
78712017-04-12 Pedro Alves <palves@redhat.com>
7872
7873 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
7874 calls to set_gdbarch_gnu_triplet_regexp.
7875
53375380
PA
78762017-04-12 Pedro Alves <palves@redhat.com>
7877
7878 PR gdb/21323
7879 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
7880 New enum value.
7881 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
7882 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
7883 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
7884 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
7885 * gdbarch.h, gdbarch.c: Regenerate.
7886 * aarch64-tdep.c (aarch64_gdbarch_init): Override
7887 gdbarch_wchar_bit and gdbarch_wchar_signed.
7888 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
7889 * arm-tdep.c (arm_gdbarch_init): Likewise.
7890 * avr-tdep.c (avr_gdbarch_init): Likewise.
7891 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
7892 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
7893 * i386-tdep.c (i386_go32_init_abi): Likewise.
7894 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
7895 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
7896 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7897 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
7898 * sh-tdep.c (sh_gdbarch_init): Likewise.
7899 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7900 * sparc64-tdep.c (sparc64_init_abi): Likewise.
7901 * windows-tdep.c (windows_init_abi): Likewise.
7902 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
7903
53e710ac
PA
79042017-04-12 Pedro Alves <palves@redhat.com>
7905
7906 PR c++/21323
7907 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
7908 cplus_primitive_type_char32_t>: New enum values.
7909 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
7910 and cplus_primitive_type_char32_t.
7911 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
7912 32, use the archtecture's built-in type for char16_t and char32_t,
7913 respectively. Otherwise, fallback to init_integer_type as before,
7914 but make the type unsigned, and issue a complaint.
7915 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
7916
ab0538b8
AH
79172017-04-12 Alan Hayward <alan.hayward@arm.com>
7918
5e0e0422 7919 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
7920 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
7921
5430098f
SDJ
79222017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7923
7924 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
7925 'const char *'.
7926
7c5ded6a
SDJ
79272017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
7928
7929 * common/common-utils.c (free_vector_argv): New function.
7930 * common/common-utils.h: Include <vector>.
7931 (free_vector_argv): New prototype.
7932 * darwin-nat.c (darwin_create_inferior): Rewrite function
7933 prototype in order to constify "exec_file" and accept a
7934 "std::string" for "allargs".
7935 * fork-child.c: Include <vector>.
7936 (breakup_args): Rewrite function, using C++.
7937 (fork_inferior): Rewrite function header, constify "exec_file_arg"
7938 and accept "std::string" for "allargs". Update the code to
7939 calculate "argv" based on "allargs". Update calls to "exec_fun"
7940 and "execvp".
7941 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
7942 order to constify "exec_file" and accept a "std::string" for
7943 "allargs".
7944 * go32-nat.c (go32_create_inferior): Likewise.
7945 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
7946 * infcmd.c (run_command_1): Constify "exec_file". Use
7947 "std::string" for inferior arguments.
7948 * inferior.h (fork_inferior): Update prototype.
7949 * linux-nat.c (linux_nat_create_inferior): Rewrite function
7950 prototype in order to constify "exec_file" and accept a
7951 "std::string" for "allargs".
7952 * nto-procfs.c (procfs_create_inferior): Likewise.
7953 * procfs.c (procfs_create_inferior): Likewise.
7954 * remote-sim.c (gdbsim_create_inferior): Likewise.
7955 * remote.c (extended_remote_run): Update code to accept
7956 "std::string" as argument.
7957 (extended_remote_create_inferior): Rewrite function prototype in
7958 order to constify "exec_file" and accept a "std::string" for
7959 "allargs".
7960 * rs6000-nat.c (super_create_inferior): Likewise.
7961 (rs6000_create_inferior): Likewise.
7962 * target.h (struct target_ops) <to_create_inferior>: Likewise.
7963 * windows-nat.c (windows_create_inferior): Likewise.
7964
ae0eee42
PA
79652017-04-11 Pedro Alves <palves@redhat.com>
7966
7967 * thread.c: Fix whitespace throughout.
7968
a6acac06
PR
79692017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
7970
7971 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
7972
64403bd1
AH
79732017-04-11 Alan Hayward <alan.hayward@arm.com>
7974
7975 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
7976
a5bef50f
SDJ
79772017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
7978
7979 PR gdb/21364
7980 * osdata.c (info_osdata): Check if 'type' is an empty string
7981 instead of NULL.
7982
9295a5a9
PA
79832017-04-10 Pedro Alves <palves@redhat.com>
7984
7985 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
7986 (ptid_to_global_thread_id, in_thread_list)
7987 (do_captured_list_thread_ids, set_resumed, set_running)
7988 (set_executing, set_stop_requested, finish_thread_state)
7989 (validate_registers_access, can_access_registers_ptid)
7990 (print_thread_info_1, switch_to_thread)
7991 (do_restore_current_thread_cleanup)
7992 (make_cleanup_restore_current_thread, thread_command)
7993 (thread_name_command): Use operator== instead of ptid_equal.
7994
996812e3
PA
79952017-04-10 Pedro Alves <palves@redhat.com>
7996
7997 * thread.c (struct current_thread_cleanup) <next>: Delete field.
7998 (current_thread_cleanup_chain): Delete.
7999 (restore_current_thread_cleanup_dtor)
8000 (make_cleanup_restore_current_thread): Remove references to
8001 current_thread_cleanup_chain.
8002
845b344f
AH
80032017-04-10 Alan Hayward <alan.hayward@arm.com>
8004
8005 * msp430-tdep.c (msp430_pseudo_register_read): Never return
8006 REG_UNKNOWN.
8007
803bdfe4
YQ
80082017-04-10 Yao Qi <yao.qi@linaro.org>
8009
8010 PR gdb/19942
8011 * gdbthread.h (thread_info::deletable): New method.
8012 (thread_info::incref): New method.
8013 (thread_info::decref): New method.
8014 (thread_info::refcount): Move it to private.
8015 * infrun.c (save_stop_context): Call inc_refcount.
8016 (release_stop_context_cleanup): Likewise.
8017 * thread.c (set_thread_exited): New function.
8018 (init_thread_list): Delete "tp" only it is deletable, otherwise
8019 call set_thread_exited.
8020 (delete_thread_1): Call set_thread_exited.
8021 (current_thread_cleanup) <inferior_pid>: Remove.
8022 <thread>: New field.
8023 (restore_current_thread_ptid_changed): Removed.
8024 (do_restore_current_thread_cleanup): Adjust.
8025 (restore_current_thread_cleanup_dtor): Don't call
8026 find_thread_ptid.
8027 (set_thread_refcount): Use dec_refcount.
8028 (make_cleanup_restore_current_thread): Adjust.
8029 (thread_apply_all_command): Call inc_refcount.
8030 (_initialize_thread): Don't call
8031 observer_attach_thread_ptid_changed.
8032
8c25b497
YQ
80332017-04-10 Yao Qi <yao.qi@linaro.org>
8034
8035 * thread.c (delete_thread_1): Hoist code on marking thread as
8036 exited.
8037
8473b447
SM
80382017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8039
8040 * windows-nat.c (windows_detach): Initialize ptid with
8041 minus_one_ptid.
8042
6670ec13
SM
80432017-04-07 Simon Marchi <simon.marchi@ericsson.com>
8044
8045 * unittests/ptid-selftests.c: Fix erroneous assert messages.
8046
ba2f91bb
AH
80472017-04-07 Alan Hayward <alan.hayward@arm.com>
8048
8049 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
8050 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
8051 (bfin_pseudo_register_write): Likewise
8052
436252de
SM
80532017-04-06 Simon Marchi <simon.marchi@ericsson.com>
8054
8055 * common/ptid.h (struct ptid): Change to...
8056 (class ptid_t): ... this.
8057 <ptid_t>: New constructors.
8058 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
8059 matches>: New methods.
8060 <make_null, make_minus_one>: New static methods.
8061 <pid>: Rename to...
8062 <m_pid>: ...this.
8063 <lwp>: Rename to...
8064 <m_lwp>: ...this.
8065 <tid>: Rename to...
8066 <m_tid>: ...this.
8067 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
8068 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
8069 as references, move comment to class ptid_t.
8070 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
8071 ptid_t static methods.
8072 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
8073 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
8074 Take ptid arguments as references, implement using ptid_t methods.
8075 * unittests/ptid-selftests.c: New file.
8076 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8077 unittests/ptid-selftests.c.
8078 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
8079
0dedf377
TP
80802017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
8081
8082 * python/python.c (python_run_simple_file): Cast mode literal to
8083 non-const char pointer as expected by PyFile_FromString.
8084
4e9868d4
SM
80852017-04-05 Simon Marchi <simon.marchi@ericsson.com>
8086
8087 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
8088 minus_one_ptid and null_ptid.
8089
9bf2a700
PA
80902017-04-05 Pedro Alves <palves@redhat.com>
8091
8092 * warning.m4 (build_warnings): Remove -Wno-write-strings.
8093 * configure: Regenerate.
8094
a121b7c1
PA
80952017-04-05 Pedro Alves <palves@redhat.com>
8096
8097 * ada-exp.y (yyerror): Constify.
8098 * ada-lang.c (bound_name, get_selections)
8099 (ada_variant_discrim_type)
8100 (ada_variant_discrim_name, ada_value_struct_elt)
8101 (ada_lookup_struct_elt_type, is_unchecked_variant)
8102 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
8103 (catch_ada_exception_command_split)
8104 (catch_ada_assert_command_split, catch_assert_command)
8105 (ada_op_name): Constify.
8106 * ada-lang.h (ada_yyerror, get_selections)
8107 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
8108 * arc-tdep.c (arc_print_frame_cache): Constify.
8109 * arm-tdep.c (arm_skip_stub): Constify.
8110 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
8111 (gen_aggregate_elt_ref): Constify.
8112 * bcache.c (print_bcache_statistics): Constify.
8113 * bcache.h (print_bcache_statistics): Constify.
8114 * break-catch-throw.c (catch_exception_command_1):
8115 * breakpoint.c (struct ep_type_description::description):
8116 Constify.
8117 (add_solib_catchpoint): Constify.
8118 (catch_fork_command_1): Add cast.
8119 (add_catch_command): Constify.
8120 * breakpoint.h (add_catch_command, add_solib_catchpoint):
8121 Constify.
8122 * bsd-uthread.c (bsd_uthread_state): Constify.
8123 * buildsym.c (patch_subfile_names): Constify.
8124 * buildsym.h (next_symbol_text_func, patch_subfile_names):
8125 Constify.
8126 * c-exp.y (yyerror): Constify.
8127 (token::oper): Constify.
8128 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
8129 * c-varobj.c (cplus_describe_child): Constify.
8130 * charset.c (find_charset_names): Add cast.
8131 (find_charset_names): Constify array and add const_cast.
8132 * cli/cli-cmds.c (complete_command, cd_command): Constify.
8133 (edit_command): Constify.
8134 * cli/cli-decode.c (lookup_cmd): Constify.
8135 * cli/cli-dump.c (dump_memory_command, dump_value_command):
8136 Constify.
8137 (struct dump_context): Constify.
8138 (add_dump_command, restore_command): Constify.
8139 * cli/cli-script.c (get_command_line): Constify.
8140 * cli/cli-script.h (get_command_line): Constify.
8141 * cli/cli-utils.c (check_for_argument): Constify.
8142 * cli/cli-utils.h (check_for_argument): Constify.
8143 * coff-pe-read.c (struct read_pe_section_data): Constify.
8144 * command.h (lookup_cmd): Constify.
8145 * common/print-utils.c (decimal2str): Constify.
8146 * completer.c (gdb_print_filename): Constify.
8147 * corefile.c (set_gnutarget): Constify.
8148 * cp-name-parser.y (yyerror): Constify.
8149 * cp-valprint.c (cp_print_class_member): Constify.
8150 * cris-tdep.c (cris_register_name, crisv32_register_name):
8151 Constify.
8152 * d-exp.y (yyerror): Constify.
8153 (struct token::oper): Constify.
8154 * d-lang.h (d_yyerror): Constify.
8155 * dbxread.c (struct header_file_location::name): Constify.
8156 (add_old_header_file, add_new_header_file, last_function_name)
8157 (dbx_next_symbol_text, add_bincl_to_list)
8158 (find_corresponding_bincl_psymtab, set_namestring)
8159 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
8160 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
8161 * defs.h (command_line_input, print_address_symbolic)
8162 (deprecated_readline_begin_hook): Constify.
8163 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
8164 Constify.
8165 * event-top.c (handle_line_of_input): Constify and add cast.
8166 * exceptions.c (catch_errors): Constify.
8167 * exceptions.h (catch_errors): Constify.
8168 * expprint.c (print_subexp_standard, op_string, op_name)
8169 (op_name_standard, dump_raw_expression, dump_raw_expression):
8170 * expression.h (op_name, op_string, dump_raw_expression):
8171 Constify.
8172 * f-exp.y (yyerror): Constify.
8173 (struct token::oper): Constify.
8174 (struct f77_boolean_val::name): Constify.
8175 * f-lang.c (f_word_break_characters): Constify.
8176 * f-lang.h (f_yyerror): Constify.
8177 * fork-child.c (fork_inferior): Add cast.
8178 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8179 (new_variant): Constify.
8180 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8181 * gdbarch.c: Regenerate.
8182 * gdbcore.h (set_gnutarget): Constify.
8183 * go-exp.y (yyerror): Constify.
8184 (token::oper): Constify.
8185 * go-lang.h (go_yyerror): Constify.
8186 * go32-nat.c (go32_sysinfo): Constify.
8187 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8188 * guile/scm-cmd.c (cmdscm_function): Constify.
8189 * guile/scm-param.c (pascm_param_value): Constify.
8190 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8191 (h8300sx_register_name): Constify.
8192 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8193 Constify.
8194 * ia64-tdep.c (ia64_register_names): Constify.
8195 * infcmd.c (construct_inferior_arguments): Constify.
8196 (path_command, attach_post_wait): Constify.
8197 * language.c (show_range_command, show_case_command)
8198 (unk_lang_error): Constify.
8199 * language.h (language_defn::la_error)
8200 (language_defn::la_name_of_this): Constify.
8201 * linespec.c (decode_line_2): Constify.
8202 * linux-thread-db.c (thread_db_err_str): Constify.
8203 * lm32-tdep.c (lm32_register_name): Constify.
8204 * m2-exp.y (yyerror): Constify.
8205 * m2-lang.h (m2_yyerror): Constify.
8206 * m32r-tdep.c (m32r_register_names): Constify and make static.
8207 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8208 * m88k-tdep.c (m88k_register_name): Constify.
8209 * macroexp.c (appendmem): Constify.
8210 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8211 (upgrade_type, parse_external, parse_partial_symbols)
8212 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8213 (new_symbol): Constify.
8214 * memattr.c (mem_info_command): Constify.
8215 * mep-tdep.c (register_name_from_keyword): Constify.
8216 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8217 Constify.
8218 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8219 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8220 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8221 cast.
8222 (mi_execute_async_cli_command): Constify.
8223 * mips-tdep.c (mips_register_name): Constify.
8224 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8225 (am33_register_name, am33_2_register_name)
8226 * moxie-tdep.c (moxie_register_names): Constify.
8227 * nat/linux-osdata.c (osdata_type): Constify fields.
8228 * nto-tdep.c (nto_parse_redirection): Constify.
8229 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8230 (lookup_child_selector): Constify.
8231 (objc_methcall::name): Constify.
8232 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8233 (lookup_struct_typedef): Constify.
8234 * objfiles.c (pc_in_section): Constify.
8235 * objfiles.h (pc_in_section): Constify.
8236 * p-exp.y (struct token::oper): Constify.
8237 (yyerror): Constify.
8238 * p-lang.h (pascal_yyerror): Constify.
8239 * parser-defs.h (op_name_standard): Constify.
8240 (op_print::string): Constify.
8241 (exp_descriptor::op_name): Constify.
8242 * printcmd.c (print_address_symbolic): Constify.
8243 * psymtab.c (print_partial_symbols): Constify.
8244 * python/py-breakpoint.c (stop_func): Constify.
8245 (bppy_get_expression): Constify.
8246 * python/py-cmd.c (cmdpy_completer::name): Constify.
8247 (cmdpy_function): Constify.
8248 * python/py-event.c (evpy_add_attribute)
8249 (gdbpy_initialize_event_generic): Constify.
8250 * python/py-event.h (evpy_add_attribute)
8251 (gdbpy_initialize_event_generic): Constify.
8252 * python/py-evts.c (add_new_registry): Constify.
8253 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8254 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8255 * python/py-inferior.c (get_buffer): Add cast.
8256 * python/py-param.c (parm_constant::name): Constify.
8257 * python/py-unwind.c (fprint_frame_id): Constify.
8258 * python/python.c (gdbpy_parameter_value): Constify.
8259 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8260 * remote.c (memory_packet_config::name): Constify.
8261 (show_packet_config_cmd, remote_write_bytes)
8262 (remote_buffer_add_string):
8263 * reverse.c (exec_reverse_once): Constify.
8264 * rs6000-tdep.c (variant::name, variant::description): Constify.
8265 * rust-exp.y (rustyyerror): Constify.
8266 * rust-lang.c (rust_op_name): Constify.
8267 * rust-lang.h (rustyyerror): Constify.
8268 * serial.h (serial_ops::name): Constify.
8269 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8270 (sh_sh3e_register_name, sh_sh2e_register_name)
8271 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8272 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8273 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8274 (sh_sh4al_dsp_register_name): Constify.
8275 * sh64-tdep.c (sh64_register_name): Constify.
8276 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8277 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8278 * stabsread.c (patch_block_stabs, read_type_number)
8279 (ref_map::stabs, ref_add, process_reference)
8280 (symbol_reference_defined, define_symbol, define_symbol)
8281 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8282 (read_one_struct_field, read_struct_fields, read_baseclasses)
8283 (read_tilde_fields, read_struct_type, read_array_type)
8284 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8285 (read_huge_number, read_range_type, read_args, common_block_start)
8286 (find_name_end): Constify.
8287 * stabsread.h (common_block_start, define_symbol)
8288 (process_one_symbol, symbol_reference_defined, ref_add):
8289 * symfile.c (get_section_index, add_symbol_file_command):
8290 * symfile.h (get_section_index): Constify.
8291 * target-descriptions.c (tdesc_type::name): Constify.
8292 (tdesc_free_type): Add cast.
8293 * target.c (find_default_run_target):
8294 (add_deprecated_target_alias, find_default_run_target)
8295 (target_announce_detach): Constify.
8296 (do_option): Constify.
8297 * target.h (add_deprecated_target_alias): Constify.
8298 * thread.c (print_thread_info_1): Constify.
8299 * top.c (deprecated_readline_begin_hook, command_line_input):
8300 Constify.
8301 (init_main): Add casts.
8302 * top.h (handle_line_of_input): Constify.
8303 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8304 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8305 (tfind_command): Rename to ...
8306 (tfind_command_1): ... this and constify.
8307 (tfind_command): New function.
8308 (tfind_end_command, tfind_start_command): Adjust.
8309 (encode_source_string): Constify.
8310 * tracepoint.h (encode_source_string): Constify.
8311 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8312 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8313 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8314 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8315 * tui/tui-win.c (parse_scrolling_args): Constify.
8316 * tui/tui-windata.c (tui_erase_data_content): Constify.
8317 * tui/tui-windata.h (tui_erase_data_content): Constify.
8318 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8319 * tui/tui.c (tui_enable): Add cast.
8320 * utils.c (defaulted_query): Constify.
8321 (init_page_info): Add cast.
8322 (puts_debug, subset_compare): Constify.
8323 * utils.h (subset_compare): Constify.
8324 * varobj.c (varobj_format_string): Constify.
8325 * varobj.h (varobj_format_string): Constify.
8326 * vax-tdep.c (vax_register_name): Constify.
8327 * windows-nat.c (windows_detach): Constify.
8328 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8329 * xml-support.c (gdb_xml_end_element): Constify.
8330 * xml-tdesc.c (tdesc_start_reg): Constify.
8331 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8332 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8333 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8334
995816ba
PA
83352017-04-05 Pedro Alves <palves@redhat.com>
8336
8337 * proc-api.c (struct trans): Constify.
8338 (procfs_note): Constify.
8339 * proc-events.c (struct trans, syscall_table):
8340 * proc-flags.c (struct trans): Constify.
8341 * proc-utils.h (procfs_note): Constify.
8342 * proc-why.c (struct trans): Constify.
8343 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8344 (procfs_detach): Constify.
8345 * sol-thread.c (struct string_map): Constify.
8346 (td_err_string, td_state_string): Constify.
8347
3e83a920
PA
83482017-04-05 Pedro Alves <palves@redhat.com>
8349
8350 * proc-api.c (procfs_filename): Don't initialize
8351 procfs_filename.
8352 (prepare_to_trace): Assume procfs_filename is non-NULL.
8353 (_initialize_proc_api): Give procfs_filename a default value here.
8354
63160a43
PA
83552017-04-05 Pedro Alves <palves@redhat.com>
8356
8357 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8358 'cond_string' parameter.
8359 (extract_exception_regexp): Constify 'string' parameter.
8360 (catch_exception_command_1): Constify.
8361 * breakpoint.c (init_catchpoint)
8362 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8363 parameter.
8364 (ep_parse_optional_if_clause, catch_fork_command_1)
8365 (catch_exec_command_1): Constify.
8366 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8367 parameter.
8368 (ep_parse_optional_if_clause): Constify.
8369 * cli/cli-utils.c (remove_trailing_whitespace)
8370 (check_for_argument): Constify.
8371 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8372 non-const overload.
8373 (check_for_argument): Likewise.
8374
9b2eba3d
PA
83752017-04-05 Pedro Alves <palves@redhat.com>
8376
8377 * event-top.c (command_line_handler): Add cast to execute_command
8378 call.
8379 * record-btrace.c (cmd_record_btrace_bts_start)
8380 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8381 (cmd_record_btrace_start): Add cast to execute_command call.
8382 * record-full.c (record_full_goto_insn):
8383 * record.c (record_start, record_stop): Add cast to
8384 execute_command_to_string calls.
8385 (cmd_record_start): Add cast to execute_command calls.
8386
2adadf51
PA
83872017-04-05 Pedro Alves <palves@redhat.com>
8388
8389 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8390 static inline function.
8391 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8392 array and use gdb_PyArg_ParseTupleAndKeywords.
8393 * python/py-cmd.c (cmdpy_init): Likewise.
8394 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8395 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8396 (infpy_search_memory): Likewise.
8397 * python/py-objfile.c (objfpy_add_separate_debug_file)
8398 (gdbpy_lookup_objfile): Likewise.
8399 * python/py-symbol.c (gdbpy_lookup_symbol)
8400 (gdbpy_lookup_global_symbol): Likewise.
8401 * python/py-type.c (gdbpy_lookup_type): Likewise.
8402 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8403 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8404 Likewise.
8405
0d1f4ceb
PA
84062017-04-05 Pedro Alves <palves@redhat.com>
8407
8408 * python/python-internal.h (gdb_PyGetSetDef): New type.
8409 * python/py-block.c (block_object_getset)
8410 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8411 * python/py-event.c (event_object_getset)
8412 (finish_breakpoint_object_getset): Likewise.
8413 * python/py-inferior.c (inferior_object_getset): Likewise.
8414 * python/py-infthread.c (thread_object_getset): Likewise.
8415 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8416 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8417 * python/py-objfile.c (objfile_getset): Likewise.
8418 * python/py-progspace.c (pspace_getset): Likewise.
8419 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8420 Likewise.
8421 * python/py-record.c (recpy_record_getset): Likewise.
8422 * python/py-symbol.c (symbol_object_getset): Likewise.
8423 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8424 Likewise.
8425 * python/py-type.c (type_object_getset, field_object_getset):
8426 Likewise.
8427 * python/py-value.c (value_object_getset): Likewise.
8428
4d759979
PA
84292017-04-05 Pedro Alves <palves@redhat.com>
8430
8431 * python/python-internal.h (gdb_PyObject_CallMethod)
8432 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8433 New functions.
8434 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8435 (PySys_GetObject, PySys_SetPath): New macros.
8436
fdf9e36f
PA
84372017-04-05 Pedro Alves <palves@redhat.com>
8438
8439 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8440 info_osdata_command.
8441 * osdata.c (info_osdata_command): Rename to ...
8442 (info_osdata): ... this. Constify 'type' parameter, and remove
8443 the 'from_tty' parameter. Accept NULL TYPE.
8444 (info_osdata_command): New function.
8445 * osdata.h (info_osdata_command): Remove declaration.
8446 (info_osdata): New declaration.
8447
9f33b8b7
PA
84482017-04-05 Pedro Alves <palves@redhat.com>
8449
8450 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8451 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8452 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8453 parameter.
8454 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8455 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8456 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8457 parameter.
8458 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8459 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
8460 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
8461 (mi_cmd_file_list_exec_source_files)
8462 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
8463 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8464 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
8465 parameter.
8466 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
8467 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
8468 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
8469 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
8470 (mi_cmd_stack_info_frame): Constify 'command' parameter.
8471 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
8472 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
8473 'command' parameter.
8474 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
8475 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
8476 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
8477 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
8478 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
8479 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
8480 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
8481 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
8482 (mi_cmd_var_set_update_range): Constify 'command' parameter.
8483 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
8484 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
8485 parameter.
8486 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
8487 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
8488 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
8489 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
8490 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
8491 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
8492 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
8493 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
8494 (mi_cmd_data_list_changed_registers)
8495 (mi_cmd_data_write_register_values)
8496 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
8497 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
8498 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
8499 (mi_cmd_list_features, mi_cmd_list_target_features)
8500 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
8501 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
8502 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
8503 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
8504 (mi_cmd_trace_frame_collected): Constify 'command'
8505 parameter.
8506 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
8507 'command' parameter.
8508
67cb5b2d
PA
85092017-04-05 Pedro Alves <palves@redhat.com>
8510
8511 * ada-lang.c (ada_completer_word_break_characters): Now a const
8512 array.
8513 (ada_get_gdb_completer_word_break_characters): Constify.
8514 * completer.c (gdb_completer_command_word_break_characters)
8515 (gdb_completer_file_name_break_characters)
8516 (gdb_completer_quote_characters): Now const arrays.
8517 (get_gdb_completer_quote_characters): Constify.
8518 (set_rl_completer_word_break_characters): New function.
8519 (set_gdb_completion_word_break_characters)
8520 (complete_line_internal): Use it.
8521 * completer.h (get_gdb_completer_quote_characters): Constify.
8522 (set_rl_completer_word_break_characters): Declare.
8523 * f-lang.c (f_word_break_characters): Constify.
8524 * language.c (default_word_break_characters): Constify.
8525 * language.h (language_defn::la_word_break_characters): Constify.
8526 (default_word_break_characters): Constify.
8527 * top.c (init_main): Use set_rl_completer_word_break_characters.
8528
7a114964
PA
85292017-04-05 Pedro Alves <palves@redhat.com>
8530
8531 * aix-thread.c (aix_thread_pid_to_str)
8532 (aix_thread_extra_thread_info): Constify.
8533 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
8534 * bsd-uthread.c (bsd_uthread_extra_thread_info)
8535 (bsd_uthread_pid_to_str): Constify.
8536 * corelow.c (core_pid_to_str): Constify.
8537 * darwin-nat.c (darwin_pid_to_str): Constify.
8538 * fbsd-nat.c (fbsd_pid_to_str): Constify.
8539 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
8540 Constify.
8541 * gnu-nat.c (gnu_pid_to_str): Constify.
8542 * go32-nat.c (go32_pid_to_str): Constify.
8543 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
8544 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
8545 * inferior.c (inferior_pid_to_str): Constify.
8546 * linux-nat.c (linux_nat_pid_to_str): Constify.
8547 * linux-tdep.c (linux_core_pid_to_str): Constify.
8548 * linux-thread-db.c (thread_db_pid_to_str)
8549 (thread_db_extra_thread_info): Constify.
8550 * nto-tdep.c (nto_extra_thread_info): Constify.
8551 * nto-tdep.h (nto_extra_thread_info): Constify.
8552 * obsd-nat.c (obsd_pid_to_str): Constify.
8553 * procfs.c (procfs_pid_to_str): Constify.
8554 * ravenscar-thread.c (ravenscar_extra_thread_info)
8555 (ravenscar_pid_to_str): Constify.
8556 * remote-sim.c (gdbsim_pid_to_str): Constify.
8557 * remote.c (remote_threads_extra_info, remote_pid_to_str):
8558 Constify.
8559 * sol-thread.c (solaris_pid_to_str): Constify.
8560 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
8561 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
8562 * target.c (default_pid_to_str, target_pid_to_str)
8563 (normal_pid_to_str, default_pid_to_str): Constify.
8564 * target.h (target_ops::to_pid_to_str)
8565 (target_ops::to_extra_thread_info): Constify.
8566 (target_pid_to_str, normal_pid_to_str): Constify.
8567 * windows-nat.c (windows_pid_to_str): Constify.
8568 * gdbarch.sh (core_pid_to_str): Constify.
8569 * target-delegates.c: Regenerate.
8570 * gdbarch.h, gdbarch.c: Regenerate.
8571
69bbf465
PA
85722017-04-05 Pedro Alves <palves@redhat.com>
8573
8574 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
8575 the memory of the temporary warning_pre_print override.
8576 * utils.c (warning_pre_print): Constify.
8577 * utils.h (warning_pre_print): Constify.
8578
be47f9e8
PA
85792017-04-05 Pedro Alves <palves@redhat.com>
8580
8581 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
8582 (shell_command): New function.
8583 (make_command): Use std::string.
8584 (init_cli_cmds): Register shell_command instead of shell_escape.
8585
bde6261a
PA
85862017-04-05 Pedro Alves <palves@redhat.com>
8587
8588 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
8589 * tracepoint.c (default_collect): Don't initialize.
8590
b38ef47f
PA
85912017-04-05 Pedro Alves <palves@redhat.com>
8592
8593 * macroexp.c (macro_buffer::shared): Now a bool.
8594 (init_buffer): Update.
8595 (init_shared_buffer): Constify 'addr' parameter.
8596 (substitute_args, expand, macro_expand, macro_expand_next): Remove
8597 casts.
8598
f995bbe8
PA
85992017-04-05 Pedro Alves <palves@redhat.com>
8600
8601 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
8602 * disasm.c (set_disassembler_options): Constify local.
8603 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
8604
4a596fe2
SDJ
86052017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
8606
8607 PR gdb/21352
8608 * tracefile.c (tsave_command): Fix argument parsing for '-r'
8609 option.
8610
2cad08ea
YQ
86112017-04-05 Yao Qi <yao.qi@linaro.org>
8612
8613 * frame.c (frame_unwind_register_unsigned): Call
8614 frame_unwind_register_value.
8615
55a98976
YQ
86162017-04-05 Yao Qi <yao.qi@linaro.org>
8617
8618 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
8619 Use gdb_test_multiple, and don't match anchor.
8620
4ac40124
PA
86212017-04-05 Pedro Alves <palves@redhat.com>
8622
8623 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
8624 (Write After Approval): Remove Simon Marchi.
8625
c053b654
PA
86262017-04-05 Pedro Alves <palves@redhat.com>
8627
8628 * common/gdb_optional.h (optional::optional): Make constexpr and
8629 initialize m_dummy.
8630
4c7bf4f9
JB
86312017-04-04 John Baldwin <jhb@FreeBSD.org>
8632
8633 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8634 (amd64fbsd_jmp_buf_reg_offset): Remove.
8635 (amd64fbsd_supply_uthread): Remove function.
8636 (amd64fbsd_collect_uthread): Remove function.
8637 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
8638 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
8639 (x86_64-*-freebsd*): Remove bsd-uthread.o.
8640 (fbsd-nat.c): Update comment.
8641 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
8642 (i386fbsd_jmp_buf_reg_offset): Remove.
8643 (i386fbsd_supply_uthread): Remove function.
8644 (i386fbsd_collect_uthread): Remove function.
8645 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
8646
1e1a8bef
JB
86472017-04-04 John Baldwin <jhb@FreeBSD.org>
8648
8649 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
8650 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
8651 * NEWS: Mention that support for FreeBSD/alpha was removed.
8652 * alpha-fbsd-tdep.c: Delete file.
8653 * config/alpha/fbsd.mh: Delete file.
8654 * configure.host: Delete alpha*-*-freebsd* and
8655 alpha*-*-kfreebsd*-gnu.
8656 * configure.tgt: Delete alpha*-*-freebsd* and
8657 alpha*-*-kfreebsd*-gnu.
8658
49907934
JB
86592017-04-04 John Baldwin <jhb@FreeBSD.org>
8660
8661 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
8662 amd64bsd_store_inferior_registers): Use ptid from regcache.
8663
6f77053d
PA
86642017-04-04 Pedro Alves <palves@redhat.com>
8665
8666 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
8667 data fields, make them private and add "m_" prefixes.
8668 (lnp_state_machine::lnp_state_machine): New ctor.
8669 (record_line, check_line_address, handle_set_discriminator)
8670 (handle_set_address, handle_advance_pc, handle_special_opcode)
8671 (handle_advance_line, handle_set_file, handle_negate_stmt)
8672 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
8673 (end_sequence, advance_line): New methods.
8674 (m_gdbarch, m_record_lines_p): New fields.
8675 (lnp_reader_state): Delete.
8676 (dwarf_record_line): Rename to ...
8677 (lnp_state_machine::record_line): ... adjust.
8678 (init_lnp_state_machine): Delete.
8679 (lnp_state_machine::lnp_state_machine): New.
8680 (check_line_address): Rename to ...
8681 (lnp_state_machine::check_line_address): This.
8682 (dwarf_decode_lines_1): Remove reference to "reader_state".
8683 Adjust lnp_state_machine having a non-default ctor. Use bool.
8684 State machine internal state manipulation moved to
8685 lnp_state_machine methods.
8686
9c541725
PA
86872017-04-04 Pedro Alves <palves@redhat.com>
8688
8689 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8690 unittests/offset-type-selftests.c.
8691 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
8692 * common/offset-type.h: New file.
8693 * common/preprocessor.h: New file.
8694 * common/traits.h: New file.
8695 * common/valid-expr.h: New file.
8696 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
8697 sect_offset and cu_offset strong typedefs throughout.
8698 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
8699 typedefs throughout.
8700 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
8701 sect_offset and cu_offset strong typedefs throughout.
8702 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
8703 typedefs throughout.
8704 * gdbtypes.h: Include "common/offset-type.h".
8705 (cu_offset): Now an offset type (strong typedef) instead of a
8706 struct.
8707 (sect_offset): Likewise.
8708 (union call_site_parameter_u): Rename "param_offset" field to
8709 "param_cu_off".
8710 * unittests/offset-type-selftests.c: New file.
8711
ecfb656c
PA
87122017-04-04 Pedro Alves <palves@redhat.com>
8713
8714 * common/underlying.h: New file.
8715 * dwarf2read.c: Include "common/gdb_optional.h" and
8716 "common/underlying.h".
8717 (dir_index, file_name_index): New types.
8718 (file_entry): Use them.
8719 (file_entry::include): Use to_underlying.
8720 (line_header::add_file_name): Use dir_index.
8721 (read_formatted_entries): Use gdb::optional. Read form before
8722 writting to file_entry.
8723 (dwarf_decode_line_header): Use dir_index.
8724 (lnp_state_machine::current_file): Use to_underlying.
8725 (lnp_state_machine::file): Change type to file_name_index.
8726 (dwarf_record_line): Use to_underlying.
8727 (init_lnp_state_machine): Use file_name_index.
8728 (dwarf_decode_lines_1): Use dir_index and file_name_index.
8729
d194f1fe
PA
87302017-04-04 Pedro Alves <palves@redhat.com>
8731
8732 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
8733 operator bool, has_value and get methods.
8734
fff8551c
PA
87352017-04-04 Pedro Alves <palves@redhat.com>
8736
8737 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
8738 fields.
8739 (line_header): Initialize all data fields. Change type of
8740 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
8741 Change type of include_dirs to std::vector<const char *>. Remove
8742 num_include_dirs, include_dirs_size. Change type of file_names to
8743 std::vector<file_entry>. Remove num_file_names, file_names_size.
8744 (line_header::line_header): New.
8745 (line_header::add_include_dir, line_header::add_file_name): New
8746 methods.
8747 (line_header::include_dir_at): Remove NULL check.
8748 (line_header::file_name_at): Add const overload.
8749 (line_header_up): New unique_ptr typedef.
8750 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
8751 std::vector. Remove free_line_header call.
8752 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
8753 free_line_header call.
8754 (free_cu_line_header): Delete.
8755 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
8756 (setup_type_unit_groups): Use line_header_up instead of cleanups.
8757 Adjust to use std::vector.
8758 (free_line_header): Delete.
8759 (free_line_header_voidp): Use delete.
8760 (add_include_dir): Replace with ...
8761 (line_header::add_include_dir): ... this method. Use std::vector.
8762 (add_file_name): Replace with ...
8763 (line_header::add_file_name): ... this method. Use std::vector.
8764 (add_include_dir_stub): Delete.
8765 (read_formatted_entries): Remove memset.
8766 (dwarf_decode_line_header): Return a line_header_up instead of a
8767 raw pointer. Remove cleanup handling. Pass lambdas to
8768 read_formatted_entries. Adjust to use line_header methods.
8769 (dwarf_decode_lines_1): Adjust to use line_header methods.
8770 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
8771 use std::vector.
8772
d62a8ae2
SM
87732017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
8774
8775 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
8776 instead of struct ptid.
8777
db3a1dc7
AH
87782017-05-04 Alan Hayward <alan.hayward@arm.com>
8779
8780 * frame.c (get_frame_register_bytes): Unwind using value.
8781 (put_frame_register_bytes): Likewise.
8782
b1b45502
IB
87832017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
8784
8785 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
8786 aggregate-like.
8787
ec13808e
JK
87882017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
8789
8790 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
8791
12316564
YQ
87922017-03-29 Yao Qi <yao.qi@linaro.org>
8793
8794 * gdbthread.h (struct thread_info): Declare constructor and
8795 destructor. Add some in-class member initializers.
8796 * thread.c (free_thread): Remove.
8797 (init_thread_list): Call delete instead of free_thread.
8798 (new_thread): Call thread_info constructor.
8799 (thread_info::thread_info): New function.
8800 (thread_info::~thread_info): New function.
8801 (delete_thread_1): Call delete instead of free_thread.
8802 (make_cleanup_restore_current_thread): Move tp and frame to
8803 inner block.
8804
fe5f7374
AK
88052017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8806
8807 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
8808 (arc_skip_prologue): Likewise.
8809 (arc_make_frame_cache): Likewise.
8810 (arc_pv_get_operand): New function.
8811 (arc_is_in_prologue): Likewise.
8812 (arc_analyze_prologue): Likewise.
8813 (arc_print_frame_cache): Likewise.
8814 (MAX_PROLOGUE_LENGTH): New constant.
8815
eea78757
AK
88162017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8817
8818 * configure.tgt: Add arc-insn.o.
8819 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
8820 (dump_arc_instruction_command): New function.
8821 (arc_fprintf_disasm): Likewise.
8822 (arc_disassemble_info): Likewise.
8823 (arc_insn_get_operand_value): Likewise.
8824 (arc_insn_get_operand_value_signed): Likewise.
8825 (arc_insn_get_memory_base_reg): Likewise.
8826 (arc_insn_get_memory_offset): Likewise.
8827 (arc_insn_get_branch_target): Likewise.
8828 (arc_insn_dump): Likewise.
8829 (arc_insn_get_linear_next_pc): Likewise.
8830 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
8831 (arc_disassemble_info): Likewise.
8832 (arc_insn_get_branch_target): Likewise.
8833 (arc_insn_get_linear_next_pc): Likewise.
8834 * NEWS: Mention new "maint print arc arc-instruction".
8835
3be78afd
AK
88362017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8837
8838 * arc-tdep (maintenance_print_arc_list): New variable.
8839 (maintenance_print_arc_command): New function.
8840
296ec4fa
AK
88412017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
8842
8843 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
8844 Add "limm" and "reserved".
8845 (arc_cannot_fetch_register, arc_cannot_store_register): Add
8846 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
8847 * arc-tdep.h (arc_regnum): Likewise.
8848
f74f865e
MF
88492017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8850
8851 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
8852 for THREADPTR register.
8853 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
8854 register.
8855 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
8856 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
8857 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
8858
0d0bf81a
MF
88592017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8860
8861 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
8862 registers above gdbarch_num_regs (gdbarch) as privileged in
8863 call0 ABI.
8864
0ce4291e
MF
88652017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8866
8867 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
8868 for a single specified register or for all registers in
8869 a0_base..a0_base + C0_NREGS range.
8870 (supply_gregset_reg): Call regcache_raw_supply for a single
8871 specified register or for all registers in a0_base..a0_base +
8872 C0_NREGS range.
8873
c56054f9
MF
88742017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8875
8876 * arch/xtensa.h (C0_NREGS): Add definition.
8877 * xtensa-tdep.c (C0_NREGS): Remove definition.
8878
a4398628
MF
88792017-03-27 Max Filippov <jcmvbkbc@gmail.com>
8880
8881 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
8882 Drop xtensa_default_isa initialization.
8883 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
8884
8c43009f
PA
88852017-03-27 Pedro Alves <palves@redhat.com>
8886
8887 * dwarf2read.c (file_entry) <dir_index>: Add comment.
8888 (file_entry::include_dir): New method.
8889 (line_header::include_dir_at, line_header::file_name_at): New
8890 methods.
8891 (setup_type_unit_groups, setup_type_unit_groups)
8892 (psymtab_include_file_name): Simplify using the new methods.
8893 (lnp_state_machine) <the_line_header>: New field.
8894 <file>: Add comment.
8895 (lnp_state_machine::current_file): New method.
8896 (dwarf_record_line): Simplify using the new methods.
8897 (init_lnp_state_machine): Initialize the "the_line_header" field.
8898 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
8899 Simplify using the new methods.
8900
a7e80b9e
PA
89012017-03-27 Pedro Alves <palves@redhat.com>
8902
8903 * cp-name-parser.y (make_empty): Delete.
8904 (demangler_special, nested_name, ptr_operator, array_indicator)
8905 (direct_declarator, declarator_1): Use fill_comp instead of
8906 make_empty.
8907
21047726
PA
89082017-03-27 Pedro Alves <palves@redhat.com>
8909
8910 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
8911 to ATTRIBUTE_PRINTF.
8912 * solib-target.c (library_list_start_list): Print "string" not
8913 "version".
8914 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
8915 gdb_xml_error call.
8916
d721ba37
PA
89172017-03-27 Pedro Alves <palves@redhat.com>
8918
8919 * dwarf2read.c (struct file_and_directory): New.
8920 (dwarf2_get_dwz_file): Adjust to use std::string.
8921 (dw2_get_file_names_reader): Adjust to use file_and_directory.
8922 (find_file_and_directory): Adjust to return a file_and_directory
8923 object.
8924 (read_file_scope): Adjust to use file_and_directory. Remove
8925 make_cleanup/do_cleanups calls.
8926 (open_and_init_dwp_file): Adjust to use std::string. Remove
8927 make_cleanup/do_cleanups calls.
8928 * python/python.c (do_start_initialization): Adjust to ldirname
8929 returning a std::string.
8930 * utils.c (ldirname): Now returns a std::string.
8931 * utils.h (ldirname): Change return type to std::string.
8932 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
8933 returning a std::string.
8934 * xml-tdesc.c (file_read_description_xml): Likewise.
8935
ed771251
AH
89362017-03-24 Alan Hayward <alan.hayward@arm.com>
8937
8938 * regcache.c (regcache_debug_print_register): New function.
8939 * regcache.h (regcache_debug_print_register): New declaration.
8940 * target.c (debug_print_register): Remove.
8941 (target_fetch_registers): Call regcache_debug_print_register.
8942 (target_store_registers): Likewise.
8943
568c1b9f
PB
89442017-03-24 Pádraig Brady <pbrady@fb.com>
8945
8946 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
8947 reference beyond the 'lh->include_dirs' array before accessing to
8948 it.
8949 (psymtab_include_file_name): Likewise.
8950 (dwarf_decode_lines_1): Likewise.
8951 (dwarf_decode_lines): Likewise.
8952 (file_file_name): Likewise.
8953
3e00d44f
SM
89542017-03-23 Simon Marchi <simon.marchi@ericsson.com>
8955
8956 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
8957 inferior_ptid.
8958 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8959 ps_lsetfpregs): Likewise.
8960 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
8961 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
8962 ps_lsetfpregs): Likewise.
8963 * target.c (target_fetch_registers, target_store_registers):
8964 Remove asserts.
8965
077ae656
AH
89662017-03-23 Alan Hayward <alan.hayward@arm.com>
8967
8968 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
8969
1e2b521d
YQ
89702017-03-23 Yao Qi <yao.qi@linaro.org>
8971
8972 * aarch64-tdep.c (aarch64_process_record_test): Declare.
8973 (_initialize_aarch64_tdep): Register it.
8974 (aarch64_record_load_store): Handle PRFM instruction.
8975 (aarch64_process_record_test): New function.
8976
33877125
YQ
89772017-03-23 Yao Qi <yao.qi@linaro.org>
8978
8979 * aarch64-tdep.c (aarch64_record_load_store): Fix code
8980 indentation.
8981
a0eef940
YQ
89822017-03-23 Yao Qi <yao.qi@linaro.org>
8983
8984 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
8985
3f2a3564
PR
89862017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
8987
8988 python/python.c (do_start_initialization): Fix memory leak.
8989
b67aeab0
SM
89902017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8991
8992 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
8993 using get_ptrace_pid.
8994 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
8995 inferior_ptid.
8996 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
8997 inferior_ptid instead of pid.
8998
ffdbe864
YQ
89992017-03-22 Yao Qi <yao.qi@linaro.org>
9000
9001 * aarch64-tdep.c: Wrap locally used classes in anonymous
9002 namespace.
9003 * arm-tdep.c: Likewise.
9004 * linespec.c: Likewise.
9005 * ui-out.c: Likewise.
9006
9d736fbf
JG
90072017-03-22 Jonah Graham <jonah@kichwacoders.com>
9008
9009 PR gdb/19637
9010 * python/lib/gdb/printer/bound_registers.py: Import sys.
9011
3de88e9a
SM
90122017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9013
9014 * windows-nat.c (do_windows_fetch_inferior_registers): Add
9015 windows_thread_info parameter and use it instead of
9016 current_thread.
9017 (windows_fetch_inferior_registers): Don't set current_thread,
9018 pass the thread to do_windows_fetch_inferior_registers. Use
9019 ptid from regcache instead of inferior_ptid.
9020 (do_windows_store_inferior_registers): Add windows_thread_info
9021 parameter and use it instead of current_thread.
9022 (windows_store_inferior_registers): Don't set current_thread,
9023 pass the thread to do_windows_store_inferior_registers. Use
9024 ptid from regcache instead of inferior_ptid.
9025
0e7b8f61
SM
90262017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9027
9028 * ser-mingw.c (ser_windows_raw): Remove reference to
9029 struct serial::current_timeout.
9030
5badf10a
IR
90312017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
9032
9033 PR tdep/20928
9034 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
9035 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
9036 (sparc64_fsr_type): Fix %fsr decoding.
9037
cee59b3f
TW
90382017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
9039
9040 * python/py-record-btrace.c (btpy_insn_data): Change return type
9041 for Python 2.
9042
639a9038
SM
90432017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9044
9045 * spu-linux-nat.c (spu_fetch_inferior_registers,
9046 spu_store_inferior_registers): Use ptid from regcache, set and
9047 restore inferior_ptid.
9048 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
9049 Likewise.
9050
bcc0c096
SM
90512017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9052
9053 * i386-linux-nat.c (fetch_register, store_register,
9054 i386_linux_fetch_inferior_registers,
9055 i386_linux_store_inferior_registers): Use ptid from regcache.
9056 * ia64-linux-nat.c (ia64_linux_fetch_register,
9057 ia64_linux_store_register): Likewise.
9058 * inf-ptrace.c (inf_ptrace_fetch_register,
9059 inf_ptrace_store_register): Likewise.
9060 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
9061 m32r_linux_store_inferior_registers): Likewise.
9062 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
9063 m68kbsd_store_inferior_registers): Likewise.
9064 * m68k-linux-nat.c (fetch_register, store_register,
9065 m68k_linux_fetch_inferior_registers,
9066 m68k_linux_store_inferior_registers): Likewise.
9067 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
9068 m88kbsd_store_inferior_registers): Likewise.
9069 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
9070 mips_fbsd_store_inferior_registers): Likewise.
9071 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
9072 mips64_linux_regsets_store_registers): Likewise.
9073 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
9074 mipsnbsd_store_inferior_registers): Likewise.
9075 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
9076 mips64obsd_store_inferior_registers): Likewise.
9077 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
9078 Likewise.
9079 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
9080 ppcfbsd_store_inferior_registers): Likewise.
9081 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
9082 ppc_linux_store_inferior_registers): Likewise.
9083 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
9084 ppcnbsd_store_inferior_registers): Likewise.
9085 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
9086 ppcobsd_store_registers): Likewise.
9087 * procfs.c (procfs_fetch_registers, procfs_store_registers):
9088 Likewise.
9089 * ravenscar-thread.c (ravenscar_fetch_registers,
9090 ravenscar_store_registers, ravenscar_prepare_to_store):
9091 Likewise.
9092 * record-btrace.c (record_btrace_fetch_registers,
9093 record_btrace_store_registers, record_btrace_prepare_to_store):
9094 Likewise.
9095 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
9096 Lookup inferior using ptid from regcache, instead of
9097 current_inferior.
9098 * remote.c (remote_fetch_registers, remote_store_registers): Use
9099 ptid from regcache.
9100 * rs6000-nat.c (fetch_register, store_register): Likewise.
9101 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
9102 s390_linux_store_inferior_registers): Likewise.
9103 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
9104 shnbsd_store_inferior_registers): Likewise.
9105 * sol-thread.c (sol_thread_fetch_registers,
9106 sol_thread_store_registers): Likewise.
9107 * sparc-nat.c (sparc_fetch_inferior_registers,
9108 sparc_store_inferior_registers): Likewise.
9109 * tilegx-linux-nat.c (fetch_inferior_registers,
9110 store_inferior_registers): Likewise.
9111 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
9112 vaxbsd_store_inferior_registers): Likewise.
9113 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
9114 store_xtregs): Likewise.
9115
c0f55cc6
AV
91162017-03-20 Artemiy Volkov <artemiyv@acm.org>
9117
9118 PR gdb/14441
9119 * NEWS: Mention support for rvalue references in GDB and python.
9120 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
9121 supports both lvalue and rvalue references.
9122
15c0a2a9
AV
91232017-03-20 Artemiy Volkov <artemiyv@acm.org>
9124
9125 PR gdb/14441
9126 * gdbtypes.c (rank_one_type): Implement overloading
9127 resolution rules regarding rvalue references.
9128
aa006118
AV
91292017-03-20 Artemiy Volkov <artemiyv@acm.org>
9130
9131 PR gdb/14441
9132 * aarch64-tdep.c (aarch64_type_align)
9133 (aarch64_extract_return_value, aarch64_store_return_value): Change
9134 lvalue reference type checks to general reference type checks.
9135 * amd64-tdep.c (amd64_classify): Likewise.
9136 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
9137 Likewise.
9138 * arm-tdep.c (arm_type_align, arm_extract_return_value)
9139 (arm_store_return_value): Likewise.
9140 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
9141 * c-typeprint.c (c_print_type): Likewise.
9142 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
9143 (cplus_number_of_children, cplus_describe_child): Likewise.
9144 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
9145 * completer.c (expression_completer): Likewise.
9146 * cp-support.c (make_symbol_overload_list_adl_namespace):
9147 Likewise.
9148 * darwin-nat-info.c (info_mach_region_command): Likewise.
9149 * dwarf2loc.c (entry_data_value_coerce_ref)
9150 (value_of_dwarf_reg_entry): Likewise.
9151 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
9152 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
9153 Likewise.
9154 * findvar.c (extract_typed_address, store_typed_address):
9155 Likewise.
9156 * gdbtypes.c (rank_one_type): Likewise.
9157 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
9158 * infcall.c (value_arg_coerce): Likewise.
9159 * language.c (pointer_type): Likewise.
9160 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
9161 Likewise.
9162 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
9163 * mn10300-tdep.c (mn10300_type_align): Likewise.
9164 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
9165 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
9166 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
9167 Likewise.
9168 * printcmd.c (print_formatted, x_command): Likewise.
9169 * python/py-type.c (typy_get_composite, typy_template_argument):
9170 Likewise.
9171 * python/py-value.c (valpy_referenced_value)
9172 (valpy_get_dynamic_type, value_has_field): Likewise.
9173 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
9174 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
9175 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
9176 * spu-tdep.c (spu_scalar_value_p): Likewise.
9177 * symtab.c (lookup_symbol_aux): Likewise.
9178 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9179 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9180 Likewise.
9181 * valops.c (value_cast_pointers, value_cast)
9182 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9183 (value_struct_elt, value_struct_elt_bitpos)
9184 (value_find_oload_method_list, find_overload_match)
9185 (value_rtti_indirect_type): Likewise.
9186 * valprint.c (val_print_scalar_type_p, generic_val_print):
9187 Likewise.
9188 * value.c (value_actual_type, value_as_address, unpack_long)
9189 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9190 (coerce_ref): Likewise.
9191 * varobj.c (varobj_get_value_type): Likewise.
9192
3fcf899d
AV
91932017-03-20 Artemiy Volkov <artemiyv@acm.org>
9194
9195 PR gdb/14441
9196 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9197 table of constants.
9198 * python/lib/gdb/command/explore.py: Support exploring values
9199 of rvalue reference types.
9200 * python/lib/gdb/types.py: Implement get_basic_type() for
9201 rvalue reference types.
9202 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9203 constant.
9204 * python/py-value.c (valpy_getitem): Add an rvalue reference
9205 check.
9206 (valpy_reference_value): Add new parameter "refcode".
9207 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9208 New wrappers for valpy_reference_value().
9209 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9210 (gdbpy_invoke_xmethod): Likewise.
9211
4297a3f0
AV
92122017-03-20 Artemiy Volkov <artemiyv@acm.org>
9213
9214 PR gdb/14441
9215 * dwarf2read.c (process_die, read_type_die_1): Handle the
9216 DW_TAG_rvalue_reference_type DIE.
9217 (read_tag_reference_type): Add new parameter "refcode".
9218
e1cb3213
AV
92192017-03-20 Artemiy Volkov <artemiyv@acm.org>
9220
9221 PR gdb/14441
9222 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9223 (c_type_print_modifier, c_type_print_varspec_suffix)
9224 (c_type_print_base): Support printing rvalue reference types.
9225 * c-valprint.c (c_val_print, c_value_print): Support printing
9226 rvalue reference values.
9227
e4347c89
AV
92282017-03-20 Artemiy Volkov <artemiyv@acm.org>
9229
9230 PR gdb/14441
9231 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9232 typename.
9233 * cp-support.c (replace_typedefs): Handle
9234 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9235 * python/py-type.c (typy_lookup_type): Likewise.
9236
53cc15f5
AV
92372017-03-20 Artemiy Volkov <artemiyv@acm.org>
9238
9239 PR gdb/14441
9240 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9241 * parse.c (insert_type): Change assert statement.
9242 (follow_types): Handle rvalue reference types.
9243 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9244 constant.
9245
a65cfae5
AV
92462017-03-20 Artemiy Volkov <artemiyv@acm.org>
9247
9248 PR gdb/14441
9249 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9250 value_ref() interface.
9251 * c-valprint.c (c_value_print): Likewise.
9252 * infcall.c (value_arg_coerce): Likewise.
9253 * python/py-value.c (valpy_reference_value): Likewise.
9254 * valops.c (value_cast, value_reinterpret_cast)
9255 (value_dynamic_cast, typecmp): Likewise.
9256 (value_ref): Parameterize by kind of return value reference type.
9257 * value.h (value_ref): Add new parameter "refcode".
9258
3b224330
AV
92592017-03-20 Artemiy Volkov <artemiyv@acm.org>
9260
9261 PR gdb/14441
9262 * dwarf2read.c (read_tag_reference_type): Use
9263 lookup_lvalue_reference_type() instead of lookup_reference_type().
9264 * eval.c (evaluate_subexp_standard): Likewise.
9265 * f-exp.y: Likewise.
9266 * gdbtypes.c (make_reference_type, lookup_reference_type):
9267 Generalize with rvalue reference types.
9268 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9269 convenience wrappers for lookup_reference_type().
9270 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9271 reference kind parameter.
9272 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9273 wrappers for lookup_reference_type().
9274 * guile/scm-type.c (gdbscm_type_reference): Use
9275 lookup_lvalue_reference_type() instead of lookup_reference_type().
9276 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9277 * parse.c (follow_types): Likewise.
9278 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9279 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9280 Likewise.
9281 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9282 (gdbpy_invoke_xmethod): Likewise.
9283 * stabsread.c: Provide extra argument to make_reference_type()
9284 call.
9285 * valops.c (value_ref, value_rtti_indirect_type): Use
9286 lookup_lvalue_reference_type() instead of lookup_reference_type().
9287
f9aeb8d4
AV
92882017-03-20 Artemiy Volkov <artemiyv@acm.org>
9289
9290 PR gdb/14441
9291 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9292 (TYPE_IS_REFERENCE): New macro.
9293 (struct type): Add rvalue_reference_type field.
9294 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9295
51457a05
MAL
92962017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9297
9298 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9299 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9300 New function definition.
9301 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9302 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9303 New function declaration.
9304 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9305 * mi/mi-interp.h: New file.
9306 * solib.c (info_sharedlibrary_command): Replace for loop with
9307 ALL_SO_LIBS macro
9308 * solib.h (update_solib_list): New function declaration.
9309 (so_list_head): Move macro.
9310 * solist.h (ALL_SO_LIBS): New macro.
9311
e696b3ad
MAL
93122017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9313
9314 * infcmd.c (post_create_inferior): Remove unused argument in
9315 call to solib_add.
9316 * remote.c (remote_start_remote): Likewise.
9317 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9318 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9319 (enable_break): Likewise.
9320 * solib.c (update_solib_list): Remove unused target argument
9321 and its documentation.
9322 (solib_add): Remove unused target argument. Remove unused
9323 argument in call to update_solib_list.
9324 (info_sharedlibrary_command): Remove unused argument in call
9325 to update_solib_list.
9326 (sharedlibrary_command): Remove unused argument in call to
9327 solib_add.
9328 (handle_solib_event): Likewise.
9329 (reload_shared_libraries): Likewise.
9330 * solib.h (solib_add): Remove unused target argument.
9331
dcb84eda
AA
93322017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9333
9334 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9335 (s390_displaced_step_fixup): Cover relative branches with the
9336 default fixup handling. This fixes lack of support for some
9337 relative branch instructions.
9338
d9cb6cdc
SM
93392017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9340
9341 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9342 ptid from regcache.
9343
1afaf9f4
SM
93442017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9345
9346 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9347 i386_darwin_store_inferior_registers): Use ptid from regcache.
9348
aac12e24
SM
93492017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9350
9351 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9352 i386bsd_store_inferior_registers): Use ptid from regcache.
9353
bbe1eef1
SM
93542017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9355
9356 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9357 hppaobsd_store_registers): Use ptid from regcache.
9358
10799020
SM
93592017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9360
9361 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9362 hppanbsd_store_registers): Use ptid from regcache.
9363
00204cf7
SM
93642017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9365
9366 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9367 from regcache. Use get_ptrace_pid.
9368
11a33714
SM
93692017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9370
9371 * corelow.c (get_core_register_section): Use ptid from regcache,
9372 update doc.
9373
317cd492
SM
93742017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9375
9376 * bsd-uthread.c (bsd_uthread_fetch_registers,
9377 bsd_uthread_store_registers): Use ptid from regcache, set and
9378 restore inferior_ptid.
9379
9ac8a7c2
SM
93802017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9381
9382 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9383 fetch_fp_regs, store_register, store_regs, store_fp_register,
9384 store_fp_regs): Use ptid from regcache.
9385
4ac4bb6a
SM
93862017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9387
9388 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9389 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9390 store_vfp_regs): Use ptid from regcache.
9391
9bcbdca8
PA
93922017-03-17 Pedro Alves <palves@redhat.com>
9393
9394 PR remote/21188
9395 * ser-base.c (ser_base_wait_for): Add comment.
9396 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9397 version.
9398 * ser-unix.c (hardwire_raw): Remove reference to
9399 scb->current_timeout.
9400 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9401 (hardwire_ops): Install ser_base_readchar instead of
9402 hardwire_readchar.
9403 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9404 Remove fields.
9405
7503099f
JG
94062017-03-17 Jonah Graham <jonah@kichwacoders.com>
9407
9408 PR gdb/19637
9409 * python/lib/gdb/printer/bound_registers.py: Add support for
9410 Python 3.
9411
7942e96e
AA
94122017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9413
9414 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9415 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9416 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9417 byte_offset to subobj_byte_offset. Fix the handling of
9418 DWARF_VALUE_STACK on big-endian targets when coming via an
9419 implicit pointer.
9420 (dwarf2_evaluate_loc_desc): Adjust call to
9421 dwarf2_evaluate_loc_desc_full.
9422 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9423 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9424
ba14f379
YQ
94252017-03-16 Yao Qi <yao.qi@linaro.org>
9426
9427 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9428 and REVSH instructions.
9429
b121eeb9
YQ
94302017-03-16 Yao Qi <yao.qi@linaro.org>
9431
9432 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9433 (arm_record_test): Declare.
9434 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9435 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9436 align with the manual.
9437 (thumb_record_misc): Adjust the code order to align with the
9438 manual.
9439 (thumb2_record_decode_insn_handler): Fix instruction matching.
9440 (instruction_reader_thumb): New class.
9441 (arm_record_test): New function.
9442
728a7913
YQ
94432017-03-16 Yao Qi <yao.qi@linaro.org>
9444
9445 * arm-tdep.c (abstract_memory_reader): New class.
9446 (instruction_reader): New class.
9447 (extract_arm_insn): Add argument 'reader'. Callers updated.
9448 (decode_insn): Likewise.
9449
34b43320
DE
94502017-03-16 Doug Evans <dje@google.com>
9451
a7c0469f
DE
9452 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9453 member. Change type of TYPE member to SCM. All uses updated.
9454 (lsscm_make_lazy_string_smob): Add assert.
9455 (lsscm_make_lazy_string): Flag bad length values.
9456 (lsscm_elt_type): New function.
9457 (gdbscm_lazy_string_to_value): Rewrite to use
9458 lsscm_safe_lazy_string_to_value.
9459 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
9460 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
9461 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
9462 in incoming type.
9463 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9464 * guile/scm-type.c (tyscm_scm_to_type): New function.
9465
94662017-03-15 Doug Evans <dje@google.com>
9467
34b43320
DE
9468 PR python/17728, python/18439, python/18779
9469 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
9470 member. Change type of TYPE member to PyObject *. All uses updated.
9471 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
9472 (gdbpy_create_lazy_string_object): Flag bad length values.
9473 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
9474 Handle typedefs in incoming type.
9475 (stpy_lazy_string_elt_type): New function.
9476 (gdbpy_extract_lazy_string): Call it.
9477 * python/py-value.c (valpy_lazy_string): Flag bad length values.
9478 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
9479 typedefs in incoming type.
9480
a3a5fecc
DE
94812017-03-16 Doug Evans <dje@google.com>
9482
9483 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9484 * guile/scm-type.c (tyscm_scm_to_type): New function.
9485
28f1c605
JW
94862017-03-16 Jiong Wang <jiong.wang@arm.com>
9487
9488 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
9489 "ULONGEST" for "skip".
9490
87c336f6
AA
94912017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9492
9493 PR gdb/21220
9494 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
9495 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
9496 (inf_ptrace_peek_poke): ...here. New function. Now also loop
9497 over ptrace peek/poke until end of buffer or error.
9498
cf81cf60
SM
94992017-03-14 Simon Marchi <simon.marchi@ericsson.com>
9500
9501 * parse.c (length_of_subexp): Make static.
9502 * parser-defs.h (length_of_subexp): Remove.
9503
a379284a
AA
95042017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9505
9506 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
9507 as well.
9508
8a6200ba
PA
95092017-03-14 Pedro Alves <palves@redhat.com>
9510
9511 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
9512 (main): Use std::unique_ptr. Remove calls to
9513 cp_demangled_name_parse_free.
9514
f79ec206
SM
95152017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9516
9517 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
9518 alphabsd_store_inferior_registers): Use regcache->ptid instead
9519 of inferior_ptid.
9520
edb5fb00
SM
95212017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9522
9523 * aix-thread.c (aix_thread_fetch_registers,
9524 aix_thread_store_registers): Use regcache->ptid instead of
9525 inferior_ptid.
9526
55119686
SM
95272017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9528
9529 * aarch64-linux-nat.c (fetch_gregs_from_thread,
9530 store_gregs_to_thread, fetch_fpregs_from_thread,
9531 store_fpregs_to_thread): Use regcache->ptid instead of
9532 inferior_ptid.
9533
6a06fbb7
SM
95342017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9535
9536 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
9537 amd64_linux_fetch_inferior_registers): Use regcache->ptid
9538 instead of inferior_ptid.
9539
c6386875
SM
95402017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9541
9542 * target.c (target_fetch_registers, target_store_registers): Add
9543 assert.
9544
ddaaf0fb
SM
95452017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9546
9547 * regcache.h (regcache_get_ptid): New function.
9548 * regcache.c (regcache_get_ptid): New function.
9549
b9da89d1 95502017-03-13 Mark Wielaard <mark@klomp.org>
9551
9552 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
9553
5f4d1085
KS
95542017-03-10 Keith Seitz <keiths@redhat.com>
9555
9556 PR c++/8218
9557 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
9558
c65d6b55
PA
95592017-03-08 Pedro Alves <palves@redhat.com>
9560
9561 PR gdb/18360
9562 * infrun.c (start_step_over, do_target_resume, resume)
9563 (restart_threads): Assert we're not resuming a thread that is
9564 meant to be stopped.
9565 (infrun_thread_stop_requested_callback): Delete.
9566 (infrun_thread_stop_requested): If the thread is internally
9567 stopped, queue a pending stop event and clear the thread's
9568 inline-frame state.
9569 (handle_stop_requested): New function.
9570 (handle_syscall_event, handle_inferior_event_1): Use
9571 handle_stop_requested.
9572 (handle_stop_requested): New function.
9573 (handle_signal_stop): Set the thread's stop_signal here instead of
9574 at caller.
9575 (finish_step_over): Clear step over info unconditionally.
9576 (handle_signal_stop): If the user had interrupted the event
9577 thread, consider the stop a random signal.
9578 (handle_signal_stop) <signal arrived while stepping over
9579 breakpoint>: Don't restart threads here.
9580 (stop_waiting): Don't clear step-over info here.
9581
15c22686
PA
95822017-03-08 Pedro Alves <palves@redhat.com>
9583
9584 PR 21206
9585 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
9586 goes to argument 2, not 1.
9587
6e5d74e7
PA
95882017-03-08 Pedro Alves <palves@redhat.com>
9589
9590 PR cli/21218
9591 * top.c (gdb_readline_wrapper): Avoid passing NULL to
9592 display_gdb_prompt.
9593 (command_line_input): Add comment.
9594
9753a2f6
PA
95952017-03-08 Pedro Alves <palves@redhat.com>
9596
9597 PR tui/21216
9598 * tui/tui-file.c (tui_file::write): New.
9599 * tui/tui-file.h (tui_file): Override "write".
9600 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
9601 factored out from ...
9602 (tui_puts): ... here.
9603 (tui_putc): Use them.
9604 (tui_write): New function.
9605 * tui/tui-io.h (tui_write): Declare.
9606
1672e0d9
SDJ
96072017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
9608
9609 * Makefile.in (SFILES): Replace "environ.c" with
9610 "common/environ.c".
9611 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
9612 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
9613 to...
9614 * common/environ.c: ... here.
9615 * environ.h: Moved to...
9616 * common/environ.h: ... here.
9617
f7bb4e3a
PB
96182017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9619
9620 * gdbarch.sh (pstring_ptr): New static function.
9621 (gdbarch_disassembler_options): Use it.
9622 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
9623 not valid_disassembler_option->name.
9624 * gdbarch.c: Regenerate.
9625
e45ced6c
PB
96262017-03-07 Peter Bergner <bergner@vnet.ibm.com>
9627
9628 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
9629
5f6fd321
PA
96302017-03-07 Pedro Alves <palves@redhat.com>
9631
9632 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
9633
6dbb839a 96342017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
9635
9636 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
9637 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
9638 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 9639 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 9640
d274ecf4
SM
96412017-03-06 Simon Marchi <simon.marchi@ericsson.com>
9642
9643 * xtensa-linux-nat.c (fetch_gregs): Remove const.
9644
df97be55
SM
96452017-03-03 Simon Marchi <simon.marchi@ericsson.com>
9646
9647 * remote.c (remote_add_target_side_commands): Use range-based
9648 for loop.
9649
7d45f3df
YQ
96502017-03-03 Yao Qi <yao.qi@linaro.org>
9651
9652 PR gdb/21165
9653 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
9654 value is lazy.
9655 * valprint.c (common_val_print): Likewise.
9656
65b48a81
PB
96572017-02-28 Peter Bergner <bergner@vnet.ibm.com>
9658
9659 * NEWS: Mention new set/show disassembler-options commands.
9660 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
9661 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
9662 (prospective_options): New static variable.
9663 (gdb_disassembler::gdb_disassembler): Initialize
9664 m_di.disassembler_options.
9665 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
9666 (get_disassembler_options): New function.
9667 (set_disassembler_options): Likewise.
9668 (set_disassembler_options_sfunc): Likewise.
9669 (show_disassembler_options_sfunc): Likewise.
9670 (disassembler_options_completer): Likewise.
9671 (_initialize_disasm): Likewise.
9672 * disasm.h (get_disassembler_options): New prototype.
9673 (set_disassembler_options): Likewise.
9674 * gdbarch.sh (gdbarch_disassembler_options): New variable.
9675 (gdbarch_verify_disassembler_options): Likewise.
9676 * gdbarch.c: Regenerate.
9677 * gdbarch.h: Likewise.
9678 * arm-tdep.c (num_disassembly_options): Delete.
9679 (set_disassembly_style): Likewise.
9680 (arm_disassembler_options): New static variable.
9681 (set_disassembly_style_sfunc): Convert short style name into long
9682 option name. Call set_disassembler_options.
9683 (show_disassembly_style_sfunc): New function.
9684 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
9685 set_gdbarch_verify_disassembler_options.
9686 (_initialize_arm_tdep): Delete regnames variable and update callers.
9687 (arm_disassembler_options): Initialize.
9688 (disasm_options): New variable.
9689 (num_disassembly_options): Rename from this...
9690 (num_disassembly_styles): ...to this. Compute by scanning through
9691 disasm_options.
9692 (valid_disassembly_styles): Initialize using disasm_options.
9693 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
9694 set_arm_regname_option.
9695 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
9696 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
9697 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
9698 set_gdbarch_verify_disassembler_options.
9699 * s390-tdep.c (s390_disassembler_options): New static variable.
9700 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
9701 set_gdbarch_verify_disassembler_options.
9702
d538e36d
SM
97032017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9704
9705 * remote.c (remote_add_target_side_condition): Remove "struct"
9706 keyword from range-based for loop.
9707
83621223
SM
97082017-02-27 Simon Marchi <simon.marchi@ericsson.com>
9709
9710 * remote.c (remote_add_target_side_condition): Use range-based
9711 for loop. Update comment.
9712
2123df0e
YQ
97132017-02-27 Yao Qi <yao.qi@linaro.org>
9714
9715 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
9716
8e368124
AH
97172017-02-26 Alan Hayward <alan.hayward@arm.com>
9718
9719 * regcache.c (regcache_raw_update): New function.
9720 (regcache_raw_read): Move code to regcache_raw_update.
9721 * regcache.h (regcache_raw_update): New declaration.
9722 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
9723
a49dd8dd
JK
97242017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
9725
9726 * dwarf2read.c (create_debug_type_hash_table): Initialize
9727 header.signature and header.type_offset_in_tu.
9728
34e4bae9
PA
97292017-02-24 Pedro Alves <palves@redhat.com>
9730
9731 * symtab.c (make_file_symbol_completion_list_1): Use
9732 add_symtab_completions.
9733
b0e4b369
AH
97342017-02-24 Alan Hayward <alan.hayward@arm.com>
9735
9736 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
9737
975c21ab
AH
97382017-02-24 Alan Hayward <alan.hayward@arm.com>
9739
9740 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
9741 I386_MAX_REGISTER_SIZE.
9742 (i386_pseudo_register_write): Likewise.
9743 (i386_process_record): Likewise.
9744 * i387-tdep.c (i387_supply_xsave): Likewise.
9745 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
9746 (store_register): Likewise.
9747
14bc53a8
PA
97482017-02-23 Pedro Alves <palves@redhat.com>
9749
9750 * ada-lang.c: Include "common/function-view.h".
9751 (ada_iterate_over_symbols): Adjust to use function_view as
9752 callback type.
9753 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
9754 (ada_make_symbol_completion_list): Use a lambda.
9755 (ada_exc_search_name_matches): Delete.
9756 (name_matches_regex): New.
9757 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
9758 * compile/compile-c-support.c: Include "common/function-view.h".
9759 (print_one_macro): Change prototype to accept a ui_file pointer.
9760 (write_macro_definitions): Use a lambda.
9761 * dwarf2read.c: Include "common/function-view.h".
9762 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
9763 (dw2_expand_symtabs_matching): Adjust to use function_view as
9764 callback type.
9765 * language.h: Include "common/function-view.h".
9766 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
9767 function_view as callback type.
9768 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
9769 * linespec.c: Include "common/function-view.h".
9770 (collect_info::add_symbol): New method.
9771 (struct symbol_and_data_callback, iterate_inline_only, struct
9772 symbol_matcher_data, iterate_name_matcher): Delete.
9773 (iterate_over_all_matching_symtabs): Adjust to use function_view
9774 as callback type and lambdas.
9775 (iterate_over_file_blocks): Adjust to use function_view as
9776 callback type.
9777 (decode_compound_collector): Now a class with private fields.
9778 (decode_compound_collector::release_symbols): New method.
9779 (collect_one_symbol): Rename to...
9780 (decode_compound_collector::operator()): ... this and adjust.
9781 (lookup_prefix_sym): decode_compound_collector construction bits
9782 move to decode_compound_collector ctor. Pass the
9783 decode_compound_collector object directly as callback. Remove
9784 cleanups and use decode_compound_collector::release_symbols
9785 instead.
9786 (symtab_collector): Now a class with private fields.
9787 (symtab_collector::release_symtabs): New method.
9788 (add_symtabs_to_list): Rename to...
9789 (symtab_collector::operator()): ... this and adjust.
9790 (collect_symtabs_from_filename): symtab_collector construction
9791 bits move to symtab_collector ctor. Pass the symtab_collector
9792 object directly as callback. Remove cleanups and use
9793 symtab_collector::release_symtabs instead.
9794 (collect_symbols): Delete.
9795 (add_matching_symbols_to_info): Use lambdas.
9796 * macrocmd.c (print_macro_callback): Delete.
9797 (info_macro_command): Use a lambda.
9798 (info_macros_command): Pass print_macro_definition as callable
9799 directly.
9800 (print_one_macro): Remove 'ignore' parameter.
9801 (macro_list_command): Adjust.
9802 * macrotab.c (macro_for_each_data::fn): Now a function_view.
9803 (macro_for_each_data::user_data): Delete field.
9804 (foreach_macro): Adjust to call the function_view.
9805 (macro_for_each): Adjust to use function_view as callback type.
9806 (foreach_macro_in_scope): Adjust to call the function_view.
9807 (macro_for_each_in_scope): Adjust to use function_view as callback
9808 type.
9809 * macrotab.h: Include "common/function-view.h".
9810 (macro_callback_fn): Declare a prototype instead of a pointer.
9811 Remove "user_data" parameter.
9812 (macro_for_each, macro_for_each_in_scope): Adjust to use
9813 function_view as callback type.
9814 * psymtab.c (partial_map_expand_apply)
9815 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
9816 Adjust to use function_view as callback type and to return bool.
9817 (psym_expand_symtabs_matching): Adjust to use function_view as
9818 callback types.
9819 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
9820 to use function_view as callback type and to return bool.
9821 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
9822 callback types.
9823 * symfile.c (expand_symtabs_matching): Adjust to use function_view
9824 as callback types.
9825 * symfile.h: Include "common/function-view.h".
9826 (expand_symtabs_file_matcher_ftype)
9827 (expand_symtabs_symbol_matcher_ftype)
9828 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
9829 return bool.
9830 (quick_symbol_functions::map_symtabs_matching_filename)
9831 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
9832 function_view as callback type and return bool.
9833 (expand_symtabs_matching): Adjust to use function_view as callback
9834 type.
9835 (maintenance_expand_name_matcher)
9836 (maintenance_expand_file_matcher): Delete.
9837 (maintenance_expand_symtabs): Use lambdas.
9838 * symtab.c (iterate_over_some_symtabs): Adjust to use
9839 function_view as callback types and return bool.
9840 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
9841 of a cleanup.
9842 (lookup_symtab_callback): Delete.
9843 (lookup_symtab): Use a lambda.
9844 (iterate_over_symbols): Adjust to use function_view as callback
9845 type.
9846 (struct search_symbols_data, search_symbols_file_matches)
9847 (search_symbols_name_matches): Delete.
9848 (search_symbols): Use a pair of lambdas.
9849 (struct add_name_data, add_macro_name, symbol_completion_matcher)
9850 (symtab_expansion_callback): Delete.
9851 (default_make_symbol_completion_list_break_on_1): Use lambdas.
9852 * symtab.h: Include "common/function-view.h".
9853 (iterate_over_some_symtabs): Adjust to use function_view as
9854 callback type and return bool.
9855 (iterate_over_symtabs): Adjust to use function_view as callback
9856 type.
9857 (symbol_found_callback_ftype): Remove 'data' parameter and return
9858 bool.
9859 (iterate_over_symbols): Adjust to use function_view as callback
9860 type.
9861
07e253aa
PA
98622017-02-23 Pedro Alves <palves@redhat.com>
9863
9864 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
9865 (%.o) <unittests/%.c>: New pattern.
9866 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
9867 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
9868 * common/function-view.h: New file.
9869 * unittests/function-view-selftests.c: New file.
9870 * configure: Regenerate.
9871
8eaf5320
SM
98722017-02-23 Simon Marchi <simon.marchi@ericsson.com>
9873
9874 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
9875 inferior_ptid.
9876 * go32-nat.c (go32_thread_alive): Likewise.
9877
38768751
YQ
98782017-02-23 Yao Qi <yao.qi@linaro.org>
9879
9880 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
9881 delete.
9882
0a8beaba
YQ
98832017-02-23 Yao Qi <yao.qi@linaro.org>
9884
9885 * varobj.c (varobj_clear_saved_item): Use delete instead of
9886 xfree.
9887 (update_dynamic_varobj_children): Likewise.
9888
58fdfd2c
JK
98892017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9890
9891 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
9892
1b90b139
SM
98932017-02-21 Simon Marchi <simon.marchi@ericsson.com>
9894
9895 * common/enum-flags.h (enum_flags::enum_flags): Initialize
9896 m_enum_value to 0 in default constructor.
9897
2039d74e
EBM
98982017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
9899
9900 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
9901 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
9902 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
9903 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
9904 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
9905 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
9906 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
9907 IS_STORE_CONDITIONAL_INSN.
9908
7814882a
JK
99092017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
9910
9911 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
9912
0ae60b63
JK
99132017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9914
9915 * NEWS (Changes since GDB 7.12): Add DWARF-5.
9916
0224619f
JK
99172017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9918
9919 * dwarf2read.c (skip_one_die, read_attribute_value)
9920 (dwarf2_const_value_attr, dump_die_shallow)
9921 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
9922 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
9923
0af92d60
JK
99242017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9925
9926 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
9927 (dwarf_parse_macro_header): Accept DWARF version 5.
9928 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
9929
216f72a1
JK
99302017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9931
9932 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
9933 DW_AT_GNU_*.
9934 * common/common-exceptions.h (enum errors): Likewise.
9935 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
9936 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
9937 (dwarf_expr_context::execute_stack_op): Likewise.
9938 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
9939 Likewise.
9940 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
9941 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
9942 (show_entry_values_debug, call_site_to_target_addr)
9943 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
9944 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
9945 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
9946 (value_of_dwarf_block_entry, indirect_pieced_value)
9947 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
9948 (disassemble_dwarf_expression): Likewise.
9949 * dwarf2read.c (process_die, inherit_abstract_dies)
9950 (read_call_site_scope): Likewise.
9951 * gdbtypes.h (struct func_type, struct call_site_parameter)
9952 (struct call_site): Likewise.
9953 * stack.c (read_frame_arg): Likewise.
9954 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
9955
43988095
JK
99562017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
9957
9958 * defs.h (read_unsigned_leb128): New declaration.
9959 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
9960 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
9961 (dwarf2_find_location_expression): Call also
9962 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
9963 * dwarf2loc.h (dwarf2_version): New declaration.
9964 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
9965 rnglists.
9966 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
9967 .debug_rnglists.
9968 (struct dwop_section_names): Add loclists_dwo.
9969 (dwop_section_names): Add .debug_loclists.dwo.
9970 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
9971 (struct dwarf2_per_cu_data): Add dwarf_version.
9972 (struct dwo_sections): Add loclists.
9973 (struct attr_abbrev): Add implicit_const.
9974 (read_indirect_line_string): New declaration.
9975 (read_unsigned_leb128): Delete declaration.
9976 (rcuh_kind): New definition.
9977 (read_and_check_comp_unit_head): Change parameter
9978 is_debug_types_section to section_kind.
9979 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
9980 (read_comp_unit_head): Change parameter abfd to section, add parameter
9981 section_kind. Handle DWARF-5.
9982 (error_check_comp_unit_head): Accept also DWARF version 5.
9983 (read_and_check_comp_unit_head): Change parameter
9984 is_debug_types_section to section_kind.
9985 (read_and_check_type_unit_head): Delete function.
9986 (read_abbrev_offset): Handle DWARF-5.
9987 (create_debug_type_hash_table): Add parameter section_kind. Process
9988 only DW_UT_type. Use signature and type_offset_in_tu from struct
9989 comp_unit_head.
9990 (create_debug_types_hash_table): Update create_debug_type_hash_table
9991 caller.
9992 (create_all_type_units): Call create_debug_type_hash_table.
9993 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
9994 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
9995 caller.
9996 (skip_one_die): Handle DW_FORM_implicit_const.
9997 (dwarf2_rnglists_process): New function.
9998 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
9999 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
10000 (read_attribute_value): Handle DW_FORM_implicit_const,
10001 DW_FORM_line_strp.
10002 (read_attribute): Handle DW_FORM_implicit_const.
10003 (read_indirect_string_at_offset_from): New function from
10004 read_indirect_string_at_offset.
10005 (read_indirect_string_at_offset): Call
10006 read_indirect_string_at_offset_from.
10007 (read_indirect_line_string_at_offset): New function.
10008 (read_indirect_string): New function comment.
10009 (read_indirect_line_string): New function.
10010 (read_unsigned_leb128): Make it global.
10011 (dwarf2_string_attr): Handle DWARF-5.
10012 (add_include_dir_stub, read_formatted_entries): New functions.
10013 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
10014 Handle DWARF-5.
10015 (per_cu_header_read_in): Update read_comp_unit_head caller.
10016 (dwarf2_version): New function.
10017 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
10018 rnglists.
10019 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
10020 fields.
10021
22d2f3ab
JK
100222017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10023
10024 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
10025
5f46c5a5
JK
100262017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10027
10028 * dwarf2read.c (dwarf2_ranges_process): New function from
10029 dwarf2_ranges_read.
10030 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
10031 dwarf2_ranges_process.
10032
78d4d2c5
JK
100332017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10034
10035 * dwarf2read.c (create_debug_type_hash_table): New function from
10036 create_debug_types_hash_table.
10037 (create_debug_types_hash_table): Call create_debug_type_hash_table.
10038 (create_all_type_units, open_and_init_dwo_file): Update
10039 create_debug_types_hash_table callers.
10040
1b076f25
SDJ
100412017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10042
10043 PR gdb/16188
10044 * fork-child.c (trace_start_error): Fix thinko. va_end should
10045 refer to 'ap', not 'args'.
10046
0db8980c
SDJ
100472017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10048 Pedro Alves <palves@redhat.com>
10049
10050 PR gdb/16188
10051 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
10052 calls succeeded.
10053 * fork-child.c (trace_start_error): New function.
10054 (trace_start_error_with_name): Likewise.
10055 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
10056 * inf-ptrace.c (inf_ptrace_me): Likewise.
10057 * inferior.h (trace_start_error): New prototype.
10058 (trace_start_error_with_name): Likewise.
10059
99e8a4f9
SDJ
100602017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
10061
10062 PR gdb/21164
10063 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
10064 NULL before using it.
10065 * symmisc.c (maintenance_print_symbols): Likewise.
10066 (maintenance_print_msymbols): Likewise.
10067
4e746bb6
TW
100682017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10069
10070 * NEWS: Add record Python bindings entry.
10071
100722017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10073
10074 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
10075 py-record-full.o.
10076 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
10077 * python/py-record-btrace.c, python/py-record-btrace.h,
10078 python/py-record-full.c, python/py-record-full.h: New file.
10079 * python/py-record.c: Add include for py-record-btrace.h and
10080 py-record-full.h.
10081 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
10082 recpy_instruction_history, recpy_function_call_history, recpy_begin,
10083 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
10084 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
10085 New definition.
10086 (gdbpy_initialize_btrace): New export.
10087 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
10088
100892017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10090
10091 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
10092 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
10093 * python/py-record.c: New file.
10094 * python/python-internal.h (gdbpy_start_recording,
10095 gdbpy_current_recording, gdpy_stop_recording,
10096 gdbpy_initialize_record): New export.
10097 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
10098 (python_GdbMethods): Add gdbpy_start_recording,
10099 gdbpy_current_recording and gdbpy_stop_recording.
10100
101012017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10102
10103 * record-btrace.c (record_btrace_record_method): New function.
10104 (init_record_btrace_ops): Initialize to_record_method.
10105 * record-full.c (record_full_record_method): New function.
10106 (init_record_full_ops, init_record_full_core_ops): Add
10107 record_full_record_method.
10108 * record.h (enum record_method): New enum.
10109 * target-debug.h (target_debug_print_enum_record_method: New define.
10110 * target-delegates.c: Regenerate.
10111 * target.c (target_record_method): New function.
10112 * target.h: Include record.h.
10113 (struct target_ops) <to_record_method>: New field.
10114 (target_record_method): New export.
10115
101162017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10117
10118 * record.h (record_start, record_stop): New export.
10119 * record.c (record_start, record_stop): New function.
10120
101212017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10122
10123 * btrace.c (btrace_fetch): Copy function call segments pointer
10124 into a vector.
10125 (btrace_clear): Clear the vector.
10126 (btrace_find_insn_by_number): Use binary search to find the correct
10127 function call segment.
10128 * btrace.h (brace_fun_p): New typedef.
10129 (struct btrace_thread_info) <functions>: New field.
10130
101312017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10132
10133 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
10134 * btrace.c (btrace_decode_error): ... here. New function.
10135 * btrace.h (btrace_decode_error): New export.
10136
101372017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10138
10139 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
10140 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
10141 btrace_find_insn_by_number): Remove special case for gaps.
10142 * btrace.h (btrace_insn_get_error): New export.
10143 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
10144 * record-btrace.c (btrace_insn_history): Print number for gaps.
10145 (record_btrace_info, record_btrace_goto): Handle gaps.
10146
3f77c769
TT
101472017-02-14 Tom Tromey <tom@tromey.com>
10148
10149 PR python/13598:
10150 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
10151 event.
10152 * python/py-evts.c (gdbpy_initialize_py_events): Add
10153 before_prompt registry.
10154 * python/py-events.h (events_object) <before_prompt>: New field.
10155
4c2c7ac6
MM
101562017-02-14 Markus Metzger <markus.t.metzger@intel.com>
10157
10158 * btrace.c (ftrace_new_switch): Preserve up link and flags.
10159
5cf30ebf
LM
101602017-02-13 Luis Machado <lgustavo@codesourcery.com>
10161
10162 * symfile (_initialize_symfile): Add usage text to the load command's
10163 help text.
10164
26a06916
SM
101652017-02-10 Simon Marchi <simon.marchi@ericsson.com>
10166
10167 * utils.c (defaulted_query): Don't query on secondary UIs.
10168
0b145e37
TT
101692017-02-10 Tom Tromey <tom@tromey.com>
10170
10171 * rust-lang.c (rust_get_disr_info): Remove unused variable.
10172
2d8365c4
TT
101732017-02-10 Tom Tromey <tom@tromey.com>
10174
10175 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
10176 "cleanup" local.
10177 * python/py-type.c (typy_legacy_template_argument): Remove
10178 unnecessary "cleanup" local.
10179
2bb8f231
TT
101802017-02-10 Tom Tromey <tom@tromey.com>
10181
10182 * python/python.c (do_start_initialization): New function, from
10183 _initialize_python.
10184 (_initialize_python): Call do_start_initialization.
10185 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10186 goto.
10187
1bdfaf42
TT
101882017-02-10 Tom Tromey <tom@tromey.com>
10189
10190 * python/py-prettyprint.c (pretty_print_one_value): Use
10191 gdbpy_ref.
10192
88b6faea
TT
101932017-02-10 Tom Tromey <tom@tromey.com>
10194
10195 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10196 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10197 gdbpy_ref.
10198 * python/py-type.c (field_new): Use gdbpy_ref.
10199 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10200 gdbpy_ref.
10201 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10202 (py_free_pspace): Likewise.
10203 (pspace_to_pspace_object): Likewise.
10204 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10205 (py_free_objfile): Likewise.
10206 (objfile_to_objfile_object): Likewise.
10207 * python/py-inferior.c (delete_thread_object): Use
10208 gdbpy_ref.
10209 (infpy_read_memory): Likewise.
10210 (py_free_inferior): Likewise.
10211 * python/py-evtregistry.c (create_eventregistry_object): Use
10212 gdbpy_ref.
10213 * python/py-event.c (create_event_object): Use gdbpy_ref.
10214
7780f186
TT
102152017-02-10 Tom Tromey <tom@tromey.com>
10216
10217 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10218 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10219 used.
10220 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10221 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10222 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10223 python/py-framefilter.c, python/py-function.c,
10224 python/py-inferior.c, python/py-infevents.c,
10225 python/py-linetable.c, python/py-newobjfileevent.c,
10226 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10227 python/py-signalevent.c, python/py-stopevent.c,
10228 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10229 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10230 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10231 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10232
d4b0bb18
TT
102332017-02-10 Tom Tromey <tom@tromey.com>
10234
10235 * ui-out.h (ui_out_emit_type): New class.
10236 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10237 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10238 and ui_out_emit_tuple.
10239 (enumerate_locals): Likewise.
10240 (py_mi_print_variables, py_print_locals, py_print_args): Use
10241 ui_out_emit_list.
10242 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10243 ui_out_emit_list.
10244 * common/gdb_optional.h: New file.
10245
f67f945c
MG
102462017-02-10 Martin Galvan <martingalvan@sourceware.org>
10247
10248 * MAINTAINERS (Write After Approval): Update my e-mail address.
10249
18da0c51
MG
102502017-02-10 Martin Galvan <martingalvan@sourceware.org>
10251
10252 PR gdb/21122
10253 * breakpoint.c (_initialize_breakpoint): Update the help description
10254 of the 'commands' command to indicate that it takes a list argument.
10255
62c14536
SM
102562017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10257
10258 * interps.c (current_interp_set_logging): Remove "return".
10259
ff6fa247
GB
102602017-02-09 Gary Benson <gbenson@redhat.com>
10261
10262 * symtab.c (add_symtab_completions): Prevent NULL pointer
10263 dereference.
10264
a474bd8e
PA
102652017-02-08 Pedro Alves <palves@redhat.com>
10266
10267 * interps.c (interp::interp): Remove reference to quiet_p.
10268 (interp_set): Make static. Remove dead "Switching to" output
10269 code.
10270 (interp_quiet_p, interp_set_quiet): Delete.
10271 (interpreter_exec_cmd): Don't set the interpreter quiet.
10272 * interps.h (interp_quiet_p): Make static.
10273 (class interp) <quiet_p>: Remove field
10274
3d7b173c
JG
102752017-02-08 Jerome Guitton <guitton@adacore.com>
10276
604c4576
JG
10277 * cli/cli-decode.c (find_command_name_length): Make it extern.
10278 * cli/cli-decode.h (find_command_name_length): Declare.
10279 * cli/cli-script.c (command_name_equals, line_first_arg):
10280 New functions.
10281 (process_next_line): Use cli-decode to parse command names.
10282 (build_command_line): Make args a constant pointer.
10283
102842017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 10285
3d7b173c
JG
10286 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10287 Remove case-insensitive search.
10288
1291063d
JM
102892017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10290
10291 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10292 at the end of the line. Avoids an ARI warning.
10293
20b477a7
LM
102942017-02-06 Luis Machado <lgustavo@codesourcery.com>
10295
10296 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10297 rdseed instructions.
10298 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10299
3f7b46f2
IR
103002017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10301
10302 PR tdep/20936
10303 Provide and use sparc32 and sparc64 target description XML files.
10304 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10305 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10306 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10307 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10308 * features/sparc/sparc32-solaris.xml: New file.
10309 * features/sparc/sparc64-solaris.xml: New file.
10310 * features/sparc/sparc32-solaris.c: Generated.
10311 * features/sparc/sparc64-solaris.c: Generated.
10312 * sparc-tdep.h: Account for differences in target descriptions.
10313 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10314 (sparc32_register_type): Use target provided registers.
10315 (validate_tdesc_registers): New function.
10316 (sparc32_gdbarch_init): Use tdesc_has_registers.
10317 Set pseudoregister functions.
10318 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10319 (sparc64_register_type): Use target provided registers.
10320 (sparc64_init_abi): Set pseudoregister functions.
10321
f0fd41c1
TT
103222017-02-03 Tom Tromey <tom@tromey.com>
10323
10324 PR rust/21097:
10325 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10326 with a single member.
10327
d6f9b0fb
PA
103282017-02-03 Pedro Alves <palves@redhat.com>
10329
10330 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10331 (cli_interp_base::~cli_interp_base): New.
10332 (cli_interp): New struct.
10333 (as_cli_interp): Cast the interp itself to cli_interp.
10334 (cli_interpreter_pre_command_loop): Rename to ...
10335 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10336 parameter.
10337 (cli_interpreter_init): Rename to ...
10338 (cli_interp::init): ... this. Remove 'self' parameter. Use
10339 boolean. Make extern.
10340 (cli_interpreter_resume): Rename to ...
10341 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10342 extern.
10343 (cli_interpreter_suspend): Rename to ...
10344 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10345 extern.
10346 (cli_interpreter_exec): Rename to ...
10347 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10348 extern.
10349 (cli_interpreter_supports_command_editing): Rename to ...
10350 (cli_interp_base::supports_command_editing): ... this. Remove
10351 'interp' parameter. Make extern.
10352 (cli_ui_out): Rename to ...
10353 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10354 Make extern.
10355 (cli_set_logging): Rename to ...
10356 (cli_interp_base::set_logging): ... this. Remove 'interp'
10357 parameter. Make extern.
10358 (cli_interp_procs): Delete.
10359 (cli_interp_factory): Adjust to use "new".
10360 * cli/cli-interp.h: Include "interps.h".
10361 (struct cli_interp_base): New struct.
10362 * interps.c (struct interp): Delete. Fields moved to interps.h.
10363 (interp_new): Delete.
10364 (interp::interp, interp::~interp): New.
10365 (interp_set): Use bool, and return void. Assume the interpreter
10366 has suspend, init and resume methods, and that the all return
10367 void.
10368 (set_top_level_interpreter): interp_set returns void.
10369 (interp_ui_out): Adapt.
10370 (current_interp_set_logging): Adapt.
10371 (interp_data): Delete.
10372 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10373 (interp_exec): Adapt.
10374 (top_level_interpreter_data): Delete.
10375 * interps.h (interp_init_ftype, interp_resume_ftype)
10376 (interp_suspend_ftype, interp_exec_ftype)
10377 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10378 (class interp): New.
10379 (interp_new): Delete.
10380 (interp_set): Now returns void. Use bool.
10381 (interp_data, top_level_interpreter_data): Delete.
10382 * mi/mi-common.h: Include interps.h.
10383 (class mi_interp): Inherit from interp. Define a ctor. Declare
10384 init, resume, suspect, exec, interp_ui_out, set_logging and
10385 pre_command_loop methods.
10386 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10387 (mi_interpreter_init): Rename to ...
10388 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10389 bool, return void and make extern. Adjust.
10390 (mi_interpreter_resume): ... Rename to ...
10391 (mi_interp::resume): ... this. Remove the 'data' parameter,
10392 return void and make extern. Adjust.
10393 (mi_interpreter_suspend): ... Rename to ...
10394 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10395 return void and make extern. Adjust.
10396 (mi_interpreter_exec): ... Rename to ...
10397 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10398 extern. Adjust.
10399 (mi_interpreter_pre_command_loop): ... Rename to ...
10400 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10401 parameter and make extern.
10402 (mi_on_normal_stop_1): Adjust.
10403 (mi_ui_out): Rename to ...
10404 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10405 parameter and make extern. Adjust.
10406 (mi_set_logging): Rename to ...
10407 (mi_interp::set_logging): ... this. Remove the 'interp'
10408 parameter and make extern. Adjust.
10409 (mi_interp_procs): Delete.
10410 (mi_interp_factory): Adjust to use 'new'.
10411 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10412 (mi_print_exception, mi_execute_command, mi_load_progress):
10413 Adjust.
10414 * tui/tui-interp.c (tui_interp): New class.
10415 (as_tui_interp): Return a tui_interp pointer.
10416 (tui_on_normal_stop, tui_on_signal_received)
10417 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10418 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10419 to use interp::interp_ui_out.
10420 (tui_init): Rename to ...
10421 (tui_interp::init): ... this. Remove the 'self' parameter, use
10422 bool, return void and make extern. Adjust.
10423 (tui_resume): Rename to ...
10424 (tui_interp::resume): ... this. Remove the 'data' parameter,
10425 return void and make extern. Adjust.
10426 (tui_suspend): Rename to ...
10427 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10428 return void and make extern. Adjust.
10429 (tui_ui_out): Rename to ...
10430 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10431 parameter, and make extern. Adjust.
10432 (tui_exec): Rename to ...
10433 (tui_interp::exec): ... this. Remove the 'data' parameter and
10434 make extern.
10435 (tui_interp_procs): Delete.
10436 (tui_interp_factory): Use "new".
10437
65c40c95
TT
104382017-02-02 Tom Tromey <tom@tromey.com>
10439
10440 * rust-exp.y (ends_raw_string, space_then_number)
10441 (rust_identifier_start_p): Return bool.
10442 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10443 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10444 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10445 (rust_chartype_p): Return bool.
10446 (val_print_struct, rust_print_struct_def, rust_print_type):
10447 Update.
10448 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10449 Return bool.
10450
b50f188d
TT
104512017-02-02 Tom Tromey <tom@tromey.com>
10452
10453 * rust-lang.c: Reindent.
10454
03c85b11
TT
104552017-02-02 Tom Tromey <tom@tromey.com>
10456
10457 * rust-lang.h (rust_crate_for_block): Update.
10458 * rust-lang.c (rust_crate_for_block): Return std::string.
10459 (rust_get_disr_info): Use std:;string, not
10460 gdb::unique_xmalloc_ptr.
10461 * rust-exp.y (crate_name): Update.
10462
9b6da501
PA
104632017-02-02 Pedro Alves <palves@redhat.com>
10464
10465 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
10466 field out of gdb_disassembler_test and make it static.
10467
ec4cb20b
PA
104682017-02-02 Pedro Alves <palves@redhat.com>
10469
10470 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
10471 mi1_interp and mi_interp fields.
10472
5be5dbf0
PA
104732017-02-02 Pedro Alves <palves@redhat.com>
10474
616268b6
PA
10475 * cli/cli-interp.c (struct saved_output_files, saved_output):
10476 Moved from cli/cli-logging.c.
10477 (cli_set_logging): New function.
10478 (cli_interp_procs): Install cli_set_logging.
10479 * cli/cli-interp.h (make_logging_output, cli_set_logging):
10480 Declare.
10481 * cli/cli-logging.c (struct saved_output_files, saved_output):
10482 Moved to cli/cli-interp.c.
10483 (pop_output_files): Don't save outputs here.
10484 (make_logging_output): New function.
10485 (handle_redirections): Don't build tee nor save previous outputs
10486 here.
10487 * interps.c (current_interp_set_logging): Change prototype.
10488 Assume there's always a set_logging_proc method installed.
10489 * interps.h (interp_set_logging_ftype): Change prototype.
10490 (current_interp_set_logging): Change prototype and adjust comment.
10491 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
10492 use make_logging_output.
10493 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
104942017-02-02 Pedro Alves <palves@redhat.com>
10495
5be5dbf0
PA
10496 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
10497 from ...
10498 (set_logging_overwrite): ... here.
10499 (logging_no_redirect_file): Delete.
10500 (set_logging_redirect): Don't handle redirection on the fly.
10501 Instead warn that "logging off" / "logging on" is necessary.
10502 (pop_output_files): Delete references to logging_no_redirect_file.
10503 (show_logging_command): Always speak in terms of what will happen
10504 once logging is reenabled.
10505
c99cc448
PA
105062017-02-02 Pedro Alves <palves@redhat.com>
10507
10508 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
10509
8b172ce7
PA
105102017-02-02 Pedro Alves <palves@redhat.com>
10511
10512 * disasm.c (gdb_pretty_print_insn): Rename to ...
10513 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
10514 Remove gdbarch parameter. Adapt to clear the object's buffers
10515 instead of allocating new buffers, and to print using the object's
10516 gdb_disassembler instead of calling gdb_print_insn.
10517 (dump_insns): Use gdb_pretty_print_disassembler.
10518 * disasm.h (gdb_pretty_print_insn): Delete declaration.
10519 (gdb_pretty_print_disassembler): New class.
10520 * record-btrace.c (btrace_insn_history): Use
10521 gdb_pretty_print_disassembler.
10522
d7e74731
PA
105232017-02-02 Pedro Alves <palves@redhat.com>
10524
10525 * ada-lang.c (type_as_string): Use string_file.
10526 * ada-valprint.c (ada_print_floating): Use string_file.
10527 * ada-varobj.c (ada_varobj_scalar_image)
10528 (ada_varobj_get_value_image): Use string_file.
10529 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
10530 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
10531 * breakpoint.c (update_inserted_breakpoint_locations)
10532 (insert_breakpoint_locations, reattach_breakpoints)
10533 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
10534 (print_it_watchpoint): Use string_file.
10535 (save_breakpoints): Use stdio_file.
10536 * c-exp.y (oper): Use string_file.
10537 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
10538 tee_file.
10539 (pop_output_files): Use delete.
10540 (handle_redirections): Use stdio_file and tee_file.
10541 * cli/cli-setshow.c (do_show_command): Use string_file.
10542 * compile/compile-c-support.c (c_compute_program): Use
10543 string_file.
10544 * compile/compile-c-symbols.c (generate_vla_size): Take a
10545 'string_file &' instead of a 'ui_file *'.
10546 (generate_c_for_for_one_variable): Take a 'string_file &' instead
10547 of a 'ui_file *'. Use string_file.
10548 (generate_c_for_variable_locations): Take a 'string_file &'
10549 instead of a 'ui_file *'.
10550 * compile/compile-internal.h (generate_c_for_for_one_variable):
10551 Take a 'string_file &' instead of a 'ui_file *'.
10552 * compile/compile-loc2c.c (push, pushf, unary, binary)
10553 (print_label, pushf_register_address, pushf_register)
10554 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
10555 'ui_file *'. Adjust.
10556 * compile/compile.c (compile_to_object): Use string_file.
10557 * compile/compile.h (compile_dwarf_expr_to_c)
10558 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
10559 'ui_file *'.
10560 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
10561 (replace_typedefs_qualified_name): Use string_file and
10562 obstack_copy0.
10563 * disasm.c (gdb_pretty_print_insn): Use string_file.
10564 (gdb_disassembly): Adjust reference the null_stream global.
10565 (do_ui_file_delete): Delete.
10566 (gdb_insn_length): Use null_stream.
10567 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
10568 * dwarf2loc.c (dwarf2_compile_property_to_c)
10569 (locexpr_generate_c_location, loclist_generate_c_location): Take a
10570 'string_file &' instead of a 'ui_file *'.
10571 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
10572 * dwarf2read.c (do_ui_file_peek_last): Delete.
10573 (dwarf2_compute_name): Use string_file.
10574 * event-top.c (gdb_setup_readline): Use stdio_file.
10575 * gdbarch.sh (verify_gdbarch): Use string_file.
10576 * gdbtypes.c (safe_parse_type): Use null_stream.
10577 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
10578 string_file.
10579 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
10580 'string_file *' instead of a 'ui_file *'.
10581 (gdbscm_arch_disassemble): Use string_file.
10582 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
10583 * guile/scm-ports.c (class ioscm_file_port): Now a class that
10584 inherits from ui_file.
10585 (ioscm_file_port_delete, ioscm_file_port_rewind)
10586 (ioscm_file_port_put): Delete.
10587 (ioscm_file_port_write): Rename to ...
10588 (ioscm_file_port::write): ... this. Remove file_port_magic
10589 checks.
10590 (ioscm_file_port_new): Delete.
10591 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
10592 ui_file_up.
10593 * guile/scm-type.c (tyscm_type_name): Use string_file.
10594 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
10595 Use string_file.
10596 * infcmd.c (print_return_value_1): Use string_file.
10597 * infrun.c (print_target_wait_results): Use string_file.
10598 * language.c (add_language): Use string_file.
10599 * location.c (explicit_to_string_internal): Use string_file.
10600 * main.c (captured_main_1): Use null_file.
10601 * maint.c (maintenance_print_architecture): Use stdio_file.
10602 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
10603 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
10604 event_channel>: Change type to mi_console_file pointer.
10605 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
10606 (mi_console_file_delete): Delete.
10607 (struct mi_console_file): Delete.
10608 (mi_console_file_magic): Delete.
10609 (mi_console_file_new): Delete.
10610 (mi_console_file::mi_console_file): New.
10611 (mi_console_file_delete): Delete.
10612 (mi_console_file_fputs): Delete.
10613 (mi_console_file::write): New.
10614 (mi_console_raw_packet): Delete.
10615 (mi_console_file::flush): New.
10616 (mi_console_file_flush): Delete.
10617 (mi_console_set_raw): Rename to ...
10618 (mi_console_file::set_raw): ... this.
10619 * mi/mi-console.h (class mi_console_file): New class.
10620 (mi_console_file_new, mi_console_set_raw): Delete.
10621 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
10622 (mi_set_logging): Use delete and tee_file. Adjust.
10623 * mi/mi-main.c (output_register): Use string_file.
10624 (mi_cmd_data_evaluate_expression): Use string_file.
10625 (mi_cmd_data_read_memory): Use string_file.
10626 (mi_cmd_execute, print_variable_or_computed): Use string_file.
10627 * mi/mi-out.c (mi_ui_out::main_stream): New.
10628 (mi_ui_out::rewind): Use main_stream and
10629 string_file.
10630 (mi_ui_out::put): Use main_stream and string_file.
10631 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10632 Allocate a 'string_file' instead.
10633 (mi_out_new): Don't allocate a mem_fileopen stream here.
10634 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
10635 (mi_ui_out::main_stream): Declare method.
10636 * printcmd.c (eval_command): Use string_file.
10637 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
10638 * python/py-arch.c (archpy_disassemble): Use string_file.
10639 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
10640 * python/py-frame.c (frapy_str): Use string_file.
10641 * python/py-framefilter.c (py_print_type, py_print_single_arg):
10642 Use string_file.
10643 * python/py-type.c (typy_str): Use string_file.
10644 * python/py-unwind.c (unwind_infopy_str): Use string_file.
10645 * python/py-value.c (valpy_str): Use string_file.
10646 * record-btrace.c (btrace_insn_history): Use string_file.
10647 * regcache.c (regcache_print): Use stdio_file.
10648 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
10649 * remote.c (escape_buffer): Use string_file.
10650 * rust-lang.c (rust_get_disr_info): Use string_file.
10651 * serial.c (serial_open_ops_1): Use stdio_file.
10652 (do_serial_close): Use delete.
10653 * stack.c (print_frame_arg): Use string_file.
10654 (print_frame_args): Remove local mem_fileopen stream, not used.
10655 (print_frame): Use string_file.
10656 * symmisc.c (maintenance_print_symbols): Use stdio_file.
10657 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
10658 Take a 'string_file *' instead of a 'ui_file *'.
10659 * top.c (new_ui): Use stdio_file and stderr_file.
10660 (free_ui): Use delete.
10661 (execute_command_to_string): Use string_file.
10662 (quit_confirm): Use string_file.
10663 * tracepoint.c (collection_list::append_exp): Use string_file.
10664 * tui/tui-disasm.c (tui_disassemble): Use string_file.
10665 * tui/tui-file.c: Don't include "ui-file.h".
10666 (enum streamtype, struct tui_stream): Delete.
10667 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
10668 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
10669 (tui_file::tui_file): New method.
10670 (tui_file_fputs): Delete.
10671 (tui_file_get_strbuf): Delete.
10672 (tui_file::puts): New method.
10673 (tui_file_adjust_strbuf): Delete.
10674 (tui_file_flush): Delete.
10675 (tui_file::flush): New method.
10676 * tui/tui-file.h: Tweak intro comment.
10677 Include ui-file.h.
10678 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
10679 (tui_file_adjust_strbuf): Delete declarations.
10680 (class tui_file): New class.
10681 * tui/tui-io.c (tui_initialize_io): Use tui_file.
10682 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
10683 (tui_register_format): Use string_stream.
10684 * tui/tui-stack.c (tui_make_status_line): Use string_file.
10685 (tui_get_function_from_frame): Use string_file.
10686 * typeprint.c (type_to_string): Use string_file.
10687 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
10688 (null_stream): New global.
10689 (ui_file_delete): Delete.
10690 (ui_file::ui_file): New.
10691 (null_file_isatty): Delete.
10692 (ui_file::~ui_file): New.
10693 (null_file_rewind): Delete.
10694 (ui_file::printf): New.
10695 (null_file_put): Delete.
10696 (null_file_flush): Delete.
10697 (ui_file::putstr): New.
10698 (null_file_write): Delete.
10699 (ui_file::putstrn): New.
10700 (null_file_read): Delete.
10701 (ui_file::putc): New.
10702 (null_file_fputs): Delete.
10703 (null_file_write_async_safe): Delete.
10704 (ui_file::vprintf): New.
10705 (null_file_delete): Delete.
10706 (null_file::write): New.
10707 (null_file_fseek): Delete.
10708 (null_file::puts): New.
10709 (ui_file_data): Delete.
10710 (null_file::write_async_safe): New.
10711 (gdb_flush, ui_file_isatty): Adjust.
10712 (ui_file_put, ui_file_rewind): Delete.
10713 (ui_file_write): Adjust.
10714 (ui_file_write_for_put): Delete.
10715 (ui_file_write_async_safe, ui_file_read): Adjust.
10716 (ui_file_fseek): Delete.
10717 (fputs_unfiltered): Adjust.
10718 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
10719 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
10720 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
10721 (set_ui_file_data): Delete.
10722 (string_file::~string_file, string_file::write)
10723 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
10724 (do_ui_file_as_string, ui_file_as_string): Delete.
10725 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
10726 (struct mem_file): Delete.
10727 (mem_file_new): Delete.
10728 (stdio_file::stdio_file): New.
10729 (mem_file_delete): Delete.
10730 (stdio_file::stdio_file): New.
10731 (mem_fileopen): Delete.
10732 (stdio_file::~stdio_file): New.
10733 (mem_file_rewind): Delete.
10734 (stdio_file::set_stream): New.
10735 (mem_file_put): Delete.
10736 (stdio_file::open): New.
10737 (mem_file_write): Delete.
10738 (stdio_file_magic, struct stdio_file): Delete.
10739 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
10740 (stdio_file::flush): New.
10741 (stdio_file_read): Rename to ...
10742 (stdio_file::read): ... this. Adjust.
10743 (stdio_file_write): Rename to ...
10744 (stdio_file::write): ... this. Adjust.
10745 (stdio_file_write_async_safe): Rename to ...
10746 (stdio_file::write_async_safe) ... this. Adjust.
10747 (stdio_file_fputs): Rename to ...
10748 (stdio_file::puts) ... this. Adjust.
10749 (stdio_file_isatty): Delete.
10750 (stdio_file_fseek): Delete.
10751 (stdio_file::isatty): New.
10752 (stderr_file_write): Rename to ...
10753 (stderr_file::write) ... this. Adjust.
10754 (stderr_file_fputs): Rename to ...
10755 (stderr_file::puts) ... this. Adjust.
10756 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
10757 (stderr_file::stderr_file): New.
10758 (tee_file_magic): Delete.
10759 (struct tee_file): Delete.
10760 (tee_file::tee_file): New.
10761 (tee_file_new): Delete.
10762 (tee_file::~tee_file): New.
10763 (tee_file_delete): Delete.
10764 (tee_file_flush): Rename to ...
10765 (tee_file::flush): ... this. Adjust.
10766 (tee_file_write): Rename to ...
10767 (tee_file::write): ... this. Adjust.
10768 (tee_file::write_async_safe): New.
10769 (tee_file_fputs): Rename to ...
10770 (tee_file::puts): ... this. Adjust.
10771 (tee_file_isatty): Rename to ...
10772 (tee_file::isatty): ... this. Adjust.
10773 * ui-file.h (struct obstack, struct ui_file): Don't
10774 forward-declare.
10775 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
10776 (ui_file_write_ftype)
10777 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
10778 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
10779 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
10780 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
10781 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
10782 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
10783 (set_ui_file_fseek): Delete.
10784 (ui_file_data, ui_file_delete, ui_file_rewind)
10785 (struct ui_file): New.
10786 (ui_file_up): New.
10787 (class null_file): New.
10788 (null_stream): Declare.
10789 (ui_file_write_for_put, ui_file_put): Delete.
10790 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
10791 Delete.
10792 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
10793 (gdb_fopen, tee_file_new): Delete.
10794 (struct string_file): New.
10795 (struct stdio_file): New.
10796 (stdio_file_up): New.
10797 (struct stderr_file): New.
10798 (class tee_file): New.
10799 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
10800 of a 'ui_file *'. Adjust.
10801 * ui-out.h (class ui_out) <field_stream>: Likewise.
10802 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
10803 (null_stream): Delete.
10804 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
10805 Adjust.
10806 * utils.h (struct ui_file): Delete forward declaration..
10807 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
10808 (error_stream): Take a 'string_file &' instead of a
10809 'ui_file *'.
10810 * varobj.c (varobj_value_get_print_value): Use string_file.
10811 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
10812 * gdbarch.c: Regenerate.
10813
187808b0
PA
108142017-02-02 Pedro Alves <palves@redhat.com>
10815
10816 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
10817 (gdb_pretty_print_insn): ... this. Now a free function. Add back
10818 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
10819 Adjust to call gdb_print_insn instead of
10820 gdb_disassembler::print_insn.
10821 (dump_insns, do_mixed_source_and_assembly_deprecated)
10822 (do_mixed_source_and_assembly, do_assembly_only): Add back a
10823 'gdbarch' parameter. Remove gdb_disassembler parameter.
10824 (gdb_disassembly): Don't allocate a gdb_disassembler here.
10825 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
10826 declaration.
10827 (gdb_pretty_print_insn): Re-add declaration.
10828 * record-btrace.c (btrace_insn_history): Don't allocate a
10829 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
10830
7a8eb317
SM
108312017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
10832
10833 * disasm.h (gdb_disassembly): Remove file_string parameter.
10834 * disasm.c (gdb_disassembly): Likewise.
10835 * cli/cli-cmds.c (print_disassembly): Adapt.
10836 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
10837 * stack.c (do_gdb_disassembly): Likewise.
10838
7346ef59
AA
108392017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
10840
10841 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
10842 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
10843 targets. And if the implicit value is longer than needed, extract
10844 the first bytes instead of the "least significant" ones.
10845
cd4007e4
MM
108462017-02-01 Markus Metzger <markus.t.metzger@intel.com>
10847
10848 * btrace.c (btrace_enable): Do not call btrace_add_pc for
10849 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
10850 (btrace_fetch): Assert can_access_registers_ptid.
10851 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
10852 validate_registers_access.
10853
cf77c34e
MM
108542017-02-01 Markus Metzger <markus.t.metzger@intel.com>
10855
10856 * gdbthread.h (can_access_registers_ptid): New.
10857 * thread.c (can_access_registers_ptid): New.
10858
be85ce7d
PA
108592017-02-01 Pedro Alves <palves@redhat.com>
10860
10861 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
10862
29b0b251
PA
108632017-01-31 Pedro Alves <palves@redhat.com>
10864
10865 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
10866 Fix typos.
10867
289b5b24
PA
108682017-01-31 Pedro Alves <palves@redhat.com>
10869
10870 * stack.c (print_frame_args): Remove local mem_fileopen stream,
10871 not used.
10872
b47413b4
PA
108732017-01-31 Pedro Alves <palves@redhat.com>
10874
10875 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
10876
60adb36c
PA
108772017-01-31 Pedro Alves <palves@redhat.com>
10878
10879 * common/scoped_restore.h
10880 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
10881 change the value's parameter type to T2.
10882 (make_scoped_restore): Likewise.
10883
2735833d
WT
108842017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10885 Richard Henderson <rth@redhat.com>
10886
10887 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
10888 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
10889 GS_BASE for older kernels.
10890 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
10891 GS_BASE for older kernels.
10892 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
10893 and GS_BASE to the offset table.
10894 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
10895 system register group.
10896 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
10897 for older kernels.
10898 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
10899 amd64 ABI.
10900 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
10901 AMD64_GSBASE_REGNUM.
10902 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
10903 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
10904 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
10905 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
10906 i386/64bit-segments.xml in those rules.
10907 * features/i386/64bit-segments.xml: New file.
10908 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
10909 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
10910 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
10911 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
10912 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
10913 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
10914 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
10915 * features/i386/amd64-avx-linux.c: Regenerated.
10916 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
10917 * features/i386/amd64-avx-mpx.c: Regenerated.
10918 * features/i386/amd64-avx512-linux.c: Regenerated.
10919 * features/i386/amd64-linux.c: Regenerated.
10920 * features/i386/amd64-mpx-linux.c: Regenerated.
10921 * features/i386/i386-avx-mpx-linux.c: Regenerated.
10922 * features/i386/i386-avx-mpx.c: Regenerated.
10923 * features/i386/x32-avx-linux.c: Regenerated.
10924 * features/i386/x32-avx512-linux.c: Regenerated.
10925 * regformats/i386/amd64-avx-linux.dat: Regenerated.
10926 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
10927 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
10928 * regformats/i386/amd64-linux.dat: Regenerated.
10929 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
10930 * regformats/i386/x32-avx-linux.dat: Regenerated.
10931 * regformats/i386/x32-avx512-linux.dat: Regenerated.
10932 * regformats/i386/x32-linux.dat: Regenerated.
10933
8884e97e
WT
109342017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10935
10936 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
10937 Set to AMD64_NUM_REGS.
10938
7005d26a
WT
109392017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
10940
10941 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
10942 that checks validity of a register number.
10943
4bd2e1b2
KC
109442017-01-27 Kees Cook <keescook@google.com>
10945
10946 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
10947 fetch_fpregs if target has fpa registers.
10948 (arm_linux_store_inferior_registers): Call store_fpregs if target
10949 has fpa registers.
10950
7cf1de6c
AA
109512017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
10952
10953 * cris-tdep.c (cris_gdbarch_init): Remove check for
10954 info.byte_order and force it to BFD_ENDIAN_LITTLE.
10955
874a1c8c
AT
109562017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
10957
10958 * corelow.c (get_core_register_section): Check for regset
10959 existence before checking for REGSET_VARIABLE_SIZE.
10960
d8b49cf0
YQ
109612017-01-26 Yao Qi <yao.qi@linaro.org>
10962 Pedro Alves <palves@redhat.com>
10963
10964 PR gdb/20939
10965 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
10966 call memory_error, save memaddr instead.
10967 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
10968 negative, cal memory_error.
10969 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
10970
658ca58c
YQ
109712017-01-26 Yao Qi <yao.qi@linaro.org>
10972
10973 * disasm-selftests.c (memory_error_test): New function.
10974 (_initialize_disasm_selftests): Register memory_error_test.
10975
79843d45
YQ
109762017-01-26 Yao Qi <yao.qi@linaro.org>
10977
10978 * Makefile.in (SFILES): Add disasm-selftests.c and
10979 selftest-arch.c.
10980 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
10981 * disasm-selftests.c: New file.
10982 * selftest-arch.c: New file.
10983 * selftest-arch.h: New file.
10984
8cafda32
YQ
109852017-01-26 Yao Qi <yao.qi@linaro.org>
10986
10987 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
10988 to bfd_arch_mep. Don't return 0 if section is not
10989 found. Call print_insn_mep.
10990
e47ad6c0
YQ
109912017-01-26 Pedro Alves <palves@redhat.com>
10992 Yao Qi <yao.qi@linaro.org>
10993
10994 * arm-tdep.c: Include "disasm.h".
10995 (gdb_print_insn_arm): Update code to get gdbarch.
10996 * disasm.c (dis_asm_read_memory): Change it to
10997 gdb_disassembler::dis_asm_read_memory.
10998 (dis_asm_memory_error): Likewise.
10999 (dis_asm_print_address): Likewise.
11000 (gdb_pretty_print_insn): Change it to
11001 gdb_disassembler::pretty_print_insn.
11002 (dump_insns): Add one argument gdb_disassemlber. All
11003 callers updated.
11004 (do_mixed_source_and_assembly_deprecated): Likewise.
11005 (do_mixed_source_and_assembly): Likewise.
11006 (do_assembly_only): Likewise.
11007 (gdb_disassembler::gdb_disassembler): New.
11008 (gdb_disassembler::print_insn): New.
11009 * disasm.h (class gdb_disassembler): New.
11010 (gdb_pretty_print_insn): Remove declaration.
11011 (gdb_disassemble_info): Likewise.
11012 * guile/scm-disasm.c (class gdbscm_disassembler): New.
11013 (gdbscm_disasm_read_memory_worker): Update.
11014 (gdbscm_disasm_read_memory): Update.
11015 (gdbscm_disasm_memory_error): Remove.
11016 (gdbscm_disasm_print_address): Remove.
11017 (gdbscm_disassembler::gdbscm_disassembler): New.
11018 (gdbscm_print_insn_from_port): Update.
11019 * mips-tdep.c: Include disasm.h.
11020 (gdb_print_insn_mips): Update code to get gdbarch.
11021 * record-btrace.c (btrace_insn_history): Update.
11022 * spu-tdep.c: Include disasm.h.
11023 (struct spu_dis_asm_data): Remove.
11024 (struct spu_dis_asm_info): New.
11025 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
11026 SPU id.
11027 (gdb_print_insn_spu): Cast disassemble_info to
11028 spu_dis_asm_info.
11029
80d75874
YQ
110302017-01-26 Yao Qi <yao.qi@linaro.org>
11031
11032 * disasm.c (do_ui_file_delete): Delete.
11033 (gdb_insn_length): Move code creating stream to ...
11034 * utils.c (null_stream): ... here. New function.
11035 * utils.h (null_stream): Declare.
11036
60685cd0
SM
110372017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
11038
11039 * python/py-inferior.c (find_thread_object): Return directly
11040 from the loop. Remove "found" variable.
11041
eb1cdb62
JB
110422017-01-21 Joel Brobecker <brobecker@adacore.com>
11043
11044 GDB 7.12.1 released.
11045
b1ce6568
SM
110462017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11047
11048 * python/py-function.c (fnpy_call): Reorder declarations to have
11049 the gdbpy_enter object declared first.
11050 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
11051
6f8b0407
SM
110522017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11053
fec93fb1 11054 PR python/21068
6f8b0407
SM
11055 * python/python-internal.h (PyMem_RawMalloc): Define for
11056 Python < 3.4.
11057 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
11058 PyMem_RawMalloc instead of PyMem_Malloc.
11059
78cbbba8
LM
110602017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
11061 Luis Machado <lgustavo@codesourcery.com>
11062
11063 * NEWS (New commands): Mention flash-erase.
11064 (New MI commands): Mention target-flash-erase.
11065 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
11066 command.
11067 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
11068 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
11069 * target.c (flash_erase_command): New function.
11070 (initialize_targets): Add new flash-erase command.
11071 * target.h (flash_erase_command): New declaration.
11072
2132fe85
JB
110732017-01-20 Joel Brobecker <brobecker@adacore.com>
11074
11075 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
11076 HAVE_SYS_PROCFS_H is defined.
11077
d1dff226
AH
110782017-01-18 Alan Hayward <alan.hayward@arm.com>
11079
11080 * remote.c (struct cached_reg): Change data into a pointer.
11081 * (stop_reply_dtr): Free data pointers before deleting vector.
11082 (process_stop_reply): Likewise.
11083 (remote_parse_stop_reply): Allocate space for data
11084
9890e433
AH
110852017-01-18 Alan Hayward <alan.hayward@arm.com>
11086
11087 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
11088 MAX_REGISTER_SIZE.
11089 (amd64_pseudo_register_read_value): Likewise.
11090 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
11091 (store_register_using_P): Likewise.
11092 * regcache.c (regcache_xfer_part): Likewise.
11093
7a36499a
IR
110942017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
11095
11096 Split real and pseudo registers.
11097 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
11098 (sparc32_pseudo_regnum): New enum.
11099 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
11100 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
11101 (SPARC32_CP0_REGISTERS): New macro.
11102 (sparc32_pseudo_register_name): New function.
11103 (sparc32_register_name): Use sparc32_pseudo_register_name.
11104 (sparc32_pseudo_register_type): New function.
11105 (sparc32_register_type): Use sparc32_pseudo_register_type.
11106 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
11107 pseudo register numbers.
11108 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
11109 (SPARC64_CP0_REGISTERS): New macro.
11110 (sparc64_pseudo_register_name): New function.
11111 (sparc64_register_name): Use sparc64_pseudo_register_name.
11112 (sparc64_pseudo_register_type): New function.
11113 (sparc64_register_type): Use sparc64_pseudo_register_type.
11114 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
11115 pseudo register numbers.
11116 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
11117 sparc64_store_arguments): Handle pseudo register numbers.
11118
6f8976bf
YQ
111192017-01-13 Yao Qi <yao.qi@linaro.org>
11120
11121 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
11122 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
11123 output.
11124 (getpkt_or_notif_sane_1): Likewise.
11125
e4241ace
YQ
111262017-01-13 Yao Qi <yao.qi@linaro.org>
11127
11128 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
11129 of CC. Pass "-x c++-header" instead of "-x c".
11130
3015c064
SM
111312017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11132
11133 * remote.c (remote_can_async_p): Update comment.
11134
fde1b17d
SM
111352017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11136
11137 * linux-nat.c (linux_nat_can_async_p): Update comment.
11138
ca1ca08b
SM
111392017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11140
11141 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
11142
4ad2da73
SM
111432017-01-11 Simon Marchi <simon.marchi@ericsson.com>
11144
11145 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
11146
c8b23b3f
TT
111472017-01-10 Tom Tromey <tom@tromey.com>
11148
11149 * python/py-type.c (typy_legacy_template_argument): Update.
11150 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
11151 ~demangle_parse_info): Declare new members.
11152 (cp_demangled_name_to_comp): Return unique_ptr.
11153 (cp_demangled_name_parse_free)
11154 (make_cleanup_cp_demangled_name_parse_free)
11155 (cp_new_demangle_parse_info): Remove.
11156 * cp-support.c (do_demangled_name_parse_free_cleanup)
11157 (make_cleanup_cp_demangled_name_parse_free): Remove.
11158 (inspect_type, cp_canonicalize_string_full)
11159 (cp_canonicalize_string): Update.
11160 (mangled_name_to_comp): Change return type.
11161 (cp_class_name_from_physname, method_name_from_physname)
11162 (cp_func_name, cp_remove_params): Update.
11163 * cp-name-parser.y (demangle_parse_info): New constructor, from
11164 cp_new_demangle_parse_info.
11165 (~demangle_parse_info): New destructor, from
11166 cp_demangled_name_parse_free.
11167 (cp_merge_demangle_parse_infos): Update.
11168 (cp_demangled_name_to_comp): Change return type.
11169
1ac32117
TT
111702017-01-10 Tom Tromey <tom@tromey.com>
11171
11172 * top.c (prevent_dont_repeat): Change return type.
11173 * python/python.c (execute_gdb_command): Use std::string.
11174 Update.
11175 * guile/guile.c (gdbscm_execute_gdb_command): Update.
11176 * command.h (prevent_dont_repeat): Change return type.
11177 * breakpoint.c (bpstat_do_actions_1): Update.
11178
0cf08227
TT
111792017-01-10 Tom Tromey <tom@tromey.com>
11180
11181 * value.h (scoped_value_mark::~scoped_value_mark): Call
11182 free_to_mark.
11183 (scoped_value_mark::free_to_mark): New method.
11184 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11185 scoped_value_mark.
11186
eb115069
TT
111872017-01-10 Tom Tromey <tom@tromey.com>
11188
11189 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11190 (valpy_reference_value, valpy_const_value, valpy_get_address)
11191 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11192 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11193 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11194 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11195 scoped_value_mark.
11196 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11197 * value.h (scoped_value_mark): New class.
11198
906768f9
TT
111992017-01-10 Tom Tromey <tom@tromey.com>
11200
11201 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11202 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11203 * psymtab.c (discard_psymtabs_upto): Remove.
11204 (make_cleanup_discard_psymtabs): Remove.
11205 (struct psymtab_state): Remove.
11206
bef155c3
TT
112072017-01-10 Tom Tromey <tom@tromey.com>
11208
11209 * record-full.c (record_full_save_cleanups): Remove.
11210 (record_full_save): Use gdb::unlinker.
11211 * gcore.c (do_bfd_delete_cleanup): Remove.
11212 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11213 cleanups.
11214 * dwarf2read.c (unlink_if_set): Remove.
11215 (write_psymtabs_to_index): Use gdb::unlinker.
11216 * common/gdb_unlinker.h: New file.
11217
192b62ce
TT
112182017-01-10 Tom Tromey <tom@tromey.com>
11219
11220 * windows-tdep.c (windows_xfer_shared_library): Update.
11221 * windows-nat.c (windows_make_so): Update.
11222 * utils.h (make_cleanup_bfd_unref): Remove.
11223 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11224 * symfile.h (symfile_bfd_open)
11225 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11226 * symfile.c (read_symbols, symbol_file_add)
11227 (separate_debug_file_exists): Update.
11228 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11229 (generic_load, reread_symbols): Update.
11230 * symfile-mem.c (symbol_file_add_from_memory): Update.
11231 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11232 (spu_symbol_file_add_from_memory): Update.
11233 * solist.h (struct target_so_ops) <bfd_open>: Return
11234 gdb_bfd_ref_ptr.
11235 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11236 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11237 gdb_bfd_ref_ptr.
11238 (solib_map_sections, reload_shared_libraries_1): Update.
11239 * solib-svr4.c (enable_break): Update.
11240 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11241 * solib-frv.c (enable_break2): Update.
11242 * solib-dsbt.c (enable_break): Update.
11243 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11244 gdb_bfd_ref_ptr.
11245 (darwin_solib_get_all_image_info_addr_at_init): Update.
11246 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11247 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11248 * record-full.c (record_full_save): Update.
11249 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11250 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11251 * minidebug.c (find_separate_debug_file_in_section): Return
11252 gdb_bfd_ref_ptr.
11253 * machoread.c (macho_add_oso_symfile): Change abfd to
11254 gdb_bfd_ref_ptr.
11255 (macho_symfile_read_all_oso): Update.
11256 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11257 (macho_symfile_read): Update.
11258 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11259 (jit_bfd_try_read_symtab): Update.
11260 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11261 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11262 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11263 gdb_bfd_ref_ptr.
11264 (gdb_bfd_ref_policy): New struct.
11265 (gdb_bfd_ref_ptr): New typedef.
11266 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11267 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11268 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11269 gdb_bfd_ref_ptr.
11270 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11271 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11272 (gcore_command): Update.
11273 * exec.c (exec_file_attach): Update.
11274 * elfread.c (elf_symfile_read): Update.
11275 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11276 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11277 (open_and_init_dwo_file): Update.
11278 (open_dwp_file): Return gdb_bfd_ref_ptr.
11279 (open_and_init_dwp_file): Update.
11280 * corelow.c (core_open): Update.
11281 * compile/compile-object-load.c (compile_object_load): Update.
11282 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11283 * coffread.c (coff_symfile_read): Update.
11284 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11285 gdb_bfd_ref_ptr. Rename.
11286 (dump_bfd_file, restore_command): Update.
11287 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11288 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11289 (find_separate_debug_file_by_buildid): Update.
11290
50315b21
TT
112912017-01-10 Tom Tromey <tom@tromey.com>
11292
11293 * common/gdb_ref_ptr.h: New file.
11294 * python/py-ref.h (struct gdbpy_ref_policy): New.
11295 (gdbpy_ref): Now a typedef.
11296
fc4007c9
TT
112972017-01-10 Tom Tromey <tom@tromey.com>
11298
11299 * utils.h (make_cleanup_htab_delete): Don't declare.
11300 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11301 Remove.
11302 * linespec.c (decode_compound_collector): Add constructor,
11303 destructor.
11304 (lookup_prefix_sym): Remove cleanup.
11305 (symtab_collector): Add constructor, destructor.
11306 (collect_symtabs_from_filename): Remove cleanup.
11307 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11308 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11309 Use htab_up.
11310 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11311 * dwarf2read.c (dw2_expand_symtabs_matching)
11312 (dw2_map_symbol_filenames, dwarf_decode_macros)
11313 (write_psymtabs_to_index): Use htab_up.
11314 * dwarf2loc.c (func_verify_no_selftailcall)
11315 (call_site_find_chain_1, func_verify_no_selftailcall)
11316 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11317 std::vector, gdb::unique_xmalloc_ptr.
11318 (call_sitep): Remove typedef.
11319 (dwarf2_locexpr_baton_eval): Remove unused variable.
11320
8dbcee67
TT
113212017-01-10 Tom Tromey <tom@tromey.com>
11322
11323 * python/python-internal.h (make_cleanup_py_decref)
11324 (make_cleanup_py_xdecref): Don't declare.
11325 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11326 (py_xdecref, make_cleanup_py_xdecref): Remove.
11327
13df46cc
TT
113282017-01-10 Tom Tromey <tom@tromey.com>
11329
11330 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11331 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11332
06fc9bf7
TT
113332017-01-10 Tom Tromey <tom@tromey.com>
11334
11335 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11336
830a4934
TT
113372017-01-10 Tom Tromey <tom@tromey.com>
11338
11339 * python/py-utils.c (unicode_to_encoded_string)
11340 (python_string_to_target_string)
11341 (python_string_to_target_python_string)
11342 (python_string_to_host_string, gdbpy_obj_to_string)
11343 (get_addr_from_python): Use gdbpy_ref.
11344
4586d543
TT
113452017-01-10 Tom Tromey <tom@tromey.com>
11346
11347 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11348 gdbpy_ref.
11349
59876f8f
TT
113502017-01-10 Tom Tromey <tom@tromey.com>
11351
11352 * python/python.c (eval_python_command, gdbpy_decode_line)
11353 (gdbpy_run_events, gdbpy_start_type_printers)
11354 (gdbpy_apply_type_printers): Use gdbpy_ref.
11355
97d83487
TT
113562017-01-10 Tom Tromey <tom@tromey.com>
11357
11358 * python/py-param.c (get_doc_string, compute_enum_values): Use
11359 gdbpy_ref.
11360
9205649a
TT
113612017-01-10 Tom Tromey <tom@tromey.com>
11362
11363 * python/py-inferior.c (find_thread_object, build_inferior_list):
11364 Use gdbpy_ref.
11365
74c49d45
TT
113662017-01-10 Tom Tromey <tom@tromey.com>
11367
11368 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11369
16361ffb
TT
113702017-01-10 Tom Tromey <tom@tromey.com>
11371
11372 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11373 gdbpy_ref.
11374
905f2cca
TT
113752017-01-10 Tom Tromey <tom@tromey.com>
11376
11377 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11378 extra incref.
11379 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11380 Use gdbpy_ref.
11381
64081434
TT
113822017-01-10 Tom Tromey <tom@tromey.com>
11383
11384 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11385 gdbpy_ref.
11386
59e9e831
TT
113872017-01-10 Tom Tromey <tom@tromey.com>
11388
11389 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11390 decref results of PyArg_ParseTupleAndKeywords.
11391
9de10f6d
TT
113922017-01-10 Tom Tromey <tom@tromey.com>
11393
11394 * python/python.c (python_run_simple_file): Use
11395 unique_xmalloc_ptr, gdbpy_ref.
11396
2bd5759d
TT
113972017-01-10 Tom Tromey <tom@tromey.com>
11398
11399 * python/py-prettyprint.c (print_stack_unless_memory_error)
11400 (print_string_repr, print_children): Use gdbpy_ref.
11401 (dummy_python_frame): New class.
11402 (dummy_python_frame::dummy_python_frame): Rename from
11403 push_dummy_python_frame.
11404 (py_restore_tstate): Remove.
11405
3b4e0e01
TT
114062017-01-10 Tom Tromey <tom@tromey.com>
11407
11408 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11409
17a22718
TT
114102017-01-10 Tom Tromey <tom@tromey.com>
11411
11412 * python/python.c (ensure_python_env, restore_python_env):
11413 Remove.
11414 * python/python-internal.h (ensure_python_env): Don't declare.
11415 * varobj.h (varobj_ensure_python_env): Don't declare.
11416 * varobj.c (varobj_ensure_python_env): Remove.
11417
68cdc557
TT
114182017-01-10 Tom Tromey <tom@tromey.com>
11419
11420 * varobj.c (varobj_value_get_print_value): Use
11421 gdbpy_enter_varobj.
11422
1eba6383
TT
114232017-01-10 Tom Tromey <tom@tromey.com>
11424
11425 * python/py-prettyprint.c (print_string_repr, print_children):
11426 Update.
11427 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11428 of "encoding".
11429 * varobj.c (varobj_value_get_print_value): Update.
11430 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11431
bde7b3e3
TT
114322017-01-10 Tom Tromey <tom@tromey.com>
11433
11434 * varobj.c (varobj_get_display_hint)
11435 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11436 (varobj_set_visualizer, free_variable): Use
11437 gdbpy_enter_varobj.
11438
a7785f8c
TT
114392017-01-10 Tom Tromey <tom@tromey.com>
11440
11441 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11442 (do_finish_initialization): New function. Use gdbpy_ref.
11443 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11444 do_finish_initialization.
11445
2865bfce
TT
114462017-01-10 Tom Tromey <tom@tromey.com>
11447
11448 * python/py-param.c (get_set_value, get_show_value): Use
11449 gdbpy_enter, gdbpy_ref.
11450
0e9dcc75
TT
114512017-01-10 Tom Tromey <tom@tromey.com>
11452
11453 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11454
12a5cedd
TT
114552017-01-10 Tom Tromey <tom@tromey.com>
11456
11457 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11458
788f2586
TT
114592017-01-10 Tom Tromey <tom@tromey.com>
11460
11461 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
11462 Use gdbpy_enter_varobj.
11463
6cd67bea
TT
114642017-01-10 Tom Tromey <tom@tromey.com>
11465
11466 * varobj.c (gdbpy_enter_varobj): New constructor.
11467 * python/python-internal.h (gdbpy_enter_varobj): New class.
11468 * python/py-varobj.c (py_varobj_get_iterator): Use
11469 gdbpy_enter_varobj.
11470
14b122bf
TT
114712017-01-10 Tom Tromey <tom@tromey.com>
11472
11473 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
11474 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11475 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
11476 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
11477 unique_xmalloc_ptr.
11478 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
11479
bf1ca3b9
TT
114802017-01-10 Tom Tromey <tom@tromey.com>
11481
11482 * python/py-xmethods.c (invoke_match_method): Use
11483 gdbpy_ref.
11484
572a5524
TT
114852017-01-10 Tom Tromey <tom@tromey.com>
11486
11487 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
11488 gdbpy_enter, gdbpy_ref.
11489
396a78b6
TT
114902017-01-10 Tom Tromey <tom@tromey.com>
11491
11492 * python/python.c (python_interactive_command): Use gdbpy_enter.
11493
a88b13c7
TT
114942017-01-10 Tom Tromey <tom@tromey.com>
11495
11496 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
11497 gdbpy_ref.
11498
e9f0c363
TT
114992017-01-10 Tom Tromey <tom@tromey.com>
11500
11501 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
11502 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11503
6349f452
TT
115042017-01-10 Tom Tromey <tom@tromey.com>
11505
11506 * utils.h (htab_deleter): New struct.
11507 (htab_up): New typedef.
11508 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
11509 gdbpy_enter, gdbpy_ref, htab_up.
11510
c0171de6
TT
115112017-01-10 Tom Tromey <tom@tromey.com>
11512
11513 * python/py-unwind.c (pending_frame_invalidate): Remove.
11514 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
11515
f18e226f
TT
115162017-01-10 Tom Tromey <tom@tromey.com>
11517
11518 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
11519 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
11520
c57af3f1
TT
115212017-01-10 Tom Tromey <tom@tromey.com>
11522
11523 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
11524
60e600ec
TT
115252017-01-10 Tom Tromey <tom@tromey.com>
11526
11527 * python/python.c (gdbpy_eval_from_control_command)
11528 (gdbpy_source_script, gdbpy_run_events)
11529 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
11530 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
11531 gdbpy_enter.
11532
bf7da5b0
TT
115332017-01-10 Tom Tromey <tom@tromey.com>
11534
11535 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
11536
2d38bced
TT
115372017-01-10 Tom Tromey <tom@tromey.com>
11538
11539 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
11540
07bc7329
TT
115412017-01-10 Tom Tromey <tom@tromey.com>
11542
11543 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
11544 (python_on_inferior_call_pre, python_on_inferior_call_post)
11545 (python_on_memory_change, python_on_register_change)
11546 (python_inferior_exit, python_new_objfile, add_thread_object)
11547 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
11548
6e7c365e
TT
115492017-01-10 Tom Tromey <tom@tromey.com>
11550
11551 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
11552 (bpfinishpy_handle_exit): Use gdbpy_enter.
11553
6ba0cd40
TT
115542017-01-10 Tom Tromey <tom@tromey.com>
11555
11556 * python/py-cmd.c (cmdpy_destroyer)
11557 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
11558 gdbpy_enter.
11559
de2dc875
TT
115602017-01-10 Tom Tromey <tom@tromey.com>
11561
11562 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11563 gdbpy_enter.
11564 (gdbpy_breakpoint_has_cond): Likewise.
11565
4ecee2c4
TT
115662017-01-10 Tom Tromey <tom@tromey.com>
11567
11568 * python/python.c (gdbpy_enter): New constructor.
11569 (~gdbpy_enter): New destructor.
11570 (restore_python_env, ensure_python_env): Rewrite.
11571 * python/python-internal.h (gdbpy_enter): New class.
11572
37fce74f
TT
115732017-01-10 Tom Tromey <tom@tromey.com>
11574
11575 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
11576
53a0cca3
TT
115772017-01-10 Tom Tromey <tom@tromey.com>
11578
11579 * python/py-value.c (value_has_field, get_field_flag)
11580 (get_field_type, valpy_getitem, convert_value_from_python): Use
11581 gdbpy_ref.
11582
ff3724f5
TT
115832017-01-10 Tom Tromey <tom@tromey.com>
11584
11585 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
11586 gdbpy_ref.
11587
0700aea5
TT
115882017-01-10 Tom Tromey <tom@tromey.com>
11589
11590 * python/py-prettyprint.c (search_pp_list)
11591 (find_pretty_printer_from_objfiles)
11592 (find_pretty_printer_from_progspace)
11593 (find_pretty_printer_from_gdb, find_pretty_printer)
11594 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
11595 gdbpy_ref.
11596
1bb44c9f
TT
115972017-01-10 Tom Tromey <tom@tromey.com>
11598
11599 * python/py-param.c (call_doc_function): Use gdbpy_ref.
11600
87ce03fd
TT
116012017-01-10 Tom Tromey <tom@tromey.com>
11602
11603 * python/py-linetable.c (build_line_table_tuple_from_pcs)
11604 (ltpy_get_all_source_lines): Use gdbpy_ref.
11605
ee0a3fb8
TT
116062017-01-10 Tom Tromey <tom@tromey.com>
11607
11608 * python/py-framefilter.c (extract_sym, extract_value)
11609 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
11610 gdbpy_ref.
11611
bf2a52fa
TT
116122017-01-10 Tom Tromey <tom@tromey.com>
11613
11614 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
11615
f59fe7f8
TT
116162017-01-10 Tom Tromey <tom@tromey.com>
11617
11618 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
11619
80bd970a
TT
116202017-01-10 Tom Tromey <tom@tromey.com>
11621
11622 * python/py-function.c (convert_values_to_python, fnpy_init): Use
11623 gdbpy_ref.
11624
d1b3de2e
TT
116252017-01-10 Tom Tromey <tom@tromey.com>
11626
11627 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
11628
3bb43384
TT
116292017-01-10 Tom Tromey <tom@tromey.com>
11630
11631 * python/py-type.c (convert_field, make_fielditem, typy_fields)
11632 (typy_range): Use gdbpy_ref.
11633
abf5651e
TT
116342017-01-10 Tom Tromey <tom@tromey.com>
11635
11636 * python/py-threadevent.c (create_thread_event_object): Use
11637 gdbpy_ref.
11638 * python/py-stopevent.c (create_stop_event_object): Simplify.
11639 (emit_stop_event): Use gdbpy_ref.
11640 * python/py-signalevent.c (create_signal_event_object): Use
11641 gdbpy_ref.
11642 * python/py-newobjfileevent.c (create_new_objfile_event_object)
11643 (emit_new_objfile_event, create_clear_objfiles_event_object)
11644 (emit_clear_objfiles_event): Use gdbpy_ref.
11645 * python/py-infevents.c (create_inferior_call_event_object)
11646 (create_register_changed_event_object)
11647 (create_memory_changed_event_object, emit_inferior_call_event)
11648 (emit_memory_changed_event, emit_register_changed_event): Use
11649 gdbpy_ref.
11650 * python/py-exitedevent.c (create_exited_event_object)
11651 (emit_exited_event): Use gdbpy_ref.
11652 * python/py-event.h (evpy_emit_event): Remove
11653 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
11654 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
11655 * python/py-continueevent.c (emit_continue_event): Use
11656 gdbpy_ref.
11657 * python/py-breakpoint.c (gdbpy_breakpoint_created)
11658 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
11659 gdbpy_ref.
11660 * python/py-bpevent.c (create_breakpoint_event_object): Use
11661 gdbpy_ref.
11662
a68ff33e
TT
116632017-01-10 Tom Tromey <tom@tromey.com>
11664
11665 * python/py-ref.h: New file.
11666
7becfd03
SM
116672017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11668
11669 * cli-out.c (cli_ui_out::do_redirect): Change return type to
11670 void.
11671 * cli-out.h (cli_ui_out::do_redirect): Likewise.
11672 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
11673 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
11674 * ui-out.c (ui_out::redirect): Likewise.
11675 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
11676 * cli/cli-logging.c (set_logging_redirect): Update call site of
11677 ui_out::redirect.
11678 (handle_redirections): Likewise.
11679 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
11680 * top.c (execute_command_to_string): Likewise.
11681 * utils.c (do_ui_out_redirect_pop): Likewise.
11682
df294654
SM
116832017-01-10 Simon Marchi <simon.marchi@ericsson.com>
11684
11685 * stack.c (_initialize_stack): Update "frame" command help message.
11686
f5e6296e
IB
116872017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
11688
11689 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
11690
0e2d6fa6
YQ
116912017-01-06 Yao Qi <yao.qi@linaro.org>
11692
11693 * x86-linux-nat.h: Include gdb_proc_service.h.
11694
44d6d3f9
YQ
116952017-01-06 Yao Qi <yao.qi@linaro.org>
11696
11697 * ser-base.h: Include serial.h.
11698
656731fe
YQ
116992017-01-06 Yao Qi <yao.qi@linaro.org>
11700
11701 * ppc-linux-tdep.h: Include ppc-tdep.h.
11702
1ca8f924
YQ
117032017-01-06 Yao Qi <yao.qi@linaro.org>
11704
11705 * nat/amd64-linux-siginfo.h: Include signal.h.
11706
bc3008c4
YQ
117072017-01-06 Yao Qi <yao.qi@linaro.org>
11708
11709 * nat/aarch64-linux-hw-point.h: Include break-common.h.
11710
66c80d03
YQ
117112017-01-06 Yao Qi <yao.qi@linaro.org>
11712
11713 * mi/mi-parse.h: Include mi-cmds.h.
11714
051d2dda
YQ
117152017-01-06 Yao Qi <yao.qi@linaro.org>
11716
11717 * inf-loop.c: Don't include "target.h".
11718 * inf-loop.h: Include it here.
11719
8018d34f
YQ
117202017-01-06 Yao Qi <yao.qi@linaro.org>
11721
11722 * dfp.h: Include "dboulest.h" and "expression.h".
11723
c0b8369c
YQ
117242017-01-06 Yao Qi <yao.qi@linaro.org>
11725
11726 * ax-gdb.h: Include "ax.h".
11727
ad5cba2a
YQ
117282017-01-06 Yao Qi <yao.qi@linaro.org>
11729
11730 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
11731 with nat/gdb_ptrace.h.
11732
1c33cd7f
YQ
117332017-01-05 Yao Qi <yao.qi@linaro.org>
11734
11735 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
11736 new line.
11737 (mips64_fbsd_sigframe_init): Likewise.
11738
c988ac1d
JB
117392017-01-04 John Baldwin <jhb@FreeBSD.org>
11740
11741 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
11742 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
11743
b268007c
JB
117442017-01-04 John Baldwin <jhb@FreeBSD.org>
11745
11746 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
11747 * NEWS: Mention new FreeBSD/mips native configuration.
11748 * config/mips/fbsd.mh: New file.
11749 * configure.host: Add mips*-*-freebsd*.
11750 * mips-fbsd-nat.c: New file.
11751
387360da
JB
117522017-01-04 John Baldwin <jhb@FreeBSD.org>
11753
11754 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
11755 (ALLDEPFILES): Add mips-fbsd-tdep.c.
11756 * NEWS: Mention new FreeBSD/mips target.
11757 * configure.tgt: Add mips*-*-freebsd*.
11758 * mips-fbsd-tdep.c: New file.
11759 * mips-fbsd-tdep.h: New file.
11760
2aaaf250
YQ
117612017-01-04 Yao Qi <yao.qi@linaro.org>
11762
11763 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
11764 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
11765
61baf725
JB
117662017-01-01 Joel Brobecker <brobecker@adacore.com>
11767
6dbb839a 11768 Update copyright year range in all GDB files.
61baf725 11769
c113e7ff 117702017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 11771
c113e7ff 11772 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 11773
c113e7ff 11774For older changes see ChangeLog-2016.
c906108c
SS
11775\f
11776Local Variables:
11777mode: change-log
11778left-margin: 8
11779fill-column: 74
11780version-control: never
57da7796 11781coding: utf-8
c906108c 11782End:
This page took 2.451709 seconds and 4 git commands to generate.