]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/ChangeLog
Remove ioctl-based procfs support on Solaris
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
1 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2
3 * configure.ac Don't check for sys/fault.h, sys/syscall.h,
4 sys/proc.h.
5 (NEW_PROC_API): Remove.
6 (prsysent_t, pr_sigset_t, pr_sigaction64_t, pr_siginfo64_t):
7 Likewise.
8 * common/common.m4 (GDB_AC_COMMON): Don't check for sys/syscall.h.
9 * configure: Regenerate.
10 * config.in: Regenerate.
11 * gdbserver/configure: Regenerate.
12 * gdbserver/config.in: Regenerate.
13
14 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Remove
15 NEW_PROC_API test.
16 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Likewise.
17
18 * linux-btrace.c: Remove HAVE_SYS_SYSCALL_H test.
19
20 * proc-api.c: Remove !NEW_PROC_API support.
21 Remove HAVE_SYS_PROC_H and HAVE_SYS_USER_H tests.
22 Remove tests for macros always defined on Solaris.
23 * proc-events.c: Remove !NEW_PROC_API support.
24 Remove Remove HAVE_SYS_SYSCALL_H, HAVE_SYS_PROC_H and
25 HAVE_SYS_USER_H tests.
26 (init_syscall_table): Remove non-Solaris syscalls.
27 Remove tests for syscalls present on all Solaris versions.
28 Add missing Solaris 10+ syscalls.
29 (signal_table): Remove non-Solaris signals.
30 Remove tests for signals present on all Solaris versions.
31 (fault_table): Remove non-Solaris faults.
32 Remove tests for faults present on all Solaris versions.
33 * proc-flags.c: Remove !NEW_PROC_API support.
34 (pr_flag_table): Remove non-Solaris and pre-Solaris 7 comments.
35 Remove non-Solaris flags.
36 * proc-why.c: Remove !NEW_PROC_API support.
37 (pr_why_table): Remove meaningless comments.
38 Remove tests for reasons present on all Solaris versions.
39 Remove OSF/1 cases.
40 (proc_prettyfprint_why): Likewise.
41
42 * procfs.c: Remove !NEW_PROC_API and DYNAMIC_SYSCALLS support.
43 Remove HAVE_SYS_FAULT_H and HAVE_SYS_SYSCALL_H tests.
44 Remove WA_READ test, IRIX watchpoint support.
45 (gdb_sigset_t, gdb_sigaction_t, gdb_siginfo_t): Replace by base
46 types. Change users.
47 (gdb_praddset, gdb_prdelset, gdb_premptysysset, gdb_praddsysset)
48 (gdb_prdelset, gdb_pr_issyssetmember): Replace by base macros.
49 Change callers.
50 Remove CTL_PROC_NAME_FMT tests.
51 (gdb_prstatus_t, gdb_lwpstatus_t): Replace by base types. Change
52 users.
53 (sysset_t_size): Remove. Use sizeof (sysset_t) in callers.
54 Remove PROCFS_DONT_PIOCSSIG_CURSIG support.
55 (proc_modify_flag): Replace GDBRESET by PCUNSET.
56 Remove PR_ASYNC, PR_KLC tests.
57 (proc_unset_inherit_on_fork): Remove PR_ASYNC test.
58 (proc_parent_pid): Remove PCWATCH etc. tests.
59 (proc_set_watchpoint): Remove !PCWATCH && !PIOCSWATCH support.
60 Remove PCAGENT test.
61 (proc_get_nthreads) [PIOCNTHR && PIOCTLIST]: Remove.
62 Remove SYS_lwpcreate || SYS_lwp_create test.
63 (proc_get_current_thread): Likewise.
64 [PIOCNTHR && PIOCTLIST]: Remove.
65 [PIOCLSTATUS]: Remove.
66 (procfs_debug_inferior): Remove non-Solaris cases, conditionals.
67 [PRFS_STOPEXEC]: Remove.
68 (syscall_is_lwp_exit): Remove non-Solaris cases, conditionals.
69 (syscall_is_exit): Likewise.
70 (syscall_is_exec): Likewise.
71 (syscall_is_lwp_create): Likewise.
72 Remove SYS_syssgi support.
73 (procfs_wait): Remove PR_ASYNC, !PIOCSSPCACT tests.
74 [SYS_syssgi]: Remove.
75 Remove non-Solaris cases, conditionals.
76 (unconditionally_kill_inferior) [PROCFS_NEED_PIOCSSIG_FOR_KILL]:
77 Remove.
78 (procfs_init_inferior) [SYS_syssgi]: Remove.
79 (procfs_set_exec_trap) [PRFS_STOPEXEC]: Remove.
80 (procfs_inferior_created) [SYS_syssgi]: Remove.
81 (procfs_set_watchpoint): Remove !AIX5 test.
82 (procfs_stopped_by_watchpoint): Remove FLTWATCH test, FLTKWATCH
83 case.
84 (mappingflags) [MA_PHYS]: Remove.
85 (info_mappings_callback): Remove PCAGENT test.
86 Remove PIOCOPENLWP || PCAGENT test.
87
88 2017-11-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
89
90 * sol-thread.c (info_solthreads): Constify args.
91 Cast args to void *.
92
93 2017-11-29 John Baldwin <jhb@FreeBSD.org>
94
95 * target-float.c [HAVE_LIBMPFR]: Define MPFR_USE_INTMAX_T.
96
97 2017-11-29 Joel Brobecker <brobecker@adacore.com>
98
99 * ada-lang.c (to_fixed_range_type): Make sure that the size
100 of the range type being returned is the same as the size
101 of the range type being fixed.
102
103 2017-11-29 Pedro Alves <palves@redhat.com>
104
105 PR c++/19436
106 * NEWS: Mention setting breakpoints on functions with C++ ABI
107 tags.
108 * completer.h (completion_match_for_lcd) <match,
109 mark_ignored_range>: New methods.
110 <finish>: Consider ignored ranges.
111 <clear>: Clear ignored ranges.
112 <m_ignored_ranges, m_finished_storage>: New fields.
113 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
114 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
115 completion_match_for_lcd pointer to strncmp_iw_with_mode.
116 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
117 * language.c (default_symbol_name_matcher): Pass the
118 completion_match_for_lcd pointer to strncmp_iw_with_mode.
119 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
120 * utils.c (skip_abi_tag): New function.
121 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
122 Handle ABI tags.
123 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
124 parameter.
125
126 2017-11-29 Pedro Alves <palves@redhat.com>
127
128 PR c++/19436
129 * NEWS: Mention setting breakpoints on functions with C++ ABI
130 tags.
131 * completer.h (completion_match_for_lcd) <match,
132 mark_ignored_range>: New methods.
133 <finish>: Consider ignored ranges.
134 <clear>: Clear ignored ranges.
135 <m_ignored_ranges, m_finished_storage>: New fields.
136 * cp-support.c (cp_search_name_hash): Ignore ABI tags.
137 (cp_symbol_name_matches_1, cp_fq_symbol_name_matches): Pass the
138 completion_match_for_lcd pointer to strncmp_iw_with_mode.
139 (test_cp_symbol_name_cmp): Add [abi:...] tags unit tests.
140 * language.c (default_symbol_name_matcher): Pass the
141 completion_match_for_lcd pointer to strncmp_iw_with_mode.
142 * linespec.c (linespec_lexer_lex_string): Don't tokenize ABI tags.
143 * utils.c (skip_abi_tag): New function.
144 (strncmp_iw_with_mode): Add completion_match_for_lcd parameter.
145 Handle ABI tags.
146 * utils.h (strncmp_iw_with_mode): Add completion_match_for_lcd
147 parameter.
148
149 2017-11-29 Pedro Alves <palves@redhat.com>
150
151 * NEWS: Mention that breakpoints on C++ functions are now set on
152 on all namespaces/classes by default, and mention "break
153 -qualified".
154 * ax-gdb.c (agent_command_1): Adjust to pass a
155 symbol_name_match_type to new_linespec_location.
156 * breakpoint.c (parse_breakpoint_sals): Adjust to
157 get_linespec_location's return type change.
158 (strace_marker_create_sals_from_location): Adjust to pass a
159 symbol_name_match_type to new_linespec_location.
160 (strace_marker_decode_location): Adjust to get_linespec_location's
161 return type change.
162 (strace_command): Adjust to pass a symbol_name_match_type to
163 new_linespec_location.
164 (LOCATION_HELP_STRING): Add paragraph about wildmatching, and
165 mention "-qualified".
166 * c-lang.c (cplus_language_defn): Install cp_search_name_hash.
167 * completer.c (explicit_location_match_type::MATCH_QUALIFIED): New
168 enumerator.
169 (complete_address_and_linespec_locations): New parameter
170 'match_type'. Pass it down.
171 (explicit_options): Add "-qualified".
172 (collect_explicit_location_matches): Pass the requested match type
173 to the linespec completers. Handle MATCH_QUALIFIED.
174 (location_completer): Handle "-qualified" combined with linespecs.
175 * cp-support.c (cp_search_name_hash): New.
176 (cp_symbol_name_matches_1): Implement wild matching for C++.
177 (cp_fq_symbol_name_matches): Reimplement.
178 (cp_get_symbol_name_matcher): Return different matchers depending
179 on the lookup name's match type.
180 (selftests::test_cp_symbol_name_matches): Add wild matching tests.
181 * cp-support.h (cp_search_name_hash): New declaration.
182 * dwarf2read.c
183 (selftests::dw2_expand_symtabs_matching::test_symbols): Add
184 symbols.
185 (test_dw2_expand_symtabs_matching_symbol): Add wild matching
186 tests.
187 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Adjust to
188 pass a symbol_name_match_type to new_linespec_location.
189 * linespec.c (linespec_parse_basic): Lookup function symbols using
190 the parser's symbol name match type.
191 (convert_explicit_location_to_linespec): New
192 symbol_name_match_type parameter. Pass it down to
193 find_linespec_symbols.
194 (convert_explicit_location_to_sals): Pass the location's name
195 match type to convert_explicit_location_to_linespec.
196 (parse_linespec): New match_type parameter. Save it in the
197 parser.
198 (linespec_parser_new): Default to symbol_name_match_type::WILD.
199 (linespec_complete_function): New symbol_name_match_type
200 parameter. Use it.
201 (complete_linespec_component): Pass down the parser's recorded
202 name match type.
203 (linespec_complete_label): New symbol_name_match_type parameter.
204 Use it.
205 (linespec_complete): New symbol_name_match_type parameter. Save
206 it in the parser and pass it down. Adjust to
207 get_linespec_location's prototype change.
208 (find_function_symbols, find_linespec_symbols): New
209 symbol_name_match_type parameter. Pass it down instead of
210 assuming symbol_name_match_type::WILD.
211 * linespec.h (linespec_complete, linespec_complete_function)
212 (linespec_complete_label): New symbol_name_match_type parameter.
213 * location.c (event_location::linespec_location): Now a struct
214 linespec_location.
215 (EL_LINESPEC): Adjust.
216 (initialize_explicit_location): Default to
217 symbol_name_match_type::WILD.
218 (new_linespec_location): New symbol_name_match_type parameter.
219 Record it in the location.
220 (get_linespec_location): Now returns a struct linespec_location.
221 (new_explicit_location): Also copy func_name_match_type.
222 (explicit_to_string_internal)
223 (string_to_explicit_location): Handle "-qualified".
224 (copy_event_location): Adjust to LINESPEC_LOCATION type change.
225 Copy symbol_name_match_type fields.
226 (event_location_deleter::operator()): Adjust to LINESPEC_LOCATION
227 type change.
228 (event_location_to_string): Adjust to LINESPEC_LOCATION type
229 change. Handle "-qualfied".
230 (string_to_explicit_location): Handle "-qualified".
231 (string_to_event_location_basic): New symbol_name_match_type
232 parameter. Pass it down.
233 (string_to_event_location): Handle "-qualified".
234 * location.h (struct linespec_location): New.
235 (explicit_location::func_name_match_type): New field.
236 (new_linespec_location): Now returns a const linespec_location *.
237 (string_to_event_location_basic): New symbol_name_match_type
238 parameter.
239 (explicit_completion_info::saw_explicit_location_option): New
240 field.
241 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Adjust to pass a
242 symbol_name_match_type to new_linespec_location.
243 * python/py-breakpoint.c (bppy_init): Likewise.
244 * python/python.c (gdbpy_decode_line): Likewise.
245
246 2017-11-29 Pedro Alves <palves@redhat.com>
247
248 * ada-lang.c (ada_lookup_name_info::matches): Change type of
249 parameter from completion_match to completion_match_result.
250 Adjust.
251 (do_wild_match, do_full_match, ada_symbol_name_matches): Likewise.
252 * completer.c (completion_tracker::maybe_add_completion): Add
253 match_for_lcd parameter and use it.
254 (completion_tracker::add_completion): Likewise.
255 * completer.h (class completion_match_for_lcd): New class.
256 (completion_match_result::match_for_lcd): New field.
257 (completion_match_result::set_match): New method.
258 (completion_tracker): Add comments.
259 (completion_tracker::add_completion): Add match_for_lcd parameter.
260 (completion_tracker::reset_completion_match_result): Reset
261 match_for_lcd too.
262 (completion_tracker::maybe_add_completion): Add match_for_lcd
263 parameter.
264 (completion_tracker::m_lowest_common_denominator_unique): Extend
265 comments.
266 * cp-support.c (cp_symbol_name_matches_1)
267 (cp_fq_symbol_name_matches): Change type of parameter from
268 completion_match to completion_match_result. Adjust.
269 * language.c (default_symbol_name_matcher): Change type of
270 parameter from completion_match to completion_match_result.
271 Adjust.
272 * language.h (completion_match_for_lcd): Forward declare.
273 (default_symbol_name_matcher): Change type of parameter from
274 completion_match to completion_match_result.
275 * symtab.c (compare_symbol_name): Adjust.
276 (completion_list_add_name): Pass the match_for_lcd to the tracker.
277 * symtab.h (ada_lookup_name_info::matches): Change type of
278 parameter from completion_match to completion_match_result.
279 (symbol_name_matcher_ftype): Likewise, and update comments.
280
281 2017-11-29 Pedro Alves <palves@redhat.com>
282
283 * linespec.c (minsym_found, add_minsym): Use msymbol_is_function.
284 * minsyms.c (msymbol_is_text): Delete.
285 (msymbol_is_function): New function.
286 * minsyms.h (msymbol_is_text): Delete.
287 (msymbol_is_function): New declaration.
288 * symtab.c (find_function_alias_target): Use msymbol_is_function.
289
290 2017-11-29 Tom Tromey <tom@tromey.com>
291
292 * Makefile.in (distclean): Handle the case where rmdir fails.
293
294 2017-11-29 Tom Tromey <tom@tromey.com>
295
296 * symfile.c (_initialize_symfile): Update usage text for
297 add-symbol-file, symbol-file, load.
298
299 2017-11-29 Tom Tromey <tom@tromey.com>
300
301 * symfile.c (add_symbol_file_command): Error if some arguments to
302 -s are missing. Change unrecognized-argument error message.
303 (_initialize_symfile): Fix usage text for add-symbol-file.
304
305 2017-11-27 Tom Tromey <tom@tromey.com>
306
307 * Makefile.in (REMOTE_OBS): Remove.
308 (SFILES): Remove remote sources.
309 (COMMON_SFILES): Add remote sources.
310 (ALLDEPFILES): Remove dcache.c.
311
312 2017-11-27 Tom Tromey <tom@tromey.com>
313
314 * Makefile.in (SUBDIR_TARGET_SRCS, SUBDIR_TARGET_OBS): New
315 variables.
316 (SFILES): Use SUBDIR_TARGET_SRCS.
317 (COMMON_OBS): Use SUBDIR_TARGET_OBS. Remove waitstatus.o.
318 (CONFIG_SRC_SUBDIR): Add target.
319 (%.o): Remove target rule.
320
321 2017-11-27 Tom Tromey <tom@tromey.com>
322
323 * Makefile.in (COMMON_OBS): Remove filename-seen-cache.o,
324 registry.o, thread-fsm.o, debug.o.
325 (COMMON_SFILES): Add filename-seen-cache.c, registry.c,
326 thread-fsm.c, debug.c.
327
328 2017-11-27 Tom Tromey <tom@tromey.com>
329
330 * Makefile.in (COMMON_SFILES): New.
331 (SFILES): Move some entries to COMMON_SFILES.
332 (COMMON_OBS): Use COMMON_SFILES.
333
334 2017-11-27 Tom Tromey <tom@tromey.com>
335
336 * Makefile.in (YYFILES): Update comment.
337 (YYOBJ): Redefine.
338
339 2017-11-27 Tom Tromey <tom@tromey.com>
340
341 * Makefile.in (SUBDIR_PYTHON_OBS): Redefine.
342 (CONFIG_SRC_SUBDIR): Add python.
343 (%.o): Remove python rule.
344 (python/%.o): New rule.
345 * configure: Rebuild.
346 * configure.ac (CONFIG_OBS): Refer to python/python.o
347
348 2017-11-27 Tom Tromey <tom@tromey.com>
349
350 * configure: Rebuild.
351 * configure.ac (CONFIG_OBS): Refer to guile/guile.o.
352 * Makefile.in (SUBDIR_GUILE_OBS): Redefine.
353 (CONFIG_SRC_SUBDIR): Add guile.
354 (%.o): Remove guile rule.
355
356 2017-11-27 Tom Tromey <tom@tromey.com>
357
358 * Makefile.in (SUBDIR_UNITTESTS_OBS): Redefine.
359 (%.o): Remove unittests rule.
360 (CONFIG_SRC_SUBDIR): Add unittests.
361
362 2017-11-27 Tom Tromey <tom@tromey.com>
363
364 * Makefile.in (SUBDIR_TUI_OBS): Redefine.
365 (CONFIG_SRC_SUBDIR): Add tui.
366 (%.o): Remove tui rule.
367
368 2017-11-27 Tom Tromey <tom@tromey.com>
369
370 * Makefile.in (SUBDIR_GCC_COMPILE_OBS): Redefine.
371 (%.o): Remove compile rule.
372 (CONFIG_SRC_SUBDIR): Add compile.
373
374 2017-11-27 Tom Tromey <tom@tromey.com>
375
376 * Makefile.in (SUBDIR_MI_OBS): Redefine.
377 (%.o): Remove mi rule.
378 (CONFIG_SRC_SUBDIR): Add mi.
379 (COMMON_OBS): Use mi/mi-common.o
380
381 2017-11-27 Tom Tromey <tom@tromey.com>
382
383 * Makefile.in (SUBDIR_CLI_OBS): Redefine.
384 (%.o): Remove cli rule.
385 (CONFIG_SRC_SUBDIR): Add cli.
386
387 2017-11-27 Tom Tromey <tom@tromey.com>
388
389 * configure.ac (CONFIG_SRC_SUBDIR): Don't subst.
390 * configure: Rebuild.
391 * Makefile.in (CONFIG_SRC_SUBDIR): Redefine.
392 (CONFIG_DEP_SUBDIR): New variable.
393 (%.o): Add order-only dependency.
394 ($(CONFIG_DEP_SUBDIR)): New target.
395
396 2017-11-26 Dominik Czarnota <dominik.b.czarnota@gmail.com>
397
398 PR gdb/21945
399 * findcmd.c (_initialize_mem_search): Update find command help
400 text.
401
402 2017-11-26 Simon Marchi <simon.marchi@polymtl.ca>
403
404 * python/python.c (do_start_initialization): Change progname
405 type to gdb::unique_xmalloc_ptr. Release the pointer when using
406 Python 2.
407
408 2017-11-26 Tom Tromey <tom@tromey.com>
409
410 * common/format.h: Add include guards.
411
412 2017-11-26 Tom Tromey <tom@tromey.com>
413
414 * nat/linux-personality.h (class
415 maybe_disable_address_space_randomization): New class.
416 (maybe_disable_address_space_randomization): Don't declare
417 function.
418 * nat/linux-personality.c (restore_personality)
419 (make_disable_asr_cleanup): Remove.
420 (maybe_disable_address_space_randomization): Now a constructor.
421 (~maybe_disable_address_space_randomization): New destructor.
422 * linux-nat.c (linux_nat_create_inferior): Update.
423
424 2017-11-26 Tom Tromey <tom@tromey.com>
425
426 * gcore.c (write_gcore_file_1): Use gdb::unique_xmalloc_ptr.
427
428 2017-11-26 Ulrich Weigand <uweigand@de.ibm.com>
429
430 * spu-tdep.c (spu_software_single_step): Access SPU_LSLR_REGNUM as
431 "cooked" register. Access only first four bytes of branch target
432 registers.
433
434 2017-11-25 Sergio Durigan Junior <sergiodj@redhat.com>
435
436 PR gdb/22491
437 * stap-probe.c (relocate_address): New function.
438 (stap_probe::get_relocated_address): Use 'relocate_address'.
439 (stap_probe::set_semaphore): Use 'relocate_address' and pass
440 'm_sem_addr'.
441 (stap_probe::clear_semaphore): Likewise.
442
443 2017-11-25 Pedro Alves <palves@redhat.com>
444
445 * dictionary.c: Include "safe-ctype.h".
446 * minsyms.c: Include "safe-ctype.h".
447 * minsyms.c (SYMBOL_HASH_NEXT): Use TOLOWER instead of tolower.
448
449 2017-11-25 Pedro Alves <palves@redhat.com>
450
451 * completer.c (complete_line_internal_1): Skip spaces until the
452 start of the command.
453
454 2017-11-24 Pedro Alves <palves@redhat.com>
455
456 * cp-support.c (cp_symbol_name_matches_1): New, factored out from
457 cp_fq_symbol_name_matches. Pass language_cplus to
458 strncmp_with_mode.
459 (cp_fq_symbol_name_matches): Call cp_symbol_name_matches_1.
460 (selftests::test_cp_symbol_name_cmp): New.
461 (_initialize_cp_support): Register "cp_symbol_name_matches"
462 selftests.
463 * language.c (default_symbol_name_matcher): Pass language_minimal
464 to strncmp_iw_with_mode.
465 * utils.c: Include "cp-support.h" and <algorithm>.
466 (valid_identifier_name_char, cp_skip_operator_token, skip_ws)
467 (cp_is_operator): New functions.
468 (strncmp_iw_with_mode): Use them. Add language parameter. Don't
469 skip whitespace in the symbol name when the lookup name doesn't
470 have spaces, and vice versa.
471 (strncmp_iw, strcmp_iw): Pass language to strncmp_iw_with_mode.
472 * utils.h (strncmp_iw_with_mode): Add language parameter.
473
474 2017-11-24 Joel Brobecker <brobecker@adacore.com>
475
476 * ada-lang.c (ada_exception_message_1, ada_exception_message):
477 New functions.
478 (print_it_exception): If available, display the exception
479 message as well.
480 * NEWS: Document new feature.
481
482 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
483
484 * configure.nat <spu-linux>: Add fork-inferior.o to NATDEPFILES.
485
486 2017-11-24 Philipp Rudo <prudo@linux.vnet.ibm.com>
487
488 * dtrace-probe.c (dtrace_probe::build_arg_exprs)
489 (dtrace_probe::is_enabled, dtrace_probe::enable)
490 (dtrace_probe::disable): Remove keyword 'struct' at for-range
491 variable
492 * probe.c (gen_ui_out_table_header_info)
493 (print_ui_out_not_applicables): Remove keyword 'struct' at
494 for-range variable
495
496 2017-11-24 Alan Hayward <alan.hayward@arm.com>
497
498 * configure.tgt: Add arch/aarch64.o
499
500 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
501
502 * common/common-utils.h: Include poison.h.
503 (xfree): Remove declaration, add definition with static_assert.
504 * common/common-utils.c (xfree): Remove.
505 * common/poison.h (IsMallocatable): Define.
506 (IsFreeable): Define.
507 (free): Delete for non-freeable types.
508 (xnew): New.
509 (XNEW): Undef and redefine.
510 (xcnew): New.
511 (XCNEW): Undef and redefine.
512 (xdelete): New.
513 (XDELETE): Undef and redefine.
514 (xnewvec): New.
515 (XNEWVEC): Undef and redefine.
516 (xcnewvec): New.
517 (XCNEWVEC): Undef and redefine.
518 (xresizevec): New.
519 (XRESIZEVEC): Undef and redefine.
520 (xdeletevec): New.
521 (XDELETEVEC): Undef and redefine.
522 (xnewvar): New.
523 (XNEWVAR): Undef and redefine.
524 (xcnewvar): New.
525 (XCNEWVAR): Undef and redefine.
526 (xresizevar): New.
527 (XRESIZEVAR): Undef and redefine.
528
529 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
530
531 * gdbthread.h (private_thread_info): Define structure type, add
532 virtual pure destructor.
533 (thread_info) <priv>: Change type to unique_ptr.
534 <private_dtor>: Remove.
535 * thread.c (add_thread_with_info): Adjust to use of unique_ptr.
536 (private_thread_info::~private_thread_info): Provide default
537 implementation.
538 (thread_info::~thread_info): Don't call private_dtor nor
539 manually free priv.
540 * aix-thread.c (private_thread_info): Rename to ...
541 (aix_thread_info): ... this.
542 (get_aix_thread_info): New.
543 (sync_threadlists): Adjust.
544 (iter_tid): Adjust.
545 (aix_thread_resume): Adjust.
546 (aix_thread_fetch_registers): Adjust.
547 (aix_thread_store_registers): Adjust.
548 (aix_thread_extra_thread_info): Adjust.
549 * darwin-nat.h (private_thread_info): Rename to ...
550 (darwin_thread_info): ... this.
551 (get_darwin_thread_info): New.
552 * darwin-nat.c (darwin_init_thread_list): Adjust.
553 (darwin_check_new_threads): Adjust.
554 (thread_info_from_private_thread_info): Adjust.
555 * linux-thread-db.c (private_thread_info): Rename to ...
556 (thread_db_thread_info): ... this, initialize fields.
557 (get_thread_db_thread_info): New.
558 <dying>: Change type to bool.
559 (update_thread_state): Adjust to type rename.
560 (record_thread): Adjust to type rename an use of unique_ptr.
561 (thread_db_pid_to_str): Likewise.
562 (thread_db_extra_thread_info): Likewise.
563 (thread_db_thread_handle_to_thread_info): Likewise.
564 (thread_db_get_thread_local_address): Likewise.
565 * nto-tdep.h (private_thread_info): Rename to ...
566 (nto_thread_info): ... this, initialize fields.
567 (get_nto_thread_info): New.
568 <name>: Change type to std::string.
569 * nto-tdep.c (nto_extra_thread_info): Adjust to type rename and
570 use of unique_ptr.
571 * nto-procfs.c (update_thread_private_data_name): Adjust to
572 std::string change, allocate nto_private_thread_info with new.
573 (update_thread_private_data): Adjust to unique_ptr.
574 * remote.c (private_thread_info): Rename to ...
575 (remote_thread_info): ... this, initialize data members with
576 default values.
577 <extra, name>: Change type to std::string.
578 <thread_handle>: Change type to non-pointer.
579 (free_private_thread_info): Remove.
580 (get_private_info_thread): Rename to...
581 (get_remote_thread_info): ... this, change return type, adjust to
582 use of unique_ptr, use remote_thread_info constructor.
583 (remote_add_thread): Adjust.
584 (get_private_info_ptid): Rename to...
585 (get_remote_thread_info): ...this, change return type.
586 (remote_thread_name): Use get_remote_thread_info, adjust to
587 change to std::string.
588 (struct thread_item) <~thread_item>: Remove.
589 <thread_handle>: Make non pointer.
590 (start_thread): Adjust to thread_item::thread_handle type
591 change.
592 (remote_update_thread_list): Adjust to type name change, move
593 strings from temporary to long-lived object instead of
594 duplicating.
595 (remote_threads_extra_info): Use get_remote_thread_info.
596 (process_initial_stop_replies): Likewise.
597 (resume_clear_thread_private_info): Likewise.
598 (remote_resume): Adjust to type name change.
599 (remote_commit_resume): Use get_remote_thread_info.
600 (process_stop_reply): Adjust to type name change.
601 (remote_stopped_by_sw_breakpoint): Use get_remote_thread_info.
602 (remote_stopped_by_hw_breakpoint): Likewise.
603 (remote_stopped_by_watchpoint): Likewise.
604 (remote_stopped_data_address): Likewise.
605 (remote_core_of_thread): Likewise.
606 (remote_thread_handle_to_thread_info): Use
607 get_private_info_thread, adjust to thread_handle field type
608 change.
609
610 2017-11-24 Simon Marchi <simon.marchi@polymtl.ca>
611
612 * remote.c (struct thread_item): Add constructor, disable copy
613 construction and copy assignment, define default move
614 construction and move assignment.
615 <extra, name>: Change type to std::string.
616 <core>: Initialize.
617 <thread_handle>: Make non-pointer.
618 (thread_item_t): Remove typedef.
619 (DEF_VEC_O(thread_item_t)): Remove.
620 (threads_listing_context) <contains_thread>: New method.
621 <remove_thread>: New method.
622 <items>: Change type to std::vector.
623 (clear_threads_listing_context): Remove.
624 (threads_listing_context_remove): Remove.
625 (remote_newthread_step): Use thread_item constructor, adjust to
626 change to std::vector.
627 (start_thread): Use thread_item constructor, adjust to change to
628 std::vector.
629 (end_thread): Adjust to change to std::vector and std::string.
630 (remote_get_threads_with_qthreadinfo): Use thread_item
631 constructor, adjust to std::vector.
632 (remote_update_thread_list): Adjust to change to std::vector and
633 std::string, use threads_listing_context methods.
634 (remove_child_of_pending_fork): Adjust.
635 (remove_new_fork_children): Adjust.
636 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add rsp-low-selftests.c.
637 (SUBDIR_UNITTESTS_OBS): Add rsp-low-selftests.o.
638 * unittests/rsp-low-selftests.c: New file.
639 * common/rsp-low.h: Include common/byte-vector.h.
640 (hex2bin): New overload.
641 * common/rsp-low.c (hex2bin): New overload.
642
643 2017-11-24 Simon Marchi <simon.marchi@ericsson.com>
644
645 * inferior.h (private_inferior): Define structure type, add
646 virtual pure destructor.
647 (inferior) <priv>: Change type to unique_ptr.
648 * inferior.c (private_inferior::~private_inferior): Provide
649 default implementation.
650 (inferior::~inferior): Don't free priv field.
651 (exit_inferior_1): Likewise.
652 * darwin-nat.h (struct darwin_exception_info): Initialize fields.
653 (darwin_exception_info): Remove typedef.
654 (DEF_VEC_O (darwin_thread_t)); Remove.
655 (private_inferior): Rename to ...
656 (darwin_private_inferior): ... this, extend private_inferior.
657 (get_darwin_inferior): New.
658 <threads>: Change type to std::vector of darwin_thread_t pointers.
659 * darwin-nat.c (darwin_check_new_threads): Adjust.
660 (find_inferior_task_it): Adjust.
661 (darwin_find_thread); Adjust.
662 (darwin_suspend_inferior): Adjust.
663 (darwin_resume_inferior): Adjust.
664 (darwin_find_new_inferior): Adjust.
665 (darwin_decode_notify_message): Adjust.
666 (darwin_send_reply): Adjust.
667 (darwin_resume_inferior_threads): Adjust.
668 (darwin_suspend_inferior_threads): Adjust.
669 (darwin_decode_message): Adjust.
670 (darwin_wait): Adjust.
671 (darwin_interrupt): Adjust.
672 (darwin_deallocate_threads): Adjust.
673 (darwin_mourn_inferior): Adjust, don't free private data.
674 (darwin_reply_to_all_pending_messages): Adjust.
675 (darwin_stop_inferior): Adjust.
676 (darwin_setup_exceptions): Adjust.
677 (darwin_kill_inferior): Adjust.
678 (darwin_setup_request_notification): Adjust.
679 (darwin_attach_pid): Adjust.
680 (darwin_init_thread_list): Adjust.
681 (darwin_setup_fake_stop_event): Adjust.
682 (darwin_attach): Adjust.
683 (darwin_detach): Adjust.
684 (darwin_xfer_partial): Adjust.
685 (set_enable_mach_exceptions): Adjust.
686 (darwin_pid_to_exec_file): Adjust.
687 (darwin_get_ada_task_ptid): Adjust.
688 * darwin-nat-info.c (get_task_from_args): Adjust.
689 (info_mach_ports_command): Adjust.
690 (info_mach_region_command): Adjust.
691 (info_mach_exceptions_command): Adjust.
692 * remote.c (private_inferior): Rename to ...
693 (remote_private_inferior): ... this, initialize fields.
694 (get_remote_inferior); New.
695 (remote_commit_resume): Use get_remote_inferior.
696 (check_pending_event_prevents_wildcard_vcont_callback): Likewise.
697
698 2017-11-24 Pedro Alves <palves@redhat.com>
699
700 * NEWS: Mention linespecs and explicit locations, and completion
701 improvements.
702
703 2017-11-24 Yao Qi <yao.qi@linaro.org>
704
705 * regcache.c (regcache::dump): Remove footnote_register_size.
706
707 2017-11-24 Yao Qi <yao.qi@linaro.org>
708
709 * regcache.c (cooked_read_test): Add more test for readonly
710 regcache.
711
712 2017-11-24 Yao Qi <yao.qi@linaro.org>
713
714 * gdbarch-selftests.c (test_target_has_registers): Move it to
715 target.c.
716 (test_target_has_stack): Likewise.
717 (test_target_has_memory): Likewise.
718 (test_target_prepare_to_store): Likewise.
719 (test_target_store_registers): Likewise.
720 (test_target_ops): Likewise.
721 * regcache.c: Include selftest-arch.h and gdbthread.h.
722 (target_ops_no_register): New class.
723 (test_target_fetch_registers): New.
724 (test_target_store_registers): New.
725 (test_target_xfer_partial): New.
726 (readwrite_regcache): New.
727 (cooked_read_test): New.
728 (_initialize_regcache): Register the test.
729 * target.c: (test_target_has_registers): Moved from
730 gdbarch-selftests.c.
731 (test_target_has_stack): Likewise.
732 (test_target_has_memory): Likewise.
733 (test_target_prepare_to_store): Likewise.
734 (test_target_store_registers): Likewise.
735 * target.h (test_target_ops): New class.
736
737 2017-11-24 Alan Hayward <alan.hayward@arm.com>
738
739 * aarch64-tdep.c (_initialize_aarch64_tdep): Add target desc
740 selftest.
741
742 2017-11-24 Alan Hayward <alan.hayward@arm.com>
743
744 * aarch64-tdep.c (_initialize_aarch64_tdep): Remove init.
745 * arch/aarch64.c (aarch64_create_target_description): Create
746 new target description.
747 * features/Makefile: Add new files.
748 * features/aarch64.c: Remove file.
749 * features/aarch64-core.c: New autogenerated file.
750 * features/aarch64-fpu.c: New autogenerated file.
751 * target-descriptions.c (maint_print_c_tdesc_cmd): Check for aarch64.
752
753 2017-11-24 Alan Hayward <alan.hayward@arm.com>
754
755 * Makefile.in: Add new files.
756 * aarch64-linux-nat.c (aarch64_linux_read_description): Call
757 aarch64_read_description.
758 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
759 Call aarch64_read_description.
760 * aarch64-tdep.c (aarch64_read_description): New function.
761 (aarch64_gdbarch_init): Call aarch64_read_description.
762 * aarch64-tdep.h (aarch64_read_description): New function.
763 * arch/aarch64.c: New file.
764 * configure.tgt: Add new files.
765
766 2017-11-24 Yao Qi <yao.qi@linaro.org>
767
768 * mi/mi-main.c (register_changed_p): Update.
769 * value.c (value_contents_bits_eq): Change return type.
770 (value_contents_eq): Likewise.
771 * value.h: Update comments.
772
773 2017-11-24 Yao Qi <yao.qi@linaro.org>
774
775 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Remove
776 local 'changed'. Remove error.
777 (register_changed_p): Change return type to bool.
778
779 2017-11-24 Yao Qi <yao.qi@linaro.org>
780
781 * arch/tic6x.c: New file.
782 * arch/tic6x.h: New file.
783 * features/Makefile (FEATURE_XMLFILES): Add tic6x-c6xp.xml,
784 tic6x-core.xml and tic6x-gp.xml.
785 * features/tic6x-c6xp.c: Generated.
786 * features/tic6x-core.c: Generated.
787 * features/tic6x-gp.c: Generated.
788 * target-descriptions.c (maint_print_c_tdesc_cmd): Match
789 "tic6x-".
790
791 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
792
793 * mi/mi-main.c (list_available_thread_groups): Change map value
794 type to std::vector.
795
796 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
797
798 * osdata.c (osdata_end_column, get_osdata): Remove std::move.
799
800 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
801
802 * varobj.c (struct varobj_dynamic) <children_requested_>: Rename
803 back to...
804 <children_requested>: ... this.
805 (varobj_get_num_children, varobj_update): Adjust.
806
807 2017-11-23 Simon Marchi <simon.marchi@ericsson.com>
808
809 * ada-varobj.c (ada_value_is_changeable_p): Change int to bool where applicable.
810 (ada_value_has_mutated): Likewise.
811 * c-varobj.c (varobj_is_anonymous_child): Likewise.
812 (c_is_path_expr_parent): Likewise.
813 * mi/mi-cmd-var.c (varobj_update_one): Likewise.
814 (mi_cmd_var_set_frozen): Likewise.
815 (mi_cmd_var_update_iter): Likewise.
816 (mi_cmd_var_update): Likewise.
817 * varobj.c (pretty_printing): Likewise.
818 (varobj_enable_pretty_printing): Likewise.
819 (struct varobj_root) <floating, is_valid>: Likewise.
820 (struct varobj_dynamic) <children_requested>: Likewise.
821 (delete_variable): Likewise.
822 (delete_variable_1): Likewise.
823 (install_variable): Likewise.
824 (update_type_if_necessary): Likewise.
825 (install_new_value): Likewise.
826 (value_of_root): Likewise.
827 (is_root_p): Likewise.
828 (varobj_create): Likewise.
829 (varobj_delete): Likewise.
830 (varobj_has_more): Likewise.
831 (varobj_set_frozen): Likewise.
832 (varobj_get_frozen): Likewise.
833 (install_dynamic_child): Likewise.
834 (dynamic_varobj_has_child_method): Likewise.
835 (update_dynamic_varobj_children): Likewise.
836 (varobj_get_num_children): Likewise.
837 (varobj_list_children): Likewise.
838 (is_path_expr_parent): Likewise.
839 (varobj_default_is_path_expr_parent): Likewise.
840 (varobj_is_dynamic_p): Likewise.
841 (varobj_set_value): Likewise.
842 (varobj_value_has_mutated): Likewise.
843 (varobj_update): Likewise.
844 (check_scope): Likewise.
845 (value_of_root_1): Likewise.
846 (varobj_value_get_print_value): Likewise.
847 (varobj_editable_p): Likewise.
848 (varobj_value_is_changeable_p): Likewise.
849 (varobj_floating_p): Likewise.
850 (varobj_default_value_is_changeable_p): Likewise.
851 (varobj_invalidate_iter): Likewise.
852 * varobj.h (struct varobj_update_result) <type_changed,
853 children_changed, changed, value_installed>: Likewise.
854 (struct varobj) <updated, frozen, not_fetched>: Likewise.
855 (struct lang_varobj_ops) <value_is_changeable_p,
856 value_has_mutated, is_path_expr_parent>: Likewise.
857 (varobj_delete): Likewise.
858 (varobj_set_frozen): Likewise.
859 (varobj_get_frozen): Likewise.
860 (varobj_set_value): Likewise.
861 (varobj_update): Likewise.
862 (varobj_editable_p): Likewise.
863 (varobj_floating_p): Likewise.
864 (varobj_has_more): Likewise.
865 (varobj_is_dynamic_p): Likewise.
866 (varobj_default_value_is_changeable_p): Likewise.
867 (varobj_value_is_changeable_p): Likewise.
868 (varobj_is_anonymous_child): Likewise.
869 (varobj_default_is_path_expr_parent): Likewise.
870
871 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
872
873 * dtrace-probe.c (struct probe_ops dtrace_probe_ops): Delete.
874 (struct dtrace_probe_arg) <dtrace_probe_arg>: New constructor.
875 <type_str>: Convert to 'std::string'.
876 <expr>: Convert to 'expression_up'.
877 (dtrace_probe_arg_s): Delete type and VEC.
878 (dtrace_probe_enabler_s): Likewise.
879 (struct dtrace_probe): Replace by...
880 (class dtrace_static_probe_ops): ...this and...
881 (class dtrace_probe): ...this.
882 (dtrace_probe_is_linespec): Rename to...
883 (dtrace_static_probe_ops::is_linespec): ...this. Adjust code
884 to reflect change.
885 (dtrace_process_dof_probe): Use 'std::vector' instead of VEC.
886 Adjust code. Create new instance of 'dtrace_probe'.
887 (dtrace_build_arg_exprs): Rename to...
888 (dtrace_probe::build_arg_exprs): ...this. Adjust code to
889 reflect change.
890 (dtrace_get_probes): Rename to...
891 (dtrace_static_probe_ops::get_probes): ...this. Adjust code
892 to reflect change.
893 (dtrace_get_arg): Rename to...
894 (dtrace_probe::get_arg_by_number): ...this. Adjust code to
895 reflect change.
896 (dtrace_probe_is_enabled): Rename to...
897 (dtrace_probe::is_enabled): ...this. Adjust code to reflect
898 change.
899 (dtrace_get_probe_address): Rename to...
900 (dtrace_probe::get_relocated_address): ...this. Adjust code
901 to reflect change.
902 (dtrace_get_probe_argument_count): Rename to...
903 (dtrace_probe::get_argument_count): ...this. Adjust code to
904 reflect change.
905 (dtrace_can_evaluate_probe_arguments): Rename to...
906 (dtrace_probe::can_evaluate_arguments): ...this. Adjust code
907 to reflect change.
908 (dtrace_evaluate_probe_argument): Rename to...
909 (dtrace_probe::evaluate_argument): ...this. Adjust code to
910 reflect change.
911 (dtrace_compile_to_ax): Rename to...
912 (dtrace_probe::compile_to_ax): ...this. Adjust code to
913 reflect change.
914 (dtrace_probe_destroy): Delete.
915 (dtrace_type_name): Rename to...
916 (dtrace_static_probe_ops::type_name): ...this. Adjust code to
917 reflect change.
918 (dtrace_probe::get_static_ops): New method.
919 (dtrace_gen_info_probes_table_header): Rename to...
920 (dtrace_static_probe_ops::gen_info_probes_table_header):
921 ...this. Adjust code to reflect change.
922 (dtrace_gen_info_probes_table_values): Rename to...
923 (dtrace_probe::gen_info_probes_table_values): ...this. Adjust
924 code to reflect change.
925 (dtrace_enable_probe): Rename to...
926 (dtrace_probe::enable_probe): ...this. Adjust code to reflect
927 change.
928 (dtrace_disable_probe): Rename to...
929 (dtrace_probe::disable_probe): ...this. Adjust code to reflect
930 change.
931 (struct probe_ops dtrace_probe_ops): Delete.
932 (info_probes_dtrace_command): Call 'info_probes_for_spops'
933 instead of 'info_probes_for_ops'.
934 (_initialize_dtrace_probe): Use 'all_static_probe_ops' instead
935 of 'all_probe_ops'.
936
937 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
938 Simon Marchi <simark@simark.ca>
939
940 * stap-probe.c (struct probe_ops stap_probe_ops): Delete
941 variable.
942 (struct stap_probe_arg) <stap_probe_arg>: New constructor.
943 <aexpr>: Change type to 'expression_up'.
944 (stap_probe_arg_s): Delete type and VEC.
945 (struct stap_probe): Delete. Replace by...
946 (class stap_static_probe_ops): ...this and...
947 (class stap_probe): ...this. Rename variables to add 'm_'
948 prefix. Do not use 'union' for arguments anymore.
949 (stap_get_expected_argument_type): Receive probe name instead
950 of 'struct stap_probe'. Adjust code.
951 (stap_parse_probe_arguments): Rename to...
952 (stap_probe::parse_arguments): ...this. Adjust code to
953 reflect change.
954 (stap_get_probe_address): Rename to...
955 (stap_probe::get_relocated_address): ...this. Adjust code
956 to reflect change.
957 (stap_get_probe_argument_count): Rename to...
958 (stap_probe::get_argument_count): ...this. Adjust code
959 to reflect change.
960 (stap_get_arg): Rename to...
961 (stap_probe::get_arg_by_number'): ...this. Adjust code to
962 reflect change.
963 (can_evaluate_probe_arguments): Rename to...
964 (stap_probe::can_evaluate_arguments): ...this. Adjust code
965 to reflect change.
966 (stap_evaluate_probe_argument): Rename to...
967 (stap_probe::evaluate_argument): ...this. Adjust code
968 to reflect change.
969 (stap_compile_to_ax): Rename to...
970 (stap_probe::compile_to_ax): ...this. Adjust code to
971 reflect change.
972 (stap_probe_destroy): Delete.
973 (stap_modify_semaphore): Adjust comment.
974 (stap_set_semaphore): Rename to...
975 (stap_probe::set_semaphore): ...this. Adjust code to reflect
976 change.
977 (stap_clear_semaphore): Rename to...
978 (stap_probe::clear_semaphore): ...this. Adjust code to
979 reflect change.
980 (stap_probe::get_static_ops): New method.
981 (handle_stap_probe): Adjust code to create instance of
982 'stap_probe'.
983 (stap_get_probes): Rename to...
984 (stap_static_probe_ops::get_probes): ...this. Adjust code to
985 reflect change.
986 (stap_probe_is_linespec): Rename to...
987 (stap_static_probe_ops::is_linespec): ...this. Adjust code to
988 reflect change.
989 (stap_type_name): Rename to...
990 (stap_static_probe_ops::type_name): ...this. Adjust code to
991 reflect change.
992 (stap_gen_info_probes_table_header): Rename to...
993 (stap_static_probe_ops::gen_info_probes_table_header):
994 ...this. Adjust code to reflect change.
995 (stap_gen_info_probes_table_values): Rename to...
996 (stap_probe::gen_info_probes_table_values): ...this. Adjust
997 code to reflect change.
998 (struct probe_ops stap_probe_ops): Delete.
999 (info_probes_stap_command): Use 'info_probes_for_spops'
1000 instead of 'info_probes_for_ops'.
1001 (_initialize_stap_probe): Use 'all_static_probe_ops' instead
1002 of 'all_probe_ops'.
1003
1004 2017-11-22 Sergio Durigan Junior <sergiodj@redhat.com>
1005
1006 * break-catch-throw.c (fetch_probe_arguments): Use
1007 'probe.prob' instead of 'probe.probe'.
1008 * breakpoint.c (create_longjmp_master_breakpoint): Call
1009 'can_evaluate_arguments' and 'get_relocated_address' methods
1010 from probe.
1011 (create_exception_master_breakpoint): Likewise.
1012 (add_location_to_breakpoint): Use 'sal->prob' instead of
1013 'sal->probe'.
1014 (bkpt_probe_insert_location): Call 'set_semaphore' method from
1015 probe.
1016 (bkpt_probe_remove_location): Likewise, for 'clear_semaphore'.
1017 * elfread.c (elf_get_probes): Use 'static_probe_ops' instead
1018 of 'probe_ops'.
1019 (probe_key_free): Call 'delete' on probe.
1020 (check_exception_resume): Use 'probe.prob' instead of
1021 'probe.probe'.
1022 * location.c (string_to_event_location_basic): Call
1023 'probe_linespec_to_static_ops'.
1024 * probe.c (class any_static_probe_ops): New class.
1025 (any_static_probe_ops any_static_probe_ops): New variable.
1026 (parse_probes_in_pspace): Receive 'static_probe_ops' as
1027 argument. Adjust code to reflect change.
1028 (parse_probes): Use 'static_probe_ops' instead of
1029 'probe_ops'. Adjust code to reflect change.
1030 (find_probes_in_objfile): Call methods to get name and
1031 provider from probe.
1032 (find_probe_by_pc): Use 'result.prob' instead of
1033 'result.probe'. Call 'get_relocated_address' method from
1034 probe.
1035 (collect_probes): Adjust comment and argument list to receive
1036 'static_probe_ops' instead of 'probe_ops'. Adjust code to
1037 reflect change. Call necessary methods from probe.
1038 (compare_probes): Call methods to get name and provider from
1039 probes.
1040 (gen_ui_out_table_header_info): Receive 'static_probe_ops'
1041 instead of 'probe_ops'. Use 'std::vector' instead of VEC,
1042 adjust code accordingly.
1043 (print_ui_out_not_applicables): Likewise.
1044 (info_probes_for_ops): Rename to...
1045 (info_probes_for_spops): ...this. Receive 'static_probe_ops'
1046 as argument instead of 'probe_ops'. Adjust code. Call
1047 necessary methods from probe.
1048 (info_probes_command): Use 'info_probes_for_spops'.
1049 (enable_probes_command): Pass correct argument to
1050 'collect_probes'. Call methods from probe.
1051 (disable_probes_command): Likewise.
1052 (get_probe_address): Move to 'any_static_probe_ops::get_address'.
1053 (get_probe_argument_count): Move to
1054 'any_static_probe_ops::get_argument_count'.
1055 (can_evaluate_probe_arguments): Move to
1056 'any_static_probe_ops::can_evaluate_arguments'.
1057 (evaluate_probe_argument): Move to
1058 'any_static_probe_ops::evaluate_argument'.
1059 (probe_safe_evaluate_at_pc): Use 'probe.prob' instead of
1060 'probe.probe'.
1061 (probe_linespec_to_ops): Rename to...
1062 (probe_linespec_to_static_ops): ...this. Adjust code.
1063 (probe_any_is_linespec): Rename to...
1064 (any_static_probe_ops::is_linespec): ...this.
1065 (probe_any_get_probes): Rename to...
1066 (any_static_probe_ops::get_probes): ...this.
1067 (any_static_probe_ops::type_name): New method.
1068 (any_static_probe_ops::gen_info_probes_table_header): New
1069 method.
1070 (compute_probe_arg): Use 'pc_probe.prob' instead of
1071 'pc_probe.probe'. Call methods from probe.
1072 (compile_probe_arg): Likewise.
1073 (std::vector<const probe_ops *> all_probe_ops): Delete.
1074 (std::vector<const static_probe_ops *> all_static_probe_ops):
1075 New variable.
1076 (_initialize_probe): Use 'all_static_probe_ops' instead of
1077 'all_probe_ops'.
1078 * probe.h (struct info_probe_column) <field_name>: Delete
1079 extraneous newline
1080 (info_probe_column_s): Delete type and VEC.
1081 (struct probe_ops): Delete. Replace with...
1082 (class static_probe_ops): ...this and...
1083 (clas probe): ...this.
1084 (struct bound_probe) <bound_probe>: Delete extraneous
1085 newline. Adjust constructor to receive 'probe' instead of
1086 'struct probe'.
1087 <probe>: Rename to...
1088 <prob>: ...this. Delete extraneous newline.
1089 <objfile>: Delete extraneous newline.
1090 (register_probe_ops): Delete unused prototype.
1091 (info_probes_for_ops): Rename to...
1092 (info_probes_for_spops): ...this. Adjust comment.
1093 (get_probe_address): Move to 'probe::get_address'.
1094 (get_probe_argument_count): Move to
1095 'probe::get_argument_count'.
1096 (can_evaluate_probe_arguments): Move to
1097 'probe::can_evaluate_arguments'.
1098 (evaluate_probe_argument): Move to 'probe::evaluate_argument'.
1099 * solib-svr4.c (struct svr4_info): Adjust comment.
1100 (struct probe_and_action) <probe>: Rename to...
1101 <prob>: ...this.
1102 (register_solib_event_probe): Receive 'probe' instead of
1103 'struct probe' as argument. Use 'prob' instead of 'probe'
1104 when applicable.
1105 (solib_event_probe_action): Call 'get_argument_count' method
1106 from probe. Adjust comment.
1107 (svr4_handle_solib_event): Adjust comment. Call
1108 'evaluate_argument' method from probe.
1109 (svr4_create_probe_breakpoints): Call 'get_relocated_address'
1110 from probe.
1111 (svr4_create_solib_event_breakpoints): Use 'probe' instead of
1112 'struct probe'. Call 'can_evaluate_arguments' from probe.
1113 * symfile.h: Forward declare 'class probe' instead of 'struct
1114 probe'.
1115 * symtab.h: Likewise.
1116 (struct symtab_and_line) <probe>: Rename to...
1117 <prob>: ...this.
1118 * tracepoint.c (start_tracing): Use 'prob' when applicable.
1119 Call probe methods.
1120 (stop_tracing): Likewise.
1121
1122 2017-11-22 Joel Brobecker <brobecker@adacore.com>
1123
1124 * ravenscar-thread.c (ravenscar_inferior_created): Remove
1125 trailing newline at end of string in call to warning.
1126
1127 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1128
1129 * osdata.h: Include vector isntead of vec.h.
1130 (osdata_column_s): Remove typedef.
1131 (struct osdata_column): Add constructor.
1132 <name, value>: Change type to std::string.
1133 (DEF_VEC_O (osdata_column_s)): Remove.
1134 (osdata_item_s): Remove typedef.
1135 (struct osdata_item) <columns>: Change type to std::vector.
1136 (DEF_VEC_O (osdata_item_s)): Remove.
1137 (struct osdata): Add constructor.
1138 <type>: Change type to std::string.
1139 <items>: Change type to std::vector.
1140 (osdata_p): Remove typedef.
1141 (DEF_VEC_P (osdata_p)): Remove.
1142 (osdata_parse): Return a unique_ptr.
1143 (osdata_free): Remove.
1144 (make_cleanup_osdata_free): Remove.
1145 (get_osdata): Return a unique_ptr.
1146 (get_osdata_column): Return pointer to std::string, take a
1147 reference to osdata_item as parameter.
1148 * osdata.c (struct osdata_parsing_data) <osdata>: Change type to
1149 unique_ptr.
1150 <property_name>: Change type to std::string.
1151 (osdata_start_osdata): Allocate osdata with new and adjust.
1152 (osdata_start_item): Adjust.
1153 (osdata_start_column): Adjust.
1154 (osdata_end_column): Adjust.
1155 (clear_parsing_data): Remove.
1156 (osdata_parse): Return a unique_ptr and adjust, remove cleanup.
1157 (osdata_item_clear): Remove.
1158 (get_osdata): return a unique_ptr and adjust.
1159 (get_osdata_column): Return a pointer to std::string and adjust.
1160 (info_osdata): Adjust.
1161 * mi/mi-main.c: Include <map>.
1162 (free_vector_of_osdata_items): Remove.
1163 (list_available_thread_groups): Adjust, use std::map instead of
1164 splay tree.
1165
1166 2017-11-22 Simon Marchi <simon.marchi@ericsson.com>
1167
1168 * stack.c (iterate_over_block_locals): Add LOC_OPTIMIZED_OUT
1169 case in switch.
1170
1171 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1172
1173 * varobj.h (DEF_VEC_P (varobj_p)): Remove.
1174
1175 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1176
1177 * varobj.h (struct varobj_update_result): Add constructor, add
1178 move constructor, disable copy and assign, initialize fields.
1179 <newobj>: Change type to std::vector.
1180 (varobj_update): Return std::vector.
1181 * varobj.c (install_dynamic_child): Change VEC parameters to
1182 std::vector and adjust.
1183 (update_dynamic_varobj_children): Likewise.
1184 (varobj_update): Return std::vector and adjust.
1185 * mi/mi-cmd-var.c (varobj_update_one): Adjust to vector changes.
1186
1187 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1188
1189 * varobj.h (struct varobj) <parent>: Remove const.
1190 <children>: Change type to std::vector.
1191 (varobj_list_children): Return std::vector const reference.
1192 (varobj_restrict_range): Change parameter type to std::vector
1193 const reference.
1194 * varobj.c (varobj_has_more): Adjust.
1195 (varobj_restrict_range): Change parameter type to std::vector
1196 const reference and adjust.
1197 (install_dynamic_child): Adjust.
1198 (update_dynamic_varobj_children): Adjust.
1199 (varobj_list_children): Return std::vector const reference and
1200 adjust.
1201 (varobj_add_child): Adjust.
1202 (update_type_if_necessary): Adjust.
1203 (varobj_update): Adjust.
1204 (delete_variable_1): Adjust.
1205 * ada-varobj.c (ada_value_has_mutated): Adjust.
1206 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Adjust.
1207
1208 2017-11-22 Simon Marchi <simon.marchi@polymtl.ca>
1209
1210 * varobj.h (struct varobj): Add constructor and destructor,
1211 initialize fields.
1212 * varobj.c (struct varobj_root): Initialize fields.
1213 (struct varobj_dynamic): Initialize fields.
1214 (varobj_create): Use unique_ptr instead of cleanup. Create
1215 varobj with new instead of new_root_variable.
1216 (delete_variable_1): Free variable with delete instead of
1217 free_variable.
1218 (create_child_with_value): Create variable with new instead of
1219 new_variable.
1220 (varobj::varobj): New.
1221 (varobj::~varobj): New (body mostly coming from free_variable).
1222 (new_variable): Remove.
1223 (free_variable): Remove.
1224 (do_free_variable_cleanup): Remove.
1225 (make_cleanup_free_variable): Remove.
1226
1227 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1228
1229 * core-regset.c: Remove file.
1230 * Makefile.in (ALLDEPFILES): Remove core-regset.c.
1231
1232 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1233
1234 * NEWS: Document use of GNU MPFR.
1235 * README: Likewise.
1236
1237 * Makefile.in (LIBMPFR): Add define.
1238 (CLIBS): Add $(LIBMPFR).
1239 * configure.ac: Add --with-mpfr configure option.
1240 * configure: Regenerate.
1241 * config.in: Regenerate.
1242
1243 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
1244 (class mpfr_float_ops): New type.
1245 (mpfr_float_ops::from_target): Two new overloaded functions.
1246 (mpfr_float_ops::to_target): Likewise.
1247 (mpfr_float_ops::to_string): New function.
1248 (mpfr_float_ops::from_string): Likewise.
1249 (mpfr_float_ops::to_longest): Likewise.
1250 (mpfr_float_ops::from_longest): Likewise.
1251 (mpfr_float_ops::from_ulongest): Likewise.
1252 (mpfr_float_ops::to_host_double): Likewise.
1253 (mpfr_float_ops::from_host_double): Likewise.
1254 (mpfr_float_ops::convert): Likewise.
1255 (mpfr_float_ops::binop): Likewise.
1256 (mpfr_float_ops::compare): Likewise.
1257 (get_target_float_ops): Use mpfr_float_ops if available.
1258
1259 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
1260
1261 * target-float.c: Do not include <math.h>.
1262 Include <cmath> and <limits>.
1263 (DOUBLEST): Do not define.
1264 (class target_float_ops): New type.
1265 (class host_float_ops): New templated type.
1266 (class decimal_float_ops): New type.
1267
1268 (floatformat_to_doublest): Rename to ...
1269 (host_float_ops<T>::from_target): ... this. Use template type T
1270 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1271 (host_float_ops<T>::from_target): New overload using a type argument.
1272 (floatformat_from_doublest): Rename to ...
1273 (host_float_ops<T>::to_target): ... this. Use template type T
1274 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
1275 (host_float_ops<T>::to_target): New overload using a type argument.
1276 (floatformat_printf_format): New function.
1277 (struct printf_length_modifier): New templated type.
1278 (floatformat_to_string): Rename to ...
1279 (host_float_ops<T>::to_string): ... this. Use type instead of
1280 floatformat argument. Use floatformat_printf_format and
1281 printf_length_modifier. Remove special handling of invalid numbers,
1282 infinities and NaN (moved to target_float_to_string).
1283 (struct scanf_length_modifier): New templated type.
1284 (floatformat_from_string): Rename to ...
1285 (host_float_ops<T>::from_string): ... this. Use type instead of
1286 floatformat argument. Use scanf_length_modifier.
1287 (floatformat_to_longest): Rename to ...
1288 (host_float_ops<T>::to_longest): ... this. Use type instead of
1289 floatformat argument. Handle out-of-range values deterministically.
1290 (floatformat_from_longest): Rename to ...
1291 (host_float_ops<T>::from_longest): ... this. Use type instead of
1292 floatformat argument.
1293 (floatformat_from_ulongest): Rename to ...
1294 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
1295 floatformat argument.
1296 (floatformat_to_host_double): Rename to ...
1297 (host_float_ops<T>::to_host_double): ... this. Use type instead of
1298 floatformat argument.
1299 (floatformat_from_host_double): Rename to ...
1300 (host_float_ops<T>::from_host_double): ... this. Use type instead of
1301 floatformat argument.
1302 (floatformat_convert): Rename to ...
1303 (host_float_ops<T>::convert): ... this. Use type instead of
1304 floatformat arguments. Remove handling of no-op conversions.
1305 (floatformat_binop): Rename to ...
1306 (host_float_ops<T>::binop): ... this. Use type instead of
1307 floatformat arguments.
1308 (floatformat_compare): Rename to ...
1309 (host_float_ops<T>::compare): ... this. Use type instead of
1310 floatformat arguments.
1311
1312 (match_endianness): Use type instead of length/byte_order arguments.
1313 (set_decnumber_context): Likewise.
1314 (decimal_from_number): Likewise. Update calls.
1315 (decimal_to_number): Likewise.
1316 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
1317 (decimal_float_ops::to_host_double): New dummy function.
1318 (decimal_float_ops::from_host_double): Likewise.
1319 (decimal_to_string): Rename to ...
1320 (decimal_float_ops::to_string): ... this. Use type instead of
1321 length/byte_order arguments. Update calls.
1322 (decimal_from_string): Rename to ...
1323 (decimal_float_ops::from_string): ... this. Use type instead of
1324 length/byte_order arguments. Update calls.
1325 (decimal_from_longest): Rename to ...
1326 (decimal_float_ops::from_longest): ... this. Use type instead of
1327 length/byte_order arguments. Update calls.
1328 (decimal_from_ulongest): Rename to ...
1329 (decimal_float_ops::from_ulongest): ... this. Use type instead of
1330 length/byte_order arguments. Update calls.
1331 (decimal_to_longest): Rename to ...
1332 (decimal_float_ops::to_longest): ... this. Use type instead of
1333 length/byte_order arguments. Update calls.
1334 (decimal_binop): Rename to ...
1335 (decimal_float_ops::binop): ... this. Use type instead of
1336 length/byte_order arguments. Update calls.
1337 (decimal_compare): Rename to ...
1338 (decimal_float_ops::compare): ... this. Use type instead of
1339 length/byte_order arguments. Update calls.
1340 (decimal_convert): Rename to ...
1341 (decimal_float_ops::convert): ... this. Use type instead of
1342 length/byte_order arguments. Update calls.
1343
1344 (target_float_same_category_p): New function.
1345 (target_float_same_format_p): Likewise.
1346 (target_float_format_length): Likewise.
1347 (enum target_float_ops_kind): New type.
1348 (get_target_float_ops_kind): New function.
1349 (get_target_float_ops): Three new overloaded functions.
1350
1351 (target_float_is_zero): Update call.
1352 (target_float_to_string): Add special handling of invalid numbers,
1353 infinities and NaN (moved from floatformat_to_string). Use
1354 target_float_ops callback.
1355 (target_float_from_string): Use target_float_ops callback.
1356 (target_float_to_longest): Likewise.
1357 (target_float_from_longest): Likewise.
1358 (target_float_from_ulongest): Likewise.
1359 (target_float_to_host_double): Likewise.
1360 (target_float_from_host_double): Likewise.
1361 (target_float_convert): Add special case for no-op conversions.
1362 Use target_float_ops callback.
1363 (target_float_binop): Use target_float_ops callback.
1364 (target_float_compare): Likewise.
1365
1366 2017-11-22 Yao Qi <yao.qi@linaro.org>
1367
1368 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
1369
1370 2017-11-22 Yao Qi <yao.qi@linaro.org>
1371
1372 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
1373 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
1374
1375 2017-11-21 Jerome Guitton <guitton@adacore.com>
1376
1377 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
1378 with event ptid from the lower layer before doing the
1379 ravenscar-specific update.
1380
1381 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1382
1383 * ravenscar-thread.c (is_ravenscar_task): Also verify that
1384 the ptid's TID is nonzero.
1385
1386 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1387
1388 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
1389 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
1390 Make non-static. Change return type to char *. Adjust code
1391 accordingly. Rewrite the function's documentation.
1392 (read_atcb): Adjust call to get_tcb_types_info accordingly.
1393 * ravenscar-thread.c (ravenscar_inferior_created): Check that
1394 we have enough debugging information in the runtime to support
1395 Ada task debugging before we enable the ravenscar-thread layer.
1396
1397 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1398
1399 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
1400 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
1401 * ravenscar-thread.c: Add into comment.
1402 (base_magic_null_ptid): Delete.
1403 (base_ptid): Change documentation.
1404 (ravenscar_active_task): Renames ravenscar_running_thread.
1405 All callers updated throughout.
1406 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
1407 (ravenscar_task_is_currently_active): Likewise.
1408 (get_base_thread_from_ravenscar_task): Ditto.
1409 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
1410 (ravenscar_runtime_initialized): Likewise.
1411 (get_running_thread_id): Add new parameter "cpu". Adjust
1412 implementation to handle this new parameter.
1413 (ravenscar_fetch_registers): Small adjustment to use
1414 is_ravenscar_task and ravenscar_task_is_currently_active in
1415 order to decide whether to use the target beneath or this
1416 module's arch_ops.
1417 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
1418 (ravenscar_stopped_by_sw_breakpoint): Use
1419 get_base_thread_from_ravenscar_task to get the underlying
1420 thread, rather than using base_ptid.
1421 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1422 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1423 Likewise.
1424 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
1425
1426 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1427
1428 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
1429 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
1430 (get_tcb_types_info): Set fieldnos.base_cpu.
1431 (read_atcb): Set task_info->base_cpu.
1432 (info_task): Print "Base CPU" info if set by runtime.
1433
1434 2017-11-21 Joel Brobecker <brobecker@adacore.com>
1435
1436 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
1437 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
1438 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
1439 New functions.
1440 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
1441 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
1442 to_stopped_data_address and to_core_of_thread fields of
1443 ravenscar_ops.
1444
1445 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
1446
1447 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
1448 (struct gdbarch_tdep): New member long_double_abi.
1449 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
1450 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
1451 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
1452 format depending on long_double_abi tdep member.
1453 (ppc_floatformat_for_type): Handle __ibm128 type.
1454
1455 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
1456
1457 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
1458
1459 2017-11-21 Pedro Alves <palves@redhat.com>
1460
1461 * dwarf2read.c (mapped_index::find_name_components_bounds)
1462 <completion mode, upper bound>: Use std::lower_bound instead of
1463 std::upper_bound.
1464 (test_mapped_index_find_name_component_bounds): Remove incorrect
1465 "t1_fund" from expected symbols.
1466
1467 2017-11-21 Pedro Alves <palves@redhat.com>
1468
1469 * dwarf2read.c (mapped_index::name_components_casing): New field.
1470 (mapped_index) <build_name_components,
1471 find_name_components_bounds): Declare new methods.
1472 (mapped_index::find_name_components_bounds)
1473 (mapped_index::build_name_components): New methods, factored out
1474 from dw2_expand_symtabs_matching_symbol.
1475 (check_find_bounds_finds)
1476 (test_mapped_index_find_name_component_bounds): New.
1477 (run_test): Rename to ...
1478 (test_dw2_expand_symtabs_matching_symbol): ... this.
1479 (run_test): Reimplement.
1480
1481 2017-11-21 Pedro Alves <palves@redhat.com>
1482
1483 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
1484 (symbol_end): Use cp_ident_is_alnum.
1485 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
1486 * dwarf2read.c (make_sort_after_prefix_name): New function.
1487 (dw2_expand_symtabs_matching_symbol): Use it.
1488 (test_symbols): Add more symbols.
1489 (run_test): Add tests.
1490
1491 2017-11-17 Tom Tromey <tom@tromey.com>
1492
1493 * symtab.h (enum symbol_subclass_kind): New.
1494 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
1495 Remove.
1496 <subclass>: New member.
1497 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
1498 * rust-lang.c (rust_get_trait_object_pointer): Update.
1499 * dwarf2read.c (read_func_scope): Update.
1500 (read_variable): Update.
1501
1502 2017-11-17 Tom Tromey <tom@tromey.com>
1503
1504 * dwarf2read.c (read_func_scope): Update.
1505 * symtab.h (struct template_symbol): Derive from symbol.
1506 <base>: Remove.
1507
1508 2017-11-17 Tom Tromey <tom@tromey.com>
1509
1510 * symtab.h (struct symbol) <is_rust_vtable>: New member.
1511 (struct rust_vtable_symbol): New.
1512 (find_symbol_at_address): Declare.
1513 * symtab.c (find_symbol_at_address): New function.
1514 * symfile.h (struct quick_symbol_functions)
1515 <find_compunit_symtab_by_address>: New member.
1516 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
1517 function.
1518 (debug_sym_quick_functions): Link to
1519 debug_qf_find_compunit_symtab_by_address.
1520 * rust-lang.c (rust_get_trait_object_pointer): New function.
1521 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
1522 rust_get_trait_object_pointer.
1523 * psymtab.c (psym_relocate): Clear psymbol_map.
1524 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
1525 functions.
1526 (psym_functions): Link to psym_find_compunit_symtab_by_address.
1527 * objfiles.h (struct objfile) <psymbol_map>: New member.
1528 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
1529 (process_die) <DW_TAG_variable>: New case. Call read_variable.
1530 (rust_containing_type, read_variable): New functions.
1531
1532 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1533
1534 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
1535
1536 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1537
1538 * common/filestuff.c: Include <algorithm>.
1539 (open_fds): Change type to std::vector<int>.
1540 (do_mark_open_fd): Adjust.
1541 (unmark_fd_no_cloexec): Adjust.
1542 (do_close): Adjust.
1543
1544 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1545
1546 * breakpoint.c (output_thread_groups): Take an std::vector.
1547 (print_one_breakpoint_location): Adjust.
1548
1549 2017-11-17 Joel Brobecker <brobecker@adacore.com>
1550
1551 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
1552 (ada_evaluate_subexp_for_cast): New function.
1553 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
1554 ada_evaluate_subexp_for_cast.
1555 (ada_evaluate_subexp) <nosideret>: Replace code by call to
1556 eval_skip_value.
1557 * eval.c (evaluate_var_value): Make non-static.
1558 (evaluate_var_msym_value, eval_skip_value): Likewise.
1559 * value.h (evaluate_var_value, evaluate_var_msym_value)
1560 (eval_skip_value): Declare.
1561
1562 2017-11-16 Joel Brobecker <brobecker@adacore.com>
1563
1564 * ada-lang.c (ada_value_cast): Remove parameter "noside".
1565 Update all callers.
1566
1567 2017-11-16 Pedro Alves <palves@redhat.com>
1568
1569 * python/py-unwind.c (pyuw_sniffer): Translate
1570 PyExc_KeyboardInterrupt to a GDB Quit exception.
1571
1572 2017-11-16 Pedro Alves <palves@redhat.com>
1573
1574 * infrun.c (resume_cleanups): Delete.
1575 (resume): No longer install a resume_cleanups cleanup nor call
1576 QUIT.
1577 (proceed): Pass the terminal to the inferior.
1578 (keep_going_pass_signal): No longer install a resume_cleanups
1579 cleanup.
1580
1581 2017-11-16 Pedro Alves <palves@redhat.com>
1582
1583 * inf-loop.c (inferior_event_handler): Don't swallow the exception
1584 if the prompt is blocked.
1585
1586 2017-11-16 Pedro Alves <palves@redhat.com>
1587
1588 * breakpoint.c (insert_bp_location): Replace bp_err and
1589 bp_err_message locals by a gdb_exception local.
1590
1591 2017-11-16 Pedro Alves <palves@redhat.com>
1592
1593 * inflow.c (scoped_ignore_sigttou): New class.
1594 (child_terminal_ours_1, new_tty): Use it.
1595
1596 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
1597
1598 * target-float.c (decimal_from_number): Add byte_order argument and
1599 call match_endianness. Error if unknown floating-point type.
1600 (decimal_to_number): Add byte_order argument and call match_endianness.
1601 (decimal_from_longest): Update call. Do not call match_endianness.
1602 (decimal_from_ulongest): Likewise.
1603 (decimal_binop): Likewise.
1604 (decimal_is_zero): Likewise.
1605 (decimal_compare): Likewise.
1606 (decimal_convert): Likewise.
1607
1608 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
1609
1610 * python/python.c (gdbpy_rbreak): New function.
1611 * NEWS: Document Python rbreak feature.
1612
1613 2017-11-16 Yao Qi <yao.qi@linaro.org>
1614
1615 * features/tic6x-c62x.xml: Remove.
1616 * features/tic6x-c64x.xml: Remove.
1617 * features/tic6x-c64xp.xml: Remove.
1618
1619 2017-11-15 John Baldwin <jhb@FreeBSD.org>
1620
1621 * symtab.h: Include <array>.
1622
1623 2017-11-15 John Baldwin <jhb@FreeBSD.org>
1624
1625 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
1626 (bsd_kvm_proc_cmd): Likewise.
1627
1628 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
1629
1630 * tui/tui-win.c (window_name_completer): Replace VEC with
1631 std::vector.
1632
1633 2017-11-15 Andrew Cagney <cagney@gnu.org>
1634
1635 * MAINTAINERS: Remove no-longer applicable entries.
1636
1637 2017-11-15 Andrew Cagney <cagney@gnu.org>
1638
1639 * MAINTAINERS: Move self to Past Maintainers.
1640
1641 2017-11-15 Yao Qi <yao.qi@linaro.org>
1642
1643 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
1644 * features/nios2-linux.c: Remove.
1645 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
1646 initialize_tdesc_nios2_linux.
1647
1648 2017-11-15 Yao Qi <yao.qi@linaro.org>
1649
1650 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
1651 M68HC11_LAST_HARD_REG + 1.
1652
1653 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
1654
1655 PR gdb/22388
1656 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
1657 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
1658 Return TARGET_XFER_EOF if size of returned data is 0.
1659
1660 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
1661
1662 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1663 memory-map-selftests.c.
1664 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
1665 * memory-map.c (memory_map_start_memory): Fix computation of hi
1666 address.
1667 * unittests/memory-map-selftests.c: New file.
1668
1669 2017-11-09 Joel Brobecker <brobecker@adacore.com>
1670
1671 * ada-lang.c: Fix some typos in the general command documenting
1672 how Ada expressions are being evaluated and how their result
1673 is printed.
1674
1675 2017-11-09 Tom Tromey <tom@tromey.com>
1676
1677 * psymtab.c (psymbol_hash): Do not hash string contents.
1678 (psymbol_compare): Add comment.
1679
1680 2017-11-09 Tom Tromey <tom@tromey.com>
1681
1682 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
1683
1684 2017-11-08 Joel Brobecker <brobecker@adacore.com>
1685
1686 * ada-exp.y (write_var_from_sym): Remove parameter
1687 "orig_left_context". Update all callers.
1688
1689 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
1690
1691 * tracepoint.h (class collection_list) <stringify>: Return
1692 std::vector<std::string>.
1693 (encode_actions_rsp): Change parameters to
1694 std::vector<std::string> *.
1695 * tracepoint.c (collection_list::stringify): Return
1696 std::vector<std::string> and adjust accordingly.
1697 (encode_actions_rsp): Changee parameters to
1698 std::vector<std::string> and adjust accordingly.
1699 * remote.c (free_actions_list),
1700 free_actions_list_cleanup_wrapper): Remove.
1701 (remote_download_tracepoint): Adjust to std::vector.
1702
1703 2017-11-08 Tom Tromey <tom@tromey.com>
1704
1705 * dwarf2read.c (symbolp): Remove typedef.
1706 (read_func_scope): Use std::vector.
1707 (process_structure_scope): Use std::vector.
1708
1709 2017-11-08 Pedro Alves <palves@redhat.com>
1710
1711 * ada-lang.c (ada_make_symbol_completion_list): Use
1712 completion_skip_symbol.
1713 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
1714 (symbol_is_function_or_method(symbol*)): New.
1715 (add_symtab_completions): Add complete_symbol_mode parameter. Use
1716 completion_skip_symbol.
1717 (default_collect_symbol_completion_matches_break_on): Use
1718 completion_skip_symbol. Pass down mode.
1719 (collect_file_symbol_completion_matches): Pass down mode.
1720 * symtab.h (symbol_is_function_or_method): New declarations.
1721 (completion_skip_symbol): New template function.
1722
1723 2017-11-08 Pedro Alves <palves@redhat.com>
1724
1725 * linespec.c (iterate_over_all_matching_symtabs): Add
1726 search_domain parameter. Pass it down to expand_symtabs_matching.
1727 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
1728 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
1729 search_domain.
1730 (add_all_symbol_names_from_pspace): Add search_domain parameter.
1731 Pass it down.
1732 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
1733 symbols.
1734 (add_matching_symbols_to_info): Add search_domain parameter. Pass
1735 it down.
1736
1737 2017-11-08 Pedro Alves <palves@redhat.com>
1738
1739 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
1740 text_len locals and don't pass them down.
1741 * symtab.c (completion_list_add_name): Remove
1742 sym_text/sym_text_len parameters and adjust.
1743 (completion_list_add_symbol, completion_list_add_msymbol)
1744 (completion_list_objc_symbol, completion_list_add_fields)
1745 (add_symtab_completions): Likewise.
1746 (default_collect_symbol_completion_matches_break_on)
1747 (collect_file_symbol_completion_matches): Remove sym_text_len
1748 local and don't pass it down.
1749 * symtab.h (completion_list_add_name): Remove
1750 sym_text/sym_text_len parameters.
1751
1752 2017-11-08 Pedro Alves <palves@redhat.com>
1753
1754 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1755 unittests/lookup_name_info-selftests.c.
1756 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
1757 * cp-support.c: Include "selftest.h".
1758 (cp_remove_params_1): Rename from cp_remove_params. Add
1759 'require_param' parameter, and handle it.
1760 (cp_remove_params): Reimplement.
1761 (cp_remove_params_if_any): New.
1762 (selftests::quote): New.
1763 (selftests::check_remove_params): New.
1764 (selftests::test_cp_remove_params): New.
1765 (_initialize_cp_support): Install
1766 selftests::test_cp_remove_params.
1767 * cp-support.h (cp_remove_params_if_any): Declare.
1768 * dwarf2read.c :Include "selftest.h".
1769 (dw2_expand_symtabs_matching_symbol): Use
1770 lookup_name_info::make_ignore_params.
1771 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
1772 (selftests::dw2_expand_symtabs_matching::string_or_null)
1773 (selftests::dw2_expand_symtabs_matching::check_match)
1774 (selftests::dw2_expand_symtabs_matching::test_symbols)
1775 (selftests::dw2_expand_symtabs_matching::run_test): New.
1776 (_initialize_dwarf2_read): Register
1777 selftests::dw2_expand_symtabs_matching::run_test.
1778 * psymtab.c (psym_expand_symtabs_matching): Use
1779 lookup_name_info::make_ignore_params.
1780 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
1781 If the lookup name wants to ignore parameters, strip them.
1782 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
1783 code handling '('.
1784 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
1785 (default_collect_symbol_completion_matches_break_on): Don't try to
1786 strip parameters.
1787 * symtab.h (lookup_name_info::lookup_name_info): Add
1788 'ignore_parameters' parameter.
1789 (lookup_name_info::ignore_parameters)
1790 (lookup_name_info::make_ignore_params): New methods.
1791 (lookup_name_info::m_ignore_parameters): New field.
1792 * unittests/lookup_name_info-selftests.c: New file.
1793
1794 2017-11-08 Pedro Alves <palves@redhat.com>
1795
1796 * dwarf2read.c (dw2_expand_marked_cus)
1797 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
1798 (dw2_expand_symtabs_matching): Move further below.
1799 (dw2_expand_marked_cus): Reindent.
1800
1801 2017-11-08 Pedro Alves <palves@redhat.com>
1802
1803 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
1804 (struct name_component): New.
1805 (mapped_index::name_components): New field.
1806 (mapped_index::symbol_name_at): New method.
1807 (dwarf2_read_index): Call mapped_index ctor.
1808 (dw2_map_matching_symbols): Add comment about name_components
1809 table.
1810 (dw2_expand_symtabs_matching): Factor part to...
1811 (dw2_expand_symtabs_matching_symbol): ... this new function.
1812 Build name components table, and lookup symbols in it before
1813 calling the name matcher.
1814 (dw2_expand_marked_cus): New, factored out from
1815 dw2_expand_symtabs_matching.
1816 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
1817
1818 2017-11-08 Pedro Alves <palves@redhat.com>
1819
1820 * ada-lang.c (ada_encode): Rename to ..
1821 (ada_encode_1): ... this. Add throw_errors parameter and handle
1822 it.
1823 (ada_encode): Reimplement.
1824 (match_name): Delete, folded into full_name.
1825 (resolve_subexp): No longer pass the encoded name to
1826 ada_lookup_symbol_list.
1827 (should_use_wild_match): Delete.
1828 (name_match_type_from_name): New.
1829 (ada_lookup_simple_minsym): Use lookup_name_info and the
1830 language's symbol_name_matcher_ftype.
1831 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
1832 (ada_add_block_renamings): Adjust to use lookup_name_info.
1833 (ada_lookup_name): New.
1834 (add_nonlocal_symbols, ada_add_all_symbols)
1835 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
1836 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
1837 (ada_name_for_lookup): Delete.
1838 (ada_lookup_encoded_symbol): Construct a verbatim name.
1839 (wild_match): Reverse sense of return type. Use bool.
1840 (full_match): Reverse sense of return type. Inline bits of old
1841 match_name here.
1842 (ada_add_block_symbols): Adjust to use lookup_name_info.
1843 (symbol_completion_match): Delete, folded into...
1844 (ada_lookup_name_info::matches): ... .this new method.
1845 (symbol_completion_add): Delete.
1846 (ada_collect_symbol_completion_matches): Add name_match_type
1847 parameter. Adjust to use lookup_name_info and
1848 completion_list_add_name.
1849 (get_var_value, ada_add_global_exceptions): Adjust to use
1850 lookup_name_info.
1851 (ada_get_symbol_name_cmp): Delete.
1852 (do_wild_match, do_full_match): New functions.
1853 (ada_lookup_name_info::ada_lookup_name_info): New method.
1854 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
1855 functions.
1856 (ada_language_defn): Install ada_get_symbol_name_matcher.
1857 * ada-lex.l (processId): If name starts with '<', copy it
1858 verbatim.
1859 * block.c (block_iter_match_step, block_iter_match_first)
1860 (block_iter_match_next, block_lookup_symbol)
1861 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
1862 lookup_name_info.
1863 * block.h (block_iter_match_first, block_iter_match_next)
1864 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
1865 * c-lang.c (c_language_defn, cplus_language_defn)
1866 (asm_language_defn, minimal_language_defn): Adjust comments to
1867 refer to la_get_symbol_name_matcher.
1868 * completer.c (complete_files_symbols)
1869 (collect_explicit_location_matches, symbol_completer): Pass a
1870 symbol_name_match_type down.
1871 * completer.h (class completion_match, completion_match_result):
1872 New classes.
1873 (completion_tracker::reset_completion_match_result): New method.
1874 (completion_tracker::m_completion_match_result): New field.
1875 * cp-support.c (make_symbol_overload_list_block): Adjust to use
1876 lookup_name_info.
1877 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
1878 functions.
1879 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
1880 * d-lang.c: Adjust comments to refer to
1881 la_get_symbol_name_matcher.
1882 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
1883 Adjust to use lookup_name_info.
1884 (dict_iter_match_first, dict_iter_match_next)
1885 (iter_match_first_hashed, iter_match_next_hashed)
1886 (iter_match_first_linear, iter_match_next_linear): Adjust to work
1887 with a lookup_name_info.
1888 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
1889 Likewise.
1890 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
1891 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
1892 (gdb_index_symbol_name_matcher): New class.
1893 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
1894 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
1895 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
1896 with a symbol_name_match_type.
1897 (f_language_defn): Adjust comments to refer to
1898 la_get_symbol_name_matcher.
1899 * go-lang.c (go_language_defn): Adjust comments to refer to
1900 la_get_symbol_name_matcher.
1901 * language.c (default_symbol_name_matcher)
1902 (language_get_symbol_name_matcher): New functions.
1903 (unknown_language_defn, auto_language_defn): Adjust comments to
1904 refer to la_get_symbol_name_matcher.
1905 * language.h (symbol_name_cmp_ftype): Delete.
1906 (language_defn) <la_collect_symbol_completion_matches>: Add match
1907 type parameter.
1908 <la_get_symbol_name_cmp>: Delete field.
1909 <la_get_symbol_name_matcher>: New field.
1910 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
1911 (default_symbol_name_matcher, language_get_symbol_name_matcher):
1912 Declare.
1913 * linespec.c (iterate_over_all_matching_symtabs)
1914 (iterate_over_file_blocks): Adjust to use lookup_name_info.
1915 (find_methods): Add language parameter, and use lookup_name_info
1916 and the language's symbol_name_matcher_ftype.
1917 (linespec_complete_function): Adjust.
1918 (lookup_prefix_sym): Use lookup_name_info.
1919 (add_all_symbol_names_from_pspace): Adjust.
1920 (find_superclass_methods): Add language parameter and pass it
1921 down.
1922 (find_method): Pass symbol language down.
1923 (find_linespec_symbols): Don't demangle or Ada encode here.
1924 (search_minsyms_for_name): Add lookup_name_info parameter.
1925 (add_matching_symbols_to_info): Add name_match_type parameter.
1926 Use lookup_name_info.
1927 * m2-lang.c (m2_language_defn): Adjust comments to refer to
1928 la_get_symbol_name_matcher.
1929 * minsyms.c: Include <algorithm>.
1930 (add_minsym_to_demangled_hash_table): Remove table parameter and
1931 add objfile parameter. Use search_name_hash, and add language to
1932 demangled languages vector.
1933 (struct found_minimal_symbols): New struct.
1934 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
1935 New functions.
1936 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
1937 input names here. Use lookup_name_info instead. Lookup up
1938 demangled names once for each language in the demangled names
1939 vector.
1940 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
1941 demangled names once for each language in the demangled names
1942 vector.
1943 (build_minimal_symbol_hash_tables): Adjust.
1944 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
1945 lookup_name_info.
1946 * objc-lang.c (objc_language_defn): Adjust comment to refer to
1947 la_get_symbol_name_matcher.
1948 * objfiles.h: Include <vector>.
1949 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
1950 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
1951 la_get_symbol_name_matcher.
1952 * p-lang.c (pascal_language_defn): Adjust comment to refer to
1953 la_get_symbol_name_matcher.
1954 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
1955 (match_partial_symbol): Use symbol_name_match_type,
1956 lookup_name_info and psymbol_name_matches.
1957 (lookup_partial_symbol): Use lookup_name_info.
1958 (map_block): Use symbol_name_match_type and lookup_name_info.
1959 (psym_map_matching_symbols): Use symbol_name_match_type.
1960 (psymbol_name_matches): New.
1961 (recursively_search_psymtabs): Use lookup_name_info and
1962 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
1963 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
1964 'kind' parameter to 'domain'.
1965 * rust-lang.c (rust_language_defn): Adjust comment to refer to
1966 la_get_symbol_name_matcher.
1967 * symfile-debug.c (debug_qf_map_matching_symbols)
1968 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
1969 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
1970 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
1971 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
1972 Adjust to use symbol_name_match_type.
1973 <expand_symtabs_matching>: Adjust to use lookup_name_info.
1974 (expand_symtabs_matching): Adjust to use lookup_name_info.
1975 * symmisc.c (maintenance_expand_symtabs): Use
1976 lookup_name_info::match_any ().
1977 * symtab.c (symbol_matches_search_name): New.
1978 (eq_symbol_entry): Adjust to use lookup_name_info and the
1979 language's matcher.
1980 (demangle_for_lookup_info::demangle_for_lookup_info): New.
1981 (lookup_name_info::match_any): New.
1982 (iterate_over_symbols, search_symbols): Use lookup_name_info.
1983 (compare_symbol_name): Add language, lookup_name_info and
1984 completion_match_result parameters, and use them.
1985 (completion_list_add_name): Make extern. Add language and
1986 lookup_name_info parameters. Use them.
1987 (completion_list_add_symbol, completion_list_add_msymbol)
1988 (completion_list_objc_symbol): Add lookup_name_info parameters and
1989 adjust. Pass down language.
1990 (completion_list_add_fields): Add lookup_name_info parameters and
1991 adjust. Pass down language.
1992 (add_symtab_completions): Add lookup_name_info parameters and
1993 adjust.
1994 (default_collect_symbol_completion_matches_break_on): Add
1995 name_match_type parameter, and use it. Use lookup_name_info.
1996 (default_collect_symbol_completion_matches)
1997 (collect_symbol_completion_matches): Add name_match_type
1998 parameter, and pass it down.
1999 (collect_symbol_completion_matches_type): Adjust.
2000 (collect_file_symbol_completion_matches): Add name_match_type
2001 parameter, and use lookup_name_info.
2002 * symtab.h: Include <string> and "common/gdb_optional.h".
2003 (enum class symbol_name_match_type): New.
2004 (class ada_lookup_name_info): New.
2005 (struct demangle_for_lookup_info): New.
2006 (class lookup_name_info): New.
2007 (symbol_name_matcher_ftype): New.
2008 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
2009 (symbol_matches_search_name): Declare.
2010 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
2011 (default_collect_symbol_completion_matches)
2012 (collect_symbol_completion_matches)
2013 (collect_file_symbol_completion_matches): Add name_match_type
2014 parameter.
2015 (iterate_over_symbols): Use lookup_name_info.
2016 (completion_list_add_name): Declare.
2017 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
2018 (strncmp_iw_with_mode): Now extern.
2019 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
2020 (strncmp_iw_with_mode): Declare.
2021
2022 2017-11-08 Keith Seitz <keiths@redhat.com>
2023 Pedro Alves <palves@redhat.com>
2024
2025 * ada-lang.c (ada_language_defn): Install
2026 default_search_name_hash.
2027 * buildsym.c (struct buildsym_compunit): <language>: New field.
2028 (finish_block_internal): Pass language when creating dictionaries.
2029 (start_buildsym_compunit, start_symtab): New language parameters.
2030 Use them.
2031 (restart_symtab): Pass down compilation unit's language.
2032 * buildsym.h (enum language): Forward declare.
2033 (start_symtab): New 'language' parameter.
2034 * c-lang.c (c_language_defn, cplus_language_defn)
2035 (asm_language_defn, minimal_language_defn): Install
2036 default_search_name_hash.
2037 * coffread.c (coff_start_symtab): Adjust.
2038 * d-lang.c (d_language_defn): Install default_search_name_hash.
2039 * dbxread.c (struct symloc): Add 'pst_language' field.
2040 (PST_LANGUAGE): Define.
2041 (start_psymtab, read_ofile_symtab): Use it.
2042 (process_one_symbol): New 'language' parameter. Pass it down.
2043 * dictionary.c (struct dictionary) <language>: New field.
2044 (DICT_LANGUAGE): Define.
2045 (dict_create_hashed, dict_create_hashed_expandable)
2046 (dict_create_linear, dict_create_linear_expandable): New parameter
2047 'language'. Set the dictionary's language.
2048 (iter_match_first_hashed): Adjust to rename.
2049 (insert_symbol_hashed): Assert we don't see mismatching
2050 languages. Adjust to rename.
2051 (dict_hash): Rename to ...
2052 (default_search_name_hash): ... this and make extern.
2053 * dictionary.h (struct language_defn): Forward declare.
2054 (dict_create_hashed): New parameter 'language'.
2055 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
2056 * f-lang.c (f_language_defn): Install default_search_name_hash.
2057 * go-lang.c (go_language_defn): Install default_search_name_hash.
2058 * jit.c (finalize_symtab): Pass compunit's language to dictionary
2059 creation.
2060 * language.c (unknown_language_defn, auto_language_defn):
2061 * language.h (language_defn::la_search_name_hash): New field.
2062 (default_search_name_hash): Declare.
2063 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
2064 * mdebugread.c (new_block): New parameter 'language'.
2065 * mdebugread.c (parse_symbol): Pass symbol language to block
2066 allocation.
2067 (psymtab_to_symtab_1): Pass down language.
2068 (new_symtab): Pass compunit's language to block allocation.
2069 * objc-lang.c (objc_language_defn): Install
2070 default_search_name_hash.
2071 * opencl-lang.c (opencl_language_defn):
2072 * p-lang.c (pascal_language_defn): Install
2073 default_search_name_hash.
2074 * rust-lang.c (rust_language_defn): Install
2075 default_search_name_hash.
2076 * stabsread.h (enum language): Forward declare.
2077 (process_one_symbol): Add 'language' parameter.
2078 * symtab.c (search_name_hash): New function.
2079 * symtab.h (search_name_hash): Declare.
2080 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
2081
2082 2017-11-08 Pedro Alves <palves@redhat.com>
2083
2084 * cp-name-parser.y (main): Don't initialize extra_chars.
2085
2086 2017-11-07 Tom Tromey <tom@tromey.com>
2087
2088 * event-top.h (command_handler): Constify.
2089 * record-full.c (cmd_record_full_start): Update.
2090 * thread.c (thread_apply_all_command): Update.
2091 * printcmd.c (eval_command): Update.
2092 * mi/mi-main.c (mi_execute_cli_command): Update.
2093 (mi_execute_async_cli_command): Update.
2094 * tui/tui-stack.c (tui_update_command): Update.
2095 * cli/cli-interp.c (safe_execute_command): Constify.
2096 * record.c (record_start): Update.
2097 (record_start, record_stop, cmd_record_start): Update.
2098 * record-btrace.c (cmd_record_btrace_bts_start): Update.
2099 (cmd_record_btrace_pt_start): Update.
2100 (cmd_record_btrace_start): Update.
2101 (cmd_record_btrace_start): Update.
2102 * reverse.c (exec_reverse_once): Update.
2103 * python/python.c (execute_gdb_command): Don't copy the command.
2104 * event-top.c (command_line_handler): Update.
2105 (command_handler): Constify.
2106 * defs.h (deprecated_call_command_hook): Constify.
2107 * cli/cli-script.h (execute_user_command): Constify.
2108 * cli/cli-script.c (execute_user_command): Constify.
2109 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
2110 (enum command_control_type): Update.
2111 * main.c (catch_command_errors): Remove non-const overload.
2112 (catch_command_errors_ftype): Remove.
2113 * python/py-cmd.c (cmdpy_function): Constify.
2114 * guile/scm-cmd.c (cmdscm_function): Constify.
2115 * cli/cli-dump.c (call_dump_func): Constify.
2116 * cli/cli-decode.c (do_const_cfunc): Constify.
2117 (do_sfunc): Constify.
2118 (cmd_func): Constify.
2119 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
2120 * top.h (execute_command): Constify.
2121 * top.c (execute_command): Constify.
2122 (execute_command_to_string): Constify.
2123 (deprecated_call_command_hook): Constify.
2124 * command.h (cmd_func): Constify.
2125 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
2126
2127 2017-11-07 Tom Tromey <tom@tromey.com>
2128
2129 * ada-lang.c (catch_ada_exception_command): Constify.
2130 (catch_assert_command): Constify.
2131 * break-catch-throw.c (catch_catch_command, catch_throw_command)
2132 (catch_rethrow_command): Constify.
2133 (catch_exception_command_1): Constify.
2134 * breakpoint.h (add_catch_command): Constify.
2135 * break-catch-syscall.c (catch_syscall_command_1): Constify.
2136 (catch_syscall_split_args): Constify.
2137 * break-catch-sig.c (catch_signal_command): Constify.
2138 (catch_signal_split_args): Constify.
2139 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
2140 cmd_const_sfunc_ftype.
2141 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
2142 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2143 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2144 (add_setshow_string_cmd, struct cmd_list_element)
2145 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2146 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2147 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
2148 Constify.
2149 (set_cmd_sfunc): Constify.
2150 (empty_sfunc): Constify.
2151 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
2152 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
2153 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
2154 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
2155 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
2156 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
2157 Constify.
2158 (set_cmd_sfunc): Constify.
2159 (cmd_sfunc_ftype): Remove.
2160 * compile/compile.c (set_compile_args): Constify.
2161 * infrun.c (set_disable_randomization): Constify.
2162 * infcmd.c (set_args_command, set_cwd_command): Constify.
2163 * breakpoint.c (set_condition_evaluation_mode): Constify.
2164 (add_catch_command): Constify.
2165 (catch_fork_command_1, catch_exec_command_1)
2166 (catch_load_command_1, catch_unload_command_1): Constify.
2167 (catch_load_or_unload): Constify.
2168 * guile/scm-param.c (pascm_set_func): Constify.
2169 (add_setshow_generic): Constify.
2170 * python/py-param.c (get_set_value): Constify.
2171 * top.h (set_verbose): Constify.
2172 * tui/tui-win.c (tui_set_var_cmd): Constify.
2173 * mi/mi-main.c (set_mi_async_command): Constify.
2174 * cli/cli-logging.c (set_logging_overwrite)
2175 (set_logging_redirect): Constify.
2176 * value.c (set_max_value_size): Constify.
2177 * valprint.c (set_input_radix, set_output_radix): Constify.
2178 * utils.c (set_width_command, set_height_command): Constify.
2179 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
2180 * tracepoint.c (set_disconnected_tracing)
2181 (set_circular_trace_buffer, set_trace_buffer_size)
2182 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
2183 * top.c (set_history_size_command, set_verbose, set_editing)
2184 (set_gdb_datadir, set_history_filename): Constify.
2185 * target.c (set_targetdebug, maint_set_target_async_command)
2186 (maint_set_target_non_stop_command, set_target_permissions)
2187 (set_write_memory_permission): Constify.
2188 (open_target): Constify.
2189 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
2190 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
2191 * symtab.c (set_symbol_cache_size_handler): Constify.
2192 * symfile.c (set_ext_lang_command): Constify.
2193 * symfile-debug.c (set_debug_symfile): Constify.
2194 * source.c (set_directories_command): Constify.
2195 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
2196 * serial.c (set_parity): Constify.
2197 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
2198 * remote.c (set_remote_exec_file, set_remotebreak)
2199 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
2200 * record.c (set_record_insn_history_size)
2201 (set_record_call_history_size): Constify.
2202 * record-full.c (set_record_full_insn_max_num): Constify.
2203 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
2204 * osabi.c (set_osabi): Constify.
2205 * mips-tdep.c (set_mips64_transfers_32bit_regs)
2206 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
2207 * maint.c (maintenance_set_profile_cmd): Constify.
2208 * linux-thread-db.c (set_libthread_db_search_path): Constify.
2209 * language.c (set_language_command, set_range_command)
2210 (set_case_command): Constify.
2211 * infrun.c (set_non_stop, set_observer_mode)
2212 (set_stop_on_solib_events, set_schedlock_func)
2213 (set_exec_direction_func): Constify.
2214 * infcmd.c (set_inferior_tty_command): Constify.
2215 * disasm.c (set_disassembler_options_sfunc): Constify.
2216 * demangle.c (set_demangling_command): Constify.
2217 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
2218 * cris-tdep.c (set_cris_version, set_cris_mode)
2219 (set_cris_dwarf2_cfi): Constify.
2220 * corefile.c (set_gnutarget_command): Constify.
2221 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
2222 (set_target_wide_charset_sfunc): Constify.
2223 * breakpoint.c (update_dprintf_commands): Constify.
2224 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
2225 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
2226 (set_disassembly_style_sfunc): Constify.
2227 * arch-utils.c (set_endian, set_architecture): Constify.
2228 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
2229 * agent.c (set_can_use_agent): Constify.
2230
2231 2017-11-07 Tom Tromey <tom@tromey.com>
2232
2233 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
2234 (go32_pde, go32_pte, go32_pte_for_address): Constify.
2235 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
2236 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
2237 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
2238 (parse_int_arg, show_thread_default_detach_sc_cmd)
2239 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
2240 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
2241 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
2242 (show_task_pause_cmd, set_task_detach_sc_cmd)
2243 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
2244 (set_noninvasive_cmd, set_thread_pause_cmd)
2245 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
2246 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
2247 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
2248 * windows-nat.c (display_selectors): Constify.
2249 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
2250 non-const "cfunc".
2251 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
2252 (cmd_cfunc_eq): Likewise.
2253 (struct cmd_list_element): Likewise.
2254 (do_cfunc): Remove.
2255 (cli_user_command_p): Update.
2256 * command.h (add_cmd): Remove non-const overload.
2257 (cmd_cfunc_ftype): Remove typedef.
2258 (cmd_cfunc_eq): Remove non-const overload.
2259 * value.c (show_values): Constify.
2260 * thread.c (thread_apply_all_command): Constify.
2261 * symfile.c (load_command): Constify.
2262 * source.c (directory_command): Constify.
2263 * maint.c (maintenance_internal_error)
2264 (maintenance_demangler_warning, maintenance_space_display)
2265 (maintenance_print_architecture, maintenance_translate_address)
2266 (maintenance_info_selftests, maintenance_internal_warning):
2267 Constify.
2268 * breakpoint.c (disable_trace_command, enable_trace_command):
2269 Constify.
2270 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
2271 Constify.
2272 (add_auto_load_safe_path): Constify.
2273 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
2274 * top.h (show_commands): Constify.
2275 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
2276 * sparc64-tdep.c (adi_examine_command): Constify.
2277 (adi_assign_command): Constify.
2278
2279 2017-11-07 Tom Tromey <tom@tromey.com>
2280
2281 * frame.h (info_locals_command, info_args_command): Constify.
2282 * auto-load.h (auto_load_info_scripts): Constify.
2283 * inferior.h (registers_info): Constify.
2284 * copying.c: Rebuild.
2285 * copying.awk: Constify generated commands.
2286 * auto-load.c (auto_load_info_scripts)
2287 (info_auto_load_gdb_scripts): Constify.
2288 * cli/cli-decode.c (struct cmd_list_element): Take a
2289 cmd_const_cfunc_ftype.
2290 * command.h (add_info): Take a cmd_const_cfunc_ftype.
2291 * tui/tui-win.c (tui_all_windows_info): Constify.
2292 * python/py-auto-load.c (info_auto_load_python_scripts):
2293 Constify.
2294 * cli/cli-cmds.c (show_command): Remove non-const overload.
2295 * tracepoint.c (info_tvariables_command, info_scope_command):
2296 Constify.
2297 (info_static_tracepoint_markers_command): Constify.
2298 * thread.c (info_threads_command): Constify.
2299 (print_thread_info_1): Constify.
2300 * target.c (info_target_command): Constify.
2301 * symtab.c (info_sources_command, info_functions_command)
2302 (info_types_command): Constify.
2303 (info_variables_command): Remove non-const overload.
2304 * symfile.c (info_ext_lang_command): Constify.
2305 * stack.c (info_frame_command, info_locals_command)
2306 (info_args_command): Constify.
2307 (backtrace_command): Remove non-const overload.
2308 * source.c (info_source_command, info_line_command): Constify.
2309 * solib.c (info_sharedlibrary_command): Constify.
2310 * skip.c (info_skip_command): Constify.
2311 * ser-go32.c (info_serial_command): Constify.
2312 * reverse.c (info_bookmarks_command): Constify.
2313 * printcmd.c (info_symbol_command, info_address_command)
2314 (info_display_command): Constify.
2315 * osdata.c (info_osdata_command): Constify.
2316 * objc-lang.c (info_selectors_command, info_classes_command):
2317 Constify.
2318 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
2319 * memattr.c (info_mem_command): Constify.
2320 * macrocmd.c (info_macro_command, info_macros_command): Constify.
2321 * linux-fork.c (info_checkpoints_command): Constify.
2322 * infrun.c (info_signals_command): Constify.
2323 * inflow.c (info_terminal_command): Constify.
2324 * inferior.c (info_inferiors_command): Constify.
2325 (print_inferior): Constify.
2326 * infcmd.c (info_program_command, info_all_registers_command)
2327 (info_registers_command, info_vector_command)
2328 (info_float_command): Constify.
2329 (registers_info): Constify.
2330 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
2331 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
2332 Constify.
2333 * f-valprint.c (info_common_command): Constify.
2334 * dcache.c (info_dcache_command): Constify.
2335 (dcache_info_1): Constify.
2336 * darwin-nat-info.c (info_mach_tasks_command)
2337 (info_mach_task_command, info_mach_ports_command)
2338 (info_mach_port_command, info_mach_threads_command)
2339 (info_mach_thread_command, info_mach_regions_command)
2340 (info_mach_regions_recurse_command, info_mach_region_command)
2341 (info_mach_exceptions_command): Constify.
2342 (get_task_from_args): Constify.
2343 * cp-support.c (info_vtbl_command): Constify.
2344 * breakpoint.c (info_watchpoints_command)
2345 (info_tracepoints_command): Constify.
2346 (info_breakpoints_command): Remove non-const overload.
2347 * avr-tdep.c (avr_io_reg_read_command): Constify.
2348 * auxv.c (info_auxv_command): Constify.
2349 * ada-tasks.c (info_tasks_command): Constify.
2350 (info_task): Constify.
2351 * ada-lang.c (info_exceptions_command): Constify.
2352
2353 2017-11-07 Tom Tromey <tom@tromey.com>
2354
2355 * solib.h (no_shared_libraries): Constify.
2356 * frame.h (return_command): Constify.
2357 * cli/cli-cmds.h (quit_command): Constify.
2358 * top.h (quit_command, execute_command): Constify.
2359 * target.h (flash_erase_command): Constify.
2360 * inferior.h (set_inferior_args, attach_command): Constify.
2361 * tracepoint.h (start_tracing, stop_tracing): Constify.
2362 * breakpoint.h (break_command, tbreak_command)
2363 (hbreak_command_wrapper, thbreak_command_wrapper)
2364 (rbreak_command_wrapper, watch_command_wrapper)
2365 (awatch_command_wrapper, rwatch_command_wrapper)
2366 (get_tracepoint_by_number): Constify.
2367 * symtab.c (info_variables_command, rbreak_command)
2368 (symtab_symbol_info): Constify.
2369 (info_variables_command): Add non-const overload.
2370 * top.c (dont_repeat_command): Constify.
2371 * breakpoint.c (ignore_command, commands_command)
2372 (condition_command, tbreak_command, hbreak_command)
2373 (thbreak_command, clear_command, break_command)
2374 (info_breakpoints_command, watch_command, rwatch_command)
2375 (awatch_command, trace_command, ftrace_command, strace_command)
2376 (trace_pass_command, break_range_command, dprintf_command)
2377 (agent_printf_command, get_tracepoint_by_number)
2378 (watch_maybe_just_location, trace_pass_command): Constify.
2379 (info_breakpoints_command): Add non-const overload.
2380 * tracefile.c (tsave_command): Constify.
2381 * infcmd.c (attach_command, disconnect_command, signal_command)
2382 (queue_signal_command, stepi_command, nexti_command)
2383 (finish_command, next_command, step_command, until_command)
2384 (advance_command, jump_command, continue_command, run_command)
2385 (start_command, starti_command, interrupt_command)
2386 (run_command_1, set_inferior_args, step_1): Constify.
2387 * inferior.c (add_inferior_command, remove_inferior_command)
2388 (clone_inferior_command): Constify.
2389 * linux-fork.c (checkpoint_command, restart_command): Constify.
2390 * windows-nat.c (signal_event_command): Constify.
2391 * guile/guile.c (guile_repl_command, guile_command): Constify.
2392 * printcmd.c (x_command, display_command, printf_command)
2393 (output_command, set_command, call_command, print_command)
2394 (eval_command): Constify.
2395 (non_const_set_command): Remove.
2396 (_initialize_printcmd): Update.
2397 * source.c (forward_search_command, reverse_search_command):
2398 Constify.
2399 * jit.c (jit_reader_load_command, jit_reader_unload_command):
2400 Constify.
2401 * infrun.c (handle_command): Constify.
2402 * memattr.c (mem_command): Constify.
2403 * stack.c (return_command, up_command, up_silently_command)
2404 (down_command, down_silently_command, frame_command)
2405 (backtrace_command, func_command, backtrace_command_1): Constify.
2406 (backtrace_command): Add non-const overload.
2407 * remote-sim.c (simulator_command): Constify.
2408 * exec.c (set_section_command): Constify.
2409 * tracepoint.c (tdump_command, trace_variable_command)
2410 (tstatus_command, tstop_command, tstart_command)
2411 (end_actions_pseudocommand, while_stepping_pseudocommand)
2412 (collect_pseudocommand, teval_pseudocommand, actions_command)
2413 (start_tracing, stop_tracing): Constify.
2414 * value.c (init_if_undefined_command): Constify.
2415 * tui/tui-stack.c (tui_update_command): Constify.
2416 * tui/tui-win.c (tui_refresh_all_command)
2417 (tui_set_tab_width_command, tui_set_win_height_command)
2418 (tui_set_focus_command, tui_scroll_forward_command)
2419 (tui_scroll_backward_command, tui_scroll_left_command)
2420 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
2421 (tui_set_win_height): Constify.
2422 * tui/tui-layout.c (tui_layout_command): Constify.
2423 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
2424 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
2425 (proc_untrace_sysexit_cmd): Constify.
2426 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
2427 (threadset_test_cmd, threadlist_update_test_cmd)
2428 (threadalive_test): Constify.
2429 * objc-lang.c (print_object_command): Constify.
2430 * command.h (add_com): Constify.
2431 * cli/cli-dump.c (restore_command): Constify.
2432 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
2433 (help_command, complete_command, shell_command, edit_command)
2434 (list_command, disassemble_command, make_command)
2435 (apropos_command, alias_command): Constify.
2436 * cli/cli-script.c (document_command, define_command)
2437 (while_command, if_command, validate_comname): Constify.
2438 * cli/cli-decode.c (struct cmd_list_element): Change type of
2439 "fun".
2440 * target.c (do_monitor_command, flash_erase_command): Constify.
2441 * regcache.c (reg_flush_command): Constify.
2442 * reverse.c (reverse_step, reverse_next, reverse_stepi)
2443 (reverse_nexti, reverse_continue, reverse_finish)
2444 (save_bookmark_command, goto_bookmark_command)
2445 (exec_reverse_once): Constify.
2446 * python/python.c (python_interactive_command, python_command):
2447 Constify.
2448 * typeprint.c (ptype_command, whatis_command, whatis_exp):
2449 Constify.
2450 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
2451 * gcore.c (gcore_command): Constify.
2452
2453 2017-11-07 Tom Tromey <tom@tromey.com>
2454
2455 * printcmd.c (x_command): Call set_repeat_arguments.
2456 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
2457 * top.c (repeat_arguments): New global.
2458 (set_repeat_arguments): New function.
2459 (execute_command): Handle repeat_arguments.
2460 (show_commands): Calls set_repeat_arguments.
2461 * command.h (set_repeat_arguments): Declare.
2462
2463 2017-11-07 Tom Tromey <tom@tromey.com>
2464
2465 * stack.c (backtrace_command): Use std::string.
2466 (backtrace_command_1): Make "count_exp" const.
2467
2468 2017-11-07 Tom Tromey <tom@tromey.com>
2469
2470 * source.c (directory_switch, mod_path, add_path): Constify.
2471 * defs.h (add_path, mod_path, directory_switch): Constify.
2472 * mi/mi-cmd-env.c (env_mod_path): Constify.
2473
2474 2017-11-07 Tom Tromey <tom@tromey.com>
2475
2476 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
2477 (run_command_1, continue_command, step_1, jump_command)
2478 (signal_command, until_command, advance_command, finish_command)
2479 (attach_command): Update.
2480
2481 2017-11-07 Tom Tromey <tom@tromey.com>
2482
2483 * command.h (set_cmd_cfunc): Don't declare.
2484 * cli/cli-decode.c (set_cmd_cfunc): Now static.
2485
2486 2017-11-07 Tom Tromey <tom@tromey.com>
2487
2488 * stack.c (select_frame_command): Constify.
2489 * cli/cli-decode.c (add_com_suppress_notification): Constify.
2490 * command.h (add_com_suppress_notification): Constify.
2491
2492 2017-11-07 Tom Tromey <tom@tromey.com>
2493
2494 * breakpoint.c (stop_command): Constify.
2495 * cli/cli-decode.c (struct cmd_list_element): Constify.
2496 * command.h (add_abbrev_prefix_cmd): Constify.
2497
2498 2017-11-07 Pedro Alves <palves@redhat.com>
2499
2500 * breakpoint.c (extract_bp_kind): New enum.
2501 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
2502 factored out from ...
2503 (extract_bp_number_and_location): ... here.
2504 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
2505
2506 2017-11-07 Pedro Alves <palves@redhat.com>
2507
2508 * breakpoint.c (extract_bp_number_and_location): Change return
2509 type to void. Throw error instead of warning.
2510 (enable_disable_command): Adjust.
2511
2512 2017-11-07 Xavier Roirand <roirand@adacore.com>
2513 Pedro Alves <palves@redhat.com>
2514
2515 * breakpoint.c (map_breakpoint_number_range): New, factored out
2516 from ...
2517 (map_breakpoint_numbers): ... here.
2518 (find_location_by_number): Change parameters from string to
2519 breakpoint number and location.
2520 (extract_bp_number_and_location): New function.
2521 (enable_disable_bp_num_loc)
2522 (enable_disable_breakpoint_location_range)
2523 (enable_disable_command): New functions, factored out ...
2524 (enable_command, disable_command): ... these functions, and
2525 adjusted to support ranges.
2526 * NEWS: Document enable/disable breakpoint location range feature.
2527
2528 2017-11-06 Luis Machado <luis.machado@linaro.org>
2529
2530 * MAINTAINERS (Write After Approval): Update my e-mail address.
2531
2532 2017-11-06 Pedro Alves <palves@redhat.com>
2533
2534 * gnu-nat.c (gnu_terminal_init): Delete.
2535 (gnu_target): Don't install gnu_terminal_init.
2536 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
2537 (child_terminal_init): ... this function.
2538
2539 2017-11-06 Pedro Alves <palves@redhat.com>
2540
2541 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
2542 sgtty.h.
2543 * config.in, configure: Regenerate.
2544
2545 2017-11-06 Pedro Alves <palves@redhat.com>
2546
2547 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
2548 (async_init_signals): Adjust.
2549 (handle_stop_sig): Rename to ...
2550 (handle_sigtstp): ... this.
2551 (async_stop_sig): Rename to ...
2552 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
2553 SIGTSTP path.
2554 * event-top.h: Move signal.h include to the top. Check SIGTSTP
2555 instead of STOP_SIGNAL thoughout.
2556 (handle_stop_sig): Rename to ...
2557 (handle_sigtstp): ... this.
2558 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
2559
2560 2017-11-06 Pedro Alves <palves@redhat.com>
2561
2562 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
2563 longer set flags twice in row.
2564
2565 2017-11-06 Pedro Alves <palves@redhat.com>
2566
2567 * Makefile.in (SER_HARDWIRE): Update comment.
2568 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
2569 * common/gdb_termios.h: Delete file.
2570 * common/job-control.c: Include termios.h and unistd.h instead of
2571 gdb_termios.h.
2572 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
2573 check.
2574 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
2575 Remove sgtty code.
2576 * configure.ac: No longer check for termio.h and sgtty.h.
2577 * configure: Regenerate.
2578 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
2579 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
2580 Replace PROCESS_GROUP_TYPE references with pid_t references
2581 throughout.
2582 (gdb_getpgrp): Delete.
2583 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
2584 (child_terminal_inferior): Remove comment. Remove sgtty code.
2585 (child_terminal_ours_1): Use tcgetpgrp directly instead of
2586 gdb_getpgrp. Use serial_set_tty_state instead aof
2587 serial_noflush_set_tty_state. Remove sgtty code.
2588 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
2589 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
2590 (inferior_process_group): Now returns pid_t.
2591 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
2592 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
2593 * ser-event.c (serial_event_ops): Update.
2594 * ser-go32.c (dos_noflush_set_tty_state): Delete.
2595 (dos_ops): Update.
2596 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
2597 * ser-pipe.c (pipe_ops): Update.
2598 * ser-tcp.c (tcp_ops): Update.
2599 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
2600 HAVE_TERMIOS checks.
2601 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
2602 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
2603 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
2604 assume termios.
2605 (hardwire_noflush_set_tty_state): Delete.
2606 (hardwire_print_tty_state, hardwire_drain_output)
2607 (hardwire_flush_output, hardwire_flush_input)
2608 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
2609 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
2610 code, and assume termios.
2611 (hardwire_ops): Update.
2612 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
2613 * serial.c (serial_noflush_set_tty_state): Delete.
2614 * serial.h (serial_noflush_set_tty_state): Delete.
2615 (serial_ops::noflush_set_tty_state): Delete.
2616
2617 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2618
2619 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
2620 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
2621 (COMMON_OBS): Remove doublest.o and dfp.o.
2622 Do not build target-float.c (instead of doublest.c)
2623 with -Wformat-nonliteral.
2624
2625 * doublest.c: Remove file.
2626 * doublest.h: Remove file.
2627 * dfp.c: Remove file.
2628 * dfp.h: Remove file.
2629
2630 * target-float.c: Do not include "doublest.h" and "dfp.h".
2631 (DOUBLEST): Move here from doublest.h.
2632 (enum float_kind): Likewise.
2633 (FLOATFORMAT_CHAR_BIT): Likewise.
2634 (FLOATFORMAT_LARGEST_BYTES): Likewise.
2635 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
2636 (floatformat_precision): Likewise.
2637 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
2638 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
2639 Likewise.
2640 (host_float_format, host_double_format, host_long_double_format):
2641 Likewise.
2642 (floatformat_to_string, floatformat_from_string): Likewise.
2643 (floatformat_to_doublest): Likewise. Also, inline the original
2644 convert_floatformat_to_doublest.
2645 (floatformat_from_doublest): Likewise. Also, inline the original
2646 convert_floatformat_from_doublest.
2647
2648 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
2649 (MAX_DECIMAL_STRING): Move here from dfp.c.
2650 (match_endianness): Likewise.
2651 (set_decnumber_context, decimal_check_errors): Likewise.
2652 (decimal_from_number, decimal_to_number): Likewise.
2653 (decimal_to_string, decimal_from_string): Likewise. Make static.
2654 (decimal_from_longest, decimal_from_ulongest): Likewise.
2655 (decimal_to_longest): Likewise.
2656 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
2657 (decimal_convert): Likewise.
2658
2659 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2660
2661 * doublest.c: Do not include "gdbtypes.h".
2662 (extract_typed_floating): Remove.
2663 (store_typed_floating): Remove.
2664 (convert_typed_floating): Remove.
2665 * doublest.h (struct type): Remove.
2666 (DOUBLEST_PRINT_FORMAT): Remove.
2667 (DOUBLEST_SCAN_FORMAT): Remove.
2668 (extract_typed_floating): Remove.
2669 (store_typed_floating): Remove.
2670 (convert_typed_floating): Remove.
2671
2672 * dfp.c (decimal_from_doublest): Remove.
2673 (decimal_to_doublest): Remove.
2674 * dfp.h: Do not include "doublest.h".
2675 (decimal_from_doublest): Remove.
2676 (decimal_to_doublest): Remove.
2677
2678 * value.c: Do not include "doublest.h" and "dfp.h".
2679 (value_as_double): Remove.
2680 (unpack_double): Remove.
2681 (value_from_double): Remove.
2682 (value_from_decfloat): Remove.
2683 * value.h: Do not include "doublest.h".
2684 (value_as_double): Remove.
2685 (unpack_double): Remove.
2686 (value_from_double): Remove.
2687 (value_from_decfloat): Remove.
2688
2689 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2690
2691 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
2692 (i386_extract_return_value): Use target_float_convert.
2693 (i386_store_return_value): Likewise.
2694 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
2695 (i387_value_to_register): Likewise.
2696 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
2697 (ia64_register_to_value): Use target_float_convert.
2698 (ia64_value_to_register): Likewise.
2699 (ia64_extract_return_value): Likewise.
2700 (ia64_store_return_value): Likewise.
2701 (ia64_push_dummy_call): Likewise.
2702 * m68k-tdep.c: Include "target-float.h".
2703 (m68k_register_to_value): Use target_float_convert.
2704 (m68k_value_to_register): Likewise.
2705 (m68k_svr4_extract_return_value): Likewise.
2706 (m68k_svr4_store_return_value): Likewise.
2707 * ppc-sysv-tdep.c: Include "target-float.h".
2708 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
2709 (do_ppc_sysv_return_value): Likewise.
2710 (ppc64_sysv_abi_push_freg): Likewise.
2711 (ppc64_sysv_abi_return_value_base): Likewise.
2712 * rs6000-aix-tdep.c: Include "target-float.h".
2713 (rs6000_push_dummy_call): Use target_float_convert.
2714 (rs6000_return_value): Likewise.
2715 * rs6000-lynx178-tdep.c: Include "target-float.h".
2716 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
2717 (rs6000_lynx178_return_value): Likewise.
2718 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
2719 (rs6000_register_to_value): Use target_float_convert.
2720 (rs6000_value_to_register): Likewise.
2721 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
2722 (arm_extract_return_value): Use target_float_convert.
2723 (arm_store_return_value): Likewise.
2724 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
2725 (sh_register_convert_to_virtual): Use target_float_convert.
2726 (sh_register_convert_to_raw): Likewise.
2727 * sh64-tdep.c: Include "target-float.h".
2728 (sh64_extract_return_value): Use target_float_convert.
2729 (sh64_register_convert_to_virtual): Likewise.
2730 (sh64_register_convert_to_raw): Likewise. Fix argument types.
2731
2732 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2733
2734 * target-float.c (floatformat_to_host_double): New function.
2735 (floatformat_from_host_double): Likewise.
2736 (target_float_to_host_double): Likewise.
2737 (target_float_from_host_double): Likewise.
2738 * target-float.h (target_float_to_host_double): Add prototype.
2739 (target_float_from_host_double): Likewise.
2740
2741 * guile/scm-value.c: Include "target-float.h".
2742 (gdbscm_value_to_real): Use target_float_to_host_double.
2743 Handle integer source values via value_as_long.
2744 * guile/scm-math.c: Include "target-float.h". Do not include
2745 "doublest.h", "dfp.h", and "expression.h".
2746 (vlscm_convert_typed_number): Use target_float_from_host_double.
2747 (vlscm_convert_number): Likewise.
2748
2749 * python/py-value.c (valpy_float): Use target_float_to_host_double.
2750 (convert_value_from_python): Use target_float_from_host_double.
2751
2752 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2753
2754 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
2755 (cast_from_fixed): Likewise.
2756 (ada_scaling_type): New function.
2757 (ada_delta): Return value instead of DOUBLEST. Perform target
2758 arithmetic instead of host arithmetic.
2759 (scaling_factor): Rename to ...
2760 (ada_scaling_factor) ... this. Make non-static. Return value instead
2761 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
2762 (ada_fixed_to_float): Remove.
2763 (ada_float_to_fixed): Remove.
2764 * ada-lang.h (ada_fixed_to_float): Remove.
2765 (ada_float_to_fixed): Remove.
2766 (ada_delta): Return value instead of DOUBLEST.
2767 (ada_scaling_factor): Add prototype.
2768
2769 * ada-typeprint.c: Include "target-float.h".
2770 (print_fixed_point_type): Perform target arithmetic instead of
2771 host arithmetic.
2772 * ada-valprint.c: Include "target-float.h".
2773 (ada_val_print_num): Perform target arithmetic instead of
2774 host arithmetic for fixed-point types.
2775
2776 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2777
2778 * target-float.c: Include <math.h>.
2779 (floatformat_binop): New function.
2780 (floatformat_compare): Likewise.
2781 (target_float_binop): Likewise.
2782 (target_float_compare): Likewise.
2783 * target-float.h: Include "expression.h".
2784 (target_float_binop): Add prototype.
2785 (target_float_compare): Likewise.
2786
2787 * valarith.c: Do not include "doublest.h" and "dfp.h".
2788 Include "common/byte-vector.h".
2789 (value_args_as_decimal): Remove, replace by ...
2790 (value_args_as_target_float): ... this function. Handle both
2791 binary and decimal target floating-point formats.
2792 (scalar_binop): Handle both binary and decimal FP using
2793 value_args_as_target_float and target_float_binop.
2794 (value_equal): Handle both binary and decimal FP using
2795 value_args_as_target_float and target_float_compare.
2796 (value_less): Likewise.
2797 (value_pos): Handle all scalar types as simple copy.
2798 (value_neg): Handle all scalar types via BINOP_SUB from 0.
2799 * dfp.c (decimal_binop): Throw error instead of internal_error
2800 when called with an unsupported operation code.
2801
2802 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2803
2804 * target-float.c (target_float_to_string): New function.
2805 (target_float_from_string): New function.
2806 * target-float.h (target_float_to_string): Add prototype.
2807 (target_float_from_string): Add prototype.
2808
2809 * valprint.c: Include "target-float.h". Do not include
2810 "doublest.h" and "dfp.h".
2811 (print_floating): Use target_float_to_string.
2812 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
2813 (printf_floating): Use target_float_to_string.
2814 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
2815 (print_i387_value): Use target_float_to_string.
2816 * mips-tdep.c: Include "target-float.h".
2817 (mips_print_fp_register): Use target_float_to_string.
2818 * sh64-tdep.c: Include "target-float.h".
2819 (sh64_do_fp_register): Use target_float_to_string.
2820
2821 * parse.c: Include "target-float.h". Do not include
2822 "doublest.h" and "dfp.h".
2823 (parse_float): Use target_float_from_string.
2824 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
2825 (define_symbol): Use target_float_from_string.
2826 * gdbarch-selftests.c: Include "target-float.h".
2827 (register_to_value_test): Use target_float_from_string.
2828
2829 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
2830
2831 * Makefile.c (SFILES): Add target-float.c.
2832 (HFILES_NO_SRCDIR): Add target-float.h.
2833 (COMMON_OBS): Add target-float.o.
2834 * target-float.h: New file.
2835 * target-float.c: New file.
2836
2837 * doublest.c (floatformat_classify): Fix detection of float_zero.
2838
2839 * gdbtypes.c (is_floating_type): New function.
2840 * gdbtypes.h (is_floating_type): Add prototype.
2841
2842 * value.c: Do not include "floatformat.h".
2843 (unpack_double): Use target_float_is_valid.
2844 (is_floating_value): New function.
2845 * value.h (is_floating_value): Add prototype-
2846
2847 * valarith.c: Include "target-float.h".
2848 (value_logical_not): Use target_float_is_zero.
2849
2850 * python/py-value.c: Include "target-float.h".
2851 (valpy_nonzero): Use target_float_is_zero.
2852
2853 2017-11-04 Tom Tromey <tom@tromey.com>
2854
2855 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
2856
2857 2017-11-04 Tom Tromey <tom@tromey.com>
2858
2859 * breakpoint.c (set_momentary_breakpoint): Return
2860 breakpoint_up.
2861 (until_break_command): Update.
2862 (new_until_break_fsm): Change argument types to
2863 breakpoint_up.
2864 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2865 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
2866 Remove.
2867 * infcmd.c (finish_forward): Update.
2868 * breakpoint.h (set_momentary_breakpoint)
2869 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
2870 (make_cleanup_delete_breakpoint): Remove.
2871 (struct breakpoint_deleter): New.
2872 (breakpoint_up): New typedef.
2873 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
2874 (insert_exception_resume_breakpoint): Update.
2875 (insert_exception_resume_from_probe): Update.
2876 (insert_longjmp_resume_breakpoint): Update.
2877 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
2878 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
2879 * infcall.c (call_function_by_hand_dummy): Update
2880
2881 2017-11-04 Tom Tromey <tom@tromey.com>
2882
2883 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
2884
2885 2017-11-04 Tom Tromey <tom@tromey.com>
2886
2887 * linux-tdep.c (linux_core_info_proc_mappings): Use
2888 gdb::def_vector.
2889 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
2890 "size" argument.
2891 (linux_corefile_thread): Update.
2892 (linux_make_corefile_notes): Remove unused variable.
2893
2894 2017-11-04 Tom Tromey <tom@tromey.com>
2895
2896 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
2897 gdb::byte_vector.
2898
2899 2017-11-04 Tom Tromey <tom@tromey.com>
2900
2901 * objfiles.c (do_free_objfile_cleanup): Remove.
2902 * compile/compile-object-load.c (compile_object_load): Update.
2903 * objfiles.h (make_cleanup_free_objfile): Remove.
2904
2905 2017-11-04 Tom Tromey <tom@tromey.com>
2906
2907 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
2908 (adi_read_versions): Change "tags" to "gdb_byte *".
2909 (adi_print_versions): Likewise.
2910
2911 2017-11-04 Tom Tromey <tom@tromey.com>
2912
2913 * breakpoint.c
2914 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
2915 from start_rbreak_breakpoints.
2916 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
2917 * breakpoint.h (class scoped_rbreak_breakpoints): New.
2918 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
2919 * symtab.c (do_end_rbreak_breakpoints): Remove.
2920 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
2921
2922 2017-11-04 Tom Tromey <tom@tromey.com>
2923
2924 * cp-namespace.c (reset_directive_searched): Remove.
2925 (cp_lookup_symbol_via_imports): Use scoped_restore.
2926 * cp-support.c (reset_directive_searched): Remove.
2927 (make_symbol_overload_list_using): Use scoped_restore.
2928 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
2929 (reset_directive_searched): Remove.
2930
2931 2017-11-04 Tom Tromey <tom@tromey.com>
2932
2933 * symfile.c (find_separate_debug_file_by_debuglink): Use
2934 unique_xmalloc_ptr.
2935
2936 2017-11-04 Tom Tromey <tom@tromey.com>
2937
2938 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
2939 type of "info".
2940 (compute_stack_depth): Likewise.
2941 (do_compile_dwarf_expr_to_c): Use std::vector.
2942
2943 2017-11-04 Tom Tromey <tom@tromey.com>
2944
2945 * compile/compile-object-load.c (link_callbacks_einfo): Use
2946 std::string.
2947
2948 2017-11-04 Tom Tromey <tom@tromey.com>
2949
2950 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
2951 Use scoped_free_pendings.
2952 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
2953 scoped_free_pendings.
2954 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
2955 (xcoff_initial_scan): Likewise.
2956 * buildsym.c (reset_symtab_globals): Update comment.
2957 (scoped_free_pendings): Rename from really_free_pendings.
2958 (prepare_for_building): Update comment.
2959 (buildsym_init): Likewise.
2960 * buildsym.h (class scoped_free_pendings): New class.
2961 (really_free_pendings): Don't declare.
2962
2963 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
2964
2965 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
2966 output when converting a zero value to a special byteorder format.
2967
2968 2017-11-02 Yao Qi <yao.qi@linaro.org>
2969
2970 * frame.c (do_frame_register_read): Remove aspace.
2971 * jit.c (jit_frame_sniffer): Likwise.
2972 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
2973 * regcache.c (regcache::regcache): Pass nullptr.
2974 (regcache_print): Caller updated.
2975 * regcache.h (regcache::regcache): Remove one constructor
2976 parameter aspace.
2977
2978 2017-11-02 Yao Qi <yao.qi@linaro.org>
2979
2980 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
2981
2982 2017-11-02 Yao Qi <yao.qi@linaro.org>
2983
2984 * breakpoint.c (insert_single_step_breakpoints): Update.
2985 * frame.c (struct frame_info) <aspace>: Add const.
2986 (frame_save_as_regcache): Add const.
2987 (get_frame_address_space): Return const address_space *.
2988 * frame.h (get_frame_address_space): Update declaration.
2989 * infrun.c (struct step_over_info) <aspace>: Add const.
2990 (set_step_over_info): Make aspace const.
2991 (displaced_step_prepare_throw): Change variable const.
2992 (resume): Likewise.
2993 (proceed): Likewise.
2994 (adjust_pc_after_break): Likewise.
2995 (save_waitstatus): Likewise.
2996 (handle_signal_stop): Likewise.
2997 (keep_going_pass_signal): Likewise.
2998 * jit.c (jit_frame_sniffer): Add const.
2999 * mips-tdep.c (mips_single_step_through_delay): Likewise.
3000 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
3001 * record-full.c (record_full_wait_1): Likewise.
3002 * regcache.c (regcache::regcache): Change parameter to const.
3003 * regcache.h (regcache::regcache): Likewise.
3004 (regcache::aspace): Return const address_space *.
3005 (regcache) <m_aspace>: Add const.
3006
3007 2017-11-02 Yao Qi <yao.qi@linaro.org>
3008
3009 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
3010 * frame.c (create_sentinel_frame): Likewise.
3011 * infrun.c (displaced_step_prepare_throw): Likewise.
3012 (resume): Likewise.
3013 (thread_still_needs_step_over_bp): Likewise.
3014 (proceed): Likewise.
3015 (do_target_wait): Likewise.
3016 (adjust_pc_after_break): Likewise.
3017 (handle_syscall_event): Likewise.
3018 (save_waitstatus): Likewise.
3019 (handle_inferior_event_1): Likewise.
3020 (handle_signal_stop): Likewise.
3021 (keep_going_pass_signal): Likewise.
3022 * linux-nat.c (status_callback): Likewise.
3023 (save_stop_reason): Likewise.
3024 (resume_stopped_resumed_lwps): Likewise.
3025 * record-full.c (record_full_exec_insn): Likewise.
3026 (record_full_wait_1): Likewise.
3027 * regcache.c (get_regcache_aspace): Remove.
3028 * regcache.h (get_regcache_aspace): Remove.
3029
3030 2017-11-02 Yao Qi <yao.qi@linaro.org>
3031
3032 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
3033 (init_regcache_descr): Use gdbarch_num_regs.
3034 (regcache::regcache): Likewise.
3035 (regcache::get_register_status): Likewise.
3036 (regcache::assert_raw_regnum): Likewise.
3037 (regcache::cooked_read): Likewise.
3038 (regcache::cooked_read_value): Likewise.
3039 (regcache::cooked_write): Likewise.
3040 (regcache::dump): Likewise.
3041 (regcache::num_raw_registers): New method.
3042 * regcache.h (class regcache) <num_raw_registers>: New.
3043
3044 2017-11-02 Yao Qi <yao.qi@linaro.org>
3045
3046 * regcache.c (regcache::assert_regnum): New method.
3047 (regcache::invalidate): Call assert_regnum.
3048 (regcache::raw_update): Likewise.
3049 (regcache::raw_write): Likewise.
3050 (regcache::raw_read_part): Likewise.
3051 (regcache::raw_write_part): Likewise.
3052 (regcache::raw_supply): Likewise.
3053 (regcache::raw_supply_integer): Likewise.
3054 (regcache::raw_supply_zeroed): Likewise.
3055 (regcache::raw_collect): Likewise.
3056 (regcache::raw_collect_integer): Likewise.
3057 * regcache.h (regcache::assert_regnum): Declare.
3058
3059 2017-11-02 Yao Qi <yao.qi@linaro.org>
3060
3061 * regcache.c (regcache::dump): Remove code.
3062
3063 2017-11-02 Yao Qi <yao.qi@linaro.org>
3064
3065 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
3066 Remove.
3067 <sizeof_cooked_register_status>: Remove.
3068 (init_regcache_descr): Update.
3069 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
3070 (regcache::save): Likewise.
3071 (regcache::dump): Likewise.
3072
3073 2017-11-01 James Bowman <james.bowman@ftdichip.com>
3074
3075 * ft32-tdep.c (ft32_fetch_instruction): New function.
3076 (ft32_analyze_prologue): Use ft32_fetch_instruction().
3077
3078 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
3079
3080 * cli/cli-script.c (execute_control_command): Rename to ...
3081 (execute_control_command_1): ... this.
3082 (execute_control_command): New function.
3083
3084 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
3085
3086 * tracepoint.c (tfind_command): Remove const_cast.
3087
3088 2017-10-30 Mike Gulick <mgulick@mathworks.com>
3089
3090 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
3091
3092 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
3093
3094 * common/common-utils.h (in_inclusive_range): New function.
3095 * arm-tdep.c (arm_record_extension_space): Use
3096 in_inclusive_range.
3097 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
3098 * cris-tdep.c (cris_spec_reg_applicable): Use
3099 in_inclusive_range.
3100
3101 2017-10-30 Pedro Alves <palves@redhat.com>
3102 Simon Marchi <simon.marchi@ericsson.com>
3103
3104 * remote.c (remote_set_syscall_catchpoint): Build a std::string
3105 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
3106
3107 2017-10-30 Pedro Alves <palves@redhat.com>
3108
3109 * common/common-utils.c (string_appendf, string_vappendf): New
3110 functions.
3111 * common/common-utils.h (string_appendf, string_vappendf): New
3112 declarations.
3113 * unittests/common-utils-selftests.c (string_appendf_func)
3114 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
3115 (string_vappendf_tests): New functions.
3116 (_initialize_common_utils_selftests): Register "string_appendf" and
3117 "string_vappendf tests".
3118
3119 2017-10-30 Pedro Alves <palves@redhat.com>
3120
3121 * unittests/common-utils-selftests.c (format_func): New typedef.
3122 (string_printf_tests, string_vprintf_tests): Tests factored out
3123 and merged to ...
3124 (test_format_func): ... this new function.
3125 (string_printf_tests, string_vprintf_tests): Reimplement on top of
3126 test_format_func.
3127
3128 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3129
3130 * darwin-nat.c: Remove include of gdb.h.
3131
3132 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3133
3134 * xtensa-xtregs.c: Fix formatting issues.
3135
3136 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
3137
3138 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
3139
3140 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
3141
3142 PR python/21213
3143 * python/py-infthread.c (thpy_get_inferior): Increment reference
3144 of inferior before returning it.
3145
3146 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3147
3148 * unittests/common-utils-selftests.c (format): Add
3149 ATTRIBUTE_PRINTF.
3150
3151 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3152
3153 * xml-syscall.c (struct syscall_desc): Add constructor.
3154 <name>: Change type to std::string.
3155 (syscall_desc_up): New typedef.
3156 (syscall_desc_p): Remove typeder.
3157 (DEF_VEC_P(syscall_desc_p)): Remove.
3158 (struct syscall_group_desc): Add constructor.
3159 <name>: Change type to std::string.
3160 <syscalls>: Change type to std::vector.
3161 (syscall_group_desc_up): New typedef.
3162 (syscall_group_desc_p): Remove typedef.
3163 (DEF_VEC_P(syscall_group_desc_p)): Remove.
3164 (struct syscalls_info) <syscalls>: Change type to std::vector of
3165 unique_ptr.
3166 <groups>: Likewise.
3167 <my_gdb_datadir>: Change type to std::string.
3168 (syscalls_info_up): New typedef.
3169 (allocate_syscalls_info): Remove.
3170 (syscalls_info_free_syscalls_desc): Remove.
3171 (syscalls_info_free_syscall_group_desc): Remove.
3172 (free_syscalls_info): Remove.
3173 (make_cleanup_free_syscalls_info): Remove.
3174 (syscall_group_create_syscall_group_desc): Adjust.
3175 (syscall_group_add_syscall): Adjust.
3176 (syscall_create_syscall_desc): Adjust.
3177 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
3178 (init_syscalls_info): Adjust.
3179 (syscall_group_get_group_by_name): Adjust.
3180 (xml_get_syscall_number): Adjust.
3181 (xml_get_syscall_name): Adjust.
3182 (xml_list_of_syscalls): Adjust.
3183 (xml_list_syscalls_by_group): Adjust.
3184 (xml_list_of_groups): Adjust.
3185
3186 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3187
3188 * probe.h: Don't include gdb_vecs.h.
3189 (DEF_VEC_P (probe_p)): Remove.
3190 (find_probes_in_objfile): Return an std::vector.
3191 * probe.c (find_probes_in_objfile): Likewise.
3192 * breakpoint.c (breakpoint_objfile_data)
3193 <longjmp_probes>: Change type to std::vector.
3194 <exception_probes>: Likewise.
3195 (free_breakpoint_probes): Don't manually free vectors.
3196 (create_longjmp_master_breakpoint): Adjust.
3197 (create_exception_master_breakpoint): Adjust.
3198 * solib-svr4.c (svr4_create_probe_breakpoints): Change
3199 parameter type, adjust.
3200 (svr4_create_solib_event_breakpoints): Adjust.
3201
3202 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3203
3204 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
3205 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
3206 with new.
3207 (free_breakpoint_probes): Rename to ...
3208 (free_breakpoint_objfile_data): ... this, and call delete on
3209 bp_objfile_data..
3210
3211 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
3212
3213 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
3214 (loaded_script_ptr): Remove typedef.
3215 (DEF_VEC_P (loaded_script_ptr)): Remove.
3216 (struct collect_matching_scripts_data): Add constructor.
3217 <scripts_p>: Change type to (pointer to) std::vector.
3218 (collect_matching_scripts_data): Adjust.
3219 (sort_scripts_by_name): Make suitable for std::sort.
3220 (print_scripts): Don't sort vector, adjust to std::vector.
3221 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
3222
3223 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3224
3225 * symfile.c (filename_language): Make struct, not typedef. Add
3226 constructor.
3227 <ext>: Change type to std::string.
3228 (DEF_VEC_O (filename_language)): Remove.
3229 (filename_language_table): Change type to std::vector.
3230 (add_filename_language): Adjust.
3231 (set_ext_lang_command): Adjust.
3232 (info_ext_lang_command): Adjust.
3233 (deduce_language_from_filename): Adjust.
3234 (class scoped_restore_filename_language_table): Remove.
3235 (test_filename_language): Use scoped_restore.
3236 (test_set_ext_lang_command): Use scoped_restore, adjust to
3237 std::vector change.
3238
3239 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
3240
3241 * symfile.c: Include selftest.h.
3242 (class scoped_restore_filename_language_table): New.
3243 (test_filename_language): New test.
3244 (test_set_ext_lang_command): New test.
3245 (_initialize_symfile): Register tests.
3246
3247 2017-10-27 Keith Seitz <keiths@redhat.com>
3248
3249 * breakpoint.c (print_breakpoint_location): Use the symbol saved
3250 in the bp_location, falling back to find_pc_sect_function when
3251 needed.
3252 (add_location_to_breakpoint): Save sal->symbol.
3253 * breakpoint.h (struct bp_location) <symbol>: New field.
3254 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
3255 * symtab.h (struct symtab_and_line) <symbol>: New field.
3256
3257 2017-10-26 Patrick Frants <osscontribute@gmail.com>
3258
3259 PR gdb/13669
3260 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
3261 to rewind obstack.
3262
3263 2017-10-26 Pedro Alves <palves@redhat.com>
3264
3265 * remote.c (remote_async_terminal_ours_p): Delete.
3266 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
3267 Remove references to 'remote_async_terminal_ours_p'.
3268
3269 2017-10-26 Yao Qi <yao.qi@linaro.org>
3270
3271 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
3272
3273 2017-10-26 Yao Qi <yao.qi@linaro.org>
3274
3275 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
3276 aspace const.
3277 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
3278 Likewise.
3279 * breakpoint.c (bpstat_check_location): Remove cast.
3280 (breakpoint_hit_catch_fork): Make aspce const.
3281 (breakpoint_hit_catch_solib): Likewise.
3282 (breakpoint_hit_catch_exec): Likewise.
3283 (breakpoint_hit_ranged_breakpoint): Likewise.
3284 (breakpoint_hit_watchpoint): Likewise.
3285 (base_breakpoint_breakpoint_hit): Likewise.
3286 (bkpt_breakpoint_hit): Likewise.
3287 (dprintf_breakpoint_hit): Likewise.
3288 (tracepoint_breakpoint_hit): Likewise.
3289 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
3290
3291 2017-10-26 Yao Qi <yao.qi@linaro.org>
3292
3293 * breakpoint.c (breakpoint_location_address_match): Change
3294 "struct address_space *" to "const address_space".
3295 (breakpoint_location_address_range_overlap): Likewise.
3296 (breakpoint_here_p): Likewise.
3297 (breakpoint_in_range_p): Likewise.
3298 (moribund_breakpoint_here_p): Likewise.
3299 (bp_location_inserted_here_p): Likewise.
3300 (software_breakpoint_inserted_here_p): Likewise.
3301 (hardware_breakpoint_inserted_here_p): Likewise.
3302 (hardware_watchpoint_inserted_in_range): Likewise.
3303 (bpstat_check_location): Likewise.
3304 (bpstat_stop_status): Likewise.
3305 (breakpoint_address_match): Likewise.
3306 (breakpoint_address_match_range): Likewise.
3307 (breakpoint_location_address_match): Likewise.
3308 (breakpoint_location_address_range_overlap): Likewise.
3309 (insert_single_step_breakpoint): Likewise.
3310 (breakpoint_has_location_inserted_here): Likewise.
3311 (single_step_breakpoint_inserted_here_p): Likewise.
3312 (pc_at_non_inline_function): Likewise.
3313 * breakpoint.h (bpstat_stop_status): Update declaration.
3314 (breakpoint_here_p): Likewise.
3315 (breakpoint_in_range_p): Likewise.
3316 (moribund_breakpoint_here_p): Likewise.
3317 (breakpoint_inserted_here_p): Likewise.
3318 (software_breakpoint_inserted_here_p): Likewise.
3319 (hardware_breakpoint_inserted_here_p): Likewise.
3320 (breakpoint_has_location_inserted_here): Likewise.
3321 (single_step_breakpoint_inserted_here_p): Likewise.
3322 (hardware_watchpoint_inserted_in_range): Likewise.
3323 (breakpoint_address_match): Likewise.
3324 (insert_single_step_breakpoint): Likewise.
3325 (pc_at_non_inline_function): Likewise.
3326 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
3327 * record.c (record_check_stopped_by_breakpoint): Likewise.
3328 * record.h (record_check_stopped_by_breakpoint): Likewise.
3329 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
3330
3331 2017-10-25 Yao Qi <yao.qi@linaro.org>
3332
3333 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
3334 regcache->arch () instead get_regcache_arch.
3335 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
3336 Likewise.
3337 (aarch64_fbsd_store_inferior_registers): Likewise.
3338 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
3339 (store_gregs_to_thread): Likewise.
3340 (fetch_fpregs_from_thread): Likewise.
3341 (store_fpregs_to_thread): Likewise.
3342 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
3343 (aarch64_store_return_value): Likewise.
3344 (aarch64_software_single_step): Likewise.
3345 * aix-thread.c (aix_thread_wait): Likewise.
3346 (supply_reg32): Likewise.
3347 (supply_sprs64): Likewise.
3348 (supply_sprs32): Likewise.
3349 (fill_gprs64): Likewise.
3350 (fill_gprs32): Likewise.
3351 (fill_sprs64): Likewise.
3352 (fill_sprs32): Likewise.
3353 (store_regs_user_thread): Likewise.
3354 (store_regs_kernel_thread): Likewise.
3355 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
3356 (alphabsd_store_inferior_registers): Likewise.
3357 * alpha-tdep.c (alpha_extract_return_value): Likewise.
3358 (alpha_store_return_value): Likewise.
3359 (alpha_deal_with_atomic_sequence): Likewise.
3360 (alpha_next_pc): Likewise.
3361 (alpha_software_single_step): Likewise.
3362 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
3363 (amd64bsd_store_inferior_registers): Likewise.
3364 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
3365 Likewise.
3366 (amd64_linux_store_inferior_registers): Likewise.
3367 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
3368 (amd64_collect_native_gregset): Likewise.
3369 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
3370 (amd64obsd_collect_uthread): Likewise.
3371 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
3372 (amd64_collect_fpregset): Likewise.
3373 (amd64_supply_fxsave): Likewise.
3374 (amd64_supply_xsave): Likewise.
3375 (amd64_collect_fxsave): Likewise.
3376 (amd64_collect_xsave): Likewise.
3377 * arc-tdep.c (arc_write_pc): Likewise.
3378 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
3379 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
3380 (arm_fbsd_store_inferior_registers): Likewise.
3381 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
3382 (store_vfp_regs): Likewise.
3383 (arm_linux_fetch_inferior_registers): Likewise.
3384 (arm_linux_store_inferior_registers): Likewise.
3385 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
3386 (arm_linux_sigreturn_next_pc): Likewise.
3387 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
3388 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
3389 (fetch_register): Likewise.
3390 (store_register): Likewise.
3391 * arm-tdep.c (arm_is_thumb): Likewise.
3392 (displaced_in_arm_mode): Likewise.
3393 (bx_write_pc): Likewise.
3394 (arm_get_next_pcs_addr_bits_remove): Likewise.
3395 (arm_software_single_step): Likewise.
3396 (arm_extract_return_value): Likewise.
3397 (arm_store_return_value): Likewise.
3398 (arm_write_pc): Likewise.
3399 * bfin-tdep.c (bfin_extract_return_value): Likewise.
3400 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
3401 (bsd_uthread_store_registers): Likewise.
3402 * core-regset.c (fetch_core_registers): Likewise.
3403 * corelow.c (get_core_registers): Likewise.
3404 * cris-tdep.c (cris_store_return_value): Likewise.
3405 (cris_extract_return_value): Likewise.
3406 (find_step_target): Likewise.
3407 (find_step_target): Likewise.
3408 (cris_software_single_step): Likewise.
3409 * ctf.c (ctf_fetch_registers): Likewise.
3410 * darwin-nat.c (cancel_breakpoint): Likewise.
3411 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
3412 * frv-tdep.c (frv_extract_return_value): Likewise.
3413 * ft32-tdep.c (ft32_store_return_value): Likewise.
3414 (ft32_extract_return_value): Likewise.
3415 * go32-nat.c (fetch_register): Likewise.
3416 (go32_fetch_registers): Likewise.
3417 (go32_store_registers): Likewise.
3418 (store_register): Likewise.
3419 * h8300-tdep.c (h8300_extract_return_value): Likewise.
3420 (h8300_store_return_value): Likewise.
3421 * hppa-linux-nat.c (fetch_register): Likewise.
3422 (store_register): Likewise.
3423 (hppa_linux_fetch_inferior_registers): Likewise.
3424 (hppa_linux_store_inferior_registers): Likewise.
3425 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
3426 (i386_darwin_store_inferior_registers): Likewise.
3427 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
3428 (gnu_store_registers): Likewise.
3429 * i386-linux-nat.c (fetch_register): Likewise.
3430 (store_register): Likewise.
3431 (supply_gregset): Likewise.
3432 (fill_gregset): Likewise.
3433 (i386_linux_fetch_inferior_registers): Likewise.
3434 (i386_linux_store_inferior_registers): Likewise.
3435 (i386_linux_resume): Likewise.
3436 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
3437 Likewise.
3438 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
3439 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
3440 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
3441 (i386obsd_collect_uthread): Likewise.
3442 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
3443 (i386_supply_gregset): Likewise.
3444 (i386_collect_gregset): Likewise.
3445 (i386_supply_fpregset): Likewise.
3446 (i386_collect_fpregset): Likewise.
3447 (i386_mpx_bd_base): Likewise.
3448 * i386-v4-nat.c (supply_fpregset): Likewise.
3449 (fill_fpregset): Likewise.
3450 * i387-tdep.c (i387_supply_fsave): Likewise.
3451 (i387_collect_fsave): Likewise.
3452 (i387_supply_fxsave): Likewise.
3453 (i387_collect_fxsave): Likewise.
3454 (i387_supply_xsave): Likewise.
3455 (i387_collect_xsave): Likewise.
3456 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
3457 (ia64_linux_store_registers): Likewise.
3458 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
3459 (ia64_extract_return_value): Likewise.
3460 (ia64_store_return_value): Likewise.
3461 (find_func_descr): Likewise.
3462 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
3463 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
3464 (inf_ptrace_store_registers): Likewise.
3465 * infrun.c (use_displaced_stepping): Likewise.
3466 (displaced_step_prepare_throw): Likewise.
3467 (resume): Likewise.
3468 (proceed): Likewise.
3469 (do_target_wait): Likewise.
3470 (adjust_pc_after_break): Likewise.
3471 (handle_inferior_event_1): Likewise.
3472 (handle_signal_stop): Likewise.
3473 (save_infcall_suspend_state): Likewise.
3474 (restore_infcall_suspend_state): Likewise.
3475 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
3476 * jit.c (jit_frame_prev_register): Likewise.
3477 * linux-nat.c (save_stop_reason): Likewise.
3478 (linux_nat_wait_1): Likewise.
3479 (resume_stopped_resumed_lwps): Likewise.
3480 * linux-record.c (record_linux_sockaddr): Likewise.
3481 (record_linux_msghdr): Likewise.
3482 (record_linux_system_call): Likewise.
3483 * linux-tdep.c (linux_collect_thread_registers): Likewise.
3484 * lm32-tdep.c (lm32_extract_return_value): Likewise.
3485 (lm32_store_return_value): Likewise.
3486 * m32c-tdep.c (m32c_read_flg): Likewise.
3487 (m32c_pseudo_register_read): Likewise.
3488 (m32c_pseudo_register_write): Likewise.
3489 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
3490 (m32r_linux_collect_gregset): Likewise.
3491 * m32r-tdep.c (m32r_store_return_value): Likewise.
3492 (m32r_extract_return_value): Likewise.
3493 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
3494 (m68kbsd_collect_fpregset): Likewise.
3495 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
3496 * m68k-linux-nat.c (fetch_register): Likewise.
3497 (old_fetch_inferior_registers): Likewise.
3498 (old_store_inferior_registers): Likewise.
3499 (store_regs): Likewise.
3500 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
3501 (m68k_svr4_store_return_value): Likewise.
3502 * m88k-tdep.c (m88k_store_arguments): Likewise.
3503 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
3504 (mi_cmd_data_write_register_values): Likewise.
3505 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
3506 (mips_fbsd_store_inferior_registers): Likewise.
3507 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
3508 (mips_fbsd_supply_gregs): Likewise.
3509 (mips_fbsd_collect_fpregs): Likewise.
3510 (mips_fbsd_collect_gregs): Likewise.
3511 (mips_fbsd_supply_fpregset): Likewise.
3512 (mips_fbsd_collect_fpregset): Likewise.
3513 (mips_fbsd_supply_gregset): Likewise.
3514 (mips_fbsd_collect_gregset): Likewise.
3515 * mips-linux-nat.c (supply_gregset): Likewise.
3516 (fill_gregset): Likewise.
3517 (supply_fpregset): Likewise.
3518 (fill_fpregset): Likewise.
3519 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
3520 (mips_fill_gregset): Likewise.
3521 (mips_supply_fpregset): Likewise.
3522 (mips_fill_fpregset): Likewise.
3523 (mips64_supply_gregset): Likewise.
3524 (micromips_linux_sigframe_validate): Likewise.
3525 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
3526 (mipsnbsd_fetch_inferior_registers): Likewise.
3527 (mipsnbsd_store_inferior_registers): Likewise.
3528 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
3529 (mipsnbsd_supply_gregset): Likewise.
3530 (mipsnbsd_iterate_over_regset_sections): Likewise.
3531 (mipsnbsd_supply_reg): Likewise.
3532 (mipsnbsd_supply_fpreg): Likewise.
3533 * mips-tdep.c (mips_in_frame_stub): Likewise.
3534 (mips_dummy_id): Likewise.
3535 (is_octeon_bbit_op): Likewise.
3536 (micromips_bc1_pc): Likewise.
3537 (extended_mips16_next_pc): Likewise.
3538 (mips16_next_pc): Likewise.
3539 (deal_with_atomic_sequence): Likewise.
3540 * moxie-tdep.c (moxie_process_readu): Likewise.
3541 * nios2-tdep.c (nios2_get_next_pc): Likewise.
3542 * nto-procfs.c (procfs_store_registers): Likewise.
3543 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
3544 (ppcfbsd_store_inferior_registers): Likewise.
3545 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
3546 (fetch_altivec_register): Likewise.
3547 (get_spe_registers): Likewise.
3548 (fetch_spe_register): Likewise.
3549 (fetch_altivec_registers): Likewise.
3550 (fetch_all_gp_regs): Likewise.
3551 (fetch_all_fp_regs): Likewise.
3552 (store_vsx_register): Likewise.
3553 (store_altivec_register): Likewise.
3554 (set_spe_registers): Likewise.
3555 (store_spe_register): Likewise.
3556 (store_altivec_registers): Likewise.
3557 (store_all_gp_regs): Likewise.
3558 (store_all_fp_regs): Likewise.
3559 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
3560 (ppc_linux_collect_gregset): Likewise.
3561 (ppc_canonicalize_syscall): Likewise.
3562 (ppc_linux_record_signal): Likewise.
3563 (ppu2spu_prev_register): Likewise.
3564 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
3565 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
3566 (ppcobsd_store_registers): Likewise.
3567 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
3568 Likewise.
3569 (ppc_ravenscar_generic_store_registers): Likewise.
3570 * procfs.c (procfs_fetch_registers): Likewise.
3571 (procfs_store_registers): Likewise.
3572 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
3573 (ravenscar_store_registers): Likewise.
3574 (ravenscar_prepare_to_store): Likewise.
3575 * record-btrace.c (record_btrace_fetch_registers): Likewise.
3576 * record-full.c (record_full_wait_1): Likewise.
3577 (record_full_registers_change): Likewise.
3578 (record_full_store_registers): Likewise.
3579 (record_full_core_fetch_registers): Likewise.
3580 (record_full_save): Likewise.
3581 (record_full_goto_insn): Likewise.
3582 * regcache.c (regcache_register_size): Likewise.
3583 (get_regcache_arch): Remove.
3584 (regcache_read_pc): Likewise.
3585 * regcache.h (get_regcache_arch): Remove.
3586 * remote-sim.c (gdbsim_fetch_register): Likewise.
3587 (gdbsim_store_register): Likewise.
3588 * remote.c (fetch_register_using_p): Likewise.
3589 (send_g_packet): Likewise.
3590 (remote_prepare_to_store): Likewise.
3591 (store_registers_using_G): Likewise.
3592 * reverse.c (save_bookmark_command): Likewise.
3593 (goto_bookmark_command): Likewise.
3594 * rs6000-aix-tdep.c (branch_dest): Likewise.
3595 * rs6000-nat.c (rs6000_ptrace64): Likewise.
3596 (fetch_register): Likewise.
3597 * rs6000-tdep.c (ppc_supply_reg): Likewise.
3598 (ppc_collect_reg): Likewise.
3599 (ppc_collect_gregset): Likewise.
3600 (ppc_collect_fpregset): Likewise.
3601 (ppc_collect_vsxregset): Likewise.
3602 (ppc_collect_vrregset): Likewise.
3603 (ppc_displaced_step_hw_singlestep): Likewise.
3604 (rs6000_pseudo_register_read): Likewise.
3605 (rs6000_pseudo_register_write): Likewise.
3606 * s390-linux-nat.c (supply_gregset): Likewise.
3607 (fill_gregset): Likewise.
3608 (s390_linux_fetch_inferior_registers): Likewise.
3609 * s390-linux-tdep.c (s390_write_pc): Likewise.
3610 (s390_software_single_step): Likewise.
3611 (s390_all_but_pc_registers_record): Likewise.
3612 (s390_linux_syscall_record): Likewise.
3613 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
3614 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
3615 (shnbsd_store_inferior_registers): Likewise.
3616 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
3617 (sh_extract_return_value_fpu): Likewise.
3618 (sh_store_return_value_nofpu): Likewise.
3619 (sh_corefile_supply_regset): Likewise.
3620 (sh_corefile_collect_regset): Likewise.
3621 * sh64-tdep.c (sh64_extract_return_value): Likewise.
3622 (sh64_store_return_value): Likewise.
3623 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
3624 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
3625 (sparc_store_inferior_registers): Likewise.
3626 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
3627 (sparc_ravenscar_prepare_to_store): Likewise.
3628 * sparc-tdep.c (sparc32_store_arguments): Likewise.
3629 (sparc_analyze_control_transfer): Likewise.
3630 (sparc_step_trap): Likewise.
3631 (sparc_software_single_step): Likewise.
3632 (sparc32_gdbarch_init): Likewise.
3633 (sparc_supply_rwindow): Likewise.
3634 (sparc_collect_rwindow): Likewise.
3635 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
3636 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
3637 (sparc64nbsd_collect_gregset): Likewise.
3638 (sparc64nbsd_supply_fpregset): Likewise.
3639 (sparc64nbsd_collect_fpregset): Likewise.
3640 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
3641 (sparc64_supply_gregset): Likewise.
3642 (sparc64_collect_gregset): Likewise.
3643 (sparc64_supply_fpregset): Likewise.
3644 (sparc64_collect_fpregset): Likewise.
3645 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
3646 * spu-tdep.c (spu_unwind_sp): Likewise.
3647 (spu2ppu_prev_register): Likewise.
3648 (spu_memory_remove_breakpoint): Likewise.
3649 * stack.c (return_command): Likewise.
3650 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
3651 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
3652 * tracefile.c (trace_save_ctf): Likewise.
3653 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
3654 (do_windows_store_inferior_registers): Likewise.
3655 (windows_resume): Likewise.
3656 * xtensa-linux-nat.c (fill_gregset): Likewise.
3657 (supply_gregset_reg): Likewise.
3658 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
3659 (xtensa_register_read_masked): Likewise.
3660 (xtensa_supply_gregset): Likewise.
3661 (xtensa_extract_return_value): Likewise.
3662 (xtensa_store_return_value): Likewise.
3663
3664 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
3665
3666 * doublest.c (floatformat_from_string): New function.
3667 * doublest.h (floatformat_from_string): Add prototype.
3668
3669 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
3670 (OP_FLOAT): ... this.
3671 * expression.h: Do not include "doublest.h".
3672 (union exp_element): Replace doubleconst and decfloatconst by
3673 new element floatconst.
3674 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
3675 (ada_evaluate_subexp): Likewise.
3676 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
3677 OP_DOUBLE and OP_DECFLOAT.
3678 * expprint.c (print_subexp_standard): Likewise.
3679 (dump_subexp_body_standard): Likewise.
3680 * breakpoint.c (watchpoint_exp_is_const): Likewise.
3681
3682 * parse.c: Include "dfp.h".
3683 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3684 (write_exp_elt_floatcst): New function.
3685 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
3686 and OP_DECFLOAT.
3687 (operator_check_standard): Likewise.
3688 (parse_float): Do not accept suffix. Take type as input. Return bool.
3689 Return target format buffer instead of host DOUBLEST.
3690 Use floatformat_from_string and decimal_from_string to parse
3691 either binary or decimal floating-point types.
3692 (parse_c_float): Remove.
3693 * parser-defs.h: Do not include "doublest.h".
3694 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
3695 (write_exp_elt_floatcst): Add prototype.
3696 (parse_float): Update prototype.
3697 (parse_c_float): Remove.
3698
3699 * c-exp.y: Do not include "dfp.h".
3700 (typed_val_float): Use byte buffer instead of DOUBLEST.
3701 (typed_val_decfloat): Remove.
3702 (DECFLOAT): Remove.
3703 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3704 (parse_number): Update to new parse_float interface.
3705 Parse suffixes and determine type before calling parse_float.
3706 Handle decimal and binary FP types the same way.
3707
3708 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3709 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
3710 (parse_number): Update to new parse_float interface.
3711 Parse suffixes and determine type before calling parse_float.
3712
3713 * f-exp.y: Replace dval by typed_val_float.
3714 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3715 (parse_number): Use parse_float instead of atof.
3716
3717 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3718 (parse_go_float): Remove.
3719 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3720 (parse_number): Call parse_float instead of parse_go_float.
3721 Parse suffixes and determine type before calling parse_float.
3722
3723 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3724 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3725 (parse_number): Update to new parse_float interface.
3726 Parse suffixes and determine type before calling parse_float.
3727
3728 * m2-exp.y: Replace dval by byte buffer val.
3729 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3730 (parse_number): Call parse_float instead of atof.
3731
3732 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
3733 (lex_number): Call parse_float instead of strtod.
3734 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
3735 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
3736 Use write_exp_elt_floatcst.
3737 (unit_testing): Remove static variable.
3738 (rust_type): Do not check unit_testing.
3739 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
3740
3741 * ada-exp.y (type_float, type_double): Remove.
3742 (typed_val_float): Use byte buffer instead of DOUBLEST.
3743 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
3744 * ada-lex.l (processReal): Use parse_float instead of sscanf.
3745
3746 2017-10-25 Alan Hayward <alan.hayward@arm.com>
3747
3748 * aarch64-tdep.h (enum aarch64_regnum): Remove.
3749 * arch/aarch64.h: New file.
3750
3751 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3752
3753 * dfp.h (decimal_from_string): Use const reference for argument.
3754 * dfp.c (decimal_from_string): Likewise.
3755
3756 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3757
3758 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
3759 * sh64-tdep.c (sh64_do_fp_register): Likewise.
3760 * mips-tdep.c (mips_print_fp_register): Likewise.
3761
3762 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3763
3764 * common/format.h (enum argclass): Replace decfloat_arg by
3765 dec32float_arg, dec64float_arg, and dec128float_arg.
3766 * common/format.c (parse_format_string): Update to return
3767 new decimal float argument classes.
3768
3769 * printcmd.c (printf_decfloat): Rename to ...
3770 (printf_floating): ... this. Add argclass argument, and use it
3771 instead of parsing the format string again. Add support for
3772 binary floating-point values, using floatformat_to_string.
3773 Convert value to the target format if it doesn't already match.
3774 (ui_printf): Call printf_floating instead of printf_decfloat,
3775 also for double_arg / long_double_arg. Pass argclass.
3776
3777 * dfp.c (decimal_to_string): Add format string argument.
3778 * dfp.h (decimal_to_string): Likewise.
3779
3780 * doublest.c (floatformat_to_string): Add format string argument.
3781 * doublest.h (floatformat_to_string): Likewise.
3782
3783 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3784
3785 * doublest.c (floatformat_precision): New routine.
3786 (floatformat_to_string): Likewise.
3787 * doublest.c (floatformat_to_string): Add prototype.
3788
3789 * printcmd.c (print_scalar_formatted): Only call print_floating
3790 on floating-point types.
3791 * valprint.c: Do not include "floatformat.h".
3792 (generic_val_print_decfloat): Remove.
3793 (generic_val_print): Call generic_val_print_float for both
3794 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
3795 (print_floating): Use floatformat_to_string. Handle decimal float.
3796 (print_decimal_floating): Remove, merge into floatformat_to_string.
3797 * value.h (print_decimal_floating): Remove.
3798
3799 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
3800
3801 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
3802
3803 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
3804
3805 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3806
3807 * memattr.h: Don't include vec.h.
3808 (struct mem_attrib): Initialize fields.
3809 <unknown>: New static method.
3810 (struct mem_region): Add constructors, operator<, initialize
3811 fields.
3812 * memattr.c: Include algorithm.
3813 (default_mem_attrib, unknown_mem_attrib): Remove.
3814 (user_mem_region_list): New global.
3815 (target_mem_region_list, mem_region_list): Change type to
3816 std::vector<mem_region>.
3817 (mem_use_target): Now a function.
3818 (target_mem_regions_valid): Change type to bool.
3819 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
3820 (require_user_regions): Adjust.
3821 (require_target_regions): Adjust.
3822 (create_mem_region): Adjust.
3823 (lookup_mem_region): Adjust.
3824 (invalidate_target_mem_regions): Adjust.
3825 (mem_clear): Rename to...
3826 (user_mem_clear): ... this, and adjust.
3827 (mem_command): Adjust.
3828 (info_mem_command): Adjust.
3829 (mem_enable, enable_mem_command, mem_disable,
3830 disable_mem_command): Adjust.
3831 (mem_delete): Adjust.
3832 (delete_mem_command): Adjust.
3833 * memory-map.h (parse_memory_map): Return an std::vector.
3834 * memory-map.c (parse_memory_map): Likewise.
3835 (struct memory_map_parsing_data): Add constructor.
3836 <memory_map>: Point to std::vector.
3837 (memory_map_start_memory): Adjust.
3838 (memory_map_end_memory): Adjust.
3839 (memory_map_end_property): Adjust.
3840 (clear_result): Remove.
3841 * remote.c (remote_memory_map): Return an std::vector.
3842 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
3843 Remove.
3844 (target_debug_print_mem_region_vector): New.
3845 * target-delegates.c: Regenerate.
3846 * target.h (mem_region_vector): New typedef.
3847 (to_memory_map): Return mem_region_vector.
3848 (target_memory_map): Return an std::vector.
3849 * target.c (target_memory_map): Return an std::vector.
3850 (flash_erase_command): Adjust.
3851
3852 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
3853
3854 * memory-map.c (struct memory_map_parsing_data) <property_name>:
3855 Change type to std::string.
3856 (memory_map_start_property): Adjust.
3857 (memory_map_end_property): Adjust.
3858
3859 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
3860
3861 * infrun.h: Include common/byte-vector.h.
3862 (struct displaced_step_closure): New struct.
3863 (struct buf_displaced_step_closure): New struct.
3864 * infrun.c (displaced_step_closure::~displaced_step_closure):
3865 Provide default implementation.
3866 (displaced_step_clear): Deallocate step closure with delete.
3867 * aarch64-tdep.c (displaced_step_closure): Rename to ...
3868 (aarch64_displaced_step_closure): ... this, extend
3869 displaced_step_closure.
3870 (aarch64_displaced_step_data) <dsc>: Change type to
3871 aarch64_displaced_step_closure.
3872 (aarch64_displaced_step_copy_insn): Adjust to type change, use
3873 unique_ptr.
3874 (aarch64_displaced_step_fixup): Add cast for displaced step
3875 closure.
3876 * amd64-tdep.c (displaced_step_closure): Rename to ...
3877 (amd64_displaced_step_closure): ... this, extend
3878 displaced_step_closure.
3879 <insn_buf>: Change type to std::vector<gdb_byte>.
3880 <max_len>: Remove.
3881 (fixup_riprel): Change type of DSC parameter, adjust to type
3882 change of insn_buf.
3883 (fixup_displaced_copy): Change type of DSC parameter.
3884 (amd64_displaced_step_copy_insn): Instantiate
3885 amd64_displaced_step_closure.
3886 (amd64_displaced_step_fixup): Add cast for closure type, adjust
3887 to type change of insn_buf.
3888 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
3889 parameter DSC.
3890 (arm_linux_copy_svc): Likewise.
3891 (cleanup_kernel_helper_return): Likewise.
3892 (arm_catch_kernel_helper_return): Likewise.
3893 (arm_linux_displaced_step_copy_insn): Instantiate
3894 arm_displaced_step_closure.
3895 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
3896 (displaced_read_reg): Change type of parameter DSC.
3897 (branch_write_pc): Likewise.
3898 (load_write_pc): Likewise.
3899 (alu_write_pc): Likewise.
3900 (displaced_write_reg): Likewise.
3901 (arm_copy_unmodified): Likewise.
3902 (thumb_copy_unmodified_32bit): Likewise.
3903 (thumb_copy_unmodified_16bit): Likewise.
3904 (cleanup_preload): Likewise.
3905 (install_preload): Likewise.
3906 (arm_copy_preload): Likewise.
3907 (thumb2_copy_preload): Likewise.
3908 (install_preload_reg): Likewise.
3909 (arm_copy_preload_reg): Likewise.
3910 (cleanup_copro_load_store): Likewise.
3911 (install_copro_load_store): Likewise.
3912 (arm_copy_copro_load_store) Likewise.
3913 (thumb2_copy_copro_load_store): Likewise.
3914 (cleanup_branch): Likewise.
3915 (install_b_bl_blx): Likewise.
3916 (arm_copy_b_bl_blx): Likewise.
3917 (thumb2_copy_b_bl_blx): Likewise.
3918 (thumb_copy_b): Likewise.
3919 (install_bx_blx_reg): Likewise.
3920 (arm_copy_bx_blx_reg): Likewise.
3921 (thumb_copy_bx_blx_reg): Likewise.
3922 (cleanup_alu_imm): Likewise.
3923 (arm_copy_alu_imm): Likewise.
3924 (thumb2_copy_alu_imm): Likewise.
3925 (cleanup_alu_reg): Likewise.
3926 (install_alu_reg): Likewise.
3927 (arm_copy_alu_reg): Likewise.
3928 (thumb_copy_alu_reg): Likewise.
3929 (cleanup_alu_shifted_reg): Likewise.
3930 (install_alu_shifted_reg): Likewise.
3931 (arm_copy_alu_shifted_reg): Likewise.
3932 (cleanup_load): Likewise.
3933 (cleanup_store): Likewise.
3934 (arm_copy_extra_ld_st): Likewise.
3935 (install_load_store): Likewise.
3936 (thumb2_copy_load_literal): Likewise.
3937 (thumb2_copy_load_reg_imm): Likewise.
3938 (arm_copy_ldr_str_ldrb_strb): Likewise.
3939 (cleanup_block_load_all): Likewise.
3940 (cleanup_block_store_pc): Likewise.
3941 (cleanup_block_load_pc): Likewise.
3942 (arm_copy_block_xfer): Likewise.
3943 (thumb2_copy_block_xfer): Likewise.
3944 (cleanup_svc): Likewise.
3945 (install_svc): Likewise.
3946 (arm_copy_svc): Likewise.
3947 (thumb_copy_svc): Likewise.
3948 (arm_copy_undef): Likewise.
3949 (thumb_32bit_copy_undef): Likewise.
3950 (arm_copy_unpred): Likewise.
3951 (arm_decode_misc_memhint_neon): Likewise.
3952 (arm_decode_unconditional): Likewise.
3953 (arm_decode_miscellaneous): Likewise.
3954 (arm_decode_dp_misc): Likewise.
3955 (arm_decode_ld_st_word_ubyte): Likewise.
3956 (arm_decode_media): Likewise.
3957 (arm_decode_b_bl_ldmstm): Likewise.
3958 (arm_decode_ext_reg_ld_st): Likewise.
3959 (thumb2_decode_dp_shift_reg): Likewise.
3960 (thumb2_decode_ext_reg_ld_st): Likewise.
3961 (arm_decode_svc_copro): Likewise.
3962 (thumb2_decode_svc_copro): Likewise.
3963 (install_pc_relative): Likewise.
3964 (thumb_copy_pc_relative_16bit): Likewise.
3965 (thumb_decode_pc_relative_16bit): Likewise.
3966 (thumb_copy_pc_relative_32bit): Likewise.
3967 (thumb_copy_16bit_ldr_literal): Likewise.
3968 (thumb_copy_cbnz_cbz): Likewise.
3969 (thumb2_copy_table_branch): Likewise.
3970 (cleanup_pop_pc_16bit_all): Likewise.
3971 (thumb_copy_pop_pc_16bit): Likewise.
3972 (thumb_process_displaced_16bit_insn): Likewise.
3973 (decode_thumb_32bit_ld_mem_hints): Likewise.
3974 (thumb_process_displaced_32bit_insn): Likewise.
3975 (thumb_process_displaced_insn): Likewise.
3976 (arm_process_displaced_insn): Likewise.
3977 (arm_displaced_init_closure): Likewise.
3978 (arm_displaced_step_fixup): Add cast for closure.
3979 * arm-tdep.h: Include infrun.h.
3980 (displaced_step_closure): Rename to ...
3981 (arm_displaced_step_closure): ... this, extend
3982 displaced_step_closure.
3983 <u::svc::copy_svc_os>: Change type of parameter DSC.
3984 <cleanup>: Likewise.
3985 (arm_process_displaced_insn): Likewise.
3986 (arm_displaced_init_closure): Likewise.
3987 (displaced_read_reg): Likewise.
3988 (displaced_write_reg): Likewise.
3989 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3990 Adjust.
3991 * i386-tdep.h: Include infrun.h.
3992 (i386_displaced_step_closure): New typedef.
3993 * i386-tdep.c (i386_displaced_step_copy_insn): Use
3994 i386_displaced_step_closure.
3995 (i386_displaced_step_fixup): Adjust.
3996 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
3997 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
3998 and unique_ptr.
3999 (ppc_displaced_step_fixup): Adjust.
4000 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
4001 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
4002 and unique_ptr.
4003 (s390_displaced_step_fixup): Adjust.
4004
4005 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
4006
4007 * interps.h (interp_resume, interp_suspend, interp_set_temp):
4008 Remove declarations.
4009
4010 2017-10-20 Tom Tromey <tom@tromey.com>
4011
4012 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
4013 std::vector.
4014 (gdb_bfd_record_inclusion): Update.
4015 (bfdp): Remove typedef.
4016
4017 2017-10-20 Tom Tromey <tom@tromey.com>
4018
4019 * gdb_bfd.c (gdb_bfd_ref): Use new.
4020 (struct gdb_bfd_data): Add constructor, destructor, and member
4021 initializers.
4022 (gdb_bfd_unref): Use delete.
4023
4024 2017-10-20 Tom Tromey <tom@tromey.com>
4025
4026 * exec.c (exec_file_attach): Use new_bfd_ref.
4027 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
4028 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
4029 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
4030 new_bfd_ref.
4031 * gdb_bfd.h (new_bfd_ref): New function.
4032
4033 2017-10-20 Pedro Alves <palves@redhat.com>
4034
4035 * main.c (captured_command_loop): Add attribute noinline.
4036
4037 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
4038
4039 * interps.c (struct interp_factory): Add constructor.
4040 (interp_factory_p): Remove typedef.
4041 (DEF_VEC_P(interp_factory_p)): Remove.
4042 (interpreter_factories): Change type to std::vector.
4043 (interp_factory_register): Adjust.
4044 (interp_lookup): Adjust.
4045 (interpreter_completer): Adjust.
4046
4047 2017-10-19 Tom Tromey <tom@tromey.com>
4048
4049 * break-catch-syscall.c (catch_syscall_completer): Use
4050 std::string, gdb::unique_xmalloc_ptr.
4051
4052 2017-10-19 Tom Tromey <tom@tromey.com>
4053
4054 * infcall.c (call_function_by_hand_dummy): Use std::string.
4055
4056 2017-10-19 Tom Tromey <tom@tromey.com>
4057
4058 * mi/mi-main.c (mi_cmd_execute): Update.
4059 * top.h (prepare_execute_command): Return scoped_value_mark.
4060 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
4061 Add move constructor.
4062 * top.c (prepare_execute_command): Return scoped_value_mark.
4063 (execute_command): Update.
4064
4065 2017-10-19 Pedro Alves <palves@redhat.com>
4066
4067 * xml-support.c (xml_fetch_content_from_file): Check fread's
4068 return.
4069
4070 2017-10-19 Pedro Alves <palves@redhat.com>
4071
4072 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
4073 async.
4074 (handle_error_fd): New function.
4075 (ser_base_async): Add/delete an event loop file handler for
4076 error_fd.
4077
4078 2017-10-19 Pedro Alves <palves@redhat.com>
4079
4080 * xml-support.c (xml_fetch_content_from_file): Don't read in
4081 chunks. Instead use fseek to determine the file's size, and read
4082 it in one go.
4083
4084 2017-11-18 Keith Seitz <keiths@redhat.com>
4085
4086 * c-exp.y (oper): Canonicalize conversion operators of user-defined
4087 types.
4088 Add whitespace to front of type name.
4089
4090 2017-10-18 Keith Seitz <keiths@redhat.com>
4091
4092 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
4093 DW_AT_accessibility.
4094
4095 2017-10-18 Yao Qi <yao.qi@linaro.org>
4096
4097 * features/tic6x-c62x-linux.c: Remove.
4098
4099 2017-10-17 Tom Tromey <tom@tromey.com>
4100
4101 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
4102 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
4103 (do_mixed_source_and_assembly): Likewise.
4104
4105 2017-10-17 Tom Tromey <tom@tromey.com>
4106
4107 * regcache.c (regcache::xfer_part): Remove assertion.
4108
4109 2017-10-17 Pedro Alves <palves@redhat.com>
4110
4111 * xml-support.c (xml_fetch_content_from_file): Call
4112 unique_ptr::release() instead unique_ptr::get() when passing
4113 through xrealloc.
4114
4115 2017-10-17 Yao Qi <yao.qi@linaro.org>
4116
4117 * regcache.c (regcache::xfer_part): Remove parameters read and
4118 write, add parameter is_raw. All callers are updated.
4119
4120 2017-10-16 Keith Seitz <keiths@redhat.com>
4121
4122 * c-typeprint.c (enum access_specifier): Moved here from
4123 c_type_print_base.
4124 (output_access_specifier): New function.
4125 (c_type_print_base): Consider typedefs when assessing
4126 whether access labels are needed.
4127 Use output_access_specifier as needed.
4128 Output access specifier for typedefs, if needed.
4129 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
4130 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
4131 fields.
4132 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
4133 accessor macros.
4134
4135 2017-10-16 Tom Tromey <tom@tromey.com>
4136
4137 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
4138 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
4139 * target.c (target_fileio_read_stralloc): Update.
4140 * sparc64-tdep.c (adi_is_addr_mapped): Update.
4141 * target.h (target_fileio_read_stralloc): Return
4142 unique_xmalloc_ptr.
4143
4144 2017-10-16 Tom Tromey <tom@tromey.com>
4145
4146 * xml-syscall.c (xml_init_syscalls_info): Update.
4147 * xml-support.c (xinclude_start_include): Update.
4148 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
4149 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
4150 (xml_fetch_content_from_file): Likewise.
4151 * osdata.c (get_osdata): Update.
4152 * target.h (target_read_stralloc, target_get_osdata): Return
4153 unique_xmalloc_ptr.
4154 * solib-aix.c (solib_aix_get_library_list): Update.
4155 * solib-target.c (solib_target_current_sos): Update.
4156 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
4157 * xml-tdesc.c (fetch_available_features_from_target): Update.
4158 (target_fetch_description_xml): Update.
4159 (file_read_description_xml): Update.
4160 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
4161 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
4162 (remote_pid_to_exec_file): Update.
4163 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
4164 (target_get_osdata): Likewise.
4165
4166 2017-10-16 Tom Tromey <tom@tromey.com>
4167
4168 * remote.c (remote_register_number_and_offset): Use std::vector.
4169 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
4170 (putpkt_binary): Use gdb::def_vector.
4171 (compare_sections_command): Use gdb::byte_vector.
4172
4173 2017-10-16 Tom Tromey <tom@tromey.com>
4174
4175 * ppc-linux-nat.c (hwdebug_insert_point): Use
4176 gdb::unique_xmalloc_ptr, XDUP.
4177
4178 2017-10-16 Tom Tromey <tom@tromey.com>
4179
4180 * probe.c (parse_probes): Use std::string.
4181 (info_probes_for_ops, enable_probes_command)
4182 (disable_probes_command): Remove cleanups.
4183
4184 2017-10-16 Tom Tromey <tom@tromey.com>
4185
4186 * buildsym.c (block_compar): Remove.
4187 (end_symtab_get_static_block): Use std::vector.
4188
4189 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
4190
4191 * memrange.h (struct mem_range): Define operator< and operator==.
4192 (mem_range_s): Remove.
4193 (DEF_VEC_O (mem_range_s)): Remove.
4194 (normalize_mem_ranges): Change parameter type to std::vector.
4195 * memrange.c (compare_mem_ranges): Remove.
4196 (normalize_mem_ranges): Change parameter type to std::vector,
4197 adjust to vector change.
4198 * exec.c (section_table_available_memory): Return vector, remove
4199 parameter.
4200 (section_table_read_available_memory): Adjust to std::vector
4201 change.
4202 * remote.c (remote_read_bytes): Adjust to std::vector
4203 change.
4204 * tracepoint.h (traceframe_available_memory): Change parameter
4205 type to std::vector.
4206 * tracepoint.c (traceframe_available_memory): Change parameter
4207 type to std::vector, adjust.
4208 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
4209 std::vector change.
4210 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4211 unittests/memrange-selftests.c.
4212 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
4213 * gdb/unittests/memrange-selftests.c: New file.
4214
4215 2017-10-16 Pedro Alves <palves@redhat.com>
4216
4217 * elfread.c (probe_key_free): Rename range-for variable.
4218 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
4219 (find_probe_by_pc, collect_probes): Rename range-for variable.
4220
4221 2017-10-16 Yao Qi <yao.qi@linaro.org>
4222
4223 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
4224 * features/tic6x-c62x.c: Remove.
4225 * features/tic6x-c64x-linux.c: Remove.
4226 * features/tic6x-c64x.c: Remove.
4227 * features/tic6x-c64xp-linux.c: Remove.
4228 * features/tic6x-c64xp.c: Remove.
4229 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
4230 initialize_tdesc_tic6x_*_linux functions.
4231 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
4232 initialize_tdesc_tic6x_* functions.
4233
4234 2017-10-16 Yao Qi <yao.qi@linaro.org>
4235
4236 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
4237 tic6x-c62x.
4238 * regformats/tic6x-c62x.dat: Remove.
4239 * regformats/tic6x-c64x.dat: Remove.
4240 * regformats/tic6x-c64xp.dat: Remove.
4241
4242 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
4243
4244 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
4245 (the !HAVE_LIBEXPAT version).
4246
4247 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4248
4249 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
4250 const.
4251
4252 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4253
4254 * target.h: Include tracepoint.h.
4255 (enum trace_find_type): Move to tracepoint.h.
4256 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
4257 * tracepoint.h: Don't include target.h
4258 (enum trace_find_type): Move from target.h.
4259 (parse_traceframe_info): Return a unique ptr.
4260 * tracepoint.c (current_traceframe_info): Change type to unique
4261 ptr.
4262 (free_traceframe_info): Remove.
4263 (clear_traceframe_info): Don't manually free
4264 current_traceframe_info.
4265 (free_result): Remove.
4266 (parse_traceframe_info): Return a unique ptr.
4267 (get_traceframe_info): Adjust to unique ptr.
4268 * ctf.c (ctf_traceframe_info): Return a unique ptr.
4269 * remote.c (remote_traceframe_info): Return a unique ptr.
4270 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
4271 ptr.
4272 * target-debug.h (target_debug_print_traceframe_info_up): New
4273 macro.
4274 * target-delegates.c: Regenerate.
4275
4276 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4277
4278 * memrange.h (struct mem_range): Add constructors.
4279 * tracepoint.h (struct traceframe_info) <memory>: Change type to
4280 std::vector<mem_range>.
4281 * tracepoint.c (free_traceframe_info): Don't manually free
4282 vector.
4283 (traceframe_info_start_memory): Adjust to vector change.
4284 (traceframe_available_memory): Likewise.
4285 * tracefile-tfile.c (build_traceframe_info): Likewise.
4286 * ctf.c (ctf_traceframe_info): Likewise.
4287
4288 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4289
4290 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
4291 std::vector<int>.
4292 * tracepoint.c (free_traceframe_info): Deallocate with delete.
4293 (traceframe_info_start_tvar): Adjust to vector change.
4294 (parse_traceframe_info): Allocate with new.
4295 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
4296 vector change.
4297 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
4298 change.
4299 tfile_traceframe_info): Allocate with new.
4300 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
4301 change.
4302
4303 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
4304
4305 * tracepoint.c (traceframe_info): Rename to...
4306 (current_traceframe_info): ...this.
4307 (clear_traceframe_info): Adjust.
4308 (get_traceframe_info): Adjust.
4309
4310 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4311
4312 * nat/linux-osdata.c: Include algorithm.
4313 (compare_processes): Remove.
4314 (struct pid_pgid_entry): New struct.
4315 (linux_xfer_osdata_processgroups): Use std::vector instead of
4316 XNEWVEC.
4317
4318 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
4319
4320 * objfiles.h: Don't include symfile.h.
4321 (struct partial_symbol): Remove forward-declaration.
4322 (struct objfile) <global_psymbols, static_psymbols>: Change type
4323 to std::vector<partial_symbol *>.
4324 * objfiles.c (objfile::objfile): Don't memset those fields.
4325 (objfile::~objfile): Don't free those fields.
4326 * psympriv.h (struct psymbol_allocation_list): Remove
4327 forward-declaration.
4328 (add_psymbol_to_list): Change psymbol_allocation_list parameter
4329 to std::vector.
4330 (start_psymtab_common): Change parameters to std::vector.
4331 * psymtab.c: Include algorithm.
4332 (require_partial_symbols): Call shrink_to_fit.
4333 (find_pc_sect_psymbol): Adjust to vector change.
4334 (match_partial_symbol): Likewise.
4335 (lookup_partial_symbol): Likewise.
4336 (psym_relocate): Likewise.
4337 (dump_psymtab): Likewise.
4338 (recursively_search_psymtabs): Likewise.
4339 (compare_psymbols): Remove.
4340 (sort_pst_symbols): Adjust to vector change.
4341 (start_psymtab_common): Likewise.
4342 (end_psymtab_common): Likewise.
4343 (psymbol_bcache_full): De-constify return value.
4344 (add_psymbol_to_bcache): Likewise.
4345 (extend_psymbol_list): Remove.
4346 (append_psymbol_to_list): Adjust to vector change.
4347 (add_psymbol_to_list): Likewise.
4348 (init_psymbol_list): Likewise.
4349 (maintenance_info_psymtabs): Likewise.
4350 (maintenance_check_psymtabs): Likewise.
4351 * symfile.h (struct psymbol_allocation_list): Remove.
4352 * symfile.c (reread_symbols): Adjust to vector change.
4353 * dbxread.c (start_psymtab): Change type of parameters.
4354 (dbx_symfile_read): Adjust to vector change.
4355 (read_dbx_symtab): Likewise.
4356 (start_psymtab): Change type of parameters.
4357 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
4358 (create_partial_symtab): Likewise.
4359 (add_partial_symbol): Likewise.
4360 (write_one_signatured_type): Likewise.
4361 (recursively_write_psymbols): Likewise.
4362 * mdebugread.c (parse_partial_symbols): Likewise.
4363 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
4364 (scan_xcoff_symtab): Adjust to vector change.
4365 (xcoff_initial_scan): Likewise.
4366
4367 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
4368
4369 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
4370
4371 2017-10-13 Yao Qi <yao.qi@linaro.org>
4372
4373 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
4374 Remove s390x-*-expedite, add s390x-expedite.
4375
4376 2017-10-13 Yao Qi <yao.qi@linaro.org>
4377
4378 * features/s390-gs-linux64.c: Regenerated.
4379 * features/s390x-gs-linux64.c: Regenerated.
4380
4381 2017-10-13 Tom Tromey <tom@tromey.com>
4382
4383 * compile/compile-object-run.c (do_module_cleanup): Use delete.
4384 * solib.c (update_solib_list, reload_shared_libraries_1): Use
4385 delete.
4386 * symfile.c (symbol_file_add_with_addrs): Use new.
4387 (symbol_file_add_separate): Update comment.
4388 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
4389 * jit.c (jit_object_close_impl): Use new.
4390 (jit_unregister_code): Use delete.
4391 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
4392 (~objfile): Rename from free_objfile.
4393 (free_objfile_separate_debug, do_free_objfile_cleanup)
4394 (free_all_objfiles, objfile_purge_solibs): Use delete.
4395 * objfiles.h (struct objfile): Add constructor and destructor.
4396 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
4397 (allocate_objfile, free_objfile): Don't declare.
4398 (struct objstats): Add initializers.
4399
4400 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4401
4402 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
4403 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
4404 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
4405 * gdbarch.h: Regenerate.
4406 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
4407 Adjust comment.
4408 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
4409 (i386_displaced_step_fixup): Adjust comment.
4410 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
4411
4412 2017-10-12 Tom Tromey <tom@tromey.com>
4413
4414 * prologue-value.h (pv_area::store_would_trash): Return bool.
4415 (pv_area::find_reg): Likewise.
4416 * prologue-value.c (pv_area::store_would_trash): Return bool.
4417 (pv_area::find_reg): Likewise.
4418
4419 2017-10-12 Tom Tromey <tom@tromey.com>
4420
4421 * s390-linux-tdep.c (s390_store, s390_load)
4422 (s390_check_for_saved, s390_analyze_prologue): Update.
4423 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
4424 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
4425 * prologue-value.h (class pv_area): Move from prologue-value.c.
4426 Change names of members. Add constructor, destructor, member
4427 functions.
4428 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
4429 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
4430 (pv_area_fetch, pv_area_scan): Don't declare.
4431 * prologue-value.c (struct pv_area::area_entry): Now member of
4432 pv_area.
4433 (struct pv_area): Move to prologue-value.h.
4434 (pv_area::pv_area): Rename from make_pv_area.
4435 (pv_area::~pv_area): Rename from free_pv_area.
4436 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
4437 (clear_entries, find_entry, overlaps, store_would_trash, store)
4438 (fetch, find_reg, scan): Now member of pv_area.
4439 Remove "area" argument. Update.
4440 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
4441 Update.
4442 * mn10300-tdep.c (push_reg, check_for_saved)
4443 (mn10300_analyze_prologue): Update.
4444 * mep-tdep.c (is_arg_spill, check_for_saved)
4445 (mep_analyze_prologue): Update.
4446 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
4447 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
4448 (m32c_is_struct_return, m32c_analyze_prologue): Update.
4449 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
4450 Update.
4451 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
4452 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
4453
4454 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
4455
4456 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
4457 * linux-nat.c (linux_nat_delete_thread): New variable.
4458 (lwp_free): Invoke linux_nat_delete_thread if set.
4459 (linux_nat_set_delete_thread): New function.
4460 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
4461 thread delete callback.
4462 * arm-linux-nat.c (arm_linux_delete_thread): New function.
4463 (_initialize_arm_linux_nat): Assign thread delete callback.
4464 * s390-linux-nat.c (s390_delete_thread): New function.
4465 (_initialize_s390_nat): Assign thread delete callback.
4466 * x86-linux-nat.c (x86_linux_add_target): Likewise.
4467 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
4468 function.
4469 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
4470 declaration.
4471 * nat/x86-linux.c (x86_linux_delete_thread): New function.
4472 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
4473
4474 2017-10-09 Tom Tromey <tom@tromey.com>
4475
4476 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
4477 std::string.
4478 * tui/tui-layout.c (enum tui_status): Use std::string.
4479
4480 2017-10-11 Tom Tromey <tom@tromey.com>
4481
4482 * gdbthread.h (thread_command): Constify.
4483 * inferior.h (detach_command): Constify.
4484 * top.h (set_history, show_history): Constify.
4485 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
4486 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
4487 * bsd-kvm.c (bsd_kvm_cmd): Constify.
4488 * printcmd.c (set_command): Constify.
4489 (non_const_set_command): New function.
4490 * dcache.c (set_dcache_command, show_dcache_command): Constify.
4491 * breakpoint.c (enable_command, disable_command, delete_command)
4492 (catch_command, tcatch_command, set_breakpoint_cmd)
4493 (show_breakpoint_cmd): Constify.
4494 * macrocmd.c (macro_command): Constify.
4495 * infcmd.c (unset_command, kill_command, detach_command)
4496 (info_proc_cmd): Constify.
4497 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
4498 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
4499 (info_auto_load_cmd): Constify.
4500 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
4501 (unset_tdesc_cmd): Constify.
4502 * ada-lang.c (set_ada_command, show_ada_command)
4503 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
4504 * guile/guile.c (set_guile_command, show_guile_command)
4505 (info_guile_command): Constify.
4506 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
4507 Constify.
4508 * skip.c (skip_command): Constify.
4509 * compile/compile.c (_initialize_compile): Constify.
4510 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
4511 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
4512 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
4513 (maint_btrace_pt_show_cmd): Constify.
4514 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
4515 Constify.
4516 * python/python.c (user_show_python, user_set_python): Constify.
4517 * mips-tdep.c (set_mips_command, show_mips_command)
4518 (set_mipsfpu_command): Constify.
4519 * record-btrace.c (cmd_record_btrace_start)
4520 (cmd_set_record_btrace, cmd_show_record_btrace)
4521 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
4522 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
4523 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
4524 Constify.
4525 * symfile.c (overlay_command): Constify.
4526 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
4527 * cli/cli-logging.c (set_logging_command, show_logging_command):
4528 Constify.
4529 * cli/cli-dump.c (dump_command, append_command)
4530 (srec_dump_command, ihex_dump_command, verilog_dump_command)
4531 (tekhex_dump_command, binary_dump_command)
4532 (binary_append_command): Constify.
4533 * cli/cli-decode.c (struct cmd_list_element): Change type of
4534 "fun".
4535 * cli/cli-cmds.c (info_command, show_command, set_debug)
4536 (show_debug): Constify.
4537 (show_command): Add non-const overload.
4538 * top.c (set_history, show_history): Constify.
4539 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
4540 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
4541 * target.c (target_command): Constify.
4542 * sparc64-tdep.c (info_adi_command): Constify.
4543 * record-full.c (cmd_record_full_start): Constify.
4544 (set_record_full_command): Constify. Fix typo.
4545 (show_record_full_command): Constify.
4546 * thread.c (thread_command, thread_apply_command): Constify.
4547 * memattr.c (dummy_cmd): Constify.
4548 * value.c (function_command): Constify.
4549 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
4550 * probe.c (info_probes_command): Constify.
4551 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
4552 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
4553 (show_thread_cmd, set_thread_default_cmd)
4554 (show_thread_default_cmd): Constify.
4555 (check_empty): Constify.
4556 * tracepoint.c (tfind_command): Constify.
4557 * cp-support.c (maint_cplus_command): Constify.
4558 * windows-tdep.c (info_w32_command): Constify.
4559 * record.c (cmd_record_start, set_record_command)
4560 (show_record_command, info_record_command, cmd_record_goto):
4561 Constify.
4562 * ravenscar-thread.c (set_ravenscar_command)
4563 (show_ravenscar_command): Constify.
4564 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
4565 Constify.
4566 (add_internal_problem_command): Remove casts.
4567 * arc-tdep.c (maintenance_print_arc_command): Constify.
4568 * valprint.c (set_print, show_print, set_print_raw)
4569 (show_print_raw): Constify.
4570 * maint.c (maintenance_command, maintenance_info_command)
4571 (maintenance_print_command, maintenance_set_cmd)
4572 (maintenance_show_cmd, set_per_command_cmd)
4573 (show_per_command_cmd, maintenance_check_command): Constify.
4574 * language.c (set_check, show_check): Constify.
4575 * typeprint.c (show_print_type, set_print_type): Constify.
4576 * go32-nat.c (go32_info_dos_command): Constify.
4577
4578 2017-10-11 Tom Tromey <tom@tromey.com>
4579
4580 * breakpoint.c (prepare_re_set_context): Remove.
4581 (breakpoint_re_set_one): Update. Don't use cleanups.
4582 (breakpoint_re_set): Use scoped_restore, std::string, and
4583 scoped_restore_current_language.
4584
4585 2017-10-11 Tom Tromey <tom@tromey.com>
4586
4587 * breakpoint.c (commands_command_1): Use std::string.
4588 (cleanup_executing_breakpoints): Remove.
4589 (bpstat_do_actions_1): Use scoped_restore.
4590 (bpstat_check_watchpoint): Use std::string.
4591 (decode_static_tracepoint_spec): Likewise.
4592 (break_range_command): Likewise.
4593 (watch_command_1): Likewise.
4594 (compare_breakpoints): Change argument types.
4595 (clear_command): Use std::vector.
4596 (cleanup_executing_breakpoints): Remove.
4597 (update_global_location_list): Use unique_xmalloc_ptr.
4598 (strace_command): Remove unused declaration.
4599
4600 2017-10-11 John Baldwin <jhb@FreeBSD.org>
4601
4602 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
4603 * NEWS: Mention new FreeBSD/arm native configuration.
4604 * configure.host: Add arm*-*-freebsd*.
4605 * configure.nat: Likewise.
4606 * arm-fbsd-nat.c: New file.
4607
4608 2017-10-11 John Baldwin <jhb@FreeBSD.org>
4609
4610 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
4611 (ALLDEPFILES): Add arm-fbsd-tdep.c.
4612 * NEWS: Mention new FreeBSD/arm target.
4613 * configure.tgt: Add arm*-*-freebsd*.
4614 * arm-fbsd-tdep.c: New file.
4615 * arm-fbsd-tdep.h: New file.
4616
4617 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4618
4619 * linux-tdep.c (linux_make_corefile_notes): Remove call to
4620 `gdbarch_elfcore_write_linux_prpsinfo'.
4621 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
4622 method.
4623 (elf_internal_linux_prpsinfo): Remove declaration.
4624 * gdbarch.h: Regenerate.
4625 * gdbarch.c: Regenerate.
4626
4627 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
4628
4629 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
4630 `set_gdbarch_elfcore_write_linux_prpsinfo'.
4631
4632 2017-10-11 Pedro Alves <palves@redhat.com>
4633
4634 * breakpoint.c (reattach_breakpoints): Delete.
4635 * breakpoint.h (reattach_breakpoints): Delete.
4636
4637 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
4638
4639 * symfile.c (registered_sym_fns): Make struct, not typedef.
4640 (DEF_VEC_O (registered_sym_fns)): Remove.
4641 (symtab_fns): Change type to std::vector.
4642 (add_symtab_fns): Adjust.
4643 (find_sym_fns): Adjust.
4644
4645 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
4646
4647 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
4648 * arc-tdep.h (arc_arch_is_em): New function.
4649 (arc_arch_is_hs): Likewise.
4650
4651 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
4652
4653 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
4654 parentheses in the declaration.
4655 (macro_lookup_inclusion): Likewise.
4656 (macro_lookup_definition): Likewise.
4657 * p-lang.h (pascal_builtin_types): Likewise.
4658 * tui/tui-data.c (tui_win_list): Likewise.
4659 * tui/tui-data.h (tui_win_list): Likewise.
4660 * utils.h (make_cleanup_free_section_addr_info): Likewise.
4661
4662 2017-10-11 Mark Rages <markrages@gmail.com>
4663
4664 * target-memory.c (block_boundaries): Fix for block address not
4665 aligned on block size.
4666
4667 2017-10-10 Pedro Alves <palves@redhat.com>
4668 Tom Tromey <tom@tromey.com>
4669
4670 * breakpoint.c (struct captured_breakpoint_query_args)
4671 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
4672 (print_breakpoint): New.
4673 * breakpoint.h (print_breakpoint): Declare.
4674 * common/common-exceptions.h (enum return_reason): Remove
4675 references to catch_exceptions.
4676 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
4677 Delete.
4678 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
4679 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
4680 * gdb.h: Delete.
4681 * gdbthread.h (thread_select): Declare.
4682 * mi/mi-cmd-break.c: Don't include gdb.h.
4683 (breakpoint_notify): Use print_breakpoint.
4684 * mi/mi-cmd-catch.c: Don't include gdb.h.
4685 * mi/mi-interp.c: Don't include gdb.h.
4686 (mi_print_breakpoint_for_event): New.
4687 (mi_breakpoint_created, mi_breakpoint_modified): Use
4688 mi_print_breakpoint_for_event.
4689 * mi/mi-main.c: Don't include gdb.h.
4690 (mi_cmd_thread_select): Parse the global thread ID here. Use
4691 thread_select instead of gdb_thread_select.
4692 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
4693 of using gdb_list_thread_ids.
4694 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
4695 FILEIO_ENOSYS here.
4696 (remote_fileio_request): Use TRY/CATCH instead of
4697 catch_exceptions.
4698 * symfile-mem.c (struct symbol_file_add_from_memory_args)
4699 (symbol_file_add_from_memory_wrapper): Delete.
4700 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
4701 * thread.c: Don't include gdb.h.
4702 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
4703 (thread_alive): Use thread_select.
4704 (do_captured_thread_select): Delete, parts salvaged as ...
4705 (thread_select): ... this new function.
4706 (gdb_thread_select): Delete.
4707
4708 2017-10-10 Pedro Alves <palves@redhat.com>
4709 Tom Tromey <tom@tromey.com>
4710
4711 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
4712 and reverse logic.
4713 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
4714 No longer macros. Instead ...
4715 (enum wp_check_result): They're now values of this new
4716 enumeration.
4717 (watchpoint_check): Change return type to wp_check_result and
4718 parameter type to bpstat.
4719 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
4720 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
4721 catch_errors. Reverse logic of watchpoint_check call.
4722 (breakpoint_re_set_one): Now returns void and takes a breakpoint
4723 pointer as parameter.
4724 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
4725 * common/common-exceptions.c (throw_exception_sjlj): Update
4726 comments to avoid mentioning catch_errors.
4727 * exceptions.c (catch_errors): Delete.
4728 * exceptions.h: Update comments to avoid mentioning catch_errors.
4729 (catch_errors_ftype, catch_errors): Delete.
4730 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
4731 (hook_stop_stub): Delete.
4732 (restore_selected_frame): Change return type to void, and
4733 parameter type to const frame_id &.
4734 (restore_infcall_control_state): Use TRY/CATCH instead of
4735 catch_errors.
4736 * main.c (captured_command_loop): Return void and remove
4737 parameter. Remove references to catch_errors.
4738 (captured_main): Use TRY/CATCH instead of catch_errors.
4739 * objc-lang.c (objc_submethod_helper_data)
4740 (find_objc_msgcall_submethod_helper): Delete.
4741 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
4742 catch_errors.
4743 * record-full.c (record_full_message): Return void.
4744 (record_full_message_args, record_full_message_wrapper): Delete.
4745 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
4746 instead of catch_errors.
4747 * solib-aix.c (solib_aix_open_symbol_file_object): Change
4748 parameter type to int.
4749 * solib-darwin.c (open_symbol_file_object): Ditto.
4750 * solib-dsbt.c (open_symbol_file_object): Ditto.
4751 * solib-frv.c (open_symbol_file_object): Ditto.
4752 * solib-svr4.c (open_symbol_file_object): Ditto.
4753 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
4754 * solib.c (update_solib_list): Use TRY/CATCH instead of
4755 catch_errors.
4756 * solist.h (struct target_so_ops) <open_symbol_file_object>:
4757 Change type.
4758 * symmisc.c (struct print_symbol_args): Remove.
4759 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
4760 (print_symbol): Change type.
4761 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
4762 and remove parameters.
4763 (catch_errors): New.
4764 (get_windows_debug_event): Adjust.
4765
4766 2017-10-09 Tom Tromey <tom@tromey.com>
4767
4768 * mi/mi-main.c (free_splay_tree): Remove.
4769 (list_available_thread_groups): Use splay_tree_up.
4770 * common/gdb_splay_tree.h: New file.
4771
4772 2017-10-09 Tom Tromey <tom@tromey.com>
4773
4774 * mi/mi-main.c (do_nothing): Remove.
4775 (list_available_thread_groups): Update.
4776
4777 2017-10-09 Pedro Alves <palves@redhat.com>
4778
4779 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
4780 reading registers when switching context.
4781
4782 2017-10-09 John Baldwin <jhb@FreeBSD.org>
4783
4784 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
4785 (fbsd_convert_siginfo): Likewise.
4786 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
4787
4788 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
4789
4790 * configure.ac (try_guile_versions): Remove guile-2.2.
4791 * configure: Regenerate.
4792
4793 2017-10-09 Tom Tromey <tom@tromey.com>
4794
4795 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
4796 (COMPILE.pre): Use $(CXX).
4797
4798 2017-10-09 Pedro Alves <palves@redhat.com>
4799
4800 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
4801 Use bool.
4802 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4803 * cp-support.h (cp_remove_params): Now returns a
4804 gdb::unique_xmalloc_ptr.
4805 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
4806 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
4807 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
4808 returning a gdb::unique_xmalloc_ptr.
4809 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
4810 * stack.c (find_frame_funname): Adjust to cp_remove_params
4811 returning a gdb::unique_xmalloc_ptr.
4812
4813 2017-10-08 Tom Tromey <tom@tromey.com>
4814
4815 * dwarf2read.c (dwarf2_get_dwz_file): Use
4816 gdb::unique_xmalloc_ptr.
4817 (find_slot_in_mapped_hash): Likewise.
4818 (dwarf2_physname): Likewise.
4819 (create_dwo_unit_in_dwp_v1): Use std::string.
4820 (create_dwo_unit_in_dwp_v2): Likewise.
4821 (lookup_dwo_cutu): Likewise.
4822 (inherit_abstract_dies): Use std::vector.
4823 (read_array_type): Likewise.
4824 (dwarf_decode_macros): Remove unused declaration.
4825 (unsigned_int_compar): Remove.
4826 (dwarf2_build_psymtabs_hard): Use scoped_restore.
4827 (psymtabs_addrmap_cleanup): Remove.
4828
4829 2017-10-08 Tom Tromey <tom@tromey.com>
4830
4831 * frame-unwind.c (frame_unwind_try_unwinder): Update.
4832 * frame.h (frame_cleanup_after_sniffer): Declare.
4833 (frame_prepare_for_sniffer): Return void.
4834 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
4835 type of argument.
4836 (frame_prepare_for_sniffer): Return void.
4837
4838 2017-10-08 Tom Tromey <tom@tromey.com>
4839
4840 * utils.h (make_cleanup_value_free): Remove.
4841 * utils.c (do_value_free, struct cleanup): Remove.
4842 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
4843 Use gdb_value_up.
4844 * value.h (struct value_deleter): New.
4845 (gdb_value_up): New typedef.
4846
4847 2017-10-08 Tom Tromey <tom@tromey.com>
4848
4849 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
4850 (make_cleanup_free_search_symbols): Remove.
4851 (search_symbols): Return std::vector.
4852 (symbol_search::compare_search_syms): Now member of
4853 symbol_search. Change arguments.
4854 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
4855 (symtab_symbol_info, rbreak_command): Update.
4856 * symtab.h (struct symbol_search) <next>: Remove.
4857 Add constructors.
4858 (symbol_search::operator<): New function.
4859 (symbol_search::operator==): New function.
4860 (search_symbols): Remove std::vector.
4861 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
4862 (symbol_search::compare_search_syms): Declare.
4863
4864 2017-10-06 Yao Qi <yao.qi@linaro.org>
4865
4866 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
4867 arch/aarch64-insn.o.
4868 Remove one rule.
4869 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
4870
4871 2017-10-06 Yao Qi <yao.qi@linaro.org>
4872
4873 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
4874 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
4875 arch/arm-linux.o respectively.
4876 * configure.tgt: Likewise.
4877
4878 2017-10-06 Yao Qi <yao.qi@linaro.org>
4879
4880 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
4881 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
4882
4883 2017-10-06 Pedro Alves <palves@redhat.com>
4884
4885 * windows-nat.c: Include <algorithm>.
4886
4887 2017-10-06 Yao Qi <yao.qi@linaro.org>
4888
4889 * configure.tgt (i386_tobjs): New variable.
4890 (amd64_tobjs): New variable.
4891 Set $cpu_obs and $os_obs.
4892
4893 2017-10-06 Yao Qi <yao.qi@linaro.org>
4894
4895 * Makefile.in (CONFIG_SRC_SUBDIR): New.
4896 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
4897 (clean): Remove object files and dependency files.
4898 (distclean): Remove the directory.
4899 * configure.ac: Invoke AC_CONFIG_COMMANDS.
4900 * configure: Re-generated.
4901 * configure.tgt: Replace amd64.o with arch/amd64.o.
4902
4903 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
4904
4905 PR build/22188
4906 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
4907 and SETEND.
4908
4909 2017-10-05 Pedro Alves <palves@redhat.com>
4910
4911 * linux-nat.c (linux_child_follow_fork): When following the parent
4912 and detaching the child, consult the parent thread's architecture
4913 instead of the child's.
4914
4915 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4916
4917 * ax.h: Do not include "doublest.h".
4918 (union agent_val): Remove.
4919
4920 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4921
4922 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
4923 (decimal_to_string): Return std::string object.
4924 (decimal_from_string): Accept std::string object. Return bool.
4925 (decimal_from_integral, decimal_from_doublest): Remove.
4926 (decimal_from_longest): Add prototype.
4927 (decimal_from_ulongest): Likewise.
4928 (decimal_to_longest): Likewise.
4929 (decimal_from_doublest): Likewise.
4930 * dfp.c: Do not include "gdbtypes.h" or "value.h".
4931 (MAX_DECIMAL_STRING): Move here.
4932 (decimal_to_string): Return std::string object.
4933 (decimal_from_string): Accept std::string object. Return bool.
4934 (decimal_from_integral): Remove, replace by ...
4935 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
4936 (decimal_to_longest): New function.
4937 (decimal_from_floating): Remove, replace by ...
4938 (decimal_from_doublest): ... this new function.
4939 (decimal_to_doublest): Update to new decimal_to_string interface.
4940
4941 * value.c (unpack_long): Use decimal_to_longest.
4942 * valops.c (value_cast): Use decimal_from_doublest instead of
4943 decimal_from_floating. Use decimal_from_[u]longest isntead of
4944 decimal_from_integral.
4945 * valarith.c (value_args_as_decimal): Likewise.
4946 * valprint.c (print_decimal_floating): Update to new
4947 decimal_to_string interface.
4948 * printcmd.c (printf_decfloat): Likewise.
4949 * c-exp.y (parse_number): Update to new decimal_from_string interface.
4950
4951 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
4952
4953 * doublest.h: Do not include "floatformat.h". Remove stale comments.
4954 * gdbtypes.c: Include "floatformat.h".
4955 * value.c: Likewise.
4956 * m68k-tdep.c: Likewise.
4957
4958 * findvar.c: Do not include "floatformat.h".
4959 * amd64-darwin-tdep.c: Likewise.
4960 * arm-linux-tdep.c: Likewise.
4961 * i386-darwin-tdep.c: Likewise.
4962 * i387-tdep.c: Likewise.
4963 * m68k-linux-tdep.c: Likewise.
4964 * mep-tdep.c: Likewise.
4965 * mips-tdep.c: Likewise.
4966 * nios2-tdep.c: Likewise.
4967 * s390-linux-tdep.c: Likewise.
4968 * sparc-obsd-tdep.c: Likewise.
4969 * sparc-tdep.c: Likewise.
4970 * sparc64-tdep.c: Likewise.
4971 * spu-tdep.c: Likewise.
4972 * tic6x-tdep.c: Likewise.
4973 * tilegx-tdep.c: Likewise.
4974 * vax-tdep.c: Likewise.
4975 * xstormy16-tdep.c: Likewise.
4976 * xtensa-tdep.c: Likewise.
4977
4978 * top.c: Do not include "doublest.h".
4979 * aarch64-tdep.c: Likewise.
4980 * alpha-tdep.c: Likewise.
4981 * arm-linux-tdep.c: Likewise.
4982 * m68k-linux-tdep.c: Likewise.
4983 * tilegx-tdep.c: Likewise.
4984 * xstormy16-tdep.c: Likewise.
4985
4986 2017-10-05 John Baldwin <jhb@FreeBSD.org>
4987
4988 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
4989 (mipsn32_fbsd_sigframe): Define.
4990 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
4991 for FreeBSD/mipsn32.
4992
4993 2017-10-05 John Baldwin <jhb@FreeBSD.org>
4994
4995 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
4996 AT_HWCAP.
4997
4998 2017-10-05 Tristan Gingold <tgingold@free.fr>
4999
5000 * MAINTAINERS (Misc): Update my email address.
5001
5002 2017-10-04 Pedro Alves <palves@redhat.com>
5003
5004 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
5005 it instead of target_gdbarch.
5006 (get_remote_state, get_remote_packet_size): Adjust
5007 get_remote_arch_state calls, passing down target_gdbarch
5008 explicitly.
5009 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
5010 'gdbarch' and use it instead of target_gdbarch.
5011 (get_memory_packet_size): Adjust get_remote_arch_state calls,
5012 passing down target_gdbarch explicitly.
5013 (struct stop_reply) <arch>: New field.
5014 (remote_parse_stop_reply): Use the stopped thread's architecture,
5015 not the current inferior's. Save the architecture in the
5016 stop_reply.
5017 (process_stop_reply): Use the stop reply's architecture.
5018 (process_g_packet, remote_fetch_registers)
5019 (remote_prepare_to_store, store_registers_using_G)
5020 (remote_store_registers): Adjust get_remote_arch_state calls,
5021 using the regcache's architecture.
5022 (remote_get_trace_status): Adjust get_remote_arch_state calls,
5023 passing down target_gdbarch explicitly.
5024 * spu-multiarch.c (spu_thread_architecture): Defer to the target
5025 beneath instead of calling target_gdbarch.
5026 * target.c (default_thread_architecture): Use the specified
5027 inferior's architecture, instead of the current inferior's
5028 architecture (via target_gdbarch).
5029
5030 2017-10-04 Pedro Alves <palves@redhat.com>
5031
5032 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
5033 case.
5034 (regcache_print): Handle !target_has_registers here instead.
5035
5036 2017-10-04 Pedro Alves <palves@redhat.com>
5037
5038 * frame.c (create_test_frame): Delete.
5039 * frame.h (create_test_frame): Delete.
5040 * gdbarch-selftests.c: Include gdbthread.h and target.h.
5041 (class regcache_test): Delete.
5042 (test_target_has_registers, test_target_has_stack)
5043 (test_target_has_memory, test_target_prepare_to_store)
5044 (test_target_store_registers): New functions.
5045 (test_target_ops): New class.
5046 (register_to_value_test): Error out if there's already a
5047 process_stratum (or higher) target pushed. Create a fuller mock
5048 environment, with mock target_ops, inferior, address space, thread
5049 and inferior_ptid.
5050 * progspace.c (struct address_space): Move to ...
5051 * progspace.h (struct address_space): ... here.
5052 * regcache.h (regcache::~regcache, regcache::raw_write)
5053 [GDB_SELF_TEST]: No longer virtual.
5054
5055 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
5056
5057 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
5058
5059 2017-10-04 Pedro Alves <palves@redhat.com>
5060
5061 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
5062 out of 'between TRY and CATCH'.
5063
5064 2017-10-04 Pedro Alves <palves@redhat.com>
5065
5066 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
5067 * common/common-exceptions.h (TRY): Open an outermost scope.
5068 Expand intro comment.
5069 (CATCH): Reindent.
5070 (END_CATCH): Close the outermost scope.
5071 * completer.c (complete_line_internal): Add missing END_CATCH.
5072
5073 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5074
5075 * NEWS (Changes since GDB 8.0): Add entry about new
5076 'set-cwd-on-gdbserver' feature.
5077 (New remote packets): Add entry for QSetWorkingDir.
5078 * common/common-inferior.h (set_inferior_cwd): New prototype.
5079 * infcmd.c (set_inferior_cwd): Remove "static".
5080 (show_cwd_command): Expand text to include remote debugging.
5081 * remote.c: Add PACKET_QSetWorkingDir.
5082 (remote_protocol_features) <QSetWorkingDir>: New entry for
5083 PACKET_QSetWorkingDir.
5084 (extended_remote_set_inferior_cwd): New function.
5085 (extended_remote_create_inferior): Call
5086 "extended_remote_set_inferior_cwd".
5087 (_initialize_remote): Call "add_packet_config_cmd" for
5088 QSetWorkingDir.
5089
5090 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5091
5092 * NEWS (New commands): Mention "set/show cwd".
5093 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
5094 "cd" command's help text.
5095 * common/common-inferior.h (get_inferior_cwd): New prototype.
5096 * infcmd.c (inferior_cwd_scratch): New global variable.
5097 (set_inferior_cwd): New function.
5098 (get_inferior_cwd): Likewise.
5099 (set_cwd_command): Likewise.
5100 (show_cwd_command): Likewise.
5101 (_initialize_infcmd): Add "set/show cwd" commands.
5102 * inferior.h (class inferior) <cwd>: New field.
5103 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
5104 (fork_inferior): Change inferior's cwd before its execution.
5105 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
5106 to CreateProcess.
5107
5108 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
5109
5110 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
5111 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
5112 (COMMON_OBS): Add gdb_tilde_expand.o.
5113 * common/gdb_tilde_expand.c: New file.
5114 * common/gdb_tilde_expand.h: Likewise.
5115
5116 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
5117
5118 * gdbarch.sh (objfile): Remove duplicate declaration.
5119 * gdbarch.h: Regenerate.
5120
5121 2017-10-03 Tom Tromey <tom@tromey.com>
5122
5123 * utils.c (internal_vproblem): Use string_vprintf.
5124
5125 2017-10-03 Tom Tromey <tom@tromey.com>
5126
5127 * printcmd.c (info_symbol_command): Use std::string.
5128
5129 2017-10-03 Tom Tromey <tom@tromey.com>
5130
5131 * top.c (gdb_safe_append_history): Use std::string.
5132
5133 2017-10-03 Tom Tromey <tom@tromey.com>
5134
5135 * event-top.c (stdin_event_handler): Update.
5136 * main.c (captured_main_1): Update.
5137 * top.h (make_delete_ui_cleanup): Remove.
5138 (struct ui): Add constructor and destructor.
5139 (new_ui, delete_ui): Remove.
5140 * top.c (make_delete_ui_cleanup): Remove.
5141 (new_ui_command): Use std::unique_ptr.
5142 (delete_ui_cleanup): Remove.
5143 (ui::ui): Rename from new_ui. Update.
5144 (free_ui): Remove.
5145 (ui::~ui): Rename from delete_ui. Update.
5146
5147 2017-10-03 Tom Tromey <tom@tromey.com>
5148
5149 * symfile.c (load_progress): Use gdb::byte_vector.
5150
5151 2017-10-03 Tom Tromey <tom@tromey.com>
5152
5153 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
5154 declaration.
5155 * printcmd.c (x_command): Remove unused declaration.
5156 * symfile.c (symbol_file_command): Remove unused declaration.
5157
5158 2017-10-03 Tom Tromey <tom@tromey.com>
5159
5160 * utils.c (internal_vproblem): Use std::string.
5161 (defaulted_query): Likewise.
5162
5163 2017-10-03 Tom Tromey <tom@tromey.com>
5164
5165 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
5166 * top.c (execute_command_to_string): Update.
5167 * utils.c (make_cleanup_restore_page_info): Remove.
5168 (do_restore_page_info_cleanup): Remove.
5169 (set_batch_flag_and_restore_page_info):
5170 New.
5171 (make_cleanup_restore_page_info): Remove.
5172 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5173 (~set_batch_flag_and_restore_page_info): New
5174 (make_cleanup_restore_uinteger): Remove.
5175 (make_cleanup_restore_integer): Remove.
5176 (struct restore_integer_closure): Remove.
5177 (restore_integer): Remove.
5178 * utils.h (struct set_batch_flag_and_restore_page_info): New
5179 class.
5180 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
5181 (make_cleanup_restore_page_info): Remove.
5182 (make_cleanup_restore_uinteger) Remove.
5183 (make_cleanup_restore_integer) Remove.
5184
5185 2017-10-03 Tom Tromey <tom@tromey.com>
5186
5187 * record-full.h (record_full_gdb_operation_disable_set): Return
5188 scoped_restore_tmpl<int>.
5189 * infrun.c (adjust_pc_after_break): Update.
5190 (handle_signal_stop): Update.
5191 * record-full.c (record_full_gdb_operation_disable_set): Return
5192 scoped_restore_tmpl<int>.
5193 (record_full_wait_1, record_full_insert_breakpoint)
5194 (record_full_remove_breakpoint, record_full_save)
5195 (record_full_goto_insn): Update.
5196
5197 2017-10-02 Tom Tromey <tom@tromey.com>
5198
5199 PR rust/22236:
5200 * rust-lang.c (rust_val_print_str): New function.
5201 (val_print_struct): Call it.
5202 (rust_subscript): Preserve name of slice type.
5203
5204 2017-10-02 Tom Tromey <tom@tromey.com>
5205
5206 * rust-lang.c (rust_subscript): Handle slices in
5207 EVAL_AVOID_SIDE_EFFECTS case.
5208
5209 2017-10-02 Tom Tromey <tom@tromey.com>
5210
5211 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
5212
5213 2017-10-02 Tom Tromey <tom@tromey.com>
5214
5215 * rust-lang.h (rust_slice_type): Add "extern".
5216
5217 2017-10-02 Tom Tromey <tom@tromey.com>
5218 Pedro Alves <palves@redhat.com>
5219
5220 * ada-lang.h (ada_exc_info::operator<): Make const.
5221 (ada_exc_info::operator==): Make const.
5222 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
5223 Make const.
5224
5225 2017-09-29 Tom Tromey <tom@tromey.com>
5226
5227 * target.c (read_whatever_is_readable): Change type of "result".
5228 Update.
5229 (free_memory_read_result_vector): Remove.
5230 (read_memory_robust): Change return type. Update.
5231 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
5232 bin2hex, std::string.
5233 * target.h (memory_read_result_s): Remove typedef.
5234 (free_memory_read_result_vector): Remove.
5235 (read_memory_robust): Return std::vector.
5236
5237 2017-09-29 Tom Tromey <tom@tromey.com>
5238
5239 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
5240
5241 2017-09-29 Tom Tromey <tom@tromey.com>
5242
5243 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
5244 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
5245 operator< and operator==.
5246 (ada_exceptions_list): Return a std::vector.
5247 * ada-lang.c (ada_exc_info::operator<): Rename from
5248 compare_ada_exception_info.
5249 (ada_exc_info::operator==): New.
5250 (sort_remove_dups_ada_exceptions_list): Change type of
5251 "exceptions".
5252 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
5253 (ada_add_global_exceptions): Likewise.
5254 (ada_exceptions_list_1): Return a std::vector.
5255 (ada_exceptions_list): Likewise.
5256
5257 2017-09-29 Tom Tromey <tom@tromey.com>
5258
5259 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
5260 'std::set *'.
5261 (print_one_inferior): Update.
5262 (free_vector_of_ints): Remove.
5263 (list_available_thread_groups): Change "ids" to std::set.
5264 (mi_cmd_list_thread_groups): Update.
5265 (struct collect_cores_data) <core>: Now a std::set.
5266 (collect_cores): Update.
5267 (unique): Remove.
5268 (print_one_inferior): Update.
5269
5270 2017-09-29 Tom Tromey <tom@tromey.com>
5271
5272 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
5273 (mi_execute_async_cli_command): Likewise.
5274 (mi_cmd_trace_frame_collected): Use field_fmt.
5275
5276 2017-09-29 Tom Tromey <tom@tromey.com>
5277
5278 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
5279 gdb::byte_vector.
5280
5281 2017-09-29 Tom Tromey <tom@tromey.com>
5282
5283 * mi/mi-parse.c (mi_parse): Remove unused declaration.
5284
5285 2017-09-29 Tom Tromey <tom@tromey.com>
5286
5287 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
5288
5289 2017-09-29 Tom Tromey <tom@tromey.com>
5290
5291 * varobj.h (varobj_gen_name): Return std::string.
5292 * varobj.c (varobj_gen_name): Return std::string.
5293 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
5294 (mi_cmd_var_delete): Don't copy "name".
5295
5296 2017-09-29 Tom Tromey <tom@tromey.com>
5297
5298 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
5299 (mi_cmd_break_insert_1): Update.
5300
5301 2017-09-29 Tom Tromey <tom@tromey.com>
5302
5303 * target.h (make_scoped_defer_target_commit_resume): Update.
5304 * target.c (make_scoped_defer_target_commit_resume): Rename from
5305 make_cleanup_defer_target_commit_resume. Return a
5306 scoped_restore.
5307 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
5308
5309 2017-09-29 Tom Tromey <tom@tromey.com>
5310
5311 * main.c (captured_main_1): Remove unused declaration.
5312 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
5313
5314 2017-09-29 Tom Tromey <tom@tromey.com>
5315
5316 * symtab.c (search_symbols): Remove unused outer cleanup.
5317 (make_source_files_completion_list): Remove unused declaration.
5318
5319 2017-09-29 Tom Tromey <tom@tromey.com>
5320
5321 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
5322
5323 2017-09-29 Tom Tromey <tom@tromey.com>
5324
5325 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
5326 gdb::byte_vector.
5327
5328 2017-09-29 Tom Tromey <tom@tromey.com>
5329
5330 * complaints.c (vcomplaint): Use std::string.
5331
5332 2017-09-29 Tom Tromey <tom@tromey.com>
5333
5334 * tracepoint.c (trace_variable_command): Use std::string.
5335 (encode_actions_1): Remove unused declarations.
5336 (create_tsv_from_upload): Use std::string.
5337
5338 2017-09-29 Tom Tromey <tom@tromey.com>
5339
5340 * cp-support.c (gdb_demangle): Use std::string.
5341
5342 2017-09-29 Tom Tromey <tom@tromey.com>
5343
5344 * stack.c (parse_frame_specification): Use std::string
5345 (info_frame_command): Use gdb::unique_xmalloc_ptr.
5346
5347 2017-09-29 Tom Tromey <tom@tromey.com>
5348
5349 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
5350
5351 2017-09-29 Tom Tromey <tom@tromey.com>
5352
5353 * utils.c (vfprintf_maybe_filtered): Use std::string.
5354 (vfprintf_unfiltered): Likewise.
5355
5356 2017-09-29 Tom Tromey <tom@tromey.com>
5357
5358 * event-top.c (top_level_prompt): Return std::string.
5359 (display_gdb_prompt): Update.
5360
5361 2017-09-29 Tom Tromey <tom@tromey.com>
5362
5363 * unittests/common-utils-selftests.c (format): New function.
5364 (string_vprintf_tests): New function.
5365 (_initialize_common_utils_selftests): Register new tests.
5366 * common/common-utils.c (string_vprintf): New function.
5367 * common/common-utils.h (string_vprintf): Declare.
5368
5369 2017-09-29 Pedro Alves <palves@redhat.com>
5370
5371 * common/rsp-low.c (unpack_varlen_hex): Constify.
5372 * common/rsp-low.h (unpack_varlen_hex): Constify.
5373 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
5374 Constify.
5375 * remote.c (remote_set_permissions, read_ptid)
5376 (remote_current_thread, remote_get_threads_with_qthreadinfo)
5377 (remote_static_tracepoint_marker_at)
5378 (remote_static_tracepoint_markers_by_strid)
5379 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
5380 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
5381 (parse_tracepoint_definition, parse_tsv_definition)
5382 (parse_static_tracepoint_marker_definition): Constify.
5383 * tracepoint.h (parse_static_tracepoint_marker_definition)
5384 (parse_trace_status, parse_tracepoint_status)
5385 (parse_tracepoint_definition, parse_tsv_definition): Constify.
5386
5387 2017-09-29 Pedro Alves <palves@redhat.com>
5388
5389 * remote.c (target_buf, target_buf_size): Delete.
5390 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
5391 Use the connection's packet buffer instead.
5392 All callers adjusted.
5393 (_initialize_remote): Remove references to target_buf and
5394 target_buf_size.
5395
5396 2017-09-28 Pedro Alves <palves@redhat.com>
5397
5398 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5399 unittests/common-utils-selftests.c.
5400 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
5401 (COMMON_OBS): Remove utils-selftests.o.
5402 * utils-selftests.c: Move to ...
5403 * unittests/common-utils-selftests.c: ... here and rename self
5404 test to "string_printf".
5405
5406 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
5407
5408 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
5409 having NULL cus or tus.
5410
5411 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5412
5413 * arm-tdep.c: (convert_from_extended): Remove.
5414 (convert_to_extended): Likewise.
5415 (arm_extract_return_value): Use convert_typed_floating.
5416 (arm_store_return_value): Likewise.
5417
5418 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5419 * sh-tdep.c: Do not include "floatformat.h".
5420 (sh_littlebyte_bigword_type): New function.
5421 (sh_register_convert_to_virtual): Use convert_typed_floating.
5422 (sh_register_convert_to_raw): Likewise.
5423 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
5424 (sh64_littlebyte_bigword_type): New function.
5425 (sh64_extract_return_value): Use convert_typed_floating.
5426 (sh64_register_convert_to_virtual): Likewise.
5427 (sh64_register_convert_to_raw): Likewise.
5428
5429 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5430
5431 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
5432 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
5433
5434 * gdbtypes.h (union type_specific): Make field floatformat hold
5435 just a single struct floatformat, not an array.
5436 (floatformat_from_type): Move here.
5437 * gdbtypes.c (floatformat_from_type): Move here. Update to
5438 changed TYPE_FLOATFORMAT definition.
5439 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
5440 (recursive_dump_type): Likewise.
5441 (init_float_type): Install correct floatformat for byte order.
5442 (arch_float_type): Likewise.
5443
5444 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
5445
5446 * gdbtypes.c (init_type): Change incoming argument from
5447 length-in-bytes to length-in-bits. Assert length is a
5448 multiple of TARGET_CHAR_BITS.
5449 (arch_type, arch_flags_type): Likewise.
5450 (init_integer_type): Update call to init_type.
5451 (init_character_type): Likewise.
5452 (init_boolean_type): Likewise.
5453 (init_float_type): Likewise.
5454 (init_decfloat_type): Likewise.
5455 (init_complex_type): Likewise.
5456 (init_pointer_type): Likewise.
5457 (objfile_type): Likewise.
5458 (arch_integer_type): Update call to arch_type.
5459 (arch_character_type): Likewise.
5460 (arch_boolean_type): Likewise.
5461 (arch_float_type): Likewise.
5462 (arch_decfloat_type): Likewise.
5463 (arch_complex_type): Likewise.
5464 (arch_pointer_type): Likewise.
5465 (gdbtypes_post_init): Likewise.
5466
5467 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
5468 (read_base_type): Likewise.
5469 * mdebugread.c (basic_type): Likewise.
5470 * stabsread.c (dbx_init_float_type): Likewise.
5471 (rs6000_builtin_type): Likewise.
5472 (read_range_type): Likewise. Also, fix call to init_integer_type
5473 with erroneous length argument.
5474
5475 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
5476 * d-lang.c (build_d_types): Likewise.
5477 * f-lang.c (build_fortran_types): Likewise.
5478 * go-lang.c (build_go_types): Likewise.
5479 * opencl-lang.c (build_opencl_types): Likewise.
5480 * jit.c (finalize_symtab): Likewise.
5481 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
5482 (build_std_type_info_type): Likewise.
5483 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
5484 update call to arch_flags_type.
5485
5486 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
5487 arch_type.
5488 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
5489 * windows-tdep.c (windows_get_tlb_type): Likewise.
5490
5491 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
5492 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
5493 * m32c-tdep.c (make_types): Likewise.
5494 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
5495 (rl78_psw_type): Update call to arch_flags_type.
5496 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
5497 * rx-tdep.c (rx_psw_type): Likewise.
5498 (rx_fpsw_type): Likewise.
5499 * sparc-tdep.c (sparc_psr_type): Likewise.
5500 (sparc_fsr_type): Likewise.
5501 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
5502 (sparc64_ccr_type): Likewise.
5503 (sparc64_fsr_type): Likewise.
5504 (sparc64_fprs_type): Likewise.
5505
5506 2017-09-27 Tom Tromey <tom@tromey.com>
5507
5508 * findcmd.c (find_command): Constify.
5509
5510 2017-09-27 Tom Tromey <tom@tromey.com>
5511
5512 * ada-tasks.c (task_command_1, task_command): Constify.
5513
5514 2017-09-27 Tom Tromey <tom@tromey.com>
5515
5516 * symtab.c (maintenance_print_symbol_cache)
5517 (maintenance_flush_symbol_cache)
5518 (maintenance_print_symbol_cache_statistics): Constify.
5519
5520 2017-09-27 Tom Tromey <tom@tromey.com>
5521
5522 * inferior.c (detach_inferior_command, kill_inferior_command)
5523 (inferior_command): Constify.
5524
5525 2017-09-27 Tom Tromey <tom@tromey.com>
5526
5527 * regcache.c (regcache_print, maintenance_print_registers)
5528 (maintenance_print_raw_registers)
5529 (maintenance_print_cooked_registers)
5530 (maintenance_print_register_groups)
5531 (maintenance_print_remote_registers): Constify.
5532
5533 2017-09-27 Tom Tromey <tom@tromey.com>
5534
5535 * printcmd.c (map_display_numbers, undisplay_command)
5536 (enable_disable_display_command, enable_display_command)
5537 (disable_display_command): Constify.
5538
5539 2017-09-27 Tom Tromey <tom@tromey.com>
5540
5541 * breakpoint.h (delete_command): Don't declare.
5542 * breakpoint.c (delete_command, enable_once_command)
5543 (enable_count_command, enable_delete_command, breakpoint_1)
5544 (maintenance_info_breakpoints, stopin_command, stopat_command)
5545 (delete_command, delete_trace_command, save_breakpoints)
5546 (save_breakpoints_command, save_tracepoints_command): Constify.
5547
5548 2017-09-27 Tom Tromey <tom@tromey.com>
5549
5550 * macrocmd.c (macro_expand_command, macro_expand_once_command)
5551 (skip_ws, extract_identifier, macro_define_command)
5552 (macro_undef_command, macro_list_command): Constify.
5553
5554 2017-09-27 Tom Tromey <tom@tromey.com>
5555
5556 * infcmd.c (environment_info, set_environment_command)
5557 (unset_environment_command, path_info, info_proc_cmd_1)
5558 (info_proc_cmd_mappings, info_proc_cmd_stat)
5559 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
5560 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
5561
5562 2017-09-27 Tom Tromey <tom@tromey.com>
5563
5564 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
5565 Constify.
5566
5567 2017-09-27 Tom Tromey <tom@tromey.com>
5568
5569 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
5570
5571 2017-09-27 Tom Tromey <tom@tromey.com>
5572
5573 * demangle.c (demangle_command): Constify.
5574
5575 2017-09-27 Tom Tromey <tom@tromey.com>
5576
5577 * progspace.c (maintenance_info_program_spaces_command):
5578 Constify.
5579
5580 2017-09-27 Tom Tromey <tom@tromey.com>
5581
5582 * compile/compile.c (check_raw_argument, compile_file_command)
5583 (compile_code_command, compile_print_command): Constify.
5584
5585 2017-09-27 Tom Tromey <tom@tromey.com>
5586
5587 * reggroups.c (maintenance_print_reggroups): Constify.
5588
5589 2017-09-27 Tom Tromey <tom@tromey.com>
5590
5591 * dwarf2read.c (save_gdb_index_command): Constify.
5592
5593 2017-09-27 Tom Tromey <tom@tromey.com>
5594
5595 * stap-probe.c (info_probes_stap_command): Constify.
5596
5597 2017-09-27 Tom Tromey <tom@tromey.com>
5598
5599 * fork-child.c (unset_exec_wrapper_command): Constify.
5600
5601 2017-09-27 Tom Tromey <tom@tromey.com>
5602
5603 * btrace.c (get_uint, get_context_size, no_chunk)
5604 (maint_btrace_packet_history_cmd)
5605 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
5606 (maint_info_btrace_cmd): Constify.
5607
5608 2017-09-27 Tom Tromey <tom@tromey.com>
5609
5610 * reverse.c (delete_bookmark_command): Constify.
5611
5612 2017-09-27 Tom Tromey <tom@tromey.com>
5613
5614 * remote.c (set_memory_packet_size)
5615 (set_memory_write_packet_size, show_memory_write_packet_size)
5616 (set_memory_read_packet_size, show_memory_read_packet_size)
5617 (compare_sections_command, packet_command, remote_put_command)
5618 (remote_get_command, remote_delete_command): Constify.
5619
5620 2017-09-27 Tom Tromey <tom@tromey.com>
5621
5622 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
5623 (set_mipsfpu_double_command, set_mipsfpu_none_command)
5624 (set_mipsfpu_auto_command): Constify.
5625
5626 2017-09-27 Tom Tromey <tom@tromey.com>
5627
5628 * cli/cli-cmds.h (cd_command): Constify.
5629 * cli/cli-cmds.c (cd_command): Constify.
5630
5631 2017-09-27 Tom Tromey <tom@tromey.com>
5632
5633 * thread.c (thread_name_command, thread_find_command): Constify.
5634
5635 2017-09-27 Tom Tromey <tom@tromey.com>
5636
5637 * probe.c (enable_probes_command, disable_probes_command):
5638 Constify.
5639
5640 2017-09-27 Tom Tromey <tom@tromey.com>
5641
5642 * symfile.c (symbol_file_command): Constify.
5643 * gdbcore.h (deprecated_file_changed_hook): Constify.
5644 * exec.c (deprecated_file_changed_hook, exec_file_command)
5645 (file_command): Constify.
5646 * defs.h (symbol_file_command): Constify.
5647
5648 2017-09-27 Tom Tromey <tom@tromey.com>
5649
5650 * remote-fileio.c (set_system_call_allowed)
5651 (show_system_call_allowed): Constify.
5652
5653 2017-09-27 Tom Tromey <tom@tromey.com>
5654
5655 * tracepoint.c (delete_trace_variable_command)
5656 (tfind_end_command, tfind_start_command, tfind_pc_command)
5657 (tfind_tracepoint_command, tfind_line_command)
5658 (tfind_range_command, tfind_outside_command): Constify.
5659
5660 2017-09-27 Tom Tromey <tom@tromey.com>
5661
5662 * ax-gdb.c (maint_agent_printf_command, agent_command)
5663 (agent_eval_command): Constify.
5664
5665 2017-09-27 Tom Tromey <tom@tromey.com>
5666
5667 * tracepoint.c (info_scope_command): Constify.
5668 * python/python.c (gdbpy_decode_line): Constify.
5669 * python/py-breakpoint.c (bppy_init): Constify.
5670 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
5671 * location.h: (new_linespec_location)
5672 (string_to_event_location_basic, string_to_event_location):
5673 Constify.
5674 * location.c (new_linespec_location)
5675 (string_to_event_location_basic, string_to_event_location):
5676 Constify.
5677 * linespec.h (decode_line_with_current_source)
5678 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
5679 * linespec.c (linespec_lex_to_end)
5680 (decode_line_with_current_source)
5681 (decode_line_with_last_displayed): Constify.
5682 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
5683 Constify.
5684 * cli/cli-cmds.c (edit_command, list_command): Constify.
5685 * breakpoint.h (until_break_command, watch_command_wrapper)
5686 (awatch_command_wrapper, rwatch_command_wrapper)
5687 (init_ada_exception_breakpoint): Constify.
5688 * breakpoint.c (break_command_1, dprintf_command)
5689 (break_range_command, watch_command_wrapper)
5690 (rwatch_command_wrapper, awatch_command_wrapper)
5691 (until_break_command, init_ada_exception_breakpoint)
5692 (strace_marker_create_sals_from_location, trace_command)
5693 (ftrace_command, strace_command, struct tracepoint): Constify.
5694 * ax-gdb.c (agent_command_1): Constify.
5695 * ada-lang.c (ada_exception_sal): Constify.
5696
5697 2017-09-27 Tom Tromey <tom@tromey.com>
5698
5699 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
5700 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
5701 (get_context_size, no_chunk, get_insn_history_modifiers)
5702 (cmd_record_insn_history, get_call_history_modifiers)
5703 (cmd_record_call_history): Constify.
5704
5705 2017-09-27 Tom Tromey <tom@tromey.com>
5706
5707 * source.c (show_substitute_path_command)
5708 (unset_substitute_path_command, set_substitute_path_command):
5709 Constify.
5710
5711 2017-09-27 Tom Tromey <tom@tromey.com>
5712
5713 * typeprint.c (maintenance_print_type): Constify.
5714 * maint.c (maintenance_dump_me, maintenance_demangle)
5715 (maintenance_time_display, maintenance_info_sections)
5716 (maintenance_print_statistics, maintenance_deprecate)
5717 (maintenance_undeprecate): Constify.
5718 (maintenance_do_deprecate): Constify. Use std::string.
5719 (maintenance_selftest): Constify.
5720 * gdbtypes.h (maintenance_print_type): Constify.
5721
5722 2017-09-27 Tom Tromey <tom@tromey.com>
5723
5724 * hppa-tdep.c (unwind_command): Constify.
5725
5726 2017-09-27 Tom Tromey <tom@tromey.com>
5727
5728 * target-descriptions.c (unset_tdesc_filename_cmd)
5729 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
5730 Constify.
5731
5732 2017-09-27 Tom Tromey <tom@tromey.com>
5733
5734 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
5735
5736 2017-09-27 Tom Tromey <tom@tromey.com>
5737
5738 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
5739
5740 2017-09-27 Tom Tromey <tom@tromey.com>
5741
5742 * tui/tui-regs.c (tui_reg_command): Constify.
5743
5744 2017-09-27 Tom Tromey <tom@tromey.com>
5745
5746 * skip.c (skip_file_command, skip_function_command)
5747 (skip_enable_command, skip_disable_command, skip_delete_command):
5748 Constify.
5749
5750 2017-09-27 Tom Tromey <tom@tromey.com>
5751
5752 * record-btrace.c (cmd_record_btrace_bts_start)
5753 (cmd_record_btrace_pt_start): Constify.
5754
5755 2017-09-27 Tom Tromey <tom@tromey.com>
5756
5757 * symmisc.c (maintenance_print_symbols)
5758 (maintenance_print_msymbols, maintenance_print_objfiles)
5759 (maintenance_info_symtabs, maintenance_check_symtabs)
5760 (maintenance_expand_symtabs, maintenance_info_line_tables):
5761 Constify.
5762
5763 2017-09-27 Tom Tromey <tom@tromey.com>
5764
5765 * top.c (new_ui_command): Constify.
5766
5767 2017-09-27 Tom Tromey <tom@tromey.com>
5768
5769 * symfile.c (add_symbol_file_command)
5770 (remove_symbol_file_command, list_overlays_command)
5771 (map_overlay_command, unmap_overlay_command)
5772 (overlay_auto_command, overlay_manual_command)
5773 (overlay_off_command, overlay_load_command): Constify.
5774
5775 2017-09-27 Tom Tromey <tom@tromey.com>
5776
5777 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
5778 (info_spu_mailbox_command, info_spu_dma_command)
5779 (info_spu_proxydma_command): Constify.
5780
5781 2017-09-27 Tom Tromey <tom@tromey.com>
5782
5783 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
5784
5785 2017-09-27 Tom Tromey <tom@tromey.com>
5786
5787 * cli/cli-script.c (user_defined_command): Constify.
5788
5789 2017-09-27 Tom Tromey <tom@tromey.com>
5790
5791 * cli/cli-dump.c (dump_memory_command, dump_value_command)
5792 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
5793 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
5794 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
5795 (dump_binary_value, append_binary_memory, append_binary_value):
5796 Constify.
5797 (struct dump_context) <func>: Constify.
5798 (add_dump_command): Update.
5799
5800 2017-09-27 Tom Tromey <tom@tromey.com>
5801
5802 * cli/cli-cmds.c (show_version, show_configuration)
5803 (source_command, show_user): Constify.
5804
5805 2017-09-27 Tom Tromey <tom@tromey.com>
5806
5807 * target.c (maintenance_print_target_stack): Constify.
5808
5809 2017-09-27 Tom Tromey <tom@tromey.com>
5810
5811 * interps.c (interpreter_exec_cmd): Constify.
5812
5813 2017-09-27 Tom Tromey <tom@tromey.com>
5814
5815 * record-full.c (cmd_record_full_restore): Constify.
5816
5817 2017-09-27 Tom Tromey <tom@tromey.com>
5818
5819 * memattr.c (enable_mem_command, disable_mem_command)
5820 (delete_mem_command): Constify.
5821
5822 2017-09-27 Tom Tromey <tom@tromey.com>
5823
5824 * value.c (show_convenience): Constify.
5825
5826 2017-09-27 Tom Tromey <tom@tromey.com>
5827
5828 * gdbcore.h (core_file_command): Update.
5829 * corefile.c (core_file_command): Constify.
5830
5831 2017-09-27 Tom Tromey <tom@tromey.com>
5832
5833 * user-regs.c (maintenance_print_user_registers): Constify.
5834
5835 2017-09-27 Tom Tromey <tom@tromey.com>
5836
5837 * cp-namespace.c (maintenance_cplus_namespace): Constify.
5838
5839 2017-09-27 Tom Tromey <tom@tromey.com>
5840
5841 * cp-support.c (first_component_command): Constify.
5842
5843 2017-09-27 Tom Tromey <tom@tromey.com>
5844
5845 * psymtab.c (maintenance_print_psymbols)
5846 (maintenance_info_psymtabs, maintenance_check_psymtabs):
5847 Constify.
5848
5849 2017-09-27 Tom Tromey <tom@tromey.com>
5850
5851 * windows-tdep.c (display_tib): Constify.
5852
5853 2017-09-27 Tom Tromey <tom@tromey.com>
5854
5855 * linux-fork.c (delete_checkpoint_command)
5856 (detach_checkpoint_command): Constify.
5857
5858 2017-09-27 Tom Tromey <tom@tromey.com>
5859
5860 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
5861
5862 2017-09-27 Tom Tromey <tom@tromey.com>
5863
5864 * arc-tdep.c (dump_arc_instruction_command): Constify.
5865
5866 2017-09-27 Tom Tromey <tom@tromey.com>
5867
5868 * valprint.c (set_radix, show_radix): Constify.
5869
5870 2017-09-27 Tom Tromey <tom@tromey.com>
5871
5872 * dtrace-probe.c (info_probes_dtrace_command): Constify.
5873
5874 2017-09-27 Tom Tromey <tom@tromey.com>
5875
5876 * command.h (not_just_help_class_command): Update.
5877 * cli/cli-decode.h (not_just_help_class_command): Update.
5878 * cli/cli-decode.c (not_just_help_class_command): Constify.
5879
5880 2017-09-27 Tom Tromey <tom@tromey.com>
5881
5882 * gdb_bfd.c (maintenance_info_bfds): Constify.
5883
5884 2017-09-27 Tom Tromey <tom@tromey.com>
5885
5886 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
5887 overloads.
5888 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
5889 (do_const_cfunc): New function.
5890 (cmd_cfunc_eq): New overload.
5891 (cli_user_command_p): Check do_const_cfunc.
5892 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
5893 const_cfunc.
5894 * command.h (add_cmd): Add const overload and no-function
5895 overload.
5896 (set_cmd_cfunc): Add const overload.
5897 (cmd_const_cfunc_ftype): Declare.
5898 (cmd_cfunc_eq): Add const overload.
5899 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
5900 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
5901 overload.
5902
5903 2017-09-27 Tom Tromey <tom@tromey.com>
5904
5905 * macroexp.c (get_next_token_for_substitution): New function.
5906 (substitute_args): Call it. Check for __VA_OPT__.
5907
5908 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5909 Pedro Alves <palves@redhat.com>
5910
5911 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
5912 producer_is_icc_lt_14.
5913 (producer_is_icc_lt_14): New function.
5914 (check_producer): Add code for checking version of ICC.
5915 (producer_is_icc): Move to producer.c.
5916 (read_structure_type): Restrict ICC workaround to ICC<14.
5917 * producer.c: Include selftest.h.
5918 (producer_is_icc, producer_parsing_tests, _initialize_producer):
5919 New functions.
5920 * producer.h (producer_is_icc): New declaration.
5921
5922 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
5923
5924 * Makefile.in (SFILES): Add producer.c.
5925 (COMMON_OBS): Add producer.o
5926 * amd64-tdep.c (producer.h): Add new include.
5927 * dwarf2read.c (producer.h): Add new include.
5928 * producer.c: New file.
5929 * producer.h: New file.
5930 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
5931 producer.c.
5932 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
5933 producer.h.
5934
5935 2017-09-26 Matthias Klose <doko@ubuntu.com>
5936
5937 * configure.ac: Search ncursesw before ncurses.
5938 Check ncursesw/ncurses.h before ncurses/ncurses.h.
5939 * gdb_curses.h: Include <ncursesw/ncurses.h>
5940 * config.in, configure: Regenerate.
5941
5942 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5943
5944 PR gdb/22185
5945 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
5946 obsolete.
5947 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
5948 Remove i386sol2 support.
5949 * configure.nat <i386sol2>: Remove.
5950 <sol2-64>: Fold into ...
5951 <sol2>: ... this.
5952 Move common settings to default section.
5953 Add sol-thread.o.
5954 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
5955 x86_64-*-solaris2.1[0-9]*>: Rename to ...
5956 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
5957 <i[34567]86-*-solaris*>: Remove.
5958 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
5959
5960 * configure.ac: Remove wctype in libw check.
5961 (_MSE_INT_H): Don't define on Solaris 7-9.
5962 <solaris*>: Remove libthread_db.so.1 check.
5963 * configure: Regenerate.
5964 * config.in: Regenerate.
5965
5966 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
5967 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
5968 (gdb_ps_size_t): Remove.
5969 Use base types in users.
5970 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
5971
5972 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
5973
5974 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5975
5976 PR build/22206
5977 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
5978 (adi_is_addr_mapped): Likewise.
5979 (PSR_ICC): Don't redefine.
5980 (PSR_IMPL): Likewise.
5981
5982 2017-09-25 Tom Tromey <tom@tromey.com>
5983
5984 * regcache.c (regcache::dump): Use string_printf.
5985
5986 2017-09-25 Tom Tromey <tom@tromey.com>
5987
5988 * regcache.c (class regcache_invalidator): New.
5989 (struct register_to_invalidate): Remove.
5990 (make_cleanup_regcache_invalidate): Remove.
5991 (regcache::raw_write): Use regcache_invalidator.
5992
5993 2017-09-25 Tom Tromey <tom@tromey.com>
5994
5995 * spu-tdep.c (spu2ppu_sniffer): Update.
5996 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
5997 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
5998 Remove.
5999 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
6000 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
6001 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
6002 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
6003 (frame_pop): Update.
6004
6005 2017-09-25 Tom Tromey <tom@tromey.com>
6006
6007 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
6008 * regcache.h (regcache_xfree): Don't declare.
6009 * regcache.c (regcache_xfree): Remove.
6010 (do_regcache_xfree): Use delete.
6011 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
6012 * linux-fork.c (free_fork): Use delete.
6013 (fork_save_infrun_state): Likewise.
6014 * jit.c (jit_dealloc_cache): Use delete.
6015 * infrun.c (discard_infcall_suspend_state): Use delete.
6016
6017 2017-09-25 Tom Tromey <tom@tromey.com>
6018
6019 * regcache.h (regcache_xmalloc): Don't declare.
6020 (regcache_raw_set_cached_value): Update comment.
6021 * regcache.c (regcache_xmalloc): Remove.
6022 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
6023 * jit.c (jit_frame_sniffer): Use new.
6024 * frame.c (frame_save_as_regcache): Use new.
6025
6026 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6027
6028 * NEWS: Advertise support for guarded-storage registers on IBM z.
6029
6030 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6031
6032 * s390-linux-nat.c (have_regset_gs): New static variable.
6033 (s390_linux_fetch_inferior_registers): Handle guarded-storage
6034 control block and guarded-storage broadcast control regsets.
6035 (s390_read_description): Detect whether the target has
6036 guarded-storage support, return appropriate tdesc.
6037 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
6038 (features/s390x-gs-linux64.c): Likewise.
6039 (struct gdbarch_tdep) <have_gs>: New field.
6040 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
6041 (s390_gsbc_regset): New variables.
6042 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
6043 and s390_gsbc_regset, if applicable.
6044 (s390_core_read_description): Check whether core file was from a
6045 target with guarded-storage support; include appropriate regsets.
6046 (s390_gdbarch_init): Add registers for guarded-storage support.
6047 (_initialize_s390_tdep): Initialize new target descriptions that
6048 include registers for guarded-storage support.
6049 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
6050 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
6051 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
6052 (S390_NUM_REGS): Adjust macro definition.
6053 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
6054 (tdesc_s390x_gs_linux64): New declarations.
6055
6056 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
6057
6058 * features/s390-gs-linux64.xml: New file.
6059 * features/s390-gs.xml: New file.
6060 * features/s390-gsbc.xml: New file.
6061 * features/s390x-gs-linux64.xml: New file.
6062 * features/Makefile (WHICH): Add s390-gs-linux64 and
6063 s390x-gs-linux64.
6064 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
6065 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
6066 * features/s390-gs-linux64.c: New generated file.
6067 * features/s390x-gs-linux64.c: New file.
6068 * regformats/s390-gs-linux64.dat: New file.
6069 * regformats/s390x-gs-linux64.dat: New file.
6070
6071 2017-09-23 Tom Tromey <tom@tromey.com>
6072
6073 * defs.h (make_cleanup_override_quit_handler): Don't declare.
6074
6075 2017-09-22 Tom Tromey <tom@tromey.com>
6076
6077 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
6078 type to scoped_restore_tmpl.
6079 <scoped_input_handler>: Initialize m_quit_handler directly.
6080
6081 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6082
6083 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
6084 (cd_command): Likewise. Free "current_directory" before
6085 assigning to it.
6086 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
6087 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
6088 * top.c (gdb_dirbuf): Remove global declaration.
6089 * top.h (gdb_dirbuf): Likewise.
6090
6091 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
6092
6093 * gnulib/aclocal.m4: Regenerate.
6094 * gnulib/config.in: Regenerate.
6095 * gnulib/configure: Regenerate.
6096 * gnulib/import/Makefile.am: Regenerate.
6097 * gnulib/import/Makefile.in: Regenerate.
6098 * gnulib/import/assure.h: New file.
6099 * gnulib/import/at-func.c: Likewise
6100 * gnulib/import/chdir-long.c: New file.
6101 * gnulib/import/chdir-long.h: New file.
6102 * gnulib/import/cloexec.c: New file.
6103 * gnulib/import/cloexec.h: New file.
6104 * gnulib/import/close.c: New file.
6105 * gnulib/import/closedir.c: New file.
6106 * gnulib/import/dirent-private.h: New file.
6107 * gnulib/import/dup-safer.c: New file.
6108 * gnulib/import/dup.c: New file.
6109 * gnulib/import/dup2.c: New file.
6110 * gnulib/import/error.c: New file.
6111 * gnulib/import/error.h: New file.
6112 * gnulib/import/exitfail.c: New file.
6113 * gnulib/import/exitfail.h: New file.
6114 * gnulib/import/fchdir.c: New file.
6115 * gnulib/import/fcntl.c: New file.
6116 * gnulib/import/fcntl.in.h: New file.
6117 * gnulib/import/fd-hook.c: New file.
6118 * gnulib/import/fd-hook.h: New file.
6119 * gnulib/import/fd-safer.c: New file.
6120 * gnulib/import/fdopendir.c: New file.
6121 * gnulib/import/filename.h: New file.
6122 * gnulib/import/filenamecat-lgpl.c: New file.
6123 * gnulib/import/filenamecat.h: New file.
6124 * gnulib/import/fstat.c: New file.
6125 * gnulib/import/fstatat.c: New file.
6126 * gnulib/import/getcwd-lgpl.c: New file.
6127 * gnulib/import/getcwd.c: New file.
6128 * gnulib/import/getdtablesize.c: New file.
6129 * gnulib/import/getlogin_r.c: New file.
6130 * gnulib/import/getprogname.c: New file.
6131 * gnulib/import/getprogname.h: New file.
6132 * gnulib/import/gettext.h: New file.
6133 * gnulib/import/glob-libc.h: New file.
6134 * gnulib/import/glob.c: New file.
6135 * gnulib/import/glob.in.h: New file.
6136 * gnulib/import/intprops.h: New file.
6137 * gnulib/import/m4/chdir-long.m4: New file.
6138 * gnulib/import/m4/close.m4: New file.
6139 * gnulib/import/m4/closedir.m4: New file.
6140 * gnulib/import/m4/d-ino.m4: New file.
6141 * gnulib/import/m4/d-type.m4: New file.
6142 * gnulib/import/m4/dup.m4: New file.
6143 * gnulib/import/m4/dup2.m4: New file.
6144 * gnulib/import/m4/error.m4: New file.
6145 * gnulib/import/m4/fchdir.m4: New file.
6146 * gnulib/import/m4/fcntl.m4: New file.
6147 * gnulib/import/m4/fcntl_h.m4: New file.
6148 * gnulib/import/m4/fdopendir.m4: New file.
6149 * gnulib/import/m4/filenamecat.m4: New file.
6150 * gnulib/import/m4/fstat.m4: New file.
6151 * gnulib/import/m4/fstatat.m4: New file.
6152 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
6153 * gnulib/import/m4/getcwd-path-max.m4: New file.
6154 * gnulib/import/m4/getcwd.m4: New file.
6155 * gnulib/import/m4/getdtablesize.m4: New file.
6156 * gnulib/import/m4/getlogin_r.m4: New file.
6157 * gnulib/import/m4/getprogname.m4: New file.
6158 * gnulib/import/m4/glob.m4: New file.
6159 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
6160 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
6161 * gnulib/import/m4/mempcpy.m4: New file.
6162 * gnulib/import/m4/memrchr.m4: New file.
6163 * gnulib/import/m4/mode_t.m4: New file.
6164 * gnulib/import/m4/msvc-inval.m4: New file.
6165 * gnulib/import/m4/msvc-nothrow.m4: New file.
6166 * gnulib/import/m4/open.m4: New file.
6167 * gnulib/import/m4/openat.m4: New file.
6168 * gnulib/import/m4/opendir.m4: New file.
6169 * gnulib/import/m4/readdir.m4: New file.
6170 * gnulib/import/m4/realloc.m4: New file.
6171 * gnulib/import/m4/rewinddir.m4: New file.
6172 * gnulib/import/m4/save-cwd.m4: New file.
6173 * gnulib/import/m4/strdup.m4: New file.
6174 * gnulib/import/m4/strerror.m4: New file.
6175 * gnulib/import/m4/unistd-safer.m4: New file.
6176 * gnulib/import/mempcpy.c: New file.
6177 * gnulib/import/memrchr.c: New file.
6178 * gnulib/import/msvc-inval.c: New file.
6179 * gnulib/import/msvc-inval.h: New file.
6180 * gnulib/import/msvc-nothrow.c: New file.
6181 * gnulib/import/msvc-nothrow.h: New file.
6182 * gnulib/import/open.c: New file.
6183 * gnulib/import/openat-die.c: New file.
6184 * gnulib/import/openat-priv.h: New file.
6185 * gnulib/import/openat-proc.c: New file.
6186 * gnulib/import/openat.c: New file.
6187 * gnulib/import/openat.h: New file.
6188 * gnulib/import/opendir.c: New file.
6189 * gnulib/import/pipe-safer.c: New file.
6190 * gnulib/import/readdir.c: New file.
6191 * gnulib/import/realloc.c: New file.
6192 * gnulib/import/rewinddir.c: New file.
6193 * gnulib/import/save-cwd.c: New file.
6194 * gnulib/import/save-cwd.h: New file.
6195 * gnulib/import/strdup.c: New file.
6196 * gnulib/import/strerror-override.c: New file.
6197 * gnulib/import/strerror-override.h: New file.
6198 * gnulib/import/strerror.c: New file.
6199 * gnulib/import/unistd--.h: New file.
6200 * gnulib/import/unistd-safer.h: New file.
6201 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
6202 "getcwd" and "glob".
6203 * ser-tcp.c: Undefine "close" before redefining it.
6204
6205 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6206
6207 * guile/scm-value.c (gdbscm_value_address): Initialize address,
6208 get rid of res_val.
6209
6210 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6211
6212 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
6213 <sol2,sparc>: Likewise.
6214 <sol2-64,i386>: Likewise.
6215
6216 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
6217 -Wdeprecated-declarations on *-*-solaris*.
6218 * configure: Regenerate.
6219
6220 * procfs.c: Include "nat/inferior.h".
6221 (procfs_info_proc): Fix typo.
6222
6223 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6224
6225 * remote.c (vector): Include.
6226 (struct private_thread_info): Add field, thread_handle.
6227 (free_private_thread_info): Deallocate storage associated with
6228 thread handle.
6229 (get_private_info_thread): Initialize `thread_handle' field.
6230 (struct thread_item): Add field, thread_handle.
6231 (clear_threads_listing_context): Deallocate storage associated
6232 with thread handle.
6233 (start_thread): Add support for "handle" attribute.
6234 (thread_attributes): Add "handle".
6235 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
6236 field.
6237 (remote_update_thread_list): Update thread_handle.
6238 (remote_thread_handle_to_thread_info): New function.
6239 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
6240
6241 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6242
6243 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
6244 function.
6245 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
6246 * python/python-internal.h (thread_object_type): Declare.
6247
6248 2017-09-21 Kevin Buettner <kevinb@redhat.com>
6249
6250 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
6251 (target_thread_handle_to_thread_info): Declare.
6252 * target.c (target_thread_handle_to_thread_info): New function.
6253 * target-delegates.c: Regenerate.
6254 * gdbthread.h (find_thread_by_handle): Declare.
6255 * thread.c (find_thread_by_handle): New function.
6256 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
6257 function.
6258 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
6259
6260 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6261
6262 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
6263
6264 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
6265
6266 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
6267
6268 2017-09-21 Yao Qi <yao.qi@linaro.org>
6269
6270 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
6271 to gdb_target_obs.
6272
6273 2017-09-20 Tom Tromey <tom@tromey.com>
6274
6275 * breakpoint.c (struct counted_command_line): Remove.
6276 (breakpoint_commands): Update.
6277 (alloc_counted_command_line, incref_counted_command_line)
6278 (decref_counted_command_line, do_cleanup_counted_command_line)
6279 (make_cleanup_decref_counted_command_line): Remove.
6280 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
6281 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
6282 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
6283 (save_breakpoints): Update.
6284 * breakpoint.h (counted_command_line): Now a typedef to
6285 shared_ptr.
6286 (struct breakpoint) <commands>: Now a counted_command_line.
6287 (struct bpstats) <command>: Likewise.
6288
6289 2017-09-20 Tom Tromey <tom@tromey.com>
6290
6291 * breakpoint.c (struct commands_info, do_map_commands_command):
6292 Remove.
6293 (commands_command_1): Update.
6294 (iterate_over_related_breakpoints): Take a function_view.
6295 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
6296 (delete_command): Update.
6297 (map_breakpoint_numbers): Take a function_view.
6298 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
6299 (disable_command): Update.
6300 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
6301 (enable_command): Update.
6302 (struct disp_data, do_enable_breakpoint_disp)
6303 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
6304 (do_map_enable_delete_breakpoint): Remove.
6305 (enable_once_command, enable_count_command, enable_delete_command)
6306 (delete_trace_variable_command): Update.
6307
6308 2017-09-20 Tom Tromey <tom@tromey.com>
6309
6310 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
6311 (bpstat_clear): Use delete.
6312 (bpstats): New constructors.
6313 (bpstat_copy, bpstat_stop_status): Use new.
6314 (dprintf_after_condition_true): Update.
6315 * breakpoint.h (bpstats::bpstats): Add constructors.
6316 (bpstats::~bpstats): Add destructor.
6317
6318 2017-09-20 Pedro Alves <palves@redhat.com>
6319
6320 * eval.c (make_params): Delete, refactored as ...
6321 (class fake_method): ... this new type's ctor.
6322 (fake_method::~fake_method): New.
6323 (evaluate_subexp_standard): Use 'fake_method'.
6324
6325 2017-09-20 Tom Tromey <tom@tromey.com>
6326
6327 * windows-nat.c (get_windows_debug_event, windows_wait)
6328 (do_initial_windows_stuff, windows_attach): Update.
6329 * utils.c (vwarning, internal_vproblem): Update.
6330 (ui_unregister_input_event_handler_cleanup)
6331 (prepare_to_handle_input): Remove.
6332 (class scoped_input_handler): New.
6333 (defaulted_query, prompt_for_continue): Update.
6334 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
6335 Update.
6336 * top.c (undo_terminal_modifications_before_exit): Update.
6337 * target/target.h (target_terminal_init, target_terminal_inferior)
6338 (target_terminal_ours): Don't declare.
6339 (class target_terminal): New.
6340 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
6341 (target_terminal_ours_for_output)
6342 (make_cleanup_restore_target_terminal): Don't declare.
6343 (target_terminal_info): Remove.
6344 * target.c (enum terminal_state, terminal_state): Remove.
6345 (target_terminal::terminal_state): Define.
6346 (target_terminal::init): Rename from target_terminal_init.
6347 (target_terminal::inferior): Rename from
6348 target_terminal_inferior.
6349 (target_terminal::ours): Rename from target_terminal_ours.
6350 (target_terminal::ours_for_output): Rename from
6351 target_terminal_ours_for_output.
6352 (target_terminal::info): New method.
6353 (cleanup_restore_target_terminal)
6354 (make_cleanup_restore_target_terminal): Remove.
6355 * solib.c (handle_solib_event): Update.
6356 * remote.c (remote_serial_quit_handler): Update.
6357 (remote_terminal_inferior, remote_wait_as): Update.
6358 * record-full.c (record_full_wait_1): Update.
6359 * nto-procfs.c (procfs_create_inferior): Update.
6360 * nat/fork-inferior.c (startup_inferior): Update.
6361 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
6362 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
6363 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
6364 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
6365 (mi_breakpoint_created, mi_breakpoint_deleted)
6366 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
6367 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
6368 (mi_user_selected_context_changed, report_initial_inferior):
6369 Update.
6370 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
6371 (linux_nat_terminal_inferior): Update.
6372 * infrun.c (follow_fork_inferior)
6373 (handle_vfork_child_exec_or_exit, do_target_resume)
6374 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
6375 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
6376 Update.
6377 * inflow.c (child_terminal_init, info_terminal_command): Update.
6378 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
6379 (attach_command): Update.
6380 * infcall.c (call_thread_fsm_should_stop): Update.
6381 * gnu-nat.c (gnu_attach): Update.
6382 * extension.c (struct active_ext_lang_state)
6383 (restore_active_ext_lang): Update.
6384 * exceptions.c (print_flush): Update.
6385 * event-top.c (async_enable_stdin, default_quit_handler): Update.
6386 (struct quit_handler_cleanup_data, restore_quit_handler)
6387 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
6388 Remove.
6389 * cp-support.c (gdb_demangle): Update.
6390 * breakpoint.c (update_inserted_breakpoint_locations)
6391 (insert_breakpoint_locations, handle_jit_event)
6392 (disable_breakpoints_in_unloaded_shlib): Update.
6393 * annotate.c (annotate_breakpoints_invalid)
6394 (annotate_frames_invalid): Update.
6395
6396 2017-09-20 Tom Tromey <tom@tromey.com>
6397
6398 * main.c (catch_command_errors): Rename from
6399 catch_command_errors_const.
6400 (captured_main_1): Update.
6401
6402 2017-09-20 Pedro Alves <palves@redhat.com>
6403
6404 * cli/cli-cmds.c (list_command): Use print_sal_location.
6405 (print_sal_location): New function.
6406 (ambiguous_line_spec): Use print_sal_location.
6407 * linespec.c (symbol_to_sal): Record the symbol in the sal.
6408 * symtab.c (find_function_start_sal): Likewise.
6409 * symtab.h (symtab_and_line::symbol): New field.
6410
6411 2017-09-20 Pedro Alves <palves@redhat.com>
6412
6413 * linespec.c (minsym_found): Handle non-text minsyms.
6414 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
6415
6416 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6417
6418 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
6419 backslash.
6420
6421 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
6422
6423 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
6424 vmovups instead vmovaps.
6425 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
6426
6427 2017-09-19 John Baldwin <jhb@FreeBSD.org>
6428
6429 * NEWS (Changes since GDB 8.0): Add starti.
6430 * infcmd.c (enum run_break): New.
6431 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
6432 case.
6433 (run_command): Use enum run_how.
6434 (start_command): Likewise.
6435 (starti_command): New function.
6436 (RUN_ARGS_HELP): New macro.
6437 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
6438 commands. Add starti command.
6439
6440 2017-09-19 Yao Qi <yao.qi@linaro.org>
6441
6442 * Makefile.in (monitor.o): Remove the rule.
6443
6444 2017-09-19 Yao Qi <yao.qi@linaro.org>
6445
6446 * annotate.h (struct annotate_arg_emitter): Use
6447 DISABLE_COPY_AND_ASSIGN.
6448 * common/refcounted-object.h (refcounted_object): Likewise.
6449 * completer.h (struct completion_result): Likewise.
6450 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
6451 * filename-seen-cache.h (filename_seen_cache): Likewise.
6452 * gdbcore.h (thread_section_name): Likewise.
6453 * gdb_regex.h (compiled_regex): Likewise.
6454 * gdbthread.h (scoped_restore_current_thread): Likewise.
6455 * inferior.h (scoped_restore_current_inferior): Likewise.
6456 * jit.c (jit_reader): Likewise.
6457 * linespec.h (struct linespec_result): Likewise.
6458 * mi/mi-parse.h (struct mi_parse): Likewise.
6459 * nat/fork-inferior.c (execv_argv): Likewise.
6460 * progspace.h (scoped_restore_current_program_space): Likewise.
6461 * python/python-internal.h (class gdbpy_enter): Likewise.
6462 * regcache.h (regcache): Likewise.
6463 * target-descriptions.c (struct tdesc_reg): Likewise.
6464 (struct tdesc_type): Likewise.
6465 (struct tdesc_feature): Likewise.
6466 * ui-out.h (ui_out_emit_type): Likewise.
6467
6468 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
6469
6470 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
6471 label abort_expression.
6472
6473 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6474
6475 * common/buffer.c (buffer_xml_printf): Adjust.
6476 * common/xml-utils.c (xml_escape_text): Change return type to
6477 std::string, update code accordingly.
6478 * common/xml-utils.h (xml_escape_text): Change return type to
6479 std::string.
6480 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
6481 * windows-tdep.c (windows_xfer_shared_library): Adjust.
6482 * unittests/xml-utils-selftests.c (test_xml_escape_text):
6483 Adjust.
6484
6485 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6486
6487 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
6488 (SUBDIR_UNITTESTS_OBS): Add new object file.
6489 * unittests/xml-utils-selftests.c: New file.
6490
6491 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6492
6493 * common/selftest.h (selftest): New struct/interface.
6494 (register_test): Add name parameter, add new overload.
6495 (run_tests): Add filter parameter.
6496 (for_each_selftest_ftype): New typedef.
6497 (for_each_selftest): New declaration.
6498 * common/selftest.c (tests): Change type to
6499 map<string, unique_ptr<selftest>>.
6500 (simple_selftest): New struct.
6501 (register_test): New function.
6502 (register_test): Add name parameter and use it.
6503 (run_tests): Add filter parameter and use it. Add prints.
6504 Adjust to vector -> map change.
6505 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
6506 registering selftests.
6507 * arm-tdep.c (_initialize_arm_tdep): Likewise.
6508 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
6509 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
6510 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
6511 * findvar.c (_initialize_findvar): Likewise.
6512 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
6513 * maint.c (maintenance_selftest): Update call to run_tests.
6514 (maintenance_info_selftests): New function.
6515 (_initialize_maint_cmds): Register "maintenance info selftests"
6516 command. Update "maintenance selftest" doc.
6517 * regcache.c (_initialize_regcache): Add names when registering
6518 selftests.
6519 * rust-exp.y (_initialize_rust_exp): Likewise.
6520 * selftest-arch.c (gdbarch_selftest): New struct.
6521 (gdbarch_tests): Remove.
6522 (register_test_foreach_arch): Add name parameter. Call
6523 register_test.
6524 (tests_with_arch): Remove, move most content to
6525 gdbarch_selftest::operator().
6526 (_initialize_selftests_foreach_arch): Remove.
6527 * selftest-arch.h (register_test_foreach_arch): Add name
6528 parameter.
6529 (run_tests_with_arch): New declaration.
6530 * utils-selftests.c (_initialize_utils_selftests): Add names
6531 when registering selftests.
6532 * utils.c (_initialize_utils): Likewise.
6533 * unittests/array-view-selftests.c
6534 (_initialize_array_view_selftests): Likewise.
6535 * unittests/environ-selftests.c (_initialize_environ_selftests):
6536 Likewise.
6537 * unittests/function-view-selftests.c
6538 (_initialize_function_view_selftests): Likewise.
6539 * unittests/offset-type-selftests.c
6540 (_initialize_offset_type_selftests): Likewise.
6541 * unittests/optional-selftests.c
6542 (_initialize_optional_selftests): Likewise.
6543 * unittests/scoped_restore-selftests.c
6544 (_initialize_scoped_restore_selftests): Likewise.
6545 * NEWS: Document "maintenance selftest" and "maint info
6546 selftests".
6547
6548 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6549
6550 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
6551 scoped_restore.
6552
6553 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
6554
6555 * mi/mi-main.c (mi_load_progress): Make uiout variable
6556 a unique_ptr.
6557
6558 2017-09-15 Pedro Alves <palves@redhat.com>
6559
6560 * compile/compile-c-types.c (convert_enum, convert_int)
6561 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
6562
6563 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
6564
6565 * dwarf2read.c (copy_string): Remove.
6566 (parse_macro_definition): Replace copy_string with savestring.
6567
6568 2017-09-15 Yao Qi <yao.qi@linaro.org>
6569
6570 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
6571 gdb_target_obs.
6572 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
6573 Likewise.
6574 (i[34567]86-*-linux*): Likewise.
6575
6576 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6577
6578 * dwarf2expr.h (dwarf_stack_value): Add constructor.
6579 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
6580 <stack>: Change type to std::vector.
6581 <stack_len, stack_allocated>: Remove.
6582 <grow_stack>: Remove.
6583 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6584 (dwarf_expr_context::~dwarf_expr_context): Remove.
6585 (dwarf_expr_context::grow_stack): Remove.
6586 (dwarf_expr_context::push): Adjust.
6587 (dwarf_expr_context::pop): Adjust.
6588 (dwarf_expr_context::fetch): Adjust.
6589 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
6590 (dwarf_expr_context::stack_empty_p): Adjust.
6591 (dwarf_expr_context::execute_stack_op): Adjust.
6592
6593 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6594
6595 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
6596 return type to bool.
6597 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
6598
6599 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6600
6601 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
6602 Change type to bool.
6603 (dwarf_stack_value) <in_stack_memory>: Likewise.
6604 (dwarf_expr_context) <push_address>: Change parameter type to
6605 bool.
6606 <fetch_in_stack_memory>: Change return type to bool.
6607 <push>: Change parameter type to bool.
6608 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
6609 to bool.
6610 (dwarf_expr_context::push_address): Likewise.
6611 (dwarf_expr_context::fetch_in_stack_memory): Change return type
6612 to bool.
6613 (dwarf_expr_context::execute_stack_op): Adjust.
6614 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
6615
6616 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
6617
6618 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
6619 (struct dwarf_expr_context) <n_pieces>: Remove.
6620 <pieces>: Change type to std::vector.
6621 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
6622 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
6623 pieces.
6624 (dwarf_expr_context::add_piece): Adjust.
6625 * dwarf2loc.c (struct piece_closure): Initialize fields.
6626 <n_pieces>: Remove.
6627 <pieces>: Change type to std::vector.
6628 (allocate_piece_closure): Adjust, change parameter to
6629 std::vector rvalue and std::move it to piece_closure.
6630 (rw_pieced_value): Adjust.
6631 (check_pieced_synthetic_pointer): Adjust.
6632 (indirect_synthetic_pointer): Adjust.
6633 (coerce_pieced_ref): Adjust.
6634 (free_pieced_value_closure): Adjust. Use delete to free
6635 piece_closure.
6636 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
6637 to allocate_piece_closure.
6638 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
6639
6640 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6641
6642 * probe.h (probe_ops_cp): Remove typedef.
6643 (DEF_VEC_P (probe_ops_cp)): Remove.
6644 (all_probe_ops): Change type to std::vector.
6645 * probe.c (info_probes_for_ops): Adjust to vector change.
6646 (probe_linespec_to_ops): Likewise.
6647 (all_probe_ops): Change type to std::vector.
6648 (_initialize_probe): Adjust to vector change.
6649 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
6650 * elfread.c (elf_get_probes): Likewise.
6651 * stap-probe.c (_initialize_stap_probe): Likewise.
6652
6653 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6654
6655 * probe.h (struct bound_probe): Define constructors.
6656 * probe.c (bound_probe_s): Remove typedef.
6657 (DEF_VEC_O (bound_probe_s)): Remove VEC.
6658 (collect_probes): Change return type to std::vector, remove
6659 cleanup.
6660 (compare_probes): Return bool, change parameter type. Change
6661 semantic to "less than".
6662 (gen_ui_out_table_header_info): Change parameter to std::vector
6663 and update.
6664 (exists_probe_with_pops): Likewise.
6665 (info_probes_for_ops): Update to std::vector change.
6666 (enable_probes_command): Likewise.
6667 (disable_probes_command): Likewise.
6668
6669 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
6670
6671 * probe.h (struct probe_ops) <get_probes>: Change parameter from
6672 vec to std::vector.
6673 * probe.c (parse_probes_in_pspace): Update.
6674 (find_probes_in_objfile): Update.
6675 (find_probe_by_pc): Update.
6676 (collect_probes): Update.
6677 (probe_any_get_probes): Update.
6678 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
6679 return type to reference to std::vector.
6680 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
6681 std::vector and update.
6682 (dtrace_process_dof): Likewise.
6683 (dtrace_get_probes): Likewise.
6684 * elfread.c (elf_get_probes): Change return type to std::vector,
6685 store an std::vector in bfd_data.
6686 (probe_key_free): Update to std::vector.
6687 * stap-probe.c (handle_stap_probe): Change parameter to
6688 std::vector and update.
6689 (stap_get_probes): Likewise.
6690 * symfile-debug.c (debug_sym_get_probes): Change return type to
6691 std::vector and update.
6692
6693 2017-09-11 Tom Tromey <tom@tromey.com>
6694
6695 * breakpoint.c (program_breakpoint_here_p): Update.
6696 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
6697 from make_show_memory_breakpoints_cleanup. Return a
6698 scoped_restore_tmpl<int>.
6699 (restore_show_memory_breakpoints): Remove.
6700 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
6701 * mem-break.c (memory_validate_breakpoint): Update.
6702 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
6703 (ia64_memory_remove_breakpoint): Update.
6704 (ia64_breakpoint_from_pc): Update.
6705 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
6706 from make_show_memory_breakpoints_cleanup.
6707
6708 2017-09-11 Tom Tromey <tom@tromey.com>
6709
6710 * d-namespace.c (d_lookup_symbol): Use std::string.
6711 (find_symbol_in_baseclass): Likewise.
6712
6713 2017-09-11 Tom Tromey <tom@tromey.com>
6714
6715 * ctf.c (ctf_start): Use std::string.
6716
6717 2017-09-11 Tom Tromey <tom@tromey.com>
6718
6719 * ada-lang.c (is_known_support_routine): Update.
6720 (ada_unhandled_exception_name_addr_from_raise): Update.
6721 * guile/scm-frame.c (gdbscm_frame_name): Update.
6722 * python/py-frame.c (frapy_name): Update.
6723 (frapy_function): Update.
6724 * stack.h (find_frame_funname): Update.
6725 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
6726 (print_frame): Update.
6727
6728 2017-09-11 Tom Tromey <tom@tromey.com>
6729
6730 * findcmd.c (put_bits): Take a gdb::byte_vector.
6731 (parse_find_args): Return gdb::byte_vector. "args" now const.
6732 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
6733 cleanups.
6734 (find_command): Update.
6735
6736 2017-09-11 Tom Tromey <tom@tromey.com>
6737
6738 * cli/cli-script.c (class scoped_restore_hook_in): New.
6739 (clear_hook_in_cleanup): Remove.
6740 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
6741 scoped_restore_hook_in.
6742
6743 2017-09-11 Tom Tromey <tom@tromey.com>
6744
6745 * cli/cli-script.c (restore_interp): Remove.
6746 (read_command_lines): Use scoped_restore_interp.
6747 * interps.c (scoped_restore_interp::set_temp): Rename from
6748 interp_set_temp.
6749 * interps.h (class scoped_restore_interp): New.
6750 (interp_set_temp): Remove.
6751
6752 2017-09-11 Tom Tromey <tom@tromey.com>
6753
6754 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
6755 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
6756 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
6757 scoped_restore.
6758 (mi_cmd_break_insert_1): Update.
6759 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
6760 scoped_restore.
6761
6762 2017-09-11 Tom Tromey <tom@tromey.com>
6763
6764 * demangle.c (demangle_command): Update.
6765 * breakpoint.c (disable_command): Update.
6766 (enable_command): Update.
6767 (find_location_by_number): Make "number" const. Use
6768 get_number_trailer.
6769 * cli/cli-utils.c (extract_arg): Return std::string.
6770 * probe.c (parse_probe_linespec): Update. Change types.
6771 (collect_probes): Take string arguments.
6772 (parse_probe_linespec): Likewise.
6773 (info_probes_for_ops): Update.
6774 (enable_probes_command): Update.
6775 (disable_probes_command): Update.
6776 * break-catch-sig.c (catch_signal_split_args): Update.
6777 * mi/mi-parse.c (mi_parse): Update.
6778
6779 2017-09-11 Tom Tromey <tom@tromey.com>
6780
6781 * language.h (language_enum): Make argument const.
6782 * language.c (language_enum): Make argument const.
6783
6784 2017-09-11 Tom Tromey <tom@tromey.com>
6785
6786 * common/common-utils.h (skip_to_space): Remove macro, redeclare
6787 as function.
6788 (skip_to_space): Rename from skip_to_space_const.
6789 * common/common-utils.c (skip_to_space): New function.
6790 (skip_to_space): Rename from skip_to_space_const.
6791 * cli/cli-utils.h (get_number): Rename from get_number_const.
6792 (extract_arg): Rename from extract_arg_const.
6793 * cli/cli-utils.c (get_number): Rename from get_number_const.
6794 (extract_arg): Rename from extract_arg_const.
6795 (number_or_range_parser::get_number): Use ::get_number.
6796 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
6797 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
6798 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
6799 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
6800 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
6801 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
6802 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
6803 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
6804
6805 2017-09-11 Tom Tromey <tom@tromey.com>
6806
6807 * python/python.c (do_start_initialization): Use
6808 py-event-types.def to initialize types.
6809 Define all object type structures.
6810 * python/python-internal.h: Don't declare event initialization
6811 functions.
6812 * python/py-threadevent.c (thread_event_object_type): Don't
6813 define.
6814 * python/py-stopevent.c (stop_event_object_type): Don't define.
6815 * python/py-signalevent.c (signal_event_object_type): Don't
6816 declare or define.
6817 * python/py-newobjfileevent.c (new_objfile_event_object_type)
6818 (clear_objfiles_event_object_type): Don't declare or define.
6819 * python/py-infevents.c (inferior_call_pre_event_object_type)
6820 (inferior_call_post_event_object_type)
6821 (register_changed_event_object_type)
6822 (memory_changed_event_object_type): Don't declare or define.
6823 * python/py-inferior.c (new_thread_event_object_type)
6824 (new_inferior_event_object_type)
6825 (inferior_deleted_event_object_type): Don't declare or define.
6826 * python/py-exitedevent.c (exited_event_object_type): Don't
6827 declare or define.
6828 * python/py-evts.c (gdbpy_initialize_py_events): Use
6829 py-all-events.def.
6830 * python/py-events.h (thread_event_object_type): Don't declare.
6831 (events_object): Use py-all-events.def.
6832 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
6833 py-event-types.def.
6834 * python/py-event-types.def: New file.
6835 * python/py-continueevent.c (create_continue_event_object): Don't
6836 declare or define.
6837 * python/py-bpevent.c (breakpoint_event_object_type): Don't
6838 declare or define.
6839 * python/py-all-events.def: New file.
6840
6841 2017-09-11 Tom Tromey <tom@tromey.com>
6842
6843 * python/py-threadevent.c (create_thread_event_object): Return
6844 gdbpy_ref.
6845 * python/py-stopevent.h (create_stop_event_object)
6846 (create_breakpoint_event_object, create_signal_event_object):
6847 Update.
6848 * python/py-stopevent.c (create_stop_event_object): Return
6849 gdbpy_ref.
6850 (emit_stop_event): Update.
6851 * python/py-signalevent.c (create_signal_event_object): Return
6852 gdbpy_ref.
6853 * python/py-infevents.c (create_inferior_call_event_object):
6854 Update.
6855 * python/py-event.h (create_event_object)
6856 (create_thread_event_object): Update.
6857 * python/py-event.c (create_event_object): Return gdbpy_ref.
6858 * python/py-continueevent.c: Return gdbpy_ref.
6859 * python/py-bpevent.c (create_breakpoint_event_object): Return
6860 gdbpy_ref.
6861
6862 2017-09-11 Tom Tromey <tom@tromey.com>
6863
6864 PR python/15622:
6865 * NEWS: Add entry.
6866 * python/python.c (do_start_initialization): Initialize new event
6867 types.
6868 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
6869 (gdbpy_initialize_inferior_deleted_event)
6870 (gdbpy_initialize_new_thread_event): Declare.
6871 * python/py-threadevent.c (create_thread_event_object): Add option
6872 "thread" parameter.
6873 * python/py-inferior.c (new_thread_event_object_type)
6874 (new_inferior_event_object_type)
6875 (inferior_deleted_event_object_type): Declare.
6876 (python_new_inferior, python_inferior_deleted): New functions.
6877 (add_thread_object): Emit new_thread event.
6878 (gdbpy_initialize_inferior): Attach new functions to corresponding
6879 observers.
6880 (new_thread, new_inferior, inferior_deleted): Define new event
6881 types.
6882 * python/py-evts.c (gdbpy_initialize_py_events): Add new
6883 registries.
6884 * python/py-events.h (events_object) <new_inferior,
6885 inferior_deleted, new_thread>: New fields.
6886 * python/py-event.h (create_thread_event_breakpoint): Add optional
6887 "thread" parameter.
6888
6889 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
6890
6891 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
6892 check current_ui instead.
6893 (internal_vproblem): Likewise.
6894
6895 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
6896
6897 * thread.c (print_thread_info_1): Remove unnecessary calls to
6898 uiout->is_mi_like_p.
6899
6900 2017-09-09 Tom Tromey <tom@tromey.com>
6901
6902 * namespace.h (add_using_directive): Update.
6903 * namespace.c (add_using_directive): Change type of excludes to
6904 std::vector.
6905 * dwarf2read.c (read_import_statement): Use std::vector.
6906 (read_namespace): Update.
6907 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
6908
6909 2017-09-09 Tom Tromey <tom@tromey.com>
6910
6911 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
6912
6913 2017-09-09 Tom Tromey <tom@tromey.com>
6914
6915 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
6916
6917 2017-09-09 Tom Tromey <tom@tromey.com>
6918
6919 * stack.c (func_command): Use gdb::def_vector.
6920
6921 2017-09-09 Tom Tromey <tom@tromey.com>
6922
6923 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
6924 ui_out_emit_list, ui_out_emit_tuple.
6925 (mi_cmd_var_update): Likewise.
6926
6927 2017-09-09 Tom Tromey <tom@tromey.com>
6928
6929 * mi/mi-interp.c (mi_user_selected_context_changed): Use
6930 ui_out_redirect_pop.
6931 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
6932 ui_out_redirect_pop.
6933 * utils.c (do_ui_out_redirect_pop)
6934 (make_cleanup_ui_out_redirect_pop): Remove.
6935 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
6936 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
6937 * ui-out.h (ui_out_redirect_pop): New class.
6938
6939 2017-09-09 Tom Tromey <tom@tromey.com>
6940
6941 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
6942 (list_available_thread_groups, mi_cmd_list_thread_groups)
6943 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
6944 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
6945 Likewise.
6946
6947 2017-09-09 Tom Tromey <tom@tromey.com>
6948
6949 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
6950 ui_out_emit_tuple.
6951
6952 2017-09-09 Tom Tromey <tom@tromey.com>
6953
6954 * target.c (flash_erase_command): Use ui_out_emit_tuple.
6955 * stack.c (print_frame): Use ui_out_emit_tuple.
6956 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
6957 (info_spu_mailbox_command, info_spu_dma_command)
6958 (info_spu_proxydma_command): Likewise.
6959 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
6960 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
6961 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
6962 ui_out_emit_tuple.
6963 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
6964
6965 2017-09-09 Tom Tromey <tom@tromey.com>
6966
6967 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
6968 (class ui_out_emit_table): Update comment.
6969 * ui-out.c (do_cleanup_table_end)
6970 (make_cleanup_ui_out_table_begin_end): Remove.
6971 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
6972 (info_spu_dma_cmdlist): Likewise.
6973 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
6974 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
6975 ui_out_emit_table.
6976
6977 2017-09-09 Tom Tromey <tom@tromey.com>
6978
6979 * thread.c (print_thread_info_1): Use ui_out_emit_table,
6980 ui_out_emit_list, gdb::optional.
6981
6982 2017-09-09 John Baldwin <jhb@FreeBSD.org>
6983
6984 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
6985 prototype.
6986 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
6987 prototype.
6988 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
6989 prototype.
6990 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
6991 * ada-exp.y: Remove _initialize_ada_exp prototype.
6992 * ada-lang.c: Remove _initialize_ada_language prototype.
6993 * ada-tasks.c: Remove _initialize_tasks prototype.
6994 * addrmap.c: Remove _initialize_addrmap prototype.
6995 * agent.c: Remove _initialize_agent prototype.
6996 * aix-thread.c: Remove _initialize_aix_thread prototype.
6997 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
6998 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
6999 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
7000 prototype.
7001 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
7002 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
7003 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
7004 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
7005 prototype.
7006 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
7007 prototype.
7008 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
7009 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
7010 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
7011 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
7012 prototype.
7013 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
7014 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
7015 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
7016 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
7017 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7018 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
7019 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
7020 prototype.
7021 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
7022 prototype.
7023 * annotate.c: Remove _initialize_annotate prototype.
7024 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
7025 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
7026 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
7027 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
7028 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
7029 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
7030 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
7031 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
7032 prototype.
7033 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
7034 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
7035 * auto-load.c: Remove _initialize_auto_load prototype.
7036 * auxv.c: Remove _initialize_auxv prototype.
7037 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
7038 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
7039 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
7040 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
7041 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
7042 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
7043 prototype.
7044 * break-catch-throw.c: Remove _initialize_break_catch_throw
7045 prototype.
7046 * breakpoint.c: Remove _initialize_breakpoint prototype.
7047 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
7048 * btrace.c: Remove _initialize_btrace prototype.
7049 * charset.c: Remove _initialize_charset prototype.
7050 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
7051 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
7052 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
7053 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
7054 * cli/cli-script.c: Remove _initialize_cli_script prototype.
7055 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
7056 * coffread.c: Remove _initialize_coffread prototype.
7057 * compile/compile.c: Remove _initialize_compile prototype.
7058 * complaints.c: Remove _initialize_complaints prototype.
7059 * completer.c: Remove _initialize_completer prototype.
7060 * copying.awk: Remove _initialize_copying prototype.
7061 * copying.c: Regenerate.
7062 * core-regset.c: Remove _initialize_core_regset prototype.
7063 * corefile.c: Remove _initialize_core prototype.
7064 * corelow.c: Remove _initialize_corelow prototype.
7065 * cp-abi.c: Remove _initialize_cp_abi prototype.
7066 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
7067 * cp-support.c: Remove _initialize_cp_support prototype.
7068 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
7069 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
7070 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
7071 * ctf.c: Remove _initialize_ctf prototype.
7072 * d-lang.c: Remove _initialize_d_language prototype.
7073 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
7074 prototype.
7075 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
7076 * dbxread.c: Remove _initialize_dbxread prototype.
7077 * dcache.c: Remove _initialize_dcache prototype.
7078 * demangle.c: Remove _initialize_demangler prototype.
7079 * disasm-selftests.c: Remove _initialize_disasm_selftests
7080 prototype.
7081 * disasm.c: Remove _initialize_disasm prototype.
7082 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
7083 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
7084 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
7085 prototype.
7086 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
7087 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
7088 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
7089 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
7090 * elfread.c: Remove _initialize_elfread prototype.
7091 * exec.c: Remove _initialize_exec prototype.
7092 * extension.c: Remove _initialize_extension prototype.
7093 * f-lang.c: Remove _initialize_f_language prototype.
7094 * f-valprint.c: Remove _initialize_f_valprint prototype.
7095 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
7096 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
7097 * filesystem.c: Remove _initialize_filesystem prototype.
7098 * findcmd.c: Remove _initialize_mem_search prototype.
7099 * fork-child.c: Remove _initialize_fork_child prototype.
7100 * frame-base.c: Remove _initialize_frame_base prototype.
7101 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
7102 * frame.c: Remove _initialize_frame prototype.
7103 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
7104 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
7105 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
7106 * gcore.c: Remove _initialize_gcore prototype.
7107 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
7108 * gdbarch.c: Regenerate.
7109 * gdbarch.sh: Remove _initialize_gdbarch prototype.
7110 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
7111 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
7112 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
7113 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
7114 * go-lang.c: Remove _initialize_go_language prototype.
7115 * go32-nat.c: Remove _initialize_go32_nat prototype.
7116 * guile/guile.c: Remove _initialize_guile prototype.
7117 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
7118 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
7119 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
7120 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
7121 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
7122 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
7123 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
7124 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
7125 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
7126 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
7127 prototype.
7128 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
7129 prototype.
7130 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
7131 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
7132 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
7133 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
7134 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
7135 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
7136 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
7137 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
7138 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
7139 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
7140 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
7141 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
7142 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
7143 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
7144 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
7145 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
7146 prototype.
7147 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
7148 prototype.
7149 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
7150 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
7151 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
7152 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
7153 * infcall.c: Remove _initialize_infcall prototype.
7154 * infcmd.c: Remove _initialize_infcmd prototype.
7155 * inferior.c: Remove _initialize_inferiors prototype.
7156 * inflow.c: Remove _initialize_inflow prototype.
7157 * infrun.c: Remove _initialize_infrun prototype.
7158 * interps.c: Remove _initialize_interpreter prototype.
7159 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
7160 * jit.c: Remove _initialize_jit prototype.
7161 * language.c: Remove _initialize_language prototype.
7162 * linux-fork.c: Remove _initialize_linux_fork prototype.
7163 * linux-nat.c: Remove _initialize_linux_nat prototype.
7164 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
7165 * linux-thread-db.c: Remove _initialize_thread_db prototype.
7166 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
7167 * m2-lang.c: Remove _initialize_m2_language prototype.
7168 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
7169 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
7170 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
7171 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
7172 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
7173 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7174 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7175 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
7176 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
7177 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
7178 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
7179 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
7180 * machoread.c: Remove _initialize_machoread prototype.
7181 * macrocmd.c: Remove _initialize_macrocmd prototype.
7182 * macroscope.c: Remove _initialize_macroscope prototype.
7183 * maint.c: Remove _initialize_maint_cmds prototype.
7184 * mdebugread.c: Remove _initialize_mdebugread prototype.
7185 * memattr.c: Remove _initialize_mem prototype.
7186 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
7187 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
7188 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
7189 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
7190 * mi/mi-main.c: Remove _initialize_mi_main prototype.
7191 * microblaze-linux-tdep.c: Remove
7192 _initialize_microblaze_linux_tdep prototype.
7193 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
7194 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
7195 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
7196 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
7197 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
7198 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
7199 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
7200 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
7201 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
7202 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
7203 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
7204 prototype.
7205 * mipsread.c: Remove _initialize_mipsread prototype.
7206 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
7207 prototype.
7208 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
7209 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
7210 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
7211 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
7212 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
7213 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
7214 prototype.
7215 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
7216 * nto-procfs.c: Remove _initialize_procfs prototype.
7217 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
7218 * objc-lang.c: Remove _initialize_objc_language prototype.
7219 * objfiles.c: Remove _initialize_objfiles prototype.
7220 * observer.c: Remove observer_test_first_notification_function,
7221 observer_test_second_notification_function,
7222 observer_test_third_notification_function, and
7223 _initialize_observer prototypes.
7224 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
7225 * osabi.c: Remove _initialize_gdb_osabi prototype.
7226 * osdata.c: Remove _initialize_osdata prototype.
7227 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
7228 * parse.c: Remove _initialize_parse prototype.
7229 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
7230 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
7231 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
7232 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
7233 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
7234 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
7235 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
7236 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
7237 * printcmd.c: Remove _initialize_printcmd prototype.
7238 * probe.c: Remove _initialize_probe prototype.
7239 * proc-api.c: Remove _initialize_proc_api prototype.
7240 * proc-events.c: Remove _initialize_proc_events prototype.
7241 * proc-service.c: Remove _initialize_proc_service prototype.
7242 * procfs.c: Remove _initialize_procfs prototype.
7243 * psymtab.c: Remove _initialize_psymtab prototype.
7244 * python/python.c: Remove _initialize_python prototype.
7245 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
7246 * record-btrace.c: Remove _initialize_record_btrace prototype.
7247 * record-full.c: Remove _initialize_record_full prototype.
7248 * record.c: Remove _initialize_record prototype.
7249 * regcache.c: Remove _initialize_regcache prototype.
7250 * reggroups.c: Remove _initialize_reggroup prototype.
7251 * remote-notif.c: Remove _initialize_notif prototype.
7252 * remote-sim.c: Remove _initialize_remote_sim prototype.
7253 * remote.c: Remove _initialize_remote prototype.
7254 * reverse.c: Remove _initialize_reverse prototype.
7255 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
7256 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
7257 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
7258 prototype.
7259 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
7260 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
7261 * rust-exp.y: Remove _initialize_rust_exp prototype.
7262 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
7263 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
7264 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
7265 * score-tdep.c: Remove _initialize_score_tdep prototype.
7266 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
7267 prototype.
7268 * ser-go32.c: Remove _initialize_ser_dos prototype.
7269 * ser-mingw.c: Remove _initialize_ser_windows prototype.
7270 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
7271 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
7272 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
7273 * serial.c: Remove _initialize_serial prototype.
7274 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
7275 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
7276 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
7277 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
7278 * skip.c: Remove _initialize_step_skip prototype.
7279 * sol-thread.c: Remove _initialize_sol_thread prototype.
7280 * solib-aix.c: Remove _initialize_solib_aix prototype.
7281 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
7282 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
7283 * solib-frv.c: Remove _initialize_frv_solib prototype.
7284 * solib-spu.c: Remove _initialize_spu_solib prototype.
7285 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
7286 * solib-target.c: Remove _initialize_solib_target prototype.
7287 * solib.c: Remove _initialize_solib prototype.
7288 * source.c: Remove _initialize_source prototype.
7289 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
7290 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
7291 prototype.
7292 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
7293 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
7294 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
7295 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
7296 prototype.
7297 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
7298 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
7299 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
7300 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
7301 prototype.
7302 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
7303 prototype.
7304 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
7305 prototype.
7306 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
7307 prototype.
7308 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
7309 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
7310 prototype.
7311 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
7312 prototype.
7313 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
7314 prototype.
7315 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
7316 prototype.
7317 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
7318 prototype.
7319 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
7320 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
7321 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
7322 * stabsread.c: Remove _initialize_stabsread prototype.
7323 * stack.c: Remove _initialize_stack prototype.
7324 * stap-probe.c: Remove _initialize_stap_probe prototype.
7325 * std-regs.c: Remove _initialize_frame_reg prototype.
7326 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
7327 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
7328 * symfile.c: Remove _initialize_symfile prototype.
7329 * symmisc.c: Remove _initialize_symmisc prototype.
7330 * symtab.c: Remove _initialize_symtab prototype.
7331 * target-dcache.c: Remove _initialize_target_dcache prototype.
7332 * target-descriptions.c: Remove _initialize_target_descriptions
7333 prototype.
7334 * thread.c: Remove _initialize_thread prototype.
7335 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
7336 prototype.
7337 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
7338 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
7339 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
7340 prototype.
7341 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
7342 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
7343 * tracefile.c: Remove _initialize_tracefile prototype.
7344 * tracepoint.c: Remove _initialize_tracepoint prototype.
7345 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
7346 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
7347 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
7348 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
7349 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
7350 * tui/tui-win.c: Remove _initialize_tui_win prototype.
7351 * tui/tui.c: Remove _initialize_tui prototype.
7352 * typeprint.c: Remove _initialize_typeprint prototype.
7353 * user-regs.c: Remove _initialize_user_regs prototype.
7354 * utils.c: Remove _initialize_utils prototype.
7355 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
7356 * valarith.c: Remove _initialize_valarith prototype.
7357 * valops.c: Remove _initialize_valops prototype.
7358 * valprint.c: Remove _initialize_valprint prototype.
7359 * value.c: Remove _initialize_values prototype.
7360 * varobj.c: Remove _initialize_varobj prototype.
7361 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
7362 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
7363 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
7364 * windows-nat.c: Remove _initialize_windows_nat,
7365 _initialize_check_for_gdb_ini, and _initialize_loadable
7366 prototypes.
7367 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
7368 * xcoffread.c: Remove _initialize_xcoffread prototype.
7369 * xml-support.c: Remove _initialize_xml_support prototype.
7370 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
7371 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
7372 prototype.
7373 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
7374 prototype.
7375 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
7376
7377 2017-09-08 Keith Seitz <keiths@redhat.com>
7378
7379 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
7380 field.
7381
7382 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
7383
7384 * f-valprint.c (f_val_print): Remove check for one byte
7385 sized integers. Remove printing of character type.
7386
7387 2017-09-08 Frank Penczek <frank.penczek@intel.com>
7388 Christoph Weinmann <christoph.t.weinmann@intel.com>
7389 Bernhard Heckel <bernhard.heckel@intel.com>
7390
7391 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
7392 to maintain proper indentation when printing pointers/refs.
7393
7394 2017-09-07 Joel Brobecker <brobecker@adacore.com>
7395
7396 GDB 8.0.1 released.
7397
7398 2017-09-07 Joel Brobecker <brobecker@adacore.com>
7399
7400 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
7401
7402 2017-09-05 Tom Tromey <tom@tromey.com>
7403
7404 * parse.c (funcall_chain): Now a std::vector.
7405 (start_arglist, end_arglist): Simplify.
7406 (free_funcalls): Remove.
7407 (parse_exp_in_context_1): Remove cleanup.
7408
7409 2017-09-05 Tom Tromey <tom@tromey.com>
7410
7411 * go-exp.y (go_parse): Don't create a cleanup.
7412
7413 2017-09-05 Tom Tromey <tom@tromey.com>
7414
7415 * d-exp.y (PrimaryExpression): Use std::string.
7416 (d_parse): Don't create a cleanup.
7417
7418 2017-09-05 Tom Tromey <tom@tromey.com>
7419
7420 * utils.c (do_clear_parser_state): Remove.
7421 (make_cleanup_clear_parser_state): Remove.
7422 * p-exp.y (pascal_parse): Use scoped_restore.
7423 * m2-exp.y (m2_parse): Use scoped_restore.
7424 * f-exp.y (f_parse): Use scoped_restore.
7425 * d-exp.y (d_parse): Use scoped_restore.
7426 * c-exp.y (c_parse): Use scoped_restore.
7427 * ada-exp.y (ada_parse): Use scoped_restore.
7428 * utils.h (make_cleanup_clear_parser_state): Remove.
7429
7430 2017-09-06 Keith Seitz <keiths@redhat.com>
7431
7432 * dwarf2read.c (dw2_linkage_name_attr): New function.
7433 (dw2_linkage_name): New function.
7434 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
7435 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
7436 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
7437
7438 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7439
7440 * config/djgpp/djconfig.sh: Correct shell portability issue.
7441
7442 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7443
7444 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
7445
7446 2017-09-06 John Baldwin <jhb@FreeBSD.org>
7447
7448 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
7449 * NEWS: Mention new FreeBSD/mips native configuration.
7450 * configure.host: Add aarch64*-*-freebsd*.
7451 * configure.nat: Likewise.
7452 * aarch64-fbsd-nat.c: New file.
7453
7454 2017-09-06 John Baldwin <jhb@FreeBSD.org>
7455
7456 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
7457 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
7458 * NEWS: Mention new FreeBSD/aarch64 target.
7459 * configure.tgt: Add aarch64*-*-freebsd*.
7460 * aarch64-fbsd-tdep.c: New file.
7461 * aarch64-fbsd-tdep.h: New file.
7462
7463 2017-09-06 Kamil Rytarowski <n54@gmx.com>
7464
7465 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
7466
7467 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
7468
7469 * parse.c (find_minsym_type_and_address): Don't relocate addresses
7470 of TLS symbols.
7471
7472 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
7473
7474 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
7475 call.
7476
7477 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7478
7479 * infrun.c (follow_exec): Call add_thread after
7480 target_find_description.
7481
7482 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7483
7484 * infrun.c (handle_inferior_event_1): When exec'ing, read
7485 stop_pc after follow_exec.
7486
7487 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7488
7489 * remote.c (process_g_packet): Update error message.
7490
7491 2017-09-05 Yao Qi <yao.qi@linaro.org>
7492
7493 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
7494 targets.
7495
7496 2017-09-05 Pedro Alves <palves@redhat.com>
7497
7498 * eval.c (eval_call, evaluate_funcall): New functions, factored
7499 out from ...
7500 (evaluate_subexp_standard): ... this.
7501
7502 2017-09-05 Yao Qi <yao.qi@linaro.org>
7503
7504 * amd64-tdep.c (amd64_target_description): Create target
7505 descriptions.
7506 (_initialize_amd64_tdep): Don't call functions
7507 initialize_tdesc_amd64_*. Add self tests.
7508 * arch/amd64.c (amd64_create_target_description): Add parameter
7509 is_linux. Call set_tdesc_osabi if is_linux is true.
7510 * arch/amd64.h (amd64_create_target_description): Update the
7511 declaration.
7512 * arch/i386.c (i386_create_target_description): Add parameter
7513 is_linux. Call set_tdesc_osabi if is_linux is true.
7514 * arch/i386.h (i386_create_target_description): Update
7515 declaration.
7516 * configure.tgt: Add i386.o to gdb_target_obs.
7517 * features/Makefile (XMLTOC): Remove i386/*.xml.
7518 * features/i386/amd64-avx-avx512.c: Remove.
7519 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
7520 * features/i386/amd64-avx-mpx.c: Remove.
7521 * features/i386/amd64-avx.c: Remove.
7522 * features/i386/amd64-mpx.c: Remove.
7523 * features/i386/amd64.c: Remove.
7524 * features/i386/i386-avx-avx512.c: Remove.
7525 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
7526 * features/i386/i386-avx-mpx.c: Remove.
7527 * features/i386/i386-avx.c: Remove.
7528 * features/i386/i386-mmx.c: Remove.
7529 * features/i386/i386-mpx.c: Remove.
7530 * features/i386/i386.c: Remove.
7531 * i386-tdep.c: Don't include features/i386/i386*.c., include
7532 target-descriptions.h and arch/i386.h.
7533 (i386_target_description): Create target descriptions.
7534 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
7535 functions. Do self tests.
7536
7537 2017-09-05 Yao Qi <yao.qi@linaro.org>
7538
7539 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
7540 * features/i386/amd64-avx-avx512-linux.c: Removed.
7541 * features/i386/amd64-avx-linux.c: Removed.
7542 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
7543 * features/i386/amd64-avx-mpx-linux.c: Removed.
7544 * features/i386/amd64-linux.c: Removed.
7545 * features/i386/amd64-mpx-linux.c: Removed.
7546 * features/i386/x32-avx-avx512-linux.c: Removed.
7547 * features/i386/x32-avx-linux.c: Removed.
7548 * features/i386/x32-linux.c: Removed.
7549
7550 2017-09-05 Yao Qi <yao.qi@linaro.org>
7551
7552 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
7553 features/i386/*.c.
7554 (amd64_linux_read_description): Call
7555 amd64_create_target_description.
7556 * arch/amd64.c: New file.
7557 * arch/amd64.h: New file.
7558 * configure.tgt (x86_64-*-linux*): Append amd64.o.
7559 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
7560
7561 2017-09-05 Yao Qi <yao.qi@linaro.org>
7562
7563 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
7564 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
7565 (amd64_linux_read_description): Create target descriptions.
7566 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
7567 functions. Add unit tests.
7568 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
7569 x32-core.xml.
7570 * features/i386/64bit-avx.c: Generated.
7571 * features/i386/64bit-avx512.c: Generated.
7572 * features/i386/64bit-core.c: Generated.
7573 * features/i386/64bit-linux.c: Generated.
7574 * features/i386/64bit-mpx.c: Generated.
7575 * features/i386/64bit-pkeys.c: Generated.
7576 * features/i386/64bit-segments.c: Generated.
7577 * features/i386/64bit-sse.c: Generated.
7578 * features/i386/x32-core.c: Generated.
7579 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
7580 c files for amd64-linux and x32-linux.
7581
7582 2017-09-05 Yao Qi <yao.qi@linaro.org>
7583
7584 * amd64-linux-tdep.c (amd64_linux_read_description): New
7585 function.
7586 (amd64_linux_core_read_description): Call
7587 amd64_linux_read_description.
7588 (amd64_linux_init_abi): Likewise.
7589 (amd64_x32_linux_init_abi): Likewise.
7590 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
7591 * x86-linux-nat.c (x86_linux_read_description): Call
7592 amd64_linux_read_description.
7593
7594 2017-09-05 Yao Qi <yao.qi@linaro.org>
7595
7596 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
7597 comments.
7598
7599 2017-09-05 Yao Qi <yao.qi@linaro.org>
7600
7601 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
7602 * features/i386/i386-avx-avx512-linux.c: Remove.
7603 * features/i386/i386-avx-linux.c: Remove.
7604 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
7605 * features/i386/i386-avx-mpx-linux.c: Remove.
7606 * features/i386/i386-linux.c: Remove.
7607 * features/i386/i386-mmx-linux.c: Remove.
7608 * features/i386/i386-mpx-linux.c: Remove.
7609
7610 2017-09-05 Yao Qi <yao.qi@linaro.org>
7611
7612 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
7613 (SFILES): Add arch/i386.c.
7614 (HFILES_NO_SRCDIR): Add arch/i386.h.
7615 * arch/i386.c: New file.
7616 * arch/i386.h: New file.
7617 * arch/tdesc.h (allocate_target_description): Declare.
7618 (set_tdesc_architecture): Declare.
7619 (set_tdesc_osabi): Declare.
7620 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
7621 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
7622 include arch/i386.h.
7623 (i386_linux_read_description): Remove code and call
7624 i386_create_target_description.
7625 (set_tdesc_architecture): New function.
7626 (set_tdesc_osabi): New function.
7627 * target-descriptions.h (allocate_target_description): Remove.
7628
7629 2017-09-05 Yao Qi <yao.qi@linaro.org>
7630
7631 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
7632 * target-descriptions.c (tdesc_create_feature): Likewise, and
7633 adjust code.
7634 * features/i386/32bit-avx.c: Re-generated.
7635 * features/i386/32bit-avx512.c: Re-generated.
7636 * features/i386/32bit-core.c: Re-generated.
7637 * features/i386/32bit-linux.c: Re-generated.
7638 * features/i386/32bit-mpx.c: Re-generated.
7639 * features/i386/32bit-pkeys.c: Re-generated.
7640 * features/i386/32bit-sse.c: Re-generated.
7641
7642 2017-09-05 Yao Qi <yao.qi@linaro.org>
7643
7644 * regformats/regdef.h (struct reg): Override operator == and !=.
7645
7646 2017-09-05 Yao Qi <yao.qi@linaro.org>
7647
7648 * arch/tdesc.h: New file.
7649 * regformats/regdat.sh: Generate code using tdesc_create_reg.
7650 * target-descriptions.c: Update comments.
7651 * target-descriptions.h: Include "arch/tdesc.h". Remove the
7652 declarations.
7653 * features/i386/32bit-avx.c: Re-generated.
7654 * features/i386/32bit-avx512.c: Re-generated.
7655 * features/i386/32bit-core.c: Re-generated.
7656 * features/i386/32bit-linux.c: Re-generated.
7657 * features/i386/32bit-mpx.c: Re-generated.
7658 * features/i386/32bit-pkeys.c: Re-generated.
7659 * features/i386/32bit-sse.c: Re-generated.
7660
7661 2017-09-05 Yao Qi <yao.qi@linaro.org>
7662
7663 * regformats/regdat.sh: Update generated code.
7664
7665 2017-09-05 Yao Qi <yao.qi@linaro.org>
7666
7667 * regformats/regdat.sh: Adjust code order.
7668
7669 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
7670
7671 * expprint.c (dump_subexp_body_standard): Use constant format
7672 string in fprintf_filtered call.
7673
7674 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7675
7676 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
7677 NetBSD/i386.
7678 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
7679
7680 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7681
7682 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
7683
7684 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7685
7686 * bsd-kvm.o: Define _KMEMUSER.
7687 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
7688 * configure: Regenerate.
7689
7690 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7691
7692 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
7693 * i386-fbsd-nat.c: Likewise.
7694
7695 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7696
7697 * unittests/array-view-selftests.c: Add include of <array>.
7698
7699 2017-09-04 John Baldwin <jhb@FreeBSD.org>
7700
7701 * spu-tdep.c (flush_ea_cache): Add missing argument to
7702 call_function_by_hand.
7703
7704 2017-09-04 Pedro Alves <palves@redhat.com>
7705
7706 * NEWS (Safer support for debugging with no debug info): New.
7707
7708 2017-09-04 Pedro Alves <palves@redhat.com>
7709
7710 * c-exp.y (function_method, function_method_void): Add current
7711 instance flags to TYPE_INSTANCE.
7712 * dwarf2read.c (check_modifier): New.
7713 (compute_delayed_physnames): Assert that only C++ adds delayed
7714 physnames. Mark fn_fields as const/volatile depending on
7715 physname.
7716 * eval.c (make_params): New type_instance_flags parameter. Use
7717 it as the new type's instance flags.
7718 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
7719 flags element and pass it to make_params.
7720 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
7721 instance flags element.
7722 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
7723 * gdbtypes.h: Include "enum-flags.h".
7724 (type_instance_flags): New enum-flags type.
7725 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
7726 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
7727 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
7728 (follow_type_instance_flags): New function.
7729 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
7730 * parser-defs.h (follow_type_instance_flags): Declare.
7731 * valops.c (value_struct_elt_for_reference): const/volatile must
7732 match too.
7733
7734 2017-09-04 Pedro Alves <palves@redhat.com>
7735
7736 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
7737 function/method scopes; lookup the nested name as a function local
7738 static variable.
7739
7740 2017-09-04 Pedro Alves <palves@redhat.com>
7741
7742 (%type <voidval>): Add function_method.
7743 * c-exp.y (exp): New production for calls with no arguments.
7744 (function_method, function_method_void_or_typelist): New
7745 productions.
7746 (exp): New production for "method()::static_var".
7747 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
7748 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7749 Handle OP_FUNC_STATIC_VAR.
7750 * parse.c (operator_length_standard):
7751 Handle OP_FUNC_STATIC_VAR.
7752
7753 2017-09-04 Pedro Alves <palves@redhat.com>
7754
7755 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
7756 handling.
7757 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7758 Ditto.
7759 * parse.c (operator_length_standard, operator_check_standard):
7760 Ditto.
7761 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
7762
7763 2017-09-04 Pedro Alves <palves@redhat.com>
7764
7765 * ax-gdb.c: Include "typeprint.h".
7766 (gen_expr_for_cast): New function.
7767 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
7768 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
7769 type is unknown.
7770 * dwarf2read.c (new_symbol_full): Fallback to int instead of
7771 nodebug_data_symbol.
7772 * eval.c: Include "typeprint.h".
7773 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
7774 Error out if symbol has unknown type.
7775 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
7776 evaluate_subexp_for_cast.
7777 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
7778 OP_VAR_MSYM_VALUE.
7779 (evaluate_subexp_for_cast): New function.
7780 * gdbtypes.c (init_nodebug_var_type): New function.
7781 (objfile_type): Use it to initialize types of variables with no
7782 debug info.
7783 * typeprint.c (error_unknown_type): New.
7784 * typeprint.h (error_unknown_type): New declaration.
7785 * compile/compile-c-types.c (convert_type_basic): Handle
7786 TYPE_CODE_ERROR; warn and fallback to int for variables with
7787 unknown type.
7788
7789 2017-09-04 Pedro Alves <palves@redhat.com>
7790
7791 * eval.c (evaluate_var_value): New function, factored out from ...
7792 (evaluate_subexp_standard): ... here.
7793
7794 2017-09-04 Pedro Alves <palves@redhat.com>
7795
7796 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
7797 Remove useless assignments to 'op'.
7798
7799 2017-09-04 Pedro Alves <palves@redhat.com>
7800
7801 * eval.c (eval_skip_value): New function.
7802 (evaluate_subexp_standard): Use it.
7803
7804 2017-09-04 Pedro Alves <palves@redhat.com>
7805
7806 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
7807 function name from symbol/minsym and pass it to
7808 error_call_unknown_return_type.
7809
7810 2017-09-04 Pedro Alves <palves@redhat.com>
7811
7812 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
7813 * ax-gdb.c (gen_msym_var_ref): New function.
7814 (gen_expr): Handle OP_VAR_MSYM_VALUE.
7815 * eval.c (evaluate_var_msym_value): New function.
7816 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
7817 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
7818 to call_function_by_hand.
7819 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
7820 Handle OP_VAR_MSYM_VALUE.
7821 (union exp_element) <msymbol>: New field.
7822 * minsyms.h (struct type): Forward declare.
7823 (find_minsym_type_and_address): Declare.
7824 * parse.c (write_exp_elt_msym): New function.
7825 (write_exp_msymbol): Delete, refactored as ...
7826 (find_minsym_type_and_address): ... this new function.
7827 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
7828 (operator_length_standard, operator_check_standard): Handle
7829 OP_VAR_MSYM_VALUE.
7830 * std-operator.def (OP_VAR_MSYM_VALUE): New.
7831
7832 2017-09-04 Pedro Alves <palves@redhat.com>
7833
7834 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
7835 TYPE_GNU_IFUNC specially here. Throw error if return type is
7836 unknown.
7837 * ada-typeprint.c (print_func_type): Handle functions with unknown
7838 return type.
7839 * c-typeprint.c (c_type_print_base): Handle functions and methods
7840 with unknown return type.
7841 * compile/compile-c-symbols.c (convert_symbol_bmsym)
7842 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
7843 * compile/compile-c-types.c: Include "objfiles.h".
7844 (convert_func): For functions with unknown return type, warn and
7845 default to int.
7846 * compile/compile-object-run.c (compile_object_run): Adjust call
7847 to call_function_by_hand_dummy.
7848 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
7849 call_function_by_hand.
7850 * eval.c (evaluate_subexp_standard): Adjust calls to
7851 call_function_by_hand. Handle functions and methods with unknown
7852 return type. Pass expect_type to call_function_by_hand.
7853 * f-typeprint.c (f_type_print_base): Handle functions with unknown
7854 return type.
7855 * gcore.c (call_target_sbrk): Adjust call to
7856 call_function_by_hand.
7857 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
7858 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
7859 an integer address type instead of nodebug.
7860 * guile/scm-value.c (gdbscm_value_call): Adjust call to
7861 call_function_by_hand.
7862 * infcall.c (error_call_unknown_return_type): New function.
7863 (call_function_by_hand): New "default_return_type" parameter.
7864 Pass it down.
7865 (call_function_by_hand_dummy): New "default_return_type"
7866 parameter. Use it instead of defaulting to int. If there's no
7867 default and the return type is unknown, throw an error. If
7868 there's a default return type, and the called function has no
7869 debug info, then assume the function is prototyped.
7870 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
7871 New "default_return_type" parameter.
7872 (error_call_unknown_return_type): New declaration.
7873 * linux-fork.c (call_lseek): Cast return type of lseek.
7874 (inferior_call_waitpid, checkpoint_command): Adjust calls to
7875 call_function_by_hand.
7876 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
7877 calls to call_function_by_hand.
7878 * m2-typeprint.c (m2_procedure): Handle functions with unknown
7879 return type.
7880 * objc-lang.c (lookup_objc_class, lookup_child_selector)
7881 (value_nsstring, print_object_command): Adjust calls to
7882 call_function_by_hand.
7883 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
7884 functions with unknown return type.
7885 (pascal_type_print_func_varspec_suffix): New function.
7886 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
7887 TYPE_CODE_METHOD>: Use it.
7888 * python/py-value.c (valpy_call): Adjust call to
7889 call_function_by_hand.
7890 * rust-lang.c (rust_evaluate_funcall): Adjust call to
7891 call_function_by_hand.
7892 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
7893 call_function_by_hand.
7894 * valops.c (value_allocate_space_in_inferior): Adjust call to
7895 call_function_by_hand.
7896 * typeprint.c (type_print_unknown_return_type): New function.
7897 * typeprint.h (type_print_unknown_return_type): New declaration.
7898
7899 2017-09-04 Pedro Alves <palves@redhat.com>
7900
7901 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
7902 types with more than one parameter as prototyped.
7903
7904 2017-09-04 Pedro Alves <palves@redhat.com>
7905
7906 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
7907 (disassemble_command): Use gdb_disassembly_flags instead of bare
7908 int.
7909 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
7910 (dump_insns, do_mixed_source_and_assembly_deprecated)
7911 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
7912 Use gdb_disassembly_flags instead of bare int.
7913 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
7914 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
7915 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
7916 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
7917 (enum gdb_disassembly_flag): ... values of this new enumeration.
7918 (gdb_disassembly_flags): Define.
7919 (gdb_disassembly)
7920 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
7921 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
7922 gdb_disassembly_flags instead of bare int.
7923 * record-btrace.c (btrace_insn_history)
7924 (record_btrace_insn_history, record_btrace_insn_history_range)
7925 (record_btrace_insn_history_from): Use gdb_disassembly_flags
7926 instead of bare int.
7927 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
7928 Use gdb_disassembly_flags instead of bare int.
7929 * target-debug.h (target_debug_print_gdb_disassembly_flags):
7930 Define.
7931 * target-delegates.c: Regenerate.
7932 * target.c (target_insn_history, target_insn_history_from)
7933 (target_insn_history_range): Use gdb_disassembly_flags instead of
7934 bare int.
7935 * target.h: Include "disasm.h".
7936 (struct target_ops) <to_insn_history, to_insn_history_from,
7937 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
7938 int.
7939 (target_insn_history, target_insn_history_from)
7940 (target_insn_history_range): Use gdb_disassembly_flags instead of
7941 bare int.
7942
7943 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7944
7945 * cli/cli-script.c (build_command_line): For if/while commands,
7946 check whether args is empty.
7947
7948 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
7949
7950 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
7951 (enum command_control_type): Likewise.
7952 (struct command_line): Likewise.
7953 (free_command_lines): Likewise.
7954 (struct command_lines_deleter): Likewise.
7955 (command_line_up): Likewise.
7956 (read_command_lines): Likewise.
7957 (read_command_lines_1): Likewise.
7958 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
7959 (enum command_control_type): Likewise.
7960 (struct command_line): Likewise.
7961 (free_command_lines): Likewise.
7962 (struct command_lines_deleter): Likewise.
7963 (command_line_up): Likewise.
7964 (read_command_lines): Likewise.
7965 (read_command_lines_1): Likewise.
7966 * breakpoint.h: Include cli/cli-script.h.
7967 * extension-priv.h: Likewise.
7968 * gdbcmd.h: Likewise.
7969
7970 2017-09-04 Pedro Alves <palves@redhat.com>
7971
7972 * ada-lang.c (is_known_support_routine): Move sal declaration to
7973 where it is initialized.
7974 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
7975 (parse_breakpoint_sals, decode_static_tracepoint_spec)
7976 (clear_command, update_static_tracepoint): Remove init_sal
7977 references. Move declarations closer to initializations.
7978 * cli/cli-cmds.c (list_command): Move sal declarations closer to
7979 initializations.
7980 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
7981 references. Move sal declarations closer to initializations.
7982 * frame.c (find_frame_sal): Return a symtab_and_line via function
7983 return instead of output parameter. Remove init_sal references.
7984 * frame.h (find_frame_sal): Return a symtab_and_line via function
7985 return instead of output parameter.
7986 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
7987 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
7988 instead of memset.
7989 (gdbscm_find_pc_line): Remove init_sal reference.
7990 * infcall.c (call_function_by_hand_dummy): Remove init_sal
7991 references. Move declarations closer to initializations.
7992 * infcmd.c (set_step_frame): Update. Move declarations closer to
7993 initializations.
7994 (finish_backward): Remove init_sal references. Move declarations
7995 closer to initializations.
7996 * infrun.c (process_event_stop_test, handle_step_into_function)
7997 (insert_hp_step_resume_breakpoint_at_frame)
7998 (insert_step_resume_breakpoint_at_caller): Likewise.
7999 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
8000 (symbol_to_sal): Likewise.
8001 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
8002 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
8003 to its initialization.
8004 * reverse.c (save_bookmark_command): Use new/delete. Remove
8005 init_sal references. Move declarations closer to initializations.
8006 * source.c (get_current_source_symtab_and_line): Remove brace
8007 initialization.
8008 (set_current_source_symtab_and_line): Now takes the sal by const
8009 reference. Remove brace initialization.
8010 (line_info): Remove init_sal reference.
8011 * source.h (set_current_source_symtab_and_line): Now takes a
8012 symtab_and_line via const reference.
8013 * stack.c (set_current_sal_from_frame): Adjust.
8014 (print_frame_info): Adjust.
8015 (get_last_displayed_sal): Return the sal via function return
8016 instead of via output parameter. Simplify.
8017 (frame_info): Adjust.
8018 * stack.h (get_last_displayed_sal): Return the sal via function
8019 return instead of via output parameter.
8020 * symtab.c (init_sal): Delete.
8021 (find_pc_sect_line): Remove init_sal references. Move
8022 declarations closer to initializations.
8023 (find_function_start_sal): Remove init_sal references. Move
8024 declarations closer to initializations.
8025 * symtab.h (struct symtab_and_line): In-class initialize all
8026 fields.
8027 * tracepoint.c (set_traceframe_context)
8028 (print_one_static_tracepoint_marker): Remove init_sal references.
8029 Move declarations closer to initializations.
8030 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
8031 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
8032 declarations closer to initializations.
8033 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
8034 init_sal references. Adjust.
8035
8036 2017-09-04 Pedro Alves <palves@redhat.com>
8037
8038 * ax-gdb.c (agent_command_1): Use range-for.
8039 * break-catch-throw.c (re_set_exception_catchpoint): Update.
8040 * breakpoint.c: Include "common/array-view.h".
8041 (init_breakpoint_sal, create_breakpoint_sal): Change sals
8042 parameter from struct symtabs_and_lines to
8043 array_view<symtab_and_line>. Adjust. Use range-for. Update.
8044 (breakpoint_sals_to_pc): Change sals parameter from struct
8045 symtabs_and_lines to std::vector reference.
8046 (check_fast_tracepoint_sals): Change sals parameter from struct
8047 symtabs_and_lines to std::array_view. Use range-for.
8048 (decode_static_tracepoint_spec): Return a std::vector instead of
8049 symtabs_and_lines. Update.
8050 (create_breakpoint): Update.
8051 (break_range_command, until_break_command, clear_command): Update.
8052 (base_breakpoint_decode_location, bkpt_decode_location)
8053 (bkpt_probe_create_sals_from_location)
8054 (bkpt_probe_decode_location, tracepoint_decode_location)
8055 (tracepoint_probe_decode_location)
8056 (strace_marker_create_sals_from_location): Return a std::vector
8057 instead of symtabs_and_lines.
8058 (strace_marker_create_breakpoints_sal): Update.
8059 (strace_marker_decode_location): Return a std::vector instead of
8060 symtabs_and_lines. Update.
8061 (update_breakpoint_locations): Change struct symtabs_and_lines
8062 parameters to gdb::array_view. Adjust.
8063 (location_to_sals): Return a std::vector instead of
8064 symtabs_and_lines. Update.
8065 (breakpoint_re_set_default): Use std::vector instead of struct
8066 symtabs_and_lines.
8067 (decode_location_default): Return a std::vector instead of
8068 symtabs_and_lines. Update.
8069 * breakpoint.h: Include "common/array-view.h".
8070 (struct breakpoint_ops) <decode_location>: Now returns a
8071 std::vector instead of returning a symtabs_and_lines via output
8072 parameter.
8073 (update_breakpoint_locations): Change sals parameters to use
8074 gdb::array_view.
8075 * cli/cli-cmds.c (edit_command, list_command): Update to use
8076 std::vector and gdb::array_view.
8077 (ambiguous_line_spec): Adjust to use gdb::array_view and
8078 range-for.
8079 (compare_symtabs): Rename to ...
8080 (cmp_symtabs): ... this. Change parameters to symtab_and_line
8081 const reference and adjust.
8082 (filter_sals): Rewrite using std::vector and standard algorithms.
8083 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
8084 (jump_command): Update to use std::vector.
8085 * linespec.c (struct linespec_state) <canonical_names>: Update
8086 comment.
8087 (add_sal_to_sals_basic): Delete.
8088 (add_sal_to_sals, filter_results, convert_results_to_lsals)
8089 (decode_line_2, create_sals_line_offset)
8090 (convert_address_location_to_sals, convert_linespec_to_sals)
8091 (convert_explicit_location_to_sals, parse_linespec)
8092 (event_location_to_sals, decode_line_full, decode_line_1)
8093 (decode_line_with_current_source)
8094 (decode_line_with_last_displayed, decode_objc)
8095 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
8096 (linespec_result::~linespec_result): Adjust to use std::vector
8097 instead of symtabs_and_lines.
8098 * linespec.h (linespec_sals::sals): Now a std::vector.
8099 (struct linespec_result): Use std::vector, bool, and in-class
8100 initialization.
8101 (decode_line_1, decode_line_with_current_source)
8102 (decode_line_with_last_displayed): Return std::vector.
8103 * macrocmd.c (info_macros_command): Use std::vector.
8104 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
8105 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
8106 std::vector.
8107 * probe.h (parse_probes): Return a std::vector.
8108 * python/python.c (gdbpy_decode_line): Use std::vector and
8109 gdb::array_view.
8110 * source.c (select_source_symtab, line_info): Use std::vector.
8111 * stack.c (func_command): Use std::vector.
8112 * symtab.h (struct symtabs_and_lines): Delete.
8113 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
8114
8115 2017-09-04 Pedro Alves <palves@redhat.com>
8116
8117 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8118 unittests/array-view-selftests.c.
8119 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
8120 * common/array-view.h: New file.
8121 * unittests/array-view-selftests.c: New file.
8122
8123 2017-09-04 Pedro Alves <palves@redhat.com>
8124
8125 * cli/cli-cmds.c (edit_command): Pass message to
8126 ambiguous_line_spec.
8127 (list_command): Pass message to ambiguous_line_spec. Say
8128 "first"/"last" instead of "start" and "end" to be consistent with
8129 the manual.
8130 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
8131 them to print formatted message.
8132
8133 2017-09-04 Pedro Alves <palves@redhat.com>
8134
8135 * btrace.c (ftrace_add_pt): Pass btrace_insn to
8136 ftrace_update_insns by reference instead of pointer.
8137
8138 2017-09-04 Yao Qi <yao.qi@linaro.org>
8139
8140 * i386-go32-tdep.c: Include x86-xstate.h.
8141 (i386_go32_init_abi): Call i386_target_description.
8142 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
8143 if xcr0 is X86_XSTATE_X87_MASK.
8144 * i386-tdep.h (tdesc_i386): Remove the declaration.
8145 (tdesc_i386_mmx): Likewise.
8146
8147 2017-09-04 Yao Qi <yao.qi@linaro.org>
8148
8149 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
8150 X86_XSTATE_SSE_MASK instead of 0.
8151
8152 2017-09-04 Yao Qi <yao.qi@linaro.org>
8153
8154 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
8155 i386_target_description.
8156 * i386-fbsd-nat.c (i386fbsd_read_description): Call
8157 i386_target_description.
8158 * i386-tdep.c (i386_gdbarch_init): Likewise.
8159
8160 2017-09-04 Yao Qi <yao.qi@linaro.org>
8161
8162 * amd64-darwin-tdep.c: Include "x86-xstate.h".
8163 (x86_darwin_init_abi_64): Call amd64_target_description.
8164 * amd64-dicos-tdep.c: Likewise.
8165 * amd64-fbsd-nat.c: Likewise.
8166 * amd64-fbsd-tdep.c: Likewise.
8167 * amd64-nbsd-tdep.c: Likewise.
8168 * amd64-obsd-tdep.c: Likewise.
8169 * amd64-sol2-tdep.c: Likewise.
8170 * amd64-windows-tdep.c: Likewise.
8171 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
8172
8173 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
8174
8175 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
8176 (btrace_function) <insn>: Change type to use std::vector.
8177 * btrace.c (ftrace_debug, ftrace_call_num_insn,
8178 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
8179 ftrace_update_insns, ftrace_compute_global_level_offset,
8180 btrace_stitch_bts, btrace_clear, btrace_insn_get,
8181 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
8182 change to std::vector.
8183 (ftrace_update_insns): Adjust to change to std::vector, change
8184 type of INSN parameter.
8185 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
8186 * record-btrace.c (btrace_call_history_insn_range,
8187 btrace_compute_src_line_range,
8188 record_btrace_frame_prev_register): Adjust to change to
8189 std::vector.
8190 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
8191 to change to std::vector.
8192
8193 2017-09-03 Tom Tromey <tom@tromey.com>
8194
8195 * corefile.c (reopen_exec_file): Use std::string.
8196
8197 2017-09-03 Tom Tromey <tom@tromey.com>
8198
8199 * compile/compile.c (compile_register_name_mangled): Return
8200 std::string.
8201 * compile/compile-loc2c.c (pushf_register_address): Update.
8202 (pushf_register): Update.
8203 * compile/compile-c-types.c (convert_array): Update.
8204 * compile/compile-c-symbols.c (generate_vla_size): Update.
8205 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
8206 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
8207 (convert_one_symbol): Update.
8208 (generate_c_for_for_one_variable): Update.
8209 * compile/compile-c-support.c (c_get_range_decl_name): Return a
8210 std::string.
8211 (generate_register_struct): Update.
8212 * compile/compile-internal.h (c_get_range_decl_name): Return a
8213 std::string.
8214 (compile_register_name_mangled): Return std::string.
8215
8216 2017-09-03 Tom Tromey <tom@tromey.com>
8217
8218 * utils.c (perror_string): Return a std::string.
8219 (throw_perror_with_name, perror_warning_with_name): Update.
8220
8221 2017-09-03 Tom Tromey <tom@tromey.com>
8222
8223 * demangle.c (demangle_command): Use std::string,
8224 unique_xmalloc_ptr.
8225
8226 2017-09-03 Tom Tromey <tom@tromey.com>
8227
8228 * cli/cli-setshow.c (do_set_command): Use std::string.
8229
8230 2017-09-03 Tom Tromey <tom@tromey.com>
8231
8232 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
8233
8234 2017-09-03 Tom Tromey <tom@tromey.com>
8235
8236 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
8237
8238 2017-09-03 Tom Tromey <tom@tromey.com>
8239
8240 * mi/mi-cmd-env.c (env_execute_cli_command): Use
8241 gdb::unique_xmalloc_ptr.
8242
8243 2017-09-03 Tom Tromey <tom@tromey.com>
8244
8245 * thread.c (print_thread_info_1): Use string_printf.
8246 (thread_apply_command, thread_apply_all_command): Use
8247 std::string.
8248
8249 2017-09-03 Tom Tromey <tom@tromey.com>
8250
8251 * valprint.c (val_print_string): Update.
8252 * gdbcore.h (memory_error_message): Return std::string.
8253 * corefile.c (memory_error_message): Return std::string.
8254 (memory_error): Update.
8255 * breakpoint.c (insert_bp_location): Update.
8256
8257 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
8258
8259 * target/waitstatus.h (target_waitstatus_to_string): Change
8260 return type to std::string.
8261 * target/waitstatus.c (target_waitstatus_to_string): Return
8262 std::string.
8263 * target.h (target_waitstatus_to_string): Remove declaration.
8264 * infrun.c (resume, clear_proceed_status_thread,
8265 print_target_wait_results, do_target_wait, save_waitstatus,
8266 stop_all_threads): Adjust.
8267 * record-btrace.c (record_btrace_wait): Adjust.
8268 * target-debug.h
8269 (target_debug_print_struct_target_waitstatus_p): Adjust.
8270
8271 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
8272
8273 PR gdb/22046
8274 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
8275 detection.
8276
8277 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
8278
8279 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
8280 for setting/unsetting environment variables on the remote target.
8281 (New remote packets): Add entries for QEnvironmentHexEncoded,
8282 QEnvironmentUnset and QEnvironmentReset.
8283 * common/environ.c (gdb_environ::operator=): Extend method to
8284 handle m_user_set_env_list and m_user_unset_env_list.
8285 (gdb_environ::clear): Likewise.
8286 (match_var_in_string): Change type of first parameter from 'char
8287 *' to 'const char *'.
8288 (gdb_environ::set): Extend method to handle
8289 m_user_set_env_list and m_user_unset_env_list.
8290 (gdb_environ::unset): Likewise.
8291 (gdb_environ::clear_user_set_env): New method.
8292 (gdb_environ::user_set_envp): Likewise.
8293 (gdb_environ::user_unset_envp): Likewise.
8294 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
8295 m_user_unset_env_list on move constructor/assignment.
8296 (unset): Add new default parameter 'update_unset_list = true'.
8297 (clear_user_set_env): New method.
8298 (user_set_envp): Likewise.
8299 (user_unset_envp): Likewise.
8300 (m_user_set_env_list): New std::set.
8301 (m_user_unset_env_list): Likewise.
8302 * common/rsp-low.c (hex2str): New function.
8303 (bin2hex): New overload for bin2hex function.
8304 * common/rsp-low.c (hex2str): New prototype.
8305 (str2hex): New overload prototype.
8306 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
8307 QEnvironmentUnset and QEnvironmentReset.
8308 (remote_protocol_features): Add QEnvironmentHexEncoded,
8309 QEnvironmentUnset and QEnvironmentReset packets.
8310 (send_environment_packet): New function.
8311 (extended_remote_environment_support): Likewise.
8312 (extended_remote_create_inferior): Call
8313 extended_remote_environment_support.
8314 (_initialize_remote): Add QEnvironmentHexEncoded,
8315 QEnvironmentUnset and QEnvironmentReset packet configs.
8316 * unittests/environ-selftests.c (gdb_selftest_env_var):
8317 New variable.
8318 (test_vector_initialization): New function.
8319 (test_init_from_host_environ): Likewise.
8320 (test_reinit_from_host_environ): Likewise.
8321 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
8322 Likewise.
8323 (test_unset_set_empty_vector): Likewise.
8324 (test_vector_clear): Likewise.
8325 (test_std_move): Likewise.
8326 (test_move_constructor):
8327 (test_self_move): Likewise.
8328 (test_set_unset_reset): Likewise.
8329 (run_tests): Rewrite in terms of the functions above.
8330
8331 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
8332
8333 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
8334 (adi_available): Use a temp variable of type CORE_ADDR as argument
8335 3 when calling target_auxv_search.
8336 (adi_normalize_address): Use masks and xor operators to calculate
8337 normalized address.
8338 (adi_read_versions, adi_write_versions, adi_print_versions)
8339 (do_examine, do_assign): Use paddress.
8340
8341 2017-08-29 John Baldwin <jhb@FreeBSD.org>
8342
8343 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
8344 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
8345 out of loop and add supply of FIR.
8346 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
8347 add collect of FIR.
8348
8349 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
8350
8351 PR gdb/21827
8352 * cli/cli-script.c (define_command): Don't convert command name
8353 to lower case.
8354
8355 2017-08-25 Joel Brobecker <brobecker@adacore.com>
8356
8357 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
8358 Update all callers accordingly. Remove all code blocks handling
8359 the case where DISPP is not NULL.
8360
8361 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8362
8363 PR symtab/22003
8364 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
8365 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
8366 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
8367
8368 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
8369
8370 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
8371 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
8372 (read_comp_units_from_section): New parameter abbrev_section, use
8373 read_and_check_comp_unit_head, allocate signatured_type if needed.
8374 (create_all_comp_units): Update read_comp_units_from_section caller.
8375
8376 2017-08-23 Pedro Alves <palves@redhat.com>
8377
8378 PR remote/21852
8379 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
8380 to null_ptid and switch to thread without reading the registers
8381 after adding the inferior.
8382
8383 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8384
8385 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
8386 compile-gcc.
8387 * compile/compile.c (compile_gcc, show_compile_gcc): New.
8388 (compile_to_object): Implement compile_gcc.
8389 (_initialize_compile): Install "set compile-gcc". Initialize
8390 compile_gcc.
8391
8392 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
8393
8394 * compile/compile.c (compile_to_object): Conditionally call
8395 set_verbose. Conditionally call compile or compile_v0.
8396
8397 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
8398
8399 * sparc64-tdep.h: (adi_normalize_address): New export.
8400 * sparc-nat.h: (open_adi_tag_fd): New export.
8401 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
8402 * sparc64-linux-tdep.c:
8403 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
8404 (sparc64_linux_handle_segmentation_fault): New function.
8405 (sparc64_linux_init_abi): Register
8406 sparc64_linux_handle_segmentation_fault
8407 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
8408 (sparc64_addr_bits_remove): New function.
8409 (sparc64_init_abi): Register sparc64_addr_bits_remove.
8410 (MAX_PROC_NAME_SIZE): New macro.
8411 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
8412 (sparc64adilist): New variable.
8413 (adi_proc_list): New variable.
8414 (find_adi_info): New function.
8415 (add_adi_info): New function.
8416 (get_adi_info_proc): New function.
8417 (get_adi_info): New function.
8418 (info_adi_command): New function.
8419 (read_maps_entry): New function.
8420 (adi_available): New function.
8421 (adi_normalize_address): New function.
8422 (adi_align_address): New function.
8423 (adi_convert_byte_count): New function.
8424 (adi_tag_fd): New function.
8425 (adi_is_addr_mapped): New function.
8426 (adi_read_versions): New function.
8427 (adi_write_versions): New function.
8428 (adi_print_versions): New function.
8429 (do_examine): New function.
8430 (do_assign): New function.
8431 (adi_examine_command): New function.
8432 (adi_assign_command): New function.
8433 (_initialize_sparc64_adi_tdep): New function.
8434
8435 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
8436
8437 * breakpoint.c (breakpoints_info): Rename to ...
8438 (info_breakpoints_command): ... this.
8439 (watchpoints_info): Rename to ...
8440 (info_watchpoints_command): ... this.
8441 (tracepoints_info): Rename to ...
8442 (info_tracepoints_command): ... this.
8443 (_initialize_breakpoint): Adjust.
8444 * dcache.c (dcache_info): Rename to ...
8445 (info_display_command): ... this.
8446 (_initialize_dcache): Adjust.
8447 * frame.h (args_info): Rename to ...
8448 (info_args_command): ... this.
8449 (locals_info): Rename to ...
8450 (info_locals_command): ... this.
8451 * infcmd.c (nofp_registers_info): Rename to ...
8452 (info_registers_command): ... this.
8453 (float_info): Rename to ...
8454 (info_float_command): ... this.
8455 (program_info): Rename to ...
8456 (info_program_command): ... this.
8457 (all_registers_info): Rename to ...
8458 (info_all_registers_command): ... this.
8459 (vector_info): Rename to ...
8460 (info_vector_command): ... this.
8461 (float_info): Rename to ...
8462 (info_float_command): ... this.
8463 (_initialize_infcmd): Adjust.
8464 * inferior.h (term_info): Rename to ...
8465 (info_terminal_command): ... this.
8466 * inflow.c (term_info): Rename to ...
8467 (info_terminal_command): ... this.
8468 (_initialize_inflow): Adjust.
8469 * infrun.c (signals_info): Rename to ...
8470 (info_signals_command): ... this.
8471 (_initialize_infrun): Adjust.
8472 * objc-lang.c (classes_info): Rename to ...
8473 (info_classes_command): ... this.
8474 (selectors_info): Rename to ...
8475 (info_selectors_command): ... this.
8476 (_initialize_objc_language): Adjust.
8477 * printcmd.c (sym_info): Rename to ...
8478 (info_symbol_command): ... this.
8479 (address_info): Rename to ...
8480 (info_address_command): ... this.
8481 (display_info): Rename to ...
8482 (info_display_command): ... this.
8483 (_initialize_printcmd): Adjust.
8484 * reverse.c (bookmarks_info): Rename to ...
8485 (info_breakpoints_command): ... this.
8486 (_initialize_reverse): Adjust.
8487 * ser-go32.c (dos_info): Rename to ...
8488 (info_serial_command): ... this.
8489 (_initialize_ser_dos): Adjust.
8490 * skip.c (skip_info): Rename to ...
8491 (info_skip_command): ... this.
8492 (_initialize_step_skip): Adjust.
8493 * source.c (line_info): Rename to ...
8494 (info_line_command): ... this.
8495 (source_info): Rename to ...
8496 (info_source_command)
8497 * stack.c (frame_info): Rename to ...
8498 (info_frame_command): ... this.
8499 (locals_info): Rename to ...
8500 (info_locals_command): ... this.
8501 (args_info): Rename to ...
8502 (info_args_command): ... this.
8503 (_initialize_stack): Adjust.
8504 * symtab.c (sources_info): Rename to ...
8505 (info_sources_command): ... this.
8506 (variables_info): Rename to ...
8507 (info_variables_command): ... this.
8508 (functions_info): Rename to ...
8509 (info_functions_command): ... this.
8510 (types_info): Rename to ...
8511 (info_types_command): ... this.
8512 (_initialize_symtab): Adjust.
8513 * target.c (target_info): Rename to ...
8514 (info_target_command): ... this.
8515 (initialize_targets): Adjust.
8516 * tracepoint.c (tvariables_info): Rename to ...
8517 (info_tvariables_command): ... this.
8518 (scope_info): Rename to ...
8519 (info_scope_command): ... this.
8520 (trace_dump_actions): Adjust.
8521 (_initialize_tracepoint): Adjust.
8522
8523 2017-08-22 Tom Tromey <tom@tromey.com>
8524
8525 * breakpoint.h (install_breakpoint): Update.
8526 * breakpoint.c (add_solib_catchpoint): Update.
8527 (install_breakpoint): Change argument to a std::unique_ptr.
8528 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
8529 (create_breakpoint_sal, create_breakpoint): Update.
8530 (watch_command_1, catch_exec_command_1)
8531 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
8532 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
8533 Return the breakpoint.
8534 (set_raw_breakpoint_without_location, set_raw_breakpoint)
8535 (new_single_step_breakpoint): Update.
8536 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
8537 std::unique_ptr.
8538 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8539 std::unique_ptr.
8540 * break-catch-sig.c (create_signal_catchpoint): Use
8541 std::unique_ptr.
8542 * ada-lang.c (create_ada_exception_catchpoint): Use
8543 std::unique_ptr.
8544
8545 2017-08-22 Tom Tromey <tom@tromey.com>
8546
8547 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
8548
8549 2017-08-22 Tom Tromey <tom@tromey.com>
8550
8551 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
8552 (lookup_partial_symbol): Update.
8553
8554 2017-08-22 Tom Tromey <tom@tromey.com>
8555
8556 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
8557 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
8558 (find_and_open_source, symtab_to_fullname): Update.
8559 * psymtab.c (psymtab_to_fullname): Update.
8560
8561 2017-08-22 Tom Tromey <tom@tromey.com>
8562
8563 * exec.c (exec_file_attach): Update.
8564 * linux-thread-db.c (try_thread_db_load): Update.
8565 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
8566 * utils.c (gdb_realpath): Change return type.
8567 (gdb_realpath_keepfile): Update.
8568 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
8569 (_initialize_utils): Register the new self test.
8570 * source.c (openp): Update.
8571 (find_and_open_source): Update.
8572 * nto-tdep.c (nto_find_and_open_solib): Update.
8573 * main.c (set_gdb_data_directory): Update.
8574 (captured_main_1): Update.
8575 * dwarf2read.c (dwarf2_get_dwz_file): Update
8576 (dw2_map_symbol_filenames): Update.
8577 * auto-load.c (auto_load_safe_path_vec_update): Update.
8578 (filename_is_in_auto_load_safe_path_vec): Change type of
8579 "filename_realp".
8580 (auto_load_objfile_script): Update.
8581 (file_is_auto_load_safe): Update. Use std::string.
8582 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
8583
8584 2017-08-22 Tom Tromey <tom@tromey.com>
8585
8586 * utils.c (gdb_realpath_keepfile): Return a
8587 gdb::unique_xmalloc_ptr.
8588 * exec.c (exec_file_attach): Update.
8589 * utils.h (gdb_realpath_keepfile): Return a
8590 gdb::unique_xmalloc_ptr.
8591
8592 2017-08-22 Tom Tromey <tom@tromey.com>
8593
8594 * compile/compile.c (compile_file_command): Use
8595 gdb::unique_xmalloc_ptr, std::string.
8596 * utils.c (gdb_abspath): Change return type.
8597 * source.c (openp): Update.
8598 * objfiles.c (allocate_objfile): Update.
8599 * main.c (set_gdb_data_directory): Update.
8600 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
8601
8602 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
8603
8604 * cli-cmds.c (list_commands): List actual code around more than
8605 one location.
8606
8607 2017-08-21 John Baldwin <jhb@FreeBSD.org>
8608
8609 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
8610
8611 2017-08-21 Pedro Alves <palves@redhat.com>
8612
8613 PR gdb/19487
8614 * c-exp.y (variable production): Handle function aliases.
8615 * minsyms.c (msymbol_is_text): New function.
8616 * minsyms.h (msymbol_is_text): Declare.
8617 * symtab.c (find_function_alias_target): New function.
8618 * symtab.h (find_function_alias_target): Declare.
8619
8620 2017-08-21 Pedro Alves <palves@redhat.com>
8621
8622 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
8623 typedefs.
8624 * typeprint.c (whatis_exp): If handling "whatis", and expression
8625 is OP_TYPE, strip one typedef level. Otherwise don't strip
8626 typedefs here.
8627 * valops.c (value_cast): Save "to" type before resolving
8628 stubs/typedefs. Use that type as resulting value's type.
8629
8630 2017-08-18 Tom Tromey <tom@tromey.com>
8631 Pedro Alves <palves@redhat.com>
8632
8633 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
8634 * sol-thread.c (sol_thread_resume, sol_thread_wait)
8635 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
8636 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
8637 * proc-service.c (ps_xfer_memory): Use scoped_restore.
8638 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
8639 (linux_get_siginfo_data): Add "thread" argument. Use
8640 scoped_restore.
8641 * linux-nat.c (linux_child_follow_fork)
8642 (check_stopped_by_watchpoint): Use scoped_restore.
8643 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
8644 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
8645 (restore_inferior_ptid, save_inferior_ptid): Remove.
8646 * btrace.c (btrace_fetch): Use scoped_restore.
8647 * bsd-uthread.c (bsd_uthread_fetch_registers)
8648 (bsd_uthread_store_registers): Use scoped_restore.
8649 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
8650 scoped_restore.
8651 * aix-thread.c (aix_thread_resume, aix_thread_wait)
8652 (aix_thread_xfer_partial): Use scoped_restore.
8653 * inferior.h (save_inferior_ptid): Remove.
8654
8655 2017-08-18 Yao Qi <yao.qi@linaro.org>
8656
8657 PR tdep/21818
8658 * arm-tdep.c (gdb_print_insn_arm): Mark
8659 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
8660
8661 2017-08-18 Yao Qi <yao.qi@linaro.org>
8662
8663 * NEWS: Mention GDBserver's new option "--selftest".
8664 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
8665 * selftest.c: Move it to common/selftest.c.
8666 * selftest.h: Move it to common/selftest.h.
8667 * selftest-arch.c (reset): New function.
8668 (tests_with_arch): Call reset.
8669
8670 2017-08-18 Yao Qi <yao.qi@linaro.org>
8671
8672 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
8673 instead of exception_fprintf and printf_filtered.
8674
8675 2017-08-18 Yao Qi <yao.qi@linaro.org>
8676
8677 * selftest.c (register_self_test): Rename it to
8678 selftests::register_test.
8679 (run_self_tests): selftest::run_tests.
8680 * selftest.h: Update declarations.
8681 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
8682 selftests::register_test_foreach_arch.
8683 * selftest-arch.h: Update declaration.
8684 * aarch64-tdep.c: Update.
8685 * arm-tdep.c: Likewise.
8686 * disasm-selftests.c: Likewise.
8687 * dwarf2loc.c: Likewise.
8688 * dwarf2-frame.c: Likewise.
8689 * findvar.c: Likewise.
8690 * gdbarch-selftests.c: Likewise.
8691 * maint.c (maintenance_selftest): Likewise.
8692 * regcache.c: Likewise.
8693 * rust-exp.y: Likewise.
8694 * selftest-arch.c: Likewise.
8695 * unittests/environ-selftests.c: Likewise.
8696 * unittests/function-view-selftests.c: Likewise.
8697 * unittests/offset-type-selftests.c: Likewise.
8698 * unittests/optional-selftests.c: Likewise.
8699 * unittests/scoped_restore-selftests.c: Likewise.
8700 * utils-selftests.c: Likewise.
8701
8702 2017-08-17 Pedro Alves <palves@redhat.com>
8703
8704 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
8705 local.
8706
8707 2017-08-17 Pedro Alves <palves@redhat.com>
8708
8709 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
8710 field.
8711 (reset_die_in_process): Delete, replaced by ...
8712 (process_die_scope): ... this new class. Make it responsible for
8713 freeing cu->line_header too.
8714 (process_die): Use process_die_scope.
8715 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
8716 cu->line_header_die_owner. Don't release the line header if it's
8717 owned by the CU.
8718 (setup_type_unit_groups): Make the CU/DIE own the line header.
8719 Don't release the line header here.
8720
8721 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
8722
8723 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
8724
8725 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
8726
8727 * NEWS: Mention new shortcuts for nexti and stepi in TUI
8728 Single-Key mode
8729
8730 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
8731
8732 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
8733 mode command list.
8734
8735 2017-08-15 Stafford Horne <shorne@gmail.com>
8736
8737 * MAINTAINERS (Write After Approval): Add Stafford Horne.
8738
8739 2017-08-15 Stafford Horne <shorne@gmail.com>
8740
8741 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
8742
8743 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
8744
8745 PR gdb/21954
8746 * infcmd.c (unset_environment_command): Use the 'clear' method on
8747 the environment instead of resetting it.
8748
8749 2017-08-15 John Baldwin <jhb@FreeBSD.org>
8750
8751 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
8752 platforms.
8753
8754 2017-08-14 Tom Tromey <tom@tromey.com>
8755
8756 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
8757 (print_binary_chars): Likewise.
8758 (BITS_IN_BYTES): Remove.
8759
8760 2017-08-14 Tom Tromey <tom@tromey.com>
8761
8762 PR gdb/21675
8763 * valprint.c (LOW_ZERO): Change value to 034.
8764 (print_octal_chars): Add static_asserts for octal constants.
8765 * printcmd.c (print_scalar_formatted): Add 'd' case.
8766
8767 2017-08-11 Tom Tromey <tom@tromey.com>
8768
8769 * symfile.c (add_symbol_file_command): Use std::vector.
8770
8771 2017-08-14 Tom Tromey <tom@tromey.com>
8772
8773 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
8774 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
8775 std::move.
8776 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
8777
8778 2017-08-11 Pedro Alves <palves@redhat.com>
8779
8780 * infrun.c (process_event_stop_test): Adjust
8781 function_name_is_marked_for_skip call.
8782 * skip.c: Include <list>.
8783 (skiplist_entry): Make it a class with private fields, and
8784 getters/setters.
8785 (skiplist_entry_chain): Delete.
8786 (skiplist_entries): New.
8787 (skiplist_entry_count): Delete.
8788 (highest_skiplist_entry_num): New.
8789 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
8790 (add_skiplist_entry): Delete.
8791 (skiplist_entry::skiplist_entry): New.
8792 (skiplist_entry::add_entry): New.
8793 (skip_file_command, skip_function): Adjust.
8794 (compile_skip_regexp): Delete.
8795 (skip_command): Don't compile regexp here. Adjust to use
8796 skiplist_entry::add_entry.
8797 (skip_info): Adjust to use range-for and getters.
8798 (skip_enable_command, skip_disable_command): Adjust to use
8799 range-for and setters.
8800 (skip_delete_command): Adjust to use std::list.
8801 (add_skiplist_entry): Delete.
8802 (skip_file_p): Delete, refactored as ...
8803 (skiplist_entry::do_skip_file_p): ... this new method.
8804 (skip_gfile_p): Delete, refactored as ...
8805 (skiplist_entry::do_gskip_file_p): ... this new method.
8806 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
8807 (skiplist_entry::skip_function_p): ... this new method.
8808 (function_name_is_marked_for_skip): Now returns bool, and takes
8809 the function sal by const reference. Adjust to use range-for and
8810 skiplist_entry methods.
8811 (_initialize_step_skip): Remove references to
8812 skiplist_entry_chain, skiplist_entry_count.
8813 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
8814 takes the function sal by const reference.
8815
8816 2017-08-11 Yao Qi <yao.qi@linaro.org>
8817
8818 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
8819 (dwarf2_frame_cache): Remove reset_cache_cleanup.
8820 (dwarf2_frame_cache):
8821 * frame-unwind.c (frame_unwind_try_unwinder): Catch
8822 RETURN_MASK_ALL and set *this_case to NULL.
8823 * frame-unwind.h: Update comments.
8824
8825 2017-08-11 Yao Qi <yao.qi@linaro.org>
8826
8827 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
8828 (dwarf2_frame_state_copy_regs): Remove.
8829 (dwarf2_frame_state_free_regs): Remove.
8830 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
8831 (dwarf2_restore_rule): Call method .alloc_regs instead of
8832 dwarf2_frame_state_alloc_regs.
8833 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
8834 constructor. Call std::move.
8835 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
8836 (dwarf2_frame_cache): Likewise.
8837
8838 [GDB_SELF_TEST]: Include selftest.h and
8839 selftest-arch.h.
8840 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
8841 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
8842 execute_cfa_program_test.
8843
8844 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
8845 copy ctor, assignment operator, move assignment.
8846 <alloc_regs>: New method.
8847 <swap>: New method.
8848 (struct dwarf2_frame_state): Delete dtor.
8849 (dwarf2_frame_state_alloc_regs): Remove declaration.
8850 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
8851 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
8852
8853 2017-08-11 Yao Qi <yao.qi@linaro.org>
8854
8855 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
8856 (dwarf2_frame_state::dwarf2_frame_state): New.
8857 (dwarf2_frame_state::~dwarf2_frame_state): New.
8858 (dwarf2_fetch_cfa_info): Update.
8859 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
8860 rather than a pointer. Update code.
8861 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
8862 dtor.
8863 <data_align, code_align, retaddr_column>: Change them to const.
8864 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
8865 to bool.
8866
8867 2017-08-11 Yao Qi <yao.qi@linaro.org>
8868
8869 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
8870 <loc.exp>: New field.
8871 * dwarf2-frame.c (execute_cfa_program): Update.
8872 (dwarf2_frame_prev_register): Update.
8873
8874 2017-08-10 Pedro Alves <palves@redhat.com>
8875
8876 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
8877
8878 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8879
8880 * fbsd-nat.c (struct fbsd_fork_info): Remove.
8881 (fbsd_pending_children): Use std::list.
8882 (fbsd_remember_child): Likewise.
8883 (fbsd_is_child_pending): Likewise.
8884 (fbsd_pending_vfork_done): Use std::forward_list.
8885 (fbsd_add_vfork_done): Likewise.
8886 (fbsd_is_vfork_done_pending): Likewise.
8887 (fbsd_next_vfork_done): Likewise.
8888
8889 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8890
8891 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
8892 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
8893 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
8894 for `mapfilename'.
8895 (fbsd_xfer_partial): Use gdb::byte_vector.
8896 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
8897
8898 2017-08-09 John Baldwin <jhb@FreeBSD.org>
8899
8900 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
8901 "filestuff.h".
8902 (fbsd_find_memory_regions): Fix `mapfile' initialization.
8903
8904 2017-08-09 Tom Tromey <tom@tromey.com>
8905
8906 * skip.c (skiplist_entry): New constructor.
8907 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
8908 (skiplist_entry::file_is_glob): Now bool.
8909 (skiplist_entry::file, skiplist_entry::function): Now
8910 std::string.
8911 (make_skip_entry): Return a unique_ptr. Use new.
8912 (free_skiplist_entry, free_skiplist_entry_cleanup)
8913 (make_free_skiplist_entry_cleanup): Remove.
8914 (skip_command, skip_disable_command, add_skiplist_entry)
8915 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
8916 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
8917 (function_name_is_marked_for_skip): Update.
8918 (skip_delete_command): Update. Use delete.
8919
8920 2017-08-09 Jiong Wang <jiong.wang@arm.com>
8921
8922 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
8923 (aarch64_linux_core_read_description): New function.
8924 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
8925
8926 2017-08-09 Pedro Alves <palves@redhat.com>
8927
8928 * cp-name-parser.y (cp_comp_to_string): Return a
8929 gdb::unique_xmalloc_ptr<char>.
8930 * cp-support.c (replace_typedefs_qualified_name)
8931 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
8932 (cp_canonicalize_string_full): Use op= instead of explicit
8933 convertion.
8934 (cp_class_name_from_physname, method_name_from_physname)
8935 (cp_func_name, cp_remove_params): Adjust to use
8936 gdb::unique_xmalloc_ptr<char>.
8937 * cp-support.h (cp_comp_to_string): Return a
8938 gdb::unique_xmalloc_ptr<char>.
8939 * python/py-type.c (typy_lookup_type): Adjust to use
8940 gdb::unique_xmalloc_ptr<char>.
8941
8942 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
8943
8944 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
8945
8946 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
8947 Yao Qi <yao.qi@linaro.org>
8948
8949 * cp-support.c (cp_canonicalize_string_full): Use
8950 gdb::unique_xmalloc_ptr<char>.
8951 (cp_canonicalize_string): Likewise.
8952
8953 2017-08-09 Yao Qi <yao.qi@linaro.org>
8954
8955 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
8956 * regformats/i386/amd64-avx-avx512.dat: Remove.
8957 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
8958 * regformats/i386/amd64-avx-mpx.dat:Remove.
8959 * regformats/i386/amd64-avx.dat: Remove.
8960 * regformats/i386/amd64-mpx.dat: Remove.
8961 * regformats/i386/i386-avx-avx512.dat: Remove.
8962 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
8963 * regformats/i386/i386-avx-mpx.dat: Remove.
8964 * regformats/i386/i386-mmx.dat: Remove.
8965 * regformats/i386/i386-mpx.dat: Remove.
8966
8967 2017-08-09 Yao Qi <yao.qi@linaro.org>
8968
8969 * amd64-tdep.h (tdesc_x32): Remove the declaration.
8970 * amd64-tdep.c: Don't include features/i386/x32*.c.
8971 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
8972 functions.
8973 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
8974 and i386/x32-avx-avx512.
8975 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
8976 and i386/x32.xml.
8977 * features/i386/x32-avx-avx512.c: Removed.
8978 * features/i386/x32-avx-avx512.xml: Removed.
8979 * features/i386/x32-avx.c: Removed.
8980 * features/i386/x32-avx.xml: Removed.
8981 * features/i386/x32.c: Removed.
8982 * features/i386/x32.xml: Removed.
8983 * regformats/i386/x32-avx-avx512.dat: Removed.
8984 * regformats/i386/x32-avx.dat: Removed.
8985 * regformats/i386/x32.dat: Removed.
8986
8987 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8988
8989 PR breakpoints/21886
8990 * mem-break.c (default_memory_insert_breakpoint): Use
8991 `->placed_address' rather than `->reqstd_address' for the
8992 breakpoint location.
8993
8994 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
8995
8996 * arch-utils.c (default_print_insn): Remove arch/mach/endian
8997 assertions.
8998
8999 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
9000
9001 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
9002 a union of `tdep_info', `tdesc_data' and `id'.
9003 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
9004 rather than `info.tdep_info'.
9005 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
9006 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9007 * i386-tdep.c (i386_gdbarch_init): Likewise.
9008 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
9009 * mips-tdep.c (mips_gdbarch_init): Likewise.
9010 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
9011 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9012 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
9013 `info.tdep_info'.
9014 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
9015 `info.tdep_info'.
9016 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
9017 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
9018 `info.tdep_info'.
9019 * spu-tdep.c (spu_gdbarch_init): Likewise.
9020 * gdbarch.h: Regenerate.
9021
9022 2017-08-07 Leszek Swirski <leszeks@google.com>
9023
9024 PR symtab/20899
9025 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
9026
9027 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
9028
9029 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
9030 (gdbsim_open): Rename gdb_argv args object to argv.
9031
9032 2017-08-05 Tom Tromey <tom@tromey.com>
9033
9034 * compile/compile-object-load.c (compile_object_load): Use
9035 gdb::unique_xmalloc_ptr.
9036 * cli/cli-dump.c (scan_filename): Rename from
9037 scan_filename_with_cleanup. Change return type.
9038 (scan_expression): Rename from scan_expression_with_cleanup.
9039 Change return type.
9040 (dump_memory_to_file, dump_value_to_file, restore_command):
9041 Use gdb::unique_xmalloc_ptr. Update.
9042 * cli/cli-cmds.c (find_and_open_script): Use
9043 gdb::unique_xmalloc_ptr.
9044 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
9045 * symmisc.c (maintenance_print_symbols)
9046 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
9047 * symfile.c (symfile_bfd_open, generic_load)
9048 (add_symbol_file_command, remove_symbol_file_command): Use
9049 gdb::unique_xmalloc_ptr.
9050 * source.c (openp): Use gdb::unique_xmalloc_ptr.
9051 * psymtab.c (maintenance_print_psymbols): Use
9052 gdb::unique_xmalloc_ptr.
9053 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
9054 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
9055 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
9056 (reload_shared_libraries_1): Likewise.
9057
9058 2017-08-05 Tom Tromey <tom@tromey.com>
9059
9060 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
9061 (rust_op_vector, rust_set_vector): New typedefs.
9062 (current_parser): New global.
9063 (work_obstack): Change to pointer type. Update all users.
9064 (rust_ast, pstate): Remove globals.
9065 (struct rust_parser): New.
9066 (%union) <params, field_inits>: Change type.
9067 (start, tuple_expr, unit_expr, struct_expr_list, literal)
9068 (field_expr, expr_list, maybe_expr_list, type_list): Update.
9069 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
9070 (convert_params_to_types, convert_params_to_expression): Change
9071 type of "params".
9072 (ast_string): Change type of "fields".
9073 (rust_parse): Make a rust_parser. Remove cleanups.
9074 (rust_lex_tests): Make and install an auto_obstack.
9075
9076 2017-08-04 Yao Qi <yao.qi@linaro.org>
9077
9078 * configure.srv (ipa_x32_linux_regobj): New.
9079 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
9080 instead of X86_TDESC_AVX512.
9081 (initialize_low_tracepoint): Call
9082 init_registers_x32_avx_avx512_linux.
9083
9084 2017-08-04 Yao Qi <yao.qi@linaro.org>
9085
9086 * utils.h (gdb_argv): Add namespace std for nullptr_t.
9087
9088 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
9089
9090 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
9091
9092 2017-08-03 Tom Tromey <tom@tromey.com>
9093
9094 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
9095 Remove.
9096 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
9097
9098 2017-08-03 Tom Tromey <tom@tromey.com>
9099
9100 * python/py-param.c (compute_enum_values): Use gdb_argv.
9101
9102 2017-08-03 Tom Tromey <tom@tromey.com>
9103
9104 * utils.h (struct gdb_argv_deleter): New.
9105 (gdb_argv): New class.
9106 * utils.c (gdb_argv::reset): New method.
9107 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
9108 * tracefile.c (tsave_command): Use gdb_argv.
9109 * top.c (new_ui_command): Use gdb_argv.
9110 * symmisc.c (maintenance_print_symbols)
9111 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
9112 * symfile.c (symbol_file_command, generic_load)
9113 (remove_symbol_file_command): Use gdb_argv.
9114 * stack.c (backtrace_command): Use gdb_argv.
9115 * source.c (add_path, show_substitute_path_command)
9116 (unset_substitute_path_command, set_substitute_path_command):
9117 Use gdb_argv.
9118 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
9119 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
9120 * remote.c (extended_remote_run, remote_put_command)
9121 (remote_get_command, remote_delete_command): Use gdb_argv.
9122 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
9123 (gdbsim_open): Use gdb_argv.
9124 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
9125 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
9126 * procfs.c (procfs_info_proc): Use gdb_argv.
9127 * interps.c (interpreter_exec_cmd): Use gdb_argv.
9128 * infrun.c (handle_command): Use gdb_argv.
9129 * inferior.c (add_inferior_command, clone_inferior_command):
9130 Use gdb_argv.
9131 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
9132 * exec.c (exec_file_command): Use gdb_argv.
9133 * cli/cli-cmds.c (alias_command): Use gdb_argv.
9134 * compile/compile.c (build_argc_argv): Use gdb_argv.
9135
9136 2017-08-03 Tom Tromey <tom@tromey.com>
9137
9138 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
9139
9140 2017-08-03 Tom Tromey <tom@tromey.com>
9141
9142 * python/python.c (compute_python_string): Return std::string.
9143 (gdbpy_eval_from_control_command): Update.
9144 (do_start_initialization): Use std::string.
9145 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
9146 xstrprintf.
9147 * python/py-breakpoint.c (local_setattro): Use string_printf, not
9148 xstrprintf.
9149
9150 2017-08-03 Tom Tromey <tom@tromey.com>
9151
9152 * top.h (do_restore_instream_cleanup): Remove.
9153 * top.c (do_restore_instream_cleanup): Remove.
9154 (read_command_file): Use scoped_restore.
9155 * cli/cli-script.c (execute_user_command): Use scoped_restore.
9156
9157 2017-08-03 Tom Tromey <tom@tromey.com>
9158
9159 * cli/cli-script.c (execute_user_command)
9160 (execute_control_command): Use scoped_restore.
9161
9162 2017-08-03 Tom Tromey <tom@tromey.com>
9163
9164 * cli/cli-script.c (do_restore_user_call_depth): Remove.
9165 (execute_user_command): Remove user_call_depth; use
9166 user_args_stack's size instead.
9167
9168 2017-08-03 Tom Tromey <tom@tromey.com>
9169
9170 * top.h (in_user_command): Remove.
9171 * top.c (in_user_command): Remove.
9172 * cli/cli-script.c (do_restore_user_call_depth)
9173 (execute_user_command): Update.
9174
9175 2017-08-03 Tom Tromey <tom@tromey.com>
9176
9177 * valops.c (search_struct_method): Use gdb::byte_vector.
9178 * valarith.c (value_concat): Use std::vector.
9179 * target.c (memory_xfer_partial): Use gdb::byte_vector.
9180 (simple_search_memory): Likewise.
9181 * printcmd.c (find_string_backward): Use gdb::byte_vector.
9182 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
9183 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
9184 * elfread.c (elf_rel_plt_read): Use std::string.
9185 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
9186 * cli/cli-dump.c (restore_section_callback): Use
9187 gdb::byte_vector.
9188
9189 2017-08-03 Tom Tromey <tom@tromey.com>
9190
9191 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
9192
9193 2017-08-03 Tom Tromey <tom@tromey.com>
9194
9195 * tui/tui-regs.c (tui_restore_gdbout): Remove.
9196 (tui_register_format): Use scoped_restore.
9197
9198 2017-08-03 Tom Tromey <tom@tromey.com>
9199
9200 * reverse.c (exec_direction_default): Remove.
9201 (exec_reverse_once): Use scoped_restore.
9202 * remote.c (restore_remote_timeout): Remove.
9203 (remote_flash_erase, remote_flash_write, remote_flash_done)
9204 (readchar, remote_serial_write): Use scoped_restore.
9205 * cli/cli-script.c (struct source_cleanup_lines_args)
9206 (source_cleanup_lines): Remove.
9207 (script_from_file): Use scoped_restore.
9208 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
9209 (source_command): Use scoped_restore.
9210
9211 2017-08-03 Tom Tromey <tom@tromey.com>
9212
9213 * utils.h (make_cleanup_free_so): Remove.
9214 * utils.c (do_free_so, make_cleanup_free_so): Remove.
9215 * solist.h (struct so_deleter): New.
9216 (so_list_up): New typedef.
9217 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
9218
9219 2017-08-03 Tom Tromey <tom@tromey.com>
9220
9221 * utils.h (make_cleanup_restore_current_language): Remove.
9222 * utils.c (do_restore_current_language)
9223 (make_cleanup_restore_current_language): Remove.
9224 * parse.c (parse_exp_in_context_1)
9225 (parse_expression_with_language): Use
9226 scoped_restore_current_language.
9227 * mi/mi-main.c (mi_cmd_execute): Use
9228 scoped_restore_current_language.
9229 * language.h (scoped_restore_current_language): New class.
9230
9231 2017-08-03 Tom Tromey <tom@tromey.com>
9232
9233 * compile/compile.c (cleanup_unlink_file): Remove.
9234 (compile_to_object): Use gdb::unlinker.
9235 (eval_compile_command): Likewise.
9236
9237 2017-08-03 Tom Tromey <tom@tromey.com>
9238
9239 * utils.h (make_cleanup_fclose): Remove.
9240 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
9241
9242 2017-08-03 Tom Tromey <tom@tromey.com>
9243
9244 * top.c (open_terminal_stream): Return gdb_file_up.
9245 (new_ui_command): Update.
9246
9247 2017-08-03 Tom Tromey <tom@tromey.com>
9248
9249 * source.c (print_source_lines_base, forward_search_command)
9250 (reverse_search_command): Use gdb_file_up.
9251
9252 2017-08-03 Tom Tromey <tom@tromey.com>
9253
9254 * fbsd-nat.c (fbsd_find_memory_regions): Update.
9255
9256 2017-08-03 Tom Tromey <tom@tromey.com>
9257
9258 * cli/cli-cmds.c (find_and_open_script): Change return type.
9259 Remove "streamp" and "full_path" parameters.
9260 (source_script_with_search): Update.
9261 * auto-load.c (source_script_file): Update.
9262 * cli/cli-cmds.h (find_and_open_script): Change type.
9263 (open_script): New struct.
9264
9265 2017-08-03 Tom Tromey <tom@tromey.com>
9266
9267 * xml-support.c (xml_fetch_content_from_file): Update.
9268 * ui-file.c (stdio_file::open): Update.
9269 * tracefile-tfile.c (tfile_start): Update.
9270 * remote.c (remote_file_put, remote_file_get): Update.
9271 * nat/linux-procfs.c (linux_proc_get_int)
9272 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
9273 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
9274 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
9275 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
9276 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
9277 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
9278 * linux-nat.c (linux_proc_pending_signals): Update.
9279 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
9280 (file_closer): Remove.
9281 * compile/compile.c (compile_to_object): Update.
9282 * common/filestuff.h (struct gdb_file_deleter): New.
9283 (gdb_file_up): New typedef.
9284 (gdb_fopen_cloexec): Change return type.
9285 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
9286 * cli/cli-dump.c (fopen_with_cleanup): Remove.
9287 (dump_binary_file, restore_binary_file): Update.
9288 * auto-load.c (auto_load_objfile_script_1): Update.
9289
9290 2017-08-03 Tom Tromey <tom@tromey.com>
9291
9292 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
9293 (info_static_tracepoint_markers_command): Likewise.
9294 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
9295 * skip.c (skip_info): Use ui_out_emit_table.
9296 * progspace.c (print_program_space): Use ui_out_emit_table.
9297 * osdata.c (info_osdata): Use ui_out_emit_table.
9298 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
9299 ui_out_emit_table.
9300 * linux-thread-db.c (info_auto_load_libthread_db): Use
9301 ui_out_emit_table.
9302 * inferior.c (print_inferior): Use ui_out_emit_table.
9303 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
9304 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
9305 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
9306 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
9307 * ui-out.h (class ui_out_emit_table): New.
9308
9309 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
9310
9311 * mips-tdep.c (mips_fpu_type_str): New function.
9312 (mips_dump_tdep): Call it.
9313
9314 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
9315
9316 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
9317 `->mips_fpu_type'.
9318
9319 2017-07-31 Xavier Roirand <roirand@adacore.com>
9320
9321 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
9322
9323 2017-07-27 Xavier Roirand <roirand@adacore.com>
9324
9325 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
9326
9327 2017-07-26 Yao Qi <yao.qi@linaro.org>
9328
9329 * cli/cli-cmds.c (maintenancechecklist): New variable.
9330 * gdbcmd.h (maintenancechecklist): Declare it.
9331 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
9332 Call i386_linux_read_description with different masks.
9333 * maint.c (maintenance_check_command): New function.
9334 (_initialize_maint_cmds): Call add_prefix_cmd.
9335 * target-descriptions.c (tdesc_reg): override operator != and ==.
9336 (tdesc_type): Likewise.
9337 (tdesc_feature): Likewise.
9338 (target_desc): Likewise.
9339 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
9340 (maintenance_check_xml_descriptions): New function.
9341 (_initialize_target_descriptions) Add command "xml-descriptions".
9342 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
9343
9344 2017-07-26 Yao Qi <yao.qi@linaro.org>
9345
9346 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
9347 Include features/i386/32bit-*.c.
9348 (i386_linux_read_description): Generate target description if it
9349 doesn't exist.
9350 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
9351 functions.
9352 * features/i386/32bit-linux.c: Re-generated.
9353 * features/i386/32bit-sse.c: Likewise.
9354 * target-descriptions.c (print_c_feature::visit): Print code to
9355 set register number if needed.
9356 (print_c_feature) <m_next_regnum>: New field.
9357
9358 2017-07-26 Yao Qi <yao.qi@linaro.org>
9359
9360 * features/Makefile (CFILES): Rename with TDESC_CFILES.
9361 (FEATURE_XMLFILES): New.
9362 (FEATURE_CFILES): New.
9363 New rules.
9364 (clean-cfiles): Remove generated c files.
9365 * features/i386/32bit-avx.c: Generated.
9366 * features/i386/32bit-avx512.c: Generated.
9367 * features/i386/32bit-core.c: Generated.
9368 * features/i386/32bit-linux.c: Generated.
9369 * features/i386/32bit-mpx.c: Generated.
9370 * features/i386/32bit-pkeys.c: Generated.
9371 * features/i386/32bit-sse.c: Generated.
9372 * target-descriptions.c: Include algorithm.
9373 (tdesc_element_visitor): Add method visit_end.
9374 (print_c_tdesc): Implement visit_end.
9375 (print_c_tdesc:: m_filename_after_features): Move it to
9376 protected.
9377 (print_c_feature): New class.
9378 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
9379 name starts with "i386/32bit-".
9380
9381 2017-07-26 Yao Qi <yao.qi@linaro.org>
9382
9383 * target-descriptions.c (tdesc_element_visitor): New class.
9384 (tdesc_element): New class.
9385 (tdesc_reg): Inherit from tdesc_element.
9386 (tdesc_reg::accept): New function.
9387 (tdesc_type): Inherit from tdesc_element.
9388 (tdesc_type::accept): New function.
9389 (tdesc_feature): Inherit from tdesc_element.
9390 (tdesc_feature::accept): New function.
9391 (target_desc): Inherit from tdesc_element.
9392 (target_desc::target_desc): New.
9393 (target_desc::~target_desc): New.
9394 (target_desc::accept): New.
9395 (allocate_target_description): Use new.
9396 (free_target_description): Use delete.
9397 (print_c_tdesc): New class.
9398 (maint_print_c_tdesc_cmd): Adjust.
9399
9400 * features/aarch64.c: Re-generated.
9401 * features/arc-arcompact.c: Re-generated.
9402 * features/arc-v2.c: Re-generated.
9403 * features/arm/arm-with-iwmmxt.c: Re-generated.
9404 * features/arm/arm-with-m.c: Re-generated.
9405 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
9406 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
9407 * features/arm/arm-with-neon.c: Re-generated.
9408 * features/arm/arm-with-vfpv2.c: Re-generated.
9409 * features/arm/arm-with-vfpv3.c: Re-generated.
9410 * features/i386/amd64-avx-avx512.c: Re-generated.
9411 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9412 * features/i386/amd64-avx.c: Re-generated.
9413 * features/i386/amd64-avx-linux.c: Re-generated.
9414 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
9415 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9416 * features/i386/amd64-avx-mpx.c: Re-generated.
9417 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
9418 * features/i386/amd64.c: Re-generated.
9419 * features/i386/amd64-linux.c: Re-generated.
9420 * features/i386/amd64-mpx.c: Re-generated.
9421 * features/i386/amd64-mpx-linux.c: Re-generated.
9422 * features/i386/i386-avx-avx512.c: Re-generated.
9423 * features/i386/i386-avx-avx512-linux.c: Re-generated.
9424 * features/i386/i386-avx.c: Re-generated.
9425 * features/i386/i386-avx-linux.c: Re-generated.
9426 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
9427 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
9428 * features/i386/i386-avx-mpx.c: Re-generated.
9429 * features/i386/i386-avx-mpx-linux.c: Re-generated.
9430 * features/i386/i386.c: Re-generated.
9431 * features/i386/i386-linux.c: Re-generated.
9432 * features/i386/i386-mmx.c: Re-generated.
9433 * features/i386/i386-mmx-linux.c: Re-generated.
9434 * features/i386/i386-mpx.c: Re-generated.
9435 * features/i386/i386-mpx-linux.c: Re-generated.
9436 * features/i386/x32-avx-avx512.c: Re-generated.
9437 * features/i386/x32-avx-avx512-linux.c: Re-generated.
9438 * features/i386/x32-avx.c: Re-generated.
9439 * features/i386/x32-avx-linux.c: Re-generated.
9440 * features/i386/x32.c: Re-generated.
9441 * features/i386/x32-linux.c: Re-generated.
9442 * features/microblaze.c: Re-generated.
9443 * features/microblaze-with-stack-protect.c: Re-generated.
9444 * features/mips64-dsp-linux.c: Re-generated.
9445 * features/mips64-linux.c: Re-generated.
9446 * features/mips-dsp-linux.c: Re-generated.
9447 * features/mips-linux.c: Re-generated.
9448 * features/nds32.c: Re-generated.
9449 * features/nios2.c: Re-generated.
9450 * features/nios2-linux.c: Re-generated.
9451 * features/rs6000/powerpc-32.c: Re-generated.
9452 * features/rs6000/powerpc-32l.c: Re-generated.
9453 * features/rs6000/powerpc-403.c: Re-generated.
9454 * features/rs6000/powerpc-403gc.c : Re-generated.
9455 * features/rs6000/powerpc-405.c: Re-generated.
9456 * features/rs6000/powerpc-505.c: Re-generated.
9457 * features/rs6000/powerpc-601.c: Re-generated.
9458 * features/rs6000/powerpc-602.c: Re-generated.
9459 * features/rs6000/powerpc-603.c: Re-generated.
9460 * features/rs6000/powerpc-604.c: Re-generated.
9461 * features/rs6000/powerpc-64.c: Re-generated.
9462 * features/rs6000/powerpc-64l.c: Re-generated.
9463 * features/rs6000/powerpc-7400.c: Re-generated.
9464 * features/rs6000/powerpc-750.c: Re-generated.
9465 * features/rs6000/powerpc-860.c: Re-generated.
9466 * features/rs6000/powerpc-altivec32.c: Re-generated.
9467 * features/rs6000/powerpc-altivec32l.c: Re-generated.
9468 * features/rs6000/powerpc-altivec64.c: Re-generated.
9469 * features/rs6000/powerpc-altivec64l.c: Re-generated.
9470 * features/rs6000/powerpc-cell32l.c: Re-generated.
9471 * features/rs6000/powerpc-cell64l.c: Re-generated.
9472 * features/rs6000/powerpc-e500.c: Re-generated.
9473 * features/rs6000/powerpc-e500l.c: Re-generated.
9474 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
9475 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
9476 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
9477 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
9478 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
9479 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
9480 * features/rs6000/powerpc-vsx32.c: Re-generated.
9481 * features/rs6000/powerpc-vsx32l.c: Re-generated.
9482 * features/rs6000/powerpc-vsx64.c: Re-generated.
9483 * features/rs6000/powerpc-vsx64l.c: Re-generated.
9484 * features/rs6000/rs6000.c: Re-generated.
9485 * features/s390-linux32.c: Re-generated.
9486 * features/s390-linux32v1.c: Re-generated.
9487 * features/s390-linux32v2.c: Re-generated.
9488 * features/s390-linux64.c: Re-generated.
9489 * features/s390-linux64v1.c: Re-generated.
9490 * features/s390-linux64v2.c: Re-generated.
9491 * features/s390-te-linux64.c: Re-generated.
9492 * features/s390-tevx-linux64.c: Re-generated.
9493 * features/s390-vx-linux64.c: Re-generated.
9494 * features/s390x-linux64.c: Re-generated.
9495 * features/s390x-linux64v1.c: Re-generated.
9496 * features/s390x-linux64v2.c: Re-generated.
9497 * features/s390x-te-linux64.c: Re-generated.
9498 * features/s390x-tevx-linux64.c: Re-generated.
9499 * features/s390x-vx-linux64.c: Re-generated.
9500 * features/sparc/sparc32-solaris.c: Re-generated.
9501 * features/sparc/sparc64-solaris.c: Re-generated.
9502 * features/tic6x-c62x.c: Re-generated.
9503 * features/tic6x-c62x-linux.c: Re-generated.
9504 * features/tic6x-c64x.c: Re-generated.
9505 * features/tic6x-c64x-linux.c: Re-generated.
9506 * features/tic6x-c64xp.c: Re-generated.
9507 * features/tic6x-c64xp-linux.c: Re-generated.
9508
9509 2017-07-26 Yao Qi <yao.qi@linaro.org>
9510
9511 * i386-linux-tdep.c (i386_linux_read_description): New function.
9512 (i386_linux_core_read_description): Call
9513 i386_linux_read_description.
9514 * i386-linux-tdep.h (i386_linux_read_description): Declare.
9515 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
9516 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
9517 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
9518 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
9519 * x86-linux-nat.c (x86_linux_read_description): Call
9520 i386_linux_read_description.
9521
9522 2017-07-26 Yao Qi <yao.qi@linaro.org>
9523
9524 * NEWS: Mention it.
9525 * features/Makefile (%.c: %.xml): Pass the xml file name to
9526 command "maint print c-tdesc".
9527 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
9528 name from 'arg'.
9529
9530 2017-07-26 Yao Qi <yao.qi@linaro.org>
9531
9532 * target-descriptions.c (target_desc): Add ctor and dtor. Do
9533 in-class initialization.
9534 (tdesc_create_feature): Call new instead of XCNEW.
9535 (free_target_description): Ue delete.
9536
9537 2017-07-25 John Baldwin <jhb@FreeBSD.org>
9538
9539 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
9540
9541 2017-07-25 Yao Qi <yao.qi@linaro.org>
9542
9543 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
9544 constant.
9545 (amd64_x32_init_abi): Likewise.
9546 * amd64-tdep.h (amd64_init_abi): Update declaration.
9547 (amd64_x32_init_abi): Likewise.
9548
9549 2017-07-25 Yao Qi <yao.qi@linaro.org>
9550
9551 PR tdep/21717
9552 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
9553 condition for FPSCR.
9554 (arm_linux_store_inferior_registers): Likewise.
9555
9556 2017-07-22 Tom Tromey <tom@tromey.com>
9557
9558 * break-catch-syscall.c (struct catch_syscall_inferior_data)
9559 <syscalls_counts>: Now a std::vector.
9560 (get_catch_syscall_inferior_data): Use "new".
9561 (catch_syscall_inferior_data_cleanup): Use "delete".
9562 (insert_catch_syscall, remove_catch_syscall)
9563 (clear_syscall_counts): Update.
9564
9565 2017-07-22 Tom Tromey <tom@tromey.com>
9566
9567 * break-catch-syscall.c (syscall_catchpoint)
9568 <syscalls_to_be_caught>: Now a std::vector<int>
9569 (~syscall_catchpoint): Remove.
9570 (insert_catch_syscall, remove_catch_syscall)
9571 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
9572 (print_mention_catch_syscall, print_recreate_catch_syscall):
9573 Update.
9574 (create_syscall_event_catchpoint): Change type of "filter"
9575 parameter.
9576 (catch_syscall_split_args): Return a std::vector.
9577 (catch_syscall_command_1, catching_syscall_number_1): Update.
9578
9579 2017-07-22 Tom Tromey <tom@tromey.com>
9580
9581 * break-catch-throw.c (struct exception_catchpoint)
9582 <exception_rx>: Now a std::string.
9583 (~exception_catchpoint): Remove.
9584 (print_one_detail_exception_catchpoint): Update.
9585 (handle_gnu_v3_exceptions): Change type of except_rx.
9586 (extract_exception_regexp): Return a std::string.
9587 (catch_exception_command_1): Update.
9588
9589 2017-07-22 Tom Tromey <tom@tromey.com>
9590
9591 * break-catch-sig.c (gdb_signal_type): Remove typedef.
9592 (struct signal_catchpoint) <signals_to_be_caught>: Now a
9593 std::vector.
9594 <catch_all>: Now a bool.
9595 (~signal_catchpoint): Remove.
9596 (signal_catchpoint_insert_location)
9597 (signal_catchpoint_remove_location)
9598 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
9599 (signal_catchpoint_print_mention)
9600 (signal_catchpoint_print_recreate)
9601 (signal_catchpoint_explains_signal): Update.
9602 (create_signal_catchpoint): Change type of "filter" and
9603 "catch_all".
9604 (catch_signal_split_args): Return a std::vector. Change type of
9605 "catch_all".
9606 (catch_signal_command): Update.
9607
9608 2017-07-20 Pedro Alves <palves@redhat.com>
9609
9610 * ada-lang.c (ada_language_defn): Make extern.
9611 (_initialize_ada_language): Remove add_language call.
9612 * c-lang.c (c_language_defn, cplus_language_defn)
9613 (asm_language_defn, minimal_language_defn): Make extern.
9614 (_initialize_c_language): Delete.
9615 * completer.c (compare_cstrings): Delete, moved to utils.h.
9616 * d-lang.c (d_language_defn): Make extern.
9617 (_initialize_d_language): Remove add_language calls.
9618 * defs.h (enum language): Add comment.
9619 * f-lang.c (f_language_defn): Make extern.
9620 (_initialize_f_language): Remove add_language call.
9621 * go-lang.c (go_language_defn): Make extern.
9622 (_initialize_go_language): Remove add_language call.
9623 * language.c: Include <algorithm>.
9624 (languages): Redefine as const array.
9625 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
9626 (set_language_command): Handle "local". Use for-range loop.
9627 (set_language): Remove loop.
9628 (language_enum): Rewrite.
9629 (language_def, language_str): Remove loops.
9630 (add_language): Delete.
9631 (add_set_language_command): New, based on add_languages.
9632 (skip_language_trampoline): Adjust.
9633 (local_language_defn): Delete.
9634 (language_gdbarch_post_init): Adjust.
9635 (_initialize_language): Remove add_language calls. Call
9636 add_set_language_command.
9637 * language.h (add_language): Delete.
9638 (auto_language_defn)
9639 (unknown_language_defn, minimal_language_defn, ada_language_defn)
9640 (asm_language_defn, c_language_defn, cplus_language_defn)
9641 (d_language_defn, f_language_defn, go_language_defn)
9642 (m2_language_defn, objc_language_defn, opencl_language_defn)
9643 (pascal_language_defn, rust_language_defn): Declare.
9644 * m2-lang.c (m2_language_defn): Make extern.
9645 (_initialize_m2_language): Remove add_language call.
9646 * objc-lang.c (objc_language_defn): Make extern.
9647 (_initialize_objc_language): Remove add_language call.
9648 * opencl-lang.c (opencl_language_defn): Make extern.
9649 (_initialize_opencl_language): Remove add_language call.
9650 * p-lang.c (pascal_language_defn): Make extern.
9651 (_initialize_pascal_language): Delete.
9652 * rust-lang.c (rust_language_defn): Make extern.
9653 (_initialize_rust_language): Delete.
9654 * utils.h (compare_cstrings): New static inline function.
9655
9656 2017-07-20 Pedro Alves <palves@redhat.com>
9657
9658 * ada-lang.c (ada_to_fixed_type_1): Adjust.
9659 (get_var_value): Constify parameters.
9660 (get_int_var_value): Change prototype.
9661 (to_fixed_range_type): Adjust.
9662 * ada-lang.h (get_int_var_value): Change prototype.
9663
9664 2017-07-20 Pedro Alves <palves@redhat.com>
9665
9666 * dwarf2read.c (dw2_lookup_symbol): Use
9667 SYMBOL_MATCHES_SEARCH_NAME.
9668 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
9669
9670 2017-07-20 Pedro Alves <palves@redhat.com>
9671
9672 * block.c (block_iter_name_step, block_iter_name_first)
9673 (block_iter_name_next): Delete.
9674 (block_lookup_symbol_primary): Adjust to use
9675 dict_iter_match_first/dict_iter_match_next.
9676 * block.h (block_iter_name_first, block_iter_name_next): Delete
9677 declarations.
9678 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
9679 dict_iter_match_first/dict_iter_match_next.
9680
9681 2017-07-20 Pedro Alves <palves@redhat.com>
9682
9683 * cp-support.c (cp_find_first_component_aux): Add missing case for
9684 end of string.
9685
9686 2017-07-18 David Blaikie <dblaikie@gmail.com>
9687
9688 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
9689 of dwo_cu's dwo_file.
9690
9691 2017-07-18 Yao Qi <yao.qi@linaro.org>
9692
9693 * remote.c (store_registers_using_G): Remove one line comment.
9694
9695 2017-07-18 Yao Qi <yao.qi@linaro.org>
9696
9697 * regcache.c (regcache_cpy): Simplify it.
9698 (regcache::cpy_no_passthrough): Remove it.
9699 * regcache.h (cpy_no_passthrough): Remove it.
9700 (regcache_dup, regcache_cpy): Update comments.
9701
9702 2017-07-18 Pedro Alves <palves@redhat.com>
9703
9704 * remote-sim.c (sim_command_completer): Adjust to work with a
9705 completion_tracker instead of a VEC.
9706
9707 2017-07-17 Pedro Alves <palves@redhat.com>
9708
9709 * completer.c (complete_source_filenames): New function.
9710 (complete_address_and_linespec_locations): New function.
9711 (location_completer): Use complete_address_and_linespec_locations.
9712 (completion_tracker::build_completion_result): Honor the tracker's
9713 request to suppress append.
9714 * completer.h (completion_tracker::suppress_append_ws)
9715 (completion_tracker::set_suppress_append_ws): New methods.
9716 (completion_tracker::m_suppress_append_ws): New field.
9717 (complete_source_filenames): New declaration.
9718 * linespec.c (linespec_complete_what): New.
9719 (struct ls_parser) <complete_what, completion_word,
9720 completion_quote_char, completion_quote_end, completion_tracker>:
9721 New fields.
9722 (string_find_incomplete_keyword_at_end): New.
9723 (linespec_lexer_lex_string): Record quote char. If in completion
9724 mode, don't throw.
9725 (linespec_lexer_consume_token): Advance the completion word point.
9726 (linespec_lexer_peek_token): Save/restore completion info.
9727 (save_stream_and_consume_token): New.
9728 (set_completion_after_number): New.
9729 (linespec_parse_basic): Set what to complete next depending on
9730 token. Handle function and label completions specially.
9731 (parse_linespec): Disable objc shortcut in completion mode. Set
9732 what to complete next depending on token type. Skip keyword if in
9733 completion mode.
9734 (complete_linespec_component, linespec_complete): New.
9735 * linespec.h (linespec_complete): Declare.
9736
9737 2017-07-17 Pedro Alves <palves@redhat.com>
9738
9739 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
9740 Handle 'operator<' / 'operator<<'.
9741
9742 2017-07-17 Pedro Alves <palves@redhat.com>
9743
9744 * completer.c (collect_explicit_location_matches): Handle
9745 MATCH_LABEL.
9746 (convert_explicit_location_to_linespec): New, factored out from
9747 ...
9748 (convert_explicit_location_to_sals): ... this.
9749 (complete_label): New.
9750 (linespec_complete_label, find_label_symbols_in_block): New.
9751 (find_label_symbols): Add completion_mode parameter and adjust to
9752 call find_label_symbols_in_block.
9753 * linespec.h (linespec_complete_label): Declare.
9754
9755 2017-07-17 Pedro Alves <palves@redhat.com>
9756
9757 * ada-lang.c (ada_collect_symbol_completion_matches): Add
9758 complete_symbol_mode parameter.
9759 * cli/cli-cmds.c (complete_command): Get the completion result out
9760 of the handle_brkchars tracker if used a custom word point.
9761 * completer.c: Include "linespec.h".
9762 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
9763 (advance_to_expression_complete_word_point): New.
9764 (completion_tracker::completes_to_completion_word): New.
9765 (complete_files_symbols): Pass down
9766 complete_symbol_mode::EXPRESSION.
9767 (explicit_options, probe_options): New.
9768 (collect_explicit_location_matches): Complete on the
9769 explictit_loc->foo instead of word. Use
9770 linespec_complete_function. Handle MATCH_LINE. Handle offering
9771 keyword and options completions.
9772 (backup_text_ptr): Delete.
9773 (skip_keyword): New.
9774 (complete_explicit_location): Remove 'word' parameter. Add
9775 language, quoted_arg_start and quoted_arg_end parameters.
9776 Rewrite, parsing left to right.
9777 (location_completer): Rewrite.
9778 (location_completer_handle_brkchars): New function.
9779 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
9780 (enum complete_line_internal_reason): Adjust comments.
9781 (completion_tracker::discard_completions): New.
9782 (completer_handle_brkchars_func_for_completer): Handle
9783 location_completer.
9784 (gdb_custom_word_point_brkchars)
9785 (gdb_org_rl_basic_quote_characters): New.
9786 (gdb_completion_word_break_characters_throw)
9787 (completion_find_completion_word): Handle trackers that use a
9788 custom word point.
9789 (completion_tracker::advance_custom_word_point_by): New.
9790 (completion_tracker::build_completion_result): Don't rely on
9791 readline appending the quote char.
9792 (gdb_rl_attempted_completion_function_throw): Handle trackers that
9793 use a custom word point.
9794 (gdb_rl_attempted_completion_function): Restore
9795 rl_basic_quote_characters.
9796 * completer.h (class completion_tracker): Extend intro comment.
9797 (completion_tracker::set_quote_char)
9798 (completion_tracker::quote_char)
9799 (completion_tracker::set_use_custom_word_point)
9800 (completion_tracker::use_custom_word_point)
9801 (completion_tracker::custom_word_point)
9802 (completion_tracker::set_custom_word_point)
9803 (completion_tracker::advance_custom_word_point_by)
9804 (completion_tracker::completes_to_completion_word)
9805 (completion_tracker::discard_completions): New methods.
9806 (completion_tracker::m_quote_char)
9807 (completion_tracker::m_use_custom_word_point)
9808 (completion_tracker::m_custom_word_point): New fields.
9809 (advance_to_expression_complete_word_point): Declare.
9810 * f-lang.c (f_collect_symbol_completion_matches): Add
9811 complete_symbol_mode parameter.
9812 * language.h (struct language_defn)
9813 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
9814 parameter.
9815 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
9816 (linespec_complete_function): New function.
9817 (linespec_lexer_lex_keyword): Adjust.
9818 * linespec.h (linespec_keywords, linespec_complete_function): New
9819 declarations.
9820 * location.c (find_end_quote): New function.
9821 (explicit_location_lex_one): Add explicit_completion_info
9822 parameter. Save quoting info. Don't throw if being called for
9823 completion. Don't handle Ada operators here.
9824 (is_cp_operator, skip_op_false_positives, first_of)
9825 (explicit_location_lex_one_function): New function.
9826 (string_to_explicit_location): Replace 'dont_throw' parameter with
9827 an explicit_completion_info pointer parameter. Handle it. Don't
9828 use explicit_location_lex_one to lex function names. Use
9829 explicit_location_lex_one_function instead.
9830 * location.h (struct explicit_completion_info): New.
9831 (string_to_explicit_location): Replace 'dont_throw' parameter with
9832 an explicit_completion_info pointer parameter.
9833 * symtab.c (default_collect_symbol_completion_matches_break_on):
9834 Add complete_symbol_mode parameter. Handle LINESPEC mode.
9835 (default_collect_symbol_completion_matches)
9836 (collect_symbol_completion_matches): Add complete_symbol_mode
9837 parameter.
9838 (collect_symbol_completion_matches_type): Pass down
9839 complete_symbol_mode::EXPRESSION.
9840 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9841 parameter. Handle LINESPEC mode.
9842 * symtab.h (complete_symbol_mode): New.
9843 (default_collect_symbol_completion_matches_break_on)
9844 (default_collect_symbol_completion_matches)
9845 (collect_symbol_completion_matches)
9846 (collect_file_symbol_completion_matches): Add complete_symbol_mode
9847 parameter.
9848
9849 2017-07-17 Pedro Alves <palves@redhat.com>
9850
9851 * utils.c (enum class strncmp_iw_mode): New.
9852 (strcmp_iw): Rename to ...
9853 (strncmp_iw_with_mode): ... this. Add string2_len and mode
9854 parameters. Handle them.
9855 (strncmp_iw): New.
9856 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
9857 * utils.h (strncmp_iw): Declare.
9858 (strcmp_iw): Move describing comments here.
9859
9860 2017-07-17 Pedro Alves <palves@redhat.com>
9861
9862 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
9863 CP_OPERATOR_STR.
9864 * c-typeprint.c (is_type_conversion_operator): Use
9865 CP_OPERATOR_STR.
9866 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
9867 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
9868 CP_OPERATOR_LEN.
9869 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
9870 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
9871 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
9872 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
9873 CP_OPERATOR_STR.
9874 * location.c: Include "cp-support.h".
9875 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
9876 CP_OPERATOR_STR.
9877 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
9878 CP_OPERATOR_LEN.
9879
9880 2017-07-17 Pedro Alves <palves@redhat.com>
9881
9882 * cli/cli-cmds.c (complete_command): Use a completion tracker
9883 along with completion_find_completion_word for handle_brkchars
9884 phase.
9885 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
9886 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
9887 (struct gdb_rl_completion_word_info): New.
9888 (gdb_rl_find_completion_word): New.
9889 (completion_find_completion_word): New.
9890 * completer.h (completion_find_completion_word): Declare.
9891
9892 2017-07-17 Pedro Alves <palves@redhat.com>
9893
9894 * ada-lang.c (symbol_completion_match): Adjust comments.
9895 (symbol_completion_add): Replace vector parameter with
9896 completion_tracker parameter. Use it.
9897 (ada_make_symbol_completion_list): Rename to...
9898 (ada_collect_symbol_completion_matches): ... this. Add
9899 completion_tracker parameter and use it.
9900 (ada_language_defn): Adjust.
9901 * break-catch-syscall.c (catch_syscall_completer): Adjust
9902 prototype and work with completion_tracker instead of VEC.
9903 * breakpoint.c (condition_completer): Adjust prototype and work
9904 with completion_tracker instead of VEC.
9905 * c-lang.c (c_language_defn, cplus_language_defn)
9906 (asm_language_defn, minimal_language_defn): Adjust to renames.
9907 * cli/cli-cmds.c (complete_command): Rework using
9908 completion_tracker. Catch exceptions when completing.
9909 * cli/cli-decode.c (integer_unlimited_completer)
9910 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
9911 with completion_tracker instead of VEC.
9912 * command.h (struct completion_tracker): Forward declare.
9913 (completer_ftype, completer_handle_brkchars_ftype): Change
9914 types.
9915 (complete_on_cmdlist, complete_on_enum): Adjust.
9916 * completer.c: Include <algorithm>.
9917 (struct gdb_completer_state): New.
9918 (current_completion): New global.
9919 (readline_line_completion_function): Delete.
9920 (noop_completer, filename_completer)
9921 (filename_completer_handle_brkchars, complete_files_symbols)
9922 (linespec_location_completer): Adjust to work with a
9923 completion_tracker instead of a VEC.
9924 (string_or_empty): New.
9925 (collect_explicit_location_matches): Adjust to work with a
9926 completion_tracker instead of a VEC.
9927 (explicit_location_completer): Rename to ...
9928 (complete_explicit_location): ... this and adjust to work with a
9929 completion_tracker instead of a VEC.
9930 (location_completer): Adjust to work with a completion_tracker
9931 instead of a VEC.
9932 (add_struct_fields): Adjust to work with a completion_list instead
9933 of VEC.
9934 (expression_completer): Rename to ...
9935 (complete_expression): ... this and adjust to work with a
9936 completion_tracker instead of a VEC. Use complete_files_symbols.
9937 (expression_completer): Reimplement on top of complete_expression.
9938 (symbol_completer): Adjust to work with a completion_tracker
9939 instead of a VEC.
9940 (enum complete_line_internal_reason): Add describing comments.
9941 (complete_line_internal_normal_command): Adjust to work with a
9942 completion_tracker instead of a VEC.
9943 (complete_line_internal): Rename to ...
9944 (complete_line_internal_1): ... this and adjust to work with a
9945 completion_tracker instead of a VEC. Assert TEXT is NULL in the
9946 handle_brkchars phase.
9947 (new_completion_tracker): Delete.
9948 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
9949 complete_line_internal_1.
9950 (free_completion_tracker): Delete.
9951 (INITIAL_COMPLETION_HTAB_SIZE): New.
9952 (completion_tracker::completion_tracker)
9953 (completion_tracker::~completion_tracker): New.
9954 (maybe_add_completion): Delete.
9955 (completion_tracker::maybe_add_completion)
9956 (completion_tracker::add_completion)
9957 (completion_tracker::add_completions): New.
9958 (throw_max_completions_reached_error): Delete.
9959 (complete_line): Adjust to work with a completion_tracker instead
9960 of a VEC. Don't create a completion_tracker_t or check for max
9961 completions here.
9962 (command_completer, command_completer_handle_brkchars)
9963 (signal_completer, reg_or_group_completer_1)
9964 (reg_or_group_completer, default_completer_handle_brkchars):
9965 Adjust to work with a completion_tracker.
9966 (gdb_completion_word_break_characters_throw): New.
9967 (gdb_completion_word_break_characters): Reimplement.
9968 (line_completion_function): Delete.
9969 (completion_tracker::recompute_lowest_common_denominator)
9970 (expand_preserving_ws)
9971 (completion_tracker::build_completion_result)
9972 (completion_result::completion_result)
9973 (completion_result::completion_result)
9974 (completion_result::~completion_result)
9975 (completion_result::completion_result)
9976 (completion_result::release_match_list, compare_cstrings)
9977 (completion_result::sort_match_list)
9978 (completion_result::reset_match_list)
9979 (gdb_rl_attempted_completion_function_throw)
9980 (gdb_rl_attempted_completion_function): New.
9981 * completer.h (completion_list, struct completion_result)
9982 (class completion_tracker): New.
9983 (complete_line): Add completion_tracker parameter.
9984 (readline_line_completion_function): Delete.
9985 (gdb_rl_attempted_completion_function): New.
9986 (noop_completer, filename_completer, expression_completer)
9987 (location_completer, symbol_completer, command_completer)
9988 (signal_completer, reg_or_group_completer): Update prototypes.
9989 (completion_tracker_t, new_completion_tracker)
9990 (make_cleanup_free_completion_tracker): Delete.
9991 (enum maybe_add_completion_enum): Delete.
9992 (maybe_add_completion): Delete.
9993 (throw_max_completions_reached_error): Delete.
9994 * corefile.c (complete_set_gnutarget): Adjust to work with a
9995 completion_tracker instead of a VEC.
9996 * cp-abi.c (cp_abi_completer): Adjust to work with a
9997 completion_tracker instead of a VEC.
9998 * d-lang.c (d_language_defn): Adjust.
9999 * disasm.c (disassembler_options_completer): Adjust to work with a
10000 completion_tracker instead of a VEC.
10001 * f-lang.c (f_make_symbol_completion_list): Rename to ...
10002 (f_collect_symbol_completion_matches): ... this. Adjust to work
10003 with a completion_tracker instead of a VEC.
10004 (f_language_defn): Adjust.
10005 * go-lang.c (go_language_defn): Adjust.
10006 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
10007 Adjust to work with a completion_tracker instead of a VEC.
10008 * infrun.c (handle_completer): Likewise.
10009 * interps.c (interpreter_completer): Likewise.
10010 * interps.h (interpreter_completer): Likewise.
10011 * language.c (unknown_language_defn, auto_language_defn)
10012 (local_language_defn): Adjust.
10013 * language.h (language_defn::la_make_symbol_completion_list):
10014 Rename to ...
10015 (language_defn::la_collect_symbol_completion_matches): ... this
10016 and adjust to work with a completion_tracker instead of a VEC.
10017 * m2-lang.c (m2_language_defn): Adjust.
10018 * objc-lang.c (objc_language_defn): Adjust.
10019 * opencl-lang.c (opencl_language_defn): Adjust.
10020 * p-lang.c (pascal_language_defn): Adjust.
10021 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
10022 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
10023 with a completion_tracker.
10024 * rust-lang.c (rust_language_defn): Adjust.
10025 * symtab.c (free_completion_list, do_free_completion_list)
10026 (return_val, completion_tracker): Delete.
10027 (completion_list_add_name, completion_list_add_symbol)
10028 (completion_list_add_msymbol, completion_list_objc_symbol)
10029 (completion_list_add_fields, add_symtab_completions): Add
10030 completion_tracker parameter and use it.
10031 (default_make_symbol_completion_list_break_on_1): Rename to...
10032 (default_collect_symbol_completion_matches_break_on): ... this.
10033 Add completion_tracker parameter and use it instead of allocating
10034 a completion tracker here.
10035 (default_make_symbol_completion_list_break_on): Delete old
10036 implementation.
10037 (default_make_symbol_completion_list): Delete.
10038 (default_collect_symbol_completion_matches): New.
10039 (make_symbol_completion_list): Delete.
10040 (collect_symbol_completion_matches): New.
10041 (make_symbol_completion_type): Rename to ...
10042 (collect_symbol_completion_matches_type): ... this. Add
10043 completion_tracker parameter and use it instead of VEC.
10044 (make_file_symbol_completion_list_1): Rename to...
10045 (collect_file_symbol_completion_matches): ... this. Add
10046 completion_tracker parameter and use it instead of VEC.
10047 (make_file_symbol_completion_list): Delete.
10048 (add_filename_to_list): Use completion_list instead of a VEC.
10049 (add_partial_filename_data::list): Now a completion_list.
10050 (make_source_files_completion_list): Work with a completion_list
10051 instead of a VEC.
10052 * symtab.h: Include "completer.h".
10053 (default_make_symbol_completion_list_break_on)
10054 (default_make_symbol_completion_list, make_symbol_completion_list)
10055 (make_symbol_completion_type, make_file_symbol_completion_list)
10056 (make_source_files_completion_list): Delete.
10057 (default_collect_symbol_completion_matches_break_on)
10058 (default_collect_symbol_completion_matches)
10059 (collect_symbol_completion_matches)
10060 (collect_symbol_completion_matches_type)
10061 (collect_file_symbol_completion_matches)
10062 (make_source_files_completion_list): New.
10063 * top.c (init_main): Don't install a rl_completion_entry_function
10064 hook. Install a rl_attempted_completion_function hook instead.
10065 * tui/tui-layout.c (layout_completer): Adjust to work with a
10066 completion_tracker.
10067 * tui/tui-regs.c (tui_reggroup_completer):
10068 * tui/tui-win.c (window_name_completer, focus_completer)
10069 (winheight_completer): Adjust to work with a completion_tracker.
10070 * value.c: Include "completer.h".
10071 (complete_internalvar): Adjust to work with a completion_tracker.
10072 * value.h (complete_internalvar): Likewise.
10073
10074 2017-07-17 Pedro Alves <palves@redhat.com>
10075
10076 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
10077 renames.
10078 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
10079 comments to completer_ftype's declaration.
10080 <completer_handle_brkchars>: Change type to
10081 completer_handle_brkchars_ftype.
10082 * command.h (completer_ftype): Add describing comment and give
10083 names to parameters.
10084 (completer_ftype_void): Rename to ...
10085 (completer_handle_brkchars_ftype) ... this. Add describing comment.
10086 (set_cmd_completer_handle_brkchars): Adjust.
10087 * completer.c (filename_completer_handle_brkchars): New function.
10088 (complete_line_internal_normal_command): New function, factored
10089 out from ...
10090 (complete_line_internal): ... here.
10091 (command_completer_handle_brkchars)
10092 (default_completer_handle_brkchars)
10093 (completer_handle_brkchars_func_for_completer): New functions.
10094 * completer.h (set_gdb_completion_word_break_characters): Delete
10095 declaration.
10096 (completer_handle_brkchars_func_for_completer): New declaration.
10097 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
10098 completer_handle_brkchars_func_for_completer.
10099
10100 2017-07-17 Pedro Alves <palves@redhat.com>
10101
10102 * completer.c (symbol_completer): New function, based on
10103 make_symbol_completion_list_fn.
10104 * completer.h (symbol_completer): New declaration.
10105 * guile/scm-cmd.c (cmdscm_completers): Adjust.
10106 * python/py-cmd.c (completers): Adjust.
10107 * symtab.c (make_symbol_completion_list_fn): Delete.
10108 * symtab.h (make_symbol_completion_list_fn): Delete.
10109 * cli/cli-decode.c (add_cmd): Adjust.
10110
10111 2017-07-17 Pedro Alves <palves@redhat.com>
10112
10113 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
10114 * dwarf2read.c: Include "filename-seen-cache.h".
10115 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
10116 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
10117 * filename-seen-cache.c: New file.
10118 * filename-seen-cache.h: New file.
10119 * symtab.c: Include "filename-seen-cache.h".
10120 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
10121 (create_filename_seen_cache, clear_filename_seen_cache)
10122 (delete_filename_seen_cache, filename_seen): Delete, parts moved
10123 to filename-seen-cache.h/filename-seen-cache.c.
10124 (output_source_filename, sources_info)
10125 (maybe_add_partial_symtab_filename)
10126 (make_source_files_completion_list): Adjust to use
10127 filename_seen_cache.
10128
10129 2017-07-17 Pedro Alves <palves@redhat.com>
10130
10131 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
10132 fields.
10133 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
10134 dwarf2_debug_sections*)): New.
10135 (dwarf2_per_objfile::dwarf2_per_objfile(const
10136 dwarf2_per_objfile&)): Declare as deleted.
10137 (dwarf2_per_objfile::operator=): Declare as deleted.
10138 (dwarf2_per_objfile::dwarf2_per_objfile)
10139 (dwarf2_per_objfile::~dwarf2_per_objfile)
10140 (dwarf2_per_objfile::free_cached_comp_units): New.
10141 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
10142 ctor. Call dwarf2_per_objfile's ctor manually.
10143 (dwarf2_locate_sections): Deleted/refactored as ...
10144 (dwarf2_per_objfile::locate_sections): ... this new method.
10145 (free_cached_comp_units): Defer to
10146 dwarf2_per_objfile::free_cached_comp_units.
10147 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
10148
10149 2017-07-14 Tom Tromey <tom@tromey.com>
10150
10151 PR rust/21764:
10152 * rust-exp.y (convert_ast_to_expression): Add "want_type"
10153 parameter.
10154 <UNOP_SIZEOF>: Split into separate case.
10155 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
10156
10157 2017-07-14 Tom Tromey <tom@tromey.com>
10158
10159 PR rust/21763:
10160 * symtab.c (symbol_matches_domain): Add language_rust to special
10161 case.
10162 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
10163 treat LOC_TYPEDEF symbols as variables.
10164
10165 2017-07-14 Pedro Alves <palves@redhat.com>
10166
10167 * symtab.c (make_file_symbol_completion_list_1): Iterate over
10168 symtabs matching all symtabs with SRCFILE as file name instead of
10169 only considering the first hit, with lookup_symtab.
10170
10171 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10172
10173 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
10174 operator_name parameters.
10175 (gen_expr): Update function call.
10176
10177 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10178
10179 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
10180 parameter.
10181 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
10182 Likewise.
10183 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
10184 parameter, use agent_expr::gdbarch instead, update function
10185 calls.
10186 (locexpr_tracepoint_var_ref): Likewise.
10187 (loclist_tracepoint_var_ref): Likewise.
10188 * ax-gdb.c (gen_trace_static_fields): Likewise.
10189 (gen_traced_pop): Likewise.
10190 (gen_frame_args_address): Likewise.
10191 (gen_frame_locals_address): Likewise.
10192 (gen_var_ref): Likewise.
10193 (gen_struct_ref_recursive): Likewise.
10194 (gen_static_field): Likewise.
10195 (gen_maybe_namespace_elt): Likewise.
10196 (gen_expr): Likewise.
10197 (gen_trace_for_var): Likewise.
10198 (gen_trace_for_expr): Likewise.
10199 (gen_trace_for_return_address): Likewise.
10200
10201 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10202
10203 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
10204 parameter.
10205 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
10206
10207 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
10208
10209 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
10210 from ax, update calls.
10211 (gen_usual_arithmetic): Likewise.
10212 (gen_integral_promotions): Likewise.
10213 (gen_bitfield_ref): Likewise.
10214 (gen_primitive_field): Likewise.
10215 (gen_struct_ref_recursive): Likewise.
10216 (gen_struct_ref): Likewise.
10217 (gen_maybe_namespace_elt): Likewise.
10218 (gen_struct_elt_for_reference): Likewise.
10219 (gen_namespace_elt): Likewise.
10220 (gen_aggregate_elt_ref): Likewise.
10221 (gen_expr): Get gdbarch from ax, update calls.
10222 (gen_expr_binop_rest): Likewise.
10223
10224 2017-07-13 Pedro Alves <palves@redhat.com>
10225
10226 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
10227 as default tdesc.
10228 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
10229 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
10230 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
10231 tdesc_amd64_linux as default tdesc. Get final tdesc from the
10232 tdep.
10233 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
10234 Get final tdesc from the tdep.
10235 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
10236 default tdesc.
10237 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
10238 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
10239 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
10240 Use it as default tdesc.
10241 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
10242 down to amd_init_abi. No longer handle fallback tdesc here.
10243 * amd64-tdep.h (tdesc_x32): Declare.
10244 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
10245 parameter.
10246 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
10247 as default tdesc.
10248
10249 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10250
10251 * s390-linux-tdep.c (s390_process_record): Add support for
10252 instructions new in arch12.
10253
10254 2017-07-11 John Baldwin <jhb@FreeBSD.org>
10255
10256 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
10257 PT_GETFSBASE and PT_GETGSBASE.
10258 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
10259 PT_SETGSBASE.
10260
10261 2017-07-11 John Baldwin <jhb@FreeBSD.org>
10262
10263 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
10264 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
10265 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
10266 those rules.
10267 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
10268 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
10269 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
10270 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
10271 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
10272 * features/i386/amd64.xml: Add 64bit-segments.xml.
10273 * features/i386/amd64-avx-avx512.c: Regenerated.
10274 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
10275 * features/i386/amd64-avx-mpx.c: Regenerated.
10276 * features/i386/amd64-avx.c: Regenerated.
10277 * features/i386/amd64-mpx.c: Regenerated.
10278 * features/i386/amd64.c: Regenerated.
10279 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
10280 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10281 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
10282 * regformats/i386/amd64-avx.dat: Regenerated.
10283 * regformats/i386/amd64-mpx.dat: Regenerated.
10284 * regformats/i386/amd64.dat: Regenerated.
10285
10286 2017-07-10 Yao Qi <yao.qi@linaro.org>
10287
10288 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
10289 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
10290
10291 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
10292
10293 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
10294 unsetenv.
10295 * gnulib/aclocal.m4: Regenerate.
10296 * gnulib/config.in: Regenerate.
10297 * gnulib/configure: Regenerate.
10298 * gnulib/import/Makefile.am: Regenerate.
10299 * gnulib/import/Makefile.in: Regenerate.
10300 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
10301 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
10302 * gnulib/import/m4/environ.m4: New file.
10303 * gnulib/import/m4/setenv.m4: New file.
10304 * gnulib/import/setenv.c: New file.
10305 * gnulib/import/unsetenv.c: New file.
10306
10307 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
10308
10309 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
10310 address when op is DW_OP_addr.
10311
10312 2017-07-09 Tom Tromey <tom@tromey.com>
10313
10314 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
10315 check and apply to outer type.
10316
10317 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10318
10319 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
10320 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
10321 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
10322 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
10323
10324 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10325
10326 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
10327
10328 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10329
10330 * corelow.c (get_core_siginfo): Remove.
10331 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
10332 instead of get_core_siginfo.
10333 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
10334 * gdbarch.h: Re-generate.
10335 * gdbarch.c: Re-generate.
10336 * linux-tdep.c (linux_core_xfer_siginfo): New.
10337 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
10338
10339 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10340
10341 * corelow.c (thread_section_name): Move to ...
10342 * gdbcore.h (thread_section_name): ... here.
10343
10344 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10345
10346 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
10347 (struct siginfo32): New.
10348 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
10349 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
10350 via ptrace(PT_LWPINFO).
10351
10352 2017-07-07 John Baldwin <jhb@FreeBSD.org>
10353
10354 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
10355 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
10356 (fbsd_get_siginfo_type): New.
10357 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
10358 (_initialize_fbsd_tdep): New.
10359
10360 2017-07-06 David Blaikie <dblaikie@gmail.com>
10361
10362 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
10363 a singular dwo_unit*) to support multiple CUs in the same way that
10364 multiple TUs are supported.
10365 (create_cus_hash_table): Replace create_dwo_cu with a function for
10366 parsing multiple CUs from a DWO file.
10367 (open_and_init_dwo_file): Use create_cus_hash_table rather than
10368 create_dwo_cu.
10369 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
10370 htab_find, rather than comparing the signature to a singleton CU in
10371 the dwo_file.
10372
10373 2017-07-06 Pedro Alves <palves@redhat.com>
10374
10375 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
10376
10377 2017-07-04 Pedro Alves <palves@redhat.com>
10378
10379 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
10380 * gdbtypes.h (TYPE_STATIC): Delete.
10381 (struct fn_field) <is_public, is_abstract, is_static, is_final,
10382 is_synchronized, is_native>: Delete.
10383 <dummy>: Bump.
10384 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
10385 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
10386 (TYPE_FN_FIELD_ABSTRACT): Delete.
10387
10388 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
10389
10390 * buffer.h (buffer_finish): Fix spelling mistakes.
10391
10392 2017-07-01 Eli Zaretskii <eliz@gnu.org>
10393
10394 * .dir-locals.el: Automatically switch to C-style comments in
10395 versions of Emacs that support the feature.
10396
10397 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10398 Pedro Alves <palves@redhat.com>
10399
10400 PR cli/21688
10401 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
10402 (process_next_line): New variable 'inline_cmd'.
10403 Adjust 'if' clauses for "python", "compile" and "guile" to use
10404 'command_name_equals' and check for '!inline_cmd'.
10405
10406 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
10407
10408 PR cli/21688
10409 * cli/cli-script.c (command_name_equals_not_inline): New function.
10410 (process_next_line): Adjust 'if' clauses for "python", "compile"
10411 and "guile" to use command_name_equals_not_inline.
10412
10413 2017-06-29 Pedro Alves <palves@redhat.com>
10414
10415 * completer.c (expression_completer): Call
10416 linespec_location_completer instead of location_completer.
10417
10418 2017-06-29 Pedro Alves <palves@redhat.com>
10419
10420 * completer.c (expression_completer): Remove code that recomputes
10421 'text' from 'word'.
10422
10423 2017-06-29 Yao Qi <yao.qi@linaro.org>
10424
10425 * regformats/regdat.sh: Generate code with
10426 "ifndef IN_PROCESS_AGENT".
10427
10428 2017-06-28 Pedro Alves <palves@redhat.com>
10429
10430 * command.h: Include "common/scoped_restore.h".
10431
10432 2017-06-28 Yao Qi <yao.qi@linaro.org>
10433
10434 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
10435 instead of obstack_grow.
10436
10437 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
10438
10439 PR gdb/21337
10440 * symfile.c (reread_symbols): Call objfiles_changed just before
10441 read_symbols.
10442
10443 2017-06-27 Pedro Alves <palves@redhat.com>
10444
10445 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
10446 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
10447 (completion_list_add_symbol, completion_list_add_msymbol):
10448 ... these new functions.
10449 (add_symtab_completions)
10450 (default_make_symbol_completion_list_break_on_1): Adjust.
10451
10452 2017-06-27 Pedro Alves <palves@redhat.com>
10453
10454 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
10455 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
10456 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
10457 dtor.
10458 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
10459 'storage_obstack' field an auto_obstack. In-class initialize all
10460 non-bitfield fields. Make minsyms_read bool.
10461 * symfile.c (read_symbols): Adjust.
10462
10463 2017-06-27 Alan Hayward <alan.hayward@arm.com>
10464
10465 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
10466 (gdbsim_store_register): Likewise.
10467
10468 2017-06-27 Pedro Alves <palves@redhat.com>
10469
10470 * c-exp.y (name_obstack): Now an auto_obstack.
10471 (yylex): Use auto_obstack::clear.
10472 (c_parse): Use auto_obstack::clear instead of reinitializing and
10473 freeing the obstack.
10474 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
10475 * d-exp.y (name_obstack): Now an auto_obstack.
10476 (yylex): Use auto_obstack::clear.
10477 (d_parse): Use auto_obstack::clear instead of reinitializing and
10478 freeing the obstack.
10479 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
10480 auto_obstack.
10481 * dwarf2read.c (create_addrmap_from_index)
10482 (dwarf2_build_psymtabs_hard)
10483 (update_enumeration_type_from_children): Likewise.
10484 * gdb_obstack.h (auto_obstack): New type.
10485 * go-exp.y (name_obstack): Now an auto_obstack.
10486 (build_packaged_name): Use auto_obstack::clear.
10487 (go_parse): Use auto_obstack::clear instead of reinitializing and
10488 freeing the obstack.
10489 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
10490 auto_obstack.
10491 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
10492 * rust-exp.y (work_obstack): Now an auto_obstack.
10493 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
10494 reinitializing and freeing the obstack.
10495 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
10496 (host_char_to_target): Use auto_obstack.
10497 * utils.h (make_cleanup_obstack_free): Delete declaration.
10498 * valprint.c (generic_emit_char, generic_printstr): Use
10499 auto_obstack.
10500
10501 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
10502
10503 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
10504 thread.
10505 (darwin_init_thread_list): Don't update dummy thread.
10506 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
10507
10508 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10509
10510 * record-full.c (netorder16): Remove.
10511
10512 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10513
10514 * common/diagnostics.h: Define macros for GCC.
10515 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
10516 * common/vec.h: Include diagnostics.h.
10517 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
10518 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
10519 warning.
10520
10521 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
10522
10523 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
10524 New macro.
10525 * ada-lex.l: Ignore deprecated register warnings.
10526
10527 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10528
10529 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
10530 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
10531
10532 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10533
10534 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
10535 its own line.
10536
10537 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
10538
10539 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
10540
10541 2017-06-23 Alan Hayward <alan.hayward@arm.com>
10542
10543 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
10544 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
10545 (xtensa_register_read_masked): Likewise.
10546
10547 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
10548
10549 * common/environ.c (gdb_environ::unset): Update comment.
10550
10551 2017-06-22 Alan Hayward <alan.hayward@arm.com>
10552
10553 * python/py-unwind.c (pyuw_sniffer): Allocate space for
10554 registers.
10555
10556 2017-06-22 Alan Hayward <alan.hayward@arm.com>
10557
10558 * record-full.c (record_full_exec_insn): Use byte_vector.
10559
10560 2017-06-22 Yao Qi <yao.qi@linaro.org>
10561
10562 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
10563 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
10564
10565 2017-06-22 Alan Hayward <alan.hayward@arm.com>
10566
10567 * remote.c (cached_reg): Move from here...
10568 * regcache.h (cached_reg): ...to here.
10569 * python/py-unwind.c (struct reg_info): Remove.
10570 (cached_frame_info): Use cached_reg_t.
10571 (pyuw_prev_register): Likewise.
10572 (pyuw_sniffer): Use cached_reg_t and allocate registers.
10573 (pyuw_dealloc_cache): Free all registers.
10574
10575 2017-06-22 Pedro Alves <palves@redhat.com>
10576 Simon Marchi <simon.marchi@ericsson.com>
10577
10578 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
10579 warning.
10580 * common/diagnostics.h: New file.
10581
10582 2017-06-22 Pedro Alves <palves@redhat.com>
10583
10584 * common/agent.h: Add include guards.
10585
10586 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
10587
10588 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
10589 talk about addressable units instead of bytes.
10590
10591 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10592
10593 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
10594 of '::const_iterator'.
10595
10596 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
10597
10598 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
10599 'unittests/environ-selftests.c'.
10600 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
10601 * charset.c (find_charset_names): Declare object 'iconv_env'.
10602 Update code to use 'iconv_env' object. Remove call to
10603 'free_environ'.
10604 * common/environ.c: Include <utility>.
10605 (make_environ): Delete function.
10606 (free_environ): Delete function.
10607 (gdb_environ::clear): New function.
10608 (gdb_environ::operator=): New function.
10609 (gdb_environ::get): Likewise.
10610 (environ_vector): Delete function.
10611 (set_in_environ): Delete function.
10612 (gdb_environ::set): New function.
10613 (unset_in_environ): Delete function.
10614 (gdb_environ::unset): New function.
10615 (gdb_environ::envp): Likewise.
10616 * common/environ.h: Include <vector>.
10617 (struct gdb_environ): Delete; transform into...
10618 (class gdb_environ): ... this class.
10619 (free_environ): Delete prototype.
10620 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
10621 environ_vector): Likewise.
10622 * infcmd.c (run_command_1): Update code to call
10623 'envp' from 'gdb_environ' class.
10624 (environment_info): Update code to call methods from 'gdb_environ'
10625 class.
10626 (unset_environment_command): Likewise.
10627 (path_info): Likewise.
10628 (path_command): Likewise.
10629 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
10630 (inferior::inferior): Initialize 'environment' using the host's
10631 information.
10632 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
10633 Include "environ.h".
10634 (class inferior) <environment>: Change type from 'struct
10635 gdb_environ' to 'gdb_environ'.
10636 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
10637 methods from 'gdb_environ' class.
10638 * solib.c (solib_find_1): Likewise
10639 * unittests/environ-selftests.c: New file.
10640
10641 2017-06-20 Yao Qi <yao.qi@linaro.org>
10642
10643 * features/i386/i386-linux.xml: Exchange the order of including
10644 32bit-linux.xml and 32bit-sse.xml.
10645 * features/i386/i386-linux.c: Regenerated.
10646
10647 2017-06-20 Yao Qi <yao.qi@linaro.org>
10648
10649 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
10650 Delete copy ctor and assignment operator.
10651 (tdesc_type): Likewise.
10652 (tdesc_feature): Likewise.
10653 (tdesc_free_reg): Remove.
10654 (tdesc_create_reg): Use new.
10655 (tdesc_free_type): Remove.
10656 (tdesc_create_vector): Use new.
10657 (tdesc_create_union): Likewise.
10658 (tdesc_create_flags): Likewise.
10659 (tdesc_create_enum): Likewise.
10660 (tdesc_free_feature): Delete.
10661 (free_target_description): Use delete.
10662
10663 2017-06-19 John Baldwin <jhb@FreeBSD.org>
10664
10665 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
10666 registers.
10667
10668 2017-06-19 Pedro Alves <palves@redhat.com>
10669
10670 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
10671 after gdb::unlinker.
10672
10673 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
10674
10675 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
10676 gdb_environ to access an environment variable.
10677
10678 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
10679
10680 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
10681 gdb_byte*.
10682
10683 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10684
10685 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
10686
10687 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10688
10689 * configure: Re-generate.
10690 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
10691
10692 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10693
10694 * configure: Re-generate.
10695 * warning.m4: Pass -Werror to compiler when checking for
10696 supported warning flags.
10697
10698 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
10699
10700 * Makefile.in (COMPILE.pre): Add "-x c++".
10701
10702 2017-06-16 Alan Hayward <alan.hayward@arm.com>
10703 Pedro Alves <palves@redhat.com>
10704 Yao Qi <yao.qi@linaro.org>
10705
10706 * defs.h (RequireLongest): New.
10707 (extract_integer): Declare function template.
10708 (extract_signed_integer): Remove the declaration, but define it
10709 static inline.
10710 (extract_unsigned_integer): Likewise.
10711 (store_integer): Declare function template.
10712 (store_signed_integer): Remove the declaration, but define it
10713 static inline.
10714 (store_unsigned_integer): Likewise.
10715 * findvar.c (extract_integer): New function template.
10716 (extract_signed_integer): Remove.
10717 (extract_unsigned_integer): Remove.
10718 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
10719 instantiations.
10720 (store_integer): New function template.
10721 (store_signed_integer): Remove.
10722 (store_unsigned_integer): Remove.
10723 (store_integer): Explicit instantiations.
10724 * regcache.c (regcache_raw_read_signed): Update.
10725 (regcache::raw_read): New function.
10726 (regcache::raw_read_signed): Remove.
10727 (regcache::raw_read_unsigned): Remove.
10728 (regcache_raw_read_unsigned): Update.
10729 (regcache_raw_write_unsigned): Update.
10730 (regcache::raw_write_signed): Remove.
10731 (regcache::raw_write): New function.
10732 (regcache_cooked_read_signed): Update.
10733 (regcache::raw_write_unsigned): Remove.
10734 (regcache::cooked_read_signed): Remove.
10735 (regcache_cooked_read_unsigned): Update.
10736 (regcache::cooked_read_unsigned): Remove.
10737 (regcache_cooked_write_signed): Update.
10738 (regcache_cooked_write_unsigned): Update.
10739 * regcache.h (regcache) <raw_read_signed>: Remove.
10740 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
10741 <raw_read, raw_write>: New.
10742 <cooked_read_signed, cooked_write_signed>: Remove.
10743 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
10744 <cooked_read, cooked_write>: New.
10745 * sh64-tdep.c (sh64_pseudo_register_read): Update.
10746 (sh64_pseudo_register_write): Update.
10747
10748 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
10749
10750 * arc-tdep.c (arc_disassembler_options): New variable.
10751 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
10752 of default_print_insn.
10753 (arc_delayed_print_insn): Set info->section when needed,
10754 use default_print_insn to retrieve a disassembler.
10755
10756 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
10757
10758 PR gdb/21574
10759 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
10760 to mention $SHELL and startup-with-shell.
10761
10762 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
10763
10764 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
10765
10766 2017-06-14 Yao Qi <yao.qi@linaro.org>
10767
10768 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
10769 default_print_insn instead of print_insn_aarch64.
10770 * arm-tdep.c (gdb_print_insn_arm): Call
10771 default_print_insn instead of print_insn_big_arm
10772 and print_insn_little_arm.
10773 * i386-tdep.c (i386_print_insn): Call default_print_insn
10774 instead of print_insn_i386.
10775 * ia64-tdep.c (ia64_print_insn): Call
10776 default_print_insn instead of print_insn_ia64.
10777 * mips-tdep.c (gdb_print_insn_mips): Call
10778 default_print_insn instead of print_insn_big_mips
10779 and print_insn_little_mips.
10780 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
10781 instead of print_insn_spu.
10782
10783 2017-06-14 Pedro Alves <palves@redhat.com>
10784
10785 * ada-lang.c: Include "common/byte-vector.h".
10786 (ada_value_primitive_packed_val): Use gdb::byte_vector.
10787 * charset.c (wchar_iterator::iterate): Resize the vector instead
10788 of reserving it.
10789 * common/byte-vector.h: Include "common/def-vector.h".
10790 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
10791 * cli/cli-dump.c: Include "common/byte-vector.h".
10792 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
10793 * common/byte-vector.h: New file.
10794 * common/def-vector.h: New file.
10795 * common/default-init-alloc.h: New file.
10796 * dwarf2loc.c: Include "common/byte-vector.h".
10797 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
10798 instead of reserving it.
10799 * dwarf2read.c: Include "common/byte-vector.h".
10800 (data_buf::m_vec): Now a gdb::byte_vector.
10801 * gdb_regex.c: Include "common/def-vector.h".
10802 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
10803 * mi/mi-main.c: Include "common/byte-vector.h".
10804 (mi_cmd_data_read_memory): Use gdb::byte_vector.
10805 * printcmd.c: Include "common/byte-vector.h".
10806 (print_scalar_formatted): Use gdb::byte_vector.
10807 * valprint.c: Include "common/byte-vector.h".
10808 (maybe_negate_by_bytes, print_decimal_chars): Use
10809 gdb::byte_vector.
10810
10811 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10812
10813 * darwin-nat.c: Include "nat/fork-inferior.h".
10814
10815 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10816
10817 * configure.nat: Factor out Darwin bits that are not
10818 architecture-specific. Add fork-inferior.o.
10819
10820 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
10821
10822 * configure.nat: Factor out AIX bits that are not
10823 architecture-specific. Add fork-inferior.o.
10824
10825 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10826
10827 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
10828 (read_pieced_value, write_pieced_value): ...here. Reduce to
10829 wrappers that just call rw_pieced_value.
10830
10831 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10832
10833 * dwarf2loc.c (write_pieced_value): When writing the data for a
10834 memory piece, use write_memory_with_notification instead of
10835 write_memory.
10836
10837 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10838
10839 * valops.c (read_value_memory): Change embedded_offset to
10840 represent a bit offset instead of a byte offset.
10841 * value.h (read_value_memory): Adjust comment.
10842
10843 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10844
10845 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
10846 dest_offset_bits and source_offset_bits.
10847 (write_pieced_value): Likewise.
10848
10849 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10850
10851 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
10852 given by DW_OP_bit_piece.
10853 (write_pieced_value): Likewise.
10854
10855 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10856
10857 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
10858 some other preparations to the places where sufficient information
10859 is available.
10860 (write_pieced_value): Likewise.
10861
10862 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10863
10864 * dwarf2loc.c (bits_to_bytes): New function.
10865 (read_pieced_value): Fix offset calculations for register pieces
10866 on big-endian targets.
10867 (write_pieced_value): Likewise.
10868
10869 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10870
10871 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
10872 (write_pieced_value): Likewise.
10873
10874 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10875
10876 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
10877 transfer the source value's least significant bits, instead of its
10878 lowest-addressed ones. Rename type_len to max_offset.
10879 (read_pieced_value): Mirror above changes to write_pieced_value as
10880 applicable.
10881
10882 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10883
10884 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
10885 truncate full bytes from dest_offset_bits before using it as an
10886 offset into the buffer.
10887
10888 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10889
10890 * dwarf2loc.c (write_pieced_value): Include transfer size in
10891 byte-wise check.
10892
10893 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10894
10895 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
10896 calculation of this_size.
10897
10898 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10899
10900 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
10901 when targeting a bit-field.
10902 (write_pieced_value): Likewise.
10903
10904 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10905
10906 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
10907 (allocate_piece_closure): Drop addr_size parameter.
10908 (dwarf2_evaluate_loc_desc_full): Adjust call to
10909 allocate_piece_closure.
10910
10911 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10912
10913 PR gdb/21226
10914 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
10915 the LSB end, independent of endianness.
10916
10917 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
10918
10919 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
10920 size capping.
10921
10922 2017-06-13 Yao Qi <yao.qi@linaro.org>
10923
10924 * mips-linux-nat.c: Move include features/mips*-linux.c to
10925 mips-linux-tdep.c.
10926 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
10927 to mips-linux-tdep.c.
10928 * mips-linux-tdep.c: Include features/mips*-linux.c
10929 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
10930 functions.
10931 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
10932 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
10933 (tdesc_mips64_dsp_linux): Declare.
10934
10935 2017-06-12 Tom Tromey <tom@tromey.com>
10936
10937 * valprint.h (val_print_type_code_int): Remove.
10938 * valprint.c (generic_val_print_int): Always call
10939 val_print_scalar_formatted.
10940 (val_print_type_code_int): Remove.
10941 * printcmd.c (print_scalar_formatted): Handle options->format==0.
10942 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
10943 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
10944 * ada-valprint.c (ada_val_print_num): Use
10945 val_print_scalar_formatted.
10946
10947 2017-06-12 Tom Tromey <tom@tromey.com>
10948
10949 * printcmd.c (print_scalar_formatted): Unify the two switches.
10950 Don't convert scalars to LONGEST.
10951
10952 2017-06-12 Tom Tromey <tom@tromey.com>
10953
10954 PR exp/16225:
10955 * valprint.h (print_decimal_chars): Update.
10956 * valprint.c (maybe_negate_by_bytes): New function.
10957 (print_decimal_chars): Add "is_signed" argument.
10958 * printcmd.c (print_scalar_formatted): Update.
10959
10960 2017-06-12 Tom Tromey <tom@tromey.com>
10961
10962 PR exp/16225:
10963 * valprint.h (print_binary_chars, print_hex_chars): Update.
10964 * valprint.c (val_print_type_code_int): Update.
10965 (print_binary_chars): Add "zero_pad" argument.
10966 (emit_octal_digit): New function.
10967 (print_octal_chars): Don't zero-pad.
10968 (print_decimal_chars): Likewise.
10969 (print_hex_chars): Add "zero_pad" argument.
10970 * sh64-tdep.c (sh64_do_fp_register): Update.
10971 * regcache.c (regcache::dump): Update.
10972 * printcmd.c (print_scalar_formatted): Update.
10973 * infcmd.c (default_print_one_register_info): Update.
10974
10975 2017-06-12 Pedro Alves <palves@redhat.com>
10976 Alan Hayward <alan.hayward@arm.com>
10977
10978 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
10979 (mips_eabi_push_dummy_call): Rename local 'regsize' to
10980 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
10981 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
10982 Assert that abi_regsize bytes fit in 'ref_valbuf'.
10983
10984 2017-06-12 Pedro Alves <palves@redhat.com>
10985
10986 * dwarf2read.c (mapped_symtab::data): Now a vector of
10987 symtab_index_entry instead of vector of
10988 std::unique_ptr<symtab_index_entry>. All users adjusted to check
10989 whether an element's name is NULL instead of checking whether the
10990 element itself is NULL.
10991 (find_slot): Change return type. Adjust.
10992 (hash_expand, , add_index_entry, uniquify_cu_indices)
10993 (write_hash_table): Adjust.
10994
10995 2017-06-12 Pedro Alves <palves@redhat.com>
10996
10997 * dwarf2read.c (recursively_count_psymbols): New function.
10998 (write_psymtabs_to_index): Call it to compute number of psyms and
10999 pass estimate size of psyms_seen to unordered_set's ctor.
11000
11001 2017-06-12 Pedro Alves <palves@redhat.com>
11002
11003 * dwarf2read.c (write_hash_table): Check if key already exists
11004 before emplacing.
11005
11006 2017-06-12 Pedro Alves <palves@redhat.com>
11007
11008 * dwarf2read.c (data_buf::append_space): Rename to...
11009 (data_buf::grow): ... this, and make private. Adjust all callers.
11010 (data_buf::append_uint): New method.
11011 (add_address_entry, write_one_signatured_type)
11012 (write_psymtabs_to_index): Use it.
11013
11014 2017-06-12 Pedro Alves <palves@redhat.com>
11015
11016 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
11017 (file_write (FILE *, const std::vector<Elem>&)): Delete.
11018 (data_buf::file_write): Call ::fwrite directly.
11019
11020 2017-06-12 Pedro Alves <palves@redhat.com>
11021
11022 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
11023 std::vector::erase.
11024
11025 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
11026
11027 Code cleanup: C++ify .gdb_index producer.
11028 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
11029 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
11030 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
11031 (create_strtab, add_string): Remove.
11032 (file_write, data_buf): New.
11033 (struct symtab_index_entry): Use std::vector for cu_indices.
11034 (struct mapped_symtab): Use std::vector for data.
11035 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
11036 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
11037 Remove.
11038 (find_slot): Change return type. Update it to the new data structures.
11039 (hash_expand, add_index_entry): Update it to the new data structures.
11040 (offset_type_compare): Remove.
11041 (uniquify_cu_indices): Update it to the new data structures.
11042 (c_str_view, c_str_view_hasher, vector_hasher): New.
11043 (add_indices_to_cpool): Remove.
11044 (write_hash_table): Update it to the new data structures.
11045 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
11046 (eq_psymtab_cu_index): Remove.
11047 (psym_index_map): New typedef.
11048 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
11049 reference and std::unordered_map for cu_index_htab.
11050 (add_address_entry, add_address_entry_worker, write_address_map)
11051 (write_psymbols): Update it to the new data structures.
11052 (write_obstack): Remove.
11053 (struct signatured_type_index_data): Change types_list to a data_buf
11054 reference and psyms_seen to a std::unordered_set reference.
11055 (write_one_signatured_type, recursively_write_psymbols)
11056 (write_psymtabs_to_index): Update it to the new data structures.
11057
11058 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
11059
11060 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
11061 separate-debug-file commands.
11062 * symfile.h (separate_debug_file_debug): New global.
11063 * symfile.c (separate_debug_file_debug): New global.
11064 (separate_debug_file_exists, find_separate_debug_file): Add
11065 debug output.
11066 (_initialize_symfile): Add "set debug separate-debug-file"
11067 command.
11068 * build-id.c (build_id_to_debug_bfd,
11069 find_separate_debug_file_by_buildid): Add debug output.
11070
11071 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
11072
11073 * gdbarch.sh (displaced_step_free_closure): Remove.
11074 * gdbarch.h, gdbarch.c: Re-generate.
11075 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
11076 displaced_step_free_closure.
11077 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
11078 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
11079 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
11080 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11081 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
11082 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11083 * arch-utils.h (simple_displaced_step_free_closure): Remove.
11084 * arch-utils.c (simple_displaced_step_free_closure): Remove.
11085 * infrun.c (displaced_step_clear): Call xfree instead of
11086 gdbarch_displaced_step_free_closure.
11087
11088 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
11089
11090 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
11091 NULL".
11092
11093 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11094
11095 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
11096 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
11097 (mn10300_push_dummy_call): Likewise.
11098
11099 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11100
11101 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
11102
11103 2017-06-08 Alan Hayward <alan.hayward@arm.com>
11104
11105 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
11106
11107 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11108
11109 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
11110 able to start inferiors using a shell.
11111 (New remote packets): Announce new packet "QStartupWithShell".
11112 * remote.c: Add PACKET_QStartupWithShell.
11113 (extended_remote_create_inferior): Handle new
11114 PACKET_QStartupWithShell.
11115 (remote_protocol_features) <QStartupWithShell>: New entry for
11116 PACKET_QStartupWithShell.
11117 (_initialize_remote): Call "add_packet_config_cmd" for
11118 QStartupShell.
11119
11120 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11121 Pedro Alves <palves@redhat.com>
11122
11123 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
11124 and "nat/fork-inferior.h".
11125 * common/common-inferior.h: New file, with contents from
11126 "gdb/inferior.h".
11127 * commom/common-utils.c: Include "common-utils.h".
11128 (stringify_argv): New function.
11129 * common/common-utils.h (stringify_argv): New prototype.
11130 * configure.nat: Add "fork-inferior.o" as a dependency for
11131 "*linux*", "fbsd*" and "nbsd*" hosts.
11132 * corefile.c (get_exec_file): Update comment.
11133 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
11134 instead of "startup_inferior".
11135 (darwin_create_inferior): Call "add_thread_silent" after
11136 "fork_inferior".
11137 * fork-child.c: Cleanup unnecessary includes.
11138 (SHELL_FILE): Move to "common/common-fork-child.c".
11139 (environ): Likewise.
11140 (exec_wrapper): Initialize.
11141 (get_exec_wrapper): New function.
11142 (breakup_args): Move to "common/common-fork-child.c"; rename to
11143 "breakup_args_for_exec".
11144 (escape_bang_in_quoted_argument): Move to
11145 "common/common-fork-child.c".
11146 (saved_ui): New variable.
11147 (prefork_hook): New function.
11148 (postfork_hook): Likewise.
11149 (postfork_child_hook): Likewise.
11150 (gdb_startup_inferior): Likewise.
11151 (fork_inferior): Move to "common/common-fork-child.c". Update
11152 function to support gdbserver.
11153 (startup_inferior): Likewise.
11154 * gdbcore.h (get_exec_file): Remove declaration.
11155 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
11156 instead of "startup_inferior". Call "add_thread_silent" after
11157 "fork_inferior".
11158 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
11159 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
11160 instead of "startup_inferior". Call "add_thread_silent" after
11161 "fork_inferior".
11162 * inferior.h: Include "common-inferior.h".
11163 (trace_start_error): Move to "common/common-utils.h".
11164 (trace_start_error_with_name): Likewise.
11165 (fork_inferior): Move prototype to "nat/fork-inferior.h".
11166 (startup_inferior): Likewise.
11167 (gdb_startup_inferior): New prototype.
11168 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
11169 * nat/fork-inferior.h: New file.
11170 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
11171 instead of "startup_inferior". Call "add_thread_silent" after
11172 "fork_inferior".
11173 * target.h (target_terminal_init): Move prototype to
11174 "target/target.h".
11175 (target_terminal_inferior): Likewise.
11176 (target_terminal_ours): Likewise.
11177 * target/target.h (target_terminal_init): New prototype, moved
11178 from "target.h".
11179 (target_terminal_inferior): Likewise.
11180 (target_terminal_ours): Likewise.
11181 * utils.c (gdb_flush_out_err): New function.
11182
11183 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11184
11185 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
11186 * common/common-gdbthread.h: New file, with parts from
11187 "gdb/gdbthread.h".
11188 * gdbthread.h: Include "common-gdbthread.h".
11189 (switch_to_thread): Moved to "common/common-gdbthread.h".
11190
11191 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
11192
11193 * Makefile.in (SFILES): Add "common/job-control.c".
11194 (HFILES_NO_SRCDIR): Add "common/job-control.h".
11195 (COMMON_OBS): Add "job-control.o".
11196 * common/job-control.c: New file, with contents from
11197 "gdb/inflow.c".
11198 * common/job-control.h: New file, with contents from "terminal.h".
11199 * fork-child.c: Include "job-control.h".
11200 * inflow.c: Include "job-control.h".
11201 (gdb_setpgid): Move to "common/common-inflow.c".
11202 (_initialize_inflow): Move setting of "job_control" to
11203 "handle_job_control".
11204 * terminal.h (job_control): Moved to "common/common-terminal.h".
11205 (gdb_setpgid): Likewise.
11206 * top.c: Include "job_control.h".
11207 * utils.c: Likewise.
11208 (job_control): Moved to "job-control.c".
11209
11210 2017-06-07 Pedro Alves <palves@redhat.com>
11211
11212 * Makefile.in (SFILES): Add gdb_regex.c.
11213 (COMMON_OBS): Add gdb_regex.o.
11214 * ada-lang.c (ada_add_standard_exceptions)
11215 (ada_add_exceptions_from_frame, name_matches_regex)
11216 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
11217 parameter type to compiled_regex. Adjust.
11218 (ada_exceptions_list): Use compiled_regex.
11219 * break-catch-throw.c (exception_catchpoint::pattern): Now a
11220 std::unique_ptr<compiled_regex>.
11221 (exception_catchpoint::~exception_catchpoint): Remove regfree
11222 call.
11223 (check_status_exception_catchpoint): Adjust to use compiled_regex.
11224 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
11225 * breakpoint.c (solib_catchpoint::compiled): Now a
11226 std::unique_ptr<compiled_regex>.
11227 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
11228 (check_status_catch_solib): Adjust to use compiled_regex.
11229 (add_solib_catchpoint): Adjust to use compiled_regex.
11230 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
11231 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
11232 compiled_regex reference. Adjust to use it.
11233 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
11234 declaration. Include "gdb_regex.h".
11235 (apropos_cmd): Change regex parameter to compiled_regex reference.
11236 * gdb_regex.c: New file.
11237 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
11238 declarations.
11239 (class compiled_regex): New.
11240 * linux-tdep.c: Include "common/gdb_optional.h".
11241 (struct mapping_regexes): New, factored out from
11242 mapping_is_anonymous_p, and adjusted to use compiled_regex.
11243 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
11244 gdb::optional and remove cleanups. Adjust to compiled_regex.
11245 * probe.c: Include "common/gdb_optional.h".
11246 (collect_probes): Use compiled_regex and gdb::optional and remove
11247 cleanups.
11248 * skip.c: Include "common/gdb_optional.h".
11249 (skiplist_entry::compiled_function_regexp): Now a
11250 gdb::optional<compiled_regex>.
11251 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
11252 (free_skiplist_entry): Remove regfree call.
11253 (compile_skip_regexp, skip_rfunction_p): Adjust to use
11254 compiled_regex and gdb::optional.
11255 * symtab.c: Include "common/gdb_optional.h".
11256 (search_symbols): Use compiled_regex and gdb::optional.
11257 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
11258 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
11259 to gdb_regex.c.
11260
11261 2017-06-07 Alan Hayward <alan.hayward@arm.com>
11262
11263 * regcache.c (regcache::save): Avoid buffer use.
11264 (regcache::dump): Likewise.
11265
11266 2017-06-07 Alan Hayward <alan.hayward@arm.com>
11267
11268 * sh-tdep.c (sh_pseudo_register_read): Remove
11269 MAX_REGISTER_SIZE.
11270 (sh_pseudo_register_write): Likewise.
11271 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
11272 (sh64_pseudo_register_write): Likewise
11273
11274 2017-06-07 Alan Hayward <alan.hayward@arm.com>
11275
11276 * aarch64-tdep.c (aarch64_store_return_value): Use
11277 V_REGISTER_SIZE.
11278 (aarch64_pseudo_read_value): Likewise.
11279 (aarch64_pseudo_write): Likewise.
11280
11281 2017-06-06 Yao Qi <yao.qi@linaro.org>
11282
11283 * regformats/regdef.h (set_register_cache): Remove the
11284 declaration.
11285
11286 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11287
11288 * frame.c (frame_unwind_register_signed): Use
11289 frame_unwind_register_value.
11290
11291 2017-06-06 Pedro Alves <palves@redhat.com>
11292
11293 PR breakpoints/21553
11294 * breakpoint.c (create_breakpoints_sal_default)
11295 (init_breakpoint_sal, create_breakpoint_sal): Use
11296 gdb::unique_xmalloc_ptr for string parameters.
11297 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11298 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
11299 (base_breakpoint_create_breakpoints_sal)
11300 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
11301 (strace_marker_create_breakpoints_sal)
11302 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
11303 string parameters.
11304 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
11305 gdb::unique_xmalloc_ptr for string parameters.
11306 (create_breakpoint): Constify 'extra_string' and 'cond_string'
11307 parameters.
11308
11309 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11310
11311 * alpha-tdep.c (alpha_register_to_value): Use
11312 get_frame_register_value.
11313 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
11314
11315 2017-06-06 Alan Hayward <alan.hayward@arm.com>
11316
11317 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
11318 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
11319 (ia64_value_to_register): Likewise.
11320 (ia64_extract_return_value): Likewise.
11321 (ia64_store_return_value): Likewise.
11322 (ia64_push_dummy_call): Likewise.
11323
11324 2017-06-04 Joel Brobecker <brobecker@adacore.com>
11325
11326 GDB 8.0 released.
11327
11328 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
11329
11330 * x86-linux-nat.c (struct arch_lwp_info): Remove.
11331
11332 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
11333
11334 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
11335 parameter.
11336 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
11337
11338 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
11339
11340 * event-loop.c (poll_timers): Unallocate timer using delete
11341 instead of xfree.
11342
11343 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11344
11345 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
11346 (struct breakpoint) <~breakpoint>: New.
11347 (struct watchpoint): Inherit from breakpoint.
11348 <~watchpoint>: New.
11349 <base>: Remove.
11350 (struct tracepoint): Inherit from breakpoint.
11351 <base>: Remove.
11352 * breakpoint.c (longjmp_breakpoint_ops): Remove.
11353 (struct longjmp_breakpoint): Inherit from breakpoint.
11354 <~longjmp_breakpoint>: New.
11355 <base>: Remove.
11356 (new_breakpoint_from_type): Remove casts.
11357 (watchpoint_in_thread_scope): Remove reference to base field.
11358 (watchpoint_del_at_next_stop): Likewise.
11359 (update_watchpoint): Likewise.
11360 (watchpoint_check): Likewise.
11361 (bpstat_check_watchpoint): Likewise.
11362 (set_longjmp_breakpoint): Likewise.
11363 (struct fork_catchpoint): Inherit from breakpoint.
11364 <base>: Remove.
11365 (struct solib_catchpoint): Inherit from breakpoint.
11366 <~solib_catchpoint>: New.
11367 <base>: Remove.
11368 (dtor_catch_solib): Change to ...
11369 (solib_catchpoint::~solib_catchpoint): ... this.
11370 (breakpoint_hit_catch_solib): Remove reference to base field.
11371 (add_solib_catchpoint): Likewise.
11372 (create_fork_vfork_event_catchpoint): Likewise.
11373 (struct exec_catchpoint): Inherit from breakpoint.
11374 <~exec_catchpoint>: New.
11375 <base>: Remove.
11376 (dtor_catch_exec): Change to ...
11377 (exec_catchpoint::~exec_catchpoint): ... this.
11378 (dtor_watchpoint): Change to ...
11379 (watchpoint::~watchpoint): ... this.
11380 (watch_command_1): Remove reference to base field.
11381 (catch_exec_command_1): Likewise.
11382 (base_breakpoint_dtor): Change to ...
11383 (breakpoint::~breakpoint): ... this.
11384 (base_breakpoint_ops): Remove dtor field value.
11385 (longjmp_bkpt_dtor): Change to ...
11386 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
11387 (strace_marker_create_breakpoints_sal): Remove reference to base
11388 field.
11389 (delete_breakpoint): Don't manually call breakpoint destructor.
11390 (create_tracepoint_from_upload): Remove reference to base field.
11391 (trace_pass_set_count): Likewise.
11392 (initialize_breakpoint_ops): Don't initialize
11393 momentary_breakpoint_ops, don't set dtors.
11394 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
11395 <~ada_catchpoint>: New.
11396 <base>: Remove.
11397 (create_excep_cond_exprs): Remove reference to base field.
11398 (dtor_exception): Change to ...
11399 (ada_catchpoint::~ada_catchpoint): ... this.
11400 (dtor_catch_exception): Remove.
11401 (dtor_catch_exception_unhandled): Remove.
11402 (dtor_catch_assert): Remove.
11403 (create_ada_exception_catchpoint): Remove reference to base
11404 field.
11405 (initialize_ada_catchpoint_ops): Don't set dtors.
11406 * break-catch-sig.c (struct signal_catchpoint): Inherit from
11407 breakpoint.
11408 <~signal_catchpoint>: New.
11409 <base>: Remove.
11410 (signal_catchpoint_dtor): Change to ...
11411 (signal_catchpoint::~signal_catchpoint): ... this.
11412 (create_signal_catchpoint): Remove reference to base field.
11413 (initialize_signal_catchpoint_ops): Don't set dtor.
11414 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
11415 from breakpoint.
11416 <~syscall_catchpoint>: New.
11417 <base>: Remove.
11418 (dtor_catch_syscall): Change to ...
11419 (syscall_catchpoint::~syscall_catchpoint): ... this.
11420 (create_syscall_event_catchpoint): Remove reference to base
11421 field.
11422 (initialize_syscall_catchpoint_ops): Don't set dtor.
11423 * break-catch-throw.c (struct exception_catchpoint): Inherit
11424 from breakpoint.
11425 <~exception_catchpoint>: New.
11426 <base>: Remove.
11427 (dtor_exception_catchpoint): Change to ...
11428 (exception_catchpoint::~exception_catchpoint): ... this.
11429 (handle_gnu_v3_exceptions): Remove reference to base field.
11430 (initialize_throw_catchpoint_ops): Don't set dtor.
11431 * ctf.c (ctf_get_traceframe_address): Remove reference to base
11432 field.
11433 * remote.c (remote_get_tracepoint_status): Likewise.
11434 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
11435 * tracefile.c (tracefile_fetch_registers): Likewise.
11436 * tracepoint.c (actions_command): Likewise.
11437 (validate_actionline): Likewise.
11438 (tfind_1): Likewise.
11439 (get_traceframe_location): Likewise.
11440 (find_matching_tracepoint_location): Likewise.
11441 (parse_tracepoint_status): Likewise.
11442 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
11443
11444 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11445
11446 * breakpoint.c (struct longjmp_breakpoint): New struct.
11447 (is_tracepoint_type): Change return type to bool.
11448 (is_longjmp_type): New function.
11449 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
11450 (set_raw_breakpoint_without_location): Use
11451 new_breakpoint_from_type.
11452 (set_raw_breakpoint): Likewise.
11453
11454 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
11455
11456 * breakpoint.c (new_breakpoint_from_type): New function.
11457 (create_breakpoint_sal): Use new_breakpoint_from_type and
11458 unique_ptr.
11459 (create_breakpoint): Likewise.
11460
11461 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
11462
11463 * memattr.c (mem_info_command): Rename to ...
11464 (info_mem_command): ... this.
11465 (mem_enable_command): Rename to ...
11466 (enable_mem_command): ... this.
11467 (mem_disable_command): Rename to ...
11468 (disable_mem_command): ... this.
11469 (mem_delete_command): Rename to ...
11470 (delete_mem_command): ... this.
11471 (_initialize_mem): Adjust function names.
11472
11473 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11474
11475 * btrace.c (handle_pt_insn_events): New.
11476 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
11477 STATUS. Split into this and ...
11478 (handle_pt_insn_event_flags): ... this.
11479
11480 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
11481
11482 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
11483 and struct pt_insn.resynced.
11484 * configure: Regenerated.
11485 * config.in: Regenerated.
11486
11487 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11488
11489 * btrace.c (ftrace_find_call_by_number): New function.
11490 (ftrace_new_function): Store objects, not pointers.
11491 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
11492 ftrace_new_gap, ftrace_update_function,
11493 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
11494 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
11495 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
11496 btrace_ends_with_single_insn, btrace_call_get): Account for
11497 btrace_thread_info::functions now storing objects.
11498 * btrace.h (struct btrace_thread_info): Add constructor.
11499 (struct btrace_thread_info) <functions>: Make std::vector.
11500 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
11501 Initialize with default values.
11502 * record-btrace.c (record_btrace_frame_sniffer): Account for
11503 btrace_thread_info::functions now storing objects.
11504
11505 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11506
11507 * btrace.c: Remove typedef bfun_s.
11508 (ftrace_new_gap): Directly add gaps to the list of gaps.
11509 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
11510 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
11511 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
11512 instead of gdb VEC.
11513
11514 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11515
11516 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
11517 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
11518 with btrace_thread_info::next_segment and
11519 btrace_thread_info::prev_segment.
11520 * btrace.h: Remove struct btrace_func_link.
11521 (struct btrace_function): Replace pair of function segment pointers
11522 with pair of indices.
11523 * python/py-record-btrace.c (btpy_call_prev_sibling,
11524 btpy_call_next_sibling): Replace references to
11525 btrace_thread_info::segment with btrace_thread_info::next_segment and
11526 btrace_thread_info::prev_segment.
11527 * record-btrace.c (record_btrace_frame_this_id): Use
11528 btrace_find_call_by_number.
11529
11530 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11531
11532 * btrace.c (ftrace_new_function, ftrace_fixup_level,
11533 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
11534 btrace_insn_next, btrace_insn_prev): Remove references to
11535 btrace_thread_info::flow.
11536 * btrace.h (struct btrace_function): Remove FLOW.
11537
11538 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11539
11540 * btrace.c (ftrace_find_call_by_number): New function.
11541 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
11542 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
11543 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
11544 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
11545 index.
11546 * btrace.h (struct btrace_function): Turn UP into an index.
11547 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
11548 as an index.
11549 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
11550 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
11551 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
11552
11553 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11554
11555 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11556 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11557 ftrace_update_function, ftrace_compute_global_level_offset,
11558 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
11559 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
11560 btrace_insn_end, btrace_is_empty): Remove references to
11561 btrace_thread_info::begin and btrace_thread_info::end.
11562 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
11563 (struct btrace_thread_info) <functions>: Adjust comment.
11564 * record-btrace.c (record_btrace_start_replaying): Remove reference to
11565 btrace_thread_info::begin.
11566
11567 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11568
11569 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
11570 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
11571 ftrace_update_function): Remove arguments that implicitly were always
11572 BTINFO->END.
11573 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
11574 Don't pass BTINFO->END.
11575
11576 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11577
11578 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
11579 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
11580 btrace_find_insn_by_number): Replace function segment pointer with
11581 index.
11582 (btrace_insn_cmp): Simplify.
11583 * btrace.h: (struct btrace_insn_iterator) Rename index to
11584 insn_index. Replace function segment pointer with index into function
11585 segment vector.
11586 * record-btrace.c (record_btrace_call_history): Replace function
11587 segment pointer use with index.
11588 (record_btrace_frame_sniffer): Retrieve function call segment through
11589 vector.
11590 (record_btrace_set_replay): Remove defunc't safety check.
11591
11592 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11593
11594 * btrace.c (btrace_ends_with_single_insn): New function.
11595 (btrace_call_get, btrace_call_number, btrace_call_begin,
11596 btrace_call_end, btrace_call_next, btrace_call_prev,
11597 btrace_find_call_by_number): Use index into call segment vector
11598 instead of pointer.
11599 (btrace_call_cmp): Simplify.
11600 * btrace.h (struct btrace_call_iterator): Replace function call segment
11601 pointer with index into vector.
11602 * record-btrace.c (record_btrace_call_history): Use index instead of
11603 pointer.
11604
11605 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11606
11607 * btrace.c (btrace_insn_begin, btrace_insn_end,
11608 btrace_find_insn_by_number): Add btinfo to iterator.
11609 * btrace.h (struct btrace_insn_iterator): Add btinfo.
11610
11611 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11612
11613 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
11614 and save pointers directly.
11615 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
11616 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
11617 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
11618 changed signature of functions.
11619 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
11620 (btrace_fetch): Remove code that adds btrace_function pointers to
11621 vector of btrace_functions.
11622 (btrace_clear): Simplify freeing vector of btrace_functions.
11623
11624 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
11625
11626 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
11627 Replace VEC_* with std::vector functions.
11628 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
11629 (struct btrace_thread_info)<functions>: Change type to std::vector.
11630
11631 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
11632
11633 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
11634 "Removed targets and native configurations" up. Merge duplicate
11635 "New commands" sub-sections. Add "New options" sub-sections.
11636
11637 2017-05-26 Alan Hayward <alan.hayward@arm.com>
11638
11639 * defs.h (copy_integer_to_size): New declaration.
11640 * findvar.c (copy_integer_to_size): New function.
11641 (do_cint_test): New selftest function.
11642 (copy_integer_to_size_test): Likewise.
11643 (_initialize_findvar): Likewise.
11644 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
11645 (mips_fbsd_collect_reg): Use raw_collect_integer.
11646 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
11647 (mips64_fill_gregset): Use raw_collect_integer
11648 (mips64_fill_fpregset): Use raw_supply_integer.
11649 * regcache.c (regcache::raw_supply_integer): New function.
11650 (regcache::raw_collect_integer): Likewise.
11651 * regcache.h: (regcache::raw_supply_integer): New declaration.
11652 (regcache::raw_collect_integer): Likewise.
11653
11654 2017-05-24 Yao Qi <yao.qi@linaro.org>
11655
11656 * Makefile.in (SFILES): Add gdbarch-selftests.c.
11657 (COMMON_OBS): Add gdbarch-selftests.o.
11658 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
11659 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
11660 * gdbarch-selftests.c: New file.
11661 * regcache.h (regcache) <~regcache>: Mark it virtual if
11662 GDB_SELF_TEST.
11663 <raw_write>: Likewise.
11664
11665 2017-05-24 Yao Qi <yao.qi@linaro.org>
11666
11667 * regcache.c (current_regcache): Change it to
11668 regcache::current_regcache.
11669 (regcache_observer_target_changed): Update.
11670 (regcache_thread_ptid_changed): Make it a regcache static
11671 method.
11672 (regcache_thread_ptid_changed): Update.
11673 (class regcache_access): New.
11674 (current_regcache_test): Update.
11675 (_initialize_regcache): Update.
11676 * regcache.h: Include forward_list.
11677 (regcache): Declare regcache_thread_ptid_changed and declare
11678 registers_changed_ptid as friend.
11679
11680 2017-05-24 Yao Qi <yao.qi@linaro.org>
11681
11682 * i387-tdep.c (i387_register_to_value): Use register_size
11683 instead of TYPE_LENGTH.
11684 * m68k-tdep.c (m68k_register_to_value): Likewise.
11685
11686 2017-05-24 Yao Qi <yao.qi@linaro.org>
11687
11688 * i387-tdep.c (i387_convert_register_p): Return false if type
11689 code isn't TYPE_CODE_FLT.
11690
11691 2017-05-24 Yao Qi <yao.qi@linaro.org>
11692
11693 * alpha-tdep.c (alpha_convert_register_p): Return true if type
11694 length is 4.
11695 (alpha_register_to_value): Remove type length check.
11696 (alpha_value_to_register): Likewise.
11697
11698 2017-05-24 Yao Qi <yao.qi@linaro.org>
11699
11700 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
11701 TYPE_CODE_FLT.
11702
11703 2017-05-24 Yao Qi <yao.qi@linaro.org>
11704
11705 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
11706 TYPE_CODE_FLT or not.
11707
11708 2017-05-24 Yao Qi <yao.qi@linaro.org>
11709
11710 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
11711 * avr-tdep.c (avr_gdbarch_init): Likewise.
11712 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11713 * cris-tdep.c (cris_gdbarch_init): Likewise.
11714 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11715 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11716 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11717 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
11718 * mep-tdep.c (mep_gdbarch_init): Likewise.
11719 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11720 * mips-tdep.c (mips_gdbarch_init): Likewise.
11721 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11722 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11723 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11724 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11725 * v850-tdep.c (v850_gdbarch_init): Likewise.
11726
11727 2017-05-24 Yao Qi <yao.qi@linaro.org>
11728
11729 * selftest-arch.c (tests_with_arch): Call registers_changed
11730 and reinit_frame_cache.
11731 * selftest.c (run_self_tests): Likewise.
11732
11733 2017-05-24 Yao Qi <yao.qi@linaro.org>
11734
11735 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
11736 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
11737
11738 2017-05-24 Yao Qi <yao.qi@linaro.org>
11739
11740 * rl78-tdep.c (rl78_gdbarch_init): Don't call
11741 set_gdbarch_print_insn.
11742
11743 2017-05-24 Yao Qi <yao.qi@linaro.org>
11744
11745 * h8300-tdep.c (h8300_gdbarch_init): Don't call
11746 set_gdbarch_print_insn.
11747
11748 2017-05-24 Yao Qi <yao.qi@linaro.org>
11749
11750 * alpha-tdep.c (alpha_gdbarch_init): Don't call
11751 set_gdbarch_print_insn.
11752 * arc-tdep.c (arc_gdbarch_init): Likewise.
11753 * arch-utils.c: include dis-asm.h.
11754 (default_print_insn): New function.
11755 * arch-utils.h (default_print_insn): Declare.
11756 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
11757 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
11758 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
11759 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
11760 * frv-tdep.c (frv_gdbarch_init): Likewise.
11761 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
11762 * gdbarch.sh (print_insn): Use default_print_insn.
11763 * gdbarch.c: Regenerated.
11764 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
11765 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
11766 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
11767 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
11768 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11769 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
11770 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
11771 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
11772 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
11773 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
11774 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
11775 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11776 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
11777 * mt-tdep.c (mt_gdbarch_init): Likewise.
11778 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11779 * nios2-tdep.c (nios2_print_insn): Remove.
11780 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
11781 * rx-tdep.c (rx_gdbarch_init): Likewise.
11782 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
11783 * score-tdep.c (score_print_insn): Remove.
11784 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
11785 * sh-tdep.c (sh_gdbarch_init): Likewise.
11786 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
11787 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11788 * tic6x-tdep.c (tic6x_print_insn): Remove.
11789 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
11790 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
11791 * v850-tdep.c (v850_gdbarch_init): Likewise.
11792 * vax-tdep.c (vax_gdbarch_init): Likewise.
11793 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11794 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
11795
11796 2017-05-23 John Baldwin <jhb@FreeBSD.org>
11797
11798 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
11799 (MIPS_FP0_REGNUM): Remove.
11800 (MIPS_FSR_REGNUM): Remove.
11801 (mips_fbsd_supply_fpregs): Use mips_regnum.
11802 (mips_fbsd_supply_gregs): Likewise.
11803 (mips_fbsd_collect_fpregs): Likewise.
11804 (mips_fbsd_collect_gregs): Likewise.
11805
11806 2017-05-23 John Baldwin <jhb@FreeBSD.org>
11807
11808 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
11809 (getpfpregs_supplies): New function.
11810 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
11811 getfpregs_supplies.
11812 (mips_fbsd_store_inferior_registers): Likewise.
11813
11814 2017-05-22 Pedro Alves <palves@redhat.com>
11815
11816 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
11817 maintainer.
11818
11819 2017-05-22 Alan Hayward <alan.hayward@arm.com>
11820
11821 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
11822 (store_register): Likewise.
11823 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
11824 (get_decimal_float_return_value): Likewise.
11825 (do_ppc_sysv_return_value): Likewise.
11826 (ppc64_sysv_abi_push_integer): Likewise.
11827 (ppc64_sysv_abi_push_freg): Likewise.
11828 (ppc64_sysv_abi_return_value_base): Likewise.
11829 (ppc64_sysv_abi_return_value): Likewise.
11830 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
11831 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
11832 * rs6000-nat.c: Likewise.
11833 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
11834 (rs6000_value_to_register): Likewise.
11835 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
11836
11837 2017-05-21 Tom Tromey <tom@tromey.com>
11838
11839 PR rust/21466:
11840 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
11841 arrays as "[T]", not "[T; ]".
11842
11843 2017-05-19 Tom Tromey <tom@tromey.com>
11844
11845 PR rust/21484:
11846 * rust-lang.c (exp_descriptor_rust): New function.
11847 (rust_language_defn): Use it.
11848 * p-lang.c (pascal_language_defn): Update.
11849 * opencl-lang.c (opencl_language_defn): Update.
11850 * objc-lang.c (objc_language_defn): Update.
11851 * m2-lang.c (m2_language_defn): Update.
11852 * language.h (struct language_defn)
11853 <la_watch_location_expression>: New member.
11854 * language.c (unknown_language_defn, auto_language_defn)
11855 (local_language_defn): Update.
11856 * go-lang.c (go_language_defn): Update.
11857 * f-lang.c (f_language_defn): Update.
11858 * d-lang.c (d_language_defn): Update.
11859 * c-lang.h (c_watch_location_expression): Declare.
11860 * c-lang.c (c_watch_location_expression): New function.
11861 (c_language_defn, cplus_language_defn, asm_language_defn)
11862 (minimal_language_defn): Use it.
11863 * breakpoint.c (watch_command_1): Call
11864 la_watch_location_expression.
11865 * ada-lang.c (ada_language_defn): Update.
11866
11867 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11868
11869 PR tui/21482
11870 * gdb_curses.h (NOMACROS): Define.
11871 (NCURSES_NOMACROS): Define.
11872
11873 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11874
11875 PR tui/21482
11876 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
11877 arg to char *.
11878 * tui/tui-wingeneral.c (box_win): Likewise.
11879 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
11880 (tui_show_source_line): Likewise.
11881 (tui_show_exec_info_content): Likewise.
11882
11883 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
11884
11885 * sparc-tdep.c (sparc_structure_return_p)
11886 (sparc_arg_on_registers_p): New functions.
11887 (sparc32_store_arguments): Use them.
11888 * sparc64-tdep.c (sparc64_16_byte_align_p)
11889 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
11890 Handle TYPE_CODE_ARRAY.
11891
11892 2017-05-17 Yao Qi <yao.qi@linaro.org>
11893
11894 * cli/cli-decode.c (add_alias_cmd): New function.
11895 * command.h (add_alias_cmd): Declare.
11896 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
11897 instead call add_alias_cmd.
11898
11899 2017-05-17 Pedro Alves <palves@redhat.com>
11900
11901 * Makefile.in (nat_extra_makefile_frag): Rename to ...
11902 (nat_makefile_frag): ... this. All references updated.
11903 * configure.ac: Likewise.
11904 * configure.nat: Likewise. Enhance comments.
11905 * configure: Regenerate.
11906
11907 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
11908
11909 * procfs.c (procfs_create_inferior): Change prototype to match
11910 definition.
11911
11912 2017-05-13 Eli Zaretskii <eliz@gnu.org>
11913
11914 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
11915 C++ compiler warning.
11916
11917 2017-05-12 Tom Tromey <tom@tromey.com>
11918
11919 PR rust/21483:
11920 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
11921 recurse, just call value_struct_elt directly.
11922
11923 2017-05-12 Tom Tromey <tom@tromey.com>
11924
11925 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
11926 OP_RUST_ARRAY>: Fix.
11927
11928 2017-05-12 Tom Tromey <tom@tromey.com>
11929
11930 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
11931
11932 2017-05-09 Yao Qi <yao.qi@linaro.org>
11933
11934 * regcache.c: Include <forward_list>.
11935 (struct regcache_list): Remove.
11936 (current_regcache): Update.
11937 (get_thread_arch_aspace_regcache): Update for std::forward_list.
11938 (regcache_thread_ptid_changed): Likewise.
11939 (registers_changed_ptid): Likewise.
11940 (current_regcache_size): Likewise.
11941
11942 2017-05-09 Yao Qi <yao.qi@linaro.org>
11943
11944 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
11945 (current_regcache_size): New function.
11946 (current_regcache_test): New function.
11947 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
11948
11949 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11950
11951 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
11952 (print_gp_register_row): Use get_frame_register_value.
11953
11954 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11955
11956 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
11957 (mips_supply_fpregset): Likewise.
11958 (mips64_supply_gregset): Likewise.
11959
11960 2017-05-08 Alan Hayward <alan.hayward@arm.com>
11961
11962 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
11963 regcache->raw_supply_zeroed.
11964
11965 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11966
11967 * configure.nat: Rearrange 'case' statements to match
11968 host before cpu.
11969
11970 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
11971
11972 * Makefile.in: Remove "@host_makefile_frag@". Add variables
11973 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
11974 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
11975 "@nat_extra_makefile_frag@".
11976 (Makefile): Remove dependency on "@frags@".
11977 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
11978 (data-directory/Makefile): Likewise.
11979 * config/aarch64/linux.mh: Deleted; moved contents to
11980 "gdb/configure.nat".
11981 * config/alpha/alpha-linux.mh: Likewise.
11982 * config/alpha/nbsd.mh: Likewise.
11983 * config/arm/linux.mh: Likewise.
11984 * config/arm/nbsdelf.mh: Likewise.
11985 * config/i386/cygwin.mh: Likewise.
11986 * config/i386/cygwin64.mh: Likewise.
11987 * config/i386/darwin.mh: Likewise.
11988 * config/i386/fbsd.mh: Likewise.
11989 * config/i386/fbsd64.mh: Likewise.
11990 * config/i386/go32.mh: Likewise.
11991 * config/i386/i386gnu.mh: Likewise.
11992 * config/i386/i386sol2.mh: Likewise.
11993 * config/i386/linux.mh: Likewise.
11994 * config/i386/linux64.mh: Likewise.
11995 * config/i386/mingw.mh: Likewise.
11996 * config/i386/mingw64.mh: Likewise.
11997 * config/i386/nbsd64.mh: Likewise.
11998 * config/i386/nbsdelf.mh: Likewise.
11999 * config/i386/nto.mh: Likewise.
12000 * config/i386/obsd.mh: Likewise.
12001 * config/i386/obsd64.mh: Likewise.
12002 * config/i386/sol2-64.mh: Likewise.
12003 * config/ia64/linux.mh: Likewise.
12004 * config/m32r/linux.mh: Likewise.
12005 * config/m68k/linux.mh: Likewise.
12006 * config/m68k/nbsdelf.mh: Likewise.
12007 * config/m68k/obsd.mh: Likewise.
12008 * config/m88k/obsd.mh: Likewise.
12009 * config/mips/fbsd.mh: Likewise.
12010 * config/mips/linux.mh: Likewise.
12011 * config/mips/nbsd.mh: Likewise.
12012 * config/mips/obsd64.mh: Likewise.
12013 * config/pa/linux.mh: Likewise.
12014 * config/pa/nbsd.mh: Likewise.
12015 * config/pa/obsd.mh: Likewise.
12016 * config/powerpc/aix.mh: Likewise.
12017 * config/powerpc/fbsd.mh: Likewise.
12018 * config/powerpc/linux.mh: Likewise.
12019 * config/powerpc/nbsd.mh: Likewise.
12020 * config/powerpc/obsd.mh: Likewise.
12021 * config/powerpc/ppc64-linux.mh: Likewise.
12022 * config/powerpc/spu-linux.mh: Likewise.
12023 * config/s390/linux.mh: Likewise.
12024 * config/sh/nbsd.mh: Likewise.
12025 * config/sparc/fbsd.mh: Likewise.
12026 * config/sparc/linux.mh: Likewise.
12027 * config/sparc/linux64.mh: Likewise.
12028 * config/sparc/nbsd64.mh: Likewise.
12029 * config/sparc/nbsdelf.mh: Likewise.
12030 * config/sparc/obsd64.mh: Likewise.
12031 * config/sparc/sol2.mh: Likewise.
12032 * config/tilegx/linux.mh: Likewise.
12033 * config/vax/nbsdelf.mh: Likewise.
12034 * config/vax/obsd.mh: Likewise.
12035 * config/xtensa/linux.mh: Likewise.
12036 * config/i386/i386gnu.mn: New file, with excerpts from
12037 "config/i386/i386gnu.mh".
12038 * configure: Regenerate.
12039 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
12040 *.mh files under "gdb/config".
12041 * configure.nat: New file, with contents from the
12042 "gdb/config/*/*.mh" files.
12043
12044 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
12045
12046 * btrace.c (btrace_clear): Free insn vector.
12047
12048 2017-05-05 Pedro Alves <palves@redhat.com>
12049
12050 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
12051 * configure: Regenerate.
12052
12053 2017-05-04 Pedro Alves <palves@redhat.com>
12054
12055 * Makefile.in (SFILES): Add progspace-and-thread.c.
12056 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
12057 (COMMON_OBS): Add progspace-and-thread.o.
12058 * breakpoint.c: Include "progspace-and-thread.h".
12059 (update_inserted_breakpoint_locations)
12060 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
12061 Use scoped_restore_current_pspace_and_thread.
12062 (create_std_terminate_master_breakpoint): Use
12063 scoped_restore_current_program_space.
12064 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
12065 (print_breakpoint_location): Use
12066 scoped_restore_current_program_space.
12067 (bp_loc_is_permanent): Use
12068 scoped_restore_current_pspace_and_thread.
12069 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
12070 (download_tracepoint_locations): Use
12071 scoped_restore_current_pspace_and_thread.
12072 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
12073 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
12074 (enum step_over_calls_kind): Moved from inferior.h.
12075 (class scoped_restore_current_thread): New class.
12076 * gdbthread.h (make_cleanup_restore_current_thread): Delete
12077 declaration.
12078 (scoped_restore_current_thread): New class.
12079 * infcmd.c: Include "common/gdb_optional.h".
12080 (continue_1, proceed_after_attach): Use
12081 scoped_restore_current_thread.
12082 (notice_new_inferior): Use scoped_restore_current_thread.
12083 * inferior.c: Include "progspace-and-thread.h".
12084 (restore_inferior, save_current_inferior): Delete.
12085 (add_inferior_command, clone_inferior_command): Use
12086 scoped_restore_current_pspace_and_thread.
12087 * inferior.h (scoped_restore_current_inferior): New class.
12088 * infrun.c: Include "progspace-and-thread.h" and
12089 "common/gdb_optional.h".
12090 (follow_fork_inferior): Use
12091 scoped_restore_current_pspace_and_thread.
12092 (scoped_restore_exited_inferior): New class.
12093 (handle_vfork_child_exec_or_exit): Use
12094 scoped_restore_exited_inferior,
12095 scoped_restore_current_pspace_and_thread,
12096 scoped_restore_current_thread and scoped_restore.
12097 (fetch_inferior_event): Use scoped_restore_current_thread.
12098 * linespec.c (decode_line_full, decode_line_1): Use
12099 scoped_restore_current_program_space.
12100 * mi/mi-main.c: Include "progspace-and-thread.h".
12101 (exec_continue): Use scoped_restore_current_thread.
12102 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
12103 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
12104 * proc-service.c (ps_pglobal_lookup): Use
12105 scoped_restore_current_program_space.
12106 * progspace-and-thread.c: New file.
12107 * progspace-and-thread.h: New file.
12108 * progspace.c (release_program_space, clone_program_space): Use
12109 scoped_restore_current_program_space.
12110 (restore_program_space, save_current_program_space)
12111 (save_current_space_and_thread): Delete.
12112 (switch_to_program_space_and_thread): Moved to
12113 progspace-and-thread.c.
12114 * progspace.h (save_current_program_space)
12115 (save_current_space_and_thread): Delete declarations.
12116 (scoped_restore_current_program_space): New class.
12117 * remote.c (remote_btrace_maybe_reopen): Use
12118 scoped_restore_current_thread.
12119 * symtab.c: Include "progspace-and-thread.h".
12120 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
12121 * thread.c (print_thread_info_1): Use
12122 scoped_restore_current_thread.
12123 (struct current_thread_cleanup): Delete.
12124 (do_restore_current_thread_cleanup)
12125 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
12126 (scoped_restore_current_thread::~scoped_restore_current_thread):
12127 ... this new dtor.
12128 (make_cleanup_restore_current_thread): Rename/convert to ...
12129 (scoped_restore_current_thread::scoped_restore_current_thread):
12130 ... this new ctor.
12131 (thread_apply_all_command): Use scoped_restore_current_thread.
12132 (thread_apply_command): Use scoped_restore_current_thread.
12133 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
12134 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
12135
12136 2017-05-04 Pedro Alves <palves@redhat.com>
12137
12138 * thread.c (make_cleanup_restore_current_thread): Move
12139 find_thread_ptid call before the is_stopped call. Assert that the
12140 thread is found. Replace is_stopped call by checking the thread's
12141 state directly. Remove unnecessary NULL-thread check.
12142
12143 2017-05-04 Pedro Alves <palves@redhat.com>
12144
12145 * corelow.c (thread_section_name): New class.
12146 (get_core_register_section, get_core_siginfo): Use it.
12147
12148 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
12149
12150 * corelow.c (sniff_core_bfd): Remove extra semicolon.
12151 (get_core_register_section): Remove xfree of NULL pointer.
12152
12153 2017-05-03 Alan Hayward <alan.hayward@arm.com>
12154
12155 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
12156 * regcache.c (regcache::raw_supply_zeroed): New function.
12157 * regcache.h (regcache::raw_supply_zeroed): New declaration.
12158
12159 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
12160
12161 * gdbarch.sh: Remove commented out definition of
12162 TARGET_CHAR_BIT.
12163 * gdbarch.h: Re-generate.
12164
12165 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
12166
12167 * configure: Regenerate.
12168
12169 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
12170
12171 * solib-target.c (solib_target_relocate_section_addresses):
12172 Remove num_section_bases, num_bases, segment_bases variables.
12173
12174 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12175
12176 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
12177
12178 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12179
12180 * solib-target.c: Include <vector>
12181 (struct lm_info_target) <~lm_info_target>: Remove.
12182 <segment_bases, section_bases>: Change type to
12183 std::vector<CORE_ADDR>.
12184 (library_list_start_segment, library_list_start_section,
12185 library_list_end_library,
12186 solib_target_relocate_section_addresses): Adjust.
12187
12188 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12189
12190 * gdbarch.sh (software_single_step): Change return type to
12191 std::vector<CORE_ADDR>.
12192 * gdbarch.c, gdbarch.h: Re-generate.
12193 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
12194 Adjust.
12195 (arm_deal_with_atomic_sequence_raw): Adjust.
12196 (thumb_get_next_pcs_raw): Adjust.
12197 (arm_get_next_pcs_raw): Adjust.
12198 (arm_get_next_pcs): Adjust.
12199 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
12200 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
12201 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
12202 (alpha_software_single_step): Adjust.
12203 * alpha-tdep.h (alpha_software_single_step): Adjust.
12204 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
12205 * arm-tdep.c (arm_software_single_step): Adjust.
12206 (arm_breakpoint_kind_from_current_state): Adjust.
12207 * arm-tdep.h (arm_software_single_step): Adjust.
12208 * breakpoint.c (insert_single_step_breakpoint): Adjust.
12209 * cris-tdep.c (cris_software_single_step): Adjust.
12210 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
12211 (micromips_deal_with_atomic_sequence): Adjust.
12212 (deal_with_atomic_sequence): Adjust.
12213 (mips_software_single_step): Adjust.
12214 * mips-tdep.h (mips_software_single_step): Adjust.
12215 * moxie-tdep.c (moxie_software_single_step): Adjust.
12216 * nios2-tdep.c (nios2_software_single_step): Adjust.
12217 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
12218 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
12219 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
12220 * s390-linux-tdep.c (s390_software_single_step): Adjust.
12221 * sparc-tdep.c (sparc_software_single_step): Adjust.
12222 * spu-tdep.c (spu_software_single_step): Adjust.
12223 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
12224
12225 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
12226
12227 * gdbarch.sh: Use semi-colon as field separator instead of colon.
12228 * gdbarch.h: Re-generate.
12229
12230 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12231
12232 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
12233 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
12234 * python/py-instruction.c, python/py-instruction.h: New file.
12235 * python/py-record.c: Add py-instruction.h include.
12236 (gdbpy_initialize_record): Make gdb.Instruction a super class of
12237 gdb.RecordInstruction.
12238 * python/python-internal.h: Add gdbpy_initialize_instruction
12239 declaration.
12240 * python/python.c (do_start_initialization): Add
12241 gdbpy_initialize_instruction.
12242
12243 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12244
12245 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
12246 Remove.
12247 (btrace_func_from_recpy_func): New function.
12248 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
12249 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
12250 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
12251 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
12252 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
12253 Also, use new helper functions.
12254 (btpy_list_item): Use new helper functions.
12255 (recpy_bt_function_call_history): Use new type name.
12256 (btpy_call_getset): Remove.
12257 (gdbpy_initialize_btrace): Remove code to initialize
12258 gdb.BtraceFunctionCall.
12259 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
12260 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
12261 recpy_bt_func_prev, recpy_bt_func_next): New export.
12262 * python/py-record.c (recpy_func_type): New static object.
12263 (recpy_func_new, recpy_func_level, recpy_func_symbol,
12264 recpy_func_instructions, recpy_func_up, recpy_func_prev,
12265 recpy_func_next): New function.
12266 (recpy_element_hash, recpy_element_richcompare): Updated comment.
12267 (recpy_func_getset): New static object.
12268 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
12269 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
12270
12271 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12272
12273 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
12274 (btpy_object, btpy_insn_type, btpy_new): Remove.
12275 (btpy_list_object): Use gdb.RecordInstruction type instead of
12276 gdb.BtraceInstruction type.
12277 (btrace_insn_from_recpy_insn): New function.
12278 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
12279 btpy_new.
12280 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
12281 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
12282 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
12283 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
12284 instead of btpy_object.
12285 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12286 btpy_insn_data, btpy_insn_decode): Rename to ...
12287 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
12288 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
12289 recpy_bt_insn_decode): This. Also, use new helper functions.
12290 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
12291 recpy_insn_type.
12292 (btpy_insn_getset): Remove.
12293 (gdbpy_initialize_btrace): Remove code to initialize
12294 gdb.BtraceInstruction. Use recpy_element_object.
12295 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
12296 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
12297 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
12298 * python/py-record.c (recpy_insn_type): New static object.
12299 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
12300 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
12301 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
12302 New function.
12303 (recpy_insn_getset): New static object.
12304 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
12305 * python/py-record.h (recpy_element_object): New typedef.
12306 (recpy_insn_type, recpy_insn_new): New export.
12307
12308 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12309
12310 * py-record-btrace.c (btpy_insn_new): Removed.
12311 (btpy_insn_or_gap_new): New function.
12312 (btpy_insn_error): Removed.
12313 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
12314 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
12315 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
12316 btpy_insn_or_gap_new instead of btpy_insn_new.
12317 (btpy_insn_getset): Remove btpy_insn_error.
12318 * py-record.c (recpy_gap_type): New static object.
12319 (recpy_gap_object): New typedef.
12320 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
12321 recpy_gap_reason_string): New function.
12322 (recpy_gap_getset): New static object.
12323 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
12324 * py-record.h (recpy_gap_new): New export.
12325
12326 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12327
12328 * python/py-record.c (recpy_ptid): Remove.
12329 (recpy_record_getset): Remove recpy_ptid.
12330
12331 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12332
12333 * btrace.c (btrace_fetch): Set inferior_ptid.
12334 * python/py-record-btrace.c: Add "py-record.h" include.
12335 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
12336 recpy_bt_end, recpy_bt_instruction_history,
12337 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
12338 in gdb.Record object instead of current ptid.
12339 * python/py-record.c: Include new "py-record.h" file.
12340 (recpy_record_object): Moved to py-record.h.
12341 * python/py-record.h: New file.
12342
12343 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
12344
12345 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
12346 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
12347 indentation.
12348
12349 2017-05-01 Joel Brobecker <brobecker@adacore.com>
12350
12351 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
12352 the past maintainers section.
12353
12354 2017-04-28 Yao Qi <yao.qi@linaro.org>
12355
12356 * infcmd.c (get_return_value): Use regcache ctor, and remove
12357 cleanup.
12358
12359 2017-04-28 Yao Qi <yao.qi@linaro.org>
12360 Pedro Alves <palves@redhat.com>
12361
12362 * regcache.c (regcache::regcache): New tag dispatch ctor.
12363 (do_cooked_read): Moved above.
12364 (regcache_dup): Use the tag dispatch ctor..
12365 * regcache.h (regcache): Declare ctor, delete copy ctor and
12366 assignment operator, remove friend regcache_dup.
12367
12368 2017-04-28 Yao Qi <yao.qi@linaro.org>
12369
12370 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
12371 call method save instead of regcache_cpy.
12372 * regcache.h (struct regcache): Make regcache_dup a friend.
12373
12374 2017-04-28 Yao Qi <yao.qi@linaro.org>
12375
12376 * regcache.c (struct regcache): Move to regcache.h
12377 (regcache::arch): New method.
12378 (regcache_get_ptid): Update.
12379 (get_regcache_arch): Call arch method.
12380 (get_regcache_aspace): Call method aspace.
12381 (register_buffer): Change it to method.
12382 (regcache_save): Change it to regcache::save.
12383 (regcache_restore): Likewise.
12384 (regcache_cpy_no_passthrough): Remove the declaration.
12385 (regcache_cpy): Call methods restore and cpy_no_passthrough.
12386 (regcache_cpy_no_passthrough): Change it to method
12387 cpy_no_passthrough.
12388 (regcache_register_status): Change it to method
12389 get_register_status.
12390 (regcache_invalidate): Change it to method invalidate.
12391 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
12392 (regcache_raw_update): Change it to method raw_update.
12393 (regcache_raw_read): Likewise.
12394 (regcache_raw_read_signed): Likewise.
12395 (regcache_raw_read_unsigned): Likewise.
12396 (regcache_raw_write_signed): Likewise.
12397 (regcache_raw_write_unsigned): Likewise.
12398 (regcache_cooked_read): Likewise.
12399 (regcache_cooked_read_value): Likewise.
12400 (regcache_cooked_read_signed): Likewise.
12401 (regcache_cooked_read_unsigned): Likewise.
12402 (regcache_cooked_write_signed): Likewise.
12403 (regcache_cooked_write_unsigned): Likewise.
12404 (regcache_raw_set_cached_value): Likewise.
12405 (regcache_raw_write): Likewise.
12406 (regcache_cooked_write): Likewise.
12407 (regcache_xfer_part): Likewise.
12408 (regcache_raw_read_part): Likewise.
12409 (regcache_raw_write_part): Likewise.
12410 (regcache_cooked_read_part): Likewise.
12411 (regcache_cooked_write_part): Likewise.
12412 (regcache_raw_supply): Likewise.
12413 (regcache_raw_collect): Likewise.
12414 (regcache_transfer_regset): Likewise.
12415 (regcache_supply_regset): Likewise.
12416 (regcache_collect_regset): Likewise.
12417 (regcache_debug_print_register): Likewise.
12418 (enum regcache_dump_what): Move it to regcache.h.
12419 (regcache_dump): Change it to method dump.
12420 * regcache.h (enum regcache_dump_what): New.
12421 (class regcache): New.
12422 * target.c (target_fetch_registers): Call method
12423 debug_print_register.
12424 (target_store_registers): Likewise.
12425
12426 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12427
12428 * windows-nat.c (struct lm_info_windows): Initialize field.
12429 (windows_make_so): Allocate lm_info_windows with new.
12430 (windows_free_so): Free lm_info_windows with delete.
12431
12432 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12433
12434 * solib-darwin.c (struct lm_info_darwin): Initialize field.
12435 (darwin_current_sos): Allocate lm_info_darwin with new, remove
12436 cleanup.
12437 (darwin_free_so): Free lm_info_darwin with delete.
12438
12439 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12440
12441 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
12442 <l_addr_p>: Change type to bool.
12443 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
12444 (svr4_free_so): Free lm_info_svr4 with delete.
12445 (svr4_copy_library_list): Replace memcpy with call to copy
12446 constructor.
12447 (library_list_start_library, svr4_default_sos): Allocate
12448 lm_info_svr4 with new.
12449
12450 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12451
12452 * solib-target.c (struct lm_info_target): Add destructor,
12453 initialize fields.
12454 <name>: Change type to std::string.
12455 (library_list_start_library): Allocate lm_info_target with new.
12456 (solib_target_free_library_list): Free lm_info_target with
12457 delete.
12458 (solib_target_current_sos): Adapt to std::string.
12459 (solib_target_free_so): Free lm_info_target with delete.
12460
12461 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12462
12463 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
12464 fields.
12465 (frv_current_sos): Allocate lm_info_frv with new.
12466 (frv_relocate_main_executable): Free lm_info_frv with delete,
12467 allocate with new.
12468 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
12469
12470 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12471
12472 * solib-frv.c (struct lm_info_frv): Fix indentation.
12473
12474 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12475
12476 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
12477 map field.
12478 (dsbt_current_sos): Allocate lm_info_dsbt with new.
12479 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
12480 and allocate with new.
12481 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
12482
12483 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12484
12485 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
12486 <filename, member_name>: Change type to std::string.
12487 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
12488 (library_list_start_library): Allocate lm_info_aix with new.
12489 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
12490 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
12491 with copy constructor.
12492
12493 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12494
12495 * solist.h (struct lm_info): Remove.
12496 (struct lm_info_base): New class.
12497 (struct so_list) <lm_info>: Change type to lm_info_base *.
12498 * nto-tdep.c (struct lm_info): Remove.
12499 (lm_addr): Adjust.
12500 * solib-aix.c (struct lm_info): Rename to ...
12501 (struct lm_info_aix): ... this. Extend lm_info_base.
12502 (lm_info_p): Rename to ...
12503 (lm_info_aix_p): ... this, and adjust.
12504 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
12505 solib_aix_parse_libraries, library_list_start_library,
12506 solib_aix_free_library_list, solib_aix_parse_libraries,
12507 solib_aix_get_library_list,
12508 solib_aix_relocate_section_addresses, solib_aix_free_so,
12509 solib_aix_get_section_offsets,
12510 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
12511 Adjust.
12512 (struct solib_aix_inferior_data) <library_list>: Adjust.
12513 * solib-darwin.c (struct lm_info): Rename to ...
12514 (struct lm_info_darwin): ... this. Extend lm_info_base.
12515 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
12516 * solib-dsbt.c (struct lm_info): Rename to ...
12517 (struct lm_info_dsbt): ... this. Extend lm_info_base.
12518 (struct dsbt_info) <main_executable_lm_info): Adjust.
12519 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
12520 dsbt_relocate_section_addresses): Adjust.
12521 * solib-frv.c (struct lm_info): Rename to ...
12522 (struct lm_info_frv): ... this. Extend lm_info_base.
12523 (main_executable_lm_info): Adjust.
12524 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
12525 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
12526 find_canonical_descriptor_in_load_object,
12527 frv_fdpic_find_canonical_descriptor): Adjust.
12528 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
12529 to lm_info_svr4.
12530 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
12531 svr4_clear_so, svr4_copy_library_list,
12532 library_list_start_library, svr4_default_sos, svr4_read_so_list,
12533 svr4_current_sos, svr4_fetch_objfile_link_map,
12534 solist_update_incremental): Adjust.
12535 * solib-svr4.h (struct lm_info_svr4): Move here from
12536 solib-svr4.c.
12537 * solib-target.c (struct lm_info): Rename to ...
12538 (struct lm_info_target): ... this. Extend lm_info_base.
12539 (lm_info_p): Rename to ...
12540 (lm_info_target_p): ... this.
12541 (solib_target_parse_libraries, library_list_start_segment,
12542 library_list_start_section, library_list_start_library,
12543 library_list_end_library, solib_target_free_library_list,
12544 solib_target_current_sos, solib_target_free_so,
12545 solib_target_relocate_section_addresses): Adjust.
12546 * windows-nat.c (struct lm_info): Rename to ...
12547 (struct lm_info_windows): ... this. Extend lm_info_base.
12548 (windows_make_so, handle_load_dll, handle_unload_dll,
12549 windows_xfer_shared_libraries): Adjust.
12550
12551 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
12552
12553 * solib-darwin.c (struct darwin_so_list): Remove.
12554 (darwin_current_sos): Allocate an so_list object instead of a
12555 darwin_so_list, separately allocate an lm_info object.
12556 (darwin_free_so): Free lm_info.
12557
12558 2017-04-28 John Baldwin <jhb@FreeBSD.org>
12559
12560 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
12561 with fprintf_filtered.
12562
12563 2017-04-28 Yao Qi <yao.qi@linaro.org>
12564
12565 * regcache.c (regcache::regcache): New function.
12566 (regcache::~regcache): New function.
12567 (regcache_xmalloc_1): Remove.
12568 (regcache_xmalloc): Call new regcache.
12569 (regcache_xfree): Call delete regcache.
12570 (get_thread_arch_aspace_regcache): Call new regcache.
12571
12572 2017-04-28 Yao Qi <yao.qi@linaro.org>
12573
12574 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
12575 lwp instead of ptid_get_lwp.
12576
12577 2017-04-28 Yao Qi <yao.qi@linaro.org>
12578
12579 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
12580 lwp_info instead of getting from inferior_ptid.
12581
12582 2017-04-27 Keith Seitz <keiths@redhat.com>
12583
12584 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
12585 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
12586 (CV_CONVERSION_BADNESS): Define.
12587 (rank_one_type): Remove overly restrictive rvalue reference
12588 rank checks.
12589 Add cv-qualifier checks and subranks for type equality.
12590 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
12591 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
12592 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
12593
12594 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
12595
12596 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
12597 count when creating the object.
12598
12599 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
12600 Ulrich Weigand <uweigand@de.ibm.com>
12601
12602 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
12603 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
12604 is used in AIX.
12605 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
12606 (process_xcoff_symbol): Likewise.
12607 (scan_xcoff_symtab): Likewise.
12608
12609 2017-04-26 Alan Hayward <alan.hayward@arm.com>
12610
12611 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
12612 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
12613 (ia64_access_reg): Use get_frame_register_unsigned.
12614 (ia64_access_rse_reg): Likewise.
12615 (ia64_libunwind_frame_prev_register): Likewise.
12616
12617 2017-04-26 Jiong Wang <jiong.wang@arm.com>
12618
12619 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
12620 * gdbarch.c: Regenerated.
12621 * gdbarch.h: Regenerated.
12622 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
12623 visibility external.
12624 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
12625 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
12626 (enum cfa_how_kind): Move to ...
12627 (struct dwarf2_frame_state_reg_info): Likewise.
12628 (struct dwarf2_frame_state): Likewise.
12629 * dwarf2-frame.h: ... here.
12630 (dwarf2_frame_state_alloc_regs): New declaration.
12631 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
12632 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
12633
12634 2017-04-26 Alan Hayward <alan.hayward@arm.com>
12635
12636 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
12637 regcache_raw_read_unsigned.
12638 (xtensa_pseudo_register_write): Likewise.
12639
12640 2017-04-26 Alan Hayward <alan.hayward@arm.com>
12641
12642 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
12643 (nds32_pseudo_register_write): Likewise.
12644
12645 2017-04-25 Yao Qi <yao.qi@linaro.org>
12646
12647 * regcache.c (struct regcache) <readonly_p>: Change its type
12648 to bool.
12649 (regcache_xmalloc_1): Update parameter type and callers update.
12650
12651 2017-04-25 Yao Qi <yao.qi@linaro.org>
12652
12653 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
12654 set_gdbarch_wchar_bit.
12655 * arm-tdep.c (arm_gdbarch_init): Likewise.
12656
12657 2017-04-25 Pedro Alves <palves@redhat.com>
12658
12659 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
12660 (BothAreRelocatable, memcopy, memmove): Don't define.
12661 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
12662 macros.
12663
12664 2017-04-25 Pedro Alves <palves@redhat.com>
12665
12666 * common/common-defs.h: Include "common/poison.h".
12667 * common/function-view.h: (Not, Or, Requires): Move to traits.h
12668 and adjust.
12669 * common/poison.h: New file.
12670 * common/traits.h: Include <type_traits>.
12671 (Not, Or, Requires): New, moved from common/function-view.h.
12672
12673 2017-04-25 Pedro Alves <palves@redhat.com>
12674
12675 * breakpoint.h (struct breakpoint): In-class initialize all
12676 fields. Make boolean fields "bool".
12677 * breakpoint.c (init_raw_breakpoint_without_location): Remove
12678 memset call and initializations no longer necessary.
12679
12680 2017-04-25 Pedro Alves <palves@redhat.com>
12681
12682 * btrace.c (pt_btrace_insn_flags): Change parameter type to
12683 reference.
12684 (pt_btrace_insn): New function.
12685 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
12686
12687 2017-04-25 Pedro Alves <palves@redhat.com>
12688
12689 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
12690 "base" field and inherit from "bp_location" instead. Add
12691 non-default ctor.
12692 (allocate_location_exception): Use new non-default ctor.
12693 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
12694 (init_bp_location): Convert to ...
12695 (bp_location::bp_location): ... this new ctor, and remove memset
12696 call.
12697 (base_breakpoint_allocate_location): Use the new non-default ctor.
12698 * breakpoint.h (bp_location): Now a class. Declare default and
12699 non-default ctors. In-class initialize all members.
12700 (init_bp_location): Remove declaration.
12701
12702 2017-04-25 Pedro Alves <palves@redhat.com>
12703
12704 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
12705 assignment operator.
12706
12707 2017-04-24 Yao Qi <yao.qi@linaro.org>
12708
12709 * doublest.c (convert_doublest_to_floatformat): Call
12710 floatformat_totalsize_bytes.
12711
12712 2017-04-22 Tom Tromey <tom@tromey.com>
12713
12714 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
12715 ui_out_emit_list.
12716 * stack.c (print_frame): Use ui_out_emit_list.
12717 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12718 ui_out_emit_list.
12719 * mi/mi-main.c (print_one_inferior)
12720 (mi_cmd_data_list_register_names)
12721 (mi_cmd_data_list_register_values, mi_cmd_list_features)
12722 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
12723 ui_out_emit_list.
12724 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
12725 (mi_output_solib_attribs): Use ui_out_emit_list,
12726 ui_out_emit_tuple.
12727 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
12728 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
12729 (mi_cmd_stack_list_args, list_args_or_locals): Use
12730 ui_out_emit_list.
12731 * disasm.c (do_assembly_only): Use ui_out_emit_list.
12732 * breakpoint.c (print_solib_event, output_thread_groups): Use
12733 ui_out_emit_list.
12734
12735 2017-04-22 Tom Tromey <tom@tromey.com>
12736
12737 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
12738 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
12739 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
12740
12741 2017-04-22 Tom Tromey <tom@tromey.com>
12742
12743 * tracepoint.c (tvariables_info_1)
12744 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
12745
12746 2017-04-22 Tom Tromey <tom@tromey.com>
12747
12748 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
12749 annotate_arg_emitter.
12750 * breakpoint.c (print_mention_watchpoint)
12751 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
12752 * annotate.h (struct annotate_arg_emitter): New.
12753
12754 2017-04-22 Tom Tromey <tom@tromey.com>
12755
12756 * record-btrace.c (record_btrace_insn_history)
12757 (record_btrace_insn_history_range, record_btrace_call_history)
12758 (record_btrace_call_history_range): Use ui_out_emit_tuple.
12759 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
12760 ui_out_emit_tuple.
12761 * stack.c (print_frame_info): Use ui_out_emit_tuple.
12762 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
12763 * skip.c (skip_info): Use ui_out_emit_tuple.
12764 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
12765 * progspace.c (print_program_space): Use ui_out_emit_tuple.
12766 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
12767 * osdata.c (info_osdata): Use ui_out_emit_tuple.
12768 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
12769 ui_out_emit_tuple.
12770 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
12771 (output_register, mi_cmd_data_read_memory)
12772 (mi_cmd_data_read_memory_bytes, mi_load_progress)
12773 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
12774 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
12775 Use ui_out_emit_tuple.
12776 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
12777 ui_out_emit_tuple.
12778 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12779 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
12780 * linux-thread-db.c (info_auto_load_libthread_db): Use
12781 ui_out_emit_tuple.
12782 * inferior.c (print_inferior): Use ui_out_emit_tuple.
12783 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
12784 * disasm.c (do_mixed_source_and_assembly_deprecated)
12785 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
12786 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
12787 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
12788 * breakpoint.c (print_one_breakpoint_location)
12789 (print_one_breakpoint): Use ui_out_emit_tuple.
12790 * auto-load.c (print_script, info_auto_load_cmd): Use
12791 ui_out_emit_tuple.
12792 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
12793
12794 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
12795
12796 * thread.c (print_thread_info_1): Remove dead code.
12797
12798 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
12799
12800 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
12801 GDB_SELF_TEST.
12802 * arm-tdep.c (selftests::arm_record_test): Likewise.
12803
12804 2017-04-21 Yao Qi <yao.qi@linaro.org>
12805
12806 * regcache.c (regcache_restore): Remove argument 2. Replace
12807 argument 3 with regcache. Get register status from
12808 src->register_status and get register contents from
12809 register_buffer (src, regnum).
12810 (regcache_cpy): Update.
12811
12812 2017-04-19 Pedro Alves <palves@redhat.com>
12813
12814 * gdbthread.h (thread): Add missing closing parenthesis in
12815 comment.
12816
12817 2017-04-19 Pedro Alves <palves@redhat.com>
12818
12819 * common/refcounted-object.h: New file.
12820 * gdbthread.h: Include "common/refcounted-object.h".
12821 (thread_info): Inherit from refcounted_object and add comments.
12822 (thread_info::incref, thread_info::decref)
12823 (thread_info::m_refcount): Delete.
12824 (thread_info::deletable): Use the refcounted_object::refcount()
12825 method.
12826 * inferior.c (current_inferior_): Add comment.
12827 (set_current_inferior): Increment/decrement refcounts.
12828 (prune_inferiors, remove_inferior_command): Skip inferiors marked
12829 not-deletable instead of comparing with the current inferior.
12830 (initialize_inferiors): Increment the initial inferior's refcount.
12831 * inferior.h (struct inferior): Forward declare.
12832 Include "common/refcounted-object.h".
12833 (current_inferior, set_current_inferior): Move declaration to
12834 before struct inferior's definition, and fix comment.
12835 (inferior): Inherit from refcounted_object. Add comments.
12836 * thread.c (switch_to_thread_no_regs): Reference the thread's
12837 inferior pointer directly instead of doing a ptid lookup.
12838 (switch_to_no_thread): New function.
12839 (switch_to_thread(thread_info *)): New function, factored out
12840 from ...
12841 (switch_to_thread(ptid_t)): ... this.
12842 (restore_current_thread): Delete.
12843 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
12844 fields, and add 'inf' field.
12845 (do_restore_current_thread_cleanup): Check whether old->inf is
12846 alive instead of looking up an inferior by ptid. Use
12847 switch_to_thread and switch_to_no_thread.
12848 (restore_current_thread_cleanup_dtor): Use old->inf directly
12849 instead of lookup up an inferior by id. Decref the inferior.
12850 Don't restore 'removable'.
12851 (make_cleanup_restore_current_thread): Same the inferior pointer
12852 in old, instead of the inferior number. Incref the inferior.
12853 Don't save/clear 'removable'.
12854
12855 2017-04-19 Pedro Alves <palves@redhat.com>
12856
12857 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12858 unittests/scoped_restore-selftests.c.
12859 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
12860 * common/scoped_restore.h (scoped_restore_base): Make "class".
12861 (scoped_restore_base::release): New public method.
12862 (scoped_restore_base::scoped_restore_base): New protected ctor.
12863 (scoped_restore_base::m_saved_var): New protected field.
12864 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
12865 scoped_restore_base base class instead of m_saved_var directly.
12866 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
12867 (scoped_restore_tmpl::scoped_restore_tmpl(const
12868 scoped_restore_tmpl<T>&)): Likewise.
12869 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
12870 method.
12871 (scoped_restore_tmpl::saved_var): New method.
12872 (scoped_restore_tmpl::m_saved_var): Delete.
12873 * inferior.h (inferior::detaching): Now a bool.
12874 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
12875 cleanup.
12876 * unittests/scoped_restore-selftests.c: New file.
12877
12878 2017-04-19 Pedro Alves <palves@redhat.com>
12879
12880 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
12881 Re-sort in alphabetic order.
12882
12883 2017-04-18 Pedro Alves <palves@redhat.com>
12884
12885 * xml-support.c (obstack_xml_printf): Delete.
12886 * xml-support.h (obstack_xml_printf): Delete.
12887
12888 2017-04-18 Pedro Alves <palves@redhat.com>
12889
12890 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
12891 vdebug, verror, body_text, start_element, end_element, name,
12892 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
12893 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
12894 is_xinclude>: Make private and add m_ prefix.
12895 (gdb_xml_parser::body_text): New method, based on ...
12896 (gdb_xml_body_text): ... this. Adjust.
12897 (gdb_xml_parser::vdebug): New method, based on ...
12898 (gdb_xml_debug): ... this. Adjust.
12899 (gdb_xml_parser::verror): New method, based on ...
12900 (gdb_xml_error): ... this. Adjust.
12901 (gdb_xml_parser::start_element): New method, based on ...
12902 (gdb_xml_start_element): ... this. Adjust.
12903 (gdb_xml_start_element_wrapper): Defer to
12904 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
12905 (gdb_xml_parser::end_element): New method, based on ...
12906 (gdb_xml_end_element_wrapper): ... this. Adjust.
12907 (gdb_xml_parser::~gdb_xml_parser): Adjust.
12908 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
12909 (gdb_xml_parser::use_dtd): New method, based on ...
12910 (gdb_xml_use_dtd): ... this. Adjust.
12911 (gdb_xml_parser::parse): New method, based on ...
12912 (gdb_xml_parse): ... this. Adjust.
12913 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
12914 (xinclude_start_include): Adjust to call the parser's name method.
12915 (xml_xinclude_default, xml_xinclude_start_doctype)
12916 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
12917 method.
12918 (xml_process_xincludes): Adjust to call parser methods.
12919 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
12920 declarations.
12921
12922 2017-04-18 Pedro Alves <palves@redhat.com>
12923
12924 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
12925 gdb::optional<std::string>.
12926 * xml-support.c: Include <string>.
12927 (scope_level::scope_level(scope_level &&))
12928 (scope_level::~scope_level): Delete.
12929 (scope_level::body): Now a std::string.
12930 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
12931 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
12932 parameter.
12933 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
12934 (xinclude_parsing_data::output): Now a std::string reference.
12935 (xinclude_start_include): Adjust.
12936 (xml_xinclude_default): Adjust.
12937 (xml_process_xincludes): Add 'output' parameter, and return bool.
12938 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
12939 and return bool.
12940 * xml-tdesc.c: Include <unordered_map> and <string>.
12941 (tdesc_xml_cache): Delete.
12942 (tdesc_xml_cache_s): Delete.
12943 (xml_cache): Now an std::unordered_map.
12944 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
12945 (target_fetch_description_xml): Change return type to
12946 gdb::optional<std::string>, and adjust.
12947 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
12948 (target_fetch_description_xml): Change return type to
12949 gdb::optional<std::string>.
12950
12951 2017-04-18 Pedro Alves <palves@redhat.com>
12952
12953 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12954 unittests/optional-selftests.c.
12955 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
12956 * unittests/optional-selftests.c: New file.
12957 * unittests/optional/assignment/1.cc: New file.
12958 * unittests/optional/assignment/2.cc: New file.
12959 * unittests/optional/assignment/3.cc: New file.
12960 * unittests/optional/assignment/4.cc: New file.
12961 * unittests/optional/assignment/5.cc: New file.
12962 * unittests/optional/assignment/6.cc: New file.
12963 * unittests/optional/assignment/7.cc: New file.
12964 * unittests/optional/cons/copy.cc: New file.
12965 * unittests/optional/cons/default.cc: New file.
12966 * unittests/optional/cons/move.cc: New file.
12967 * unittests/optional/cons/value.cc: New file.
12968 * unittests/optional/in_place.cc: New file.
12969 * unittests/optional/observers/1.cc: New file.
12970 * unittests/optional/observers/2.cc: New file.
12971
12972 2017-04-18 Pedro Alves <palves@redhat.com>
12973
12974 * common/gdb_optional.h: Include common/traits.h.
12975 (in_place_t): New type.
12976 (in_place): New constexpr variable.
12977 (optional::optional): Remove member initialization of
12978 m_instantiated.
12979 (optional::optional(in_place_t...)): New constructor.
12980 (optional::~optional): Use reset.
12981 (optional::optional(const optional&)): New.
12982 (optional::optional(const optional&&)): New.
12983 (optional::optional(T &)): New.
12984 (optional::optional(T &&)): New.
12985 (operator::operator=(const optional &)): New.
12986 (operator::operator=(optional &&)): New.
12987 (operator::operator= (const T &))
12988 (operator::operator= (T &&))
12989 (operator::emplace (Args &&... args)): Return a T&. Use reset.
12990 (operator::reset): New.
12991 (operator::m_instantiated):: Add in-class initializer.
12992 * common/traits.h: Include <type_traits>.
12993 (struct And): New types.
12994
12995 2017-04-18 Pedro Alves <palves@redhat.com>
12996
12997 * xml-support.c: Include <vector>.
12998 (scope_level::scope_level(const gdb_xml_element *))
12999 (scope_level::scope_level(scope_level&&)): New.
13000 (scope_level::~scope_level): New.
13001 (scope_level_s): Delete.
13002 (gdb_xml_parser::scopes): Now a std::vector.
13003 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
13004 Use std::vector.
13005 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
13006 scope cleanup code.
13007 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
13008 of the scopes member. Use std::vector::emplace_back.
13009
13010 2017-04-18 Pedro Alves <palves@redhat.com>
13011
13012 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
13013 a bool.
13014 (gdb_xml_end_element): Change type of first parameter.
13015 (gdb_xml_cleanup): Rename to ...
13016 (gdb_xml_parser::~gdb_xml_parser): ... this.
13017 (gdb_xml_create_parser_and_cleanup): Delete with ...
13018 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
13019 to this new ctor.
13020 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
13021 using gdb_xml_create_parser_and_cleanup.
13022 (xinclude_parsing_data): Add ctor/dtor.
13023 (xml_xinclude_cleanup): Delete.
13024 (xml_process_xincludes): Create a local xinclude_parsing_data
13025 instead of heap-allocating one. Create a local gdb_xml_parser
13026 instead of heap-allocating one with
13027 gdb_xml_create_parser_and_cleanup.
13028
13029 2017-04-18 John Baldwin <jhb@FreeBSD.org>
13030
13031 PR threads/20743
13032 * fbsd-nat.c (resume_one_thread_cb): Remove.
13033 (resume_all_threads_cb): Remove.
13034 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
13035 iterate_over_threads.
13036
13037 2017-04-17 Joel Brobecker <brobecker@adacore.com>
13038
13039 * NEWS: Create a new section for the next release branch.
13040 Rename the section of the current branch, now that it has
13041 been cut.
13042
13043 2017-04-17 Joel Brobecker <brobecker@adacore.com>
13044
13045 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
13046 * version.in: Bump version to 8.0.50.DATE-git.
13047
13048 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
13049
13050 PR gdb/21385
13051 * windows-nat.c (windows_create_inferior): Declare 'allargs'
13052 independently of the host, and fix build breakage on Cygwin.
13053
13054 2017-04-13 Pedro Alves <palves@redhat.com>
13055
13056 * inferior.c (free_inferior): Convert to ...
13057 (inferior::~inferior): ... this dtor.
13058 (inferior::inferior): New ctor, factored out from ...
13059 (add_inferior_silent): ... here. Allocate the inferior with a new
13060 expression.
13061 (delete_inferior): Call delete instead of free_inferior.
13062 * inferior.h (gdb_environ, continuation): Forward declare.
13063 (inferior): Now a class. Add in-class initialization to all
13064 members. Make boolean fields bool, except 'detaching'.
13065 (inferior::inferior): New explicit ctor.
13066 (inferior::~inferior): New.
13067
13068 2017-04-13 Pedro Alves <palves@redhat.com>
13069
13070 * inferior.c (init_inferior_list): Delete.
13071 * inferior.h (init_inferior_list): Delete.
13072
13073 2017-04-13 Pedro Alves <palves@redhat.com>
13074
13075 PR threads/13217
13076 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
13077 (top level): Call it twice, with different thread sets.
13078
13079 2017-04-13 Pedro Alves <palves@redhat.com>
13080
13081 * thread.c: Include <algorithm>.
13082 (thread_array_cleanup): Delete.
13083 (scoped_inc_dec_ref): New class.
13084 (live_threads_count): New function.
13085 (set_thread_refcount): Delete.
13086 (tp_array_compar_ascending): Now a bool.
13087 (tp_array_compar): Convert to a std::sort comparison function.
13088 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
13089 and live_threads_count.
13090
13091 2017-04-13 Pedro Alves <palves@redhat.com>
13092
13093 * infrun.c (follow_fork_inferior): Also switch the current
13094 inferior.
13095
13096 2017-04-13 Pedro Alves <palves@redhat.com>
13097
13098 * breakpoint.c (watch_command_1): Save watchpoint-frame info
13099 before calling create_internal_breakpoint.
13100
13101 2017-04-13 Pedro Alves <palves@redhat.com>
13102
13103 * fork-child.c (execv_argv): New class.
13104 (breakup_args): Refactored as ...
13105 (execv_argv::init_for_no_shell): .. this method of execv_argv.
13106 Copy arguments to storage and replace separators with NULL
13107 terminators in place.
13108 (escape_bang_in_quoted_argument): Adjust to return bool.
13109 (execv_argv::execv_argv): New ctor.
13110 (execv_argv::init_for_shell): New method, factored out from
13111 fork_inferior. Don't strdup strings into the vector.
13112 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
13113 Remove free_vector_argv call.
13114
13115 2017-04-13 Yao Qi <yao.qi@linaro.org>
13116
13117 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
13118 tdep->rx_psw_type.
13119
13120 2017-04-13 Yao Qi <yao.qi@linaro.org>
13121
13122 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
13123 * rx-tdep.c (rx_gdbarch_init): Likewise.
13124
13125 2017-04-13 Pedro Alves <palves@redhat.com>
13126
13127 * breakpoint.h (struct breakpoint): Reindent.
13128
13129 2017-04-13 Pedro Alves <palves@redhat.com>
13130
13131 * breakpoint.c (bp_location): Rename to ...
13132 (bp_locations): ... this. All references updated.
13133 (bp_location_count): Rename to ...
13134 (bp_locations_count): ... this. All references updated.
13135 (bp_location_placed_address_before_address_max): Rename to ...
13136 (bp_locations_placed_address_before_address_max): ... this. All
13137 references updated.
13138 (bp_location_shadow_len_after_address_max): Rename to ...
13139 (bp_locations_shadow_len_after_address_max): ... this. All
13140 references updated.
13141 (bp_location_compare_addrs): Rename to ...
13142 (bp_locations_compare_addrs): ... this. All references updated.
13143 (bp_location_compare):Rename to ...
13144 (bp_locations_compare): ... this. All references updated.
13145 (bp_location_target_extensions_update): Rename to ...
13146 (bp_locations_target_extensions_update): ... this. All references
13147 updated.
13148
13149 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13150
13151 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
13152 * common/common.m4: Check headers 'termios.h', 'termio.h' and
13153 'sgtty.h'.
13154 * common/gdb_termios.h: New file, with parts of "terminal.h".
13155 * inflow.c: Include "gdb_termios.h".
13156 * ser-unix.c: Include "gdb_termios.h".
13157 * terminal.h: Move terminal-related defines to
13158 "common/gdb_termios.h".
13159
13160 2017-04-12 Tom Tromey <tom@tromey.com>
13161
13162 * probe.c (parse_probes): Update.
13163 * location.h (delete_event_location): Don't declare.
13164 (event_location_deleter::operator()): Update.
13165 * location.c (event_location_deleter::operator()): Rename from
13166 delete_event_location.
13167 * linespec.h (linespec_result) <location>: Change type to
13168 event_location_up.
13169 * linespec.c (canonicalize_linespec, event_location_to_sals)
13170 (decode_objc): Update.
13171 (linespec_result): Don't call delete_event_location.
13172 * breakpoint.c (create_breakpoints_sal)
13173 (bkpt_probe_create_sals_from_location)
13174 (strace_marker_create_sals_from_location): Update.
13175
13176 2017-04-12 Tom Tromey <tom@tromey.com>
13177
13178 * linespec.h (struct linespec_result): Add constructor and
13179 destructor.
13180 (init_linespec_result, destroy_linespec_result)
13181 (make_cleanup_destroy_linespec_result): Don't declare.
13182 * linespec.c (init_linespec_result): Remove.
13183 (linespec_result::~linespec_result): Rename from
13184 destroy_linespec_result. Update.
13185 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
13186 Remove.
13187 * breakpoint.c (create_breakpoint, break_range_command)
13188 (decode_location_default): Update.
13189 * ax-gdb.c (agent_command_1): Update.
13190
13191 2017-04-12 Tom Tromey <tom@tromey.com>
13192
13193 * remote.c (remote_download_tracepoint): Update.
13194 * python/py-breakpoint.c (bppy_get_location): Update.
13195 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
13196 (gdbscm_breakpoint_location): Update.
13197 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
13198 * breakpoint.h (struct breakpoint) <location, location_range_end>:
13199 Change type to event_location_up.
13200 * breakpoint.c (create_overlay_event_breakpoint)
13201 (create_longjmp_master_breakpoint)
13202 (create_std_terminate_master_breakpoint)
13203 (create_exception_master_breakpoint)
13204 (breakpoint_event_location_empty_p, print_breakpoint_location)
13205 (print_one_breakpoint_location, create_thread_event_breakpoint)
13206 (init_breakpoint_sal, create_breakpoint)
13207 (print_recreate_ranged_breakpoint, break_range_command)
13208 (init_ada_exception_breakpoint, say_where): Update.
13209 (base_breakpoint_dtor): Don't call delete_event_location.
13210 (bkpt_print_recreate, tracepoint_print_recreate)
13211 (dprintf_print_recreate, update_static_tracepoint)
13212 (breakpoint_re_set_default): Update.
13213
13214 2017-04-12 Tom Tromey <tom@tromey.com>
13215
13216 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
13217 type of "to_do". Update.
13218 (compute_stack_depth): Use std::vector.
13219
13220 2017-04-12 Tom Tromey <tom@tromey.com>
13221
13222 * printcmd.c (find_instruction_backward): Use std::vector.
13223
13224 2017-04-12 Tom Tromey <tom@tromey.com>
13225
13226 * symfile.c (objfilep): Remove typedef.
13227 (reread_symbols): Use a std::vector.
13228
13229 2017-04-12 Tom Tromey <tom@tromey.com>
13230
13231 * mi/mi-main.c (exec_direction_forward): Remove.
13232 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
13233 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
13234 scoped_restore.
13235 * guile/guile.c (guile_repl_command, guile_command)
13236 (gdbscm_execute_gdb_command): Use scoped_restore.
13237 * go-exp.y (go_parse): Use scoped_restore.
13238 * d-exp.y (d_parse): Use scoped_restore.
13239 * cli/cli-decode.c (cmd_func): Use scoped_restore.
13240 * c-exp.y (c_parse): Use scoped_restore.
13241
13242 2017-04-12 Tom Tromey <tom@tromey.com>
13243
13244 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
13245 (mi_parse): Update return type.
13246 (mi_parse_free): Remove.
13247 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
13248 (mi_parse::~mi_parse): Rename from mi_parse_free.
13249 (mi_parse_cleanup): Remove.
13250 (mi_parse): Return a unique_ptr. Use new.
13251 * mi/mi-main.c (mi_execute_command): Update.
13252
13253 2017-04-12 Tom Tromey <tom@tromey.com>
13254
13255 * location.c (explicit_location_lex_one): Return a
13256 unique_xmalloc_ptr.
13257 (string_to_explicit_location): Update. Remove cleanups.
13258
13259 2017-04-12 Tom Tromey <tom@tromey.com>
13260
13261 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
13262 (compare_value_and_voffset): Change type. Update.
13263 (compute_vtable_size): Change type of "offset_vec".
13264 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
13265 (gnuv3_get_typeid): Remove extraneous declaration.
13266
13267 2017-04-12 Tom Tromey <tom@tromey.com>
13268
13269 * charset.h (wchar_iterator): Fix comment.
13270
13271 2017-04-12 Tom Tromey <tom@tromey.com>
13272
13273 * charset.c (iconv_wrapper): New class.
13274 (cleanup_iconv): Remove.
13275 (convert_between_encodings): Use it.
13276
13277 2017-04-12 Tom Tromey <tom@tromey.com>
13278
13279 * symfile.h (increment_reading_symtab): Update type.
13280 * symfile.c (decrement_reading_symtab): Remove.
13281 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
13282 * psymtab.c (psymtab_to_symtab): Update.
13283 * dwarf2read.c (dw2_instantiate_symtab): Update.
13284
13285 2017-04-12 Tom Tromey <tom@tromey.com>
13286
13287 * jit.c (struct jit_reader): Declare separately. Add constructor
13288 and destructor. Change type of "handle".
13289 (loaded_jit_reader): Define separately.
13290 (jit_reader_load): Update. New "new".
13291 (jit_reader_unload_command): Use "delete".
13292 * gdb-dlfcn.h (struct dlclose_deleter): New.
13293 (gdb_dlhandle_up): New typedef.
13294 (gdb_dlopen, gdb_dlsym): Update types.
13295 (gdb_dlclose): Remove.
13296 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
13297 (gdb_dlsym): Change type of "handle".
13298 (make_cleanup_dlclose): Remove.
13299 (dlclose_deleter::operator()): Rename from gdb_dlclose.
13300 * compile/compile-c-support.c (load_libcc): Update.
13301
13302 2017-04-12 Tom Tromey <tom@tromey.com>
13303
13304 * symtab.h (find_pcs_for_symtab_line): Change return type.
13305 * symtab.c (find_pcs_for_symtab_line): Change return type.
13306 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
13307 type of "vec". Update.
13308 (ltpy_get_pcs_for_line): Update.
13309 * linespec.c (decode_digits_ordinary): Update.
13310
13311 2017-04-12 Tom Tromey <tom@tromey.com>
13312
13313 * tracepoint.c (actions_command): Update.
13314 * python/python.c (python_command, python_interactive_command):
13315 Update.
13316 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
13317 * guile/guile.c (guile_command): Update.
13318 * defs.h (read_command_lines, read_command_lines_1): Return
13319 command_line_up.
13320 (command_lines_deleter): New struct.
13321 (command_line_up): New typedef.
13322 * compile/compile.c (compile_code_command)
13323 (compile_print_command): Update.
13324 * cli/cli-script.h (get_command_line, copy_command_lines): Return
13325 command_line_up.
13326 (make_cleanup_free_command_lines): Remove.
13327 * cli/cli-script.c (get_command_line, read_command_lines_1)
13328 (copy_command_lines): Return command_line_up.
13329 (while_command, if_command, read_command_lines, define_command)
13330 (document_command): Update.
13331 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
13332 Remove.
13333 * breakpoint.h (breakpoint_set_commands): Change type of
13334 "commands".
13335 * breakpoint.c (breakpoint_set_commands): Change type of
13336 "commands". Update.
13337 (do_map_commands_command, update_dprintf_command_list)
13338 (create_tracepoint_from_upload): Update.
13339
13340 2017-04-12 Tom Tromey <tom@tromey.com>
13341
13342 * tracepoint.c (scope_info): Update.
13343 * spu-tdep.c (spu_catch_start): Update.
13344 * python/python.c (gdbpy_decode_line): Update.
13345 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
13346 * python/py-breakpoint.c (bppy_init): Update.
13347 * probe.c (parse_probes): Update.
13348 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
13349 * location.h (event_location_deleter): New struct.
13350 (event_location_up): New typedef.
13351 (new_linespec_location, new_address_location, new_probe_location)
13352 (new_explicit_location, copy_event_location)
13353 (string_to_event_location, string_to_event_location_basic)
13354 (string_to_explicit_location): Update return type.
13355 (make_cleanup_delete_event_location): Remove.
13356 * location.c (new_linespec_location, new_address_location)
13357 (new_probe_location, new_explicit_location, copy_event_location):
13358 Return event_location_up.
13359 (delete_event_location_cleanup)
13360 (make_cleanup_delete_event_location): Remove.
13361 (string_to_explicit_location, string_to_event_location_basic)
13362 (string_to_event_location): Return event_location_up.
13363 * linespec.c (canonicalize_linespec, event_location_to_sals)
13364 (decode_line_with_current_source)
13365 (decode_line_with_last_displayed, decode_objc): Update.
13366 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
13367 * completer.c (location_completer): Update.
13368 * cli/cli-cmds.c (edit_command, list_command): Update.
13369 * breakpoint.c (create_overlay_event_breakpoint)
13370 (create_longjmp_master_breakpoint)
13371 (create_std_terminate_master_breakpoint)
13372 (create_exception_master_breakpoint)
13373 (create_thread_event_breakpoint): Update.
13374 (init_breakpoint_sal): Update. Remove some dead code.
13375 (create_breakpoint_sal): Change type of "location". Update.
13376 (create_breakpoints_sal, create_breakpoint, break_command_1)
13377 (dprintf_command, break_range_command, until_break_command)
13378 (init_ada_exception_breakpoint)
13379 (strace_marker_create_sals_from_location)
13380 (update_static_tracepoint, trace_command, ftrace_command)
13381 (strace_command, create_tracepoint_from_upload): Update.
13382 * break-catch-throw.c (re_set_exception_catchpoint): Update.
13383 * ax-gdb.c (agent_command_1): Update.
13384
13385 2017-04-12 Pedro Alves <palves@redhat.com>
13386
13387 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
13388 * configure.tgt: Handle i[34567]86-*-go32* and
13389 i[34567]86-*-msdosdjgpp*.
13390 * i386-tdep.c (i386_svr4_reg_to_regnum):
13391 Make extern.
13392 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
13393 i386-go32-tdep.c.
13394 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
13395 * i386-go32-tdep.c: New file.
13396 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
13397 declarations.
13398
13399 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
13400
13401 * aix-thread.c (pd_status2str): Change return type to const char *.
13402
13403 2017-04-12 Pedro Alves <palves@redhat.com>
13404
13405 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
13406 calls to set_gdbarch_gnu_triplet_regexp.
13407
13408 2017-04-12 Pedro Alves <palves@redhat.com>
13409
13410 PR gdb/21323
13411 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
13412 New enum value.
13413 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
13414 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
13415 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
13416 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
13417 * gdbarch.h, gdbarch.c: Regenerate.
13418 * aarch64-tdep.c (aarch64_gdbarch_init): Override
13419 gdbarch_wchar_bit and gdbarch_wchar_signed.
13420 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
13421 * arm-tdep.c (arm_gdbarch_init): Likewise.
13422 * avr-tdep.c (avr_gdbarch_init): Likewise.
13423 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
13424 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
13425 * i386-tdep.c (i386_go32_init_abi): Likewise.
13426 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
13427 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
13428 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
13429 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
13430 * sh-tdep.c (sh_gdbarch_init): Likewise.
13431 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
13432 * sparc64-tdep.c (sparc64_init_abi): Likewise.
13433 * windows-tdep.c (windows_init_abi): Likewise.
13434 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
13435
13436 2017-04-12 Pedro Alves <palves@redhat.com>
13437
13438 PR c++/21323
13439 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
13440 cplus_primitive_type_char32_t>: New enum values.
13441 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
13442 and cplus_primitive_type_char32_t.
13443 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
13444 32, use the archtecture's built-in type for char16_t and char32_t,
13445 respectively. Otherwise, fallback to init_integer_type as before,
13446 but make the type unsigned, and issue a complaint.
13447 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
13448
13449 2017-04-12 Alan Hayward <alan.hayward@arm.com>
13450
13451 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
13452 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
13453
13454 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13455
13456 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
13457 'const char *'.
13458
13459 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
13460
13461 * common/common-utils.c (free_vector_argv): New function.
13462 * common/common-utils.h: Include <vector>.
13463 (free_vector_argv): New prototype.
13464 * darwin-nat.c (darwin_create_inferior): Rewrite function
13465 prototype in order to constify "exec_file" and accept a
13466 "std::string" for "allargs".
13467 * fork-child.c: Include <vector>.
13468 (breakup_args): Rewrite function, using C++.
13469 (fork_inferior): Rewrite function header, constify "exec_file_arg"
13470 and accept "std::string" for "allargs". Update the code to
13471 calculate "argv" based on "allargs". Update calls to "exec_fun"
13472 and "execvp".
13473 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
13474 order to constify "exec_file" and accept a "std::string" for
13475 "allargs".
13476 * go32-nat.c (go32_create_inferior): Likewise.
13477 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
13478 * infcmd.c (run_command_1): Constify "exec_file". Use
13479 "std::string" for inferior arguments.
13480 * inferior.h (fork_inferior): Update prototype.
13481 * linux-nat.c (linux_nat_create_inferior): Rewrite function
13482 prototype in order to constify "exec_file" and accept a
13483 "std::string" for "allargs".
13484 * nto-procfs.c (procfs_create_inferior): Likewise.
13485 * procfs.c (procfs_create_inferior): Likewise.
13486 * remote-sim.c (gdbsim_create_inferior): Likewise.
13487 * remote.c (extended_remote_run): Update code to accept
13488 "std::string" as argument.
13489 (extended_remote_create_inferior): Rewrite function prototype in
13490 order to constify "exec_file" and accept a "std::string" for
13491 "allargs".
13492 * rs6000-nat.c (super_create_inferior): Likewise.
13493 (rs6000_create_inferior): Likewise.
13494 * target.h (struct target_ops) <to_create_inferior>: Likewise.
13495 * windows-nat.c (windows_create_inferior): Likewise.
13496
13497 2017-04-11 Pedro Alves <palves@redhat.com>
13498
13499 * thread.c: Fix whitespace throughout.
13500
13501 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
13502
13503 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
13504
13505 2017-04-11 Alan Hayward <alan.hayward@arm.com>
13506
13507 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
13508
13509 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
13510
13511 PR gdb/21364
13512 * osdata.c (info_osdata): Check if 'type' is an empty string
13513 instead of NULL.
13514
13515 2017-04-10 Pedro Alves <palves@redhat.com>
13516
13517 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
13518 (ptid_to_global_thread_id, in_thread_list)
13519 (do_captured_list_thread_ids, set_resumed, set_running)
13520 (set_executing, set_stop_requested, finish_thread_state)
13521 (validate_registers_access, can_access_registers_ptid)
13522 (print_thread_info_1, switch_to_thread)
13523 (do_restore_current_thread_cleanup)
13524 (make_cleanup_restore_current_thread, thread_command)
13525 (thread_name_command): Use operator== instead of ptid_equal.
13526
13527 2017-04-10 Pedro Alves <palves@redhat.com>
13528
13529 * thread.c (struct current_thread_cleanup) <next>: Delete field.
13530 (current_thread_cleanup_chain): Delete.
13531 (restore_current_thread_cleanup_dtor)
13532 (make_cleanup_restore_current_thread): Remove references to
13533 current_thread_cleanup_chain.
13534
13535 2017-04-10 Alan Hayward <alan.hayward@arm.com>
13536
13537 * msp430-tdep.c (msp430_pseudo_register_read): Never return
13538 REG_UNKNOWN.
13539
13540 2017-04-10 Yao Qi <yao.qi@linaro.org>
13541
13542 PR gdb/19942
13543 * gdbthread.h (thread_info::deletable): New method.
13544 (thread_info::incref): New method.
13545 (thread_info::decref): New method.
13546 (thread_info::refcount): Move it to private.
13547 * infrun.c (save_stop_context): Call inc_refcount.
13548 (release_stop_context_cleanup): Likewise.
13549 * thread.c (set_thread_exited): New function.
13550 (init_thread_list): Delete "tp" only it is deletable, otherwise
13551 call set_thread_exited.
13552 (delete_thread_1): Call set_thread_exited.
13553 (current_thread_cleanup) <inferior_pid>: Remove.
13554 <thread>: New field.
13555 (restore_current_thread_ptid_changed): Removed.
13556 (do_restore_current_thread_cleanup): Adjust.
13557 (restore_current_thread_cleanup_dtor): Don't call
13558 find_thread_ptid.
13559 (set_thread_refcount): Use dec_refcount.
13560 (make_cleanup_restore_current_thread): Adjust.
13561 (thread_apply_all_command): Call inc_refcount.
13562 (_initialize_thread): Don't call
13563 observer_attach_thread_ptid_changed.
13564
13565 2017-04-10 Yao Qi <yao.qi@linaro.org>
13566
13567 * thread.c (delete_thread_1): Hoist code on marking thread as
13568 exited.
13569
13570 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
13571
13572 * windows-nat.c (windows_detach): Initialize ptid with
13573 minus_one_ptid.
13574
13575 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
13576
13577 * unittests/ptid-selftests.c: Fix erroneous assert messages.
13578
13579 2017-04-07 Alan Hayward <alan.hayward@arm.com>
13580
13581 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
13582 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
13583 (bfin_pseudo_register_write): Likewise
13584
13585 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
13586
13587 * common/ptid.h (struct ptid): Change to...
13588 (class ptid_t): ... this.
13589 <ptid_t>: New constructors.
13590 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
13591 matches>: New methods.
13592 <make_null, make_minus_one>: New static methods.
13593 <pid>: Rename to...
13594 <m_pid>: ...this.
13595 <lwp>: Rename to...
13596 <m_lwp>: ...this.
13597 <tid>: Rename to...
13598 <m_tid>: ...this.
13599 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
13600 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
13601 as references, move comment to class ptid_t.
13602 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
13603 ptid_t static methods.
13604 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
13605 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
13606 Take ptid arguments as references, implement using ptid_t methods.
13607 * unittests/ptid-selftests.c: New file.
13608 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
13609 unittests/ptid-selftests.c.
13610 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
13611
13612 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
13613
13614 * python/python.c (python_run_simple_file): Cast mode literal to
13615 non-const char pointer as expected by PyFile_FromString.
13616
13617 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
13618
13619 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
13620 minus_one_ptid and null_ptid.
13621
13622 2017-04-05 Pedro Alves <palves@redhat.com>
13623
13624 * warning.m4 (build_warnings): Remove -Wno-write-strings.
13625 * configure: Regenerate.
13626
13627 2017-04-05 Pedro Alves <palves@redhat.com>
13628
13629 * ada-exp.y (yyerror): Constify.
13630 * ada-lang.c (bound_name, get_selections)
13631 (ada_variant_discrim_type)
13632 (ada_variant_discrim_name, ada_value_struct_elt)
13633 (ada_lookup_struct_elt_type, is_unchecked_variant)
13634 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
13635 (catch_ada_exception_command_split)
13636 (catch_ada_assert_command_split, catch_assert_command)
13637 (ada_op_name): Constify.
13638 * ada-lang.h (ada_yyerror, get_selections)
13639 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
13640 * arc-tdep.c (arc_print_frame_cache): Constify.
13641 * arm-tdep.c (arm_skip_stub): Constify.
13642 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
13643 (gen_aggregate_elt_ref): Constify.
13644 * bcache.c (print_bcache_statistics): Constify.
13645 * bcache.h (print_bcache_statistics): Constify.
13646 * break-catch-throw.c (catch_exception_command_1):
13647 * breakpoint.c (struct ep_type_description::description):
13648 Constify.
13649 (add_solib_catchpoint): Constify.
13650 (catch_fork_command_1): Add cast.
13651 (add_catch_command): Constify.
13652 * breakpoint.h (add_catch_command, add_solib_catchpoint):
13653 Constify.
13654 * bsd-uthread.c (bsd_uthread_state): Constify.
13655 * buildsym.c (patch_subfile_names): Constify.
13656 * buildsym.h (next_symbol_text_func, patch_subfile_names):
13657 Constify.
13658 * c-exp.y (yyerror): Constify.
13659 (token::oper): Constify.
13660 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
13661 * c-varobj.c (cplus_describe_child): Constify.
13662 * charset.c (find_charset_names): Add cast.
13663 (find_charset_names): Constify array and add const_cast.
13664 * cli/cli-cmds.c (complete_command, cd_command): Constify.
13665 (edit_command): Constify.
13666 * cli/cli-decode.c (lookup_cmd): Constify.
13667 * cli/cli-dump.c (dump_memory_command, dump_value_command):
13668 Constify.
13669 (struct dump_context): Constify.
13670 (add_dump_command, restore_command): Constify.
13671 * cli/cli-script.c (get_command_line): Constify.
13672 * cli/cli-script.h (get_command_line): Constify.
13673 * cli/cli-utils.c (check_for_argument): Constify.
13674 * cli/cli-utils.h (check_for_argument): Constify.
13675 * coff-pe-read.c (struct read_pe_section_data): Constify.
13676 * command.h (lookup_cmd): Constify.
13677 * common/print-utils.c (decimal2str): Constify.
13678 * completer.c (gdb_print_filename): Constify.
13679 * corefile.c (set_gnutarget): Constify.
13680 * cp-name-parser.y (yyerror): Constify.
13681 * cp-valprint.c (cp_print_class_member): Constify.
13682 * cris-tdep.c (cris_register_name, crisv32_register_name):
13683 Constify.
13684 * d-exp.y (yyerror): Constify.
13685 (struct token::oper): Constify.
13686 * d-lang.h (d_yyerror): Constify.
13687 * dbxread.c (struct header_file_location::name): Constify.
13688 (add_old_header_file, add_new_header_file, last_function_name)
13689 (dbx_next_symbol_text, add_bincl_to_list)
13690 (find_corresponding_bincl_psymtab, set_namestring)
13691 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
13692 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
13693 * defs.h (command_line_input, print_address_symbolic)
13694 (deprecated_readline_begin_hook): Constify.
13695 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
13696 Constify.
13697 * event-top.c (handle_line_of_input): Constify and add cast.
13698 * exceptions.c (catch_errors): Constify.
13699 * exceptions.h (catch_errors): Constify.
13700 * expprint.c (print_subexp_standard, op_string, op_name)
13701 (op_name_standard, dump_raw_expression, dump_raw_expression):
13702 * expression.h (op_name, op_string, dump_raw_expression):
13703 Constify.
13704 * f-exp.y (yyerror): Constify.
13705 (struct token::oper): Constify.
13706 (struct f77_boolean_val::name): Constify.
13707 * f-lang.c (f_word_break_characters): Constify.
13708 * f-lang.h (f_yyerror): Constify.
13709 * fork-child.c (fork_inferior): Add cast.
13710 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
13711 (new_variant): Constify.
13712 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
13713 * gdbarch.c: Regenerate.
13714 * gdbcore.h (set_gnutarget): Constify.
13715 * go-exp.y (yyerror): Constify.
13716 (token::oper): Constify.
13717 * go-lang.h (go_yyerror): Constify.
13718 * go32-nat.c (go32_sysinfo): Constify.
13719 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
13720 * guile/scm-cmd.c (cmdscm_function): Constify.
13721 * guile/scm-param.c (pascm_param_value): Constify.
13722 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
13723 (h8300sx_register_name): Constify.
13724 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
13725 Constify.
13726 * ia64-tdep.c (ia64_register_names): Constify.
13727 * infcmd.c (construct_inferior_arguments): Constify.
13728 (path_command, attach_post_wait): Constify.
13729 * language.c (show_range_command, show_case_command)
13730 (unk_lang_error): Constify.
13731 * language.h (language_defn::la_error)
13732 (language_defn::la_name_of_this): Constify.
13733 * linespec.c (decode_line_2): Constify.
13734 * linux-thread-db.c (thread_db_err_str): Constify.
13735 * lm32-tdep.c (lm32_register_name): Constify.
13736 * m2-exp.y (yyerror): Constify.
13737 * m2-lang.h (m2_yyerror): Constify.
13738 * m32r-tdep.c (m32r_register_names): Constify and make static.
13739 * m68hc11-tdep.c (m68hc11_register_names): Constify.
13740 * m88k-tdep.c (m88k_register_name): Constify.
13741 * macroexp.c (appendmem): Constify.
13742 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
13743 (upgrade_type, parse_external, parse_partial_symbols)
13744 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
13745 (new_symbol): Constify.
13746 * memattr.c (mem_info_command): Constify.
13747 * mep-tdep.c (register_name_from_keyword): Constify.
13748 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
13749 Constify.
13750 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
13751 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
13752 * mi/mi-main.c (captured_mi_execute_command): Constify and add
13753 cast.
13754 (mi_execute_async_cli_command): Constify.
13755 * mips-tdep.c (mips_register_name): Constify.
13756 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
13757 (am33_register_name, am33_2_register_name)
13758 * moxie-tdep.c (moxie_register_names): Constify.
13759 * nat/linux-osdata.c (osdata_type): Constify fields.
13760 * nto-tdep.c (nto_parse_redirection): Constify.
13761 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
13762 (lookup_child_selector): Constify.
13763 (objc_methcall::name): Constify.
13764 * objc-lang.h (lookup_objc_class, lookup_child_selector)
13765 (lookup_struct_typedef): Constify.
13766 * objfiles.c (pc_in_section): Constify.
13767 * objfiles.h (pc_in_section): Constify.
13768 * p-exp.y (struct token::oper): Constify.
13769 (yyerror): Constify.
13770 * p-lang.h (pascal_yyerror): Constify.
13771 * parser-defs.h (op_name_standard): Constify.
13772 (op_print::string): Constify.
13773 (exp_descriptor::op_name): Constify.
13774 * printcmd.c (print_address_symbolic): Constify.
13775 * psymtab.c (print_partial_symbols): Constify.
13776 * python/py-breakpoint.c (stop_func): Constify.
13777 (bppy_get_expression): Constify.
13778 * python/py-cmd.c (cmdpy_completer::name): Constify.
13779 (cmdpy_function): Constify.
13780 * python/py-event.c (evpy_add_attribute)
13781 (gdbpy_initialize_event_generic): Constify.
13782 * python/py-event.h (evpy_add_attribute)
13783 (gdbpy_initialize_event_generic): Constify.
13784 * python/py-evts.c (add_new_registry): Constify.
13785 * python/py-finishbreakpoint.c (outofscope_func): Constify.
13786 * python/py-framefilter.c (get_py_iter_from_func): Constify.
13787 * python/py-inferior.c (get_buffer): Add cast.
13788 * python/py-param.c (parm_constant::name): Constify.
13789 * python/py-unwind.c (fprint_frame_id): Constify.
13790 * python/python.c (gdbpy_parameter_value): Constify.
13791 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
13792 * remote.c (memory_packet_config::name): Constify.
13793 (show_packet_config_cmd, remote_write_bytes)
13794 (remote_buffer_add_string):
13795 * reverse.c (exec_reverse_once): Constify.
13796 * rs6000-tdep.c (variant::name, variant::description): Constify.
13797 * rust-exp.y (rustyyerror): Constify.
13798 * rust-lang.c (rust_op_name): Constify.
13799 * rust-lang.h (rustyyerror): Constify.
13800 * serial.h (serial_ops::name): Constify.
13801 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
13802 (sh_sh3e_register_name, sh_sh2e_register_name)
13803 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
13804 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
13805 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
13806 (sh_sh4al_dsp_register_name): Constify.
13807 * sh64-tdep.c (sh64_register_name): Constify.
13808 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
13809 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
13810 * stabsread.c (patch_block_stabs, read_type_number)
13811 (ref_map::stabs, ref_add, process_reference)
13812 (symbol_reference_defined, define_symbol, define_symbol)
13813 (error_type, read_type, read_member_functions, read_cpp_abbrev)
13814 (read_one_struct_field, read_struct_fields, read_baseclasses)
13815 (read_tilde_fields, read_struct_type, read_array_type)
13816 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
13817 (read_huge_number, read_range_type, read_args, common_block_start)
13818 (find_name_end): Constify.
13819 * stabsread.h (common_block_start, define_symbol)
13820 (process_one_symbol, symbol_reference_defined, ref_add):
13821 * symfile.c (get_section_index, add_symbol_file_command):
13822 * symfile.h (get_section_index): Constify.
13823 * target-descriptions.c (tdesc_type::name): Constify.
13824 (tdesc_free_type): Add cast.
13825 * target.c (find_default_run_target):
13826 (add_deprecated_target_alias, find_default_run_target)
13827 (target_announce_detach): Constify.
13828 (do_option): Constify.
13829 * target.h (add_deprecated_target_alias): Constify.
13830 * thread.c (print_thread_info_1): Constify.
13831 * top.c (deprecated_readline_begin_hook, command_line_input):
13832 Constify.
13833 (init_main): Add casts.
13834 * top.h (handle_line_of_input): Constify.
13835 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
13836 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
13837 (tfind_command): Rename to ...
13838 (tfind_command_1): ... this and constify.
13839 (tfind_command): New function.
13840 (tfind_end_command, tfind_start_command): Adjust.
13841 (encode_source_string): Constify.
13842 * tracepoint.h (encode_source_string): Constify.
13843 * tui/tui-data.c (tui_partial_win_by_name): Constify.
13844 * tui/tui-data.h (tui_partial_win_by_name): Constify.
13845 * tui/tui-source.c (tui_set_source_content_nil): Constify.
13846 * tui/tui-source.h (tui_set_source_content_nil): Constify.
13847 * tui/tui-win.c (parse_scrolling_args): Constify.
13848 * tui/tui-windata.c (tui_erase_data_content): Constify.
13849 * tui/tui-windata.h (tui_erase_data_content): Constify.
13850 * tui/tui-winsource.c (tui_erase_source_content): Constify.
13851 * tui/tui.c (tui_enable): Add cast.
13852 * utils.c (defaulted_query): Constify.
13853 (init_page_info): Add cast.
13854 (puts_debug, subset_compare): Constify.
13855 * utils.h (subset_compare): Constify.
13856 * varobj.c (varobj_format_string): Constify.
13857 * varobj.h (varobj_format_string): Constify.
13858 * vax-tdep.c (vax_register_name): Constify.
13859 * windows-nat.c (windows_detach): Constify.
13860 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
13861 * xml-support.c (gdb_xml_end_element): Constify.
13862 * xml-tdesc.c (tdesc_start_reg): Constify.
13863 * xstormy16-tdep.c (xstormy16_register_name): Constify.
13864 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
13865 * xtensa-tdep.h (xtensa_register_t::name): Constify.
13866
13867 2017-04-05 Pedro Alves <palves@redhat.com>
13868
13869 * proc-api.c (struct trans): Constify.
13870 (procfs_note): Constify.
13871 * proc-events.c (struct trans, syscall_table):
13872 * proc-flags.c (struct trans): Constify.
13873 * proc-utils.h (procfs_note): Constify.
13874 * proc-why.c (struct trans): Constify.
13875 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
13876 (procfs_detach): Constify.
13877 * sol-thread.c (struct string_map): Constify.
13878 (td_err_string, td_state_string): Constify.
13879
13880 2017-04-05 Pedro Alves <palves@redhat.com>
13881
13882 * proc-api.c (procfs_filename): Don't initialize
13883 procfs_filename.
13884 (prepare_to_trace): Assume procfs_filename is non-NULL.
13885 (_initialize_proc_api): Give procfs_filename a default value here.
13886
13887 2017-04-05 Pedro Alves <palves@redhat.com>
13888
13889 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
13890 'cond_string' parameter.
13891 (extract_exception_regexp): Constify 'string' parameter.
13892 (catch_exception_command_1): Constify.
13893 * breakpoint.c (init_catchpoint)
13894 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
13895 parameter.
13896 (ep_parse_optional_if_clause, catch_fork_command_1)
13897 (catch_exec_command_1): Constify.
13898 * breakpoint.h (init_catchpoint): Constify 'cond_string'
13899 parameter.
13900 (ep_parse_optional_if_clause): Constify.
13901 * cli/cli-utils.c (remove_trailing_whitespace)
13902 (check_for_argument): Constify.
13903 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
13904 non-const overload.
13905 (check_for_argument): Likewise.
13906
13907 2017-04-05 Pedro Alves <palves@redhat.com>
13908
13909 * event-top.c (command_line_handler): Add cast to execute_command
13910 call.
13911 * record-btrace.c (cmd_record_btrace_bts_start)
13912 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
13913 (cmd_record_btrace_start): Add cast to execute_command call.
13914 * record-full.c (record_full_goto_insn):
13915 * record.c (record_start, record_stop): Add cast to
13916 execute_command_to_string calls.
13917 (cmd_record_start): Add cast to execute_command calls.
13918
13919 2017-04-05 Pedro Alves <palves@redhat.com>
13920
13921 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
13922 static inline function.
13923 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
13924 array and use gdb_PyArg_ParseTupleAndKeywords.
13925 * python/py-cmd.c (cmdpy_init): Likewise.
13926 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
13927 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
13928 (infpy_search_memory): Likewise.
13929 * python/py-objfile.c (objfpy_add_separate_debug_file)
13930 (gdbpy_lookup_objfile): Likewise.
13931 * python/py-symbol.c (gdbpy_lookup_symbol)
13932 (gdbpy_lookup_global_symbol): Likewise.
13933 * python/py-type.c (gdbpy_lookup_type): Likewise.
13934 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
13935 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
13936 Likewise.
13937
13938 2017-04-05 Pedro Alves <palves@redhat.com>
13939
13940 * python/python-internal.h (gdb_PyGetSetDef): New type.
13941 * python/py-block.c (block_object_getset)
13942 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
13943 * python/py-event.c (event_object_getset)
13944 (finish_breakpoint_object_getset): Likewise.
13945 * python/py-inferior.c (inferior_object_getset): Likewise.
13946 * python/py-infthread.c (thread_object_getset): Likewise.
13947 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
13948 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
13949 * python/py-objfile.c (objfile_getset): Likewise.
13950 * python/py-progspace.c (pspace_getset): Likewise.
13951 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
13952 Likewise.
13953 * python/py-record.c (recpy_record_getset): Likewise.
13954 * python/py-symbol.c (symbol_object_getset): Likewise.
13955 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
13956 Likewise.
13957 * python/py-type.c (type_object_getset, field_object_getset):
13958 Likewise.
13959 * python/py-value.c (value_object_getset): Likewise.
13960
13961 2017-04-05 Pedro Alves <palves@redhat.com>
13962
13963 * python/python-internal.h (gdb_PyObject_CallMethod)
13964 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
13965 New functions.
13966 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
13967 (PySys_GetObject, PySys_SetPath): New macros.
13968
13969 2017-04-05 Pedro Alves <palves@redhat.com>
13970
13971 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
13972 info_osdata_command.
13973 * osdata.c (info_osdata_command): Rename to ...
13974 (info_osdata): ... this. Constify 'type' parameter, and remove
13975 the 'from_tty' parameter. Accept NULL TYPE.
13976 (info_osdata_command): New function.
13977 * osdata.h (info_osdata_command): Remove declaration.
13978 (info_osdata): New declaration.
13979
13980 2017-04-05 Pedro Alves <palves@redhat.com>
13981
13982 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
13983 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
13984 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
13985 parameter.
13986 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
13987 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
13988 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
13989 parameter.
13990 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
13991 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
13992 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
13993 (mi_cmd_file_list_exec_source_files)
13994 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
13995 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
13996 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
13997 parameter.
13998 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
13999 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
14000 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
14001 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
14002 (mi_cmd_stack_info_frame): Constify 'command' parameter.
14003 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
14004 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
14005 'command' parameter.
14006 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
14007 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
14008 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
14009 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
14010 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
14011 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
14012 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
14013 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
14014 (mi_cmd_var_set_update_range): Constify 'command' parameter.
14015 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
14016 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
14017 parameter.
14018 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
14019 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
14020 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
14021 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
14022 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
14023 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
14024 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
14025 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
14026 (mi_cmd_data_list_changed_registers)
14027 (mi_cmd_data_write_register_values)
14028 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
14029 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
14030 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
14031 (mi_cmd_list_features, mi_cmd_list_target_features)
14032 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
14033 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
14034 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
14035 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
14036 (mi_cmd_trace_frame_collected): Constify 'command'
14037 parameter.
14038 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
14039 'command' parameter.
14040
14041 2017-04-05 Pedro Alves <palves@redhat.com>
14042
14043 * ada-lang.c (ada_completer_word_break_characters): Now a const
14044 array.
14045 (ada_get_gdb_completer_word_break_characters): Constify.
14046 * completer.c (gdb_completer_command_word_break_characters)
14047 (gdb_completer_file_name_break_characters)
14048 (gdb_completer_quote_characters): Now const arrays.
14049 (get_gdb_completer_quote_characters): Constify.
14050 (set_rl_completer_word_break_characters): New function.
14051 (set_gdb_completion_word_break_characters)
14052 (complete_line_internal): Use it.
14053 * completer.h (get_gdb_completer_quote_characters): Constify.
14054 (set_rl_completer_word_break_characters): Declare.
14055 * f-lang.c (f_word_break_characters): Constify.
14056 * language.c (default_word_break_characters): Constify.
14057 * language.h (language_defn::la_word_break_characters): Constify.
14058 (default_word_break_characters): Constify.
14059 * top.c (init_main): Use set_rl_completer_word_break_characters.
14060
14061 2017-04-05 Pedro Alves <palves@redhat.com>
14062
14063 * aix-thread.c (aix_thread_pid_to_str)
14064 (aix_thread_extra_thread_info): Constify.
14065 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
14066 * bsd-uthread.c (bsd_uthread_extra_thread_info)
14067 (bsd_uthread_pid_to_str): Constify.
14068 * corelow.c (core_pid_to_str): Constify.
14069 * darwin-nat.c (darwin_pid_to_str): Constify.
14070 * fbsd-nat.c (fbsd_pid_to_str): Constify.
14071 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
14072 Constify.
14073 * gnu-nat.c (gnu_pid_to_str): Constify.
14074 * go32-nat.c (go32_pid_to_str): Constify.
14075 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
14076 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
14077 * inferior.c (inferior_pid_to_str): Constify.
14078 * linux-nat.c (linux_nat_pid_to_str): Constify.
14079 * linux-tdep.c (linux_core_pid_to_str): Constify.
14080 * linux-thread-db.c (thread_db_pid_to_str)
14081 (thread_db_extra_thread_info): Constify.
14082 * nto-tdep.c (nto_extra_thread_info): Constify.
14083 * nto-tdep.h (nto_extra_thread_info): Constify.
14084 * obsd-nat.c (obsd_pid_to_str): Constify.
14085 * procfs.c (procfs_pid_to_str): Constify.
14086 * ravenscar-thread.c (ravenscar_extra_thread_info)
14087 (ravenscar_pid_to_str): Constify.
14088 * remote-sim.c (gdbsim_pid_to_str): Constify.
14089 * remote.c (remote_threads_extra_info, remote_pid_to_str):
14090 Constify.
14091 * sol-thread.c (solaris_pid_to_str): Constify.
14092 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
14093 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
14094 * target.c (default_pid_to_str, target_pid_to_str)
14095 (normal_pid_to_str, default_pid_to_str): Constify.
14096 * target.h (target_ops::to_pid_to_str)
14097 (target_ops::to_extra_thread_info): Constify.
14098 (target_pid_to_str, normal_pid_to_str): Constify.
14099 * windows-nat.c (windows_pid_to_str): Constify.
14100 * gdbarch.sh (core_pid_to_str): Constify.
14101 * target-delegates.c: Regenerate.
14102 * gdbarch.h, gdbarch.c: Regenerate.
14103
14104 2017-04-05 Pedro Alves <palves@redhat.com>
14105
14106 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
14107 the memory of the temporary warning_pre_print override.
14108 * utils.c (warning_pre_print): Constify.
14109 * utils.h (warning_pre_print): Constify.
14110
14111 2017-04-05 Pedro Alves <palves@redhat.com>
14112
14113 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
14114 (shell_command): New function.
14115 (make_command): Use std::string.
14116 (init_cli_cmds): Register shell_command instead of shell_escape.
14117
14118 2017-04-05 Pedro Alves <palves@redhat.com>
14119
14120 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
14121 * tracepoint.c (default_collect): Don't initialize.
14122
14123 2017-04-05 Pedro Alves <palves@redhat.com>
14124
14125 * macroexp.c (macro_buffer::shared): Now a bool.
14126 (init_buffer): Update.
14127 (init_shared_buffer): Constify 'addr' parameter.
14128 (substitute_args, expand, macro_expand, macro_expand_next): Remove
14129 casts.
14130
14131 2017-04-05 Pedro Alves <palves@redhat.com>
14132
14133 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
14134 * disasm.c (set_disassembler_options): Constify local.
14135 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
14136
14137 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
14138
14139 PR gdb/21352
14140 * tracefile.c (tsave_command): Fix argument parsing for '-r'
14141 option.
14142
14143 2017-04-05 Yao Qi <yao.qi@linaro.org>
14144
14145 * frame.c (frame_unwind_register_unsigned): Call
14146 frame_unwind_register_value.
14147
14148 2017-04-05 Yao Qi <yao.qi@linaro.org>
14149
14150 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
14151 Use gdb_test_multiple, and don't match anchor.
14152
14153 2017-04-05 Pedro Alves <palves@redhat.com>
14154
14155 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
14156 (Write After Approval): Remove Simon Marchi.
14157
14158 2017-04-05 Pedro Alves <palves@redhat.com>
14159
14160 * common/gdb_optional.h (optional::optional): Make constexpr and
14161 initialize m_dummy.
14162
14163 2017-04-04 John Baldwin <jhb@FreeBSD.org>
14164
14165 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14166 (amd64fbsd_jmp_buf_reg_offset): Remove.
14167 (amd64fbsd_supply_uthread): Remove function.
14168 (amd64fbsd_collect_uthread): Remove function.
14169 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
14170 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
14171 (x86_64-*-freebsd*): Remove bsd-uthread.o.
14172 (fbsd-nat.c): Update comment.
14173 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
14174 (i386fbsd_jmp_buf_reg_offset): Remove.
14175 (i386fbsd_supply_uthread): Remove function.
14176 (i386fbsd_collect_uthread): Remove function.
14177 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
14178
14179 2017-04-04 John Baldwin <jhb@FreeBSD.org>
14180
14181 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
14182 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
14183 * NEWS: Mention that support for FreeBSD/alpha was removed.
14184 * alpha-fbsd-tdep.c: Delete file.
14185 * config/alpha/fbsd.mh: Delete file.
14186 * configure.host: Delete alpha*-*-freebsd* and
14187 alpha*-*-kfreebsd*-gnu.
14188 * configure.tgt: Delete alpha*-*-freebsd* and
14189 alpha*-*-kfreebsd*-gnu.
14190
14191 2017-04-04 John Baldwin <jhb@FreeBSD.org>
14192
14193 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
14194 amd64bsd_store_inferior_registers): Use ptid from regcache.
14195
14196 2017-04-04 Pedro Alves <palves@redhat.com>
14197
14198 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
14199 data fields, make them private and add "m_" prefixes.
14200 (lnp_state_machine::lnp_state_machine): New ctor.
14201 (record_line, check_line_address, handle_set_discriminator)
14202 (handle_set_address, handle_advance_pc, handle_special_opcode)
14203 (handle_advance_line, handle_set_file, handle_negate_stmt)
14204 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
14205 (end_sequence, advance_line): New methods.
14206 (m_gdbarch, m_record_lines_p): New fields.
14207 (lnp_reader_state): Delete.
14208 (dwarf_record_line): Rename to ...
14209 (lnp_state_machine::record_line): ... adjust.
14210 (init_lnp_state_machine): Delete.
14211 (lnp_state_machine::lnp_state_machine): New.
14212 (check_line_address): Rename to ...
14213 (lnp_state_machine::check_line_address): This.
14214 (dwarf_decode_lines_1): Remove reference to "reader_state".
14215 Adjust lnp_state_machine having a non-default ctor. Use bool.
14216 State machine internal state manipulation moved to
14217 lnp_state_machine methods.
14218
14219 2017-04-04 Pedro Alves <palves@redhat.com>
14220
14221 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
14222 unittests/offset-type-selftests.c.
14223 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
14224 * common/offset-type.h: New file.
14225 * common/preprocessor.h: New file.
14226 * common/traits.h: New file.
14227 * common/valid-expr.h: New file.
14228 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
14229 sect_offset and cu_offset strong typedefs throughout.
14230 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
14231 typedefs throughout.
14232 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
14233 sect_offset and cu_offset strong typedefs throughout.
14234 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
14235 typedefs throughout.
14236 * gdbtypes.h: Include "common/offset-type.h".
14237 (cu_offset): Now an offset type (strong typedef) instead of a
14238 struct.
14239 (sect_offset): Likewise.
14240 (union call_site_parameter_u): Rename "param_offset" field to
14241 "param_cu_off".
14242 * unittests/offset-type-selftests.c: New file.
14243
14244 2017-04-04 Pedro Alves <palves@redhat.com>
14245
14246 * common/underlying.h: New file.
14247 * dwarf2read.c: Include "common/gdb_optional.h" and
14248 "common/underlying.h".
14249 (dir_index, file_name_index): New types.
14250 (file_entry): Use them.
14251 (file_entry::include): Use to_underlying.
14252 (line_header::add_file_name): Use dir_index.
14253 (read_formatted_entries): Use gdb::optional. Read form before
14254 writting to file_entry.
14255 (dwarf_decode_line_header): Use dir_index.
14256 (lnp_state_machine::current_file): Use to_underlying.
14257 (lnp_state_machine::file): Change type to file_name_index.
14258 (dwarf_record_line): Use to_underlying.
14259 (init_lnp_state_machine): Use file_name_index.
14260 (dwarf_decode_lines_1): Use dir_index and file_name_index.
14261
14262 2017-04-04 Pedro Alves <palves@redhat.com>
14263
14264 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
14265 operator bool, has_value and get methods.
14266
14267 2017-04-04 Pedro Alves <palves@redhat.com>
14268
14269 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
14270 fields.
14271 (line_header): Initialize all data fields. Change type of
14272 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
14273 Change type of include_dirs to std::vector<const char *>. Remove
14274 num_include_dirs, include_dirs_size. Change type of file_names to
14275 std::vector<file_entry>. Remove num_file_names, file_names_size.
14276 (line_header::line_header): New.
14277 (line_header::add_include_dir, line_header::add_file_name): New
14278 methods.
14279 (line_header::include_dir_at): Remove NULL check.
14280 (line_header::file_name_at): Add const overload.
14281 (line_header_up): New unique_ptr typedef.
14282 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
14283 std::vector. Remove free_line_header call.
14284 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
14285 free_line_header call.
14286 (free_cu_line_header): Delete.
14287 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
14288 (setup_type_unit_groups): Use line_header_up instead of cleanups.
14289 Adjust to use std::vector.
14290 (free_line_header): Delete.
14291 (free_line_header_voidp): Use delete.
14292 (add_include_dir): Replace with ...
14293 (line_header::add_include_dir): ... this method. Use std::vector.
14294 (add_file_name): Replace with ...
14295 (line_header::add_file_name): ... this method. Use std::vector.
14296 (add_include_dir_stub): Delete.
14297 (read_formatted_entries): Remove memset.
14298 (dwarf_decode_line_header): Return a line_header_up instead of a
14299 raw pointer. Remove cleanup handling. Pass lambdas to
14300 read_formatted_entries. Adjust to use line_header methods.
14301 (dwarf_decode_lines_1): Adjust to use line_header methods.
14302 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
14303 use std::vector.
14304
14305 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
14306
14307 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
14308 instead of struct ptid.
14309
14310 2017-05-04 Alan Hayward <alan.hayward@arm.com>
14311
14312 * frame.c (get_frame_register_bytes): Unwind using value.
14313 (put_frame_register_bytes): Likewise.
14314
14315 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
14316
14317 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
14318 aggregate-like.
14319
14320 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
14321
14322 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
14323
14324 2017-03-29 Yao Qi <yao.qi@linaro.org>
14325
14326 * gdbthread.h (struct thread_info): Declare constructor and
14327 destructor. Add some in-class member initializers.
14328 * thread.c (free_thread): Remove.
14329 (init_thread_list): Call delete instead of free_thread.
14330 (new_thread): Call thread_info constructor.
14331 (thread_info::thread_info): New function.
14332 (thread_info::~thread_info): New function.
14333 (delete_thread_1): Call delete instead of free_thread.
14334 (make_cleanup_restore_current_thread): Move tp and frame to
14335 inner block.
14336
14337 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14338
14339 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
14340 (arc_skip_prologue): Likewise.
14341 (arc_make_frame_cache): Likewise.
14342 (arc_pv_get_operand): New function.
14343 (arc_is_in_prologue): Likewise.
14344 (arc_analyze_prologue): Likewise.
14345 (arc_print_frame_cache): Likewise.
14346 (MAX_PROLOGUE_LENGTH): New constant.
14347
14348 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14349
14350 * configure.tgt: Add arc-insn.o.
14351 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
14352 (dump_arc_instruction_command): New function.
14353 (arc_fprintf_disasm): Likewise.
14354 (arc_disassemble_info): Likewise.
14355 (arc_insn_get_operand_value): Likewise.
14356 (arc_insn_get_operand_value_signed): Likewise.
14357 (arc_insn_get_memory_base_reg): Likewise.
14358 (arc_insn_get_memory_offset): Likewise.
14359 (arc_insn_get_branch_target): Likewise.
14360 (arc_insn_dump): Likewise.
14361 (arc_insn_get_linear_next_pc): Likewise.
14362 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
14363 (arc_disassemble_info): Likewise.
14364 (arc_insn_get_branch_target): Likewise.
14365 (arc_insn_get_linear_next_pc): Likewise.
14366 * NEWS: Mention new "maint print arc arc-instruction".
14367
14368 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14369
14370 * arc-tdep (maintenance_print_arc_list): New variable.
14371 (maintenance_print_arc_command): New function.
14372
14373 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
14374
14375 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
14376 Add "limm" and "reserved".
14377 (arc_cannot_fetch_register, arc_cannot_store_register): Add
14378 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
14379 * arc-tdep.h (arc_regnum): Likewise.
14380
14381 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14382
14383 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14384 for THREADPTR register.
14385 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
14386 register.
14387 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
14388 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
14389 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
14390
14391 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14392
14393 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
14394 registers above gdbarch_num_regs (gdbarch) as privileged in
14395 call0 ABI.
14396
14397 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14398
14399 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
14400 for a single specified register or for all registers in
14401 a0_base..a0_base + C0_NREGS range.
14402 (supply_gregset_reg): Call regcache_raw_supply for a single
14403 specified register or for all registers in a0_base..a0_base +
14404 C0_NREGS range.
14405
14406 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14407
14408 * arch/xtensa.h (C0_NREGS): Add definition.
14409 * xtensa-tdep.c (C0_NREGS): Remove definition.
14410
14411 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
14412
14413 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
14414 Drop xtensa_default_isa initialization.
14415 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
14416
14417 2017-03-27 Pedro Alves <palves@redhat.com>
14418
14419 * dwarf2read.c (file_entry) <dir_index>: Add comment.
14420 (file_entry::include_dir): New method.
14421 (line_header::include_dir_at, line_header::file_name_at): New
14422 methods.
14423 (setup_type_unit_groups, setup_type_unit_groups)
14424 (psymtab_include_file_name): Simplify using the new methods.
14425 (lnp_state_machine) <the_line_header>: New field.
14426 <file>: Add comment.
14427 (lnp_state_machine::current_file): New method.
14428 (dwarf_record_line): Simplify using the new methods.
14429 (init_lnp_state_machine): Initialize the "the_line_header" field.
14430 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
14431 Simplify using the new methods.
14432
14433 2017-03-27 Pedro Alves <palves@redhat.com>
14434
14435 * cp-name-parser.y (make_empty): Delete.
14436 (demangler_special, nested_name, ptr_operator, array_indicator)
14437 (direct_declarator, declarator_1): Use fill_comp instead of
14438 make_empty.
14439
14440 2017-03-27 Pedro Alves <palves@redhat.com>
14441
14442 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
14443 to ATTRIBUTE_PRINTF.
14444 * solib-target.c (library_list_start_list): Print "string" not
14445 "version".
14446 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
14447 gdb_xml_error call.
14448
14449 2017-03-27 Pedro Alves <palves@redhat.com>
14450
14451 * dwarf2read.c (struct file_and_directory): New.
14452 (dwarf2_get_dwz_file): Adjust to use std::string.
14453 (dw2_get_file_names_reader): Adjust to use file_and_directory.
14454 (find_file_and_directory): Adjust to return a file_and_directory
14455 object.
14456 (read_file_scope): Adjust to use file_and_directory. Remove
14457 make_cleanup/do_cleanups calls.
14458 (open_and_init_dwp_file): Adjust to use std::string. Remove
14459 make_cleanup/do_cleanups calls.
14460 * python/python.c (do_start_initialization): Adjust to ldirname
14461 returning a std::string.
14462 * utils.c (ldirname): Now returns a std::string.
14463 * utils.h (ldirname): Change return type to std::string.
14464 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
14465 returning a std::string.
14466 * xml-tdesc.c (file_read_description_xml): Likewise.
14467
14468 2017-03-24 Alan Hayward <alan.hayward@arm.com>
14469
14470 * regcache.c (regcache_debug_print_register): New function.
14471 * regcache.h (regcache_debug_print_register): New declaration.
14472 * target.c (debug_print_register): Remove.
14473 (target_fetch_registers): Call regcache_debug_print_register.
14474 (target_store_registers): Likewise.
14475
14476 2017-03-24 Pádraig Brady <pbrady@fb.com>
14477
14478 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
14479 reference beyond the 'lh->include_dirs' array before accessing to
14480 it.
14481 (psymtab_include_file_name): Likewise.
14482 (dwarf_decode_lines_1): Likewise.
14483 (dwarf_decode_lines): Likewise.
14484 (file_file_name): Likewise.
14485
14486 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
14487
14488 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
14489 inferior_ptid.
14490 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14491 ps_lsetfpregs): Likewise.
14492 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
14493 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
14494 ps_lsetfpregs): Likewise.
14495 * target.c (target_fetch_registers, target_store_registers):
14496 Remove asserts.
14497
14498 2017-03-23 Alan Hayward <alan.hayward@arm.com>
14499
14500 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
14501
14502 2017-03-23 Yao Qi <yao.qi@linaro.org>
14503
14504 * aarch64-tdep.c (aarch64_process_record_test): Declare.
14505 (_initialize_aarch64_tdep): Register it.
14506 (aarch64_record_load_store): Handle PRFM instruction.
14507 (aarch64_process_record_test): New function.
14508
14509 2017-03-23 Yao Qi <yao.qi@linaro.org>
14510
14511 * aarch64-tdep.c (aarch64_record_load_store): Fix code
14512 indentation.
14513
14514 2017-03-23 Yao Qi <yao.qi@linaro.org>
14515
14516 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
14517
14518 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
14519
14520 python/python.c (do_start_initialization): Fix memory leak.
14521
14522 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
14523
14524 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
14525 using get_ptrace_pid.
14526 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
14527 inferior_ptid.
14528 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
14529 inferior_ptid instead of pid.
14530
14531 2017-03-22 Yao Qi <yao.qi@linaro.org>
14532
14533 * aarch64-tdep.c: Wrap locally used classes in anonymous
14534 namespace.
14535 * arm-tdep.c: Likewise.
14536 * linespec.c: Likewise.
14537 * ui-out.c: Likewise.
14538
14539 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
14540
14541 PR gdb/19637
14542 * python/lib/gdb/printer/bound_registers.py: Import sys.
14543
14544 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14545
14546 * windows-nat.c (do_windows_fetch_inferior_registers): Add
14547 windows_thread_info parameter and use it instead of
14548 current_thread.
14549 (windows_fetch_inferior_registers): Don't set current_thread,
14550 pass the thread to do_windows_fetch_inferior_registers. Use
14551 ptid from regcache instead of inferior_ptid.
14552 (do_windows_store_inferior_registers): Add windows_thread_info
14553 parameter and use it instead of current_thread.
14554 (windows_store_inferior_registers): Don't set current_thread,
14555 pass the thread to do_windows_store_inferior_registers. Use
14556 ptid from regcache instead of inferior_ptid.
14557
14558 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
14559
14560 * ser-mingw.c (ser_windows_raw): Remove reference to
14561 struct serial::current_timeout.
14562
14563 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
14564
14565 PR tdep/20928
14566 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
14567 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
14568 (sparc64_fsr_type): Fix %fsr decoding.
14569
14570 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
14571
14572 * python/py-record-btrace.c (btpy_insn_data): Change return type
14573 for Python 2.
14574
14575 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14576
14577 * spu-linux-nat.c (spu_fetch_inferior_registers,
14578 spu_store_inferior_registers): Use ptid from regcache, set and
14579 restore inferior_ptid.
14580 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
14581 Likewise.
14582
14583 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
14584
14585 * i386-linux-nat.c (fetch_register, store_register,
14586 i386_linux_fetch_inferior_registers,
14587 i386_linux_store_inferior_registers): Use ptid from regcache.
14588 * ia64-linux-nat.c (ia64_linux_fetch_register,
14589 ia64_linux_store_register): Likewise.
14590 * inf-ptrace.c (inf_ptrace_fetch_register,
14591 inf_ptrace_store_register): Likewise.
14592 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
14593 m32r_linux_store_inferior_registers): Likewise.
14594 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
14595 m68kbsd_store_inferior_registers): Likewise.
14596 * m68k-linux-nat.c (fetch_register, store_register,
14597 m68k_linux_fetch_inferior_registers,
14598 m68k_linux_store_inferior_registers): Likewise.
14599 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
14600 m88kbsd_store_inferior_registers): Likewise.
14601 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
14602 mips_fbsd_store_inferior_registers): Likewise.
14603 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
14604 mips64_linux_regsets_store_registers): Likewise.
14605 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
14606 mipsnbsd_store_inferior_registers): Likewise.
14607 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
14608 mips64obsd_store_inferior_registers): Likewise.
14609 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
14610 Likewise.
14611 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
14612 ppcfbsd_store_inferior_registers): Likewise.
14613 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
14614 ppc_linux_store_inferior_registers): Likewise.
14615 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
14616 ppcnbsd_store_inferior_registers): Likewise.
14617 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
14618 ppcobsd_store_registers): Likewise.
14619 * procfs.c (procfs_fetch_registers, procfs_store_registers):
14620 Likewise.
14621 * ravenscar-thread.c (ravenscar_fetch_registers,
14622 ravenscar_store_registers, ravenscar_prepare_to_store):
14623 Likewise.
14624 * record-btrace.c (record_btrace_fetch_registers,
14625 record_btrace_store_registers, record_btrace_prepare_to_store):
14626 Likewise.
14627 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
14628 Lookup inferior using ptid from regcache, instead of
14629 current_inferior.
14630 * remote.c (remote_fetch_registers, remote_store_registers): Use
14631 ptid from regcache.
14632 * rs6000-nat.c (fetch_register, store_register): Likewise.
14633 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
14634 s390_linux_store_inferior_registers): Likewise.
14635 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
14636 shnbsd_store_inferior_registers): Likewise.
14637 * sol-thread.c (sol_thread_fetch_registers,
14638 sol_thread_store_registers): Likewise.
14639 * sparc-nat.c (sparc_fetch_inferior_registers,
14640 sparc_store_inferior_registers): Likewise.
14641 * tilegx-linux-nat.c (fetch_inferior_registers,
14642 store_inferior_registers): Likewise.
14643 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
14644 vaxbsd_store_inferior_registers): Likewise.
14645 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
14646 store_xtregs): Likewise.
14647
14648 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14649
14650 PR gdb/14441
14651 * NEWS: Mention support for rvalue references in GDB and python.
14652 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
14653 supports both lvalue and rvalue references.
14654
14655 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14656
14657 PR gdb/14441
14658 * gdbtypes.c (rank_one_type): Implement overloading
14659 resolution rules regarding rvalue references.
14660
14661 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14662
14663 PR gdb/14441
14664 * aarch64-tdep.c (aarch64_type_align)
14665 (aarch64_extract_return_value, aarch64_store_return_value): Change
14666 lvalue reference type checks to general reference type checks.
14667 * amd64-tdep.c (amd64_classify): Likewise.
14668 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
14669 Likewise.
14670 * arm-tdep.c (arm_type_align, arm_extract_return_value)
14671 (arm_store_return_value): Likewise.
14672 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
14673 * c-typeprint.c (c_print_type): Likewise.
14674 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
14675 (cplus_number_of_children, cplus_describe_child): Likewise.
14676 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
14677 * completer.c (expression_completer): Likewise.
14678 * cp-support.c (make_symbol_overload_list_adl_namespace):
14679 Likewise.
14680 * darwin-nat-info.c (info_mach_region_command): Likewise.
14681 * dwarf2loc.c (entry_data_value_coerce_ref)
14682 (value_of_dwarf_reg_entry): Likewise.
14683 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
14684 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
14685 Likewise.
14686 * findvar.c (extract_typed_address, store_typed_address):
14687 Likewise.
14688 * gdbtypes.c (rank_one_type): Likewise.
14689 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
14690 * infcall.c (value_arg_coerce): Likewise.
14691 * language.c (pointer_type): Likewise.
14692 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
14693 Likewise.
14694 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
14695 * mn10300-tdep.c (mn10300_type_align): Likewise.
14696 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
14697 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
14698 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
14699 Likewise.
14700 * printcmd.c (print_formatted, x_command): Likewise.
14701 * python/py-type.c (typy_get_composite, typy_template_argument):
14702 Likewise.
14703 * python/py-value.c (valpy_referenced_value)
14704 (valpy_get_dynamic_type, value_has_field): Likewise.
14705 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
14706 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
14707 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
14708 * spu-tdep.c (spu_scalar_value_p): Likewise.
14709 * symtab.c (lookup_symbol_aux): Likewise.
14710 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
14711 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
14712 Likewise.
14713 * valops.c (value_cast_pointers, value_cast)
14714 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
14715 (value_struct_elt, value_struct_elt_bitpos)
14716 (value_find_oload_method_list, find_overload_match)
14717 (value_rtti_indirect_type): Likewise.
14718 * valprint.c (val_print_scalar_type_p, generic_val_print):
14719 Likewise.
14720 * value.c (value_actual_type, value_as_address, unpack_long)
14721 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
14722 (coerce_ref): Likewise.
14723 * varobj.c (varobj_get_value_type): Likewise.
14724
14725 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14726
14727 PR gdb/14441
14728 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
14729 table of constants.
14730 * python/lib/gdb/command/explore.py: Support exploring values
14731 of rvalue reference types.
14732 * python/lib/gdb/types.py: Implement get_basic_type() for
14733 rvalue reference types.
14734 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
14735 constant.
14736 * python/py-value.c (valpy_getitem): Add an rvalue reference
14737 check.
14738 (valpy_reference_value): Add new parameter "refcode".
14739 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
14740 New wrappers for valpy_reference_value().
14741 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14742 (gdbpy_invoke_xmethod): Likewise.
14743
14744 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14745
14746 PR gdb/14441
14747 * dwarf2read.c (process_die, read_type_die_1): Handle the
14748 DW_TAG_rvalue_reference_type DIE.
14749 (read_tag_reference_type): Add new parameter "refcode".
14750
14751 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14752
14753 PR gdb/14441
14754 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
14755 (c_type_print_modifier, c_type_print_varspec_suffix)
14756 (c_type_print_base): Support printing rvalue reference types.
14757 * c-valprint.c (c_val_print, c_value_print): Support printing
14758 rvalue reference values.
14759
14760 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14761
14762 PR gdb/14441
14763 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
14764 typename.
14765 * cp-support.c (replace_typedefs): Handle
14766 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
14767 * python/py-type.c (typy_lookup_type): Likewise.
14768
14769 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14770
14771 PR gdb/14441
14772 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
14773 * parse.c (insert_type): Change assert statement.
14774 (follow_types): Handle rvalue reference types.
14775 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
14776 constant.
14777
14778 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14779
14780 PR gdb/14441
14781 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
14782 value_ref() interface.
14783 * c-valprint.c (c_value_print): Likewise.
14784 * infcall.c (value_arg_coerce): Likewise.
14785 * python/py-value.c (valpy_reference_value): Likewise.
14786 * valops.c (value_cast, value_reinterpret_cast)
14787 (value_dynamic_cast, typecmp): Likewise.
14788 (value_ref): Parameterize by kind of return value reference type.
14789 * value.h (value_ref): Add new parameter "refcode".
14790
14791 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14792
14793 PR gdb/14441
14794 * dwarf2read.c (read_tag_reference_type): Use
14795 lookup_lvalue_reference_type() instead of lookup_reference_type().
14796 * eval.c (evaluate_subexp_standard): Likewise.
14797 * f-exp.y: Likewise.
14798 * gdbtypes.c (make_reference_type, lookup_reference_type):
14799 Generalize with rvalue reference types.
14800 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
14801 convenience wrappers for lookup_reference_type().
14802 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
14803 reference kind parameter.
14804 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
14805 wrappers for lookup_reference_type().
14806 * guile/scm-type.c (gdbscm_type_reference): Use
14807 lookup_lvalue_reference_type() instead of lookup_reference_type().
14808 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
14809 * parse.c (follow_types): Likewise.
14810 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
14811 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
14812 Likewise.
14813 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
14814 (gdbpy_invoke_xmethod): Likewise.
14815 * stabsread.c: Provide extra argument to make_reference_type()
14816 call.
14817 * valops.c (value_ref, value_rtti_indirect_type): Use
14818 lookup_lvalue_reference_type() instead of lookup_reference_type().
14819
14820 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
14821
14822 PR gdb/14441
14823 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
14824 (TYPE_IS_REFERENCE): New macro.
14825 (struct type): Add rvalue_reference_type field.
14826 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
14827
14828 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14829
14830 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
14831 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
14832 New function definition.
14833 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
14834 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
14835 New function declaration.
14836 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
14837 * mi/mi-interp.h: New file.
14838 * solib.c (info_sharedlibrary_command): Replace for loop with
14839 ALL_SO_LIBS macro
14840 * solib.h (update_solib_list): New function declaration.
14841 (so_list_head): Move macro.
14842 * solist.h (ALL_SO_LIBS): New macro.
14843
14844 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
14845
14846 * infcmd.c (post_create_inferior): Remove unused argument in
14847 call to solib_add.
14848 * remote.c (remote_start_remote): Likewise.
14849 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
14850 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
14851 (enable_break): Likewise.
14852 * solib.c (update_solib_list): Remove unused target argument
14853 and its documentation.
14854 (solib_add): Remove unused target argument. Remove unused
14855 argument in call to update_solib_list.
14856 (info_sharedlibrary_command): Remove unused argument in call
14857 to update_solib_list.
14858 (sharedlibrary_command): Remove unused argument in call to
14859 solib_add.
14860 (handle_solib_event): Likewise.
14861 (reload_shared_libraries): Likewise.
14862 * solib.h (solib_add): Remove unused target argument.
14863
14864 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
14865
14866 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
14867 (s390_displaced_step_fixup): Cover relative branches with the
14868 default fixup handling. This fixes lack of support for some
14869 relative branch instructions.
14870
14871 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14872
14873 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
14874 ptid from regcache.
14875
14876 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14877
14878 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
14879 i386_darwin_store_inferior_registers): Use ptid from regcache.
14880
14881 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14882
14883 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
14884 i386bsd_store_inferior_registers): Use ptid from regcache.
14885
14886 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14887
14888 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
14889 hppaobsd_store_registers): Use ptid from regcache.
14890
14891 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14892
14893 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
14894 hppanbsd_store_registers): Use ptid from regcache.
14895
14896 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14897
14898 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
14899 from regcache. Use get_ptrace_pid.
14900
14901 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14902
14903 * corelow.c (get_core_register_section): Use ptid from regcache,
14904 update doc.
14905
14906 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14907
14908 * bsd-uthread.c (bsd_uthread_fetch_registers,
14909 bsd_uthread_store_registers): Use ptid from regcache, set and
14910 restore inferior_ptid.
14911
14912 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14913
14914 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
14915 fetch_fp_regs, store_register, store_regs, store_fp_register,
14916 store_fp_regs): Use ptid from regcache.
14917
14918 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
14919
14920 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
14921 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
14922 store_vfp_regs): Use ptid from regcache.
14923
14924 2017-03-17 Pedro Alves <palves@redhat.com>
14925
14926 PR remote/21188
14927 * ser-base.c (ser_base_wait_for): Add comment.
14928 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
14929 version.
14930 * ser-unix.c (hardwire_raw): Remove reference to
14931 scb->current_timeout.
14932 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
14933 (hardwire_ops): Install ser_base_readchar instead of
14934 hardwire_readchar.
14935 * serial.h (struct serial) <current_timeout, timeout_remaining>:
14936 Remove fields.
14937
14938 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
14939
14940 PR gdb/19637
14941 * python/lib/gdb/printer/bound_registers.py: Add support for
14942 Python 3.
14943
14944 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
14945
14946 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
14947 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
14948 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
14949 byte_offset to subobj_byte_offset. Fix the handling of
14950 DWARF_VALUE_STACK on big-endian targets when coming via an
14951 implicit pointer.
14952 (dwarf2_evaluate_loc_desc): Adjust call to
14953 dwarf2_evaluate_loc_desc_full.
14954 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
14955 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
14956
14957 2017-03-16 Yao Qi <yao.qi@linaro.org>
14958
14959 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
14960 and REVSH instructions.
14961
14962 2017-03-16 Yao Qi <yao.qi@linaro.org>
14963
14964 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
14965 (arm_record_test): Declare.
14966 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
14967 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
14968 align with the manual.
14969 (thumb_record_misc): Adjust the code order to align with the
14970 manual.
14971 (thumb2_record_decode_insn_handler): Fix instruction matching.
14972 (instruction_reader_thumb): New class.
14973 (arm_record_test): New function.
14974
14975 2017-03-16 Yao Qi <yao.qi@linaro.org>
14976
14977 * arm-tdep.c (abstract_memory_reader): New class.
14978 (instruction_reader): New class.
14979 (extract_arm_insn): Add argument 'reader'. Callers updated.
14980 (decode_insn): Likewise.
14981
14982 2017-03-16 Doug Evans <dje@google.com>
14983
14984 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
14985 member. Change type of TYPE member to SCM. All uses updated.
14986 (lsscm_make_lazy_string_smob): Add assert.
14987 (lsscm_make_lazy_string): Flag bad length values.
14988 (lsscm_elt_type): New function.
14989 (gdbscm_lazy_string_to_value): Rewrite to use
14990 lsscm_safe_lazy_string_to_value.
14991 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
14992 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
14993 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
14994 in incoming type.
14995 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
14996 * guile/scm-type.c (tyscm_scm_to_type): New function.
14997
14998 2017-03-15 Doug Evans <dje@google.com>
14999
15000 PR python/17728, python/18439, python/18779
15001 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
15002 member. Change type of TYPE member to PyObject *. All uses updated.
15003 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
15004 (gdbpy_create_lazy_string_object): Flag bad length values.
15005 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
15006 Handle typedefs in incoming type.
15007 (stpy_lazy_string_elt_type): New function.
15008 (gdbpy_extract_lazy_string): Call it.
15009 * python/py-value.c (valpy_lazy_string): Flag bad length values.
15010 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
15011 typedefs in incoming type.
15012
15013 2017-03-16 Doug Evans <dje@google.com>
15014
15015 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
15016 * guile/scm-type.c (tyscm_scm_to_type): New function.
15017
15018 2017-03-16 Jiong Wang <jiong.wang@arm.com>
15019
15020 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
15021 "ULONGEST" for "skip".
15022
15023 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15024
15025 PR gdb/21220
15026 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
15027 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
15028 (inf_ptrace_peek_poke): ...here. New function. Now also loop
15029 over ptrace peek/poke until end of buffer or error.
15030
15031 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
15032
15033 * parse.c (length_of_subexp): Make static.
15034 * parser-defs.h (length_of_subexp): Remove.
15035
15036 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
15037
15038 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
15039 as well.
15040
15041 2017-03-14 Pedro Alves <palves@redhat.com>
15042
15043 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
15044 (main): Use std::unique_ptr. Remove calls to
15045 cp_demangled_name_parse_free.
15046
15047 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15048
15049 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
15050 alphabsd_store_inferior_registers): Use regcache->ptid instead
15051 of inferior_ptid.
15052
15053 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15054
15055 * aix-thread.c (aix_thread_fetch_registers,
15056 aix_thread_store_registers): Use regcache->ptid instead of
15057 inferior_ptid.
15058
15059 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15060
15061 * aarch64-linux-nat.c (fetch_gregs_from_thread,
15062 store_gregs_to_thread, fetch_fpregs_from_thread,
15063 store_fpregs_to_thread): Use regcache->ptid instead of
15064 inferior_ptid.
15065
15066 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15067
15068 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
15069 amd64_linux_fetch_inferior_registers): Use regcache->ptid
15070 instead of inferior_ptid.
15071
15072 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15073
15074 * target.c (target_fetch_registers, target_store_registers): Add
15075 assert.
15076
15077 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
15078
15079 * regcache.h (regcache_get_ptid): New function.
15080 * regcache.c (regcache_get_ptid): New function.
15081
15082 2017-03-13 Mark Wielaard <mark@klomp.org>
15083
15084 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
15085
15086 2017-03-10 Keith Seitz <keiths@redhat.com>
15087
15088 PR c++/8218
15089 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
15090
15091 2017-03-08 Pedro Alves <palves@redhat.com>
15092
15093 PR gdb/18360
15094 * infrun.c (start_step_over, do_target_resume, resume)
15095 (restart_threads): Assert we're not resuming a thread that is
15096 meant to be stopped.
15097 (infrun_thread_stop_requested_callback): Delete.
15098 (infrun_thread_stop_requested): If the thread is internally
15099 stopped, queue a pending stop event and clear the thread's
15100 inline-frame state.
15101 (handle_stop_requested): New function.
15102 (handle_syscall_event, handle_inferior_event_1): Use
15103 handle_stop_requested.
15104 (handle_stop_requested): New function.
15105 (handle_signal_stop): Set the thread's stop_signal here instead of
15106 at caller.
15107 (finish_step_over): Clear step over info unconditionally.
15108 (handle_signal_stop): If the user had interrupted the event
15109 thread, consider the stop a random signal.
15110 (handle_signal_stop) <signal arrived while stepping over
15111 breakpoint>: Don't restart threads here.
15112 (stop_waiting): Don't clear step-over info here.
15113
15114 2017-03-08 Pedro Alves <palves@redhat.com>
15115
15116 PR 21206
15117 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
15118 goes to argument 2, not 1.
15119
15120 2017-03-08 Pedro Alves <palves@redhat.com>
15121
15122 PR cli/21218
15123 * top.c (gdb_readline_wrapper): Avoid passing NULL to
15124 display_gdb_prompt.
15125 (command_line_input): Add comment.
15126
15127 2017-03-08 Pedro Alves <palves@redhat.com>
15128
15129 PR tui/21216
15130 * tui/tui-file.c (tui_file::write): New.
15131 * tui/tui-file.h (tui_file): Override "write".
15132 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
15133 factored out from ...
15134 (tui_puts): ... here.
15135 (tui_putc): Use them.
15136 (tui_write): New function.
15137 * tui/tui-io.h (tui_write): Declare.
15138
15139 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
15140
15141 * Makefile.in (SFILES): Replace "environ.c" with
15142 "common/environ.c".
15143 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
15144 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
15145 to...
15146 * common/environ.c: ... here.
15147 * environ.h: Moved to...
15148 * common/environ.h: ... here.
15149
15150 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15151
15152 * gdbarch.sh (pstring_ptr): New static function.
15153 (gdbarch_disassembler_options): Use it.
15154 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
15155 not valid_disassembler_option->name.
15156 * gdbarch.c: Regenerate.
15157
15158 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
15159
15160 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
15161
15162 2017-03-07 Pedro Alves <palves@redhat.com>
15163
15164 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
15165
15166 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
15167
15168 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
15169 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
15170 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
15171 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
15172
15173 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
15174
15175 * xtensa-linux-nat.c (fetch_gregs): Remove const.
15176
15177 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
15178
15179 * remote.c (remote_add_target_side_commands): Use range-based
15180 for loop.
15181
15182 2017-03-03 Yao Qi <yao.qi@linaro.org>
15183
15184 PR gdb/21165
15185 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
15186 value is lazy.
15187 * valprint.c (common_val_print): Likewise.
15188
15189 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
15190
15191 * NEWS: Mention new set/show disassembler-options commands.
15192 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
15193 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
15194 (prospective_options): New static variable.
15195 (gdb_disassembler::gdb_disassembler): Initialize
15196 m_di.disassembler_options.
15197 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
15198 (get_disassembler_options): New function.
15199 (set_disassembler_options): Likewise.
15200 (set_disassembler_options_sfunc): Likewise.
15201 (show_disassembler_options_sfunc): Likewise.
15202 (disassembler_options_completer): Likewise.
15203 (_initialize_disasm): Likewise.
15204 * disasm.h (get_disassembler_options): New prototype.
15205 (set_disassembler_options): Likewise.
15206 * gdbarch.sh (gdbarch_disassembler_options): New variable.
15207 (gdbarch_verify_disassembler_options): Likewise.
15208 * gdbarch.c: Regenerate.
15209 * gdbarch.h: Likewise.
15210 * arm-tdep.c (num_disassembly_options): Delete.
15211 (set_disassembly_style): Likewise.
15212 (arm_disassembler_options): New static variable.
15213 (set_disassembly_style_sfunc): Convert short style name into long
15214 option name. Call set_disassembler_options.
15215 (show_disassembly_style_sfunc): New function.
15216 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
15217 set_gdbarch_verify_disassembler_options.
15218 (_initialize_arm_tdep): Delete regnames variable and update callers.
15219 (arm_disassembler_options): Initialize.
15220 (disasm_options): New variable.
15221 (num_disassembly_options): Rename from this...
15222 (num_disassembly_styles): ...to this. Compute by scanning through
15223 disasm_options.
15224 (valid_disassembly_styles): Initialize using disasm_options.
15225 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
15226 set_arm_regname_option.
15227 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
15228 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
15229 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
15230 set_gdbarch_verify_disassembler_options.
15231 * s390-tdep.c (s390_disassembler_options): New static variable.
15232 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
15233 set_gdbarch_verify_disassembler_options.
15234
15235 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15236
15237 * remote.c (remote_add_target_side_condition): Remove "struct"
15238 keyword from range-based for loop.
15239
15240 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
15241
15242 * remote.c (remote_add_target_side_condition): Use range-based
15243 for loop. Update comment.
15244
15245 2017-02-27 Yao Qi <yao.qi@linaro.org>
15246
15247 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
15248
15249 2017-02-26 Alan Hayward <alan.hayward@arm.com>
15250
15251 * regcache.c (regcache_raw_update): New function.
15252 (regcache_raw_read): Move code to regcache_raw_update.
15253 * regcache.h (regcache_raw_update): New declaration.
15254 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
15255
15256 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
15257
15258 * dwarf2read.c (create_debug_type_hash_table): Initialize
15259 header.signature and header.type_offset_in_tu.
15260
15261 2017-02-24 Pedro Alves <palves@redhat.com>
15262
15263 * symtab.c (make_file_symbol_completion_list_1): Use
15264 add_symtab_completions.
15265
15266 2017-02-24 Alan Hayward <alan.hayward@arm.com>
15267
15268 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
15269
15270 2017-02-24 Alan Hayward <alan.hayward@arm.com>
15271
15272 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
15273 I386_MAX_REGISTER_SIZE.
15274 (i386_pseudo_register_write): Likewise.
15275 (i386_process_record): Likewise.
15276 * i387-tdep.c (i387_supply_xsave): Likewise.
15277 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
15278 (store_register): Likewise.
15279
15280 2017-02-23 Pedro Alves <palves@redhat.com>
15281
15282 * ada-lang.c: Include "common/function-view.h".
15283 (ada_iterate_over_symbols): Adjust to use function_view as
15284 callback type.
15285 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
15286 (ada_make_symbol_completion_list): Use a lambda.
15287 (ada_exc_search_name_matches): Delete.
15288 (name_matches_regex): New.
15289 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
15290 * compile/compile-c-support.c: Include "common/function-view.h".
15291 (print_one_macro): Change prototype to accept a ui_file pointer.
15292 (write_macro_definitions): Use a lambda.
15293 * dwarf2read.c: Include "common/function-view.h".
15294 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
15295 (dw2_expand_symtabs_matching): Adjust to use function_view as
15296 callback type.
15297 * language.h: Include "common/function-view.h".
15298 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
15299 function_view as callback type.
15300 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
15301 * linespec.c: Include "common/function-view.h".
15302 (collect_info::add_symbol): New method.
15303 (struct symbol_and_data_callback, iterate_inline_only, struct
15304 symbol_matcher_data, iterate_name_matcher): Delete.
15305 (iterate_over_all_matching_symtabs): Adjust to use function_view
15306 as callback type and lambdas.
15307 (iterate_over_file_blocks): Adjust to use function_view as
15308 callback type.
15309 (decode_compound_collector): Now a class with private fields.
15310 (decode_compound_collector::release_symbols): New method.
15311 (collect_one_symbol): Rename to...
15312 (decode_compound_collector::operator()): ... this and adjust.
15313 (lookup_prefix_sym): decode_compound_collector construction bits
15314 move to decode_compound_collector ctor. Pass the
15315 decode_compound_collector object directly as callback. Remove
15316 cleanups and use decode_compound_collector::release_symbols
15317 instead.
15318 (symtab_collector): Now a class with private fields.
15319 (symtab_collector::release_symtabs): New method.
15320 (add_symtabs_to_list): Rename to...
15321 (symtab_collector::operator()): ... this and adjust.
15322 (collect_symtabs_from_filename): symtab_collector construction
15323 bits move to symtab_collector ctor. Pass the symtab_collector
15324 object directly as callback. Remove cleanups and use
15325 symtab_collector::release_symtabs instead.
15326 (collect_symbols): Delete.
15327 (add_matching_symbols_to_info): Use lambdas.
15328 * macrocmd.c (print_macro_callback): Delete.
15329 (info_macro_command): Use a lambda.
15330 (info_macros_command): Pass print_macro_definition as callable
15331 directly.
15332 (print_one_macro): Remove 'ignore' parameter.
15333 (macro_list_command): Adjust.
15334 * macrotab.c (macro_for_each_data::fn): Now a function_view.
15335 (macro_for_each_data::user_data): Delete field.
15336 (foreach_macro): Adjust to call the function_view.
15337 (macro_for_each): Adjust to use function_view as callback type.
15338 (foreach_macro_in_scope): Adjust to call the function_view.
15339 (macro_for_each_in_scope): Adjust to use function_view as callback
15340 type.
15341 * macrotab.h: Include "common/function-view.h".
15342 (macro_callback_fn): Declare a prototype instead of a pointer.
15343 Remove "user_data" parameter.
15344 (macro_for_each, macro_for_each_in_scope): Adjust to use
15345 function_view as callback type.
15346 * psymtab.c (partial_map_expand_apply)
15347 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
15348 Adjust to use function_view as callback type and to return bool.
15349 (psym_expand_symtabs_matching): Adjust to use function_view as
15350 callback types.
15351 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
15352 to use function_view as callback type and to return bool.
15353 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
15354 callback types.
15355 * symfile.c (expand_symtabs_matching): Adjust to use function_view
15356 as callback types.
15357 * symfile.h: Include "common/function-view.h".
15358 (expand_symtabs_file_matcher_ftype)
15359 (expand_symtabs_symbol_matcher_ftype)
15360 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
15361 return bool.
15362 (quick_symbol_functions::map_symtabs_matching_filename)
15363 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
15364 function_view as callback type and return bool.
15365 (expand_symtabs_matching): Adjust to use function_view as callback
15366 type.
15367 (maintenance_expand_name_matcher)
15368 (maintenance_expand_file_matcher): Delete.
15369 (maintenance_expand_symtabs): Use lambdas.
15370 * symtab.c (iterate_over_some_symtabs): Adjust to use
15371 function_view as callback types and return bool.
15372 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
15373 of a cleanup.
15374 (lookup_symtab_callback): Delete.
15375 (lookup_symtab): Use a lambda.
15376 (iterate_over_symbols): Adjust to use function_view as callback
15377 type.
15378 (struct search_symbols_data, search_symbols_file_matches)
15379 (search_symbols_name_matches): Delete.
15380 (search_symbols): Use a pair of lambdas.
15381 (struct add_name_data, add_macro_name, symbol_completion_matcher)
15382 (symtab_expansion_callback): Delete.
15383 (default_make_symbol_completion_list_break_on_1): Use lambdas.
15384 * symtab.h: Include "common/function-view.h".
15385 (iterate_over_some_symtabs): Adjust to use function_view as
15386 callback type and return bool.
15387 (iterate_over_symtabs): Adjust to use function_view as callback
15388 type.
15389 (symbol_found_callback_ftype): Remove 'data' parameter and return
15390 bool.
15391 (iterate_over_symbols): Adjust to use function_view as callback
15392 type.
15393
15394 2017-02-23 Pedro Alves <palves@redhat.com>
15395
15396 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
15397 (%.o) <unittests/%.c>: New pattern.
15398 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
15399 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
15400 * common/function-view.h: New file.
15401 * unittests/function-view-selftests.c: New file.
15402 * configure: Regenerate.
15403
15404 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
15405
15406 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
15407 inferior_ptid.
15408 * go32-nat.c (go32_thread_alive): Likewise.
15409
15410 2017-02-23 Yao Qi <yao.qi@linaro.org>
15411
15412 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
15413 delete.
15414
15415 2017-02-23 Yao Qi <yao.qi@linaro.org>
15416
15417 * varobj.c (varobj_clear_saved_item): Use delete instead of
15418 xfree.
15419 (update_dynamic_varobj_children): Likewise.
15420
15421 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15422
15423 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
15424
15425 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
15426
15427 * common/enum-flags.h (enum_flags::enum_flags): Initialize
15428 m_enum_value to 0 in default constructor.
15429
15430 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
15431
15432 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
15433 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
15434 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
15435 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
15436 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
15437 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
15438 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
15439 IS_STORE_CONDITIONAL_INSN.
15440
15441 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
15442
15443 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
15444
15445 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15446
15447 * NEWS (Changes since GDB 7.12): Add DWARF-5.
15448
15449 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15450
15451 * dwarf2read.c (skip_one_die, read_attribute_value)
15452 (dwarf2_const_value_attr, dump_die_shallow)
15453 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
15454 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
15455
15456 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15457
15458 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
15459 (dwarf_parse_macro_header): Accept DWARF version 5.
15460 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
15461
15462 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15463
15464 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
15465 DW_AT_GNU_*.
15466 * common/common-exceptions.h (enum errors): Likewise.
15467 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
15468 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
15469 (dwarf_expr_context::execute_stack_op): Likewise.
15470 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
15471 Likewise.
15472 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
15473 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
15474 (show_entry_values_debug, call_site_to_target_addr)
15475 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
15476 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
15477 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
15478 (value_of_dwarf_block_entry, indirect_pieced_value)
15479 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
15480 (disassemble_dwarf_expression): Likewise.
15481 * dwarf2read.c (process_die, inherit_abstract_dies)
15482 (read_call_site_scope): Likewise.
15483 * gdbtypes.h (struct func_type, struct call_site_parameter)
15484 (struct call_site): Likewise.
15485 * stack.c (read_frame_arg): Likewise.
15486 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
15487
15488 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15489
15490 * defs.h (read_unsigned_leb128): New declaration.
15491 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
15492 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
15493 (dwarf2_find_location_expression): Call also
15494 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
15495 * dwarf2loc.h (dwarf2_version): New declaration.
15496 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
15497 rnglists.
15498 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
15499 .debug_rnglists.
15500 (struct dwop_section_names): Add loclists_dwo.
15501 (dwop_section_names): Add .debug_loclists.dwo.
15502 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
15503 (struct dwarf2_per_cu_data): Add dwarf_version.
15504 (struct dwo_sections): Add loclists.
15505 (struct attr_abbrev): Add implicit_const.
15506 (read_indirect_line_string): New declaration.
15507 (read_unsigned_leb128): Delete declaration.
15508 (rcuh_kind): New definition.
15509 (read_and_check_comp_unit_head): Change parameter
15510 is_debug_types_section to section_kind.
15511 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
15512 (read_comp_unit_head): Change parameter abfd to section, add parameter
15513 section_kind. Handle DWARF-5.
15514 (error_check_comp_unit_head): Accept also DWARF version 5.
15515 (read_and_check_comp_unit_head): Change parameter
15516 is_debug_types_section to section_kind.
15517 (read_and_check_type_unit_head): Delete function.
15518 (read_abbrev_offset): Handle DWARF-5.
15519 (create_debug_type_hash_table): Add parameter section_kind. Process
15520 only DW_UT_type. Use signature and type_offset_in_tu from struct
15521 comp_unit_head.
15522 (create_debug_types_hash_table): Update create_debug_type_hash_table
15523 caller.
15524 (create_all_type_units): Call create_debug_type_hash_table.
15525 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
15526 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
15527 caller.
15528 (skip_one_die): Handle DW_FORM_implicit_const.
15529 (dwarf2_rnglists_process): New function.
15530 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
15531 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
15532 (read_attribute_value): Handle DW_FORM_implicit_const,
15533 DW_FORM_line_strp.
15534 (read_attribute): Handle DW_FORM_implicit_const.
15535 (read_indirect_string_at_offset_from): New function from
15536 read_indirect_string_at_offset.
15537 (read_indirect_string_at_offset): Call
15538 read_indirect_string_at_offset_from.
15539 (read_indirect_line_string_at_offset): New function.
15540 (read_indirect_string): New function comment.
15541 (read_indirect_line_string): New function.
15542 (read_unsigned_leb128): Make it global.
15543 (dwarf2_string_attr): Handle DWARF-5.
15544 (add_include_dir_stub, read_formatted_entries): New functions.
15545 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
15546 Handle DWARF-5.
15547 (per_cu_header_read_in): Update read_comp_unit_head caller.
15548 (dwarf2_version): New function.
15549 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
15550 rnglists.
15551 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
15552 fields.
15553
15554 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15555
15556 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
15557
15558 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15559
15560 * dwarf2read.c (dwarf2_ranges_process): New function from
15561 dwarf2_ranges_read.
15562 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
15563 dwarf2_ranges_process.
15564
15565 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
15566
15567 * dwarf2read.c (create_debug_type_hash_table): New function from
15568 create_debug_types_hash_table.
15569 (create_debug_types_hash_table): Call create_debug_type_hash_table.
15570 (create_all_type_units, open_and_init_dwo_file): Update
15571 create_debug_types_hash_table callers.
15572
15573 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15574
15575 PR gdb/16188
15576 * fork-child.c (trace_start_error): Fix thinko. va_end should
15577 refer to 'ap', not 'args'.
15578
15579 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
15580 Pedro Alves <palves@redhat.com>
15581
15582 PR gdb/16188
15583 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
15584 calls succeeded.
15585 * fork-child.c (trace_start_error): New function.
15586 (trace_start_error_with_name): Likewise.
15587 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
15588 * inf-ptrace.c (inf_ptrace_me): Likewise.
15589 * inferior.h (trace_start_error): New prototype.
15590 (trace_start_error_with_name): Likewise.
15591
15592 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
15593
15594 PR gdb/21164
15595 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
15596 NULL before using it.
15597 * symmisc.c (maintenance_print_symbols): Likewise.
15598 (maintenance_print_msymbols): Likewise.
15599
15600 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15601
15602 * NEWS: Add record Python bindings entry.
15603
15604 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15605
15606 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
15607 py-record-full.o.
15608 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
15609 * python/py-record-btrace.c, python/py-record-btrace.h,
15610 python/py-record-full.c, python/py-record-full.h: New file.
15611 * python/py-record.c: Add include for py-record-btrace.h and
15612 py-record-full.h.
15613 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
15614 recpy_instruction_history, recpy_function_call_history, recpy_begin,
15615 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
15616 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
15617 New definition.
15618 (gdbpy_initialize_btrace): New export.
15619 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
15620
15621 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15622
15623 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
15624 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
15625 * python/py-record.c: New file.
15626 * python/python-internal.h (gdbpy_start_recording,
15627 gdbpy_current_recording, gdpy_stop_recording,
15628 gdbpy_initialize_record): New export.
15629 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
15630 (python_GdbMethods): Add gdbpy_start_recording,
15631 gdbpy_current_recording and gdbpy_stop_recording.
15632
15633 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15634
15635 * record-btrace.c (record_btrace_record_method): New function.
15636 (init_record_btrace_ops): Initialize to_record_method.
15637 * record-full.c (record_full_record_method): New function.
15638 (init_record_full_ops, init_record_full_core_ops): Add
15639 record_full_record_method.
15640 * record.h (enum record_method): New enum.
15641 * target-debug.h (target_debug_print_enum_record_method: New define.
15642 * target-delegates.c: Regenerate.
15643 * target.c (target_record_method): New function.
15644 * target.h: Include record.h.
15645 (struct target_ops) <to_record_method>: New field.
15646 (target_record_method): New export.
15647
15648 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15649
15650 * record.h (record_start, record_stop): New export.
15651 * record.c (record_start, record_stop): New function.
15652
15653 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15654
15655 * btrace.c (btrace_fetch): Copy function call segments pointer
15656 into a vector.
15657 (btrace_clear): Clear the vector.
15658 (btrace_find_insn_by_number): Use binary search to find the correct
15659 function call segment.
15660 * btrace.h (brace_fun_p): New typedef.
15661 (struct btrace_thread_info) <functions>: New field.
15662
15663 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15664
15665 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
15666 * btrace.c (btrace_decode_error): ... here. New function.
15667 * btrace.h (btrace_decode_error): New export.
15668
15669 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
15670
15671 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
15672 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
15673 btrace_find_insn_by_number): Remove special case for gaps.
15674 * btrace.h (btrace_insn_get_error): New export.
15675 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
15676 * record-btrace.c (btrace_insn_history): Print number for gaps.
15677 (record_btrace_info, record_btrace_goto): Handle gaps.
15678
15679 2017-02-14 Tom Tromey <tom@tromey.com>
15680
15681 PR python/13598:
15682 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
15683 event.
15684 * python/py-evts.c (gdbpy_initialize_py_events): Add
15685 before_prompt registry.
15686 * python/py-events.h (events_object) <before_prompt>: New field.
15687
15688 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
15689
15690 * btrace.c (ftrace_new_switch): Preserve up link and flags.
15691
15692 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
15693
15694 * symfile (_initialize_symfile): Add usage text to the load command's
15695 help text.
15696
15697 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
15698
15699 * utils.c (defaulted_query): Don't query on secondary UIs.
15700
15701 2017-02-10 Tom Tromey <tom@tromey.com>
15702
15703 * rust-lang.c (rust_get_disr_info): Remove unused variable.
15704
15705 2017-02-10 Tom Tromey <tom@tromey.com>
15706
15707 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
15708 "cleanup" local.
15709 * python/py-type.c (typy_legacy_template_argument): Remove
15710 unnecessary "cleanup" local.
15711
15712 2017-02-10 Tom Tromey <tom@tromey.com>
15713
15714 * python/python.c (do_start_initialization): New function, from
15715 _initialize_python.
15716 (_initialize_python): Call do_start_initialization.
15717 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
15718 goto.
15719
15720 2017-02-10 Tom Tromey <tom@tromey.com>
15721
15722 * python/py-prettyprint.c (pretty_print_one_value): Use
15723 gdbpy_ref.
15724
15725 2017-02-10 Tom Tromey <tom@tromey.com>
15726
15727 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
15728 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
15729 gdbpy_ref.
15730 * python/py-type.c (field_new): Use gdbpy_ref.
15731 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
15732 gdbpy_ref.
15733 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
15734 (py_free_pspace): Likewise.
15735 (pspace_to_pspace_object): Likewise.
15736 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
15737 (py_free_objfile): Likewise.
15738 (objfile_to_objfile_object): Likewise.
15739 * python/py-inferior.c (delete_thread_object): Use
15740 gdbpy_ref.
15741 (infpy_read_memory): Likewise.
15742 (py_free_inferior): Likewise.
15743 * python/py-evtregistry.c (create_eventregistry_object): Use
15744 gdbpy_ref.
15745 * python/py-event.c (create_event_object): Use gdbpy_ref.
15746
15747 2017-02-10 Tom Tromey <tom@tromey.com>
15748
15749 * python/py-ref.h (gdbpy_ref_policy): Now a template.
15750 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
15751 used.
15752 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
15753 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
15754 python/py-exitedevent.c, python/py-finishbreakpoint.c,
15755 python/py-framefilter.c, python/py-function.c,
15756 python/py-inferior.c, python/py-infevents.c,
15757 python/py-linetable.c, python/py-newobjfileevent.c,
15758 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
15759 python/py-signalevent.c, python/py-stopevent.c,
15760 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
15761 python/py-unwind.c, python/py-utils.c, python/py-value.c,
15762 python/py-varobj.c, python/py-xmethods.c, python/python.c,
15763 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
15764
15765 2017-02-10 Tom Tromey <tom@tromey.com>
15766
15767 * ui-out.h (ui_out_emit_type): New class.
15768 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
15769 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
15770 and ui_out_emit_tuple.
15771 (enumerate_locals): Likewise.
15772 (py_mi_print_variables, py_print_locals, py_print_args): Use
15773 ui_out_emit_list.
15774 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
15775 ui_out_emit_list.
15776 * common/gdb_optional.h: New file.
15777
15778 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
15779
15780 * MAINTAINERS (Write After Approval): Update my e-mail address.
15781
15782 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
15783
15784 PR gdb/21122
15785 * breakpoint.c (_initialize_breakpoint): Update the help description
15786 of the 'commands' command to indicate that it takes a list argument.
15787
15788 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
15789
15790 * interps.c (current_interp_set_logging): Remove "return".
15791
15792 2017-02-09 Gary Benson <gbenson@redhat.com>
15793
15794 * symtab.c (add_symtab_completions): Prevent NULL pointer
15795 dereference.
15796
15797 2017-02-08 Pedro Alves <palves@redhat.com>
15798
15799 * interps.c (interp::interp): Remove reference to quiet_p.
15800 (interp_set): Make static. Remove dead "Switching to" output
15801 code.
15802 (interp_quiet_p, interp_set_quiet): Delete.
15803 (interpreter_exec_cmd): Don't set the interpreter quiet.
15804 * interps.h (interp_quiet_p): Make static.
15805 (class interp) <quiet_p>: Remove field
15806
15807 2017-02-08 Jerome Guitton <guitton@adacore.com>
15808
15809 * cli/cli-decode.c (find_command_name_length): Make it extern.
15810 * cli/cli-decode.h (find_command_name_length): Declare.
15811 * cli/cli-script.c (command_name_equals, line_first_arg):
15812 New functions.
15813 (process_next_line): Use cli-decode to parse command names.
15814 (build_command_line): Make args a constant pointer.
15815
15816 2017-02-08 Jerome Guitton <guitton@adacore.com>
15817
15818 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
15819 Remove case-insensitive search.
15820
15821 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
15822
15823 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
15824 at the end of the line. Avoids an ARI warning.
15825
15826 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
15827
15828 * NEWS: Mention support for record/replay of Intel 64 rdrand and
15829 rdseed instructions.
15830 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
15831
15832 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
15833
15834 PR tdep/20936
15835 Provide and use sparc32 and sparc64 target description XML files.
15836 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
15837 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
15838 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
15839 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
15840 * features/sparc/sparc32-solaris.xml: New file.
15841 * features/sparc/sparc64-solaris.xml: New file.
15842 * features/sparc/sparc32-solaris.c: Generated.
15843 * features/sparc/sparc64-solaris.c: Generated.
15844 * sparc-tdep.h: Account for differences in target descriptions.
15845 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
15846 (sparc32_register_type): Use target provided registers.
15847 (validate_tdesc_registers): New function.
15848 (sparc32_gdbarch_init): Use tdesc_has_registers.
15849 Set pseudoregister functions.
15850 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
15851 (sparc64_register_type): Use target provided registers.
15852 (sparc64_init_abi): Set pseudoregister functions.
15853
15854 2017-02-03 Tom Tromey <tom@tromey.com>
15855
15856 PR rust/21097:
15857 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
15858 with a single member.
15859
15860 2017-02-03 Pedro Alves <palves@redhat.com>
15861
15862 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
15863 (cli_interp_base::~cli_interp_base): New.
15864 (cli_interp): New struct.
15865 (as_cli_interp): Cast the interp itself to cli_interp.
15866 (cli_interpreter_pre_command_loop): Rename to ...
15867 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
15868 parameter.
15869 (cli_interpreter_init): Rename to ...
15870 (cli_interp::init): ... this. Remove 'self' parameter. Use
15871 boolean. Make extern.
15872 (cli_interpreter_resume): Rename to ...
15873 (cli_interp::resume): ... this. Remove 'data' parameter. Make
15874 extern.
15875 (cli_interpreter_suspend): Rename to ...
15876 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
15877 extern.
15878 (cli_interpreter_exec): Rename to ...
15879 (cli_interp::exec): ... this. Remove 'data' parameter. Make
15880 extern.
15881 (cli_interpreter_supports_command_editing): Rename to ...
15882 (cli_interp_base::supports_command_editing): ... this. Remove
15883 'interp' parameter. Make extern.
15884 (cli_ui_out): Rename to ...
15885 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
15886 Make extern.
15887 (cli_set_logging): Rename to ...
15888 (cli_interp_base::set_logging): ... this. Remove 'interp'
15889 parameter. Make extern.
15890 (cli_interp_procs): Delete.
15891 (cli_interp_factory): Adjust to use "new".
15892 * cli/cli-interp.h: Include "interps.h".
15893 (struct cli_interp_base): New struct.
15894 * interps.c (struct interp): Delete. Fields moved to interps.h.
15895 (interp_new): Delete.
15896 (interp::interp, interp::~interp): New.
15897 (interp_set): Use bool, and return void. Assume the interpreter
15898 has suspend, init and resume methods, and that the all return
15899 void.
15900 (set_top_level_interpreter): interp_set returns void.
15901 (interp_ui_out): Adapt.
15902 (current_interp_set_logging): Adapt.
15903 (interp_data): Delete.
15904 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
15905 (interp_exec): Adapt.
15906 (top_level_interpreter_data): Delete.
15907 * interps.h (interp_init_ftype, interp_resume_ftype)
15908 (interp_suspend_ftype, interp_exec_ftype)
15909 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
15910 (class interp): New.
15911 (interp_new): Delete.
15912 (interp_set): Now returns void. Use bool.
15913 (interp_data, top_level_interpreter_data): Delete.
15914 * mi/mi-common.h: Include interps.h.
15915 (class mi_interp): Inherit from interp. Define a ctor. Declare
15916 init, resume, suspect, exec, interp_ui_out, set_logging and
15917 pre_command_loop methods.
15918 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
15919 (mi_interpreter_init): Rename to ...
15920 (mi_interp::init): ... this. Remove the 'interp' parameter, use
15921 bool, return void and make extern. Adjust.
15922 (mi_interpreter_resume): ... Rename to ...
15923 (mi_interp::resume): ... this. Remove the 'data' parameter,
15924 return void and make extern. Adjust.
15925 (mi_interpreter_suspend): ... Rename to ...
15926 (mi_interp::suspend): ... this. Remove the 'data' parameter,
15927 return void and make extern. Adjust.
15928 (mi_interpreter_exec): ... Rename to ...
15929 (mi_interp::exec): ... this. Remove the 'data' parameter and make
15930 extern. Adjust.
15931 (mi_interpreter_pre_command_loop): ... Rename to ...
15932 (mi_interp::pre_command_loop): ... this. Remove the 'self'
15933 parameter and make extern.
15934 (mi_on_normal_stop_1): Adjust.
15935 (mi_ui_out): Rename to ...
15936 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
15937 parameter and make extern. Adjust.
15938 (mi_set_logging): Rename to ...
15939 (mi_interp::set_logging): ... this. Remove the 'interp'
15940 parameter and make extern. Adjust.
15941 (mi_interp_procs): Delete.
15942 (mi_interp_factory): Adjust to use 'new'.
15943 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
15944 (mi_print_exception, mi_execute_command, mi_load_progress):
15945 Adjust.
15946 * tui/tui-interp.c (tui_interp): New class.
15947 (as_tui_interp): Return a tui_interp pointer.
15948 (tui_on_normal_stop, tui_on_signal_received)
15949 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
15950 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
15951 to use interp::interp_ui_out.
15952 (tui_init): Rename to ...
15953 (tui_interp::init): ... this. Remove the 'self' parameter, use
15954 bool, return void and make extern. Adjust.
15955 (tui_resume): Rename to ...
15956 (tui_interp::resume): ... this. Remove the 'data' parameter,
15957 return void and make extern. Adjust.
15958 (tui_suspend): Rename to ...
15959 (tui_interp::suspend): ... this. Remove the 'data' parameter,
15960 return void and make extern. Adjust.
15961 (tui_ui_out): Rename to ...
15962 (tui_interp::interp_ui_out): ... this. Remove the 'self'
15963 parameter, and make extern. Adjust.
15964 (tui_exec): Rename to ...
15965 (tui_interp::exec): ... this. Remove the 'data' parameter and
15966 make extern.
15967 (tui_interp_procs): Delete.
15968 (tui_interp_factory): Use "new".
15969
15970 2017-02-02 Tom Tromey <tom@tromey.com>
15971
15972 * rust-exp.y (ends_raw_string, space_then_number)
15973 (rust_identifier_start_p): Return bool.
15974 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
15975 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
15976 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
15977 (rust_chartype_p): Return bool.
15978 (val_print_struct, rust_print_struct_def, rust_print_type):
15979 Update.
15980 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
15981 Return bool.
15982
15983 2017-02-02 Tom Tromey <tom@tromey.com>
15984
15985 * rust-lang.c: Reindent.
15986
15987 2017-02-02 Tom Tromey <tom@tromey.com>
15988
15989 * rust-lang.h (rust_crate_for_block): Update.
15990 * rust-lang.c (rust_crate_for_block): Return std::string.
15991 (rust_get_disr_info): Use std:;string, not
15992 gdb::unique_xmalloc_ptr.
15993 * rust-exp.y (crate_name): Update.
15994
15995 2017-02-02 Pedro Alves <palves@redhat.com>
15996
15997 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
15998 field out of gdb_disassembler_test and make it static.
15999
16000 2017-02-02 Pedro Alves <palves@redhat.com>
16001
16002 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
16003 mi1_interp and mi_interp fields.
16004
16005 2017-02-02 Pedro Alves <palves@redhat.com>
16006
16007 * cli/cli-interp.c (struct saved_output_files, saved_output):
16008 Moved from cli/cli-logging.c.
16009 (cli_set_logging): New function.
16010 (cli_interp_procs): Install cli_set_logging.
16011 * cli/cli-interp.h (make_logging_output, cli_set_logging):
16012 Declare.
16013 * cli/cli-logging.c (struct saved_output_files, saved_output):
16014 Moved to cli/cli-interp.c.
16015 (pop_output_files): Don't save outputs here.
16016 (make_logging_output): New function.
16017 (handle_redirections): Don't build tee nor save previous outputs
16018 here.
16019 * interps.c (current_interp_set_logging): Change prototype.
16020 Assume there's always a set_logging_proc method installed.
16021 * interps.h (interp_set_logging_ftype): Change prototype.
16022 (current_interp_set_logging): Change prototype and adjust comment.
16023 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
16024 use make_logging_output.
16025 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
16026 2017-02-02 Pedro Alves <palves@redhat.com>
16027
16028 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
16029 from ...
16030 (set_logging_overwrite): ... here.
16031 (logging_no_redirect_file): Delete.
16032 (set_logging_redirect): Don't handle redirection on the fly.
16033 Instead warn that "logging off" / "logging on" is necessary.
16034 (pop_output_files): Delete references to logging_no_redirect_file.
16035 (show_logging_command): Always speak in terms of what will happen
16036 once logging is reenabled.
16037
16038 2017-02-02 Pedro Alves <palves@redhat.com>
16039
16040 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
16041
16042 2017-02-02 Pedro Alves <palves@redhat.com>
16043
16044 * disasm.c (gdb_pretty_print_insn): Rename to ...
16045 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
16046 Remove gdbarch parameter. Adapt to clear the object's buffers
16047 instead of allocating new buffers, and to print using the object's
16048 gdb_disassembler instead of calling gdb_print_insn.
16049 (dump_insns): Use gdb_pretty_print_disassembler.
16050 * disasm.h (gdb_pretty_print_insn): Delete declaration.
16051 (gdb_pretty_print_disassembler): New class.
16052 * record-btrace.c (btrace_insn_history): Use
16053 gdb_pretty_print_disassembler.
16054
16055 2017-02-02 Pedro Alves <palves@redhat.com>
16056
16057 * ada-lang.c (type_as_string): Use string_file.
16058 * ada-valprint.c (ada_print_floating): Use string_file.
16059 * ada-varobj.c (ada_varobj_scalar_image)
16060 (ada_varobj_get_value_image): Use string_file.
16061 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
16062 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
16063 * breakpoint.c (update_inserted_breakpoint_locations)
16064 (insert_breakpoint_locations, reattach_breakpoints)
16065 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
16066 (print_it_watchpoint): Use string_file.
16067 (save_breakpoints): Use stdio_file.
16068 * c-exp.y (oper): Use string_file.
16069 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
16070 tee_file.
16071 (pop_output_files): Use delete.
16072 (handle_redirections): Use stdio_file and tee_file.
16073 * cli/cli-setshow.c (do_show_command): Use string_file.
16074 * compile/compile-c-support.c (c_compute_program): Use
16075 string_file.
16076 * compile/compile-c-symbols.c (generate_vla_size): Take a
16077 'string_file &' instead of a 'ui_file *'.
16078 (generate_c_for_for_one_variable): Take a 'string_file &' instead
16079 of a 'ui_file *'. Use string_file.
16080 (generate_c_for_variable_locations): Take a 'string_file &'
16081 instead of a 'ui_file *'.
16082 * compile/compile-internal.h (generate_c_for_for_one_variable):
16083 Take a 'string_file &' instead of a 'ui_file *'.
16084 * compile/compile-loc2c.c (push, pushf, unary, binary)
16085 (print_label, pushf_register_address, pushf_register)
16086 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
16087 'ui_file *'. Adjust.
16088 * compile/compile.c (compile_to_object): Use string_file.
16089 * compile/compile.h (compile_dwarf_expr_to_c)
16090 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
16091 'ui_file *'.
16092 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
16093 (replace_typedefs_qualified_name): Use string_file and
16094 obstack_copy0.
16095 * disasm.c (gdb_pretty_print_insn): Use string_file.
16096 (gdb_disassembly): Adjust reference the null_stream global.
16097 (do_ui_file_delete): Delete.
16098 (gdb_insn_length): Use null_stream.
16099 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
16100 * dwarf2loc.c (dwarf2_compile_property_to_c)
16101 (locexpr_generate_c_location, loclist_generate_c_location): Take a
16102 'string_file &' instead of a 'ui_file *'.
16103 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
16104 * dwarf2read.c (do_ui_file_peek_last): Delete.
16105 (dwarf2_compute_name): Use string_file.
16106 * event-top.c (gdb_setup_readline): Use stdio_file.
16107 * gdbarch.sh (verify_gdbarch): Use string_file.
16108 * gdbtypes.c (safe_parse_type): Use null_stream.
16109 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
16110 string_file.
16111 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
16112 'string_file *' instead of a 'ui_file *'.
16113 (gdbscm_arch_disassemble): Use string_file.
16114 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
16115 * guile/scm-ports.c (class ioscm_file_port): Now a class that
16116 inherits from ui_file.
16117 (ioscm_file_port_delete, ioscm_file_port_rewind)
16118 (ioscm_file_port_put): Delete.
16119 (ioscm_file_port_write): Rename to ...
16120 (ioscm_file_port::write): ... this. Remove file_port_magic
16121 checks.
16122 (ioscm_file_port_new): Delete.
16123 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
16124 ui_file_up.
16125 * guile/scm-type.c (tyscm_type_name): Use string_file.
16126 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
16127 Use string_file.
16128 * infcmd.c (print_return_value_1): Use string_file.
16129 * infrun.c (print_target_wait_results): Use string_file.
16130 * language.c (add_language): Use string_file.
16131 * location.c (explicit_to_string_internal): Use string_file.
16132 * main.c (captured_main_1): Use null_file.
16133 * maint.c (maintenance_print_architecture): Use stdio_file.
16134 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
16135 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
16136 event_channel>: Change type to mi_console_file pointer.
16137 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
16138 (mi_console_file_delete): Delete.
16139 (struct mi_console_file): Delete.
16140 (mi_console_file_magic): Delete.
16141 (mi_console_file_new): Delete.
16142 (mi_console_file::mi_console_file): New.
16143 (mi_console_file_delete): Delete.
16144 (mi_console_file_fputs): Delete.
16145 (mi_console_file::write): New.
16146 (mi_console_raw_packet): Delete.
16147 (mi_console_file::flush): New.
16148 (mi_console_file_flush): Delete.
16149 (mi_console_set_raw): Rename to ...
16150 (mi_console_file::set_raw): ... this.
16151 * mi/mi-console.h (class mi_console_file): New class.
16152 (mi_console_file_new, mi_console_set_raw): Delete.
16153 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
16154 (mi_set_logging): Use delete and tee_file. Adjust.
16155 * mi/mi-main.c (output_register): Use string_file.
16156 (mi_cmd_data_evaluate_expression): Use string_file.
16157 (mi_cmd_data_read_memory): Use string_file.
16158 (mi_cmd_execute, print_variable_or_computed): Use string_file.
16159 * mi/mi-out.c (mi_ui_out::main_stream): New.
16160 (mi_ui_out::rewind): Use main_stream and
16161 string_file.
16162 (mi_ui_out::put): Use main_stream and string_file.
16163 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16164 Allocate a 'string_file' instead.
16165 (mi_out_new): Don't allocate a mem_fileopen stream here.
16166 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
16167 (mi_ui_out::main_stream): Declare method.
16168 * printcmd.c (eval_command): Use string_file.
16169 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
16170 * python/py-arch.c (archpy_disassemble): Use string_file.
16171 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
16172 * python/py-frame.c (frapy_str): Use string_file.
16173 * python/py-framefilter.c (py_print_type, py_print_single_arg):
16174 Use string_file.
16175 * python/py-type.c (typy_str): Use string_file.
16176 * python/py-unwind.c (unwind_infopy_str): Use string_file.
16177 * python/py-value.c (valpy_str): Use string_file.
16178 * record-btrace.c (btrace_insn_history): Use string_file.
16179 * regcache.c (regcache_print): Use stdio_file.
16180 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
16181 * remote.c (escape_buffer): Use string_file.
16182 * rust-lang.c (rust_get_disr_info): Use string_file.
16183 * serial.c (serial_open_ops_1): Use stdio_file.
16184 (do_serial_close): Use delete.
16185 * stack.c (print_frame_arg): Use string_file.
16186 (print_frame_args): Remove local mem_fileopen stream, not used.
16187 (print_frame): Use string_file.
16188 * symmisc.c (maintenance_print_symbols): Use stdio_file.
16189 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
16190 Take a 'string_file *' instead of a 'ui_file *'.
16191 * top.c (new_ui): Use stdio_file and stderr_file.
16192 (free_ui): Use delete.
16193 (execute_command_to_string): Use string_file.
16194 (quit_confirm): Use string_file.
16195 * tracepoint.c (collection_list::append_exp): Use string_file.
16196 * tui/tui-disasm.c (tui_disassemble): Use string_file.
16197 * tui/tui-file.c: Don't include "ui-file.h".
16198 (enum streamtype, struct tui_stream): Delete.
16199 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
16200 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
16201 (tui_file::tui_file): New method.
16202 (tui_file_fputs): Delete.
16203 (tui_file_get_strbuf): Delete.
16204 (tui_file::puts): New method.
16205 (tui_file_adjust_strbuf): Delete.
16206 (tui_file_flush): Delete.
16207 (tui_file::flush): New method.
16208 * tui/tui-file.h: Tweak intro comment.
16209 Include ui-file.h.
16210 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
16211 (tui_file_adjust_strbuf): Delete declarations.
16212 (class tui_file): New class.
16213 * tui/tui-io.c (tui_initialize_io): Use tui_file.
16214 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
16215 (tui_register_format): Use string_stream.
16216 * tui/tui-stack.c (tui_make_status_line): Use string_file.
16217 (tui_get_function_from_frame): Use string_file.
16218 * typeprint.c (type_to_string): Use string_file.
16219 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
16220 (null_stream): New global.
16221 (ui_file_delete): Delete.
16222 (ui_file::ui_file): New.
16223 (null_file_isatty): Delete.
16224 (ui_file::~ui_file): New.
16225 (null_file_rewind): Delete.
16226 (ui_file::printf): New.
16227 (null_file_put): Delete.
16228 (null_file_flush): Delete.
16229 (ui_file::putstr): New.
16230 (null_file_write): Delete.
16231 (ui_file::putstrn): New.
16232 (null_file_read): Delete.
16233 (ui_file::putc): New.
16234 (null_file_fputs): Delete.
16235 (null_file_write_async_safe): Delete.
16236 (ui_file::vprintf): New.
16237 (null_file_delete): Delete.
16238 (null_file::write): New.
16239 (null_file_fseek): Delete.
16240 (null_file::puts): New.
16241 (ui_file_data): Delete.
16242 (null_file::write_async_safe): New.
16243 (gdb_flush, ui_file_isatty): Adjust.
16244 (ui_file_put, ui_file_rewind): Delete.
16245 (ui_file_write): Adjust.
16246 (ui_file_write_for_put): Delete.
16247 (ui_file_write_async_safe, ui_file_read): Adjust.
16248 (ui_file_fseek): Delete.
16249 (fputs_unfiltered): Adjust.
16250 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
16251 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
16252 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
16253 (set_ui_file_data): Delete.
16254 (string_file::~string_file, string_file::write)
16255 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
16256 (do_ui_file_as_string, ui_file_as_string): Delete.
16257 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
16258 (struct mem_file): Delete.
16259 (mem_file_new): Delete.
16260 (stdio_file::stdio_file): New.
16261 (mem_file_delete): Delete.
16262 (stdio_file::stdio_file): New.
16263 (mem_fileopen): Delete.
16264 (stdio_file::~stdio_file): New.
16265 (mem_file_rewind): Delete.
16266 (stdio_file::set_stream): New.
16267 (mem_file_put): Delete.
16268 (stdio_file::open): New.
16269 (mem_file_write): Delete.
16270 (stdio_file_magic, struct stdio_file): Delete.
16271 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
16272 (stdio_file::flush): New.
16273 (stdio_file_read): Rename to ...
16274 (stdio_file::read): ... this. Adjust.
16275 (stdio_file_write): Rename to ...
16276 (stdio_file::write): ... this. Adjust.
16277 (stdio_file_write_async_safe): Rename to ...
16278 (stdio_file::write_async_safe) ... this. Adjust.
16279 (stdio_file_fputs): Rename to ...
16280 (stdio_file::puts) ... this. Adjust.
16281 (stdio_file_isatty): Delete.
16282 (stdio_file_fseek): Delete.
16283 (stdio_file::isatty): New.
16284 (stderr_file_write): Rename to ...
16285 (stderr_file::write) ... this. Adjust.
16286 (stderr_file_fputs): Rename to ...
16287 (stderr_file::puts) ... this. Adjust.
16288 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
16289 (stderr_file::stderr_file): New.
16290 (tee_file_magic): Delete.
16291 (struct tee_file): Delete.
16292 (tee_file::tee_file): New.
16293 (tee_file_new): Delete.
16294 (tee_file::~tee_file): New.
16295 (tee_file_delete): Delete.
16296 (tee_file_flush): Rename to ...
16297 (tee_file::flush): ... this. Adjust.
16298 (tee_file_write): Rename to ...
16299 (tee_file::write): ... this. Adjust.
16300 (tee_file::write_async_safe): New.
16301 (tee_file_fputs): Rename to ...
16302 (tee_file::puts): ... this. Adjust.
16303 (tee_file_isatty): Rename to ...
16304 (tee_file::isatty): ... this. Adjust.
16305 * ui-file.h (struct obstack, struct ui_file): Don't
16306 forward-declare.
16307 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
16308 (ui_file_write_ftype)
16309 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
16310 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
16311 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
16312 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
16313 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
16314 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
16315 (set_ui_file_fseek): Delete.
16316 (ui_file_data, ui_file_delete, ui_file_rewind)
16317 (struct ui_file): New.
16318 (ui_file_up): New.
16319 (class null_file): New.
16320 (null_stream): Declare.
16321 (ui_file_write_for_put, ui_file_put): Delete.
16322 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
16323 Delete.
16324 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
16325 (gdb_fopen, tee_file_new): Delete.
16326 (struct string_file): New.
16327 (struct stdio_file): New.
16328 (stdio_file_up): New.
16329 (struct stderr_file): New.
16330 (class tee_file): New.
16331 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
16332 of a 'ui_file *'. Adjust.
16333 * ui-out.h (class ui_out) <field_stream>: Likewise.
16334 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
16335 (null_stream): Delete.
16336 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
16337 Adjust.
16338 * utils.h (struct ui_file): Delete forward declaration..
16339 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
16340 (error_stream): Take a 'string_file &' instead of a
16341 'ui_file *'.
16342 * varobj.c (varobj_value_get_print_value): Use string_file.
16343 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
16344 * gdbarch.c: Regenerate.
16345
16346 2017-02-02 Pedro Alves <palves@redhat.com>
16347
16348 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
16349 (gdb_pretty_print_insn): ... this. Now a free function. Add back
16350 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
16351 Adjust to call gdb_print_insn instead of
16352 gdb_disassembler::print_insn.
16353 (dump_insns, do_mixed_source_and_assembly_deprecated)
16354 (do_mixed_source_and_assembly, do_assembly_only): Add back a
16355 'gdbarch' parameter. Remove gdb_disassembler parameter.
16356 (gdb_disassembly): Don't allocate a gdb_disassembler here.
16357 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
16358 declaration.
16359 (gdb_pretty_print_insn): Re-add declaration.
16360 * record-btrace.c (btrace_insn_history): Don't allocate a
16361 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
16362
16363 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
16364
16365 * disasm.h (gdb_disassembly): Remove file_string parameter.
16366 * disasm.c (gdb_disassembly): Likewise.
16367 * cli/cli-cmds.c (print_disassembly): Adapt.
16368 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
16369 * stack.c (do_gdb_disassembly): Likewise.
16370
16371 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
16372
16373 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
16374 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
16375 targets. And if the implicit value is longer than needed, extract
16376 the first bytes instead of the "least significant" ones.
16377
16378 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16379
16380 * btrace.c (btrace_enable): Do not call btrace_add_pc for
16381 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
16382 (btrace_fetch): Assert can_access_registers_ptid.
16383 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
16384 validate_registers_access.
16385
16386 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
16387
16388 * gdbthread.h (can_access_registers_ptid): New.
16389 * thread.c (can_access_registers_ptid): New.
16390
16391 2017-02-01 Pedro Alves <palves@redhat.com>
16392
16393 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
16394
16395 2017-01-31 Pedro Alves <palves@redhat.com>
16396
16397 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
16398 Fix typos.
16399
16400 2017-01-31 Pedro Alves <palves@redhat.com>
16401
16402 * stack.c (print_frame_args): Remove local mem_fileopen stream,
16403 not used.
16404
16405 2017-01-31 Pedro Alves <palves@redhat.com>
16406
16407 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
16408
16409 2017-01-31 Pedro Alves <palves@redhat.com>
16410
16411 * common/scoped_restore.h
16412 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
16413 change the value's parameter type to T2.
16414 (make_scoped_restore): Likewise.
16415
16416 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16417 Richard Henderson <rth@redhat.com>
16418
16419 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
16420 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
16421 GS_BASE for older kernels.
16422 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
16423 GS_BASE for older kernels.
16424 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
16425 and GS_BASE to the offset table.
16426 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
16427 system register group.
16428 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
16429 for older kernels.
16430 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
16431 amd64 ABI.
16432 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
16433 AMD64_GSBASE_REGNUM.
16434 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
16435 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
16436 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
16437 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
16438 i386/64bit-segments.xml in those rules.
16439 * features/i386/64bit-segments.xml: New file.
16440 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
16441 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
16442 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
16443 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
16444 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
16445 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
16446 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
16447 * features/i386/amd64-avx-linux.c: Regenerated.
16448 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
16449 * features/i386/amd64-avx-mpx.c: Regenerated.
16450 * features/i386/amd64-avx512-linux.c: Regenerated.
16451 * features/i386/amd64-linux.c: Regenerated.
16452 * features/i386/amd64-mpx-linux.c: Regenerated.
16453 * features/i386/i386-avx-mpx-linux.c: Regenerated.
16454 * features/i386/i386-avx-mpx.c: Regenerated.
16455 * features/i386/x32-avx-linux.c: Regenerated.
16456 * features/i386/x32-avx512-linux.c: Regenerated.
16457 * regformats/i386/amd64-avx-linux.dat: Regenerated.
16458 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
16459 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
16460 * regformats/i386/amd64-linux.dat: Regenerated.
16461 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
16462 * regformats/i386/x32-avx-linux.dat: Regenerated.
16463 * regformats/i386/x32-avx512-linux.dat: Regenerated.
16464 * regformats/i386/x32-linux.dat: Regenerated.
16465
16466 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16467
16468 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
16469 Set to AMD64_NUM_REGS.
16470
16471 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
16472
16473 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
16474 that checks validity of a register number.
16475
16476 2017-01-27 Kees Cook <keescook@google.com>
16477
16478 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
16479 fetch_fpregs if target has fpa registers.
16480 (arm_linux_store_inferior_registers): Call store_fpregs if target
16481 has fpa registers.
16482
16483 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
16484
16485 * cris-tdep.c (cris_gdbarch_init): Remove check for
16486 info.byte_order and force it to BFD_ENDIAN_LITTLE.
16487
16488 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
16489
16490 * corelow.c (get_core_register_section): Check for regset
16491 existence before checking for REGSET_VARIABLE_SIZE.
16492
16493 2017-01-26 Yao Qi <yao.qi@linaro.org>
16494 Pedro Alves <palves@redhat.com>
16495
16496 PR gdb/20939
16497 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
16498 call memory_error, save memaddr instead.
16499 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
16500 negative, cal memory_error.
16501 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
16502
16503 2017-01-26 Yao Qi <yao.qi@linaro.org>
16504
16505 * disasm-selftests.c (memory_error_test): New function.
16506 (_initialize_disasm_selftests): Register memory_error_test.
16507
16508 2017-01-26 Yao Qi <yao.qi@linaro.org>
16509
16510 * Makefile.in (SFILES): Add disasm-selftests.c and
16511 selftest-arch.c.
16512 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
16513 * disasm-selftests.c: New file.
16514 * selftest-arch.c: New file.
16515 * selftest-arch.h: New file.
16516
16517 2017-01-26 Yao Qi <yao.qi@linaro.org>
16518
16519 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
16520 to bfd_arch_mep. Don't return 0 if section is not
16521 found. Call print_insn_mep.
16522
16523 2017-01-26 Pedro Alves <palves@redhat.com>
16524 Yao Qi <yao.qi@linaro.org>
16525
16526 * arm-tdep.c: Include "disasm.h".
16527 (gdb_print_insn_arm): Update code to get gdbarch.
16528 * disasm.c (dis_asm_read_memory): Change it to
16529 gdb_disassembler::dis_asm_read_memory.
16530 (dis_asm_memory_error): Likewise.
16531 (dis_asm_print_address): Likewise.
16532 (gdb_pretty_print_insn): Change it to
16533 gdb_disassembler::pretty_print_insn.
16534 (dump_insns): Add one argument gdb_disassemlber. All
16535 callers updated.
16536 (do_mixed_source_and_assembly_deprecated): Likewise.
16537 (do_mixed_source_and_assembly): Likewise.
16538 (do_assembly_only): Likewise.
16539 (gdb_disassembler::gdb_disassembler): New.
16540 (gdb_disassembler::print_insn): New.
16541 * disasm.h (class gdb_disassembler): New.
16542 (gdb_pretty_print_insn): Remove declaration.
16543 (gdb_disassemble_info): Likewise.
16544 * guile/scm-disasm.c (class gdbscm_disassembler): New.
16545 (gdbscm_disasm_read_memory_worker): Update.
16546 (gdbscm_disasm_read_memory): Update.
16547 (gdbscm_disasm_memory_error): Remove.
16548 (gdbscm_disasm_print_address): Remove.
16549 (gdbscm_disassembler::gdbscm_disassembler): New.
16550 (gdbscm_print_insn_from_port): Update.
16551 * mips-tdep.c: Include disasm.h.
16552 (gdb_print_insn_mips): Update code to get gdbarch.
16553 * record-btrace.c (btrace_insn_history): Update.
16554 * spu-tdep.c: Include disasm.h.
16555 (struct spu_dis_asm_data): Remove.
16556 (struct spu_dis_asm_info): New.
16557 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
16558 SPU id.
16559 (gdb_print_insn_spu): Cast disassemble_info to
16560 spu_dis_asm_info.
16561
16562 2017-01-26 Yao Qi <yao.qi@linaro.org>
16563
16564 * disasm.c (do_ui_file_delete): Delete.
16565 (gdb_insn_length): Move code creating stream to ...
16566 * utils.c (null_stream): ... here. New function.
16567 * utils.h (null_stream): Declare.
16568
16569 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
16570
16571 * python/py-inferior.c (find_thread_object): Return directly
16572 from the loop. Remove "found" variable.
16573
16574 2017-01-21 Joel Brobecker <brobecker@adacore.com>
16575
16576 GDB 7.12.1 released.
16577
16578 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16579
16580 * python/py-function.c (fnpy_call): Reorder declarations to have
16581 the gdbpy_enter object declared first.
16582 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
16583
16584 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
16585
16586 PR python/21068
16587 * python/python-internal.h (PyMem_RawMalloc): Define for
16588 Python < 3.4.
16589 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
16590 PyMem_RawMalloc instead of PyMem_Malloc.
16591
16592 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
16593 Luis Machado <lgustavo@codesourcery.com>
16594
16595 * NEWS (New commands): Mention flash-erase.
16596 (New MI commands): Mention target-flash-erase.
16597 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
16598 command.
16599 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
16600 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
16601 * target.c (flash_erase_command): New function.
16602 (initialize_targets): Add new flash-erase command.
16603 * target.h (flash_erase_command): New declaration.
16604
16605 2017-01-20 Joel Brobecker <brobecker@adacore.com>
16606
16607 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
16608 HAVE_SYS_PROCFS_H is defined.
16609
16610 2017-01-18 Alan Hayward <alan.hayward@arm.com>
16611
16612 * remote.c (struct cached_reg): Change data into a pointer.
16613 * (stop_reply_dtr): Free data pointers before deleting vector.
16614 (process_stop_reply): Likewise.
16615 (remote_parse_stop_reply): Allocate space for data
16616
16617 2017-01-18 Alan Hayward <alan.hayward@arm.com>
16618
16619 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
16620 MAX_REGISTER_SIZE.
16621 (amd64_pseudo_register_read_value): Likewise.
16622 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
16623 (store_register_using_P): Likewise.
16624 * regcache.c (regcache_xfer_part): Likewise.
16625
16626 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
16627
16628 Split real and pseudo registers.
16629 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
16630 (sparc32_pseudo_regnum): New enum.
16631 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
16632 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
16633 (SPARC32_CP0_REGISTERS): New macro.
16634 (sparc32_pseudo_register_name): New function.
16635 (sparc32_register_name): Use sparc32_pseudo_register_name.
16636 (sparc32_pseudo_register_type): New function.
16637 (sparc32_register_type): Use sparc32_pseudo_register_type.
16638 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
16639 pseudo register numbers.
16640 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
16641 (SPARC64_CP0_REGISTERS): New macro.
16642 (sparc64_pseudo_register_name): New function.
16643 (sparc64_register_name): Use sparc64_pseudo_register_name.
16644 (sparc64_pseudo_register_type): New function.
16645 (sparc64_register_type): Use sparc64_pseudo_register_type.
16646 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
16647 pseudo register numbers.
16648 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
16649 sparc64_store_arguments): Handle pseudo register numbers.
16650
16651 2017-01-13 Yao Qi <yao.qi@linaro.org>
16652
16653 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
16654 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
16655 output.
16656 (getpkt_or_notif_sane_1): Likewise.
16657
16658 2017-01-13 Yao Qi <yao.qi@linaro.org>
16659
16660 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
16661 of CC. Pass "-x c++-header" instead of "-x c".
16662
16663 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16664
16665 * remote.c (remote_can_async_p): Update comment.
16666
16667 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16668
16669 * linux-nat.c (linux_nat_can_async_p): Update comment.
16670
16671 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
16672
16673 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
16674
16675 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
16676
16677 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
16678
16679 2017-01-10 Tom Tromey <tom@tromey.com>
16680
16681 * python/py-type.c (typy_legacy_template_argument): Update.
16682 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
16683 ~demangle_parse_info): Declare new members.
16684 (cp_demangled_name_to_comp): Return unique_ptr.
16685 (cp_demangled_name_parse_free)
16686 (make_cleanup_cp_demangled_name_parse_free)
16687 (cp_new_demangle_parse_info): Remove.
16688 * cp-support.c (do_demangled_name_parse_free_cleanup)
16689 (make_cleanup_cp_demangled_name_parse_free): Remove.
16690 (inspect_type, cp_canonicalize_string_full)
16691 (cp_canonicalize_string): Update.
16692 (mangled_name_to_comp): Change return type.
16693 (cp_class_name_from_physname, method_name_from_physname)
16694 (cp_func_name, cp_remove_params): Update.
16695 * cp-name-parser.y (demangle_parse_info): New constructor, from
16696 cp_new_demangle_parse_info.
16697 (~demangle_parse_info): New destructor, from
16698 cp_demangled_name_parse_free.
16699 (cp_merge_demangle_parse_infos): Update.
16700 (cp_demangled_name_to_comp): Change return type.
16701
16702 2017-01-10 Tom Tromey <tom@tromey.com>
16703
16704 * top.c (prevent_dont_repeat): Change return type.
16705 * python/python.c (execute_gdb_command): Use std::string.
16706 Update.
16707 * guile/guile.c (gdbscm_execute_gdb_command): Update.
16708 * command.h (prevent_dont_repeat): Change return type.
16709 * breakpoint.c (bpstat_do_actions_1): Update.
16710
16711 2017-01-10 Tom Tromey <tom@tromey.com>
16712
16713 * value.h (scoped_value_mark::~scoped_value_mark): Call
16714 free_to_mark.
16715 (scoped_value_mark::free_to_mark): New method.
16716 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
16717 scoped_value_mark.
16718
16719 2017-01-10 Tom Tromey <tom@tromey.com>
16720
16721 * python/py-value.c (valpy_dereference, valpy_referenced_value)
16722 (valpy_reference_value, valpy_const_value, valpy_get_address)
16723 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
16724 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
16725 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
16726 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
16727 scoped_value_mark.
16728 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
16729 * value.h (scoped_value_mark): New class.
16730
16731 2017-01-10 Tom Tromey <tom@tromey.com>
16732
16733 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
16734 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
16735 * psymtab.c (discard_psymtabs_upto): Remove.
16736 (make_cleanup_discard_psymtabs): Remove.
16737 (struct psymtab_state): Remove.
16738
16739 2017-01-10 Tom Tromey <tom@tromey.com>
16740
16741 * record-full.c (record_full_save_cleanups): Remove.
16742 (record_full_save): Use gdb::unlinker.
16743 * gcore.c (do_bfd_delete_cleanup): Remove.
16744 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
16745 cleanups.
16746 * dwarf2read.c (unlink_if_set): Remove.
16747 (write_psymtabs_to_index): Use gdb::unlinker.
16748 * common/gdb_unlinker.h: New file.
16749
16750 2017-01-10 Tom Tromey <tom@tromey.com>
16751
16752 * windows-tdep.c (windows_xfer_shared_library): Update.
16753 * windows-nat.c (windows_make_so): Update.
16754 * utils.h (make_cleanup_bfd_unref): Remove.
16755 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
16756 * symfile.h (symfile_bfd_open)
16757 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
16758 * symfile.c (read_symbols, symbol_file_add)
16759 (separate_debug_file_exists): Update.
16760 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
16761 (generic_load, reread_symbols): Update.
16762 * symfile-mem.c (symbol_file_add_from_memory): Update.
16763 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
16764 (spu_symbol_file_add_from_memory): Update.
16765 * solist.h (struct target_so_ops) <bfd_open>: Return
16766 gdb_bfd_ref_ptr.
16767 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
16768 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
16769 gdb_bfd_ref_ptr.
16770 (solib_map_sections, reload_shared_libraries_1): Update.
16771 * solib-svr4.c (enable_break): Update.
16772 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
16773 * solib-frv.c (enable_break2): Update.
16774 * solib-dsbt.c (enable_break): Update.
16775 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
16776 gdb_bfd_ref_ptr.
16777 (darwin_solib_get_all_image_info_addr_at_init): Update.
16778 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
16779 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
16780 * record-full.c (record_full_save): Update.
16781 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
16782 * procfs.c (insert_dbx_link_bpt_in_file): Update.
16783 * minidebug.c (find_separate_debug_file_in_section): Return
16784 gdb_bfd_ref_ptr.
16785 * machoread.c (macho_add_oso_symfile): Change abfd to
16786 gdb_bfd_ref_ptr.
16787 (macho_symfile_read_all_oso): Update.
16788 (macho_check_dsym): Return gdb_bfd_ref_ptr.
16789 (macho_symfile_read): Update.
16790 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
16791 (jit_bfd_try_read_symtab): Update.
16792 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16793 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16794 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16795 gdb_bfd_ref_ptr.
16796 (gdb_bfd_ref_policy): New struct.
16797 (gdb_bfd_ref_ptr): New typedef.
16798 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
16799 (gdb_bfd_openw, gdb_bfd_openr_iovec)
16800 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
16801 gdb_bfd_ref_ptr.
16802 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16803 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
16804 (gcore_command): Update.
16805 * exec.c (exec_file_attach): Update.
16806 * elfread.c (elf_symfile_read): Update.
16807 * dwarf2read.c (dwarf2_get_dwz_file): Update.
16808 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
16809 (open_and_init_dwo_file): Update.
16810 (open_dwp_file): Return gdb_bfd_ref_ptr.
16811 (open_and_init_dwp_file): Update.
16812 * corelow.c (core_open): Update.
16813 * compile/compile-object-load.c (compile_object_load): Update.
16814 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
16815 * coffread.c (coff_symfile_read): Update.
16816 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
16817 gdb_bfd_ref_ptr. Rename.
16818 (dump_bfd_file, restore_command): Update.
16819 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16820 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
16821 (find_separate_debug_file_by_buildid): Update.
16822
16823 2017-01-10 Tom Tromey <tom@tromey.com>
16824
16825 * common/gdb_ref_ptr.h: New file.
16826 * python/py-ref.h (struct gdbpy_ref_policy): New.
16827 (gdbpy_ref): Now a typedef.
16828
16829 2017-01-10 Tom Tromey <tom@tromey.com>
16830
16831 * utils.h (make_cleanup_htab_delete): Don't declare.
16832 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
16833 Remove.
16834 * linespec.c (decode_compound_collector): Add constructor,
16835 destructor.
16836 (lookup_prefix_sym): Remove cleanup.
16837 (symtab_collector): Add constructor, destructor.
16838 (collect_symtabs_from_filename): Remove cleanup.
16839 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
16840 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
16841 Use htab_up.
16842 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
16843 * dwarf2read.c (dw2_expand_symtabs_matching)
16844 (dw2_map_symbol_filenames, dwarf_decode_macros)
16845 (write_psymtabs_to_index): Use htab_up.
16846 * dwarf2loc.c (func_verify_no_selftailcall)
16847 (call_site_find_chain_1, func_verify_no_selftailcall)
16848 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
16849 std::vector, gdb::unique_xmalloc_ptr.
16850 (call_sitep): Remove typedef.
16851 (dwarf2_locexpr_baton_eval): Remove unused variable.
16852
16853 2017-01-10 Tom Tromey <tom@tromey.com>
16854
16855 * python/python-internal.h (make_cleanup_py_decref)
16856 (make_cleanup_py_xdecref): Don't declare.
16857 * python/py-utils.c (py_decref, make_cleanup_py_decref)
16858 (py_xdecref, make_cleanup_py_xdecref): Remove.
16859
16860 2017-01-10 Tom Tromey <tom@tromey.com>
16861
16862 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
16863 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
16864
16865 2017-01-10 Tom Tromey <tom@tromey.com>
16866
16867 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
16868
16869 2017-01-10 Tom Tromey <tom@tromey.com>
16870
16871 * python/py-utils.c (unicode_to_encoded_string)
16872 (python_string_to_target_string)
16873 (python_string_to_target_python_string)
16874 (python_string_to_host_string, gdbpy_obj_to_string)
16875 (get_addr_from_python): Use gdbpy_ref.
16876
16877 2017-01-10 Tom Tromey <tom@tromey.com>
16878
16879 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
16880 gdbpy_ref.
16881
16882 2017-01-10 Tom Tromey <tom@tromey.com>
16883
16884 * python/python.c (eval_python_command, gdbpy_decode_line)
16885 (gdbpy_run_events, gdbpy_start_type_printers)
16886 (gdbpy_apply_type_printers): Use gdbpy_ref.
16887
16888 2017-01-10 Tom Tromey <tom@tromey.com>
16889
16890 * python/py-param.c (get_doc_string, compute_enum_values): Use
16891 gdbpy_ref.
16892
16893 2017-01-10 Tom Tromey <tom@tromey.com>
16894
16895 * python/py-inferior.c (find_thread_object, build_inferior_list):
16896 Use gdbpy_ref.
16897
16898 2017-01-10 Tom Tromey <tom@tromey.com>
16899
16900 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16901
16902 2017-01-10 Tom Tromey <tom@tromey.com>
16903
16904 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
16905 gdbpy_ref.
16906
16907 2017-01-10 Tom Tromey <tom@tromey.com>
16908
16909 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
16910 extra incref.
16911 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
16912 Use gdbpy_ref.
16913
16914 2017-01-10 Tom Tromey <tom@tromey.com>
16915
16916 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
16917 gdbpy_ref.
16918
16919 2017-01-10 Tom Tromey <tom@tromey.com>
16920
16921 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
16922 decref results of PyArg_ParseTupleAndKeywords.
16923
16924 2017-01-10 Tom Tromey <tom@tromey.com>
16925
16926 * python/python.c (python_run_simple_file): Use
16927 unique_xmalloc_ptr, gdbpy_ref.
16928
16929 2017-01-10 Tom Tromey <tom@tromey.com>
16930
16931 * python/py-prettyprint.c (print_stack_unless_memory_error)
16932 (print_string_repr, print_children): Use gdbpy_ref.
16933 (dummy_python_frame): New class.
16934 (dummy_python_frame::dummy_python_frame): Rename from
16935 push_dummy_python_frame.
16936 (py_restore_tstate): Remove.
16937
16938 2017-01-10 Tom Tromey <tom@tromey.com>
16939
16940 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
16941
16942 2017-01-10 Tom Tromey <tom@tromey.com>
16943
16944 * python/python.c (ensure_python_env, restore_python_env):
16945 Remove.
16946 * python/python-internal.h (ensure_python_env): Don't declare.
16947 * varobj.h (varobj_ensure_python_env): Don't declare.
16948 * varobj.c (varobj_ensure_python_env): Remove.
16949
16950 2017-01-10 Tom Tromey <tom@tromey.com>
16951
16952 * varobj.c (varobj_value_get_print_value): Use
16953 gdbpy_enter_varobj.
16954
16955 2017-01-10 Tom Tromey <tom@tromey.com>
16956
16957 * python/py-prettyprint.c (print_string_repr, print_children):
16958 Update.
16959 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
16960 of "encoding".
16961 * varobj.c (varobj_value_get_print_value): Update.
16962 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
16963
16964 2017-01-10 Tom Tromey <tom@tromey.com>
16965
16966 * varobj.c (varobj_get_display_hint)
16967 (dynamic_varobj_has_child_method, install_new_value_visualizer)
16968 (varobj_set_visualizer, free_variable): Use
16969 gdbpy_enter_varobj.
16970
16971 2017-01-10 Tom Tromey <tom@tromey.com>
16972
16973 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
16974 (do_finish_initialization): New function. Use gdbpy_ref.
16975 (gdbpy_finish_initialization): Use gdbpy_enter. Call
16976 do_finish_initialization.
16977
16978 2017-01-10 Tom Tromey <tom@tromey.com>
16979
16980 * python/py-param.c (get_set_value, get_show_value): Use
16981 gdbpy_enter, gdbpy_ref.
16982
16983 2017-01-10 Tom Tromey <tom@tromey.com>
16984
16985 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
16986
16987 2017-01-10 Tom Tromey <tom@tromey.com>
16988
16989 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
16990
16991 2017-01-10 Tom Tromey <tom@tromey.com>
16992
16993 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
16994 Use gdbpy_enter_varobj.
16995
16996 2017-01-10 Tom Tromey <tom@tromey.com>
16997
16998 * varobj.c (gdbpy_enter_varobj): New constructor.
16999 * python/python-internal.h (gdbpy_enter_varobj): New class.
17000 * python/py-varobj.c (py_varobj_get_iterator): Use
17001 gdbpy_enter_varobj.
17002
17003 2017-01-10 Tom Tromey <tom@tromey.com>
17004
17005 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
17006 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17007 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
17008 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
17009 unique_xmalloc_ptr.
17010 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
17011
17012 2017-01-10 Tom Tromey <tom@tromey.com>
17013
17014 * python/py-xmethods.c (invoke_match_method): Use
17015 gdbpy_ref.
17016
17017 2017-01-10 Tom Tromey <tom@tromey.com>
17018
17019 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
17020 gdbpy_enter, gdbpy_ref.
17021
17022 2017-01-10 Tom Tromey <tom@tromey.com>
17023
17024 * python/python.c (python_interactive_command): Use gdbpy_enter.
17025
17026 2017-01-10 Tom Tromey <tom@tromey.com>
17027
17028 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
17029 gdbpy_ref.
17030
17031 2017-01-10 Tom Tromey <tom@tromey.com>
17032
17033 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
17034 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
17035
17036 2017-01-10 Tom Tromey <tom@tromey.com>
17037
17038 * utils.h (htab_deleter): New struct.
17039 (htab_up): New typedef.
17040 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
17041 gdbpy_enter, gdbpy_ref, htab_up.
17042
17043 2017-01-10 Tom Tromey <tom@tromey.com>
17044
17045 * python/py-unwind.c (pending_frame_invalidate): Remove.
17046 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
17047
17048 2017-01-10 Tom Tromey <tom@tromey.com>
17049
17050 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
17051 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
17052
17053 2017-01-10 Tom Tromey <tom@tromey.com>
17054
17055 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
17056
17057 2017-01-10 Tom Tromey <tom@tromey.com>
17058
17059 * python/python.c (gdbpy_eval_from_control_command)
17060 (gdbpy_source_script, gdbpy_run_events)
17061 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
17062 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
17063 gdbpy_enter.
17064
17065 2017-01-10 Tom Tromey <tom@tromey.com>
17066
17067 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
17068
17069 2017-01-10 Tom Tromey <tom@tromey.com>
17070
17071 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
17072
17073 2017-01-10 Tom Tromey <tom@tromey.com>
17074
17075 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
17076 (python_on_inferior_call_pre, python_on_inferior_call_post)
17077 (python_on_memory_change, python_on_register_change)
17078 (python_inferior_exit, python_new_objfile, add_thread_object)
17079 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
17080
17081 2017-01-10 Tom Tromey <tom@tromey.com>
17082
17083 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
17084 (bpfinishpy_handle_exit): Use gdbpy_enter.
17085
17086 2017-01-10 Tom Tromey <tom@tromey.com>
17087
17088 * python/py-cmd.c (cmdpy_destroyer)
17089 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
17090 gdbpy_enter.
17091
17092 2017-01-10 Tom Tromey <tom@tromey.com>
17093
17094 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
17095 gdbpy_enter.
17096 (gdbpy_breakpoint_has_cond): Likewise.
17097
17098 2017-01-10 Tom Tromey <tom@tromey.com>
17099
17100 * python/python.c (gdbpy_enter): New constructor.
17101 (~gdbpy_enter): New destructor.
17102 (restore_python_env, ensure_python_env): Rewrite.
17103 * python/python-internal.h (gdbpy_enter): New class.
17104
17105 2017-01-10 Tom Tromey <tom@tromey.com>
17106
17107 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
17108
17109 2017-01-10 Tom Tromey <tom@tromey.com>
17110
17111 * python/py-value.c (value_has_field, get_field_flag)
17112 (get_field_type, valpy_getitem, convert_value_from_python): Use
17113 gdbpy_ref.
17114
17115 2017-01-10 Tom Tromey <tom@tromey.com>
17116
17117 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
17118 gdbpy_ref.
17119
17120 2017-01-10 Tom Tromey <tom@tromey.com>
17121
17122 * python/py-prettyprint.c (search_pp_list)
17123 (find_pretty_printer_from_objfiles)
17124 (find_pretty_printer_from_progspace)
17125 (find_pretty_printer_from_gdb, find_pretty_printer)
17126 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
17127 gdbpy_ref.
17128
17129 2017-01-10 Tom Tromey <tom@tromey.com>
17130
17131 * python/py-param.c (call_doc_function): Use gdbpy_ref.
17132
17133 2017-01-10 Tom Tromey <tom@tromey.com>
17134
17135 * python/py-linetable.c (build_line_table_tuple_from_pcs)
17136 (ltpy_get_all_source_lines): Use gdbpy_ref.
17137
17138 2017-01-10 Tom Tromey <tom@tromey.com>
17139
17140 * python/py-framefilter.c (extract_sym, extract_value)
17141 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
17142 gdbpy_ref.
17143
17144 2017-01-10 Tom Tromey <tom@tromey.com>
17145
17146 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
17147
17148 2017-01-10 Tom Tromey <tom@tromey.com>
17149
17150 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
17151
17152 2017-01-10 Tom Tromey <tom@tromey.com>
17153
17154 * python/py-function.c (convert_values_to_python, fnpy_init): Use
17155 gdbpy_ref.
17156
17157 2017-01-10 Tom Tromey <tom@tromey.com>
17158
17159 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
17160
17161 2017-01-10 Tom Tromey <tom@tromey.com>
17162
17163 * python/py-type.c (convert_field, make_fielditem, typy_fields)
17164 (typy_range): Use gdbpy_ref.
17165
17166 2017-01-10 Tom Tromey <tom@tromey.com>
17167
17168 * python/py-threadevent.c (create_thread_event_object): Use
17169 gdbpy_ref.
17170 * python/py-stopevent.c (create_stop_event_object): Simplify.
17171 (emit_stop_event): Use gdbpy_ref.
17172 * python/py-signalevent.c (create_signal_event_object): Use
17173 gdbpy_ref.
17174 * python/py-newobjfileevent.c (create_new_objfile_event_object)
17175 (emit_new_objfile_event, create_clear_objfiles_event_object)
17176 (emit_clear_objfiles_event): Use gdbpy_ref.
17177 * python/py-infevents.c (create_inferior_call_event_object)
17178 (create_register_changed_event_object)
17179 (create_memory_changed_event_object, emit_inferior_call_event)
17180 (emit_memory_changed_event, emit_register_changed_event): Use
17181 gdbpy_ref.
17182 * python/py-exitedevent.c (create_exited_event_object)
17183 (emit_exited_event): Use gdbpy_ref.
17184 * python/py-event.h (evpy_emit_event): Remove
17185 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
17186 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
17187 * python/py-continueevent.c (emit_continue_event): Use
17188 gdbpy_ref.
17189 * python/py-breakpoint.c (gdbpy_breakpoint_created)
17190 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
17191 gdbpy_ref.
17192 * python/py-bpevent.c (create_breakpoint_event_object): Use
17193 gdbpy_ref.
17194
17195 2017-01-10 Tom Tromey <tom@tromey.com>
17196
17197 * python/py-ref.h: New file.
17198
17199 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17200
17201 * cli-out.c (cli_ui_out::do_redirect): Change return type to
17202 void.
17203 * cli-out.h (cli_ui_out::do_redirect): Likewise.
17204 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
17205 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
17206 * ui-out.c (ui_out::redirect): Likewise.
17207 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
17208 * cli/cli-logging.c (set_logging_redirect): Update call site of
17209 ui_out::redirect.
17210 (handle_redirections): Likewise.
17211 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
17212 * top.c (execute_command_to_string): Likewise.
17213 * utils.c (do_ui_out_redirect_pop): Likewise.
17214
17215 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
17216
17217 * stack.c (_initialize_stack): Update "frame" command help message.
17218
17219 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
17220
17221 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
17222
17223 2017-01-06 Yao Qi <yao.qi@linaro.org>
17224
17225 * x86-linux-nat.h: Include gdb_proc_service.h.
17226
17227 2017-01-06 Yao Qi <yao.qi@linaro.org>
17228
17229 * ser-base.h: Include serial.h.
17230
17231 2017-01-06 Yao Qi <yao.qi@linaro.org>
17232
17233 * ppc-linux-tdep.h: Include ppc-tdep.h.
17234
17235 2017-01-06 Yao Qi <yao.qi@linaro.org>
17236
17237 * nat/amd64-linux-siginfo.h: Include signal.h.
17238
17239 2017-01-06 Yao Qi <yao.qi@linaro.org>
17240
17241 * nat/aarch64-linux-hw-point.h: Include break-common.h.
17242
17243 2017-01-06 Yao Qi <yao.qi@linaro.org>
17244
17245 * mi/mi-parse.h: Include mi-cmds.h.
17246
17247 2017-01-06 Yao Qi <yao.qi@linaro.org>
17248
17249 * inf-loop.c: Don't include "target.h".
17250 * inf-loop.h: Include it here.
17251
17252 2017-01-06 Yao Qi <yao.qi@linaro.org>
17253
17254 * dfp.h: Include "dboulest.h" and "expression.h".
17255
17256 2017-01-06 Yao Qi <yao.qi@linaro.org>
17257
17258 * ax-gdb.h: Include "ax.h".
17259
17260 2017-01-06 Yao Qi <yao.qi@linaro.org>
17261
17262 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
17263 with nat/gdb_ptrace.h.
17264
17265 2017-01-05 Yao Qi <yao.qi@linaro.org>
17266
17267 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
17268 new line.
17269 (mips64_fbsd_sigframe_init): Likewise.
17270
17271 2017-01-04 John Baldwin <jhb@FreeBSD.org>
17272
17273 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
17274 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
17275
17276 2017-01-04 John Baldwin <jhb@FreeBSD.org>
17277
17278 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
17279 * NEWS: Mention new FreeBSD/mips native configuration.
17280 * config/mips/fbsd.mh: New file.
17281 * configure.host: Add mips*-*-freebsd*.
17282 * mips-fbsd-nat.c: New file.
17283
17284 2017-01-04 John Baldwin <jhb@FreeBSD.org>
17285
17286 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
17287 (ALLDEPFILES): Add mips-fbsd-tdep.c.
17288 * NEWS: Mention new FreeBSD/mips target.
17289 * configure.tgt: Add mips*-*-freebsd*.
17290 * mips-fbsd-tdep.c: New file.
17291 * mips-fbsd-tdep.h: New file.
17292
17293 2017-01-04 Yao Qi <yao.qi@linaro.org>
17294
17295 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
17296 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
17297
17298 2017-01-01 Joel Brobecker <brobecker@adacore.com>
17299
17300 Update copyright year range in all GDB files.
17301
17302 2017-01-01 Joel Brobecker <brobecker@adacore.com>
17303
17304 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
17305
17306 For older changes see ChangeLog-2016.
17307 \f
17308 Local Variables:
17309 mode: change-log
17310 left-margin: 8
17311 fill-column: 74
17312 version-control: never
17313 coding: utf-8
17314 End: