Remove make_delete_ui_cleanup
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
895b8f30
TT
12017-10-03 Tom Tromey <tom@tromey.com>
2
3 * event-top.c (stdin_event_handler): Update.
4 * main.c (captured_main_1): Update.
5 * top.h (make_delete_ui_cleanup): Remove.
6 (struct ui): Add constructor and destructor.
7 (new_ui, delete_ui): Remove.
8 * top.c (make_delete_ui_cleanup): Remove.
9 (new_ui_command): Use std::unique_ptr.
10 (delete_ui_cleanup): Remove.
11 (ui::ui): Rename from new_ui. Update.
12 (free_ui): Remove.
13 (ui::~ui): Rename from delete_ui. Update.
14
0efef640
TT
152017-10-03 Tom Tromey <tom@tromey.com>
16
17 * symfile.c (load_progress): Use gdb::byte_vector.
18
245ad7d3
TT
192017-10-03 Tom Tromey <tom@tromey.com>
20
21 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
22 declaration.
23 * printcmd.c (x_command): Remove unused declaration.
24 * symfile.c (symbol_file_command): Remove unused declaration.
25
e05550d7
TT
262017-10-03 Tom Tromey <tom@tromey.com>
27
28 * utils.c (internal_vproblem): Use std::string.
29 (defaulted_query): Likewise.
30
b95de2b7
TT
312017-10-03 Tom Tromey <tom@tromey.com>
32
33 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
34 * top.c (execute_command_to_string): Update.
35 * utils.c (make_cleanup_restore_page_info): Remove.
36 (do_restore_page_info_cleanup): Remove.
37 (set_batch_flag_and_restore_page_info):
38 New.
39 (make_cleanup_restore_page_info): Remove.
40 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
41 (~set_batch_flag_and_restore_page_info): New
42 (make_cleanup_restore_uinteger): Remove.
43 (make_cleanup_restore_integer): Remove.
44 (struct restore_integer_closure): Remove.
45 (restore_integer): Remove.
46 * utils.h (struct set_batch_flag_and_restore_page_info): New
47 class.
48 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
49 (make_cleanup_restore_page_info): Remove.
50 (make_cleanup_restore_uinteger) Remove.
51 (make_cleanup_restore_integer) Remove.
52
07036511
TT
532017-10-03 Tom Tromey <tom@tromey.com>
54
55 * record-full.h (record_full_gdb_operation_disable_set): Return
56 scoped_restore_tmpl<int>.
57 * infrun.c (adjust_pc_after_break): Update.
58 (handle_signal_stop): Update.
59 * record-full.c (record_full_gdb_operation_disable_set): Return
60 scoped_restore_tmpl<int>.
61 (record_full_wait_1, record_full_insert_breakpoint)
62 (record_full_remove_breakpoint, record_full_save)
63 (record_full_goto_insn): Update.
64
45320ffa
TT
652017-10-02 Tom Tromey <tom@tromey.com>
66
67 PR rust/22236:
68 * rust-lang.c (rust_val_print_str): New function.
69 (val_print_struct): Call it.
70 (rust_subscript): Preserve name of slice type.
71
b3e3859b
TT
722017-10-02 Tom Tromey <tom@tromey.com>
73
74 * rust-lang.c (rust_subscript): Handle slices in
75 EVAL_AVOID_SIDE_EFFECTS case.
76
01af5e0d
TT
772017-10-02 Tom Tromey <tom@tromey.com>
78
79 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
80
888e3ddb
TT
812017-10-02 Tom Tromey <tom@tromey.com>
82
83 * rust-lang.h (rust_slice_type): Add "extern".
84
cc536b21
PA
852017-10-02 Tom Tromey <tom@tromey.com>
86 Pedro Alves <palves@redhat.com>
87
88 * ada-lang.h (ada_exc_info::operator<): Make const.
89 (ada_exc_info::operator==): Make const.
90 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
91 Make const.
92
386c8614
TT
932017-09-29 Tom Tromey <tom@tromey.com>
94
95 * target.c (read_whatever_is_readable): Change type of "result".
96 Update.
97 (free_memory_read_result_vector): Remove.
98 (read_memory_robust): Change return type. Update.
99 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
100 bin2hex, std::string.
101 * target.h (memory_read_result_s): Remove typedef.
102 (free_memory_read_result_vector): Remove.
103 (read_memory_robust): Return std::vector.
104
789c4b5e
TT
1052017-09-29 Tom Tromey <tom@tromey.com>
106
107 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
108
ab816a27
TT
1092017-09-29 Tom Tromey <tom@tromey.com>
110
111 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
112 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
113 operator< and operator==.
114 (ada_exceptions_list): Return a std::vector.
115 * ada-lang.c (ada_exc_info::operator<): Rename from
116 compare_ada_exception_info.
117 (ada_exc_info::operator==): New.
118 (sort_remove_dups_ada_exceptions_list): Change type of
119 "exceptions".
120 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
121 (ada_add_global_exceptions): Likewise.
122 (ada_exceptions_list_1): Return a std::vector.
123 (ada_exceptions_list): Likewise.
124
52f9abe4
TT
1252017-09-29 Tom Tromey <tom@tromey.com>
126
127 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
128 'std::set *'.
129 (print_one_inferior): Update.
130 (free_vector_of_ints): Remove.
131 (list_available_thread_groups): Change "ids" to std::set.
132 (mi_cmd_list_thread_groups): Update.
133 (struct collect_cores_data) <core>: Now a std::set.
134 (collect_cores): Update.
135 (unique): Remove.
136 (print_one_inferior): Update.
137
dcd5ddcc
TT
1382017-09-29 Tom Tromey <tom@tromey.com>
139
140 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
141 (mi_execute_async_cli_command): Likewise.
142 (mi_cmd_trace_frame_collected): Use field_fmt.
143
45d288cc
TT
1442017-09-29 Tom Tromey <tom@tromey.com>
145
146 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
147 gdb::byte_vector.
148
6afe2f4a
TT
1492017-09-29 Tom Tromey <tom@tromey.com>
150
151 * mi/mi-parse.c (mi_parse): Remove unused declaration.
152
9813429a
TT
1532017-09-29 Tom Tromey <tom@tromey.com>
154
155 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
156
2d6960b4
TT
1572017-09-29 Tom Tromey <tom@tromey.com>
158
159 * varobj.h (varobj_gen_name): Return std::string.
160 * varobj.c (varobj_gen_name): Return std::string.
161 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
162 (mi_cmd_var_delete): Don't copy "name".
163
784c453a
TT
1642017-09-29 Tom Tromey <tom@tromey.com>
165
166 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
167 (mi_cmd_break_insert_1): Update.
168
a9bc57b9
TT
1692017-09-29 Tom Tromey <tom@tromey.com>
170
171 * target.h (make_scoped_defer_target_commit_resume): Update.
172 * target.c (make_scoped_defer_target_commit_resume): Rename from
173 make_cleanup_defer_target_commit_resume. Return a
174 scoped_restore.
175 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
176
9754d8c4
TT
1772017-09-29 Tom Tromey <tom@tromey.com>
178
179 * main.c (captured_main_1): Remove unused declaration.
180 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
181
99ef965c
TT
1822017-09-29 Tom Tromey <tom@tromey.com>
183
184 * symtab.c (search_symbols): Remove unused outer cleanup.
185 (make_source_files_completion_list): Remove unused declaration.
186
42518ba7
TT
1872017-09-29 Tom Tromey <tom@tromey.com>
188
189 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
190
726b2169
TT
1912017-09-29 Tom Tromey <tom@tromey.com>
192
193 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
194 gdb::byte_vector.
195
55b06432
TT
1962017-09-29 Tom Tromey <tom@tromey.com>
197
198 * complaints.c (vcomplaint): Use std::string.
199
8abcee91
TT
2002017-09-29 Tom Tromey <tom@tromey.com>
201
202 * tracepoint.c (trace_variable_command): Use std::string.
203 (encode_actions_1): Remove unused declarations.
204 (create_tsv_from_upload): Use std::string.
205
6ad94bc7
TT
2062017-09-29 Tom Tromey <tom@tromey.com>
207
208 * cp-support.c (gdb_demangle): Use std::string.
209
2003f3d8
TT
2102017-09-29 Tom Tromey <tom@tromey.com>
211
212 * stack.c (parse_frame_specification): Use std::string
213 (info_frame_command): Use gdb::unique_xmalloc_ptr.
214
8f8accb5
TT
2152017-09-29 Tom Tromey <tom@tromey.com>
216
217 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
218
200aa7b1
TT
2192017-09-29 Tom Tromey <tom@tromey.com>
220
221 * utils.c (vfprintf_maybe_filtered): Use std::string.
222 (vfprintf_unfiltered): Likewise.
223
606aae8a
TT
2242017-09-29 Tom Tromey <tom@tromey.com>
225
226 * event-top.c (top_level_prompt): Return std::string.
227 (display_gdb_prompt): Update.
228
bd413795
TT
2292017-09-29 Tom Tromey <tom@tromey.com>
230
231 * unittests/common-utils-selftests.c (format): New function.
232 (string_vprintf_tests): New function.
233 (_initialize_common_utils_selftests): Register new tests.
234 * common/common-utils.c (string_vprintf): New function.
235 * common/common-utils.h (string_vprintf): Declare.
236
256642e8
PA
2372017-09-29 Pedro Alves <palves@redhat.com>
238
239 * common/rsp-low.c (unpack_varlen_hex): Constify.
240 * common/rsp-low.h (unpack_varlen_hex): Constify.
241 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
242 Constify.
243 * remote.c (remote_set_permissions, read_ptid)
244 (remote_current_thread, remote_get_threads_with_qthreadinfo)
245 (remote_static_tracepoint_marker_at)
246 (remote_static_tracepoint_markers_by_strid)
247 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
248 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
249 (parse_tracepoint_definition, parse_tsv_definition)
250 (parse_static_tracepoint_marker_definition): Constify.
251 * tracepoint.h (parse_static_tracepoint_marker_definition)
252 (parse_trace_status, parse_tracepoint_status)
253 (parse_tracepoint_definition, parse_tsv_definition): Constify.
254
b6bb3468
PA
2552017-09-29 Pedro Alves <palves@redhat.com>
256
257 * remote.c (target_buf, target_buf_size): Delete.
258 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
259 Use the connection's packet buffer instead.
260 All callers adjusted.
261 (_initialize_remote): Remove references to target_buf and
262 target_buf_size.
263
b2f8eb7a
PA
2642017-09-28 Pedro Alves <palves@redhat.com>
265
266 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
267 unittests/common-utils-selftests.c.
268 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
269 (COMMON_OBS): Remove utils-selftests.o.
270 * utils-selftests.c: Move to ...
271 * unittests/common-utils-selftests.c: ... here and rename self
272 test to "string_printf".
273
08302ed2
DE
2742017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
275
276 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
277 having NULL cus or tus.
278
96a5a1d3
UW
2792017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
280
281 * arm-tdep.c: (convert_from_extended): Remove.
282 (convert_to_extended): Likewise.
283 (arm_extract_return_value): Use convert_typed_floating.
284 (arm_store_return_value): Likewise.
285
286 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
287 * sh-tdep.c: Do not include "floatformat.h".
288 (sh_littlebyte_bigword_type): New function.
289 (sh_register_convert_to_virtual): Use convert_typed_floating.
290 (sh_register_convert_to_raw): Likewise.
291 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
292 (sh64_littlebyte_bigword_type): New function.
293 (sh64_extract_return_value): Use convert_typed_floating.
294 (sh64_register_convert_to_virtual): Likewise.
295 (sh64_register_convert_to_raw): Likewise.
296
0db7851f
UW
2972017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
298
299 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
300 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
301
302 * gdbtypes.h (union type_specific): Make field floatformat hold
303 just a single struct floatformat, not an array.
304 (floatformat_from_type): Move here.
305 * gdbtypes.c (floatformat_from_type): Move here. Update to
306 changed TYPE_FLOATFORMAT definition.
307 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
308 (recursive_dump_type): Likewise.
309 (init_float_type): Install correct floatformat for byte order.
310 (arch_float_type): Likewise.
311
77b7c781
UW
3122017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
313
314 * gdbtypes.c (init_type): Change incoming argument from
315 length-in-bytes to length-in-bits. Assert length is a
316 multiple of TARGET_CHAR_BITS.
317 (arch_type, arch_flags_type): Likewise.
318 (init_integer_type): Update call to init_type.
319 (init_character_type): Likewise.
320 (init_boolean_type): Likewise.
321 (init_float_type): Likewise.
322 (init_decfloat_type): Likewise.
323 (init_complex_type): Likewise.
324 (init_pointer_type): Likewise.
325 (objfile_type): Likewise.
326 (arch_integer_type): Update call to arch_type.
327 (arch_character_type): Likewise.
328 (arch_boolean_type): Likewise.
329 (arch_float_type): Likewise.
330 (arch_decfloat_type): Likewise.
331 (arch_complex_type): Likewise.
332 (arch_pointer_type): Likewise.
333 (gdbtypes_post_init): Likewise.
334
335 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
336 (read_base_type): Likewise.
337 * mdebugread.c (basic_type): Likewise.
338 * stabsread.c (dbx_init_float_type): Likewise.
339 (rs6000_builtin_type): Likewise.
340 (read_range_type): Likewise. Also, fix call to init_integer_type
341 with erroneous length argument.
342
343 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
344 * d-lang.c (build_d_types): Likewise.
345 * f-lang.c (build_fortran_types): Likewise.
346 * go-lang.c (build_go_types): Likewise.
347 * opencl-lang.c (build_opencl_types): Likewise.
348 * jit.c (finalize_symtab): Likewise.
349 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
350 (build_std_type_info_type): Likewise.
351 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
352 update call to arch_flags_type.
353
354 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
355 arch_type.
356 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
357 * windows-tdep.c (windows_get_tlb_type): Likewise.
358
359 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
360 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
361 * m32c-tdep.c (make_types): Likewise.
362 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
363 (rl78_psw_type): Update call to arch_flags_type.
364 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
365 * rx-tdep.c (rx_psw_type): Likewise.
366 (rx_fpsw_type): Likewise.
367 * sparc-tdep.c (sparc_psr_type): Likewise.
368 (sparc_fsr_type): Likewise.
369 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
370 (sparc64_ccr_type): Likewise.
371 (sparc64_fsr_type): Likewise.
372 (sparc64_fprs_type): Likewise.
373
f21b4d5c
TT
3742017-09-27 Tom Tromey <tom@tromey.com>
375
376 * findcmd.c (find_command): Constify.
377
643c2ffa
TT
3782017-09-27 Tom Tromey <tom@tromey.com>
379
380 * ada-tasks.c (task_command_1, task_command): Constify.
381
510e5e56
TT
3822017-09-27 Tom Tromey <tom@tromey.com>
383
384 * symtab.c (maintenance_print_symbol_cache)
385 (maintenance_flush_symbol_cache)
386 (maintenance_print_symbol_cache_statistics): Constify.
387
e503b191
TT
3882017-09-27 Tom Tromey <tom@tromey.com>
389
390 * inferior.c (detach_inferior_command, kill_inferior_command)
391 (inferior_command): Constify.
392
4e001312
TT
3932017-09-27 Tom Tromey <tom@tromey.com>
394
395 * regcache.c (regcache_print, maintenance_print_registers)
396 (maintenance_print_raw_registers)
397 (maintenance_print_cooked_registers)
398 (maintenance_print_register_groups)
399 (maintenance_print_remote_registers): Constify.
400
77763700
TT
4012017-09-27 Tom Tromey <tom@tromey.com>
402
403 * printcmd.c (map_display_numbers, undisplay_command)
404 (enable_disable_display_command, enable_display_command)
405 (disable_display_command): Constify.
406
4495129a
TT
4072017-09-27 Tom Tromey <tom@tromey.com>
408
409 * breakpoint.h (delete_command): Don't declare.
410 * breakpoint.c (delete_command, enable_once_command)
411 (enable_count_command, enable_delete_command, breakpoint_1)
412 (maintenance_info_breakpoints, stopin_command, stopat_command)
413 (delete_command, delete_trace_command, save_breakpoints)
414 (save_breakpoints_command, save_tracepoints_command): Constify.
415
3088cf40
TT
4162017-09-27 Tom Tromey <tom@tromey.com>
417
418 * macrocmd.c (macro_expand_command, macro_expand_once_command)
419 (skip_ws, extract_identifier, macro_define_command)
420 (macro_undef_command, macro_list_command): Constify.
421
69f476a3
TT
4222017-09-27 Tom Tromey <tom@tromey.com>
423
424 * infcmd.c (environment_info, set_environment_command)
425 (unset_environment_command, path_info, info_proc_cmd_1)
426 (info_proc_cmd_mappings, info_proc_cmd_stat)
427 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
428 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
429
c4a3e68e
TT
4302017-09-27 Tom Tromey <tom@tromey.com>
431
432 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
433 Constify.
434
c9d31bd6
TT
4352017-09-27 Tom Tromey <tom@tromey.com>
436
437 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
438
1f3f85eb
TT
4392017-09-27 Tom Tromey <tom@tromey.com>
440
441 * demangle.c (demangle_command): Constify.
442
9c504b5d
TT
4432017-09-27 Tom Tromey <tom@tromey.com>
444
445 * progspace.c (maintenance_info_program_spaces_command):
446 Constify.
447
6663cf91
TT
4482017-09-27 Tom Tromey <tom@tromey.com>
449
450 * compile/compile.c (check_raw_argument, compile_file_command)
451 (compile_code_command, compile_print_command): Constify.
452
34e5fa26
TT
4532017-09-27 Tom Tromey <tom@tromey.com>
454
455 * reggroups.c (maintenance_print_reggroups): Constify.
456
8384c356
TT
4572017-09-27 Tom Tromey <tom@tromey.com>
458
459 * dwarf2read.c (save_gdb_index_command): Constify.
460
884beb0c
TT
4612017-09-27 Tom Tromey <tom@tromey.com>
462
463 * stap-probe.c (info_probes_stap_command): Constify.
464
e0b2930c
TT
4652017-09-27 Tom Tromey <tom@tromey.com>
466
467 * fork-child.c (unset_exec_wrapper_command): Constify.
468
f938677d
TT
4692017-09-27 Tom Tromey <tom@tromey.com>
470
471 * btrace.c (get_uint, get_context_size, no_chunk)
472 (maint_btrace_packet_history_cmd)
473 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
474 (maint_info_btrace_cmd): Constify.
475
8949cb87
TT
4762017-09-27 Tom Tromey <tom@tromey.com>
477
478 * reverse.c (delete_bookmark_command): Constify.
479
ac88e2de
TT
4802017-09-27 Tom Tromey <tom@tromey.com>
481
482 * remote.c (set_memory_packet_size)
483 (set_memory_write_packet_size, show_memory_write_packet_size)
484 (set_memory_read_packet_size, show_memory_read_packet_size)
485 (compare_sections_command, packet_command, remote_put_command)
486 (remote_get_command, remote_delete_command): Constify.
487
bd4c9dfe
TT
4882017-09-27 Tom Tromey <tom@tromey.com>
489
490 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
491 (set_mipsfpu_double_command, set_mipsfpu_none_command)
492 (set_mipsfpu_auto_command): Constify.
493
5e93d4c6
TT
4942017-09-27 Tom Tromey <tom@tromey.com>
495
496 * cli/cli-cmds.h (cd_command): Constify.
497 * cli/cli-cmds.c (cd_command): Constify.
498
fc41a75b
TT
4992017-09-27 Tom Tromey <tom@tromey.com>
500
501 * thread.c (thread_name_command, thread_find_command): Constify.
502
67810076
TT
5032017-09-27 Tom Tromey <tom@tromey.com>
504
505 * probe.c (enable_probes_command, disable_probes_command):
506 Constify.
507
1d8b34a7
TT
5082017-09-27 Tom Tromey <tom@tromey.com>
509
510 * symfile.c (symbol_file_command): Constify.
511 * gdbcore.h (deprecated_file_changed_hook): Constify.
512 * exec.c (deprecated_file_changed_hook, exec_file_command)
513 (file_command): Constify.
514 * defs.h (symbol_file_command): Constify.
515
442019e1
TT
5162017-09-27 Tom Tromey <tom@tromey.com>
517
518 * remote-fileio.c (set_system_call_allowed)
519 (show_system_call_allowed): Constify.
520
2983f7cb
TT
5212017-09-27 Tom Tromey <tom@tromey.com>
522
523 * tracepoint.c (delete_trace_variable_command)
524 (tfind_end_command, tfind_start_command, tfind_pc_command)
525 (tfind_tracepoint_command, tfind_line_command)
526 (tfind_range_command, tfind_outside_command): Constify.
527
4fd41b24
TT
5282017-09-27 Tom Tromey <tom@tromey.com>
529
530 * ax-gdb.c (maint_agent_printf_command, agent_command)
531 (agent_eval_command): Constify.
532
f2fc3015
TT
5332017-09-27 Tom Tromey <tom@tromey.com>
534
535 * tracepoint.c (info_scope_command): Constify.
536 * python/python.c (gdbpy_decode_line): Constify.
537 * python/py-breakpoint.c (bppy_init): Constify.
538 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
539 * location.h: (new_linespec_location)
540 (string_to_event_location_basic, string_to_event_location):
541 Constify.
542 * location.c (new_linespec_location)
543 (string_to_event_location_basic, string_to_event_location):
544 Constify.
545 * linespec.h (decode_line_with_current_source)
546 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
547 * linespec.c (linespec_lex_to_end)
548 (decode_line_with_current_source)
549 (decode_line_with_last_displayed): Constify.
550 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
551 Constify.
552 * cli/cli-cmds.c (edit_command, list_command): Constify.
553 * breakpoint.h (until_break_command, watch_command_wrapper)
554 (awatch_command_wrapper, rwatch_command_wrapper)
555 (init_ada_exception_breakpoint): Constify.
556 * breakpoint.c (break_command_1, dprintf_command)
557 (break_range_command, watch_command_wrapper)
558 (rwatch_command_wrapper, awatch_command_wrapper)
559 (until_break_command, init_ada_exception_breakpoint)
560 (strace_marker_create_sals_from_location, trace_command)
561 (ftrace_command, strace_command, struct tracepoint): Constify.
562 * ax-gdb.c (agent_command_1): Constify.
563 * ada-lang.c (ada_exception_sal): Constify.
564
8c2f95f4
TT
5652017-09-27 Tom Tromey <tom@tromey.com>
566
567 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
568 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
569 (get_context_size, no_chunk, get_insn_history_modifiers)
570 (cmd_record_insn_history, get_call_history_modifiers)
571 (cmd_record_call_history): Constify.
572
a0d65762
TT
5732017-09-27 Tom Tromey <tom@tromey.com>
574
575 * source.c (show_substitute_path_command)
576 (unset_substitute_path_command, set_substitute_path_command):
577 Constify.
578
58971144
TT
5792017-09-27 Tom Tromey <tom@tromey.com>
580
581 * typeprint.c (maintenance_print_type): Constify.
582 * maint.c (maintenance_dump_me, maintenance_demangle)
583 (maintenance_time_display, maintenance_info_sections)
584 (maintenance_print_statistics, maintenance_deprecate)
585 (maintenance_undeprecate): Constify.
586 (maintenance_do_deprecate): Constify. Use std::string.
587 (maintenance_selftest): Constify.
588 * gdbtypes.h (maintenance_print_type): Constify.
589
c482f52c
TT
5902017-09-27 Tom Tromey <tom@tromey.com>
591
592 * hppa-tdep.c (unwind_command): Constify.
593
e100df1a
TT
5942017-09-27 Tom Tromey <tom@tromey.com>
595
596 * target-descriptions.c (unset_tdesc_filename_cmd)
597 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
598 Constify.
599
31d56ade
TT
6002017-09-27 Tom Tromey <tom@tromey.com>
601
602 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
603
b961da0b
TT
6042017-09-27 Tom Tromey <tom@tromey.com>
605
606 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
607
e2d8ae16
TT
6082017-09-27 Tom Tromey <tom@tromey.com>
609
610 * tui/tui-regs.c (tui_reg_command): Constify.
611
863779b0
TT
6122017-09-27 Tom Tromey <tom@tromey.com>
613
614 * skip.c (skip_file_command, skip_function_command)
615 (skip_enable_command, skip_disable_command, skip_delete_command):
616 Constify.
617
cdb34d4a
TT
6182017-09-27 Tom Tromey <tom@tromey.com>
619
620 * record-btrace.c (cmd_record_btrace_bts_start)
621 (cmd_record_btrace_pt_start): Constify.
622
e99c83e7
TT
6232017-09-27 Tom Tromey <tom@tromey.com>
624
625 * symmisc.c (maintenance_print_symbols)
626 (maintenance_print_msymbols, maintenance_print_objfiles)
627 (maintenance_info_symtabs, maintenance_check_symtabs)
628 (maintenance_expand_symtabs, maintenance_info_line_tables):
629 Constify.
630
32faf971
TT
6312017-09-27 Tom Tromey <tom@tromey.com>
632
633 * top.c (new_ui_command): Constify.
634
2cf311eb
TT
6352017-09-27 Tom Tromey <tom@tromey.com>
636
637 * symfile.c (add_symbol_file_command)
638 (remove_symbol_file_command, list_overlays_command)
639 (map_overlay_command, unmap_overlay_command)
640 (overlay_auto_command, overlay_manual_command)
641 (overlay_off_command, overlay_load_command): Constify.
642
e6738699
TT
6432017-09-27 Tom Tromey <tom@tromey.com>
644
645 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
646 (info_spu_mailbox_command, info_spu_dma_command)
647 (info_spu_proxydma_command): Constify.
648
aa360cd5
TT
6492017-09-27 Tom Tromey <tom@tromey.com>
650
651 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
652
898241a5
TT
6532017-09-27 Tom Tromey <tom@tromey.com>
654
655 * cli/cli-script.c (user_defined_command): Constify.
656
2d0ac106
TT
6572017-09-27 Tom Tromey <tom@tromey.com>
658
659 * cli/cli-dump.c (dump_memory_command, dump_value_command)
660 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
661 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
662 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
663 (dump_binary_value, append_binary_memory, append_binary_value):
664 Constify.
665 (struct dump_context) <func>: Constify.
666 (add_dump_command): Update.
667
dede02ce
TT
6682017-09-27 Tom Tromey <tom@tromey.com>
669
670 * cli/cli-cmds.c (show_version, show_configuration)
671 (source_command, show_user): Constify.
672
d3cb6b99
TT
6732017-09-27 Tom Tromey <tom@tromey.com>
674
675 * target.c (maintenance_print_target_stack): Constify.
676
1970a12f
TT
6772017-09-27 Tom Tromey <tom@tromey.com>
678
679 * interps.c (interpreter_exec_cmd): Constify.
680
41243651
TT
6812017-09-27 Tom Tromey <tom@tromey.com>
682
683 * record-full.c (cmd_record_full_restore): Constify.
684
4465d9db
TT
6852017-09-27 Tom Tromey <tom@tromey.com>
686
687 * memattr.c (enable_mem_command, disable_mem_command)
688 (delete_mem_command): Constify.
689
ad25e423
TT
6902017-09-27 Tom Tromey <tom@tromey.com>
691
692 * value.c (show_convenience): Constify.
693
d64097b1
TT
6942017-09-27 Tom Tromey <tom@tromey.com>
695
696 * gdbcore.h (core_file_command): Update.
697 * corefile.c (core_file_command): Constify.
698
4d4589ef
TT
6992017-09-27 Tom Tromey <tom@tromey.com>
700
701 * user-regs.c (maintenance_print_user_registers): Constify.
702
32a7bf17
TT
7032017-09-27 Tom Tromey <tom@tromey.com>
704
705 * cp-namespace.c (maintenance_cplus_namespace): Constify.
706
4a475551
TT
7072017-09-27 Tom Tromey <tom@tromey.com>
708
709 * cp-support.c (first_component_command): Constify.
710
990b9f9f
TT
7112017-09-27 Tom Tromey <tom@tromey.com>
712
713 * psymtab.c (maintenance_print_psymbols)
714 (maintenance_info_psymtabs, maintenance_check_psymtabs):
715 Constify.
716
c281872e
TT
7172017-09-27 Tom Tromey <tom@tromey.com>
718
719 * windows-tdep.c (display_tib): Constify.
720
5b64bf74
TT
7212017-09-27 Tom Tromey <tom@tromey.com>
722
723 * linux-fork.c (delete_checkpoint_command)
724 (detach_checkpoint_command): Constify.
725
4ada038f
TT
7262017-09-27 Tom Tromey <tom@tromey.com>
727
728 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
729
57f5a81b
TT
7302017-09-27 Tom Tromey <tom@tromey.com>
731
732 * arc-tdep.c (dump_arc_instruction_command): Constify.
733
b0a8e6c4
TT
7342017-09-27 Tom Tromey <tom@tromey.com>
735
736 * valprint.c (set_radix, show_radix): Constify.
737
8d97dc1c
TT
7382017-09-27 Tom Tromey <tom@tromey.com>
739
740 * dtrace-probe.c (info_probes_dtrace_command): Constify.
741
eb7c454d
TT
7422017-09-27 Tom Tromey <tom@tromey.com>
743
744 * command.h (not_just_help_class_command): Update.
745 * cli/cli-decode.h (not_just_help_class_command): Update.
746 * cli/cli-decode.c (not_just_help_class_command): Constify.
747
e4e33335
TT
7482017-09-27 Tom Tromey <tom@tromey.com>
749
750 * gdb_bfd.c (maintenance_info_bfds): Constify.
751
0450cc4c
TT
7522017-09-27 Tom Tromey <tom@tromey.com>
753
754 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
755 overloads.
756 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
757 (do_const_cfunc): New function.
758 (cmd_cfunc_eq): New overload.
759 (cli_user_command_p): Check do_const_cfunc.
760 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
761 const_cfunc.
762 * command.h (add_cmd): Add const overload and no-function
763 overload.
764 (set_cmd_cfunc): Add const overload.
765 (cmd_const_cfunc_ftype): Declare.
766 (cmd_cfunc_eq): Add const overload.
767 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
768 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
769 overload.
770
a9bbfbd8
TT
7712017-09-27 Tom Tromey <tom@tromey.com>
772
773 * macroexp.c (get_next_token_for_substitution): New function.
774 (substitute_args): Call it. Check for __VA_OPT__.
775
5230b05a
WT
7762017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
777 Pedro Alves <palves@redhat.com>
778
779 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
780 producer_is_icc_lt_14.
781 (producer_is_icc_lt_14): New function.
782 (check_producer): Add code for checking version of ICC.
783 (producer_is_icc): Move to producer.c.
784 (read_structure_type): Restrict ICC workaround to ICC<14.
785 * producer.c: Include selftest.h.
786 (producer_is_icc, producer_parsing_tests, _initialize_producer):
787 New functions.
788 * producer.h (producer_is_icc): New declaration.
789
b32b108a
WT
7902017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
791
792 * Makefile.in (SFILES): Add producer.c.
793 (COMMON_OBS): Add producer.o
794 * amd64-tdep.c (producer.h): Add new include.
795 * dwarf2read.c (producer.h): Add new include.
796 * producer.c: New file.
797 * producer.h: New file.
798 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
799 producer.c.
800 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
801 producer.h.
802
5007d765
MK
8032017-09-26 Matthias Klose <doko@ubuntu.com>
804
805 * configure.ac: Search ncursesw before ncurses.
806 Check ncursesw/ncurses.h before ncurses/ncurses.h.
807 * gdb_curses.h: Include <ncursesw/ncurses.h>
808 * config.in, configure: Regenerate.
809
281c4447
RO
8102017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
811
812 PR gdb/22185
813 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
814 obsolete.
815 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
816 Remove i386sol2 support.
817 * configure.nat <i386sol2>: Remove.
818 <sol2-64>: Fold into ...
819 <sol2>: ... this.
820 Move common settings to default section.
821 Add sol-thread.o.
822 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
823 x86_64-*-solaris2.1[0-9]*>: Rename to ...
824 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
825 <i[34567]86-*-solaris*>: Remove.
826 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
827
828 * configure.ac: Remove wctype in libw check.
829 (_MSE_INT_H): Don't define on Solaris 7-9.
830 <solaris*>: Remove libthread_db.so.1 check.
831 * configure: Regenerate.
832 * config.in: Regenerate.
833
834 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
835 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
836 (gdb_ps_size_t): Remove.
837 Use base types in users.
838 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
839
840 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
841
39b06c20
RO
8422017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
843
844 PR build/22206
845 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
846 (adi_is_addr_mapped): Likewise.
847 (PSR_ICC): Don't redefine.
848 (PSR_IMPL): Likewise.
849
6c3e20f1
TT
8502017-09-25 Tom Tromey <tom@tromey.com>
851
852 * regcache.c (regcache::dump): Use string_printf.
853
b292235f
TT
8542017-09-25 Tom Tromey <tom@tromey.com>
855
856 * regcache.c (class regcache_invalidator): New.
857 (struct register_to_invalidate): Remove.
858 (make_cleanup_regcache_invalidate): Remove.
859 (regcache::raw_write): Use regcache_invalidator.
860
9ac86b52
TT
8612017-09-25 Tom Tromey <tom@tromey.com>
862
863 * spu-tdep.c (spu2ppu_sniffer): Update.
864 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
865 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
866 Remove.
867 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
868 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
869 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
870 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
871 (frame_pop): Update.
872
c0e383c6
TT
8732017-09-25 Tom Tromey <tom@tromey.com>
874
875 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
876 * regcache.h (regcache_xfree): Don't declare.
877 * regcache.c (regcache_xfree): Remove.
878 (do_regcache_xfree): Use delete.
879 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
880 * linux-fork.c (free_fork): Use delete.
881 (fork_save_infrun_state): Likewise.
882 * jit.c (jit_dealloc_cache): Use delete.
883 * infrun.c (discard_infcall_suspend_state): Use delete.
884
791199cc
TT
8852017-09-25 Tom Tromey <tom@tromey.com>
886
887 * regcache.h (regcache_xmalloc): Don't declare.
888 (regcache_raw_set_cached_value): Update comment.
889 * regcache.c (regcache_xmalloc): Remove.
890 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
891 * jit.c (jit_frame_sniffer): Use new.
892 * frame.c (frame_save_as_regcache): Use new.
893
289e23aa
AA
8942017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
895
896 * NEWS: Advertise support for guarded-storage registers on IBM z.
897
1b63490c
AA
8982017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
899
900 * s390-linux-nat.c (have_regset_gs): New static variable.
901 (s390_linux_fetch_inferior_registers): Handle guarded-storage
902 control block and guarded-storage broadcast control regsets.
903 (s390_read_description): Detect whether the target has
904 guarded-storage support, return appropriate tdesc.
905 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
906 (features/s390x-gs-linux64.c): Likewise.
907 (struct gdbarch_tdep) <have_gs>: New field.
908 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
909 (s390_gsbc_regset): New variables.
910 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
911 and s390_gsbc_regset, if applicable.
912 (s390_core_read_description): Check whether core file was from a
913 target with guarded-storage support; include appropriate regsets.
914 (s390_gdbarch_init): Add registers for guarded-storage support.
915 (_initialize_s390_tdep): Initialize new target descriptions that
916 include registers for guarded-storage support.
917 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
918 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
919 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
920 (S390_NUM_REGS): Adjust macro definition.
921 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
922 (tdesc_s390x_gs_linux64): New declarations.
923
96235dc1
AA
9242017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
925
926 * features/s390-gs-linux64.xml: New file.
927 * features/s390-gs.xml: New file.
928 * features/s390-gsbc.xml: New file.
929 * features/s390x-gs-linux64.xml: New file.
930 * features/Makefile (WHICH): Add s390-gs-linux64 and
931 s390x-gs-linux64.
932 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
933 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
934 * features/s390-gs-linux64.c: New generated file.
935 * features/s390x-gs-linux64.c: New file.
936 * regformats/s390-gs-linux64.dat: New file.
937 * regformats/s390x-gs-linux64.dat: New file.
938
b4a7c699
TT
9392017-09-23 Tom Tromey <tom@tromey.com>
940
941 * defs.h (make_cleanup_override_quit_handler): Don't declare.
942
c2f97536
TT
9432017-09-22 Tom Tromey <tom@tromey.com>
944
945 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
946 type to scoped_restore_tmpl.
947 <scoped_input_handler>: Initialize m_quit_handler directly.
948
43573013
SDJ
9492017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
950
951 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
952 (cd_command): Likewise. Free "current_directory" before
953 assigning to it.
954 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
955 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
956 * top.c (gdb_dirbuf): Remove global declaration.
957 * top.h (gdb_dirbuf): Likewise.
958
6ec2e0f5
SDJ
9592017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
960
961 * gnulib/aclocal.m4: Regenerate.
962 * gnulib/config.in: Regenerate.
963 * gnulib/configure: Regenerate.
964 * gnulib/import/Makefile.am: Regenerate.
965 * gnulib/import/Makefile.in: Regenerate.
966 * gnulib/import/assure.h: New file.
967 * gnulib/import/at-func.c: Likewise
968 * gnulib/import/chdir-long.c: New file.
969 * gnulib/import/chdir-long.h: New file.
970 * gnulib/import/cloexec.c: New file.
971 * gnulib/import/cloexec.h: New file.
972 * gnulib/import/close.c: New file.
973 * gnulib/import/closedir.c: New file.
974 * gnulib/import/dirent-private.h: New file.
975 * gnulib/import/dup-safer.c: New file.
976 * gnulib/import/dup.c: New file.
977 * gnulib/import/dup2.c: New file.
978 * gnulib/import/error.c: New file.
979 * gnulib/import/error.h: New file.
980 * gnulib/import/exitfail.c: New file.
981 * gnulib/import/exitfail.h: New file.
982 * gnulib/import/fchdir.c: New file.
983 * gnulib/import/fcntl.c: New file.
984 * gnulib/import/fcntl.in.h: New file.
985 * gnulib/import/fd-hook.c: New file.
986 * gnulib/import/fd-hook.h: New file.
987 * gnulib/import/fd-safer.c: New file.
988 * gnulib/import/fdopendir.c: New file.
989 * gnulib/import/filename.h: New file.
990 * gnulib/import/filenamecat-lgpl.c: New file.
991 * gnulib/import/filenamecat.h: New file.
992 * gnulib/import/fstat.c: New file.
993 * gnulib/import/fstatat.c: New file.
994 * gnulib/import/getcwd-lgpl.c: New file.
995 * gnulib/import/getcwd.c: New file.
996 * gnulib/import/getdtablesize.c: New file.
997 * gnulib/import/getlogin_r.c: New file.
998 * gnulib/import/getprogname.c: New file.
999 * gnulib/import/getprogname.h: New file.
1000 * gnulib/import/gettext.h: New file.
1001 * gnulib/import/glob-libc.h: New file.
1002 * gnulib/import/glob.c: New file.
1003 * gnulib/import/glob.in.h: New file.
1004 * gnulib/import/intprops.h: New file.
1005 * gnulib/import/m4/chdir-long.m4: New file.
1006 * gnulib/import/m4/close.m4: New file.
1007 * gnulib/import/m4/closedir.m4: New file.
1008 * gnulib/import/m4/d-ino.m4: New file.
1009 * gnulib/import/m4/d-type.m4: New file.
1010 * gnulib/import/m4/dup.m4: New file.
1011 * gnulib/import/m4/dup2.m4: New file.
1012 * gnulib/import/m4/error.m4: New file.
1013 * gnulib/import/m4/fchdir.m4: New file.
1014 * gnulib/import/m4/fcntl.m4: New file.
1015 * gnulib/import/m4/fcntl_h.m4: New file.
1016 * gnulib/import/m4/fdopendir.m4: New file.
1017 * gnulib/import/m4/filenamecat.m4: New file.
1018 * gnulib/import/m4/fstat.m4: New file.
1019 * gnulib/import/m4/fstatat.m4: New file.
1020 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
1021 * gnulib/import/m4/getcwd-path-max.m4: New file.
1022 * gnulib/import/m4/getcwd.m4: New file.
1023 * gnulib/import/m4/getdtablesize.m4: New file.
1024 * gnulib/import/m4/getlogin_r.m4: New file.
1025 * gnulib/import/m4/getprogname.m4: New file.
1026 * gnulib/import/m4/glob.m4: New file.
1027 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
1028 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
1029 * gnulib/import/m4/mempcpy.m4: New file.
1030 * gnulib/import/m4/memrchr.m4: New file.
1031 * gnulib/import/m4/mode_t.m4: New file.
1032 * gnulib/import/m4/msvc-inval.m4: New file.
1033 * gnulib/import/m4/msvc-nothrow.m4: New file.
1034 * gnulib/import/m4/open.m4: New file.
1035 * gnulib/import/m4/openat.m4: New file.
1036 * gnulib/import/m4/opendir.m4: New file.
1037 * gnulib/import/m4/readdir.m4: New file.
1038 * gnulib/import/m4/realloc.m4: New file.
1039 * gnulib/import/m4/rewinddir.m4: New file.
1040 * gnulib/import/m4/save-cwd.m4: New file.
1041 * gnulib/import/m4/strdup.m4: New file.
1042 * gnulib/import/m4/strerror.m4: New file.
1043 * gnulib/import/m4/unistd-safer.m4: New file.
1044 * gnulib/import/mempcpy.c: New file.
1045 * gnulib/import/memrchr.c: New file.
1046 * gnulib/import/msvc-inval.c: New file.
1047 * gnulib/import/msvc-inval.h: New file.
1048 * gnulib/import/msvc-nothrow.c: New file.
1049 * gnulib/import/msvc-nothrow.h: New file.
1050 * gnulib/import/open.c: New file.
1051 * gnulib/import/openat-die.c: New file.
1052 * gnulib/import/openat-priv.h: New file.
1053 * gnulib/import/openat-proc.c: New file.
1054 * gnulib/import/openat.c: New file.
1055 * gnulib/import/openat.h: New file.
1056 * gnulib/import/opendir.c: New file.
1057 * gnulib/import/pipe-safer.c: New file.
1058 * gnulib/import/readdir.c: New file.
1059 * gnulib/import/realloc.c: New file.
1060 * gnulib/import/rewinddir.c: New file.
1061 * gnulib/import/save-cwd.c: New file.
1062 * gnulib/import/save-cwd.h: New file.
1063 * gnulib/import/strdup.c: New file.
1064 * gnulib/import/strerror-override.c: New file.
1065 * gnulib/import/strerror-override.h: New file.
1066 * gnulib/import/strerror.c: New file.
1067 * gnulib/import/unistd--.h: New file.
1068 * gnulib/import/unistd-safer.h: New file.
1069 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
1070 "getcwd" and "glob".
1071 * ser-tcp.c: Undefine "close" before redefining it.
1072
432ae719
SM
10732017-09-21 Simon Marchi <simon.marchi@ericsson.com>
1074
1075 * guile/scm-value.c (gdbscm_value_address): Initialize address,
1076 get rid of res_val.
1077
4fa7574e
RO
10782017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1079
1080 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
1081 <sol2,sparc>: Likewise.
1082 <sol2-64,i386>: Likewise.
1083
1084 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
1085 -Wdeprecated-declarations on *-*-solaris*.
1086 * configure: Regenerate.
1087
1088 * procfs.c: Include "nat/inferior.h".
1089 (procfs_info_proc): Fix typo.
1090
f6327dcb
KB
10912017-09-21 Kevin Buettner <kevinb@redhat.com>
1092
1093 * remote.c (vector): Include.
1094 (struct private_thread_info): Add field, thread_handle.
1095 (free_private_thread_info): Deallocate storage associated with
1096 thread handle.
1097 (get_private_info_thread): Initialize `thread_handle' field.
1098 (struct thread_item): Add field, thread_handle.
1099 (clear_threads_listing_context): Deallocate storage associated
1100 with thread handle.
1101 (start_thread): Add support for "handle" attribute.
1102 (thread_attributes): Add "handle".
1103 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
1104 field.
1105 (remote_update_thread_list): Update thread_handle.
1106 (remote_thread_handle_to_thread_info): New function.
1107 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
1108
fbbe5337
KB
11092017-09-21 Kevin Buettner <kevinb@redhat.com>
1110
1111 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
1112 function.
1113 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
1114 * python/python-internal.h (thread_object_type): Declare.
1115
e04ee09e
KB
11162017-09-21 Kevin Buettner <kevinb@redhat.com>
1117
1118 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
1119 (target_thread_handle_to_thread_info): Declare.
1120 * target.c (target_thread_handle_to_thread_info): New function.
1121 * target-delegates.c: Regenerate.
1122 * gdbthread.h (find_thread_by_handle): Declare.
1123 * thread.c (find_thread_by_handle): New function.
1124 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
1125 function.
1126 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
1127
1e5b66ed
SM
11282017-09-21 Simon Marchi <simon.marchi@ericsson.com>
1129
1130 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
1131
ebe48ba0
SM
11322017-09-21 Simon Marchi <simon.marchi@ericsson.com>
1133
1134 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
1135
0a0bf5dc
YQ
11362017-09-21 Yao Qi <yao.qi@linaro.org>
1137
1138 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
1139 to gdb_target_obs.
1140
d1b0a7bf
TT
11412017-09-20 Tom Tromey <tom@tromey.com>
1142
1143 * breakpoint.c (struct counted_command_line): Remove.
1144 (breakpoint_commands): Update.
1145 (alloc_counted_command_line, incref_counted_command_line)
1146 (decref_counted_command_line, do_cleanup_counted_command_line)
1147 (make_cleanup_decref_counted_command_line): Remove.
1148 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
1149 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
1150 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
1151 (save_breakpoints): Update.
1152 * breakpoint.h (counted_command_line): Now a typedef to
1153 shared_ptr.
1154 (struct breakpoint) <commands>: Now a counted_command_line.
1155 (struct bpstats) <command>: Likewise.
1156
48649e1b
TT
11572017-09-20 Tom Tromey <tom@tromey.com>
1158
1159 * breakpoint.c (struct commands_info, do_map_commands_command):
1160 Remove.
1161 (commands_command_1): Update.
1162 (iterate_over_related_breakpoints): Take a function_view.
1163 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
1164 (delete_command): Update.
1165 (map_breakpoint_numbers): Take a function_view.
1166 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
1167 (disable_command): Update.
1168 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
1169 (enable_command): Update.
1170 (struct disp_data, do_enable_breakpoint_disp)
1171 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
1172 (do_map_enable_delete_breakpoint): Remove.
1173 (enable_once_command, enable_count_command, enable_delete_command)
1174 (delete_trace_variable_command): Update.
1175
04afa70c
TT
11762017-09-20 Tom Tromey <tom@tromey.com>
1177
1178 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
1179 (bpstat_clear): Use delete.
1180 (bpstats): New constructors.
1181 (bpstat_copy, bpstat_stop_status): Use new.
1182 (dprintf_after_condition_true): Update.
1183 * breakpoint.h (bpstats::bpstats): Add constructors.
1184 (bpstats::~bpstats): Add destructor.
1185
c83833f4
PA
11862017-09-20 Pedro Alves <palves@redhat.com>
1187
1188 * eval.c (make_params): Delete, refactored as ...
1189 (class fake_method): ... this new type's ctor.
1190 (fake_method::~fake_method): New.
1191 (evaluate_subexp_standard): Use 'fake_method'.
1192
223ffa71
TT
11932017-09-20 Tom Tromey <tom@tromey.com>
1194
1195 * windows-nat.c (get_windows_debug_event, windows_wait)
1196 (do_initial_windows_stuff, windows_attach): Update.
1197 * utils.c (vwarning, internal_vproblem): Update.
1198 (ui_unregister_input_event_handler_cleanup)
1199 (prepare_to_handle_input): Remove.
1200 (class scoped_input_handler): New.
1201 (defaulted_query, prompt_for_continue): Update.
1202 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
1203 Update.
1204 * top.c (undo_terminal_modifications_before_exit): Update.
1205 * target/target.h (target_terminal_init, target_terminal_inferior)
1206 (target_terminal_ours): Don't declare.
1207 (class target_terminal): New.
1208 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
1209 (target_terminal_ours_for_output)
1210 (make_cleanup_restore_target_terminal): Don't declare.
1211 (target_terminal_info): Remove.
1212 * target.c (enum terminal_state, terminal_state): Remove.
1213 (target_terminal::terminal_state): Define.
1214 (target_terminal::init): Rename from target_terminal_init.
1215 (target_terminal::inferior): Rename from
1216 target_terminal_inferior.
1217 (target_terminal::ours): Rename from target_terminal_ours.
1218 (target_terminal::ours_for_output): Rename from
1219 target_terminal_ours_for_output.
1220 (target_terminal::info): New method.
1221 (cleanup_restore_target_terminal)
1222 (make_cleanup_restore_target_terminal): Remove.
1223 * solib.c (handle_solib_event): Update.
1224 * remote.c (remote_serial_quit_handler): Update.
1225 (remote_terminal_inferior, remote_wait_as): Update.
1226 * record-full.c (record_full_wait_1): Update.
1227 * nto-procfs.c (procfs_create_inferior): Update.
1228 * nat/fork-inferior.c (startup_inferior): Update.
1229 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
1230 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
1231 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
1232 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
1233 (mi_breakpoint_created, mi_breakpoint_deleted)
1234 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
1235 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
1236 (mi_user_selected_context_changed, report_initial_inferior):
1237 Update.
1238 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
1239 (linux_nat_terminal_inferior): Update.
1240 * infrun.c (follow_fork_inferior)
1241 (handle_vfork_child_exec_or_exit, do_target_resume)
1242 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
1243 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
1244 Update.
1245 * inflow.c (child_terminal_init, info_terminal_command): Update.
1246 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
1247 (attach_command): Update.
1248 * infcall.c (call_thread_fsm_should_stop): Update.
1249 * gnu-nat.c (gnu_attach): Update.
1250 * extension.c (struct active_ext_lang_state)
1251 (restore_active_ext_lang): Update.
1252 * exceptions.c (print_flush): Update.
1253 * event-top.c (async_enable_stdin, default_quit_handler): Update.
1254 (struct quit_handler_cleanup_data, restore_quit_handler)
1255 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
1256 Remove.
1257 * cp-support.c (gdb_demangle): Update.
1258 * breakpoint.c (update_inserted_breakpoint_locations)
1259 (insert_breakpoint_locations, handle_jit_event)
1260 (disable_breakpoints_in_unloaded_shlib): Update.
1261 * annotate.c (annotate_breakpoints_invalid)
1262 (annotate_frames_invalid): Update.
1263
013af3fc
TT
12642017-09-20 Tom Tromey <tom@tromey.com>
1265
1266 * main.c (catch_command_errors): Rename from
1267 catch_command_errors_const.
1268 (captured_main_1): Update.
1269
06871ae8
PA
12702017-09-20 Pedro Alves <palves@redhat.com>
1271
1272 * cli/cli-cmds.c (list_command): Use print_sal_location.
1273 (print_sal_location): New function.
1274 (ambiguous_line_spec): Use print_sal_location.
1275 * linespec.c (symbol_to_sal): Record the symbol in the sal.
1276 * symtab.c (find_function_start_sal): Likewise.
1277 * symtab.h (symtab_and_line::symbol): New field.
1278
e5f25bc5
PA
12792017-09-20 Pedro Alves <palves@redhat.com>
1280
1281 * linespec.c (minsym_found): Handle non-text minsyms.
1282 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
1283
1b7fa39e
WT
12842017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1285
1286 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
1287 backslash.
1288
37dd0825
WT
12892017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
1290
1291 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
1292 vmovups instead vmovaps.
1293 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
1294
4e5a4f58
JB
12952017-09-19 John Baldwin <jhb@FreeBSD.org>
1296
1297 * NEWS (Changes since GDB 8.0): Add starti.
1298 * infcmd.c (enum run_break): New.
1299 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
1300 case.
1301 (run_command): Use enum run_how.
1302 (start_command): Likewise.
1303 (starti_command): New function.
1304 (RUN_ARGS_HELP): New macro.
1305 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
1306 commands. Add starti command.
1307
aa70c9f1
YQ
13082017-09-19 Yao Qi <yao.qi@linaro.org>
1309
1310 * Makefile.in (monitor.o): Remove the rule.
1311
d6541620
YQ
13122017-09-19 Yao Qi <yao.qi@linaro.org>
1313
1314 * annotate.h (struct annotate_arg_emitter): Use
1315 DISABLE_COPY_AND_ASSIGN.
1316 * common/refcounted-object.h (refcounted_object): Likewise.
1317 * completer.h (struct completion_result): Likewise.
1318 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
1319 * filename-seen-cache.h (filename_seen_cache): Likewise.
1320 * gdbcore.h (thread_section_name): Likewise.
1321 * gdb_regex.h (compiled_regex): Likewise.
1322 * gdbthread.h (scoped_restore_current_thread): Likewise.
1323 * inferior.h (scoped_restore_current_inferior): Likewise.
1324 * jit.c (jit_reader): Likewise.
1325 * linespec.h (struct linespec_result): Likewise.
1326 * mi/mi-parse.h (struct mi_parse): Likewise.
1327 * nat/fork-inferior.c (execv_argv): Likewise.
1328 * progspace.h (scoped_restore_current_program_space): Likewise.
1329 * python/python-internal.h (class gdbpy_enter): Likewise.
1330 * regcache.h (regcache): Likewise.
1331 * target-descriptions.c (struct tdesc_reg): Likewise.
1332 (struct tdesc_type): Likewise.
1333 (struct tdesc_feature): Likewise.
1334 * ui-out.h (ui_out_emit_type): Likewise.
1335
0615127c
SM
13362017-09-18 Simon Marchi <simon.marchi@ericsson.com>
1337
1338 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
1339 label abort_expression.
1340
5e187554
SM
13412017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1342
1343 * common/buffer.c (buffer_xml_printf): Adjust.
1344 * common/xml-utils.c (xml_escape_text): Change return type to
1345 std::string, update code accordingly.
1346 * common/xml-utils.h (xml_escape_text): Change return type to
1347 std::string.
1348 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
1349 * windows-tdep.c (windows_xfer_shared_library): Adjust.
1350 * unittests/xml-utils-selftests.c (test_xml_escape_text):
1351 Adjust.
1352
c3d7b541
SM
13532017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1354
1355 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
1356 (SUBDIR_UNITTESTS_OBS): Add new object file.
1357 * unittests/xml-utils-selftests.c: New file.
1358
1526853e
SM
13592017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1360
1361 * common/selftest.h (selftest): New struct/interface.
1362 (register_test): Add name parameter, add new overload.
1363 (run_tests): Add filter parameter.
1364 (for_each_selftest_ftype): New typedef.
1365 (for_each_selftest): New declaration.
1366 * common/selftest.c (tests): Change type to
1367 map<string, unique_ptr<selftest>>.
1368 (simple_selftest): New struct.
1369 (register_test): New function.
1370 (register_test): Add name parameter and use it.
1371 (run_tests): Add filter parameter and use it. Add prints.
1372 Adjust to vector -> map change.
1373 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
1374 registering selftests.
1375 * arm-tdep.c (_initialize_arm_tdep): Likewise.
1376 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
1377 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
1378 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
1379 * findvar.c (_initialize_findvar): Likewise.
1380 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
1381 * maint.c (maintenance_selftest): Update call to run_tests.
1382 (maintenance_info_selftests): New function.
1383 (_initialize_maint_cmds): Register "maintenance info selftests"
1384 command. Update "maintenance selftest" doc.
1385 * regcache.c (_initialize_regcache): Add names when registering
1386 selftests.
1387 * rust-exp.y (_initialize_rust_exp): Likewise.
1388 * selftest-arch.c (gdbarch_selftest): New struct.
1389 (gdbarch_tests): Remove.
1390 (register_test_foreach_arch): Add name parameter. Call
1391 register_test.
1392 (tests_with_arch): Remove, move most content to
1393 gdbarch_selftest::operator().
1394 (_initialize_selftests_foreach_arch): Remove.
1395 * selftest-arch.h (register_test_foreach_arch): Add name
1396 parameter.
1397 (run_tests_with_arch): New declaration.
1398 * utils-selftests.c (_initialize_utils_selftests): Add names
1399 when registering selftests.
1400 * utils.c (_initialize_utils): Likewise.
1401 * unittests/array-view-selftests.c
1402 (_initialize_array_view_selftests): Likewise.
1403 * unittests/environ-selftests.c (_initialize_environ_selftests):
1404 Likewise.
1405 * unittests/function-view-selftests.c
1406 (_initialize_function_view_selftests): Likewise.
1407 * unittests/offset-type-selftests.c
1408 (_initialize_offset_type_selftests): Likewise.
1409 * unittests/optional-selftests.c
1410 (_initialize_optional_selftests): Likewise.
1411 * unittests/scoped_restore-selftests.c
1412 (_initialize_scoped_restore_selftests): Likewise.
1413 * NEWS: Document "maintenance selftest" and "maint info
1414 selftests".
1415
5846367a
SM
14162017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1417
1418 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
1419 scoped_restore.
1420
bd77e8ff
SM
14212017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1422
1423 * mi/mi-main.c (mi_load_progress): Make uiout variable
1424 a unique_ptr.
1425
26a67918
PA
14262017-09-15 Pedro Alves <palves@redhat.com>
1427
1428 * compile/compile-c-types.c (convert_enum, convert_int)
1429 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
1430
3f8a7804
SM
14312017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1432
1433 * dwarf2read.c (copy_string): Remove.
1434 (parse_macro_definition): Replace copy_string with savestring.
1435
8d200706
YQ
14362017-09-15 Yao Qi <yao.qi@linaro.org>
1437
1438 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
1439 gdb_target_obs.
1440 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
1441 Likewise.
1442 (i[34567]86-*-linux*): Likewise.
1443
d185219d
SM
14442017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1445
1446 * dwarf2expr.h (dwarf_stack_value): Add constructor.
1447 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
1448 <stack>: Change type to std::vector.
1449 <stack_len, stack_allocated>: Remove.
1450 <grow_stack>: Remove.
1451 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1452 (dwarf_expr_context::~dwarf_expr_context): Remove.
1453 (dwarf_expr_context::grow_stack): Remove.
1454 (dwarf_expr_context::push): Adjust.
1455 (dwarf_expr_context::pop): Adjust.
1456 (dwarf_expr_context::fetch): Adjust.
1457 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
1458 (dwarf_expr_context::stack_empty_p): Adjust.
1459 (dwarf_expr_context::execute_stack_op): Adjust.
1460
eccd80d6
SM
14612017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1462
1463 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
1464 return type to bool.
1465 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
1466
69009882
SM
14672017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1468
1469 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
1470 Change type to bool.
1471 (dwarf_stack_value) <in_stack_memory>: Likewise.
1472 (dwarf_expr_context) <push_address>: Change parameter type to
1473 bool.
1474 <fetch_in_stack_memory>: Change return type to bool.
1475 <push>: Change parameter type to bool.
1476 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
1477 to bool.
1478 (dwarf_expr_context::push_address): Likewise.
1479 (dwarf_expr_context::fetch_in_stack_memory): Change return type
1480 to bool.
1481 (dwarf_expr_context::execute_stack_op): Adjust.
1482 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
1483
1e467161
SM
14842017-09-14 Simon Marchi <simon.marchi@ericsson.com>
1485
1486 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
1487 (struct dwarf_expr_context) <n_pieces>: Remove.
1488 <pieces>: Change type to std::vector.
1489 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
1490 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
1491 pieces.
1492 (dwarf_expr_context::add_piece): Adjust.
1493 * dwarf2loc.c (struct piece_closure): Initialize fields.
1494 <n_pieces>: Remove.
1495 <pieces>: Change type to std::vector.
1496 (allocate_piece_closure): Adjust, change parameter to
1497 std::vector rvalue and std::move it to piece_closure.
1498 (rw_pieced_value): Adjust.
1499 (check_pieced_synthetic_pointer): Adjust.
1500 (indirect_synthetic_pointer): Adjust.
1501 (coerce_pieced_ref): Adjust.
1502 (free_pieced_value_closure): Adjust. Use delete to free
1503 piece_closure.
1504 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
1505 to allocate_piece_closure.
1506 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
1507
0782db84
SM
15082017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1509
1510 * probe.h (probe_ops_cp): Remove typedef.
1511 (DEF_VEC_P (probe_ops_cp)): Remove.
1512 (all_probe_ops): Change type to std::vector.
1513 * probe.c (info_probes_for_ops): Adjust to vector change.
1514 (probe_linespec_to_ops): Likewise.
1515 (all_probe_ops): Change type to std::vector.
1516 (_initialize_probe): Adjust to vector change.
1517 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
1518 * elfread.c (elf_get_probes): Likewise.
1519 * stap-probe.c (_initialize_stap_probe): Likewise.
1520
1eac6bea
SM
15212017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1522
1523 * probe.h (struct bound_probe): Define constructors.
1524 * probe.c (bound_probe_s): Remove typedef.
1525 (DEF_VEC_O (bound_probe_s)): Remove VEC.
1526 (collect_probes): Change return type to std::vector, remove
1527 cleanup.
1528 (compare_probes): Return bool, change parameter type. Change
1529 semantic to "less than".
1530 (gen_ui_out_table_header_info): Change parameter to std::vector
1531 and update.
1532 (exists_probe_with_pops): Likewise.
1533 (info_probes_for_ops): Update to std::vector change.
1534 (enable_probes_command): Likewise.
1535 (disable_probes_command): Likewise.
1536
aaa63a31
SM
15372017-09-12 Simon Marchi <simon.marchi@ericsson.com>
1538
1539 * probe.h (struct probe_ops) <get_probes>: Change parameter from
1540 vec to std::vector.
1541 * probe.c (parse_probes_in_pspace): Update.
1542 (find_probes_in_objfile): Update.
1543 (find_probe_by_pc): Update.
1544 (collect_probes): Update.
1545 (probe_any_get_probes): Update.
1546 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
1547 return type to reference to std::vector.
1548 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
1549 std::vector and update.
1550 (dtrace_process_dof): Likewise.
1551 (dtrace_get_probes): Likewise.
1552 * elfread.c (elf_get_probes): Change return type to std::vector,
1553 store an std::vector in bfd_data.
1554 (probe_key_free): Update to std::vector.
1555 * stap-probe.c (handle_stap_probe): Change parameter to
1556 std::vector and update.
1557 (stap_get_probes): Likewise.
1558 * symfile-debug.c (debug_sym_get_probes): Change return type to
1559 std::vector and update.
1560
cb85b21b
TT
15612017-09-11 Tom Tromey <tom@tromey.com>
1562
1563 * breakpoint.c (program_breakpoint_here_p): Update.
1564 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
1565 from make_show_memory_breakpoints_cleanup. Return a
1566 scoped_restore_tmpl<int>.
1567 (restore_show_memory_breakpoints): Remove.
1568 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
1569 * mem-break.c (memory_validate_breakpoint): Update.
1570 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
1571 (ia64_memory_remove_breakpoint): Update.
1572 (ia64_breakpoint_from_pc): Update.
1573 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
1574 from make_show_memory_breakpoints_cleanup.
1575
8fbc99ef
TT
15762017-09-11 Tom Tromey <tom@tromey.com>
1577
1578 * d-namespace.c (d_lookup_symbol): Use std::string.
1579 (find_symbol_in_baseclass): Likewise.
1580
50feb4bd
TT
15812017-09-11 Tom Tromey <tom@tromey.com>
1582
1583 * ctf.c (ctf_start): Use std::string.
1584
c6dc63a1
TT
15852017-09-11 Tom Tromey <tom@tromey.com>
1586
1587 * ada-lang.c (is_known_support_routine): Update.
1588 (ada_unhandled_exception_name_addr_from_raise): Update.
1589 * guile/scm-frame.c (gdbscm_frame_name): Update.
1590 * python/py-frame.c (frapy_name): Update.
1591 (frapy_function): Update.
1592 * stack.h (find_frame_funname): Update.
1593 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
1594 (print_frame): Update.
1595
d6b9b80f
TT
15962017-09-11 Tom Tromey <tom@tromey.com>
1597
1598 * findcmd.c (put_bits): Take a gdb::byte_vector.
1599 (parse_find_args): Return gdb::byte_vector. "args" now const.
1600 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
1601 cleanups.
1602 (find_command): Update.
1603
a9921622
TT
16042017-09-11 Tom Tromey <tom@tromey.com>
1605
1606 * cli/cli-script.c (class scoped_restore_hook_in): New.
1607 (clear_hook_in_cleanup): Remove.
1608 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
1609 scoped_restore_hook_in.
1610
be0d7abb
TT
16112017-09-11 Tom Tromey <tom@tromey.com>
1612
1613 * cli/cli-script.c (restore_interp): Remove.
1614 (read_command_lines): Use scoped_restore_interp.
1615 * interps.c (scoped_restore_interp::set_temp): Rename from
1616 interp_set_temp.
1617 * interps.h (class scoped_restore_interp): New.
1618 (interp_set_temp): Remove.
1619
00f675ff
TT
16202017-09-11 Tom Tromey <tom@tromey.com>
1621
1622 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1623 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
1624 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
1625 scoped_restore.
1626 (mi_cmd_break_insert_1): Update.
1627 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
1628 scoped_restore.
1629
cb791d59
TT
16302017-09-11 Tom Tromey <tom@tromey.com>
1631
1632 * demangle.c (demangle_command): Update.
1633 * breakpoint.c (disable_command): Update.
1634 (enable_command): Update.
1635 (find_location_by_number): Make "number" const. Use
1636 get_number_trailer.
1637 * cli/cli-utils.c (extract_arg): Return std::string.
1638 * probe.c (parse_probe_linespec): Update. Change types.
1639 (collect_probes): Take string arguments.
1640 (parse_probe_linespec): Likewise.
1641 (info_probes_for_ops): Update.
1642 (enable_probes_command): Update.
1643 (disable_probes_command): Update.
1644 * break-catch-sig.c (catch_signal_split_args): Update.
1645 * mi/mi-parse.c (mi_parse): Update.
1646
2039bd9f
TT
16472017-09-11 Tom Tromey <tom@tromey.com>
1648
1649 * language.h (language_enum): Make argument const.
1650 * language.c (language_enum): Make argument const.
1651
f1735a53
TT
16522017-09-11 Tom Tromey <tom@tromey.com>
1653
1654 * common/common-utils.h (skip_to_space): Remove macro, redeclare
1655 as function.
1656 (skip_to_space): Rename from skip_to_space_const.
1657 * common/common-utils.c (skip_to_space): New function.
1658 (skip_to_space): Rename from skip_to_space_const.
1659 * cli/cli-utils.h (get_number): Rename from get_number_const.
1660 (extract_arg): Rename from extract_arg_const.
1661 * cli/cli-utils.c (get_number): Rename from get_number_const.
1662 (extract_arg): Rename from extract_arg_const.
1663 (number_or_range_parser::get_number): Use ::get_number.
1664 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
1665 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
1666 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
1667 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
1668 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
1669 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
1670 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
1671 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
1672
7d221d74
TT
16732017-09-11 Tom Tromey <tom@tromey.com>
1674
1675 * python/python.c (do_start_initialization): Use
1676 py-event-types.def to initialize types.
1677 Define all object type structures.
1678 * python/python-internal.h: Don't declare event initialization
1679 functions.
1680 * python/py-threadevent.c (thread_event_object_type): Don't
1681 define.
1682 * python/py-stopevent.c (stop_event_object_type): Don't define.
1683 * python/py-signalevent.c (signal_event_object_type): Don't
1684 declare or define.
1685 * python/py-newobjfileevent.c (new_objfile_event_object_type)
1686 (clear_objfiles_event_object_type): Don't declare or define.
1687 * python/py-infevents.c (inferior_call_pre_event_object_type)
1688 (inferior_call_post_event_object_type)
1689 (register_changed_event_object_type)
1690 (memory_changed_event_object_type): Don't declare or define.
1691 * python/py-inferior.c (new_thread_event_object_type)
1692 (new_inferior_event_object_type)
1693 (inferior_deleted_event_object_type): Don't declare or define.
1694 * python/py-exitedevent.c (exited_event_object_type): Don't
1695 declare or define.
1696 * python/py-evts.c (gdbpy_initialize_py_events): Use
1697 py-all-events.def.
1698 * python/py-events.h (thread_event_object_type): Don't declare.
1699 (events_object): Use py-all-events.def.
1700 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
1701 py-event-types.def.
1702 * python/py-event-types.def: New file.
1703 * python/py-continueevent.c (create_continue_event_object): Don't
1704 declare or define.
1705 * python/py-bpevent.c (breakpoint_event_object_type): Don't
1706 declare or define.
1707 * python/py-all-events.def: New file.
1708
35c61a1d
TT
17092017-09-11 Tom Tromey <tom@tromey.com>
1710
1711 * python/py-threadevent.c (create_thread_event_object): Return
1712 gdbpy_ref.
1713 * python/py-stopevent.h (create_stop_event_object)
1714 (create_breakpoint_event_object, create_signal_event_object):
1715 Update.
1716 * python/py-stopevent.c (create_stop_event_object): Return
1717 gdbpy_ref.
1718 (emit_stop_event): Update.
1719 * python/py-signalevent.c (create_signal_event_object): Return
1720 gdbpy_ref.
1721 * python/py-infevents.c (create_inferior_call_event_object):
1722 Update.
1723 * python/py-event.h (create_event_object)
1724 (create_thread_event_object): Update.
1725 * python/py-event.c (create_event_object): Return gdbpy_ref.
1726 * python/py-continueevent.c: Return gdbpy_ref.
1727 * python/py-bpevent.c (create_breakpoint_event_object): Return
1728 gdbpy_ref.
1729
7c96f8c1
TT
17302017-09-11 Tom Tromey <tom@tromey.com>
1731
1732 PR python/15622:
1733 * NEWS: Add entry.
1734 * python/python.c (do_start_initialization): Initialize new event
1735 types.
1736 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
1737 (gdbpy_initialize_inferior_deleted_event)
1738 (gdbpy_initialize_new_thread_event): Declare.
1739 * python/py-threadevent.c (create_thread_event_object): Add option
1740 "thread" parameter.
1741 * python/py-inferior.c (new_thread_event_object_type)
1742 (new_inferior_event_object_type)
1743 (inferior_deleted_event_object_type): Declare.
1744 (python_new_inferior, python_inferior_deleted): New functions.
1745 (add_thread_object): Emit new_thread event.
1746 (gdbpy_initialize_inferior): Attach new functions to corresponding
1747 observers.
1748 (new_thread, new_inferior, inferior_deleted): Define new event
1749 types.
1750 * python/py-evts.c (gdbpy_initialize_py_events): Add new
1751 registries.
1752 * python/py-events.h (events_object) <new_inferior,
1753 inferior_deleted, new_thread>: New fields.
1754 * python/py-event.h (create_thread_event_breakpoint): Add optional
1755 "thread" parameter.
1756
72542b8e
AB
17572017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
1758
1759 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
1760 check current_ui instead.
1761 (internal_vproblem): Likewise.
1762
0d64823e
SM
17632017-09-09 Simon Marchi <simon.marchi@ericsson.com>
1764
1765 * thread.c (print_thread_info_1): Remove unnecessary calls to
1766 uiout->is_mi_like_p.
1767
eb1e02fd
TT
17682017-09-09 Tom Tromey <tom@tromey.com>
1769
1770 * namespace.h (add_using_directive): Update.
1771 * namespace.c (add_using_directive): Change type of excludes to
1772 std::vector.
1773 * dwarf2read.c (read_import_statement): Use std::vector.
1774 (read_namespace): Update.
1775 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1776
0fc21fd8
TT
17772017-09-09 Tom Tromey <tom@tromey.com>
1778
1779 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
1780
49663d05
TT
17812017-09-09 Tom Tromey <tom@tromey.com>
1782
1783 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
1784
0b868b60
TT
17852017-09-09 Tom Tromey <tom@tromey.com>
1786
1787 * stack.c (func_command): Use gdb::def_vector.
1788
c0470d48
TT
17892017-09-09 Tom Tromey <tom@tromey.com>
1790
1791 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
1792 ui_out_emit_list, ui_out_emit_tuple.
1793 (mi_cmd_var_update): Likewise.
1794
ca5909c7
TT
17952017-09-09 Tom Tromey <tom@tromey.com>
1796
1797 * mi/mi-interp.c (mi_user_selected_context_changed): Use
1798 ui_out_redirect_pop.
1799 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
1800 ui_out_redirect_pop.
1801 * utils.c (do_ui_out_redirect_pop)
1802 (make_cleanup_ui_out_redirect_pop): Remove.
1803 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
1804 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
1805 * ui-out.h (ui_out_redirect_pop): New class.
1806
e6a2252a
TT
18072017-09-09 Tom Tromey <tom@tromey.com>
1808
1809 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
1810 (list_available_thread_groups, mi_cmd_list_thread_groups)
1811 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
1812 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
1813 Likewise.
1814
393702cd
TT
18152017-09-09 Tom Tromey <tom@tromey.com>
1816
1817 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
1818 ui_out_emit_tuple.
1819
76f9c9cf
TT
18202017-09-09 Tom Tromey <tom@tromey.com>
1821
1822 * target.c (flash_erase_command): Use ui_out_emit_tuple.
1823 * stack.c (print_frame): Use ui_out_emit_tuple.
1824 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
1825 (info_spu_mailbox_command, info_spu_dma_command)
1826 (info_spu_proxydma_command): Likewise.
1827 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
1828 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
1829 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
1830 ui_out_emit_tuple.
1831 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
1832
dc9fe180
TT
18332017-09-09 Tom Tromey <tom@tromey.com>
1834
1835 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
1836 (class ui_out_emit_table): Update comment.
1837 * ui-out.c (do_cleanup_table_end)
1838 (make_cleanup_ui_out_table_begin_end): Remove.
1839 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
1840 (info_spu_dma_cmdlist): Likewise.
1841 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
1842 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
1843 ui_out_emit_table.
1844
f8cc3da6
TT
18452017-09-09 Tom Tromey <tom@tromey.com>
1846
1847 * thread.c (print_thread_info_1): Use ui_out_emit_table,
1848 ui_out_emit_list, gdb::optional.
1849
481695ed
JB
18502017-09-09 John Baldwin <jhb@FreeBSD.org>
1851
1852 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
1853 prototype.
1854 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
1855 prototype.
1856 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
1857 prototype.
1858 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
1859 * ada-exp.y: Remove _initialize_ada_exp prototype.
1860 * ada-lang.c: Remove _initialize_ada_language prototype.
1861 * ada-tasks.c: Remove _initialize_tasks prototype.
1862 * addrmap.c: Remove _initialize_addrmap prototype.
1863 * agent.c: Remove _initialize_agent prototype.
1864 * aix-thread.c: Remove _initialize_aix_thread prototype.
1865 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
1866 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
1867 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
1868 prototype.
1869 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
1870 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
1871 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
1872 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
1873 prototype.
1874 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
1875 prototype.
1876 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
1877 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
1878 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
1879 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
1880 prototype.
1881 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
1882 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
1883 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
1884 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
1885 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
1886 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
1887 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
1888 prototype.
1889 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
1890 prototype.
1891 * annotate.c: Remove _initialize_annotate prototype.
1892 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
1893 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
1894 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
1895 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
1896 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
1897 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
1898 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
1899 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
1900 prototype.
1901 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
1902 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
1903 * auto-load.c: Remove _initialize_auto_load prototype.
1904 * auxv.c: Remove _initialize_auxv prototype.
1905 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
1906 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
1907 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
1908 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
1909 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
1910 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
1911 prototype.
1912 * break-catch-throw.c: Remove _initialize_break_catch_throw
1913 prototype.
1914 * breakpoint.c: Remove _initialize_breakpoint prototype.
1915 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
1916 * btrace.c: Remove _initialize_btrace prototype.
1917 * charset.c: Remove _initialize_charset prototype.
1918 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
1919 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
1920 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
1921 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
1922 * cli/cli-script.c: Remove _initialize_cli_script prototype.
1923 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
1924 * coffread.c: Remove _initialize_coffread prototype.
1925 * compile/compile.c: Remove _initialize_compile prototype.
1926 * complaints.c: Remove _initialize_complaints prototype.
1927 * completer.c: Remove _initialize_completer prototype.
1928 * copying.awk: Remove _initialize_copying prototype.
1929 * copying.c: Regenerate.
1930 * core-regset.c: Remove _initialize_core_regset prototype.
1931 * corefile.c: Remove _initialize_core prototype.
1932 * corelow.c: Remove _initialize_corelow prototype.
1933 * cp-abi.c: Remove _initialize_cp_abi prototype.
1934 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
1935 * cp-support.c: Remove _initialize_cp_support prototype.
1936 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
1937 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
1938 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
1939 * ctf.c: Remove _initialize_ctf prototype.
1940 * d-lang.c: Remove _initialize_d_language prototype.
1941 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
1942 prototype.
1943 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
1944 * dbxread.c: Remove _initialize_dbxread prototype.
1945 * dcache.c: Remove _initialize_dcache prototype.
1946 * demangle.c: Remove _initialize_demangler prototype.
1947 * disasm-selftests.c: Remove _initialize_disasm_selftests
1948 prototype.
1949 * disasm.c: Remove _initialize_disasm prototype.
1950 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
1951 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
1952 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
1953 prototype.
1954 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
1955 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
1956 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
1957 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
1958 * elfread.c: Remove _initialize_elfread prototype.
1959 * exec.c: Remove _initialize_exec prototype.
1960 * extension.c: Remove _initialize_extension prototype.
1961 * f-lang.c: Remove _initialize_f_language prototype.
1962 * f-valprint.c: Remove _initialize_f_valprint prototype.
1963 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
1964 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
1965 * filesystem.c: Remove _initialize_filesystem prototype.
1966 * findcmd.c: Remove _initialize_mem_search prototype.
1967 * fork-child.c: Remove _initialize_fork_child prototype.
1968 * frame-base.c: Remove _initialize_frame_base prototype.
1969 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
1970 * frame.c: Remove _initialize_frame prototype.
1971 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
1972 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
1973 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
1974 * gcore.c: Remove _initialize_gcore prototype.
1975 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
1976 * gdbarch.c: Regenerate.
1977 * gdbarch.sh: Remove _initialize_gdbarch prototype.
1978 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
1979 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
1980 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
1981 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
1982 * go-lang.c: Remove _initialize_go_language prototype.
1983 * go32-nat.c: Remove _initialize_go32_nat prototype.
1984 * guile/guile.c: Remove _initialize_guile prototype.
1985 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
1986 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
1987 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
1988 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
1989 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
1990 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
1991 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
1992 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
1993 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
1994 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
1995 prototype.
1996 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
1997 prototype.
1998 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
1999 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
2000 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
2001 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
2002 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
2003 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
2004 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
2005 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
2006 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
2007 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
2008 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
2009 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
2010 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
2011 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
2012 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
2013 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
2014 prototype.
2015 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
2016 prototype.
2017 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
2018 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
2019 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
2020 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
2021 * infcall.c: Remove _initialize_infcall prototype.
2022 * infcmd.c: Remove _initialize_infcmd prototype.
2023 * inferior.c: Remove _initialize_inferiors prototype.
2024 * inflow.c: Remove _initialize_inflow prototype.
2025 * infrun.c: Remove _initialize_infrun prototype.
2026 * interps.c: Remove _initialize_interpreter prototype.
2027 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
2028 * jit.c: Remove _initialize_jit prototype.
2029 * language.c: Remove _initialize_language prototype.
2030 * linux-fork.c: Remove _initialize_linux_fork prototype.
2031 * linux-nat.c: Remove _initialize_linux_nat prototype.
2032 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
2033 * linux-thread-db.c: Remove _initialize_thread_db prototype.
2034 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
2035 * m2-lang.c: Remove _initialize_m2_language prototype.
2036 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
2037 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
2038 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
2039 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
2040 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
2041 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
2042 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
2043 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
2044 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
2045 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
2046 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
2047 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
2048 * machoread.c: Remove _initialize_machoread prototype.
2049 * macrocmd.c: Remove _initialize_macrocmd prototype.
2050 * macroscope.c: Remove _initialize_macroscope prototype.
2051 * maint.c: Remove _initialize_maint_cmds prototype.
2052 * mdebugread.c: Remove _initialize_mdebugread prototype.
2053 * memattr.c: Remove _initialize_mem prototype.
2054 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
2055 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
2056 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
2057 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
2058 * mi/mi-main.c: Remove _initialize_mi_main prototype.
2059 * microblaze-linux-tdep.c: Remove
2060 _initialize_microblaze_linux_tdep prototype.
2061 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
2062 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
2063 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
2064 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
2065 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
2066 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
2067 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
2068 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
2069 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
2070 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
2071 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
2072 prototype.
2073 * mipsread.c: Remove _initialize_mipsread prototype.
2074 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
2075 prototype.
2076 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
2077 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
2078 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
2079 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
2080 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
2081 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
2082 prototype.
2083 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
2084 * nto-procfs.c: Remove _initialize_procfs prototype.
2085 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
2086 * objc-lang.c: Remove _initialize_objc_language prototype.
2087 * objfiles.c: Remove _initialize_objfiles prototype.
2088 * observer.c: Remove observer_test_first_notification_function,
2089 observer_test_second_notification_function,
2090 observer_test_third_notification_function, and
2091 _initialize_observer prototypes.
2092 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
2093 * osabi.c: Remove _initialize_gdb_osabi prototype.
2094 * osdata.c: Remove _initialize_osdata prototype.
2095 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
2096 * parse.c: Remove _initialize_parse prototype.
2097 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
2098 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
2099 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
2100 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
2101 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
2102 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
2103 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
2104 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
2105 * printcmd.c: Remove _initialize_printcmd prototype.
2106 * probe.c: Remove _initialize_probe prototype.
2107 * proc-api.c: Remove _initialize_proc_api prototype.
2108 * proc-events.c: Remove _initialize_proc_events prototype.
2109 * proc-service.c: Remove _initialize_proc_service prototype.
2110 * procfs.c: Remove _initialize_procfs prototype.
2111 * psymtab.c: Remove _initialize_psymtab prototype.
2112 * python/python.c: Remove _initialize_python prototype.
2113 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
2114 * record-btrace.c: Remove _initialize_record_btrace prototype.
2115 * record-full.c: Remove _initialize_record_full prototype.
2116 * record.c: Remove _initialize_record prototype.
2117 * regcache.c: Remove _initialize_regcache prototype.
2118 * reggroups.c: Remove _initialize_reggroup prototype.
2119 * remote-notif.c: Remove _initialize_notif prototype.
2120 * remote-sim.c: Remove _initialize_remote_sim prototype.
2121 * remote.c: Remove _initialize_remote prototype.
2122 * reverse.c: Remove _initialize_reverse prototype.
2123 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
2124 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
2125 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
2126 prototype.
2127 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
2128 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
2129 * rust-exp.y: Remove _initialize_rust_exp prototype.
2130 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
2131 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
2132 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
2133 * score-tdep.c: Remove _initialize_score_tdep prototype.
2134 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
2135 prototype.
2136 * ser-go32.c: Remove _initialize_ser_dos prototype.
2137 * ser-mingw.c: Remove _initialize_ser_windows prototype.
2138 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
2139 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
2140 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
2141 * serial.c: Remove _initialize_serial prototype.
2142 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
2143 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
2144 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
2145 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
2146 * skip.c: Remove _initialize_step_skip prototype.
2147 * sol-thread.c: Remove _initialize_sol_thread prototype.
2148 * solib-aix.c: Remove _initialize_solib_aix prototype.
2149 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
2150 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
2151 * solib-frv.c: Remove _initialize_frv_solib prototype.
2152 * solib-spu.c: Remove _initialize_spu_solib prototype.
2153 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
2154 * solib-target.c: Remove _initialize_solib_target prototype.
2155 * solib.c: Remove _initialize_solib prototype.
2156 * source.c: Remove _initialize_source prototype.
2157 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
2158 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
2159 prototype.
2160 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
2161 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
2162 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
2163 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
2164 prototype.
2165 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
2166 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
2167 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
2168 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
2169 prototype.
2170 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
2171 prototype.
2172 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
2173 prototype.
2174 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
2175 prototype.
2176 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
2177 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
2178 prototype.
2179 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
2180 prototype.
2181 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
2182 prototype.
2183 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
2184 prototype.
2185 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
2186 prototype.
2187 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
2188 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
2189 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
2190 * stabsread.c: Remove _initialize_stabsread prototype.
2191 * stack.c: Remove _initialize_stack prototype.
2192 * stap-probe.c: Remove _initialize_stap_probe prototype.
2193 * std-regs.c: Remove _initialize_frame_reg prototype.
2194 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
2195 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
2196 * symfile.c: Remove _initialize_symfile prototype.
2197 * symmisc.c: Remove _initialize_symmisc prototype.
2198 * symtab.c: Remove _initialize_symtab prototype.
2199 * target-dcache.c: Remove _initialize_target_dcache prototype.
2200 * target-descriptions.c: Remove _initialize_target_descriptions
2201 prototype.
2202 * thread.c: Remove _initialize_thread prototype.
2203 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
2204 prototype.
2205 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
2206 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
2207 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
2208 prototype.
2209 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
2210 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
2211 * tracefile.c: Remove _initialize_tracefile prototype.
2212 * tracepoint.c: Remove _initialize_tracepoint prototype.
2213 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
2214 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
2215 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
2216 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
2217 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
2218 * tui/tui-win.c: Remove _initialize_tui_win prototype.
2219 * tui/tui.c: Remove _initialize_tui prototype.
2220 * typeprint.c: Remove _initialize_typeprint prototype.
2221 * user-regs.c: Remove _initialize_user_regs prototype.
2222 * utils.c: Remove _initialize_utils prototype.
2223 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
2224 * valarith.c: Remove _initialize_valarith prototype.
2225 * valops.c: Remove _initialize_valops prototype.
2226 * valprint.c: Remove _initialize_valprint prototype.
2227 * value.c: Remove _initialize_values prototype.
2228 * varobj.c: Remove _initialize_varobj prototype.
2229 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
2230 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
2231 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
2232 * windows-nat.c: Remove _initialize_windows_nat,
2233 _initialize_check_for_gdb_ini, and _initialize_loadable
2234 prototypes.
2235 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
2236 * xcoffread.c: Remove _initialize_xcoffread prototype.
2237 * xml-support.c: Remove _initialize_xml_support prototype.
2238 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
2239 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
2240 prototype.
2241 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
2242 prototype.
2243 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
2244
a611b5cb
KS
22452017-09-08 Keith Seitz <keiths@redhat.com>
2246
2247 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
2248 field.
2249
469412dd
CW
22502017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
2251
2252 * f-valprint.c (f_val_print): Remove check for one byte
2253 sized integers. Remove printing of character type.
2254
a5ad232b
FP
22552017-09-08 Frank Penczek <frank.penczek@intel.com>
2256 Christoph Weinmann <christoph.t.weinmann@intel.com>
2257 Bernhard Heckel <bernhard.heckel@intel.com>
2258
2259 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
2260 to maintain proper indentation when printing pointers/refs.
2261
e5014227
JB
22622017-09-07 Joel Brobecker <brobecker@adacore.com>
2263
2264 GDB 8.0.1 released.
2265
63c99141
JB
22662017-09-07 Joel Brobecker <brobecker@adacore.com>
2267
2268 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
2269
69c1e056
TT
22702017-09-05 Tom Tromey <tom@tromey.com>
2271
2272 * parse.c (funcall_chain): Now a std::vector.
2273 (start_arglist, end_arglist): Simplify.
2274 (free_funcalls): Remove.
2275 (parse_exp_in_context_1): Remove cleanup.
2276
fef704bf
TT
22772017-09-05 Tom Tromey <tom@tromey.com>
2278
2279 * go-exp.y (go_parse): Don't create a cleanup.
2280
5613c585
TT
22812017-09-05 Tom Tromey <tom@tromey.com>
2282
2283 * d-exp.y (PrimaryExpression): Use std::string.
2284 (d_parse): Don't create a cleanup.
2285
eae49211
TT
22862017-09-05 Tom Tromey <tom@tromey.com>
2287
2288 * utils.c (do_clear_parser_state): Remove.
2289 (make_cleanup_clear_parser_state): Remove.
2290 * p-exp.y (pascal_parse): Use scoped_restore.
2291 * m2-exp.y (m2_parse): Use scoped_restore.
2292 * f-exp.y (f_parse): Use scoped_restore.
2293 * d-exp.y (d_parse): Use scoped_restore.
2294 * c-exp.y (c_parse): Use scoped_restore.
2295 * ada-exp.y (ada_parse): Use scoped_restore.
2296 * utils.h (make_cleanup_clear_parser_state): Remove.
2297
73b9be8b
KS
22982017-09-06 Keith Seitz <keiths@redhat.com>
2299
2300 * dwarf2read.c (dw2_linkage_name_attr): New function.
2301 (dw2_linkage_name): New function.
2302 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
2303 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
2304 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
2305
a102602b
KR
23062017-09-06 Kamil Rytarowski <n54@gmx.com>
2307
2308 * config/djgpp/djconfig.sh: Correct shell portability issue.
2309
28ad437d
KR
23102017-09-06 Kamil Rytarowski <n54@gmx.com>
2311
2312 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
2313
351787dd
JB
23142017-09-06 John Baldwin <jhb@FreeBSD.org>
2315
2316 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
2317 * NEWS: Mention new FreeBSD/mips native configuration.
2318 * configure.host: Add aarch64*-*-freebsd*.
2319 * configure.nat: Likewise.
2320 * aarch64-fbsd-nat.c: New file.
2321
c0f84956
JB
23222017-09-06 John Baldwin <jhb@FreeBSD.org>
2323
2324 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
2325 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
2326 * NEWS: Mention new FreeBSD/aarch64 target.
2327 * configure.tgt: Add aarch64*-*-freebsd*.
2328 * aarch64-fbsd-tdep.c: New file.
2329 * aarch64-fbsd-tdep.h: New file.
2330
7610297a
KR
23312017-09-06 Kamil Rytarowski <n54@gmx.com>
2332
2333 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
2334
fbd1b771
JK
23352017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
2336
2337 * parse.c (find_minsym_type_and_address): Don't relocate addresses
2338 of TLS symbols.
2339
5ca79eae
PW
23402017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2341
2342 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
2343 call.
2344
bf93d7ba
SM
23452017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2346
2347 * infrun.c (follow_exec): Call add_thread after
2348 target_find_description.
2349
1bb7c059
SM
23502017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2351
2352 * infrun.c (handle_inferior_event_1): When exec'ing, read
2353 stop_pc after follow_exec.
2354
fc809827
SM
23552017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2356
2357 * remote.c (process_g_packet): Update error message.
2358
d2fcdd85
YQ
23592017-09-05 Yao Qi <yao.qi@linaro.org>
2360
2361 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
2362 targets.
2363
e69570ee
PA
23642017-09-05 Pedro Alves <palves@redhat.com>
2365
2366 * eval.c (eval_call, evaluate_funcall): New functions, factored
2367 out from ...
2368 (evaluate_subexp_standard): ... this.
2369
22916b07
YQ
23702017-09-05 Yao Qi <yao.qi@linaro.org>
2371
2372 * amd64-tdep.c (amd64_target_description): Create target
2373 descriptions.
2374 (_initialize_amd64_tdep): Don't call functions
2375 initialize_tdesc_amd64_*. Add self tests.
2376 * arch/amd64.c (amd64_create_target_description): Add parameter
2377 is_linux. Call set_tdesc_osabi if is_linux is true.
2378 * arch/amd64.h (amd64_create_target_description): Update the
2379 declaration.
2380 * arch/i386.c (i386_create_target_description): Add parameter
2381 is_linux. Call set_tdesc_osabi if is_linux is true.
2382 * arch/i386.h (i386_create_target_description): Update
2383 declaration.
2384 * configure.tgt: Add i386.o to gdb_target_obs.
2385 * features/Makefile (XMLTOC): Remove i386/*.xml.
2386 * features/i386/amd64-avx-avx512.c: Remove.
2387 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
2388 * features/i386/amd64-avx-mpx.c: Remove.
2389 * features/i386/amd64-avx.c: Remove.
2390 * features/i386/amd64-mpx.c: Remove.
2391 * features/i386/amd64.c: Remove.
2392 * features/i386/i386-avx-avx512.c: Remove.
2393 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
2394 * features/i386/i386-avx-mpx.c: Remove.
2395 * features/i386/i386-avx.c: Remove.
2396 * features/i386/i386-mmx.c: Remove.
2397 * features/i386/i386-mpx.c: Remove.
2398 * features/i386/i386.c: Remove.
2399 * i386-tdep.c: Don't include features/i386/i386*.c., include
2400 target-descriptions.h and arch/i386.h.
2401 (i386_target_description): Create target descriptions.
2402 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
2403 functions. Do self tests.
2404
0854b7b1
YQ
24052017-09-05 Yao Qi <yao.qi@linaro.org>
2406
2407 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
2408 * features/i386/amd64-avx-avx512-linux.c: Removed.
2409 * features/i386/amd64-avx-linux.c: Removed.
2410 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
2411 * features/i386/amd64-avx-mpx-linux.c: Removed.
2412 * features/i386/amd64-linux.c: Removed.
2413 * features/i386/amd64-mpx-linux.c: Removed.
2414 * features/i386/x32-avx-avx512-linux.c: Removed.
2415 * features/i386/x32-avx-linux.c: Removed.
2416 * features/i386/x32-linux.c: Removed.
2417
b4570e4b
YQ
24182017-09-05 Yao Qi <yao.qi@linaro.org>
2419
2420 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
2421 features/i386/*.c.
2422 (amd64_linux_read_description): Call
2423 amd64_create_target_description.
2424 * arch/amd64.c: New file.
2425 * arch/amd64.h: New file.
2426 * configure.tgt (x86_64-*-linux*): Append amd64.o.
2427 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
2428
6c73f67f
YQ
24292017-09-05 Yao Qi <yao.qi@linaro.org>
2430
2431 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
2432 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
2433 (amd64_linux_read_description): Create target descriptions.
2434 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
2435 functions. Add unit tests.
2436 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
2437 x32-core.xml.
2438 * features/i386/64bit-avx.c: Generated.
2439 * features/i386/64bit-avx512.c: Generated.
2440 * features/i386/64bit-core.c: Generated.
2441 * features/i386/64bit-linux.c: Generated.
2442 * features/i386/64bit-mpx.c: Generated.
2443 * features/i386/64bit-pkeys.c: Generated.
2444 * features/i386/64bit-segments.c: Generated.
2445 * features/i386/64bit-sse.c: Generated.
2446 * features/i386/x32-core.c: Generated.
2447 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
2448 c files for amd64-linux and x32-linux.
2449
9d3d478b
YQ
24502017-09-05 Yao Qi <yao.qi@linaro.org>
2451
2452 * amd64-linux-tdep.c (amd64_linux_read_description): New
2453 function.
2454 (amd64_linux_core_read_description): Call
2455 amd64_linux_read_description.
2456 (amd64_linux_init_abi): Likewise.
2457 (amd64_x32_linux_init_abi): Likewise.
2458 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
2459 * x86-linux-nat.c (x86_linux_read_description): Call
2460 amd64_linux_read_description.
2461
b9f1d50f
YQ
24622017-09-05 Yao Qi <yao.qi@linaro.org>
2463
2464 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
2465 comments.
2466
188c9e6d
YQ
24672017-09-05 Yao Qi <yao.qi@linaro.org>
2468
2469 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
2470 * features/i386/i386-avx-avx512-linux.c: Remove.
2471 * features/i386/i386-avx-linux.c: Remove.
2472 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
2473 * features/i386/i386-avx-mpx-linux.c: Remove.
2474 * features/i386/i386-linux.c: Remove.
2475 * features/i386/i386-mmx-linux.c: Remove.
2476 * features/i386/i386-mpx-linux.c: Remove.
2477
5f035c07
YQ
24782017-09-05 Yao Qi <yao.qi@linaro.org>
2479
2480 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
2481 (SFILES): Add arch/i386.c.
2482 (HFILES_NO_SRCDIR): Add arch/i386.h.
2483 * arch/i386.c: New file.
2484 * arch/i386.h: New file.
2485 * arch/tdesc.h (allocate_target_description): Declare.
2486 (set_tdesc_architecture): Declare.
2487 (set_tdesc_osabi): Declare.
2488 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
2489 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
2490 include arch/i386.h.
2491 (i386_linux_read_description): Remove code and call
2492 i386_create_target_description.
2493 (set_tdesc_architecture): New function.
2494 (set_tdesc_osabi): New function.
2495 * target-descriptions.h (allocate_target_description): Remove.
2496
0abe8a89
YQ
24972017-09-05 Yao Qi <yao.qi@linaro.org>
2498
2499 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
2500 * target-descriptions.c (tdesc_create_feature): Likewise, and
2501 adjust code.
2502 * features/i386/32bit-avx.c: Re-generated.
2503 * features/i386/32bit-avx512.c: Re-generated.
2504 * features/i386/32bit-core.c: Re-generated.
2505 * features/i386/32bit-linux.c: Re-generated.
2506 * features/i386/32bit-mpx.c: Re-generated.
2507 * features/i386/32bit-pkeys.c: Re-generated.
2508 * features/i386/32bit-sse.c: Re-generated.
2509
0a188386
YQ
25102017-09-05 Yao Qi <yao.qi@linaro.org>
2511
2512 * regformats/regdef.h (struct reg): Override operator == and !=.
2513
f49ff000
YQ
25142017-09-05 Yao Qi <yao.qi@linaro.org>
2515
2516 * arch/tdesc.h: New file.
2517 * regformats/regdat.sh: Generate code using tdesc_create_reg.
2518 * target-descriptions.c: Update comments.
2519 * target-descriptions.h: Include "arch/tdesc.h". Remove the
2520 declarations.
2521 * features/i386/32bit-avx.c: Re-generated.
2522 * features/i386/32bit-avx512.c: Re-generated.
2523 * features/i386/32bit-core.c: Re-generated.
2524 * features/i386/32bit-linux.c: Re-generated.
2525 * features/i386/32bit-mpx.c: Re-generated.
2526 * features/i386/32bit-pkeys.c: Re-generated.
2527 * features/i386/32bit-sse.c: Re-generated.
2528
f7000548
YQ
25292017-09-05 Yao Qi <yao.qi@linaro.org>
2530
2531 * regformats/regdat.sh: Update generated code.
2532
c9a5e2a5
YQ
25332017-09-05 Yao Qi <yao.qi@linaro.org>
2534
2535 * regformats/regdat.sh: Adjust code order.
2536
d6b687ac
SM
25372017-09-05 Simon Marchi <simon.marchi@ericsson.com>
2538
2539 * expprint.c (dump_subexp_body_standard): Use constant format
2540 string in fprintf_filtered call.
2541
a379bfd0
JB
25422017-09-04 John Baldwin <jhb@FreeBSD.org>
2543
2544 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
2545 NetBSD/i386.
2546 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
2547
f7efc967
JB
25482017-09-04 John Baldwin <jhb@FreeBSD.org>
2549
2550 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
2551
c49fbc6c
JB
25522017-09-04 John Baldwin <jhb@FreeBSD.org>
2553
2554 * bsd-kvm.o: Define _KMEMUSER.
2555 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
2556 * configure: Regenerate.
2557
26562e73
JB
25582017-09-04 John Baldwin <jhb@FreeBSD.org>
2559
2560 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
2561 * i386-fbsd-nat.c: Likewise.
2562
31cf1487
JB
25632017-09-04 John Baldwin <jhb@FreeBSD.org>
2564
2565 * unittests/array-view-selftests.c: Add include of <array>.
2566
5b9f8a7c
JB
25672017-09-04 John Baldwin <jhb@FreeBSD.org>
2568
2569 * spu-tdep.c (flush_ea_cache): Add missing argument to
2570 call_function_by_hand.
2571
d69cf9b2
PA
25722017-09-04 Pedro Alves <palves@redhat.com>
2573
2574 * NEWS (Safer support for debugging with no debug info): New.
2575
3693fdb3
PA
25762017-09-04 Pedro Alves <palves@redhat.com>
2577
2578 * c-exp.y (function_method, function_method_void): Add current
2579 instance flags to TYPE_INSTANCE.
2580 * dwarf2read.c (check_modifier): New.
2581 (compute_delayed_physnames): Assert that only C++ adds delayed
2582 physnames. Mark fn_fields as const/volatile depending on
2583 physname.
2584 * eval.c (make_params): New type_instance_flags parameter. Use
2585 it as the new type's instance flags.
2586 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
2587 flags element and pass it to make_params.
2588 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
2589 instance flags element.
2590 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
2591 * gdbtypes.h: Include "enum-flags.h".
2592 (type_instance_flags): New enum-flags type.
2593 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
2594 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
2595 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
2596 (follow_type_instance_flags): New function.
2597 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
2598 * parser-defs.h (follow_type_instance_flags): Declare.
2599 * valops.c (value_struct_elt_for_reference): const/volatile must
2600 match too.
2601
e68cb8e0
PA
26022017-09-04 Pedro Alves <palves@redhat.com>
2603
2604 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
2605 function/method scopes; lookup the nested name as a function local
2606 static variable.
2607
858be34c
PA
26082017-09-04 Pedro Alves <palves@redhat.com>
2609
2610 (%type <voidval>): Add function_method.
2611 * c-exp.y (exp): New production for calls with no arguments.
2612 (function_method, function_method_void_or_typelist): New
2613 productions.
2614 (exp): New production for "method()::static_var".
2615 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
2616 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2617 Handle OP_FUNC_STATIC_VAR.
2618 * parse.c (operator_length_standard):
2619 Handle OP_FUNC_STATIC_VAR.
2620
dd5901a6
PA
26212017-09-04 Pedro Alves <palves@redhat.com>
2622
2623 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
2624 handling.
2625 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2626 Ditto.
2627 * parse.c (operator_length_standard, operator_check_standard):
2628 Ditto.
2629 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
2630
46a4882b
PA
26312017-09-04 Pedro Alves <palves@redhat.com>
2632
2633 * ax-gdb.c: Include "typeprint.h".
2634 (gen_expr_for_cast): New function.
2635 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
2636 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
2637 type is unknown.
2638 * dwarf2read.c (new_symbol_full): Fallback to int instead of
2639 nodebug_data_symbol.
2640 * eval.c: Include "typeprint.h".
2641 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
2642 Error out if symbol has unknown type.
2643 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
2644 evaluate_subexp_for_cast.
2645 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
2646 OP_VAR_MSYM_VALUE.
2647 (evaluate_subexp_for_cast): New function.
2648 * gdbtypes.c (init_nodebug_var_type): New function.
2649 (objfile_type): Use it to initialize types of variables with no
2650 debug info.
2651 * typeprint.c (error_unknown_type): New.
2652 * typeprint.h (error_unknown_type): New declaration.
2653 * compile/compile-c-types.c (convert_type_basic): Handle
2654 TYPE_CODE_ERROR; warn and fallback to int for variables with
2655 unknown type.
2656
fe13dfec
PA
26572017-09-04 Pedro Alves <palves@redhat.com>
2658
2659 * eval.c (evaluate_var_value): New function, factored out from ...
2660 (evaluate_subexp_standard): ... here.
2661
d008ee21
PA
26622017-09-04 Pedro Alves <palves@redhat.com>
2663
2664 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
2665 Remove useless assignments to 'op'.
2666
827d0c51
PA
26672017-09-04 Pedro Alves <palves@redhat.com>
2668
2669 * eval.c (eval_skip_value): New function.
2670 (evaluate_subexp_standard): Use it.
2671
2c5a2be1
PA
26722017-09-04 Pedro Alves <palves@redhat.com>
2673
2674 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
2675 function name from symbol/minsym and pass it to
2676 error_call_unknown_return_type.
2677
74ea4be4
PA
26782017-09-04 Pedro Alves <palves@redhat.com>
2679
2680 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
2681 * ax-gdb.c (gen_msym_var_ref): New function.
2682 (gen_expr): Handle OP_VAR_MSYM_VALUE.
2683 * eval.c (evaluate_var_msym_value): New function.
2684 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
2685 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
2686 to call_function_by_hand.
2687 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
2688 Handle OP_VAR_MSYM_VALUE.
2689 (union exp_element) <msymbol>: New field.
2690 * minsyms.h (struct type): Forward declare.
2691 (find_minsym_type_and_address): Declare.
2692 * parse.c (write_exp_elt_msym): New function.
2693 (write_exp_msymbol): Delete, refactored as ...
2694 (find_minsym_type_and_address): ... this new function.
2695 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
2696 (operator_length_standard, operator_check_standard): Handle
2697 OP_VAR_MSYM_VALUE.
2698 * std-operator.def (OP_VAR_MSYM_VALUE): New.
2699
7022349d
PA
27002017-09-04 Pedro Alves <palves@redhat.com>
2701
2702 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
2703 TYPE_GNU_IFUNC specially here. Throw error if return type is
2704 unknown.
2705 * ada-typeprint.c (print_func_type): Handle functions with unknown
2706 return type.
2707 * c-typeprint.c (c_type_print_base): Handle functions and methods
2708 with unknown return type.
2709 * compile/compile-c-symbols.c (convert_symbol_bmsym)
2710 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
2711 * compile/compile-c-types.c: Include "objfiles.h".
2712 (convert_func): For functions with unknown return type, warn and
2713 default to int.
2714 * compile/compile-object-run.c (compile_object_run): Adjust call
2715 to call_function_by_hand_dummy.
2716 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
2717 call_function_by_hand.
2718 * eval.c (evaluate_subexp_standard): Adjust calls to
2719 call_function_by_hand. Handle functions and methods with unknown
2720 return type. Pass expect_type to call_function_by_hand.
2721 * f-typeprint.c (f_type_print_base): Handle functions with unknown
2722 return type.
2723 * gcore.c (call_target_sbrk): Adjust call to
2724 call_function_by_hand.
2725 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
2726 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
2727 an integer address type instead of nodebug.
2728 * guile/scm-value.c (gdbscm_value_call): Adjust call to
2729 call_function_by_hand.
2730 * infcall.c (error_call_unknown_return_type): New function.
2731 (call_function_by_hand): New "default_return_type" parameter.
2732 Pass it down.
2733 (call_function_by_hand_dummy): New "default_return_type"
2734 parameter. Use it instead of defaulting to int. If there's no
2735 default and the return type is unknown, throw an error. If
2736 there's a default return type, and the called function has no
2737 debug info, then assume the function is prototyped.
2738 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
2739 New "default_return_type" parameter.
2740 (error_call_unknown_return_type): New declaration.
2741 * linux-fork.c (call_lseek): Cast return type of lseek.
2742 (inferior_call_waitpid, checkpoint_command): Adjust calls to
2743 call_function_by_hand.
2744 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
2745 calls to call_function_by_hand.
2746 * m2-typeprint.c (m2_procedure): Handle functions with unknown
2747 return type.
2748 * objc-lang.c (lookup_objc_class, lookup_child_selector)
2749 (value_nsstring, print_object_command): Adjust calls to
2750 call_function_by_hand.
2751 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
2752 functions with unknown return type.
2753 (pascal_type_print_func_varspec_suffix): New function.
2754 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
2755 TYPE_CODE_METHOD>: Use it.
2756 * python/py-value.c (valpy_call): Adjust call to
2757 call_function_by_hand.
2758 * rust-lang.c (rust_evaluate_funcall): Adjust call to
2759 call_function_by_hand.
2760 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
2761 call_function_by_hand.
2762 * valops.c (value_allocate_space_in_inferior): Adjust call to
2763 call_function_by_hand.
2764 * typeprint.c (type_print_unknown_return_type): New function.
2765 * typeprint.h (type_print_unknown_return_type): New declaration.
2766
54990598
PA
27672017-09-04 Pedro Alves <palves@redhat.com>
2768
2769 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
2770 types with more than one parameter as prototyped.
2771
9a24775b
PA
27722017-09-04 Pedro Alves <palves@redhat.com>
2773
2774 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
2775 (disassemble_command): Use gdb_disassembly_flags instead of bare
2776 int.
2777 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
2778 (dump_insns, do_mixed_source_and_assembly_deprecated)
2779 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
2780 Use gdb_disassembly_flags instead of bare int.
2781 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
2782 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
2783 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
2784 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
2785 (enum gdb_disassembly_flag): ... values of this new enumeration.
2786 (gdb_disassembly_flags): Define.
2787 (gdb_disassembly)
2788 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
2789 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
2790 gdb_disassembly_flags instead of bare int.
2791 * record-btrace.c (btrace_insn_history)
2792 (record_btrace_insn_history, record_btrace_insn_history_range)
2793 (record_btrace_insn_history_from): Use gdb_disassembly_flags
2794 instead of bare int.
2795 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
2796 Use gdb_disassembly_flags instead of bare int.
2797 * target-debug.h (target_debug_print_gdb_disassembly_flags):
2798 Define.
2799 * target-delegates.c: Regenerate.
2800 * target.c (target_insn_history, target_insn_history_from)
2801 (target_insn_history_range): Use gdb_disassembly_flags instead of
2802 bare int.
2803 * target.h: Include "disasm.h".
2804 (struct target_ops) <to_insn_history, to_insn_history_from,
2805 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
2806 int.
2807 (target_insn_history, target_insn_history_from)
2808 (target_insn_history_range): Use gdb_disassembly_flags instead of
2809 bare int.
2810
80a65e9b
SM
28112017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2812
2813 * cli/cli-script.c (build_command_line): For if/while commands,
2814 check whether args is empty.
2815
6b66338c
SM
28162017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2817
2818 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
2819 (enum command_control_type): Likewise.
2820 (struct command_line): Likewise.
2821 (free_command_lines): Likewise.
2822 (struct command_lines_deleter): Likewise.
2823 (command_line_up): Likewise.
2824 (read_command_lines): Likewise.
2825 (read_command_lines_1): Likewise.
2826 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
2827 (enum command_control_type): Likewise.
2828 (struct command_line): Likewise.
2829 (free_command_lines): Likewise.
2830 (struct command_lines_deleter): Likewise.
2831 (command_line_up): Likewise.
2832 (read_command_lines): Likewise.
2833 (read_command_lines_1): Likewise.
2834 * breakpoint.h: Include cli/cli-script.h.
2835 * extension-priv.h: Likewise.
2836 * gdbcmd.h: Likewise.
2837
51abb421
PA
28382017-09-04 Pedro Alves <palves@redhat.com>
2839
2840 * ada-lang.c (is_known_support_routine): Move sal declaration to
2841 where it is initialized.
2842 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
2843 (parse_breakpoint_sals, decode_static_tracepoint_spec)
2844 (clear_command, update_static_tracepoint): Remove init_sal
2845 references. Move declarations closer to initializations.
2846 * cli/cli-cmds.c (list_command): Move sal declarations closer to
2847 initializations.
2848 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
2849 references. Move sal declarations closer to initializations.
2850 * frame.c (find_frame_sal): Return a symtab_and_line via function
2851 return instead of output parameter. Remove init_sal references.
2852 * frame.h (find_frame_sal): Return a symtab_and_line via function
2853 return instead of output parameter.
2854 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
2855 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
2856 instead of memset.
2857 (gdbscm_find_pc_line): Remove init_sal reference.
2858 * infcall.c (call_function_by_hand_dummy): Remove init_sal
2859 references. Move declarations closer to initializations.
2860 * infcmd.c (set_step_frame): Update. Move declarations closer to
2861 initializations.
2862 (finish_backward): Remove init_sal references. Move declarations
2863 closer to initializations.
2864 * infrun.c (process_event_stop_test, handle_step_into_function)
2865 (insert_hp_step_resume_breakpoint_at_frame)
2866 (insert_step_resume_breakpoint_at_caller): Likewise.
2867 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
2868 (symbol_to_sal): Likewise.
2869 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
2870 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
2871 to its initialization.
2872 * reverse.c (save_bookmark_command): Use new/delete. Remove
2873 init_sal references. Move declarations closer to initializations.
2874 * source.c (get_current_source_symtab_and_line): Remove brace
2875 initialization.
2876 (set_current_source_symtab_and_line): Now takes the sal by const
2877 reference. Remove brace initialization.
2878 (line_info): Remove init_sal reference.
2879 * source.h (set_current_source_symtab_and_line): Now takes a
2880 symtab_and_line via const reference.
2881 * stack.c (set_current_sal_from_frame): Adjust.
2882 (print_frame_info): Adjust.
2883 (get_last_displayed_sal): Return the sal via function return
2884 instead of via output parameter. Simplify.
2885 (frame_info): Adjust.
2886 * stack.h (get_last_displayed_sal): Return the sal via function
2887 return instead of via output parameter.
2888 * symtab.c (init_sal): Delete.
2889 (find_pc_sect_line): Remove init_sal references. Move
2890 declarations closer to initializations.
2891 (find_function_start_sal): Remove init_sal references. Move
2892 declarations closer to initializations.
2893 * symtab.h (struct symtab_and_line): In-class initialize all
2894 fields.
2895 * tracepoint.c (set_traceframe_context)
2896 (print_one_static_tracepoint_marker): Remove init_sal references.
2897 Move declarations closer to initializations.
2898 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
2899 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
2900 declarations closer to initializations.
2901 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
2902 init_sal references. Adjust.
2903
6c5b2ebe
PA
29042017-09-04 Pedro Alves <palves@redhat.com>
2905
2906 * ax-gdb.c (agent_command_1): Use range-for.
2907 * break-catch-throw.c (re_set_exception_catchpoint): Update.
2908 * breakpoint.c: Include "common/array-view.h".
2909 (init_breakpoint_sal, create_breakpoint_sal): Change sals
2910 parameter from struct symtabs_and_lines to
2911 array_view<symtab_and_line>. Adjust. Use range-for. Update.
2912 (breakpoint_sals_to_pc): Change sals parameter from struct
2913 symtabs_and_lines to std::vector reference.
2914 (check_fast_tracepoint_sals): Change sals parameter from struct
2915 symtabs_and_lines to std::array_view. Use range-for.
2916 (decode_static_tracepoint_spec): Return a std::vector instead of
2917 symtabs_and_lines. Update.
2918 (create_breakpoint): Update.
2919 (break_range_command, until_break_command, clear_command): Update.
2920 (base_breakpoint_decode_location, bkpt_decode_location)
2921 (bkpt_probe_create_sals_from_location)
2922 (bkpt_probe_decode_location, tracepoint_decode_location)
2923 (tracepoint_probe_decode_location)
2924 (strace_marker_create_sals_from_location): Return a std::vector
2925 instead of symtabs_and_lines.
2926 (strace_marker_create_breakpoints_sal): Update.
2927 (strace_marker_decode_location): Return a std::vector instead of
2928 symtabs_and_lines. Update.
2929 (update_breakpoint_locations): Change struct symtabs_and_lines
2930 parameters to gdb::array_view. Adjust.
2931 (location_to_sals): Return a std::vector instead of
2932 symtabs_and_lines. Update.
2933 (breakpoint_re_set_default): Use std::vector instead of struct
2934 symtabs_and_lines.
2935 (decode_location_default): Return a std::vector instead of
2936 symtabs_and_lines. Update.
2937 * breakpoint.h: Include "common/array-view.h".
2938 (struct breakpoint_ops) <decode_location>: Now returns a
2939 std::vector instead of returning a symtabs_and_lines via output
2940 parameter.
2941 (update_breakpoint_locations): Change sals parameters to use
2942 gdb::array_view.
2943 * cli/cli-cmds.c (edit_command, list_command): Update to use
2944 std::vector and gdb::array_view.
2945 (ambiguous_line_spec): Adjust to use gdb::array_view and
2946 range-for.
2947 (compare_symtabs): Rename to ...
2948 (cmp_symtabs): ... this. Change parameters to symtab_and_line
2949 const reference and adjust.
2950 (filter_sals): Rewrite using std::vector and standard algorithms.
2951 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
2952 (jump_command): Update to use std::vector.
2953 * linespec.c (struct linespec_state) <canonical_names>: Update
2954 comment.
2955 (add_sal_to_sals_basic): Delete.
2956 (add_sal_to_sals, filter_results, convert_results_to_lsals)
2957 (decode_line_2, create_sals_line_offset)
2958 (convert_address_location_to_sals, convert_linespec_to_sals)
2959 (convert_explicit_location_to_sals, parse_linespec)
2960 (event_location_to_sals, decode_line_full, decode_line_1)
2961 (decode_line_with_current_source)
2962 (decode_line_with_last_displayed, decode_objc)
2963 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
2964 (linespec_result::~linespec_result): Adjust to use std::vector
2965 instead of symtabs_and_lines.
2966 * linespec.h (linespec_sals::sals): Now a std::vector.
2967 (struct linespec_result): Use std::vector, bool, and in-class
2968 initialization.
2969 (decode_line_1, decode_line_with_current_source)
2970 (decode_line_with_last_displayed): Return std::vector.
2971 * macrocmd.c (info_macros_command): Use std::vector.
2972 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
2973 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
2974 std::vector.
2975 * probe.h (parse_probes): Return a std::vector.
2976 * python/python.c (gdbpy_decode_line): Use std::vector and
2977 gdb::array_view.
2978 * source.c (select_source_symtab, line_info): Use std::vector.
2979 * stack.c (func_command): Use std::vector.
2980 * symtab.h (struct symtabs_and_lines): Delete.
2981 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
2982
7c44b49c
PA
29832017-09-04 Pedro Alves <palves@redhat.com>
2984
2985 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2986 unittests/array-view-selftests.c.
2987 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
2988 * common/array-view.h: New file.
2989 * unittests/array-view-selftests.c: New file.
2990
e439fa14
PA
29912017-09-04 Pedro Alves <palves@redhat.com>
2992
2993 * cli/cli-cmds.c (edit_command): Pass message to
2994 ambiguous_line_spec.
2995 (list_command): Pass message to ambiguous_line_spec. Say
2996 "first"/"last" instead of "start" and "end" to be consistent with
2997 the manual.
2998 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
2999 them to print formatted message.
3000
7525b645
PA
30012017-09-04 Pedro Alves <palves@redhat.com>
3002
3003 * btrace.c (ftrace_add_pt): Pass btrace_insn to
3004 ftrace_update_insns by reference instead of pointer.
3005
badc0020
YQ
30062017-09-04 Yao Qi <yao.qi@linaro.org>
3007
3008 * i386-go32-tdep.c: Include x86-xstate.h.
3009 (i386_go32_init_abi): Call i386_target_description.
3010 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
3011 if xcr0 is X86_XSTATE_X87_MASK.
3012 * i386-tdep.h (tdesc_i386): Remove the declaration.
3013 (tdesc_i386_mmx): Likewise.
3014
d78bdb54
YQ
30152017-09-04 Yao Qi <yao.qi@linaro.org>
3016
3017 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
3018 X86_XSTATE_SSE_MASK instead of 0.
3019
ca1fa5ee
YQ
30202017-09-04 Yao Qi <yao.qi@linaro.org>
3021
3022 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
3023 i386_target_description.
3024 * i386-fbsd-nat.c (i386fbsd_read_description): Call
3025 i386_target_description.
3026 * i386-tdep.c (i386_gdbarch_init): Likewise.
3027
2434b019
YQ
30282017-09-04 Yao Qi <yao.qi@linaro.org>
3029
3030 * amd64-darwin-tdep.c: Include "x86-xstate.h".
3031 (x86_darwin_init_abi_64): Call amd64_target_description.
3032 * amd64-dicos-tdep.c: Likewise.
3033 * amd64-fbsd-nat.c: Likewise.
3034 * amd64-fbsd-tdep.c: Likewise.
3035 * amd64-nbsd-tdep.c: Likewise.
3036 * amd64-obsd-tdep.c: Likewise.
3037 * amd64-sol2-tdep.c: Likewise.
3038 * amd64-windows-tdep.c: Likewise.
3039 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
3040
0860c437
SM
30412017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3042
3043 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
3044 (btrace_function) <insn>: Change type to use std::vector.
3045 * btrace.c (ftrace_debug, ftrace_call_num_insn,
3046 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
3047 ftrace_update_insns, ftrace_compute_global_level_offset,
3048 btrace_stitch_bts, btrace_clear, btrace_insn_get,
3049 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
3050 change to std::vector.
3051 (ftrace_update_insns): Adjust to change to std::vector, change
3052 type of INSN parameter.
3053 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
3054 * record-btrace.c (btrace_call_history_insn_range,
3055 btrace_compute_src_line_range,
3056 record_btrace_frame_prev_register): Adjust to change to
3057 std::vector.
3058 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
3059 to change to std::vector.
3060
0638b7f9
TT
30612017-09-03 Tom Tromey <tom@tromey.com>
3062
3063 * corefile.c (reopen_exec_file): Use std::string.
3064
8f84fb0e
TT
30652017-09-03 Tom Tromey <tom@tromey.com>
3066
3067 * compile/compile.c (compile_register_name_mangled): Return
3068 std::string.
3069 * compile/compile-loc2c.c (pushf_register_address): Update.
3070 (pushf_register): Update.
3071 * compile/compile-c-types.c (convert_array): Update.
3072 * compile/compile-c-symbols.c (generate_vla_size): Update.
3073 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
3074 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
3075 (convert_one_symbol): Update.
3076 (generate_c_for_for_one_variable): Update.
3077 * compile/compile-c-support.c (c_get_range_decl_name): Return a
3078 std::string.
3079 (generate_register_struct): Update.
3080 * compile/compile-internal.h (c_get_range_decl_name): Return a
3081 std::string.
3082 (compile_register_name_mangled): Return std::string.
3083
18e9961f
TT
30842017-09-03 Tom Tromey <tom@tromey.com>
3085
3086 * utils.c (perror_string): Return a std::string.
3087 (throw_perror_with_name, perror_warning_with_name): Update.
3088
45343786
TT
30892017-09-03 Tom Tromey <tom@tromey.com>
3090
3091 * demangle.c (demangle_command): Use std::string,
3092 unique_xmalloc_ptr.
3093
b57af503
TT
30942017-09-03 Tom Tromey <tom@tromey.com>
3095
3096 * cli/cli-setshow.c (do_set_command): Use std::string.
3097
6eecf35f
TT
30982017-09-03 Tom Tromey <tom@tromey.com>
3099
3100 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
3101
56496dd4
TT
31022017-09-03 Tom Tromey <tom@tromey.com>
3103
3104 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
3105
e91a1fa7
TT
31062017-09-03 Tom Tromey <tom@tromey.com>
3107
3108 * mi/mi-cmd-env.c (env_execute_cli_command): Use
3109 gdb::unique_xmalloc_ptr.
3110
7ffd83d7
TT
31112017-09-03 Tom Tromey <tom@tromey.com>
3112
3113 * thread.c (print_thread_info_1): Use string_printf.
3114 (thread_apply_command, thread_apply_all_command): Use
3115 std::string.
3116
1ccbe998
TT
31172017-09-03 Tom Tromey <tom@tromey.com>
3118
3119 * valprint.c (val_print_string): Update.
3120 * gdbcore.h (memory_error_message): Return std::string.
3121 * corefile.c (memory_error_message): Return std::string.
3122 (memory_error): Update.
3123 * breakpoint.c (insert_bp_location): Update.
3124
23fdd69e
SM
31252017-09-03 Simon Marchi <simon.marchi@ericsson.com>
3126
3127 * target/waitstatus.h (target_waitstatus_to_string): Change
3128 return type to std::string.
3129 * target/waitstatus.c (target_waitstatus_to_string): Return
3130 std::string.
3131 * target.h (target_waitstatus_to_string): Remove declaration.
3132 * infrun.c (resume, clear_proceed_status_thread,
3133 print_target_wait_results, do_target_wait, save_waitstatus,
3134 stop_all_threads): Adjust.
3135 * record-btrace.c (record_btrace_wait): Adjust.
3136 * target-debug.h
3137 (target_debug_print_struct_target_waitstatus_p): Adjust.
3138
5c811d30
JK
31392017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
3140
3141 PR gdb/22046
3142 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
3143 detection.
3144
0a2dde4a
SDJ
31452017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
3146
3147 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
3148 for setting/unsetting environment variables on the remote target.
3149 (New remote packets): Add entries for QEnvironmentHexEncoded,
3150 QEnvironmentUnset and QEnvironmentReset.
3151 * common/environ.c (gdb_environ::operator=): Extend method to
3152 handle m_user_set_env_list and m_user_unset_env_list.
3153 (gdb_environ::clear): Likewise.
3154 (match_var_in_string): Change type of first parameter from 'char
3155 *' to 'const char *'.
3156 (gdb_environ::set): Extend method to handle
3157 m_user_set_env_list and m_user_unset_env_list.
3158 (gdb_environ::unset): Likewise.
3159 (gdb_environ::clear_user_set_env): New method.
3160 (gdb_environ::user_set_envp): Likewise.
3161 (gdb_environ::user_unset_envp): Likewise.
3162 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
3163 m_user_unset_env_list on move constructor/assignment.
3164 (unset): Add new default parameter 'update_unset_list = true'.
3165 (clear_user_set_env): New method.
3166 (user_set_envp): Likewise.
3167 (user_unset_envp): Likewise.
3168 (m_user_set_env_list): New std::set.
3169 (m_user_unset_env_list): Likewise.
3170 * common/rsp-low.c (hex2str): New function.
3171 (bin2hex): New overload for bin2hex function.
3172 * common/rsp-low.c (hex2str): New prototype.
3173 (str2hex): New overload prototype.
3174 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
3175 QEnvironmentUnset and QEnvironmentReset.
3176 (remote_protocol_features): Add QEnvironmentHexEncoded,
3177 QEnvironmentUnset and QEnvironmentReset packets.
3178 (send_environment_packet): New function.
3179 (extended_remote_environment_support): Likewise.
3180 (extended_remote_create_inferior): Call
3181 extended_remote_environment_support.
3182 (_initialize_remote): Add QEnvironmentHexEncoded,
3183 QEnvironmentUnset and QEnvironmentReset packet configs.
3184 * unittests/environ-selftests.c (gdb_selftest_env_var):
3185 New variable.
3186 (test_vector_initialization): New function.
3187 (test_init_from_host_environ): Likewise.
3188 (test_reinit_from_host_environ): Likewise.
3189 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
3190 Likewise.
3191 (test_unset_set_empty_vector): Likewise.
3192 (test_vector_clear): Likewise.
3193 (test_std_move): Likewise.
3194 (test_move_constructor):
3195 (test_self_move): Likewise.
3196 (test_set_unset_reset): Likewise.
3197 (run_tests): Rewrite in terms of the functions above.
3198
654670a4
WP
31992017-08-31 Weimin Pan <weimin.pan@oracle.com>
3200
3201 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
3202 (adi_available): Use a temp variable of type CORE_ADDR as argument
3203 3 when calling target_auxv_search.
3204 (adi_normalize_address): Use masks and xor operators to calculate
3205 normalized address.
3206 (adi_read_versions, adi_write_versions, adi_print_versions)
3207 (do_examine, do_assign): Use paddress.
3208
7755ddb7
JB
32092017-08-29 John Baldwin <jhb@FreeBSD.org>
3210
3211 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
3212 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
3213 out of loop and add supply of FIR.
3214 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
3215 add collect of FIR.
3216
fd437cbc
SM
32172017-08-28 Simon Marchi <simon.marchi@ericsson.com>
3218
3804a343 3219 PR gdb/21827
fd437cbc
SM
3220 * cli/cli-script.c (define_command): Don't convert command name
3221 to lower case.
3222
988f6b3d
JB
32232017-08-25 Joel Brobecker <brobecker@adacore.com>
3224
3225 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
3226 Update all callers accordingly. Remove all code blocks handling
3227 the case where DISPP is not NULL.
3228
663c44ac
JK
32292017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3230
3231 PR symtab/22003
3232 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
3233 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3234 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
3235
f1902523
JK
32362017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
3237
3238 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
3239 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
3240 (read_comp_units_from_section): New parameter abbrev_section, use
3241 read_and_check_comp_unit_head, allocate signatured_type if needed.
3242 (create_all_comp_units): Update read_comp_units_from_section caller.
3243
87215ad1
SDJ
32442017-08-23 Pedro Alves <palves@redhat.com>
3245
3246 PR remote/21852
3247 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
3248 to null_ptid and switch to thread without reading the registers
3249 after adding the inferior.
3250
6e41ddec
JK
32512017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3252
3253 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
3254 compile-gcc.
3255 * compile/compile.c (compile_gcc, show_compile_gcc): New.
3256 (compile_to_object): Implement compile_gcc.
3257 (_initialize_compile): Install "set compile-gcc". Initialize
3258 compile_gcc.
3259
e68c32d5
JK
32602017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
3261
3262 * compile/compile.c (compile_to_object): Conditionally call
3263 set_verbose. Conditionally call compile or compile_v0.
3264
58afddc6
WP
32652017-08-07 Weimin Pan <weimin.pan@oracle.com>
3266
3267 * sparc64-tdep.h: (adi_normalize_address): New export.
3268 * sparc-nat.h: (open_adi_tag_fd): New export.
3269 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
3270 * sparc64-linux-tdep.c:
3271 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
3272 (sparc64_linux_handle_segmentation_fault): New function.
3273 (sparc64_linux_init_abi): Register
3274 sparc64_linux_handle_segmentation_fault
3275 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
3276 (sparc64_addr_bits_remove): New function.
3277 (sparc64_init_abi): Register sparc64_addr_bits_remove.
3278 (MAX_PROC_NAME_SIZE): New macro.
3279 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
3280 (sparc64adilist): New variable.
3281 (adi_proc_list): New variable.
3282 (find_adi_info): New function.
3283 (add_adi_info): New function.
3284 (get_adi_info_proc): New function.
3285 (get_adi_info): New function.
3286 (info_adi_command): New function.
3287 (read_maps_entry): New function.
3288 (adi_available): New function.
3289 (adi_normalize_address): New function.
3290 (adi_align_address): New function.
3291 (adi_convert_byte_count): New function.
3292 (adi_tag_fd): New function.
3293 (adi_is_addr_mapped): New function.
3294 (adi_read_versions): New function.
3295 (adi_write_versions): New function.
3296 (adi_print_versions): New function.
3297 (do_examine): New function.
3298 (do_assign): New function.
3299 (adi_examine_command): New function.
3300 (adi_assign_command): New function.
3301 (_initialize_sparc64_adi_tdep): New function.
3302
11db9430
SM
33032017-08-22 Simon Marchi <simon.marchi@ericsson.com>
3304
3305 * breakpoint.c (breakpoints_info): Rename to ...
3306 (info_breakpoints_command): ... this.
3307 (watchpoints_info): Rename to ...
3308 (info_watchpoints_command): ... this.
3309 (tracepoints_info): Rename to ...
3310 (info_tracepoints_command): ... this.
3311 (_initialize_breakpoint): Adjust.
3312 * dcache.c (dcache_info): Rename to ...
3313 (info_display_command): ... this.
3314 (_initialize_dcache): Adjust.
3315 * frame.h (args_info): Rename to ...
3316 (info_args_command): ... this.
3317 (locals_info): Rename to ...
3318 (info_locals_command): ... this.
3319 * infcmd.c (nofp_registers_info): Rename to ...
3320 (info_registers_command): ... this.
3321 (float_info): Rename to ...
3322 (info_float_command): ... this.
3323 (program_info): Rename to ...
3324 (info_program_command): ... this.
3325 (all_registers_info): Rename to ...
3326 (info_all_registers_command): ... this.
3327 (vector_info): Rename to ...
3328 (info_vector_command): ... this.
3329 (float_info): Rename to ...
3330 (info_float_command): ... this.
3331 (_initialize_infcmd): Adjust.
3332 * inferior.h (term_info): Rename to ...
3333 (info_terminal_command): ... this.
3334 * inflow.c (term_info): Rename to ...
3335 (info_terminal_command): ... this.
3336 (_initialize_inflow): Adjust.
3337 * infrun.c (signals_info): Rename to ...
3338 (info_signals_command): ... this.
3339 (_initialize_infrun): Adjust.
3340 * objc-lang.c (classes_info): Rename to ...
3341 (info_classes_command): ... this.
3342 (selectors_info): Rename to ...
3343 (info_selectors_command): ... this.
3344 (_initialize_objc_language): Adjust.
3345 * printcmd.c (sym_info): Rename to ...
3346 (info_symbol_command): ... this.
3347 (address_info): Rename to ...
3348 (info_address_command): ... this.
3349 (display_info): Rename to ...
3350 (info_display_command): ... this.
3351 (_initialize_printcmd): Adjust.
3352 * reverse.c (bookmarks_info): Rename to ...
3353 (info_breakpoints_command): ... this.
3354 (_initialize_reverse): Adjust.
3355 * ser-go32.c (dos_info): Rename to ...
3356 (info_serial_command): ... this.
3357 (_initialize_ser_dos): Adjust.
3358 * skip.c (skip_info): Rename to ...
3359 (info_skip_command): ... this.
3360 (_initialize_step_skip): Adjust.
3361 * source.c (line_info): Rename to ...
3362 (info_line_command): ... this.
3363 (source_info): Rename to ...
3364 (info_source_command)
3365 * stack.c (frame_info): Rename to ...
3366 (info_frame_command): ... this.
3367 (locals_info): Rename to ...
3368 (info_locals_command): ... this.
3369 (args_info): Rename to ...
3370 (info_args_command): ... this.
3371 (_initialize_stack): Adjust.
3372 * symtab.c (sources_info): Rename to ...
3373 (info_sources_command): ... this.
3374 (variables_info): Rename to ...
3375 (info_variables_command): ... this.
3376 (functions_info): Rename to ...
3377 (info_functions_command): ... this.
3378 (types_info): Rename to ...
3379 (info_types_command): ... this.
3380 (_initialize_symtab): Adjust.
3381 * target.c (target_info): Rename to ...
3382 (info_target_command): ... this.
3383 (initialize_targets): Adjust.
3384 * tracepoint.c (tvariables_info): Rename to ...
3385 (info_tvariables_command): ... this.
3386 (scope_info): Rename to ...
3387 (info_scope_command): ... this.
3388 (trace_dump_actions): Adjust.
3389 (_initialize_tracepoint): Adjust.
3390
b270e6f9
TT
33912017-08-22 Tom Tromey <tom@tromey.com>
3392
3393 * breakpoint.h (install_breakpoint): Update.
3394 * breakpoint.c (add_solib_catchpoint): Update.
3395 (install_breakpoint): Change argument to a std::unique_ptr.
3396 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
3397 (create_breakpoint_sal, create_breakpoint): Update.
3398 (watch_command_1, catch_exec_command_1)
3399 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
3400 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
3401 Return the breakpoint.
3402 (set_raw_breakpoint_without_location, set_raw_breakpoint)
3403 (new_single_step_breakpoint): Update.
3404 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
3405 std::unique_ptr.
3406 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3407 std::unique_ptr.
3408 * break-catch-sig.c (create_signal_catchpoint): Use
3409 std::unique_ptr.
3410 * ada-lang.c (create_ada_exception_catchpoint): Use
3411 std::unique_ptr.
3412
36bd8eaa
TT
34132017-08-22 Tom Tromey <tom@tromey.com>
3414
3415 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
3416
56f37645
TT
34172017-08-22 Tom Tromey <tom@tromey.com>
3418
3419 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
3420 (lookup_partial_symbol): Update.
3421
0b581c69
TT
34222017-08-22 Tom Tromey <tom@tromey.com>
3423
3424 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
3425 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
3426 (find_and_open_source, symtab_to_fullname): Update.
3427 * psymtab.c (psymtab_to_fullname): Update.
3428
14278e1f
TT
34292017-08-22 Tom Tromey <tom@tromey.com>
3430
3431 * exec.c (exec_file_attach): Update.
3432 * linux-thread-db.c (try_thread_db_load): Update.
3433 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
3434 * utils.c (gdb_realpath): Change return type.
3435 (gdb_realpath_keepfile): Update.
3436 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
3437 (_initialize_utils): Register the new self test.
3438 * source.c (openp): Update.
3439 (find_and_open_source): Update.
3440 * nto-tdep.c (nto_find_and_open_solib): Update.
3441 * main.c (set_gdb_data_directory): Update.
3442 (captured_main_1): Update.
3443 * dwarf2read.c (dwarf2_get_dwz_file): Update
3444 (dw2_map_symbol_filenames): Update.
3445 * auto-load.c (auto_load_safe_path_vec_update): Update.
3446 (filename_is_in_auto_load_safe_path_vec): Change type of
3447 "filename_realp".
3448 (auto_load_objfile_script): Update.
3449 (file_is_auto_load_safe): Update. Use std::string.
3450 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
3451
4971c9a7
TT
34522017-08-22 Tom Tromey <tom@tromey.com>
3453
3454 * utils.c (gdb_realpath_keepfile): Return a
3455 gdb::unique_xmalloc_ptr.
3456 * exec.c (exec_file_attach): Update.
3457 * utils.h (gdb_realpath_keepfile): Return a
3458 gdb::unique_xmalloc_ptr.
3459
e3e41d58
TT
34602017-08-22 Tom Tromey <tom@tromey.com>
3461
3462 * compile/compile.c (compile_file_command): Use
3463 gdb::unique_xmalloc_ptr, std::string.
3464 * utils.c (gdb_abspath): Change return type.
3465 * source.c (openp): Update.
3466 * objfiles.c (allocate_objfile): Update.
3467 * main.c (set_gdb_data_directory): Update.
3468 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
3469
0d999a6e
ZZ
34702017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
3471
3472 * cli-cmds.c (list_commands): List actual code around more than
3473 one location.
3474
329d5e7e
JB
34752017-08-21 John Baldwin <jhb@FreeBSD.org>
3476
3477 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
3478
bf223d3e
PA
34792017-08-21 Pedro Alves <palves@redhat.com>
3480
3481 PR gdb/19487
3482 * c-exp.y (variable production): Handle function aliases.
3483 * minsyms.c (msymbol_is_text): New function.
3484 * minsyms.h (msymbol_is_text): Declare.
3485 * symtab.c (find_function_alias_target): New function.
3486 * symtab.h (find_function_alias_target): Declare.
3487
c973d0aa
PA
34882017-08-21 Pedro Alves <palves@redhat.com>
3489
3490 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
3491 typedefs.
3492 * typeprint.c (whatis_exp): If handling "whatis", and expression
3493 is OP_TYPE, strip one typedef level. Otherwise don't strip
3494 typedefs here.
3495 * valops.c (value_cast): Save "to" type before resolving
3496 stubs/typedefs. Use that type as resulting value's type.
3497
2989a365
TT
34982017-08-18 Tom Tromey <tom@tromey.com>
3499 Pedro Alves <palves@redhat.com>
3500
3501 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
3502 * sol-thread.c (sol_thread_resume, sol_thread_wait)
3503 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
3504 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
3505 * proc-service.c (ps_xfer_memory): Use scoped_restore.
3506 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
3507 (linux_get_siginfo_data): Add "thread" argument. Use
3508 scoped_restore.
3509 * linux-nat.c (linux_child_follow_fork)
3510 (check_stopped_by_watchpoint): Use scoped_restore.
3511 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
3512 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
3513 (restore_inferior_ptid, save_inferior_ptid): Remove.
3514 * btrace.c (btrace_fetch): Use scoped_restore.
3515 * bsd-uthread.c (bsd_uthread_fetch_registers)
3516 (bsd_uthread_store_registers): Use scoped_restore.
3517 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
3518 scoped_restore.
3519 * aix-thread.c (aix_thread_resume, aix_thread_wait)
3520 (aix_thread_xfer_partial): Use scoped_restore.
3521 * inferior.h (save_inferior_ptid): Remove.
3522
e60eb288
YQ
35232017-08-18 Yao Qi <yao.qi@linaro.org>
3524
3525 PR tdep/21818
3526 * arm-tdep.c (gdb_print_insn_arm): Mark
3527 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
3528
6d580b63
YQ
35292017-08-18 Yao Qi <yao.qi@linaro.org>
3530
3531 * NEWS: Mention GDBserver's new option "--selftest".
3532 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
3533 * selftest.c: Move it to common/selftest.c.
3534 * selftest.h: Move it to common/selftest.h.
3535 * selftest-arch.c (reset): New function.
3536 (tests_with_arch): Call reset.
3537
86dcbf50
YQ
35382017-08-18 Yao Qi <yao.qi@linaro.org>
3539
3540 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
3541 instead of exception_fprintf and printf_filtered.
3542
7649770c
YQ
35432017-08-18 Yao Qi <yao.qi@linaro.org>
3544
3545 * selftest.c (register_self_test): Rename it to
3546 selftests::register_test.
3547 (run_self_tests): selftest::run_tests.
3548 * selftest.h: Update declarations.
3549 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
3550 selftests::register_test_foreach_arch.
3551 * selftest-arch.h: Update declaration.
3552 * aarch64-tdep.c: Update.
3553 * arm-tdep.c: Likewise.
3554 * disasm-selftests.c: Likewise.
3555 * dwarf2loc.c: Likewise.
3556 * dwarf2-frame.c: Likewise.
3557 * findvar.c: Likewise.
3558 * gdbarch-selftests.c: Likewise.
3559 * maint.c (maintenance_selftest): Likewise.
3560 * regcache.c: Likewise.
3561 * rust-exp.y: Likewise.
3562 * selftest-arch.c: Likewise.
3563 * unittests/environ-selftests.c: Likewise.
3564 * unittests/function-view-selftests.c: Likewise.
3565 * unittests/offset-type-selftests.c: Likewise.
3566 * unittests/optional-selftests.c: Likewise.
3567 * unittests/scoped_restore-selftests.c: Likewise.
3568 * utils-selftests.c: Likewise.
3569
b0cba12e
PA
35702017-08-17 Pedro Alves <palves@redhat.com>
3571
3572 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
3573 local.
3574
4c8aa72d
PA
35752017-08-17 Pedro Alves <palves@redhat.com>
3576
3577 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
3578 field.
3579 (reset_die_in_process): Delete, replaced by ...
3580 (process_die_scope): ... this new class. Make it responsible for
3581 freeing cu->line_header too.
3582 (process_die): Use process_die_scope.
3583 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
3584 cu->line_header_die_owner. Don't release the line header if it's
3585 owned by the CU.
3586 (setup_type_unit_groups): Make the CU/DIE own the line header.
3587 Don't release the line header here.
3588
ba713918
AL
35892017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
3590
3591 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
3592
44d0fb3a
RK
35932017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
3594
3595 * NEWS: Mention new shortcuts for nexti and stepi in TUI
3596 Single-Key mode
3597
a5afdb16
RK
35982017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
3599
3600 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
3601 mode command list.
3602
47613aeb
SH
36032017-08-15 Stafford Horne <shorne@gmail.com>
3604
3605 * MAINTAINERS (Write After Approval): Add Stafford Horne.
3606
9c3cc999
SH
36072017-08-15 Stafford Horne <shorne@gmail.com>
3608
3609 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
3610
206726fb
SDJ
36112017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
3612
3613 PR gdb/21954
3614 * infcmd.c (unset_environment_command): Use the 'clear' method on
3615 the environment instead of resetting it.
3616
0335ac6d
JB
36172017-08-15 John Baldwin <jhb@FreeBSD.org>
3618
3619 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
3620 platforms.
3621
d3abe1c8
TT
36222017-08-14 Tom Tromey <tom@tromey.com>
3623
3624 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
3625 (print_binary_chars): Likewise.
3626 (BITS_IN_BYTES): Remove.
3627
d6382fff
TT
36282017-08-14 Tom Tromey <tom@tromey.com>
3629
3630 PR gdb/21675
3631 * valprint.c (LOW_ZERO): Change value to 034.
3632 (print_octal_chars): Add static_asserts for octal constants.
3633 * printcmd.c (print_scalar_formatted): Add 'd' case.
3634
f978cb06
TT
36352017-08-11 Tom Tromey <tom@tromey.com>
3636
3637 * symfile.c (add_symbol_file_command): Use std::vector.
3638
2f5404b3
TT
36392017-08-14 Tom Tromey <tom@tromey.com>
3640
3641 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
3642 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
3643 std::move.
3644 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
3645
de7985c3
PA
36462017-08-11 Pedro Alves <palves@redhat.com>
3647
3648 * infrun.c (process_event_stop_test): Adjust
3649 function_name_is_marked_for_skip call.
3650 * skip.c: Include <list>.
3651 (skiplist_entry): Make it a class with private fields, and
3652 getters/setters.
3653 (skiplist_entry_chain): Delete.
3654 (skiplist_entries): New.
3655 (skiplist_entry_count): Delete.
3656 (highest_skiplist_entry_num): New.
3657 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
3658 (add_skiplist_entry): Delete.
3659 (skiplist_entry::skiplist_entry): New.
3660 (skiplist_entry::add_entry): New.
3661 (skip_file_command, skip_function): Adjust.
3662 (compile_skip_regexp): Delete.
3663 (skip_command): Don't compile regexp here. Adjust to use
3664 skiplist_entry::add_entry.
3665 (skip_info): Adjust to use range-for and getters.
3666 (skip_enable_command, skip_disable_command): Adjust to use
3667 range-for and setters.
3668 (skip_delete_command): Adjust to use std::list.
3669 (add_skiplist_entry): Delete.
3670 (skip_file_p): Delete, refactored as ...
3671 (skiplist_entry::do_skip_file_p): ... this new method.
3672 (skip_gfile_p): Delete, refactored as ...
3673 (skiplist_entry::do_gskip_file_p): ... this new method.
3674 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
3675 (skiplist_entry::skip_function_p): ... this new method.
3676 (function_name_is_marked_for_skip): Now returns bool, and takes
3677 the function sal by const reference. Adjust to use range-for and
3678 skiplist_entry methods.
3679 (_initialize_step_skip): Remove references to
3680 skiplist_entry_chain, skiplist_entry_count.
3681 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
3682 takes the function sal by const reference.
3683
be7d3cd5
YQ
36842017-08-11 Yao Qi <yao.qi@linaro.org>
3685
3686 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
3687 (dwarf2_frame_cache): Remove reset_cache_cleanup.
3688 (dwarf2_frame_cache):
3689 * frame-unwind.c (frame_unwind_try_unwinder): Catch
3690 RETURN_MASK_ALL and set *this_case to NULL.
3691 * frame-unwind.h: Update comments.
3692
1c90d9f0
YQ
36932017-08-11 Yao Qi <yao.qi@linaro.org>
3694
3695 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
3696 (dwarf2_frame_state_copy_regs): Remove.
3697 (dwarf2_frame_state_free_regs): Remove.
3698 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
3699 (dwarf2_restore_rule): Call method .alloc_regs instead of
3700 dwarf2_frame_state_alloc_regs.
3701 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
3702 constructor. Call std::move.
3703 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
3704 (dwarf2_frame_cache): Likewise.
3705
3706 [GDB_SELF_TEST]: Include selftest.h and
3707 selftest-arch.h.
3708 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
3709 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
3710 execute_cfa_program_test.
3711
3712 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
3713 copy ctor, assignment operator, move assignment.
3714 <alloc_regs>: New method.
3715 <swap>: New method.
3716 (struct dwarf2_frame_state): Delete dtor.
3717 (dwarf2_frame_state_alloc_regs): Remove declaration.
3718 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
3719 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
3720
afe37d6b
YQ
37212017-08-11 Yao Qi <yao.qi@linaro.org>
3722
3723 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
3724 (dwarf2_frame_state::dwarf2_frame_state): New.
3725 (dwarf2_frame_state::~dwarf2_frame_state): New.
3726 (dwarf2_fetch_cfa_info): Update.
3727 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
3728 rather than a pointer. Update code.
3729 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
3730 dtor.
3731 <data_align, code_align, retaddr_column>: Change them to const.
3732 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
3733 to bool.
3734
b348037f
YQ
37352017-08-11 Yao Qi <yao.qi@linaro.org>
3736
3737 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
3738 <loc.exp>: New field.
3739 * dwarf2-frame.c (execute_cfa_program): Update.
3740 (dwarf2_frame_prev_register): Update.
3741
e7c9de26
PA
37422017-08-10 Pedro Alves <palves@redhat.com>
3743
3744 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
3745
e8c6b620
JB
37462017-08-09 John Baldwin <jhb@FreeBSD.org>
3747
3748 * fbsd-nat.c (struct fbsd_fork_info): Remove.
3749 (fbsd_pending_children): Use std::list.
3750 (fbsd_remember_child): Likewise.
3751 (fbsd_is_child_pending): Likewise.
3752 (fbsd_pending_vfork_done): Use std::forward_list.
3753 (fbsd_add_vfork_done): Likewise.
3754 (fbsd_is_vfork_done_pending): Likewise.
3755 (fbsd_next_vfork_done): Likewise.
3756
e4a26669
JB
37572017-08-09 John Baldwin <jhb@FreeBSD.org>
3758
3759 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
3760 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
3761 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
3762 for `mapfilename'.
3763 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 3764 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 3765
142311d3
JB
37662017-08-09 John Baldwin <jhb@FreeBSD.org>
3767
3768 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
3769 "filestuff.h".
3770 (fbsd_find_memory_regions): Fix `mapfile' initialization.
3771
42fa2e0e
TT
37722017-08-09 Tom Tromey <tom@tromey.com>
3773
3774 * skip.c (skiplist_entry): New constructor.
3775 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
3776 (skiplist_entry::file_is_glob): Now bool.
3777 (skiplist_entry::file, skiplist_entry::function): Now
3778 std::string.
3779 (make_skip_entry): Return a unique_ptr. Use new.
3780 (free_skiplist_entry, free_skiplist_entry_cleanup)
3781 (make_free_skiplist_entry_cleanup): Remove.
3782 (skip_command, skip_disable_command, add_skiplist_entry)
3783 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
3784 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
3785 (function_name_is_marked_for_skip): Update.
3786 (skip_delete_command): Update. Use delete.
3787
cd3af38d
JW
37882017-08-09 Jiong Wang <jiong.wang@arm.com>
3789
3790 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
3791 (aarch64_linux_core_read_description): New function.
3792 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
3793
29592bde
PA
37942017-08-09 Pedro Alves <palves@redhat.com>
3795
3796 * cp-name-parser.y (cp_comp_to_string): Return a
3797 gdb::unique_xmalloc_ptr<char>.
3798 * cp-support.c (replace_typedefs_qualified_name)
3799 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
3800 (cp_canonicalize_string_full): Use op= instead of explicit
3801 convertion.
3802 (cp_class_name_from_physname, method_name_from_physname)
3803 (cp_func_name, cp_remove_params): Adjust to use
3804 gdb::unique_xmalloc_ptr<char>.
3805 * cp-support.h (cp_comp_to_string): Return a
3806 gdb::unique_xmalloc_ptr<char>.
3807 * python/py-type.c (typy_lookup_type): Adjust to use
3808 gdb::unique_xmalloc_ptr<char>.
3809
b3340438
L
38102017-08-09 H.J. Lu <hongjiu.lu@intel.com>
3811
3812 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
3813
e88e8651
YQ
38142017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
3815 Yao Qi <yao.qi@linaro.org>
3816
3817 * cp-support.c (cp_canonicalize_string_full): Use
3818 gdb::unique_xmalloc_ptr<char>.
3819 (cp_canonicalize_string): Likewise.
3820
f5a29eb0
YQ
38212017-08-09 Yao Qi <yao.qi@linaro.org>
3822
3823 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
3824 * regformats/i386/amd64-avx-avx512.dat: Remove.
3825 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
3826 * regformats/i386/amd64-avx-mpx.dat:Remove.
3827 * regformats/i386/amd64-avx.dat: Remove.
3828 * regformats/i386/amd64-mpx.dat: Remove.
3829 * regformats/i386/i386-avx-avx512.dat: Remove.
3830 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
3831 * regformats/i386/i386-avx-mpx.dat: Remove.
3832 * regformats/i386/i386-mmx.dat: Remove.
3833 * regformats/i386/i386-mpx.dat: Remove.
3834
57757c2f
YQ
38352017-08-09 Yao Qi <yao.qi@linaro.org>
3836
3837 * amd64-tdep.h (tdesc_x32): Remove the declaration.
3838 * amd64-tdep.c: Don't include features/i386/x32*.c.
3839 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
3840 functions.
3841 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
3842 and i386/x32-avx-avx512.
3843 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
3844 and i386/x32.xml.
3845 * features/i386/x32-avx-avx512.c: Removed.
3846 * features/i386/x32-avx-avx512.xml: Removed.
3847 * features/i386/x32-avx.c: Removed.
3848 * features/i386/x32-avx.xml: Removed.
3849 * features/i386/x32.c: Removed.
3850 * features/i386/x32.xml: Removed.
3851 * regformats/i386/x32-avx-avx512.dat: Removed.
3852 * regformats/i386/x32-avx.dat: Removed.
3853 * regformats/i386/x32.dat: Removed.
3854
ba7b109b
MR
38552017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3856
3857 PR breakpoints/21886
3858 * mem-break.c (default_memory_insert_breakpoint): Use
3859 `->placed_address' rather than `->reqstd_address' for the
3860 breakpoint location.
3861
e347efc3
MR
38622017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3863
3864 * arch-utils.c (default_print_insn): Remove arch/mach/endian
3865 assertions.
3866
0dba2a6c
MR
38672017-08-07 Maciej W. Rozycki <macro@imgtec.com>
3868
3869 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
3870 a union of `tdep_info', `tdesc_data' and `id'.
3871 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
3872 rather than `info.tdep_info'.
3873 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
3874 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
3875 * i386-tdep.c (i386_gdbarch_init): Likewise.
3876 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
3877 * mips-tdep.c (mips_gdbarch_init): Likewise.
3878 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
3879 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
3880 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
3881 `info.tdep_info'.
3882 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
3883 `info.tdep_info'.
3884 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
3885 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
3886 `info.tdep_info'.
3887 * spu-tdep.c (spu_gdbarch_init): Likewise.
3888 * gdbarch.h: Regenerate.
3889
16eb6b2d
LS
38902017-08-07 Leszek Swirski <leszeks@google.com>
3891
7b005726 3892 PR symtab/20899
16eb6b2d
LS
3893 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
3894
74cbb09e
SM
38952017-08-07 Simon Marchi <simon.marchi@ericsson.com>
3896
3897 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
3898 (gdbsim_open): Rename gdb_argv args object to argv.
3899
ee0c3293
TT
39002017-08-05 Tom Tromey <tom@tromey.com>
3901
3902 * compile/compile-object-load.c (compile_object_load): Use
3903 gdb::unique_xmalloc_ptr.
3904 * cli/cli-dump.c (scan_filename): Rename from
3905 scan_filename_with_cleanup. Change return type.
3906 (scan_expression): Rename from scan_expression_with_cleanup.
3907 Change return type.
3908 (dump_memory_to_file, dump_value_to_file, restore_command):
3909 Use gdb::unique_xmalloc_ptr. Update.
3910 * cli/cli-cmds.c (find_and_open_script): Use
3911 gdb::unique_xmalloc_ptr.
3912 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
3913 * symmisc.c (maintenance_print_symbols)
3914 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
3915 * symfile.c (symfile_bfd_open, generic_load)
3916 (add_symbol_file_command, remove_symbol_file_command): Use
3917 gdb::unique_xmalloc_ptr.
3918 * source.c (openp): Use gdb::unique_xmalloc_ptr.
3919 * psymtab.c (maintenance_print_psymbols): Use
3920 gdb::unique_xmalloc_ptr.
3921 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
3922 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
3923 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
3924 (reload_shared_libraries_1): Likewise.
3925
3232fabd
TT
39262017-08-05 Tom Tromey <tom@tromey.com>
3927
3928 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
3929 (rust_op_vector, rust_set_vector): New typedefs.
3930 (current_parser): New global.
3931 (work_obstack): Change to pointer type. Update all users.
3932 (rust_ast, pstate): Remove globals.
3933 (struct rust_parser): New.
3934 (%union) <params, field_inits>: Change type.
3935 (start, tuple_expr, unit_expr, struct_expr_list, literal)
3936 (field_expr, expr_list, maybe_expr_list, type_list): Update.
3937 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
3938 (convert_params_to_types, convert_params_to_expression): Change
3939 type of "params".
3940 (ast_string): Change type of "fields".
3941 (rust_parse): Make a rust_parser. Remove cleanups.
3942 (rust_lex_tests): Make and install an auto_obstack.
3943
f02fd774
YQ
39442017-08-04 Yao Qi <yao.qi@linaro.org>
3945
3946 * configure.srv (ipa_x32_linux_regobj): New.
3947 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
3948 instead of X86_TDESC_AVX512.
3949 (initialize_low_tracepoint): Call
3950 init_registers_x32_avx_avx512_linux.
3951
91975afd
YQ
39522017-08-04 Yao Qi <yao.qi@linaro.org>
3953
3954 * utils.h (gdb_argv): Add namespace std for nullptr_t.
3955
2331fa3a
RK
39562017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
3957
3958 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
3959
744e4fe1
TT
39602017-08-03 Tom Tromey <tom@tromey.com>
3961
3962 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
3963 Remove.
3964 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
3965
1c034b67
TT
39662017-08-03 Tom Tromey <tom@tromey.com>
3967
3968 * python/py-param.c (compute_enum_values): Use gdb_argv.
3969
773a1edc
TT
39702017-08-03 Tom Tromey <tom@tromey.com>
3971
3972 * utils.h (struct gdb_argv_deleter): New.
3973 (gdb_argv): New class.
3974 * utils.c (gdb_argv::reset): New method.
3975 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
3976 * tracefile.c (tsave_command): Use gdb_argv.
3977 * top.c (new_ui_command): Use gdb_argv.
3978 * symmisc.c (maintenance_print_symbols)
3979 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
3980 * symfile.c (symbol_file_command, generic_load)
3981 (remove_symbol_file_command): Use gdb_argv.
3982 * stack.c (backtrace_command): Use gdb_argv.
3983 * source.c (add_path, show_substitute_path_command)
3984 (unset_substitute_path_command, set_substitute_path_command):
3985 Use gdb_argv.
3986 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
3987 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
3988 * remote.c (extended_remote_run, remote_put_command)
3989 (remote_get_command, remote_delete_command): Use gdb_argv.
3990 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
3991 (gdbsim_open): Use gdb_argv.
3992 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
3993 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
3994 * procfs.c (procfs_info_proc): Use gdb_argv.
3995 * interps.c (interpreter_exec_cmd): Use gdb_argv.
3996 * infrun.c (handle_command): Use gdb_argv.
3997 * inferior.c (add_inferior_command, clone_inferior_command):
3998 Use gdb_argv.
3999 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
4000 * exec.c (exec_file_command): Use gdb_argv.
4001 * cli/cli-cmds.c (alias_command): Use gdb_argv.
4002 * compile/compile.c (build_argc_argv): Use gdb_argv.
4003
0d50bde3
TT
40042017-08-03 Tom Tromey <tom@tromey.com>
4005
4006 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
4007
7f968c89
TT
40082017-08-03 Tom Tromey <tom@tromey.com>
4009
4010 * python/python.c (compute_python_string): Return std::string.
4011 (gdbpy_eval_from_control_command): Update.
4012 (do_start_initialization): Use std::string.
4013 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
4014 xstrprintf.
4015 * python/py-breakpoint.c (local_setattro): Use string_printf, not
4016 xstrprintf.
4017
3c9ebddd
TT
40182017-08-03 Tom Tromey <tom@tromey.com>
4019
4020 * top.h (do_restore_instream_cleanup): Remove.
4021 * top.c (do_restore_instream_cleanup): Remove.
4022 (read_command_file): Use scoped_restore.
4023 * cli/cli-script.c (execute_user_command): Use scoped_restore.
4024
b51b225e
TT
40252017-08-03 Tom Tromey <tom@tromey.com>
4026
4027 * cli/cli-script.c (execute_user_command)
4028 (execute_control_command): Use scoped_restore.
4029
ac991630
TT
40302017-08-03 Tom Tromey <tom@tromey.com>
4031
4032 * cli/cli-script.c (do_restore_user_call_depth): Remove.
4033 (execute_user_command): Remove user_call_depth; use
4034 user_args_stack's size instead.
4035
898e0c8e
TT
40362017-08-03 Tom Tromey <tom@tromey.com>
4037
4038 * top.h (in_user_command): Remove.
4039 * top.c (in_user_command): Remove.
4040 * cli/cli-script.c (do_restore_user_call_depth)
4041 (execute_user_command): Update.
4042
26fcd5d7
TT
40432017-08-03 Tom Tromey <tom@tromey.com>
4044
4045 * valops.c (search_struct_method): Use gdb::byte_vector.
4046 * valarith.c (value_concat): Use std::vector.
4047 * target.c (memory_xfer_partial): Use gdb::byte_vector.
4048 (simple_search_memory): Likewise.
4049 * printcmd.c (find_string_backward): Use gdb::byte_vector.
4050 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
4051 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
4052 * elfread.c (elf_rel_plt_read): Use std::string.
4053 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
4054 * cli/cli-dump.c (restore_section_callback): Use
4055 gdb::byte_vector.
4056
7c218e6c
TT
40572017-08-03 Tom Tromey <tom@tromey.com>
4058
4059 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
4060
31b68d4a
TT
40612017-08-03 Tom Tromey <tom@tromey.com>
4062
4063 * tui/tui-regs.c (tui_restore_gdbout): Remove.
4064 (tui_register_format): Use scoped_restore.
4065
2ec845e7
TT
40662017-08-03 Tom Tromey <tom@tromey.com>
4067
4068 * reverse.c (exec_direction_default): Remove.
4069 (exec_reverse_once): Use scoped_restore.
4070 * remote.c (restore_remote_timeout): Remove.
4071 (remote_flash_erase, remote_flash_write, remote_flash_done)
4072 (readchar, remote_serial_write): Use scoped_restore.
4073 * cli/cli-script.c (struct source_cleanup_lines_args)
4074 (source_cleanup_lines): Remove.
4075 (script_from_file): Use scoped_restore.
4076 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
4077 (source_command): Use scoped_restore.
4078
b3bc8453
TT
40792017-08-03 Tom Tromey <tom@tromey.com>
4080
4081 * utils.h (make_cleanup_free_so): Remove.
4082 * utils.c (do_free_so, make_cleanup_free_so): Remove.
4083 * solist.h (struct so_deleter): New.
4084 (so_list_up): New typedef.
4085 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
4086
e3ad2841
TT
40872017-08-03 Tom Tromey <tom@tromey.com>
4088
4089 * utils.h (make_cleanup_restore_current_language): Remove.
4090 * utils.c (do_restore_current_language)
4091 (make_cleanup_restore_current_language): Remove.
4092 * parse.c (parse_exp_in_context_1)
4093 (parse_expression_with_language): Use
4094 scoped_restore_current_language.
4095 * mi/mi-main.c (mi_cmd_execute): Use
4096 scoped_restore_current_language.
4097 * language.h (scoped_restore_current_language): New class.
4098
b80cf838
TT
40992017-08-03 Tom Tromey <tom@tromey.com>
4100
4101 * compile/compile.c (cleanup_unlink_file): Remove.
4102 (compile_to_object): Use gdb::unlinker.
4103 (eval_compile_command): Likewise.
4104
fad0444a
TT
41052017-08-03 Tom Tromey <tom@tromey.com>
4106
4107 * utils.h (make_cleanup_fclose): Remove.
4108 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
4109
6e7bc05c
TT
41102017-08-03 Tom Tromey <tom@tromey.com>
4111
4112 * top.c (open_terminal_stream): Return gdb_file_up.
4113 (new_ui_command): Update.
4114
4a45905b
TT
41152017-08-03 Tom Tromey <tom@tromey.com>
4116
4117 * source.c (print_source_lines_base, forward_search_command)
4118 (reverse_search_command): Use gdb_file_up.
4119
7cd06d6e
TT
41202017-08-03 Tom Tromey <tom@tromey.com>
4121
4122 * fbsd-nat.c (fbsd_find_memory_regions): Update.
4123
ed166945
TT
41242017-08-03 Tom Tromey <tom@tromey.com>
4125
4126 * cli/cli-cmds.c (find_and_open_script): Change return type.
4127 Remove "streamp" and "full_path" parameters.
4128 (source_script_with_search): Update.
4129 * auto-load.c (source_script_file): Update.
4130 * cli/cli-cmds.h (find_and_open_script): Change type.
4131 (open_script): New struct.
4132
d419f42d
TT
41332017-08-03 Tom Tromey <tom@tromey.com>
4134
4135 * xml-support.c (xml_fetch_content_from_file): Update.
4136 * ui-file.c (stdio_file::open): Update.
4137 * tracefile-tfile.c (tfile_start): Update.
4138 * remote.c (remote_file_put, remote_file_get): Update.
4139 * nat/linux-procfs.c (linux_proc_get_int)
4140 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
4141 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
4142 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
4143 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
4144 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
4145 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
4146 * linux-nat.c (linux_proc_pending_signals): Update.
4147 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
4148 (file_closer): Remove.
4149 * compile/compile.c (compile_to_object): Update.
4150 * common/filestuff.h (struct gdb_file_deleter): New.
4151 (gdb_file_up): New typedef.
4152 (gdb_fopen_cloexec): Change return type.
4153 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
4154 * cli/cli-dump.c (fopen_with_cleanup): Remove.
4155 (dump_binary_file, restore_binary_file): Update.
4156 * auto-load.c (auto_load_objfile_script_1): Update.
4157
4a2b031d
TT
41582017-08-03 Tom Tromey <tom@tromey.com>
4159
4160 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
4161 (info_static_tracepoint_markers_command): Likewise.
4162 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
4163 * skip.c (skip_info): Use ui_out_emit_table.
4164 * progspace.c (print_program_space): Use ui_out_emit_table.
4165 * osdata.c (info_osdata): Use ui_out_emit_table.
4166 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
4167 ui_out_emit_table.
4168 * linux-thread-db.c (info_auto_load_libthread_db): Use
4169 ui_out_emit_table.
4170 * inferior.c (print_inferior): Use ui_out_emit_table.
4171 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
4172 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
4173 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
4174 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
4175 * ui-out.h (class ui_out_emit_table): New.
4176
a4f320fd
MR
41772017-08-02 Maciej W. Rozycki <macro@imgtec.com>
4178
4179 * mips-tdep.c (mips_fpu_type_str): New function.
4180 (mips_dump_tdep): Call it.
4181
a2f1f308
MR
41822017-08-01 Maciej W. Rozycki <macro@imgtec.com>
4183
4184 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
4185 `->mips_fpu_type'.
4186
7e5ed83b
XR
41872017-07-31 Xavier Roirand <roirand@adacore.com>
4188
4189 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
4190
4c9dc811
XR
41912017-07-27 Xavier Roirand <roirand@adacore.com>
4192
4193 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
4194
27d41eac
YQ
41952017-07-26 Yao Qi <yao.qi@linaro.org>
4196
4197 * cli/cli-cmds.c (maintenancechecklist): New variable.
4198 * gdbcmd.h (maintenancechecklist): Declare it.
4199 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
4200 Call i386_linux_read_description with different masks.
4201 * maint.c (maintenance_check_command): New function.
4202 (_initialize_maint_cmds): Call add_prefix_cmd.
4203 * target-descriptions.c (tdesc_reg): override operator != and ==.
4204 (tdesc_type): Likewise.
4205 (tdesc_feature): Likewise.
4206 (target_desc): Likewise.
4207 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
4208 (maintenance_check_xml_descriptions): New function.
4209 (_initialize_target_descriptions) Add command "xml-descriptions".
4210 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
4211
ea03d0d3
YQ
42122017-07-26 Yao Qi <yao.qi@linaro.org>
4213
4214 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
4215 Include features/i386/32bit-*.c.
4216 (i386_linux_read_description): Generate target description if it
4217 doesn't exist.
4218 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
4219 functions.
4220 * features/i386/32bit-linux.c: Re-generated.
4221 * features/i386/32bit-sse.c: Likewise.
4222 * target-descriptions.c (print_c_feature::visit): Print code to
4223 set register number if needed.
4224 (print_c_feature) <m_next_regnum>: New field.
4225
25aa13e5
YQ
42262017-07-26 Yao Qi <yao.qi@linaro.org>
4227
4228 * features/Makefile (CFILES): Rename with TDESC_CFILES.
4229 (FEATURE_XMLFILES): New.
4230 (FEATURE_CFILES): New.
4231 New rules.
4232 (clean-cfiles): Remove generated c files.
4233 * features/i386/32bit-avx.c: Generated.
4234 * features/i386/32bit-avx512.c: Generated.
4235 * features/i386/32bit-core.c: Generated.
4236 * features/i386/32bit-linux.c: Generated.
4237 * features/i386/32bit-mpx.c: Generated.
4238 * features/i386/32bit-pkeys.c: Generated.
4239 * features/i386/32bit-sse.c: Generated.
4240 * target-descriptions.c: Include algorithm.
4241 (tdesc_element_visitor): Add method visit_end.
4242 (print_c_tdesc): Implement visit_end.
4243 (print_c_tdesc:: m_filename_after_features): Move it to
4244 protected.
4245 (print_c_feature): New class.
4246 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
4247 name starts with "i386/32bit-".
4248
6eb1e6a8
YQ
42492017-07-26 Yao Qi <yao.qi@linaro.org>
4250
4251 * target-descriptions.c (tdesc_element_visitor): New class.
4252 (tdesc_element): New class.
4253 (tdesc_reg): Inherit from tdesc_element.
4254 (tdesc_reg::accept): New function.
4255 (tdesc_type): Inherit from tdesc_element.
4256 (tdesc_type::accept): New function.
4257 (tdesc_feature): Inherit from tdesc_element.
4258 (tdesc_feature::accept): New function.
4259 (target_desc): Inherit from tdesc_element.
4260 (target_desc::target_desc): New.
4261 (target_desc::~target_desc): New.
4262 (target_desc::accept): New.
4263 (allocate_target_description): Use new.
4264 (free_target_description): Use delete.
4265 (print_c_tdesc): New class.
4266 (maint_print_c_tdesc_cmd): Adjust.
4267
4268 * features/aarch64.c: Re-generated.
4269 * features/arc-arcompact.c: Re-generated.
4270 * features/arc-v2.c: Re-generated.
4271 * features/arm/arm-with-iwmmxt.c: Re-generated.
4272 * features/arm/arm-with-m.c: Re-generated.
4273 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
4274 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
4275 * features/arm/arm-with-neon.c: Re-generated.
4276 * features/arm/arm-with-vfpv2.c: Re-generated.
4277 * features/arm/arm-with-vfpv3.c: Re-generated.
4278 * features/i386/amd64-avx-avx512.c: Re-generated.
4279 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
4280 * features/i386/amd64-avx.c: Re-generated.
4281 * features/i386/amd64-avx-linux.c: Re-generated.
4282 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
4283 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
4284 * features/i386/amd64-avx-mpx.c: Re-generated.
4285 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
4286 * features/i386/amd64.c: Re-generated.
4287 * features/i386/amd64-linux.c: Re-generated.
4288 * features/i386/amd64-mpx.c: Re-generated.
4289 * features/i386/amd64-mpx-linux.c: Re-generated.
4290 * features/i386/i386-avx-avx512.c: Re-generated.
4291 * features/i386/i386-avx-avx512-linux.c: Re-generated.
4292 * features/i386/i386-avx.c: Re-generated.
4293 * features/i386/i386-avx-linux.c: Re-generated.
4294 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
4295 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
4296 * features/i386/i386-avx-mpx.c: Re-generated.
4297 * features/i386/i386-avx-mpx-linux.c: Re-generated.
4298 * features/i386/i386.c: Re-generated.
4299 * features/i386/i386-linux.c: Re-generated.
4300 * features/i386/i386-mmx.c: Re-generated.
4301 * features/i386/i386-mmx-linux.c: Re-generated.
4302 * features/i386/i386-mpx.c: Re-generated.
4303 * features/i386/i386-mpx-linux.c: Re-generated.
4304 * features/i386/x32-avx-avx512.c: Re-generated.
4305 * features/i386/x32-avx-avx512-linux.c: Re-generated.
4306 * features/i386/x32-avx.c: Re-generated.
4307 * features/i386/x32-avx-linux.c: Re-generated.
4308 * features/i386/x32.c: Re-generated.
4309 * features/i386/x32-linux.c: Re-generated.
4310 * features/microblaze.c: Re-generated.
4311 * features/microblaze-with-stack-protect.c: Re-generated.
4312 * features/mips64-dsp-linux.c: Re-generated.
4313 * features/mips64-linux.c: Re-generated.
4314 * features/mips-dsp-linux.c: Re-generated.
4315 * features/mips-linux.c: Re-generated.
4316 * features/nds32.c: Re-generated.
4317 * features/nios2.c: Re-generated.
4318 * features/nios2-linux.c: Re-generated.
4319 * features/rs6000/powerpc-32.c: Re-generated.
4320 * features/rs6000/powerpc-32l.c: Re-generated.
4321 * features/rs6000/powerpc-403.c: Re-generated.
4322 * features/rs6000/powerpc-403gc.c : Re-generated.
4323 * features/rs6000/powerpc-405.c: Re-generated.
4324 * features/rs6000/powerpc-505.c: Re-generated.
4325 * features/rs6000/powerpc-601.c: Re-generated.
4326 * features/rs6000/powerpc-602.c: Re-generated.
4327 * features/rs6000/powerpc-603.c: Re-generated.
4328 * features/rs6000/powerpc-604.c: Re-generated.
4329 * features/rs6000/powerpc-64.c: Re-generated.
4330 * features/rs6000/powerpc-64l.c: Re-generated.
4331 * features/rs6000/powerpc-7400.c: Re-generated.
4332 * features/rs6000/powerpc-750.c: Re-generated.
4333 * features/rs6000/powerpc-860.c: Re-generated.
4334 * features/rs6000/powerpc-altivec32.c: Re-generated.
4335 * features/rs6000/powerpc-altivec32l.c: Re-generated.
4336 * features/rs6000/powerpc-altivec64.c: Re-generated.
4337 * features/rs6000/powerpc-altivec64l.c: Re-generated.
4338 * features/rs6000/powerpc-cell32l.c: Re-generated.
4339 * features/rs6000/powerpc-cell64l.c: Re-generated.
4340 * features/rs6000/powerpc-e500.c: Re-generated.
4341 * features/rs6000/powerpc-e500l.c: Re-generated.
4342 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
4343 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
4344 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
4345 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
4346 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
4347 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
4348 * features/rs6000/powerpc-vsx32.c: Re-generated.
4349 * features/rs6000/powerpc-vsx32l.c: Re-generated.
4350 * features/rs6000/powerpc-vsx64.c: Re-generated.
4351 * features/rs6000/powerpc-vsx64l.c: Re-generated.
4352 * features/rs6000/rs6000.c: Re-generated.
4353 * features/s390-linux32.c: Re-generated.
4354 * features/s390-linux32v1.c: Re-generated.
4355 * features/s390-linux32v2.c: Re-generated.
4356 * features/s390-linux64.c: Re-generated.
4357 * features/s390-linux64v1.c: Re-generated.
4358 * features/s390-linux64v2.c: Re-generated.
4359 * features/s390-te-linux64.c: Re-generated.
4360 * features/s390-tevx-linux64.c: Re-generated.
4361 * features/s390-vx-linux64.c: Re-generated.
4362 * features/s390x-linux64.c: Re-generated.
4363 * features/s390x-linux64v1.c: Re-generated.
4364 * features/s390x-linux64v2.c: Re-generated.
4365 * features/s390x-te-linux64.c: Re-generated.
4366 * features/s390x-tevx-linux64.c: Re-generated.
4367 * features/s390x-vx-linux64.c: Re-generated.
4368 * features/sparc/sparc32-solaris.c: Re-generated.
4369 * features/sparc/sparc64-solaris.c: Re-generated.
4370 * features/tic6x-c62x.c: Re-generated.
4371 * features/tic6x-c62x-linux.c: Re-generated.
4372 * features/tic6x-c64x.c: Re-generated.
4373 * features/tic6x-c64x-linux.c: Re-generated.
4374 * features/tic6x-c64xp.c: Re-generated.
4375 * features/tic6x-c64xp-linux.c: Re-generated.
4376
35b4818d
YQ
43772017-07-26 Yao Qi <yao.qi@linaro.org>
4378
4379 * i386-linux-tdep.c (i386_linux_read_description): New function.
4380 (i386_linux_core_read_description): Call
4381 i386_linux_read_description.
4382 * i386-linux-tdep.h (i386_linux_read_description): Declare.
4383 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
4384 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
4385 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
4386 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
4387 * x86-linux-nat.c (x86_linux_read_description): Call
4388 i386_linux_read_description.
4389
8e2141c6
YQ
43902017-07-26 Yao Qi <yao.qi@linaro.org>
4391
4392 * NEWS: Mention it.
4393 * features/Makefile (%.c: %.xml): Pass the xml file name to
4394 command "maint print c-tdesc".
4395 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
4396 name from 'arg'.
4397
b468ff4c
YQ
43982017-07-26 Yao Qi <yao.qi@linaro.org>
4399
4400 * target-descriptions.c (target_desc): Add ctor and dtor. Do
4401 in-class initialization.
4402 (tdesc_create_feature): Call new instead of XCNEW.
4403 (free_target_description): Ue delete.
4404
b9c0e1b4
JB
44052017-07-25 John Baldwin <jhb@FreeBSD.org>
4406
4407 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
4408
a04b5337
YQ
44092017-07-25 Yao Qi <yao.qi@linaro.org>
4410
4411 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
4412 constant.
4413 (amd64_x32_init_abi): Likewise.
4414 * amd64-tdep.h (amd64_init_abi): Update declaration.
4415 (amd64_x32_init_abi): Likewise.
4416
02ad7fc2
YQ
44172017-07-25 Yao Qi <yao.qi@linaro.org>
4418
4419 PR tdep/21717
4420 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
4421 condition for FPSCR.
4422 (arm_linux_store_inferior_registers): Likewise.
4423
b6f48cb0
TT
44242017-07-22 Tom Tromey <tom@tromey.com>
4425
4426 * break-catch-syscall.c (struct catch_syscall_inferior_data)
4427 <syscalls_counts>: Now a std::vector.
4428 (get_catch_syscall_inferior_data): Use "new".
4429 (catch_syscall_inferior_data_cleanup): Use "delete".
4430 (insert_catch_syscall, remove_catch_syscall)
4431 (clear_syscall_counts): Update.
4432
e12c9b7a
TT
44332017-07-22 Tom Tromey <tom@tromey.com>
4434
4435 * break-catch-syscall.c (syscall_catchpoint)
4436 <syscalls_to_be_caught>: Now a std::vector<int>
4437 (~syscall_catchpoint): Remove.
4438 (insert_catch_syscall, remove_catch_syscall)
4439 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
4440 (print_mention_catch_syscall, print_recreate_catch_syscall):
4441 Update.
4442 (create_syscall_event_catchpoint): Change type of "filter"
4443 parameter.
4444 (catch_syscall_split_args): Return a std::vector.
4445 (catch_syscall_command_1, catching_syscall_number_1): Update.
4446
4fa8aeac
TT
44472017-07-22 Tom Tromey <tom@tromey.com>
4448
4449 * break-catch-throw.c (struct exception_catchpoint)
4450 <exception_rx>: Now a std::string.
4451 (~exception_catchpoint): Remove.
4452 (print_one_detail_exception_catchpoint): Update.
4453 (handle_gnu_v3_exceptions): Change type of except_rx.
4454 (extract_exception_regexp): Return a std::string.
4455 (catch_exception_command_1): Update.
4456
f746a154
TT
44572017-07-22 Tom Tromey <tom@tromey.com>
4458
4459 * break-catch-sig.c (gdb_signal_type): Remove typedef.
4460 (struct signal_catchpoint) <signals_to_be_caught>: Now a
4461 std::vector.
4462 <catch_all>: Now a bool.
4463 (~signal_catchpoint): Remove.
4464 (signal_catchpoint_insert_location)
4465 (signal_catchpoint_remove_location)
4466 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
4467 (signal_catchpoint_print_mention)
4468 (signal_catchpoint_print_recreate)
4469 (signal_catchpoint_explains_signal): Update.
4470 (create_signal_catchpoint): Change type of "filter" and
4471 "catch_all".
4472 (catch_signal_split_args): Return a std::vector. Change type of
4473 "catch_all".
4474 (catch_signal_command): Update.
4475
47e77640
PA
44762017-07-20 Pedro Alves <palves@redhat.com>
4477
4478 * ada-lang.c (ada_language_defn): Make extern.
4479 (_initialize_ada_language): Remove add_language call.
4480 * c-lang.c (c_language_defn, cplus_language_defn)
4481 (asm_language_defn, minimal_language_defn): Make extern.
4482 (_initialize_c_language): Delete.
4483 * completer.c (compare_cstrings): Delete, moved to utils.h.
4484 * d-lang.c (d_language_defn): Make extern.
4485 (_initialize_d_language): Remove add_language calls.
4486 * defs.h (enum language): Add comment.
4487 * f-lang.c (f_language_defn): Make extern.
4488 (_initialize_f_language): Remove add_language call.
4489 * go-lang.c (go_language_defn): Make extern.
4490 (_initialize_go_language): Remove add_language call.
4491 * language.c: Include <algorithm>.
4492 (languages): Redefine as const array.
4493 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
4494 (set_language_command): Handle "local". Use for-range loop.
4495 (set_language): Remove loop.
4496 (language_enum): Rewrite.
4497 (language_def, language_str): Remove loops.
4498 (add_language): Delete.
4499 (add_set_language_command): New, based on add_languages.
4500 (skip_language_trampoline): Adjust.
4501 (local_language_defn): Delete.
4502 (language_gdbarch_post_init): Adjust.
4503 (_initialize_language): Remove add_language calls. Call
4504 add_set_language_command.
4505 * language.h (add_language): Delete.
4506 (auto_language_defn)
4507 (unknown_language_defn, minimal_language_defn, ada_language_defn)
4508 (asm_language_defn, c_language_defn, cplus_language_defn)
4509 (d_language_defn, f_language_defn, go_language_defn)
4510 (m2_language_defn, objc_language_defn, opencl_language_defn)
4511 (pascal_language_defn, rust_language_defn): Declare.
4512 * m2-lang.c (m2_language_defn): Make extern.
4513 (_initialize_m2_language): Remove add_language call.
4514 * objc-lang.c (objc_language_defn): Make extern.
4515 (_initialize_objc_language): Remove add_language call.
4516 * opencl-lang.c (opencl_language_defn): Make extern.
4517 (_initialize_opencl_language): Remove add_language call.
4518 * p-lang.c (pascal_language_defn): Make extern.
4519 (_initialize_pascal_language): Delete.
4520 * rust-lang.c (rust_language_defn): Make extern.
4521 (_initialize_rust_language): Delete.
4522 * utils.h (compare_cstrings): New static inline function.
4523
edb0c9cb
PA
45242017-07-20 Pedro Alves <palves@redhat.com>
4525
4526 * ada-lang.c (ada_to_fixed_type_1): Adjust.
4527 (get_var_value): Constify parameters.
4528 (get_int_var_value): Change prototype.
4529 (to_fixed_range_type): Adjust.
4530 * ada-lang.h (get_int_var_value): Change prototype.
4531
a778f165
PA
45322017-07-20 Pedro Alves <palves@redhat.com>
4533
4534 * dwarf2read.c (dw2_lookup_symbol): Use
4535 SYMBOL_MATCHES_SEARCH_NAME.
4536 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
4537
42edd901
PA
45382017-07-20 Pedro Alves <palves@redhat.com>
4539
4540 * block.c (block_iter_name_step, block_iter_name_first)
4541 (block_iter_name_next): Delete.
4542 (block_lookup_symbol_primary): Adjust to use
4543 dict_iter_match_first/dict_iter_match_next.
4544 * block.h (block_iter_name_first, block_iter_name_next): Delete
4545 declarations.
4546 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
4547 dict_iter_match_first/dict_iter_match_next.
4548
cf325299
PA
45492017-07-20 Pedro Alves <palves@redhat.com>
4550
4551 * cp-support.c (cp_find_first_component_aux): Add missing case for
4552 end of string.
4553
c5ed0576
DB
45542017-07-18 David Blaikie <dblaikie@gmail.com>
4555
4556 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
4557 of dwo_cu's dwo_file.
4558
27841e76
YQ
45592017-07-18 Yao Qi <yao.qi@linaro.org>
4560
4561 * remote.c (store_registers_using_G): Remove one line comment.
4562
cfb7e58b
YQ
45632017-07-18 Yao Qi <yao.qi@linaro.org>
4564
4565 * regcache.c (regcache_cpy): Simplify it.
4566 (regcache::cpy_no_passthrough): Remove it.
4567 * regcache.h (cpy_no_passthrough): Remove it.
4568 (regcache_dup, regcache_cpy): Update comments.
4569
386535dd
PA
45702017-07-18 Pedro Alves <palves@redhat.com>
4571
4572 * remote-sim.c (sim_command_completer): Adjust to work with a
4573 completion_tracker instead of a VEC.
4574
c45ec17c
PA
45752017-07-17 Pedro Alves <palves@redhat.com>
4576
4577 * completer.c (complete_source_filenames): New function.
4578 (complete_address_and_linespec_locations): New function.
4579 (location_completer): Use complete_address_and_linespec_locations.
4580 (completion_tracker::build_completion_result): Honor the tracker's
4581 request to suppress append.
4582 * completer.h (completion_tracker::suppress_append_ws)
4583 (completion_tracker::set_suppress_append_ws): New methods.
4584 (completion_tracker::m_suppress_append_ws): New field.
4585 (complete_source_filenames): New declaration.
4586 * linespec.c (linespec_complete_what): New.
4587 (struct ls_parser) <complete_what, completion_word,
4588 completion_quote_char, completion_quote_end, completion_tracker>:
4589 New fields.
4590 (string_find_incomplete_keyword_at_end): New.
4591 (linespec_lexer_lex_string): Record quote char. If in completion
4592 mode, don't throw.
4593 (linespec_lexer_consume_token): Advance the completion word point.
4594 (linespec_lexer_peek_token): Save/restore completion info.
4595 (save_stream_and_consume_token): New.
4596 (set_completion_after_number): New.
4597 (linespec_parse_basic): Set what to complete next depending on
4598 token. Handle function and label completions specially.
4599 (parse_linespec): Disable objc shortcut in completion mode. Set
4600 what to complete next depending on token type. Skip keyword if in
4601 completion mode.
4602 (complete_linespec_component, linespec_complete): New.
4603 * linespec.h (linespec_complete): Declare.
4604
be966d42
PA
46052017-07-17 Pedro Alves <palves@redhat.com>
4606
4607 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
4608 Handle 'operator<' / 'operator<<'.
4609
a2459270
PA
46102017-07-17 Pedro Alves <palves@redhat.com>
4611
4612 * completer.c (collect_explicit_location_matches): Handle
4613 MATCH_LABEL.
4614 (convert_explicit_location_to_linespec): New, factored out from
4615 ...
4616 (convert_explicit_location_to_sals): ... this.
4617 (complete_label): New.
4618 (linespec_complete_label, find_label_symbols_in_block): New.
4619 (find_label_symbols): Add completion_mode parameter and adjust to
4620 call find_label_symbols_in_block.
4621 * linespec.h (linespec_complete_label): Declare.
4622
c6756f62
PA
46232017-07-17 Pedro Alves <palves@redhat.com>
4624
4625 * ada-lang.c (ada_collect_symbol_completion_matches): Add
4626 complete_symbol_mode parameter.
4627 * cli/cli-cmds.c (complete_command): Get the completion result out
4628 of the handle_brkchars tracker if used a custom word point.
4629 * completer.c: Include "linespec.h".
4630 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
4631 (advance_to_expression_complete_word_point): New.
4632 (completion_tracker::completes_to_completion_word): New.
4633 (complete_files_symbols): Pass down
4634 complete_symbol_mode::EXPRESSION.
4635 (explicit_options, probe_options): New.
4636 (collect_explicit_location_matches): Complete on the
4637 explictit_loc->foo instead of word. Use
4638 linespec_complete_function. Handle MATCH_LINE. Handle offering
4639 keyword and options completions.
4640 (backup_text_ptr): Delete.
4641 (skip_keyword): New.
4642 (complete_explicit_location): Remove 'word' parameter. Add
4643 language, quoted_arg_start and quoted_arg_end parameters.
4644 Rewrite, parsing left to right.
4645 (location_completer): Rewrite.
4646 (location_completer_handle_brkchars): New function.
4647 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
4648 (enum complete_line_internal_reason): Adjust comments.
4649 (completion_tracker::discard_completions): New.
4650 (completer_handle_brkchars_func_for_completer): Handle
4651 location_completer.
4652 (gdb_custom_word_point_brkchars)
4653 (gdb_org_rl_basic_quote_characters): New.
4654 (gdb_completion_word_break_characters_throw)
4655 (completion_find_completion_word): Handle trackers that use a
4656 custom word point.
4657 (completion_tracker::advance_custom_word_point_by): New.
4658 (completion_tracker::build_completion_result): Don't rely on
4659 readline appending the quote char.
4660 (gdb_rl_attempted_completion_function_throw): Handle trackers that
4661 use a custom word point.
4662 (gdb_rl_attempted_completion_function): Restore
4663 rl_basic_quote_characters.
4664 * completer.h (class completion_tracker): Extend intro comment.
4665 (completion_tracker::set_quote_char)
4666 (completion_tracker::quote_char)
4667 (completion_tracker::set_use_custom_word_point)
4668 (completion_tracker::use_custom_word_point)
4669 (completion_tracker::custom_word_point)
4670 (completion_tracker::set_custom_word_point)
4671 (completion_tracker::advance_custom_word_point_by)
4672 (completion_tracker::completes_to_completion_word)
4673 (completion_tracker::discard_completions): New methods.
4674 (completion_tracker::m_quote_char)
4675 (completion_tracker::m_use_custom_word_point)
4676 (completion_tracker::m_custom_word_point): New fields.
4677 (advance_to_expression_complete_word_point): Declare.
4678 * f-lang.c (f_collect_symbol_completion_matches): Add
4679 complete_symbol_mode parameter.
4680 * language.h (struct language_defn)
4681 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
4682 parameter.
4683 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
4684 (linespec_complete_function): New function.
4685 (linespec_lexer_lex_keyword): Adjust.
4686 * linespec.h (linespec_keywords, linespec_complete_function): New
4687 declarations.
4688 * location.c (find_end_quote): New function.
4689 (explicit_location_lex_one): Add explicit_completion_info
4690 parameter. Save quoting info. Don't throw if being called for
4691 completion. Don't handle Ada operators here.
4692 (is_cp_operator, skip_op_false_positives, first_of)
4693 (explicit_location_lex_one_function): New function.
4694 (string_to_explicit_location): Replace 'dont_throw' parameter with
4695 an explicit_completion_info pointer parameter. Handle it. Don't
4696 use explicit_location_lex_one to lex function names. Use
4697 explicit_location_lex_one_function instead.
4698 * location.h (struct explicit_completion_info): New.
4699 (string_to_explicit_location): Replace 'dont_throw' parameter with
4700 an explicit_completion_info pointer parameter.
4701 * symtab.c (default_collect_symbol_completion_matches_break_on):
4702 Add complete_symbol_mode parameter. Handle LINESPEC mode.
4703 (default_collect_symbol_completion_matches)
4704 (collect_symbol_completion_matches): Add complete_symbol_mode
4705 parameter.
4706 (collect_symbol_completion_matches_type): Pass down
4707 complete_symbol_mode::EXPRESSION.
4708 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4709 parameter. Handle LINESPEC mode.
4710 * symtab.h (complete_symbol_mode): New.
4711 (default_collect_symbol_completion_matches_break_on)
4712 (default_collect_symbol_completion_matches)
4713 (collect_symbol_completion_matches)
4714 (collect_file_symbol_completion_matches): Add complete_symbol_mode
4715 parameter.
4716
1d550c82
PA
47172017-07-17 Pedro Alves <palves@redhat.com>
4718
4719 * utils.c (enum class strncmp_iw_mode): New.
4720 (strcmp_iw): Rename to ...
4721 (strncmp_iw_with_mode): ... this. Add string2_len and mode
4722 parameters. Handle them.
4723 (strncmp_iw): New.
4724 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
4725 * utils.h (strncmp_iw): Declare.
4726 (strcmp_iw): Move describing comments here.
4727
8090b426
PA
47282017-07-17 Pedro Alves <palves@redhat.com>
4729
4730 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
4731 CP_OPERATOR_STR.
4732 * c-typeprint.c (is_type_conversion_operator): Use
4733 CP_OPERATOR_STR.
4734 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
4735 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
4736 CP_OPERATOR_LEN.
4737 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
4738 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
4739 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
4740 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
4741 CP_OPERATOR_STR.
4742 * location.c: Include "cp-support.h".
4743 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
4744 CP_OPERATOR_STR.
4745 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
4746 CP_OPERATOR_LEN.
4747
6a2c1b87
PA
47482017-07-17 Pedro Alves <palves@redhat.com>
4749
4750 * cli/cli-cmds.c (complete_command): Use a completion tracker
4751 along with completion_find_completion_word for handle_brkchars
4752 phase.
4753 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
4754 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
4755 (struct gdb_rl_completion_word_info): New.
4756 (gdb_rl_find_completion_word): New.
4757 (completion_find_completion_word): New.
4758 * completer.h (completion_find_completion_word): Declare.
4759
eb3ff9a5
PA
47602017-07-17 Pedro Alves <palves@redhat.com>
4761
4762 * ada-lang.c (symbol_completion_match): Adjust comments.
4763 (symbol_completion_add): Replace vector parameter with
4764 completion_tracker parameter. Use it.
4765 (ada_make_symbol_completion_list): Rename to...
4766 (ada_collect_symbol_completion_matches): ... this. Add
4767 completion_tracker parameter and use it.
4768 (ada_language_defn): Adjust.
4769 * break-catch-syscall.c (catch_syscall_completer): Adjust
4770 prototype and work with completion_tracker instead of VEC.
4771 * breakpoint.c (condition_completer): Adjust prototype and work
4772 with completion_tracker instead of VEC.
4773 * c-lang.c (c_language_defn, cplus_language_defn)
4774 (asm_language_defn, minimal_language_defn): Adjust to renames.
4775 * cli/cli-cmds.c (complete_command): Rework using
4776 completion_tracker. Catch exceptions when completing.
4777 * cli/cli-decode.c (integer_unlimited_completer)
4778 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
4779 with completion_tracker instead of VEC.
4780 * command.h (struct completion_tracker): Forward declare.
4781 (completer_ftype, completer_handle_brkchars_ftype): Change
4782 types.
4783 (complete_on_cmdlist, complete_on_enum): Adjust.
4784 * completer.c: Include <algorithm>.
4785 (struct gdb_completer_state): New.
4786 (current_completion): New global.
4787 (readline_line_completion_function): Delete.
4788 (noop_completer, filename_completer)
4789 (filename_completer_handle_brkchars, complete_files_symbols)
4790 (linespec_location_completer): Adjust to work with a
4791 completion_tracker instead of a VEC.
4792 (string_or_empty): New.
4793 (collect_explicit_location_matches): Adjust to work with a
4794 completion_tracker instead of a VEC.
4795 (explicit_location_completer): Rename to ...
4796 (complete_explicit_location): ... this and adjust to work with a
4797 completion_tracker instead of a VEC.
4798 (location_completer): Adjust to work with a completion_tracker
4799 instead of a VEC.
4800 (add_struct_fields): Adjust to work with a completion_list instead
4801 of VEC.
4802 (expression_completer): Rename to ...
4803 (complete_expression): ... this and adjust to work with a
4804 completion_tracker instead of a VEC. Use complete_files_symbols.
4805 (expression_completer): Reimplement on top of complete_expression.
4806 (symbol_completer): Adjust to work with a completion_tracker
4807 instead of a VEC.
4808 (enum complete_line_internal_reason): Add describing comments.
4809 (complete_line_internal_normal_command): Adjust to work with a
4810 completion_tracker instead of a VEC.
4811 (complete_line_internal): Rename to ...
4812 (complete_line_internal_1): ... this and adjust to work with a
4813 completion_tracker instead of a VEC. Assert TEXT is NULL in the
4814 handle_brkchars phase.
4815 (new_completion_tracker): Delete.
4816 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
4817 complete_line_internal_1.
4818 (free_completion_tracker): Delete.
4819 (INITIAL_COMPLETION_HTAB_SIZE): New.
4820 (completion_tracker::completion_tracker)
4821 (completion_tracker::~completion_tracker): New.
4822 (maybe_add_completion): Delete.
4823 (completion_tracker::maybe_add_completion)
4824 (completion_tracker::add_completion)
4825 (completion_tracker::add_completions): New.
4826 (throw_max_completions_reached_error): Delete.
4827 (complete_line): Adjust to work with a completion_tracker instead
4828 of a VEC. Don't create a completion_tracker_t or check for max
4829 completions here.
4830 (command_completer, command_completer_handle_brkchars)
4831 (signal_completer, reg_or_group_completer_1)
4832 (reg_or_group_completer, default_completer_handle_brkchars):
4833 Adjust to work with a completion_tracker.
4834 (gdb_completion_word_break_characters_throw): New.
4835 (gdb_completion_word_break_characters): Reimplement.
4836 (line_completion_function): Delete.
4837 (completion_tracker::recompute_lowest_common_denominator)
4838 (expand_preserving_ws)
4839 (completion_tracker::build_completion_result)
4840 (completion_result::completion_result)
4841 (completion_result::completion_result)
4842 (completion_result::~completion_result)
4843 (completion_result::completion_result)
4844 (completion_result::release_match_list, compare_cstrings)
4845 (completion_result::sort_match_list)
4846 (completion_result::reset_match_list)
4847 (gdb_rl_attempted_completion_function_throw)
4848 (gdb_rl_attempted_completion_function): New.
4849 * completer.h (completion_list, struct completion_result)
4850 (class completion_tracker): New.
4851 (complete_line): Add completion_tracker parameter.
4852 (readline_line_completion_function): Delete.
4853 (gdb_rl_attempted_completion_function): New.
4854 (noop_completer, filename_completer, expression_completer)
4855 (location_completer, symbol_completer, command_completer)
4856 (signal_completer, reg_or_group_completer): Update prototypes.
4857 (completion_tracker_t, new_completion_tracker)
4858 (make_cleanup_free_completion_tracker): Delete.
4859 (enum maybe_add_completion_enum): Delete.
4860 (maybe_add_completion): Delete.
4861 (throw_max_completions_reached_error): Delete.
4862 * corefile.c (complete_set_gnutarget): Adjust to work with a
4863 completion_tracker instead of a VEC.
4864 * cp-abi.c (cp_abi_completer): Adjust to work with a
4865 completion_tracker instead of a VEC.
4866 * d-lang.c (d_language_defn): Adjust.
4867 * disasm.c (disassembler_options_completer): Adjust to work with a
4868 completion_tracker instead of a VEC.
4869 * f-lang.c (f_make_symbol_completion_list): Rename to ...
4870 (f_collect_symbol_completion_matches): ... this. Adjust to work
4871 with a completion_tracker instead of a VEC.
4872 (f_language_defn): Adjust.
4873 * go-lang.c (go_language_defn): Adjust.
4874 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
4875 Adjust to work with a completion_tracker instead of a VEC.
4876 * infrun.c (handle_completer): Likewise.
4877 * interps.c (interpreter_completer): Likewise.
4878 * interps.h (interpreter_completer): Likewise.
4879 * language.c (unknown_language_defn, auto_language_defn)
4880 (local_language_defn): Adjust.
4881 * language.h (language_defn::la_make_symbol_completion_list):
4882 Rename to ...
4883 (language_defn::la_collect_symbol_completion_matches): ... this
4884 and adjust to work with a completion_tracker instead of a VEC.
4885 * m2-lang.c (m2_language_defn): Adjust.
4886 * objc-lang.c (objc_language_defn): Adjust.
4887 * opencl-lang.c (opencl_language_defn): Adjust.
4888 * p-lang.c (pascal_language_defn): Adjust.
4889 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
4890 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
4891 with a completion_tracker.
4892 * rust-lang.c (rust_language_defn): Adjust.
4893 * symtab.c (free_completion_list, do_free_completion_list)
4894 (return_val, completion_tracker): Delete.
4895 (completion_list_add_name, completion_list_add_symbol)
4896 (completion_list_add_msymbol, completion_list_objc_symbol)
4897 (completion_list_add_fields, add_symtab_completions): Add
4898 completion_tracker parameter and use it.
4899 (default_make_symbol_completion_list_break_on_1): Rename to...
4900 (default_collect_symbol_completion_matches_break_on): ... this.
4901 Add completion_tracker parameter and use it instead of allocating
4902 a completion tracker here.
4903 (default_make_symbol_completion_list_break_on): Delete old
4904 implementation.
4905 (default_make_symbol_completion_list): Delete.
4906 (default_collect_symbol_completion_matches): New.
4907 (make_symbol_completion_list): Delete.
4908 (collect_symbol_completion_matches): New.
4909 (make_symbol_completion_type): Rename to ...
4910 (collect_symbol_completion_matches_type): ... this. Add
4911 completion_tracker parameter and use it instead of VEC.
4912 (make_file_symbol_completion_list_1): Rename to...
4913 (collect_file_symbol_completion_matches): ... this. Add
4914 completion_tracker parameter and use it instead of VEC.
4915 (make_file_symbol_completion_list): Delete.
4916 (add_filename_to_list): Use completion_list instead of a VEC.
4917 (add_partial_filename_data::list): Now a completion_list.
4918 (make_source_files_completion_list): Work with a completion_list
4919 instead of a VEC.
4920 * symtab.h: Include "completer.h".
4921 (default_make_symbol_completion_list_break_on)
4922 (default_make_symbol_completion_list, make_symbol_completion_list)
4923 (make_symbol_completion_type, make_file_symbol_completion_list)
4924 (make_source_files_completion_list): Delete.
4925 (default_collect_symbol_completion_matches_break_on)
4926 (default_collect_symbol_completion_matches)
4927 (collect_symbol_completion_matches)
4928 (collect_symbol_completion_matches_type)
4929 (collect_file_symbol_completion_matches)
4930 (make_source_files_completion_list): New.
4931 * top.c (init_main): Don't install a rl_completion_entry_function
4932 hook. Install a rl_attempted_completion_function hook instead.
4933 * tui/tui-layout.c (layout_completer): Adjust to work with a
4934 completion_tracker.
4935 * tui/tui-regs.c (tui_reggroup_completer):
4936 * tui/tui-win.c (window_name_completer, focus_completer)
4937 (winheight_completer): Adjust to work with a completion_tracker.
4938 * value.c: Include "completer.h".
4939 (complete_internalvar): Adjust to work with a completion_tracker.
4940 * value.h (complete_internalvar): Likewise.
4941
6e1dbf8c
PA
49422017-07-17 Pedro Alves <palves@redhat.com>
4943
4944 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
4945 renames.
4946 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
4947 comments to completer_ftype's declaration.
4948 <completer_handle_brkchars>: Change type to
4949 completer_handle_brkchars_ftype.
4950 * command.h (completer_ftype): Add describing comment and give
4951 names to parameters.
4952 (completer_ftype_void): Rename to ...
4953 (completer_handle_brkchars_ftype) ... this. Add describing comment.
4954 (set_cmd_completer_handle_brkchars): Adjust.
4955 * completer.c (filename_completer_handle_brkchars): New function.
4956 (complete_line_internal_normal_command): New function, factored
4957 out from ...
4958 (complete_line_internal): ... here.
4959 (command_completer_handle_brkchars)
4960 (default_completer_handle_brkchars)
4961 (completer_handle_brkchars_func_for_completer): New functions.
4962 * completer.h (set_gdb_completion_word_break_characters): Delete
4963 declaration.
4964 (completer_handle_brkchars_func_for_completer): New declaration.
4965 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
4966 completer_handle_brkchars_func_for_completer.
4967
78b13106
PA
49682017-07-17 Pedro Alves <palves@redhat.com>
4969
4970 * completer.c (symbol_completer): New function, based on
4971 make_symbol_completion_list_fn.
4972 * completer.h (symbol_completer): New declaration.
4973 * guile/scm-cmd.c (cmdscm_completers): Adjust.
4974 * python/py-cmd.c (completers): Adjust.
4975 * symtab.c (make_symbol_completion_list_fn): Delete.
4976 * symtab.h (make_symbol_completion_list_fn): Delete.
4977 * cli/cli-decode.c (add_cmd): Adjust.
4978
bbf2f4df
PA
49792017-07-17 Pedro Alves <palves@redhat.com>
4980
4981 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
4982 * dwarf2read.c: Include "filename-seen-cache.h".
4983 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
4984 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
4985 * filename-seen-cache.c: New file.
4986 * filename-seen-cache.h: New file.
4987 * symtab.c: Include "filename-seen-cache.h".
4988 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
4989 (create_filename_seen_cache, clear_filename_seen_cache)
4990 (delete_filename_seen_cache, filename_seen): Delete, parts moved
4991 to filename-seen-cache.h/filename-seen-cache.c.
4992 (output_source_filename, sources_info)
4993 (maybe_add_partial_symtab_filename)
4994 (make_source_files_completion_list): Adjust to use
4995 filename_seen_cache.
4996
330cdd98
PA
49972017-07-17 Pedro Alves <palves@redhat.com>
4998
4999 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
5000 fields.
5001 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
5002 dwarf2_debug_sections*)): New.
5003 (dwarf2_per_objfile::dwarf2_per_objfile(const
5004 dwarf2_per_objfile&)): Declare as deleted.
5005 (dwarf2_per_objfile::operator=): Declare as deleted.
5006 (dwarf2_per_objfile::dwarf2_per_objfile)
5007 (dwarf2_per_objfile::~dwarf2_per_objfile)
5008 (dwarf2_per_objfile::free_cached_comp_units): New.
5009 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
5010 ctor. Call dwarf2_per_objfile's ctor manually.
5011 (dwarf2_locate_sections): Deleted/refactored as ...
5012 (dwarf2_per_objfile::locate_sections): ... this new method.
5013 (free_cached_comp_units): Defer to
5014 dwarf2_per_objfile::free_cached_comp_units.
5015 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
5016
8880f2a9
TT
50172017-07-14 Tom Tromey <tom@tromey.com>
5018
5019 PR rust/21764:
5020 * rust-exp.y (convert_ast_to_expression): Add "want_type"
5021 parameter.
5022 <UNOP_SIZEOF>: Split into separate case.
5023 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
5024
65547233
TT
50252017-07-14 Tom Tromey <tom@tromey.com>
5026
5027 PR rust/21763:
5028 * symtab.c (symbol_matches_domain): Add language_rust to special
5029 case.
5030 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
5031 treat LOC_TYPEDEF symbols as variables.
5032
8f14146e
PA
50332017-07-14 Pedro Alves <palves@redhat.com>
5034
5035 * symtab.c (make_file_symbol_completion_list_1): Iterate over
5036 symtabs matching all symtabs with SRCFILE as file name instead of
5037 only considering the first hit, with lookup_symtab.
5038
2347965c
SM
50392017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5040
5041 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
5042 operator_name parameters.
5043 (gen_expr): Update function call.
5044
40f4af28
SM
50452017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5046
5047 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
5048 parameter.
5049 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
5050 Likewise.
5051 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
5052 parameter, use agent_expr::gdbarch instead, update function
5053 calls.
5054 (locexpr_tracepoint_var_ref): Likewise.
5055 (loclist_tracepoint_var_ref): Likewise.
5056 * ax-gdb.c (gen_trace_static_fields): Likewise.
5057 (gen_traced_pop): Likewise.
5058 (gen_frame_args_address): Likewise.
5059 (gen_frame_locals_address): Likewise.
5060 (gen_var_ref): Likewise.
5061 (gen_struct_ref_recursive): Likewise.
5062 (gen_static_field): Likewise.
5063 (gen_maybe_namespace_elt): Likewise.
5064 (gen_expr): Likewise.
5065 (gen_trace_for_var): Likewise.
5066 (gen_trace_for_expr): Likewise.
5067 (gen_trace_for_return_address): Likewise.
5068
053f8057
SM
50692017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5070
5071 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
5072 parameter.
5073 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
5074
6661ad48
SM
50752017-07-14 Simon Marchi <simon.marchi@ericsson.com>
5076
5077 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
5078 from ax, update calls.
5079 (gen_usual_arithmetic): Likewise.
5080 (gen_integral_promotions): Likewise.
5081 (gen_bitfield_ref): Likewise.
5082 (gen_primitive_field): Likewise.
5083 (gen_struct_ref_recursive): Likewise.
5084 (gen_struct_ref): Likewise.
5085 (gen_maybe_namespace_elt): Likewise.
5086 (gen_struct_elt_for_reference): Likewise.
5087 (gen_namespace_elt): Likewise.
5088 (gen_aggregate_elt_ref): Likewise.
5089 (gen_expr): Get gdbarch from ax, update calls.
5090 (gen_expr_binop_rest): Likewise.
5091
c55a47e7
PA
50922017-07-13 Pedro Alves <palves@redhat.com>
5093
5094 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
5095 as default tdesc.
5096 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
5097 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
5098 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
5099 tdesc_amd64_linux as default tdesc. Get final tdesc from the
5100 tdep.
5101 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
5102 Get final tdesc from the tdep.
5103 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
5104 default tdesc.
5105 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
5106 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
5107 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
5108 Use it as default tdesc.
5109 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
5110 down to amd_init_abi. No longer handle fallback tdesc here.
5111 * amd64-tdep.h (tdesc_x32): Declare.
5112 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
5113 parameter.
5114 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
5115 as default tdesc.
5116
55efceab
AA
51172017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5118
5119 * s390-linux-tdep.c (s390_process_record): Add support for
5120 instructions new in arch12.
5121
0aa37b65
JB
51222017-07-11 John Baldwin <jhb@FreeBSD.org>
5123
5124 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
5125 PT_GETFSBASE and PT_GETGSBASE.
5126 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
5127 PT_SETGSBASE.
5128
48aeef91
JB
51292017-07-11 John Baldwin <jhb@FreeBSD.org>
5130
5131 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
5132 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
5133 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
5134 those rules.
5135 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
5136 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
5137 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
5138 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
5139 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
5140 * features/i386/amd64.xml: Add 64bit-segments.xml.
5141 * features/i386/amd64-avx-avx512.c: Regenerated.
5142 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
5143 * features/i386/amd64-avx-mpx.c: Regenerated.
5144 * features/i386/amd64-avx.c: Regenerated.
5145 * features/i386/amd64-mpx.c: Regenerated.
5146 * features/i386/amd64.c: Regenerated.
5147 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
5148 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5149 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
5150 * regformats/i386/amd64-avx.dat: Regenerated.
5151 * regformats/i386/amd64-mpx.dat: Regenerated.
5152 * regformats/i386/amd64.dat: Regenerated.
5153
77c501bc
YQ
51542017-07-10 Yao Qi <yao.qi@linaro.org>
5155
5156 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
5157 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
5158
6dc8d757
AK
51592017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
5160
5161 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
5162 unsetenv.
5163 * gnulib/aclocal.m4: Regenerate.
5164 * gnulib/config.in: Regenerate.
5165 * gnulib/configure: Regenerate.
5166 * gnulib/import/Makefile.am: Regenerate.
5167 * gnulib/import/Makefile.in: Regenerate.
5168 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
5169 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
5170 * gnulib/import/m4/environ.m4: New file.
5171 * gnulib/import/m4/setenv.m4: New file.
5172 * gnulib/import/setenv.c: New file.
5173 * gnulib/import/unsetenv.c: New file.
5174
266934d1
SM
51752017-07-09 Simon Marchi <simon.marchi@ericsson.com>
5176
5177 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
5178 address when op is DW_OP_addr.
5179
03278692
TT
51802017-07-09 Tom Tromey <tom@tromey.com>
5181
5182 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
5183 check and apply to outer type.
5184
4b654465
JB
51852017-07-07 John Baldwin <jhb@FreeBSD.org>
5186
5187 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
5188 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
5189 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
5190 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
5191
2af9fc44
JB
51922017-07-07 John Baldwin <jhb@FreeBSD.org>
5193
5194 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
5195
382b69bb
JB
51962017-07-07 John Baldwin <jhb@FreeBSD.org>
5197
5198 * corelow.c (get_core_siginfo): Remove.
5199 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
5200 instead of get_core_siginfo.
5201 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
5202 * gdbarch.h: Re-generate.
5203 * gdbarch.c: Re-generate.
5204 * linux-tdep.c (linux_core_xfer_siginfo): New.
5205 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
5206
6e5eab33
JB
52072017-07-07 John Baldwin <jhb@FreeBSD.org>
5208
5209 * corelow.c (thread_section_name): Move to ...
5210 * gdbcore.h (thread_section_name): ... here.
5211
929edea9
JB
52122017-07-07 John Baldwin <jhb@FreeBSD.org>
5213
5214 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
5215 (struct siginfo32): New.
5216 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
5217 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
5218 via ptrace(PT_LWPINFO).
5219
762c974a
JB
52202017-07-07 John Baldwin <jhb@FreeBSD.org>
5221
5222 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
5223 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
5224 (fbsd_get_siginfo_type): New.
5225 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
5226 (_initialize_fbsd_tdep): New.
5227
33c5cd75
DB
52282017-07-06 David Blaikie <dblaikie@gmail.com>
5229
5230 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
5231 a singular dwo_unit*) to support multiple CUs in the same way that
5232 multiple TUs are supported.
5233 (create_cus_hash_table): Replace create_dwo_cu with a function for
5234 parsing multiple CUs from a DWO file.
5235 (open_and_init_dwo_file): Use create_cus_hash_table rather than
5236 create_dwo_cu.
5237 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
5238 htab_find, rather than comparing the signature to a singleton CU in
5239 the dwo_file.
5240
8455d262
PA
52412017-07-06 Pedro Alves <palves@redhat.com>
5242
5243 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
5244
4da3eb35
PA
52452017-07-04 Pedro Alves <palves@redhat.com>
5246
5247 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
5248 * gdbtypes.h (TYPE_STATIC): Delete.
5249 (struct fn_field) <is_public, is_abstract, is_static, is_final,
5250 is_synchronized, is_native>: Delete.
5251 <dummy>: Bump.
5252 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
5253 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
5254 (TYPE_FN_FIELD_ABSTRACT): Delete.
5255
5bfd255c
SM
52562017-07-03 Simon Marchi <simon.marchi@ericsson.com>
5257
5258 * buffer.h (buffer_finish): Fix spelling mistakes.
5259
25c54127
EZ
52602017-07-01 Eli Zaretskii <eliz@gnu.org>
5261
5262 * .dir-locals.el: Automatically switch to C-style comments in
5263 versions of Emacs that support the feature.
5264
dc4bde35
SDJ
52652017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5266 Pedro Alves <palves@redhat.com>
5267
5268 PR cli/21688
5269 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
5270 (process_next_line): New variable 'inline_cmd'.
5271 Adjust 'if' clauses for "python", "compile" and "guile" to use
5272 'command_name_equals' and check for '!inline_cmd'.
5273
51ed89aa
SDJ
52742017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
5275
5276 PR cli/21688
5277 * cli/cli-script.c (command_name_equals_not_inline): New function.
5278 (process_next_line): Adjust 'if' clauses for "python", "compile"
5279 and "guile" to use command_name_equals_not_inline.
5280
eb17d413
PA
52812017-06-29 Pedro Alves <palves@redhat.com>
5282
5283 * completer.c (expression_completer): Call
5284 linespec_location_completer instead of location_completer.
5285
195bcdd5
PA
52862017-06-29 Pedro Alves <palves@redhat.com>
5287
5288 * completer.c (expression_completer): Remove code that recomputes
5289 'text' from 'word'.
5290
adc764e7
YQ
52912017-06-29 Yao Qi <yao.qi@linaro.org>
5292
5293 * regformats/regdat.sh: Generate code with
5294 "ifndef IN_PROCESS_AGENT".
5295
6e75794e
PA
52962017-06-28 Pedro Alves <palves@redhat.com>
5297
5298 * command.h: Include "common/scoped_restore.h".
5299
bc491f2e
YQ
53002017-06-28 Yao Qi <yao.qi@linaro.org>
5301
5302 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
5303 instead of obstack_grow.
5304
41664b45
DG
53052017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
5306
5307 PR gdb/21337
5308 * symfile.c (reread_symbols): Call objfiles_changed just before
5309 read_symbols.
5310
6da67eb1
PA
53112017-06-27 Pedro Alves <palves@redhat.com>
5312
5313 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
5314 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
5315 (completion_list_add_symbol, completion_list_add_msymbol):
5316 ... these new functions.
5317 (add_symtab_completions)
5318 (default_make_symbol_completion_list_break_on_1): Adjust.
5319
23732b1e
PA
53202017-06-27 Pedro Alves <palves@redhat.com>
5321
5322 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
5323 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
5324 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
5325 dtor.
5326 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
5327 'storage_obstack' field an auto_obstack. In-class initialize all
5328 non-bitfield fields. Make minsyms_read bool.
5329 * symfile.c (read_symbols): Adjust.
5330
a4d1e79a
AH
53312017-06-27 Alan Hayward <alan.hayward@arm.com>
5332
5333 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
5334 (gdbsim_store_register): Likewise.
5335
8268c778
PA
53362017-06-27 Pedro Alves <palves@redhat.com>
5337
5338 * c-exp.y (name_obstack): Now an auto_obstack.
5339 (yylex): Use auto_obstack::clear.
5340 (c_parse): Use auto_obstack::clear instead of reinitializing and
5341 freeing the obstack.
5342 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
5343 * d-exp.y (name_obstack): Now an auto_obstack.
5344 (yylex): Use auto_obstack::clear.
5345 (d_parse): Use auto_obstack::clear instead of reinitializing and
5346 freeing the obstack.
5347 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
5348 auto_obstack.
5349 * dwarf2read.c (create_addrmap_from_index)
5350 (dwarf2_build_psymtabs_hard)
5351 (update_enumeration_type_from_children): Likewise.
5352 * gdb_obstack.h (auto_obstack): New type.
5353 * go-exp.y (name_obstack): Now an auto_obstack.
5354 (build_packaged_name): Use auto_obstack::clear.
5355 (go_parse): Use auto_obstack::clear instead of reinitializing and
5356 freeing the obstack.
5357 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
5358 auto_obstack.
5359 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
5360 * rust-exp.y (work_obstack): Now an auto_obstack.
5361 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
5362 reinitializing and freeing the obstack.
5363 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
5364 (host_char_to_target): Use auto_obstack.
5365 * utils.h (make_cleanup_obstack_free): Delete declaration.
5366 * valprint.c (generic_emit_char, generic_printstr): Use
5367 auto_obstack.
5368
db665f42
SM
53692017-06-27 Simon Marchi <simon.marchi@ericsson.com>
5370
5371 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
5372 thread.
5373 (darwin_init_thread_list): Don't update dummy thread.
5374 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
5375
873c0814
SM
53762017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5377
5378 * record-full.c (netorder16): Remove.
5379
8b5a7a6e
SM
53802017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5381
5382 * common/diagnostics.h: Define macros for GCC.
5383 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
5384 * common/vec.h: Include diagnostics.h.
5385 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
5386 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
5387 warning.
5388
d1435379
SM
53892017-06-26 Simon Marchi <simon.marchi@ericsson.com>
5390
5391 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
5392 New macro.
5393 * ada-lex.l: Ignore deprecated register warnings.
5394
cc75e0fd
SM
53952017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5396
5397 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
5398 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
5399
07809eaf
SM
54002017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5401
5402 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
5403 its own line.
5404
f076f034
SM
54052017-06-25 Simon Marchi <simon.marchi@ericsson.com>
5406
5407 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
5408
0dd5cbc5
AH
54092017-06-23 Alan Hayward <alan.hayward@arm.com>
5410
5411 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
5412 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
5413 (xtensa_register_read_masked): Likewise.
5414
d4c6ce5b
SDJ
54152017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
5416
5417 * common/environ.c (gdb_environ::unset): Update comment.
5418
16892a03
AH
54192017-06-22 Alan Hayward <alan.hayward@arm.com>
5420
5421 * python/py-unwind.c (pyuw_sniffer): Allocate space for
5422 registers.
5423
d7dcbefc
AH
54242017-06-22 Alan Hayward <alan.hayward@arm.com>
5425
5426 * record-full.c (record_full_exec_insn): Use byte_vector.
5427
b30ff123
YQ
54282017-06-22 Yao Qi <yao.qi@linaro.org>
5429
5430 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
5431 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
5432
4fa847d7
AH
54332017-06-22 Alan Hayward <alan.hayward@arm.com>
5434
5435 * remote.c (cached_reg): Move from here...
5436 * regcache.h (cached_reg): ...to here.
5437 * python/py-unwind.c (struct reg_info): Remove.
5438 (cached_frame_info): Use cached_reg_t.
5439 (pyuw_prev_register): Likewise.
5440 (pyuw_sniffer): Use cached_reg_t and allocate registers.
5441 (pyuw_dealloc_cache): Free all registers.
5442
f4906a9a
PA
54432017-06-22 Pedro Alves <palves@redhat.com>
5444 Simon Marchi <simon.marchi@ericsson.com>
5445
5446 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
5447 warning.
5448 * common/diagnostics.h: New file.
5449
b45a1208
PA
54502017-06-22 Pedro Alves <palves@redhat.com>
5451
5452 * common/agent.h: Add include guards.
5453
e4da2c61
SM
54542017-06-21 Simon Marchi <simon.marchi@ericsson.com>
5455
5456 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
5457 talk about addressable units instead of bytes.
5458
96160d60
SDJ
54592017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5460
5461 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
5462 of '::const_iterator'.
5463
9a6c7d9c
SDJ
54642017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
5465
5466 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5467 'unittests/environ-selftests.c'.
5468 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
5469 * charset.c (find_charset_names): Declare object 'iconv_env'.
5470 Update code to use 'iconv_env' object. Remove call to
5471 'free_environ'.
5472 * common/environ.c: Include <utility>.
5473 (make_environ): Delete function.
5474 (free_environ): Delete function.
5475 (gdb_environ::clear): New function.
5476 (gdb_environ::operator=): New function.
5477 (gdb_environ::get): Likewise.
5478 (environ_vector): Delete function.
5479 (set_in_environ): Delete function.
5480 (gdb_environ::set): New function.
5481 (unset_in_environ): Delete function.
5482 (gdb_environ::unset): New function.
5483 (gdb_environ::envp): Likewise.
5484 * common/environ.h: Include <vector>.
5485 (struct gdb_environ): Delete; transform into...
5486 (class gdb_environ): ... this class.
5487 (free_environ): Delete prototype.
5488 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
5489 environ_vector): Likewise.
5490 * infcmd.c (run_command_1): Update code to call
5491 'envp' from 'gdb_environ' class.
5492 (environment_info): Update code to call methods from 'gdb_environ'
5493 class.
5494 (unset_environment_command): Likewise.
5495 (path_info): Likewise.
5496 (path_command): Likewise.
5497 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
5498 (inferior::inferior): Initialize 'environment' using the host's
5499 information.
5500 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
5501 Include "environ.h".
5502 (class inferior) <environment>: Change type from 'struct
5503 gdb_environ' to 'gdb_environ'.
5504 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
5505 methods from 'gdb_environ' class.
5506 * solib.c (solib_find_1): Likewise
5507 * unittests/environ-selftests.c: New file.
5508
75c554cf
YQ
55092017-06-20 Yao Qi <yao.qi@linaro.org>
5510
5511 * features/i386/i386-linux.xml: Exchange the order of including
5512 32bit-linux.xml and 32bit-sse.xml.
5513 * features/i386/i386-linux.c: Regenerated.
5514
72ddacb7
YQ
55152017-06-20 Yao Qi <yao.qi@linaro.org>
5516
5517 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
5518 Delete copy ctor and assignment operator.
5519 (tdesc_type): Likewise.
5520 (tdesc_feature): Likewise.
5521 (tdesc_free_reg): Remove.
5522 (tdesc_create_reg): Use new.
5523 (tdesc_free_type): Remove.
5524 (tdesc_create_vector): Use new.
5525 (tdesc_create_union): Likewise.
5526 (tdesc_create_flags): Likewise.
5527 (tdesc_create_enum): Likewise.
5528 (tdesc_free_feature): Delete.
5529 (free_target_description): Use delete.
5530
325c9fd4
JB
55312017-06-19 John Baldwin <jhb@FreeBSD.org>
5532
5533 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
5534 registers.
5535
16b7a719
PA
55362017-06-19 Pedro Alves <palves@redhat.com>
5537
5538 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
5539 after gdb::unlinker.
5540
1c8e01c9
SDJ
55412017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
5542
5543 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
5544 gdb_environ to access an environment variable.
5545
ffce45d2
TP
55462017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5547
5548 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
5549 gdb_byte*.
5550
1d4fbac9
SM
55512017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5552
5553 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
5554
8465943a
SM
55552017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5556
5557 * configure: Re-generate.
5558 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
5559
3e019bdc
SM
55602017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5561
5562 * configure: Re-generate.
5563 * warning.m4: Pass -Werror to compiler when checking for
5564 supported warning flags.
5565
cf0dd6f0
SM
55662017-06-17 Simon Marchi <simon.marchi@ericsson.com>
5567
5568 * Makefile.in (COMPILE.pre): Add "-x c++".
5569
6f98355c
YQ
55702017-06-16 Alan Hayward <alan.hayward@arm.com>
5571 Pedro Alves <palves@redhat.com>
5572 Yao Qi <yao.qi@linaro.org>
5573
5574 * defs.h (RequireLongest): New.
5575 (extract_integer): Declare function template.
5576 (extract_signed_integer): Remove the declaration, but define it
5577 static inline.
5578 (extract_unsigned_integer): Likewise.
5579 (store_integer): Declare function template.
5580 (store_signed_integer): Remove the declaration, but define it
5581 static inline.
5582 (store_unsigned_integer): Likewise.
5583 * findvar.c (extract_integer): New function template.
5584 (extract_signed_integer): Remove.
5585 (extract_unsigned_integer): Remove.
5586 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
5587 instantiations.
5588 (store_integer): New function template.
5589 (store_signed_integer): Remove.
5590 (store_unsigned_integer): Remove.
5591 (store_integer): Explicit instantiations.
5592 * regcache.c (regcache_raw_read_signed): Update.
5593 (regcache::raw_read): New function.
5594 (regcache::raw_read_signed): Remove.
5595 (regcache::raw_read_unsigned): Remove.
5596 (regcache_raw_read_unsigned): Update.
5597 (regcache_raw_write_unsigned): Update.
5598 (regcache::raw_write_signed): Remove.
5599 (regcache::raw_write): New function.
5600 (regcache_cooked_read_signed): Update.
5601 (regcache::raw_write_unsigned): Remove.
5602 (regcache::cooked_read_signed): Remove.
5603 (regcache_cooked_read_unsigned): Update.
5604 (regcache::cooked_read_unsigned): Remove.
5605 (regcache_cooked_write_signed): Update.
5606 (regcache_cooked_write_unsigned): Update.
5607 * regcache.h (regcache) <raw_read_signed>: Remove.
5608 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
5609 <raw_read, raw_write>: New.
5610 <cooked_read_signed, cooked_write_signed>: Remove.
5611 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
5612 <cooked_read, cooked_write>: New.
5613 * sh64-tdep.c (sh64_pseudo_register_read): Update.
5614 (sh64_pseudo_register_write): Update.
5615
a87dc45a
AK
56162017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
5617
5618 * arc-tdep.c (arc_disassembler_options): New variable.
5619 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
5620 of default_print_insn.
5621 (arc_delayed_print_insn): Set info->section when needed,
5622 use default_print_insn to retrieve a disassembler.
5623
45159d6a
SDJ
56242017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
5625
5626 PR gdb/21574
5627 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
5628 to mention $SHELL and startup-with-shell.
5629
b46c4cf0
MF
56302017-06-14 Max Filippov <jcmvbkbc@gmail.com>
5631
5632 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
5633
6394c606
YQ
56342017-06-14 Yao Qi <yao.qi@linaro.org>
5635
5636 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
5637 default_print_insn instead of print_insn_aarch64.
5638 * arm-tdep.c (gdb_print_insn_arm): Call
5639 default_print_insn instead of print_insn_big_arm
5640 and print_insn_little_arm.
5641 * i386-tdep.c (i386_print_insn): Call default_print_insn
5642 instead of print_insn_i386.
5643 * ia64-tdep.c (ia64_print_insn): Call
5644 default_print_insn instead of print_insn_ia64.
5645 * mips-tdep.c (gdb_print_insn_mips): Call
5646 default_print_insn instead of print_insn_big_mips
5647 and print_insn_little_mips.
5648 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
5649 instead of print_insn_spu.
5650
d5722aa2
PA
56512017-06-14 Pedro Alves <palves@redhat.com>
5652
5653 * ada-lang.c: Include "common/byte-vector.h".
5654 (ada_value_primitive_packed_val): Use gdb::byte_vector.
5655 * charset.c (wchar_iterator::iterate): Resize the vector instead
5656 of reserving it.
5657 * common/byte-vector.h: Include "common/def-vector.h".
5658 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
5659 * cli/cli-dump.c: Include "common/byte-vector.h".
5660 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
5661 * common/byte-vector.h: New file.
5662 * common/def-vector.h: New file.
5663 * common/default-init-alloc.h: New file.
5664 * dwarf2loc.c: Include "common/byte-vector.h".
5665 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
5666 instead of reserving it.
5667 * dwarf2read.c: Include "common/byte-vector.h".
5668 (data_buf::m_vec): Now a gdb::byte_vector.
5669 * gdb_regex.c: Include "common/def-vector.h".
5670 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
5671 * mi/mi-main.c: Include "common/byte-vector.h".
5672 (mi_cmd_data_read_memory): Use gdb::byte_vector.
5673 * printcmd.c: Include "common/byte-vector.h".
5674 (print_scalar_formatted): Use gdb::byte_vector.
5675 * valprint.c: Include "common/byte-vector.h".
5676 (maybe_negate_by_bytes, print_decimal_chars): Use
5677 gdb::byte_vector.
5678
01ec7a27
SM
56792017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5680
5681 * darwin-nat.c: Include "nat/fork-inferior.h".
5682
848d9074
SM
56832017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5684
5685 * configure.nat: Factor out Darwin bits that are not
5686 architecture-specific. Add fork-inferior.o.
5687
3b912944
SM
56882017-06-13 Simon Marchi <simon.marchi@ericsson.com>
5689
5690 * configure.nat: Factor out AIX bits that are not
5691 architecture-specific. Add fork-inferior.o.
5692
55acdf22
AA
56932017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5694
5695 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
5696 (read_pieced_value, write_pieced_value): ...here. Reduce to
5697 wrappers that just call rw_pieced_value.
5698
f65e2044
AA
56992017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5700
5701 * dwarf2loc.c (write_pieced_value): When writing the data for a
5702 memory piece, use write_memory_with_notification instead of
5703 write_memory.
5704
23f945bf
AA
57052017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5706
5707 * valops.c (read_value_memory): Change embedded_offset to
5708 represent a bit offset instead of a byte offset.
5709 * value.h (read_value_memory): Adjust comment.
5710
f236533e
AA
57112017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5712
5713 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
5714 dest_offset_bits and source_offset_bits.
5715 (write_pieced_value): Likewise.
5716
65d84b76
AA
57172017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5718
5719 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
5720 given by DW_OP_bit_piece.
5721 (write_pieced_value): Likewise.
5722
242d31ab
AA
57232017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5724
5725 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
5726 some other preparations to the places where sufficient information
5727 is available.
5728 (write_pieced_value): Likewise.
5729
03c8af18
AA
57302017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5731
5732 * dwarf2loc.c (bits_to_bytes): New function.
5733 (read_pieced_value): Fix offset calculations for register pieces
5734 on big-endian targets.
5735 (write_pieced_value): Likewise.
5736
840989c1
AA
57372017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5738
5739 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
5740 (write_pieced_value): Likewise.
5741
359b19bb
AA
57422017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5743
5744 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
5745 transfer the source value's least significant bits, instead of its
5746 lowest-addressed ones. Rename type_len to max_offset.
5747 (read_pieced_value): Mirror above changes to write_pieced_value as
5748 applicable.
5749
07c9ca3b
AA
57502017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5751
5752 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
5753 truncate full bytes from dest_offset_bits before using it as an
5754 offset into the buffer.
5755
f1cc9874
AA
57562017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5757
5758 * dwarf2loc.c (write_pieced_value): Include transfer size in
5759 byte-wise check.
5760
cdaac320
AA
57612017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5762
5763 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
5764 calculation of this_size.
5765
af547a96
AA
57662017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5767
5768 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
5769 when targeting a bit-field.
5770 (write_pieced_value): Likewise.
5771
ddd7882a
AA
57722017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5773
5774 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
5775 (allocate_piece_closure): Drop addr_size parameter.
5776 (dwarf2_evaluate_loc_desc_full): Adjust call to
5777 allocate_piece_closure.
5778
e9352324
AA
57792017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5780
5781 PR gdb/21226
5782 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
5783 the LSB end, independent of endianness.
5784
d5d1163e
AA
57852017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
5786
5787 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
5788 size capping.
5789
032bb6ea
YQ
57902017-06-13 Yao Qi <yao.qi@linaro.org>
5791
5792 * mips-linux-nat.c: Move include features/mips*-linux.c to
5793 mips-linux-tdep.c.
5794 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
5795 to mips-linux-tdep.c.
5796 * mips-linux-tdep.c: Include features/mips*-linux.c
5797 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
5798 functions.
5799 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
5800 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
5801 (tdesc_mips64_dsp_linux): Declare.
5802
f12f6bad
TT
58032017-06-12 Tom Tromey <tom@tromey.com>
5804
5805 * valprint.h (val_print_type_code_int): Remove.
5806 * valprint.c (generic_val_print_int): Always call
5807 val_print_scalar_formatted.
5808 (val_print_type_code_int): Remove.
5809 * printcmd.c (print_scalar_formatted): Handle options->format==0.
5810 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
5811 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
5812 * ada-valprint.c (ada_val_print_num): Use
5813 val_print_scalar_formatted.
5814
d9109c80
TT
58152017-06-12 Tom Tromey <tom@tromey.com>
5816
5817 * printcmd.c (print_scalar_formatted): Unify the two switches.
5818 Don't convert scalars to LONGEST.
5819
4ac0cb1c
TT
58202017-06-12 Tom Tromey <tom@tromey.com>
5821
5822 PR exp/16225:
5823 * valprint.h (print_decimal_chars): Update.
5824 * valprint.c (maybe_negate_by_bytes): New function.
5825 (print_decimal_chars): Add "is_signed" argument.
5826 * printcmd.c (print_scalar_formatted): Update.
5827
30a25466
TT
58282017-06-12 Tom Tromey <tom@tromey.com>
5829
5830 PR exp/16225:
5831 * valprint.h (print_binary_chars, print_hex_chars): Update.
5832 * valprint.c (val_print_type_code_int): Update.
5833 (print_binary_chars): Add "zero_pad" argument.
5834 (emit_octal_digit): New function.
5835 (print_octal_chars): Don't zero-pad.
5836 (print_decimal_chars): Likewise.
5837 (print_hex_chars): Add "zero_pad" argument.
5838 * sh64-tdep.c (sh64_do_fp_register): Update.
5839 * regcache.c (regcache::dump): Update.
5840 * printcmd.c (print_scalar_formatted): Update.
5841 * infcmd.c (default_print_one_register_info): Update.
5842
b3464d03
PA
58432017-06-12 Pedro Alves <palves@redhat.com>
5844 Alan Hayward <alan.hayward@arm.com>
5845
5846 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
5847 (mips_eabi_push_dummy_call): Rename local 'regsize' to
5848 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
5849 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
5850 Assert that abi_regsize bytes fit in 'ref_valbuf'.
5851
4b76cda9
PA
58522017-06-12 Pedro Alves <palves@redhat.com>
5853
5854 * dwarf2read.c (mapped_symtab::data): Now a vector of
5855 symtab_index_entry instead of vector of
5856 std::unique_ptr<symtab_index_entry>. All users adjusted to check
5857 whether an element's name is NULL instead of checking whether the
5858 element itself is NULL.
5859 (find_slot): Change return type. Adjust.
5860 (hash_expand, , add_index_entry, uniquify_cu_indices)
5861 (write_hash_table): Adjust.
5862
e8f8bcb3
PA
58632017-06-12 Pedro Alves <palves@redhat.com>
5864
5865 * dwarf2read.c (recursively_count_psymbols): New function.
5866 (write_psymtabs_to_index): Call it to compute number of psyms and
5867 pass estimate size of psyms_seen to unordered_set's ctor.
5868
70a1152b
PA
58692017-06-12 Pedro Alves <palves@redhat.com>
5870
5871 * dwarf2read.c (write_hash_table): Check if key already exists
5872 before emplacing.
5873
c2f134ac
PA
58742017-06-12 Pedro Alves <palves@redhat.com>
5875
5876 * dwarf2read.c (data_buf::append_space): Rename to...
5877 (data_buf::grow): ... this, and make private. Adjust all callers.
5878 (data_buf::append_uint): New method.
5879 (add_address_entry, write_one_signatured_type)
5880 (write_psymtabs_to_index): Use it.
5881
a81e6d4d
PA
58822017-06-12 Pedro Alves <palves@redhat.com>
5883
5884 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
5885 (file_write (FILE *, const std::vector<Elem>&)): Delete.
5886 (data_buf::file_write): Call ::fwrite directly.
5887
6fd931f2
PA
58882017-06-12 Pedro Alves <palves@redhat.com>
5889
5890 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
5891 std::vector::erase.
5892
bc8f2430
JK
58932017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
5894
5895 Code cleanup: C++ify .gdb_index producer.
5896 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
5897 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
5898 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
5899 (create_strtab, add_string): Remove.
5900 (file_write, data_buf): New.
5901 (struct symtab_index_entry): Use std::vector for cu_indices.
5902 (struct mapped_symtab): Use std::vector for data.
5903 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
5904 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
5905 Remove.
5906 (find_slot): Change return type. Update it to the new data structures.
5907 (hash_expand, add_index_entry): Update it to the new data structures.
5908 (offset_type_compare): Remove.
5909 (uniquify_cu_indices): Update it to the new data structures.
5910 (c_str_view, c_str_view_hasher, vector_hasher): New.
5911 (add_indices_to_cpool): Remove.
5912 (write_hash_table): Update it to the new data structures.
5913 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
5914 (eq_psymtab_cu_index): Remove.
5915 (psym_index_map): New typedef.
5916 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
5917 reference and std::unordered_map for cu_index_htab.
5918 (add_address_entry, add_address_entry_worker, write_address_map)
5919 (write_psymbols): Update it to the new data structures.
5920 (write_obstack): Remove.
5921 (struct signatured_type_index_data): Change types_list to a data_buf
5922 reference and psyms_seen to a std::unordered_set reference.
5923 (write_one_signatured_type, recursively_write_psymbols)
5924 (write_psymtabs_to_index): Update it to the new data structures.
5925
c4dcb155
SM
59262017-06-11 Simon Marchi <simon.marchi@ericsson.com>
5927
5928 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
5929 separate-debug-file commands.
5930 * symfile.h (separate_debug_file_debug): New global.
5931 * symfile.c (separate_debug_file_debug): New global.
5932 (separate_debug_file_exists, find_separate_debug_file): Add
5933 debug output.
5934 (_initialize_symfile): Add "set debug separate-debug-file"
5935 command.
5936 * build-id.c (build_id_to_debug_bfd,
5937 find_separate_debug_file_by_buildid): Add debug output.
5938
6d45d4b4
SM
59392017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
5940
5941 * gdbarch.sh (displaced_step_free_closure): Remove.
5942 * gdbarch.h, gdbarch.c: Re-generate.
5943 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
5944 displaced_step_free_closure.
5945 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
5946 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
5947 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
5948 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
5949 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
5950 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
5951 * arch-utils.h (simple_displaced_step_free_closure): Remove.
5952 * arch-utils.c (simple_displaced_step_free_closure): Remove.
5953 * infrun.c (displaced_step_clear): Call xfree instead of
5954 gdbarch_displaced_step_free_closure.
5955
2f91880f
SDJ
59562017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
5957
5958 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
5959 NULL".
5960
b8b6e72f
AH
59612017-06-08 Alan Hayward <alan.hayward@arm.com>
5962
5963 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
5964 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
5965 (mn10300_push_dummy_call): Likewise.
5966
5369082e
AH
59672017-06-08 Alan Hayward <alan.hayward@arm.com>
5968
5969 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
5970
ff4ca5ac
AH
59712017-06-08 Alan Hayward <alan.hayward@arm.com>
5972
5973 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
5974
aefd8b33
SDJ
59752017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5976
5977 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
5978 able to start inferiors using a shell.
5979 (New remote packets): Announce new packet "QStartupWithShell".
5980 * remote.c: Add PACKET_QStartupWithShell.
5981 (extended_remote_create_inferior): Handle new
5982 PACKET_QStartupWithShell.
5983 (remote_protocol_features) <QStartupWithShell>: New entry for
5984 PACKET_QStartupWithShell.
5985 (_initialize_remote): Call "add_packet_config_cmd" for
5986 QStartupShell.
5987
2090129c
SDJ
59882017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
5989 Pedro Alves <palves@redhat.com>
5990
5991 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
5992 and "nat/fork-inferior.h".
5993 * common/common-inferior.h: New file, with contents from
5994 "gdb/inferior.h".
5995 * commom/common-utils.c: Include "common-utils.h".
5996 (stringify_argv): New function.
5997 * common/common-utils.h (stringify_argv): New prototype.
5998 * configure.nat: Add "fork-inferior.o" as a dependency for
5999 "*linux*", "fbsd*" and "nbsd*" hosts.
6000 * corefile.c (get_exec_file): Update comment.
6001 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
6002 instead of "startup_inferior".
6003 (darwin_create_inferior): Call "add_thread_silent" after
6004 "fork_inferior".
6005 * fork-child.c: Cleanup unnecessary includes.
6006 (SHELL_FILE): Move to "common/common-fork-child.c".
6007 (environ): Likewise.
6008 (exec_wrapper): Initialize.
6009 (get_exec_wrapper): New function.
6010 (breakup_args): Move to "common/common-fork-child.c"; rename to
6011 "breakup_args_for_exec".
6012 (escape_bang_in_quoted_argument): Move to
6013 "common/common-fork-child.c".
6014 (saved_ui): New variable.
6015 (prefork_hook): New function.
6016 (postfork_hook): Likewise.
6017 (postfork_child_hook): Likewise.
6018 (gdb_startup_inferior): Likewise.
6019 (fork_inferior): Move to "common/common-fork-child.c". Update
6020 function to support gdbserver.
6021 (startup_inferior): Likewise.
6022 * gdbcore.h (get_exec_file): Remove declaration.
6023 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
6024 instead of "startup_inferior". Call "add_thread_silent" after
6025 "fork_inferior".
6026 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
6027 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
6028 instead of "startup_inferior". Call "add_thread_silent" after
6029 "fork_inferior".
6030 * inferior.h: Include "common-inferior.h".
6031 (trace_start_error): Move to "common/common-utils.h".
6032 (trace_start_error_with_name): Likewise.
6033 (fork_inferior): Move prototype to "nat/fork-inferior.h".
6034 (startup_inferior): Likewise.
6035 (gdb_startup_inferior): New prototype.
6036 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
6037 * nat/fork-inferior.h: New file.
6038 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
6039 instead of "startup_inferior". Call "add_thread_silent" after
6040 "fork_inferior".
6041 * target.h (target_terminal_init): Move prototype to
6042 "target/target.h".
6043 (target_terminal_inferior): Likewise.
6044 (target_terminal_ours): Likewise.
6045 * target/target.h (target_terminal_init): New prototype, moved
6046 from "target.h".
6047 (target_terminal_inferior): Likewise.
6048 (target_terminal_ours): Likewise.
6049 * utils.c (gdb_flush_out_err): New function.
6050
043a4934
SDJ
60512017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6052
6053 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
6054 * common/common-gdbthread.h: New file, with parts from
6055 "gdb/gdbthread.h".
6056 * gdbthread.h: Include "common-gdbthread.h".
6057 (switch_to_thread): Moved to "common/common-gdbthread.h".
6058
15652511
SDJ
60592017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
6060
6061 * Makefile.in (SFILES): Add "common/job-control.c".
6062 (HFILES_NO_SRCDIR): Add "common/job-control.h".
6063 (COMMON_OBS): Add "job-control.o".
6064 * common/job-control.c: New file, with contents from
6065 "gdb/inflow.c".
6066 * common/job-control.h: New file, with contents from "terminal.h".
6067 * fork-child.c: Include "job-control.h".
6068 * inflow.c: Include "job-control.h".
6069 (gdb_setpgid): Move to "common/common-inflow.c".
6070 (_initialize_inflow): Move setting of "job_control" to
6071 "handle_job_control".
6072 * terminal.h (job_control): Moved to "common/common-terminal.h".
6073 (gdb_setpgid): Likewise.
6074 * top.c: Include "job_control.h".
6075 * utils.c: Likewise.
6076 (job_control): Moved to "job-control.c".
6077
2d7cc5c7
PA
60782017-06-07 Pedro Alves <palves@redhat.com>
6079
6080 * Makefile.in (SFILES): Add gdb_regex.c.
6081 (COMMON_OBS): Add gdb_regex.o.
6082 * ada-lang.c (ada_add_standard_exceptions)
6083 (ada_add_exceptions_from_frame, name_matches_regex)
6084 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
6085 parameter type to compiled_regex. Adjust.
6086 (ada_exceptions_list): Use compiled_regex.
6087 * break-catch-throw.c (exception_catchpoint::pattern): Now a
6088 std::unique_ptr<compiled_regex>.
6089 (exception_catchpoint::~exception_catchpoint): Remove regfree
6090 call.
6091 (check_status_exception_catchpoint): Adjust to use compiled_regex.
6092 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
6093 * breakpoint.c (solib_catchpoint::compiled): Now a
6094 std::unique_ptr<compiled_regex>.
6095 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
6096 (check_status_catch_solib): Adjust to use compiled_regex.
6097 (add_solib_catchpoint): Adjust to use compiled_regex.
6098 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
6099 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
6100 compiled_regex reference. Adjust to use it.
6101 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
6102 declaration. Include "gdb_regex.h".
6103 (apropos_cmd): Change regex parameter to compiled_regex reference.
6104 * gdb_regex.c: New file.
6105 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
6106 declarations.
6107 (class compiled_regex): New.
6108 * linux-tdep.c: Include "common/gdb_optional.h".
6109 (struct mapping_regexes): New, factored out from
6110 mapping_is_anonymous_p, and adjusted to use compiled_regex.
6111 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
6112 gdb::optional and remove cleanups. Adjust to compiled_regex.
6113 * probe.c: Include "common/gdb_optional.h".
6114 (collect_probes): Use compiled_regex and gdb::optional and remove
6115 cleanups.
6116 * skip.c: Include "common/gdb_optional.h".
6117 (skiplist_entry::compiled_function_regexp): Now a
6118 gdb::optional<compiled_regex>.
6119 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
6120 (free_skiplist_entry): Remove regfree call.
6121 (compile_skip_regexp, skip_rfunction_p): Adjust to use
6122 compiled_regex and gdb::optional.
6123 * symtab.c: Include "common/gdb_optional.h".
6124 (search_symbols): Use compiled_regex and gdb::optional.
6125 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
6126 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
6127 to gdb_regex.c.
6128
50d6adef
AH
61292017-06-07 Alan Hayward <alan.hayward@arm.com>
6130
6131 * regcache.c (regcache::save): Avoid buffer use.
6132 (regcache::dump): Likewise.
6133
4a8a33c8
AH
61342017-06-07 Alan Hayward <alan.hayward@arm.com>
6135
6136 * sh-tdep.c (sh_pseudo_register_read): Remove
6137 MAX_REGISTER_SIZE.
6138 (sh_pseudo_register_write): Likewise.
6139 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
6140 (sh64_pseudo_register_write): Likewise
6141
d1be909e
AH
61422017-06-07 Alan Hayward <alan.hayward@arm.com>
6143
6144 * aarch64-tdep.c (aarch64_store_return_value): Use
6145 V_REGISTER_SIZE.
6146 (aarch64_pseudo_read_value): Likewise.
6147 (aarch64_pseudo_write): Likewise.
6148
f4a65042
YQ
61492017-06-06 Yao Qi <yao.qi@linaro.org>
6150
6151 * regformats/regdef.h (set_register_cache): Remove the
6152 declaration.
6153
9f7fb0aa
AH
61542017-06-06 Alan Hayward <alan.hayward@arm.com>
6155
6156 * frame.c (frame_unwind_register_signed): Use
6157 frame_unwind_register_value.
6158
e1e01040
PA
61592017-06-06 Pedro Alves <palves@redhat.com>
6160
6161 PR breakpoints/21553
6162 * breakpoint.c (create_breakpoints_sal_default)
6163 (init_breakpoint_sal, create_breakpoint_sal): Use
6164 gdb::unique_xmalloc_ptr for string parameters.
6165 (create_breakpoint): Constify 'extra_string' and 'cond_string'
6166 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
6167 (base_breakpoint_create_breakpoints_sal)
6168 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
6169 (strace_marker_create_breakpoints_sal)
6170 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
6171 string parameters.
6172 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
6173 gdb::unique_xmalloc_ptr for string parameters.
6174 (create_breakpoint): Constify 'extra_string' and 'cond_string'
6175 parameters.
6176
fbe654c8
AH
61772017-06-06 Alan Hayward <alan.hayward@arm.com>
6178
6179 * alpha-tdep.c (alpha_register_to_value): Use
6180 get_frame_register_value.
6181 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
6182
ae0d01d6
AH
61832017-06-06 Alan Hayward <alan.hayward@arm.com>
6184
6185 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
6186 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
6187 (ia64_value_to_register): Likewise.
6188 (ia64_extract_return_value): Likewise.
6189 (ia64_store_return_value): Likewise.
6190 (ia64_push_dummy_call): Likewise.
6191
49cf576c
JB
61922017-06-04 Joel Brobecker <brobecker@adacore.com>
6193
6194 GDB 8.0 released.
6195
26b6a6ab
SM
61962017-06-03 Simon Marchi <simon.marchi@ericsson.com>
6197
6198 * x86-linux-nat.c (struct arch_lwp_info): Remove.
6199
22827c51
SM
62002017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
6201
6202 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
6203 parameter.
6204 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
6205
0e05cf3a
SM
62062017-06-02 Simon Marchi <simon.marchi@ericsson.com>
6207
6208 * event-loop.c (poll_timers): Unallocate timer using delete
6209 instead of xfree.
6210
c1fc2657
SM
62112017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6212
6213 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
6214 (struct breakpoint) <~breakpoint>: New.
6215 (struct watchpoint): Inherit from breakpoint.
6216 <~watchpoint>: New.
6217 <base>: Remove.
6218 (struct tracepoint): Inherit from breakpoint.
6219 <base>: Remove.
6220 * breakpoint.c (longjmp_breakpoint_ops): Remove.
6221 (struct longjmp_breakpoint): Inherit from breakpoint.
6222 <~longjmp_breakpoint>: New.
6223 <base>: Remove.
6224 (new_breakpoint_from_type): Remove casts.
6225 (watchpoint_in_thread_scope): Remove reference to base field.
6226 (watchpoint_del_at_next_stop): Likewise.
6227 (update_watchpoint): Likewise.
6228 (watchpoint_check): Likewise.
6229 (bpstat_check_watchpoint): Likewise.
6230 (set_longjmp_breakpoint): Likewise.
6231 (struct fork_catchpoint): Inherit from breakpoint.
6232 <base>: Remove.
6233 (struct solib_catchpoint): Inherit from breakpoint.
6234 <~solib_catchpoint>: New.
6235 <base>: Remove.
6236 (dtor_catch_solib): Change to ...
6237 (solib_catchpoint::~solib_catchpoint): ... this.
6238 (breakpoint_hit_catch_solib): Remove reference to base field.
6239 (add_solib_catchpoint): Likewise.
6240 (create_fork_vfork_event_catchpoint): Likewise.
6241 (struct exec_catchpoint): Inherit from breakpoint.
6242 <~exec_catchpoint>: New.
6243 <base>: Remove.
6244 (dtor_catch_exec): Change to ...
6245 (exec_catchpoint::~exec_catchpoint): ... this.
6246 (dtor_watchpoint): Change to ...
6247 (watchpoint::~watchpoint): ... this.
6248 (watch_command_1): Remove reference to base field.
6249 (catch_exec_command_1): Likewise.
6250 (base_breakpoint_dtor): Change to ...
6251 (breakpoint::~breakpoint): ... this.
6252 (base_breakpoint_ops): Remove dtor field value.
6253 (longjmp_bkpt_dtor): Change to ...
6254 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
6255 (strace_marker_create_breakpoints_sal): Remove reference to base
6256 field.
6257 (delete_breakpoint): Don't manually call breakpoint destructor.
6258 (create_tracepoint_from_upload): Remove reference to base field.
6259 (trace_pass_set_count): Likewise.
6260 (initialize_breakpoint_ops): Don't initialize
6261 momentary_breakpoint_ops, don't set dtors.
6262 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
6263 <~ada_catchpoint>: New.
6264 <base>: Remove.
6265 (create_excep_cond_exprs): Remove reference to base field.
6266 (dtor_exception): Change to ...
6267 (ada_catchpoint::~ada_catchpoint): ... this.
6268 (dtor_catch_exception): Remove.
6269 (dtor_catch_exception_unhandled): Remove.
6270 (dtor_catch_assert): Remove.
6271 (create_ada_exception_catchpoint): Remove reference to base
6272 field.
6273 (initialize_ada_catchpoint_ops): Don't set dtors.
6274 * break-catch-sig.c (struct signal_catchpoint): Inherit from
6275 breakpoint.
6276 <~signal_catchpoint>: New.
6277 <base>: Remove.
6278 (signal_catchpoint_dtor): Change to ...
6279 (signal_catchpoint::~signal_catchpoint): ... this.
6280 (create_signal_catchpoint): Remove reference to base field.
6281 (initialize_signal_catchpoint_ops): Don't set dtor.
6282 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
6283 from breakpoint.
6284 <~syscall_catchpoint>: New.
6285 <base>: Remove.
6286 (dtor_catch_syscall): Change to ...
6287 (syscall_catchpoint::~syscall_catchpoint): ... this.
6288 (create_syscall_event_catchpoint): Remove reference to base
6289 field.
6290 (initialize_syscall_catchpoint_ops): Don't set dtor.
6291 * break-catch-throw.c (struct exception_catchpoint): Inherit
6292 from breakpoint.
6293 <~exception_catchpoint>: New.
6294 <base>: Remove.
6295 (dtor_exception_catchpoint): Change to ...
6296 (exception_catchpoint::~exception_catchpoint): ... this.
6297 (handle_gnu_v3_exceptions): Remove reference to base field.
6298 (initialize_throw_catchpoint_ops): Don't set dtor.
6299 * ctf.c (ctf_get_traceframe_address): Remove reference to base
6300 field.
6301 * remote.c (remote_get_tracepoint_status): Likewise.
6302 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
6303 * tracefile.c (tracefile_fetch_registers): Likewise.
6304 * tracepoint.c (actions_command): Likewise.
6305 (validate_actionline): Likewise.
6306 (tfind_1): Likewise.
6307 (get_traceframe_location): Likewise.
6308 (find_matching_tracepoint_location): Likewise.
6309 (parse_tracepoint_status): Likewise.
6310 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
6311
3b0871f4
SM
63122017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6313
6314 * breakpoint.c (struct longjmp_breakpoint): New struct.
6315 (is_tracepoint_type): Change return type to bool.
6316 (is_longjmp_type): New function.
6317 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
6318 (set_raw_breakpoint_without_location): Use
6319 new_breakpoint_from_type.
6320 (set_raw_breakpoint): Likewise.
6321
a5e364af
SM
63222017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
6323
6324 * breakpoint.c (new_breakpoint_from_type): New function.
6325 (create_breakpoint_sal): Use new_breakpoint_from_type and
6326 unique_ptr.
6327 (create_breakpoint): Likewise.
6328
ae3b3f34
SM
63292017-05-31 Simon Marchi <simon.marchi@ericsson.com>
6330
6331 * memattr.c (mem_info_command): Rename to ...
6332 (info_mem_command): ... this.
6333 (mem_enable_command): Rename to ...
6334 (enable_mem_command): ... this.
6335 (mem_disable_command): Rename to ...
6336 (disable_mem_command): ... this.
6337 (mem_delete_command): Rename to ...
6338 (delete_mem_command): ... this.
6339 (_initialize_mem): Adjust function names.
6340
13ace077
MM
63412017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6342
6343 * btrace.c (handle_pt_insn_events): New.
6344 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
6345 STATUS. Split into this and ...
6346 (handle_pt_insn_event_flags): ... this.
6347
c56ccc05
MM
63482017-05-31 Markus Metzger <markus.t.metzger@intel.com>
6349
6350 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
6351 and struct pt_insn.resynced.
6352 * configure: Regenerated.
6353 * config.in: Regenerated.
6354
08c3f6d2
TW
63552017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6356
6357 * btrace.c (ftrace_find_call_by_number): New function.
6358 (ftrace_new_function): Store objects, not pointers.
6359 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
6360 ftrace_new_gap, ftrace_update_function,
6361 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
6362 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
6363 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
6364 btrace_ends_with_single_insn, btrace_call_get): Account for
6365 btrace_thread_info::functions now storing objects.
6366 * btrace.h (struct btrace_thread_info): Add constructor.
6367 (struct btrace_thread_info) <functions>: Make std::vector.
6368 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
6369 Initialize with default values.
6370 * record-btrace.c (record_btrace_frame_sniffer): Account for
6371 btrace_thread_info::functions now storing objects.
6372
8ffd39f2
TW
63732017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6374
6375 * btrace.c: Remove typedef bfun_s.
6376 (ftrace_new_gap): Directly add gaps to the list of gaps.
6377 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
6378 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
6379 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
6380 instead of gdb VEC.
6381
4aeb0dfc
TW
63822017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6383
6384 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
6385 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
6386 with btrace_thread_info::next_segment and
6387 btrace_thread_info::prev_segment.
6388 * btrace.h: Remove struct btrace_func_link.
6389 (struct btrace_function): Replace pair of function segment pointers
6390 with pair of indices.
6391 * python/py-record-btrace.c (btpy_call_prev_sibling,
6392 btpy_call_next_sibling): Replace references to
6393 btrace_thread_info::segment with btrace_thread_info::next_segment and
6394 btrace_thread_info::prev_segment.
6395 * record-btrace.c (record_btrace_frame_this_id): Use
6396 btrace_find_call_by_number.
6397
eb8f2b9c
TW
63982017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6399
6400 * btrace.c (ftrace_new_function, ftrace_fixup_level,
6401 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
6402 btrace_insn_next, btrace_insn_prev): Remove references to
6403 btrace_thread_info::flow.
6404 * btrace.h (struct btrace_function): Remove FLOW.
6405
42bfe59e
TW
64062017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6407
6408 * btrace.c (ftrace_find_call_by_number): New function.
6409 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
6410 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
6411 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
6412 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
6413 index.
6414 * btrace.h (struct btrace_function): Turn UP into an index.
6415 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
6416 as an index.
6417 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
6418 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
6419 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
6420
b54b03bd
TW
64212017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6422
6423 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6424 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6425 ftrace_update_function, ftrace_compute_global_level_offset,
6426 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
6427 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
6428 btrace_insn_end, btrace_is_empty): Remove references to
6429 btrace_thread_info::begin and btrace_thread_info::end.
6430 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
6431 (struct btrace_thread_info) <functions>: Adjust comment.
6432 * record-btrace.c (record_btrace_start_replaying): Remove reference to
6433 btrace_thread_info::begin.
6434
8286623c
TW
64352017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6436
6437 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
6438 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
6439 ftrace_update_function): Remove arguments that implicitly were always
6440 BTINFO->END.
6441 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
6442 Don't pass BTINFO->END.
6443
a0f1b963
TW
64442017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6445
6446 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
6447 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
6448 btrace_find_insn_by_number): Replace function segment pointer with
6449 index.
6450 (btrace_insn_cmp): Simplify.
6451 * btrace.h: (struct btrace_insn_iterator) Rename index to
6452 insn_index. Replace function segment pointer with index into function
6453 segment vector.
6454 * record-btrace.c (record_btrace_call_history): Replace function
6455 segment pointer use with index.
6456 (record_btrace_frame_sniffer): Retrieve function call segment through
6457 vector.
6458 (record_btrace_set_replay): Remove defunc't safety check.
6459
f158f208
TW
64602017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6461
6462 * btrace.c (btrace_ends_with_single_insn): New function.
6463 (btrace_call_get, btrace_call_number, btrace_call_begin,
6464 btrace_call_end, btrace_call_next, btrace_call_prev,
6465 btrace_find_call_by_number): Use index into call segment vector
6466 instead of pointer.
6467 (btrace_call_cmp): Simplify.
6468 * btrace.h (struct btrace_call_iterator): Replace function call segment
6469 pointer with index into vector.
6470 * record-btrace.c (record_btrace_call_history): Use index instead of
6471 pointer.
6472
521103fd
TW
64732017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6474
6475 * btrace.c (btrace_insn_begin, btrace_insn_end,
6476 btrace_find_insn_by_number): Add btinfo to iterator.
6477 * btrace.h (struct btrace_insn_iterator): Add btinfo.
6478
17b89b34
TW
64792017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6480
6481 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
6482 and save pointers directly.
6483 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
6484 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
6485 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
6486 changed signature of functions.
6487 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
6488 (btrace_fetch): Remove code that adds btrace_function pointers to
6489 vector of btrace_functions.
6490 (btrace_clear): Simplify freeing vector of btrace_functions.
6491
2b51eddc
TW
64922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
6493
6494 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
6495 Replace VEC_* with std::vector functions.
6496 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
6497 (struct btrace_thread_info)<functions>: Change type to std::vector.
6498
db6be0d5
SM
64992017-05-30 Simon Marchi <simon.marchi@ericsson.com>
6500
6501 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
6502 "Removed targets and native configurations" up. Merge duplicate
6503 "New commands" sub-sections. Add "New options" sub-sections.
6504
b057297a
AH
65052017-05-26 Alan Hayward <alan.hayward@arm.com>
6506
6507 * defs.h (copy_integer_to_size): New declaration.
6508 * findvar.c (copy_integer_to_size): New function.
6509 (do_cint_test): New selftest function.
6510 (copy_integer_to_size_test): Likewise.
6511 (_initialize_findvar): Likewise.
6512 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
6513 (mips_fbsd_collect_reg): Use raw_collect_integer.
6514 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
6515 (mips64_fill_gregset): Use raw_collect_integer
6516 (mips64_fill_fpregset): Use raw_supply_integer.
6517 * regcache.c (regcache::raw_supply_integer): New function.
6518 (regcache::raw_collect_integer): Likewise.
6519 * regcache.h: (regcache::raw_supply_integer): New declaration.
6520 (regcache::raw_collect_integer): Likewise.
6521
b77b02a5
YQ
65222017-05-24 Yao Qi <yao.qi@linaro.org>
6523
6524 * Makefile.in (SFILES): Add gdbarch-selftests.c.
6525 (COMMON_OBS): Add gdbarch-selftests.o.
6526 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
6527 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
6528 * gdbarch-selftests.c: New file.
6529 * regcache.h (regcache) <~regcache>: Mark it virtual if
6530 GDB_SELF_TEST.
6531 <raw_write>: Likewise.
6532
e521e87e
YQ
65332017-05-24 Yao Qi <yao.qi@linaro.org>
6534
6535 * regcache.c (current_regcache): Change it to
6536 regcache::current_regcache.
6537 (regcache_observer_target_changed): Update.
6538 (regcache_thread_ptid_changed): Make it a regcache static
6539 method.
6540 (regcache_thread_ptid_changed): Update.
6541 (class regcache_access): New.
6542 (current_regcache_test): Update.
6543 (_initialize_regcache): Update.
6544 * regcache.h: Include forward_list.
6545 (regcache): Declare regcache_thread_ptid_changed and declare
6546 registers_changed_ptid as friend.
6547
d8e07dda
YQ
65482017-05-24 Yao Qi <yao.qi@linaro.org>
6549
6550 * i387-tdep.c (i387_register_to_value): Use register_size
6551 instead of TYPE_LENGTH.
6552 * m68k-tdep.c (m68k_register_to_value): Likewise.
6553
8c8f9122
YQ
65542017-05-24 Yao Qi <yao.qi@linaro.org>
6555
6556 * i387-tdep.c (i387_convert_register_p): Return false if type
6557 code isn't TYPE_CODE_FLT.
6558
68fce50f
YQ
65592017-05-24 Yao Qi <yao.qi@linaro.org>
6560
6561 * alpha-tdep.c (alpha_convert_register_p): Return true if type
6562 length is 4.
6563 (alpha_register_to_value): Remove type length check.
6564 (alpha_value_to_register): Likewise.
6565
88954b49
YQ
65662017-05-24 Yao Qi <yao.qi@linaro.org>
6567
6568 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
6569 TYPE_CODE_FLT.
6570
e3ec9b69
YQ
65712017-05-24 Yao Qi <yao.qi@linaro.org>
6572
6573 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
6574 TYPE_CODE_FLT or not.
6575
cdd238da
YQ
65762017-05-24 Yao Qi <yao.qi@linaro.org>
6577
6578 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
6579 * avr-tdep.c (avr_gdbarch_init): Likewise.
6580 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6581 * cris-tdep.c (cris_gdbarch_init): Likewise.
6582 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6583 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6584 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6585 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
6586 * mep-tdep.c (mep_gdbarch_init): Likewise.
6587 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6588 * mips-tdep.c (mips_gdbarch_init): Likewise.
6589 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6590 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6591 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6592 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6593 * v850-tdep.c (v850_gdbarch_init): Likewise.
6594
7a3929c4
YQ
65952017-05-24 Yao Qi <yao.qi@linaro.org>
6596
6597 * selftest-arch.c (tests_with_arch): Call registers_changed
6598 and reinit_frame_cache.
6599 * selftest.c (run_self_tests): Likewise.
6600
f4985dba
YQ
66012017-05-24 Yao Qi <yao.qi@linaro.org>
6602
6603 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
6604 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
6605
ab20fa4a
YQ
66062017-05-24 Yao Qi <yao.qi@linaro.org>
6607
6608 * rl78-tdep.c (rl78_gdbarch_init): Don't call
6609 set_gdbarch_print_insn.
6610
f532ab94
YQ
66112017-05-24 Yao Qi <yao.qi@linaro.org>
6612
6613 * h8300-tdep.c (h8300_gdbarch_init): Don't call
6614 set_gdbarch_print_insn.
6615
39503f82
YQ
66162017-05-24 Yao Qi <yao.qi@linaro.org>
6617
6618 * alpha-tdep.c (alpha_gdbarch_init): Don't call
6619 set_gdbarch_print_insn.
6620 * arc-tdep.c (arc_gdbarch_init): Likewise.
6621 * arch-utils.c: include dis-asm.h.
6622 (default_print_insn): New function.
6623 * arch-utils.h (default_print_insn): Declare.
6624 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
6625 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
6626 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
6627 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
6628 * frv-tdep.c (frv_gdbarch_init): Likewise.
6629 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
6630 * gdbarch.sh (print_insn): Use default_print_insn.
6631 * gdbarch.c: Regenerated.
6632 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
6633 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
6634 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
6635 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
6636 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
6637 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
6638 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
6639 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
6640 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
6641 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
6642 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
6643 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
6644 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
6645 * mt-tdep.c (mt_gdbarch_init): Likewise.
6646 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
6647 * nios2-tdep.c (nios2_print_insn): Remove.
6648 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
6649 * rx-tdep.c (rx_gdbarch_init): Likewise.
6650 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
6651 * score-tdep.c (score_print_insn): Remove.
6652 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
6653 * sh-tdep.c (sh_gdbarch_init): Likewise.
6654 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
6655 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
6656 * tic6x-tdep.c (tic6x_print_insn): Remove.
6657 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
6658 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
6659 * v850-tdep.c (v850_gdbarch_init): Likewise.
6660 * vax-tdep.c (vax_gdbarch_init): Likewise.
6661 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
6662 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
6663
f7241d4f
JB
66642017-05-23 John Baldwin <jhb@FreeBSD.org>
6665
6666 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
6667 (MIPS_FP0_REGNUM): Remove.
6668 (MIPS_FSR_REGNUM): Remove.
6669 (mips_fbsd_supply_fpregs): Use mips_regnum.
6670 (mips_fbsd_supply_gregs): Likewise.
6671 (mips_fbsd_collect_fpregs): Likewise.
6672 (mips_fbsd_collect_gregs): Likewise.
6673
d489d81d
JB
66742017-05-23 John Baldwin <jhb@FreeBSD.org>
6675
6676 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
6677 (getpfpregs_supplies): New function.
6678 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
6679 getfpregs_supplies.
6680 (mips_fbsd_store_inferior_registers): Likewise.
6681
e11b3cdc
PA
66822017-05-22 Pedro Alves <palves@redhat.com>
6683
6684 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
6685 maintainer.
6686
0f068fb5
AH
66872017-05-22 Alan Hayward <alan.hayward@arm.com>
6688
6689 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
6690 (store_register): Likewise.
6691 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
6692 (get_decimal_float_return_value): Likewise.
6693 (do_ppc_sysv_return_value): Likewise.
6694 (ppc64_sysv_abi_push_integer): Likewise.
6695 (ppc64_sysv_abi_push_freg): Likewise.
6696 (ppc64_sysv_abi_return_value_base): Likewise.
6697 (ppc64_sysv_abi_return_value): Likewise.
6698 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
6699 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
6700 * rs6000-nat.c: Likewise.
6701 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
6702 (rs6000_value_to_register): Likewise.
6703 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
6704
e6cf65f2
TT
67052017-05-21 Tom Tromey <tom@tromey.com>
6706
6707 PR rust/21466:
6708 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
6709 arrays as "[T]", not "[T; ]".
6710
43cc5389
TT
67112017-05-19 Tom Tromey <tom@tromey.com>
6712
6713 PR rust/21484:
6714 * rust-lang.c (exp_descriptor_rust): New function.
6715 (rust_language_defn): Use it.
6716 * p-lang.c (pascal_language_defn): Update.
6717 * opencl-lang.c (opencl_language_defn): Update.
6718 * objc-lang.c (objc_language_defn): Update.
6719 * m2-lang.c (m2_language_defn): Update.
6720 * language.h (struct language_defn)
6721 <la_watch_location_expression>: New member.
6722 * language.c (unknown_language_defn, auto_language_defn)
6723 (local_language_defn): Update.
6724 * go-lang.c (go_language_defn): Update.
6725 * f-lang.c (f_language_defn): Update.
6726 * d-lang.c (d_language_defn): Update.
6727 * c-lang.h (c_watch_location_expression): Declare.
6728 * c-lang.c (c_watch_location_expression): New function.
6729 (c_language_defn, cplus_language_defn, asm_language_defn)
6730 (minimal_language_defn): Use it.
6731 * breakpoint.c (watch_command_1): Call
6732 la_watch_location_expression.
6733 * ada-lang.c (ada_language_defn): Update.
6734
7a6e7fcc
RO
67352017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6736
6e7e1744
RO
6737 PR tui/21482
6738 * gdb_curses.h (NOMACROS): Define.
6739 (NCURSES_NOMACROS): Define.
6740
67412017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6742
6743 PR tui/21482
7a6e7fcc
RO
6744 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
6745 arg to char *.
6746 * tui/tui-wingeneral.c (box_win): Likewise.
6747 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
6748 (tui_show_source_line): Likewise.
6749 (tui_show_exec_info_content): Likewise.
6750
1933fd8e
VM
67512017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
6752
6753 * sparc-tdep.c (sparc_structure_return_p)
6754 (sparc_arg_on_registers_p): New functions.
6755 (sparc32_store_arguments): Use them.
6756 * sparc64-tdep.c (sparc64_16_byte_align_p)
6757 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
6758 Handle TYPE_CODE_ARRAY.
6759
21873064
YQ
67602017-05-17 Yao Qi <yao.qi@linaro.org>
6761
6762 * cli/cli-decode.c (add_alias_cmd): New function.
6763 * command.h (add_alias_cmd): Declare.
6764 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
6765 instead call add_alias_cmd.
6766
2b351b19
PA
67672017-05-17 Pedro Alves <palves@redhat.com>
6768
6769 * Makefile.in (nat_extra_makefile_frag): Rename to ...
6770 (nat_makefile_frag): ... this. All references updated.
6771 * configure.ac: Likewise.
6772 * configure.nat: Likewise. Enhance comments.
6773 * configure: Regenerate.
6774
5f2ad7a3
RO
67752017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6776
6777 * procfs.c (procfs_create_inferior): Change prototype to match
6778 definition.
6779
adf3dde5
EZ
67802017-05-13 Eli Zaretskii <eliz@gnu.org>
6781
6782 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
6783 C++ compiler warning.
6784
6830f270
TT
67852017-05-12 Tom Tromey <tom@tromey.com>
6786
6787 PR rust/21483:
6788 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
6789 recurse, just call value_struct_elt directly.
6790
68f2f2e3
TT
67912017-05-12 Tom Tromey <tom@tromey.com>
6792
6793 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
6794 OP_RUST_ARRAY>: Fix.
6795
256afbc2
TT
67962017-05-12 Tom Tromey <tom@tromey.com>
6797
6798 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
6799
94bb8dfe
YQ
68002017-05-09 Yao Qi <yao.qi@linaro.org>
6801
6802 * regcache.c: Include <forward_list>.
6803 (struct regcache_list): Remove.
6804 (current_regcache): Update.
6805 (get_thread_arch_aspace_regcache): Update for std::forward_list.
6806 (regcache_thread_ptid_changed): Likewise.
6807 (registers_changed_ptid): Likewise.
6808 (current_regcache_size): Likewise.
6809
8248946c
YQ
68102017-05-09 Yao Qi <yao.qi@linaro.org>
6811
6812 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
6813 (current_regcache_size): New function.
6814 (current_regcache_test): New function.
6815 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
6816
313c5961
AH
68172017-05-08 Alan Hayward <alan.hayward@arm.com>
6818
6819 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
6820 (print_gp_register_row): Use get_frame_register_value.
6821
27bfc1d1
AH
68222017-05-08 Alan Hayward <alan.hayward@arm.com>
6823
6824 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
6825 (mips_supply_fpregset): Likewise.
6826 (mips64_supply_gregset): Likewise.
6827
146e6c5c
AH
68282017-05-08 Alan Hayward <alan.hayward@arm.com>
6829
6830 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
6831 regcache->raw_supply_zeroed.
6832
e50f25ec
SDJ
68332017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6834
6835 * configure.nat: Rearrange 'case' statements to match
6836 host before cpu.
6837
21ea5acd
SDJ
68382017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
6839
6840 * Makefile.in: Remove "@host_makefile_frag@". Add variables
6841 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
6842 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
6843 "@nat_extra_makefile_frag@".
6844 (Makefile): Remove dependency on "@frags@".
6845 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
6846 (data-directory/Makefile): Likewise.
6847 * config/aarch64/linux.mh: Deleted; moved contents to
6848 "gdb/configure.nat".
6849 * config/alpha/alpha-linux.mh: Likewise.
6850 * config/alpha/nbsd.mh: Likewise.
6851 * config/arm/linux.mh: Likewise.
6852 * config/arm/nbsdelf.mh: Likewise.
6853 * config/i386/cygwin.mh: Likewise.
6854 * config/i386/cygwin64.mh: Likewise.
6855 * config/i386/darwin.mh: Likewise.
6856 * config/i386/fbsd.mh: Likewise.
6857 * config/i386/fbsd64.mh: Likewise.
6858 * config/i386/go32.mh: Likewise.
6859 * config/i386/i386gnu.mh: Likewise.
6860 * config/i386/i386sol2.mh: Likewise.
6861 * config/i386/linux.mh: Likewise.
6862 * config/i386/linux64.mh: Likewise.
6863 * config/i386/mingw.mh: Likewise.
6864 * config/i386/mingw64.mh: Likewise.
6865 * config/i386/nbsd64.mh: Likewise.
6866 * config/i386/nbsdelf.mh: Likewise.
6867 * config/i386/nto.mh: Likewise.
6868 * config/i386/obsd.mh: Likewise.
6869 * config/i386/obsd64.mh: Likewise.
6870 * config/i386/sol2-64.mh: Likewise.
6871 * config/ia64/linux.mh: Likewise.
6872 * config/m32r/linux.mh: Likewise.
6873 * config/m68k/linux.mh: Likewise.
6874 * config/m68k/nbsdelf.mh: Likewise.
6875 * config/m68k/obsd.mh: Likewise.
6876 * config/m88k/obsd.mh: Likewise.
6877 * config/mips/fbsd.mh: Likewise.
6878 * config/mips/linux.mh: Likewise.
6879 * config/mips/nbsd.mh: Likewise.
6880 * config/mips/obsd64.mh: Likewise.
6881 * config/pa/linux.mh: Likewise.
6882 * config/pa/nbsd.mh: Likewise.
6883 * config/pa/obsd.mh: Likewise.
6884 * config/powerpc/aix.mh: Likewise.
6885 * config/powerpc/fbsd.mh: Likewise.
6886 * config/powerpc/linux.mh: Likewise.
6887 * config/powerpc/nbsd.mh: Likewise.
6888 * config/powerpc/obsd.mh: Likewise.
6889 * config/powerpc/ppc64-linux.mh: Likewise.
6890 * config/powerpc/spu-linux.mh: Likewise.
6891 * config/s390/linux.mh: Likewise.
6892 * config/sh/nbsd.mh: Likewise.
6893 * config/sparc/fbsd.mh: Likewise.
6894 * config/sparc/linux.mh: Likewise.
6895 * config/sparc/linux64.mh: Likewise.
6896 * config/sparc/nbsd64.mh: Likewise.
6897 * config/sparc/nbsdelf.mh: Likewise.
6898 * config/sparc/obsd64.mh: Likewise.
6899 * config/sparc/sol2.mh: Likewise.
6900 * config/tilegx/linux.mh: Likewise.
6901 * config/vax/nbsdelf.mh: Likewise.
6902 * config/vax/obsd.mh: Likewise.
6903 * config/xtensa/linux.mh: Likewise.
6904 * config/i386/i386gnu.mn: New file, with excerpts from
6905 "config/i386/i386gnu.mh".
6906 * configure: Regenerate.
6907 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
6908 *.mh files under "gdb/config".
6909 * configure.nat: New file, with contents from the
6910 "gdb/config/*/*.mh" files.
6911
7ed1acaf
TW
69122017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
6913
6914 * btrace.c (btrace_clear): Free insn vector.
6915
e13cb306
PA
69162017-05-05 Pedro Alves <palves@redhat.com>
6917
6918 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
6919 * configure: Regenerate.
6920
5ed8105e
PA
69212017-05-04 Pedro Alves <palves@redhat.com>
6922
6923 * Makefile.in (SFILES): Add progspace-and-thread.c.
6924 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
6925 (COMMON_OBS): Add progspace-and-thread.o.
6926 * breakpoint.c: Include "progspace-and-thread.h".
6927 (update_inserted_breakpoint_locations)
6928 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
6929 Use scoped_restore_current_pspace_and_thread.
6930 (create_std_terminate_master_breakpoint): Use
6931 scoped_restore_current_program_space.
6932 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
6933 (print_breakpoint_location): Use
6934 scoped_restore_current_program_space.
6935 (bp_loc_is_permanent): Use
6936 scoped_restore_current_pspace_and_thread.
6937 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
6938 (download_tracepoint_locations): Use
6939 scoped_restore_current_pspace_and_thread.
6940 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
6941 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
6942 (enum step_over_calls_kind): Moved from inferior.h.
6943 (class scoped_restore_current_thread): New class.
6944 * gdbthread.h (make_cleanup_restore_current_thread): Delete
6945 declaration.
6946 (scoped_restore_current_thread): New class.
6947 * infcmd.c: Include "common/gdb_optional.h".
6948 (continue_1, proceed_after_attach): Use
6949 scoped_restore_current_thread.
6950 (notice_new_inferior): Use scoped_restore_current_thread.
6951 * inferior.c: Include "progspace-and-thread.h".
6952 (restore_inferior, save_current_inferior): Delete.
6953 (add_inferior_command, clone_inferior_command): Use
6954 scoped_restore_current_pspace_and_thread.
6955 * inferior.h (scoped_restore_current_inferior): New class.
6956 * infrun.c: Include "progspace-and-thread.h" and
6957 "common/gdb_optional.h".
6958 (follow_fork_inferior): Use
6959 scoped_restore_current_pspace_and_thread.
6960 (scoped_restore_exited_inferior): New class.
6961 (handle_vfork_child_exec_or_exit): Use
6962 scoped_restore_exited_inferior,
6963 scoped_restore_current_pspace_and_thread,
6964 scoped_restore_current_thread and scoped_restore.
6965 (fetch_inferior_event): Use scoped_restore_current_thread.
6966 * linespec.c (decode_line_full, decode_line_1): Use
6967 scoped_restore_current_program_space.
6968 * mi/mi-main.c: Include "progspace-and-thread.h".
6969 (exec_continue): Use scoped_restore_current_thread.
6970 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
6971 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
6972 * proc-service.c (ps_pglobal_lookup): Use
6973 scoped_restore_current_program_space.
6974 * progspace-and-thread.c: New file.
6975 * progspace-and-thread.h: New file.
6976 * progspace.c (release_program_space, clone_program_space): Use
6977 scoped_restore_current_program_space.
6978 (restore_program_space, save_current_program_space)
6979 (save_current_space_and_thread): Delete.
6980 (switch_to_program_space_and_thread): Moved to
6981 progspace-and-thread.c.
6982 * progspace.h (save_current_program_space)
6983 (save_current_space_and_thread): Delete declarations.
6984 (scoped_restore_current_program_space): New class.
6985 * remote.c (remote_btrace_maybe_reopen): Use
6986 scoped_restore_current_thread.
6987 * symtab.c: Include "progspace-and-thread.h".
6988 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
6989 * thread.c (print_thread_info_1): Use
6990 scoped_restore_current_thread.
6991 (struct current_thread_cleanup): Delete.
6992 (do_restore_current_thread_cleanup)
6993 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
6994 (scoped_restore_current_thread::~scoped_restore_current_thread):
6995 ... this new dtor.
6996 (make_cleanup_restore_current_thread): Rename/convert to ...
6997 (scoped_restore_current_thread::scoped_restore_current_thread):
6998 ... this new ctor.
6999 (thread_apply_all_command): Use scoped_restore_current_thread.
7000 (thread_apply_command): Use scoped_restore_current_thread.
7001 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
7002 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
7003
f6223dbb
PA
70042017-05-04 Pedro Alves <palves@redhat.com>
7005
7006 * thread.c (make_cleanup_restore_current_thread): Move
7007 find_thread_ptid call before the is_stopped call. Assert that the
7008 thread is found. Replace is_stopped call by checking the thread's
7009 state directly. Remove unnecessary NULL-thread check.
7010
3c3ae77e
PA
70112017-05-04 Pedro Alves <palves@redhat.com>
7012
7013 * corelow.c (thread_section_name): New class.
7014 (get_core_register_section, get_core_siginfo): Use it.
7015
45eba0ab
AA
70162017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
7017
7018 * corelow.c (sniff_core_bfd): Remove extra semicolon.
7019 (get_core_register_section): Remove xfree of NULL pointer.
7020
f81fdd35
AH
70212017-05-03 Alan Hayward <alan.hayward@arm.com>
7022
7023 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
7024 * regcache.c (regcache::raw_supply_zeroed): New function.
7025 * regcache.h (regcache::raw_supply_zeroed): New declaration.
7026
35837774
SM
70272017-05-03 Simon Marchi <simon.marchi@ericsson.com>
7028
7029 * gdbarch.sh: Remove commented out definition of
7030 TARGET_CHAR_BIT.
7031 * gdbarch.h: Re-generate.
7032
c94fee56
SDJ
70332017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
7034
7035 * configure: Regenerate.
7036
d17f7b36
SM
70372017-05-02 Simon Marchi <simon.marchi@ericsson.com>
7038
7039 * solib-target.c (solib_target_relocate_section_addresses):
7040 Remove num_section_bases, num_bases, segment_bases variables.
7041
b560ebd6
SM
70422017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7043
7044 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
7045
f2f46dfc
SM
70462017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7047
7048 * solib-target.c: Include <vector>
7049 (struct lm_info_target) <~lm_info_target>: Remove.
7050 <segment_bases, section_bases>: Change type to
7051 std::vector<CORE_ADDR>.
7052 (library_list_start_segment, library_list_start_section,
7053 library_list_end_library,
7054 solib_target_relocate_section_addresses): Adjust.
7055
a0ff9e1a
SM
70562017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7057
7058 * gdbarch.sh (software_single_step): Change return type to
7059 std::vector<CORE_ADDR>.
7060 * gdbarch.c, gdbarch.h: Re-generate.
7061 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
7062 Adjust.
7063 (arm_deal_with_atomic_sequence_raw): Adjust.
7064 (thumb_get_next_pcs_raw): Adjust.
7065 (arm_get_next_pcs_raw): Adjust.
7066 (arm_get_next_pcs): Adjust.
7067 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
7068 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
7069 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
7070 (alpha_software_single_step): Adjust.
7071 * alpha-tdep.h (alpha_software_single_step): Adjust.
7072 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
7073 * arm-tdep.c (arm_software_single_step): Adjust.
7074 (arm_breakpoint_kind_from_current_state): Adjust.
7075 * arm-tdep.h (arm_software_single_step): Adjust.
7076 * breakpoint.c (insert_single_step_breakpoint): Adjust.
7077 * cris-tdep.c (cris_software_single_step): Adjust.
7078 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
7079 (micromips_deal_with_atomic_sequence): Adjust.
7080 (deal_with_atomic_sequence): Adjust.
7081 (mips_software_single_step): Adjust.
7082 * mips-tdep.h (mips_software_single_step): Adjust.
7083 * moxie-tdep.c (moxie_software_single_step): Adjust.
7084 * nios2-tdep.c (nios2_software_single_step): Adjust.
7085 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
7086 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
7087 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
7088 * s390-linux-tdep.c (s390_software_single_step): Adjust.
7089 * sparc-tdep.c (sparc_software_single_step): Adjust.
7090 * spu-tdep.c (spu_software_single_step): Adjust.
7091 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
7092
ea480a30
SM
70932017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
7094
7095 * gdbarch.sh: Use semi-colon as field separator instead of colon.
7096 * gdbarch.h: Re-generate.
7097
d050f7d7
TW
70982017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7099
7100 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
7101 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
7102 * python/py-instruction.c, python/py-instruction.h: New file.
7103 * python/py-record.c: Add py-instruction.h include.
7104 (gdbpy_initialize_record): Make gdb.Instruction a super class of
7105 gdb.RecordInstruction.
7106 * python/python-internal.h: Add gdbpy_initialize_instruction
7107 declaration.
7108 * python/python.c (do_start_initialization): Add
7109 gdbpy_initialize_instruction.
7110
14f819c8
TW
71112017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7112
7113 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
7114 Remove.
7115 (btrace_func_from_recpy_func): New function.
7116 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
7117 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
7118 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
7119 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
7120 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
7121 Also, use new helper functions.
7122 (btpy_list_item): Use new helper functions.
7123 (recpy_bt_function_call_history): Use new type name.
7124 (btpy_call_getset): Remove.
7125 (gdbpy_initialize_btrace): Remove code to initialize
7126 gdb.BtraceFunctionCall.
7127 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
7128 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
7129 recpy_bt_func_prev, recpy_bt_func_next): New export.
7130 * python/py-record.c (recpy_func_type): New static object.
7131 (recpy_func_new, recpy_func_level, recpy_func_symbol,
7132 recpy_func_instructions, recpy_func_up, recpy_func_prev,
7133 recpy_func_next): New function.
7134 (recpy_element_hash, recpy_element_richcompare): Updated comment.
7135 (recpy_func_getset): New static object.
7136 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
7137 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
7138
0ed5da75
TW
71392017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7140
7141 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
7142 (btpy_object, btpy_insn_type, btpy_new): Remove.
7143 (btpy_list_object): Use gdb.RecordInstruction type instead of
7144 gdb.BtraceInstruction type.
7145 (btrace_insn_from_recpy_insn): New function.
7146 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
7147 btpy_new.
7148 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
7149 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
7150 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
7151 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
7152 instead of btpy_object.
7153 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
7154 btpy_insn_data, btpy_insn_decode): Rename to ...
7155 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
7156 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
7157 recpy_bt_insn_decode): This. Also, use new helper functions.
7158 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
7159 recpy_insn_type.
7160 (btpy_insn_getset): Remove.
7161 (gdbpy_initialize_btrace): Remove code to initialize
7162 gdb.BtraceInstruction. Use recpy_element_object.
7163 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
7164 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
7165 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
7166 * python/py-record.c (recpy_insn_type): New static object.
7167 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
7168 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
7169 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
7170 New function.
7171 (recpy_insn_getset): New static object.
7172 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
7173 * python/py-record.h (recpy_element_object): New typedef.
7174 (recpy_insn_type, recpy_insn_new): New export.
7175
913aeadd
TW
71762017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7177
7178 * py-record-btrace.c (btpy_insn_new): Removed.
7179 (btpy_insn_or_gap_new): New function.
7180 (btpy_insn_error): Removed.
7181 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
7182 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
7183 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
7184 btpy_insn_or_gap_new instead of btpy_insn_new.
7185 (btpy_insn_getset): Remove btpy_insn_error.
7186 * py-record.c (recpy_gap_type): New static object.
7187 (recpy_gap_object): New typedef.
7188 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
7189 recpy_gap_reason_string): New function.
7190 (recpy_gap_getset): New static object.
7191 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
7192 * py-record.h (recpy_gap_new): New export.
7193
a3be24ad
TW
71942017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7195
7196 * python/py-record.c (recpy_ptid): Remove.
7197 (recpy_record_getset): Remove recpy_ptid.
7198
ae20e79a
TW
71992017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7200
7201 * btrace.c (btrace_fetch): Set inferior_ptid.
7202 * python/py-record-btrace.c: Add "py-record.h" include.
7203 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
7204 recpy_bt_end, recpy_bt_instruction_history,
7205 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
7206 in gdb.Record object instead of current ptid.
7207 * python/py-record.c: Include new "py-record.h" file.
7208 (recpy_record_object): Moved to py-record.h.
7209 * python/py-record.h: New file.
7210
8d0050ea
TW
72112017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
7212
7213 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
7214 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
7215 indentation.
7216
3f380b50
JB
72172017-05-01 Joel Brobecker <brobecker@adacore.com>
7218
7219 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
7220 the past maintainers section.
7221
07495424
YQ
72222017-04-28 Yao Qi <yao.qi@linaro.org>
7223
7224 * infcmd.c (get_return_value): Use regcache ctor, and remove
7225 cleanup.
7226
deb1fa3e
YQ
72272017-04-28 Yao Qi <yao.qi@linaro.org>
7228 Pedro Alves <palves@redhat.com>
7229
7230 * regcache.c (regcache::regcache): New tag dispatch ctor.
7231 (do_cooked_read): Moved above.
7232 (regcache_dup): Use the tag dispatch ctor..
7233 * regcache.h (regcache): Declare ctor, delete copy ctor and
7234 assignment operator, remove friend regcache_dup.
7235
b421c83c
YQ
72362017-04-28 Yao Qi <yao.qi@linaro.org>
7237
7238 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
7239 call method save instead of regcache_cpy.
7240 * regcache.h (struct regcache): Make regcache_dup a friend.
7241
ef79d9a3
YQ
72422017-04-28 Yao Qi <yao.qi@linaro.org>
7243
7244 * regcache.c (struct regcache): Move to regcache.h
7245 (regcache::arch): New method.
7246 (regcache_get_ptid): Update.
7247 (get_regcache_arch): Call arch method.
7248 (get_regcache_aspace): Call method aspace.
7249 (register_buffer): Change it to method.
7250 (regcache_save): Change it to regcache::save.
7251 (regcache_restore): Likewise.
7252 (regcache_cpy_no_passthrough): Remove the declaration.
7253 (regcache_cpy): Call methods restore and cpy_no_passthrough.
7254 (regcache_cpy_no_passthrough): Change it to method
7255 cpy_no_passthrough.
7256 (regcache_register_status): Change it to method
7257 get_register_status.
7258 (regcache_invalidate): Change it to method invalidate.
7259 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
7260 (regcache_raw_update): Change it to method raw_update.
7261 (regcache_raw_read): Likewise.
7262 (regcache_raw_read_signed): Likewise.
7263 (regcache_raw_read_unsigned): Likewise.
7264 (regcache_raw_write_signed): Likewise.
7265 (regcache_raw_write_unsigned): Likewise.
7266 (regcache_cooked_read): Likewise.
7267 (regcache_cooked_read_value): Likewise.
7268 (regcache_cooked_read_signed): Likewise.
7269 (regcache_cooked_read_unsigned): Likewise.
7270 (regcache_cooked_write_signed): Likewise.
7271 (regcache_cooked_write_unsigned): Likewise.
7272 (regcache_raw_set_cached_value): Likewise.
7273 (regcache_raw_write): Likewise.
7274 (regcache_cooked_write): Likewise.
7275 (regcache_xfer_part): Likewise.
7276 (regcache_raw_read_part): Likewise.
7277 (regcache_raw_write_part): Likewise.
7278 (regcache_cooked_read_part): Likewise.
7279 (regcache_cooked_write_part): Likewise.
7280 (regcache_raw_supply): Likewise.
7281 (regcache_raw_collect): Likewise.
7282 (regcache_transfer_regset): Likewise.
7283 (regcache_supply_regset): Likewise.
7284 (regcache_collect_regset): Likewise.
7285 (regcache_debug_print_register): Likewise.
7286 (enum regcache_dump_what): Move it to regcache.h.
7287 (regcache_dump): Change it to method dump.
7288 * regcache.h (enum regcache_dump_what): New.
7289 (class regcache): New.
7290 * target.c (target_fetch_registers): Call method
7291 debug_print_register.
7292 (target_store_registers): Likewise.
7293
f8fdb78e
SM
72942017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7295
7296 * windows-nat.c (struct lm_info_windows): Initialize field.
7297 (windows_make_so): Allocate lm_info_windows with new.
7298 (windows_free_so): Free lm_info_windows with delete.
7299
9ccbfd7b
SM
73002017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7301
7302 * solib-darwin.c (struct lm_info_darwin): Initialize field.
7303 (darwin_current_sos): Allocate lm_info_darwin with new, remove
7304 cleanup.
7305 (darwin_free_so): Free lm_info_darwin with delete.
7306
76e75227
SM
73072017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7308
7309 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
7310 <l_addr_p>: Change type to bool.
7311 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
7312 (svr4_free_so): Free lm_info_svr4 with delete.
7313 (svr4_copy_library_list): Replace memcpy with call to copy
7314 constructor.
7315 (library_list_start_library, svr4_default_sos): Allocate
7316 lm_info_svr4 with new.
7317
51046d9e
SM
73182017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7319
7320 * solib-target.c (struct lm_info_target): Add destructor,
7321 initialize fields.
7322 <name>: Change type to std::string.
7323 (library_list_start_library): Allocate lm_info_target with new.
7324 (solib_target_free_library_list): Free lm_info_target with
7325 delete.
7326 (solib_target_current_sos): Adapt to std::string.
7327 (solib_target_free_so): Free lm_info_target with delete.
7328
4023ae76
SM
73292017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7330
7331 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
7332 fields.
7333 (frv_current_sos): Allocate lm_info_frv with new.
7334 (frv_relocate_main_executable): Free lm_info_frv with delete,
7335 allocate with new.
7336 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
7337
af43057b
SM
73382017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7339
7340 * solib-frv.c (struct lm_info_frv): Fix indentation.
7341
b0911207
SM
73422017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7343
7344 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
7345 map field.
7346 (dsbt_current_sos): Allocate lm_info_dsbt with new.
7347 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
7348 and allocate with new.
7349 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
7350
6c401f72
SM
73512017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7352
7353 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
7354 <filename, member_name>: Change type to std::string.
7355 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
7356 (library_list_start_library): Allocate lm_info_aix with new.
7357 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
7358 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
7359 with copy constructor.
7360
d0e449a1
SM
73612017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7362
7363 * solist.h (struct lm_info): Remove.
7364 (struct lm_info_base): New class.
7365 (struct so_list) <lm_info>: Change type to lm_info_base *.
7366 * nto-tdep.c (struct lm_info): Remove.
7367 (lm_addr): Adjust.
7368 * solib-aix.c (struct lm_info): Rename to ...
7369 (struct lm_info_aix): ... this. Extend lm_info_base.
7370 (lm_info_p): Rename to ...
7371 (lm_info_aix_p): ... this, and adjust.
7372 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
7373 solib_aix_parse_libraries, library_list_start_library,
7374 solib_aix_free_library_list, solib_aix_parse_libraries,
7375 solib_aix_get_library_list,
7376 solib_aix_relocate_section_addresses, solib_aix_free_so,
7377 solib_aix_get_section_offsets,
7378 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
7379 Adjust.
7380 (struct solib_aix_inferior_data) <library_list>: Adjust.
7381 * solib-darwin.c (struct lm_info): Rename to ...
7382 (struct lm_info_darwin): ... this. Extend lm_info_base.
7383 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
7384 * solib-dsbt.c (struct lm_info): Rename to ...
7385 (struct lm_info_dsbt): ... this. Extend lm_info_base.
7386 (struct dsbt_info) <main_executable_lm_info): Adjust.
7387 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
7388 dsbt_relocate_section_addresses): Adjust.
7389 * solib-frv.c (struct lm_info): Rename to ...
7390 (struct lm_info_frv): ... this. Extend lm_info_base.
7391 (main_executable_lm_info): Adjust.
7392 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
7393 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
7394 find_canonical_descriptor_in_load_object,
7395 frv_fdpic_find_canonical_descriptor): Adjust.
7396 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
7397 to lm_info_svr4.
7398 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
7399 svr4_clear_so, svr4_copy_library_list,
7400 library_list_start_library, svr4_default_sos, svr4_read_so_list,
7401 svr4_current_sos, svr4_fetch_objfile_link_map,
7402 solist_update_incremental): Adjust.
7403 * solib-svr4.h (struct lm_info_svr4): Move here from
7404 solib-svr4.c.
7405 * solib-target.c (struct lm_info): Rename to ...
7406 (struct lm_info_target): ... this. Extend lm_info_base.
7407 (lm_info_p): Rename to ...
7408 (lm_info_target_p): ... this.
7409 (solib_target_parse_libraries, library_list_start_segment,
7410 library_list_start_section, library_list_start_library,
7411 library_list_end_library, solib_target_free_library_list,
7412 solib_target_current_sos, solib_target_free_so,
7413 solib_target_relocate_section_addresses): Adjust.
7414 * windows-nat.c (struct lm_info): Rename to ...
7415 (struct lm_info_windows): ... this. Extend lm_info_base.
7416 (windows_make_so, handle_load_dll, handle_unload_dll,
7417 windows_xfer_shared_libraries): Adjust.
7418
434a4023
SM
74192017-04-28 Simon Marchi <simon.marchi@ericsson.com>
7420
7421 * solib-darwin.c (struct darwin_so_list): Remove.
7422 (darwin_current_sos): Allocate an so_list object instead of a
7423 darwin_so_list, separately allocate an lm_info object.
7424 (darwin_free_so): Free lm_info.
7425
428544e8
JB
74262017-04-28 John Baldwin <jhb@FreeBSD.org>
7427
7428 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
7429 with fprintf_filtered.
7430
4621115f
YQ
74312017-04-28 Yao Qi <yao.qi@linaro.org>
7432
7433 * regcache.c (regcache::regcache): New function.
7434 (regcache::~regcache): New function.
7435 (regcache_xmalloc_1): Remove.
7436 (regcache_xmalloc): Call new regcache.
7437 (regcache_xfree): Call delete regcache.
7438 (get_thread_arch_aspace_regcache): Call new regcache.
7439
339053c2
YQ
74402017-04-28 Yao Qi <yao.qi@linaro.org>
7441
7442 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
7443 lwp instead of ptid_get_lwp.
7444
7974a605
YQ
74452017-04-28 Yao Qi <yao.qi@linaro.org>
7446
7447 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
7448 lwp_info instead of getting from inferior_ptid.
7449
e15c3eb4
KS
74502017-04-27 Keith Seitz <keiths@redhat.com>
7451
7452 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
7453 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
7454 (CV_CONVERSION_BADNESS): Define.
7455 (rank_one_type): Remove overly restrictive rvalue reference
7456 rank checks.
7457 Add cv-qualifier checks and subranks for type equality.
7458 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
7459 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
7460 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
7461
72bc1d24
SM
74622017-04-27 Simon Marchi <simon.marchi@ericsson.com>
7463
7464 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
7465 count when creating the object.
7466
55bcecda
UW
74672017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
7468 Ulrich Weigand <uweigand@de.ibm.com>
7469
7470 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
7471 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
7472 is used in AIX.
7473 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
7474 (process_xcoff_symbol): Likewise.
7475 (scan_xcoff_symtab): Likewise.
7476
5c99fcf8
AH
74772017-04-26 Alan Hayward <alan.hayward@arm.com>
7478
7479 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
7480 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
7481 (ia64_access_reg): Use get_frame_register_unsigned.
7482 (ia64_access_rse_reg): Likewise.
7483 (ia64_libunwind_frame_prev_register): Likewise.
7484
b41c5a85
JW
74852017-04-26 Jiong Wang <jiong.wang@arm.com>
7486
7487 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
7488 * gdbarch.c: Regenerated.
7489 * gdbarch.h: Regenerated.
7490 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
7491 visibility external.
7492 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
7493 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
7494 (enum cfa_how_kind): Move to ...
7495 (struct dwarf2_frame_state_reg_info): Likewise.
7496 (struct dwarf2_frame_state): Likewise.
7497 * dwarf2-frame.h: ... here.
7498 (dwarf2_frame_state_alloc_regs): New declaration.
7499 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
7500 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
7501
c185f580
AH
75022017-04-26 Alan Hayward <alan.hayward@arm.com>
7503
7504 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
7505 regcache_raw_read_unsigned.
7506 (xtensa_pseudo_register_write): Likewise.
7507
19c45594
AH
75082017-04-26 Alan Hayward <alan.hayward@arm.com>
7509
7510 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
7511 (nds32_pseudo_register_write): Likewise.
7512
4658f12e
YQ
75132017-04-25 Yao Qi <yao.qi@linaro.org>
7514
7515 * regcache.c (struct regcache) <readonly_p>: Change its type
7516 to bool.
7517 (regcache_xmalloc_1): Update parameter type and callers update.
7518
d581dda8
YQ
75192017-04-25 Yao Qi <yao.qi@linaro.org>
7520
7521 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
7522 set_gdbarch_wchar_bit.
7523 * arm-tdep.c (arm_gdbarch_init): Likewise.
7524
debed3db
PA
75252017-04-25 Pedro Alves <palves@redhat.com>
7526
7527 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
7528 (BothAreRelocatable, memcopy, memmove): Don't define.
7529 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
7530 macros.
7531
b0b92aeb
PA
75322017-04-25 Pedro Alves <palves@redhat.com>
7533
7534 * common/common-defs.h: Include "common/poison.h".
7535 * common/function-view.h: (Not, Or, Requires): Move to traits.h
7536 and adjust.
7537 * common/poison.h: New file.
7538 * common/traits.h: Include <type_traits>.
7539 (Not, Or, Requires): New, moved from common/function-view.h.
7540
16c4d54a
PA
75412017-04-25 Pedro Alves <palves@redhat.com>
7542
7543 * breakpoint.h (struct breakpoint): In-class initialize all
7544 fields. Make boolean fields "bool".
7545 * breakpoint.c (init_raw_breakpoint_without_location): Remove
7546 memset call and initializations no longer necessary.
7547
b5c36682
PA
75482017-04-25 Pedro Alves <palves@redhat.com>
7549
7550 * btrace.c (pt_btrace_insn_flags): Change parameter type to
7551 reference.
7552 (pt_btrace_insn): New function.
7553 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
7554
5625a286
PA
75552017-04-25 Pedro Alves <palves@redhat.com>
7556
7557 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
7558 "base" field and inherit from "bp_location" instead. Add
7559 non-default ctor.
7560 (allocate_location_exception): Use new non-default ctor.
7561 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
7562 (init_bp_location): Convert to ...
7563 (bp_location::bp_location): ... this new ctor, and remove memset
7564 call.
7565 (base_breakpoint_allocate_location): Use the new non-default ctor.
7566 * breakpoint.h (bp_location): Now a class. Declare default and
7567 non-default ctors. In-class initialize all members.
7568 (init_bp_location): Remove declaration.
7569
23bcc18f
PA
75702017-04-25 Pedro Alves <palves@redhat.com>
7571
7572 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
7573 assignment operator.
7574
e1ba3053
YQ
75752017-04-24 Yao Qi <yao.qi@linaro.org>
7576
7577 * doublest.c (convert_doublest_to_floatformat): Call
7578 floatformat_totalsize_bytes.
7579
10f489e5
TT
75802017-04-22 Tom Tromey <tom@tromey.com>
7581
7582 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
7583 ui_out_emit_list.
7584 * stack.c (print_frame): Use ui_out_emit_list.
7585 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7586 ui_out_emit_list.
7587 * mi/mi-main.c (print_one_inferior)
7588 (mi_cmd_data_list_register_names)
7589 (mi_cmd_data_list_register_values, mi_cmd_list_features)
7590 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
7591 ui_out_emit_list.
7592 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
7593 (mi_output_solib_attribs): Use ui_out_emit_list,
7594 ui_out_emit_tuple.
7595 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
7596 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
7597 (mi_cmd_stack_list_args, list_args_or_locals): Use
7598 ui_out_emit_list.
7599 * disasm.c (do_assembly_only): Use ui_out_emit_list.
7600 * breakpoint.c (print_solib_event, output_thread_groups): Use
7601 ui_out_emit_list.
7602
0092b74d
TT
76032017-04-22 Tom Tromey <tom@tromey.com>
7604
7605 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
7606 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
7607 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
7608
a14a62dd
TT
76092017-04-22 Tom Tromey <tom@tromey.com>
7610
7611 * tracepoint.c (tvariables_info_1)
7612 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
7613
46b9c129
TT
76142017-04-22 Tom Tromey <tom@tromey.com>
7615
7616 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
7617 annotate_arg_emitter.
7618 * breakpoint.c (print_mention_watchpoint)
7619 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
7620 * annotate.h (struct annotate_arg_emitter): New.
7621
2e783024
TT
76222017-04-22 Tom Tromey <tom@tromey.com>
7623
7624 * record-btrace.c (record_btrace_insn_history)
7625 (record_btrace_insn_history_range, record_btrace_call_history)
7626 (record_btrace_call_history_range): Use ui_out_emit_tuple.
7627 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
7628 ui_out_emit_tuple.
7629 * stack.c (print_frame_info): Use ui_out_emit_tuple.
7630 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
7631 * skip.c (skip_info): Use ui_out_emit_tuple.
7632 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
7633 * progspace.c (print_program_space): Use ui_out_emit_tuple.
7634 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
7635 * osdata.c (info_osdata): Use ui_out_emit_tuple.
7636 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
7637 ui_out_emit_tuple.
7638 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
7639 (output_register, mi_cmd_data_read_memory)
7640 (mi_cmd_data_read_memory_bytes, mi_load_progress)
7641 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
7642 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
7643 Use ui_out_emit_tuple.
7644 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
7645 ui_out_emit_tuple.
7646 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
7647 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
7648 * linux-thread-db.c (info_auto_load_libthread_db): Use
7649 ui_out_emit_tuple.
7650 * inferior.c (print_inferior): Use ui_out_emit_tuple.
7651 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
7652 * disasm.c (do_mixed_source_and_assembly_deprecated)
7653 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
7654 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
7655 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
7656 * breakpoint.c (print_one_breakpoint_location)
7657 (print_one_breakpoint): Use ui_out_emit_tuple.
7658 * auto-load.c (print_script, info_auto_load_cmd): Use
7659 ui_out_emit_tuple.
7660 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
7661
9be21bb4
SM
76622017-04-21 Simon Marchi <simon.marchi@ericsson.com>
7663
7664 * thread.c (print_thread_info_1): Remove dead code.
7665
0d4c07af
JK
76662017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7667
7668 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
7669 GDB_SELF_TEST.
7670 * arm-tdep.c (selftests::arm_record_test): Likewise.
7671
4daf993d
YQ
76722017-04-21 Yao Qi <yao.qi@linaro.org>
7673
7674 * regcache.c (regcache_restore): Remove argument 2. Replace
7675 argument 3 with regcache. Get register status from
7676 src->register_status and get register contents from
7677 register_buffer (src, regnum).
7678 (regcache_cpy): Update.
7679
a6c21d4a
PA
76802017-04-19 Pedro Alves <palves@redhat.com>
7681
7682 * gdbthread.h (thread): Add missing closing parenthesis in
7683 comment.
7684
3a3fd0fd
PA
76852017-04-19 Pedro Alves <palves@redhat.com>
7686
7687 * common/refcounted-object.h: New file.
7688 * gdbthread.h: Include "common/refcounted-object.h".
7689 (thread_info): Inherit from refcounted_object and add comments.
7690 (thread_info::incref, thread_info::decref)
7691 (thread_info::m_refcount): Delete.
7692 (thread_info::deletable): Use the refcounted_object::refcount()
7693 method.
7694 * inferior.c (current_inferior_): Add comment.
7695 (set_current_inferior): Increment/decrement refcounts.
7696 (prune_inferiors, remove_inferior_command): Skip inferiors marked
7697 not-deletable instead of comparing with the current inferior.
7698 (initialize_inferiors): Increment the initial inferior's refcount.
7699 * inferior.h (struct inferior): Forward declare.
7700 Include "common/refcounted-object.h".
7701 (current_inferior, set_current_inferior): Move declaration to
7702 before struct inferior's definition, and fix comment.
7703 (inferior): Inherit from refcounted_object. Add comments.
7704 * thread.c (switch_to_thread_no_regs): Reference the thread's
7705 inferior pointer directly instead of doing a ptid lookup.
7706 (switch_to_no_thread): New function.
7707 (switch_to_thread(thread_info *)): New function, factored out
7708 from ...
7709 (switch_to_thread(ptid_t)): ... this.
7710 (restore_current_thread): Delete.
7711 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
7712 fields, and add 'inf' field.
7713 (do_restore_current_thread_cleanup): Check whether old->inf is
7714 alive instead of looking up an inferior by ptid. Use
7715 switch_to_thread and switch_to_no_thread.
7716 (restore_current_thread_cleanup_dtor): Use old->inf directly
7717 instead of lookup up an inferior by id. Decref the inferior.
7718 Don't restore 'removable'.
7719 (make_cleanup_restore_current_thread): Same the inferior pointer
7720 in old, instead of the inferior number. Incref the inferior.
7721 Don't save/clear 'removable'.
7722
9bcb1f16
PA
77232017-04-19 Pedro Alves <palves@redhat.com>
7724
7725 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7726 unittests/scoped_restore-selftests.c.
7727 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
7728 * common/scoped_restore.h (scoped_restore_base): Make "class".
7729 (scoped_restore_base::release): New public method.
7730 (scoped_restore_base::scoped_restore_base): New protected ctor.
7731 (scoped_restore_base::m_saved_var): New protected field.
7732 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
7733 scoped_restore_base base class instead of m_saved_var directly.
7734 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
7735 (scoped_restore_tmpl::scoped_restore_tmpl(const
7736 scoped_restore_tmpl<T>&)): Likewise.
7737 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
7738 method.
7739 (scoped_restore_tmpl::saved_var): New method.
7740 (scoped_restore_tmpl::m_saved_var): Delete.
7741 * inferior.h (inferior::detaching): Now a bool.
7742 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
7743 cleanup.
7744 * unittests/scoped_restore-selftests.c: New file.
7745
26fcd539
PA
77462017-04-19 Pedro Alves <palves@redhat.com>
7747
7748 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
7749 Re-sort in alphabetic order.
7750
fdd243b0
PA
77512017-04-18 Pedro Alves <palves@redhat.com>
7752
7753 * xml-support.c (obstack_xml_printf): Delete.
7754 * xml-support.h (obstack_xml_printf): Delete.
7755
4895cde2
PA
77562017-04-18 Pedro Alves <palves@redhat.com>
7757
7758 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
7759 vdebug, verror, body_text, start_element, end_element, name,
7760 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
7761 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
7762 is_xinclude>: Make private and add m_ prefix.
7763 (gdb_xml_parser::body_text): New method, based on ...
7764 (gdb_xml_body_text): ... this. Adjust.
7765 (gdb_xml_parser::vdebug): New method, based on ...
7766 (gdb_xml_debug): ... this. Adjust.
7767 (gdb_xml_parser::verror): New method, based on ...
7768 (gdb_xml_error): ... this. Adjust.
7769 (gdb_xml_parser::start_element): New method, based on ...
7770 (gdb_xml_start_element): ... this. Adjust.
7771 (gdb_xml_start_element_wrapper): Defer to
7772 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
7773 (gdb_xml_parser::end_element): New method, based on ...
7774 (gdb_xml_end_element_wrapper): ... this. Adjust.
7775 (gdb_xml_parser::~gdb_xml_parser): Adjust.
7776 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
7777 (gdb_xml_parser::use_dtd): New method, based on ...
7778 (gdb_xml_use_dtd): ... this. Adjust.
7779 (gdb_xml_parser::parse): New method, based on ...
7780 (gdb_xml_parse): ... this. Adjust.
7781 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
7782 (xinclude_start_include): Adjust to call the parser's name method.
7783 (xml_xinclude_default, xml_xinclude_start_doctype)
7784 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
7785 method.
7786 (xml_process_xincludes): Adjust to call parser methods.
7787 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
7788 declarations.
7789
bd8a901f
PA
77902017-04-18 Pedro Alves <palves@redhat.com>
7791
7792 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
7793 gdb::optional<std::string>.
7794 * xml-support.c: Include <string>.
7795 (scope_level::scope_level(scope_level &&))
7796 (scope_level::~scope_level): Delete.
7797 (scope_level::body): Now a std::string.
7798 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
7799 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
7800 parameter.
7801 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
7802 (xinclude_parsing_data::output): Now a std::string reference.
7803 (xinclude_start_include): Adjust.
7804 (xml_xinclude_default): Adjust.
7805 (xml_process_xincludes): Add 'output' parameter, and return bool.
7806 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
7807 and return bool.
7808 * xml-tdesc.c: Include <unordered_map> and <string>.
7809 (tdesc_xml_cache): Delete.
7810 (tdesc_xml_cache_s): Delete.
7811 (xml_cache): Now an std::unordered_map.
7812 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
7813 (target_fetch_description_xml): Change return type to
7814 gdb::optional<std::string>, and adjust.
7815 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
7816 (target_fetch_description_xml): Change return type to
7817 gdb::optional<std::string>.
7818
d35d1958
PA
78192017-04-18 Pedro Alves <palves@redhat.com>
7820
7821 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7822 unittests/optional-selftests.c.
7823 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
7824 * unittests/optional-selftests.c: New file.
7825 * unittests/optional/assignment/1.cc: New file.
7826 * unittests/optional/assignment/2.cc: New file.
7827 * unittests/optional/assignment/3.cc: New file.
7828 * unittests/optional/assignment/4.cc: New file.
7829 * unittests/optional/assignment/5.cc: New file.
7830 * unittests/optional/assignment/6.cc: New file.
7831 * unittests/optional/assignment/7.cc: New file.
7832 * unittests/optional/cons/copy.cc: New file.
7833 * unittests/optional/cons/default.cc: New file.
7834 * unittests/optional/cons/move.cc: New file.
7835 * unittests/optional/cons/value.cc: New file.
7836 * unittests/optional/in_place.cc: New file.
7837 * unittests/optional/observers/1.cc: New file.
7838 * unittests/optional/observers/2.cc: New file.
7839
22796e97
PA
78402017-04-18 Pedro Alves <palves@redhat.com>
7841
7842 * common/gdb_optional.h: Include common/traits.h.
7843 (in_place_t): New type.
7844 (in_place): New constexpr variable.
7845 (optional::optional): Remove member initialization of
7846 m_instantiated.
7847 (optional::optional(in_place_t...)): New constructor.
7848 (optional::~optional): Use reset.
7849 (optional::optional(const optional&)): New.
7850 (optional::optional(const optional&&)): New.
7851 (optional::optional(T &)): New.
7852 (optional::optional(T &&)): New.
7853 (operator::operator=(const optional &)): New.
7854 (operator::operator=(optional &&)): New.
7855 (operator::operator= (const T &))
7856 (operator::operator= (T &&))
7857 (operator::emplace (Args &&... args)): Return a T&. Use reset.
7858 (operator::reset): New.
7859 (operator::m_instantiated):: Add in-class initializer.
7860 * common/traits.h: Include <type_traits>.
7861 (struct And): New types.
7862
a7fc9b61
PA
78632017-04-18 Pedro Alves <palves@redhat.com>
7864
7865 * xml-support.c: Include <vector>.
7866 (scope_level::scope_level(const gdb_xml_element *))
7867 (scope_level::scope_level(scope_level&&)): New.
7868 (scope_level::~scope_level): New.
7869 (scope_level_s): Delete.
7870 (gdb_xml_parser::scopes): Now a std::vector.
7871 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
7872 Use std::vector.
7873 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
7874 scope cleanup code.
7875 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
7876 of the scopes member. Use std::vector::emplace_back.
7877
010151c9
PA
78782017-04-18 Pedro Alves <palves@redhat.com>
7879
7880 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
7881 a bool.
7882 (gdb_xml_end_element): Change type of first parameter.
7883 (gdb_xml_cleanup): Rename to ...
7884 (gdb_xml_parser::~gdb_xml_parser): ... this.
7885 (gdb_xml_create_parser_and_cleanup): Delete with ...
7886 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
7887 to this new ctor.
7888 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
7889 using gdb_xml_create_parser_and_cleanup.
7890 (xinclude_parsing_data): Add ctor/dtor.
7891 (xml_xinclude_cleanup): Delete.
7892 (xml_process_xincludes): Create a local xinclude_parsing_data
7893 instead of heap-allocating one. Create a local gdb_xml_parser
7894 instead of heap-allocating one with
7895 gdb_xml_create_parser_and_cleanup.
7896
d56060f0
JB
78972017-04-18 John Baldwin <jhb@FreeBSD.org>
7898
7899 PR threads/20743
7900 * fbsd-nat.c (resume_one_thread_cb): Remove.
7901 (resume_all_threads_cb): Remove.
7902 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
7903 iterate_over_threads.
7904
305d16a9
JB
79052017-04-17 Joel Brobecker <brobecker@adacore.com>
7906
7907 * NEWS: Create a new section for the next release branch.
7908 Rename the section of the current branch, now that it has
7909 been cut.
7910
8bb57231
JB
79112017-04-17 Joel Brobecker <brobecker@adacore.com>
7912
7913 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
7914 * version.in: Bump version to 8.0.50.DATE-git.
7915
096c92dd
SDJ
79162017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
7917
7918 PR gdb/21385
7919 * windows-nat.c (windows_create_inferior): Declare 'allargs'
7920 independently of the host, and fix build breakage on Cygwin.
7921
0550c955
PA
79222017-04-13 Pedro Alves <palves@redhat.com>
7923
7924 * inferior.c (free_inferior): Convert to ...
7925 (inferior::~inferior): ... this dtor.
7926 (inferior::inferior): New ctor, factored out from ...
7927 (add_inferior_silent): ... here. Allocate the inferior with a new
7928 expression.
7929 (delete_inferior): Call delete instead of free_inferior.
7930 * inferior.h (gdb_environ, continuation): Forward declare.
7931 (inferior): Now a class. Add in-class initialization to all
7932 members. Make boolean fields bool, except 'detaching'.
7933 (inferior::inferior): New explicit ctor.
7934 (inferior::~inferior): New.
7935
e3d60dfc
PA
79362017-04-13 Pedro Alves <palves@redhat.com>
7937
7938 * inferior.c (init_inferior_list): Delete.
7939 * inferior.h (init_inferior_list): Delete.
7940
5fd69d0a
PA
79412017-04-13 Pedro Alves <palves@redhat.com>
7942
7943 PR threads/13217
7944 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
7945 (top level): Call it twice, with different thread sets.
7946
c6609450
PA
79472017-04-13 Pedro Alves <palves@redhat.com>
7948
7949 * thread.c: Include <algorithm>.
7950 (thread_array_cleanup): Delete.
7951 (scoped_inc_dec_ref): New class.
7952 (live_threads_count): New function.
7953 (set_thread_refcount): Delete.
7954 (tp_array_compar_ascending): Now a bool.
7955 (tp_array_compar): Convert to a std::sort comparison function.
7956 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
7957 and live_threads_count.
7958
2a00d7ce
PA
79592017-04-13 Pedro Alves <palves@redhat.com>
7960
7961 * infrun.c (follow_fork_inferior): Also switch the current
7962 inferior.
7963
441d7c93
PA
79642017-04-13 Pedro Alves <palves@redhat.com>
7965
7966 * breakpoint.c (watch_command_1): Save watchpoint-frame info
7967 before calling create_internal_breakpoint.
7968
808480f6
PA
79692017-04-13 Pedro Alves <palves@redhat.com>
7970
7971 * fork-child.c (execv_argv): New class.
7972 (breakup_args): Refactored as ...
7973 (execv_argv::init_for_no_shell): .. this method of execv_argv.
7974 Copy arguments to storage and replace separators with NULL
7975 terminators in place.
7976 (escape_bang_in_quoted_argument): Adjust to return bool.
7977 (execv_argv::execv_argv): New ctor.
7978 (execv_argv::init_for_shell): New method, factored out from
7979 fork_inferior. Don't strdup strings into the vector.
7980 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
7981 Remove free_vector_argv call.
7982
ad3d022a
YQ
79832017-04-13 Yao Qi <yao.qi@linaro.org>
7984
7985 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
7986 tdep->rx_psw_type.
7987
e6ddc3bf
YQ
79882017-04-13 Yao Qi <yao.qi@linaro.org>
7989
7990 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
7991 * rx-tdep.c (rx_gdbarch_init): Likewise.
7992
bfb8cf90
PA
79932017-04-13 Pedro Alves <palves@redhat.com>
7994
7995 * breakpoint.h (struct breakpoint): Reindent.
7996
f5336ca5
PA
79972017-04-13 Pedro Alves <palves@redhat.com>
7998
7999 * breakpoint.c (bp_location): Rename to ...
8000 (bp_locations): ... this. All references updated.
8001 (bp_location_count): Rename to ...
8002 (bp_locations_count): ... this. All references updated.
8003 (bp_location_placed_address_before_address_max): Rename to ...
8004 (bp_locations_placed_address_before_address_max): ... this. All
8005 references updated.
8006 (bp_location_shadow_len_after_address_max): Rename to ...
8007 (bp_locations_shadow_len_after_address_max): ... this. All
8008 references updated.
8009 (bp_location_compare_addrs): Rename to ...
8010 (bp_locations_compare_addrs): ... this. All references updated.
8011 (bp_location_compare):Rename to ...
8012 (bp_locations_compare): ... this. All references updated.
8013 (bp_location_target_extensions_update): Rename to ...
8014 (bp_locations_target_extensions_update): ... this. All references
8015 updated.
8016
be628ab8
SDJ
80172017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8018
8019 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
8020 * common/common.m4: Check headers 'termios.h', 'termio.h' and
8021 'sgtty.h'.
8022 * common/gdb_termios.h: New file, with parts of "terminal.h".
8023 * inflow.c: Include "gdb_termios.h".
8024 * ser-unix.c: Include "gdb_termios.h".
8025 * terminal.h: Move terminal-related defines to
8026 "common/gdb_termios.h".
8027
8e9e35b1
TT
80282017-04-12 Tom Tromey <tom@tromey.com>
8029
8030 * probe.c (parse_probes): Update.
8031 * location.h (delete_event_location): Don't declare.
8032 (event_location_deleter::operator()): Update.
8033 * location.c (event_location_deleter::operator()): Rename from
8034 delete_event_location.
8035 * linespec.h (linespec_result) <location>: Change type to
8036 event_location_up.
8037 * linespec.c (canonicalize_linespec, event_location_to_sals)
8038 (decode_objc): Update.
8039 (linespec_result): Don't call delete_event_location.
8040 * breakpoint.c (create_breakpoints_sal)
8041 (bkpt_probe_create_sals_from_location)
8042 (strace_marker_create_sals_from_location): Update.
8043
16e802b9
TT
80442017-04-12 Tom Tromey <tom@tromey.com>
8045
8046 * linespec.h (struct linespec_result): Add constructor and
8047 destructor.
8048 (init_linespec_result, destroy_linespec_result)
8049 (make_cleanup_destroy_linespec_result): Don't declare.
8050 * linespec.c (init_linespec_result): Remove.
8051 (linespec_result::~linespec_result): Rename from
8052 destroy_linespec_result. Update.
8053 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
8054 Remove.
8055 * breakpoint.c (create_breakpoint, break_range_command)
8056 (decode_location_default): Update.
8057 * ax-gdb.c (agent_command_1): Update.
8058
d28cd78a
TT
80592017-04-12 Tom Tromey <tom@tromey.com>
8060
8061 * remote.c (remote_download_tracepoint): Update.
8062 * python/py-breakpoint.c (bppy_get_location): Update.
8063 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
8064 (gdbscm_breakpoint_location): Update.
8065 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
8066 * breakpoint.h (struct breakpoint) <location, location_range_end>:
8067 Change type to event_location_up.
8068 * breakpoint.c (create_overlay_event_breakpoint)
8069 (create_longjmp_master_breakpoint)
8070 (create_std_terminate_master_breakpoint)
8071 (create_exception_master_breakpoint)
8072 (breakpoint_event_location_empty_p, print_breakpoint_location)
8073 (print_one_breakpoint_location, create_thread_event_breakpoint)
8074 (init_breakpoint_sal, create_breakpoint)
8075 (print_recreate_ranged_breakpoint, break_range_command)
8076 (init_ada_exception_breakpoint, say_where): Update.
8077 (base_breakpoint_dtor): Don't call delete_event_location.
8078 (bkpt_print_recreate, tracepoint_print_recreate)
8079 (dprintf_print_recreate, update_static_tracepoint)
8080 (breakpoint_re_set_default): Update.
8081
711799d5
TT
80822017-04-12 Tom Tromey <tom@tromey.com>
8083
8084 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
8085 type of "to_do". Update.
8086 (compute_stack_depth): Use std::vector.
8087
52d214d3
TT
80882017-04-12 Tom Tromey <tom@tromey.com>
8089
8090 * printcmd.c (find_instruction_backward): Use std::vector.
8091
4c404b8b
TT
80922017-04-12 Tom Tromey <tom@tromey.com>
8093
8094 * symfile.c (objfilep): Remove typedef.
8095 (reread_symbols): Use a std::vector.
8096
156d9eab
TT
80972017-04-12 Tom Tromey <tom@tromey.com>
8098
8099 * mi/mi-main.c (exec_direction_forward): Remove.
8100 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
8101 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
8102 scoped_restore.
8103 * guile/guile.c (guile_repl_command, guile_command)
8104 (gdbscm_execute_gdb_command): Use scoped_restore.
8105 * go-exp.y (go_parse): Use scoped_restore.
8106 * d-exp.y (d_parse): Use scoped_restore.
8107 * cli/cli-decode.c (cmd_func): Use scoped_restore.
8108 * c-exp.y (c_parse): Use scoped_restore.
8109
4d89769a
TT
81102017-04-12 Tom Tromey <tom@tromey.com>
8111
8112 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
8113 (mi_parse): Update return type.
8114 (mi_parse_free): Remove.
8115 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
8116 (mi_parse::~mi_parse): Rename from mi_parse_free.
8117 (mi_parse_cleanup): Remove.
8118 (mi_parse): Return a unique_ptr. Use new.
8119 * mi/mi-main.c (mi_execute_command): Update.
8120
4b217cc7
TT
81212017-04-12 Tom Tromey <tom@tromey.com>
8122
8123 * location.c (explicit_location_lex_one): Return a
8124 unique_xmalloc_ptr.
8125 (string_to_explicit_location): Update. Remove cleanups.
8126
59d3651b
TT
81272017-04-12 Tom Tromey <tom@tromey.com>
8128
8129 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
8130 (compare_value_and_voffset): Change type. Update.
8131 (compute_vtable_size): Change type of "offset_vec".
8132 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
8133 (gnuv3_get_typeid): Remove extraneous declaration.
8134
b24b0d6c
TT
81352017-04-12 Tom Tromey <tom@tromey.com>
8136
8137 * charset.h (wchar_iterator): Fix comment.
8138
80a3b8c5
TT
81392017-04-12 Tom Tromey <tom@tromey.com>
8140
8141 * charset.c (iconv_wrapper): New class.
8142 (cleanup_iconv): Remove.
8143 (convert_between_encodings): Use it.
8144
c83dd867
TT
81452017-04-12 Tom Tromey <tom@tromey.com>
8146
8147 * symfile.h (increment_reading_symtab): Update type.
8148 * symfile.c (decrement_reading_symtab): Remove.
8149 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
8150 * psymtab.c (psymtab_to_symtab): Update.
8151 * dwarf2read.c (dw2_instantiate_symtab): Update.
8152
0e8621a0
TT
81532017-04-12 Tom Tromey <tom@tromey.com>
8154
8155 * jit.c (struct jit_reader): Declare separately. Add constructor
8156 and destructor. Change type of "handle".
8157 (loaded_jit_reader): Define separately.
8158 (jit_reader_load): Update. New "new".
8159 (jit_reader_unload_command): Use "delete".
8160 * gdb-dlfcn.h (struct dlclose_deleter): New.
8161 (gdb_dlhandle_up): New typedef.
8162 (gdb_dlopen, gdb_dlsym): Update types.
8163 (gdb_dlclose): Remove.
8164 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
8165 (gdb_dlsym): Change type of "handle".
8166 (make_cleanup_dlclose): Remove.
8167 (dlclose_deleter::operator()): Rename from gdb_dlclose.
8168 * compile/compile-c-support.c (load_libcc): Update.
8169
67d89901
TT
81702017-04-12 Tom Tromey <tom@tromey.com>
8171
8172 * symtab.h (find_pcs_for_symtab_line): Change return type.
8173 * symtab.c (find_pcs_for_symtab_line): Change return type.
8174 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
8175 type of "vec". Update.
8176 (ltpy_get_pcs_for_line): Update.
8177 * linespec.c (decode_digits_ordinary): Update.
8178
93921405
TT
81792017-04-12 Tom Tromey <tom@tromey.com>
8180
8181 * tracepoint.c (actions_command): Update.
8182 * python/python.c (python_command, python_interactive_command):
8183 Update.
8184 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
8185 * guile/guile.c (guile_command): Update.
8186 * defs.h (read_command_lines, read_command_lines_1): Return
8187 command_line_up.
8188 (command_lines_deleter): New struct.
8189 (command_line_up): New typedef.
8190 * compile/compile.c (compile_code_command)
8191 (compile_print_command): Update.
8192 * cli/cli-script.h (get_command_line, copy_command_lines): Return
8193 command_line_up.
8194 (make_cleanup_free_command_lines): Remove.
8195 * cli/cli-script.c (get_command_line, read_command_lines_1)
8196 (copy_command_lines): Return command_line_up.
8197 (while_command, if_command, read_command_lines, define_command)
8198 (document_command): Update.
8199 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
8200 Remove.
8201 * breakpoint.h (breakpoint_set_commands): Change type of
8202 "commands".
8203 * breakpoint.c (breakpoint_set_commands): Change type of
8204 "commands". Update.
8205 (do_map_commands_command, update_dprintf_command_list)
8206 (create_tracepoint_from_upload): Update.
8207
ffc2605c
TT
82082017-04-12 Tom Tromey <tom@tromey.com>
8209
8210 * tracepoint.c (scope_info): Update.
8211 * spu-tdep.c (spu_catch_start): Update.
8212 * python/python.c (gdbpy_decode_line): Update.
8213 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
8214 * python/py-breakpoint.c (bppy_init): Update.
8215 * probe.c (parse_probes): Update.
8216 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
8217 * location.h (event_location_deleter): New struct.
8218 (event_location_up): New typedef.
8219 (new_linespec_location, new_address_location, new_probe_location)
8220 (new_explicit_location, copy_event_location)
8221 (string_to_event_location, string_to_event_location_basic)
8222 (string_to_explicit_location): Update return type.
8223 (make_cleanup_delete_event_location): Remove.
8224 * location.c (new_linespec_location, new_address_location)
8225 (new_probe_location, new_explicit_location, copy_event_location):
8226 Return event_location_up.
8227 (delete_event_location_cleanup)
8228 (make_cleanup_delete_event_location): Remove.
8229 (string_to_explicit_location, string_to_event_location_basic)
8230 (string_to_event_location): Return event_location_up.
8231 * linespec.c (canonicalize_linespec, event_location_to_sals)
8232 (decode_line_with_current_source)
8233 (decode_line_with_last_displayed, decode_objc): Update.
8234 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
8235 * completer.c (location_completer): Update.
8236 * cli/cli-cmds.c (edit_command, list_command): Update.
8237 * breakpoint.c (create_overlay_event_breakpoint)
8238 (create_longjmp_master_breakpoint)
8239 (create_std_terminate_master_breakpoint)
8240 (create_exception_master_breakpoint)
8241 (create_thread_event_breakpoint): Update.
8242 (init_breakpoint_sal): Update. Remove some dead code.
8243 (create_breakpoint_sal): Change type of "location". Update.
8244 (create_breakpoints_sal, create_breakpoint, break_command_1)
8245 (dprintf_command, break_range_command, until_break_command)
8246 (init_ada_exception_breakpoint)
8247 (strace_marker_create_sals_from_location)
8248 (update_static_tracepoint, trace_command, ftrace_command)
8249 (strace_command, create_tracepoint_from_upload): Update.
8250 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8251 * ax-gdb.c (agent_command_1): Update.
8252
8f10c932
PA
82532017-04-12 Pedro Alves <palves@redhat.com>
8254
8255 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
8256 * configure.tgt: Handle i[34567]86-*-go32* and
8257 i[34567]86-*-msdosdjgpp*.
8258 * i386-tdep.c (i386_svr4_reg_to_regnum):
8259 Make extern.
8260 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
8261 i386-go32-tdep.c.
8262 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
8263 * i386-go32-tdep.c: New file.
8264 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
8265 declarations.
8266
0a31ccfb
SM
82672017-04-12 Simon Marchi <simon.marchi@ericsson.com>
8268
8269 * aix-thread.c (pd_status2str): Change return type to const char *.
8270
e9bb3fbb
PA
82712017-04-12 Pedro Alves <palves@redhat.com>
8272
8273 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
8274 calls to set_gdbarch_gnu_triplet_regexp.
8275
53375380
PA
82762017-04-12 Pedro Alves <palves@redhat.com>
8277
8278 PR gdb/21323
8279 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
8280 New enum value.
8281 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
8282 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
8283 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
8284 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
8285 * gdbarch.h, gdbarch.c: Regenerate.
8286 * aarch64-tdep.c (aarch64_gdbarch_init): Override
8287 gdbarch_wchar_bit and gdbarch_wchar_signed.
8288 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
8289 * arm-tdep.c (arm_gdbarch_init): Likewise.
8290 * avr-tdep.c (avr_gdbarch_init): Likewise.
8291 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
8292 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
8293 * i386-tdep.c (i386_go32_init_abi): Likewise.
8294 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
8295 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
8296 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
8297 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
8298 * sh-tdep.c (sh_gdbarch_init): Likewise.
8299 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
8300 * sparc64-tdep.c (sparc64_init_abi): Likewise.
8301 * windows-tdep.c (windows_init_abi): Likewise.
8302 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
8303
53e710ac
PA
83042017-04-12 Pedro Alves <palves@redhat.com>
8305
8306 PR c++/21323
8307 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
8308 cplus_primitive_type_char32_t>: New enum values.
8309 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
8310 and cplus_primitive_type_char32_t.
8311 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
8312 32, use the archtecture's built-in type for char16_t and char32_t,
8313 respectively. Otherwise, fallback to init_integer_type as before,
8314 but make the type unsigned, and issue a complaint.
8315 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
8316
ab0538b8
AH
83172017-04-12 Alan Hayward <alan.hayward@arm.com>
8318
5e0e0422 8319 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
8320 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
8321
5430098f
SDJ
83222017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8323
8324 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
8325 'const char *'.
8326
7c5ded6a
SDJ
83272017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
8328
8329 * common/common-utils.c (free_vector_argv): New function.
8330 * common/common-utils.h: Include <vector>.
8331 (free_vector_argv): New prototype.
8332 * darwin-nat.c (darwin_create_inferior): Rewrite function
8333 prototype in order to constify "exec_file" and accept a
8334 "std::string" for "allargs".
8335 * fork-child.c: Include <vector>.
8336 (breakup_args): Rewrite function, using C++.
8337 (fork_inferior): Rewrite function header, constify "exec_file_arg"
8338 and accept "std::string" for "allargs". Update the code to
8339 calculate "argv" based on "allargs". Update calls to "exec_fun"
8340 and "execvp".
8341 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
8342 order to constify "exec_file" and accept a "std::string" for
8343 "allargs".
8344 * go32-nat.c (go32_create_inferior): Likewise.
8345 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
8346 * infcmd.c (run_command_1): Constify "exec_file". Use
8347 "std::string" for inferior arguments.
8348 * inferior.h (fork_inferior): Update prototype.
8349 * linux-nat.c (linux_nat_create_inferior): Rewrite function
8350 prototype in order to constify "exec_file" and accept a
8351 "std::string" for "allargs".
8352 * nto-procfs.c (procfs_create_inferior): Likewise.
8353 * procfs.c (procfs_create_inferior): Likewise.
8354 * remote-sim.c (gdbsim_create_inferior): Likewise.
8355 * remote.c (extended_remote_run): Update code to accept
8356 "std::string" as argument.
8357 (extended_remote_create_inferior): Rewrite function prototype in
8358 order to constify "exec_file" and accept a "std::string" for
8359 "allargs".
8360 * rs6000-nat.c (super_create_inferior): Likewise.
8361 (rs6000_create_inferior): Likewise.
8362 * target.h (struct target_ops) <to_create_inferior>: Likewise.
8363 * windows-nat.c (windows_create_inferior): Likewise.
8364
ae0eee42
PA
83652017-04-11 Pedro Alves <palves@redhat.com>
8366
8367 * thread.c: Fix whitespace throughout.
8368
a6acac06
PR
83692017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
8370
8371 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
8372
64403bd1
AH
83732017-04-11 Alan Hayward <alan.hayward@arm.com>
8374
8375 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
8376
a5bef50f
SDJ
83772017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
8378
8379 PR gdb/21364
8380 * osdata.c (info_osdata): Check if 'type' is an empty string
8381 instead of NULL.
8382
9295a5a9
PA
83832017-04-10 Pedro Alves <palves@redhat.com>
8384
8385 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
8386 (ptid_to_global_thread_id, in_thread_list)
8387 (do_captured_list_thread_ids, set_resumed, set_running)
8388 (set_executing, set_stop_requested, finish_thread_state)
8389 (validate_registers_access, can_access_registers_ptid)
8390 (print_thread_info_1, switch_to_thread)
8391 (do_restore_current_thread_cleanup)
8392 (make_cleanup_restore_current_thread, thread_command)
8393 (thread_name_command): Use operator== instead of ptid_equal.
8394
996812e3
PA
83952017-04-10 Pedro Alves <palves@redhat.com>
8396
8397 * thread.c (struct current_thread_cleanup) <next>: Delete field.
8398 (current_thread_cleanup_chain): Delete.
8399 (restore_current_thread_cleanup_dtor)
8400 (make_cleanup_restore_current_thread): Remove references to
8401 current_thread_cleanup_chain.
8402
845b344f
AH
84032017-04-10 Alan Hayward <alan.hayward@arm.com>
8404
8405 * msp430-tdep.c (msp430_pseudo_register_read): Never return
8406 REG_UNKNOWN.
8407
803bdfe4
YQ
84082017-04-10 Yao Qi <yao.qi@linaro.org>
8409
8410 PR gdb/19942
8411 * gdbthread.h (thread_info::deletable): New method.
8412 (thread_info::incref): New method.
8413 (thread_info::decref): New method.
8414 (thread_info::refcount): Move it to private.
8415 * infrun.c (save_stop_context): Call inc_refcount.
8416 (release_stop_context_cleanup): Likewise.
8417 * thread.c (set_thread_exited): New function.
8418 (init_thread_list): Delete "tp" only it is deletable, otherwise
8419 call set_thread_exited.
8420 (delete_thread_1): Call set_thread_exited.
8421 (current_thread_cleanup) <inferior_pid>: Remove.
8422 <thread>: New field.
8423 (restore_current_thread_ptid_changed): Removed.
8424 (do_restore_current_thread_cleanup): Adjust.
8425 (restore_current_thread_cleanup_dtor): Don't call
8426 find_thread_ptid.
8427 (set_thread_refcount): Use dec_refcount.
8428 (make_cleanup_restore_current_thread): Adjust.
8429 (thread_apply_all_command): Call inc_refcount.
8430 (_initialize_thread): Don't call
8431 observer_attach_thread_ptid_changed.
8432
8c25b497
YQ
84332017-04-10 Yao Qi <yao.qi@linaro.org>
8434
8435 * thread.c (delete_thread_1): Hoist code on marking thread as
8436 exited.
8437
8473b447
SM
84382017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
8439
8440 * windows-nat.c (windows_detach): Initialize ptid with
8441 minus_one_ptid.
8442
6670ec13
SM
84432017-04-07 Simon Marchi <simon.marchi@ericsson.com>
8444
8445 * unittests/ptid-selftests.c: Fix erroneous assert messages.
8446
ba2f91bb
AH
84472017-04-07 Alan Hayward <alan.hayward@arm.com>
8448
8449 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
8450 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
8451 (bfin_pseudo_register_write): Likewise
8452
436252de
SM
84532017-04-06 Simon Marchi <simon.marchi@ericsson.com>
8454
8455 * common/ptid.h (struct ptid): Change to...
8456 (class ptid_t): ... this.
8457 <ptid_t>: New constructors.
8458 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
8459 matches>: New methods.
8460 <make_null, make_minus_one>: New static methods.
8461 <pid>: Rename to...
8462 <m_pid>: ...this.
8463 <lwp>: Rename to...
8464 <m_lwp>: ...this.
8465 <tid>: Rename to...
8466 <m_tid>: ...this.
8467 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
8468 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
8469 as references, move comment to class ptid_t.
8470 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
8471 ptid_t static methods.
8472 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
8473 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
8474 Take ptid arguments as references, implement using ptid_t methods.
8475 * unittests/ptid-selftests.c: New file.
8476 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8477 unittests/ptid-selftests.c.
8478 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
8479
0dedf377
TP
84802017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
8481
8482 * python/python.c (python_run_simple_file): Cast mode literal to
8483 non-const char pointer as expected by PyFile_FromString.
8484
4e9868d4
SM
84852017-04-05 Simon Marchi <simon.marchi@ericsson.com>
8486
8487 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
8488 minus_one_ptid and null_ptid.
8489
9bf2a700
PA
84902017-04-05 Pedro Alves <palves@redhat.com>
8491
8492 * warning.m4 (build_warnings): Remove -Wno-write-strings.
8493 * configure: Regenerate.
8494
a121b7c1
PA
84952017-04-05 Pedro Alves <palves@redhat.com>
8496
8497 * ada-exp.y (yyerror): Constify.
8498 * ada-lang.c (bound_name, get_selections)
8499 (ada_variant_discrim_type)
8500 (ada_variant_discrim_name, ada_value_struct_elt)
8501 (ada_lookup_struct_elt_type, is_unchecked_variant)
8502 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
8503 (catch_ada_exception_command_split)
8504 (catch_ada_assert_command_split, catch_assert_command)
8505 (ada_op_name): Constify.
8506 * ada-lang.h (ada_yyerror, get_selections)
8507 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
8508 * arc-tdep.c (arc_print_frame_cache): Constify.
8509 * arm-tdep.c (arm_skip_stub): Constify.
8510 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
8511 (gen_aggregate_elt_ref): Constify.
8512 * bcache.c (print_bcache_statistics): Constify.
8513 * bcache.h (print_bcache_statistics): Constify.
8514 * break-catch-throw.c (catch_exception_command_1):
8515 * breakpoint.c (struct ep_type_description::description):
8516 Constify.
8517 (add_solib_catchpoint): Constify.
8518 (catch_fork_command_1): Add cast.
8519 (add_catch_command): Constify.
8520 * breakpoint.h (add_catch_command, add_solib_catchpoint):
8521 Constify.
8522 * bsd-uthread.c (bsd_uthread_state): Constify.
8523 * buildsym.c (patch_subfile_names): Constify.
8524 * buildsym.h (next_symbol_text_func, patch_subfile_names):
8525 Constify.
8526 * c-exp.y (yyerror): Constify.
8527 (token::oper): Constify.
8528 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
8529 * c-varobj.c (cplus_describe_child): Constify.
8530 * charset.c (find_charset_names): Add cast.
8531 (find_charset_names): Constify array and add const_cast.
8532 * cli/cli-cmds.c (complete_command, cd_command): Constify.
8533 (edit_command): Constify.
8534 * cli/cli-decode.c (lookup_cmd): Constify.
8535 * cli/cli-dump.c (dump_memory_command, dump_value_command):
8536 Constify.
8537 (struct dump_context): Constify.
8538 (add_dump_command, restore_command): Constify.
8539 * cli/cli-script.c (get_command_line): Constify.
8540 * cli/cli-script.h (get_command_line): Constify.
8541 * cli/cli-utils.c (check_for_argument): Constify.
8542 * cli/cli-utils.h (check_for_argument): Constify.
8543 * coff-pe-read.c (struct read_pe_section_data): Constify.
8544 * command.h (lookup_cmd): Constify.
8545 * common/print-utils.c (decimal2str): Constify.
8546 * completer.c (gdb_print_filename): Constify.
8547 * corefile.c (set_gnutarget): Constify.
8548 * cp-name-parser.y (yyerror): Constify.
8549 * cp-valprint.c (cp_print_class_member): Constify.
8550 * cris-tdep.c (cris_register_name, crisv32_register_name):
8551 Constify.
8552 * d-exp.y (yyerror): Constify.
8553 (struct token::oper): Constify.
8554 * d-lang.h (d_yyerror): Constify.
8555 * dbxread.c (struct header_file_location::name): Constify.
8556 (add_old_header_file, add_new_header_file, last_function_name)
8557 (dbx_next_symbol_text, add_bincl_to_list)
8558 (find_corresponding_bincl_psymtab, set_namestring)
8559 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
8560 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
8561 * defs.h (command_line_input, print_address_symbolic)
8562 (deprecated_readline_begin_hook): Constify.
8563 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
8564 Constify.
8565 * event-top.c (handle_line_of_input): Constify and add cast.
8566 * exceptions.c (catch_errors): Constify.
8567 * exceptions.h (catch_errors): Constify.
8568 * expprint.c (print_subexp_standard, op_string, op_name)
8569 (op_name_standard, dump_raw_expression, dump_raw_expression):
8570 * expression.h (op_name, op_string, dump_raw_expression):
8571 Constify.
8572 * f-exp.y (yyerror): Constify.
8573 (struct token::oper): Constify.
8574 (struct f77_boolean_val::name): Constify.
8575 * f-lang.c (f_word_break_characters): Constify.
8576 * f-lang.h (f_yyerror): Constify.
8577 * fork-child.c (fork_inferior): Add cast.
8578 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
8579 (new_variant): Constify.
8580 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
8581 * gdbarch.c: Regenerate.
8582 * gdbcore.h (set_gnutarget): Constify.
8583 * go-exp.y (yyerror): Constify.
8584 (token::oper): Constify.
8585 * go-lang.h (go_yyerror): Constify.
8586 * go32-nat.c (go32_sysinfo): Constify.
8587 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
8588 * guile/scm-cmd.c (cmdscm_function): Constify.
8589 * guile/scm-param.c (pascm_param_value): Constify.
8590 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
8591 (h8300sx_register_name): Constify.
8592 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
8593 Constify.
8594 * ia64-tdep.c (ia64_register_names): Constify.
8595 * infcmd.c (construct_inferior_arguments): Constify.
8596 (path_command, attach_post_wait): Constify.
8597 * language.c (show_range_command, show_case_command)
8598 (unk_lang_error): Constify.
8599 * language.h (language_defn::la_error)
8600 (language_defn::la_name_of_this): Constify.
8601 * linespec.c (decode_line_2): Constify.
8602 * linux-thread-db.c (thread_db_err_str): Constify.
8603 * lm32-tdep.c (lm32_register_name): Constify.
8604 * m2-exp.y (yyerror): Constify.
8605 * m2-lang.h (m2_yyerror): Constify.
8606 * m32r-tdep.c (m32r_register_names): Constify and make static.
8607 * m68hc11-tdep.c (m68hc11_register_names): Constify.
8608 * m88k-tdep.c (m88k_register_name): Constify.
8609 * macroexp.c (appendmem): Constify.
8610 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
8611 (upgrade_type, parse_external, parse_partial_symbols)
8612 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
8613 (new_symbol): Constify.
8614 * memattr.c (mem_info_command): Constify.
8615 * mep-tdep.c (register_name_from_keyword): Constify.
8616 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
8617 Constify.
8618 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
8619 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
8620 * mi/mi-main.c (captured_mi_execute_command): Constify and add
8621 cast.
8622 (mi_execute_async_cli_command): Constify.
8623 * mips-tdep.c (mips_register_name): Constify.
8624 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
8625 (am33_register_name, am33_2_register_name)
8626 * moxie-tdep.c (moxie_register_names): Constify.
8627 * nat/linux-osdata.c (osdata_type): Constify fields.
8628 * nto-tdep.c (nto_parse_redirection): Constify.
8629 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
8630 (lookup_child_selector): Constify.
8631 (objc_methcall::name): Constify.
8632 * objc-lang.h (lookup_objc_class, lookup_child_selector)
8633 (lookup_struct_typedef): Constify.
8634 * objfiles.c (pc_in_section): Constify.
8635 * objfiles.h (pc_in_section): Constify.
8636 * p-exp.y (struct token::oper): Constify.
8637 (yyerror): Constify.
8638 * p-lang.h (pascal_yyerror): Constify.
8639 * parser-defs.h (op_name_standard): Constify.
8640 (op_print::string): Constify.
8641 (exp_descriptor::op_name): Constify.
8642 * printcmd.c (print_address_symbolic): Constify.
8643 * psymtab.c (print_partial_symbols): Constify.
8644 * python/py-breakpoint.c (stop_func): Constify.
8645 (bppy_get_expression): Constify.
8646 * python/py-cmd.c (cmdpy_completer::name): Constify.
8647 (cmdpy_function): Constify.
8648 * python/py-event.c (evpy_add_attribute)
8649 (gdbpy_initialize_event_generic): Constify.
8650 * python/py-event.h (evpy_add_attribute)
8651 (gdbpy_initialize_event_generic): Constify.
8652 * python/py-evts.c (add_new_registry): Constify.
8653 * python/py-finishbreakpoint.c (outofscope_func): Constify.
8654 * python/py-framefilter.c (get_py_iter_from_func): Constify.
8655 * python/py-inferior.c (get_buffer): Add cast.
8656 * python/py-param.c (parm_constant::name): Constify.
8657 * python/py-unwind.c (fprint_frame_id): Constify.
8658 * python/python.c (gdbpy_parameter_value): Constify.
8659 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
8660 * remote.c (memory_packet_config::name): Constify.
8661 (show_packet_config_cmd, remote_write_bytes)
8662 (remote_buffer_add_string):
8663 * reverse.c (exec_reverse_once): Constify.
8664 * rs6000-tdep.c (variant::name, variant::description): Constify.
8665 * rust-exp.y (rustyyerror): Constify.
8666 * rust-lang.c (rust_op_name): Constify.
8667 * rust-lang.h (rustyyerror): Constify.
8668 * serial.h (serial_ops::name): Constify.
8669 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
8670 (sh_sh3e_register_name, sh_sh2e_register_name)
8671 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
8672 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
8673 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
8674 (sh_sh4al_dsp_register_name): Constify.
8675 * sh64-tdep.c (sh64_register_name): Constify.
8676 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
8677 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
8678 * stabsread.c (patch_block_stabs, read_type_number)
8679 (ref_map::stabs, ref_add, process_reference)
8680 (symbol_reference_defined, define_symbol, define_symbol)
8681 (error_type, read_type, read_member_functions, read_cpp_abbrev)
8682 (read_one_struct_field, read_struct_fields, read_baseclasses)
8683 (read_tilde_fields, read_struct_type, read_array_type)
8684 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
8685 (read_huge_number, read_range_type, read_args, common_block_start)
8686 (find_name_end): Constify.
8687 * stabsread.h (common_block_start, define_symbol)
8688 (process_one_symbol, symbol_reference_defined, ref_add):
8689 * symfile.c (get_section_index, add_symbol_file_command):
8690 * symfile.h (get_section_index): Constify.
8691 * target-descriptions.c (tdesc_type::name): Constify.
8692 (tdesc_free_type): Add cast.
8693 * target.c (find_default_run_target):
8694 (add_deprecated_target_alias, find_default_run_target)
8695 (target_announce_detach): Constify.
8696 (do_option): Constify.
8697 * target.h (add_deprecated_target_alias): Constify.
8698 * thread.c (print_thread_info_1): Constify.
8699 * top.c (deprecated_readline_begin_hook, command_line_input):
8700 Constify.
8701 (init_main): Add casts.
8702 * top.h (handle_line_of_input): Constify.
8703 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
8704 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
8705 (tfind_command): Rename to ...
8706 (tfind_command_1): ... this and constify.
8707 (tfind_command): New function.
8708 (tfind_end_command, tfind_start_command): Adjust.
8709 (encode_source_string): Constify.
8710 * tracepoint.h (encode_source_string): Constify.
8711 * tui/tui-data.c (tui_partial_win_by_name): Constify.
8712 * tui/tui-data.h (tui_partial_win_by_name): Constify.
8713 * tui/tui-source.c (tui_set_source_content_nil): Constify.
8714 * tui/tui-source.h (tui_set_source_content_nil): Constify.
8715 * tui/tui-win.c (parse_scrolling_args): Constify.
8716 * tui/tui-windata.c (tui_erase_data_content): Constify.
8717 * tui/tui-windata.h (tui_erase_data_content): Constify.
8718 * tui/tui-winsource.c (tui_erase_source_content): Constify.
8719 * tui/tui.c (tui_enable): Add cast.
8720 * utils.c (defaulted_query): Constify.
8721 (init_page_info): Add cast.
8722 (puts_debug, subset_compare): Constify.
8723 * utils.h (subset_compare): Constify.
8724 * varobj.c (varobj_format_string): Constify.
8725 * varobj.h (varobj_format_string): Constify.
8726 * vax-tdep.c (vax_register_name): Constify.
8727 * windows-nat.c (windows_detach): Constify.
8728 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
8729 * xml-support.c (gdb_xml_end_element): Constify.
8730 * xml-tdesc.c (tdesc_start_reg): Constify.
8731 * xstormy16-tdep.c (xstormy16_register_name): Constify.
8732 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
8733 * xtensa-tdep.h (xtensa_register_t::name): Constify.
8734
995816ba
PA
87352017-04-05 Pedro Alves <palves@redhat.com>
8736
8737 * proc-api.c (struct trans): Constify.
8738 (procfs_note): Constify.
8739 * proc-events.c (struct trans, syscall_table):
8740 * proc-flags.c (struct trans): Constify.
8741 * proc-utils.h (procfs_note): Constify.
8742 * proc-why.c (struct trans): Constify.
8743 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
8744 (procfs_detach): Constify.
8745 * sol-thread.c (struct string_map): Constify.
8746 (td_err_string, td_state_string): Constify.
8747
3e83a920
PA
87482017-04-05 Pedro Alves <palves@redhat.com>
8749
8750 * proc-api.c (procfs_filename): Don't initialize
8751 procfs_filename.
8752 (prepare_to_trace): Assume procfs_filename is non-NULL.
8753 (_initialize_proc_api): Give procfs_filename a default value here.
8754
63160a43
PA
87552017-04-05 Pedro Alves <palves@redhat.com>
8756
8757 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
8758 'cond_string' parameter.
8759 (extract_exception_regexp): Constify 'string' parameter.
8760 (catch_exception_command_1): Constify.
8761 * breakpoint.c (init_catchpoint)
8762 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
8763 parameter.
8764 (ep_parse_optional_if_clause, catch_fork_command_1)
8765 (catch_exec_command_1): Constify.
8766 * breakpoint.h (init_catchpoint): Constify 'cond_string'
8767 parameter.
8768 (ep_parse_optional_if_clause): Constify.
8769 * cli/cli-utils.c (remove_trailing_whitespace)
8770 (check_for_argument): Constify.
8771 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
8772 non-const overload.
8773 (check_for_argument): Likewise.
8774
9b2eba3d
PA
87752017-04-05 Pedro Alves <palves@redhat.com>
8776
8777 * event-top.c (command_line_handler): Add cast to execute_command
8778 call.
8779 * record-btrace.c (cmd_record_btrace_bts_start)
8780 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
8781 (cmd_record_btrace_start): Add cast to execute_command call.
8782 * record-full.c (record_full_goto_insn):
8783 * record.c (record_start, record_stop): Add cast to
8784 execute_command_to_string calls.
8785 (cmd_record_start): Add cast to execute_command calls.
8786
2adadf51
PA
87872017-04-05 Pedro Alves <palves@redhat.com>
8788
8789 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
8790 static inline function.
8791 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
8792 array and use gdb_PyArg_ParseTupleAndKeywords.
8793 * python/py-cmd.c (cmdpy_init): Likewise.
8794 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
8795 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
8796 (infpy_search_memory): Likewise.
8797 * python/py-objfile.c (objfpy_add_separate_debug_file)
8798 (gdbpy_lookup_objfile): Likewise.
8799 * python/py-symbol.c (gdbpy_lookup_symbol)
8800 (gdbpy_lookup_global_symbol): Likewise.
8801 * python/py-type.c (gdbpy_lookup_type): Likewise.
8802 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
8803 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
8804 Likewise.
8805
0d1f4ceb
PA
88062017-04-05 Pedro Alves <palves@redhat.com>
8807
8808 * python/python-internal.h (gdb_PyGetSetDef): New type.
8809 * python/py-block.c (block_object_getset)
8810 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
8811 * python/py-event.c (event_object_getset)
8812 (finish_breakpoint_object_getset): Likewise.
8813 * python/py-inferior.c (inferior_object_getset): Likewise.
8814 * python/py-infthread.c (thread_object_getset): Likewise.
8815 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
8816 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
8817 * python/py-objfile.c (objfile_getset): Likewise.
8818 * python/py-progspace.c (pspace_getset): Likewise.
8819 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
8820 Likewise.
8821 * python/py-record.c (recpy_record_getset): Likewise.
8822 * python/py-symbol.c (symbol_object_getset): Likewise.
8823 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
8824 Likewise.
8825 * python/py-type.c (type_object_getset, field_object_getset):
8826 Likewise.
8827 * python/py-value.c (value_object_getset): Likewise.
8828
4d759979
PA
88292017-04-05 Pedro Alves <palves@redhat.com>
8830
8831 * python/python-internal.h (gdb_PyObject_CallMethod)
8832 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
8833 New functions.
8834 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
8835 (PySys_GetObject, PySys_SetPath): New macros.
8836
fdf9e36f
PA
88372017-04-05 Pedro Alves <palves@redhat.com>
8838
8839 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
8840 info_osdata_command.
8841 * osdata.c (info_osdata_command): Rename to ...
8842 (info_osdata): ... this. Constify 'type' parameter, and remove
8843 the 'from_tty' parameter. Accept NULL TYPE.
8844 (info_osdata_command): New function.
8845 * osdata.h (info_osdata_command): Remove declaration.
8846 (info_osdata): New declaration.
8847
9f33b8b7
PA
88482017-04-05 Pedro Alves <palves@redhat.com>
8849
8850 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
8851 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
8852 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
8853 parameter.
8854 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
8855 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
8856 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
8857 parameter.
8858 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
8859 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
8860 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
8861 (mi_cmd_file_list_exec_source_files)
8862 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
8863 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
8864 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
8865 parameter.
8866 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
8867 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
8868 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
8869 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
8870 (mi_cmd_stack_info_frame): Constify 'command' parameter.
8871 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
8872 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
8873 'command' parameter.
8874 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
8875 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
8876 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
8877 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
8878 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
8879 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
8880 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
8881 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
8882 (mi_cmd_var_set_update_range): Constify 'command' parameter.
8883 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
8884 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
8885 parameter.
8886 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
8887 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
8888 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
8889 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
8890 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
8891 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
8892 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
8893 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
8894 (mi_cmd_data_list_changed_registers)
8895 (mi_cmd_data_write_register_values)
8896 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
8897 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
8898 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
8899 (mi_cmd_list_features, mi_cmd_list_target_features)
8900 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
8901 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
8902 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
8903 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
8904 (mi_cmd_trace_frame_collected): Constify 'command'
8905 parameter.
8906 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
8907 'command' parameter.
8908
67cb5b2d
PA
89092017-04-05 Pedro Alves <palves@redhat.com>
8910
8911 * ada-lang.c (ada_completer_word_break_characters): Now a const
8912 array.
8913 (ada_get_gdb_completer_word_break_characters): Constify.
8914 * completer.c (gdb_completer_command_word_break_characters)
8915 (gdb_completer_file_name_break_characters)
8916 (gdb_completer_quote_characters): Now const arrays.
8917 (get_gdb_completer_quote_characters): Constify.
8918 (set_rl_completer_word_break_characters): New function.
8919 (set_gdb_completion_word_break_characters)
8920 (complete_line_internal): Use it.
8921 * completer.h (get_gdb_completer_quote_characters): Constify.
8922 (set_rl_completer_word_break_characters): Declare.
8923 * f-lang.c (f_word_break_characters): Constify.
8924 * language.c (default_word_break_characters): Constify.
8925 * language.h (language_defn::la_word_break_characters): Constify.
8926 (default_word_break_characters): Constify.
8927 * top.c (init_main): Use set_rl_completer_word_break_characters.
8928
7a114964
PA
89292017-04-05 Pedro Alves <palves@redhat.com>
8930
8931 * aix-thread.c (aix_thread_pid_to_str)
8932 (aix_thread_extra_thread_info): Constify.
8933 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
8934 * bsd-uthread.c (bsd_uthread_extra_thread_info)
8935 (bsd_uthread_pid_to_str): Constify.
8936 * corelow.c (core_pid_to_str): Constify.
8937 * darwin-nat.c (darwin_pid_to_str): Constify.
8938 * fbsd-nat.c (fbsd_pid_to_str): Constify.
8939 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
8940 Constify.
8941 * gnu-nat.c (gnu_pid_to_str): Constify.
8942 * go32-nat.c (go32_pid_to_str): Constify.
8943 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
8944 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
8945 * inferior.c (inferior_pid_to_str): Constify.
8946 * linux-nat.c (linux_nat_pid_to_str): Constify.
8947 * linux-tdep.c (linux_core_pid_to_str): Constify.
8948 * linux-thread-db.c (thread_db_pid_to_str)
8949 (thread_db_extra_thread_info): Constify.
8950 * nto-tdep.c (nto_extra_thread_info): Constify.
8951 * nto-tdep.h (nto_extra_thread_info): Constify.
8952 * obsd-nat.c (obsd_pid_to_str): Constify.
8953 * procfs.c (procfs_pid_to_str): Constify.
8954 * ravenscar-thread.c (ravenscar_extra_thread_info)
8955 (ravenscar_pid_to_str): Constify.
8956 * remote-sim.c (gdbsim_pid_to_str): Constify.
8957 * remote.c (remote_threads_extra_info, remote_pid_to_str):
8958 Constify.
8959 * sol-thread.c (solaris_pid_to_str): Constify.
8960 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
8961 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
8962 * target.c (default_pid_to_str, target_pid_to_str)
8963 (normal_pid_to_str, default_pid_to_str): Constify.
8964 * target.h (target_ops::to_pid_to_str)
8965 (target_ops::to_extra_thread_info): Constify.
8966 (target_pid_to_str, normal_pid_to_str): Constify.
8967 * windows-nat.c (windows_pid_to_str): Constify.
8968 * gdbarch.sh (core_pid_to_str): Constify.
8969 * target-delegates.c: Regenerate.
8970 * gdbarch.h, gdbarch.c: Regenerate.
8971
69bbf465
PA
89722017-04-05 Pedro Alves <palves@redhat.com>
8973
8974 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
8975 the memory of the temporary warning_pre_print override.
8976 * utils.c (warning_pre_print): Constify.
8977 * utils.h (warning_pre_print): Constify.
8978
be47f9e8
PA
89792017-04-05 Pedro Alves <palves@redhat.com>
8980
8981 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
8982 (shell_command): New function.
8983 (make_command): Use std::string.
8984 (init_cli_cmds): Register shell_command instead of shell_escape.
8985
bde6261a
PA
89862017-04-05 Pedro Alves <palves@redhat.com>
8987
8988 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
8989 * tracepoint.c (default_collect): Don't initialize.
8990
b38ef47f
PA
89912017-04-05 Pedro Alves <palves@redhat.com>
8992
8993 * macroexp.c (macro_buffer::shared): Now a bool.
8994 (init_buffer): Update.
8995 (init_shared_buffer): Constify 'addr' parameter.
8996 (substitute_args, expand, macro_expand, macro_expand_next): Remove
8997 casts.
8998
f995bbe8
PA
89992017-04-05 Pedro Alves <palves@redhat.com>
9000
9001 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
9002 * disasm.c (set_disassembler_options): Constify local.
9003 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
9004
4a596fe2
SDJ
90052017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
9006
9007 PR gdb/21352
9008 * tracefile.c (tsave_command): Fix argument parsing for '-r'
9009 option.
9010
2cad08ea
YQ
90112017-04-05 Yao Qi <yao.qi@linaro.org>
9012
9013 * frame.c (frame_unwind_register_unsigned): Call
9014 frame_unwind_register_value.
9015
55a98976
YQ
90162017-04-05 Yao Qi <yao.qi@linaro.org>
9017
9018 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
9019 Use gdb_test_multiple, and don't match anchor.
9020
4ac40124
PA
90212017-04-05 Pedro Alves <palves@redhat.com>
9022
9023 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
9024 (Write After Approval): Remove Simon Marchi.
9025
c053b654
PA
90262017-04-05 Pedro Alves <palves@redhat.com>
9027
9028 * common/gdb_optional.h (optional::optional): Make constexpr and
9029 initialize m_dummy.
9030
4c7bf4f9
JB
90312017-04-04 John Baldwin <jhb@FreeBSD.org>
9032
9033 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
9034 (amd64fbsd_jmp_buf_reg_offset): Remove.
9035 (amd64fbsd_supply_uthread): Remove function.
9036 (amd64fbsd_collect_uthread): Remove function.
9037 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
9038 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
9039 (x86_64-*-freebsd*): Remove bsd-uthread.o.
9040 (fbsd-nat.c): Update comment.
9041 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
9042 (i386fbsd_jmp_buf_reg_offset): Remove.
9043 (i386fbsd_supply_uthread): Remove function.
9044 (i386fbsd_collect_uthread): Remove function.
9045 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
9046
1e1a8bef
JB
90472017-04-04 John Baldwin <jhb@FreeBSD.org>
9048
9049 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
9050 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
9051 * NEWS: Mention that support for FreeBSD/alpha was removed.
9052 * alpha-fbsd-tdep.c: Delete file.
9053 * config/alpha/fbsd.mh: Delete file.
9054 * configure.host: Delete alpha*-*-freebsd* and
9055 alpha*-*-kfreebsd*-gnu.
9056 * configure.tgt: Delete alpha*-*-freebsd* and
9057 alpha*-*-kfreebsd*-gnu.
9058
49907934
JB
90592017-04-04 John Baldwin <jhb@FreeBSD.org>
9060
9061 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
9062 amd64bsd_store_inferior_registers): Use ptid from regcache.
9063
6f77053d
PA
90642017-04-04 Pedro Alves <palves@redhat.com>
9065
9066 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
9067 data fields, make them private and add "m_" prefixes.
9068 (lnp_state_machine::lnp_state_machine): New ctor.
9069 (record_line, check_line_address, handle_set_discriminator)
9070 (handle_set_address, handle_advance_pc, handle_special_opcode)
9071 (handle_advance_line, handle_set_file, handle_negate_stmt)
9072 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
9073 (end_sequence, advance_line): New methods.
9074 (m_gdbarch, m_record_lines_p): New fields.
9075 (lnp_reader_state): Delete.
9076 (dwarf_record_line): Rename to ...
9077 (lnp_state_machine::record_line): ... adjust.
9078 (init_lnp_state_machine): Delete.
9079 (lnp_state_machine::lnp_state_machine): New.
9080 (check_line_address): Rename to ...
9081 (lnp_state_machine::check_line_address): This.
9082 (dwarf_decode_lines_1): Remove reference to "reader_state".
9083 Adjust lnp_state_machine having a non-default ctor. Use bool.
9084 State machine internal state manipulation moved to
9085 lnp_state_machine methods.
9086
9c541725
PA
90872017-04-04 Pedro Alves <palves@redhat.com>
9088
9089 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9090 unittests/offset-type-selftests.c.
9091 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
9092 * common/offset-type.h: New file.
9093 * common/preprocessor.h: New file.
9094 * common/traits.h: New file.
9095 * common/valid-expr.h: New file.
9096 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
9097 sect_offset and cu_offset strong typedefs throughout.
9098 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
9099 typedefs throughout.
9100 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
9101 sect_offset and cu_offset strong typedefs throughout.
9102 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
9103 typedefs throughout.
9104 * gdbtypes.h: Include "common/offset-type.h".
9105 (cu_offset): Now an offset type (strong typedef) instead of a
9106 struct.
9107 (sect_offset): Likewise.
9108 (union call_site_parameter_u): Rename "param_offset" field to
9109 "param_cu_off".
9110 * unittests/offset-type-selftests.c: New file.
9111
ecfb656c
PA
91122017-04-04 Pedro Alves <palves@redhat.com>
9113
9114 * common/underlying.h: New file.
9115 * dwarf2read.c: Include "common/gdb_optional.h" and
9116 "common/underlying.h".
9117 (dir_index, file_name_index): New types.
9118 (file_entry): Use them.
9119 (file_entry::include): Use to_underlying.
9120 (line_header::add_file_name): Use dir_index.
9121 (read_formatted_entries): Use gdb::optional. Read form before
9122 writting to file_entry.
9123 (dwarf_decode_line_header): Use dir_index.
9124 (lnp_state_machine::current_file): Use to_underlying.
9125 (lnp_state_machine::file): Change type to file_name_index.
9126 (dwarf_record_line): Use to_underlying.
9127 (init_lnp_state_machine): Use file_name_index.
9128 (dwarf_decode_lines_1): Use dir_index and file_name_index.
9129
d194f1fe
PA
91302017-04-04 Pedro Alves <palves@redhat.com>
9131
9132 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
9133 operator bool, has_value and get methods.
9134
fff8551c
PA
91352017-04-04 Pedro Alves <palves@redhat.com>
9136
9137 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
9138 fields.
9139 (line_header): Initialize all data fields. Change type of
9140 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
9141 Change type of include_dirs to std::vector<const char *>. Remove
9142 num_include_dirs, include_dirs_size. Change type of file_names to
9143 std::vector<file_entry>. Remove num_file_names, file_names_size.
9144 (line_header::line_header): New.
9145 (line_header::add_include_dir, line_header::add_file_name): New
9146 methods.
9147 (line_header::include_dir_at): Remove NULL check.
9148 (line_header::file_name_at): Add const overload.
9149 (line_header_up): New unique_ptr typedef.
9150 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
9151 std::vector. Remove free_line_header call.
9152 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
9153 free_line_header call.
9154 (free_cu_line_header): Delete.
9155 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
9156 (setup_type_unit_groups): Use line_header_up instead of cleanups.
9157 Adjust to use std::vector.
9158 (free_line_header): Delete.
9159 (free_line_header_voidp): Use delete.
9160 (add_include_dir): Replace with ...
9161 (line_header::add_include_dir): ... this method. Use std::vector.
9162 (add_file_name): Replace with ...
9163 (line_header::add_file_name): ... this method. Use std::vector.
9164 (add_include_dir_stub): Delete.
9165 (read_formatted_entries): Remove memset.
9166 (dwarf_decode_line_header): Return a line_header_up instead of a
9167 raw pointer. Remove cleanup handling. Pass lambdas to
9168 read_formatted_entries. Adjust to use line_header methods.
9169 (dwarf_decode_lines_1): Adjust to use line_header methods.
9170 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
9171 use std::vector.
9172
d62a8ae2
SM
91732017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
9174
9175 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
9176 instead of struct ptid.
9177
db3a1dc7
AH
91782017-05-04 Alan Hayward <alan.hayward@arm.com>
9179
9180 * frame.c (get_frame_register_bytes): Unwind using value.
9181 (put_frame_register_bytes): Likewise.
9182
b1b45502
IB
91832017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
9184
9185 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
9186 aggregate-like.
9187
ec13808e
JK
91882017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
9189
9190 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
9191
12316564
YQ
91922017-03-29 Yao Qi <yao.qi@linaro.org>
9193
9194 * gdbthread.h (struct thread_info): Declare constructor and
9195 destructor. Add some in-class member initializers.
9196 * thread.c (free_thread): Remove.
9197 (init_thread_list): Call delete instead of free_thread.
9198 (new_thread): Call thread_info constructor.
9199 (thread_info::thread_info): New function.
9200 (thread_info::~thread_info): New function.
9201 (delete_thread_1): Call delete instead of free_thread.
9202 (make_cleanup_restore_current_thread): Move tp and frame to
9203 inner block.
9204
fe5f7374
AK
92052017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9206
9207 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
9208 (arc_skip_prologue): Likewise.
9209 (arc_make_frame_cache): Likewise.
9210 (arc_pv_get_operand): New function.
9211 (arc_is_in_prologue): Likewise.
9212 (arc_analyze_prologue): Likewise.
9213 (arc_print_frame_cache): Likewise.
9214 (MAX_PROLOGUE_LENGTH): New constant.
9215
eea78757
AK
92162017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9217
9218 * configure.tgt: Add arc-insn.o.
9219 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
9220 (dump_arc_instruction_command): New function.
9221 (arc_fprintf_disasm): Likewise.
9222 (arc_disassemble_info): Likewise.
9223 (arc_insn_get_operand_value): Likewise.
9224 (arc_insn_get_operand_value_signed): Likewise.
9225 (arc_insn_get_memory_base_reg): Likewise.
9226 (arc_insn_get_memory_offset): Likewise.
9227 (arc_insn_get_branch_target): Likewise.
9228 (arc_insn_dump): Likewise.
9229 (arc_insn_get_linear_next_pc): Likewise.
9230 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
9231 (arc_disassemble_info): Likewise.
9232 (arc_insn_get_branch_target): Likewise.
9233 (arc_insn_get_linear_next_pc): Likewise.
9234 * NEWS: Mention new "maint print arc arc-instruction".
9235
3be78afd
AK
92362017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9237
9238 * arc-tdep (maintenance_print_arc_list): New variable.
9239 (maintenance_print_arc_command): New function.
9240
296ec4fa
AK
92412017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
9242
9243 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
9244 Add "limm" and "reserved".
9245 (arc_cannot_fetch_register, arc_cannot_store_register): Add
9246 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
9247 * arc-tdep.h (arc_regnum): Likewise.
9248
f74f865e
MF
92492017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9250
9251 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9252 for THREADPTR register.
9253 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
9254 register.
9255 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
9256 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
9257 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
9258
0d0bf81a
MF
92592017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9260
9261 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
9262 registers above gdbarch_num_regs (gdbarch) as privileged in
9263 call0 ABI.
9264
0ce4291e
MF
92652017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9266
9267 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
9268 for a single specified register or for all registers in
9269 a0_base..a0_base + C0_NREGS range.
9270 (supply_gregset_reg): Call regcache_raw_supply for a single
9271 specified register or for all registers in a0_base..a0_base +
9272 C0_NREGS range.
9273
c56054f9
MF
92742017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9275
9276 * arch/xtensa.h (C0_NREGS): Add definition.
9277 * xtensa-tdep.c (C0_NREGS): Remove definition.
9278
a4398628
MF
92792017-03-27 Max Filippov <jcmvbkbc@gmail.com>
9280
9281 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
9282 Drop xtensa_default_isa initialization.
9283 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
9284
8c43009f
PA
92852017-03-27 Pedro Alves <palves@redhat.com>
9286
9287 * dwarf2read.c (file_entry) <dir_index>: Add comment.
9288 (file_entry::include_dir): New method.
9289 (line_header::include_dir_at, line_header::file_name_at): New
9290 methods.
9291 (setup_type_unit_groups, setup_type_unit_groups)
9292 (psymtab_include_file_name): Simplify using the new methods.
9293 (lnp_state_machine) <the_line_header>: New field.
9294 <file>: Add comment.
9295 (lnp_state_machine::current_file): New method.
9296 (dwarf_record_line): Simplify using the new methods.
9297 (init_lnp_state_machine): Initialize the "the_line_header" field.
9298 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
9299 Simplify using the new methods.
9300
a7e80b9e
PA
93012017-03-27 Pedro Alves <palves@redhat.com>
9302
9303 * cp-name-parser.y (make_empty): Delete.
9304 (demangler_special, nested_name, ptr_operator, array_indicator)
9305 (direct_declarator, declarator_1): Use fill_comp instead of
9306 make_empty.
9307
21047726
PA
93082017-03-27 Pedro Alves <palves@redhat.com>
9309
9310 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
9311 to ATTRIBUTE_PRINTF.
9312 * solib-target.c (library_list_start_list): Print "string" not
9313 "version".
9314 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
9315 gdb_xml_error call.
9316
d721ba37
PA
93172017-03-27 Pedro Alves <palves@redhat.com>
9318
9319 * dwarf2read.c (struct file_and_directory): New.
9320 (dwarf2_get_dwz_file): Adjust to use std::string.
9321 (dw2_get_file_names_reader): Adjust to use file_and_directory.
9322 (find_file_and_directory): Adjust to return a file_and_directory
9323 object.
9324 (read_file_scope): Adjust to use file_and_directory. Remove
9325 make_cleanup/do_cleanups calls.
9326 (open_and_init_dwp_file): Adjust to use std::string. Remove
9327 make_cleanup/do_cleanups calls.
9328 * python/python.c (do_start_initialization): Adjust to ldirname
9329 returning a std::string.
9330 * utils.c (ldirname): Now returns a std::string.
9331 * utils.h (ldirname): Change return type to std::string.
9332 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
9333 returning a std::string.
9334 * xml-tdesc.c (file_read_description_xml): Likewise.
9335
ed771251
AH
93362017-03-24 Alan Hayward <alan.hayward@arm.com>
9337
9338 * regcache.c (regcache_debug_print_register): New function.
9339 * regcache.h (regcache_debug_print_register): New declaration.
9340 * target.c (debug_print_register): Remove.
9341 (target_fetch_registers): Call regcache_debug_print_register.
9342 (target_store_registers): Likewise.
9343
568c1b9f
PB
93442017-03-24 Pádraig Brady <pbrady@fb.com>
9345
9346 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
9347 reference beyond the 'lh->include_dirs' array before accessing to
9348 it.
9349 (psymtab_include_file_name): Likewise.
9350 (dwarf_decode_lines_1): Likewise.
9351 (dwarf_decode_lines): Likewise.
9352 (file_file_name): Likewise.
9353
3e00d44f
SM
93542017-03-23 Simon Marchi <simon.marchi@ericsson.com>
9355
9356 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
9357 inferior_ptid.
9358 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9359 ps_lsetfpregs): Likewise.
9360 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
9361 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
9362 ps_lsetfpregs): Likewise.
9363 * target.c (target_fetch_registers, target_store_registers):
9364 Remove asserts.
9365
077ae656
AH
93662017-03-23 Alan Hayward <alan.hayward@arm.com>
9367
9368 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
9369
1e2b521d
YQ
93702017-03-23 Yao Qi <yao.qi@linaro.org>
9371
9372 * aarch64-tdep.c (aarch64_process_record_test): Declare.
9373 (_initialize_aarch64_tdep): Register it.
9374 (aarch64_record_load_store): Handle PRFM instruction.
9375 (aarch64_process_record_test): New function.
9376
33877125
YQ
93772017-03-23 Yao Qi <yao.qi@linaro.org>
9378
9379 * aarch64-tdep.c (aarch64_record_load_store): Fix code
9380 indentation.
9381
a0eef940
YQ
93822017-03-23 Yao Qi <yao.qi@linaro.org>
9383
9384 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
9385
3f2a3564
PR
93862017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
9387
9388 python/python.c (do_start_initialization): Fix memory leak.
9389
b67aeab0
SM
93902017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
9391
9392 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
9393 using get_ptrace_pid.
9394 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
9395 inferior_ptid.
9396 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
9397 inferior_ptid instead of pid.
9398
ffdbe864
YQ
93992017-03-22 Yao Qi <yao.qi@linaro.org>
9400
9401 * aarch64-tdep.c: Wrap locally used classes in anonymous
9402 namespace.
9403 * arm-tdep.c: Likewise.
9404 * linespec.c: Likewise.
9405 * ui-out.c: Likewise.
9406
9d736fbf
JG
94072017-03-22 Jonah Graham <jonah@kichwacoders.com>
9408
9409 PR gdb/19637
9410 * python/lib/gdb/printer/bound_registers.py: Import sys.
9411
3de88e9a
SM
94122017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9413
9414 * windows-nat.c (do_windows_fetch_inferior_registers): Add
9415 windows_thread_info parameter and use it instead of
9416 current_thread.
9417 (windows_fetch_inferior_registers): Don't set current_thread,
9418 pass the thread to do_windows_fetch_inferior_registers. Use
9419 ptid from regcache instead of inferior_ptid.
9420 (do_windows_store_inferior_registers): Add windows_thread_info
9421 parameter and use it instead of current_thread.
9422 (windows_store_inferior_registers): Don't set current_thread,
9423 pass the thread to do_windows_store_inferior_registers. Use
9424 ptid from regcache instead of inferior_ptid.
9425
0e7b8f61
SM
94262017-03-21 Simon Marchi <simon.marchi@ericsson.com>
9427
9428 * ser-mingw.c (ser_windows_raw): Remove reference to
9429 struct serial::current_timeout.
9430
5badf10a
IR
94312017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
9432
9433 PR tdep/20928
9434 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
9435 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
9436 (sparc64_fsr_type): Fix %fsr decoding.
9437
cee59b3f
TW
94382017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
9439
9440 * python/py-record-btrace.c (btpy_insn_data): Change return type
9441 for Python 2.
9442
639a9038
SM
94432017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9444
9445 * spu-linux-nat.c (spu_fetch_inferior_registers,
9446 spu_store_inferior_registers): Use ptid from regcache, set and
9447 restore inferior_ptid.
9448 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
9449 Likewise.
9450
bcc0c096
SM
94512017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
9452
9453 * i386-linux-nat.c (fetch_register, store_register,
9454 i386_linux_fetch_inferior_registers,
9455 i386_linux_store_inferior_registers): Use ptid from regcache.
9456 * ia64-linux-nat.c (ia64_linux_fetch_register,
9457 ia64_linux_store_register): Likewise.
9458 * inf-ptrace.c (inf_ptrace_fetch_register,
9459 inf_ptrace_store_register): Likewise.
9460 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
9461 m32r_linux_store_inferior_registers): Likewise.
9462 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
9463 m68kbsd_store_inferior_registers): Likewise.
9464 * m68k-linux-nat.c (fetch_register, store_register,
9465 m68k_linux_fetch_inferior_registers,
9466 m68k_linux_store_inferior_registers): Likewise.
9467 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
9468 m88kbsd_store_inferior_registers): Likewise.
9469 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
9470 mips_fbsd_store_inferior_registers): Likewise.
9471 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
9472 mips64_linux_regsets_store_registers): Likewise.
9473 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
9474 mipsnbsd_store_inferior_registers): Likewise.
9475 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
9476 mips64obsd_store_inferior_registers): Likewise.
9477 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
9478 Likewise.
9479 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
9480 ppcfbsd_store_inferior_registers): Likewise.
9481 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
9482 ppc_linux_store_inferior_registers): Likewise.
9483 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
9484 ppcnbsd_store_inferior_registers): Likewise.
9485 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
9486 ppcobsd_store_registers): Likewise.
9487 * procfs.c (procfs_fetch_registers, procfs_store_registers):
9488 Likewise.
9489 * ravenscar-thread.c (ravenscar_fetch_registers,
9490 ravenscar_store_registers, ravenscar_prepare_to_store):
9491 Likewise.
9492 * record-btrace.c (record_btrace_fetch_registers,
9493 record_btrace_store_registers, record_btrace_prepare_to_store):
9494 Likewise.
9495 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
9496 Lookup inferior using ptid from regcache, instead of
9497 current_inferior.
9498 * remote.c (remote_fetch_registers, remote_store_registers): Use
9499 ptid from regcache.
9500 * rs6000-nat.c (fetch_register, store_register): Likewise.
9501 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
9502 s390_linux_store_inferior_registers): Likewise.
9503 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
9504 shnbsd_store_inferior_registers): Likewise.
9505 * sol-thread.c (sol_thread_fetch_registers,
9506 sol_thread_store_registers): Likewise.
9507 * sparc-nat.c (sparc_fetch_inferior_registers,
9508 sparc_store_inferior_registers): Likewise.
9509 * tilegx-linux-nat.c (fetch_inferior_registers,
9510 store_inferior_registers): Likewise.
9511 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
9512 vaxbsd_store_inferior_registers): Likewise.
9513 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
9514 store_xtregs): Likewise.
9515
c0f55cc6
AV
95162017-03-20 Artemiy Volkov <artemiyv@acm.org>
9517
9518 PR gdb/14441
9519 * NEWS: Mention support for rvalue references in GDB and python.
9520 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
9521 supports both lvalue and rvalue references.
9522
15c0a2a9
AV
95232017-03-20 Artemiy Volkov <artemiyv@acm.org>
9524
9525 PR gdb/14441
9526 * gdbtypes.c (rank_one_type): Implement overloading
9527 resolution rules regarding rvalue references.
9528
aa006118
AV
95292017-03-20 Artemiy Volkov <artemiyv@acm.org>
9530
9531 PR gdb/14441
9532 * aarch64-tdep.c (aarch64_type_align)
9533 (aarch64_extract_return_value, aarch64_store_return_value): Change
9534 lvalue reference type checks to general reference type checks.
9535 * amd64-tdep.c (amd64_classify): Likewise.
9536 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
9537 Likewise.
9538 * arm-tdep.c (arm_type_align, arm_extract_return_value)
9539 (arm_store_return_value): Likewise.
9540 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
9541 * c-typeprint.c (c_print_type): Likewise.
9542 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
9543 (cplus_number_of_children, cplus_describe_child): Likewise.
9544 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
9545 * completer.c (expression_completer): Likewise.
9546 * cp-support.c (make_symbol_overload_list_adl_namespace):
9547 Likewise.
9548 * darwin-nat-info.c (info_mach_region_command): Likewise.
9549 * dwarf2loc.c (entry_data_value_coerce_ref)
9550 (value_of_dwarf_reg_entry): Likewise.
9551 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
9552 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
9553 Likewise.
9554 * findvar.c (extract_typed_address, store_typed_address):
9555 Likewise.
9556 * gdbtypes.c (rank_one_type): Likewise.
9557 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
9558 * infcall.c (value_arg_coerce): Likewise.
9559 * language.c (pointer_type): Likewise.
9560 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
9561 Likewise.
9562 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
9563 * mn10300-tdep.c (mn10300_type_align): Likewise.
9564 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
9565 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
9566 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
9567 Likewise.
9568 * printcmd.c (print_formatted, x_command): Likewise.
9569 * python/py-type.c (typy_get_composite, typy_template_argument):
9570 Likewise.
9571 * python/py-value.c (valpy_referenced_value)
9572 (valpy_get_dynamic_type, value_has_field): Likewise.
9573 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
9574 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
9575 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
9576 * spu-tdep.c (spu_scalar_value_p): Likewise.
9577 * symtab.c (lookup_symbol_aux): Likewise.
9578 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
9579 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
9580 Likewise.
9581 * valops.c (value_cast_pointers, value_cast)
9582 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
9583 (value_struct_elt, value_struct_elt_bitpos)
9584 (value_find_oload_method_list, find_overload_match)
9585 (value_rtti_indirect_type): Likewise.
9586 * valprint.c (val_print_scalar_type_p, generic_val_print):
9587 Likewise.
9588 * value.c (value_actual_type, value_as_address, unpack_long)
9589 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
9590 (coerce_ref): Likewise.
9591 * varobj.c (varobj_get_value_type): Likewise.
9592
3fcf899d
AV
95932017-03-20 Artemiy Volkov <artemiyv@acm.org>
9594
9595 PR gdb/14441
9596 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
9597 table of constants.
9598 * python/lib/gdb/command/explore.py: Support exploring values
9599 of rvalue reference types.
9600 * python/lib/gdb/types.py: Implement get_basic_type() for
9601 rvalue reference types.
9602 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
9603 constant.
9604 * python/py-value.c (valpy_getitem): Add an rvalue reference
9605 check.
9606 (valpy_reference_value): Add new parameter "refcode".
9607 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
9608 New wrappers for valpy_reference_value().
9609 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9610 (gdbpy_invoke_xmethod): Likewise.
9611
4297a3f0
AV
96122017-03-20 Artemiy Volkov <artemiyv@acm.org>
9613
9614 PR gdb/14441
9615 * dwarf2read.c (process_die, read_type_die_1): Handle the
9616 DW_TAG_rvalue_reference_type DIE.
9617 (read_tag_reference_type): Add new parameter "refcode".
9618
e1cb3213
AV
96192017-03-20 Artemiy Volkov <artemiyv@acm.org>
9620
9621 PR gdb/14441
9622 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
9623 (c_type_print_modifier, c_type_print_varspec_suffix)
9624 (c_type_print_base): Support printing rvalue reference types.
9625 * c-valprint.c (c_val_print, c_value_print): Support printing
9626 rvalue reference values.
9627
e4347c89
AV
96282017-03-20 Artemiy Volkov <artemiyv@acm.org>
9629
9630 PR gdb/14441
9631 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
9632 typename.
9633 * cp-support.c (replace_typedefs): Handle
9634 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
9635 * python/py-type.c (typy_lookup_type): Likewise.
9636
53cc15f5
AV
96372017-03-20 Artemiy Volkov <artemiyv@acm.org>
9638
9639 PR gdb/14441
9640 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
9641 * parse.c (insert_type): Change assert statement.
9642 (follow_types): Handle rvalue reference types.
9643 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
9644 constant.
9645
a65cfae5
AV
96462017-03-20 Artemiy Volkov <artemiyv@acm.org>
9647
9648 PR gdb/14441
9649 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
9650 value_ref() interface.
9651 * c-valprint.c (c_value_print): Likewise.
9652 * infcall.c (value_arg_coerce): Likewise.
9653 * python/py-value.c (valpy_reference_value): Likewise.
9654 * valops.c (value_cast, value_reinterpret_cast)
9655 (value_dynamic_cast, typecmp): Likewise.
9656 (value_ref): Parameterize by kind of return value reference type.
9657 * value.h (value_ref): Add new parameter "refcode".
9658
3b224330
AV
96592017-03-20 Artemiy Volkov <artemiyv@acm.org>
9660
9661 PR gdb/14441
9662 * dwarf2read.c (read_tag_reference_type): Use
9663 lookup_lvalue_reference_type() instead of lookup_reference_type().
9664 * eval.c (evaluate_subexp_standard): Likewise.
9665 * f-exp.y: Likewise.
9666 * gdbtypes.c (make_reference_type, lookup_reference_type):
9667 Generalize with rvalue reference types.
9668 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
9669 convenience wrappers for lookup_reference_type().
9670 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
9671 reference kind parameter.
9672 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
9673 wrappers for lookup_reference_type().
9674 * guile/scm-type.c (gdbscm_type_reference): Use
9675 lookup_lvalue_reference_type() instead of lookup_reference_type().
9676 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
9677 * parse.c (follow_types): Likewise.
9678 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
9679 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
9680 Likewise.
9681 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
9682 (gdbpy_invoke_xmethod): Likewise.
9683 * stabsread.c: Provide extra argument to make_reference_type()
9684 call.
9685 * valops.c (value_ref, value_rtti_indirect_type): Use
9686 lookup_lvalue_reference_type() instead of lookup_reference_type().
9687
f9aeb8d4
AV
96882017-03-20 Artemiy Volkov <artemiyv@acm.org>
9689
9690 PR gdb/14441
9691 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
9692 (TYPE_IS_REFERENCE): New macro.
9693 (struct type): Add rvalue_reference_type field.
9694 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
9695
51457a05
MAL
96962017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9697
9698 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
9699 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
9700 New function definition.
9701 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
9702 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
9703 New function declaration.
9704 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
9705 * mi/mi-interp.h: New file.
9706 * solib.c (info_sharedlibrary_command): Replace for loop with
9707 ALL_SO_LIBS macro
9708 * solib.h (update_solib_list): New function declaration.
9709 (so_list_head): Move macro.
9710 * solist.h (ALL_SO_LIBS): New macro.
9711
e696b3ad
MAL
97122017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
9713
9714 * infcmd.c (post_create_inferior): Remove unused argument in
9715 call to solib_add.
9716 * remote.c (remote_start_remote): Likewise.
9717 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
9718 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
9719 (enable_break): Likewise.
9720 * solib.c (update_solib_list): Remove unused target argument
9721 and its documentation.
9722 (solib_add): Remove unused target argument. Remove unused
9723 argument in call to update_solib_list.
9724 (info_sharedlibrary_command): Remove unused argument in call
9725 to update_solib_list.
9726 (sharedlibrary_command): Remove unused argument in call to
9727 solib_add.
9728 (handle_solib_event): Likewise.
9729 (reload_shared_libraries): Likewise.
9730 * solib.h (solib_add): Remove unused target argument.
9731
dcb84eda
AA
97322017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
9733
9734 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
9735 (s390_displaced_step_fixup): Cover relative branches with the
9736 default fixup handling. This fixes lack of support for some
9737 relative branch instructions.
9738
d9cb6cdc
SM
97392017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9740
9741 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
9742 ptid from regcache.
9743
1afaf9f4
SM
97442017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9745
9746 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
9747 i386_darwin_store_inferior_registers): Use ptid from regcache.
9748
aac12e24
SM
97492017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9750
9751 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
9752 i386bsd_store_inferior_registers): Use ptid from regcache.
9753
bbe1eef1
SM
97542017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9755
9756 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
9757 hppaobsd_store_registers): Use ptid from regcache.
9758
10799020
SM
97592017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9760
9761 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
9762 hppanbsd_store_registers): Use ptid from regcache.
9763
00204cf7
SM
97642017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9765
9766 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
9767 from regcache. Use get_ptrace_pid.
9768
11a33714
SM
97692017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9770
9771 * corelow.c (get_core_register_section): Use ptid from regcache,
9772 update doc.
9773
317cd492
SM
97742017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9775
9776 * bsd-uthread.c (bsd_uthread_fetch_registers,
9777 bsd_uthread_store_registers): Use ptid from regcache, set and
9778 restore inferior_ptid.
9779
9ac8a7c2
SM
97802017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9781
9782 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
9783 fetch_fp_regs, store_register, store_regs, store_fp_register,
9784 store_fp_regs): Use ptid from regcache.
9785
4ac4bb6a
SM
97862017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
9787
9788 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
9789 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
9790 store_vfp_regs): Use ptid from regcache.
9791
9bcbdca8
PA
97922017-03-17 Pedro Alves <palves@redhat.com>
9793
9794 PR remote/21188
9795 * ser-base.c (ser_base_wait_for): Add comment.
9796 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
9797 version.
9798 * ser-unix.c (hardwire_raw): Remove reference to
9799 scb->current_timeout.
9800 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
9801 (hardwire_ops): Install ser_base_readchar instead of
9802 hardwire_readchar.
9803 * serial.h (struct serial) <current_timeout, timeout_remaining>:
9804 Remove fields.
9805
7503099f
JG
98062017-03-17 Jonah Graham <jonah@kichwacoders.com>
9807
9808 PR gdb/19637
9809 * python/lib/gdb/printer/bound_registers.py: Add support for
9810 Python 3.
9811
7942e96e
AA
98122017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
9813
9814 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
9815 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
9816 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
9817 byte_offset to subobj_byte_offset. Fix the handling of
9818 DWARF_VALUE_STACK on big-endian targets when coming via an
9819 implicit pointer.
9820 (dwarf2_evaluate_loc_desc): Adjust call to
9821 dwarf2_evaluate_loc_desc_full.
9822 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
9823 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
9824
ba14f379
YQ
98252017-03-16 Yao Qi <yao.qi@linaro.org>
9826
9827 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
9828 and REVSH instructions.
9829
b121eeb9
YQ
98302017-03-16 Yao Qi <yao.qi@linaro.org>
9831
9832 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
9833 (arm_record_test): Declare.
9834 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
9835 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
9836 align with the manual.
9837 (thumb_record_misc): Adjust the code order to align with the
9838 manual.
9839 (thumb2_record_decode_insn_handler): Fix instruction matching.
9840 (instruction_reader_thumb): New class.
9841 (arm_record_test): New function.
9842
728a7913
YQ
98432017-03-16 Yao Qi <yao.qi@linaro.org>
9844
9845 * arm-tdep.c (abstract_memory_reader): New class.
9846 (instruction_reader): New class.
9847 (extract_arm_insn): Add argument 'reader'. Callers updated.
9848 (decode_insn): Likewise.
9849
34b43320
DE
98502017-03-16 Doug Evans <dje@google.com>
9851
a7c0469f
DE
9852 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
9853 member. Change type of TYPE member to SCM. All uses updated.
9854 (lsscm_make_lazy_string_smob): Add assert.
9855 (lsscm_make_lazy_string): Flag bad length values.
9856 (lsscm_elt_type): New function.
9857 (gdbscm_lazy_string_to_value): Rewrite to use
9858 lsscm_safe_lazy_string_to_value.
9859 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
9860 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
9861 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
9862 in incoming type.
9863 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9864 * guile/scm-type.c (tyscm_scm_to_type): New function.
9865
98662017-03-15 Doug Evans <dje@google.com>
9867
34b43320
DE
9868 PR python/17728, python/18439, python/18779
9869 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
9870 member. Change type of TYPE member to PyObject *. All uses updated.
9871 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
9872 (gdbpy_create_lazy_string_object): Flag bad length values.
9873 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
9874 Handle typedefs in incoming type.
9875 (stpy_lazy_string_elt_type): New function.
9876 (gdbpy_extract_lazy_string): Call it.
9877 * python/py-value.c (valpy_lazy_string): Flag bad length values.
9878 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
9879 typedefs in incoming type.
9880
a3a5fecc
DE
98812017-03-16 Doug Evans <dje@google.com>
9882
9883 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
9884 * guile/scm-type.c (tyscm_scm_to_type): New function.
9885
28f1c605
JW
98862017-03-16 Jiong Wang <jiong.wang@arm.com>
9887
9888 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
9889 "ULONGEST" for "skip".
9890
87c336f6
AA
98912017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9892
9893 PR gdb/21220
9894 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
9895 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
9896 (inf_ptrace_peek_poke): ...here. New function. Now also loop
9897 over ptrace peek/poke until end of buffer or error.
9898
cf81cf60
SM
98992017-03-14 Simon Marchi <simon.marchi@ericsson.com>
9900
9901 * parse.c (length_of_subexp): Make static.
9902 * parser-defs.h (length_of_subexp): Remove.
9903
a379284a
AA
99042017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
9905
9906 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
9907 as well.
9908
8a6200ba
PA
99092017-03-14 Pedro Alves <palves@redhat.com>
9910
9911 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
9912 (main): Use std::unique_ptr. Remove calls to
9913 cp_demangled_name_parse_free.
9914
f79ec206
SM
99152017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9916
9917 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
9918 alphabsd_store_inferior_registers): Use regcache->ptid instead
9919 of inferior_ptid.
9920
edb5fb00
SM
99212017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9922
9923 * aix-thread.c (aix_thread_fetch_registers,
9924 aix_thread_store_registers): Use regcache->ptid instead of
9925 inferior_ptid.
9926
55119686
SM
99272017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9928
9929 * aarch64-linux-nat.c (fetch_gregs_from_thread,
9930 store_gregs_to_thread, fetch_fpregs_from_thread,
9931 store_fpregs_to_thread): Use regcache->ptid instead of
9932 inferior_ptid.
9933
6a06fbb7
SM
99342017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9935
9936 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
9937 amd64_linux_fetch_inferior_registers): Use regcache->ptid
9938 instead of inferior_ptid.
9939
c6386875
SM
99402017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9941
9942 * target.c (target_fetch_registers, target_store_registers): Add
9943 assert.
9944
ddaaf0fb
SM
99452017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
9946
9947 * regcache.h (regcache_get_ptid): New function.
9948 * regcache.c (regcache_get_ptid): New function.
9949
b9da89d1 99502017-03-13 Mark Wielaard <mark@klomp.org>
9951
9952 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
9953
5f4d1085
KS
99542017-03-10 Keith Seitz <keiths@redhat.com>
9955
9956 PR c++/8218
9957 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
9958
c65d6b55
PA
99592017-03-08 Pedro Alves <palves@redhat.com>
9960
9961 PR gdb/18360
9962 * infrun.c (start_step_over, do_target_resume, resume)
9963 (restart_threads): Assert we're not resuming a thread that is
9964 meant to be stopped.
9965 (infrun_thread_stop_requested_callback): Delete.
9966 (infrun_thread_stop_requested): If the thread is internally
9967 stopped, queue a pending stop event and clear the thread's
9968 inline-frame state.
9969 (handle_stop_requested): New function.
9970 (handle_syscall_event, handle_inferior_event_1): Use
9971 handle_stop_requested.
9972 (handle_stop_requested): New function.
9973 (handle_signal_stop): Set the thread's stop_signal here instead of
9974 at caller.
9975 (finish_step_over): Clear step over info unconditionally.
9976 (handle_signal_stop): If the user had interrupted the event
9977 thread, consider the stop a random signal.
9978 (handle_signal_stop) <signal arrived while stepping over
9979 breakpoint>: Don't restart threads here.
9980 (stop_waiting): Don't clear step-over info here.
9981
15c22686
PA
99822017-03-08 Pedro Alves <palves@redhat.com>
9983
9984 PR 21206
9985 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
9986 goes to argument 2, not 1.
9987
6e5d74e7
PA
99882017-03-08 Pedro Alves <palves@redhat.com>
9989
9990 PR cli/21218
9991 * top.c (gdb_readline_wrapper): Avoid passing NULL to
9992 display_gdb_prompt.
9993 (command_line_input): Add comment.
9994
9753a2f6
PA
99952017-03-08 Pedro Alves <palves@redhat.com>
9996
9997 PR tui/21216
9998 * tui/tui-file.c (tui_file::write): New.
9999 * tui/tui-file.h (tui_file): Override "write".
10000 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
10001 factored out from ...
10002 (tui_puts): ... here.
10003 (tui_putc): Use them.
10004 (tui_write): New function.
10005 * tui/tui-io.h (tui_write): Declare.
10006
1672e0d9
SDJ
100072017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
10008
10009 * Makefile.in (SFILES): Replace "environ.c" with
10010 "common/environ.c".
10011 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
10012 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
10013 to...
10014 * common/environ.c: ... here.
10015 * environ.h: Moved to...
10016 * common/environ.h: ... here.
10017
f7bb4e3a
PB
100182017-03-07 Peter Bergner <bergner@vnet.ibm.com>
10019
10020 * gdbarch.sh (pstring_ptr): New static function.
10021 (gdbarch_disassembler_options): Use it.
10022 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
10023 not valid_disassembler_option->name.
10024 * gdbarch.c: Regenerate.
10025
e45ced6c
PB
100262017-03-07 Peter Bergner <bergner@vnet.ibm.com>
10027
10028 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
10029
5f6fd321
PA
100302017-03-07 Pedro Alves <palves@redhat.com>
10031
10032 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
10033
6dbb839a 100342017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
10035
10036 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
10037 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
10038 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 10039 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 10040
d274ecf4
SM
100412017-03-06 Simon Marchi <simon.marchi@ericsson.com>
10042
10043 * xtensa-linux-nat.c (fetch_gregs): Remove const.
10044
df97be55
SM
100452017-03-03 Simon Marchi <simon.marchi@ericsson.com>
10046
10047 * remote.c (remote_add_target_side_commands): Use range-based
10048 for loop.
10049
7d45f3df
YQ
100502017-03-03 Yao Qi <yao.qi@linaro.org>
10051
10052 PR gdb/21165
10053 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
10054 value is lazy.
10055 * valprint.c (common_val_print): Likewise.
10056
65b48a81
PB
100572017-02-28 Peter Bergner <bergner@vnet.ibm.com>
10058
10059 * NEWS: Mention new set/show disassembler-options commands.
10060 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
10061 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
10062 (prospective_options): New static variable.
10063 (gdb_disassembler::gdb_disassembler): Initialize
10064 m_di.disassembler_options.
10065 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
10066 (get_disassembler_options): New function.
10067 (set_disassembler_options): Likewise.
10068 (set_disassembler_options_sfunc): Likewise.
10069 (show_disassembler_options_sfunc): Likewise.
10070 (disassembler_options_completer): Likewise.
10071 (_initialize_disasm): Likewise.
10072 * disasm.h (get_disassembler_options): New prototype.
10073 (set_disassembler_options): Likewise.
10074 * gdbarch.sh (gdbarch_disassembler_options): New variable.
10075 (gdbarch_verify_disassembler_options): Likewise.
10076 * gdbarch.c: Regenerate.
10077 * gdbarch.h: Likewise.
10078 * arm-tdep.c (num_disassembly_options): Delete.
10079 (set_disassembly_style): Likewise.
10080 (arm_disassembler_options): New static variable.
10081 (set_disassembly_style_sfunc): Convert short style name into long
10082 option name. Call set_disassembler_options.
10083 (show_disassembly_style_sfunc): New function.
10084 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
10085 set_gdbarch_verify_disassembler_options.
10086 (_initialize_arm_tdep): Delete regnames variable and update callers.
10087 (arm_disassembler_options): Initialize.
10088 (disasm_options): New variable.
10089 (num_disassembly_options): Rename from this...
10090 (num_disassembly_styles): ...to this. Compute by scanning through
10091 disasm_options.
10092 (valid_disassembly_styles): Initialize using disasm_options.
10093 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
10094 set_arm_regname_option.
10095 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
10096 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
10097 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
10098 set_gdbarch_verify_disassembler_options.
10099 * s390-tdep.c (s390_disassembler_options): New static variable.
10100 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
10101 set_gdbarch_verify_disassembler_options.
10102
d538e36d
SM
101032017-02-27 Simon Marchi <simon.marchi@ericsson.com>
10104
10105 * remote.c (remote_add_target_side_condition): Remove "struct"
10106 keyword from range-based for loop.
10107
83621223
SM
101082017-02-27 Simon Marchi <simon.marchi@ericsson.com>
10109
10110 * remote.c (remote_add_target_side_condition): Use range-based
10111 for loop. Update comment.
10112
2123df0e
YQ
101132017-02-27 Yao Qi <yao.qi@linaro.org>
10114
10115 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
10116
8e368124
AH
101172017-02-26 Alan Hayward <alan.hayward@arm.com>
10118
10119 * regcache.c (regcache_raw_update): New function.
10120 (regcache_raw_read): Move code to regcache_raw_update.
10121 * regcache.h (regcache_raw_update): New declaration.
10122 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
10123
a49dd8dd
JK
101242017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
10125
10126 * dwarf2read.c (create_debug_type_hash_table): Initialize
10127 header.signature and header.type_offset_in_tu.
10128
34e4bae9
PA
101292017-02-24 Pedro Alves <palves@redhat.com>
10130
10131 * symtab.c (make_file_symbol_completion_list_1): Use
10132 add_symtab_completions.
10133
b0e4b369
AH
101342017-02-24 Alan Hayward <alan.hayward@arm.com>
10135
10136 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
10137
975c21ab
AH
101382017-02-24 Alan Hayward <alan.hayward@arm.com>
10139
10140 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
10141 I386_MAX_REGISTER_SIZE.
10142 (i386_pseudo_register_write): Likewise.
10143 (i386_process_record): Likewise.
10144 * i387-tdep.c (i387_supply_xsave): Likewise.
10145 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
10146 (store_register): Likewise.
10147
14bc53a8
PA
101482017-02-23 Pedro Alves <palves@redhat.com>
10149
10150 * ada-lang.c: Include "common/function-view.h".
10151 (ada_iterate_over_symbols): Adjust to use function_view as
10152 callback type.
10153 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
10154 (ada_make_symbol_completion_list): Use a lambda.
10155 (ada_exc_search_name_matches): Delete.
10156 (name_matches_regex): New.
10157 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
10158 * compile/compile-c-support.c: Include "common/function-view.h".
10159 (print_one_macro): Change prototype to accept a ui_file pointer.
10160 (write_macro_definitions): Use a lambda.
10161 * dwarf2read.c: Include "common/function-view.h".
10162 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
10163 (dw2_expand_symtabs_matching): Adjust to use function_view as
10164 callback type.
10165 * language.h: Include "common/function-view.h".
10166 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
10167 function_view as callback type.
10168 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
10169 * linespec.c: Include "common/function-view.h".
10170 (collect_info::add_symbol): New method.
10171 (struct symbol_and_data_callback, iterate_inline_only, struct
10172 symbol_matcher_data, iterate_name_matcher): Delete.
10173 (iterate_over_all_matching_symtabs): Adjust to use function_view
10174 as callback type and lambdas.
10175 (iterate_over_file_blocks): Adjust to use function_view as
10176 callback type.
10177 (decode_compound_collector): Now a class with private fields.
10178 (decode_compound_collector::release_symbols): New method.
10179 (collect_one_symbol): Rename to...
10180 (decode_compound_collector::operator()): ... this and adjust.
10181 (lookup_prefix_sym): decode_compound_collector construction bits
10182 move to decode_compound_collector ctor. Pass the
10183 decode_compound_collector object directly as callback. Remove
10184 cleanups and use decode_compound_collector::release_symbols
10185 instead.
10186 (symtab_collector): Now a class with private fields.
10187 (symtab_collector::release_symtabs): New method.
10188 (add_symtabs_to_list): Rename to...
10189 (symtab_collector::operator()): ... this and adjust.
10190 (collect_symtabs_from_filename): symtab_collector construction
10191 bits move to symtab_collector ctor. Pass the symtab_collector
10192 object directly as callback. Remove cleanups and use
10193 symtab_collector::release_symtabs instead.
10194 (collect_symbols): Delete.
10195 (add_matching_symbols_to_info): Use lambdas.
10196 * macrocmd.c (print_macro_callback): Delete.
10197 (info_macro_command): Use a lambda.
10198 (info_macros_command): Pass print_macro_definition as callable
10199 directly.
10200 (print_one_macro): Remove 'ignore' parameter.
10201 (macro_list_command): Adjust.
10202 * macrotab.c (macro_for_each_data::fn): Now a function_view.
10203 (macro_for_each_data::user_data): Delete field.
10204 (foreach_macro): Adjust to call the function_view.
10205 (macro_for_each): Adjust to use function_view as callback type.
10206 (foreach_macro_in_scope): Adjust to call the function_view.
10207 (macro_for_each_in_scope): Adjust to use function_view as callback
10208 type.
10209 * macrotab.h: Include "common/function-view.h".
10210 (macro_callback_fn): Declare a prototype instead of a pointer.
10211 Remove "user_data" parameter.
10212 (macro_for_each, macro_for_each_in_scope): Adjust to use
10213 function_view as callback type.
10214 * psymtab.c (partial_map_expand_apply)
10215 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
10216 Adjust to use function_view as callback type and to return bool.
10217 (psym_expand_symtabs_matching): Adjust to use function_view as
10218 callback types.
10219 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
10220 to use function_view as callback type and to return bool.
10221 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
10222 callback types.
10223 * symfile.c (expand_symtabs_matching): Adjust to use function_view
10224 as callback types.
10225 * symfile.h: Include "common/function-view.h".
10226 (expand_symtabs_file_matcher_ftype)
10227 (expand_symtabs_symbol_matcher_ftype)
10228 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
10229 return bool.
10230 (quick_symbol_functions::map_symtabs_matching_filename)
10231 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
10232 function_view as callback type and return bool.
10233 (expand_symtabs_matching): Adjust to use function_view as callback
10234 type.
10235 (maintenance_expand_name_matcher)
10236 (maintenance_expand_file_matcher): Delete.
10237 (maintenance_expand_symtabs): Use lambdas.
10238 * symtab.c (iterate_over_some_symtabs): Adjust to use
10239 function_view as callback types and return bool.
10240 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
10241 of a cleanup.
10242 (lookup_symtab_callback): Delete.
10243 (lookup_symtab): Use a lambda.
10244 (iterate_over_symbols): Adjust to use function_view as callback
10245 type.
10246 (struct search_symbols_data, search_symbols_file_matches)
10247 (search_symbols_name_matches): Delete.
10248 (search_symbols): Use a pair of lambdas.
10249 (struct add_name_data, add_macro_name, symbol_completion_matcher)
10250 (symtab_expansion_callback): Delete.
10251 (default_make_symbol_completion_list_break_on_1): Use lambdas.
10252 * symtab.h: Include "common/function-view.h".
10253 (iterate_over_some_symtabs): Adjust to use function_view as
10254 callback type and return bool.
10255 (iterate_over_symtabs): Adjust to use function_view as callback
10256 type.
10257 (symbol_found_callback_ftype): Remove 'data' parameter and return
10258 bool.
10259 (iterate_over_symbols): Adjust to use function_view as callback
10260 type.
10261
07e253aa
PA
102622017-02-23 Pedro Alves <palves@redhat.com>
10263
10264 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
10265 (%.o) <unittests/%.c>: New pattern.
10266 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
10267 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
10268 * common/function-view.h: New file.
10269 * unittests/function-view-selftests.c: New file.
10270 * configure: Regenerate.
10271
8eaf5320
SM
102722017-02-23 Simon Marchi <simon.marchi@ericsson.com>
10273
10274 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
10275 inferior_ptid.
10276 * go32-nat.c (go32_thread_alive): Likewise.
10277
38768751
YQ
102782017-02-23 Yao Qi <yao.qi@linaro.org>
10279
10280 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
10281 delete.
10282
0a8beaba
YQ
102832017-02-23 Yao Qi <yao.qi@linaro.org>
10284
10285 * varobj.c (varobj_clear_saved_item): Use delete instead of
10286 xfree.
10287 (update_dynamic_varobj_children): Likewise.
10288
58fdfd2c
JK
102892017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10290
10291 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
10292
1b90b139
SM
102932017-02-21 Simon Marchi <simon.marchi@ericsson.com>
10294
10295 * common/enum-flags.h (enum_flags::enum_flags): Initialize
10296 m_enum_value to 0 in default constructor.
10297
2039d74e
EBM
102982017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
10299
10300 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
10301 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
10302 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
10303 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
10304 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
10305 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
10306 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
10307 IS_STORE_CONDITIONAL_INSN.
10308
7814882a
JK
103092017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
10310
10311 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
10312
0ae60b63
JK
103132017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10314
10315 * NEWS (Changes since GDB 7.12): Add DWARF-5.
10316
0224619f
JK
103172017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10318
10319 * dwarf2read.c (skip_one_die, read_attribute_value)
10320 (dwarf2_const_value_attr, dump_die_shallow)
10321 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
10322 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
10323
0af92d60
JK
103242017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10325
10326 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
10327 (dwarf_parse_macro_header): Accept DWARF version 5.
10328 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
10329
216f72a1
JK
103302017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10331
10332 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
10333 DW_AT_GNU_*.
10334 * common/common-exceptions.h (enum errors): Likewise.
10335 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
10336 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
10337 (dwarf_expr_context::execute_stack_op): Likewise.
10338 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
10339 Likewise.
10340 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
10341 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
10342 (show_entry_values_debug, call_site_to_target_addr)
10343 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
10344 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
10345 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
10346 (value_of_dwarf_block_entry, indirect_pieced_value)
10347 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
10348 (disassemble_dwarf_expression): Likewise.
10349 * dwarf2read.c (process_die, inherit_abstract_dies)
10350 (read_call_site_scope): Likewise.
10351 * gdbtypes.h (struct func_type, struct call_site_parameter)
10352 (struct call_site): Likewise.
10353 * stack.c (read_frame_arg): Likewise.
10354 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
10355
43988095
JK
103562017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10357
10358 * defs.h (read_unsigned_leb128): New declaration.
10359 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
10360 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
10361 (dwarf2_find_location_expression): Call also
10362 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
10363 * dwarf2loc.h (dwarf2_version): New declaration.
10364 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
10365 rnglists.
10366 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
10367 .debug_rnglists.
10368 (struct dwop_section_names): Add loclists_dwo.
10369 (dwop_section_names): Add .debug_loclists.dwo.
10370 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
10371 (struct dwarf2_per_cu_data): Add dwarf_version.
10372 (struct dwo_sections): Add loclists.
10373 (struct attr_abbrev): Add implicit_const.
10374 (read_indirect_line_string): New declaration.
10375 (read_unsigned_leb128): Delete declaration.
10376 (rcuh_kind): New definition.
10377 (read_and_check_comp_unit_head): Change parameter
10378 is_debug_types_section to section_kind.
10379 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
10380 (read_comp_unit_head): Change parameter abfd to section, add parameter
10381 section_kind. Handle DWARF-5.
10382 (error_check_comp_unit_head): Accept also DWARF version 5.
10383 (read_and_check_comp_unit_head): Change parameter
10384 is_debug_types_section to section_kind.
10385 (read_and_check_type_unit_head): Delete function.
10386 (read_abbrev_offset): Handle DWARF-5.
10387 (create_debug_type_hash_table): Add parameter section_kind. Process
10388 only DW_UT_type. Use signature and type_offset_in_tu from struct
10389 comp_unit_head.
10390 (create_debug_types_hash_table): Update create_debug_type_hash_table
10391 caller.
10392 (create_all_type_units): Call create_debug_type_hash_table.
10393 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
10394 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
10395 caller.
10396 (skip_one_die): Handle DW_FORM_implicit_const.
10397 (dwarf2_rnglists_process): New function.
10398 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
10399 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
10400 (read_attribute_value): Handle DW_FORM_implicit_const,
10401 DW_FORM_line_strp.
10402 (read_attribute): Handle DW_FORM_implicit_const.
10403 (read_indirect_string_at_offset_from): New function from
10404 read_indirect_string_at_offset.
10405 (read_indirect_string_at_offset): Call
10406 read_indirect_string_at_offset_from.
10407 (read_indirect_line_string_at_offset): New function.
10408 (read_indirect_string): New function comment.
10409 (read_indirect_line_string): New function.
10410 (read_unsigned_leb128): Make it global.
10411 (dwarf2_string_attr): Handle DWARF-5.
10412 (add_include_dir_stub, read_formatted_entries): New functions.
10413 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
10414 Handle DWARF-5.
10415 (per_cu_header_read_in): Update read_comp_unit_head caller.
10416 (dwarf2_version): New function.
10417 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
10418 rnglists.
10419 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
10420 fields.
10421
22d2f3ab
JK
104222017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10423
10424 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
10425
5f46c5a5
JK
104262017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10427
10428 * dwarf2read.c (dwarf2_ranges_process): New function from
10429 dwarf2_ranges_read.
10430 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
10431 dwarf2_ranges_process.
10432
78d4d2c5
JK
104332017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10434
10435 * dwarf2read.c (create_debug_type_hash_table): New function from
10436 create_debug_types_hash_table.
10437 (create_debug_types_hash_table): Call create_debug_type_hash_table.
10438 (create_all_type_units, open_and_init_dwo_file): Update
10439 create_debug_types_hash_table callers.
10440
1b076f25
SDJ
104412017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10442
10443 PR gdb/16188
10444 * fork-child.c (trace_start_error): Fix thinko. va_end should
10445 refer to 'ap', not 'args'.
10446
0db8980c
SDJ
104472017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
10448 Pedro Alves <palves@redhat.com>
10449
10450 PR gdb/16188
10451 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
10452 calls succeeded.
10453 * fork-child.c (trace_start_error): New function.
10454 (trace_start_error_with_name): Likewise.
10455 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
10456 * inf-ptrace.c (inf_ptrace_me): Likewise.
10457 * inferior.h (trace_start_error): New prototype.
10458 (trace_start_error_with_name): Likewise.
10459
99e8a4f9
SDJ
104602017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
10461
10462 PR gdb/21164
10463 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
10464 NULL before using it.
10465 * symmisc.c (maintenance_print_symbols): Likewise.
10466 (maintenance_print_msymbols): Likewise.
10467
4e746bb6
TW
104682017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10469
10470 * NEWS: Add record Python bindings entry.
10471
104722017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10473
10474 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
10475 py-record-full.o.
10476 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
10477 * python/py-record-btrace.c, python/py-record-btrace.h,
10478 python/py-record-full.c, python/py-record-full.h: New file.
10479 * python/py-record.c: Add include for py-record-btrace.h and
10480 py-record-full.h.
10481 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
10482 recpy_instruction_history, recpy_function_call_history, recpy_begin,
10483 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
10484 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
10485 New definition.
10486 (gdbpy_initialize_btrace): New export.
10487 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
10488
104892017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10490
10491 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
10492 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
10493 * python/py-record.c: New file.
10494 * python/python-internal.h (gdbpy_start_recording,
10495 gdbpy_current_recording, gdpy_stop_recording,
10496 gdbpy_initialize_record): New export.
10497 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
10498 (python_GdbMethods): Add gdbpy_start_recording,
10499 gdbpy_current_recording and gdbpy_stop_recording.
10500
105012017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10502
10503 * record-btrace.c (record_btrace_record_method): New function.
10504 (init_record_btrace_ops): Initialize to_record_method.
10505 * record-full.c (record_full_record_method): New function.
10506 (init_record_full_ops, init_record_full_core_ops): Add
10507 record_full_record_method.
10508 * record.h (enum record_method): New enum.
10509 * target-debug.h (target_debug_print_enum_record_method: New define.
10510 * target-delegates.c: Regenerate.
10511 * target.c (target_record_method): New function.
10512 * target.h: Include record.h.
10513 (struct target_ops) <to_record_method>: New field.
10514 (target_record_method): New export.
10515
105162017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10517
10518 * record.h (record_start, record_stop): New export.
10519 * record.c (record_start, record_stop): New function.
10520
105212017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10522
10523 * btrace.c (btrace_fetch): Copy function call segments pointer
10524 into a vector.
10525 (btrace_clear): Clear the vector.
10526 (btrace_find_insn_by_number): Use binary search to find the correct
10527 function call segment.
10528 * btrace.h (brace_fun_p): New typedef.
10529 (struct btrace_thread_info) <functions>: New field.
10530
105312017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10532
10533 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
10534 * btrace.c (btrace_decode_error): ... here. New function.
10535 * btrace.h (btrace_decode_error): New export.
10536
105372017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
10538
10539 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
10540 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
10541 btrace_find_insn_by_number): Remove special case for gaps.
10542 * btrace.h (btrace_insn_get_error): New export.
10543 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
10544 * record-btrace.c (btrace_insn_history): Print number for gaps.
10545 (record_btrace_info, record_btrace_goto): Handle gaps.
10546
3f77c769
TT
105472017-02-14 Tom Tromey <tom@tromey.com>
10548
10549 PR python/13598:
10550 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
10551 event.
10552 * python/py-evts.c (gdbpy_initialize_py_events): Add
10553 before_prompt registry.
10554 * python/py-events.h (events_object) <before_prompt>: New field.
10555
4c2c7ac6
MM
105562017-02-14 Markus Metzger <markus.t.metzger@intel.com>
10557
10558 * btrace.c (ftrace_new_switch): Preserve up link and flags.
10559
5cf30ebf
LM
105602017-02-13 Luis Machado <lgustavo@codesourcery.com>
10561
10562 * symfile (_initialize_symfile): Add usage text to the load command's
10563 help text.
10564
26a06916
SM
105652017-02-10 Simon Marchi <simon.marchi@ericsson.com>
10566
10567 * utils.c (defaulted_query): Don't query on secondary UIs.
10568
0b145e37
TT
105692017-02-10 Tom Tromey <tom@tromey.com>
10570
10571 * rust-lang.c (rust_get_disr_info): Remove unused variable.
10572
2d8365c4
TT
105732017-02-10 Tom Tromey <tom@tromey.com>
10574
10575 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
10576 "cleanup" local.
10577 * python/py-type.c (typy_legacy_template_argument): Remove
10578 unnecessary "cleanup" local.
10579
2bb8f231
TT
105802017-02-10 Tom Tromey <tom@tromey.com>
10581
10582 * python/python.c (do_start_initialization): New function, from
10583 _initialize_python.
10584 (_initialize_python): Call do_start_initialization.
10585 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
10586 goto.
10587
1bdfaf42
TT
105882017-02-10 Tom Tromey <tom@tromey.com>
10589
10590 * python/py-prettyprint.c (pretty_print_one_value): Use
10591 gdbpy_ref.
10592
88b6faea
TT
105932017-02-10 Tom Tromey <tom@tromey.com>
10594
10595 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
10596 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
10597 gdbpy_ref.
10598 * python/py-type.c (field_new): Use gdbpy_ref.
10599 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
10600 gdbpy_ref.
10601 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
10602 (py_free_pspace): Likewise.
10603 (pspace_to_pspace_object): Likewise.
10604 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
10605 (py_free_objfile): Likewise.
10606 (objfile_to_objfile_object): Likewise.
10607 * python/py-inferior.c (delete_thread_object): Use
10608 gdbpy_ref.
10609 (infpy_read_memory): Likewise.
10610 (py_free_inferior): Likewise.
10611 * python/py-evtregistry.c (create_eventregistry_object): Use
10612 gdbpy_ref.
10613 * python/py-event.c (create_event_object): Use gdbpy_ref.
10614
7780f186
TT
106152017-02-10 Tom Tromey <tom@tromey.com>
10616
10617 * python/py-ref.h (gdbpy_ref_policy): Now a template.
10618 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
10619 used.
10620 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
10621 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
10622 python/py-exitedevent.c, python/py-finishbreakpoint.c,
10623 python/py-framefilter.c, python/py-function.c,
10624 python/py-inferior.c, python/py-infevents.c,
10625 python/py-linetable.c, python/py-newobjfileevent.c,
10626 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
10627 python/py-signalevent.c, python/py-stopevent.c,
10628 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
10629 python/py-unwind.c, python/py-utils.c, python/py-value.c,
10630 python/py-varobj.c, python/py-xmethods.c, python/python.c,
10631 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
10632
d4b0bb18
TT
106332017-02-10 Tom Tromey <tom@tromey.com>
10634
10635 * ui-out.h (ui_out_emit_type): New class.
10636 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
10637 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
10638 and ui_out_emit_tuple.
10639 (enumerate_locals): Likewise.
10640 (py_mi_print_variables, py_print_locals, py_print_args): Use
10641 ui_out_emit_list.
10642 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
10643 ui_out_emit_list.
10644 * common/gdb_optional.h: New file.
10645
f67f945c
MG
106462017-02-10 Martin Galvan <martingalvan@sourceware.org>
10647
10648 * MAINTAINERS (Write After Approval): Update my e-mail address.
10649
18da0c51
MG
106502017-02-10 Martin Galvan <martingalvan@sourceware.org>
10651
10652 PR gdb/21122
10653 * breakpoint.c (_initialize_breakpoint): Update the help description
10654 of the 'commands' command to indicate that it takes a list argument.
10655
62c14536
SM
106562017-02-09 Simon Marchi <simon.marchi@ericsson.com>
10657
10658 * interps.c (current_interp_set_logging): Remove "return".
10659
ff6fa247
GB
106602017-02-09 Gary Benson <gbenson@redhat.com>
10661
10662 * symtab.c (add_symtab_completions): Prevent NULL pointer
10663 dereference.
10664
a474bd8e
PA
106652017-02-08 Pedro Alves <palves@redhat.com>
10666
10667 * interps.c (interp::interp): Remove reference to quiet_p.
10668 (interp_set): Make static. Remove dead "Switching to" output
10669 code.
10670 (interp_quiet_p, interp_set_quiet): Delete.
10671 (interpreter_exec_cmd): Don't set the interpreter quiet.
10672 * interps.h (interp_quiet_p): Make static.
10673 (class interp) <quiet_p>: Remove field
10674
3d7b173c
JG
106752017-02-08 Jerome Guitton <guitton@adacore.com>
10676
604c4576
JG
10677 * cli/cli-decode.c (find_command_name_length): Make it extern.
10678 * cli/cli-decode.h (find_command_name_length): Declare.
10679 * cli/cli-script.c (command_name_equals, line_first_arg):
10680 New functions.
10681 (process_next_line): Use cli-decode to parse command names.
10682 (build_command_line): Make args a constant pointer.
10683
106842017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 10685
3d7b173c
JG
10686 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
10687 Remove case-insensitive search.
10688
1291063d
JM
106892017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
10690
10691 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
10692 at the end of the line. Avoids an ARI warning.
10693
20b477a7
LM
106942017-02-06 Luis Machado <lgustavo@codesourcery.com>
10695
10696 * NEWS: Mention support for record/replay of Intel 64 rdrand and
10697 rdseed instructions.
10698 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
10699
3f7b46f2
IR
107002017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
10701
10702 PR tdep/20936
10703 Provide and use sparc32 and sparc64 target description XML files.
10704 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
10705 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
10706 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
10707 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
10708 * features/sparc/sparc32-solaris.xml: New file.
10709 * features/sparc/sparc64-solaris.xml: New file.
10710 * features/sparc/sparc32-solaris.c: Generated.
10711 * features/sparc/sparc64-solaris.c: Generated.
10712 * sparc-tdep.h: Account for differences in target descriptions.
10713 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
10714 (sparc32_register_type): Use target provided registers.
10715 (validate_tdesc_registers): New function.
10716 (sparc32_gdbarch_init): Use tdesc_has_registers.
10717 Set pseudoregister functions.
10718 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
10719 (sparc64_register_type): Use target provided registers.
10720 (sparc64_init_abi): Set pseudoregister functions.
10721
f0fd41c1
TT
107222017-02-03 Tom Tromey <tom@tromey.com>
10723
10724 PR rust/21097:
10725 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
10726 with a single member.
10727
d6f9b0fb
PA
107282017-02-03 Pedro Alves <palves@redhat.com>
10729
10730 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
10731 (cli_interp_base::~cli_interp_base): New.
10732 (cli_interp): New struct.
10733 (as_cli_interp): Cast the interp itself to cli_interp.
10734 (cli_interpreter_pre_command_loop): Rename to ...
10735 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
10736 parameter.
10737 (cli_interpreter_init): Rename to ...
10738 (cli_interp::init): ... this. Remove 'self' parameter. Use
10739 boolean. Make extern.
10740 (cli_interpreter_resume): Rename to ...
10741 (cli_interp::resume): ... this. Remove 'data' parameter. Make
10742 extern.
10743 (cli_interpreter_suspend): Rename to ...
10744 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
10745 extern.
10746 (cli_interpreter_exec): Rename to ...
10747 (cli_interp::exec): ... this. Remove 'data' parameter. Make
10748 extern.
10749 (cli_interpreter_supports_command_editing): Rename to ...
10750 (cli_interp_base::supports_command_editing): ... this. Remove
10751 'interp' parameter. Make extern.
10752 (cli_ui_out): Rename to ...
10753 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
10754 Make extern.
10755 (cli_set_logging): Rename to ...
10756 (cli_interp_base::set_logging): ... this. Remove 'interp'
10757 parameter. Make extern.
10758 (cli_interp_procs): Delete.
10759 (cli_interp_factory): Adjust to use "new".
10760 * cli/cli-interp.h: Include "interps.h".
10761 (struct cli_interp_base): New struct.
10762 * interps.c (struct interp): Delete. Fields moved to interps.h.
10763 (interp_new): Delete.
10764 (interp::interp, interp::~interp): New.
10765 (interp_set): Use bool, and return void. Assume the interpreter
10766 has suspend, init and resume methods, and that the all return
10767 void.
10768 (set_top_level_interpreter): interp_set returns void.
10769 (interp_ui_out): Adapt.
10770 (current_interp_set_logging): Adapt.
10771 (interp_data): Delete.
10772 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
10773 (interp_exec): Adapt.
10774 (top_level_interpreter_data): Delete.
10775 * interps.h (interp_init_ftype, interp_resume_ftype)
10776 (interp_suspend_ftype, interp_exec_ftype)
10777 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
10778 (class interp): New.
10779 (interp_new): Delete.
10780 (interp_set): Now returns void. Use bool.
10781 (interp_data, top_level_interpreter_data): Delete.
10782 * mi/mi-common.h: Include interps.h.
10783 (class mi_interp): Inherit from interp. Define a ctor. Declare
10784 init, resume, suspect, exec, interp_ui_out, set_logging and
10785 pre_command_loop methods.
10786 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
10787 (mi_interpreter_init): Rename to ...
10788 (mi_interp::init): ... this. Remove the 'interp' parameter, use
10789 bool, return void and make extern. Adjust.
10790 (mi_interpreter_resume): ... Rename to ...
10791 (mi_interp::resume): ... this. Remove the 'data' parameter,
10792 return void and make extern. Adjust.
10793 (mi_interpreter_suspend): ... Rename to ...
10794 (mi_interp::suspend): ... this. Remove the 'data' parameter,
10795 return void and make extern. Adjust.
10796 (mi_interpreter_exec): ... Rename to ...
10797 (mi_interp::exec): ... this. Remove the 'data' parameter and make
10798 extern. Adjust.
10799 (mi_interpreter_pre_command_loop): ... Rename to ...
10800 (mi_interp::pre_command_loop): ... this. Remove the 'self'
10801 parameter and make extern.
10802 (mi_on_normal_stop_1): Adjust.
10803 (mi_ui_out): Rename to ...
10804 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
10805 parameter and make extern. Adjust.
10806 (mi_set_logging): Rename to ...
10807 (mi_interp::set_logging): ... this. Remove the 'interp'
10808 parameter and make extern. Adjust.
10809 (mi_interp_procs): Delete.
10810 (mi_interp_factory): Adjust to use 'new'.
10811 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
10812 (mi_print_exception, mi_execute_command, mi_load_progress):
10813 Adjust.
10814 * tui/tui-interp.c (tui_interp): New class.
10815 (as_tui_interp): Return a tui_interp pointer.
10816 (tui_on_normal_stop, tui_on_signal_received)
10817 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
10818 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
10819 to use interp::interp_ui_out.
10820 (tui_init): Rename to ...
10821 (tui_interp::init): ... this. Remove the 'self' parameter, use
10822 bool, return void and make extern. Adjust.
10823 (tui_resume): Rename to ...
10824 (tui_interp::resume): ... this. Remove the 'data' parameter,
10825 return void and make extern. Adjust.
10826 (tui_suspend): Rename to ...
10827 (tui_interp::suspend): ... this. Remove the 'data' parameter,
10828 return void and make extern. Adjust.
10829 (tui_ui_out): Rename to ...
10830 (tui_interp::interp_ui_out): ... this. Remove the 'self'
10831 parameter, and make extern. Adjust.
10832 (tui_exec): Rename to ...
10833 (tui_interp::exec): ... this. Remove the 'data' parameter and
10834 make extern.
10835 (tui_interp_procs): Delete.
10836 (tui_interp_factory): Use "new".
10837
65c40c95
TT
108382017-02-02 Tom Tromey <tom@tromey.com>
10839
10840 * rust-exp.y (ends_raw_string, space_then_number)
10841 (rust_identifier_start_p): Return bool.
10842 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
10843 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
10844 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
10845 (rust_chartype_p): Return bool.
10846 (val_print_struct, rust_print_struct_def, rust_print_type):
10847 Update.
10848 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
10849 Return bool.
10850
b50f188d
TT
108512017-02-02 Tom Tromey <tom@tromey.com>
10852
10853 * rust-lang.c: Reindent.
10854
03c85b11
TT
108552017-02-02 Tom Tromey <tom@tromey.com>
10856
10857 * rust-lang.h (rust_crate_for_block): Update.
10858 * rust-lang.c (rust_crate_for_block): Return std::string.
10859 (rust_get_disr_info): Use std:;string, not
10860 gdb::unique_xmalloc_ptr.
10861 * rust-exp.y (crate_name): Update.
10862
9b6da501
PA
108632017-02-02 Pedro Alves <palves@redhat.com>
10864
10865 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
10866 field out of gdb_disassembler_test and make it static.
10867
ec4cb20b
PA
108682017-02-02 Pedro Alves <palves@redhat.com>
10869
10870 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
10871 mi1_interp and mi_interp fields.
10872
5be5dbf0
PA
108732017-02-02 Pedro Alves <palves@redhat.com>
10874
616268b6
PA
10875 * cli/cli-interp.c (struct saved_output_files, saved_output):
10876 Moved from cli/cli-logging.c.
10877 (cli_set_logging): New function.
10878 (cli_interp_procs): Install cli_set_logging.
10879 * cli/cli-interp.h (make_logging_output, cli_set_logging):
10880 Declare.
10881 * cli/cli-logging.c (struct saved_output_files, saved_output):
10882 Moved to cli/cli-interp.c.
10883 (pop_output_files): Don't save outputs here.
10884 (make_logging_output): New function.
10885 (handle_redirections): Don't build tee nor save previous outputs
10886 here.
10887 * interps.c (current_interp_set_logging): Change prototype.
10888 Assume there's always a set_logging_proc method installed.
10889 * interps.h (interp_set_logging_ftype): Change prototype.
10890 (current_interp_set_logging): Change prototype and adjust comment.
10891 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
10892 use make_logging_output.
10893 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
108942017-02-02 Pedro Alves <palves@redhat.com>
10895
5be5dbf0
PA
10896 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
10897 from ...
10898 (set_logging_overwrite): ... here.
10899 (logging_no_redirect_file): Delete.
10900 (set_logging_redirect): Don't handle redirection on the fly.
10901 Instead warn that "logging off" / "logging on" is necessary.
10902 (pop_output_files): Delete references to logging_no_redirect_file.
10903 (show_logging_command): Always speak in terms of what will happen
10904 once logging is reenabled.
10905
c99cc448
PA
109062017-02-02 Pedro Alves <palves@redhat.com>
10907
10908 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
10909
8b172ce7
PA
109102017-02-02 Pedro Alves <palves@redhat.com>
10911
10912 * disasm.c (gdb_pretty_print_insn): Rename to ...
10913 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
10914 Remove gdbarch parameter. Adapt to clear the object's buffers
10915 instead of allocating new buffers, and to print using the object's
10916 gdb_disassembler instead of calling gdb_print_insn.
10917 (dump_insns): Use gdb_pretty_print_disassembler.
10918 * disasm.h (gdb_pretty_print_insn): Delete declaration.
10919 (gdb_pretty_print_disassembler): New class.
10920 * record-btrace.c (btrace_insn_history): Use
10921 gdb_pretty_print_disassembler.
10922
d7e74731
PA
109232017-02-02 Pedro Alves <palves@redhat.com>
10924
10925 * ada-lang.c (type_as_string): Use string_file.
10926 * ada-valprint.c (ada_print_floating): Use string_file.
10927 * ada-varobj.c (ada_varobj_scalar_image)
10928 (ada_varobj_get_value_image): Use string_file.
10929 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
10930 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
10931 * breakpoint.c (update_inserted_breakpoint_locations)
10932 (insert_breakpoint_locations, reattach_breakpoints)
10933 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
10934 (print_it_watchpoint): Use string_file.
10935 (save_breakpoints): Use stdio_file.
10936 * c-exp.y (oper): Use string_file.
10937 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
10938 tee_file.
10939 (pop_output_files): Use delete.
10940 (handle_redirections): Use stdio_file and tee_file.
10941 * cli/cli-setshow.c (do_show_command): Use string_file.
10942 * compile/compile-c-support.c (c_compute_program): Use
10943 string_file.
10944 * compile/compile-c-symbols.c (generate_vla_size): Take a
10945 'string_file &' instead of a 'ui_file *'.
10946 (generate_c_for_for_one_variable): Take a 'string_file &' instead
10947 of a 'ui_file *'. Use string_file.
10948 (generate_c_for_variable_locations): Take a 'string_file &'
10949 instead of a 'ui_file *'.
10950 * compile/compile-internal.h (generate_c_for_for_one_variable):
10951 Take a 'string_file &' instead of a 'ui_file *'.
10952 * compile/compile-loc2c.c (push, pushf, unary, binary)
10953 (print_label, pushf_register_address, pushf_register)
10954 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
10955 'ui_file *'. Adjust.
10956 * compile/compile.c (compile_to_object): Use string_file.
10957 * compile/compile.h (compile_dwarf_expr_to_c)
10958 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
10959 'ui_file *'.
10960 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
10961 (replace_typedefs_qualified_name): Use string_file and
10962 obstack_copy0.
10963 * disasm.c (gdb_pretty_print_insn): Use string_file.
10964 (gdb_disassembly): Adjust reference the null_stream global.
10965 (do_ui_file_delete): Delete.
10966 (gdb_insn_length): Use null_stream.
10967 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
10968 * dwarf2loc.c (dwarf2_compile_property_to_c)
10969 (locexpr_generate_c_location, loclist_generate_c_location): Take a
10970 'string_file &' instead of a 'ui_file *'.
10971 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
10972 * dwarf2read.c (do_ui_file_peek_last): Delete.
10973 (dwarf2_compute_name): Use string_file.
10974 * event-top.c (gdb_setup_readline): Use stdio_file.
10975 * gdbarch.sh (verify_gdbarch): Use string_file.
10976 * gdbtypes.c (safe_parse_type): Use null_stream.
10977 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
10978 string_file.
10979 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
10980 'string_file *' instead of a 'ui_file *'.
10981 (gdbscm_arch_disassemble): Use string_file.
10982 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
10983 * guile/scm-ports.c (class ioscm_file_port): Now a class that
10984 inherits from ui_file.
10985 (ioscm_file_port_delete, ioscm_file_port_rewind)
10986 (ioscm_file_port_put): Delete.
10987 (ioscm_file_port_write): Rename to ...
10988 (ioscm_file_port::write): ... this. Remove file_port_magic
10989 checks.
10990 (ioscm_file_port_new): Delete.
10991 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
10992 ui_file_up.
10993 * guile/scm-type.c (tyscm_type_name): Use string_file.
10994 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
10995 Use string_file.
10996 * infcmd.c (print_return_value_1): Use string_file.
10997 * infrun.c (print_target_wait_results): Use string_file.
10998 * language.c (add_language): Use string_file.
10999 * location.c (explicit_to_string_internal): Use string_file.
11000 * main.c (captured_main_1): Use null_file.
11001 * maint.c (maintenance_print_architecture): Use stdio_file.
11002 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
11003 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
11004 event_channel>: Change type to mi_console_file pointer.
11005 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
11006 (mi_console_file_delete): Delete.
11007 (struct mi_console_file): Delete.
11008 (mi_console_file_magic): Delete.
11009 (mi_console_file_new): Delete.
11010 (mi_console_file::mi_console_file): New.
11011 (mi_console_file_delete): Delete.
11012 (mi_console_file_fputs): Delete.
11013 (mi_console_file::write): New.
11014 (mi_console_raw_packet): Delete.
11015 (mi_console_file::flush): New.
11016 (mi_console_file_flush): Delete.
11017 (mi_console_set_raw): Rename to ...
11018 (mi_console_file::set_raw): ... this.
11019 * mi/mi-console.h (class mi_console_file): New class.
11020 (mi_console_file_new, mi_console_set_raw): Delete.
11021 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
11022 (mi_set_logging): Use delete and tee_file. Adjust.
11023 * mi/mi-main.c (output_register): Use string_file.
11024 (mi_cmd_data_evaluate_expression): Use string_file.
11025 (mi_cmd_data_read_memory): Use string_file.
11026 (mi_cmd_execute, print_variable_or_computed): Use string_file.
11027 * mi/mi-out.c (mi_ui_out::main_stream): New.
11028 (mi_ui_out::rewind): Use main_stream and
11029 string_file.
11030 (mi_ui_out::put): Use main_stream and string_file.
11031 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
11032 Allocate a 'string_file' instead.
11033 (mi_out_new): Don't allocate a mem_fileopen stream here.
11034 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
11035 (mi_ui_out::main_stream): Declare method.
11036 * printcmd.c (eval_command): Use string_file.
11037 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
11038 * python/py-arch.c (archpy_disassemble): Use string_file.
11039 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
11040 * python/py-frame.c (frapy_str): Use string_file.
11041 * python/py-framefilter.c (py_print_type, py_print_single_arg):
11042 Use string_file.
11043 * python/py-type.c (typy_str): Use string_file.
11044 * python/py-unwind.c (unwind_infopy_str): Use string_file.
11045 * python/py-value.c (valpy_str): Use string_file.
11046 * record-btrace.c (btrace_insn_history): Use string_file.
11047 * regcache.c (regcache_print): Use stdio_file.
11048 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
11049 * remote.c (escape_buffer): Use string_file.
11050 * rust-lang.c (rust_get_disr_info): Use string_file.
11051 * serial.c (serial_open_ops_1): Use stdio_file.
11052 (do_serial_close): Use delete.
11053 * stack.c (print_frame_arg): Use string_file.
11054 (print_frame_args): Remove local mem_fileopen stream, not used.
11055 (print_frame): Use string_file.
11056 * symmisc.c (maintenance_print_symbols): Use stdio_file.
11057 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
11058 Take a 'string_file *' instead of a 'ui_file *'.
11059 * top.c (new_ui): Use stdio_file and stderr_file.
11060 (free_ui): Use delete.
11061 (execute_command_to_string): Use string_file.
11062 (quit_confirm): Use string_file.
11063 * tracepoint.c (collection_list::append_exp): Use string_file.
11064 * tui/tui-disasm.c (tui_disassemble): Use string_file.
11065 * tui/tui-file.c: Don't include "ui-file.h".
11066 (enum streamtype, struct tui_stream): Delete.
11067 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
11068 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
11069 (tui_file::tui_file): New method.
11070 (tui_file_fputs): Delete.
11071 (tui_file_get_strbuf): Delete.
11072 (tui_file::puts): New method.
11073 (tui_file_adjust_strbuf): Delete.
11074 (tui_file_flush): Delete.
11075 (tui_file::flush): New method.
11076 * tui/tui-file.h: Tweak intro comment.
11077 Include ui-file.h.
11078 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
11079 (tui_file_adjust_strbuf): Delete declarations.
11080 (class tui_file): New class.
11081 * tui/tui-io.c (tui_initialize_io): Use tui_file.
11082 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
11083 (tui_register_format): Use string_stream.
11084 * tui/tui-stack.c (tui_make_status_line): Use string_file.
11085 (tui_get_function_from_frame): Use string_file.
11086 * typeprint.c (type_to_string): Use string_file.
11087 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
11088 (null_stream): New global.
11089 (ui_file_delete): Delete.
11090 (ui_file::ui_file): New.
11091 (null_file_isatty): Delete.
11092 (ui_file::~ui_file): New.
11093 (null_file_rewind): Delete.
11094 (ui_file::printf): New.
11095 (null_file_put): Delete.
11096 (null_file_flush): Delete.
11097 (ui_file::putstr): New.
11098 (null_file_write): Delete.
11099 (ui_file::putstrn): New.
11100 (null_file_read): Delete.
11101 (ui_file::putc): New.
11102 (null_file_fputs): Delete.
11103 (null_file_write_async_safe): Delete.
11104 (ui_file::vprintf): New.
11105 (null_file_delete): Delete.
11106 (null_file::write): New.
11107 (null_file_fseek): Delete.
11108 (null_file::puts): New.
11109 (ui_file_data): Delete.
11110 (null_file::write_async_safe): New.
11111 (gdb_flush, ui_file_isatty): Adjust.
11112 (ui_file_put, ui_file_rewind): Delete.
11113 (ui_file_write): Adjust.
11114 (ui_file_write_for_put): Delete.
11115 (ui_file_write_async_safe, ui_file_read): Adjust.
11116 (ui_file_fseek): Delete.
11117 (fputs_unfiltered): Adjust.
11118 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
11119 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
11120 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
11121 (set_ui_file_data): Delete.
11122 (string_file::~string_file, string_file::write)
11123 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
11124 (do_ui_file_as_string, ui_file_as_string): Delete.
11125 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
11126 (struct mem_file): Delete.
11127 (mem_file_new): Delete.
11128 (stdio_file::stdio_file): New.
11129 (mem_file_delete): Delete.
11130 (stdio_file::stdio_file): New.
11131 (mem_fileopen): Delete.
11132 (stdio_file::~stdio_file): New.
11133 (mem_file_rewind): Delete.
11134 (stdio_file::set_stream): New.
11135 (mem_file_put): Delete.
11136 (stdio_file::open): New.
11137 (mem_file_write): Delete.
11138 (stdio_file_magic, struct stdio_file): Delete.
11139 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
11140 (stdio_file::flush): New.
11141 (stdio_file_read): Rename to ...
11142 (stdio_file::read): ... this. Adjust.
11143 (stdio_file_write): Rename to ...
11144 (stdio_file::write): ... this. Adjust.
11145 (stdio_file_write_async_safe): Rename to ...
11146 (stdio_file::write_async_safe) ... this. Adjust.
11147 (stdio_file_fputs): Rename to ...
11148 (stdio_file::puts) ... this. Adjust.
11149 (stdio_file_isatty): Delete.
11150 (stdio_file_fseek): Delete.
11151 (stdio_file::isatty): New.
11152 (stderr_file_write): Rename to ...
11153 (stderr_file::write) ... this. Adjust.
11154 (stderr_file_fputs): Rename to ...
11155 (stderr_file::puts) ... this. Adjust.
11156 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
11157 (stderr_file::stderr_file): New.
11158 (tee_file_magic): Delete.
11159 (struct tee_file): Delete.
11160 (tee_file::tee_file): New.
11161 (tee_file_new): Delete.
11162 (tee_file::~tee_file): New.
11163 (tee_file_delete): Delete.
11164 (tee_file_flush): Rename to ...
11165 (tee_file::flush): ... this. Adjust.
11166 (tee_file_write): Rename to ...
11167 (tee_file::write): ... this. Adjust.
11168 (tee_file::write_async_safe): New.
11169 (tee_file_fputs): Rename to ...
11170 (tee_file::puts): ... this. Adjust.
11171 (tee_file_isatty): Rename to ...
11172 (tee_file::isatty): ... this. Adjust.
11173 * ui-file.h (struct obstack, struct ui_file): Don't
11174 forward-declare.
11175 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
11176 (ui_file_write_ftype)
11177 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
11178 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
11179 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
11180 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
11181 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
11182 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
11183 (set_ui_file_fseek): Delete.
11184 (ui_file_data, ui_file_delete, ui_file_rewind)
11185 (struct ui_file): New.
11186 (ui_file_up): New.
11187 (class null_file): New.
11188 (null_stream): Declare.
11189 (ui_file_write_for_put, ui_file_put): Delete.
11190 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
11191 Delete.
11192 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
11193 (gdb_fopen, tee_file_new): Delete.
11194 (struct string_file): New.
11195 (struct stdio_file): New.
11196 (stdio_file_up): New.
11197 (struct stderr_file): New.
11198 (class tee_file): New.
11199 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
11200 of a 'ui_file *'. Adjust.
11201 * ui-out.h (class ui_out) <field_stream>: Likewise.
11202 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
11203 (null_stream): Delete.
11204 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
11205 Adjust.
11206 * utils.h (struct ui_file): Delete forward declaration..
11207 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
11208 (error_stream): Take a 'string_file &' instead of a
11209 'ui_file *'.
11210 * varobj.c (varobj_value_get_print_value): Use string_file.
11211 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
11212 * gdbarch.c: Regenerate.
11213
187808b0
PA
112142017-02-02 Pedro Alves <palves@redhat.com>
11215
11216 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
11217 (gdb_pretty_print_insn): ... this. Now a free function. Add back
11218 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
11219 Adjust to call gdb_print_insn instead of
11220 gdb_disassembler::print_insn.
11221 (dump_insns, do_mixed_source_and_assembly_deprecated)
11222 (do_mixed_source_and_assembly, do_assembly_only): Add back a
11223 'gdbarch' parameter. Remove gdb_disassembler parameter.
11224 (gdb_disassembly): Don't allocate a gdb_disassembler here.
11225 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
11226 declaration.
11227 (gdb_pretty_print_insn): Re-add declaration.
11228 * record-btrace.c (btrace_insn_history): Don't allocate a
11229 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
11230
7a8eb317
SM
112312017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
11232
11233 * disasm.h (gdb_disassembly): Remove file_string parameter.
11234 * disasm.c (gdb_disassembly): Likewise.
11235 * cli/cli-cmds.c (print_disassembly): Adapt.
11236 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
11237 * stack.c (do_gdb_disassembly): Likewise.
11238
7346ef59
AA
112392017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
11240
11241 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
11242 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
11243 targets. And if the implicit value is longer than needed, extract
11244 the first bytes instead of the "least significant" ones.
11245
cd4007e4
MM
112462017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11247
11248 * btrace.c (btrace_enable): Do not call btrace_add_pc for
11249 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
11250 (btrace_fetch): Assert can_access_registers_ptid.
11251 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
11252 validate_registers_access.
11253
cf77c34e
MM
112542017-02-01 Markus Metzger <markus.t.metzger@intel.com>
11255
11256 * gdbthread.h (can_access_registers_ptid): New.
11257 * thread.c (can_access_registers_ptid): New.
11258
be85ce7d
PA
112592017-02-01 Pedro Alves <palves@redhat.com>
11260
11261 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
11262
29b0b251
PA
112632017-01-31 Pedro Alves <palves@redhat.com>
11264
11265 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
11266 Fix typos.
11267
289b5b24
PA
112682017-01-31 Pedro Alves <palves@redhat.com>
11269
11270 * stack.c (print_frame_args): Remove local mem_fileopen stream,
11271 not used.
11272
b47413b4
PA
112732017-01-31 Pedro Alves <palves@redhat.com>
11274
11275 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
11276
60adb36c
PA
112772017-01-31 Pedro Alves <palves@redhat.com>
11278
11279 * common/scoped_restore.h
11280 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
11281 change the value's parameter type to T2.
11282 (make_scoped_restore): Likewise.
11283
2735833d
WT
112842017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11285 Richard Henderson <rth@redhat.com>
11286
11287 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
11288 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
11289 GS_BASE for older kernels.
11290 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
11291 GS_BASE for older kernels.
11292 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
11293 and GS_BASE to the offset table.
11294 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
11295 system register group.
11296 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
11297 for older kernels.
11298 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
11299 amd64 ABI.
11300 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
11301 AMD64_GSBASE_REGNUM.
11302 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
11303 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
11304 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
11305 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
11306 i386/64bit-segments.xml in those rules.
11307 * features/i386/64bit-segments.xml: New file.
11308 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
11309 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
11310 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
11311 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
11312 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
11313 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
11314 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
11315 * features/i386/amd64-avx-linux.c: Regenerated.
11316 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
11317 * features/i386/amd64-avx-mpx.c: Regenerated.
11318 * features/i386/amd64-avx512-linux.c: Regenerated.
11319 * features/i386/amd64-linux.c: Regenerated.
11320 * features/i386/amd64-mpx-linux.c: Regenerated.
11321 * features/i386/i386-avx-mpx-linux.c: Regenerated.
11322 * features/i386/i386-avx-mpx.c: Regenerated.
11323 * features/i386/x32-avx-linux.c: Regenerated.
11324 * features/i386/x32-avx512-linux.c: Regenerated.
11325 * regformats/i386/amd64-avx-linux.dat: Regenerated.
11326 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
11327 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
11328 * regformats/i386/amd64-linux.dat: Regenerated.
11329 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
11330 * regformats/i386/x32-avx-linux.dat: Regenerated.
11331 * regformats/i386/x32-avx512-linux.dat: Regenerated.
11332 * regformats/i386/x32-linux.dat: Regenerated.
11333
8884e97e
WT
113342017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11335
11336 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
11337 Set to AMD64_NUM_REGS.
11338
7005d26a
WT
113392017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
11340
11341 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
11342 that checks validity of a register number.
11343
4bd2e1b2
KC
113442017-01-27 Kees Cook <keescook@google.com>
11345
11346 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
11347 fetch_fpregs if target has fpa registers.
11348 (arm_linux_store_inferior_registers): Call store_fpregs if target
11349 has fpa registers.
11350
7cf1de6c
AA
113512017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
11352
11353 * cris-tdep.c (cris_gdbarch_init): Remove check for
11354 info.byte_order and force it to BFD_ENDIAN_LITTLE.
11355
874a1c8c
AT
113562017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
11357
11358 * corelow.c (get_core_register_section): Check for regset
11359 existence before checking for REGSET_VARIABLE_SIZE.
11360
d8b49cf0
YQ
113612017-01-26 Yao Qi <yao.qi@linaro.org>
11362 Pedro Alves <palves@redhat.com>
11363
11364 PR gdb/20939
11365 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
11366 call memory_error, save memaddr instead.
11367 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
11368 negative, cal memory_error.
11369 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
11370
658ca58c
YQ
113712017-01-26 Yao Qi <yao.qi@linaro.org>
11372
11373 * disasm-selftests.c (memory_error_test): New function.
11374 (_initialize_disasm_selftests): Register memory_error_test.
11375
79843d45
YQ
113762017-01-26 Yao Qi <yao.qi@linaro.org>
11377
11378 * Makefile.in (SFILES): Add disasm-selftests.c and
11379 selftest-arch.c.
11380 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
11381 * disasm-selftests.c: New file.
11382 * selftest-arch.c: New file.
11383 * selftest-arch.h: New file.
11384
8cafda32
YQ
113852017-01-26 Yao Qi <yao.qi@linaro.org>
11386
11387 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
11388 to bfd_arch_mep. Don't return 0 if section is not
11389 found. Call print_insn_mep.
11390
e47ad6c0
YQ
113912017-01-26 Pedro Alves <palves@redhat.com>
11392 Yao Qi <yao.qi@linaro.org>
11393
11394 * arm-tdep.c: Include "disasm.h".
11395 (gdb_print_insn_arm): Update code to get gdbarch.
11396 * disasm.c (dis_asm_read_memory): Change it to
11397 gdb_disassembler::dis_asm_read_memory.
11398 (dis_asm_memory_error): Likewise.
11399 (dis_asm_print_address): Likewise.
11400 (gdb_pretty_print_insn): Change it to
11401 gdb_disassembler::pretty_print_insn.
11402 (dump_insns): Add one argument gdb_disassemlber. All
11403 callers updated.
11404 (do_mixed_source_and_assembly_deprecated): Likewise.
11405 (do_mixed_source_and_assembly): Likewise.
11406 (do_assembly_only): Likewise.
11407 (gdb_disassembler::gdb_disassembler): New.
11408 (gdb_disassembler::print_insn): New.
11409 * disasm.h (class gdb_disassembler): New.
11410 (gdb_pretty_print_insn): Remove declaration.
11411 (gdb_disassemble_info): Likewise.
11412 * guile/scm-disasm.c (class gdbscm_disassembler): New.
11413 (gdbscm_disasm_read_memory_worker): Update.
11414 (gdbscm_disasm_read_memory): Update.
11415 (gdbscm_disasm_memory_error): Remove.
11416 (gdbscm_disasm_print_address): Remove.
11417 (gdbscm_disassembler::gdbscm_disassembler): New.
11418 (gdbscm_print_insn_from_port): Update.
11419 * mips-tdep.c: Include disasm.h.
11420 (gdb_print_insn_mips): Update code to get gdbarch.
11421 * record-btrace.c (btrace_insn_history): Update.
11422 * spu-tdep.c: Include disasm.h.
11423 (struct spu_dis_asm_data): Remove.
11424 (struct spu_dis_asm_info): New.
11425 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
11426 SPU id.
11427 (gdb_print_insn_spu): Cast disassemble_info to
11428 spu_dis_asm_info.
11429
80d75874
YQ
114302017-01-26 Yao Qi <yao.qi@linaro.org>
11431
11432 * disasm.c (do_ui_file_delete): Delete.
11433 (gdb_insn_length): Move code creating stream to ...
11434 * utils.c (null_stream): ... here. New function.
11435 * utils.h (null_stream): Declare.
11436
60685cd0
SM
114372017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
11438
11439 * python/py-inferior.c (find_thread_object): Return directly
11440 from the loop. Remove "found" variable.
11441
eb1cdb62
JB
114422017-01-21 Joel Brobecker <brobecker@adacore.com>
11443
11444 GDB 7.12.1 released.
11445
b1ce6568
SM
114462017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11447
11448 * python/py-function.c (fnpy_call): Reorder declarations to have
11449 the gdbpy_enter object declared first.
11450 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
11451
6f8b0407
SM
114522017-01-20 Simon Marchi <simon.marchi@ericsson.com>
11453
fec93fb1 11454 PR python/21068
6f8b0407
SM
11455 * python/python-internal.h (PyMem_RawMalloc): Define for
11456 Python < 3.4.
11457 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
11458 PyMem_RawMalloc instead of PyMem_Malloc.
11459
78cbbba8
LM
114602017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
11461 Luis Machado <lgustavo@codesourcery.com>
11462
11463 * NEWS (New commands): Mention flash-erase.
11464 (New MI commands): Mention target-flash-erase.
11465 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
11466 command.
11467 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
11468 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
11469 * target.c (flash_erase_command): New function.
11470 (initialize_targets): Add new flash-erase command.
11471 * target.h (flash_erase_command): New declaration.
11472
2132fe85
JB
114732017-01-20 Joel Brobecker <brobecker@adacore.com>
11474
11475 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
11476 HAVE_SYS_PROCFS_H is defined.
11477
d1dff226
AH
114782017-01-18 Alan Hayward <alan.hayward@arm.com>
11479
11480 * remote.c (struct cached_reg): Change data into a pointer.
11481 * (stop_reply_dtr): Free data pointers before deleting vector.
11482 (process_stop_reply): Likewise.
11483 (remote_parse_stop_reply): Allocate space for data
11484
9890e433
AH
114852017-01-18 Alan Hayward <alan.hayward@arm.com>
11486
11487 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
11488 MAX_REGISTER_SIZE.
11489 (amd64_pseudo_register_read_value): Likewise.
11490 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
11491 (store_register_using_P): Likewise.
11492 * regcache.c (regcache_xfer_part): Likewise.
11493
7a36499a
IR
114942017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
11495
11496 Split real and pseudo registers.
11497 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
11498 (sparc32_pseudo_regnum): New enum.
11499 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
11500 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
11501 (SPARC32_CP0_REGISTERS): New macro.
11502 (sparc32_pseudo_register_name): New function.
11503 (sparc32_register_name): Use sparc32_pseudo_register_name.
11504 (sparc32_pseudo_register_type): New function.
11505 (sparc32_register_type): Use sparc32_pseudo_register_type.
11506 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
11507 pseudo register numbers.
11508 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
11509 (SPARC64_CP0_REGISTERS): New macro.
11510 (sparc64_pseudo_register_name): New function.
11511 (sparc64_register_name): Use sparc64_pseudo_register_name.
11512 (sparc64_pseudo_register_type): New function.
11513 (sparc64_register_type): Use sparc64_pseudo_register_type.
11514 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
11515 pseudo register numbers.
11516 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
11517 sparc64_store_arguments): Handle pseudo register numbers.
11518
6f8976bf
YQ
115192017-01-13 Yao Qi <yao.qi@linaro.org>
11520
11521 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
11522 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
11523 output.
11524 (getpkt_or_notif_sane_1): Likewise.
11525
e4241ace
YQ
115262017-01-13 Yao Qi <yao.qi@linaro.org>
11527
11528 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
11529 of CC. Pass "-x c++-header" instead of "-x c".
11530
3015c064
SM
115312017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11532
11533 * remote.c (remote_can_async_p): Update comment.
11534
fde1b17d
SM
115352017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11536
11537 * linux-nat.c (linux_nat_can_async_p): Update comment.
11538
ca1ca08b
SM
115392017-01-12 Simon Marchi <simon.marchi@ericsson.com>
11540
11541 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
11542
4ad2da73
SM
115432017-01-11 Simon Marchi <simon.marchi@ericsson.com>
11544
11545 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
11546
c8b23b3f
TT
115472017-01-10 Tom Tromey <tom@tromey.com>
11548
11549 * python/py-type.c (typy_legacy_template_argument): Update.
11550 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
11551 ~demangle_parse_info): Declare new members.
11552 (cp_demangled_name_to_comp): Return unique_ptr.
11553 (cp_demangled_name_parse_free)
11554 (make_cleanup_cp_demangled_name_parse_free)
11555 (cp_new_demangle_parse_info): Remove.
11556 * cp-support.c (do_demangled_name_parse_free_cleanup)
11557 (make_cleanup_cp_demangled_name_parse_free): Remove.
11558 (inspect_type, cp_canonicalize_string_full)
11559 (cp_canonicalize_string): Update.
11560 (mangled_name_to_comp): Change return type.
11561 (cp_class_name_from_physname, method_name_from_physname)
11562 (cp_func_name, cp_remove_params): Update.
11563 * cp-name-parser.y (demangle_parse_info): New constructor, from
11564 cp_new_demangle_parse_info.
11565 (~demangle_parse_info): New destructor, from
11566 cp_demangled_name_parse_free.
11567 (cp_merge_demangle_parse_infos): Update.
11568 (cp_demangled_name_to_comp): Change return type.
11569
1ac32117
TT
115702017-01-10 Tom Tromey <tom@tromey.com>
11571
11572 * top.c (prevent_dont_repeat): Change return type.
11573 * python/python.c (execute_gdb_command): Use std::string.
11574 Update.
11575 * guile/guile.c (gdbscm_execute_gdb_command): Update.
11576 * command.h (prevent_dont_repeat): Change return type.
11577 * breakpoint.c (bpstat_do_actions_1): Update.
11578
0cf08227
TT
115792017-01-10 Tom Tromey <tom@tromey.com>
11580
11581 * value.h (scoped_value_mark::~scoped_value_mark): Call
11582 free_to_mark.
11583 (scoped_value_mark::free_to_mark): New method.
11584 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
11585 scoped_value_mark.
11586
eb115069
TT
115872017-01-10 Tom Tromey <tom@tromey.com>
11588
11589 * python/py-value.c (valpy_dereference, valpy_referenced_value)
11590 (valpy_reference_value, valpy_const_value, valpy_get_address)
11591 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
11592 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
11593 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
11594 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
11595 scoped_value_mark.
11596 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
11597 * value.h (scoped_value_mark): New class.
11598
906768f9
TT
115992017-01-10 Tom Tromey <tom@tromey.com>
11600
11601 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
11602 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
11603 * psymtab.c (discard_psymtabs_upto): Remove.
11604 (make_cleanup_discard_psymtabs): Remove.
11605 (struct psymtab_state): Remove.
11606
bef155c3
TT
116072017-01-10 Tom Tromey <tom@tromey.com>
11608
11609 * record-full.c (record_full_save_cleanups): Remove.
11610 (record_full_save): Use gdb::unlinker.
11611 * gcore.c (do_bfd_delete_cleanup): Remove.
11612 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
11613 cleanups.
11614 * dwarf2read.c (unlink_if_set): Remove.
11615 (write_psymtabs_to_index): Use gdb::unlinker.
11616 * common/gdb_unlinker.h: New file.
11617
192b62ce
TT
116182017-01-10 Tom Tromey <tom@tromey.com>
11619
11620 * windows-tdep.c (windows_xfer_shared_library): Update.
11621 * windows-nat.c (windows_make_so): Update.
11622 * utils.h (make_cleanup_bfd_unref): Remove.
11623 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
11624 * symfile.h (symfile_bfd_open)
11625 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
11626 * symfile.c (read_symbols, symbol_file_add)
11627 (separate_debug_file_exists): Update.
11628 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
11629 (generic_load, reread_symbols): Update.
11630 * symfile-mem.c (symbol_file_add_from_memory): Update.
11631 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
11632 (spu_symbol_file_add_from_memory): Update.
11633 * solist.h (struct target_so_ops) <bfd_open>: Return
11634 gdb_bfd_ref_ptr.
11635 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
11636 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
11637 gdb_bfd_ref_ptr.
11638 (solib_map_sections, reload_shared_libraries_1): Update.
11639 * solib-svr4.c (enable_break): Update.
11640 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
11641 * solib-frv.c (enable_break2): Update.
11642 * solib-dsbt.c (enable_break): Update.
11643 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
11644 gdb_bfd_ref_ptr.
11645 (darwin_solib_get_all_image_info_addr_at_init): Update.
11646 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
11647 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
11648 * record-full.c (record_full_save): Update.
11649 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
11650 * procfs.c (insert_dbx_link_bpt_in_file): Update.
11651 * minidebug.c (find_separate_debug_file_in_section): Return
11652 gdb_bfd_ref_ptr.
11653 * machoread.c (macho_add_oso_symfile): Change abfd to
11654 gdb_bfd_ref_ptr.
11655 (macho_symfile_read_all_oso): Update.
11656 (macho_check_dsym): Return gdb_bfd_ref_ptr.
11657 (macho_symfile_read): Update.
11658 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
11659 (jit_bfd_try_read_symtab): Update.
11660 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11661 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11662 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11663 gdb_bfd_ref_ptr.
11664 (gdb_bfd_ref_policy): New struct.
11665 (gdb_bfd_ref_ptr): New typedef.
11666 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
11667 (gdb_bfd_openw, gdb_bfd_openr_iovec)
11668 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
11669 gdb_bfd_ref_ptr.
11670 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11671 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
11672 (gcore_command): Update.
11673 * exec.c (exec_file_attach): Update.
11674 * elfread.c (elf_symfile_read): Update.
11675 * dwarf2read.c (dwarf2_get_dwz_file): Update.
11676 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
11677 (open_and_init_dwo_file): Update.
11678 (open_dwp_file): Return gdb_bfd_ref_ptr.
11679 (open_and_init_dwp_file): Update.
11680 * corelow.c (core_open): Update.
11681 * compile/compile-object-load.c (compile_object_load): Update.
11682 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
11683 * coffread.c (coff_symfile_read): Update.
11684 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
11685 gdb_bfd_ref_ptr. Rename.
11686 (dump_bfd_file, restore_command): Update.
11687 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11688 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
11689 (find_separate_debug_file_by_buildid): Update.
11690
50315b21
TT
116912017-01-10 Tom Tromey <tom@tromey.com>
11692
11693 * common/gdb_ref_ptr.h: New file.
11694 * python/py-ref.h (struct gdbpy_ref_policy): New.
11695 (gdbpy_ref): Now a typedef.
11696
fc4007c9
TT
116972017-01-10 Tom Tromey <tom@tromey.com>
11698
11699 * utils.h (make_cleanup_htab_delete): Don't declare.
11700 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
11701 Remove.
11702 * linespec.c (decode_compound_collector): Add constructor,
11703 destructor.
11704 (lookup_prefix_sym): Remove cleanup.
11705 (symtab_collector): Add constructor, destructor.
11706 (collect_symtabs_from_filename): Remove cleanup.
11707 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
11708 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
11709 Use htab_up.
11710 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
11711 * dwarf2read.c (dw2_expand_symtabs_matching)
11712 (dw2_map_symbol_filenames, dwarf_decode_macros)
11713 (write_psymtabs_to_index): Use htab_up.
11714 * dwarf2loc.c (func_verify_no_selftailcall)
11715 (call_site_find_chain_1, func_verify_no_selftailcall)
11716 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
11717 std::vector, gdb::unique_xmalloc_ptr.
11718 (call_sitep): Remove typedef.
11719 (dwarf2_locexpr_baton_eval): Remove unused variable.
11720
8dbcee67
TT
117212017-01-10 Tom Tromey <tom@tromey.com>
11722
11723 * python/python-internal.h (make_cleanup_py_decref)
11724 (make_cleanup_py_xdecref): Don't declare.
11725 * python/py-utils.c (py_decref, make_cleanup_py_decref)
11726 (py_xdecref, make_cleanup_py_xdecref): Remove.
11727
13df46cc
TT
117282017-01-10 Tom Tromey <tom@tromey.com>
11729
11730 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
11731 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
11732
06fc9bf7
TT
117332017-01-10 Tom Tromey <tom@tromey.com>
11734
11735 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
11736
830a4934
TT
117372017-01-10 Tom Tromey <tom@tromey.com>
11738
11739 * python/py-utils.c (unicode_to_encoded_string)
11740 (python_string_to_target_string)
11741 (python_string_to_target_python_string)
11742 (python_string_to_host_string, gdbpy_obj_to_string)
11743 (get_addr_from_python): Use gdbpy_ref.
11744
4586d543
TT
117452017-01-10 Tom Tromey <tom@tromey.com>
11746
11747 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
11748 gdbpy_ref.
11749
59876f8f
TT
117502017-01-10 Tom Tromey <tom@tromey.com>
11751
11752 * python/python.c (eval_python_command, gdbpy_decode_line)
11753 (gdbpy_run_events, gdbpy_start_type_printers)
11754 (gdbpy_apply_type_printers): Use gdbpy_ref.
11755
97d83487
TT
117562017-01-10 Tom Tromey <tom@tromey.com>
11757
11758 * python/py-param.c (get_doc_string, compute_enum_values): Use
11759 gdbpy_ref.
11760
9205649a
TT
117612017-01-10 Tom Tromey <tom@tromey.com>
11762
11763 * python/py-inferior.c (find_thread_object, build_inferior_list):
11764 Use gdbpy_ref.
11765
74c49d45
TT
117662017-01-10 Tom Tromey <tom@tromey.com>
11767
11768 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11769
16361ffb
TT
117702017-01-10 Tom Tromey <tom@tromey.com>
11771
11772 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
11773 gdbpy_ref.
11774
905f2cca
TT
117752017-01-10 Tom Tromey <tom@tromey.com>
11776
11777 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
11778 extra incref.
11779 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
11780 Use gdbpy_ref.
11781
64081434
TT
117822017-01-10 Tom Tromey <tom@tromey.com>
11783
11784 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11785 gdbpy_ref.
11786
59e9e831
TT
117872017-01-10 Tom Tromey <tom@tromey.com>
11788
11789 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
11790 decref results of PyArg_ParseTupleAndKeywords.
11791
9de10f6d
TT
117922017-01-10 Tom Tromey <tom@tromey.com>
11793
11794 * python/python.c (python_run_simple_file): Use
11795 unique_xmalloc_ptr, gdbpy_ref.
11796
2bd5759d
TT
117972017-01-10 Tom Tromey <tom@tromey.com>
11798
11799 * python/py-prettyprint.c (print_stack_unless_memory_error)
11800 (print_string_repr, print_children): Use gdbpy_ref.
11801 (dummy_python_frame): New class.
11802 (dummy_python_frame::dummy_python_frame): Rename from
11803 push_dummy_python_frame.
11804 (py_restore_tstate): Remove.
11805
3b4e0e01
TT
118062017-01-10 Tom Tromey <tom@tromey.com>
11807
11808 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
11809
17a22718
TT
118102017-01-10 Tom Tromey <tom@tromey.com>
11811
11812 * python/python.c (ensure_python_env, restore_python_env):
11813 Remove.
11814 * python/python-internal.h (ensure_python_env): Don't declare.
11815 * varobj.h (varobj_ensure_python_env): Don't declare.
11816 * varobj.c (varobj_ensure_python_env): Remove.
11817
68cdc557
TT
118182017-01-10 Tom Tromey <tom@tromey.com>
11819
11820 * varobj.c (varobj_value_get_print_value): Use
11821 gdbpy_enter_varobj.
11822
1eba6383
TT
118232017-01-10 Tom Tromey <tom@tromey.com>
11824
11825 * python/py-prettyprint.c (print_string_repr, print_children):
11826 Update.
11827 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
11828 of "encoding".
11829 * varobj.c (varobj_value_get_print_value): Update.
11830 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
11831
bde7b3e3
TT
118322017-01-10 Tom Tromey <tom@tromey.com>
11833
11834 * varobj.c (varobj_get_display_hint)
11835 (dynamic_varobj_has_child_method, install_new_value_visualizer)
11836 (varobj_set_visualizer, free_variable): Use
11837 gdbpy_enter_varobj.
11838
a7785f8c
TT
118392017-01-10 Tom Tromey <tom@tromey.com>
11840
11841 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
11842 (do_finish_initialization): New function. Use gdbpy_ref.
11843 (gdbpy_finish_initialization): Use gdbpy_enter. Call
11844 do_finish_initialization.
11845
2865bfce
TT
118462017-01-10 Tom Tromey <tom@tromey.com>
11847
11848 * python/py-param.c (get_set_value, get_show_value): Use
11849 gdbpy_enter, gdbpy_ref.
11850
0e9dcc75
TT
118512017-01-10 Tom Tromey <tom@tromey.com>
11852
11853 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
11854
12a5cedd
TT
118552017-01-10 Tom Tromey <tom@tromey.com>
11856
11857 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
11858
788f2586
TT
118592017-01-10 Tom Tromey <tom@tromey.com>
11860
11861 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
11862 Use gdbpy_enter_varobj.
11863
6cd67bea
TT
118642017-01-10 Tom Tromey <tom@tromey.com>
11865
11866 * varobj.c (gdbpy_enter_varobj): New constructor.
11867 * python/python-internal.h (gdbpy_enter_varobj): New class.
11868 * python/py-varobj.c (py_varobj_get_iterator): Use
11869 gdbpy_enter_varobj.
11870
14b122bf
TT
118712017-01-10 Tom Tromey <tom@tromey.com>
11872
11873 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
11874 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11875 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
11876 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
11877 unique_xmalloc_ptr.
11878 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
11879
bf1ca3b9
TT
118802017-01-10 Tom Tromey <tom@tromey.com>
11881
11882 * python/py-xmethods.c (invoke_match_method): Use
11883 gdbpy_ref.
11884
572a5524
TT
118852017-01-10 Tom Tromey <tom@tromey.com>
11886
11887 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
11888 gdbpy_enter, gdbpy_ref.
11889
396a78b6
TT
118902017-01-10 Tom Tromey <tom@tromey.com>
11891
11892 * python/python.c (python_interactive_command): Use gdbpy_enter.
11893
a88b13c7
TT
118942017-01-10 Tom Tromey <tom@tromey.com>
11895
11896 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
11897 gdbpy_ref.
11898
e9f0c363
TT
118992017-01-10 Tom Tromey <tom@tromey.com>
11900
11901 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
11902 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
11903
6349f452
TT
119042017-01-10 Tom Tromey <tom@tromey.com>
11905
11906 * utils.h (htab_deleter): New struct.
11907 (htab_up): New typedef.
11908 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
11909 gdbpy_enter, gdbpy_ref, htab_up.
11910
c0171de6
TT
119112017-01-10 Tom Tromey <tom@tromey.com>
11912
11913 * python/py-unwind.c (pending_frame_invalidate): Remove.
11914 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
11915
f18e226f
TT
119162017-01-10 Tom Tromey <tom@tromey.com>
11917
11918 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
11919 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
11920
c57af3f1
TT
119212017-01-10 Tom Tromey <tom@tromey.com>
11922
11923 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
11924
60e600ec
TT
119252017-01-10 Tom Tromey <tom@tromey.com>
11926
11927 * python/python.c (gdbpy_eval_from_control_command)
11928 (gdbpy_source_script, gdbpy_run_events)
11929 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
11930 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
11931 gdbpy_enter.
11932
bf7da5b0
TT
119332017-01-10 Tom Tromey <tom@tromey.com>
11934
11935 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
11936
2d38bced
TT
119372017-01-10 Tom Tromey <tom@tromey.com>
11938
11939 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
11940
07bc7329
TT
119412017-01-10 Tom Tromey <tom@tromey.com>
11942
11943 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
11944 (python_on_inferior_call_pre, python_on_inferior_call_post)
11945 (python_on_memory_change, python_on_register_change)
11946 (python_inferior_exit, python_new_objfile, add_thread_object)
11947 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
11948
6e7c365e
TT
119492017-01-10 Tom Tromey <tom@tromey.com>
11950
11951 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
11952 (bpfinishpy_handle_exit): Use gdbpy_enter.
11953
6ba0cd40
TT
119542017-01-10 Tom Tromey <tom@tromey.com>
11955
11956 * python/py-cmd.c (cmdpy_destroyer)
11957 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
11958 gdbpy_enter.
11959
de2dc875
TT
119602017-01-10 Tom Tromey <tom@tromey.com>
11961
11962 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
11963 gdbpy_enter.
11964 (gdbpy_breakpoint_has_cond): Likewise.
11965
4ecee2c4
TT
119662017-01-10 Tom Tromey <tom@tromey.com>
11967
11968 * python/python.c (gdbpy_enter): New constructor.
11969 (~gdbpy_enter): New destructor.
11970 (restore_python_env, ensure_python_env): Rewrite.
11971 * python/python-internal.h (gdbpy_enter): New class.
11972
37fce74f
TT
119732017-01-10 Tom Tromey <tom@tromey.com>
11974
11975 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
11976
53a0cca3
TT
119772017-01-10 Tom Tromey <tom@tromey.com>
11978
11979 * python/py-value.c (value_has_field, get_field_flag)
11980 (get_field_type, valpy_getitem, convert_value_from_python): Use
11981 gdbpy_ref.
11982
ff3724f5
TT
119832017-01-10 Tom Tromey <tom@tromey.com>
11984
11985 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
11986 gdbpy_ref.
11987
0700aea5
TT
119882017-01-10 Tom Tromey <tom@tromey.com>
11989
11990 * python/py-prettyprint.c (search_pp_list)
11991 (find_pretty_printer_from_objfiles)
11992 (find_pretty_printer_from_progspace)
11993 (find_pretty_printer_from_gdb, find_pretty_printer)
11994 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
11995 gdbpy_ref.
11996
1bb44c9f
TT
119972017-01-10 Tom Tromey <tom@tromey.com>
11998
11999 * python/py-param.c (call_doc_function): Use gdbpy_ref.
12000
87ce03fd
TT
120012017-01-10 Tom Tromey <tom@tromey.com>
12002
12003 * python/py-linetable.c (build_line_table_tuple_from_pcs)
12004 (ltpy_get_all_source_lines): Use gdbpy_ref.
12005
ee0a3fb8
TT
120062017-01-10 Tom Tromey <tom@tromey.com>
12007
12008 * python/py-framefilter.c (extract_sym, extract_value)
12009 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
12010 gdbpy_ref.
12011
bf2a52fa
TT
120122017-01-10 Tom Tromey <tom@tromey.com>
12013
12014 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
12015
f59fe7f8
TT
120162017-01-10 Tom Tromey <tom@tromey.com>
12017
12018 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
12019
80bd970a
TT
120202017-01-10 Tom Tromey <tom@tromey.com>
12021
12022 * python/py-function.c (convert_values_to_python, fnpy_init): Use
12023 gdbpy_ref.
12024
d1b3de2e
TT
120252017-01-10 Tom Tromey <tom@tromey.com>
12026
12027 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
12028
3bb43384
TT
120292017-01-10 Tom Tromey <tom@tromey.com>
12030
12031 * python/py-type.c (convert_field, make_fielditem, typy_fields)
12032 (typy_range): Use gdbpy_ref.
12033
abf5651e
TT
120342017-01-10 Tom Tromey <tom@tromey.com>
12035
12036 * python/py-threadevent.c (create_thread_event_object): Use
12037 gdbpy_ref.
12038 * python/py-stopevent.c (create_stop_event_object): Simplify.
12039 (emit_stop_event): Use gdbpy_ref.
12040 * python/py-signalevent.c (create_signal_event_object): Use
12041 gdbpy_ref.
12042 * python/py-newobjfileevent.c (create_new_objfile_event_object)
12043 (emit_new_objfile_event, create_clear_objfiles_event_object)
12044 (emit_clear_objfiles_event): Use gdbpy_ref.
12045 * python/py-infevents.c (create_inferior_call_event_object)
12046 (create_register_changed_event_object)
12047 (create_memory_changed_event_object, emit_inferior_call_event)
12048 (emit_memory_changed_event, emit_register_changed_event): Use
12049 gdbpy_ref.
12050 * python/py-exitedevent.c (create_exited_event_object)
12051 (emit_exited_event): Use gdbpy_ref.
12052 * python/py-event.h (evpy_emit_event): Remove
12053 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
12054 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
12055 * python/py-continueevent.c (emit_continue_event): Use
12056 gdbpy_ref.
12057 * python/py-breakpoint.c (gdbpy_breakpoint_created)
12058 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
12059 gdbpy_ref.
12060 * python/py-bpevent.c (create_breakpoint_event_object): Use
12061 gdbpy_ref.
12062
a68ff33e
TT
120632017-01-10 Tom Tromey <tom@tromey.com>
12064
12065 * python/py-ref.h: New file.
12066
7becfd03
SM
120672017-01-10 Simon Marchi <simon.marchi@ericsson.com>
12068
12069 * cli-out.c (cli_ui_out::do_redirect): Change return type to
12070 void.
12071 * cli-out.h (cli_ui_out::do_redirect): Likewise.
12072 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
12073 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
12074 * ui-out.c (ui_out::redirect): Likewise.
12075 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
12076 * cli/cli-logging.c (set_logging_redirect): Update call site of
12077 ui_out::redirect.
12078 (handle_redirections): Likewise.
12079 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
12080 * top.c (execute_command_to_string): Likewise.
12081 * utils.c (do_ui_out_redirect_pop): Likewise.
12082
df294654
SM
120832017-01-10 Simon Marchi <simon.marchi@ericsson.com>
12084
12085 * stack.c (_initialize_stack): Update "frame" command help message.
12086
f5e6296e
IB
120872017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
12088
12089 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
12090
0e2d6fa6
YQ
120912017-01-06 Yao Qi <yao.qi@linaro.org>
12092
12093 * x86-linux-nat.h: Include gdb_proc_service.h.
12094
44d6d3f9
YQ
120952017-01-06 Yao Qi <yao.qi@linaro.org>
12096
12097 * ser-base.h: Include serial.h.
12098
656731fe
YQ
120992017-01-06 Yao Qi <yao.qi@linaro.org>
12100
12101 * ppc-linux-tdep.h: Include ppc-tdep.h.
12102
1ca8f924
YQ
121032017-01-06 Yao Qi <yao.qi@linaro.org>
12104
12105 * nat/amd64-linux-siginfo.h: Include signal.h.
12106
bc3008c4
YQ
121072017-01-06 Yao Qi <yao.qi@linaro.org>
12108
12109 * nat/aarch64-linux-hw-point.h: Include break-common.h.
12110
66c80d03
YQ
121112017-01-06 Yao Qi <yao.qi@linaro.org>
12112
12113 * mi/mi-parse.h: Include mi-cmds.h.
12114
051d2dda
YQ
121152017-01-06 Yao Qi <yao.qi@linaro.org>
12116
12117 * inf-loop.c: Don't include "target.h".
12118 * inf-loop.h: Include it here.
12119
8018d34f
YQ
121202017-01-06 Yao Qi <yao.qi@linaro.org>
12121
12122 * dfp.h: Include "dboulest.h" and "expression.h".
12123
c0b8369c
YQ
121242017-01-06 Yao Qi <yao.qi@linaro.org>
12125
12126 * ax-gdb.h: Include "ax.h".
12127
ad5cba2a
YQ
121282017-01-06 Yao Qi <yao.qi@linaro.org>
12129
12130 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
12131 with nat/gdb_ptrace.h.
12132
1c33cd7f
YQ
121332017-01-05 Yao Qi <yao.qi@linaro.org>
12134
12135 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
12136 new line.
12137 (mips64_fbsd_sigframe_init): Likewise.
12138
c988ac1d
JB
121392017-01-04 John Baldwin <jhb@FreeBSD.org>
12140
12141 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
12142 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
12143
b268007c
JB
121442017-01-04 John Baldwin <jhb@FreeBSD.org>
12145
12146 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
12147 * NEWS: Mention new FreeBSD/mips native configuration.
12148 * config/mips/fbsd.mh: New file.
12149 * configure.host: Add mips*-*-freebsd*.
12150 * mips-fbsd-nat.c: New file.
12151
387360da
JB
121522017-01-04 John Baldwin <jhb@FreeBSD.org>
12153
12154 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
12155 (ALLDEPFILES): Add mips-fbsd-tdep.c.
12156 * NEWS: Mention new FreeBSD/mips target.
12157 * configure.tgt: Add mips*-*-freebsd*.
12158 * mips-fbsd-tdep.c: New file.
12159 * mips-fbsd-tdep.h: New file.
12160
2aaaf250
YQ
121612017-01-04 Yao Qi <yao.qi@linaro.org>
12162
12163 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
12164 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
12165
61baf725
JB
121662017-01-01 Joel Brobecker <brobecker@adacore.com>
12167
6dbb839a 12168 Update copyright year range in all GDB files.
61baf725 12169
c113e7ff 121702017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 12171
c113e7ff 12172 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 12173
c113e7ff 12174For older changes see ChangeLog-2016.
c906108c
SS
12175\f
12176Local Variables:
12177mode: change-log
12178left-margin: 8
12179fill-column: 74
12180version-control: never
57da7796 12181coding: utf-8
c906108c 12182End:
This page took 2.831008 seconds and 4 git commands to generate.