1 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
3 * NEWS: Document use of GNU MPFR.
6 * Makefile.in (LIBMPFR): Add define.
7 (CLIBS): Add $(LIBMPFR).
8 * configure.ac: Add --with-mpfr configure option.
9 * configure: Regenerate.
10 * config.in: Regenerate.
12 * target-float.c [HAVE_LIBMPFR]: Include <mpfr.h>.
13 (class mpfr_float_ops): New type.
14 (mpfr_float_ops::from_target): Two new overloaded functions.
15 (mpfr_float_ops::to_target): Likewise.
16 (mpfr_float_ops::to_string): New function.
17 (mpfr_float_ops::from_string): Likewise.
18 (mpfr_float_ops::to_longest): Likewise.
19 (mpfr_float_ops::from_longest): Likewise.
20 (mpfr_float_ops::from_ulongest): Likewise.
21 (mpfr_float_ops::to_host_double): Likewise.
22 (mpfr_float_ops::from_host_double): Likewise.
23 (mpfr_float_ops::convert): Likewise.
24 (mpfr_float_ops::binop): Likewise.
25 (mpfr_float_ops::compare): Likewise.
26 (get_target_float_ops): Use mpfr_float_ops if available.
28 2017-11-22 Ulrich Weigand <uweigand@de.ibm.com>
30 * target-float.c: Do not include <math.h>.
31 Include <cmath> and <limits>.
32 (DOUBLEST): Do not define.
33 (class target_float_ops): New type.
34 (class host_float_ops): New templated type.
35 (class decimal_float_ops): New type.
37 (floatformat_to_doublest): Rename to ...
38 (host_float_ops<T>::from_target): ... this. Use template type T
39 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
40 (host_float_ops<T>::from_target): New overload using a type argument.
41 (floatformat_from_doublest): Rename to ...
42 (host_float_ops<T>::to_target): ... this. Use template type T
43 instead of DOUBLEST. Use C++ math routines. Update recursive calls.
44 (host_float_ops<T>::to_target): New overload using a type argument.
45 (floatformat_printf_format): New function.
46 (struct printf_length_modifier): New templated type.
47 (floatformat_to_string): Rename to ...
48 (host_float_ops<T>::to_string): ... this. Use type instead of
49 floatformat argument. Use floatformat_printf_format and
50 printf_length_modifier. Remove special handling of invalid numbers,
51 infinities and NaN (moved to target_float_to_string).
52 (struct scanf_length_modifier): New templated type.
53 (floatformat_from_string): Rename to ...
54 (host_float_ops<T>::from_string): ... this. Use type instead of
55 floatformat argument. Use scanf_length_modifier.
56 (floatformat_to_longest): Rename to ...
57 (host_float_ops<T>::to_longest): ... this. Use type instead of
58 floatformat argument. Handle out-of-range values deterministically.
59 (floatformat_from_longest): Rename to ...
60 (host_float_ops<T>::from_longest): ... this. Use type instead of
62 (floatformat_from_ulongest): Rename to ...
63 (host_float_ops<T>::from_ulongest): ... this. Use type instead of
65 (floatformat_to_host_double): Rename to ...
66 (host_float_ops<T>::to_host_double): ... this. Use type instead of
68 (floatformat_from_host_double): Rename to ...
69 (host_float_ops<T>::from_host_double): ... this. Use type instead of
71 (floatformat_convert): Rename to ...
72 (host_float_ops<T>::convert): ... this. Use type instead of
73 floatformat arguments. Remove handling of no-op conversions.
74 (floatformat_binop): Rename to ...
75 (host_float_ops<T>::binop): ... this. Use type instead of
76 floatformat arguments.
77 (floatformat_compare): Rename to ...
78 (host_float_ops<T>::compare): ... this. Use type instead of
79 floatformat arguments.
81 (match_endianness): Use type instead of length/byte_order arguments.
82 (set_decnumber_context): Likewise.
83 (decimal_from_number): Likewise. Update calls.
84 (decimal_to_number): Likewise.
85 (decimal_is_zero): Likewise. Update calls. Move to earlier in file.
86 (decimal_float_ops::to_host_double): New dummy function.
87 (decimal_float_ops::from_host_double): Likewise.
88 (decimal_to_string): Rename to ...
89 (decimal_float_ops::to_string): ... this. Use type instead of
90 length/byte_order arguments. Update calls.
91 (decimal_from_string): Rename to ...
92 (decimal_float_ops::from_string): ... this. Use type instead of
93 length/byte_order arguments. Update calls.
94 (decimal_from_longest): Rename to ...
95 (decimal_float_ops::from_longest): ... this. Use type instead of
96 length/byte_order arguments. Update calls.
97 (decimal_from_ulongest): Rename to ...
98 (decimal_float_ops::from_ulongest): ... this. Use type instead of
99 length/byte_order arguments. Update calls.
100 (decimal_to_longest): Rename to ...
101 (decimal_float_ops::to_longest): ... this. Use type instead of
102 length/byte_order arguments. Update calls.
103 (decimal_binop): Rename to ...
104 (decimal_float_ops::binop): ... this. Use type instead of
105 length/byte_order arguments. Update calls.
106 (decimal_compare): Rename to ...
107 (decimal_float_ops::compare): ... this. Use type instead of
108 length/byte_order arguments. Update calls.
109 (decimal_convert): Rename to ...
110 (decimal_float_ops::convert): ... this. Use type instead of
111 length/byte_order arguments. Update calls.
113 (target_float_same_category_p): New function.
114 (target_float_same_format_p): Likewise.
115 (target_float_format_length): Likewise.
116 (enum target_float_ops_kind): New type.
117 (get_target_float_ops_kind): New function.
118 (get_target_float_ops): Three new overloaded functions.
120 (target_float_is_zero): Update call.
121 (target_float_to_string): Add special handling of invalid numbers,
122 infinities and NaN (moved from floatformat_to_string). Use
123 target_float_ops callback.
124 (target_float_from_string): Use target_float_ops callback.
125 (target_float_to_longest): Likewise.
126 (target_float_from_longest): Likewise.
127 (target_float_from_ulongest): Likewise.
128 (target_float_to_host_double): Likewise.
129 (target_float_from_host_double): Likewise.
130 (target_float_convert): Add special case for no-op conversions.
131 Use target_float_ops callback.
132 (target_float_binop): Use target_float_ops callback.
133 (target_float_compare): Likewise.
135 2017-11-22 Yao Qi <yao.qi@linaro.org>
137 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use strcpy.
139 2017-11-22 Yao Qi <yao.qi@linaro.org>
141 * cli/cli-decode.c (help_list): Use memcpy instead of strncpy.
142 * cp-namespace.c (cp_lookup_transparent_type_loop): Likewise.
144 2017-11-21 Jerome Guitton <guitton@adacore.com>
146 * ravenscar-thread.c (ravenscar_wait): Update inferior ptid
147 with event ptid from the lower layer before doing the
148 ravenscar-specific update.
150 2017-11-21 Joel Brobecker <brobecker@adacore.com>
152 * ravenscar-thread.c (is_ravenscar_task): Also verify that
153 the ptid's TID is nonzero.
155 2017-11-21 Joel Brobecker <brobecker@adacore.com>
157 * ada-lang.h (ada_get_tcb_types_info): Add declaration.
158 * ada-tasks.c (ada_get_tcb_types_info): Renames get_tcb_types_info.
159 Make non-static. Change return type to char *. Adjust code
160 accordingly. Rewrite the function's documentation.
161 (read_atcb): Adjust call to get_tcb_types_info accordingly.
162 * ravenscar-thread.c (ravenscar_inferior_created): Check that
163 we have enough debugging information in the runtime to support
164 Ada task debugging before we enable the ravenscar-thread layer.
166 2017-11-21 Joel Brobecker <brobecker@adacore.com>
168 * ada-lang.h (ada_get_task_info_from_ptid): Add declaration.
169 * ada-tasks.c (ada_get_task_info_from_ptid): New function.
170 * ravenscar-thread.c: Add into comment.
171 (base_magic_null_ptid): Delete.
172 (base_ptid): Change documentation.
173 (ravenscar_active_task): Renames ravenscar_running_thread.
174 All callers updated throughout.
175 (is_ravenscar_task, ravenscar_get_thread_base_cpu): New function.
176 (ravenscar_task_is_currently_active): Likewise.
177 (get_base_thread_from_ravenscar_task): Ditto.
178 (ravenscar_update_inferior_ptid): Adjust to handle multiple CPUs.
179 (ravenscar_runtime_initialized): Likewise.
180 (get_running_thread_id): Add new parameter "cpu". Adjust
181 implementation to handle this new parameter.
182 (ravenscar_fetch_registers): Small adjustment to use
183 is_ravenscar_task and ravenscar_task_is_currently_active in
184 order to decide whether to use the target beneath or this
186 (ravenscar_store_registers, ravenscar_prepare_to_store): Likewise.
187 (ravenscar_stopped_by_sw_breakpoint): Use
188 get_base_thread_from_ravenscar_task to get the underlying
189 thread, rather than using base_ptid.
190 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
191 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
193 (ravenscar_inferior_created): Do not set base_magic_null_ptid.
195 2017-11-21 Joel Brobecker <brobecker@adacore.com>
197 * ada-lang.h (struct ada_task_info) <base_cpu>: New field.
198 * ada-lang.c (struct atcb_fieldno) <base_cpu>: New field.
199 (get_tcb_types_info): Set fieldnos.base_cpu.
200 (read_atcb): Set task_info->base_cpu.
201 (info_task): Print "Base CPU" info if set by runtime.
203 2017-11-21 Joel Brobecker <brobecker@adacore.com>
205 * ravenscar-thread.c (ravenscar_stopped_by_sw_breakpoint)
206 (ravenscar_stopped_by_hw_breakpoint, ravenscar_stopped_by_watchpoint)
207 (ravenscar_stopped_data_address, ravenscar_core_of_thread):
209 (init_ravenscar_thread_ops): Set the to_stopped_by_sw_breakpoint,
210 to_stopped_by_hw_breakpoint, to_stopped_by_watchpoint,
211 to_stopped_data_address and to_core_of_thread fields of
214 2017-11-21 Ulrich Weigand <uweigand@de.ibm.com>
216 * ppc-tdep.h (enum powerpc_long_double_abi): New data type.
217 (struct gdbarch_tdep): New member long_double_abi.
218 * rs6000-tdep.c (rs6000_gdbarch_init): Initialize long_double_abi
219 member of tdep struct based on Tag_GNU_Power_ABI_FP attribute.
220 * ppc-linux-tdep.c (ppc_linux_init_abi): Install long double data
221 format depending on long_double_abi tdep member.
222 (ppc_floatformat_for_type): Handle __ibm128 type.
224 2017-11-20 Simon Marchi <simon.marchi@polymtl.ca>
226 * darwin-nat.c (set_enable_mach_exceptions): Constify parameter.
228 2017-11-21 Pedro Alves <palves@redhat.com>
230 * dwarf2read.c (mapped_index::find_name_components_bounds)
231 <completion mode, upper bound>: Use std::lower_bound instead of
233 (test_mapped_index_find_name_component_bounds): Remove incorrect
234 "t1_fund" from expected symbols.
236 2017-11-21 Pedro Alves <palves@redhat.com>
238 * dwarf2read.c (mapped_index::name_components_casing): New field.
239 (mapped_index) <build_name_components,
240 find_name_components_bounds): Declare new methods.
241 (mapped_index::find_name_components_bounds)
242 (mapped_index::build_name_components): New methods, factored out
243 from dw2_expand_symtabs_matching_symbol.
244 (check_find_bounds_finds)
245 (test_mapped_index_find_name_component_bounds): New.
246 (run_test): Rename to ...
247 (test_dw2_expand_symtabs_matching_symbol): ... this.
248 (run_test): Reimplement.
250 2017-11-21 Pedro Alves <palves@redhat.com>
252 * cp-name-parser.y (cp_ident_is_alpha, cp_ident_is_alnum): New.
253 (symbol_end): Use cp_ident_is_alnum.
254 (yylex): Use cp_ident_is_alpha and cp_ident_is_alnum.
255 * dwarf2read.c (make_sort_after_prefix_name): New function.
256 (dw2_expand_symtabs_matching_symbol): Use it.
257 (test_symbols): Add more symbols.
258 (run_test): Add tests.
260 2017-11-17 Tom Tromey <tom@tromey.com>
262 * symtab.h (enum symbol_subclass_kind): New.
263 (struct symbol) <is_cplus_template_function, is_rust_vtable>:
265 <subclass>: New member.
266 (SYMBOL_IS_CPLUS_TEMPLATE_FUNCTION): Update.
267 * rust-lang.c (rust_get_trait_object_pointer): Update.
268 * dwarf2read.c (read_func_scope): Update.
269 (read_variable): Update.
271 2017-11-17 Tom Tromey <tom@tromey.com>
273 * dwarf2read.c (read_func_scope): Update.
274 * symtab.h (struct template_symbol): Derive from symbol.
277 2017-11-17 Tom Tromey <tom@tromey.com>
279 * symtab.h (struct symbol) <is_rust_vtable>: New member.
280 (struct rust_vtable_symbol): New.
281 (find_symbol_at_address): Declare.
282 * symtab.c (find_symbol_at_address): New function.
283 * symfile.h (struct quick_symbol_functions)
284 <find_compunit_symtab_by_address>: New member.
285 * symfile-debug.c (debug_qf_find_compunit_symtab_by_address): New
287 (debug_sym_quick_functions): Link to
288 debug_qf_find_compunit_symtab_by_address.
289 * rust-lang.c (rust_get_trait_object_pointer): New function.
290 (rust_evaluate_subexp) <case UNOP_IND>: New case. Call
291 rust_get_trait_object_pointer.
292 * psymtab.c (psym_relocate): Clear psymbol_map.
293 (psym_fill_psymbol_map, psym_find_compunit_symtab_by_address): New
295 (psym_functions): Link to psym_find_compunit_symtab_by_address.
296 * objfiles.h (struct objfile) <psymbol_map>: New member.
297 * dwarf2read.c (dwarf2_gdb_index_functions): Update.
298 (process_die) <DW_TAG_variable>: New case. Call read_variable.
299 (rust_containing_type, read_variable): New functions.
301 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
303 * common/gdb_vecs.h (DEF_VEC_I (int)): Remove.
305 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
307 * common/filestuff.c: Include <algorithm>.
308 (open_fds): Change type to std::vector<int>.
309 (do_mark_open_fd): Adjust.
310 (unmark_fd_no_cloexec): Adjust.
313 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
315 * breakpoint.c (output_thread_groups): Take an std::vector.
316 (print_one_breakpoint_location): Adjust.
318 2017-11-17 Joel Brobecker <brobecker@adacore.com>
320 * ada-lang.c (resolve_subexp): Add handling of OP_VAR_MSYM_VALUE.
321 (ada_evaluate_subexp_for_cast): New function.
322 (ada_evaluate_subexp) <UNOP_CAST>: Replace code by call to
323 ada_evaluate_subexp_for_cast.
324 (ada_evaluate_subexp) <nosideret>: Replace code by call to
326 * eval.c (evaluate_var_value): Make non-static.
327 (evaluate_var_msym_value, eval_skip_value): Likewise.
328 * value.h (evaluate_var_value, evaluate_var_msym_value)
329 (eval_skip_value): Declare.
331 2017-11-16 Joel Brobecker <brobecker@adacore.com>
333 * ada-lang.c (ada_value_cast): Remove parameter "noside".
336 2017-11-16 Pedro Alves <palves@redhat.com>
338 * python/py-unwind.c (pyuw_sniffer): Translate
339 PyExc_KeyboardInterrupt to a GDB Quit exception.
341 2017-11-16 Pedro Alves <palves@redhat.com>
343 * infrun.c (resume_cleanups): Delete.
344 (resume): No longer install a resume_cleanups cleanup nor call
346 (proceed): Pass the terminal to the inferior.
347 (keep_going_pass_signal): No longer install a resume_cleanups
350 2017-11-16 Pedro Alves <palves@redhat.com>
352 * inf-loop.c (inferior_event_handler): Don't swallow the exception
353 if the prompt is blocked.
355 2017-11-16 Pedro Alves <palves@redhat.com>
357 * breakpoint.c (insert_bp_location): Replace bp_err and
358 bp_err_message locals by a gdb_exception local.
360 2017-11-16 Pedro Alves <palves@redhat.com>
362 * inflow.c (scoped_ignore_sigttou): New class.
363 (child_terminal_ours_1, new_tty): Use it.
365 2017-11-16 Ulrich Weigand <uweigand@de.ibm.com>
367 * target-float.c (decimal_from_number): Add byte_order argument and
368 call match_endianness. Error if unknown floating-point type.
369 (decimal_to_number): Add byte_order argument and call match_endianness.
370 (decimal_from_longest): Update call. Do not call match_endianness.
371 (decimal_from_ulongest): Likewise.
372 (decimal_binop): Likewise.
373 (decimal_is_zero): Likewise.
374 (decimal_compare): Likewise.
375 (decimal_convert): Likewise.
377 2017-11-16 Phil Muldoon <pmuldoon@redhat.com>
379 * python/python.c (gdbpy_rbreak): New function.
380 * NEWS: Document Python rbreak feature.
382 2017-11-16 Yao Qi <yao.qi@linaro.org>
384 * features/tic6x-c62x.xml: Remove.
385 * features/tic6x-c64x.xml: Remove.
386 * features/tic6x-c64xp.xml: Remove.
388 2017-11-15 John Baldwin <jhb@FreeBSD.org>
390 * symtab.h: Include <array>.
392 2017-11-15 John Baldwin <jhb@FreeBSD.org>
394 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
395 (bsd_kvm_proc_cmd): Likewise.
397 2017-11-15 Simon Marchi <simon.marchi@ericsson.com>
399 * tui/tui-win.c (window_name_completer): Replace VEC with
402 2017-11-15 Andrew Cagney <cagney@gnu.org>
404 * MAINTAINERS: Remove no-longer applicable entries.
406 2017-11-15 Andrew Cagney <cagney@gnu.org>
408 * MAINTAINERS: Move self to Past Maintainers.
410 2017-11-15 Yao Qi <yao.qi@linaro.org>
412 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
413 * features/nios2-linux.c: Remove.
414 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
415 initialize_tdesc_nios2_linux.
417 2017-11-15 Yao Qi <yao.qi@linaro.org>
419 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
420 M68HC11_LAST_HARD_REG + 1.
422 2017-11-14 Paul Carroll <pcarroll@codesourcery.com>
425 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
426 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
427 Return TARGET_XFER_EOF if size of returned data is 0.
429 2017-11-14 Simon Marchi <simon.marchi@ericsson.com>
431 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
432 memory-map-selftests.c.
433 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
434 * memory-map.c (memory_map_start_memory): Fix computation of hi
436 * unittests/memory-map-selftests.c: New file.
438 2017-11-09 Joel Brobecker <brobecker@adacore.com>
440 * ada-lang.c: Fix some typos in the general command documenting
441 how Ada expressions are being evaluated and how their result
444 2017-11-09 Tom Tromey <tom@tromey.com>
446 * psymtab.c (psymbol_hash): Do not hash string contents.
447 (psymbol_compare): Add comment.
449 2017-11-09 Tom Tromey <tom@tromey.com>
451 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
453 2017-11-08 Joel Brobecker <brobecker@adacore.com>
455 * ada-exp.y (write_var_from_sym): Remove parameter
456 "orig_left_context". Update all callers.
458 2017-11-08 Simon Marchi <simon.marchi@ericsson.com>
460 * tracepoint.h (class collection_list) <stringify>: Return
461 std::vector<std::string>.
462 (encode_actions_rsp): Change parameters to
463 std::vector<std::string> *.
464 * tracepoint.c (collection_list::stringify): Return
465 std::vector<std::string> and adjust accordingly.
466 (encode_actions_rsp): Changee parameters to
467 std::vector<std::string> and adjust accordingly.
468 * remote.c (free_actions_list),
469 free_actions_list_cleanup_wrapper): Remove.
470 (remote_download_tracepoint): Adjust to std::vector.
472 2017-11-08 Tom Tromey <tom@tromey.com>
474 * dwarf2read.c (symbolp): Remove typedef.
475 (read_func_scope): Use std::vector.
476 (process_structure_scope): Use std::vector.
478 2017-11-08 Pedro Alves <palves@redhat.com>
480 * ada-lang.c (ada_make_symbol_completion_list): Use
481 completion_skip_symbol.
482 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
483 (symbol_is_function_or_method(symbol*)): New.
484 (add_symtab_completions): Add complete_symbol_mode parameter. Use
485 completion_skip_symbol.
486 (default_collect_symbol_completion_matches_break_on): Use
487 completion_skip_symbol. Pass down mode.
488 (collect_file_symbol_completion_matches): Pass down mode.
489 * symtab.h (symbol_is_function_or_method): New declarations.
490 (completion_skip_symbol): New template function.
492 2017-11-08 Pedro Alves <palves@redhat.com>
494 * linespec.c (iterate_over_all_matching_symtabs): Add
495 search_domain parameter. Pass it down to expand_symtabs_matching.
496 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
497 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
499 (add_all_symbol_names_from_pspace): Add search_domain parameter.
501 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
503 (add_matching_symbols_to_info): Add search_domain parameter. Pass
506 2017-11-08 Pedro Alves <palves@redhat.com>
508 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
509 text_len locals and don't pass them down.
510 * symtab.c (completion_list_add_name): Remove
511 sym_text/sym_text_len parameters and adjust.
512 (completion_list_add_symbol, completion_list_add_msymbol)
513 (completion_list_objc_symbol, completion_list_add_fields)
514 (add_symtab_completions): Likewise.
515 (default_collect_symbol_completion_matches_break_on)
516 (collect_file_symbol_completion_matches): Remove sym_text_len
517 local and don't pass it down.
518 * symtab.h (completion_list_add_name): Remove
519 sym_text/sym_text_len parameters.
521 2017-11-08 Pedro Alves <palves@redhat.com>
523 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
524 unittests/lookup_name_info-selftests.c.
525 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
526 * cp-support.c: Include "selftest.h".
527 (cp_remove_params_1): Rename from cp_remove_params. Add
528 'require_param' parameter, and handle it.
529 (cp_remove_params): Reimplement.
530 (cp_remove_params_if_any): New.
531 (selftests::quote): New.
532 (selftests::check_remove_params): New.
533 (selftests::test_cp_remove_params): New.
534 (_initialize_cp_support): Install
535 selftests::test_cp_remove_params.
536 * cp-support.h (cp_remove_params_if_any): Declare.
537 * dwarf2read.c :Include "selftest.h".
538 (dw2_expand_symtabs_matching_symbol): Use
539 lookup_name_info::make_ignore_params.
540 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
541 (selftests::dw2_expand_symtabs_matching::string_or_null)
542 (selftests::dw2_expand_symtabs_matching::check_match)
543 (selftests::dw2_expand_symtabs_matching::test_symbols)
544 (selftests::dw2_expand_symtabs_matching::run_test): New.
545 (_initialize_dwarf2_read): Register
546 selftests::dw2_expand_symtabs_matching::run_test.
547 * psymtab.c (psym_expand_symtabs_matching): Use
548 lookup_name_info::make_ignore_params.
549 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
550 If the lookup name wants to ignore parameters, strip them.
551 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
553 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
554 (default_collect_symbol_completion_matches_break_on): Don't try to
556 * symtab.h (lookup_name_info::lookup_name_info): Add
557 'ignore_parameters' parameter.
558 (lookup_name_info::ignore_parameters)
559 (lookup_name_info::make_ignore_params): New methods.
560 (lookup_name_info::m_ignore_parameters): New field.
561 * unittests/lookup_name_info-selftests.c: New file.
563 2017-11-08 Pedro Alves <palves@redhat.com>
565 * dwarf2read.c (dw2_expand_marked_cus)
566 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
567 (dw2_expand_symtabs_matching): Move further below.
568 (dw2_expand_marked_cus): Reindent.
570 2017-11-08 Pedro Alves <palves@redhat.com>
572 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
573 (struct name_component): New.
574 (mapped_index::name_components): New field.
575 (mapped_index::symbol_name_at): New method.
576 (dwarf2_read_index): Call mapped_index ctor.
577 (dw2_map_matching_symbols): Add comment about name_components
579 (dw2_expand_symtabs_matching): Factor part to...
580 (dw2_expand_symtabs_matching_symbol): ... this new function.
581 Build name components table, and lookup symbols in it before
582 calling the name matcher.
583 (dw2_expand_marked_cus): New, factored out from
584 dw2_expand_symtabs_matching.
585 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
587 2017-11-08 Pedro Alves <palves@redhat.com>
589 * ada-lang.c (ada_encode): Rename to ..
590 (ada_encode_1): ... this. Add throw_errors parameter and handle
592 (ada_encode): Reimplement.
593 (match_name): Delete, folded into full_name.
594 (resolve_subexp): No longer pass the encoded name to
595 ada_lookup_symbol_list.
596 (should_use_wild_match): Delete.
597 (name_match_type_from_name): New.
598 (ada_lookup_simple_minsym): Use lookup_name_info and the
599 language's symbol_name_matcher_ftype.
600 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
601 (ada_add_block_renamings): Adjust to use lookup_name_info.
602 (ada_lookup_name): New.
603 (add_nonlocal_symbols, ada_add_all_symbols)
604 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
605 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
606 (ada_name_for_lookup): Delete.
607 (ada_lookup_encoded_symbol): Construct a verbatim name.
608 (wild_match): Reverse sense of return type. Use bool.
609 (full_match): Reverse sense of return type. Inline bits of old
611 (ada_add_block_symbols): Adjust to use lookup_name_info.
612 (symbol_completion_match): Delete, folded into...
613 (ada_lookup_name_info::matches): ... .this new method.
614 (symbol_completion_add): Delete.
615 (ada_collect_symbol_completion_matches): Add name_match_type
616 parameter. Adjust to use lookup_name_info and
617 completion_list_add_name.
618 (get_var_value, ada_add_global_exceptions): Adjust to use
620 (ada_get_symbol_name_cmp): Delete.
621 (do_wild_match, do_full_match): New functions.
622 (ada_lookup_name_info::ada_lookup_name_info): New method.
623 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
625 (ada_language_defn): Install ada_get_symbol_name_matcher.
626 * ada-lex.l (processId): If name starts with '<', copy it
628 * block.c (block_iter_match_step, block_iter_match_first)
629 (block_iter_match_next, block_lookup_symbol)
630 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
632 * block.h (block_iter_match_first, block_iter_match_next)
633 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
634 * c-lang.c (c_language_defn, cplus_language_defn)
635 (asm_language_defn, minimal_language_defn): Adjust comments to
636 refer to la_get_symbol_name_matcher.
637 * completer.c (complete_files_symbols)
638 (collect_explicit_location_matches, symbol_completer): Pass a
639 symbol_name_match_type down.
640 * completer.h (class completion_match, completion_match_result):
642 (completion_tracker::reset_completion_match_result): New method.
643 (completion_tracker::m_completion_match_result): New field.
644 * cp-support.c (make_symbol_overload_list_block): Adjust to use
646 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
648 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
649 * d-lang.c: Adjust comments to refer to
650 la_get_symbol_name_matcher.
651 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
652 Adjust to use lookup_name_info.
653 (dict_iter_match_first, dict_iter_match_next)
654 (iter_match_first_hashed, iter_match_next_hashed)
655 (iter_match_first_linear, iter_match_next_linear): Adjust to work
656 with a lookup_name_info.
657 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
659 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
660 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
661 (gdb_index_symbol_name_matcher): New class.
662 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
663 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
664 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
665 with a symbol_name_match_type.
666 (f_language_defn): Adjust comments to refer to
667 la_get_symbol_name_matcher.
668 * go-lang.c (go_language_defn): Adjust comments to refer to
669 la_get_symbol_name_matcher.
670 * language.c (default_symbol_name_matcher)
671 (language_get_symbol_name_matcher): New functions.
672 (unknown_language_defn, auto_language_defn): Adjust comments to
673 refer to la_get_symbol_name_matcher.
674 * language.h (symbol_name_cmp_ftype): Delete.
675 (language_defn) <la_collect_symbol_completion_matches>: Add match
677 <la_get_symbol_name_cmp>: Delete field.
678 <la_get_symbol_name_matcher>: New field.
679 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
680 (default_symbol_name_matcher, language_get_symbol_name_matcher):
682 * linespec.c (iterate_over_all_matching_symtabs)
683 (iterate_over_file_blocks): Adjust to use lookup_name_info.
684 (find_methods): Add language parameter, and use lookup_name_info
685 and the language's symbol_name_matcher_ftype.
686 (linespec_complete_function): Adjust.
687 (lookup_prefix_sym): Use lookup_name_info.
688 (add_all_symbol_names_from_pspace): Adjust.
689 (find_superclass_methods): Add language parameter and pass it
691 (find_method): Pass symbol language down.
692 (find_linespec_symbols): Don't demangle or Ada encode here.
693 (search_minsyms_for_name): Add lookup_name_info parameter.
694 (add_matching_symbols_to_info): Add name_match_type parameter.
695 Use lookup_name_info.
696 * m2-lang.c (m2_language_defn): Adjust comments to refer to
697 la_get_symbol_name_matcher.
698 * minsyms.c: Include <algorithm>.
699 (add_minsym_to_demangled_hash_table): Remove table parameter and
700 add objfile parameter. Use search_name_hash, and add language to
701 demangled languages vector.
702 (struct found_minimal_symbols): New struct.
703 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
705 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
706 input names here. Use lookup_name_info instead. Lookup up
707 demangled names once for each language in the demangled names
709 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
710 demangled names once for each language in the demangled names
712 (build_minimal_symbol_hash_tables): Adjust.
713 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
715 * objc-lang.c (objc_language_defn): Adjust comment to refer to
716 la_get_symbol_name_matcher.
717 * objfiles.h: Include <vector>.
718 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
719 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
720 la_get_symbol_name_matcher.
721 * p-lang.c (pascal_language_defn): Adjust comment to refer to
722 la_get_symbol_name_matcher.
723 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
724 (match_partial_symbol): Use symbol_name_match_type,
725 lookup_name_info and psymbol_name_matches.
726 (lookup_partial_symbol): Use lookup_name_info.
727 (map_block): Use symbol_name_match_type and lookup_name_info.
728 (psym_map_matching_symbols): Use symbol_name_match_type.
729 (psymbol_name_matches): New.
730 (recursively_search_psymtabs): Use lookup_name_info and
731 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
732 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
733 'kind' parameter to 'domain'.
734 * rust-lang.c (rust_language_defn): Adjust comment to refer to
735 la_get_symbol_name_matcher.
736 * symfile-debug.c (debug_qf_map_matching_symbols)
737 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
738 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
739 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
740 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
741 Adjust to use symbol_name_match_type.
742 <expand_symtabs_matching>: Adjust to use lookup_name_info.
743 (expand_symtabs_matching): Adjust to use lookup_name_info.
744 * symmisc.c (maintenance_expand_symtabs): Use
745 lookup_name_info::match_any ().
746 * symtab.c (symbol_matches_search_name): New.
747 (eq_symbol_entry): Adjust to use lookup_name_info and the
749 (demangle_for_lookup_info::demangle_for_lookup_info): New.
750 (lookup_name_info::match_any): New.
751 (iterate_over_symbols, search_symbols): Use lookup_name_info.
752 (compare_symbol_name): Add language, lookup_name_info and
753 completion_match_result parameters, and use them.
754 (completion_list_add_name): Make extern. Add language and
755 lookup_name_info parameters. Use them.
756 (completion_list_add_symbol, completion_list_add_msymbol)
757 (completion_list_objc_symbol): Add lookup_name_info parameters and
758 adjust. Pass down language.
759 (completion_list_add_fields): Add lookup_name_info parameters and
760 adjust. Pass down language.
761 (add_symtab_completions): Add lookup_name_info parameters and
763 (default_collect_symbol_completion_matches_break_on): Add
764 name_match_type parameter, and use it. Use lookup_name_info.
765 (default_collect_symbol_completion_matches)
766 (collect_symbol_completion_matches): Add name_match_type
767 parameter, and pass it down.
768 (collect_symbol_completion_matches_type): Adjust.
769 (collect_file_symbol_completion_matches): Add name_match_type
770 parameter, and use lookup_name_info.
771 * symtab.h: Include <string> and "common/gdb_optional.h".
772 (enum class symbol_name_match_type): New.
773 (class ada_lookup_name_info): New.
774 (struct demangle_for_lookup_info): New.
775 (class lookup_name_info): New.
776 (symbol_name_matcher_ftype): New.
777 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
778 (symbol_matches_search_name): Declare.
779 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
780 (default_collect_symbol_completion_matches)
781 (collect_symbol_completion_matches)
782 (collect_file_symbol_completion_matches): Add name_match_type
784 (iterate_over_symbols): Use lookup_name_info.
785 (completion_list_add_name): Declare.
786 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
787 (strncmp_iw_with_mode): Now extern.
788 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
789 (strncmp_iw_with_mode): Declare.
791 2017-11-08 Keith Seitz <keiths@redhat.com>
792 Pedro Alves <palves@redhat.com>
794 * ada-lang.c (ada_language_defn): Install
795 default_search_name_hash.
796 * buildsym.c (struct buildsym_compunit): <language>: New field.
797 (finish_block_internal): Pass language when creating dictionaries.
798 (start_buildsym_compunit, start_symtab): New language parameters.
800 (restart_symtab): Pass down compilation unit's language.
801 * buildsym.h (enum language): Forward declare.
802 (start_symtab): New 'language' parameter.
803 * c-lang.c (c_language_defn, cplus_language_defn)
804 (asm_language_defn, minimal_language_defn): Install
805 default_search_name_hash.
806 * coffread.c (coff_start_symtab): Adjust.
807 * d-lang.c (d_language_defn): Install default_search_name_hash.
808 * dbxread.c (struct symloc): Add 'pst_language' field.
809 (PST_LANGUAGE): Define.
810 (start_psymtab, read_ofile_symtab): Use it.
811 (process_one_symbol): New 'language' parameter. Pass it down.
812 * dictionary.c (struct dictionary) <language>: New field.
813 (DICT_LANGUAGE): Define.
814 (dict_create_hashed, dict_create_hashed_expandable)
815 (dict_create_linear, dict_create_linear_expandable): New parameter
816 'language'. Set the dictionary's language.
817 (iter_match_first_hashed): Adjust to rename.
818 (insert_symbol_hashed): Assert we don't see mismatching
819 languages. Adjust to rename.
820 (dict_hash): Rename to ...
821 (default_search_name_hash): ... this and make extern.
822 * dictionary.h (struct language_defn): Forward declare.
823 (dict_create_hashed): New parameter 'language'.
824 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
825 * f-lang.c (f_language_defn): Install default_search_name_hash.
826 * go-lang.c (go_language_defn): Install default_search_name_hash.
827 * jit.c (finalize_symtab): Pass compunit's language to dictionary
829 * language.c (unknown_language_defn, auto_language_defn):
830 * language.h (language_defn::la_search_name_hash): New field.
831 (default_search_name_hash): Declare.
832 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
833 * mdebugread.c (new_block): New parameter 'language'.
834 * mdebugread.c (parse_symbol): Pass symbol language to block
836 (psymtab_to_symtab_1): Pass down language.
837 (new_symtab): Pass compunit's language to block allocation.
838 * objc-lang.c (objc_language_defn): Install
839 default_search_name_hash.
840 * opencl-lang.c (opencl_language_defn):
841 * p-lang.c (pascal_language_defn): Install
842 default_search_name_hash.
843 * rust-lang.c (rust_language_defn): Install
844 default_search_name_hash.
845 * stabsread.h (enum language): Forward declare.
846 (process_one_symbol): Add 'language' parameter.
847 * symtab.c (search_name_hash): New function.
848 * symtab.h (search_name_hash): Declare.
849 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
851 2017-11-08 Pedro Alves <palves@redhat.com>
853 * cp-name-parser.y (main): Don't initialize extra_chars.
855 2017-11-07 Tom Tromey <tom@tromey.com>
857 * event-top.h (command_handler): Constify.
858 * record-full.c (cmd_record_full_start): Update.
859 * thread.c (thread_apply_all_command): Update.
860 * printcmd.c (eval_command): Update.
861 * mi/mi-main.c (mi_execute_cli_command): Update.
862 (mi_execute_async_cli_command): Update.
863 * tui/tui-stack.c (tui_update_command): Update.
864 * cli/cli-interp.c (safe_execute_command): Constify.
865 * record.c (record_start): Update.
866 (record_start, record_stop, cmd_record_start): Update.
867 * record-btrace.c (cmd_record_btrace_bts_start): Update.
868 (cmd_record_btrace_pt_start): Update.
869 (cmd_record_btrace_start): Update.
870 (cmd_record_btrace_start): Update.
871 * reverse.c (exec_reverse_once): Update.
872 * python/python.c (execute_gdb_command): Don't copy the command.
873 * event-top.c (command_line_handler): Update.
874 (command_handler): Constify.
875 * defs.h (deprecated_call_command_hook): Constify.
876 * cli/cli-script.h (execute_user_command): Constify.
877 * cli/cli-script.c (execute_user_command): Constify.
878 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
879 (enum command_control_type): Update.
880 * main.c (catch_command_errors): Remove non-const overload.
881 (catch_command_errors_ftype): Remove.
882 * python/py-cmd.c (cmdpy_function): Constify.
883 * guile/scm-cmd.c (cmdscm_function): Constify.
884 * cli/cli-dump.c (call_dump_func): Constify.
885 * cli/cli-decode.c (do_const_cfunc): Constify.
886 (do_sfunc): Constify.
887 (cmd_func): Constify.
888 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
889 * top.h (execute_command): Constify.
890 * top.c (execute_command): Constify.
891 (execute_command_to_string): Constify.
892 (deprecated_call_command_hook): Constify.
893 * command.h (cmd_func): Constify.
894 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
896 2017-11-07 Tom Tromey <tom@tromey.com>
898 * ada-lang.c (catch_ada_exception_command): Constify.
899 (catch_assert_command): Constify.
900 * break-catch-throw.c (catch_catch_command, catch_throw_command)
901 (catch_rethrow_command): Constify.
902 (catch_exception_command_1): Constify.
903 * breakpoint.h (add_catch_command): Constify.
904 * break-catch-syscall.c (catch_syscall_command_1): Constify.
905 (catch_syscall_split_args): Constify.
906 * break-catch-sig.c (catch_signal_command): Constify.
907 (catch_signal_split_args): Constify.
908 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
909 cmd_const_sfunc_ftype.
910 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
911 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
912 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
913 (add_setshow_string_cmd, struct cmd_list_element)
914 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
915 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
916 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
918 (set_cmd_sfunc): Constify.
919 (empty_sfunc): Constify.
920 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
921 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
922 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
923 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
924 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
925 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
927 (set_cmd_sfunc): Constify.
928 (cmd_sfunc_ftype): Remove.
929 * compile/compile.c (set_compile_args): Constify.
930 * infrun.c (set_disable_randomization): Constify.
931 * infcmd.c (set_args_command, set_cwd_command): Constify.
932 * breakpoint.c (set_condition_evaluation_mode): Constify.
933 (add_catch_command): Constify.
934 (catch_fork_command_1, catch_exec_command_1)
935 (catch_load_command_1, catch_unload_command_1): Constify.
936 (catch_load_or_unload): Constify.
937 * guile/scm-param.c (pascm_set_func): Constify.
938 (add_setshow_generic): Constify.
939 * python/py-param.c (get_set_value): Constify.
940 * top.h (set_verbose): Constify.
941 * tui/tui-win.c (tui_set_var_cmd): Constify.
942 * mi/mi-main.c (set_mi_async_command): Constify.
943 * cli/cli-logging.c (set_logging_overwrite)
944 (set_logging_redirect): Constify.
945 * value.c (set_max_value_size): Constify.
946 * valprint.c (set_input_radix, set_output_radix): Constify.
947 * utils.c (set_width_command, set_height_command): Constify.
948 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
949 * tracepoint.c (set_disconnected_tracing)
950 (set_circular_trace_buffer, set_trace_buffer_size)
951 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
952 * top.c (set_history_size_command, set_verbose, set_editing)
953 (set_gdb_datadir, set_history_filename): Constify.
954 * target.c (set_targetdebug, maint_set_target_async_command)
955 (maint_set_target_non_stop_command, set_target_permissions)
956 (set_write_memory_permission): Constify.
957 (open_target): Constify.
958 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
959 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
960 * symtab.c (set_symbol_cache_size_handler): Constify.
961 * symfile.c (set_ext_lang_command): Constify.
962 * symfile-debug.c (set_debug_symfile): Constify.
963 * source.c (set_directories_command): Constify.
964 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
965 * serial.c (set_parity): Constify.
966 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
967 * remote.c (set_remote_exec_file, set_remotebreak)
968 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
969 * record.c (set_record_insn_history_size)
970 (set_record_call_history_size): Constify.
971 * record-full.c (set_record_full_insn_max_num): Constify.
972 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
973 * osabi.c (set_osabi): Constify.
974 * mips-tdep.c (set_mips64_transfers_32bit_regs)
975 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
976 * maint.c (maintenance_set_profile_cmd): Constify.
977 * linux-thread-db.c (set_libthread_db_search_path): Constify.
978 * language.c (set_language_command, set_range_command)
979 (set_case_command): Constify.
980 * infrun.c (set_non_stop, set_observer_mode)
981 (set_stop_on_solib_events, set_schedlock_func)
982 (set_exec_direction_func): Constify.
983 * infcmd.c (set_inferior_tty_command): Constify.
984 * disasm.c (set_disassembler_options_sfunc): Constify.
985 * demangle.c (set_demangling_command): Constify.
986 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
987 * cris-tdep.c (set_cris_version, set_cris_mode)
988 (set_cris_dwarf2_cfi): Constify.
989 * corefile.c (set_gnutarget_command): Constify.
990 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
991 (set_target_wide_charset_sfunc): Constify.
992 * breakpoint.c (update_dprintf_commands): Constify.
993 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
994 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
995 (set_disassembly_style_sfunc): Constify.
996 * arch-utils.c (set_endian, set_architecture): Constify.
997 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
998 * agent.c (set_can_use_agent): Constify.
1000 2017-11-07 Tom Tromey <tom@tromey.com>
1002 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
1003 (go32_pde, go32_pte, go32_pte_for_address): Constify.
1004 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
1005 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
1006 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
1007 (parse_int_arg, show_thread_default_detach_sc_cmd)
1008 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
1009 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
1010 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
1011 (show_task_pause_cmd, set_task_detach_sc_cmd)
1012 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
1013 (set_noninvasive_cmd, set_thread_pause_cmd)
1014 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
1015 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
1016 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
1017 * windows-nat.c (display_selectors): Constify.
1018 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
1020 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
1021 (cmd_cfunc_eq): Likewise.
1022 (struct cmd_list_element): Likewise.
1024 (cli_user_command_p): Update.
1025 * command.h (add_cmd): Remove non-const overload.
1026 (cmd_cfunc_ftype): Remove typedef.
1027 (cmd_cfunc_eq): Remove non-const overload.
1028 * value.c (show_values): Constify.
1029 * thread.c (thread_apply_all_command): Constify.
1030 * symfile.c (load_command): Constify.
1031 * source.c (directory_command): Constify.
1032 * maint.c (maintenance_internal_error)
1033 (maintenance_demangler_warning, maintenance_space_display)
1034 (maintenance_print_architecture, maintenance_translate_address)
1035 (maintenance_info_selftests, maintenance_internal_warning):
1037 * breakpoint.c (disable_trace_command, enable_trace_command):
1039 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
1041 (add_auto_load_safe_path): Constify.
1042 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
1043 * top.h (show_commands): Constify.
1044 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
1045 * sparc64-tdep.c (adi_examine_command): Constify.
1046 (adi_assign_command): Constify.
1048 2017-11-07 Tom Tromey <tom@tromey.com>
1050 * frame.h (info_locals_command, info_args_command): Constify.
1051 * auto-load.h (auto_load_info_scripts): Constify.
1052 * inferior.h (registers_info): Constify.
1053 * copying.c: Rebuild.
1054 * copying.awk: Constify generated commands.
1055 * auto-load.c (auto_load_info_scripts)
1056 (info_auto_load_gdb_scripts): Constify.
1057 * cli/cli-decode.c (struct cmd_list_element): Take a
1058 cmd_const_cfunc_ftype.
1059 * command.h (add_info): Take a cmd_const_cfunc_ftype.
1060 * tui/tui-win.c (tui_all_windows_info): Constify.
1061 * python/py-auto-load.c (info_auto_load_python_scripts):
1063 * cli/cli-cmds.c (show_command): Remove non-const overload.
1064 * tracepoint.c (info_tvariables_command, info_scope_command):
1066 (info_static_tracepoint_markers_command): Constify.
1067 * thread.c (info_threads_command): Constify.
1068 (print_thread_info_1): Constify.
1069 * target.c (info_target_command): Constify.
1070 * symtab.c (info_sources_command, info_functions_command)
1071 (info_types_command): Constify.
1072 (info_variables_command): Remove non-const overload.
1073 * symfile.c (info_ext_lang_command): Constify.
1074 * stack.c (info_frame_command, info_locals_command)
1075 (info_args_command): Constify.
1076 (backtrace_command): Remove non-const overload.
1077 * source.c (info_source_command, info_line_command): Constify.
1078 * solib.c (info_sharedlibrary_command): Constify.
1079 * skip.c (info_skip_command): Constify.
1080 * ser-go32.c (info_serial_command): Constify.
1081 * reverse.c (info_bookmarks_command): Constify.
1082 * printcmd.c (info_symbol_command, info_address_command)
1083 (info_display_command): Constify.
1084 * osdata.c (info_osdata_command): Constify.
1085 * objc-lang.c (info_selectors_command, info_classes_command):
1087 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
1088 * memattr.c (info_mem_command): Constify.
1089 * macrocmd.c (info_macro_command, info_macros_command): Constify.
1090 * linux-fork.c (info_checkpoints_command): Constify.
1091 * infrun.c (info_signals_command): Constify.
1092 * inflow.c (info_terminal_command): Constify.
1093 * inferior.c (info_inferiors_command): Constify.
1094 (print_inferior): Constify.
1095 * infcmd.c (info_program_command, info_all_registers_command)
1096 (info_registers_command, info_vector_command)
1097 (info_float_command): Constify.
1098 (registers_info): Constify.
1099 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
1100 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
1102 * f-valprint.c (info_common_command): Constify.
1103 * dcache.c (info_dcache_command): Constify.
1104 (dcache_info_1): Constify.
1105 * darwin-nat-info.c (info_mach_tasks_command)
1106 (info_mach_task_command, info_mach_ports_command)
1107 (info_mach_port_command, info_mach_threads_command)
1108 (info_mach_thread_command, info_mach_regions_command)
1109 (info_mach_regions_recurse_command, info_mach_region_command)
1110 (info_mach_exceptions_command): Constify.
1111 (get_task_from_args): Constify.
1112 * cp-support.c (info_vtbl_command): Constify.
1113 * breakpoint.c (info_watchpoints_command)
1114 (info_tracepoints_command): Constify.
1115 (info_breakpoints_command): Remove non-const overload.
1116 * avr-tdep.c (avr_io_reg_read_command): Constify.
1117 * auxv.c (info_auxv_command): Constify.
1118 * ada-tasks.c (info_tasks_command): Constify.
1119 (info_task): Constify.
1120 * ada-lang.c (info_exceptions_command): Constify.
1122 2017-11-07 Tom Tromey <tom@tromey.com>
1124 * solib.h (no_shared_libraries): Constify.
1125 * frame.h (return_command): Constify.
1126 * cli/cli-cmds.h (quit_command): Constify.
1127 * top.h (quit_command, execute_command): Constify.
1128 * target.h (flash_erase_command): Constify.
1129 * inferior.h (set_inferior_args, attach_command): Constify.
1130 * tracepoint.h (start_tracing, stop_tracing): Constify.
1131 * breakpoint.h (break_command, tbreak_command)
1132 (hbreak_command_wrapper, thbreak_command_wrapper)
1133 (rbreak_command_wrapper, watch_command_wrapper)
1134 (awatch_command_wrapper, rwatch_command_wrapper)
1135 (get_tracepoint_by_number): Constify.
1136 * symtab.c (info_variables_command, rbreak_command)
1137 (symtab_symbol_info): Constify.
1138 (info_variables_command): Add non-const overload.
1139 * top.c (dont_repeat_command): Constify.
1140 * breakpoint.c (ignore_command, commands_command)
1141 (condition_command, tbreak_command, hbreak_command)
1142 (thbreak_command, clear_command, break_command)
1143 (info_breakpoints_command, watch_command, rwatch_command)
1144 (awatch_command, trace_command, ftrace_command, strace_command)
1145 (trace_pass_command, break_range_command, dprintf_command)
1146 (agent_printf_command, get_tracepoint_by_number)
1147 (watch_maybe_just_location, trace_pass_command): Constify.
1148 (info_breakpoints_command): Add non-const overload.
1149 * tracefile.c (tsave_command): Constify.
1150 * infcmd.c (attach_command, disconnect_command, signal_command)
1151 (queue_signal_command, stepi_command, nexti_command)
1152 (finish_command, next_command, step_command, until_command)
1153 (advance_command, jump_command, continue_command, run_command)
1154 (start_command, starti_command, interrupt_command)
1155 (run_command_1, set_inferior_args, step_1): Constify.
1156 * inferior.c (add_inferior_command, remove_inferior_command)
1157 (clone_inferior_command): Constify.
1158 * linux-fork.c (checkpoint_command, restart_command): Constify.
1159 * windows-nat.c (signal_event_command): Constify.
1160 * guile/guile.c (guile_repl_command, guile_command): Constify.
1161 * printcmd.c (x_command, display_command, printf_command)
1162 (output_command, set_command, call_command, print_command)
1163 (eval_command): Constify.
1164 (non_const_set_command): Remove.
1165 (_initialize_printcmd): Update.
1166 * source.c (forward_search_command, reverse_search_command):
1168 * jit.c (jit_reader_load_command, jit_reader_unload_command):
1170 * infrun.c (handle_command): Constify.
1171 * memattr.c (mem_command): Constify.
1172 * stack.c (return_command, up_command, up_silently_command)
1173 (down_command, down_silently_command, frame_command)
1174 (backtrace_command, func_command, backtrace_command_1): Constify.
1175 (backtrace_command): Add non-const overload.
1176 * remote-sim.c (simulator_command): Constify.
1177 * exec.c (set_section_command): Constify.
1178 * tracepoint.c (tdump_command, trace_variable_command)
1179 (tstatus_command, tstop_command, tstart_command)
1180 (end_actions_pseudocommand, while_stepping_pseudocommand)
1181 (collect_pseudocommand, teval_pseudocommand, actions_command)
1182 (start_tracing, stop_tracing): Constify.
1183 * value.c (init_if_undefined_command): Constify.
1184 * tui/tui-stack.c (tui_update_command): Constify.
1185 * tui/tui-win.c (tui_refresh_all_command)
1186 (tui_set_tab_width_command, tui_set_win_height_command)
1187 (tui_set_focus_command, tui_scroll_forward_command)
1188 (tui_scroll_backward_command, tui_scroll_left_command)
1189 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
1190 (tui_set_win_height): Constify.
1191 * tui/tui-layout.c (tui_layout_command): Constify.
1192 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
1193 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
1194 (proc_untrace_sysexit_cmd): Constify.
1195 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
1196 (threadset_test_cmd, threadlist_update_test_cmd)
1197 (threadalive_test): Constify.
1198 * objc-lang.c (print_object_command): Constify.
1199 * command.h (add_com): Constify.
1200 * cli/cli-dump.c (restore_command): Constify.
1201 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
1202 (help_command, complete_command, shell_command, edit_command)
1203 (list_command, disassemble_command, make_command)
1204 (apropos_command, alias_command): Constify.
1205 * cli/cli-script.c (document_command, define_command)
1206 (while_command, if_command, validate_comname): Constify.
1207 * cli/cli-decode.c (struct cmd_list_element): Change type of
1209 * target.c (do_monitor_command, flash_erase_command): Constify.
1210 * regcache.c (reg_flush_command): Constify.
1211 * reverse.c (reverse_step, reverse_next, reverse_stepi)
1212 (reverse_nexti, reverse_continue, reverse_finish)
1213 (save_bookmark_command, goto_bookmark_command)
1214 (exec_reverse_once): Constify.
1215 * python/python.c (python_interactive_command, python_command):
1217 * typeprint.c (ptype_command, whatis_command, whatis_exp):
1219 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
1220 * gcore.c (gcore_command): Constify.
1222 2017-11-07 Tom Tromey <tom@tromey.com>
1224 * printcmd.c (x_command): Call set_repeat_arguments.
1225 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
1226 * top.c (repeat_arguments): New global.
1227 (set_repeat_arguments): New function.
1228 (execute_command): Handle repeat_arguments.
1229 (show_commands): Calls set_repeat_arguments.
1230 * command.h (set_repeat_arguments): Declare.
1232 2017-11-07 Tom Tromey <tom@tromey.com>
1234 * stack.c (backtrace_command): Use std::string.
1235 (backtrace_command_1): Make "count_exp" const.
1237 2017-11-07 Tom Tromey <tom@tromey.com>
1239 * source.c (directory_switch, mod_path, add_path): Constify.
1240 * defs.h (add_path, mod_path, directory_switch): Constify.
1241 * mi/mi-cmd-env.c (env_mod_path): Constify.
1243 2017-11-07 Tom Tromey <tom@tromey.com>
1245 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
1246 (run_command_1, continue_command, step_1, jump_command)
1247 (signal_command, until_command, advance_command, finish_command)
1248 (attach_command): Update.
1250 2017-11-07 Tom Tromey <tom@tromey.com>
1252 * command.h (set_cmd_cfunc): Don't declare.
1253 * cli/cli-decode.c (set_cmd_cfunc): Now static.
1255 2017-11-07 Tom Tromey <tom@tromey.com>
1257 * stack.c (select_frame_command): Constify.
1258 * cli/cli-decode.c (add_com_suppress_notification): Constify.
1259 * command.h (add_com_suppress_notification): Constify.
1261 2017-11-07 Tom Tromey <tom@tromey.com>
1263 * breakpoint.c (stop_command): Constify.
1264 * cli/cli-decode.c (struct cmd_list_element): Constify.
1265 * command.h (add_abbrev_prefix_cmd): Constify.
1267 2017-11-07 Pedro Alves <palves@redhat.com>
1269 * breakpoint.c (extract_bp_kind): New enum.
1270 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
1271 factored out from ...
1272 (extract_bp_number_and_location): ... here.
1273 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
1275 2017-11-07 Pedro Alves <palves@redhat.com>
1277 * breakpoint.c (extract_bp_number_and_location): Change return
1278 type to void. Throw error instead of warning.
1279 (enable_disable_command): Adjust.
1281 2017-11-07 Xavier Roirand <roirand@adacore.com>
1282 Pedro Alves <palves@redhat.com>
1284 * breakpoint.c (map_breakpoint_number_range): New, factored out
1286 (map_breakpoint_numbers): ... here.
1287 (find_location_by_number): Change parameters from string to
1288 breakpoint number and location.
1289 (extract_bp_number_and_location): New function.
1290 (enable_disable_bp_num_loc)
1291 (enable_disable_breakpoint_location_range)
1292 (enable_disable_command): New functions, factored out ...
1293 (enable_command, disable_command): ... these functions, and
1294 adjusted to support ranges.
1295 * NEWS: Document enable/disable breakpoint location range feature.
1297 2017-11-06 Luis Machado <luis.machado@linaro.org>
1299 * MAINTAINERS (Write After Approval): Update my e-mail address.
1301 2017-11-06 Pedro Alves <palves@redhat.com>
1303 * gnu-nat.c (gnu_terminal_init): Delete.
1304 (gnu_target): Don't install gnu_terminal_init.
1305 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
1306 (child_terminal_init): ... this function.
1308 2017-11-06 Pedro Alves <palves@redhat.com>
1310 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
1312 * config.in, configure: Regenerate.
1314 2017-11-06 Pedro Alves <palves@redhat.com>
1316 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
1317 (async_init_signals): Adjust.
1318 (handle_stop_sig): Rename to ...
1319 (handle_sigtstp): ... this.
1320 (async_stop_sig): Rename to ...
1321 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
1323 * event-top.h: Move signal.h include to the top. Check SIGTSTP
1324 instead of STOP_SIGNAL thoughout.
1325 (handle_stop_sig): Rename to ...
1326 (handle_sigtstp): ... this.
1327 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
1329 2017-11-06 Pedro Alves <palves@redhat.com>
1331 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
1332 longer set flags twice in row.
1334 2017-11-06 Pedro Alves <palves@redhat.com>
1336 * Makefile.in (SER_HARDWIRE): Update comment.
1337 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
1338 * common/gdb_termios.h: Delete file.
1339 * common/job-control.c: Include termios.h and unistd.h instead of
1341 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
1343 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
1345 * configure.ac: No longer check for termio.h and sgtty.h.
1346 * configure: Regenerate.
1347 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
1348 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
1349 Replace PROCESS_GROUP_TYPE references with pid_t references
1351 (gdb_getpgrp): Delete.
1352 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
1353 (child_terminal_inferior): Remove comment. Remove sgtty code.
1354 (child_terminal_ours_1): Use tcgetpgrp directly instead of
1355 gdb_getpgrp. Use serial_set_tty_state instead aof
1356 serial_noflush_set_tty_state. Remove sgtty code.
1357 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
1358 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
1359 (inferior_process_group): Now returns pid_t.
1360 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
1361 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
1362 * ser-event.c (serial_event_ops): Update.
1363 * ser-go32.c (dos_noflush_set_tty_state): Delete.
1365 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
1366 * ser-pipe.c (pipe_ops): Update.
1367 * ser-tcp.c (tcp_ops): Update.
1368 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
1369 HAVE_TERMIOS checks.
1370 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
1371 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
1372 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
1374 (hardwire_noflush_set_tty_state): Delete.
1375 (hardwire_print_tty_state, hardwire_drain_output)
1376 (hardwire_flush_output, hardwire_flush_input)
1377 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
1378 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
1379 code, and assume termios.
1380 (hardwire_ops): Update.
1381 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
1382 * serial.c (serial_noflush_set_tty_state): Delete.
1383 * serial.h (serial_noflush_set_tty_state): Delete.
1384 (serial_ops::noflush_set_tty_state): Delete.
1386 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1388 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
1389 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
1390 (COMMON_OBS): Remove doublest.o and dfp.o.
1391 Do not build target-float.c (instead of doublest.c)
1392 with -Wformat-nonliteral.
1394 * doublest.c: Remove file.
1395 * doublest.h: Remove file.
1396 * dfp.c: Remove file.
1397 * dfp.h: Remove file.
1399 * target-float.c: Do not include "doublest.h" and "dfp.h".
1400 (DOUBLEST): Move here from doublest.h.
1401 (enum float_kind): Likewise.
1402 (FLOATFORMAT_CHAR_BIT): Likewise.
1403 (FLOATFORMAT_LARGEST_BYTES): Likewise.
1404 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
1405 (floatformat_precision): Likewise.
1406 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
1407 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
1409 (host_float_format, host_double_format, host_long_double_format):
1411 (floatformat_to_string, floatformat_from_string): Likewise.
1412 (floatformat_to_doublest): Likewise. Also, inline the original
1413 convert_floatformat_to_doublest.
1414 (floatformat_from_doublest): Likewise. Also, inline the original
1415 convert_floatformat_from_doublest.
1417 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
1418 (MAX_DECIMAL_STRING): Move here from dfp.c.
1419 (match_endianness): Likewise.
1420 (set_decnumber_context, decimal_check_errors): Likewise.
1421 (decimal_from_number, decimal_to_number): Likewise.
1422 (decimal_to_string, decimal_from_string): Likewise. Make static.
1423 (decimal_from_longest, decimal_from_ulongest): Likewise.
1424 (decimal_to_longest): Likewise.
1425 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
1426 (decimal_convert): Likewise.
1428 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1430 * doublest.c: Do not include "gdbtypes.h".
1431 (extract_typed_floating): Remove.
1432 (store_typed_floating): Remove.
1433 (convert_typed_floating): Remove.
1434 * doublest.h (struct type): Remove.
1435 (DOUBLEST_PRINT_FORMAT): Remove.
1436 (DOUBLEST_SCAN_FORMAT): Remove.
1437 (extract_typed_floating): Remove.
1438 (store_typed_floating): Remove.
1439 (convert_typed_floating): Remove.
1441 * dfp.c (decimal_from_doublest): Remove.
1442 (decimal_to_doublest): Remove.
1443 * dfp.h: Do not include "doublest.h".
1444 (decimal_from_doublest): Remove.
1445 (decimal_to_doublest): Remove.
1447 * value.c: Do not include "doublest.h" and "dfp.h".
1448 (value_as_double): Remove.
1449 (unpack_double): Remove.
1450 (value_from_double): Remove.
1451 (value_from_decfloat): Remove.
1452 * value.h: Do not include "doublest.h".
1453 (value_as_double): Remove.
1454 (unpack_double): Remove.
1455 (value_from_double): Remove.
1456 (value_from_decfloat): Remove.
1458 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1460 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
1461 (i386_extract_return_value): Use target_float_convert.
1462 (i386_store_return_value): Likewise.
1463 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
1464 (i387_value_to_register): Likewise.
1465 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
1466 (ia64_register_to_value): Use target_float_convert.
1467 (ia64_value_to_register): Likewise.
1468 (ia64_extract_return_value): Likewise.
1469 (ia64_store_return_value): Likewise.
1470 (ia64_push_dummy_call): Likewise.
1471 * m68k-tdep.c: Include "target-float.h".
1472 (m68k_register_to_value): Use target_float_convert.
1473 (m68k_value_to_register): Likewise.
1474 (m68k_svr4_extract_return_value): Likewise.
1475 (m68k_svr4_store_return_value): Likewise.
1476 * ppc-sysv-tdep.c: Include "target-float.h".
1477 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
1478 (do_ppc_sysv_return_value): Likewise.
1479 (ppc64_sysv_abi_push_freg): Likewise.
1480 (ppc64_sysv_abi_return_value_base): Likewise.
1481 * rs6000-aix-tdep.c: Include "target-float.h".
1482 (rs6000_push_dummy_call): Use target_float_convert.
1483 (rs6000_return_value): Likewise.
1484 * rs6000-lynx178-tdep.c: Include "target-float.h".
1485 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
1486 (rs6000_lynx178_return_value): Likewise.
1487 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
1488 (rs6000_register_to_value): Use target_float_convert.
1489 (rs6000_value_to_register): Likewise.
1490 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
1491 (arm_extract_return_value): Use target_float_convert.
1492 (arm_store_return_value): Likewise.
1493 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
1494 (sh_register_convert_to_virtual): Use target_float_convert.
1495 (sh_register_convert_to_raw): Likewise.
1496 * sh64-tdep.c: Include "target-float.h".
1497 (sh64_extract_return_value): Use target_float_convert.
1498 (sh64_register_convert_to_virtual): Likewise.
1499 (sh64_register_convert_to_raw): Likewise. Fix argument types.
1501 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1503 * target-float.c (floatformat_to_host_double): New function.
1504 (floatformat_from_host_double): Likewise.
1505 (target_float_to_host_double): Likewise.
1506 (target_float_from_host_double): Likewise.
1507 * target-float.h (target_float_to_host_double): Add prototype.
1508 (target_float_from_host_double): Likewise.
1510 * guile/scm-value.c: Include "target-float.h".
1511 (gdbscm_value_to_real): Use target_float_to_host_double.
1512 Handle integer source values via value_as_long.
1513 * guile/scm-math.c: Include "target-float.h". Do not include
1514 "doublest.h", "dfp.h", and "expression.h".
1515 (vlscm_convert_typed_number): Use target_float_from_host_double.
1516 (vlscm_convert_number): Likewise.
1518 * python/py-value.c (valpy_float): Use target_float_to_host_double.
1519 (convert_value_from_python): Use target_float_from_host_double.
1521 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1523 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
1524 (cast_from_fixed): Likewise.
1525 (ada_scaling_type): New function.
1526 (ada_delta): Return value instead of DOUBLEST. Perform target
1527 arithmetic instead of host arithmetic.
1528 (scaling_factor): Rename to ...
1529 (ada_scaling_factor) ... this. Make non-static. Return value instead
1530 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
1531 (ada_fixed_to_float): Remove.
1532 (ada_float_to_fixed): Remove.
1533 * ada-lang.h (ada_fixed_to_float): Remove.
1534 (ada_float_to_fixed): Remove.
1535 (ada_delta): Return value instead of DOUBLEST.
1536 (ada_scaling_factor): Add prototype.
1538 * ada-typeprint.c: Include "target-float.h".
1539 (print_fixed_point_type): Perform target arithmetic instead of
1541 * ada-valprint.c: Include "target-float.h".
1542 (ada_val_print_num): Perform target arithmetic instead of
1543 host arithmetic for fixed-point types.
1545 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1547 * target-float.c: Include <math.h>.
1548 (floatformat_binop): New function.
1549 (floatformat_compare): Likewise.
1550 (target_float_binop): Likewise.
1551 (target_float_compare): Likewise.
1552 * target-float.h: Include "expression.h".
1553 (target_float_binop): Add prototype.
1554 (target_float_compare): Likewise.
1556 * valarith.c: Do not include "doublest.h" and "dfp.h".
1557 Include "common/byte-vector.h".
1558 (value_args_as_decimal): Remove, replace by ...
1559 (value_args_as_target_float): ... this function. Handle both
1560 binary and decimal target floating-point formats.
1561 (scalar_binop): Handle both binary and decimal FP using
1562 value_args_as_target_float and target_float_binop.
1563 (value_equal): Handle both binary and decimal FP using
1564 value_args_as_target_float and target_float_compare.
1565 (value_less): Likewise.
1566 (value_pos): Handle all scalar types as simple copy.
1567 (value_neg): Handle all scalar types via BINOP_SUB from 0.
1568 * dfp.c (decimal_binop): Throw error instead of internal_error
1569 when called with an unsupported operation code.
1571 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1573 * target-float.c (target_float_to_string): New function.
1574 (target_float_from_string): New function.
1575 * target-float.h (target_float_to_string): Add prototype.
1576 (target_float_from_string): Add prototype.
1578 * valprint.c: Include "target-float.h". Do not include
1579 "doublest.h" and "dfp.h".
1580 (print_floating): Use target_float_to_string.
1581 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
1582 (printf_floating): Use target_float_to_string.
1583 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
1584 (print_i387_value): Use target_float_to_string.
1585 * mips-tdep.c: Include "target-float.h".
1586 (mips_print_fp_register): Use target_float_to_string.
1587 * sh64-tdep.c: Include "target-float.h".
1588 (sh64_do_fp_register): Use target_float_to_string.
1590 * parse.c: Include "target-float.h". Do not include
1591 "doublest.h" and "dfp.h".
1592 (parse_float): Use target_float_from_string.
1593 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
1594 (define_symbol): Use target_float_from_string.
1595 * gdbarch-selftests.c: Include "target-float.h".
1596 (register_to_value_test): Use target_float_from_string.
1598 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1600 * Makefile.c (SFILES): Add target-float.c.
1601 (HFILES_NO_SRCDIR): Add target-float.h.
1602 (COMMON_OBS): Add target-float.o.
1603 * target-float.h: New file.
1604 * target-float.c: New file.
1606 * doublest.c (floatformat_classify): Fix detection of float_zero.
1608 * gdbtypes.c (is_floating_type): New function.
1609 * gdbtypes.h (is_floating_type): Add prototype.
1611 * value.c: Do not include "floatformat.h".
1612 (unpack_double): Use target_float_is_valid.
1613 (is_floating_value): New function.
1614 * value.h (is_floating_value): Add prototype-
1616 * valarith.c: Include "target-float.h".
1617 (value_logical_not): Use target_float_is_zero.
1619 * python/py-value.c: Include "target-float.h".
1620 (valpy_nonzero): Use target_float_is_zero.
1622 2017-11-04 Tom Tromey <tom@tromey.com>
1624 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
1626 2017-11-04 Tom Tromey <tom@tromey.com>
1628 * breakpoint.c (set_momentary_breakpoint): Return
1630 (until_break_command): Update.
1631 (new_until_break_fsm): Change argument types to
1633 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1634 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
1636 * infcmd.c (finish_forward): Update.
1637 * breakpoint.h (set_momentary_breakpoint)
1638 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1639 (make_cleanup_delete_breakpoint): Remove.
1640 (struct breakpoint_deleter): New.
1641 (breakpoint_up): New typedef.
1642 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
1643 (insert_exception_resume_breakpoint): Update.
1644 (insert_exception_resume_from_probe): Update.
1645 (insert_longjmp_resume_breakpoint): Update.
1646 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
1647 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
1648 * infcall.c (call_function_by_hand_dummy): Update
1650 2017-11-04 Tom Tromey <tom@tromey.com>
1652 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
1654 2017-11-04 Tom Tromey <tom@tromey.com>
1656 * linux-tdep.c (linux_core_info_proc_mappings): Use
1658 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
1660 (linux_corefile_thread): Update.
1661 (linux_make_corefile_notes): Remove unused variable.
1663 2017-11-04 Tom Tromey <tom@tromey.com>
1665 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
1668 2017-11-04 Tom Tromey <tom@tromey.com>
1670 * objfiles.c (do_free_objfile_cleanup): Remove.
1671 * compile/compile-object-load.c (compile_object_load): Update.
1672 * objfiles.h (make_cleanup_free_objfile): Remove.
1674 2017-11-04 Tom Tromey <tom@tromey.com>
1676 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
1677 (adi_read_versions): Change "tags" to "gdb_byte *".
1678 (adi_print_versions): Likewise.
1680 2017-11-04 Tom Tromey <tom@tromey.com>
1683 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
1684 from start_rbreak_breakpoints.
1685 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
1686 * breakpoint.h (class scoped_rbreak_breakpoints): New.
1687 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
1688 * symtab.c (do_end_rbreak_breakpoints): Remove.
1689 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
1691 2017-11-04 Tom Tromey <tom@tromey.com>
1693 * cp-namespace.c (reset_directive_searched): Remove.
1694 (cp_lookup_symbol_via_imports): Use scoped_restore.
1695 * cp-support.c (reset_directive_searched): Remove.
1696 (make_symbol_overload_list_using): Use scoped_restore.
1697 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
1698 (reset_directive_searched): Remove.
1700 2017-11-04 Tom Tromey <tom@tromey.com>
1702 * symfile.c (find_separate_debug_file_by_debuglink): Use
1705 2017-11-04 Tom Tromey <tom@tromey.com>
1707 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
1709 (compute_stack_depth): Likewise.
1710 (do_compile_dwarf_expr_to_c): Use std::vector.
1712 2017-11-04 Tom Tromey <tom@tromey.com>
1714 * compile/compile-object-load.c (link_callbacks_einfo): Use
1717 2017-11-04 Tom Tromey <tom@tromey.com>
1719 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1720 Use scoped_free_pendings.
1721 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
1722 scoped_free_pendings.
1723 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
1724 (xcoff_initial_scan): Likewise.
1725 * buildsym.c (reset_symtab_globals): Update comment.
1726 (scoped_free_pendings): Rename from really_free_pendings.
1727 (prepare_for_building): Update comment.
1728 (buildsym_init): Likewise.
1729 * buildsym.h (class scoped_free_pendings): New class.
1730 (really_free_pendings): Don't declare.
1732 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
1734 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
1735 output when converting a zero value to a special byteorder format.
1737 2017-11-02 Yao Qi <yao.qi@linaro.org>
1739 * frame.c (do_frame_register_read): Remove aspace.
1740 * jit.c (jit_frame_sniffer): Likwise.
1741 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1742 * regcache.c (regcache::regcache): Pass nullptr.
1743 (regcache_print): Caller updated.
1744 * regcache.h (regcache::regcache): Remove one constructor
1747 2017-11-02 Yao Qi <yao.qi@linaro.org>
1749 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
1751 2017-11-02 Yao Qi <yao.qi@linaro.org>
1753 * breakpoint.c (insert_single_step_breakpoints): Update.
1754 * frame.c (struct frame_info) <aspace>: Add const.
1755 (frame_save_as_regcache): Add const.
1756 (get_frame_address_space): Return const address_space *.
1757 * frame.h (get_frame_address_space): Update declaration.
1758 * infrun.c (struct step_over_info) <aspace>: Add const.
1759 (set_step_over_info): Make aspace const.
1760 (displaced_step_prepare_throw): Change variable const.
1762 (proceed): Likewise.
1763 (adjust_pc_after_break): Likewise.
1764 (save_waitstatus): Likewise.
1765 (handle_signal_stop): Likewise.
1766 (keep_going_pass_signal): Likewise.
1767 * jit.c (jit_frame_sniffer): Add const.
1768 * mips-tdep.c (mips_single_step_through_delay): Likewise.
1769 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1770 * record-full.c (record_full_wait_1): Likewise.
1771 * regcache.c (regcache::regcache): Change parameter to const.
1772 * regcache.h (regcache::regcache): Likewise.
1773 (regcache::aspace): Return const address_space *.
1774 (regcache) <m_aspace>: Add const.
1776 2017-11-02 Yao Qi <yao.qi@linaro.org>
1778 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
1779 * frame.c (create_sentinel_frame): Likewise.
1780 * infrun.c (displaced_step_prepare_throw): Likewise.
1782 (thread_still_needs_step_over_bp): Likewise.
1783 (proceed): Likewise.
1784 (do_target_wait): Likewise.
1785 (adjust_pc_after_break): Likewise.
1786 (handle_syscall_event): Likewise.
1787 (save_waitstatus): Likewise.
1788 (handle_inferior_event_1): Likewise.
1789 (handle_signal_stop): Likewise.
1790 (keep_going_pass_signal): Likewise.
1791 * linux-nat.c (status_callback): Likewise.
1792 (save_stop_reason): Likewise.
1793 (resume_stopped_resumed_lwps): Likewise.
1794 * record-full.c (record_full_exec_insn): Likewise.
1795 (record_full_wait_1): Likewise.
1796 * regcache.c (get_regcache_aspace): Remove.
1797 * regcache.h (get_regcache_aspace): Remove.
1799 2017-11-02 Yao Qi <yao.qi@linaro.org>
1801 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
1802 (init_regcache_descr): Use gdbarch_num_regs.
1803 (regcache::regcache): Likewise.
1804 (regcache::get_register_status): Likewise.
1805 (regcache::assert_raw_regnum): Likewise.
1806 (regcache::cooked_read): Likewise.
1807 (regcache::cooked_read_value): Likewise.
1808 (regcache::cooked_write): Likewise.
1809 (regcache::dump): Likewise.
1810 (regcache::num_raw_registers): New method.
1811 * regcache.h (class regcache) <num_raw_registers>: New.
1813 2017-11-02 Yao Qi <yao.qi@linaro.org>
1815 * regcache.c (regcache::assert_regnum): New method.
1816 (regcache::invalidate): Call assert_regnum.
1817 (regcache::raw_update): Likewise.
1818 (regcache::raw_write): Likewise.
1819 (regcache::raw_read_part): Likewise.
1820 (regcache::raw_write_part): Likewise.
1821 (regcache::raw_supply): Likewise.
1822 (regcache::raw_supply_integer): Likewise.
1823 (regcache::raw_supply_zeroed): Likewise.
1824 (regcache::raw_collect): Likewise.
1825 (regcache::raw_collect_integer): Likewise.
1826 * regcache.h (regcache::assert_regnum): Declare.
1828 2017-11-02 Yao Qi <yao.qi@linaro.org>
1830 * regcache.c (regcache::dump): Remove code.
1832 2017-11-02 Yao Qi <yao.qi@linaro.org>
1834 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
1836 <sizeof_cooked_register_status>: Remove.
1837 (init_regcache_descr): Update.
1838 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
1839 (regcache::save): Likewise.
1840 (regcache::dump): Likewise.
1842 2017-11-01 James Bowman <james.bowman@ftdichip.com>
1844 * ft32-tdep.c (ft32_fetch_instruction): New function.
1845 (ft32_analyze_prologue): Use ft32_fetch_instruction().
1847 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
1849 * cli/cli-script.c (execute_control_command): Rename to ...
1850 (execute_control_command_1): ... this.
1851 (execute_control_command): New function.
1853 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
1855 * tracepoint.c (tfind_command): Remove const_cast.
1857 2017-10-30 Mike Gulick <mgulick@mathworks.com>
1859 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
1861 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
1863 * common/common-utils.h (in_inclusive_range): New function.
1864 * arm-tdep.c (arm_record_extension_space): Use
1866 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
1867 * cris-tdep.c (cris_spec_reg_applicable): Use
1870 2017-10-30 Pedro Alves <palves@redhat.com>
1871 Simon Marchi <simon.marchi@ericsson.com>
1873 * remote.c (remote_set_syscall_catchpoint): Build a std::string
1874 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
1876 2017-10-30 Pedro Alves <palves@redhat.com>
1878 * common/common-utils.c (string_appendf, string_vappendf): New
1880 * common/common-utils.h (string_appendf, string_vappendf): New
1882 * unittests/common-utils-selftests.c (string_appendf_func)
1883 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
1884 (string_vappendf_tests): New functions.
1885 (_initialize_common_utils_selftests): Register "string_appendf" and
1886 "string_vappendf tests".
1888 2017-10-30 Pedro Alves <palves@redhat.com>
1890 * unittests/common-utils-selftests.c (format_func): New typedef.
1891 (string_printf_tests, string_vprintf_tests): Tests factored out
1893 (test_format_func): ... this new function.
1894 (string_printf_tests, string_vprintf_tests): Reimplement on top of
1897 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1899 * darwin-nat.c: Remove include of gdb.h.
1901 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1903 * xtensa-xtregs.c: Fix formatting issues.
1905 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1907 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
1909 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
1912 * python/py-infthread.c (thpy_get_inferior): Increment reference
1913 of inferior before returning it.
1915 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1917 * unittests/common-utils-selftests.c (format): Add
1920 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1922 * xml-syscall.c (struct syscall_desc): Add constructor.
1923 <name>: Change type to std::string.
1924 (syscall_desc_up): New typedef.
1925 (syscall_desc_p): Remove typeder.
1926 (DEF_VEC_P(syscall_desc_p)): Remove.
1927 (struct syscall_group_desc): Add constructor.
1928 <name>: Change type to std::string.
1929 <syscalls>: Change type to std::vector.
1930 (syscall_group_desc_up): New typedef.
1931 (syscall_group_desc_p): Remove typedef.
1932 (DEF_VEC_P(syscall_group_desc_p)): Remove.
1933 (struct syscalls_info) <syscalls>: Change type to std::vector of
1936 <my_gdb_datadir>: Change type to std::string.
1937 (syscalls_info_up): New typedef.
1938 (allocate_syscalls_info): Remove.
1939 (syscalls_info_free_syscalls_desc): Remove.
1940 (syscalls_info_free_syscall_group_desc): Remove.
1941 (free_syscalls_info): Remove.
1942 (make_cleanup_free_syscalls_info): Remove.
1943 (syscall_group_create_syscall_group_desc): Adjust.
1944 (syscall_group_add_syscall): Adjust.
1945 (syscall_create_syscall_desc): Adjust.
1946 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
1947 (init_syscalls_info): Adjust.
1948 (syscall_group_get_group_by_name): Adjust.
1949 (xml_get_syscall_number): Adjust.
1950 (xml_get_syscall_name): Adjust.
1951 (xml_list_of_syscalls): Adjust.
1952 (xml_list_syscalls_by_group): Adjust.
1953 (xml_list_of_groups): Adjust.
1955 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1957 * probe.h: Don't include gdb_vecs.h.
1958 (DEF_VEC_P (probe_p)): Remove.
1959 (find_probes_in_objfile): Return an std::vector.
1960 * probe.c (find_probes_in_objfile): Likewise.
1961 * breakpoint.c (breakpoint_objfile_data)
1962 <longjmp_probes>: Change type to std::vector.
1963 <exception_probes>: Likewise.
1964 (free_breakpoint_probes): Don't manually free vectors.
1965 (create_longjmp_master_breakpoint): Adjust.
1966 (create_exception_master_breakpoint): Adjust.
1967 * solib-svr4.c (svr4_create_probe_breakpoints): Change
1968 parameter type, adjust.
1969 (svr4_create_solib_event_breakpoints): Adjust.
1971 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1973 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
1974 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
1976 (free_breakpoint_probes): Rename to ...
1977 (free_breakpoint_objfile_data): ... this, and call delete on
1980 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1982 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
1983 (loaded_script_ptr): Remove typedef.
1984 (DEF_VEC_P (loaded_script_ptr)): Remove.
1985 (struct collect_matching_scripts_data): Add constructor.
1986 <scripts_p>: Change type to (pointer to) std::vector.
1987 (collect_matching_scripts_data): Adjust.
1988 (sort_scripts_by_name): Make suitable for std::sort.
1989 (print_scripts): Don't sort vector, adjust to std::vector.
1990 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
1992 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1994 * symfile.c (filename_language): Make struct, not typedef. Add
1996 <ext>: Change type to std::string.
1997 (DEF_VEC_O (filename_language)): Remove.
1998 (filename_language_table): Change type to std::vector.
1999 (add_filename_language): Adjust.
2000 (set_ext_lang_command): Adjust.
2001 (info_ext_lang_command): Adjust.
2002 (deduce_language_from_filename): Adjust.
2003 (class scoped_restore_filename_language_table): Remove.
2004 (test_filename_language): Use scoped_restore.
2005 (test_set_ext_lang_command): Use scoped_restore, adjust to
2008 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2010 * symfile.c: Include selftest.h.
2011 (class scoped_restore_filename_language_table): New.
2012 (test_filename_language): New test.
2013 (test_set_ext_lang_command): New test.
2014 (_initialize_symfile): Register tests.
2016 2017-10-27 Keith Seitz <keiths@redhat.com>
2018 * breakpoint.c (print_breakpoint_location): Use the symbol saved
2019 in the bp_location, falling back to find_pc_sect_function when
2021 (add_location_to_breakpoint): Save sal->symbol.
2022 * breakpoint.h (struct bp_location) <symbol>: New field.
2023 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
2024 * symtab.h (struct symtab_and_line) <symbol>: New field.
2026 2017-10-26 Patrick Frants <osscontribute@gmail.com>
2029 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
2032 2017-10-26 Pedro Alves <palves@redhat.com>
2034 * remote.c (remote_async_terminal_ours_p): Delete.
2035 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
2036 Remove references to 'remote_async_terminal_ours_p'.
2038 2017-10-26 Yao Qi <yao.qi@linaro.org>
2040 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
2042 2017-10-26 Yao Qi <yao.qi@linaro.org>
2044 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
2046 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
2048 * breakpoint.c (bpstat_check_location): Remove cast.
2049 (breakpoint_hit_catch_fork): Make aspce const.
2050 (breakpoint_hit_catch_solib): Likewise.
2051 (breakpoint_hit_catch_exec): Likewise.
2052 (breakpoint_hit_ranged_breakpoint): Likewise.
2053 (breakpoint_hit_watchpoint): Likewise.
2054 (base_breakpoint_breakpoint_hit): Likewise.
2055 (bkpt_breakpoint_hit): Likewise.
2056 (dprintf_breakpoint_hit): Likewise.
2057 (tracepoint_breakpoint_hit): Likewise.
2058 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
2060 2017-10-26 Yao Qi <yao.qi@linaro.org>
2062 * breakpoint.c (breakpoint_location_address_match): Change
2063 "struct address_space *" to "const address_space".
2064 (breakpoint_location_address_range_overlap): Likewise.
2065 (breakpoint_here_p): Likewise.
2066 (breakpoint_in_range_p): Likewise.
2067 (moribund_breakpoint_here_p): Likewise.
2068 (bp_location_inserted_here_p): Likewise.
2069 (software_breakpoint_inserted_here_p): Likewise.
2070 (hardware_breakpoint_inserted_here_p): Likewise.
2071 (hardware_watchpoint_inserted_in_range): Likewise.
2072 (bpstat_check_location): Likewise.
2073 (bpstat_stop_status): Likewise.
2074 (breakpoint_address_match): Likewise.
2075 (breakpoint_address_match_range): Likewise.
2076 (breakpoint_location_address_match): Likewise.
2077 (breakpoint_location_address_range_overlap): Likewise.
2078 (insert_single_step_breakpoint): Likewise.
2079 (breakpoint_has_location_inserted_here): Likewise.
2080 (single_step_breakpoint_inserted_here_p): Likewise.
2081 (pc_at_non_inline_function): Likewise.
2082 * breakpoint.h (bpstat_stop_status): Update declaration.
2083 (breakpoint_here_p): Likewise.
2084 (breakpoint_in_range_p): Likewise.
2085 (moribund_breakpoint_here_p): Likewise.
2086 (breakpoint_inserted_here_p): Likewise.
2087 (software_breakpoint_inserted_here_p): Likewise.
2088 (hardware_breakpoint_inserted_here_p): Likewise.
2089 (breakpoint_has_location_inserted_here): Likewise.
2090 (single_step_breakpoint_inserted_here_p): Likewise.
2091 (hardware_watchpoint_inserted_in_range): Likewise.
2092 (breakpoint_address_match): Likewise.
2093 (insert_single_step_breakpoint): Likewise.
2094 (pc_at_non_inline_function): Likewise.
2095 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
2096 * record.c (record_check_stopped_by_breakpoint): Likewise.
2097 * record.h (record_check_stopped_by_breakpoint): Likewise.
2098 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
2100 2017-10-25 Yao Qi <yao.qi@linaro.org>
2102 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
2103 regcache->arch () instead get_regcache_arch.
2104 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
2106 (aarch64_fbsd_store_inferior_registers): Likewise.
2107 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
2108 (store_gregs_to_thread): Likewise.
2109 (fetch_fpregs_from_thread): Likewise.
2110 (store_fpregs_to_thread): Likewise.
2111 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
2112 (aarch64_store_return_value): Likewise.
2113 (aarch64_software_single_step): Likewise.
2114 * aix-thread.c (aix_thread_wait): Likewise.
2115 (supply_reg32): Likewise.
2116 (supply_sprs64): Likewise.
2117 (supply_sprs32): Likewise.
2118 (fill_gprs64): Likewise.
2119 (fill_gprs32): Likewise.
2120 (fill_sprs64): Likewise.
2121 (fill_sprs32): Likewise.
2122 (store_regs_user_thread): Likewise.
2123 (store_regs_kernel_thread): Likewise.
2124 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
2125 (alphabsd_store_inferior_registers): Likewise.
2126 * alpha-tdep.c (alpha_extract_return_value): Likewise.
2127 (alpha_store_return_value): Likewise.
2128 (alpha_deal_with_atomic_sequence): Likewise.
2129 (alpha_next_pc): Likewise.
2130 (alpha_software_single_step): Likewise.
2131 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
2132 (amd64bsd_store_inferior_registers): Likewise.
2133 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
2135 (amd64_linux_store_inferior_registers): Likewise.
2136 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
2137 (amd64_collect_native_gregset): Likewise.
2138 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
2139 (amd64obsd_collect_uthread): Likewise.
2140 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
2141 (amd64_collect_fpregset): Likewise.
2142 (amd64_supply_fxsave): Likewise.
2143 (amd64_supply_xsave): Likewise.
2144 (amd64_collect_fxsave): Likewise.
2145 (amd64_collect_xsave): Likewise.
2146 * arc-tdep.c (arc_write_pc): Likewise.
2147 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
2148 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
2149 (arm_fbsd_store_inferior_registers): Likewise.
2150 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
2151 (store_vfp_regs): Likewise.
2152 (arm_linux_fetch_inferior_registers): Likewise.
2153 (arm_linux_store_inferior_registers): Likewise.
2154 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
2155 (arm_linux_sigreturn_next_pc): Likewise.
2156 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
2157 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
2158 (fetch_register): Likewise.
2159 (store_register): Likewise.
2160 * arm-tdep.c (arm_is_thumb): Likewise.
2161 (displaced_in_arm_mode): Likewise.
2162 (bx_write_pc): Likewise.
2163 (arm_get_next_pcs_addr_bits_remove): Likewise.
2164 (arm_software_single_step): Likewise.
2165 (arm_extract_return_value): Likewise.
2166 (arm_store_return_value): Likewise.
2167 (arm_write_pc): Likewise.
2168 * bfin-tdep.c (bfin_extract_return_value): Likewise.
2169 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
2170 (bsd_uthread_store_registers): Likewise.
2171 * core-regset.c (fetch_core_registers): Likewise.
2172 * corelow.c (get_core_registers): Likewise.
2173 * cris-tdep.c (cris_store_return_value): Likewise.
2174 (cris_extract_return_value): Likewise.
2175 (find_step_target): Likewise.
2176 (find_step_target): Likewise.
2177 (cris_software_single_step): Likewise.
2178 * ctf.c (ctf_fetch_registers): Likewise.
2179 * darwin-nat.c (cancel_breakpoint): Likewise.
2180 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
2181 * frv-tdep.c (frv_extract_return_value): Likewise.
2182 * ft32-tdep.c (ft32_store_return_value): Likewise.
2183 (ft32_extract_return_value): Likewise.
2184 * go32-nat.c (fetch_register): Likewise.
2185 (go32_fetch_registers): Likewise.
2186 (go32_store_registers): Likewise.
2187 (store_register): Likewise.
2188 * h8300-tdep.c (h8300_extract_return_value): Likewise.
2189 (h8300_store_return_value): Likewise.
2190 * hppa-linux-nat.c (fetch_register): Likewise.
2191 (store_register): Likewise.
2192 (hppa_linux_fetch_inferior_registers): Likewise.
2193 (hppa_linux_store_inferior_registers): Likewise.
2194 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
2195 (i386_darwin_store_inferior_registers): Likewise.
2196 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
2197 (gnu_store_registers): Likewise.
2198 * i386-linux-nat.c (fetch_register): Likewise.
2199 (store_register): Likewise.
2200 (supply_gregset): Likewise.
2201 (fill_gregset): Likewise.
2202 (i386_linux_fetch_inferior_registers): Likewise.
2203 (i386_linux_store_inferior_registers): Likewise.
2204 (i386_linux_resume): Likewise.
2205 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
2207 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
2208 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
2209 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
2210 (i386obsd_collect_uthread): Likewise.
2211 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
2212 (i386_supply_gregset): Likewise.
2213 (i386_collect_gregset): Likewise.
2214 (i386_supply_fpregset): Likewise.
2215 (i386_collect_fpregset): Likewise.
2216 (i386_mpx_bd_base): Likewise.
2217 * i386-v4-nat.c (supply_fpregset): Likewise.
2218 (fill_fpregset): Likewise.
2219 * i387-tdep.c (i387_supply_fsave): Likewise.
2220 (i387_collect_fsave): Likewise.
2221 (i387_supply_fxsave): Likewise.
2222 (i387_collect_fxsave): Likewise.
2223 (i387_supply_xsave): Likewise.
2224 (i387_collect_xsave): Likewise.
2225 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
2226 (ia64_linux_store_registers): Likewise.
2227 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
2228 (ia64_extract_return_value): Likewise.
2229 (ia64_store_return_value): Likewise.
2230 (find_func_descr): Likewise.
2231 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
2232 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
2233 (inf_ptrace_store_registers): Likewise.
2234 * infrun.c (use_displaced_stepping): Likewise.
2235 (displaced_step_prepare_throw): Likewise.
2237 (proceed): Likewise.
2238 (do_target_wait): Likewise.
2239 (adjust_pc_after_break): Likewise.
2240 (handle_inferior_event_1): Likewise.
2241 (handle_signal_stop): Likewise.
2242 (save_infcall_suspend_state): Likewise.
2243 (restore_infcall_suspend_state): Likewise.
2244 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
2245 * jit.c (jit_frame_prev_register): Likewise.
2246 * linux-nat.c (save_stop_reason): Likewise.
2247 (linux_nat_wait_1): Likewise.
2248 (resume_stopped_resumed_lwps): Likewise.
2249 * linux-record.c (record_linux_sockaddr): Likewise.
2250 (record_linux_msghdr): Likewise.
2251 (record_linux_system_call): Likewise.
2252 * linux-tdep.c (linux_collect_thread_registers): Likewise.
2253 * lm32-tdep.c (lm32_extract_return_value): Likewise.
2254 (lm32_store_return_value): Likewise.
2255 * m32c-tdep.c (m32c_read_flg): Likewise.
2256 (m32c_pseudo_register_read): Likewise.
2257 (m32c_pseudo_register_write): Likewise.
2258 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
2259 (m32r_linux_collect_gregset): Likewise.
2260 * m32r-tdep.c (m32r_store_return_value): Likewise.
2261 (m32r_extract_return_value): Likewise.
2262 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
2263 (m68kbsd_collect_fpregset): Likewise.
2264 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
2265 * m68k-linux-nat.c (fetch_register): Likewise.
2266 (old_fetch_inferior_registers): Likewise.
2267 (old_store_inferior_registers): Likewise.
2268 (store_regs): Likewise.
2269 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
2270 (m68k_svr4_store_return_value): Likewise.
2271 * m88k-tdep.c (m88k_store_arguments): Likewise.
2272 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
2273 (mi_cmd_data_write_register_values): Likewise.
2274 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
2275 (mips_fbsd_store_inferior_registers): Likewise.
2276 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
2277 (mips_fbsd_supply_gregs): Likewise.
2278 (mips_fbsd_collect_fpregs): Likewise.
2279 (mips_fbsd_collect_gregs): Likewise.
2280 (mips_fbsd_supply_fpregset): Likewise.
2281 (mips_fbsd_collect_fpregset): Likewise.
2282 (mips_fbsd_supply_gregset): Likewise.
2283 (mips_fbsd_collect_gregset): Likewise.
2284 * mips-linux-nat.c (supply_gregset): Likewise.
2285 (fill_gregset): Likewise.
2286 (supply_fpregset): Likewise.
2287 (fill_fpregset): Likewise.
2288 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
2289 (mips_fill_gregset): Likewise.
2290 (mips_supply_fpregset): Likewise.
2291 (mips_fill_fpregset): Likewise.
2292 (mips64_supply_gregset): Likewise.
2293 (micromips_linux_sigframe_validate): Likewise.
2294 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
2295 (mipsnbsd_fetch_inferior_registers): Likewise.
2296 (mipsnbsd_store_inferior_registers): Likewise.
2297 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
2298 (mipsnbsd_supply_gregset): Likewise.
2299 (mipsnbsd_iterate_over_regset_sections): Likewise.
2300 (mipsnbsd_supply_reg): Likewise.
2301 (mipsnbsd_supply_fpreg): Likewise.
2302 * mips-tdep.c (mips_in_frame_stub): Likewise.
2303 (mips_dummy_id): Likewise.
2304 (is_octeon_bbit_op): Likewise.
2305 (micromips_bc1_pc): Likewise.
2306 (extended_mips16_next_pc): Likewise.
2307 (mips16_next_pc): Likewise.
2308 (deal_with_atomic_sequence): Likewise.
2309 * moxie-tdep.c (moxie_process_readu): Likewise.
2310 * nios2-tdep.c (nios2_get_next_pc): Likewise.
2311 * nto-procfs.c (procfs_store_registers): Likewise.
2312 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
2313 (ppcfbsd_store_inferior_registers): Likewise.
2314 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
2315 (fetch_altivec_register): Likewise.
2316 (get_spe_registers): Likewise.
2317 (fetch_spe_register): Likewise.
2318 (fetch_altivec_registers): Likewise.
2319 (fetch_all_gp_regs): Likewise.
2320 (fetch_all_fp_regs): Likewise.
2321 (store_vsx_register): Likewise.
2322 (store_altivec_register): Likewise.
2323 (set_spe_registers): Likewise.
2324 (store_spe_register): Likewise.
2325 (store_altivec_registers): Likewise.
2326 (store_all_gp_regs): Likewise.
2327 (store_all_fp_regs): Likewise.
2328 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
2329 (ppc_linux_collect_gregset): Likewise.
2330 (ppc_canonicalize_syscall): Likewise.
2331 (ppc_linux_record_signal): Likewise.
2332 (ppu2spu_prev_register): Likewise.
2333 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
2334 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
2335 (ppcobsd_store_registers): Likewise.
2336 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
2338 (ppc_ravenscar_generic_store_registers): Likewise.
2339 * procfs.c (procfs_fetch_registers): Likewise.
2340 (procfs_store_registers): Likewise.
2341 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
2342 (ravenscar_store_registers): Likewise.
2343 (ravenscar_prepare_to_store): Likewise.
2344 * record-btrace.c (record_btrace_fetch_registers): Likewise.
2345 * record-full.c (record_full_wait_1): Likewise.
2346 (record_full_registers_change): Likewise.
2347 (record_full_store_registers): Likewise.
2348 (record_full_core_fetch_registers): Likewise.
2349 (record_full_save): Likewise.
2350 (record_full_goto_insn): Likewise.
2351 * regcache.c (regcache_register_size): Likewise.
2352 (get_regcache_arch): Remove.
2353 (regcache_read_pc): Likewise.
2354 * regcache.h (get_regcache_arch): Remove.
2355 * remote-sim.c (gdbsim_fetch_register): Likewise.
2356 (gdbsim_store_register): Likewise.
2357 * remote.c (fetch_register_using_p): Likewise.
2358 (send_g_packet): Likewise.
2359 (remote_prepare_to_store): Likewise.
2360 (store_registers_using_G): Likewise.
2361 * reverse.c (save_bookmark_command): Likewise.
2362 (goto_bookmark_command): Likewise.
2363 * rs6000-aix-tdep.c (branch_dest): Likewise.
2364 * rs6000-nat.c (rs6000_ptrace64): Likewise.
2365 (fetch_register): Likewise.
2366 * rs6000-tdep.c (ppc_supply_reg): Likewise.
2367 (ppc_collect_reg): Likewise.
2368 (ppc_collect_gregset): Likewise.
2369 (ppc_collect_fpregset): Likewise.
2370 (ppc_collect_vsxregset): Likewise.
2371 (ppc_collect_vrregset): Likewise.
2372 (ppc_displaced_step_hw_singlestep): Likewise.
2373 (rs6000_pseudo_register_read): Likewise.
2374 (rs6000_pseudo_register_write): Likewise.
2375 * s390-linux-nat.c (supply_gregset): Likewise.
2376 (fill_gregset): Likewise.
2377 (s390_linux_fetch_inferior_registers): Likewise.
2378 * s390-linux-tdep.c (s390_write_pc): Likewise.
2379 (s390_software_single_step): Likewise.
2380 (s390_all_but_pc_registers_record): Likewise.
2381 (s390_linux_syscall_record): Likewise.
2382 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
2383 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
2384 (shnbsd_store_inferior_registers): Likewise.
2385 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
2386 (sh_extract_return_value_fpu): Likewise.
2387 (sh_store_return_value_nofpu): Likewise.
2388 (sh_corefile_supply_regset): Likewise.
2389 (sh_corefile_collect_regset): Likewise.
2390 * sh64-tdep.c (sh64_extract_return_value): Likewise.
2391 (sh64_store_return_value): Likewise.
2392 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
2393 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
2394 (sparc_store_inferior_registers): Likewise.
2395 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
2396 (sparc_ravenscar_prepare_to_store): Likewise.
2397 * sparc-tdep.c (sparc32_store_arguments): Likewise.
2398 (sparc_analyze_control_transfer): Likewise.
2399 (sparc_step_trap): Likewise.
2400 (sparc_software_single_step): Likewise.
2401 (sparc32_gdbarch_init): Likewise.
2402 (sparc_supply_rwindow): Likewise.
2403 (sparc_collect_rwindow): Likewise.
2404 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
2405 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
2406 (sparc64nbsd_collect_gregset): Likewise.
2407 (sparc64nbsd_supply_fpregset): Likewise.
2408 (sparc64nbsd_collect_fpregset): Likewise.
2409 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
2410 (sparc64_supply_gregset): Likewise.
2411 (sparc64_collect_gregset): Likewise.
2412 (sparc64_supply_fpregset): Likewise.
2413 (sparc64_collect_fpregset): Likewise.
2414 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
2415 * spu-tdep.c (spu_unwind_sp): Likewise.
2416 (spu2ppu_prev_register): Likewise.
2417 (spu_memory_remove_breakpoint): Likewise.
2418 * stack.c (return_command): Likewise.
2419 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
2420 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
2421 * tracefile.c (trace_save_ctf): Likewise.
2422 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
2423 (do_windows_store_inferior_registers): Likewise.
2424 (windows_resume): Likewise.
2425 * xtensa-linux-nat.c (fill_gregset): Likewise.
2426 (supply_gregset_reg): Likewise.
2427 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
2428 (xtensa_register_read_masked): Likewise.
2429 (xtensa_supply_gregset): Likewise.
2430 (xtensa_extract_return_value): Likewise.
2431 (xtensa_store_return_value): Likewise.
2433 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
2435 * doublest.c (floatformat_from_string): New function.
2436 * doublest.h (floatformat_from_string): Add prototype.
2438 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
2439 (OP_FLOAT): ... this.
2440 * expression.h: Do not include "doublest.h".
2441 (union exp_element): Replace doubleconst and decfloatconst by
2442 new element floatconst.
2443 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
2444 (ada_evaluate_subexp): Likewise.
2445 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
2446 OP_DOUBLE and OP_DECFLOAT.
2447 * expprint.c (print_subexp_standard): Likewise.
2448 (dump_subexp_body_standard): Likewise.
2449 * breakpoint.c (watchpoint_exp_is_const): Likewise.
2451 * parse.c: Include "dfp.h".
2452 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2453 (write_exp_elt_floatcst): New function.
2454 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
2456 (operator_check_standard): Likewise.
2457 (parse_float): Do not accept suffix. Take type as input. Return bool.
2458 Return target format buffer instead of host DOUBLEST.
2459 Use floatformat_from_string and decimal_from_string to parse
2460 either binary or decimal floating-point types.
2461 (parse_c_float): Remove.
2462 * parser-defs.h: Do not include "doublest.h".
2463 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2464 (write_exp_elt_floatcst): Add prototype.
2465 (parse_float): Update prototype.
2466 (parse_c_float): Remove.
2468 * c-exp.y: Do not include "dfp.h".
2469 (typed_val_float): Use byte buffer instead of DOUBLEST.
2470 (typed_val_decfloat): Remove.
2472 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2473 (parse_number): Update to new parse_float interface.
2474 Parse suffixes and determine type before calling parse_float.
2475 Handle decimal and binary FP types the same way.
2477 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2478 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
2479 (parse_number): Update to new parse_float interface.
2480 Parse suffixes and determine type before calling parse_float.
2482 * f-exp.y: Replace dval by typed_val_float.
2483 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2484 (parse_number): Use parse_float instead of atof.
2486 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2487 (parse_go_float): Remove.
2488 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2489 (parse_number): Call parse_float instead of parse_go_float.
2490 Parse suffixes and determine type before calling parse_float.
2492 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2493 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2494 (parse_number): Update to new parse_float interface.
2495 Parse suffixes and determine type before calling parse_float.
2497 * m2-exp.y: Replace dval by byte buffer val.
2498 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2499 (parse_number): Call parse_float instead of atof.
2501 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2502 (lex_number): Call parse_float instead of strtod.
2503 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
2504 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
2505 Use write_exp_elt_floatcst.
2506 (unit_testing): Remove static variable.
2507 (rust_type): Do not check unit_testing.
2508 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
2510 * ada-exp.y (type_float, type_double): Remove.
2511 (typed_val_float): Use byte buffer instead of DOUBLEST.
2512 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2513 * ada-lex.l (processReal): Use parse_float instead of sscanf.
2515 2017-10-25 Alan Hayward <alan.hayward@arm.com>
2517 * aarch64-tdep.h (enum aarch64_regnum): Remove.
2518 * arch/aarch64.h: New file.
2520 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2522 * dfp.h (decimal_from_string): Use const reference for argument.
2523 * dfp.c (decimal_from_string): Likewise.
2525 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2527 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
2528 * sh64-tdep.c (sh64_do_fp_register): Likewise.
2529 * mips-tdep.c (mips_print_fp_register): Likewise.
2531 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2533 * common/format.h (enum argclass): Replace decfloat_arg by
2534 dec32float_arg, dec64float_arg, and dec128float_arg.
2535 * common/format.c (parse_format_string): Update to return
2536 new decimal float argument classes.
2538 * printcmd.c (printf_decfloat): Rename to ...
2539 (printf_floating): ... this. Add argclass argument, and use it
2540 instead of parsing the format string again. Add support for
2541 binary floating-point values, using floatformat_to_string.
2542 Convert value to the target format if it doesn't already match.
2543 (ui_printf): Call printf_floating instead of printf_decfloat,
2544 also for double_arg / long_double_arg. Pass argclass.
2546 * dfp.c (decimal_to_string): Add format string argument.
2547 * dfp.h (decimal_to_string): Likewise.
2549 * doublest.c (floatformat_to_string): Add format string argument.
2550 * doublest.h (floatformat_to_string): Likewise.
2552 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2554 * doublest.c (floatformat_precision): New routine.
2555 (floatformat_to_string): Likewise.
2556 * doublest.c (floatformat_to_string): Add prototype.
2558 * printcmd.c (print_scalar_formatted): Only call print_floating
2559 on floating-point types.
2560 * valprint.c: Do not include "floatformat.h".
2561 (generic_val_print_decfloat): Remove.
2562 (generic_val_print): Call generic_val_print_float for both
2563 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
2564 (print_floating): Use floatformat_to_string. Handle decimal float.
2565 (print_decimal_floating): Remove, merge into floatformat_to_string.
2566 * value.h (print_decimal_floating): Remove.
2568 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
2570 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2572 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
2574 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2576 * memattr.h: Don't include vec.h.
2577 (struct mem_attrib): Initialize fields.
2578 <unknown>: New static method.
2579 (struct mem_region): Add constructors, operator<, initialize
2581 * memattr.c: Include algorithm.
2582 (default_mem_attrib, unknown_mem_attrib): Remove.
2583 (user_mem_region_list): New global.
2584 (target_mem_region_list, mem_region_list): Change type to
2585 std::vector<mem_region>.
2586 (mem_use_target): Now a function.
2587 (target_mem_regions_valid): Change type to bool.
2588 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
2589 (require_user_regions): Adjust.
2590 (require_target_regions): Adjust.
2591 (create_mem_region): Adjust.
2592 (lookup_mem_region): Adjust.
2593 (invalidate_target_mem_regions): Adjust.
2594 (mem_clear): Rename to...
2595 (user_mem_clear): ... this, and adjust.
2596 (mem_command): Adjust.
2597 (info_mem_command): Adjust.
2598 (mem_enable, enable_mem_command, mem_disable,
2599 disable_mem_command): Adjust.
2600 (mem_delete): Adjust.
2601 (delete_mem_command): Adjust.
2602 * memory-map.h (parse_memory_map): Return an std::vector.
2603 * memory-map.c (parse_memory_map): Likewise.
2604 (struct memory_map_parsing_data): Add constructor.
2605 <memory_map>: Point to std::vector.
2606 (memory_map_start_memory): Adjust.
2607 (memory_map_end_memory): Adjust.
2608 (memory_map_end_property): Adjust.
2609 (clear_result): Remove.
2610 * remote.c (remote_memory_map): Return an std::vector.
2611 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
2613 (target_debug_print_mem_region_vector): New.
2614 * target-delegates.c: Regenerate.
2615 * target.h (mem_region_vector): New typedef.
2616 (to_memory_map): Return mem_region_vector.
2617 (target_memory_map): Return an std::vector.
2618 * target.c (target_memory_map): Return an std::vector.
2619 (flash_erase_command): Adjust.
2621 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2623 * memory-map.c (struct memory_map_parsing_data) <property_name>:
2624 Change type to std::string.
2625 (memory_map_start_property): Adjust.
2626 (memory_map_end_property): Adjust.
2628 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2630 * infrun.h: Include common/byte-vector.h.
2631 (struct displaced_step_closure): New struct.
2632 (struct buf_displaced_step_closure): New struct.
2633 * infrun.c (displaced_step_closure::~displaced_step_closure):
2634 Provide default implementation.
2635 (displaced_step_clear): Deallocate step closure with delete.
2636 * aarch64-tdep.c (displaced_step_closure): Rename to ...
2637 (aarch64_displaced_step_closure): ... this, extend
2638 displaced_step_closure.
2639 (aarch64_displaced_step_data) <dsc>: Change type to
2640 aarch64_displaced_step_closure.
2641 (aarch64_displaced_step_copy_insn): Adjust to type change, use
2643 (aarch64_displaced_step_fixup): Add cast for displaced step
2645 * amd64-tdep.c (displaced_step_closure): Rename to ...
2646 (amd64_displaced_step_closure): ... this, extend
2647 displaced_step_closure.
2648 <insn_buf>: Change type to std::vector<gdb_byte>.
2650 (fixup_riprel): Change type of DSC parameter, adjust to type
2652 (fixup_displaced_copy): Change type of DSC parameter.
2653 (amd64_displaced_step_copy_insn): Instantiate
2654 amd64_displaced_step_closure.
2655 (amd64_displaced_step_fixup): Add cast for closure type, adjust
2656 to type change of insn_buf.
2657 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
2659 (arm_linux_copy_svc): Likewise.
2660 (cleanup_kernel_helper_return): Likewise.
2661 (arm_catch_kernel_helper_return): Likewise.
2662 (arm_linux_displaced_step_copy_insn): Instantiate
2663 arm_displaced_step_closure.
2664 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
2665 (displaced_read_reg): Change type of parameter DSC.
2666 (branch_write_pc): Likewise.
2667 (load_write_pc): Likewise.
2668 (alu_write_pc): Likewise.
2669 (displaced_write_reg): Likewise.
2670 (arm_copy_unmodified): Likewise.
2671 (thumb_copy_unmodified_32bit): Likewise.
2672 (thumb_copy_unmodified_16bit): Likewise.
2673 (cleanup_preload): Likewise.
2674 (install_preload): Likewise.
2675 (arm_copy_preload): Likewise.
2676 (thumb2_copy_preload): Likewise.
2677 (install_preload_reg): Likewise.
2678 (arm_copy_preload_reg): Likewise.
2679 (cleanup_copro_load_store): Likewise.
2680 (install_copro_load_store): Likewise.
2681 (arm_copy_copro_load_store) Likewise.
2682 (thumb2_copy_copro_load_store): Likewise.
2683 (cleanup_branch): Likewise.
2684 (install_b_bl_blx): Likewise.
2685 (arm_copy_b_bl_blx): Likewise.
2686 (thumb2_copy_b_bl_blx): Likewise.
2687 (thumb_copy_b): Likewise.
2688 (install_bx_blx_reg): Likewise.
2689 (arm_copy_bx_blx_reg): Likewise.
2690 (thumb_copy_bx_blx_reg): Likewise.
2691 (cleanup_alu_imm): Likewise.
2692 (arm_copy_alu_imm): Likewise.
2693 (thumb2_copy_alu_imm): Likewise.
2694 (cleanup_alu_reg): Likewise.
2695 (install_alu_reg): Likewise.
2696 (arm_copy_alu_reg): Likewise.
2697 (thumb_copy_alu_reg): Likewise.
2698 (cleanup_alu_shifted_reg): Likewise.
2699 (install_alu_shifted_reg): Likewise.
2700 (arm_copy_alu_shifted_reg): Likewise.
2701 (cleanup_load): Likewise.
2702 (cleanup_store): Likewise.
2703 (arm_copy_extra_ld_st): Likewise.
2704 (install_load_store): Likewise.
2705 (thumb2_copy_load_literal): Likewise.
2706 (thumb2_copy_load_reg_imm): Likewise.
2707 (arm_copy_ldr_str_ldrb_strb): Likewise.
2708 (cleanup_block_load_all): Likewise.
2709 (cleanup_block_store_pc): Likewise.
2710 (cleanup_block_load_pc): Likewise.
2711 (arm_copy_block_xfer): Likewise.
2712 (thumb2_copy_block_xfer): Likewise.
2713 (cleanup_svc): Likewise.
2714 (install_svc): Likewise.
2715 (arm_copy_svc): Likewise.
2716 (thumb_copy_svc): Likewise.
2717 (arm_copy_undef): Likewise.
2718 (thumb_32bit_copy_undef): Likewise.
2719 (arm_copy_unpred): Likewise.
2720 (arm_decode_misc_memhint_neon): Likewise.
2721 (arm_decode_unconditional): Likewise.
2722 (arm_decode_miscellaneous): Likewise.
2723 (arm_decode_dp_misc): Likewise.
2724 (arm_decode_ld_st_word_ubyte): Likewise.
2725 (arm_decode_media): Likewise.
2726 (arm_decode_b_bl_ldmstm): Likewise.
2727 (arm_decode_ext_reg_ld_st): Likewise.
2728 (thumb2_decode_dp_shift_reg): Likewise.
2729 (thumb2_decode_ext_reg_ld_st): Likewise.
2730 (arm_decode_svc_copro): Likewise.
2731 (thumb2_decode_svc_copro): Likewise.
2732 (install_pc_relative): Likewise.
2733 (thumb_copy_pc_relative_16bit): Likewise.
2734 (thumb_decode_pc_relative_16bit): Likewise.
2735 (thumb_copy_pc_relative_32bit): Likewise.
2736 (thumb_copy_16bit_ldr_literal): Likewise.
2737 (thumb_copy_cbnz_cbz): Likewise.
2738 (thumb2_copy_table_branch): Likewise.
2739 (cleanup_pop_pc_16bit_all): Likewise.
2740 (thumb_copy_pop_pc_16bit): Likewise.
2741 (thumb_process_displaced_16bit_insn): Likewise.
2742 (decode_thumb_32bit_ld_mem_hints): Likewise.
2743 (thumb_process_displaced_32bit_insn): Likewise.
2744 (thumb_process_displaced_insn): Likewise.
2745 (arm_process_displaced_insn): Likewise.
2746 (arm_displaced_init_closure): Likewise.
2747 (arm_displaced_step_fixup): Add cast for closure.
2748 * arm-tdep.h: Include infrun.h.
2749 (displaced_step_closure): Rename to ...
2750 (arm_displaced_step_closure): ... this, extend
2751 displaced_step_closure.
2752 <u::svc::copy_svc_os>: Change type of parameter DSC.
2753 <cleanup>: Likewise.
2754 (arm_process_displaced_insn): Likewise.
2755 (arm_displaced_init_closure): Likewise.
2756 (displaced_read_reg): Likewise.
2757 (displaced_write_reg): Likewise.
2758 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2760 * i386-tdep.h: Include infrun.h.
2761 (i386_displaced_step_closure): New typedef.
2762 * i386-tdep.c (i386_displaced_step_copy_insn): Use
2763 i386_displaced_step_closure.
2764 (i386_displaced_step_fixup): Adjust.
2765 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
2766 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
2768 (ppc_displaced_step_fixup): Adjust.
2769 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
2770 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
2772 (s390_displaced_step_fixup): Adjust.
2774 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2776 * interps.h (interp_resume, interp_suspend, interp_set_temp):
2777 Remove declarations.
2779 2017-10-20 Tom Tromey <tom@tromey.com>
2781 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
2783 (gdb_bfd_record_inclusion): Update.
2784 (bfdp): Remove typedef.
2786 2017-10-20 Tom Tromey <tom@tromey.com>
2788 * gdb_bfd.c (gdb_bfd_ref): Use new.
2789 (struct gdb_bfd_data): Add constructor, destructor, and member
2791 (gdb_bfd_unref): Use delete.
2793 2017-10-20 Tom Tromey <tom@tromey.com>
2795 * exec.c (exec_file_attach): Use new_bfd_ref.
2796 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
2797 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
2798 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
2800 * gdb_bfd.h (new_bfd_ref): New function.
2802 2017-10-20 Pedro Alves <palves@redhat.com>
2804 * main.c (captured_command_loop): Add attribute noinline.
2806 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
2808 * interps.c (struct interp_factory): Add constructor.
2809 (interp_factory_p): Remove typedef.
2810 (DEF_VEC_P(interp_factory_p)): Remove.
2811 (interpreter_factories): Change type to std::vector.
2812 (interp_factory_register): Adjust.
2813 (interp_lookup): Adjust.
2814 (interpreter_completer): Adjust.
2816 2017-10-19 Tom Tromey <tom@tromey.com>
2818 * break-catch-syscall.c (catch_syscall_completer): Use
2819 std::string, gdb::unique_xmalloc_ptr.
2821 2017-10-19 Tom Tromey <tom@tromey.com>
2823 * infcall.c (call_function_by_hand_dummy): Use std::string.
2825 2017-10-19 Tom Tromey <tom@tromey.com>
2827 * mi/mi-main.c (mi_cmd_execute): Update.
2828 * top.h (prepare_execute_command): Return scoped_value_mark.
2829 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
2830 Add move constructor.
2831 * top.c (prepare_execute_command): Return scoped_value_mark.
2832 (execute_command): Update.
2834 2017-10-19 Pedro Alves <palves@redhat.com>
2836 * xml-support.c (xml_fetch_content_from_file): Check fread's
2839 2017-10-19 Pedro Alves <palves@redhat.com>
2841 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
2843 (handle_error_fd): New function.
2844 (ser_base_async): Add/delete an event loop file handler for
2847 2017-10-19 Pedro Alves <palves@redhat.com>
2849 * xml-support.c (xml_fetch_content_from_file): Don't read in
2850 chunks. Instead use fseek to determine the file's size, and read
2853 2017-11-18 Keith Seitz <keiths@redhat.com>
2855 * c-exp.y (oper): Canonicalize conversion operators of user-defined
2857 Add whitespace to front of type name.
2859 2017-10-18 Keith Seitz <keiths@redhat.com>
2861 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
2862 DW_AT_accessibility.
2864 2017-10-18 Yao Qi <yao.qi@linaro.org>
2866 * features/tic6x-c62x-linux.c: Remove.
2868 2017-10-17 Tom Tromey <tom@tromey.com>
2870 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
2871 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
2872 (do_mixed_source_and_assembly): Likewise.
2874 2017-10-17 Tom Tromey <tom@tromey.com>
2876 * regcache.c (regcache::xfer_part): Remove assertion.
2878 2017-10-17 Pedro Alves <palves@redhat.com>
2880 * xml-support.c (xml_fetch_content_from_file): Call
2881 unique_ptr::release() instead unique_ptr::get() when passing
2884 2017-10-17 Yao Qi <yao.qi@linaro.org>
2886 * regcache.c (regcache::xfer_part): Remove parameters read and
2887 write, add parameter is_raw. All callers are updated.
2889 2017-10-16 Keith Seitz <keiths@redhat.com>
2891 * c-typeprint.c (enum access_specifier): Moved here from
2893 (output_access_specifier): New function.
2894 (c_type_print_base): Consider typedefs when assessing
2895 whether access labels are needed.
2896 Use output_access_specifier as needed.
2897 Output access specifier for typedefs, if needed.
2898 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
2899 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
2901 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
2904 2017-10-16 Tom Tromey <tom@tromey.com>
2906 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
2907 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
2908 * target.c (target_fileio_read_stralloc): Update.
2909 * sparc64-tdep.c (adi_is_addr_mapped): Update.
2910 * target.h (target_fileio_read_stralloc): Return
2913 2017-10-16 Tom Tromey <tom@tromey.com>
2915 * xml-syscall.c (xml_init_syscalls_info): Update.
2916 * xml-support.c (xinclude_start_include): Update.
2917 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
2918 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
2919 (xml_fetch_content_from_file): Likewise.
2920 * osdata.c (get_osdata): Update.
2921 * target.h (target_read_stralloc, target_get_osdata): Return
2923 * solib-aix.c (solib_aix_get_library_list): Update.
2924 * solib-target.c (solib_target_current_sos): Update.
2925 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
2926 * xml-tdesc.c (fetch_available_features_from_target): Update.
2927 (target_fetch_description_xml): Update.
2928 (file_read_description_xml): Update.
2929 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
2930 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
2931 (remote_pid_to_exec_file): Update.
2932 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
2933 (target_get_osdata): Likewise.
2935 2017-10-16 Tom Tromey <tom@tromey.com>
2937 * remote.c (remote_register_number_and_offset): Use std::vector.
2938 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
2939 (putpkt_binary): Use gdb::def_vector.
2940 (compare_sections_command): Use gdb::byte_vector.
2942 2017-10-16 Tom Tromey <tom@tromey.com>
2944 * ppc-linux-nat.c (hwdebug_insert_point): Use
2945 gdb::unique_xmalloc_ptr, XDUP.
2947 2017-10-16 Tom Tromey <tom@tromey.com>
2949 * probe.c (parse_probes): Use std::string.
2950 (info_probes_for_ops, enable_probes_command)
2951 (disable_probes_command): Remove cleanups.
2953 2017-10-16 Tom Tromey <tom@tromey.com>
2955 * buildsym.c (block_compar): Remove.
2956 (end_symtab_get_static_block): Use std::vector.
2958 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
2960 * memrange.h (struct mem_range): Define operator< and operator==.
2961 (mem_range_s): Remove.
2962 (DEF_VEC_O (mem_range_s)): Remove.
2963 (normalize_mem_ranges): Change parameter type to std::vector.
2964 * memrange.c (compare_mem_ranges): Remove.
2965 (normalize_mem_ranges): Change parameter type to std::vector,
2966 adjust to vector change.
2967 * exec.c (section_table_available_memory): Return vector, remove
2969 (section_table_read_available_memory): Adjust to std::vector
2971 * remote.c (remote_read_bytes): Adjust to std::vector
2973 * tracepoint.h (traceframe_available_memory): Change parameter
2974 type to std::vector.
2975 * tracepoint.c (traceframe_available_memory): Change parameter
2976 type to std::vector, adjust.
2977 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
2979 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2980 unittests/memrange-selftests.c.
2981 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
2982 * gdb/unittests/memrange-selftests.c: New file.
2984 2017-10-16 Pedro Alves <palves@redhat.com>
2986 * elfread.c (probe_key_free): Rename range-for variable.
2987 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
2988 (find_probe_by_pc, collect_probes): Rename range-for variable.
2990 2017-10-16 Yao Qi <yao.qi@linaro.org>
2992 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
2993 * features/tic6x-c62x.c: Remove.
2994 * features/tic6x-c64x-linux.c: Remove.
2995 * features/tic6x-c64x.c: Remove.
2996 * features/tic6x-c64xp-linux.c: Remove.
2997 * features/tic6x-c64xp.c: Remove.
2998 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
2999 initialize_tdesc_tic6x_*_linux functions.
3000 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
3001 initialize_tdesc_tic6x_* functions.
3003 2017-10-16 Yao Qi <yao.qi@linaro.org>
3005 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
3007 * regformats/tic6x-c62x.dat: Remove.
3008 * regformats/tic6x-c64x.dat: Remove.
3009 * regformats/tic6x-c64xp.dat: Remove.
3011 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
3013 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
3014 (the !HAVE_LIBEXPAT version).
3016 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3018 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
3021 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3023 * target.h: Include tracepoint.h.
3024 (enum trace_find_type): Move to tracepoint.h.
3025 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
3026 * tracepoint.h: Don't include target.h
3027 (enum trace_find_type): Move from target.h.
3028 (parse_traceframe_info): Return a unique ptr.
3029 * tracepoint.c (current_traceframe_info): Change type to unique
3031 (free_traceframe_info): Remove.
3032 (clear_traceframe_info): Don't manually free
3033 current_traceframe_info.
3034 (free_result): Remove.
3035 (parse_traceframe_info): Return a unique ptr.
3036 (get_traceframe_info): Adjust to unique ptr.
3037 * ctf.c (ctf_traceframe_info): Return a unique ptr.
3038 * remote.c (remote_traceframe_info): Return a unique ptr.
3039 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
3041 * target-debug.h (target_debug_print_traceframe_info_up): New
3043 * target-delegates.c: Regenerate.
3045 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3047 * memrange.h (struct mem_range): Add constructors.
3048 * tracepoint.h (struct traceframe_info) <memory>: Change type to
3049 std::vector<mem_range>.
3050 * tracepoint.c (free_traceframe_info): Don't manually free
3052 (traceframe_info_start_memory): Adjust to vector change.
3053 (traceframe_available_memory): Likewise.
3054 * tracefile-tfile.c (build_traceframe_info): Likewise.
3055 * ctf.c (ctf_traceframe_info): Likewise.
3057 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3059 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
3061 * tracepoint.c (free_traceframe_info): Deallocate with delete.
3062 (traceframe_info_start_tvar): Adjust to vector change.
3063 (parse_traceframe_info): Allocate with new.
3064 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
3066 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
3068 tfile_traceframe_info): Allocate with new.
3069 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
3072 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
3074 * tracepoint.c (traceframe_info): Rename to...
3075 (current_traceframe_info): ...this.
3076 (clear_traceframe_info): Adjust.
3077 (get_traceframe_info): Adjust.
3079 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3081 * nat/linux-osdata.c: Include algorithm.
3082 (compare_processes): Remove.
3083 (struct pid_pgid_entry): New struct.
3084 (linux_xfer_osdata_processgroups): Use std::vector instead of
3087 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
3089 * objfiles.h: Don't include symfile.h.
3090 (struct partial_symbol): Remove forward-declaration.
3091 (struct objfile) <global_psymbols, static_psymbols>: Change type
3092 to std::vector<partial_symbol *>.
3093 * objfiles.c (objfile::objfile): Don't memset those fields.
3094 (objfile::~objfile): Don't free those fields.
3095 * psympriv.h (struct psymbol_allocation_list): Remove
3096 forward-declaration.
3097 (add_psymbol_to_list): Change psymbol_allocation_list parameter
3099 (start_psymtab_common): Change parameters to std::vector.
3100 * psymtab.c: Include algorithm.
3101 (require_partial_symbols): Call shrink_to_fit.
3102 (find_pc_sect_psymbol): Adjust to vector change.
3103 (match_partial_symbol): Likewise.
3104 (lookup_partial_symbol): Likewise.
3105 (psym_relocate): Likewise.
3106 (dump_psymtab): Likewise.
3107 (recursively_search_psymtabs): Likewise.
3108 (compare_psymbols): Remove.
3109 (sort_pst_symbols): Adjust to vector change.
3110 (start_psymtab_common): Likewise.
3111 (end_psymtab_common): Likewise.
3112 (psymbol_bcache_full): De-constify return value.
3113 (add_psymbol_to_bcache): Likewise.
3114 (extend_psymbol_list): Remove.
3115 (append_psymbol_to_list): Adjust to vector change.
3116 (add_psymbol_to_list): Likewise.
3117 (init_psymbol_list): Likewise.
3118 (maintenance_info_psymtabs): Likewise.
3119 (maintenance_check_psymtabs): Likewise.
3120 * symfile.h (struct psymbol_allocation_list): Remove.
3121 * symfile.c (reread_symbols): Adjust to vector change.
3122 * dbxread.c (start_psymtab): Change type of parameters.
3123 (dbx_symfile_read): Adjust to vector change.
3124 (read_dbx_symtab): Likewise.
3125 (start_psymtab): Change type of parameters.
3126 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
3127 (create_partial_symtab): Likewise.
3128 (add_partial_symbol): Likewise.
3129 (write_one_signatured_type): Likewise.
3130 (recursively_write_psymbols): Likewise.
3131 * mdebugread.c (parse_partial_symbols): Likewise.
3132 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
3133 (scan_xcoff_symtab): Adjust to vector change.
3134 (xcoff_initial_scan): Likewise.
3136 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
3138 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
3140 2017-10-13 Yao Qi <yao.qi@linaro.org>
3142 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
3143 Remove s390x-*-expedite, add s390x-expedite.
3145 2017-10-13 Yao Qi <yao.qi@linaro.org>
3147 * features/s390-gs-linux64.c: Regenerated.
3148 * features/s390x-gs-linux64.c: Regenerated.
3150 2017-10-13 Tom Tromey <tom@tromey.com>
3152 * compile/compile-object-run.c (do_module_cleanup): Use delete.
3153 * solib.c (update_solib_list, reload_shared_libraries_1): Use
3155 * symfile.c (symbol_file_add_with_addrs): Use new.
3156 (symbol_file_add_separate): Update comment.
3157 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
3158 * jit.c (jit_object_close_impl): Use new.
3159 (jit_unregister_code): Use delete.
3160 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
3161 (~objfile): Rename from free_objfile.
3162 (free_objfile_separate_debug, do_free_objfile_cleanup)
3163 (free_all_objfiles, objfile_purge_solibs): Use delete.
3164 * objfiles.h (struct objfile): Add constructor and destructor.
3165 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
3166 (allocate_objfile, free_objfile): Don't declare.
3167 (struct objstats): Add initializers.
3169 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3171 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
3172 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
3173 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
3174 * gdbarch.h: Regenerate.
3175 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
3177 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
3178 (i386_displaced_step_fixup): Adjust comment.
3179 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
3181 2017-10-12 Tom Tromey <tom@tromey.com>
3183 * prologue-value.h (pv_area::store_would_trash): Return bool.
3184 (pv_area::find_reg): Likewise.
3185 * prologue-value.c (pv_area::store_would_trash): Return bool.
3186 (pv_area::find_reg): Likewise.
3188 2017-10-12 Tom Tromey <tom@tromey.com>
3190 * s390-linux-tdep.c (s390_store, s390_load)
3191 (s390_check_for_saved, s390_analyze_prologue): Update.
3192 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
3193 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
3194 * prologue-value.h (class pv_area): Move from prologue-value.c.
3195 Change names of members. Add constructor, destructor, member
3197 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
3198 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
3199 (pv_area_fetch, pv_area_scan): Don't declare.
3200 * prologue-value.c (struct pv_area::area_entry): Now member of
3202 (struct pv_area): Move to prologue-value.h.
3203 (pv_area::pv_area): Rename from make_pv_area.
3204 (pv_area::~pv_area): Rename from free_pv_area.
3205 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
3206 (clear_entries, find_entry, overlaps, store_would_trash, store)
3207 (fetch, find_reg, scan): Now member of pv_area.
3208 Remove "area" argument. Update.
3209 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
3211 * mn10300-tdep.c (push_reg, check_for_saved)
3212 (mn10300_analyze_prologue): Update.
3213 * mep-tdep.c (is_arg_spill, check_for_saved)
3214 (mep_analyze_prologue): Update.
3215 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
3216 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
3217 (m32c_is_struct_return, m32c_analyze_prologue): Update.
3218 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
3220 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
3221 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
3223 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
3225 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
3226 * linux-nat.c (linux_nat_delete_thread): New variable.
3227 (lwp_free): Invoke linux_nat_delete_thread if set.
3228 (linux_nat_set_delete_thread): New function.
3229 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
3230 thread delete callback.
3231 * arm-linux-nat.c (arm_linux_delete_thread): New function.
3232 (_initialize_arm_linux_nat): Assign thread delete callback.
3233 * s390-linux-nat.c (s390_delete_thread): New function.
3234 (_initialize_s390_nat): Assign thread delete callback.
3235 * x86-linux-nat.c (x86_linux_add_target): Likewise.
3236 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
3238 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
3240 * nat/x86-linux.c (x86_linux_delete_thread): New function.
3241 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
3243 2017-10-09 Tom Tromey <tom@tromey.com>
3245 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
3247 * tui/tui-layout.c (enum tui_status): Use std::string.
3249 2017-10-11 Tom Tromey <tom@tromey.com>
3251 * gdbthread.h (thread_command): Constify.
3252 * inferior.h (detach_command): Constify.
3253 * top.h (set_history, show_history): Constify.
3254 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
3255 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
3256 * bsd-kvm.c (bsd_kvm_cmd): Constify.
3257 * printcmd.c (set_command): Constify.
3258 (non_const_set_command): New function.
3259 * dcache.c (set_dcache_command, show_dcache_command): Constify.
3260 * breakpoint.c (enable_command, disable_command, delete_command)
3261 (catch_command, tcatch_command, set_breakpoint_cmd)
3262 (show_breakpoint_cmd): Constify.
3263 * macrocmd.c (macro_command): Constify.
3264 * infcmd.c (unset_command, kill_command, detach_command)
3265 (info_proc_cmd): Constify.
3266 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
3267 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
3268 (info_auto_load_cmd): Constify.
3269 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
3270 (unset_tdesc_cmd): Constify.
3271 * ada-lang.c (set_ada_command, show_ada_command)
3272 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
3273 * guile/guile.c (set_guile_command, show_guile_command)
3274 (info_guile_command): Constify.
3275 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
3277 * skip.c (skip_command): Constify.
3278 * compile/compile.c (_initialize_compile): Constify.
3279 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
3280 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
3281 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
3282 (maint_btrace_pt_show_cmd): Constify.
3283 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
3285 * python/python.c (user_show_python, user_set_python): Constify.
3286 * mips-tdep.c (set_mips_command, show_mips_command)
3287 (set_mipsfpu_command): Constify.
3288 * record-btrace.c (cmd_record_btrace_start)
3289 (cmd_set_record_btrace, cmd_show_record_btrace)
3290 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
3291 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
3292 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
3294 * symfile.c (overlay_command): Constify.
3295 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
3296 * cli/cli-logging.c (set_logging_command, show_logging_command):
3298 * cli/cli-dump.c (dump_command, append_command)
3299 (srec_dump_command, ihex_dump_command, verilog_dump_command)
3300 (tekhex_dump_command, binary_dump_command)
3301 (binary_append_command): Constify.
3302 * cli/cli-decode.c (struct cmd_list_element): Change type of
3304 * cli/cli-cmds.c (info_command, show_command, set_debug)
3305 (show_debug): Constify.
3306 (show_command): Add non-const overload.
3307 * top.c (set_history, show_history): Constify.
3308 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
3309 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
3310 * target.c (target_command): Constify.
3311 * sparc64-tdep.c (info_adi_command): Constify.
3312 * record-full.c (cmd_record_full_start): Constify.
3313 (set_record_full_command): Constify. Fix typo.
3314 (show_record_full_command): Constify.
3315 * thread.c (thread_command, thread_apply_command): Constify.
3316 * memattr.c (dummy_cmd): Constify.
3317 * value.c (function_command): Constify.
3318 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
3319 * probe.c (info_probes_command): Constify.
3320 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
3321 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
3322 (show_thread_cmd, set_thread_default_cmd)
3323 (show_thread_default_cmd): Constify.
3324 (check_empty): Constify.
3325 * tracepoint.c (tfind_command): Constify.
3326 * cp-support.c (maint_cplus_command): Constify.
3327 * windows-tdep.c (info_w32_command): Constify.
3328 * record.c (cmd_record_start, set_record_command)
3329 (show_record_command, info_record_command, cmd_record_goto):
3331 * ravenscar-thread.c (set_ravenscar_command)
3332 (show_ravenscar_command): Constify.
3333 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
3335 (add_internal_problem_command): Remove casts.
3336 * arc-tdep.c (maintenance_print_arc_command): Constify.
3337 * valprint.c (set_print, show_print, set_print_raw)
3338 (show_print_raw): Constify.
3339 * maint.c (maintenance_command, maintenance_info_command)
3340 (maintenance_print_command, maintenance_set_cmd)
3341 (maintenance_show_cmd, set_per_command_cmd)
3342 (show_per_command_cmd, maintenance_check_command): Constify.
3343 * language.c (set_check, show_check): Constify.
3344 * typeprint.c (show_print_type, set_print_type): Constify.
3345 * go32-nat.c (go32_info_dos_command): Constify.
3347 2017-10-11 Tom Tromey <tom@tromey.com>
3349 * breakpoint.c (prepare_re_set_context): Remove.
3350 (breakpoint_re_set_one): Update. Don't use cleanups.
3351 (breakpoint_re_set): Use scoped_restore, std::string, and
3352 scoped_restore_current_language.
3354 2017-10-11 Tom Tromey <tom@tromey.com>
3356 * breakpoint.c (commands_command_1): Use std::string.
3357 (cleanup_executing_breakpoints): Remove.
3358 (bpstat_do_actions_1): Use scoped_restore.
3359 (bpstat_check_watchpoint): Use std::string.
3360 (decode_static_tracepoint_spec): Likewise.
3361 (break_range_command): Likewise.
3362 (watch_command_1): Likewise.
3363 (compare_breakpoints): Change argument types.
3364 (clear_command): Use std::vector.
3365 (cleanup_executing_breakpoints): Remove.
3366 (update_global_location_list): Use unique_xmalloc_ptr.
3367 (strace_command): Remove unused declaration.
3369 2017-10-11 John Baldwin <jhb@FreeBSD.org>
3371 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
3372 * NEWS: Mention new FreeBSD/arm native configuration.
3373 * configure.host: Add arm*-*-freebsd*.
3374 * configure.nat: Likewise.
3375 * arm-fbsd-nat.c: New file.
3377 2017-10-11 John Baldwin <jhb@FreeBSD.org>
3379 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
3380 (ALLDEPFILES): Add arm-fbsd-tdep.c.
3381 * NEWS: Mention new FreeBSD/arm target.
3382 * configure.tgt: Add arm*-*-freebsd*.
3383 * arm-fbsd-tdep.c: New file.
3384 * arm-fbsd-tdep.h: New file.
3386 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3388 * linux-tdep.c (linux_make_corefile_notes): Remove call to
3389 `gdbarch_elfcore_write_linux_prpsinfo'.
3390 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
3392 (elf_internal_linux_prpsinfo): Remove declaration.
3393 * gdbarch.h: Regenerate.
3394 * gdbarch.c: Regenerate.
3396 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3398 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
3399 `set_gdbarch_elfcore_write_linux_prpsinfo'.
3401 2017-10-11 Pedro Alves <palves@redhat.com>
3403 * breakpoint.c (reattach_breakpoints): Delete.
3404 * breakpoint.h (reattach_breakpoints): Delete.
3406 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
3408 * symfile.c (registered_sym_fns): Make struct, not typedef.
3409 (DEF_VEC_O (registered_sym_fns)): Remove.
3410 (symtab_fns): Change type to std::vector.
3411 (add_symtab_fns): Adjust.
3412 (find_sym_fns): Adjust.
3414 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
3416 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
3417 * arc-tdep.h (arc_arch_is_em): New function.
3418 (arc_arch_is_hs): Likewise.
3420 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
3422 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
3423 parentheses in the declaration.
3424 (macro_lookup_inclusion): Likewise.
3425 (macro_lookup_definition): Likewise.
3426 * p-lang.h (pascal_builtin_types): Likewise.
3427 * tui/tui-data.c (tui_win_list): Likewise.
3428 * tui/tui-data.h (tui_win_list): Likewise.
3429 * utils.h (make_cleanup_free_section_addr_info): Likewise.
3431 2017-10-11 Mark Rages <markrages@gmail.com>
3433 * target-memory.c (block_boundaries): Fix for block address not
3434 aligned on block size.
3436 2017-10-10 Pedro Alves <palves@redhat.com>
3437 Tom Tromey <tom@tromey.com>
3439 * breakpoint.c (struct captured_breakpoint_query_args)
3440 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
3441 (print_breakpoint): New.
3442 * breakpoint.h (print_breakpoint): Declare.
3443 * common/common-exceptions.h (enum return_reason): Remove
3444 references to catch_exceptions.
3445 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
3447 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
3448 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
3450 * gdbthread.h (thread_select): Declare.
3451 * mi/mi-cmd-break.c: Don't include gdb.h.
3452 (breakpoint_notify): Use print_breakpoint.
3453 * mi/mi-cmd-catch.c: Don't include gdb.h.
3454 * mi/mi-interp.c: Don't include gdb.h.
3455 (mi_print_breakpoint_for_event): New.
3456 (mi_breakpoint_created, mi_breakpoint_modified): Use
3457 mi_print_breakpoint_for_event.
3458 * mi/mi-main.c: Don't include gdb.h.
3459 (mi_cmd_thread_select): Parse the global thread ID here. Use
3460 thread_select instead of gdb_thread_select.
3461 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
3462 of using gdb_list_thread_ids.
3463 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
3465 (remote_fileio_request): Use TRY/CATCH instead of
3467 * symfile-mem.c (struct symbol_file_add_from_memory_args)
3468 (symbol_file_add_from_memory_wrapper): Delete.
3469 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
3470 * thread.c: Don't include gdb.h.
3471 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
3472 (thread_alive): Use thread_select.
3473 (do_captured_thread_select): Delete, parts salvaged as ...
3474 (thread_select): ... this new function.
3475 (gdb_thread_select): Delete.
3477 2017-10-10 Pedro Alves <palves@redhat.com>
3478 Tom Tromey <tom@tromey.com>
3480 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
3482 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
3483 No longer macros. Instead ...
3484 (enum wp_check_result): They're now values of this new
3486 (watchpoint_check): Change return type to wp_check_result and
3487 parameter type to bpstat.
3488 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
3489 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
3490 catch_errors. Reverse logic of watchpoint_check call.
3491 (breakpoint_re_set_one): Now returns void and takes a breakpoint
3492 pointer as parameter.
3493 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
3494 * common/common-exceptions.c (throw_exception_sjlj): Update
3495 comments to avoid mentioning catch_errors.
3496 * exceptions.c (catch_errors): Delete.
3497 * exceptions.h: Update comments to avoid mentioning catch_errors.
3498 (catch_errors_ftype, catch_errors): Delete.
3499 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
3500 (hook_stop_stub): Delete.
3501 (restore_selected_frame): Change return type to void, and
3502 parameter type to const frame_id &.
3503 (restore_infcall_control_state): Use TRY/CATCH instead of
3505 * main.c (captured_command_loop): Return void and remove
3506 parameter. Remove references to catch_errors.
3507 (captured_main): Use TRY/CATCH instead of catch_errors.
3508 * objc-lang.c (objc_submethod_helper_data)
3509 (find_objc_msgcall_submethod_helper): Delete.
3510 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
3512 * record-full.c (record_full_message): Return void.
3513 (record_full_message_args, record_full_message_wrapper): Delete.
3514 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
3515 instead of catch_errors.
3516 * solib-aix.c (solib_aix_open_symbol_file_object): Change
3517 parameter type to int.
3518 * solib-darwin.c (open_symbol_file_object): Ditto.
3519 * solib-dsbt.c (open_symbol_file_object): Ditto.
3520 * solib-frv.c (open_symbol_file_object): Ditto.
3521 * solib-svr4.c (open_symbol_file_object): Ditto.
3522 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
3523 * solib.c (update_solib_list): Use TRY/CATCH instead of
3525 * solist.h (struct target_so_ops) <open_symbol_file_object>:
3527 * symmisc.c (struct print_symbol_args): Remove.
3528 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
3529 (print_symbol): Change type.
3530 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
3531 and remove parameters.
3532 (catch_errors): New.
3533 (get_windows_debug_event): Adjust.
3535 2017-10-09 Tom Tromey <tom@tromey.com>
3537 * mi/mi-main.c (free_splay_tree): Remove.
3538 (list_available_thread_groups): Use splay_tree_up.
3539 * common/gdb_splay_tree.h: New file.
3541 2017-10-09 Tom Tromey <tom@tromey.com>
3543 * mi/mi-main.c (do_nothing): Remove.
3544 (list_available_thread_groups): Update.
3546 2017-10-09 Pedro Alves <palves@redhat.com>
3548 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
3549 reading registers when switching context.
3551 2017-10-09 John Baldwin <jhb@FreeBSD.org>
3553 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
3554 (fbsd_convert_siginfo): Likewise.
3555 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
3557 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
3559 * configure.ac (try_guile_versions): Remove guile-2.2.
3560 * configure: Regenerate.
3562 2017-10-09 Tom Tromey <tom@tromey.com>
3564 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
3565 (COMPILE.pre): Use $(CXX).
3567 2017-10-09 Pedro Alves <palves@redhat.com>
3569 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
3571 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3572 * cp-support.h (cp_remove_params): Now returns a
3573 gdb::unique_xmalloc_ptr.
3574 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
3575 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
3576 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
3577 returning a gdb::unique_xmalloc_ptr.
3578 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3579 * stack.c (find_frame_funname): Adjust to cp_remove_params
3580 returning a gdb::unique_xmalloc_ptr.
3582 2017-10-08 Tom Tromey <tom@tromey.com>
3584 * dwarf2read.c (dwarf2_get_dwz_file): Use
3585 gdb::unique_xmalloc_ptr.
3586 (find_slot_in_mapped_hash): Likewise.
3587 (dwarf2_physname): Likewise.
3588 (create_dwo_unit_in_dwp_v1): Use std::string.
3589 (create_dwo_unit_in_dwp_v2): Likewise.
3590 (lookup_dwo_cutu): Likewise.
3591 (inherit_abstract_dies): Use std::vector.
3592 (read_array_type): Likewise.
3593 (dwarf_decode_macros): Remove unused declaration.
3594 (unsigned_int_compar): Remove.
3595 (dwarf2_build_psymtabs_hard): Use scoped_restore.
3596 (psymtabs_addrmap_cleanup): Remove.
3598 2017-10-08 Tom Tromey <tom@tromey.com>
3600 * frame-unwind.c (frame_unwind_try_unwinder): Update.
3601 * frame.h (frame_cleanup_after_sniffer): Declare.
3602 (frame_prepare_for_sniffer): Return void.
3603 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
3605 (frame_prepare_for_sniffer): Return void.
3607 2017-10-08 Tom Tromey <tom@tromey.com>
3609 * utils.h (make_cleanup_value_free): Remove.
3610 * utils.c (do_value_free, struct cleanup): Remove.
3611 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
3613 * value.h (struct value_deleter): New.
3614 (gdb_value_up): New typedef.
3616 2017-10-08 Tom Tromey <tom@tromey.com>
3618 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
3619 (make_cleanup_free_search_symbols): Remove.
3620 (search_symbols): Return std::vector.
3621 (symbol_search::compare_search_syms): Now member of
3622 symbol_search. Change arguments.
3623 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
3624 (symtab_symbol_info, rbreak_command): Update.
3625 * symtab.h (struct symbol_search) <next>: Remove.
3627 (symbol_search::operator<): New function.
3628 (symbol_search::operator==): New function.
3629 (search_symbols): Remove std::vector.
3630 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
3631 (symbol_search::compare_search_syms): Declare.
3633 2017-10-06 Yao Qi <yao.qi@linaro.org>
3635 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
3636 arch/aarch64-insn.o.
3638 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
3640 2017-10-06 Yao Qi <yao.qi@linaro.org>
3642 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
3643 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
3644 arch/arm-linux.o respectively.
3645 * configure.tgt: Likewise.
3647 2017-10-06 Yao Qi <yao.qi@linaro.org>
3649 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
3650 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
3652 2017-10-06 Pedro Alves <palves@redhat.com>
3654 * windows-nat.c: Include <algorithm>.
3656 2017-10-06 Yao Qi <yao.qi@linaro.org>
3658 * configure.tgt (i386_tobjs): New variable.
3659 (amd64_tobjs): New variable.
3660 Set $cpu_obs and $os_obs.
3662 2017-10-06 Yao Qi <yao.qi@linaro.org>
3664 * Makefile.in (CONFIG_SRC_SUBDIR): New.
3665 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
3666 (clean): Remove object files and dependency files.
3667 (distclean): Remove the directory.
3668 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3669 * configure: Re-generated.
3670 * configure.tgt: Replace amd64.o with arch/amd64.o.
3672 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
3675 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
3678 2017-10-05 Pedro Alves <palves@redhat.com>
3680 * linux-nat.c (linux_child_follow_fork): When following the parent
3681 and detaching the child, consult the parent thread's architecture
3682 instead of the child's.
3684 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3686 * ax.h: Do not include "doublest.h".
3687 (union agent_val): Remove.
3689 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3691 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
3692 (decimal_to_string): Return std::string object.
3693 (decimal_from_string): Accept std::string object. Return bool.
3694 (decimal_from_integral, decimal_from_doublest): Remove.
3695 (decimal_from_longest): Add prototype.
3696 (decimal_from_ulongest): Likewise.
3697 (decimal_to_longest): Likewise.
3698 (decimal_from_doublest): Likewise.
3699 * dfp.c: Do not include "gdbtypes.h" or "value.h".
3700 (MAX_DECIMAL_STRING): Move here.
3701 (decimal_to_string): Return std::string object.
3702 (decimal_from_string): Accept std::string object. Return bool.
3703 (decimal_from_integral): Remove, replace by ...
3704 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
3705 (decimal_to_longest): New function.
3706 (decimal_from_floating): Remove, replace by ...
3707 (decimal_from_doublest): ... this new function.
3708 (decimal_to_doublest): Update to new decimal_to_string interface.
3710 * value.c (unpack_long): Use decimal_to_longest.
3711 * valops.c (value_cast): Use decimal_from_doublest instead of
3712 decimal_from_floating. Use decimal_from_[u]longest isntead of
3713 decimal_from_integral.
3714 * valarith.c (value_args_as_decimal): Likewise.
3715 * valprint.c (print_decimal_floating): Update to new
3716 decimal_to_string interface.
3717 * printcmd.c (printf_decfloat): Likewise.
3718 * c-exp.y (parse_number): Update to new decimal_from_string interface.
3720 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3722 * doublest.h: Do not include "floatformat.h". Remove stale comments.
3723 * gdbtypes.c: Include "floatformat.h".
3724 * value.c: Likewise.
3725 * m68k-tdep.c: Likewise.
3727 * findvar.c: Do not include "floatformat.h".
3728 * amd64-darwin-tdep.c: Likewise.
3729 * arm-linux-tdep.c: Likewise.
3730 * i386-darwin-tdep.c: Likewise.
3731 * i387-tdep.c: Likewise.
3732 * m68k-linux-tdep.c: Likewise.
3733 * mep-tdep.c: Likewise.
3734 * mips-tdep.c: Likewise.
3735 * nios2-tdep.c: Likewise.
3736 * s390-linux-tdep.c: Likewise.
3737 * sparc-obsd-tdep.c: Likewise.
3738 * sparc-tdep.c: Likewise.
3739 * sparc64-tdep.c: Likewise.
3740 * spu-tdep.c: Likewise.
3741 * tic6x-tdep.c: Likewise.
3742 * tilegx-tdep.c: Likewise.
3743 * vax-tdep.c: Likewise.
3744 * xstormy16-tdep.c: Likewise.
3745 * xtensa-tdep.c: Likewise.
3747 * top.c: Do not include "doublest.h".
3748 * aarch64-tdep.c: Likewise.
3749 * alpha-tdep.c: Likewise.
3750 * arm-linux-tdep.c: Likewise.
3751 * m68k-linux-tdep.c: Likewise.
3752 * tilegx-tdep.c: Likewise.
3753 * xstormy16-tdep.c: Likewise.
3755 2017-10-05 John Baldwin <jhb@FreeBSD.org>
3757 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
3758 (mipsn32_fbsd_sigframe): Define.
3759 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
3760 for FreeBSD/mipsn32.
3762 2017-10-05 John Baldwin <jhb@FreeBSD.org>
3764 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
3767 2017-10-05 Tristan Gingold <tgingold@free.fr>
3769 * MAINTAINERS (Misc): Update my email address.
3771 2017-10-04 Pedro Alves <palves@redhat.com>
3773 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
3774 it instead of target_gdbarch.
3775 (get_remote_state, get_remote_packet_size): Adjust
3776 get_remote_arch_state calls, passing down target_gdbarch
3778 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
3779 'gdbarch' and use it instead of target_gdbarch.
3780 (get_memory_packet_size): Adjust get_remote_arch_state calls,
3781 passing down target_gdbarch explicitly.
3782 (struct stop_reply) <arch>: New field.
3783 (remote_parse_stop_reply): Use the stopped thread's architecture,
3784 not the current inferior's. Save the architecture in the
3786 (process_stop_reply): Use the stop reply's architecture.
3787 (process_g_packet, remote_fetch_registers)
3788 (remote_prepare_to_store, store_registers_using_G)
3789 (remote_store_registers): Adjust get_remote_arch_state calls,
3790 using the regcache's architecture.
3791 (remote_get_trace_status): Adjust get_remote_arch_state calls,
3792 passing down target_gdbarch explicitly.
3793 * spu-multiarch.c (spu_thread_architecture): Defer to the target
3794 beneath instead of calling target_gdbarch.
3795 * target.c (default_thread_architecture): Use the specified
3796 inferior's architecture, instead of the current inferior's
3797 architecture (via target_gdbarch).
3799 2017-10-04 Pedro Alves <palves@redhat.com>
3801 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
3803 (regcache_print): Handle !target_has_registers here instead.
3805 2017-10-04 Pedro Alves <palves@redhat.com>
3807 * frame.c (create_test_frame): Delete.
3808 * frame.h (create_test_frame): Delete.
3809 * gdbarch-selftests.c: Include gdbthread.h and target.h.
3810 (class regcache_test): Delete.
3811 (test_target_has_registers, test_target_has_stack)
3812 (test_target_has_memory, test_target_prepare_to_store)
3813 (test_target_store_registers): New functions.
3814 (test_target_ops): New class.
3815 (register_to_value_test): Error out if there's already a
3816 process_stratum (or higher) target pushed. Create a fuller mock
3817 environment, with mock target_ops, inferior, address space, thread
3819 * progspace.c (struct address_space): Move to ...
3820 * progspace.h (struct address_space): ... here.
3821 * regcache.h (regcache::~regcache, regcache::raw_write)
3822 [GDB_SELF_TEST]: No longer virtual.
3824 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
3826 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
3828 2017-10-04 Pedro Alves <palves@redhat.com>
3830 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
3831 out of 'between TRY and CATCH'.
3833 2017-10-04 Pedro Alves <palves@redhat.com>
3835 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
3836 * common/common-exceptions.h (TRY): Open an outermost scope.
3837 Expand intro comment.
3839 (END_CATCH): Close the outermost scope.
3840 * completer.c (complete_line_internal): Add missing END_CATCH.
3842 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3844 * NEWS (Changes since GDB 8.0): Add entry about new
3845 'set-cwd-on-gdbserver' feature.
3846 (New remote packets): Add entry for QSetWorkingDir.
3847 * common/common-inferior.h (set_inferior_cwd): New prototype.
3848 * infcmd.c (set_inferior_cwd): Remove "static".
3849 (show_cwd_command): Expand text to include remote debugging.
3850 * remote.c: Add PACKET_QSetWorkingDir.
3851 (remote_protocol_features) <QSetWorkingDir>: New entry for
3852 PACKET_QSetWorkingDir.
3853 (extended_remote_set_inferior_cwd): New function.
3854 (extended_remote_create_inferior): Call
3855 "extended_remote_set_inferior_cwd".
3856 (_initialize_remote): Call "add_packet_config_cmd" for
3859 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3861 * NEWS (New commands): Mention "set/show cwd".
3862 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
3863 "cd" command's help text.
3864 * common/common-inferior.h (get_inferior_cwd): New prototype.
3865 * infcmd.c (inferior_cwd_scratch): New global variable.
3866 (set_inferior_cwd): New function.
3867 (get_inferior_cwd): Likewise.
3868 (set_cwd_command): Likewise.
3869 (show_cwd_command): Likewise.
3870 (_initialize_infcmd): Add "set/show cwd" commands.
3871 * inferior.h (class inferior) <cwd>: New field.
3872 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
3873 (fork_inferior): Change inferior's cwd before its execution.
3874 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
3877 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3879 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
3880 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
3881 (COMMON_OBS): Add gdb_tilde_expand.o.
3882 * common/gdb_tilde_expand.c: New file.
3883 * common/gdb_tilde_expand.h: Likewise.
3885 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
3887 * gdbarch.sh (objfile): Remove duplicate declaration.
3888 * gdbarch.h: Regenerate.
3890 2017-10-03 Tom Tromey <tom@tromey.com>
3892 * utils.c (internal_vproblem): Use string_vprintf.
3894 2017-10-03 Tom Tromey <tom@tromey.com>
3896 * printcmd.c (info_symbol_command): Use std::string.
3898 2017-10-03 Tom Tromey <tom@tromey.com>
3900 * top.c (gdb_safe_append_history): Use std::string.
3902 2017-10-03 Tom Tromey <tom@tromey.com>
3904 * event-top.c (stdin_event_handler): Update.
3905 * main.c (captured_main_1): Update.
3906 * top.h (make_delete_ui_cleanup): Remove.
3907 (struct ui): Add constructor and destructor.
3908 (new_ui, delete_ui): Remove.
3909 * top.c (make_delete_ui_cleanup): Remove.
3910 (new_ui_command): Use std::unique_ptr.
3911 (delete_ui_cleanup): Remove.
3912 (ui::ui): Rename from new_ui. Update.
3914 (ui::~ui): Rename from delete_ui. Update.
3916 2017-10-03 Tom Tromey <tom@tromey.com>
3918 * symfile.c (load_progress): Use gdb::byte_vector.
3920 2017-10-03 Tom Tromey <tom@tromey.com>
3922 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
3924 * printcmd.c (x_command): Remove unused declaration.
3925 * symfile.c (symbol_file_command): Remove unused declaration.
3927 2017-10-03 Tom Tromey <tom@tromey.com>
3929 * utils.c (internal_vproblem): Use std::string.
3930 (defaulted_query): Likewise.
3932 2017-10-03 Tom Tromey <tom@tromey.com>
3934 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
3935 * top.c (execute_command_to_string): Update.
3936 * utils.c (make_cleanup_restore_page_info): Remove.
3937 (do_restore_page_info_cleanup): Remove.
3938 (set_batch_flag_and_restore_page_info):
3940 (make_cleanup_restore_page_info): Remove.
3941 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3942 (~set_batch_flag_and_restore_page_info): New
3943 (make_cleanup_restore_uinteger): Remove.
3944 (make_cleanup_restore_integer): Remove.
3945 (struct restore_integer_closure): Remove.
3946 (restore_integer): Remove.
3947 * utils.h (struct set_batch_flag_and_restore_page_info): New
3949 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3950 (make_cleanup_restore_page_info): Remove.
3951 (make_cleanup_restore_uinteger) Remove.
3952 (make_cleanup_restore_integer) Remove.
3954 2017-10-03 Tom Tromey <tom@tromey.com>
3956 * record-full.h (record_full_gdb_operation_disable_set): Return
3957 scoped_restore_tmpl<int>.
3958 * infrun.c (adjust_pc_after_break): Update.
3959 (handle_signal_stop): Update.
3960 * record-full.c (record_full_gdb_operation_disable_set): Return
3961 scoped_restore_tmpl<int>.
3962 (record_full_wait_1, record_full_insert_breakpoint)
3963 (record_full_remove_breakpoint, record_full_save)
3964 (record_full_goto_insn): Update.
3966 2017-10-02 Tom Tromey <tom@tromey.com>
3969 * rust-lang.c (rust_val_print_str): New function.
3970 (val_print_struct): Call it.
3971 (rust_subscript): Preserve name of slice type.
3973 2017-10-02 Tom Tromey <tom@tromey.com>
3975 * rust-lang.c (rust_subscript): Handle slices in
3976 EVAL_AVOID_SIDE_EFFECTS case.
3978 2017-10-02 Tom Tromey <tom@tromey.com>
3980 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
3982 2017-10-02 Tom Tromey <tom@tromey.com>
3984 * rust-lang.h (rust_slice_type): Add "extern".
3986 2017-10-02 Tom Tromey <tom@tromey.com>
3987 Pedro Alves <palves@redhat.com>
3989 * ada-lang.h (ada_exc_info::operator<): Make const.
3990 (ada_exc_info::operator==): Make const.
3991 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
3994 2017-09-29 Tom Tromey <tom@tromey.com>
3996 * target.c (read_whatever_is_readable): Change type of "result".
3998 (free_memory_read_result_vector): Remove.
3999 (read_memory_robust): Change return type. Update.
4000 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
4001 bin2hex, std::string.
4002 * target.h (memory_read_result_s): Remove typedef.
4003 (free_memory_read_result_vector): Remove.
4004 (read_memory_robust): Return std::vector.
4006 2017-09-29 Tom Tromey <tom@tromey.com>
4008 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
4010 2017-09-29 Tom Tromey <tom@tromey.com>
4012 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
4013 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
4014 operator< and operator==.
4015 (ada_exceptions_list): Return a std::vector.
4016 * ada-lang.c (ada_exc_info::operator<): Rename from
4017 compare_ada_exception_info.
4018 (ada_exc_info::operator==): New.
4019 (sort_remove_dups_ada_exceptions_list): Change type of
4021 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
4022 (ada_add_global_exceptions): Likewise.
4023 (ada_exceptions_list_1): Return a std::vector.
4024 (ada_exceptions_list): Likewise.
4026 2017-09-29 Tom Tromey <tom@tromey.com>
4028 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
4030 (print_one_inferior): Update.
4031 (free_vector_of_ints): Remove.
4032 (list_available_thread_groups): Change "ids" to std::set.
4033 (mi_cmd_list_thread_groups): Update.
4034 (struct collect_cores_data) <core>: Now a std::set.
4035 (collect_cores): Update.
4037 (print_one_inferior): Update.
4039 2017-09-29 Tom Tromey <tom@tromey.com>
4041 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
4042 (mi_execute_async_cli_command): Likewise.
4043 (mi_cmd_trace_frame_collected): Use field_fmt.
4045 2017-09-29 Tom Tromey <tom@tromey.com>
4047 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
4050 2017-09-29 Tom Tromey <tom@tromey.com>
4052 * mi/mi-parse.c (mi_parse): Remove unused declaration.
4054 2017-09-29 Tom Tromey <tom@tromey.com>
4056 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
4058 2017-09-29 Tom Tromey <tom@tromey.com>
4060 * varobj.h (varobj_gen_name): Return std::string.
4061 * varobj.c (varobj_gen_name): Return std::string.
4062 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
4063 (mi_cmd_var_delete): Don't copy "name".
4065 2017-09-29 Tom Tromey <tom@tromey.com>
4067 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
4068 (mi_cmd_break_insert_1): Update.
4070 2017-09-29 Tom Tromey <tom@tromey.com>
4072 * target.h (make_scoped_defer_target_commit_resume): Update.
4073 * target.c (make_scoped_defer_target_commit_resume): Rename from
4074 make_cleanup_defer_target_commit_resume. Return a
4076 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
4078 2017-09-29 Tom Tromey <tom@tromey.com>
4080 * main.c (captured_main_1): Remove unused declaration.
4081 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
4083 2017-09-29 Tom Tromey <tom@tromey.com>
4085 * symtab.c (search_symbols): Remove unused outer cleanup.
4086 (make_source_files_completion_list): Remove unused declaration.
4088 2017-09-29 Tom Tromey <tom@tromey.com>
4090 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
4092 2017-09-29 Tom Tromey <tom@tromey.com>
4094 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
4097 2017-09-29 Tom Tromey <tom@tromey.com>
4099 * complaints.c (vcomplaint): Use std::string.
4101 2017-09-29 Tom Tromey <tom@tromey.com>
4103 * tracepoint.c (trace_variable_command): Use std::string.
4104 (encode_actions_1): Remove unused declarations.
4105 (create_tsv_from_upload): Use std::string.
4107 2017-09-29 Tom Tromey <tom@tromey.com>
4109 * cp-support.c (gdb_demangle): Use std::string.
4111 2017-09-29 Tom Tromey <tom@tromey.com>
4113 * stack.c (parse_frame_specification): Use std::string
4114 (info_frame_command): Use gdb::unique_xmalloc_ptr.
4116 2017-09-29 Tom Tromey <tom@tromey.com>
4118 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
4120 2017-09-29 Tom Tromey <tom@tromey.com>
4122 * utils.c (vfprintf_maybe_filtered): Use std::string.
4123 (vfprintf_unfiltered): Likewise.
4125 2017-09-29 Tom Tromey <tom@tromey.com>
4127 * event-top.c (top_level_prompt): Return std::string.
4128 (display_gdb_prompt): Update.
4130 2017-09-29 Tom Tromey <tom@tromey.com>
4132 * unittests/common-utils-selftests.c (format): New function.
4133 (string_vprintf_tests): New function.
4134 (_initialize_common_utils_selftests): Register new tests.
4135 * common/common-utils.c (string_vprintf): New function.
4136 * common/common-utils.h (string_vprintf): Declare.
4138 2017-09-29 Pedro Alves <palves@redhat.com>
4140 * common/rsp-low.c (unpack_varlen_hex): Constify.
4141 * common/rsp-low.h (unpack_varlen_hex): Constify.
4142 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
4144 * remote.c (remote_set_permissions, read_ptid)
4145 (remote_current_thread, remote_get_threads_with_qthreadinfo)
4146 (remote_static_tracepoint_marker_at)
4147 (remote_static_tracepoint_markers_by_strid)
4148 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
4149 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
4150 (parse_tracepoint_definition, parse_tsv_definition)
4151 (parse_static_tracepoint_marker_definition): Constify.
4152 * tracepoint.h (parse_static_tracepoint_marker_definition)
4153 (parse_trace_status, parse_tracepoint_status)
4154 (parse_tracepoint_definition, parse_tsv_definition): Constify.
4156 2017-09-29 Pedro Alves <palves@redhat.com>
4158 * remote.c (target_buf, target_buf_size): Delete.
4159 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
4160 Use the connection's packet buffer instead.
4161 All callers adjusted.
4162 (_initialize_remote): Remove references to target_buf and
4165 2017-09-28 Pedro Alves <palves@redhat.com>
4167 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4168 unittests/common-utils-selftests.c.
4169 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
4170 (COMMON_OBS): Remove utils-selftests.o.
4171 * utils-selftests.c: Move to ...
4172 * unittests/common-utils-selftests.c: ... here and rename self
4173 test to "string_printf".
4175 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
4177 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
4178 having NULL cus or tus.
4180 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
4182 * arm-tdep.c: (convert_from_extended): Remove.
4183 (convert_to_extended): Likewise.
4184 (arm_extract_return_value): Use convert_typed_floating.
4185 (arm_store_return_value): Likewise.
4187 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
4188 * sh-tdep.c: Do not include "floatformat.h".
4189 (sh_littlebyte_bigword_type): New function.
4190 (sh_register_convert_to_virtual): Use convert_typed_floating.
4191 (sh_register_convert_to_raw): Likewise.
4192 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
4193 (sh64_littlebyte_bigword_type): New function.
4194 (sh64_extract_return_value): Use convert_typed_floating.
4195 (sh64_register_convert_to_virtual): Likewise.
4196 (sh64_register_convert_to_raw): Likewise.
4198 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
4200 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
4201 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
4203 * gdbtypes.h (union type_specific): Make field floatformat hold
4204 just a single struct floatformat, not an array.
4205 (floatformat_from_type): Move here.
4206 * gdbtypes.c (floatformat_from_type): Move here. Update to
4207 changed TYPE_FLOATFORMAT definition.
4208 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
4209 (recursive_dump_type): Likewise.
4210 (init_float_type): Install correct floatformat for byte order.
4211 (arch_float_type): Likewise.
4213 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
4215 * gdbtypes.c (init_type): Change incoming argument from
4216 length-in-bytes to length-in-bits. Assert length is a
4217 multiple of TARGET_CHAR_BITS.
4218 (arch_type, arch_flags_type): Likewise.
4219 (init_integer_type): Update call to init_type.
4220 (init_character_type): Likewise.
4221 (init_boolean_type): Likewise.
4222 (init_float_type): Likewise.
4223 (init_decfloat_type): Likewise.
4224 (init_complex_type): Likewise.
4225 (init_pointer_type): Likewise.
4226 (objfile_type): Likewise.
4227 (arch_integer_type): Update call to arch_type.
4228 (arch_character_type): Likewise.
4229 (arch_boolean_type): Likewise.
4230 (arch_float_type): Likewise.
4231 (arch_decfloat_type): Likewise.
4232 (arch_complex_type): Likewise.
4233 (arch_pointer_type): Likewise.
4234 (gdbtypes_post_init): Likewise.
4236 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
4237 (read_base_type): Likewise.
4238 * mdebugread.c (basic_type): Likewise.
4239 * stabsread.c (dbx_init_float_type): Likewise.
4240 (rs6000_builtin_type): Likewise.
4241 (read_range_type): Likewise. Also, fix call to init_integer_type
4242 with erroneous length argument.
4244 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
4245 * d-lang.c (build_d_types): Likewise.
4246 * f-lang.c (build_fortran_types): Likewise.
4247 * go-lang.c (build_go_types): Likewise.
4248 * opencl-lang.c (build_opencl_types): Likewise.
4249 * jit.c (finalize_symtab): Likewise.
4250 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
4251 (build_std_type_info_type): Likewise.
4252 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
4253 update call to arch_flags_type.
4255 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
4257 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
4258 * windows-tdep.c (windows_get_tlb_type): Likewise.
4260 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
4261 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
4262 * m32c-tdep.c (make_types): Likewise.
4263 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
4264 (rl78_psw_type): Update call to arch_flags_type.
4265 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
4266 * rx-tdep.c (rx_psw_type): Likewise.
4267 (rx_fpsw_type): Likewise.
4268 * sparc-tdep.c (sparc_psr_type): Likewise.
4269 (sparc_fsr_type): Likewise.
4270 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
4271 (sparc64_ccr_type): Likewise.
4272 (sparc64_fsr_type): Likewise.
4273 (sparc64_fprs_type): Likewise.
4275 2017-09-27 Tom Tromey <tom@tromey.com>
4277 * findcmd.c (find_command): Constify.
4279 2017-09-27 Tom Tromey <tom@tromey.com>
4281 * ada-tasks.c (task_command_1, task_command): Constify.
4283 2017-09-27 Tom Tromey <tom@tromey.com>
4285 * symtab.c (maintenance_print_symbol_cache)
4286 (maintenance_flush_symbol_cache)
4287 (maintenance_print_symbol_cache_statistics): Constify.
4289 2017-09-27 Tom Tromey <tom@tromey.com>
4291 * inferior.c (detach_inferior_command, kill_inferior_command)
4292 (inferior_command): Constify.
4294 2017-09-27 Tom Tromey <tom@tromey.com>
4296 * regcache.c (regcache_print, maintenance_print_registers)
4297 (maintenance_print_raw_registers)
4298 (maintenance_print_cooked_registers)
4299 (maintenance_print_register_groups)
4300 (maintenance_print_remote_registers): Constify.
4302 2017-09-27 Tom Tromey <tom@tromey.com>
4304 * printcmd.c (map_display_numbers, undisplay_command)
4305 (enable_disable_display_command, enable_display_command)
4306 (disable_display_command): Constify.
4308 2017-09-27 Tom Tromey <tom@tromey.com>
4310 * breakpoint.h (delete_command): Don't declare.
4311 * breakpoint.c (delete_command, enable_once_command)
4312 (enable_count_command, enable_delete_command, breakpoint_1)
4313 (maintenance_info_breakpoints, stopin_command, stopat_command)
4314 (delete_command, delete_trace_command, save_breakpoints)
4315 (save_breakpoints_command, save_tracepoints_command): Constify.
4317 2017-09-27 Tom Tromey <tom@tromey.com>
4319 * macrocmd.c (macro_expand_command, macro_expand_once_command)
4320 (skip_ws, extract_identifier, macro_define_command)
4321 (macro_undef_command, macro_list_command): Constify.
4323 2017-09-27 Tom Tromey <tom@tromey.com>
4325 * infcmd.c (environment_info, set_environment_command)
4326 (unset_environment_command, path_info, info_proc_cmd_1)
4327 (info_proc_cmd_mappings, info_proc_cmd_stat)
4328 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
4329 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
4331 2017-09-27 Tom Tromey <tom@tromey.com>
4333 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
4336 2017-09-27 Tom Tromey <tom@tromey.com>
4338 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
4340 2017-09-27 Tom Tromey <tom@tromey.com>
4342 * demangle.c (demangle_command): Constify.
4344 2017-09-27 Tom Tromey <tom@tromey.com>
4346 * progspace.c (maintenance_info_program_spaces_command):
4349 2017-09-27 Tom Tromey <tom@tromey.com>
4351 * compile/compile.c (check_raw_argument, compile_file_command)
4352 (compile_code_command, compile_print_command): Constify.
4354 2017-09-27 Tom Tromey <tom@tromey.com>
4356 * reggroups.c (maintenance_print_reggroups): Constify.
4358 2017-09-27 Tom Tromey <tom@tromey.com>
4360 * dwarf2read.c (save_gdb_index_command): Constify.
4362 2017-09-27 Tom Tromey <tom@tromey.com>
4364 * stap-probe.c (info_probes_stap_command): Constify.
4366 2017-09-27 Tom Tromey <tom@tromey.com>
4368 * fork-child.c (unset_exec_wrapper_command): Constify.
4370 2017-09-27 Tom Tromey <tom@tromey.com>
4372 * btrace.c (get_uint, get_context_size, no_chunk)
4373 (maint_btrace_packet_history_cmd)
4374 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
4375 (maint_info_btrace_cmd): Constify.
4377 2017-09-27 Tom Tromey <tom@tromey.com>
4379 * reverse.c (delete_bookmark_command): Constify.
4381 2017-09-27 Tom Tromey <tom@tromey.com>
4383 * remote.c (set_memory_packet_size)
4384 (set_memory_write_packet_size, show_memory_write_packet_size)
4385 (set_memory_read_packet_size, show_memory_read_packet_size)
4386 (compare_sections_command, packet_command, remote_put_command)
4387 (remote_get_command, remote_delete_command): Constify.
4389 2017-09-27 Tom Tromey <tom@tromey.com>
4391 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
4392 (set_mipsfpu_double_command, set_mipsfpu_none_command)
4393 (set_mipsfpu_auto_command): Constify.
4395 2017-09-27 Tom Tromey <tom@tromey.com>
4397 * cli/cli-cmds.h (cd_command): Constify.
4398 * cli/cli-cmds.c (cd_command): Constify.
4400 2017-09-27 Tom Tromey <tom@tromey.com>
4402 * thread.c (thread_name_command, thread_find_command): Constify.
4404 2017-09-27 Tom Tromey <tom@tromey.com>
4406 * probe.c (enable_probes_command, disable_probes_command):
4409 2017-09-27 Tom Tromey <tom@tromey.com>
4411 * symfile.c (symbol_file_command): Constify.
4412 * gdbcore.h (deprecated_file_changed_hook): Constify.
4413 * exec.c (deprecated_file_changed_hook, exec_file_command)
4414 (file_command): Constify.
4415 * defs.h (symbol_file_command): Constify.
4417 2017-09-27 Tom Tromey <tom@tromey.com>
4419 * remote-fileio.c (set_system_call_allowed)
4420 (show_system_call_allowed): Constify.
4422 2017-09-27 Tom Tromey <tom@tromey.com>
4424 * tracepoint.c (delete_trace_variable_command)
4425 (tfind_end_command, tfind_start_command, tfind_pc_command)
4426 (tfind_tracepoint_command, tfind_line_command)
4427 (tfind_range_command, tfind_outside_command): Constify.
4429 2017-09-27 Tom Tromey <tom@tromey.com>
4431 * ax-gdb.c (maint_agent_printf_command, agent_command)
4432 (agent_eval_command): Constify.
4434 2017-09-27 Tom Tromey <tom@tromey.com>
4436 * tracepoint.c (info_scope_command): Constify.
4437 * python/python.c (gdbpy_decode_line): Constify.
4438 * python/py-breakpoint.c (bppy_init): Constify.
4439 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
4440 * location.h: (new_linespec_location)
4441 (string_to_event_location_basic, string_to_event_location):
4443 * location.c (new_linespec_location)
4444 (string_to_event_location_basic, string_to_event_location):
4446 * linespec.h (decode_line_with_current_source)
4447 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
4448 * linespec.c (linespec_lex_to_end)
4449 (decode_line_with_current_source)
4450 (decode_line_with_last_displayed): Constify.
4451 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
4453 * cli/cli-cmds.c (edit_command, list_command): Constify.
4454 * breakpoint.h (until_break_command, watch_command_wrapper)
4455 (awatch_command_wrapper, rwatch_command_wrapper)
4456 (init_ada_exception_breakpoint): Constify.
4457 * breakpoint.c (break_command_1, dprintf_command)
4458 (break_range_command, watch_command_wrapper)
4459 (rwatch_command_wrapper, awatch_command_wrapper)
4460 (until_break_command, init_ada_exception_breakpoint)
4461 (strace_marker_create_sals_from_location, trace_command)
4462 (ftrace_command, strace_command, struct tracepoint): Constify.
4463 * ax-gdb.c (agent_command_1): Constify.
4464 * ada-lang.c (ada_exception_sal): Constify.
4466 2017-09-27 Tom Tromey <tom@tromey.com>
4468 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
4469 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
4470 (get_context_size, no_chunk, get_insn_history_modifiers)
4471 (cmd_record_insn_history, get_call_history_modifiers)
4472 (cmd_record_call_history): Constify.
4474 2017-09-27 Tom Tromey <tom@tromey.com>
4476 * source.c (show_substitute_path_command)
4477 (unset_substitute_path_command, set_substitute_path_command):
4480 2017-09-27 Tom Tromey <tom@tromey.com>
4482 * typeprint.c (maintenance_print_type): Constify.
4483 * maint.c (maintenance_dump_me, maintenance_demangle)
4484 (maintenance_time_display, maintenance_info_sections)
4485 (maintenance_print_statistics, maintenance_deprecate)
4486 (maintenance_undeprecate): Constify.
4487 (maintenance_do_deprecate): Constify. Use std::string.
4488 (maintenance_selftest): Constify.
4489 * gdbtypes.h (maintenance_print_type): Constify.
4491 2017-09-27 Tom Tromey <tom@tromey.com>
4493 * hppa-tdep.c (unwind_command): Constify.
4495 2017-09-27 Tom Tromey <tom@tromey.com>
4497 * target-descriptions.c (unset_tdesc_filename_cmd)
4498 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
4501 2017-09-27 Tom Tromey <tom@tromey.com>
4503 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
4505 2017-09-27 Tom Tromey <tom@tromey.com>
4507 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
4509 2017-09-27 Tom Tromey <tom@tromey.com>
4511 * tui/tui-regs.c (tui_reg_command): Constify.
4513 2017-09-27 Tom Tromey <tom@tromey.com>
4515 * skip.c (skip_file_command, skip_function_command)
4516 (skip_enable_command, skip_disable_command, skip_delete_command):
4519 2017-09-27 Tom Tromey <tom@tromey.com>
4521 * record-btrace.c (cmd_record_btrace_bts_start)
4522 (cmd_record_btrace_pt_start): Constify.
4524 2017-09-27 Tom Tromey <tom@tromey.com>
4526 * symmisc.c (maintenance_print_symbols)
4527 (maintenance_print_msymbols, maintenance_print_objfiles)
4528 (maintenance_info_symtabs, maintenance_check_symtabs)
4529 (maintenance_expand_symtabs, maintenance_info_line_tables):
4532 2017-09-27 Tom Tromey <tom@tromey.com>
4534 * top.c (new_ui_command): Constify.
4536 2017-09-27 Tom Tromey <tom@tromey.com>
4538 * symfile.c (add_symbol_file_command)
4539 (remove_symbol_file_command, list_overlays_command)
4540 (map_overlay_command, unmap_overlay_command)
4541 (overlay_auto_command, overlay_manual_command)
4542 (overlay_off_command, overlay_load_command): Constify.
4544 2017-09-27 Tom Tromey <tom@tromey.com>
4546 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
4547 (info_spu_mailbox_command, info_spu_dma_command)
4548 (info_spu_proxydma_command): Constify.
4550 2017-09-27 Tom Tromey <tom@tromey.com>
4552 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
4554 2017-09-27 Tom Tromey <tom@tromey.com>
4556 * cli/cli-script.c (user_defined_command): Constify.
4558 2017-09-27 Tom Tromey <tom@tromey.com>
4560 * cli/cli-dump.c (dump_memory_command, dump_value_command)
4561 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
4562 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
4563 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
4564 (dump_binary_value, append_binary_memory, append_binary_value):
4566 (struct dump_context) <func>: Constify.
4567 (add_dump_command): Update.
4569 2017-09-27 Tom Tromey <tom@tromey.com>
4571 * cli/cli-cmds.c (show_version, show_configuration)
4572 (source_command, show_user): Constify.
4574 2017-09-27 Tom Tromey <tom@tromey.com>
4576 * target.c (maintenance_print_target_stack): Constify.
4578 2017-09-27 Tom Tromey <tom@tromey.com>
4580 * interps.c (interpreter_exec_cmd): Constify.
4582 2017-09-27 Tom Tromey <tom@tromey.com>
4584 * record-full.c (cmd_record_full_restore): Constify.
4586 2017-09-27 Tom Tromey <tom@tromey.com>
4588 * memattr.c (enable_mem_command, disable_mem_command)
4589 (delete_mem_command): Constify.
4591 2017-09-27 Tom Tromey <tom@tromey.com>
4593 * value.c (show_convenience): Constify.
4595 2017-09-27 Tom Tromey <tom@tromey.com>
4597 * gdbcore.h (core_file_command): Update.
4598 * corefile.c (core_file_command): Constify.
4600 2017-09-27 Tom Tromey <tom@tromey.com>
4602 * user-regs.c (maintenance_print_user_registers): Constify.
4604 2017-09-27 Tom Tromey <tom@tromey.com>
4606 * cp-namespace.c (maintenance_cplus_namespace): Constify.
4608 2017-09-27 Tom Tromey <tom@tromey.com>
4610 * cp-support.c (first_component_command): Constify.
4612 2017-09-27 Tom Tromey <tom@tromey.com>
4614 * psymtab.c (maintenance_print_psymbols)
4615 (maintenance_info_psymtabs, maintenance_check_psymtabs):
4618 2017-09-27 Tom Tromey <tom@tromey.com>
4620 * windows-tdep.c (display_tib): Constify.
4622 2017-09-27 Tom Tromey <tom@tromey.com>
4624 * linux-fork.c (delete_checkpoint_command)
4625 (detach_checkpoint_command): Constify.
4627 2017-09-27 Tom Tromey <tom@tromey.com>
4629 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
4631 2017-09-27 Tom Tromey <tom@tromey.com>
4633 * arc-tdep.c (dump_arc_instruction_command): Constify.
4635 2017-09-27 Tom Tromey <tom@tromey.com>
4637 * valprint.c (set_radix, show_radix): Constify.
4639 2017-09-27 Tom Tromey <tom@tromey.com>
4641 * dtrace-probe.c (info_probes_dtrace_command): Constify.
4643 2017-09-27 Tom Tromey <tom@tromey.com>
4645 * command.h (not_just_help_class_command): Update.
4646 * cli/cli-decode.h (not_just_help_class_command): Update.
4647 * cli/cli-decode.c (not_just_help_class_command): Constify.
4649 2017-09-27 Tom Tromey <tom@tromey.com>
4651 * gdb_bfd.c (maintenance_info_bfds): Constify.
4653 2017-09-27 Tom Tromey <tom@tromey.com>
4655 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
4657 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
4658 (do_const_cfunc): New function.
4659 (cmd_cfunc_eq): New overload.
4660 (cli_user_command_p): Check do_const_cfunc.
4661 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
4663 * command.h (add_cmd): Add const overload and no-function
4665 (set_cmd_cfunc): Add const overload.
4666 (cmd_const_cfunc_ftype): Declare.
4667 (cmd_cfunc_eq): Add const overload.
4668 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
4669 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
4672 2017-09-27 Tom Tromey <tom@tromey.com>
4674 * macroexp.c (get_next_token_for_substitution): New function.
4675 (substitute_args): Call it. Check for __VA_OPT__.
4677 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4678 Pedro Alves <palves@redhat.com>
4680 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
4681 producer_is_icc_lt_14.
4682 (producer_is_icc_lt_14): New function.
4683 (check_producer): Add code for checking version of ICC.
4684 (producer_is_icc): Move to producer.c.
4685 (read_structure_type): Restrict ICC workaround to ICC<14.
4686 * producer.c: Include selftest.h.
4687 (producer_is_icc, producer_parsing_tests, _initialize_producer):
4689 * producer.h (producer_is_icc): New declaration.
4691 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4693 * Makefile.in (SFILES): Add producer.c.
4694 (COMMON_OBS): Add producer.o
4695 * amd64-tdep.c (producer.h): Add new include.
4696 * dwarf2read.c (producer.h): Add new include.
4697 * producer.c: New file.
4698 * producer.h: New file.
4699 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
4701 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
4704 2017-09-26 Matthias Klose <doko@ubuntu.com>
4706 * configure.ac: Search ncursesw before ncurses.
4707 Check ncursesw/ncurses.h before ncurses/ncurses.h.
4708 * gdb_curses.h: Include <ncursesw/ncurses.h>
4709 * config.in, configure: Regenerate.
4711 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4714 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
4716 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
4717 Remove i386sol2 support.
4718 * configure.nat <i386sol2>: Remove.
4719 <sol2-64>: Fold into ...
4721 Move common settings to default section.
4723 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
4724 x86_64-*-solaris2.1[0-9]*>: Rename to ...
4725 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
4726 <i[34567]86-*-solaris*>: Remove.
4727 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
4729 * configure.ac: Remove wctype in libw check.
4730 (_MSE_INT_H): Don't define on Solaris 7-9.
4731 <solaris*>: Remove libthread_db.so.1 check.
4732 * configure: Regenerate.
4733 * config.in: Regenerate.
4735 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
4736 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
4737 (gdb_ps_size_t): Remove.
4738 Use base types in users.
4739 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
4741 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
4743 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4746 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
4747 (adi_is_addr_mapped): Likewise.
4748 (PSR_ICC): Don't redefine.
4749 (PSR_IMPL): Likewise.
4751 2017-09-25 Tom Tromey <tom@tromey.com>
4753 * regcache.c (regcache::dump): Use string_printf.
4755 2017-09-25 Tom Tromey <tom@tromey.com>
4757 * regcache.c (class regcache_invalidator): New.
4758 (struct register_to_invalidate): Remove.
4759 (make_cleanup_regcache_invalidate): Remove.
4760 (regcache::raw_write): Use regcache_invalidator.
4762 2017-09-25 Tom Tromey <tom@tromey.com>
4764 * spu-tdep.c (spu2ppu_sniffer): Update.
4765 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
4766 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
4768 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
4769 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
4770 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
4771 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
4772 (frame_pop): Update.
4774 2017-09-25 Tom Tromey <tom@tromey.com>
4776 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
4777 * regcache.h (regcache_xfree): Don't declare.
4778 * regcache.c (regcache_xfree): Remove.
4779 (do_regcache_xfree): Use delete.
4780 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
4781 * linux-fork.c (free_fork): Use delete.
4782 (fork_save_infrun_state): Likewise.
4783 * jit.c (jit_dealloc_cache): Use delete.
4784 * infrun.c (discard_infcall_suspend_state): Use delete.
4786 2017-09-25 Tom Tromey <tom@tromey.com>
4788 * regcache.h (regcache_xmalloc): Don't declare.
4789 (regcache_raw_set_cached_value): Update comment.
4790 * regcache.c (regcache_xmalloc): Remove.
4791 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
4792 * jit.c (jit_frame_sniffer): Use new.
4793 * frame.c (frame_save_as_regcache): Use new.
4795 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4797 * NEWS: Advertise support for guarded-storage registers on IBM z.
4799 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4801 * s390-linux-nat.c (have_regset_gs): New static variable.
4802 (s390_linux_fetch_inferior_registers): Handle guarded-storage
4803 control block and guarded-storage broadcast control regsets.
4804 (s390_read_description): Detect whether the target has
4805 guarded-storage support, return appropriate tdesc.
4806 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
4807 (features/s390x-gs-linux64.c): Likewise.
4808 (struct gdbarch_tdep) <have_gs>: New field.
4809 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
4810 (s390_gsbc_regset): New variables.
4811 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
4812 and s390_gsbc_regset, if applicable.
4813 (s390_core_read_description): Check whether core file was from a
4814 target with guarded-storage support; include appropriate regsets.
4815 (s390_gdbarch_init): Add registers for guarded-storage support.
4816 (_initialize_s390_tdep): Initialize new target descriptions that
4817 include registers for guarded-storage support.
4818 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
4819 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
4820 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
4821 (S390_NUM_REGS): Adjust macro definition.
4822 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
4823 (tdesc_s390x_gs_linux64): New declarations.
4825 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4827 * features/s390-gs-linux64.xml: New file.
4828 * features/s390-gs.xml: New file.
4829 * features/s390-gsbc.xml: New file.
4830 * features/s390x-gs-linux64.xml: New file.
4831 * features/Makefile (WHICH): Add s390-gs-linux64 and
4833 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
4834 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
4835 * features/s390-gs-linux64.c: New generated file.
4836 * features/s390x-gs-linux64.c: New file.
4837 * regformats/s390-gs-linux64.dat: New file.
4838 * regformats/s390x-gs-linux64.dat: New file.
4840 2017-09-23 Tom Tromey <tom@tromey.com>
4842 * defs.h (make_cleanup_override_quit_handler): Don't declare.
4844 2017-09-22 Tom Tromey <tom@tromey.com>
4846 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
4847 type to scoped_restore_tmpl.
4848 <scoped_input_handler>: Initialize m_quit_handler directly.
4850 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4852 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
4853 (cd_command): Likewise. Free "current_directory" before
4855 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
4856 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
4857 * top.c (gdb_dirbuf): Remove global declaration.
4858 * top.h (gdb_dirbuf): Likewise.
4860 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4862 * gnulib/aclocal.m4: Regenerate.
4863 * gnulib/config.in: Regenerate.
4864 * gnulib/configure: Regenerate.
4865 * gnulib/import/Makefile.am: Regenerate.
4866 * gnulib/import/Makefile.in: Regenerate.
4867 * gnulib/import/assure.h: New file.
4868 * gnulib/import/at-func.c: Likewise
4869 * gnulib/import/chdir-long.c: New file.
4870 * gnulib/import/chdir-long.h: New file.
4871 * gnulib/import/cloexec.c: New file.
4872 * gnulib/import/cloexec.h: New file.
4873 * gnulib/import/close.c: New file.
4874 * gnulib/import/closedir.c: New file.
4875 * gnulib/import/dirent-private.h: New file.
4876 * gnulib/import/dup-safer.c: New file.
4877 * gnulib/import/dup.c: New file.
4878 * gnulib/import/dup2.c: New file.
4879 * gnulib/import/error.c: New file.
4880 * gnulib/import/error.h: New file.
4881 * gnulib/import/exitfail.c: New file.
4882 * gnulib/import/exitfail.h: New file.
4883 * gnulib/import/fchdir.c: New file.
4884 * gnulib/import/fcntl.c: New file.
4885 * gnulib/import/fcntl.in.h: New file.
4886 * gnulib/import/fd-hook.c: New file.
4887 * gnulib/import/fd-hook.h: New file.
4888 * gnulib/import/fd-safer.c: New file.
4889 * gnulib/import/fdopendir.c: New file.
4890 * gnulib/import/filename.h: New file.
4891 * gnulib/import/filenamecat-lgpl.c: New file.
4892 * gnulib/import/filenamecat.h: New file.
4893 * gnulib/import/fstat.c: New file.
4894 * gnulib/import/fstatat.c: New file.
4895 * gnulib/import/getcwd-lgpl.c: New file.
4896 * gnulib/import/getcwd.c: New file.
4897 * gnulib/import/getdtablesize.c: New file.
4898 * gnulib/import/getlogin_r.c: New file.
4899 * gnulib/import/getprogname.c: New file.
4900 * gnulib/import/getprogname.h: New file.
4901 * gnulib/import/gettext.h: New file.
4902 * gnulib/import/glob-libc.h: New file.
4903 * gnulib/import/glob.c: New file.
4904 * gnulib/import/glob.in.h: New file.
4905 * gnulib/import/intprops.h: New file.
4906 * gnulib/import/m4/chdir-long.m4: New file.
4907 * gnulib/import/m4/close.m4: New file.
4908 * gnulib/import/m4/closedir.m4: New file.
4909 * gnulib/import/m4/d-ino.m4: New file.
4910 * gnulib/import/m4/d-type.m4: New file.
4911 * gnulib/import/m4/dup.m4: New file.
4912 * gnulib/import/m4/dup2.m4: New file.
4913 * gnulib/import/m4/error.m4: New file.
4914 * gnulib/import/m4/fchdir.m4: New file.
4915 * gnulib/import/m4/fcntl.m4: New file.
4916 * gnulib/import/m4/fcntl_h.m4: New file.
4917 * gnulib/import/m4/fdopendir.m4: New file.
4918 * gnulib/import/m4/filenamecat.m4: New file.
4919 * gnulib/import/m4/fstat.m4: New file.
4920 * gnulib/import/m4/fstatat.m4: New file.
4921 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
4922 * gnulib/import/m4/getcwd-path-max.m4: New file.
4923 * gnulib/import/m4/getcwd.m4: New file.
4924 * gnulib/import/m4/getdtablesize.m4: New file.
4925 * gnulib/import/m4/getlogin_r.m4: New file.
4926 * gnulib/import/m4/getprogname.m4: New file.
4927 * gnulib/import/m4/glob.m4: New file.
4928 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4929 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4930 * gnulib/import/m4/mempcpy.m4: New file.
4931 * gnulib/import/m4/memrchr.m4: New file.
4932 * gnulib/import/m4/mode_t.m4: New file.
4933 * gnulib/import/m4/msvc-inval.m4: New file.
4934 * gnulib/import/m4/msvc-nothrow.m4: New file.
4935 * gnulib/import/m4/open.m4: New file.
4936 * gnulib/import/m4/openat.m4: New file.
4937 * gnulib/import/m4/opendir.m4: New file.
4938 * gnulib/import/m4/readdir.m4: New file.
4939 * gnulib/import/m4/realloc.m4: New file.
4940 * gnulib/import/m4/rewinddir.m4: New file.
4941 * gnulib/import/m4/save-cwd.m4: New file.
4942 * gnulib/import/m4/strdup.m4: New file.
4943 * gnulib/import/m4/strerror.m4: New file.
4944 * gnulib/import/m4/unistd-safer.m4: New file.
4945 * gnulib/import/mempcpy.c: New file.
4946 * gnulib/import/memrchr.c: New file.
4947 * gnulib/import/msvc-inval.c: New file.
4948 * gnulib/import/msvc-inval.h: New file.
4949 * gnulib/import/msvc-nothrow.c: New file.
4950 * gnulib/import/msvc-nothrow.h: New file.
4951 * gnulib/import/open.c: New file.
4952 * gnulib/import/openat-die.c: New file.
4953 * gnulib/import/openat-priv.h: New file.
4954 * gnulib/import/openat-proc.c: New file.
4955 * gnulib/import/openat.c: New file.
4956 * gnulib/import/openat.h: New file.
4957 * gnulib/import/opendir.c: New file.
4958 * gnulib/import/pipe-safer.c: New file.
4959 * gnulib/import/readdir.c: New file.
4960 * gnulib/import/realloc.c: New file.
4961 * gnulib/import/rewinddir.c: New file.
4962 * gnulib/import/save-cwd.c: New file.
4963 * gnulib/import/save-cwd.h: New file.
4964 * gnulib/import/strdup.c: New file.
4965 * gnulib/import/strerror-override.c: New file.
4966 * gnulib/import/strerror-override.h: New file.
4967 * gnulib/import/strerror.c: New file.
4968 * gnulib/import/unistd--.h: New file.
4969 * gnulib/import/unistd-safer.h: New file.
4970 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
4971 "getcwd" and "glob".
4972 * ser-tcp.c: Undefine "close" before redefining it.
4974 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4976 * guile/scm-value.c (gdbscm_value_address): Initialize address,
4979 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4981 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
4982 <sol2,sparc>: Likewise.
4983 <sol2-64,i386>: Likewise.
4985 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
4986 -Wdeprecated-declarations on *-*-solaris*.
4987 * configure: Regenerate.
4989 * procfs.c: Include "nat/inferior.h".
4990 (procfs_info_proc): Fix typo.
4992 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4994 * remote.c (vector): Include.
4995 (struct private_thread_info): Add field, thread_handle.
4996 (free_private_thread_info): Deallocate storage associated with
4998 (get_private_info_thread): Initialize `thread_handle' field.
4999 (struct thread_item): Add field, thread_handle.
5000 (clear_threads_listing_context): Deallocate storage associated
5002 (start_thread): Add support for "handle" attribute.
5003 (thread_attributes): Add "handle".
5004 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
5006 (remote_update_thread_list): Update thread_handle.
5007 (remote_thread_handle_to_thread_info): New function.
5008 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
5010 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5012 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
5014 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
5015 * python/python-internal.h (thread_object_type): Declare.
5017 2017-09-21 Kevin Buettner <kevinb@redhat.com>
5019 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
5020 (target_thread_handle_to_thread_info): Declare.
5021 * target.c (target_thread_handle_to_thread_info): New function.
5022 * target-delegates.c: Regenerate.
5023 * gdbthread.h (find_thread_by_handle): Declare.
5024 * thread.c (find_thread_by_handle): New function.
5025 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
5027 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
5029 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5031 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
5033 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
5035 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
5037 2017-09-21 Yao Qi <yao.qi@linaro.org>
5039 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
5042 2017-09-20 Tom Tromey <tom@tromey.com>
5044 * breakpoint.c (struct counted_command_line): Remove.
5045 (breakpoint_commands): Update.
5046 (alloc_counted_command_line, incref_counted_command_line)
5047 (decref_counted_command_line, do_cleanup_counted_command_line)
5048 (make_cleanup_decref_counted_command_line): Remove.
5049 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
5050 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
5051 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
5052 (save_breakpoints): Update.
5053 * breakpoint.h (counted_command_line): Now a typedef to
5055 (struct breakpoint) <commands>: Now a counted_command_line.
5056 (struct bpstats) <command>: Likewise.
5058 2017-09-20 Tom Tromey <tom@tromey.com>
5060 * breakpoint.c (struct commands_info, do_map_commands_command):
5062 (commands_command_1): Update.
5063 (iterate_over_related_breakpoints): Take a function_view.
5064 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
5065 (delete_command): Update.
5066 (map_breakpoint_numbers): Take a function_view.
5067 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
5068 (disable_command): Update.
5069 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
5070 (enable_command): Update.
5071 (struct disp_data, do_enable_breakpoint_disp)
5072 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
5073 (do_map_enable_delete_breakpoint): Remove.
5074 (enable_once_command, enable_count_command, enable_delete_command)
5075 (delete_trace_variable_command): Update.
5077 2017-09-20 Tom Tromey <tom@tromey.com>
5079 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
5080 (bpstat_clear): Use delete.
5081 (bpstats): New constructors.
5082 (bpstat_copy, bpstat_stop_status): Use new.
5083 (dprintf_after_condition_true): Update.
5084 * breakpoint.h (bpstats::bpstats): Add constructors.
5085 (bpstats::~bpstats): Add destructor.
5087 2017-09-20 Pedro Alves <palves@redhat.com>
5089 * eval.c (make_params): Delete, refactored as ...
5090 (class fake_method): ... this new type's ctor.
5091 (fake_method::~fake_method): New.
5092 (evaluate_subexp_standard): Use 'fake_method'.
5094 2017-09-20 Tom Tromey <tom@tromey.com>
5096 * windows-nat.c (get_windows_debug_event, windows_wait)
5097 (do_initial_windows_stuff, windows_attach): Update.
5098 * utils.c (vwarning, internal_vproblem): Update.
5099 (ui_unregister_input_event_handler_cleanup)
5100 (prepare_to_handle_input): Remove.
5101 (class scoped_input_handler): New.
5102 (defaulted_query, prompt_for_continue): Update.
5103 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
5105 * top.c (undo_terminal_modifications_before_exit): Update.
5106 * target/target.h (target_terminal_init, target_terminal_inferior)
5107 (target_terminal_ours): Don't declare.
5108 (class target_terminal): New.
5109 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
5110 (target_terminal_ours_for_output)
5111 (make_cleanup_restore_target_terminal): Don't declare.
5112 (target_terminal_info): Remove.
5113 * target.c (enum terminal_state, terminal_state): Remove.
5114 (target_terminal::terminal_state): Define.
5115 (target_terminal::init): Rename from target_terminal_init.
5116 (target_terminal::inferior): Rename from
5117 target_terminal_inferior.
5118 (target_terminal::ours): Rename from target_terminal_ours.
5119 (target_terminal::ours_for_output): Rename from
5120 target_terminal_ours_for_output.
5121 (target_terminal::info): New method.
5122 (cleanup_restore_target_terminal)
5123 (make_cleanup_restore_target_terminal): Remove.
5124 * solib.c (handle_solib_event): Update.
5125 * remote.c (remote_serial_quit_handler): Update.
5126 (remote_terminal_inferior, remote_wait_as): Update.
5127 * record-full.c (record_full_wait_1): Update.
5128 * nto-procfs.c (procfs_create_inferior): Update.
5129 * nat/fork-inferior.c (startup_inferior): Update.
5130 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
5131 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
5132 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
5133 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
5134 (mi_breakpoint_created, mi_breakpoint_deleted)
5135 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
5136 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
5137 (mi_user_selected_context_changed, report_initial_inferior):
5139 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
5140 (linux_nat_terminal_inferior): Update.
5141 * infrun.c (follow_fork_inferior)
5142 (handle_vfork_child_exec_or_exit, do_target_resume)
5143 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
5144 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
5146 * inflow.c (child_terminal_init, info_terminal_command): Update.
5147 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
5148 (attach_command): Update.
5149 * infcall.c (call_thread_fsm_should_stop): Update.
5150 * gnu-nat.c (gnu_attach): Update.
5151 * extension.c (struct active_ext_lang_state)
5152 (restore_active_ext_lang): Update.
5153 * exceptions.c (print_flush): Update.
5154 * event-top.c (async_enable_stdin, default_quit_handler): Update.
5155 (struct quit_handler_cleanup_data, restore_quit_handler)
5156 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
5158 * cp-support.c (gdb_demangle): Update.
5159 * breakpoint.c (update_inserted_breakpoint_locations)
5160 (insert_breakpoint_locations, handle_jit_event)
5161 (disable_breakpoints_in_unloaded_shlib): Update.
5162 * annotate.c (annotate_breakpoints_invalid)
5163 (annotate_frames_invalid): Update.
5165 2017-09-20 Tom Tromey <tom@tromey.com>
5167 * main.c (catch_command_errors): Rename from
5168 catch_command_errors_const.
5169 (captured_main_1): Update.
5171 2017-09-20 Pedro Alves <palves@redhat.com>
5173 * cli/cli-cmds.c (list_command): Use print_sal_location.
5174 (print_sal_location): New function.
5175 (ambiguous_line_spec): Use print_sal_location.
5176 * linespec.c (symbol_to_sal): Record the symbol in the sal.
5177 * symtab.c (find_function_start_sal): Likewise.
5178 * symtab.h (symtab_and_line::symbol): New field.
5180 2017-09-20 Pedro Alves <palves@redhat.com>
5182 * linespec.c (minsym_found): Handle non-text minsyms.
5183 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
5185 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
5187 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
5190 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
5192 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
5193 vmovups instead vmovaps.
5194 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
5196 2017-09-19 John Baldwin <jhb@FreeBSD.org>
5198 * NEWS (Changes since GDB 8.0): Add starti.
5199 * infcmd.c (enum run_break): New.
5200 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
5202 (run_command): Use enum run_how.
5203 (start_command): Likewise.
5204 (starti_command): New function.
5205 (RUN_ARGS_HELP): New macro.
5206 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
5207 commands. Add starti command.
5209 2017-09-19 Yao Qi <yao.qi@linaro.org>
5211 * Makefile.in (monitor.o): Remove the rule.
5213 2017-09-19 Yao Qi <yao.qi@linaro.org>
5215 * annotate.h (struct annotate_arg_emitter): Use
5216 DISABLE_COPY_AND_ASSIGN.
5217 * common/refcounted-object.h (refcounted_object): Likewise.
5218 * completer.h (struct completion_result): Likewise.
5219 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
5220 * filename-seen-cache.h (filename_seen_cache): Likewise.
5221 * gdbcore.h (thread_section_name): Likewise.
5222 * gdb_regex.h (compiled_regex): Likewise.
5223 * gdbthread.h (scoped_restore_current_thread): Likewise.
5224 * inferior.h (scoped_restore_current_inferior): Likewise.
5225 * jit.c (jit_reader): Likewise.
5226 * linespec.h (struct linespec_result): Likewise.
5227 * mi/mi-parse.h (struct mi_parse): Likewise.
5228 * nat/fork-inferior.c (execv_argv): Likewise.
5229 * progspace.h (scoped_restore_current_program_space): Likewise.
5230 * python/python-internal.h (class gdbpy_enter): Likewise.
5231 * regcache.h (regcache): Likewise.
5232 * target-descriptions.c (struct tdesc_reg): Likewise.
5233 (struct tdesc_type): Likewise.
5234 (struct tdesc_feature): Likewise.
5235 * ui-out.h (ui_out_emit_type): Likewise.
5237 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
5239 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
5240 label abort_expression.
5242 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5244 * common/buffer.c (buffer_xml_printf): Adjust.
5245 * common/xml-utils.c (xml_escape_text): Change return type to
5246 std::string, update code accordingly.
5247 * common/xml-utils.h (xml_escape_text): Change return type to
5249 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
5250 * windows-tdep.c (windows_xfer_shared_library): Adjust.
5251 * unittests/xml-utils-selftests.c (test_xml_escape_text):
5254 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5256 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
5257 (SUBDIR_UNITTESTS_OBS): Add new object file.
5258 * unittests/xml-utils-selftests.c: New file.
5260 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5262 * common/selftest.h (selftest): New struct/interface.
5263 (register_test): Add name parameter, add new overload.
5264 (run_tests): Add filter parameter.
5265 (for_each_selftest_ftype): New typedef.
5266 (for_each_selftest): New declaration.
5267 * common/selftest.c (tests): Change type to
5268 map<string, unique_ptr<selftest>>.
5269 (simple_selftest): New struct.
5270 (register_test): New function.
5271 (register_test): Add name parameter and use it.
5272 (run_tests): Add filter parameter and use it. Add prints.
5273 Adjust to vector -> map change.
5274 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
5275 registering selftests.
5276 * arm-tdep.c (_initialize_arm_tdep): Likewise.
5277 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
5278 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
5279 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
5280 * findvar.c (_initialize_findvar): Likewise.
5281 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
5282 * maint.c (maintenance_selftest): Update call to run_tests.
5283 (maintenance_info_selftests): New function.
5284 (_initialize_maint_cmds): Register "maintenance info selftests"
5285 command. Update "maintenance selftest" doc.
5286 * regcache.c (_initialize_regcache): Add names when registering
5288 * rust-exp.y (_initialize_rust_exp): Likewise.
5289 * selftest-arch.c (gdbarch_selftest): New struct.
5290 (gdbarch_tests): Remove.
5291 (register_test_foreach_arch): Add name parameter. Call
5293 (tests_with_arch): Remove, move most content to
5294 gdbarch_selftest::operator().
5295 (_initialize_selftests_foreach_arch): Remove.
5296 * selftest-arch.h (register_test_foreach_arch): Add name
5298 (run_tests_with_arch): New declaration.
5299 * utils-selftests.c (_initialize_utils_selftests): Add names
5300 when registering selftests.
5301 * utils.c (_initialize_utils): Likewise.
5302 * unittests/array-view-selftests.c
5303 (_initialize_array_view_selftests): Likewise.
5304 * unittests/environ-selftests.c (_initialize_environ_selftests):
5306 * unittests/function-view-selftests.c
5307 (_initialize_function_view_selftests): Likewise.
5308 * unittests/offset-type-selftests.c
5309 (_initialize_offset_type_selftests): Likewise.
5310 * unittests/optional-selftests.c
5311 (_initialize_optional_selftests): Likewise.
5312 * unittests/scoped_restore-selftests.c
5313 (_initialize_scoped_restore_selftests): Likewise.
5314 * NEWS: Document "maintenance selftest" and "maint info
5317 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5319 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
5322 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
5324 * mi/mi-main.c (mi_load_progress): Make uiout variable
5327 2017-09-15 Pedro Alves <palves@redhat.com>
5329 * compile/compile-c-types.c (convert_enum, convert_int)
5330 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
5332 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
5334 * dwarf2read.c (copy_string): Remove.
5335 (parse_macro_definition): Replace copy_string with savestring.
5337 2017-09-15 Yao Qi <yao.qi@linaro.org>
5339 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
5341 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
5343 (i[34567]86-*-linux*): Likewise.
5345 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5347 * dwarf2expr.h (dwarf_stack_value): Add constructor.
5348 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
5349 <stack>: Change type to std::vector.
5350 <stack_len, stack_allocated>: Remove.
5351 <grow_stack>: Remove.
5352 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5353 (dwarf_expr_context::~dwarf_expr_context): Remove.
5354 (dwarf_expr_context::grow_stack): Remove.
5355 (dwarf_expr_context::push): Adjust.
5356 (dwarf_expr_context::pop): Adjust.
5357 (dwarf_expr_context::fetch): Adjust.
5358 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
5359 (dwarf_expr_context::stack_empty_p): Adjust.
5360 (dwarf_expr_context::execute_stack_op): Adjust.
5362 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5364 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
5365 return type to bool.
5366 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
5368 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5370 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
5371 Change type to bool.
5372 (dwarf_stack_value) <in_stack_memory>: Likewise.
5373 (dwarf_expr_context) <push_address>: Change parameter type to
5375 <fetch_in_stack_memory>: Change return type to bool.
5376 <push>: Change parameter type to bool.
5377 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
5379 (dwarf_expr_context::push_address): Likewise.
5380 (dwarf_expr_context::fetch_in_stack_memory): Change return type
5382 (dwarf_expr_context::execute_stack_op): Adjust.
5383 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
5385 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
5387 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
5388 (struct dwarf_expr_context) <n_pieces>: Remove.
5389 <pieces>: Change type to std::vector.
5390 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5391 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
5393 (dwarf_expr_context::add_piece): Adjust.
5394 * dwarf2loc.c (struct piece_closure): Initialize fields.
5396 <pieces>: Change type to std::vector.
5397 (allocate_piece_closure): Adjust, change parameter to
5398 std::vector rvalue and std::move it to piece_closure.
5399 (rw_pieced_value): Adjust.
5400 (check_pieced_synthetic_pointer): Adjust.
5401 (indirect_synthetic_pointer): Adjust.
5402 (coerce_pieced_ref): Adjust.
5403 (free_pieced_value_closure): Adjust. Use delete to free
5405 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
5406 to allocate_piece_closure.
5407 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
5409 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5411 * probe.h (probe_ops_cp): Remove typedef.
5412 (DEF_VEC_P (probe_ops_cp)): Remove.
5413 (all_probe_ops): Change type to std::vector.
5414 * probe.c (info_probes_for_ops): Adjust to vector change.
5415 (probe_linespec_to_ops): Likewise.
5416 (all_probe_ops): Change type to std::vector.
5417 (_initialize_probe): Adjust to vector change.
5418 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
5419 * elfread.c (elf_get_probes): Likewise.
5420 * stap-probe.c (_initialize_stap_probe): Likewise.
5422 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5424 * probe.h (struct bound_probe): Define constructors.
5425 * probe.c (bound_probe_s): Remove typedef.
5426 (DEF_VEC_O (bound_probe_s)): Remove VEC.
5427 (collect_probes): Change return type to std::vector, remove
5429 (compare_probes): Return bool, change parameter type. Change
5430 semantic to "less than".
5431 (gen_ui_out_table_header_info): Change parameter to std::vector
5433 (exists_probe_with_pops): Likewise.
5434 (info_probes_for_ops): Update to std::vector change.
5435 (enable_probes_command): Likewise.
5436 (disable_probes_command): Likewise.
5438 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5440 * probe.h (struct probe_ops) <get_probes>: Change parameter from
5442 * probe.c (parse_probes_in_pspace): Update.
5443 (find_probes_in_objfile): Update.
5444 (find_probe_by_pc): Update.
5445 (collect_probes): Update.
5446 (probe_any_get_probes): Update.
5447 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
5448 return type to reference to std::vector.
5449 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
5450 std::vector and update.
5451 (dtrace_process_dof): Likewise.
5452 (dtrace_get_probes): Likewise.
5453 * elfread.c (elf_get_probes): Change return type to std::vector,
5454 store an std::vector in bfd_data.
5455 (probe_key_free): Update to std::vector.
5456 * stap-probe.c (handle_stap_probe): Change parameter to
5457 std::vector and update.
5458 (stap_get_probes): Likewise.
5459 * symfile-debug.c (debug_sym_get_probes): Change return type to
5460 std::vector and update.
5462 2017-09-11 Tom Tromey <tom@tromey.com>
5464 * breakpoint.c (program_breakpoint_here_p): Update.
5465 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
5466 from make_show_memory_breakpoints_cleanup. Return a
5467 scoped_restore_tmpl<int>.
5468 (restore_show_memory_breakpoints): Remove.
5469 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
5470 * mem-break.c (memory_validate_breakpoint): Update.
5471 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
5472 (ia64_memory_remove_breakpoint): Update.
5473 (ia64_breakpoint_from_pc): Update.
5474 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
5475 from make_show_memory_breakpoints_cleanup.
5477 2017-09-11 Tom Tromey <tom@tromey.com>
5479 * d-namespace.c (d_lookup_symbol): Use std::string.
5480 (find_symbol_in_baseclass): Likewise.
5482 2017-09-11 Tom Tromey <tom@tromey.com>
5484 * ctf.c (ctf_start): Use std::string.
5486 2017-09-11 Tom Tromey <tom@tromey.com>
5488 * ada-lang.c (is_known_support_routine): Update.
5489 (ada_unhandled_exception_name_addr_from_raise): Update.
5490 * guile/scm-frame.c (gdbscm_frame_name): Update.
5491 * python/py-frame.c (frapy_name): Update.
5492 (frapy_function): Update.
5493 * stack.h (find_frame_funname): Update.
5494 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
5495 (print_frame): Update.
5497 2017-09-11 Tom Tromey <tom@tromey.com>
5499 * findcmd.c (put_bits): Take a gdb::byte_vector.
5500 (parse_find_args): Return gdb::byte_vector. "args" now const.
5501 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
5503 (find_command): Update.
5505 2017-09-11 Tom Tromey <tom@tromey.com>
5507 * cli/cli-script.c (class scoped_restore_hook_in): New.
5508 (clear_hook_in_cleanup): Remove.
5509 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
5510 scoped_restore_hook_in.
5512 2017-09-11 Tom Tromey <tom@tromey.com>
5514 * cli/cli-script.c (restore_interp): Remove.
5515 (read_command_lines): Use scoped_restore_interp.
5516 * interps.c (scoped_restore_interp::set_temp): Rename from
5518 * interps.h (class scoped_restore_interp): New.
5519 (interp_set_temp): Remove.
5521 2017-09-11 Tom Tromey <tom@tromey.com>
5523 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5524 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
5525 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
5527 (mi_cmd_break_insert_1): Update.
5528 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
5531 2017-09-11 Tom Tromey <tom@tromey.com>
5533 * demangle.c (demangle_command): Update.
5534 * breakpoint.c (disable_command): Update.
5535 (enable_command): Update.
5536 (find_location_by_number): Make "number" const. Use
5538 * cli/cli-utils.c (extract_arg): Return std::string.
5539 * probe.c (parse_probe_linespec): Update. Change types.
5540 (collect_probes): Take string arguments.
5541 (parse_probe_linespec): Likewise.
5542 (info_probes_for_ops): Update.
5543 (enable_probes_command): Update.
5544 (disable_probes_command): Update.
5545 * break-catch-sig.c (catch_signal_split_args): Update.
5546 * mi/mi-parse.c (mi_parse): Update.
5548 2017-09-11 Tom Tromey <tom@tromey.com>
5550 * language.h (language_enum): Make argument const.
5551 * language.c (language_enum): Make argument const.
5553 2017-09-11 Tom Tromey <tom@tromey.com>
5555 * common/common-utils.h (skip_to_space): Remove macro, redeclare
5557 (skip_to_space): Rename from skip_to_space_const.
5558 * common/common-utils.c (skip_to_space): New function.
5559 (skip_to_space): Rename from skip_to_space_const.
5560 * cli/cli-utils.h (get_number): Rename from get_number_const.
5561 (extract_arg): Rename from extract_arg_const.
5562 * cli/cli-utils.c (get_number): Rename from get_number_const.
5563 (extract_arg): Rename from extract_arg_const.
5564 (number_or_range_parser::get_number): Use ::get_number.
5565 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
5566 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
5567 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
5568 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
5569 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
5570 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
5571 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
5572 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
5574 2017-09-11 Tom Tromey <tom@tromey.com>
5576 * python/python.c (do_start_initialization): Use
5577 py-event-types.def to initialize types.
5578 Define all object type structures.
5579 * python/python-internal.h: Don't declare event initialization
5581 * python/py-threadevent.c (thread_event_object_type): Don't
5583 * python/py-stopevent.c (stop_event_object_type): Don't define.
5584 * python/py-signalevent.c (signal_event_object_type): Don't
5586 * python/py-newobjfileevent.c (new_objfile_event_object_type)
5587 (clear_objfiles_event_object_type): Don't declare or define.
5588 * python/py-infevents.c (inferior_call_pre_event_object_type)
5589 (inferior_call_post_event_object_type)
5590 (register_changed_event_object_type)
5591 (memory_changed_event_object_type): Don't declare or define.
5592 * python/py-inferior.c (new_thread_event_object_type)
5593 (new_inferior_event_object_type)
5594 (inferior_deleted_event_object_type): Don't declare or define.
5595 * python/py-exitedevent.c (exited_event_object_type): Don't
5597 * python/py-evts.c (gdbpy_initialize_py_events): Use
5599 * python/py-events.h (thread_event_object_type): Don't declare.
5600 (events_object): Use py-all-events.def.
5601 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
5603 * python/py-event-types.def: New file.
5604 * python/py-continueevent.c (create_continue_event_object): Don't
5606 * python/py-bpevent.c (breakpoint_event_object_type): Don't
5608 * python/py-all-events.def: New file.
5610 2017-09-11 Tom Tromey <tom@tromey.com>
5612 * python/py-threadevent.c (create_thread_event_object): Return
5614 * python/py-stopevent.h (create_stop_event_object)
5615 (create_breakpoint_event_object, create_signal_event_object):
5617 * python/py-stopevent.c (create_stop_event_object): Return
5619 (emit_stop_event): Update.
5620 * python/py-signalevent.c (create_signal_event_object): Return
5622 * python/py-infevents.c (create_inferior_call_event_object):
5624 * python/py-event.h (create_event_object)
5625 (create_thread_event_object): Update.
5626 * python/py-event.c (create_event_object): Return gdbpy_ref.
5627 * python/py-continueevent.c: Return gdbpy_ref.
5628 * python/py-bpevent.c (create_breakpoint_event_object): Return
5631 2017-09-11 Tom Tromey <tom@tromey.com>
5635 * python/python.c (do_start_initialization): Initialize new event
5637 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
5638 (gdbpy_initialize_inferior_deleted_event)
5639 (gdbpy_initialize_new_thread_event): Declare.
5640 * python/py-threadevent.c (create_thread_event_object): Add option
5642 * python/py-inferior.c (new_thread_event_object_type)
5643 (new_inferior_event_object_type)
5644 (inferior_deleted_event_object_type): Declare.
5645 (python_new_inferior, python_inferior_deleted): New functions.
5646 (add_thread_object): Emit new_thread event.
5647 (gdbpy_initialize_inferior): Attach new functions to corresponding
5649 (new_thread, new_inferior, inferior_deleted): Define new event
5651 * python/py-evts.c (gdbpy_initialize_py_events): Add new
5653 * python/py-events.h (events_object) <new_inferior,
5654 inferior_deleted, new_thread>: New fields.
5655 * python/py-event.h (create_thread_event_breakpoint): Add optional
5658 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
5660 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
5661 check current_ui instead.
5662 (internal_vproblem): Likewise.
5664 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
5666 * thread.c (print_thread_info_1): Remove unnecessary calls to
5667 uiout->is_mi_like_p.
5669 2017-09-09 Tom Tromey <tom@tromey.com>
5671 * namespace.h (add_using_directive): Update.
5672 * namespace.c (add_using_directive): Change type of excludes to
5674 * dwarf2read.c (read_import_statement): Use std::vector.
5675 (read_namespace): Update.
5676 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
5678 2017-09-09 Tom Tromey <tom@tromey.com>
5680 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
5682 2017-09-09 Tom Tromey <tom@tromey.com>
5684 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
5686 2017-09-09 Tom Tromey <tom@tromey.com>
5688 * stack.c (func_command): Use gdb::def_vector.
5690 2017-09-09 Tom Tromey <tom@tromey.com>
5692 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
5693 ui_out_emit_list, ui_out_emit_tuple.
5694 (mi_cmd_var_update): Likewise.
5696 2017-09-09 Tom Tromey <tom@tromey.com>
5698 * mi/mi-interp.c (mi_user_selected_context_changed): Use
5699 ui_out_redirect_pop.
5700 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
5701 ui_out_redirect_pop.
5702 * utils.c (do_ui_out_redirect_pop)
5703 (make_cleanup_ui_out_redirect_pop): Remove.
5704 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
5705 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
5706 * ui-out.h (ui_out_redirect_pop): New class.
5708 2017-09-09 Tom Tromey <tom@tromey.com>
5710 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
5711 (list_available_thread_groups, mi_cmd_list_thread_groups)
5712 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
5713 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
5716 2017-09-09 Tom Tromey <tom@tromey.com>
5718 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
5721 2017-09-09 Tom Tromey <tom@tromey.com>
5723 * target.c (flash_erase_command): Use ui_out_emit_tuple.
5724 * stack.c (print_frame): Use ui_out_emit_tuple.
5725 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
5726 (info_spu_mailbox_command, info_spu_dma_command)
5727 (info_spu_proxydma_command): Likewise.
5728 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
5729 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
5730 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
5732 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
5734 2017-09-09 Tom Tromey <tom@tromey.com>
5736 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
5737 (class ui_out_emit_table): Update comment.
5738 * ui-out.c (do_cleanup_table_end)
5739 (make_cleanup_ui_out_table_begin_end): Remove.
5740 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
5741 (info_spu_dma_cmdlist): Likewise.
5742 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
5743 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
5746 2017-09-09 Tom Tromey <tom@tromey.com>
5748 * thread.c (print_thread_info_1): Use ui_out_emit_table,
5749 ui_out_emit_list, gdb::optional.
5751 2017-09-09 John Baldwin <jhb@FreeBSD.org>
5753 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
5755 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
5757 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
5759 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
5760 * ada-exp.y: Remove _initialize_ada_exp prototype.
5761 * ada-lang.c: Remove _initialize_ada_language prototype.
5762 * ada-tasks.c: Remove _initialize_tasks prototype.
5763 * addrmap.c: Remove _initialize_addrmap prototype.
5764 * agent.c: Remove _initialize_agent prototype.
5765 * aix-thread.c: Remove _initialize_aix_thread prototype.
5766 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
5767 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
5768 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
5770 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
5771 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
5772 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
5773 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
5775 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
5777 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
5778 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
5779 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
5780 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
5782 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
5783 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
5784 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
5785 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
5786 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5787 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
5788 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
5790 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
5792 * annotate.c: Remove _initialize_annotate prototype.
5793 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
5794 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
5795 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
5796 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
5797 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
5798 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
5799 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
5800 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
5802 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
5803 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
5804 * auto-load.c: Remove _initialize_auto_load prototype.
5805 * auxv.c: Remove _initialize_auxv prototype.
5806 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
5807 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
5808 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
5809 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
5810 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
5811 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
5813 * break-catch-throw.c: Remove _initialize_break_catch_throw
5815 * breakpoint.c: Remove _initialize_breakpoint prototype.
5816 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
5817 * btrace.c: Remove _initialize_btrace prototype.
5818 * charset.c: Remove _initialize_charset prototype.
5819 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
5820 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
5821 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
5822 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
5823 * cli/cli-script.c: Remove _initialize_cli_script prototype.
5824 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
5825 * coffread.c: Remove _initialize_coffread prototype.
5826 * compile/compile.c: Remove _initialize_compile prototype.
5827 * complaints.c: Remove _initialize_complaints prototype.
5828 * completer.c: Remove _initialize_completer prototype.
5829 * copying.awk: Remove _initialize_copying prototype.
5830 * copying.c: Regenerate.
5831 * core-regset.c: Remove _initialize_core_regset prototype.
5832 * corefile.c: Remove _initialize_core prototype.
5833 * corelow.c: Remove _initialize_corelow prototype.
5834 * cp-abi.c: Remove _initialize_cp_abi prototype.
5835 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
5836 * cp-support.c: Remove _initialize_cp_support prototype.
5837 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
5838 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
5839 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
5840 * ctf.c: Remove _initialize_ctf prototype.
5841 * d-lang.c: Remove _initialize_d_language prototype.
5842 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
5844 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
5845 * dbxread.c: Remove _initialize_dbxread prototype.
5846 * dcache.c: Remove _initialize_dcache prototype.
5847 * demangle.c: Remove _initialize_demangler prototype.
5848 * disasm-selftests.c: Remove _initialize_disasm_selftests
5850 * disasm.c: Remove _initialize_disasm prototype.
5851 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
5852 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
5853 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
5855 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
5856 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
5857 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
5858 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
5859 * elfread.c: Remove _initialize_elfread prototype.
5860 * exec.c: Remove _initialize_exec prototype.
5861 * extension.c: Remove _initialize_extension prototype.
5862 * f-lang.c: Remove _initialize_f_language prototype.
5863 * f-valprint.c: Remove _initialize_f_valprint prototype.
5864 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
5865 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
5866 * filesystem.c: Remove _initialize_filesystem prototype.
5867 * findcmd.c: Remove _initialize_mem_search prototype.
5868 * fork-child.c: Remove _initialize_fork_child prototype.
5869 * frame-base.c: Remove _initialize_frame_base prototype.
5870 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
5871 * frame.c: Remove _initialize_frame prototype.
5872 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
5873 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
5874 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
5875 * gcore.c: Remove _initialize_gcore prototype.
5876 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
5877 * gdbarch.c: Regenerate.
5878 * gdbarch.sh: Remove _initialize_gdbarch prototype.
5879 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
5880 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
5881 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
5882 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
5883 * go-lang.c: Remove _initialize_go_language prototype.
5884 * go32-nat.c: Remove _initialize_go32_nat prototype.
5885 * guile/guile.c: Remove _initialize_guile prototype.
5886 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
5887 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
5888 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
5889 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
5890 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
5891 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
5892 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
5893 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
5894 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
5895 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
5897 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
5899 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
5900 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
5901 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
5902 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
5903 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
5904 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
5905 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
5906 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
5907 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
5908 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
5909 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
5910 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
5911 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
5912 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5913 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
5914 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
5916 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
5918 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
5919 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
5920 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
5921 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
5922 * infcall.c: Remove _initialize_infcall prototype.
5923 * infcmd.c: Remove _initialize_infcmd prototype.
5924 * inferior.c: Remove _initialize_inferiors prototype.
5925 * inflow.c: Remove _initialize_inflow prototype.
5926 * infrun.c: Remove _initialize_infrun prototype.
5927 * interps.c: Remove _initialize_interpreter prototype.
5928 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
5929 * jit.c: Remove _initialize_jit prototype.
5930 * language.c: Remove _initialize_language prototype.
5931 * linux-fork.c: Remove _initialize_linux_fork prototype.
5932 * linux-nat.c: Remove _initialize_linux_nat prototype.
5933 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
5934 * linux-thread-db.c: Remove _initialize_thread_db prototype.
5935 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
5936 * m2-lang.c: Remove _initialize_m2_language prototype.
5937 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
5938 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
5939 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
5940 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
5941 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
5942 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5943 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5944 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
5945 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
5946 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
5947 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5948 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5949 * machoread.c: Remove _initialize_machoread prototype.
5950 * macrocmd.c: Remove _initialize_macrocmd prototype.
5951 * macroscope.c: Remove _initialize_macroscope prototype.
5952 * maint.c: Remove _initialize_maint_cmds prototype.
5953 * mdebugread.c: Remove _initialize_mdebugread prototype.
5954 * memattr.c: Remove _initialize_mem prototype.
5955 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
5956 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
5957 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
5958 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
5959 * mi/mi-main.c: Remove _initialize_mi_main prototype.
5960 * microblaze-linux-tdep.c: Remove
5961 _initialize_microblaze_linux_tdep prototype.
5962 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
5963 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
5964 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
5965 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
5966 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
5967 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
5968 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
5969 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
5970 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
5971 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
5972 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
5974 * mipsread.c: Remove _initialize_mipsread prototype.
5975 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
5977 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
5978 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
5979 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
5980 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
5981 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
5982 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
5984 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
5985 * nto-procfs.c: Remove _initialize_procfs prototype.
5986 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
5987 * objc-lang.c: Remove _initialize_objc_language prototype.
5988 * objfiles.c: Remove _initialize_objfiles prototype.
5989 * observer.c: Remove observer_test_first_notification_function,
5990 observer_test_second_notification_function,
5991 observer_test_third_notification_function, and
5992 _initialize_observer prototypes.
5993 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
5994 * osabi.c: Remove _initialize_gdb_osabi prototype.
5995 * osdata.c: Remove _initialize_osdata prototype.
5996 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
5997 * parse.c: Remove _initialize_parse prototype.
5998 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
5999 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
6000 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
6001 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
6002 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
6003 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
6004 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
6005 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
6006 * printcmd.c: Remove _initialize_printcmd prototype.
6007 * probe.c: Remove _initialize_probe prototype.
6008 * proc-api.c: Remove _initialize_proc_api prototype.
6009 * proc-events.c: Remove _initialize_proc_events prototype.
6010 * proc-service.c: Remove _initialize_proc_service prototype.
6011 * procfs.c: Remove _initialize_procfs prototype.
6012 * psymtab.c: Remove _initialize_psymtab prototype.
6013 * python/python.c: Remove _initialize_python prototype.
6014 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
6015 * record-btrace.c: Remove _initialize_record_btrace prototype.
6016 * record-full.c: Remove _initialize_record_full prototype.
6017 * record.c: Remove _initialize_record prototype.
6018 * regcache.c: Remove _initialize_regcache prototype.
6019 * reggroups.c: Remove _initialize_reggroup prototype.
6020 * remote-notif.c: Remove _initialize_notif prototype.
6021 * remote-sim.c: Remove _initialize_remote_sim prototype.
6022 * remote.c: Remove _initialize_remote prototype.
6023 * reverse.c: Remove _initialize_reverse prototype.
6024 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
6025 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
6026 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
6028 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
6029 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
6030 * rust-exp.y: Remove _initialize_rust_exp prototype.
6031 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
6032 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
6033 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
6034 * score-tdep.c: Remove _initialize_score_tdep prototype.
6035 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
6037 * ser-go32.c: Remove _initialize_ser_dos prototype.
6038 * ser-mingw.c: Remove _initialize_ser_windows prototype.
6039 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
6040 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
6041 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
6042 * serial.c: Remove _initialize_serial prototype.
6043 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
6044 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
6045 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
6046 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
6047 * skip.c: Remove _initialize_step_skip prototype.
6048 * sol-thread.c: Remove _initialize_sol_thread prototype.
6049 * solib-aix.c: Remove _initialize_solib_aix prototype.
6050 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
6051 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
6052 * solib-frv.c: Remove _initialize_frv_solib prototype.
6053 * solib-spu.c: Remove _initialize_spu_solib prototype.
6054 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
6055 * solib-target.c: Remove _initialize_solib_target prototype.
6056 * solib.c: Remove _initialize_solib prototype.
6057 * source.c: Remove _initialize_source prototype.
6058 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
6059 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
6061 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
6062 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
6063 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
6064 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
6066 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
6067 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
6068 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
6069 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
6071 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
6073 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
6075 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
6077 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
6078 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
6080 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
6082 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
6084 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
6086 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
6088 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
6089 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
6090 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
6091 * stabsread.c: Remove _initialize_stabsread prototype.
6092 * stack.c: Remove _initialize_stack prototype.
6093 * stap-probe.c: Remove _initialize_stap_probe prototype.
6094 * std-regs.c: Remove _initialize_frame_reg prototype.
6095 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
6096 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
6097 * symfile.c: Remove _initialize_symfile prototype.
6098 * symmisc.c: Remove _initialize_symmisc prototype.
6099 * symtab.c: Remove _initialize_symtab prototype.
6100 * target-dcache.c: Remove _initialize_target_dcache prototype.
6101 * target-descriptions.c: Remove _initialize_target_descriptions
6103 * thread.c: Remove _initialize_thread prototype.
6104 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
6106 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
6107 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
6108 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
6110 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
6111 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
6112 * tracefile.c: Remove _initialize_tracefile prototype.
6113 * tracepoint.c: Remove _initialize_tracepoint prototype.
6114 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
6115 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
6116 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
6117 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
6118 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
6119 * tui/tui-win.c: Remove _initialize_tui_win prototype.
6120 * tui/tui.c: Remove _initialize_tui prototype.
6121 * typeprint.c: Remove _initialize_typeprint prototype.
6122 * user-regs.c: Remove _initialize_user_regs prototype.
6123 * utils.c: Remove _initialize_utils prototype.
6124 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
6125 * valarith.c: Remove _initialize_valarith prototype.
6126 * valops.c: Remove _initialize_valops prototype.
6127 * valprint.c: Remove _initialize_valprint prototype.
6128 * value.c: Remove _initialize_values prototype.
6129 * varobj.c: Remove _initialize_varobj prototype.
6130 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
6131 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
6132 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
6133 * windows-nat.c: Remove _initialize_windows_nat,
6134 _initialize_check_for_gdb_ini, and _initialize_loadable
6136 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
6137 * xcoffread.c: Remove _initialize_xcoffread prototype.
6138 * xml-support.c: Remove _initialize_xml_support prototype.
6139 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
6140 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
6142 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
6144 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
6146 2017-09-08 Keith Seitz <keiths@redhat.com>
6148 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
6151 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
6153 * f-valprint.c (f_val_print): Remove check for one byte
6154 sized integers. Remove printing of character type.
6156 2017-09-08 Frank Penczek <frank.penczek@intel.com>
6157 Christoph Weinmann <christoph.t.weinmann@intel.com>
6158 Bernhard Heckel <bernhard.heckel@intel.com>
6160 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
6161 to maintain proper indentation when printing pointers/refs.
6163 2017-09-07 Joel Brobecker <brobecker@adacore.com>
6167 2017-09-07 Joel Brobecker <brobecker@adacore.com>
6169 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
6171 2017-09-05 Tom Tromey <tom@tromey.com>
6173 * parse.c (funcall_chain): Now a std::vector.
6174 (start_arglist, end_arglist): Simplify.
6175 (free_funcalls): Remove.
6176 (parse_exp_in_context_1): Remove cleanup.
6178 2017-09-05 Tom Tromey <tom@tromey.com>
6180 * go-exp.y (go_parse): Don't create a cleanup.
6182 2017-09-05 Tom Tromey <tom@tromey.com>
6184 * d-exp.y (PrimaryExpression): Use std::string.
6185 (d_parse): Don't create a cleanup.
6187 2017-09-05 Tom Tromey <tom@tromey.com>
6189 * utils.c (do_clear_parser_state): Remove.
6190 (make_cleanup_clear_parser_state): Remove.
6191 * p-exp.y (pascal_parse): Use scoped_restore.
6192 * m2-exp.y (m2_parse): Use scoped_restore.
6193 * f-exp.y (f_parse): Use scoped_restore.
6194 * d-exp.y (d_parse): Use scoped_restore.
6195 * c-exp.y (c_parse): Use scoped_restore.
6196 * ada-exp.y (ada_parse): Use scoped_restore.
6197 * utils.h (make_cleanup_clear_parser_state): Remove.
6199 2017-09-06 Keith Seitz <keiths@redhat.com>
6201 * dwarf2read.c (dw2_linkage_name_attr): New function.
6202 (dw2_linkage_name): New function.
6203 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
6204 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
6205 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
6207 2017-09-06 Kamil Rytarowski <n54@gmx.com>
6209 * config/djgpp/djconfig.sh: Correct shell portability issue.
6211 2017-09-06 Kamil Rytarowski <n54@gmx.com>
6213 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
6215 2017-09-06 John Baldwin <jhb@FreeBSD.org>
6217 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
6218 * NEWS: Mention new FreeBSD/mips native configuration.
6219 * configure.host: Add aarch64*-*-freebsd*.
6220 * configure.nat: Likewise.
6221 * aarch64-fbsd-nat.c: New file.
6223 2017-09-06 John Baldwin <jhb@FreeBSD.org>
6225 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
6226 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
6227 * NEWS: Mention new FreeBSD/aarch64 target.
6228 * configure.tgt: Add aarch64*-*-freebsd*.
6229 * aarch64-fbsd-tdep.c: New file.
6230 * aarch64-fbsd-tdep.h: New file.
6232 2017-09-06 Kamil Rytarowski <n54@gmx.com>
6234 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
6236 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
6238 * parse.c (find_minsym_type_and_address): Don't relocate addresses
6241 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6243 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
6246 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6248 * infrun.c (follow_exec): Call add_thread after
6249 target_find_description.
6251 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6253 * infrun.c (handle_inferior_event_1): When exec'ing, read
6254 stop_pc after follow_exec.
6256 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6258 * remote.c (process_g_packet): Update error message.
6260 2017-09-05 Yao Qi <yao.qi@linaro.org>
6262 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
6265 2017-09-05 Pedro Alves <palves@redhat.com>
6267 * eval.c (eval_call, evaluate_funcall): New functions, factored
6269 (evaluate_subexp_standard): ... this.
6271 2017-09-05 Yao Qi <yao.qi@linaro.org>
6273 * amd64-tdep.c (amd64_target_description): Create target
6275 (_initialize_amd64_tdep): Don't call functions
6276 initialize_tdesc_amd64_*. Add self tests.
6277 * arch/amd64.c (amd64_create_target_description): Add parameter
6278 is_linux. Call set_tdesc_osabi if is_linux is true.
6279 * arch/amd64.h (amd64_create_target_description): Update the
6281 * arch/i386.c (i386_create_target_description): Add parameter
6282 is_linux. Call set_tdesc_osabi if is_linux is true.
6283 * arch/i386.h (i386_create_target_description): Update
6285 * configure.tgt: Add i386.o to gdb_target_obs.
6286 * features/Makefile (XMLTOC): Remove i386/*.xml.
6287 * features/i386/amd64-avx-avx512.c: Remove.
6288 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
6289 * features/i386/amd64-avx-mpx.c: Remove.
6290 * features/i386/amd64-avx.c: Remove.
6291 * features/i386/amd64-mpx.c: Remove.
6292 * features/i386/amd64.c: Remove.
6293 * features/i386/i386-avx-avx512.c: Remove.
6294 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
6295 * features/i386/i386-avx-mpx.c: Remove.
6296 * features/i386/i386-avx.c: Remove.
6297 * features/i386/i386-mmx.c: Remove.
6298 * features/i386/i386-mpx.c: Remove.
6299 * features/i386/i386.c: Remove.
6300 * i386-tdep.c: Don't include features/i386/i386*.c., include
6301 target-descriptions.h and arch/i386.h.
6302 (i386_target_description): Create target descriptions.
6303 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
6304 functions. Do self tests.
6306 2017-09-05 Yao Qi <yao.qi@linaro.org>
6308 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
6309 * features/i386/amd64-avx-avx512-linux.c: Removed.
6310 * features/i386/amd64-avx-linux.c: Removed.
6311 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
6312 * features/i386/amd64-avx-mpx-linux.c: Removed.
6313 * features/i386/amd64-linux.c: Removed.
6314 * features/i386/amd64-mpx-linux.c: Removed.
6315 * features/i386/x32-avx-avx512-linux.c: Removed.
6316 * features/i386/x32-avx-linux.c: Removed.
6317 * features/i386/x32-linux.c: Removed.
6319 2017-09-05 Yao Qi <yao.qi@linaro.org>
6321 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
6323 (amd64_linux_read_description): Call
6324 amd64_create_target_description.
6325 * arch/amd64.c: New file.
6326 * arch/amd64.h: New file.
6327 * configure.tgt (x86_64-*-linux*): Append amd64.o.
6328 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
6330 2017-09-05 Yao Qi <yao.qi@linaro.org>
6332 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
6333 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
6334 (amd64_linux_read_description): Create target descriptions.
6335 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
6336 functions. Add unit tests.
6337 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
6339 * features/i386/64bit-avx.c: Generated.
6340 * features/i386/64bit-avx512.c: Generated.
6341 * features/i386/64bit-core.c: Generated.
6342 * features/i386/64bit-linux.c: Generated.
6343 * features/i386/64bit-mpx.c: Generated.
6344 * features/i386/64bit-pkeys.c: Generated.
6345 * features/i386/64bit-segments.c: Generated.
6346 * features/i386/64bit-sse.c: Generated.
6347 * features/i386/x32-core.c: Generated.
6348 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
6349 c files for amd64-linux and x32-linux.
6351 2017-09-05 Yao Qi <yao.qi@linaro.org>
6353 * amd64-linux-tdep.c (amd64_linux_read_description): New
6355 (amd64_linux_core_read_description): Call
6356 amd64_linux_read_description.
6357 (amd64_linux_init_abi): Likewise.
6358 (amd64_x32_linux_init_abi): Likewise.
6359 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
6360 * x86-linux-nat.c (x86_linux_read_description): Call
6361 amd64_linux_read_description.
6363 2017-09-05 Yao Qi <yao.qi@linaro.org>
6365 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
6368 2017-09-05 Yao Qi <yao.qi@linaro.org>
6370 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
6371 * features/i386/i386-avx-avx512-linux.c: Remove.
6372 * features/i386/i386-avx-linux.c: Remove.
6373 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
6374 * features/i386/i386-avx-mpx-linux.c: Remove.
6375 * features/i386/i386-linux.c: Remove.
6376 * features/i386/i386-mmx-linux.c: Remove.
6377 * features/i386/i386-mpx-linux.c: Remove.
6379 2017-09-05 Yao Qi <yao.qi@linaro.org>
6381 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
6382 (SFILES): Add arch/i386.c.
6383 (HFILES_NO_SRCDIR): Add arch/i386.h.
6384 * arch/i386.c: New file.
6385 * arch/i386.h: New file.
6386 * arch/tdesc.h (allocate_target_description): Declare.
6387 (set_tdesc_architecture): Declare.
6388 (set_tdesc_osabi): Declare.
6389 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
6390 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
6391 include arch/i386.h.
6392 (i386_linux_read_description): Remove code and call
6393 i386_create_target_description.
6394 (set_tdesc_architecture): New function.
6395 (set_tdesc_osabi): New function.
6396 * target-descriptions.h (allocate_target_description): Remove.
6398 2017-09-05 Yao Qi <yao.qi@linaro.org>
6400 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
6401 * target-descriptions.c (tdesc_create_feature): Likewise, and
6403 * features/i386/32bit-avx.c: Re-generated.
6404 * features/i386/32bit-avx512.c: Re-generated.
6405 * features/i386/32bit-core.c: Re-generated.
6406 * features/i386/32bit-linux.c: Re-generated.
6407 * features/i386/32bit-mpx.c: Re-generated.
6408 * features/i386/32bit-pkeys.c: Re-generated.
6409 * features/i386/32bit-sse.c: Re-generated.
6411 2017-09-05 Yao Qi <yao.qi@linaro.org>
6413 * regformats/regdef.h (struct reg): Override operator == and !=.
6415 2017-09-05 Yao Qi <yao.qi@linaro.org>
6417 * arch/tdesc.h: New file.
6418 * regformats/regdat.sh: Generate code using tdesc_create_reg.
6419 * target-descriptions.c: Update comments.
6420 * target-descriptions.h: Include "arch/tdesc.h". Remove the
6422 * features/i386/32bit-avx.c: Re-generated.
6423 * features/i386/32bit-avx512.c: Re-generated.
6424 * features/i386/32bit-core.c: Re-generated.
6425 * features/i386/32bit-linux.c: Re-generated.
6426 * features/i386/32bit-mpx.c: Re-generated.
6427 * features/i386/32bit-pkeys.c: Re-generated.
6428 * features/i386/32bit-sse.c: Re-generated.
6430 2017-09-05 Yao Qi <yao.qi@linaro.org>
6432 * regformats/regdat.sh: Update generated code.
6434 2017-09-05 Yao Qi <yao.qi@linaro.org>
6436 * regformats/regdat.sh: Adjust code order.
6438 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6440 * expprint.c (dump_subexp_body_standard): Use constant format
6441 string in fprintf_filtered call.
6443 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6445 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
6447 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
6449 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6451 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
6453 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6455 * bsd-kvm.o: Define _KMEMUSER.
6456 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
6457 * configure: Regenerate.
6459 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6461 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
6462 * i386-fbsd-nat.c: Likewise.
6464 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6466 * unittests/array-view-selftests.c: Add include of <array>.
6468 2017-09-04 John Baldwin <jhb@FreeBSD.org>
6470 * spu-tdep.c (flush_ea_cache): Add missing argument to
6471 call_function_by_hand.
6473 2017-09-04 Pedro Alves <palves@redhat.com>
6475 * NEWS (Safer support for debugging with no debug info): New.
6477 2017-09-04 Pedro Alves <palves@redhat.com>
6479 * c-exp.y (function_method, function_method_void): Add current
6480 instance flags to TYPE_INSTANCE.
6481 * dwarf2read.c (check_modifier): New.
6482 (compute_delayed_physnames): Assert that only C++ adds delayed
6483 physnames. Mark fn_fields as const/volatile depending on
6485 * eval.c (make_params): New type_instance_flags parameter. Use
6486 it as the new type's instance flags.
6487 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
6488 flags element and pass it to make_params.
6489 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
6490 instance flags element.
6491 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
6492 * gdbtypes.h: Include "enum-flags.h".
6493 (type_instance_flags): New enum-flags type.
6494 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
6495 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
6496 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
6497 (follow_type_instance_flags): New function.
6498 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
6499 * parser-defs.h (follow_type_instance_flags): Declare.
6500 * valops.c (value_struct_elt_for_reference): const/volatile must
6503 2017-09-04 Pedro Alves <palves@redhat.com>
6505 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
6506 function/method scopes; lookup the nested name as a function local
6509 2017-09-04 Pedro Alves <palves@redhat.com>
6511 (%type <voidval>): Add function_method.
6512 * c-exp.y (exp): New production for calls with no arguments.
6513 (function_method, function_method_void_or_typelist): New
6515 (exp): New production for "method()::static_var".
6516 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
6517 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6518 Handle OP_FUNC_STATIC_VAR.
6519 * parse.c (operator_length_standard):
6520 Handle OP_FUNC_STATIC_VAR.
6522 2017-09-04 Pedro Alves <palves@redhat.com>
6524 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
6526 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6528 * parse.c (operator_length_standard, operator_check_standard):
6530 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
6532 2017-09-04 Pedro Alves <palves@redhat.com>
6534 * ax-gdb.c: Include "typeprint.h".
6535 (gen_expr_for_cast): New function.
6536 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
6537 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
6539 * dwarf2read.c (new_symbol_full): Fallback to int instead of
6540 nodebug_data_symbol.
6541 * eval.c: Include "typeprint.h".
6542 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
6543 Error out if symbol has unknown type.
6544 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
6545 evaluate_subexp_for_cast.
6546 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
6548 (evaluate_subexp_for_cast): New function.
6549 * gdbtypes.c (init_nodebug_var_type): New function.
6550 (objfile_type): Use it to initialize types of variables with no
6552 * typeprint.c (error_unknown_type): New.
6553 * typeprint.h (error_unknown_type): New declaration.
6554 * compile/compile-c-types.c (convert_type_basic): Handle
6555 TYPE_CODE_ERROR; warn and fallback to int for variables with
6558 2017-09-04 Pedro Alves <palves@redhat.com>
6560 * eval.c (evaluate_var_value): New function, factored out from ...
6561 (evaluate_subexp_standard): ... here.
6563 2017-09-04 Pedro Alves <palves@redhat.com>
6565 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
6566 Remove useless assignments to 'op'.
6568 2017-09-04 Pedro Alves <palves@redhat.com>
6570 * eval.c (eval_skip_value): New function.
6571 (evaluate_subexp_standard): Use it.
6573 2017-09-04 Pedro Alves <palves@redhat.com>
6575 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
6576 function name from symbol/minsym and pass it to
6577 error_call_unknown_return_type.
6579 2017-09-04 Pedro Alves <palves@redhat.com>
6581 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
6582 * ax-gdb.c (gen_msym_var_ref): New function.
6583 (gen_expr): Handle OP_VAR_MSYM_VALUE.
6584 * eval.c (evaluate_var_msym_value): New function.
6585 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
6586 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
6587 to call_function_by_hand.
6588 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6589 Handle OP_VAR_MSYM_VALUE.
6590 (union exp_element) <msymbol>: New field.
6591 * minsyms.h (struct type): Forward declare.
6592 (find_minsym_type_and_address): Declare.
6593 * parse.c (write_exp_elt_msym): New function.
6594 (write_exp_msymbol): Delete, refactored as ...
6595 (find_minsym_type_and_address): ... this new function.
6596 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
6597 (operator_length_standard, operator_check_standard): Handle
6599 * std-operator.def (OP_VAR_MSYM_VALUE): New.
6601 2017-09-04 Pedro Alves <palves@redhat.com>
6603 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
6604 TYPE_GNU_IFUNC specially here. Throw error if return type is
6606 * ada-typeprint.c (print_func_type): Handle functions with unknown
6608 * c-typeprint.c (c_type_print_base): Handle functions and methods
6609 with unknown return type.
6610 * compile/compile-c-symbols.c (convert_symbol_bmsym)
6611 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
6612 * compile/compile-c-types.c: Include "objfiles.h".
6613 (convert_func): For functions with unknown return type, warn and
6615 * compile/compile-object-run.c (compile_object_run): Adjust call
6616 to call_function_by_hand_dummy.
6617 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
6618 call_function_by_hand.
6619 * eval.c (evaluate_subexp_standard): Adjust calls to
6620 call_function_by_hand. Handle functions and methods with unknown
6621 return type. Pass expect_type to call_function_by_hand.
6622 * f-typeprint.c (f_type_print_base): Handle functions with unknown
6624 * gcore.c (call_target_sbrk): Adjust call to
6625 call_function_by_hand.
6626 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
6627 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
6628 an integer address type instead of nodebug.
6629 * guile/scm-value.c (gdbscm_value_call): Adjust call to
6630 call_function_by_hand.
6631 * infcall.c (error_call_unknown_return_type): New function.
6632 (call_function_by_hand): New "default_return_type" parameter.
6634 (call_function_by_hand_dummy): New "default_return_type"
6635 parameter. Use it instead of defaulting to int. If there's no
6636 default and the return type is unknown, throw an error. If
6637 there's a default return type, and the called function has no
6638 debug info, then assume the function is prototyped.
6639 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
6640 New "default_return_type" parameter.
6641 (error_call_unknown_return_type): New declaration.
6642 * linux-fork.c (call_lseek): Cast return type of lseek.
6643 (inferior_call_waitpid, checkpoint_command): Adjust calls to
6644 call_function_by_hand.
6645 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
6646 calls to call_function_by_hand.
6647 * m2-typeprint.c (m2_procedure): Handle functions with unknown
6649 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6650 (value_nsstring, print_object_command): Adjust calls to
6651 call_function_by_hand.
6652 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
6653 functions with unknown return type.
6654 (pascal_type_print_func_varspec_suffix): New function.
6655 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
6656 TYPE_CODE_METHOD>: Use it.
6657 * python/py-value.c (valpy_call): Adjust call to
6658 call_function_by_hand.
6659 * rust-lang.c (rust_evaluate_funcall): Adjust call to
6660 call_function_by_hand.
6661 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
6662 call_function_by_hand.
6663 * valops.c (value_allocate_space_in_inferior): Adjust call to
6664 call_function_by_hand.
6665 * typeprint.c (type_print_unknown_return_type): New function.
6666 * typeprint.h (type_print_unknown_return_type): New declaration.
6668 2017-09-04 Pedro Alves <palves@redhat.com>
6670 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
6671 types with more than one parameter as prototyped.
6673 2017-09-04 Pedro Alves <palves@redhat.com>
6675 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
6676 (disassemble_command): Use gdb_disassembly_flags instead of bare
6678 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
6679 (dump_insns, do_mixed_source_and_assembly_deprecated)
6680 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
6681 Use gdb_disassembly_flags instead of bare int.
6682 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
6683 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
6684 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
6685 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
6686 (enum gdb_disassembly_flag): ... values of this new enumeration.
6687 (gdb_disassembly_flags): Define.
6689 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
6690 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
6691 gdb_disassembly_flags instead of bare int.
6692 * record-btrace.c (btrace_insn_history)
6693 (record_btrace_insn_history, record_btrace_insn_history_range)
6694 (record_btrace_insn_history_from): Use gdb_disassembly_flags
6695 instead of bare int.
6696 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
6697 Use gdb_disassembly_flags instead of bare int.
6698 * target-debug.h (target_debug_print_gdb_disassembly_flags):
6700 * target-delegates.c: Regenerate.
6701 * target.c (target_insn_history, target_insn_history_from)
6702 (target_insn_history_range): Use gdb_disassembly_flags instead of
6704 * target.h: Include "disasm.h".
6705 (struct target_ops) <to_insn_history, to_insn_history_from,
6706 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
6708 (target_insn_history, target_insn_history_from)
6709 (target_insn_history_range): Use gdb_disassembly_flags instead of
6712 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6714 * cli/cli-script.c (build_command_line): For if/while commands,
6715 check whether args is empty.
6717 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6719 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
6720 (enum command_control_type): Likewise.
6721 (struct command_line): Likewise.
6722 (free_command_lines): Likewise.
6723 (struct command_lines_deleter): Likewise.
6724 (command_line_up): Likewise.
6725 (read_command_lines): Likewise.
6726 (read_command_lines_1): Likewise.
6727 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
6728 (enum command_control_type): Likewise.
6729 (struct command_line): Likewise.
6730 (free_command_lines): Likewise.
6731 (struct command_lines_deleter): Likewise.
6732 (command_line_up): Likewise.
6733 (read_command_lines): Likewise.
6734 (read_command_lines_1): Likewise.
6735 * breakpoint.h: Include cli/cli-script.h.
6736 * extension-priv.h: Likewise.
6737 * gdbcmd.h: Likewise.
6739 2017-09-04 Pedro Alves <palves@redhat.com>
6741 * ada-lang.c (is_known_support_routine): Move sal declaration to
6742 where it is initialized.
6743 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
6744 (parse_breakpoint_sals, decode_static_tracepoint_spec)
6745 (clear_command, update_static_tracepoint): Remove init_sal
6746 references. Move declarations closer to initializations.
6747 * cli/cli-cmds.c (list_command): Move sal declarations closer to
6749 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
6750 references. Move sal declarations closer to initializations.
6751 * frame.c (find_frame_sal): Return a symtab_and_line via function
6752 return instead of output parameter. Remove init_sal references.
6753 * frame.h (find_frame_sal): Return a symtab_and_line via function
6754 return instead of output parameter.
6755 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
6756 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
6758 (gdbscm_find_pc_line): Remove init_sal reference.
6759 * infcall.c (call_function_by_hand_dummy): Remove init_sal
6760 references. Move declarations closer to initializations.
6761 * infcmd.c (set_step_frame): Update. Move declarations closer to
6763 (finish_backward): Remove init_sal references. Move declarations
6764 closer to initializations.
6765 * infrun.c (process_event_stop_test, handle_step_into_function)
6766 (insert_hp_step_resume_breakpoint_at_frame)
6767 (insert_step_resume_breakpoint_at_caller): Likewise.
6768 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
6769 (symbol_to_sal): Likewise.
6770 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
6771 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
6772 to its initialization.
6773 * reverse.c (save_bookmark_command): Use new/delete. Remove
6774 init_sal references. Move declarations closer to initializations.
6775 * source.c (get_current_source_symtab_and_line): Remove brace
6777 (set_current_source_symtab_and_line): Now takes the sal by const
6778 reference. Remove brace initialization.
6779 (line_info): Remove init_sal reference.
6780 * source.h (set_current_source_symtab_and_line): Now takes a
6781 symtab_and_line via const reference.
6782 * stack.c (set_current_sal_from_frame): Adjust.
6783 (print_frame_info): Adjust.
6784 (get_last_displayed_sal): Return the sal via function return
6785 instead of via output parameter. Simplify.
6786 (frame_info): Adjust.
6787 * stack.h (get_last_displayed_sal): Return the sal via function
6788 return instead of via output parameter.
6789 * symtab.c (init_sal): Delete.
6790 (find_pc_sect_line): Remove init_sal references. Move
6791 declarations closer to initializations.
6792 (find_function_start_sal): Remove init_sal references. Move
6793 declarations closer to initializations.
6794 * symtab.h (struct symtab_and_line): In-class initialize all
6796 * tracepoint.c (set_traceframe_context)
6797 (print_one_static_tracepoint_marker): Remove init_sal references.
6798 Move declarations closer to initializations.
6799 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
6800 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
6801 declarations closer to initializations.
6802 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
6803 init_sal references. Adjust.
6805 2017-09-04 Pedro Alves <palves@redhat.com>
6807 * ax-gdb.c (agent_command_1): Use range-for.
6808 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6809 * breakpoint.c: Include "common/array-view.h".
6810 (init_breakpoint_sal, create_breakpoint_sal): Change sals
6811 parameter from struct symtabs_and_lines to
6812 array_view<symtab_and_line>. Adjust. Use range-for. Update.
6813 (breakpoint_sals_to_pc): Change sals parameter from struct
6814 symtabs_and_lines to std::vector reference.
6815 (check_fast_tracepoint_sals): Change sals parameter from struct
6816 symtabs_and_lines to std::array_view. Use range-for.
6817 (decode_static_tracepoint_spec): Return a std::vector instead of
6818 symtabs_and_lines. Update.
6819 (create_breakpoint): Update.
6820 (break_range_command, until_break_command, clear_command): Update.
6821 (base_breakpoint_decode_location, bkpt_decode_location)
6822 (bkpt_probe_create_sals_from_location)
6823 (bkpt_probe_decode_location, tracepoint_decode_location)
6824 (tracepoint_probe_decode_location)
6825 (strace_marker_create_sals_from_location): Return a std::vector
6826 instead of symtabs_and_lines.
6827 (strace_marker_create_breakpoints_sal): Update.
6828 (strace_marker_decode_location): Return a std::vector instead of
6829 symtabs_and_lines. Update.
6830 (update_breakpoint_locations): Change struct symtabs_and_lines
6831 parameters to gdb::array_view. Adjust.
6832 (location_to_sals): Return a std::vector instead of
6833 symtabs_and_lines. Update.
6834 (breakpoint_re_set_default): Use std::vector instead of struct
6836 (decode_location_default): Return a std::vector instead of
6837 symtabs_and_lines. Update.
6838 * breakpoint.h: Include "common/array-view.h".
6839 (struct breakpoint_ops) <decode_location>: Now returns a
6840 std::vector instead of returning a symtabs_and_lines via output
6842 (update_breakpoint_locations): Change sals parameters to use
6844 * cli/cli-cmds.c (edit_command, list_command): Update to use
6845 std::vector and gdb::array_view.
6846 (ambiguous_line_spec): Adjust to use gdb::array_view and
6848 (compare_symtabs): Rename to ...
6849 (cmp_symtabs): ... this. Change parameters to symtab_and_line
6850 const reference and adjust.
6851 (filter_sals): Rewrite using std::vector and standard algorithms.
6852 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
6853 (jump_command): Update to use std::vector.
6854 * linespec.c (struct linespec_state) <canonical_names>: Update
6856 (add_sal_to_sals_basic): Delete.
6857 (add_sal_to_sals, filter_results, convert_results_to_lsals)
6858 (decode_line_2, create_sals_line_offset)
6859 (convert_address_location_to_sals, convert_linespec_to_sals)
6860 (convert_explicit_location_to_sals, parse_linespec)
6861 (event_location_to_sals, decode_line_full, decode_line_1)
6862 (decode_line_with_current_source)
6863 (decode_line_with_last_displayed, decode_objc)
6864 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
6865 (linespec_result::~linespec_result): Adjust to use std::vector
6866 instead of symtabs_and_lines.
6867 * linespec.h (linespec_sals::sals): Now a std::vector.
6868 (struct linespec_result): Use std::vector, bool, and in-class
6870 (decode_line_1, decode_line_with_current_source)
6871 (decode_line_with_last_displayed): Return std::vector.
6872 * macrocmd.c (info_macros_command): Use std::vector.
6873 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
6874 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
6876 * probe.h (parse_probes): Return a std::vector.
6877 * python/python.c (gdbpy_decode_line): Use std::vector and
6879 * source.c (select_source_symtab, line_info): Use std::vector.
6880 * stack.c (func_command): Use std::vector.
6881 * symtab.h (struct symtabs_and_lines): Delete.
6882 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
6884 2017-09-04 Pedro Alves <palves@redhat.com>
6886 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6887 unittests/array-view-selftests.c.
6888 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
6889 * common/array-view.h: New file.
6890 * unittests/array-view-selftests.c: New file.
6892 2017-09-04 Pedro Alves <palves@redhat.com>
6894 * cli/cli-cmds.c (edit_command): Pass message to
6895 ambiguous_line_spec.
6896 (list_command): Pass message to ambiguous_line_spec. Say
6897 "first"/"last" instead of "start" and "end" to be consistent with
6899 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
6900 them to print formatted message.
6902 2017-09-04 Pedro Alves <palves@redhat.com>
6904 * btrace.c (ftrace_add_pt): Pass btrace_insn to
6905 ftrace_update_insns by reference instead of pointer.
6907 2017-09-04 Yao Qi <yao.qi@linaro.org>
6909 * i386-go32-tdep.c: Include x86-xstate.h.
6910 (i386_go32_init_abi): Call i386_target_description.
6911 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
6912 if xcr0 is X86_XSTATE_X87_MASK.
6913 * i386-tdep.h (tdesc_i386): Remove the declaration.
6914 (tdesc_i386_mmx): Likewise.
6916 2017-09-04 Yao Qi <yao.qi@linaro.org>
6918 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
6919 X86_XSTATE_SSE_MASK instead of 0.
6921 2017-09-04 Yao Qi <yao.qi@linaro.org>
6923 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
6924 i386_target_description.
6925 * i386-fbsd-nat.c (i386fbsd_read_description): Call
6926 i386_target_description.
6927 * i386-tdep.c (i386_gdbarch_init): Likewise.
6929 2017-09-04 Yao Qi <yao.qi@linaro.org>
6931 * amd64-darwin-tdep.c: Include "x86-xstate.h".
6932 (x86_darwin_init_abi_64): Call amd64_target_description.
6933 * amd64-dicos-tdep.c: Likewise.
6934 * amd64-fbsd-nat.c: Likewise.
6935 * amd64-fbsd-tdep.c: Likewise.
6936 * amd64-nbsd-tdep.c: Likewise.
6937 * amd64-obsd-tdep.c: Likewise.
6938 * amd64-sol2-tdep.c: Likewise.
6939 * amd64-windows-tdep.c: Likewise.
6940 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
6942 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6944 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
6945 (btrace_function) <insn>: Change type to use std::vector.
6946 * btrace.c (ftrace_debug, ftrace_call_num_insn,
6947 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
6948 ftrace_update_insns, ftrace_compute_global_level_offset,
6949 btrace_stitch_bts, btrace_clear, btrace_insn_get,
6950 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
6951 change to std::vector.
6952 (ftrace_update_insns): Adjust to change to std::vector, change
6953 type of INSN parameter.
6954 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
6955 * record-btrace.c (btrace_call_history_insn_range,
6956 btrace_compute_src_line_range,
6957 record_btrace_frame_prev_register): Adjust to change to
6959 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
6960 to change to std::vector.
6962 2017-09-03 Tom Tromey <tom@tromey.com>
6964 * corefile.c (reopen_exec_file): Use std::string.
6966 2017-09-03 Tom Tromey <tom@tromey.com>
6968 * compile/compile.c (compile_register_name_mangled): Return
6970 * compile/compile-loc2c.c (pushf_register_address): Update.
6971 (pushf_register): Update.
6972 * compile/compile-c-types.c (convert_array): Update.
6973 * compile/compile-c-symbols.c (generate_vla_size): Update.
6974 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
6975 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
6976 (convert_one_symbol): Update.
6977 (generate_c_for_for_one_variable): Update.
6978 * compile/compile-c-support.c (c_get_range_decl_name): Return a
6980 (generate_register_struct): Update.
6981 * compile/compile-internal.h (c_get_range_decl_name): Return a
6983 (compile_register_name_mangled): Return std::string.
6985 2017-09-03 Tom Tromey <tom@tromey.com>
6987 * utils.c (perror_string): Return a std::string.
6988 (throw_perror_with_name, perror_warning_with_name): Update.
6990 2017-09-03 Tom Tromey <tom@tromey.com>
6992 * demangle.c (demangle_command): Use std::string,
6995 2017-09-03 Tom Tromey <tom@tromey.com>
6997 * cli/cli-setshow.c (do_set_command): Use std::string.
6999 2017-09-03 Tom Tromey <tom@tromey.com>
7001 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
7003 2017-09-03 Tom Tromey <tom@tromey.com>
7005 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
7007 2017-09-03 Tom Tromey <tom@tromey.com>
7009 * mi/mi-cmd-env.c (env_execute_cli_command): Use
7010 gdb::unique_xmalloc_ptr.
7012 2017-09-03 Tom Tromey <tom@tromey.com>
7014 * thread.c (print_thread_info_1): Use string_printf.
7015 (thread_apply_command, thread_apply_all_command): Use
7018 2017-09-03 Tom Tromey <tom@tromey.com>
7020 * valprint.c (val_print_string): Update.
7021 * gdbcore.h (memory_error_message): Return std::string.
7022 * corefile.c (memory_error_message): Return std::string.
7023 (memory_error): Update.
7024 * breakpoint.c (insert_bp_location): Update.
7026 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
7028 * target/waitstatus.h (target_waitstatus_to_string): Change
7029 return type to std::string.
7030 * target/waitstatus.c (target_waitstatus_to_string): Return
7032 * target.h (target_waitstatus_to_string): Remove declaration.
7033 * infrun.c (resume, clear_proceed_status_thread,
7034 print_target_wait_results, do_target_wait, save_waitstatus,
7035 stop_all_threads): Adjust.
7036 * record-btrace.c (record_btrace_wait): Adjust.
7038 (target_debug_print_struct_target_waitstatus_p): Adjust.
7040 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
7043 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
7046 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
7048 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
7049 for setting/unsetting environment variables on the remote target.
7050 (New remote packets): Add entries for QEnvironmentHexEncoded,
7051 QEnvironmentUnset and QEnvironmentReset.
7052 * common/environ.c (gdb_environ::operator=): Extend method to
7053 handle m_user_set_env_list and m_user_unset_env_list.
7054 (gdb_environ::clear): Likewise.
7055 (match_var_in_string): Change type of first parameter from 'char
7056 *' to 'const char *'.
7057 (gdb_environ::set): Extend method to handle
7058 m_user_set_env_list and m_user_unset_env_list.
7059 (gdb_environ::unset): Likewise.
7060 (gdb_environ::clear_user_set_env): New method.
7061 (gdb_environ::user_set_envp): Likewise.
7062 (gdb_environ::user_unset_envp): Likewise.
7063 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
7064 m_user_unset_env_list on move constructor/assignment.
7065 (unset): Add new default parameter 'update_unset_list = true'.
7066 (clear_user_set_env): New method.
7067 (user_set_envp): Likewise.
7068 (user_unset_envp): Likewise.
7069 (m_user_set_env_list): New std::set.
7070 (m_user_unset_env_list): Likewise.
7071 * common/rsp-low.c (hex2str): New function.
7072 (bin2hex): New overload for bin2hex function.
7073 * common/rsp-low.c (hex2str): New prototype.
7074 (str2hex): New overload prototype.
7075 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
7076 QEnvironmentUnset and QEnvironmentReset.
7077 (remote_protocol_features): Add QEnvironmentHexEncoded,
7078 QEnvironmentUnset and QEnvironmentReset packets.
7079 (send_environment_packet): New function.
7080 (extended_remote_environment_support): Likewise.
7081 (extended_remote_create_inferior): Call
7082 extended_remote_environment_support.
7083 (_initialize_remote): Add QEnvironmentHexEncoded,
7084 QEnvironmentUnset and QEnvironmentReset packet configs.
7085 * unittests/environ-selftests.c (gdb_selftest_env_var):
7087 (test_vector_initialization): New function.
7088 (test_init_from_host_environ): Likewise.
7089 (test_reinit_from_host_environ): Likewise.
7090 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
7092 (test_unset_set_empty_vector): Likewise.
7093 (test_vector_clear): Likewise.
7094 (test_std_move): Likewise.
7095 (test_move_constructor):
7096 (test_self_move): Likewise.
7097 (test_set_unset_reset): Likewise.
7098 (run_tests): Rewrite in terms of the functions above.
7100 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
7102 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
7103 (adi_available): Use a temp variable of type CORE_ADDR as argument
7104 3 when calling target_auxv_search.
7105 (adi_normalize_address): Use masks and xor operators to calculate
7107 (adi_read_versions, adi_write_versions, adi_print_versions)
7108 (do_examine, do_assign): Use paddress.
7110 2017-08-29 John Baldwin <jhb@FreeBSD.org>
7112 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
7113 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
7114 out of loop and add supply of FIR.
7115 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
7118 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
7121 * cli/cli-script.c (define_command): Don't convert command name
7124 2017-08-25 Joel Brobecker <brobecker@adacore.com>
7126 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
7127 Update all callers accordingly. Remove all code blocks handling
7128 the case where DISPP is not NULL.
7130 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7133 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
7134 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
7135 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
7137 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
7139 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
7140 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
7141 (read_comp_units_from_section): New parameter abbrev_section, use
7142 read_and_check_comp_unit_head, allocate signatured_type if needed.
7143 (create_all_comp_units): Update read_comp_units_from_section caller.
7145 2017-08-23 Pedro Alves <palves@redhat.com>
7148 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
7149 to null_ptid and switch to thread without reading the registers
7150 after adding the inferior.
7152 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
7154 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
7156 * compile/compile.c (compile_gcc, show_compile_gcc): New.
7157 (compile_to_object): Implement compile_gcc.
7158 (_initialize_compile): Install "set compile-gcc". Initialize
7161 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
7163 * compile/compile.c (compile_to_object): Conditionally call
7164 set_verbose. Conditionally call compile or compile_v0.
7166 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
7168 * sparc64-tdep.h: (adi_normalize_address): New export.
7169 * sparc-nat.h: (open_adi_tag_fd): New export.
7170 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
7171 * sparc64-linux-tdep.c:
7172 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
7173 (sparc64_linux_handle_segmentation_fault): New function.
7174 (sparc64_linux_init_abi): Register
7175 sparc64_linux_handle_segmentation_fault
7176 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
7177 (sparc64_addr_bits_remove): New function.
7178 (sparc64_init_abi): Register sparc64_addr_bits_remove.
7179 (MAX_PROC_NAME_SIZE): New macro.
7180 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
7181 (sparc64adilist): New variable.
7182 (adi_proc_list): New variable.
7183 (find_adi_info): New function.
7184 (add_adi_info): New function.
7185 (get_adi_info_proc): New function.
7186 (get_adi_info): New function.
7187 (info_adi_command): New function.
7188 (read_maps_entry): New function.
7189 (adi_available): New function.
7190 (adi_normalize_address): New function.
7191 (adi_align_address): New function.
7192 (adi_convert_byte_count): New function.
7193 (adi_tag_fd): New function.
7194 (adi_is_addr_mapped): New function.
7195 (adi_read_versions): New function.
7196 (adi_write_versions): New function.
7197 (adi_print_versions): New function.
7198 (do_examine): New function.
7199 (do_assign): New function.
7200 (adi_examine_command): New function.
7201 (adi_assign_command): New function.
7202 (_initialize_sparc64_adi_tdep): New function.
7204 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
7206 * breakpoint.c (breakpoints_info): Rename to ...
7207 (info_breakpoints_command): ... this.
7208 (watchpoints_info): Rename to ...
7209 (info_watchpoints_command): ... this.
7210 (tracepoints_info): Rename to ...
7211 (info_tracepoints_command): ... this.
7212 (_initialize_breakpoint): Adjust.
7213 * dcache.c (dcache_info): Rename to ...
7214 (info_display_command): ... this.
7215 (_initialize_dcache): Adjust.
7216 * frame.h (args_info): Rename to ...
7217 (info_args_command): ... this.
7218 (locals_info): Rename to ...
7219 (info_locals_command): ... this.
7220 * infcmd.c (nofp_registers_info): Rename to ...
7221 (info_registers_command): ... this.
7222 (float_info): Rename to ...
7223 (info_float_command): ... this.
7224 (program_info): Rename to ...
7225 (info_program_command): ... this.
7226 (all_registers_info): Rename to ...
7227 (info_all_registers_command): ... this.
7228 (vector_info): Rename to ...
7229 (info_vector_command): ... this.
7230 (float_info): Rename to ...
7231 (info_float_command): ... this.
7232 (_initialize_infcmd): Adjust.
7233 * inferior.h (term_info): Rename to ...
7234 (info_terminal_command): ... this.
7235 * inflow.c (term_info): Rename to ...
7236 (info_terminal_command): ... this.
7237 (_initialize_inflow): Adjust.
7238 * infrun.c (signals_info): Rename to ...
7239 (info_signals_command): ... this.
7240 (_initialize_infrun): Adjust.
7241 * objc-lang.c (classes_info): Rename to ...
7242 (info_classes_command): ... this.
7243 (selectors_info): Rename to ...
7244 (info_selectors_command): ... this.
7245 (_initialize_objc_language): Adjust.
7246 * printcmd.c (sym_info): Rename to ...
7247 (info_symbol_command): ... this.
7248 (address_info): Rename to ...
7249 (info_address_command): ... this.
7250 (display_info): Rename to ...
7251 (info_display_command): ... this.
7252 (_initialize_printcmd): Adjust.
7253 * reverse.c (bookmarks_info): Rename to ...
7254 (info_breakpoints_command): ... this.
7255 (_initialize_reverse): Adjust.
7256 * ser-go32.c (dos_info): Rename to ...
7257 (info_serial_command): ... this.
7258 (_initialize_ser_dos): Adjust.
7259 * skip.c (skip_info): Rename to ...
7260 (info_skip_command): ... this.
7261 (_initialize_step_skip): Adjust.
7262 * source.c (line_info): Rename to ...
7263 (info_line_command): ... this.
7264 (source_info): Rename to ...
7265 (info_source_command)
7266 * stack.c (frame_info): Rename to ...
7267 (info_frame_command): ... this.
7268 (locals_info): Rename to ...
7269 (info_locals_command): ... this.
7270 (args_info): Rename to ...
7271 (info_args_command): ... this.
7272 (_initialize_stack): Adjust.
7273 * symtab.c (sources_info): Rename to ...
7274 (info_sources_command): ... this.
7275 (variables_info): Rename to ...
7276 (info_variables_command): ... this.
7277 (functions_info): Rename to ...
7278 (info_functions_command): ... this.
7279 (types_info): Rename to ...
7280 (info_types_command): ... this.
7281 (_initialize_symtab): Adjust.
7282 * target.c (target_info): Rename to ...
7283 (info_target_command): ... this.
7284 (initialize_targets): Adjust.
7285 * tracepoint.c (tvariables_info): Rename to ...
7286 (info_tvariables_command): ... this.
7287 (scope_info): Rename to ...
7288 (info_scope_command): ... this.
7289 (trace_dump_actions): Adjust.
7290 (_initialize_tracepoint): Adjust.
7292 2017-08-22 Tom Tromey <tom@tromey.com>
7294 * breakpoint.h (install_breakpoint): Update.
7295 * breakpoint.c (add_solib_catchpoint): Update.
7296 (install_breakpoint): Change argument to a std::unique_ptr.
7297 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
7298 (create_breakpoint_sal, create_breakpoint): Update.
7299 (watch_command_1, catch_exec_command_1)
7300 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
7301 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
7302 Return the breakpoint.
7303 (set_raw_breakpoint_without_location, set_raw_breakpoint)
7304 (new_single_step_breakpoint): Update.
7305 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
7307 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7309 * break-catch-sig.c (create_signal_catchpoint): Use
7311 * ada-lang.c (create_ada_exception_catchpoint): Use
7314 2017-08-22 Tom Tromey <tom@tromey.com>
7316 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
7318 2017-08-22 Tom Tromey <tom@tromey.com>
7320 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
7321 (lookup_partial_symbol): Update.
7323 2017-08-22 Tom Tromey <tom@tromey.com>
7325 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
7326 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
7327 (find_and_open_source, symtab_to_fullname): Update.
7328 * psymtab.c (psymtab_to_fullname): Update.
7330 2017-08-22 Tom Tromey <tom@tromey.com>
7332 * exec.c (exec_file_attach): Update.
7333 * linux-thread-db.c (try_thread_db_load): Update.
7334 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
7335 * utils.c (gdb_realpath): Change return type.
7336 (gdb_realpath_keepfile): Update.
7337 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
7338 (_initialize_utils): Register the new self test.
7339 * source.c (openp): Update.
7340 (find_and_open_source): Update.
7341 * nto-tdep.c (nto_find_and_open_solib): Update.
7342 * main.c (set_gdb_data_directory): Update.
7343 (captured_main_1): Update.
7344 * dwarf2read.c (dwarf2_get_dwz_file): Update
7345 (dw2_map_symbol_filenames): Update.
7346 * auto-load.c (auto_load_safe_path_vec_update): Update.
7347 (filename_is_in_auto_load_safe_path_vec): Change type of
7349 (auto_load_objfile_script): Update.
7350 (file_is_auto_load_safe): Update. Use std::string.
7351 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
7353 2017-08-22 Tom Tromey <tom@tromey.com>
7355 * utils.c (gdb_realpath_keepfile): Return a
7356 gdb::unique_xmalloc_ptr.
7357 * exec.c (exec_file_attach): Update.
7358 * utils.h (gdb_realpath_keepfile): Return a
7359 gdb::unique_xmalloc_ptr.
7361 2017-08-22 Tom Tromey <tom@tromey.com>
7363 * compile/compile.c (compile_file_command): Use
7364 gdb::unique_xmalloc_ptr, std::string.
7365 * utils.c (gdb_abspath): Change return type.
7366 * source.c (openp): Update.
7367 * objfiles.c (allocate_objfile): Update.
7368 * main.c (set_gdb_data_directory): Update.
7369 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
7371 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
7373 * cli-cmds.c (list_commands): List actual code around more than
7376 2017-08-21 John Baldwin <jhb@FreeBSD.org>
7378 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
7380 2017-08-21 Pedro Alves <palves@redhat.com>
7383 * c-exp.y (variable production): Handle function aliases.
7384 * minsyms.c (msymbol_is_text): New function.
7385 * minsyms.h (msymbol_is_text): Declare.
7386 * symtab.c (find_function_alias_target): New function.
7387 * symtab.h (find_function_alias_target): Declare.
7389 2017-08-21 Pedro Alves <palves@redhat.com>
7391 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
7393 * typeprint.c (whatis_exp): If handling "whatis", and expression
7394 is OP_TYPE, strip one typedef level. Otherwise don't strip
7396 * valops.c (value_cast): Save "to" type before resolving
7397 stubs/typedefs. Use that type as resulting value's type.
7399 2017-08-18 Tom Tromey <tom@tromey.com>
7400 Pedro Alves <palves@redhat.com>
7402 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
7403 * sol-thread.c (sol_thread_resume, sol_thread_wait)
7404 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
7405 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
7406 * proc-service.c (ps_xfer_memory): Use scoped_restore.
7407 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
7408 (linux_get_siginfo_data): Add "thread" argument. Use
7410 * linux-nat.c (linux_child_follow_fork)
7411 (check_stopped_by_watchpoint): Use scoped_restore.
7412 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
7413 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
7414 (restore_inferior_ptid, save_inferior_ptid): Remove.
7415 * btrace.c (btrace_fetch): Use scoped_restore.
7416 * bsd-uthread.c (bsd_uthread_fetch_registers)
7417 (bsd_uthread_store_registers): Use scoped_restore.
7418 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
7420 * aix-thread.c (aix_thread_resume, aix_thread_wait)
7421 (aix_thread_xfer_partial): Use scoped_restore.
7422 * inferior.h (save_inferior_ptid): Remove.
7424 2017-08-18 Yao Qi <yao.qi@linaro.org>
7427 * arm-tdep.c (gdb_print_insn_arm): Mark
7428 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
7430 2017-08-18 Yao Qi <yao.qi@linaro.org>
7432 * NEWS: Mention GDBserver's new option "--selftest".
7433 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
7434 * selftest.c: Move it to common/selftest.c.
7435 * selftest.h: Move it to common/selftest.h.
7436 * selftest-arch.c (reset): New function.
7437 (tests_with_arch): Call reset.
7439 2017-08-18 Yao Qi <yao.qi@linaro.org>
7441 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
7442 instead of exception_fprintf and printf_filtered.
7444 2017-08-18 Yao Qi <yao.qi@linaro.org>
7446 * selftest.c (register_self_test): Rename it to
7447 selftests::register_test.
7448 (run_self_tests): selftest::run_tests.
7449 * selftest.h: Update declarations.
7450 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
7451 selftests::register_test_foreach_arch.
7452 * selftest-arch.h: Update declaration.
7453 * aarch64-tdep.c: Update.
7454 * arm-tdep.c: Likewise.
7455 * disasm-selftests.c: Likewise.
7456 * dwarf2loc.c: Likewise.
7457 * dwarf2-frame.c: Likewise.
7458 * findvar.c: Likewise.
7459 * gdbarch-selftests.c: Likewise.
7460 * maint.c (maintenance_selftest): Likewise.
7461 * regcache.c: Likewise.
7462 * rust-exp.y: Likewise.
7463 * selftest-arch.c: Likewise.
7464 * unittests/environ-selftests.c: Likewise.
7465 * unittests/function-view-selftests.c: Likewise.
7466 * unittests/offset-type-selftests.c: Likewise.
7467 * unittests/optional-selftests.c: Likewise.
7468 * unittests/scoped_restore-selftests.c: Likewise.
7469 * utils-selftests.c: Likewise.
7471 2017-08-17 Pedro Alves <palves@redhat.com>
7473 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
7476 2017-08-17 Pedro Alves <palves@redhat.com>
7478 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
7480 (reset_die_in_process): Delete, replaced by ...
7481 (process_die_scope): ... this new class. Make it responsible for
7482 freeing cu->line_header too.
7483 (process_die): Use process_die_scope.
7484 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
7485 cu->line_header_die_owner. Don't release the line header if it's
7487 (setup_type_unit_groups): Make the CU/DIE own the line header.
7488 Don't release the line header here.
7490 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
7492 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
7494 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
7496 * NEWS: Mention new shortcuts for nexti and stepi in TUI
7499 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
7501 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
7504 2017-08-15 Stafford Horne <shorne@gmail.com>
7506 * MAINTAINERS (Write After Approval): Add Stafford Horne.
7508 2017-08-15 Stafford Horne <shorne@gmail.com>
7510 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
7512 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
7515 * infcmd.c (unset_environment_command): Use the 'clear' method on
7516 the environment instead of resetting it.
7518 2017-08-15 John Baldwin <jhb@FreeBSD.org>
7520 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
7523 2017-08-14 Tom Tromey <tom@tromey.com>
7525 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
7526 (print_binary_chars): Likewise.
7527 (BITS_IN_BYTES): Remove.
7529 2017-08-14 Tom Tromey <tom@tromey.com>
7532 * valprint.c (LOW_ZERO): Change value to 034.
7533 (print_octal_chars): Add static_asserts for octal constants.
7534 * printcmd.c (print_scalar_formatted): Add 'd' case.
7536 2017-08-11 Tom Tromey <tom@tromey.com>
7538 * symfile.c (add_symbol_file_command): Use std::vector.
7540 2017-08-14 Tom Tromey <tom@tromey.com>
7542 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
7543 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7545 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
7547 2017-08-11 Pedro Alves <palves@redhat.com>
7549 * infrun.c (process_event_stop_test): Adjust
7550 function_name_is_marked_for_skip call.
7551 * skip.c: Include <list>.
7552 (skiplist_entry): Make it a class with private fields, and
7554 (skiplist_entry_chain): Delete.
7555 (skiplist_entries): New.
7556 (skiplist_entry_count): Delete.
7557 (highest_skiplist_entry_num): New.
7558 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
7559 (add_skiplist_entry): Delete.
7560 (skiplist_entry::skiplist_entry): New.
7561 (skiplist_entry::add_entry): New.
7562 (skip_file_command, skip_function): Adjust.
7563 (compile_skip_regexp): Delete.
7564 (skip_command): Don't compile regexp here. Adjust to use
7565 skiplist_entry::add_entry.
7566 (skip_info): Adjust to use range-for and getters.
7567 (skip_enable_command, skip_disable_command): Adjust to use
7568 range-for and setters.
7569 (skip_delete_command): Adjust to use std::list.
7570 (add_skiplist_entry): Delete.
7571 (skip_file_p): Delete, refactored as ...
7572 (skiplist_entry::do_skip_file_p): ... this new method.
7573 (skip_gfile_p): Delete, refactored as ...
7574 (skiplist_entry::do_gskip_file_p): ... this new method.
7575 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
7576 (skiplist_entry::skip_function_p): ... this new method.
7577 (function_name_is_marked_for_skip): Now returns bool, and takes
7578 the function sal by const reference. Adjust to use range-for and
7579 skiplist_entry methods.
7580 (_initialize_step_skip): Remove references to
7581 skiplist_entry_chain, skiplist_entry_count.
7582 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
7583 takes the function sal by const reference.
7585 2017-08-11 Yao Qi <yao.qi@linaro.org>
7587 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
7588 (dwarf2_frame_cache): Remove reset_cache_cleanup.
7589 (dwarf2_frame_cache):
7590 * frame-unwind.c (frame_unwind_try_unwinder): Catch
7591 RETURN_MASK_ALL and set *this_case to NULL.
7592 * frame-unwind.h: Update comments.
7594 2017-08-11 Yao Qi <yao.qi@linaro.org>
7596 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
7597 (dwarf2_frame_state_copy_regs): Remove.
7598 (dwarf2_frame_state_free_regs): Remove.
7599 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
7600 (dwarf2_restore_rule): Call method .alloc_regs instead of
7601 dwarf2_frame_state_alloc_regs.
7602 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
7603 constructor. Call std::move.
7604 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
7605 (dwarf2_frame_cache): Likewise.
7607 [GDB_SELF_TEST]: Include selftest.h and
7609 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
7610 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
7611 execute_cfa_program_test.
7613 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
7614 copy ctor, assignment operator, move assignment.
7615 <alloc_regs>: New method.
7617 (struct dwarf2_frame_state): Delete dtor.
7618 (dwarf2_frame_state_alloc_regs): Remove declaration.
7619 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
7620 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
7622 2017-08-11 Yao Qi <yao.qi@linaro.org>
7624 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
7625 (dwarf2_frame_state::dwarf2_frame_state): New.
7626 (dwarf2_frame_state::~dwarf2_frame_state): New.
7627 (dwarf2_fetch_cfa_info): Update.
7628 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
7629 rather than a pointer. Update code.
7630 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
7632 <data_align, code_align, retaddr_column>: Change them to const.
7633 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
7636 2017-08-11 Yao Qi <yao.qi@linaro.org>
7638 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
7639 <loc.exp>: New field.
7640 * dwarf2-frame.c (execute_cfa_program): Update.
7641 (dwarf2_frame_prev_register): Update.
7643 2017-08-10 Pedro Alves <palves@redhat.com>
7645 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
7647 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7649 * fbsd-nat.c (struct fbsd_fork_info): Remove.
7650 (fbsd_pending_children): Use std::list.
7651 (fbsd_remember_child): Likewise.
7652 (fbsd_is_child_pending): Likewise.
7653 (fbsd_pending_vfork_done): Use std::forward_list.
7654 (fbsd_add_vfork_done): Likewise.
7655 (fbsd_is_vfork_done_pending): Likewise.
7656 (fbsd_next_vfork_done): Likewise.
7658 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7660 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
7661 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
7662 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
7664 (fbsd_xfer_partial): Use gdb::byte_vector.
7665 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
7667 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7669 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
7671 (fbsd_find_memory_regions): Fix `mapfile' initialization.
7673 2017-08-09 Tom Tromey <tom@tromey.com>
7675 * skip.c (skiplist_entry): New constructor.
7676 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
7677 (skiplist_entry::file_is_glob): Now bool.
7678 (skiplist_entry::file, skiplist_entry::function): Now
7680 (make_skip_entry): Return a unique_ptr. Use new.
7681 (free_skiplist_entry, free_skiplist_entry_cleanup)
7682 (make_free_skiplist_entry_cleanup): Remove.
7683 (skip_command, skip_disable_command, add_skiplist_entry)
7684 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
7685 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
7686 (function_name_is_marked_for_skip): Update.
7687 (skip_delete_command): Update. Use delete.
7689 2017-08-09 Jiong Wang <jiong.wang@arm.com>
7691 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
7692 (aarch64_linux_core_read_description): New function.
7693 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
7695 2017-08-09 Pedro Alves <palves@redhat.com>
7697 * cp-name-parser.y (cp_comp_to_string): Return a
7698 gdb::unique_xmalloc_ptr<char>.
7699 * cp-support.c (replace_typedefs_qualified_name)
7700 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
7701 (cp_canonicalize_string_full): Use op= instead of explicit
7703 (cp_class_name_from_physname, method_name_from_physname)
7704 (cp_func_name, cp_remove_params): Adjust to use
7705 gdb::unique_xmalloc_ptr<char>.
7706 * cp-support.h (cp_comp_to_string): Return a
7707 gdb::unique_xmalloc_ptr<char>.
7708 * python/py-type.c (typy_lookup_type): Adjust to use
7709 gdb::unique_xmalloc_ptr<char>.
7711 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
7713 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
7715 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
7716 Yao Qi <yao.qi@linaro.org>
7718 * cp-support.c (cp_canonicalize_string_full): Use
7719 gdb::unique_xmalloc_ptr<char>.
7720 (cp_canonicalize_string): Likewise.
7722 2017-08-09 Yao Qi <yao.qi@linaro.org>
7724 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
7725 * regformats/i386/amd64-avx-avx512.dat: Remove.
7726 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
7727 * regformats/i386/amd64-avx-mpx.dat:Remove.
7728 * regformats/i386/amd64-avx.dat: Remove.
7729 * regformats/i386/amd64-mpx.dat: Remove.
7730 * regformats/i386/i386-avx-avx512.dat: Remove.
7731 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
7732 * regformats/i386/i386-avx-mpx.dat: Remove.
7733 * regformats/i386/i386-mmx.dat: Remove.
7734 * regformats/i386/i386-mpx.dat: Remove.
7736 2017-08-09 Yao Qi <yao.qi@linaro.org>
7738 * amd64-tdep.h (tdesc_x32): Remove the declaration.
7739 * amd64-tdep.c: Don't include features/i386/x32*.c.
7740 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
7742 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
7743 and i386/x32-avx-avx512.
7744 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
7746 * features/i386/x32-avx-avx512.c: Removed.
7747 * features/i386/x32-avx-avx512.xml: Removed.
7748 * features/i386/x32-avx.c: Removed.
7749 * features/i386/x32-avx.xml: Removed.
7750 * features/i386/x32.c: Removed.
7751 * features/i386/x32.xml: Removed.
7752 * regformats/i386/x32-avx-avx512.dat: Removed.
7753 * regformats/i386/x32-avx.dat: Removed.
7754 * regformats/i386/x32.dat: Removed.
7756 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7758 PR breakpoints/21886
7759 * mem-break.c (default_memory_insert_breakpoint): Use
7760 `->placed_address' rather than `->reqstd_address' for the
7761 breakpoint location.
7763 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7765 * arch-utils.c (default_print_insn): Remove arch/mach/endian
7768 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7770 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
7771 a union of `tdep_info', `tdesc_data' and `id'.
7772 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
7773 rather than `info.tdep_info'.
7774 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
7775 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
7776 * i386-tdep.c (i386_gdbarch_init): Likewise.
7777 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
7778 * mips-tdep.c (mips_gdbarch_init): Likewise.
7779 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7780 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
7781 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
7783 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
7785 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7786 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
7788 * spu-tdep.c (spu_gdbarch_init): Likewise.
7789 * gdbarch.h: Regenerate.
7791 2017-08-07 Leszek Swirski <leszeks@google.com>
7794 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
7796 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
7798 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
7799 (gdbsim_open): Rename gdb_argv args object to argv.
7801 2017-08-05 Tom Tromey <tom@tromey.com>
7803 * compile/compile-object-load.c (compile_object_load): Use
7804 gdb::unique_xmalloc_ptr.
7805 * cli/cli-dump.c (scan_filename): Rename from
7806 scan_filename_with_cleanup. Change return type.
7807 (scan_expression): Rename from scan_expression_with_cleanup.
7809 (dump_memory_to_file, dump_value_to_file, restore_command):
7810 Use gdb::unique_xmalloc_ptr. Update.
7811 * cli/cli-cmds.c (find_and_open_script): Use
7812 gdb::unique_xmalloc_ptr.
7813 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
7814 * symmisc.c (maintenance_print_symbols)
7815 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
7816 * symfile.c (symfile_bfd_open, generic_load)
7817 (add_symbol_file_command, remove_symbol_file_command): Use
7818 gdb::unique_xmalloc_ptr.
7819 * source.c (openp): Use gdb::unique_xmalloc_ptr.
7820 * psymtab.c (maintenance_print_psymbols): Use
7821 gdb::unique_xmalloc_ptr.
7822 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
7823 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
7824 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
7825 (reload_shared_libraries_1): Likewise.
7827 2017-08-05 Tom Tromey <tom@tromey.com>
7829 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
7830 (rust_op_vector, rust_set_vector): New typedefs.
7831 (current_parser): New global.
7832 (work_obstack): Change to pointer type. Update all users.
7833 (rust_ast, pstate): Remove globals.
7834 (struct rust_parser): New.
7835 (%union) <params, field_inits>: Change type.
7836 (start, tuple_expr, unit_expr, struct_expr_list, literal)
7837 (field_expr, expr_list, maybe_expr_list, type_list): Update.
7838 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
7839 (convert_params_to_types, convert_params_to_expression): Change
7841 (ast_string): Change type of "fields".
7842 (rust_parse): Make a rust_parser. Remove cleanups.
7843 (rust_lex_tests): Make and install an auto_obstack.
7845 2017-08-04 Yao Qi <yao.qi@linaro.org>
7847 * configure.srv (ipa_x32_linux_regobj): New.
7848 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
7849 instead of X86_TDESC_AVX512.
7850 (initialize_low_tracepoint): Call
7851 init_registers_x32_avx_avx512_linux.
7853 2017-08-04 Yao Qi <yao.qi@linaro.org>
7855 * utils.h (gdb_argv): Add namespace std for nullptr_t.
7857 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
7859 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
7861 2017-08-03 Tom Tromey <tom@tromey.com>
7863 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
7865 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
7867 2017-08-03 Tom Tromey <tom@tromey.com>
7869 * python/py-param.c (compute_enum_values): Use gdb_argv.
7871 2017-08-03 Tom Tromey <tom@tromey.com>
7873 * utils.h (struct gdb_argv_deleter): New.
7874 (gdb_argv): New class.
7875 * utils.c (gdb_argv::reset): New method.
7876 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
7877 * tracefile.c (tsave_command): Use gdb_argv.
7878 * top.c (new_ui_command): Use gdb_argv.
7879 * symmisc.c (maintenance_print_symbols)
7880 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
7881 * symfile.c (symbol_file_command, generic_load)
7882 (remove_symbol_file_command): Use gdb_argv.
7883 * stack.c (backtrace_command): Use gdb_argv.
7884 * source.c (add_path, show_substitute_path_command)
7885 (unset_substitute_path_command, set_substitute_path_command):
7887 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
7888 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
7889 * remote.c (extended_remote_run, remote_put_command)
7890 (remote_get_command, remote_delete_command): Use gdb_argv.
7891 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
7892 (gdbsim_open): Use gdb_argv.
7893 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
7894 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
7895 * procfs.c (procfs_info_proc): Use gdb_argv.
7896 * interps.c (interpreter_exec_cmd): Use gdb_argv.
7897 * infrun.c (handle_command): Use gdb_argv.
7898 * inferior.c (add_inferior_command, clone_inferior_command):
7900 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
7901 * exec.c (exec_file_command): Use gdb_argv.
7902 * cli/cli-cmds.c (alias_command): Use gdb_argv.
7903 * compile/compile.c (build_argc_argv): Use gdb_argv.
7905 2017-08-03 Tom Tromey <tom@tromey.com>
7907 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
7909 2017-08-03 Tom Tromey <tom@tromey.com>
7911 * python/python.c (compute_python_string): Return std::string.
7912 (gdbpy_eval_from_control_command): Update.
7913 (do_start_initialization): Use std::string.
7914 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
7916 * python/py-breakpoint.c (local_setattro): Use string_printf, not
7919 2017-08-03 Tom Tromey <tom@tromey.com>
7921 * top.h (do_restore_instream_cleanup): Remove.
7922 * top.c (do_restore_instream_cleanup): Remove.
7923 (read_command_file): Use scoped_restore.
7924 * cli/cli-script.c (execute_user_command): Use scoped_restore.
7926 2017-08-03 Tom Tromey <tom@tromey.com>
7928 * cli/cli-script.c (execute_user_command)
7929 (execute_control_command): Use scoped_restore.
7931 2017-08-03 Tom Tromey <tom@tromey.com>
7933 * cli/cli-script.c (do_restore_user_call_depth): Remove.
7934 (execute_user_command): Remove user_call_depth; use
7935 user_args_stack's size instead.
7937 2017-08-03 Tom Tromey <tom@tromey.com>
7939 * top.h (in_user_command): Remove.
7940 * top.c (in_user_command): Remove.
7941 * cli/cli-script.c (do_restore_user_call_depth)
7942 (execute_user_command): Update.
7944 2017-08-03 Tom Tromey <tom@tromey.com>
7946 * valops.c (search_struct_method): Use gdb::byte_vector.
7947 * valarith.c (value_concat): Use std::vector.
7948 * target.c (memory_xfer_partial): Use gdb::byte_vector.
7949 (simple_search_memory): Likewise.
7950 * printcmd.c (find_string_backward): Use gdb::byte_vector.
7951 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
7952 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
7953 * elfread.c (elf_rel_plt_read): Use std::string.
7954 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
7955 * cli/cli-dump.c (restore_section_callback): Use
7958 2017-08-03 Tom Tromey <tom@tromey.com>
7960 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
7962 2017-08-03 Tom Tromey <tom@tromey.com>
7964 * tui/tui-regs.c (tui_restore_gdbout): Remove.
7965 (tui_register_format): Use scoped_restore.
7967 2017-08-03 Tom Tromey <tom@tromey.com>
7969 * reverse.c (exec_direction_default): Remove.
7970 (exec_reverse_once): Use scoped_restore.
7971 * remote.c (restore_remote_timeout): Remove.
7972 (remote_flash_erase, remote_flash_write, remote_flash_done)
7973 (readchar, remote_serial_write): Use scoped_restore.
7974 * cli/cli-script.c (struct source_cleanup_lines_args)
7975 (source_cleanup_lines): Remove.
7976 (script_from_file): Use scoped_restore.
7977 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
7978 (source_command): Use scoped_restore.
7980 2017-08-03 Tom Tromey <tom@tromey.com>
7982 * utils.h (make_cleanup_free_so): Remove.
7983 * utils.c (do_free_so, make_cleanup_free_so): Remove.
7984 * solist.h (struct so_deleter): New.
7985 (so_list_up): New typedef.
7986 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
7988 2017-08-03 Tom Tromey <tom@tromey.com>
7990 * utils.h (make_cleanup_restore_current_language): Remove.
7991 * utils.c (do_restore_current_language)
7992 (make_cleanup_restore_current_language): Remove.
7993 * parse.c (parse_exp_in_context_1)
7994 (parse_expression_with_language): Use
7995 scoped_restore_current_language.
7996 * mi/mi-main.c (mi_cmd_execute): Use
7997 scoped_restore_current_language.
7998 * language.h (scoped_restore_current_language): New class.
8000 2017-08-03 Tom Tromey <tom@tromey.com>
8002 * compile/compile.c (cleanup_unlink_file): Remove.
8003 (compile_to_object): Use gdb::unlinker.
8004 (eval_compile_command): Likewise.
8006 2017-08-03 Tom Tromey <tom@tromey.com>
8008 * utils.h (make_cleanup_fclose): Remove.
8009 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
8011 2017-08-03 Tom Tromey <tom@tromey.com>
8013 * top.c (open_terminal_stream): Return gdb_file_up.
8014 (new_ui_command): Update.
8016 2017-08-03 Tom Tromey <tom@tromey.com>
8018 * source.c (print_source_lines_base, forward_search_command)
8019 (reverse_search_command): Use gdb_file_up.
8021 2017-08-03 Tom Tromey <tom@tromey.com>
8023 * fbsd-nat.c (fbsd_find_memory_regions): Update.
8025 2017-08-03 Tom Tromey <tom@tromey.com>
8027 * cli/cli-cmds.c (find_and_open_script): Change return type.
8028 Remove "streamp" and "full_path" parameters.
8029 (source_script_with_search): Update.
8030 * auto-load.c (source_script_file): Update.
8031 * cli/cli-cmds.h (find_and_open_script): Change type.
8032 (open_script): New struct.
8034 2017-08-03 Tom Tromey <tom@tromey.com>
8036 * xml-support.c (xml_fetch_content_from_file): Update.
8037 * ui-file.c (stdio_file::open): Update.
8038 * tracefile-tfile.c (tfile_start): Update.
8039 * remote.c (remote_file_put, remote_file_get): Update.
8040 * nat/linux-procfs.c (linux_proc_get_int)
8041 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
8042 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
8043 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
8044 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
8045 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
8046 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
8047 * linux-nat.c (linux_proc_pending_signals): Update.
8048 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
8049 (file_closer): Remove.
8050 * compile/compile.c (compile_to_object): Update.
8051 * common/filestuff.h (struct gdb_file_deleter): New.
8052 (gdb_file_up): New typedef.
8053 (gdb_fopen_cloexec): Change return type.
8054 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
8055 * cli/cli-dump.c (fopen_with_cleanup): Remove.
8056 (dump_binary_file, restore_binary_file): Update.
8057 * auto-load.c (auto_load_objfile_script_1): Update.
8059 2017-08-03 Tom Tromey <tom@tromey.com>
8061 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
8062 (info_static_tracepoint_markers_command): Likewise.
8063 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
8064 * skip.c (skip_info): Use ui_out_emit_table.
8065 * progspace.c (print_program_space): Use ui_out_emit_table.
8066 * osdata.c (info_osdata): Use ui_out_emit_table.
8067 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
8069 * linux-thread-db.c (info_auto_load_libthread_db): Use
8071 * inferior.c (print_inferior): Use ui_out_emit_table.
8072 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
8073 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
8074 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
8075 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
8076 * ui-out.h (class ui_out_emit_table): New.
8078 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
8080 * mips-tdep.c (mips_fpu_type_str): New function.
8081 (mips_dump_tdep): Call it.
8083 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
8085 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
8088 2017-07-31 Xavier Roirand <roirand@adacore.com>
8090 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
8092 2017-07-27 Xavier Roirand <roirand@adacore.com>
8094 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
8096 2017-07-26 Yao Qi <yao.qi@linaro.org>
8098 * cli/cli-cmds.c (maintenancechecklist): New variable.
8099 * gdbcmd.h (maintenancechecklist): Declare it.
8100 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
8101 Call i386_linux_read_description with different masks.
8102 * maint.c (maintenance_check_command): New function.
8103 (_initialize_maint_cmds): Call add_prefix_cmd.
8104 * target-descriptions.c (tdesc_reg): override operator != and ==.
8105 (tdesc_type): Likewise.
8106 (tdesc_feature): Likewise.
8107 (target_desc): Likewise.
8108 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
8109 (maintenance_check_xml_descriptions): New function.
8110 (_initialize_target_descriptions) Add command "xml-descriptions".
8111 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
8113 2017-07-26 Yao Qi <yao.qi@linaro.org>
8115 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
8116 Include features/i386/32bit-*.c.
8117 (i386_linux_read_description): Generate target description if it
8119 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
8121 * features/i386/32bit-linux.c: Re-generated.
8122 * features/i386/32bit-sse.c: Likewise.
8123 * target-descriptions.c (print_c_feature::visit): Print code to
8124 set register number if needed.
8125 (print_c_feature) <m_next_regnum>: New field.
8127 2017-07-26 Yao Qi <yao.qi@linaro.org>
8129 * features/Makefile (CFILES): Rename with TDESC_CFILES.
8130 (FEATURE_XMLFILES): New.
8131 (FEATURE_CFILES): New.
8133 (clean-cfiles): Remove generated c files.
8134 * features/i386/32bit-avx.c: Generated.
8135 * features/i386/32bit-avx512.c: Generated.
8136 * features/i386/32bit-core.c: Generated.
8137 * features/i386/32bit-linux.c: Generated.
8138 * features/i386/32bit-mpx.c: Generated.
8139 * features/i386/32bit-pkeys.c: Generated.
8140 * features/i386/32bit-sse.c: Generated.
8141 * target-descriptions.c: Include algorithm.
8142 (tdesc_element_visitor): Add method visit_end.
8143 (print_c_tdesc): Implement visit_end.
8144 (print_c_tdesc:: m_filename_after_features): Move it to
8146 (print_c_feature): New class.
8147 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
8148 name starts with "i386/32bit-".
8150 2017-07-26 Yao Qi <yao.qi@linaro.org>
8152 * target-descriptions.c (tdesc_element_visitor): New class.
8153 (tdesc_element): New class.
8154 (tdesc_reg): Inherit from tdesc_element.
8155 (tdesc_reg::accept): New function.
8156 (tdesc_type): Inherit from tdesc_element.
8157 (tdesc_type::accept): New function.
8158 (tdesc_feature): Inherit from tdesc_element.
8159 (tdesc_feature::accept): New function.
8160 (target_desc): Inherit from tdesc_element.
8161 (target_desc::target_desc): New.
8162 (target_desc::~target_desc): New.
8163 (target_desc::accept): New.
8164 (allocate_target_description): Use new.
8165 (free_target_description): Use delete.
8166 (print_c_tdesc): New class.
8167 (maint_print_c_tdesc_cmd): Adjust.
8169 * features/aarch64.c: Re-generated.
8170 * features/arc-arcompact.c: Re-generated.
8171 * features/arc-v2.c: Re-generated.
8172 * features/arm/arm-with-iwmmxt.c: Re-generated.
8173 * features/arm/arm-with-m.c: Re-generated.
8174 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
8175 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
8176 * features/arm/arm-with-neon.c: Re-generated.
8177 * features/arm/arm-with-vfpv2.c: Re-generated.
8178 * features/arm/arm-with-vfpv3.c: Re-generated.
8179 * features/i386/amd64-avx-avx512.c: Re-generated.
8180 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
8181 * features/i386/amd64-avx.c: Re-generated.
8182 * features/i386/amd64-avx-linux.c: Re-generated.
8183 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
8184 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
8185 * features/i386/amd64-avx-mpx.c: Re-generated.
8186 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
8187 * features/i386/amd64.c: Re-generated.
8188 * features/i386/amd64-linux.c: Re-generated.
8189 * features/i386/amd64-mpx.c: Re-generated.
8190 * features/i386/amd64-mpx-linux.c: Re-generated.
8191 * features/i386/i386-avx-avx512.c: Re-generated.
8192 * features/i386/i386-avx-avx512-linux.c: Re-generated.
8193 * features/i386/i386-avx.c: Re-generated.
8194 * features/i386/i386-avx-linux.c: Re-generated.
8195 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
8196 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
8197 * features/i386/i386-avx-mpx.c: Re-generated.
8198 * features/i386/i386-avx-mpx-linux.c: Re-generated.
8199 * features/i386/i386.c: Re-generated.
8200 * features/i386/i386-linux.c: Re-generated.
8201 * features/i386/i386-mmx.c: Re-generated.
8202 * features/i386/i386-mmx-linux.c: Re-generated.
8203 * features/i386/i386-mpx.c: Re-generated.
8204 * features/i386/i386-mpx-linux.c: Re-generated.
8205 * features/i386/x32-avx-avx512.c: Re-generated.
8206 * features/i386/x32-avx-avx512-linux.c: Re-generated.
8207 * features/i386/x32-avx.c: Re-generated.
8208 * features/i386/x32-avx-linux.c: Re-generated.
8209 * features/i386/x32.c: Re-generated.
8210 * features/i386/x32-linux.c: Re-generated.
8211 * features/microblaze.c: Re-generated.
8212 * features/microblaze-with-stack-protect.c: Re-generated.
8213 * features/mips64-dsp-linux.c: Re-generated.
8214 * features/mips64-linux.c: Re-generated.
8215 * features/mips-dsp-linux.c: Re-generated.
8216 * features/mips-linux.c: Re-generated.
8217 * features/nds32.c: Re-generated.
8218 * features/nios2.c: Re-generated.
8219 * features/nios2-linux.c: Re-generated.
8220 * features/rs6000/powerpc-32.c: Re-generated.
8221 * features/rs6000/powerpc-32l.c: Re-generated.
8222 * features/rs6000/powerpc-403.c: Re-generated.
8223 * features/rs6000/powerpc-403gc.c : Re-generated.
8224 * features/rs6000/powerpc-405.c: Re-generated.
8225 * features/rs6000/powerpc-505.c: Re-generated.
8226 * features/rs6000/powerpc-601.c: Re-generated.
8227 * features/rs6000/powerpc-602.c: Re-generated.
8228 * features/rs6000/powerpc-603.c: Re-generated.
8229 * features/rs6000/powerpc-604.c: Re-generated.
8230 * features/rs6000/powerpc-64.c: Re-generated.
8231 * features/rs6000/powerpc-64l.c: Re-generated.
8232 * features/rs6000/powerpc-7400.c: Re-generated.
8233 * features/rs6000/powerpc-750.c: Re-generated.
8234 * features/rs6000/powerpc-860.c: Re-generated.
8235 * features/rs6000/powerpc-altivec32.c: Re-generated.
8236 * features/rs6000/powerpc-altivec32l.c: Re-generated.
8237 * features/rs6000/powerpc-altivec64.c: Re-generated.
8238 * features/rs6000/powerpc-altivec64l.c: Re-generated.
8239 * features/rs6000/powerpc-cell32l.c: Re-generated.
8240 * features/rs6000/powerpc-cell64l.c: Re-generated.
8241 * features/rs6000/powerpc-e500.c: Re-generated.
8242 * features/rs6000/powerpc-e500l.c: Re-generated.
8243 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
8244 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
8245 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
8246 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
8247 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
8248 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
8249 * features/rs6000/powerpc-vsx32.c: Re-generated.
8250 * features/rs6000/powerpc-vsx32l.c: Re-generated.
8251 * features/rs6000/powerpc-vsx64.c: Re-generated.
8252 * features/rs6000/powerpc-vsx64l.c: Re-generated.
8253 * features/rs6000/rs6000.c: Re-generated.
8254 * features/s390-linux32.c: Re-generated.
8255 * features/s390-linux32v1.c: Re-generated.
8256 * features/s390-linux32v2.c: Re-generated.
8257 * features/s390-linux64.c: Re-generated.
8258 * features/s390-linux64v1.c: Re-generated.
8259 * features/s390-linux64v2.c: Re-generated.
8260 * features/s390-te-linux64.c: Re-generated.
8261 * features/s390-tevx-linux64.c: Re-generated.
8262 * features/s390-vx-linux64.c: Re-generated.
8263 * features/s390x-linux64.c: Re-generated.
8264 * features/s390x-linux64v1.c: Re-generated.
8265 * features/s390x-linux64v2.c: Re-generated.
8266 * features/s390x-te-linux64.c: Re-generated.
8267 * features/s390x-tevx-linux64.c: Re-generated.
8268 * features/s390x-vx-linux64.c: Re-generated.
8269 * features/sparc/sparc32-solaris.c: Re-generated.
8270 * features/sparc/sparc64-solaris.c: Re-generated.
8271 * features/tic6x-c62x.c: Re-generated.
8272 * features/tic6x-c62x-linux.c: Re-generated.
8273 * features/tic6x-c64x.c: Re-generated.
8274 * features/tic6x-c64x-linux.c: Re-generated.
8275 * features/tic6x-c64xp.c: Re-generated.
8276 * features/tic6x-c64xp-linux.c: Re-generated.
8278 2017-07-26 Yao Qi <yao.qi@linaro.org>
8280 * i386-linux-tdep.c (i386_linux_read_description): New function.
8281 (i386_linux_core_read_description): Call
8282 i386_linux_read_description.
8283 * i386-linux-tdep.h (i386_linux_read_description): Declare.
8284 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
8285 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
8286 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
8287 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
8288 * x86-linux-nat.c (x86_linux_read_description): Call
8289 i386_linux_read_description.
8291 2017-07-26 Yao Qi <yao.qi@linaro.org>
8294 * features/Makefile (%.c: %.xml): Pass the xml file name to
8295 command "maint print c-tdesc".
8296 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
8299 2017-07-26 Yao Qi <yao.qi@linaro.org>
8301 * target-descriptions.c (target_desc): Add ctor and dtor. Do
8302 in-class initialization.
8303 (tdesc_create_feature): Call new instead of XCNEW.
8304 (free_target_description): Ue delete.
8306 2017-07-25 John Baldwin <jhb@FreeBSD.org>
8308 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
8310 2017-07-25 Yao Qi <yao.qi@linaro.org>
8312 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
8314 (amd64_x32_init_abi): Likewise.
8315 * amd64-tdep.h (amd64_init_abi): Update declaration.
8316 (amd64_x32_init_abi): Likewise.
8318 2017-07-25 Yao Qi <yao.qi@linaro.org>
8321 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
8322 condition for FPSCR.
8323 (arm_linux_store_inferior_registers): Likewise.
8325 2017-07-22 Tom Tromey <tom@tromey.com>
8327 * break-catch-syscall.c (struct catch_syscall_inferior_data)
8328 <syscalls_counts>: Now a std::vector.
8329 (get_catch_syscall_inferior_data): Use "new".
8330 (catch_syscall_inferior_data_cleanup): Use "delete".
8331 (insert_catch_syscall, remove_catch_syscall)
8332 (clear_syscall_counts): Update.
8334 2017-07-22 Tom Tromey <tom@tromey.com>
8336 * break-catch-syscall.c (syscall_catchpoint)
8337 <syscalls_to_be_caught>: Now a std::vector<int>
8338 (~syscall_catchpoint): Remove.
8339 (insert_catch_syscall, remove_catch_syscall)
8340 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
8341 (print_mention_catch_syscall, print_recreate_catch_syscall):
8343 (create_syscall_event_catchpoint): Change type of "filter"
8345 (catch_syscall_split_args): Return a std::vector.
8346 (catch_syscall_command_1, catching_syscall_number_1): Update.
8348 2017-07-22 Tom Tromey <tom@tromey.com>
8350 * break-catch-throw.c (struct exception_catchpoint)
8351 <exception_rx>: Now a std::string.
8352 (~exception_catchpoint): Remove.
8353 (print_one_detail_exception_catchpoint): Update.
8354 (handle_gnu_v3_exceptions): Change type of except_rx.
8355 (extract_exception_regexp): Return a std::string.
8356 (catch_exception_command_1): Update.
8358 2017-07-22 Tom Tromey <tom@tromey.com>
8360 * break-catch-sig.c (gdb_signal_type): Remove typedef.
8361 (struct signal_catchpoint) <signals_to_be_caught>: Now a
8363 <catch_all>: Now a bool.
8364 (~signal_catchpoint): Remove.
8365 (signal_catchpoint_insert_location)
8366 (signal_catchpoint_remove_location)
8367 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
8368 (signal_catchpoint_print_mention)
8369 (signal_catchpoint_print_recreate)
8370 (signal_catchpoint_explains_signal): Update.
8371 (create_signal_catchpoint): Change type of "filter" and
8373 (catch_signal_split_args): Return a std::vector. Change type of
8375 (catch_signal_command): Update.
8377 2017-07-20 Pedro Alves <palves@redhat.com>
8379 * ada-lang.c (ada_language_defn): Make extern.
8380 (_initialize_ada_language): Remove add_language call.
8381 * c-lang.c (c_language_defn, cplus_language_defn)
8382 (asm_language_defn, minimal_language_defn): Make extern.
8383 (_initialize_c_language): Delete.
8384 * completer.c (compare_cstrings): Delete, moved to utils.h.
8385 * d-lang.c (d_language_defn): Make extern.
8386 (_initialize_d_language): Remove add_language calls.
8387 * defs.h (enum language): Add comment.
8388 * f-lang.c (f_language_defn): Make extern.
8389 (_initialize_f_language): Remove add_language call.
8390 * go-lang.c (go_language_defn): Make extern.
8391 (_initialize_go_language): Remove add_language call.
8392 * language.c: Include <algorithm>.
8393 (languages): Redefine as const array.
8394 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
8395 (set_language_command): Handle "local". Use for-range loop.
8396 (set_language): Remove loop.
8397 (language_enum): Rewrite.
8398 (language_def, language_str): Remove loops.
8399 (add_language): Delete.
8400 (add_set_language_command): New, based on add_languages.
8401 (skip_language_trampoline): Adjust.
8402 (local_language_defn): Delete.
8403 (language_gdbarch_post_init): Adjust.
8404 (_initialize_language): Remove add_language calls. Call
8405 add_set_language_command.
8406 * language.h (add_language): Delete.
8407 (auto_language_defn)
8408 (unknown_language_defn, minimal_language_defn, ada_language_defn)
8409 (asm_language_defn, c_language_defn, cplus_language_defn)
8410 (d_language_defn, f_language_defn, go_language_defn)
8411 (m2_language_defn, objc_language_defn, opencl_language_defn)
8412 (pascal_language_defn, rust_language_defn): Declare.
8413 * m2-lang.c (m2_language_defn): Make extern.
8414 (_initialize_m2_language): Remove add_language call.
8415 * objc-lang.c (objc_language_defn): Make extern.
8416 (_initialize_objc_language): Remove add_language call.
8417 * opencl-lang.c (opencl_language_defn): Make extern.
8418 (_initialize_opencl_language): Remove add_language call.
8419 * p-lang.c (pascal_language_defn): Make extern.
8420 (_initialize_pascal_language): Delete.
8421 * rust-lang.c (rust_language_defn): Make extern.
8422 (_initialize_rust_language): Delete.
8423 * utils.h (compare_cstrings): New static inline function.
8425 2017-07-20 Pedro Alves <palves@redhat.com>
8427 * ada-lang.c (ada_to_fixed_type_1): Adjust.
8428 (get_var_value): Constify parameters.
8429 (get_int_var_value): Change prototype.
8430 (to_fixed_range_type): Adjust.
8431 * ada-lang.h (get_int_var_value): Change prototype.
8433 2017-07-20 Pedro Alves <palves@redhat.com>
8435 * dwarf2read.c (dw2_lookup_symbol): Use
8436 SYMBOL_MATCHES_SEARCH_NAME.
8437 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
8439 2017-07-20 Pedro Alves <palves@redhat.com>
8441 * block.c (block_iter_name_step, block_iter_name_first)
8442 (block_iter_name_next): Delete.
8443 (block_lookup_symbol_primary): Adjust to use
8444 dict_iter_match_first/dict_iter_match_next.
8445 * block.h (block_iter_name_first, block_iter_name_next): Delete
8447 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
8448 dict_iter_match_first/dict_iter_match_next.
8450 2017-07-20 Pedro Alves <palves@redhat.com>
8452 * cp-support.c (cp_find_first_component_aux): Add missing case for
8455 2017-07-18 David Blaikie <dblaikie@gmail.com>
8457 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
8458 of dwo_cu's dwo_file.
8460 2017-07-18 Yao Qi <yao.qi@linaro.org>
8462 * remote.c (store_registers_using_G): Remove one line comment.
8464 2017-07-18 Yao Qi <yao.qi@linaro.org>
8466 * regcache.c (regcache_cpy): Simplify it.
8467 (regcache::cpy_no_passthrough): Remove it.
8468 * regcache.h (cpy_no_passthrough): Remove it.
8469 (regcache_dup, regcache_cpy): Update comments.
8471 2017-07-18 Pedro Alves <palves@redhat.com>
8473 * remote-sim.c (sim_command_completer): Adjust to work with a
8474 completion_tracker instead of a VEC.
8476 2017-07-17 Pedro Alves <palves@redhat.com>
8478 * completer.c (complete_source_filenames): New function.
8479 (complete_address_and_linespec_locations): New function.
8480 (location_completer): Use complete_address_and_linespec_locations.
8481 (completion_tracker::build_completion_result): Honor the tracker's
8482 request to suppress append.
8483 * completer.h (completion_tracker::suppress_append_ws)
8484 (completion_tracker::set_suppress_append_ws): New methods.
8485 (completion_tracker::m_suppress_append_ws): New field.
8486 (complete_source_filenames): New declaration.
8487 * linespec.c (linespec_complete_what): New.
8488 (struct ls_parser) <complete_what, completion_word,
8489 completion_quote_char, completion_quote_end, completion_tracker>:
8491 (string_find_incomplete_keyword_at_end): New.
8492 (linespec_lexer_lex_string): Record quote char. If in completion
8494 (linespec_lexer_consume_token): Advance the completion word point.
8495 (linespec_lexer_peek_token): Save/restore completion info.
8496 (save_stream_and_consume_token): New.
8497 (set_completion_after_number): New.
8498 (linespec_parse_basic): Set what to complete next depending on
8499 token. Handle function and label completions specially.
8500 (parse_linespec): Disable objc shortcut in completion mode. Set
8501 what to complete next depending on token type. Skip keyword if in
8503 (complete_linespec_component, linespec_complete): New.
8504 * linespec.h (linespec_complete): Declare.
8506 2017-07-17 Pedro Alves <palves@redhat.com>
8508 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
8509 Handle 'operator<' / 'operator<<'.
8511 2017-07-17 Pedro Alves <palves@redhat.com>
8513 * completer.c (collect_explicit_location_matches): Handle
8515 (convert_explicit_location_to_linespec): New, factored out from
8517 (convert_explicit_location_to_sals): ... this.
8518 (complete_label): New.
8519 (linespec_complete_label, find_label_symbols_in_block): New.
8520 (find_label_symbols): Add completion_mode parameter and adjust to
8521 call find_label_symbols_in_block.
8522 * linespec.h (linespec_complete_label): Declare.
8524 2017-07-17 Pedro Alves <palves@redhat.com>
8526 * ada-lang.c (ada_collect_symbol_completion_matches): Add
8527 complete_symbol_mode parameter.
8528 * cli/cli-cmds.c (complete_command): Get the completion result out
8529 of the handle_brkchars tracker if used a custom word point.
8530 * completer.c: Include "linespec.h".
8531 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
8532 (advance_to_expression_complete_word_point): New.
8533 (completion_tracker::completes_to_completion_word): New.
8534 (complete_files_symbols): Pass down
8535 complete_symbol_mode::EXPRESSION.
8536 (explicit_options, probe_options): New.
8537 (collect_explicit_location_matches): Complete on the
8538 explictit_loc->foo instead of word. Use
8539 linespec_complete_function. Handle MATCH_LINE. Handle offering
8540 keyword and options completions.
8541 (backup_text_ptr): Delete.
8542 (skip_keyword): New.
8543 (complete_explicit_location): Remove 'word' parameter. Add
8544 language, quoted_arg_start and quoted_arg_end parameters.
8545 Rewrite, parsing left to right.
8546 (location_completer): Rewrite.
8547 (location_completer_handle_brkchars): New function.
8548 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
8549 (enum complete_line_internal_reason): Adjust comments.
8550 (completion_tracker::discard_completions): New.
8551 (completer_handle_brkchars_func_for_completer): Handle
8553 (gdb_custom_word_point_brkchars)
8554 (gdb_org_rl_basic_quote_characters): New.
8555 (gdb_completion_word_break_characters_throw)
8556 (completion_find_completion_word): Handle trackers that use a
8558 (completion_tracker::advance_custom_word_point_by): New.
8559 (completion_tracker::build_completion_result): Don't rely on
8560 readline appending the quote char.
8561 (gdb_rl_attempted_completion_function_throw): Handle trackers that
8562 use a custom word point.
8563 (gdb_rl_attempted_completion_function): Restore
8564 rl_basic_quote_characters.
8565 * completer.h (class completion_tracker): Extend intro comment.
8566 (completion_tracker::set_quote_char)
8567 (completion_tracker::quote_char)
8568 (completion_tracker::set_use_custom_word_point)
8569 (completion_tracker::use_custom_word_point)
8570 (completion_tracker::custom_word_point)
8571 (completion_tracker::set_custom_word_point)
8572 (completion_tracker::advance_custom_word_point_by)
8573 (completion_tracker::completes_to_completion_word)
8574 (completion_tracker::discard_completions): New methods.
8575 (completion_tracker::m_quote_char)
8576 (completion_tracker::m_use_custom_word_point)
8577 (completion_tracker::m_custom_word_point): New fields.
8578 (advance_to_expression_complete_word_point): Declare.
8579 * f-lang.c (f_collect_symbol_completion_matches): Add
8580 complete_symbol_mode parameter.
8581 * language.h (struct language_defn)
8582 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
8584 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
8585 (linespec_complete_function): New function.
8586 (linespec_lexer_lex_keyword): Adjust.
8587 * linespec.h (linespec_keywords, linespec_complete_function): New
8589 * location.c (find_end_quote): New function.
8590 (explicit_location_lex_one): Add explicit_completion_info
8591 parameter. Save quoting info. Don't throw if being called for
8592 completion. Don't handle Ada operators here.
8593 (is_cp_operator, skip_op_false_positives, first_of)
8594 (explicit_location_lex_one_function): New function.
8595 (string_to_explicit_location): Replace 'dont_throw' parameter with
8596 an explicit_completion_info pointer parameter. Handle it. Don't
8597 use explicit_location_lex_one to lex function names. Use
8598 explicit_location_lex_one_function instead.
8599 * location.h (struct explicit_completion_info): New.
8600 (string_to_explicit_location): Replace 'dont_throw' parameter with
8601 an explicit_completion_info pointer parameter.
8602 * symtab.c (default_collect_symbol_completion_matches_break_on):
8603 Add complete_symbol_mode parameter. Handle LINESPEC mode.
8604 (default_collect_symbol_completion_matches)
8605 (collect_symbol_completion_matches): Add complete_symbol_mode
8607 (collect_symbol_completion_matches_type): Pass down
8608 complete_symbol_mode::EXPRESSION.
8609 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8610 parameter. Handle LINESPEC mode.
8611 * symtab.h (complete_symbol_mode): New.
8612 (default_collect_symbol_completion_matches_break_on)
8613 (default_collect_symbol_completion_matches)
8614 (collect_symbol_completion_matches)
8615 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8618 2017-07-17 Pedro Alves <palves@redhat.com>
8620 * utils.c (enum class strncmp_iw_mode): New.
8621 (strcmp_iw): Rename to ...
8622 (strncmp_iw_with_mode): ... this. Add string2_len and mode
8623 parameters. Handle them.
8625 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
8626 * utils.h (strncmp_iw): Declare.
8627 (strcmp_iw): Move describing comments here.
8629 2017-07-17 Pedro Alves <palves@redhat.com>
8631 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
8633 * c-typeprint.c (is_type_conversion_operator): Use
8635 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
8636 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
8638 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
8639 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
8640 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
8641 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
8643 * location.c: Include "cp-support.h".
8644 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
8646 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
8649 2017-07-17 Pedro Alves <palves@redhat.com>
8651 * cli/cli-cmds.c (complete_command): Use a completion tracker
8652 along with completion_find_completion_word for handle_brkchars
8654 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
8655 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
8656 (struct gdb_rl_completion_word_info): New.
8657 (gdb_rl_find_completion_word): New.
8658 (completion_find_completion_word): New.
8659 * completer.h (completion_find_completion_word): Declare.
8661 2017-07-17 Pedro Alves <palves@redhat.com>
8663 * ada-lang.c (symbol_completion_match): Adjust comments.
8664 (symbol_completion_add): Replace vector parameter with
8665 completion_tracker parameter. Use it.
8666 (ada_make_symbol_completion_list): Rename to...
8667 (ada_collect_symbol_completion_matches): ... this. Add
8668 completion_tracker parameter and use it.
8669 (ada_language_defn): Adjust.
8670 * break-catch-syscall.c (catch_syscall_completer): Adjust
8671 prototype and work with completion_tracker instead of VEC.
8672 * breakpoint.c (condition_completer): Adjust prototype and work
8673 with completion_tracker instead of VEC.
8674 * c-lang.c (c_language_defn, cplus_language_defn)
8675 (asm_language_defn, minimal_language_defn): Adjust to renames.
8676 * cli/cli-cmds.c (complete_command): Rework using
8677 completion_tracker. Catch exceptions when completing.
8678 * cli/cli-decode.c (integer_unlimited_completer)
8679 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
8680 with completion_tracker instead of VEC.
8681 * command.h (struct completion_tracker): Forward declare.
8682 (completer_ftype, completer_handle_brkchars_ftype): Change
8684 (complete_on_cmdlist, complete_on_enum): Adjust.
8685 * completer.c: Include <algorithm>.
8686 (struct gdb_completer_state): New.
8687 (current_completion): New global.
8688 (readline_line_completion_function): Delete.
8689 (noop_completer, filename_completer)
8690 (filename_completer_handle_brkchars, complete_files_symbols)
8691 (linespec_location_completer): Adjust to work with a
8692 completion_tracker instead of a VEC.
8693 (string_or_empty): New.
8694 (collect_explicit_location_matches): Adjust to work with a
8695 completion_tracker instead of a VEC.
8696 (explicit_location_completer): Rename to ...
8697 (complete_explicit_location): ... this and adjust to work with a
8698 completion_tracker instead of a VEC.
8699 (location_completer): Adjust to work with a completion_tracker
8701 (add_struct_fields): Adjust to work with a completion_list instead
8703 (expression_completer): Rename to ...
8704 (complete_expression): ... this and adjust to work with a
8705 completion_tracker instead of a VEC. Use complete_files_symbols.
8706 (expression_completer): Reimplement on top of complete_expression.
8707 (symbol_completer): Adjust to work with a completion_tracker
8709 (enum complete_line_internal_reason): Add describing comments.
8710 (complete_line_internal_normal_command): Adjust to work with a
8711 completion_tracker instead of a VEC.
8712 (complete_line_internal): Rename to ...
8713 (complete_line_internal_1): ... this and adjust to work with a
8714 completion_tracker instead of a VEC. Assert TEXT is NULL in the
8715 handle_brkchars phase.
8716 (new_completion_tracker): Delete.
8717 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
8718 complete_line_internal_1.
8719 (free_completion_tracker): Delete.
8720 (INITIAL_COMPLETION_HTAB_SIZE): New.
8721 (completion_tracker::completion_tracker)
8722 (completion_tracker::~completion_tracker): New.
8723 (maybe_add_completion): Delete.
8724 (completion_tracker::maybe_add_completion)
8725 (completion_tracker::add_completion)
8726 (completion_tracker::add_completions): New.
8727 (throw_max_completions_reached_error): Delete.
8728 (complete_line): Adjust to work with a completion_tracker instead
8729 of a VEC. Don't create a completion_tracker_t or check for max
8731 (command_completer, command_completer_handle_brkchars)
8732 (signal_completer, reg_or_group_completer_1)
8733 (reg_or_group_completer, default_completer_handle_brkchars):
8734 Adjust to work with a completion_tracker.
8735 (gdb_completion_word_break_characters_throw): New.
8736 (gdb_completion_word_break_characters): Reimplement.
8737 (line_completion_function): Delete.
8738 (completion_tracker::recompute_lowest_common_denominator)
8739 (expand_preserving_ws)
8740 (completion_tracker::build_completion_result)
8741 (completion_result::completion_result)
8742 (completion_result::completion_result)
8743 (completion_result::~completion_result)
8744 (completion_result::completion_result)
8745 (completion_result::release_match_list, compare_cstrings)
8746 (completion_result::sort_match_list)
8747 (completion_result::reset_match_list)
8748 (gdb_rl_attempted_completion_function_throw)
8749 (gdb_rl_attempted_completion_function): New.
8750 * completer.h (completion_list, struct completion_result)
8751 (class completion_tracker): New.
8752 (complete_line): Add completion_tracker parameter.
8753 (readline_line_completion_function): Delete.
8754 (gdb_rl_attempted_completion_function): New.
8755 (noop_completer, filename_completer, expression_completer)
8756 (location_completer, symbol_completer, command_completer)
8757 (signal_completer, reg_or_group_completer): Update prototypes.
8758 (completion_tracker_t, new_completion_tracker)
8759 (make_cleanup_free_completion_tracker): Delete.
8760 (enum maybe_add_completion_enum): Delete.
8761 (maybe_add_completion): Delete.
8762 (throw_max_completions_reached_error): Delete.
8763 * corefile.c (complete_set_gnutarget): Adjust to work with a
8764 completion_tracker instead of a VEC.
8765 * cp-abi.c (cp_abi_completer): Adjust to work with a
8766 completion_tracker instead of a VEC.
8767 * d-lang.c (d_language_defn): Adjust.
8768 * disasm.c (disassembler_options_completer): Adjust to work with a
8769 completion_tracker instead of a VEC.
8770 * f-lang.c (f_make_symbol_completion_list): Rename to ...
8771 (f_collect_symbol_completion_matches): ... this. Adjust to work
8772 with a completion_tracker instead of a VEC.
8773 (f_language_defn): Adjust.
8774 * go-lang.c (go_language_defn): Adjust.
8775 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
8776 Adjust to work with a completion_tracker instead of a VEC.
8777 * infrun.c (handle_completer): Likewise.
8778 * interps.c (interpreter_completer): Likewise.
8779 * interps.h (interpreter_completer): Likewise.
8780 * language.c (unknown_language_defn, auto_language_defn)
8781 (local_language_defn): Adjust.
8782 * language.h (language_defn::la_make_symbol_completion_list):
8784 (language_defn::la_collect_symbol_completion_matches): ... this
8785 and adjust to work with a completion_tracker instead of a VEC.
8786 * m2-lang.c (m2_language_defn): Adjust.
8787 * objc-lang.c (objc_language_defn): Adjust.
8788 * opencl-lang.c (opencl_language_defn): Adjust.
8789 * p-lang.c (pascal_language_defn): Adjust.
8790 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
8791 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
8792 with a completion_tracker.
8793 * rust-lang.c (rust_language_defn): Adjust.
8794 * symtab.c (free_completion_list, do_free_completion_list)
8795 (return_val, completion_tracker): Delete.
8796 (completion_list_add_name, completion_list_add_symbol)
8797 (completion_list_add_msymbol, completion_list_objc_symbol)
8798 (completion_list_add_fields, add_symtab_completions): Add
8799 completion_tracker parameter and use it.
8800 (default_make_symbol_completion_list_break_on_1): Rename to...
8801 (default_collect_symbol_completion_matches_break_on): ... this.
8802 Add completion_tracker parameter and use it instead of allocating
8803 a completion tracker here.
8804 (default_make_symbol_completion_list_break_on): Delete old
8806 (default_make_symbol_completion_list): Delete.
8807 (default_collect_symbol_completion_matches): New.
8808 (make_symbol_completion_list): Delete.
8809 (collect_symbol_completion_matches): New.
8810 (make_symbol_completion_type): Rename to ...
8811 (collect_symbol_completion_matches_type): ... this. Add
8812 completion_tracker parameter and use it instead of VEC.
8813 (make_file_symbol_completion_list_1): Rename to...
8814 (collect_file_symbol_completion_matches): ... this. Add
8815 completion_tracker parameter and use it instead of VEC.
8816 (make_file_symbol_completion_list): Delete.
8817 (add_filename_to_list): Use completion_list instead of a VEC.
8818 (add_partial_filename_data::list): Now a completion_list.
8819 (make_source_files_completion_list): Work with a completion_list
8821 * symtab.h: Include "completer.h".
8822 (default_make_symbol_completion_list_break_on)
8823 (default_make_symbol_completion_list, make_symbol_completion_list)
8824 (make_symbol_completion_type, make_file_symbol_completion_list)
8825 (make_source_files_completion_list): Delete.
8826 (default_collect_symbol_completion_matches_break_on)
8827 (default_collect_symbol_completion_matches)
8828 (collect_symbol_completion_matches)
8829 (collect_symbol_completion_matches_type)
8830 (collect_file_symbol_completion_matches)
8831 (make_source_files_completion_list): New.
8832 * top.c (init_main): Don't install a rl_completion_entry_function
8833 hook. Install a rl_attempted_completion_function hook instead.
8834 * tui/tui-layout.c (layout_completer): Adjust to work with a
8836 * tui/tui-regs.c (tui_reggroup_completer):
8837 * tui/tui-win.c (window_name_completer, focus_completer)
8838 (winheight_completer): Adjust to work with a completion_tracker.
8839 * value.c: Include "completer.h".
8840 (complete_internalvar): Adjust to work with a completion_tracker.
8841 * value.h (complete_internalvar): Likewise.
8843 2017-07-17 Pedro Alves <palves@redhat.com>
8845 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
8847 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
8848 comments to completer_ftype's declaration.
8849 <completer_handle_brkchars>: Change type to
8850 completer_handle_brkchars_ftype.
8851 * command.h (completer_ftype): Add describing comment and give
8852 names to parameters.
8853 (completer_ftype_void): Rename to ...
8854 (completer_handle_brkchars_ftype) ... this. Add describing comment.
8855 (set_cmd_completer_handle_brkchars): Adjust.
8856 * completer.c (filename_completer_handle_brkchars): New function.
8857 (complete_line_internal_normal_command): New function, factored
8859 (complete_line_internal): ... here.
8860 (command_completer_handle_brkchars)
8861 (default_completer_handle_brkchars)
8862 (completer_handle_brkchars_func_for_completer): New functions.
8863 * completer.h (set_gdb_completion_word_break_characters): Delete
8865 (completer_handle_brkchars_func_for_completer): New declaration.
8866 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
8867 completer_handle_brkchars_func_for_completer.
8869 2017-07-17 Pedro Alves <palves@redhat.com>
8871 * completer.c (symbol_completer): New function, based on
8872 make_symbol_completion_list_fn.
8873 * completer.h (symbol_completer): New declaration.
8874 * guile/scm-cmd.c (cmdscm_completers): Adjust.
8875 * python/py-cmd.c (completers): Adjust.
8876 * symtab.c (make_symbol_completion_list_fn): Delete.
8877 * symtab.h (make_symbol_completion_list_fn): Delete.
8878 * cli/cli-decode.c (add_cmd): Adjust.
8880 2017-07-17 Pedro Alves <palves@redhat.com>
8882 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
8883 * dwarf2read.c: Include "filename-seen-cache.h".
8884 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
8885 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
8886 * filename-seen-cache.c: New file.
8887 * filename-seen-cache.h: New file.
8888 * symtab.c: Include "filename-seen-cache.h".
8889 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
8890 (create_filename_seen_cache, clear_filename_seen_cache)
8891 (delete_filename_seen_cache, filename_seen): Delete, parts moved
8892 to filename-seen-cache.h/filename-seen-cache.c.
8893 (output_source_filename, sources_info)
8894 (maybe_add_partial_symtab_filename)
8895 (make_source_files_completion_list): Adjust to use
8896 filename_seen_cache.
8898 2017-07-17 Pedro Alves <palves@redhat.com>
8900 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
8902 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
8903 dwarf2_debug_sections*)): New.
8904 (dwarf2_per_objfile::dwarf2_per_objfile(const
8905 dwarf2_per_objfile&)): Declare as deleted.
8906 (dwarf2_per_objfile::operator=): Declare as deleted.
8907 (dwarf2_per_objfile::dwarf2_per_objfile)
8908 (dwarf2_per_objfile::~dwarf2_per_objfile)
8909 (dwarf2_per_objfile::free_cached_comp_units): New.
8910 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
8911 ctor. Call dwarf2_per_objfile's ctor manually.
8912 (dwarf2_locate_sections): Deleted/refactored as ...
8913 (dwarf2_per_objfile::locate_sections): ... this new method.
8914 (free_cached_comp_units): Defer to
8915 dwarf2_per_objfile::free_cached_comp_units.
8916 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
8918 2017-07-14 Tom Tromey <tom@tromey.com>
8921 * rust-exp.y (convert_ast_to_expression): Add "want_type"
8923 <UNOP_SIZEOF>: Split into separate case.
8924 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
8926 2017-07-14 Tom Tromey <tom@tromey.com>
8929 * symtab.c (symbol_matches_domain): Add language_rust to special
8931 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
8932 treat LOC_TYPEDEF symbols as variables.
8934 2017-07-14 Pedro Alves <palves@redhat.com>
8936 * symtab.c (make_file_symbol_completion_list_1): Iterate over
8937 symtabs matching all symtabs with SRCFILE as file name instead of
8938 only considering the first hit, with lookup_symtab.
8940 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8942 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
8943 operator_name parameters.
8944 (gen_expr): Update function call.
8946 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8948 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
8950 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
8952 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
8953 parameter, use agent_expr::gdbarch instead, update function
8955 (locexpr_tracepoint_var_ref): Likewise.
8956 (loclist_tracepoint_var_ref): Likewise.
8957 * ax-gdb.c (gen_trace_static_fields): Likewise.
8958 (gen_traced_pop): Likewise.
8959 (gen_frame_args_address): Likewise.
8960 (gen_frame_locals_address): Likewise.
8961 (gen_var_ref): Likewise.
8962 (gen_struct_ref_recursive): Likewise.
8963 (gen_static_field): Likewise.
8964 (gen_maybe_namespace_elt): Likewise.
8965 (gen_expr): Likewise.
8966 (gen_trace_for_var): Likewise.
8967 (gen_trace_for_expr): Likewise.
8968 (gen_trace_for_return_address): Likewise.
8970 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8972 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
8974 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
8976 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8978 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
8979 from ax, update calls.
8980 (gen_usual_arithmetic): Likewise.
8981 (gen_integral_promotions): Likewise.
8982 (gen_bitfield_ref): Likewise.
8983 (gen_primitive_field): Likewise.
8984 (gen_struct_ref_recursive): Likewise.
8985 (gen_struct_ref): Likewise.
8986 (gen_maybe_namespace_elt): Likewise.
8987 (gen_struct_elt_for_reference): Likewise.
8988 (gen_namespace_elt): Likewise.
8989 (gen_aggregate_elt_ref): Likewise.
8990 (gen_expr): Get gdbarch from ax, update calls.
8991 (gen_expr_binop_rest): Likewise.
8993 2017-07-13 Pedro Alves <palves@redhat.com>
8995 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
8997 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
8998 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
8999 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
9000 tdesc_amd64_linux as default tdesc. Get final tdesc from the
9002 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
9003 Get final tdesc from the tdep.
9004 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
9006 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
9007 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
9008 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
9009 Use it as default tdesc.
9010 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
9011 down to amd_init_abi. No longer handle fallback tdesc here.
9012 * amd64-tdep.h (tdesc_x32): Declare.
9013 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
9015 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
9018 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9020 * s390-linux-tdep.c (s390_process_record): Add support for
9021 instructions new in arch12.
9023 2017-07-11 John Baldwin <jhb@FreeBSD.org>
9025 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
9026 PT_GETFSBASE and PT_GETGSBASE.
9027 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
9030 2017-07-11 John Baldwin <jhb@FreeBSD.org>
9032 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
9033 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
9034 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
9036 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
9037 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
9038 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
9039 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
9040 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
9041 * features/i386/amd64.xml: Add 64bit-segments.xml.
9042 * features/i386/amd64-avx-avx512.c: Regenerated.
9043 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
9044 * features/i386/amd64-avx-mpx.c: Regenerated.
9045 * features/i386/amd64-avx.c: Regenerated.
9046 * features/i386/amd64-mpx.c: Regenerated.
9047 * features/i386/amd64.c: Regenerated.
9048 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
9049 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
9050 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
9051 * regformats/i386/amd64-avx.dat: Regenerated.
9052 * regformats/i386/amd64-mpx.dat: Regenerated.
9053 * regformats/i386/amd64.dat: Regenerated.
9055 2017-07-10 Yao Qi <yao.qi@linaro.org>
9057 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
9058 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
9060 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
9062 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
9064 * gnulib/aclocal.m4: Regenerate.
9065 * gnulib/config.in: Regenerate.
9066 * gnulib/configure: Regenerate.
9067 * gnulib/import/Makefile.am: Regenerate.
9068 * gnulib/import/Makefile.in: Regenerate.
9069 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
9070 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
9071 * gnulib/import/m4/environ.m4: New file.
9072 * gnulib/import/m4/setenv.m4: New file.
9073 * gnulib/import/setenv.c: New file.
9074 * gnulib/import/unsetenv.c: New file.
9076 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
9078 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
9079 address when op is DW_OP_addr.
9081 2017-07-09 Tom Tromey <tom@tromey.com>
9083 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
9084 check and apply to outer type.
9086 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9088 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
9089 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
9090 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
9091 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
9093 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9095 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
9097 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9099 * corelow.c (get_core_siginfo): Remove.
9100 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
9101 instead of get_core_siginfo.
9102 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
9103 * gdbarch.h: Re-generate.
9104 * gdbarch.c: Re-generate.
9105 * linux-tdep.c (linux_core_xfer_siginfo): New.
9106 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
9108 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9110 * corelow.c (thread_section_name): Move to ...
9111 * gdbcore.h (thread_section_name): ... here.
9113 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9115 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
9116 (struct siginfo32): New.
9117 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
9118 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
9119 via ptrace(PT_LWPINFO).
9121 2017-07-07 John Baldwin <jhb@FreeBSD.org>
9123 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
9124 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
9125 (fbsd_get_siginfo_type): New.
9126 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
9127 (_initialize_fbsd_tdep): New.
9129 2017-07-06 David Blaikie <dblaikie@gmail.com>
9131 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
9132 a singular dwo_unit*) to support multiple CUs in the same way that
9133 multiple TUs are supported.
9134 (create_cus_hash_table): Replace create_dwo_cu with a function for
9135 parsing multiple CUs from a DWO file.
9136 (open_and_init_dwo_file): Use create_cus_hash_table rather than
9138 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
9139 htab_find, rather than comparing the signature to a singleton CU in
9142 2017-07-06 Pedro Alves <palves@redhat.com>
9144 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
9146 2017-07-04 Pedro Alves <palves@redhat.com>
9148 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
9149 * gdbtypes.h (TYPE_STATIC): Delete.
9150 (struct fn_field) <is_public, is_abstract, is_static, is_final,
9151 is_synchronized, is_native>: Delete.
9153 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
9154 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
9155 (TYPE_FN_FIELD_ABSTRACT): Delete.
9157 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
9159 * buffer.h (buffer_finish): Fix spelling mistakes.
9161 2017-07-01 Eli Zaretskii <eliz@gnu.org>
9163 * .dir-locals.el: Automatically switch to C-style comments in
9164 versions of Emacs that support the feature.
9166 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
9167 Pedro Alves <palves@redhat.com>
9170 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
9171 (process_next_line): New variable 'inline_cmd'.
9172 Adjust 'if' clauses for "python", "compile" and "guile" to use
9173 'command_name_equals' and check for '!inline_cmd'.
9175 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
9178 * cli/cli-script.c (command_name_equals_not_inline): New function.
9179 (process_next_line): Adjust 'if' clauses for "python", "compile"
9180 and "guile" to use command_name_equals_not_inline.
9182 2017-06-29 Pedro Alves <palves@redhat.com>
9184 * completer.c (expression_completer): Call
9185 linespec_location_completer instead of location_completer.
9187 2017-06-29 Pedro Alves <palves@redhat.com>
9189 * completer.c (expression_completer): Remove code that recomputes
9192 2017-06-29 Yao Qi <yao.qi@linaro.org>
9194 * regformats/regdat.sh: Generate code with
9195 "ifndef IN_PROCESS_AGENT".
9197 2017-06-28 Pedro Alves <palves@redhat.com>
9199 * command.h: Include "common/scoped_restore.h".
9201 2017-06-28 Yao Qi <yao.qi@linaro.org>
9203 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
9204 instead of obstack_grow.
9206 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
9209 * symfile.c (reread_symbols): Call objfiles_changed just before
9212 2017-06-27 Pedro Alves <palves@redhat.com>
9214 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
9215 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
9216 (completion_list_add_symbol, completion_list_add_msymbol):
9217 ... these new functions.
9218 (add_symtab_completions)
9219 (default_make_symbol_completion_list_break_on_1): Adjust.
9221 2017-06-27 Pedro Alves <palves@redhat.com>
9223 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
9224 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
9225 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
9227 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
9228 'storage_obstack' field an auto_obstack. In-class initialize all
9229 non-bitfield fields. Make minsyms_read bool.
9230 * symfile.c (read_symbols): Adjust.
9232 2017-06-27 Alan Hayward <alan.hayward@arm.com>
9234 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
9235 (gdbsim_store_register): Likewise.
9237 2017-06-27 Pedro Alves <palves@redhat.com>
9239 * c-exp.y (name_obstack): Now an auto_obstack.
9240 (yylex): Use auto_obstack::clear.
9241 (c_parse): Use auto_obstack::clear instead of reinitializing and
9242 freeing the obstack.
9243 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
9244 * d-exp.y (name_obstack): Now an auto_obstack.
9245 (yylex): Use auto_obstack::clear.
9246 (d_parse): Use auto_obstack::clear instead of reinitializing and
9247 freeing the obstack.
9248 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
9250 * dwarf2read.c (create_addrmap_from_index)
9251 (dwarf2_build_psymtabs_hard)
9252 (update_enumeration_type_from_children): Likewise.
9253 * gdb_obstack.h (auto_obstack): New type.
9254 * go-exp.y (name_obstack): Now an auto_obstack.
9255 (build_packaged_name): Use auto_obstack::clear.
9256 (go_parse): Use auto_obstack::clear instead of reinitializing and
9257 freeing the obstack.
9258 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
9260 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
9261 * rust-exp.y (work_obstack): Now an auto_obstack.
9262 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
9263 reinitializing and freeing the obstack.
9264 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
9265 (host_char_to_target): Use auto_obstack.
9266 * utils.h (make_cleanup_obstack_free): Delete declaration.
9267 * valprint.c (generic_emit_char, generic_printstr): Use
9270 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
9272 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
9274 (darwin_init_thread_list): Don't update dummy thread.
9275 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
9277 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
9279 * record-full.c (netorder16): Remove.
9281 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
9283 * common/diagnostics.h: Define macros for GCC.
9284 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
9285 * common/vec.h: Include diagnostics.h.
9286 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
9287 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
9290 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
9292 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
9294 * ada-lex.l: Ignore deprecated register warnings.
9296 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
9298 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
9299 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
9301 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
9303 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
9306 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
9308 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
9310 2017-06-23 Alan Hayward <alan.hayward@arm.com>
9312 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
9313 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
9314 (xtensa_register_read_masked): Likewise.
9316 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
9318 * common/environ.c (gdb_environ::unset): Update comment.
9320 2017-06-22 Alan Hayward <alan.hayward@arm.com>
9322 * python/py-unwind.c (pyuw_sniffer): Allocate space for
9325 2017-06-22 Alan Hayward <alan.hayward@arm.com>
9327 * record-full.c (record_full_exec_insn): Use byte_vector.
9329 2017-06-22 Yao Qi <yao.qi@linaro.org>
9331 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
9332 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
9334 2017-06-22 Alan Hayward <alan.hayward@arm.com>
9336 * remote.c (cached_reg): Move from here...
9337 * regcache.h (cached_reg): ...to here.
9338 * python/py-unwind.c (struct reg_info): Remove.
9339 (cached_frame_info): Use cached_reg_t.
9340 (pyuw_prev_register): Likewise.
9341 (pyuw_sniffer): Use cached_reg_t and allocate registers.
9342 (pyuw_dealloc_cache): Free all registers.
9344 2017-06-22 Pedro Alves <palves@redhat.com>
9345 Simon Marchi <simon.marchi@ericsson.com>
9347 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
9349 * common/diagnostics.h: New file.
9351 2017-06-22 Pedro Alves <palves@redhat.com>
9353 * common/agent.h: Add include guards.
9355 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
9357 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
9358 talk about addressable units instead of bytes.
9360 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9362 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
9363 of '::const_iterator'.
9365 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
9367 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9368 'unittests/environ-selftests.c'.
9369 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
9370 * charset.c (find_charset_names): Declare object 'iconv_env'.
9371 Update code to use 'iconv_env' object. Remove call to
9373 * common/environ.c: Include <utility>.
9374 (make_environ): Delete function.
9375 (free_environ): Delete function.
9376 (gdb_environ::clear): New function.
9377 (gdb_environ::operator=): New function.
9378 (gdb_environ::get): Likewise.
9379 (environ_vector): Delete function.
9380 (set_in_environ): Delete function.
9381 (gdb_environ::set): New function.
9382 (unset_in_environ): Delete function.
9383 (gdb_environ::unset): New function.
9384 (gdb_environ::envp): Likewise.
9385 * common/environ.h: Include <vector>.
9386 (struct gdb_environ): Delete; transform into...
9387 (class gdb_environ): ... this class.
9388 (free_environ): Delete prototype.
9389 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
9390 environ_vector): Likewise.
9391 * infcmd.c (run_command_1): Update code to call
9392 'envp' from 'gdb_environ' class.
9393 (environment_info): Update code to call methods from 'gdb_environ'
9395 (unset_environment_command): Likewise.
9396 (path_info): Likewise.
9397 (path_command): Likewise.
9398 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
9399 (inferior::inferior): Initialize 'environment' using the host's
9401 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
9402 Include "environ.h".
9403 (class inferior) <environment>: Change type from 'struct
9404 gdb_environ' to 'gdb_environ'.
9405 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
9406 methods from 'gdb_environ' class.
9407 * solib.c (solib_find_1): Likewise
9408 * unittests/environ-selftests.c: New file.
9410 2017-06-20 Yao Qi <yao.qi@linaro.org>
9412 * features/i386/i386-linux.xml: Exchange the order of including
9413 32bit-linux.xml and 32bit-sse.xml.
9414 * features/i386/i386-linux.c: Regenerated.
9416 2017-06-20 Yao Qi <yao.qi@linaro.org>
9418 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
9419 Delete copy ctor and assignment operator.
9420 (tdesc_type): Likewise.
9421 (tdesc_feature): Likewise.
9422 (tdesc_free_reg): Remove.
9423 (tdesc_create_reg): Use new.
9424 (tdesc_free_type): Remove.
9425 (tdesc_create_vector): Use new.
9426 (tdesc_create_union): Likewise.
9427 (tdesc_create_flags): Likewise.
9428 (tdesc_create_enum): Likewise.
9429 (tdesc_free_feature): Delete.
9430 (free_target_description): Use delete.
9432 2017-06-19 John Baldwin <jhb@FreeBSD.org>
9434 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
9437 2017-06-19 Pedro Alves <palves@redhat.com>
9439 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
9440 after gdb::unlinker.
9442 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
9444 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
9445 gdb_environ to access an environment variable.
9447 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9449 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
9452 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9454 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
9456 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9458 * configure: Re-generate.
9459 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
9461 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9463 * configure: Re-generate.
9464 * warning.m4: Pass -Werror to compiler when checking for
9465 supported warning flags.
9467 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9469 * Makefile.in (COMPILE.pre): Add "-x c++".
9471 2017-06-16 Alan Hayward <alan.hayward@arm.com>
9472 Pedro Alves <palves@redhat.com>
9473 Yao Qi <yao.qi@linaro.org>
9475 * defs.h (RequireLongest): New.
9476 (extract_integer): Declare function template.
9477 (extract_signed_integer): Remove the declaration, but define it
9479 (extract_unsigned_integer): Likewise.
9480 (store_integer): Declare function template.
9481 (store_signed_integer): Remove the declaration, but define it
9483 (store_unsigned_integer): Likewise.
9484 * findvar.c (extract_integer): New function template.
9485 (extract_signed_integer): Remove.
9486 (extract_unsigned_integer): Remove.
9487 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
9489 (store_integer): New function template.
9490 (store_signed_integer): Remove.
9491 (store_unsigned_integer): Remove.
9492 (store_integer): Explicit instantiations.
9493 * regcache.c (regcache_raw_read_signed): Update.
9494 (regcache::raw_read): New function.
9495 (regcache::raw_read_signed): Remove.
9496 (regcache::raw_read_unsigned): Remove.
9497 (regcache_raw_read_unsigned): Update.
9498 (regcache_raw_write_unsigned): Update.
9499 (regcache::raw_write_signed): Remove.
9500 (regcache::raw_write): New function.
9501 (regcache_cooked_read_signed): Update.
9502 (regcache::raw_write_unsigned): Remove.
9503 (regcache::cooked_read_signed): Remove.
9504 (regcache_cooked_read_unsigned): Update.
9505 (regcache::cooked_read_unsigned): Remove.
9506 (regcache_cooked_write_signed): Update.
9507 (regcache_cooked_write_unsigned): Update.
9508 * regcache.h (regcache) <raw_read_signed>: Remove.
9509 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
9510 <raw_read, raw_write>: New.
9511 <cooked_read_signed, cooked_write_signed>: Remove.
9512 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
9513 <cooked_read, cooked_write>: New.
9514 * sh64-tdep.c (sh64_pseudo_register_read): Update.
9515 (sh64_pseudo_register_write): Update.
9517 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
9519 * arc-tdep.c (arc_disassembler_options): New variable.
9520 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
9521 of default_print_insn.
9522 (arc_delayed_print_insn): Set info->section when needed,
9523 use default_print_insn to retrieve a disassembler.
9525 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
9528 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
9529 to mention $SHELL and startup-with-shell.
9531 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
9533 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
9535 2017-06-14 Yao Qi <yao.qi@linaro.org>
9537 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
9538 default_print_insn instead of print_insn_aarch64.
9539 * arm-tdep.c (gdb_print_insn_arm): Call
9540 default_print_insn instead of print_insn_big_arm
9541 and print_insn_little_arm.
9542 * i386-tdep.c (i386_print_insn): Call default_print_insn
9543 instead of print_insn_i386.
9544 * ia64-tdep.c (ia64_print_insn): Call
9545 default_print_insn instead of print_insn_ia64.
9546 * mips-tdep.c (gdb_print_insn_mips): Call
9547 default_print_insn instead of print_insn_big_mips
9548 and print_insn_little_mips.
9549 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
9550 instead of print_insn_spu.
9552 2017-06-14 Pedro Alves <palves@redhat.com>
9554 * ada-lang.c: Include "common/byte-vector.h".
9555 (ada_value_primitive_packed_val): Use gdb::byte_vector.
9556 * charset.c (wchar_iterator::iterate): Resize the vector instead
9558 * common/byte-vector.h: Include "common/def-vector.h".
9559 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
9560 * cli/cli-dump.c: Include "common/byte-vector.h".
9561 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
9562 * common/byte-vector.h: New file.
9563 * common/def-vector.h: New file.
9564 * common/default-init-alloc.h: New file.
9565 * dwarf2loc.c: Include "common/byte-vector.h".
9566 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
9567 instead of reserving it.
9568 * dwarf2read.c: Include "common/byte-vector.h".
9569 (data_buf::m_vec): Now a gdb::byte_vector.
9570 * gdb_regex.c: Include "common/def-vector.h".
9571 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
9572 * mi/mi-main.c: Include "common/byte-vector.h".
9573 (mi_cmd_data_read_memory): Use gdb::byte_vector.
9574 * printcmd.c: Include "common/byte-vector.h".
9575 (print_scalar_formatted): Use gdb::byte_vector.
9576 * valprint.c: Include "common/byte-vector.h".
9577 (maybe_negate_by_bytes, print_decimal_chars): Use
9580 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9582 * darwin-nat.c: Include "nat/fork-inferior.h".
9584 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9586 * configure.nat: Factor out Darwin bits that are not
9587 architecture-specific. Add fork-inferior.o.
9589 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9591 * configure.nat: Factor out AIX bits that are not
9592 architecture-specific. Add fork-inferior.o.
9594 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9596 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
9597 (read_pieced_value, write_pieced_value): ...here. Reduce to
9598 wrappers that just call rw_pieced_value.
9600 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9602 * dwarf2loc.c (write_pieced_value): When writing the data for a
9603 memory piece, use write_memory_with_notification instead of
9606 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9608 * valops.c (read_value_memory): Change embedded_offset to
9609 represent a bit offset instead of a byte offset.
9610 * value.h (read_value_memory): Adjust comment.
9612 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9614 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
9615 dest_offset_bits and source_offset_bits.
9616 (write_pieced_value): Likewise.
9618 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9620 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
9621 given by DW_OP_bit_piece.
9622 (write_pieced_value): Likewise.
9624 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9626 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
9627 some other preparations to the places where sufficient information
9629 (write_pieced_value): Likewise.
9631 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9633 * dwarf2loc.c (bits_to_bytes): New function.
9634 (read_pieced_value): Fix offset calculations for register pieces
9635 on big-endian targets.
9636 (write_pieced_value): Likewise.
9638 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9640 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
9641 (write_pieced_value): Likewise.
9643 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9645 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
9646 transfer the source value's least significant bits, instead of its
9647 lowest-addressed ones. Rename type_len to max_offset.
9648 (read_pieced_value): Mirror above changes to write_pieced_value as
9651 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9653 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
9654 truncate full bytes from dest_offset_bits before using it as an
9655 offset into the buffer.
9657 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9659 * dwarf2loc.c (write_pieced_value): Include transfer size in
9662 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9664 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
9665 calculation of this_size.
9667 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9669 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
9670 when targeting a bit-field.
9671 (write_pieced_value): Likewise.
9673 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9675 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
9676 (allocate_piece_closure): Drop addr_size parameter.
9677 (dwarf2_evaluate_loc_desc_full): Adjust call to
9678 allocate_piece_closure.
9680 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9683 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
9684 the LSB end, independent of endianness.
9686 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9688 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
9691 2017-06-13 Yao Qi <yao.qi@linaro.org>
9693 * mips-linux-nat.c: Move include features/mips*-linux.c to
9695 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
9696 to mips-linux-tdep.c.
9697 * mips-linux-tdep.c: Include features/mips*-linux.c
9698 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
9700 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
9701 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
9702 (tdesc_mips64_dsp_linux): Declare.
9704 2017-06-12 Tom Tromey <tom@tromey.com>
9706 * valprint.h (val_print_type_code_int): Remove.
9707 * valprint.c (generic_val_print_int): Always call
9708 val_print_scalar_formatted.
9709 (val_print_type_code_int): Remove.
9710 * printcmd.c (print_scalar_formatted): Handle options->format==0.
9711 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
9712 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
9713 * ada-valprint.c (ada_val_print_num): Use
9714 val_print_scalar_formatted.
9716 2017-06-12 Tom Tromey <tom@tromey.com>
9718 * printcmd.c (print_scalar_formatted): Unify the two switches.
9719 Don't convert scalars to LONGEST.
9721 2017-06-12 Tom Tromey <tom@tromey.com>
9724 * valprint.h (print_decimal_chars): Update.
9725 * valprint.c (maybe_negate_by_bytes): New function.
9726 (print_decimal_chars): Add "is_signed" argument.
9727 * printcmd.c (print_scalar_formatted): Update.
9729 2017-06-12 Tom Tromey <tom@tromey.com>
9732 * valprint.h (print_binary_chars, print_hex_chars): Update.
9733 * valprint.c (val_print_type_code_int): Update.
9734 (print_binary_chars): Add "zero_pad" argument.
9735 (emit_octal_digit): New function.
9736 (print_octal_chars): Don't zero-pad.
9737 (print_decimal_chars): Likewise.
9738 (print_hex_chars): Add "zero_pad" argument.
9739 * sh64-tdep.c (sh64_do_fp_register): Update.
9740 * regcache.c (regcache::dump): Update.
9741 * printcmd.c (print_scalar_formatted): Update.
9742 * infcmd.c (default_print_one_register_info): Update.
9744 2017-06-12 Pedro Alves <palves@redhat.com>
9745 Alan Hayward <alan.hayward@arm.com>
9747 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
9748 (mips_eabi_push_dummy_call): Rename local 'regsize' to
9749 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
9750 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
9751 Assert that abi_regsize bytes fit in 'ref_valbuf'.
9753 2017-06-12 Pedro Alves <palves@redhat.com>
9755 * dwarf2read.c (mapped_symtab::data): Now a vector of
9756 symtab_index_entry instead of vector of
9757 std::unique_ptr<symtab_index_entry>. All users adjusted to check
9758 whether an element's name is NULL instead of checking whether the
9759 element itself is NULL.
9760 (find_slot): Change return type. Adjust.
9761 (hash_expand, , add_index_entry, uniquify_cu_indices)
9762 (write_hash_table): Adjust.
9764 2017-06-12 Pedro Alves <palves@redhat.com>
9766 * dwarf2read.c (recursively_count_psymbols): New function.
9767 (write_psymtabs_to_index): Call it to compute number of psyms and
9768 pass estimate size of psyms_seen to unordered_set's ctor.
9770 2017-06-12 Pedro Alves <palves@redhat.com>
9772 * dwarf2read.c (write_hash_table): Check if key already exists
9775 2017-06-12 Pedro Alves <palves@redhat.com>
9777 * dwarf2read.c (data_buf::append_space): Rename to...
9778 (data_buf::grow): ... this, and make private. Adjust all callers.
9779 (data_buf::append_uint): New method.
9780 (add_address_entry, write_one_signatured_type)
9781 (write_psymtabs_to_index): Use it.
9783 2017-06-12 Pedro Alves <palves@redhat.com>
9785 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
9786 (file_write (FILE *, const std::vector<Elem>&)): Delete.
9787 (data_buf::file_write): Call ::fwrite directly.
9789 2017-06-12 Pedro Alves <palves@redhat.com>
9791 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
9794 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9796 Code cleanup: C++ify .gdb_index producer.
9797 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
9798 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
9799 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
9800 (create_strtab, add_string): Remove.
9801 (file_write, data_buf): New.
9802 (struct symtab_index_entry): Use std::vector for cu_indices.
9803 (struct mapped_symtab): Use std::vector for data.
9804 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
9805 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
9807 (find_slot): Change return type. Update it to the new data structures.
9808 (hash_expand, add_index_entry): Update it to the new data structures.
9809 (offset_type_compare): Remove.
9810 (uniquify_cu_indices): Update it to the new data structures.
9811 (c_str_view, c_str_view_hasher, vector_hasher): New.
9812 (add_indices_to_cpool): Remove.
9813 (write_hash_table): Update it to the new data structures.
9814 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
9815 (eq_psymtab_cu_index): Remove.
9816 (psym_index_map): New typedef.
9817 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
9818 reference and std::unordered_map for cu_index_htab.
9819 (add_address_entry, add_address_entry_worker, write_address_map)
9820 (write_psymbols): Update it to the new data structures.
9821 (write_obstack): Remove.
9822 (struct signatured_type_index_data): Change types_list to a data_buf
9823 reference and psyms_seen to a std::unordered_set reference.
9824 (write_one_signatured_type, recursively_write_psymbols)
9825 (write_psymtabs_to_index): Update it to the new data structures.
9827 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
9829 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
9830 separate-debug-file commands.
9831 * symfile.h (separate_debug_file_debug): New global.
9832 * symfile.c (separate_debug_file_debug): New global.
9833 (separate_debug_file_exists, find_separate_debug_file): Add
9835 (_initialize_symfile): Add "set debug separate-debug-file"
9837 * build-id.c (build_id_to_debug_bfd,
9838 find_separate_debug_file_by_buildid): Add debug output.
9840 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
9842 * gdbarch.sh (displaced_step_free_closure): Remove.
9843 * gdbarch.h, gdbarch.c: Re-generate.
9844 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
9845 displaced_step_free_closure.
9846 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
9847 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
9848 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9849 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
9850 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9851 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
9852 * arch-utils.h (simple_displaced_step_free_closure): Remove.
9853 * arch-utils.c (simple_displaced_step_free_closure): Remove.
9854 * infrun.c (displaced_step_clear): Call xfree instead of
9855 gdbarch_displaced_step_free_closure.
9857 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
9859 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
9862 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9864 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
9865 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
9866 (mn10300_push_dummy_call): Likewise.
9868 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9870 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
9872 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9874 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
9876 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9878 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
9879 able to start inferiors using a shell.
9880 (New remote packets): Announce new packet "QStartupWithShell".
9881 * remote.c: Add PACKET_QStartupWithShell.
9882 (extended_remote_create_inferior): Handle new
9883 PACKET_QStartupWithShell.
9884 (remote_protocol_features) <QStartupWithShell>: New entry for
9885 PACKET_QStartupWithShell.
9886 (_initialize_remote): Call "add_packet_config_cmd" for
9889 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9890 Pedro Alves <palves@redhat.com>
9892 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
9893 and "nat/fork-inferior.h".
9894 * common/common-inferior.h: New file, with contents from
9896 * commom/common-utils.c: Include "common-utils.h".
9897 (stringify_argv): New function.
9898 * common/common-utils.h (stringify_argv): New prototype.
9899 * configure.nat: Add "fork-inferior.o" as a dependency for
9900 "*linux*", "fbsd*" and "nbsd*" hosts.
9901 * corefile.c (get_exec_file): Update comment.
9902 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
9903 instead of "startup_inferior".
9904 (darwin_create_inferior): Call "add_thread_silent" after
9906 * fork-child.c: Cleanup unnecessary includes.
9907 (SHELL_FILE): Move to "common/common-fork-child.c".
9908 (environ): Likewise.
9909 (exec_wrapper): Initialize.
9910 (get_exec_wrapper): New function.
9911 (breakup_args): Move to "common/common-fork-child.c"; rename to
9912 "breakup_args_for_exec".
9913 (escape_bang_in_quoted_argument): Move to
9914 "common/common-fork-child.c".
9915 (saved_ui): New variable.
9916 (prefork_hook): New function.
9917 (postfork_hook): Likewise.
9918 (postfork_child_hook): Likewise.
9919 (gdb_startup_inferior): Likewise.
9920 (fork_inferior): Move to "common/common-fork-child.c". Update
9921 function to support gdbserver.
9922 (startup_inferior): Likewise.
9923 * gdbcore.h (get_exec_file): Remove declaration.
9924 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
9925 instead of "startup_inferior". Call "add_thread_silent" after
9927 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
9928 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
9929 instead of "startup_inferior". Call "add_thread_silent" after
9931 * inferior.h: Include "common-inferior.h".
9932 (trace_start_error): Move to "common/common-utils.h".
9933 (trace_start_error_with_name): Likewise.
9934 (fork_inferior): Move prototype to "nat/fork-inferior.h".
9935 (startup_inferior): Likewise.
9936 (gdb_startup_inferior): New prototype.
9937 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
9938 * nat/fork-inferior.h: New file.
9939 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
9940 instead of "startup_inferior". Call "add_thread_silent" after
9942 * target.h (target_terminal_init): Move prototype to
9944 (target_terminal_inferior): Likewise.
9945 (target_terminal_ours): Likewise.
9946 * target/target.h (target_terminal_init): New prototype, moved
9948 (target_terminal_inferior): Likewise.
9949 (target_terminal_ours): Likewise.
9950 * utils.c (gdb_flush_out_err): New function.
9952 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9954 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
9955 * common/common-gdbthread.h: New file, with parts from
9957 * gdbthread.h: Include "common-gdbthread.h".
9958 (switch_to_thread): Moved to "common/common-gdbthread.h".
9960 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9962 * Makefile.in (SFILES): Add "common/job-control.c".
9963 (HFILES_NO_SRCDIR): Add "common/job-control.h".
9964 (COMMON_OBS): Add "job-control.o".
9965 * common/job-control.c: New file, with contents from
9967 * common/job-control.h: New file, with contents from "terminal.h".
9968 * fork-child.c: Include "job-control.h".
9969 * inflow.c: Include "job-control.h".
9970 (gdb_setpgid): Move to "common/common-inflow.c".
9971 (_initialize_inflow): Move setting of "job_control" to
9972 "handle_job_control".
9973 * terminal.h (job_control): Moved to "common/common-terminal.h".
9974 (gdb_setpgid): Likewise.
9975 * top.c: Include "job_control.h".
9976 * utils.c: Likewise.
9977 (job_control): Moved to "job-control.c".
9979 2017-06-07 Pedro Alves <palves@redhat.com>
9981 * Makefile.in (SFILES): Add gdb_regex.c.
9982 (COMMON_OBS): Add gdb_regex.o.
9983 * ada-lang.c (ada_add_standard_exceptions)
9984 (ada_add_exceptions_from_frame, name_matches_regex)
9985 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
9986 parameter type to compiled_regex. Adjust.
9987 (ada_exceptions_list): Use compiled_regex.
9988 * break-catch-throw.c (exception_catchpoint::pattern): Now a
9989 std::unique_ptr<compiled_regex>.
9990 (exception_catchpoint::~exception_catchpoint): Remove regfree
9992 (check_status_exception_catchpoint): Adjust to use compiled_regex.
9993 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
9994 * breakpoint.c (solib_catchpoint::compiled): Now a
9995 std::unique_ptr<compiled_regex>.
9996 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
9997 (check_status_catch_solib): Adjust to use compiled_regex.
9998 (add_solib_catchpoint): Adjust to use compiled_regex.
9999 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
10000 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
10001 compiled_regex reference. Adjust to use it.
10002 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
10003 declaration. Include "gdb_regex.h".
10004 (apropos_cmd): Change regex parameter to compiled_regex reference.
10005 * gdb_regex.c: New file.
10006 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
10008 (class compiled_regex): New.
10009 * linux-tdep.c: Include "common/gdb_optional.h".
10010 (struct mapping_regexes): New, factored out from
10011 mapping_is_anonymous_p, and adjusted to use compiled_regex.
10012 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
10013 gdb::optional and remove cleanups. Adjust to compiled_regex.
10014 * probe.c: Include "common/gdb_optional.h".
10015 (collect_probes): Use compiled_regex and gdb::optional and remove
10017 * skip.c: Include "common/gdb_optional.h".
10018 (skiplist_entry::compiled_function_regexp): Now a
10019 gdb::optional<compiled_regex>.
10020 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
10021 (free_skiplist_entry): Remove regfree call.
10022 (compile_skip_regexp, skip_rfunction_p): Adjust to use
10023 compiled_regex and gdb::optional.
10024 * symtab.c: Include "common/gdb_optional.h".
10025 (search_symbols): Use compiled_regex and gdb::optional.
10026 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
10027 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
10030 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10032 * regcache.c (regcache::save): Avoid buffer use.
10033 (regcache::dump): Likewise.
10035 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10037 * sh-tdep.c (sh_pseudo_register_read): Remove
10039 (sh_pseudo_register_write): Likewise.
10040 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
10041 (sh64_pseudo_register_write): Likewise
10043 2017-06-07 Alan Hayward <alan.hayward@arm.com>
10045 * aarch64-tdep.c (aarch64_store_return_value): Use
10047 (aarch64_pseudo_read_value): Likewise.
10048 (aarch64_pseudo_write): Likewise.
10050 2017-06-06 Yao Qi <yao.qi@linaro.org>
10052 * regformats/regdef.h (set_register_cache): Remove the
10055 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10057 * frame.c (frame_unwind_register_signed): Use
10058 frame_unwind_register_value.
10060 2017-06-06 Pedro Alves <palves@redhat.com>
10062 PR breakpoints/21553
10063 * breakpoint.c (create_breakpoints_sal_default)
10064 (init_breakpoint_sal, create_breakpoint_sal): Use
10065 gdb::unique_xmalloc_ptr for string parameters.
10066 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10067 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
10068 (base_breakpoint_create_breakpoints_sal)
10069 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
10070 (strace_marker_create_breakpoints_sal)
10071 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
10073 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
10074 gdb::unique_xmalloc_ptr for string parameters.
10075 (create_breakpoint): Constify 'extra_string' and 'cond_string'
10078 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10080 * alpha-tdep.c (alpha_register_to_value): Use
10081 get_frame_register_value.
10082 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
10084 2017-06-06 Alan Hayward <alan.hayward@arm.com>
10086 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
10087 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
10088 (ia64_value_to_register): Likewise.
10089 (ia64_extract_return_value): Likewise.
10090 (ia64_store_return_value): Likewise.
10091 (ia64_push_dummy_call): Likewise.
10093 2017-06-04 Joel Brobecker <brobecker@adacore.com>
10097 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
10099 * x86-linux-nat.c (struct arch_lwp_info): Remove.
10101 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
10103 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
10105 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
10107 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
10109 * event-loop.c (poll_timers): Unallocate timer using delete
10112 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10114 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
10115 (struct breakpoint) <~breakpoint>: New.
10116 (struct watchpoint): Inherit from breakpoint.
10117 <~watchpoint>: New.
10119 (struct tracepoint): Inherit from breakpoint.
10121 * breakpoint.c (longjmp_breakpoint_ops): Remove.
10122 (struct longjmp_breakpoint): Inherit from breakpoint.
10123 <~longjmp_breakpoint>: New.
10125 (new_breakpoint_from_type): Remove casts.
10126 (watchpoint_in_thread_scope): Remove reference to base field.
10127 (watchpoint_del_at_next_stop): Likewise.
10128 (update_watchpoint): Likewise.
10129 (watchpoint_check): Likewise.
10130 (bpstat_check_watchpoint): Likewise.
10131 (set_longjmp_breakpoint): Likewise.
10132 (struct fork_catchpoint): Inherit from breakpoint.
10134 (struct solib_catchpoint): Inherit from breakpoint.
10135 <~solib_catchpoint>: New.
10137 (dtor_catch_solib): Change to ...
10138 (solib_catchpoint::~solib_catchpoint): ... this.
10139 (breakpoint_hit_catch_solib): Remove reference to base field.
10140 (add_solib_catchpoint): Likewise.
10141 (create_fork_vfork_event_catchpoint): Likewise.
10142 (struct exec_catchpoint): Inherit from breakpoint.
10143 <~exec_catchpoint>: New.
10145 (dtor_catch_exec): Change to ...
10146 (exec_catchpoint::~exec_catchpoint): ... this.
10147 (dtor_watchpoint): Change to ...
10148 (watchpoint::~watchpoint): ... this.
10149 (watch_command_1): Remove reference to base field.
10150 (catch_exec_command_1): Likewise.
10151 (base_breakpoint_dtor): Change to ...
10152 (breakpoint::~breakpoint): ... this.
10153 (base_breakpoint_ops): Remove dtor field value.
10154 (longjmp_bkpt_dtor): Change to ...
10155 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
10156 (strace_marker_create_breakpoints_sal): Remove reference to base
10158 (delete_breakpoint): Don't manually call breakpoint destructor.
10159 (create_tracepoint_from_upload): Remove reference to base field.
10160 (trace_pass_set_count): Likewise.
10161 (initialize_breakpoint_ops): Don't initialize
10162 momentary_breakpoint_ops, don't set dtors.
10163 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
10164 <~ada_catchpoint>: New.
10166 (create_excep_cond_exprs): Remove reference to base field.
10167 (dtor_exception): Change to ...
10168 (ada_catchpoint::~ada_catchpoint): ... this.
10169 (dtor_catch_exception): Remove.
10170 (dtor_catch_exception_unhandled): Remove.
10171 (dtor_catch_assert): Remove.
10172 (create_ada_exception_catchpoint): Remove reference to base
10174 (initialize_ada_catchpoint_ops): Don't set dtors.
10175 * break-catch-sig.c (struct signal_catchpoint): Inherit from
10177 <~signal_catchpoint>: New.
10179 (signal_catchpoint_dtor): Change to ...
10180 (signal_catchpoint::~signal_catchpoint): ... this.
10181 (create_signal_catchpoint): Remove reference to base field.
10182 (initialize_signal_catchpoint_ops): Don't set dtor.
10183 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
10185 <~syscall_catchpoint>: New.
10187 (dtor_catch_syscall): Change to ...
10188 (syscall_catchpoint::~syscall_catchpoint): ... this.
10189 (create_syscall_event_catchpoint): Remove reference to base
10191 (initialize_syscall_catchpoint_ops): Don't set dtor.
10192 * break-catch-throw.c (struct exception_catchpoint): Inherit
10194 <~exception_catchpoint>: New.
10196 (dtor_exception_catchpoint): Change to ...
10197 (exception_catchpoint::~exception_catchpoint): ... this.
10198 (handle_gnu_v3_exceptions): Remove reference to base field.
10199 (initialize_throw_catchpoint_ops): Don't set dtor.
10200 * ctf.c (ctf_get_traceframe_address): Remove reference to base
10202 * remote.c (remote_get_tracepoint_status): Likewise.
10203 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
10204 * tracefile.c (tracefile_fetch_registers): Likewise.
10205 * tracepoint.c (actions_command): Likewise.
10206 (validate_actionline): Likewise.
10207 (tfind_1): Likewise.
10208 (get_traceframe_location): Likewise.
10209 (find_matching_tracepoint_location): Likewise.
10210 (parse_tracepoint_status): Likewise.
10211 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
10213 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10215 * breakpoint.c (struct longjmp_breakpoint): New struct.
10216 (is_tracepoint_type): Change return type to bool.
10217 (is_longjmp_type): New function.
10218 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
10219 (set_raw_breakpoint_without_location): Use
10220 new_breakpoint_from_type.
10221 (set_raw_breakpoint): Likewise.
10223 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
10225 * breakpoint.c (new_breakpoint_from_type): New function.
10226 (create_breakpoint_sal): Use new_breakpoint_from_type and
10228 (create_breakpoint): Likewise.
10230 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
10232 * memattr.c (mem_info_command): Rename to ...
10233 (info_mem_command): ... this.
10234 (mem_enable_command): Rename to ...
10235 (enable_mem_command): ... this.
10236 (mem_disable_command): Rename to ...
10237 (disable_mem_command): ... this.
10238 (mem_delete_command): Rename to ...
10239 (delete_mem_command): ... this.
10240 (_initialize_mem): Adjust function names.
10242 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
10244 * btrace.c (handle_pt_insn_events): New.
10245 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
10246 STATUS. Split into this and ...
10247 (handle_pt_insn_event_flags): ... this.
10249 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
10251 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
10252 and struct pt_insn.resynced.
10253 * configure: Regenerated.
10254 * config.in: Regenerated.
10256 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10258 * btrace.c (ftrace_find_call_by_number): New function.
10259 (ftrace_new_function): Store objects, not pointers.
10260 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
10261 ftrace_new_gap, ftrace_update_function,
10262 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
10263 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
10264 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
10265 btrace_ends_with_single_insn, btrace_call_get): Account for
10266 btrace_thread_info::functions now storing objects.
10267 * btrace.h (struct btrace_thread_info): Add constructor.
10268 (struct btrace_thread_info) <functions>: Make std::vector.
10269 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
10270 Initialize with default values.
10271 * record-btrace.c (record_btrace_frame_sniffer): Account for
10272 btrace_thread_info::functions now storing objects.
10274 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10276 * btrace.c: Remove typedef bfun_s.
10277 (ftrace_new_gap): Directly add gaps to the list of gaps.
10278 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
10279 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
10280 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
10281 instead of gdb VEC.
10283 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10285 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
10286 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
10287 with btrace_thread_info::next_segment and
10288 btrace_thread_info::prev_segment.
10289 * btrace.h: Remove struct btrace_func_link.
10290 (struct btrace_function): Replace pair of function segment pointers
10291 with pair of indices.
10292 * python/py-record-btrace.c (btpy_call_prev_sibling,
10293 btpy_call_next_sibling): Replace references to
10294 btrace_thread_info::segment with btrace_thread_info::next_segment and
10295 btrace_thread_info::prev_segment.
10296 * record-btrace.c (record_btrace_frame_this_id): Use
10297 btrace_find_call_by_number.
10299 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10301 * btrace.c (ftrace_new_function, ftrace_fixup_level,
10302 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
10303 btrace_insn_next, btrace_insn_prev): Remove references to
10304 btrace_thread_info::flow.
10305 * btrace.h (struct btrace_function): Remove FLOW.
10307 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10309 * btrace.c (ftrace_find_call_by_number): New function.
10310 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
10311 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
10312 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
10313 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
10315 * btrace.h (struct btrace_function): Turn UP into an index.
10316 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
10318 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
10319 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
10320 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
10322 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10324 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
10325 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
10326 ftrace_update_function, ftrace_compute_global_level_offset,
10327 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
10328 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
10329 btrace_insn_end, btrace_is_empty): Remove references to
10330 btrace_thread_info::begin and btrace_thread_info::end.
10331 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
10332 (struct btrace_thread_info) <functions>: Adjust comment.
10333 * record-btrace.c (record_btrace_start_replaying): Remove reference to
10334 btrace_thread_info::begin.
10336 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10338 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
10339 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
10340 ftrace_update_function): Remove arguments that implicitly were always
10342 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
10343 Don't pass BTINFO->END.
10345 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10347 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
10348 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
10349 btrace_find_insn_by_number): Replace function segment pointer with
10351 (btrace_insn_cmp): Simplify.
10352 * btrace.h: (struct btrace_insn_iterator) Rename index to
10353 insn_index. Replace function segment pointer with index into function
10355 * record-btrace.c (record_btrace_call_history): Replace function
10356 segment pointer use with index.
10357 (record_btrace_frame_sniffer): Retrieve function call segment through
10359 (record_btrace_set_replay): Remove defunc't safety check.
10361 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10363 * btrace.c (btrace_ends_with_single_insn): New function.
10364 (btrace_call_get, btrace_call_number, btrace_call_begin,
10365 btrace_call_end, btrace_call_next, btrace_call_prev,
10366 btrace_find_call_by_number): Use index into call segment vector
10367 instead of pointer.
10368 (btrace_call_cmp): Simplify.
10369 * btrace.h (struct btrace_call_iterator): Replace function call segment
10370 pointer with index into vector.
10371 * record-btrace.c (record_btrace_call_history): Use index instead of
10374 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10376 * btrace.c (btrace_insn_begin, btrace_insn_end,
10377 btrace_find_insn_by_number): Add btinfo to iterator.
10378 * btrace.h (struct btrace_insn_iterator): Add btinfo.
10380 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10382 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
10383 and save pointers directly.
10384 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
10385 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
10386 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
10387 changed signature of functions.
10388 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
10389 (btrace_fetch): Remove code that adds btrace_function pointers to
10390 vector of btrace_functions.
10391 (btrace_clear): Simplify freeing vector of btrace_functions.
10393 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10395 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
10396 Replace VEC_* with std::vector functions.
10397 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
10398 (struct btrace_thread_info)<functions>: Change type to std::vector.
10400 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
10402 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
10403 "Removed targets and native configurations" up. Merge duplicate
10404 "New commands" sub-sections. Add "New options" sub-sections.
10406 2017-05-26 Alan Hayward <alan.hayward@arm.com>
10408 * defs.h (copy_integer_to_size): New declaration.
10409 * findvar.c (copy_integer_to_size): New function.
10410 (do_cint_test): New selftest function.
10411 (copy_integer_to_size_test): Likewise.
10412 (_initialize_findvar): Likewise.
10413 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
10414 (mips_fbsd_collect_reg): Use raw_collect_integer.
10415 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
10416 (mips64_fill_gregset): Use raw_collect_integer
10417 (mips64_fill_fpregset): Use raw_supply_integer.
10418 * regcache.c (regcache::raw_supply_integer): New function.
10419 (regcache::raw_collect_integer): Likewise.
10420 * regcache.h: (regcache::raw_supply_integer): New declaration.
10421 (regcache::raw_collect_integer): Likewise.
10423 2017-05-24 Yao Qi <yao.qi@linaro.org>
10425 * Makefile.in (SFILES): Add gdbarch-selftests.c.
10426 (COMMON_OBS): Add gdbarch-selftests.o.
10427 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
10428 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
10429 * gdbarch-selftests.c: New file.
10430 * regcache.h (regcache) <~regcache>: Mark it virtual if
10432 <raw_write>: Likewise.
10434 2017-05-24 Yao Qi <yao.qi@linaro.org>
10436 * regcache.c (current_regcache): Change it to
10437 regcache::current_regcache.
10438 (regcache_observer_target_changed): Update.
10439 (regcache_thread_ptid_changed): Make it a regcache static
10441 (regcache_thread_ptid_changed): Update.
10442 (class regcache_access): New.
10443 (current_regcache_test): Update.
10444 (_initialize_regcache): Update.
10445 * regcache.h: Include forward_list.
10446 (regcache): Declare regcache_thread_ptid_changed and declare
10447 registers_changed_ptid as friend.
10449 2017-05-24 Yao Qi <yao.qi@linaro.org>
10451 * i387-tdep.c (i387_register_to_value): Use register_size
10452 instead of TYPE_LENGTH.
10453 * m68k-tdep.c (m68k_register_to_value): Likewise.
10455 2017-05-24 Yao Qi <yao.qi@linaro.org>
10457 * i387-tdep.c (i387_convert_register_p): Return false if type
10458 code isn't TYPE_CODE_FLT.
10460 2017-05-24 Yao Qi <yao.qi@linaro.org>
10462 * alpha-tdep.c (alpha_convert_register_p): Return true if type
10464 (alpha_register_to_value): Remove type length check.
10465 (alpha_value_to_register): Likewise.
10467 2017-05-24 Yao Qi <yao.qi@linaro.org>
10469 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
10472 2017-05-24 Yao Qi <yao.qi@linaro.org>
10474 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
10475 TYPE_CODE_FLT or not.
10477 2017-05-24 Yao Qi <yao.qi@linaro.org>
10479 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
10480 * avr-tdep.c (avr_gdbarch_init): Likewise.
10481 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10482 * cris-tdep.c (cris_gdbarch_init): Likewise.
10483 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10484 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10485 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10486 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
10487 * mep-tdep.c (mep_gdbarch_init): Likewise.
10488 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10489 * mips-tdep.c (mips_gdbarch_init): Likewise.
10490 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10491 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10492 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10493 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10494 * v850-tdep.c (v850_gdbarch_init): Likewise.
10496 2017-05-24 Yao Qi <yao.qi@linaro.org>
10498 * selftest-arch.c (tests_with_arch): Call registers_changed
10499 and reinit_frame_cache.
10500 * selftest.c (run_self_tests): Likewise.
10502 2017-05-24 Yao Qi <yao.qi@linaro.org>
10504 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
10505 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
10507 2017-05-24 Yao Qi <yao.qi@linaro.org>
10509 * rl78-tdep.c (rl78_gdbarch_init): Don't call
10510 set_gdbarch_print_insn.
10512 2017-05-24 Yao Qi <yao.qi@linaro.org>
10514 * h8300-tdep.c (h8300_gdbarch_init): Don't call
10515 set_gdbarch_print_insn.
10517 2017-05-24 Yao Qi <yao.qi@linaro.org>
10519 * alpha-tdep.c (alpha_gdbarch_init): Don't call
10520 set_gdbarch_print_insn.
10521 * arc-tdep.c (arc_gdbarch_init): Likewise.
10522 * arch-utils.c: include dis-asm.h.
10523 (default_print_insn): New function.
10524 * arch-utils.h (default_print_insn): Declare.
10525 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
10526 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10527 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
10528 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
10529 * frv-tdep.c (frv_gdbarch_init): Likewise.
10530 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10531 * gdbarch.sh (print_insn): Use default_print_insn.
10532 * gdbarch.c: Regenerated.
10533 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
10534 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
10535 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10536 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
10537 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10538 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
10539 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
10540 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
10541 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
10542 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10543 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10544 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10545 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10546 * mt-tdep.c (mt_gdbarch_init): Likewise.
10547 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10548 * nios2-tdep.c (nios2_print_insn): Remove.
10549 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
10550 * rx-tdep.c (rx_gdbarch_init): Likewise.
10551 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10552 * score-tdep.c (score_print_insn): Remove.
10553 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
10554 * sh-tdep.c (sh_gdbarch_init): Likewise.
10555 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10556 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10557 * tic6x-tdep.c (tic6x_print_insn): Remove.
10558 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
10559 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
10560 * v850-tdep.c (v850_gdbarch_init): Likewise.
10561 * vax-tdep.c (vax_gdbarch_init): Likewise.
10562 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10563 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
10565 2017-05-23 John Baldwin <jhb@FreeBSD.org>
10567 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
10568 (MIPS_FP0_REGNUM): Remove.
10569 (MIPS_FSR_REGNUM): Remove.
10570 (mips_fbsd_supply_fpregs): Use mips_regnum.
10571 (mips_fbsd_supply_gregs): Likewise.
10572 (mips_fbsd_collect_fpregs): Likewise.
10573 (mips_fbsd_collect_gregs): Likewise.
10575 2017-05-23 John Baldwin <jhb@FreeBSD.org>
10577 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
10578 (getpfpregs_supplies): New function.
10579 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
10580 getfpregs_supplies.
10581 (mips_fbsd_store_inferior_registers): Likewise.
10583 2017-05-22 Pedro Alves <palves@redhat.com>
10585 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
10588 2017-05-22 Alan Hayward <alan.hayward@arm.com>
10590 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
10591 (store_register): Likewise.
10592 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
10593 (get_decimal_float_return_value): Likewise.
10594 (do_ppc_sysv_return_value): Likewise.
10595 (ppc64_sysv_abi_push_integer): Likewise.
10596 (ppc64_sysv_abi_push_freg): Likewise.
10597 (ppc64_sysv_abi_return_value_base): Likewise.
10598 (ppc64_sysv_abi_return_value): Likewise.
10599 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
10600 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
10601 * rs6000-nat.c: Likewise.
10602 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
10603 (rs6000_value_to_register): Likewise.
10604 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
10606 2017-05-21 Tom Tromey <tom@tromey.com>
10609 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
10610 arrays as "[T]", not "[T; ]".
10612 2017-05-19 Tom Tromey <tom@tromey.com>
10615 * rust-lang.c (exp_descriptor_rust): New function.
10616 (rust_language_defn): Use it.
10617 * p-lang.c (pascal_language_defn): Update.
10618 * opencl-lang.c (opencl_language_defn): Update.
10619 * objc-lang.c (objc_language_defn): Update.
10620 * m2-lang.c (m2_language_defn): Update.
10621 * language.h (struct language_defn)
10622 <la_watch_location_expression>: New member.
10623 * language.c (unknown_language_defn, auto_language_defn)
10624 (local_language_defn): Update.
10625 * go-lang.c (go_language_defn): Update.
10626 * f-lang.c (f_language_defn): Update.
10627 * d-lang.c (d_language_defn): Update.
10628 * c-lang.h (c_watch_location_expression): Declare.
10629 * c-lang.c (c_watch_location_expression): New function.
10630 (c_language_defn, cplus_language_defn, asm_language_defn)
10631 (minimal_language_defn): Use it.
10632 * breakpoint.c (watch_command_1): Call
10633 la_watch_location_expression.
10634 * ada-lang.c (ada_language_defn): Update.
10636 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10639 * gdb_curses.h (NOMACROS): Define.
10640 (NCURSES_NOMACROS): Define.
10642 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10645 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
10647 * tui/tui-wingeneral.c (box_win): Likewise.
10648 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
10649 (tui_show_source_line): Likewise.
10650 (tui_show_exec_info_content): Likewise.
10652 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
10654 * sparc-tdep.c (sparc_structure_return_p)
10655 (sparc_arg_on_registers_p): New functions.
10656 (sparc32_store_arguments): Use them.
10657 * sparc64-tdep.c (sparc64_16_byte_align_p)
10658 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
10659 Handle TYPE_CODE_ARRAY.
10661 2017-05-17 Yao Qi <yao.qi@linaro.org>
10663 * cli/cli-decode.c (add_alias_cmd): New function.
10664 * command.h (add_alias_cmd): Declare.
10665 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
10666 instead call add_alias_cmd.
10668 2017-05-17 Pedro Alves <palves@redhat.com>
10670 * Makefile.in (nat_extra_makefile_frag): Rename to ...
10671 (nat_makefile_frag): ... this. All references updated.
10672 * configure.ac: Likewise.
10673 * configure.nat: Likewise. Enhance comments.
10674 * configure: Regenerate.
10676 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10678 * procfs.c (procfs_create_inferior): Change prototype to match
10681 2017-05-13 Eli Zaretskii <eliz@gnu.org>
10683 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
10684 C++ compiler warning.
10686 2017-05-12 Tom Tromey <tom@tromey.com>
10689 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
10690 recurse, just call value_struct_elt directly.
10692 2017-05-12 Tom Tromey <tom@tromey.com>
10694 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
10695 OP_RUST_ARRAY>: Fix.
10697 2017-05-12 Tom Tromey <tom@tromey.com>
10699 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
10701 2017-05-09 Yao Qi <yao.qi@linaro.org>
10703 * regcache.c: Include <forward_list>.
10704 (struct regcache_list): Remove.
10705 (current_regcache): Update.
10706 (get_thread_arch_aspace_regcache): Update for std::forward_list.
10707 (regcache_thread_ptid_changed): Likewise.
10708 (registers_changed_ptid): Likewise.
10709 (current_regcache_size): Likewise.
10711 2017-05-09 Yao Qi <yao.qi@linaro.org>
10713 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
10714 (current_regcache_size): New function.
10715 (current_regcache_test): New function.
10716 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
10718 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10720 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
10721 (print_gp_register_row): Use get_frame_register_value.
10723 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10725 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
10726 (mips_supply_fpregset): Likewise.
10727 (mips64_supply_gregset): Likewise.
10729 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10731 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
10732 regcache->raw_supply_zeroed.
10734 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10736 * configure.nat: Rearrange 'case' statements to match
10739 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10741 * Makefile.in: Remove "@host_makefile_frag@". Add variables
10742 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
10743 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
10744 "@nat_extra_makefile_frag@".
10745 (Makefile): Remove dependency on "@frags@".
10746 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
10747 (data-directory/Makefile): Likewise.
10748 * config/aarch64/linux.mh: Deleted; moved contents to
10749 "gdb/configure.nat".
10750 * config/alpha/alpha-linux.mh: Likewise.
10751 * config/alpha/nbsd.mh: Likewise.
10752 * config/arm/linux.mh: Likewise.
10753 * config/arm/nbsdelf.mh: Likewise.
10754 * config/i386/cygwin.mh: Likewise.
10755 * config/i386/cygwin64.mh: Likewise.
10756 * config/i386/darwin.mh: Likewise.
10757 * config/i386/fbsd.mh: Likewise.
10758 * config/i386/fbsd64.mh: Likewise.
10759 * config/i386/go32.mh: Likewise.
10760 * config/i386/i386gnu.mh: Likewise.
10761 * config/i386/i386sol2.mh: Likewise.
10762 * config/i386/linux.mh: Likewise.
10763 * config/i386/linux64.mh: Likewise.
10764 * config/i386/mingw.mh: Likewise.
10765 * config/i386/mingw64.mh: Likewise.
10766 * config/i386/nbsd64.mh: Likewise.
10767 * config/i386/nbsdelf.mh: Likewise.
10768 * config/i386/nto.mh: Likewise.
10769 * config/i386/obsd.mh: Likewise.
10770 * config/i386/obsd64.mh: Likewise.
10771 * config/i386/sol2-64.mh: Likewise.
10772 * config/ia64/linux.mh: Likewise.
10773 * config/m32r/linux.mh: Likewise.
10774 * config/m68k/linux.mh: Likewise.
10775 * config/m68k/nbsdelf.mh: Likewise.
10776 * config/m68k/obsd.mh: Likewise.
10777 * config/m88k/obsd.mh: Likewise.
10778 * config/mips/fbsd.mh: Likewise.
10779 * config/mips/linux.mh: Likewise.
10780 * config/mips/nbsd.mh: Likewise.
10781 * config/mips/obsd64.mh: Likewise.
10782 * config/pa/linux.mh: Likewise.
10783 * config/pa/nbsd.mh: Likewise.
10784 * config/pa/obsd.mh: Likewise.
10785 * config/powerpc/aix.mh: Likewise.
10786 * config/powerpc/fbsd.mh: Likewise.
10787 * config/powerpc/linux.mh: Likewise.
10788 * config/powerpc/nbsd.mh: Likewise.
10789 * config/powerpc/obsd.mh: Likewise.
10790 * config/powerpc/ppc64-linux.mh: Likewise.
10791 * config/powerpc/spu-linux.mh: Likewise.
10792 * config/s390/linux.mh: Likewise.
10793 * config/sh/nbsd.mh: Likewise.
10794 * config/sparc/fbsd.mh: Likewise.
10795 * config/sparc/linux.mh: Likewise.
10796 * config/sparc/linux64.mh: Likewise.
10797 * config/sparc/nbsd64.mh: Likewise.
10798 * config/sparc/nbsdelf.mh: Likewise.
10799 * config/sparc/obsd64.mh: Likewise.
10800 * config/sparc/sol2.mh: Likewise.
10801 * config/tilegx/linux.mh: Likewise.
10802 * config/vax/nbsdelf.mh: Likewise.
10803 * config/vax/obsd.mh: Likewise.
10804 * config/xtensa/linux.mh: Likewise.
10805 * config/i386/i386gnu.mn: New file, with excerpts from
10806 "config/i386/i386gnu.mh".
10807 * configure: Regenerate.
10808 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
10809 *.mh files under "gdb/config".
10810 * configure.nat: New file, with contents from the
10811 "gdb/config/*/*.mh" files.
10813 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
10815 * btrace.c (btrace_clear): Free insn vector.
10817 2017-05-05 Pedro Alves <palves@redhat.com>
10819 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
10820 * configure: Regenerate.
10822 2017-05-04 Pedro Alves <palves@redhat.com>
10824 * Makefile.in (SFILES): Add progspace-and-thread.c.
10825 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
10826 (COMMON_OBS): Add progspace-and-thread.o.
10827 * breakpoint.c: Include "progspace-and-thread.h".
10828 (update_inserted_breakpoint_locations)
10829 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
10830 Use scoped_restore_current_pspace_and_thread.
10831 (create_std_terminate_master_breakpoint): Use
10832 scoped_restore_current_program_space.
10833 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
10834 (print_breakpoint_location): Use
10835 scoped_restore_current_program_space.
10836 (bp_loc_is_permanent): Use
10837 scoped_restore_current_pspace_and_thread.
10838 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
10839 (download_tracepoint_locations): Use
10840 scoped_restore_current_pspace_and_thread.
10841 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
10842 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
10843 (enum step_over_calls_kind): Moved from inferior.h.
10844 (class scoped_restore_current_thread): New class.
10845 * gdbthread.h (make_cleanup_restore_current_thread): Delete
10847 (scoped_restore_current_thread): New class.
10848 * infcmd.c: Include "common/gdb_optional.h".
10849 (continue_1, proceed_after_attach): Use
10850 scoped_restore_current_thread.
10851 (notice_new_inferior): Use scoped_restore_current_thread.
10852 * inferior.c: Include "progspace-and-thread.h".
10853 (restore_inferior, save_current_inferior): Delete.
10854 (add_inferior_command, clone_inferior_command): Use
10855 scoped_restore_current_pspace_and_thread.
10856 * inferior.h (scoped_restore_current_inferior): New class.
10857 * infrun.c: Include "progspace-and-thread.h" and
10858 "common/gdb_optional.h".
10859 (follow_fork_inferior): Use
10860 scoped_restore_current_pspace_and_thread.
10861 (scoped_restore_exited_inferior): New class.
10862 (handle_vfork_child_exec_or_exit): Use
10863 scoped_restore_exited_inferior,
10864 scoped_restore_current_pspace_and_thread,
10865 scoped_restore_current_thread and scoped_restore.
10866 (fetch_inferior_event): Use scoped_restore_current_thread.
10867 * linespec.c (decode_line_full, decode_line_1): Use
10868 scoped_restore_current_program_space.
10869 * mi/mi-main.c: Include "progspace-and-thread.h".
10870 (exec_continue): Use scoped_restore_current_thread.
10871 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
10872 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
10873 * proc-service.c (ps_pglobal_lookup): Use
10874 scoped_restore_current_program_space.
10875 * progspace-and-thread.c: New file.
10876 * progspace-and-thread.h: New file.
10877 * progspace.c (release_program_space, clone_program_space): Use
10878 scoped_restore_current_program_space.
10879 (restore_program_space, save_current_program_space)
10880 (save_current_space_and_thread): Delete.
10881 (switch_to_program_space_and_thread): Moved to
10882 progspace-and-thread.c.
10883 * progspace.h (save_current_program_space)
10884 (save_current_space_and_thread): Delete declarations.
10885 (scoped_restore_current_program_space): New class.
10886 * remote.c (remote_btrace_maybe_reopen): Use
10887 scoped_restore_current_thread.
10888 * symtab.c: Include "progspace-and-thread.h".
10889 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
10890 * thread.c (print_thread_info_1): Use
10891 scoped_restore_current_thread.
10892 (struct current_thread_cleanup): Delete.
10893 (do_restore_current_thread_cleanup)
10894 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
10895 (scoped_restore_current_thread::~scoped_restore_current_thread):
10897 (make_cleanup_restore_current_thread): Rename/convert to ...
10898 (scoped_restore_current_thread::scoped_restore_current_thread):
10900 (thread_apply_all_command): Use scoped_restore_current_thread.
10901 (thread_apply_command): Use scoped_restore_current_thread.
10902 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
10903 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
10905 2017-05-04 Pedro Alves <palves@redhat.com>
10907 * thread.c (make_cleanup_restore_current_thread): Move
10908 find_thread_ptid call before the is_stopped call. Assert that the
10909 thread is found. Replace is_stopped call by checking the thread's
10910 state directly. Remove unnecessary NULL-thread check.
10912 2017-05-04 Pedro Alves <palves@redhat.com>
10914 * corelow.c (thread_section_name): New class.
10915 (get_core_register_section, get_core_siginfo): Use it.
10917 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
10919 * corelow.c (sniff_core_bfd): Remove extra semicolon.
10920 (get_core_register_section): Remove xfree of NULL pointer.
10922 2017-05-03 Alan Hayward <alan.hayward@arm.com>
10924 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
10925 * regcache.c (regcache::raw_supply_zeroed): New function.
10926 * regcache.h (regcache::raw_supply_zeroed): New declaration.
10928 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
10930 * gdbarch.sh: Remove commented out definition of
10932 * gdbarch.h: Re-generate.
10934 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
10936 * configure: Regenerate.
10938 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
10940 * solib-target.c (solib_target_relocate_section_addresses):
10941 Remove num_section_bases, num_bases, segment_bases variables.
10943 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10945 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
10947 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10949 * solib-target.c: Include <vector>
10950 (struct lm_info_target) <~lm_info_target>: Remove.
10951 <segment_bases, section_bases>: Change type to
10952 std::vector<CORE_ADDR>.
10953 (library_list_start_segment, library_list_start_section,
10954 library_list_end_library,
10955 solib_target_relocate_section_addresses): Adjust.
10957 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10959 * gdbarch.sh (software_single_step): Change return type to
10960 std::vector<CORE_ADDR>.
10961 * gdbarch.c, gdbarch.h: Re-generate.
10962 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
10964 (arm_deal_with_atomic_sequence_raw): Adjust.
10965 (thumb_get_next_pcs_raw): Adjust.
10966 (arm_get_next_pcs_raw): Adjust.
10967 (arm_get_next_pcs): Adjust.
10968 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
10969 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
10970 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
10971 (alpha_software_single_step): Adjust.
10972 * alpha-tdep.h (alpha_software_single_step): Adjust.
10973 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
10974 * arm-tdep.c (arm_software_single_step): Adjust.
10975 (arm_breakpoint_kind_from_current_state): Adjust.
10976 * arm-tdep.h (arm_software_single_step): Adjust.
10977 * breakpoint.c (insert_single_step_breakpoint): Adjust.
10978 * cris-tdep.c (cris_software_single_step): Adjust.
10979 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
10980 (micromips_deal_with_atomic_sequence): Adjust.
10981 (deal_with_atomic_sequence): Adjust.
10982 (mips_software_single_step): Adjust.
10983 * mips-tdep.h (mips_software_single_step): Adjust.
10984 * moxie-tdep.c (moxie_software_single_step): Adjust.
10985 * nios2-tdep.c (nios2_software_single_step): Adjust.
10986 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
10987 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
10988 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
10989 * s390-linux-tdep.c (s390_software_single_step): Adjust.
10990 * sparc-tdep.c (sparc_software_single_step): Adjust.
10991 * spu-tdep.c (spu_software_single_step): Adjust.
10992 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
10994 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10996 * gdbarch.sh: Use semi-colon as field separator instead of colon.
10997 * gdbarch.h: Re-generate.
10999 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11001 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
11002 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
11003 * python/py-instruction.c, python/py-instruction.h: New file.
11004 * python/py-record.c: Add py-instruction.h include.
11005 (gdbpy_initialize_record): Make gdb.Instruction a super class of
11006 gdb.RecordInstruction.
11007 * python/python-internal.h: Add gdbpy_initialize_instruction
11009 * python/python.c (do_start_initialization): Add
11010 gdbpy_initialize_instruction.
11012 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11014 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
11016 (btrace_func_from_recpy_func): New function.
11017 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
11018 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
11019 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
11020 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
11021 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
11022 Also, use new helper functions.
11023 (btpy_list_item): Use new helper functions.
11024 (recpy_bt_function_call_history): Use new type name.
11025 (btpy_call_getset): Remove.
11026 (gdbpy_initialize_btrace): Remove code to initialize
11027 gdb.BtraceFunctionCall.
11028 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
11029 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
11030 recpy_bt_func_prev, recpy_bt_func_next): New export.
11031 * python/py-record.c (recpy_func_type): New static object.
11032 (recpy_func_new, recpy_func_level, recpy_func_symbol,
11033 recpy_func_instructions, recpy_func_up, recpy_func_prev,
11034 recpy_func_next): New function.
11035 (recpy_element_hash, recpy_element_richcompare): Updated comment.
11036 (recpy_func_getset): New static object.
11037 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
11038 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
11040 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11042 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
11043 (btpy_object, btpy_insn_type, btpy_new): Remove.
11044 (btpy_list_object): Use gdb.RecordInstruction type instead of
11045 gdb.BtraceInstruction type.
11046 (btrace_insn_from_recpy_insn): New function.
11047 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
11049 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
11050 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
11051 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
11052 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
11053 instead of btpy_object.
11054 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11055 btpy_insn_data, btpy_insn_decode): Rename to ...
11056 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
11057 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
11058 recpy_bt_insn_decode): This. Also, use new helper functions.
11059 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
11061 (btpy_insn_getset): Remove.
11062 (gdbpy_initialize_btrace): Remove code to initialize
11063 gdb.BtraceInstruction. Use recpy_element_object.
11064 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
11065 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
11066 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
11067 * python/py-record.c (recpy_insn_type): New static object.
11068 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
11069 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
11070 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
11072 (recpy_insn_getset): New static object.
11073 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
11074 * python/py-record.h (recpy_element_object): New typedef.
11075 (recpy_insn_type, recpy_insn_new): New export.
11077 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11079 * py-record-btrace.c (btpy_insn_new): Removed.
11080 (btpy_insn_or_gap_new): New function.
11081 (btpy_insn_error): Removed.
11082 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
11083 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
11084 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
11085 btpy_insn_or_gap_new instead of btpy_insn_new.
11086 (btpy_insn_getset): Remove btpy_insn_error.
11087 * py-record.c (recpy_gap_type): New static object.
11088 (recpy_gap_object): New typedef.
11089 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
11090 recpy_gap_reason_string): New function.
11091 (recpy_gap_getset): New static object.
11092 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
11093 * py-record.h (recpy_gap_new): New export.
11095 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11097 * python/py-record.c (recpy_ptid): Remove.
11098 (recpy_record_getset): Remove recpy_ptid.
11100 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11102 * btrace.c (btrace_fetch): Set inferior_ptid.
11103 * python/py-record-btrace.c: Add "py-record.h" include.
11104 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
11105 recpy_bt_end, recpy_bt_instruction_history,
11106 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
11107 in gdb.Record object instead of current ptid.
11108 * python/py-record.c: Include new "py-record.h" file.
11109 (recpy_record_object): Moved to py-record.h.
11110 * python/py-record.h: New file.
11112 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
11114 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
11115 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
11118 2017-05-01 Joel Brobecker <brobecker@adacore.com>
11120 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
11121 the past maintainers section.
11123 2017-04-28 Yao Qi <yao.qi@linaro.org>
11125 * infcmd.c (get_return_value): Use regcache ctor, and remove
11128 2017-04-28 Yao Qi <yao.qi@linaro.org>
11129 Pedro Alves <palves@redhat.com>
11131 * regcache.c (regcache::regcache): New tag dispatch ctor.
11132 (do_cooked_read): Moved above.
11133 (regcache_dup): Use the tag dispatch ctor..
11134 * regcache.h (regcache): Declare ctor, delete copy ctor and
11135 assignment operator, remove friend regcache_dup.
11137 2017-04-28 Yao Qi <yao.qi@linaro.org>
11139 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
11140 call method save instead of regcache_cpy.
11141 * regcache.h (struct regcache): Make regcache_dup a friend.
11143 2017-04-28 Yao Qi <yao.qi@linaro.org>
11145 * regcache.c (struct regcache): Move to regcache.h
11146 (regcache::arch): New method.
11147 (regcache_get_ptid): Update.
11148 (get_regcache_arch): Call arch method.
11149 (get_regcache_aspace): Call method aspace.
11150 (register_buffer): Change it to method.
11151 (regcache_save): Change it to regcache::save.
11152 (regcache_restore): Likewise.
11153 (regcache_cpy_no_passthrough): Remove the declaration.
11154 (regcache_cpy): Call methods restore and cpy_no_passthrough.
11155 (regcache_cpy_no_passthrough): Change it to method
11156 cpy_no_passthrough.
11157 (regcache_register_status): Change it to method
11158 get_register_status.
11159 (regcache_invalidate): Change it to method invalidate.
11160 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
11161 (regcache_raw_update): Change it to method raw_update.
11162 (regcache_raw_read): Likewise.
11163 (regcache_raw_read_signed): Likewise.
11164 (regcache_raw_read_unsigned): Likewise.
11165 (regcache_raw_write_signed): Likewise.
11166 (regcache_raw_write_unsigned): Likewise.
11167 (regcache_cooked_read): Likewise.
11168 (regcache_cooked_read_value): Likewise.
11169 (regcache_cooked_read_signed): Likewise.
11170 (regcache_cooked_read_unsigned): Likewise.
11171 (regcache_cooked_write_signed): Likewise.
11172 (regcache_cooked_write_unsigned): Likewise.
11173 (regcache_raw_set_cached_value): Likewise.
11174 (regcache_raw_write): Likewise.
11175 (regcache_cooked_write): Likewise.
11176 (regcache_xfer_part): Likewise.
11177 (regcache_raw_read_part): Likewise.
11178 (regcache_raw_write_part): Likewise.
11179 (regcache_cooked_read_part): Likewise.
11180 (regcache_cooked_write_part): Likewise.
11181 (regcache_raw_supply): Likewise.
11182 (regcache_raw_collect): Likewise.
11183 (regcache_transfer_regset): Likewise.
11184 (regcache_supply_regset): Likewise.
11185 (regcache_collect_regset): Likewise.
11186 (regcache_debug_print_register): Likewise.
11187 (enum regcache_dump_what): Move it to regcache.h.
11188 (regcache_dump): Change it to method dump.
11189 * regcache.h (enum regcache_dump_what): New.
11190 (class regcache): New.
11191 * target.c (target_fetch_registers): Call method
11192 debug_print_register.
11193 (target_store_registers): Likewise.
11195 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11197 * windows-nat.c (struct lm_info_windows): Initialize field.
11198 (windows_make_so): Allocate lm_info_windows with new.
11199 (windows_free_so): Free lm_info_windows with delete.
11201 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11203 * solib-darwin.c (struct lm_info_darwin): Initialize field.
11204 (darwin_current_sos): Allocate lm_info_darwin with new, remove
11206 (darwin_free_so): Free lm_info_darwin with delete.
11208 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11210 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
11211 <l_addr_p>: Change type to bool.
11212 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
11213 (svr4_free_so): Free lm_info_svr4 with delete.
11214 (svr4_copy_library_list): Replace memcpy with call to copy
11216 (library_list_start_library, svr4_default_sos): Allocate
11217 lm_info_svr4 with new.
11219 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11221 * solib-target.c (struct lm_info_target): Add destructor,
11223 <name>: Change type to std::string.
11224 (library_list_start_library): Allocate lm_info_target with new.
11225 (solib_target_free_library_list): Free lm_info_target with
11227 (solib_target_current_sos): Adapt to std::string.
11228 (solib_target_free_so): Free lm_info_target with delete.
11230 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11232 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
11234 (frv_current_sos): Allocate lm_info_frv with new.
11235 (frv_relocate_main_executable): Free lm_info_frv with delete,
11237 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
11239 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11241 * solib-frv.c (struct lm_info_frv): Fix indentation.
11243 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11245 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
11247 (dsbt_current_sos): Allocate lm_info_dsbt with new.
11248 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
11249 and allocate with new.
11250 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
11252 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11254 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
11255 <filename, member_name>: Change type to std::string.
11256 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
11257 (library_list_start_library): Allocate lm_info_aix with new.
11258 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
11259 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
11260 with copy constructor.
11262 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11264 * solist.h (struct lm_info): Remove.
11265 (struct lm_info_base): New class.
11266 (struct so_list) <lm_info>: Change type to lm_info_base *.
11267 * nto-tdep.c (struct lm_info): Remove.
11269 * solib-aix.c (struct lm_info): Rename to ...
11270 (struct lm_info_aix): ... this. Extend lm_info_base.
11271 (lm_info_p): Rename to ...
11272 (lm_info_aix_p): ... this, and adjust.
11273 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
11274 solib_aix_parse_libraries, library_list_start_library,
11275 solib_aix_free_library_list, solib_aix_parse_libraries,
11276 solib_aix_get_library_list,
11277 solib_aix_relocate_section_addresses, solib_aix_free_so,
11278 solib_aix_get_section_offsets,
11279 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
11281 (struct solib_aix_inferior_data) <library_list>: Adjust.
11282 * solib-darwin.c (struct lm_info): Rename to ...
11283 (struct lm_info_darwin): ... this. Extend lm_info_base.
11284 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
11285 * solib-dsbt.c (struct lm_info): Rename to ...
11286 (struct lm_info_dsbt): ... this. Extend lm_info_base.
11287 (struct dsbt_info) <main_executable_lm_info): Adjust.
11288 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
11289 dsbt_relocate_section_addresses): Adjust.
11290 * solib-frv.c (struct lm_info): Rename to ...
11291 (struct lm_info_frv): ... this. Extend lm_info_base.
11292 (main_executable_lm_info): Adjust.
11293 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
11294 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
11295 find_canonical_descriptor_in_load_object,
11296 frv_fdpic_find_canonical_descriptor): Adjust.
11297 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
11299 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
11300 svr4_clear_so, svr4_copy_library_list,
11301 library_list_start_library, svr4_default_sos, svr4_read_so_list,
11302 svr4_current_sos, svr4_fetch_objfile_link_map,
11303 solist_update_incremental): Adjust.
11304 * solib-svr4.h (struct lm_info_svr4): Move here from
11306 * solib-target.c (struct lm_info): Rename to ...
11307 (struct lm_info_target): ... this. Extend lm_info_base.
11308 (lm_info_p): Rename to ...
11309 (lm_info_target_p): ... this.
11310 (solib_target_parse_libraries, library_list_start_segment,
11311 library_list_start_section, library_list_start_library,
11312 library_list_end_library, solib_target_free_library_list,
11313 solib_target_current_sos, solib_target_free_so,
11314 solib_target_relocate_section_addresses): Adjust.
11315 * windows-nat.c (struct lm_info): Rename to ...
11316 (struct lm_info_windows): ... this. Extend lm_info_base.
11317 (windows_make_so, handle_load_dll, handle_unload_dll,
11318 windows_xfer_shared_libraries): Adjust.
11320 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
11322 * solib-darwin.c (struct darwin_so_list): Remove.
11323 (darwin_current_sos): Allocate an so_list object instead of a
11324 darwin_so_list, separately allocate an lm_info object.
11325 (darwin_free_so): Free lm_info.
11327 2017-04-28 John Baldwin <jhb@FreeBSD.org>
11329 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
11330 with fprintf_filtered.
11332 2017-04-28 Yao Qi <yao.qi@linaro.org>
11334 * regcache.c (regcache::regcache): New function.
11335 (regcache::~regcache): New function.
11336 (regcache_xmalloc_1): Remove.
11337 (regcache_xmalloc): Call new regcache.
11338 (regcache_xfree): Call delete regcache.
11339 (get_thread_arch_aspace_regcache): Call new regcache.
11341 2017-04-28 Yao Qi <yao.qi@linaro.org>
11343 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
11344 lwp instead of ptid_get_lwp.
11346 2017-04-28 Yao Qi <yao.qi@linaro.org>
11348 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
11349 lwp_info instead of getting from inferior_ptid.
11351 2017-04-27 Keith Seitz <keiths@redhat.com>
11353 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
11354 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
11355 (CV_CONVERSION_BADNESS): Define.
11356 (rank_one_type): Remove overly restrictive rvalue reference
11358 Add cv-qualifier checks and subranks for type equality.
11359 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
11360 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
11361 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
11363 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
11365 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
11366 count when creating the object.
11368 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
11369 Ulrich Weigand <uweigand@de.ibm.com>
11371 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
11372 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
11374 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
11375 (process_xcoff_symbol): Likewise.
11376 (scan_xcoff_symtab): Likewise.
11378 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11380 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
11381 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
11382 (ia64_access_reg): Use get_frame_register_unsigned.
11383 (ia64_access_rse_reg): Likewise.
11384 (ia64_libunwind_frame_prev_register): Likewise.
11386 2017-04-26 Jiong Wang <jiong.wang@arm.com>
11388 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
11389 * gdbarch.c: Regenerated.
11390 * gdbarch.h: Regenerated.
11391 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
11392 visibility external.
11393 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
11394 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
11395 (enum cfa_how_kind): Move to ...
11396 (struct dwarf2_frame_state_reg_info): Likewise.
11397 (struct dwarf2_frame_state): Likewise.
11398 * dwarf2-frame.h: ... here.
11399 (dwarf2_frame_state_alloc_regs): New declaration.
11400 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
11401 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
11403 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11405 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
11406 regcache_raw_read_unsigned.
11407 (xtensa_pseudo_register_write): Likewise.
11409 2017-04-26 Alan Hayward <alan.hayward@arm.com>
11411 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
11412 (nds32_pseudo_register_write): Likewise.
11414 2017-04-25 Yao Qi <yao.qi@linaro.org>
11416 * regcache.c (struct regcache) <readonly_p>: Change its type
11418 (regcache_xmalloc_1): Update parameter type and callers update.
11420 2017-04-25 Yao Qi <yao.qi@linaro.org>
11422 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
11423 set_gdbarch_wchar_bit.
11424 * arm-tdep.c (arm_gdbarch_init): Likewise.
11426 2017-04-25 Pedro Alves <palves@redhat.com>
11428 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
11429 (BothAreRelocatable, memcopy, memmove): Don't define.
11430 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
11433 2017-04-25 Pedro Alves <palves@redhat.com>
11435 * common/common-defs.h: Include "common/poison.h".
11436 * common/function-view.h: (Not, Or, Requires): Move to traits.h
11438 * common/poison.h: New file.
11439 * common/traits.h: Include <type_traits>.
11440 (Not, Or, Requires): New, moved from common/function-view.h.
11442 2017-04-25 Pedro Alves <palves@redhat.com>
11444 * breakpoint.h (struct breakpoint): In-class initialize all
11445 fields. Make boolean fields "bool".
11446 * breakpoint.c (init_raw_breakpoint_without_location): Remove
11447 memset call and initializations no longer necessary.
11449 2017-04-25 Pedro Alves <palves@redhat.com>
11451 * btrace.c (pt_btrace_insn_flags): Change parameter type to
11453 (pt_btrace_insn): New function.
11454 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
11456 2017-04-25 Pedro Alves <palves@redhat.com>
11458 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
11459 "base" field and inherit from "bp_location" instead. Add
11461 (allocate_location_exception): Use new non-default ctor.
11462 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
11463 (init_bp_location): Convert to ...
11464 (bp_location::bp_location): ... this new ctor, and remove memset
11466 (base_breakpoint_allocate_location): Use the new non-default ctor.
11467 * breakpoint.h (bp_location): Now a class. Declare default and
11468 non-default ctors. In-class initialize all members.
11469 (init_bp_location): Remove declaration.
11471 2017-04-25 Pedro Alves <palves@redhat.com>
11473 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
11474 assignment operator.
11476 2017-04-24 Yao Qi <yao.qi@linaro.org>
11478 * doublest.c (convert_doublest_to_floatformat): Call
11479 floatformat_totalsize_bytes.
11481 2017-04-22 Tom Tromey <tom@tromey.com>
11483 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
11485 * stack.c (print_frame): Use ui_out_emit_list.
11486 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11488 * mi/mi-main.c (print_one_inferior)
11489 (mi_cmd_data_list_register_names)
11490 (mi_cmd_data_list_register_values, mi_cmd_list_features)
11491 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
11493 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
11494 (mi_output_solib_attribs): Use ui_out_emit_list,
11496 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
11497 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
11498 (mi_cmd_stack_list_args, list_args_or_locals): Use
11500 * disasm.c (do_assembly_only): Use ui_out_emit_list.
11501 * breakpoint.c (print_solib_event, output_thread_groups): Use
11504 2017-04-22 Tom Tromey <tom@tromey.com>
11506 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
11507 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
11508 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
11510 2017-04-22 Tom Tromey <tom@tromey.com>
11512 * tracepoint.c (tvariables_info_1)
11513 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
11515 2017-04-22 Tom Tromey <tom@tromey.com>
11517 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
11518 annotate_arg_emitter.
11519 * breakpoint.c (print_mention_watchpoint)
11520 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
11521 * annotate.h (struct annotate_arg_emitter): New.
11523 2017-04-22 Tom Tromey <tom@tromey.com>
11525 * record-btrace.c (record_btrace_insn_history)
11526 (record_btrace_insn_history_range, record_btrace_call_history)
11527 (record_btrace_call_history_range): Use ui_out_emit_tuple.
11528 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
11530 * stack.c (print_frame_info): Use ui_out_emit_tuple.
11531 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
11532 * skip.c (skip_info): Use ui_out_emit_tuple.
11533 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
11534 * progspace.c (print_program_space): Use ui_out_emit_tuple.
11535 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
11536 * osdata.c (info_osdata): Use ui_out_emit_tuple.
11537 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11539 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
11540 (output_register, mi_cmd_data_read_memory)
11541 (mi_cmd_data_read_memory_bytes, mi_load_progress)
11542 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
11543 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
11544 Use ui_out_emit_tuple.
11545 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
11547 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11548 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
11549 * linux-thread-db.c (info_auto_load_libthread_db): Use
11551 * inferior.c (print_inferior): Use ui_out_emit_tuple.
11552 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
11553 * disasm.c (do_mixed_source_and_assembly_deprecated)
11554 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
11555 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
11556 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
11557 * breakpoint.c (print_one_breakpoint_location)
11558 (print_one_breakpoint): Use ui_out_emit_tuple.
11559 * auto-load.c (print_script, info_auto_load_cmd): Use
11561 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
11563 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
11565 * thread.c (print_thread_info_1): Remove dead code.
11567 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11569 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
11571 * arm-tdep.c (selftests::arm_record_test): Likewise.
11573 2017-04-21 Yao Qi <yao.qi@linaro.org>
11575 * regcache.c (regcache_restore): Remove argument 2. Replace
11576 argument 3 with regcache. Get register status from
11577 src->register_status and get register contents from
11578 register_buffer (src, regnum).
11579 (regcache_cpy): Update.
11581 2017-04-19 Pedro Alves <palves@redhat.com>
11583 * gdbthread.h (thread): Add missing closing parenthesis in
11586 2017-04-19 Pedro Alves <palves@redhat.com>
11588 * common/refcounted-object.h: New file.
11589 * gdbthread.h: Include "common/refcounted-object.h".
11590 (thread_info): Inherit from refcounted_object and add comments.
11591 (thread_info::incref, thread_info::decref)
11592 (thread_info::m_refcount): Delete.
11593 (thread_info::deletable): Use the refcounted_object::refcount()
11595 * inferior.c (current_inferior_): Add comment.
11596 (set_current_inferior): Increment/decrement refcounts.
11597 (prune_inferiors, remove_inferior_command): Skip inferiors marked
11598 not-deletable instead of comparing with the current inferior.
11599 (initialize_inferiors): Increment the initial inferior's refcount.
11600 * inferior.h (struct inferior): Forward declare.
11601 Include "common/refcounted-object.h".
11602 (current_inferior, set_current_inferior): Move declaration to
11603 before struct inferior's definition, and fix comment.
11604 (inferior): Inherit from refcounted_object. Add comments.
11605 * thread.c (switch_to_thread_no_regs): Reference the thread's
11606 inferior pointer directly instead of doing a ptid lookup.
11607 (switch_to_no_thread): New function.
11608 (switch_to_thread(thread_info *)): New function, factored out
11610 (switch_to_thread(ptid_t)): ... this.
11611 (restore_current_thread): Delete.
11612 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
11613 fields, and add 'inf' field.
11614 (do_restore_current_thread_cleanup): Check whether old->inf is
11615 alive instead of looking up an inferior by ptid. Use
11616 switch_to_thread and switch_to_no_thread.
11617 (restore_current_thread_cleanup_dtor): Use old->inf directly
11618 instead of lookup up an inferior by id. Decref the inferior.
11619 Don't restore 'removable'.
11620 (make_cleanup_restore_current_thread): Same the inferior pointer
11621 in old, instead of the inferior number. Incref the inferior.
11622 Don't save/clear 'removable'.
11624 2017-04-19 Pedro Alves <palves@redhat.com>
11626 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11627 unittests/scoped_restore-selftests.c.
11628 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
11629 * common/scoped_restore.h (scoped_restore_base): Make "class".
11630 (scoped_restore_base::release): New public method.
11631 (scoped_restore_base::scoped_restore_base): New protected ctor.
11632 (scoped_restore_base::m_saved_var): New protected field.
11633 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
11634 scoped_restore_base base class instead of m_saved_var directly.
11635 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
11636 (scoped_restore_tmpl::scoped_restore_tmpl(const
11637 scoped_restore_tmpl<T>&)): Likewise.
11638 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
11640 (scoped_restore_tmpl::saved_var): New method.
11641 (scoped_restore_tmpl::m_saved_var): Delete.
11642 * inferior.h (inferior::detaching): Now a bool.
11643 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
11645 * unittests/scoped_restore-selftests.c: New file.
11647 2017-04-19 Pedro Alves <palves@redhat.com>
11649 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
11650 Re-sort in alphabetic order.
11652 2017-04-18 Pedro Alves <palves@redhat.com>
11654 * xml-support.c (obstack_xml_printf): Delete.
11655 * xml-support.h (obstack_xml_printf): Delete.
11657 2017-04-18 Pedro Alves <palves@redhat.com>
11659 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
11660 vdebug, verror, body_text, start_element, end_element, name,
11661 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
11662 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
11663 is_xinclude>: Make private and add m_ prefix.
11664 (gdb_xml_parser::body_text): New method, based on ...
11665 (gdb_xml_body_text): ... this. Adjust.
11666 (gdb_xml_parser::vdebug): New method, based on ...
11667 (gdb_xml_debug): ... this. Adjust.
11668 (gdb_xml_parser::verror): New method, based on ...
11669 (gdb_xml_error): ... this. Adjust.
11670 (gdb_xml_parser::start_element): New method, based on ...
11671 (gdb_xml_start_element): ... this. Adjust.
11672 (gdb_xml_start_element_wrapper): Defer to
11673 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
11674 (gdb_xml_parser::end_element): New method, based on ...
11675 (gdb_xml_end_element_wrapper): ... this. Adjust.
11676 (gdb_xml_parser::~gdb_xml_parser): Adjust.
11677 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
11678 (gdb_xml_parser::use_dtd): New method, based on ...
11679 (gdb_xml_use_dtd): ... this. Adjust.
11680 (gdb_xml_parser::parse): New method, based on ...
11681 (gdb_xml_parse): ... this. Adjust.
11682 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
11683 (xinclude_start_include): Adjust to call the parser's name method.
11684 (xml_xinclude_default, xml_xinclude_start_doctype)
11685 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
11687 (xml_process_xincludes): Adjust to call parser methods.
11688 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
11691 2017-04-18 Pedro Alves <palves@redhat.com>
11693 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
11694 gdb::optional<std::string>.
11695 * xml-support.c: Include <string>.
11696 (scope_level::scope_level(scope_level &&))
11697 (scope_level::~scope_level): Delete.
11698 (scope_level::body): Now a std::string.
11699 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
11700 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
11702 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
11703 (xinclude_parsing_data::output): Now a std::string reference.
11704 (xinclude_start_include): Adjust.
11705 (xml_xinclude_default): Adjust.
11706 (xml_process_xincludes): Add 'output' parameter, and return bool.
11707 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
11709 * xml-tdesc.c: Include <unordered_map> and <string>.
11710 (tdesc_xml_cache): Delete.
11711 (tdesc_xml_cache_s): Delete.
11712 (xml_cache): Now an std::unordered_map.
11713 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
11714 (target_fetch_description_xml): Change return type to
11715 gdb::optional<std::string>, and adjust.
11716 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
11717 (target_fetch_description_xml): Change return type to
11718 gdb::optional<std::string>.
11720 2017-04-18 Pedro Alves <palves@redhat.com>
11722 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11723 unittests/optional-selftests.c.
11724 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
11725 * unittests/optional-selftests.c: New file.
11726 * unittests/optional/assignment/1.cc: New file.
11727 * unittests/optional/assignment/2.cc: New file.
11728 * unittests/optional/assignment/3.cc: New file.
11729 * unittests/optional/assignment/4.cc: New file.
11730 * unittests/optional/assignment/5.cc: New file.
11731 * unittests/optional/assignment/6.cc: New file.
11732 * unittests/optional/assignment/7.cc: New file.
11733 * unittests/optional/cons/copy.cc: New file.
11734 * unittests/optional/cons/default.cc: New file.
11735 * unittests/optional/cons/move.cc: New file.
11736 * unittests/optional/cons/value.cc: New file.
11737 * unittests/optional/in_place.cc: New file.
11738 * unittests/optional/observers/1.cc: New file.
11739 * unittests/optional/observers/2.cc: New file.
11741 2017-04-18 Pedro Alves <palves@redhat.com>
11743 * common/gdb_optional.h: Include common/traits.h.
11744 (in_place_t): New type.
11745 (in_place): New constexpr variable.
11746 (optional::optional): Remove member initialization of
11748 (optional::optional(in_place_t...)): New constructor.
11749 (optional::~optional): Use reset.
11750 (optional::optional(const optional&)): New.
11751 (optional::optional(const optional&&)): New.
11752 (optional::optional(T &)): New.
11753 (optional::optional(T &&)): New.
11754 (operator::operator=(const optional &)): New.
11755 (operator::operator=(optional &&)): New.
11756 (operator::operator= (const T &))
11757 (operator::operator= (T &&))
11758 (operator::emplace (Args &&... args)): Return a T&. Use reset.
11759 (operator::reset): New.
11760 (operator::m_instantiated):: Add in-class initializer.
11761 * common/traits.h: Include <type_traits>.
11762 (struct And): New types.
11764 2017-04-18 Pedro Alves <palves@redhat.com>
11766 * xml-support.c: Include <vector>.
11767 (scope_level::scope_level(const gdb_xml_element *))
11768 (scope_level::scope_level(scope_level&&)): New.
11769 (scope_level::~scope_level): New.
11770 (scope_level_s): Delete.
11771 (gdb_xml_parser::scopes): Now a std::vector.
11772 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
11774 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
11775 scope cleanup code.
11776 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
11777 of the scopes member. Use std::vector::emplace_back.
11779 2017-04-18 Pedro Alves <palves@redhat.com>
11781 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
11783 (gdb_xml_end_element): Change type of first parameter.
11784 (gdb_xml_cleanup): Rename to ...
11785 (gdb_xml_parser::~gdb_xml_parser): ... this.
11786 (gdb_xml_create_parser_and_cleanup): Delete with ...
11787 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
11789 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
11790 using gdb_xml_create_parser_and_cleanup.
11791 (xinclude_parsing_data): Add ctor/dtor.
11792 (xml_xinclude_cleanup): Delete.
11793 (xml_process_xincludes): Create a local xinclude_parsing_data
11794 instead of heap-allocating one. Create a local gdb_xml_parser
11795 instead of heap-allocating one with
11796 gdb_xml_create_parser_and_cleanup.
11798 2017-04-18 John Baldwin <jhb@FreeBSD.org>
11801 * fbsd-nat.c (resume_one_thread_cb): Remove.
11802 (resume_all_threads_cb): Remove.
11803 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
11804 iterate_over_threads.
11806 2017-04-17 Joel Brobecker <brobecker@adacore.com>
11808 * NEWS: Create a new section for the next release branch.
11809 Rename the section of the current branch, now that it has
11812 2017-04-17 Joel Brobecker <brobecker@adacore.com>
11814 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
11815 * version.in: Bump version to 8.0.50.DATE-git.
11817 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
11820 * windows-nat.c (windows_create_inferior): Declare 'allargs'
11821 independently of the host, and fix build breakage on Cygwin.
11823 2017-04-13 Pedro Alves <palves@redhat.com>
11825 * inferior.c (free_inferior): Convert to ...
11826 (inferior::~inferior): ... this dtor.
11827 (inferior::inferior): New ctor, factored out from ...
11828 (add_inferior_silent): ... here. Allocate the inferior with a new
11830 (delete_inferior): Call delete instead of free_inferior.
11831 * inferior.h (gdb_environ, continuation): Forward declare.
11832 (inferior): Now a class. Add in-class initialization to all
11833 members. Make boolean fields bool, except 'detaching'.
11834 (inferior::inferior): New explicit ctor.
11835 (inferior::~inferior): New.
11837 2017-04-13 Pedro Alves <palves@redhat.com>
11839 * inferior.c (init_inferior_list): Delete.
11840 * inferior.h (init_inferior_list): Delete.
11842 2017-04-13 Pedro Alves <palves@redhat.com>
11845 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
11846 (top level): Call it twice, with different thread sets.
11848 2017-04-13 Pedro Alves <palves@redhat.com>
11850 * thread.c: Include <algorithm>.
11851 (thread_array_cleanup): Delete.
11852 (scoped_inc_dec_ref): New class.
11853 (live_threads_count): New function.
11854 (set_thread_refcount): Delete.
11855 (tp_array_compar_ascending): Now a bool.
11856 (tp_array_compar): Convert to a std::sort comparison function.
11857 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
11858 and live_threads_count.
11860 2017-04-13 Pedro Alves <palves@redhat.com>
11862 * infrun.c (follow_fork_inferior): Also switch the current
11865 2017-04-13 Pedro Alves <palves@redhat.com>
11867 * breakpoint.c (watch_command_1): Save watchpoint-frame info
11868 before calling create_internal_breakpoint.
11870 2017-04-13 Pedro Alves <palves@redhat.com>
11872 * fork-child.c (execv_argv): New class.
11873 (breakup_args): Refactored as ...
11874 (execv_argv::init_for_no_shell): .. this method of execv_argv.
11875 Copy arguments to storage and replace separators with NULL
11876 terminators in place.
11877 (escape_bang_in_quoted_argument): Adjust to return bool.
11878 (execv_argv::execv_argv): New ctor.
11879 (execv_argv::init_for_shell): New method, factored out from
11880 fork_inferior. Don't strdup strings into the vector.
11881 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
11882 Remove free_vector_argv call.
11884 2017-04-13 Yao Qi <yao.qi@linaro.org>
11886 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
11889 2017-04-13 Yao Qi <yao.qi@linaro.org>
11891 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
11892 * rx-tdep.c (rx_gdbarch_init): Likewise.
11894 2017-04-13 Pedro Alves <palves@redhat.com>
11896 * breakpoint.h (struct breakpoint): Reindent.
11898 2017-04-13 Pedro Alves <palves@redhat.com>
11900 * breakpoint.c (bp_location): Rename to ...
11901 (bp_locations): ... this. All references updated.
11902 (bp_location_count): Rename to ...
11903 (bp_locations_count): ... this. All references updated.
11904 (bp_location_placed_address_before_address_max): Rename to ...
11905 (bp_locations_placed_address_before_address_max): ... this. All
11906 references updated.
11907 (bp_location_shadow_len_after_address_max): Rename to ...
11908 (bp_locations_shadow_len_after_address_max): ... this. All
11909 references updated.
11910 (bp_location_compare_addrs): Rename to ...
11911 (bp_locations_compare_addrs): ... this. All references updated.
11912 (bp_location_compare):Rename to ...
11913 (bp_locations_compare): ... this. All references updated.
11914 (bp_location_target_extensions_update): Rename to ...
11915 (bp_locations_target_extensions_update): ... this. All references
11918 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11920 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
11921 * common/common.m4: Check headers 'termios.h', 'termio.h' and
11923 * common/gdb_termios.h: New file, with parts of "terminal.h".
11924 * inflow.c: Include "gdb_termios.h".
11925 * ser-unix.c: Include "gdb_termios.h".
11926 * terminal.h: Move terminal-related defines to
11927 "common/gdb_termios.h".
11929 2017-04-12 Tom Tromey <tom@tromey.com>
11931 * probe.c (parse_probes): Update.
11932 * location.h (delete_event_location): Don't declare.
11933 (event_location_deleter::operator()): Update.
11934 * location.c (event_location_deleter::operator()): Rename from
11935 delete_event_location.
11936 * linespec.h (linespec_result) <location>: Change type to
11938 * linespec.c (canonicalize_linespec, event_location_to_sals)
11939 (decode_objc): Update.
11940 (linespec_result): Don't call delete_event_location.
11941 * breakpoint.c (create_breakpoints_sal)
11942 (bkpt_probe_create_sals_from_location)
11943 (strace_marker_create_sals_from_location): Update.
11945 2017-04-12 Tom Tromey <tom@tromey.com>
11947 * linespec.h (struct linespec_result): Add constructor and
11949 (init_linespec_result, destroy_linespec_result)
11950 (make_cleanup_destroy_linespec_result): Don't declare.
11951 * linespec.c (init_linespec_result): Remove.
11952 (linespec_result::~linespec_result): Rename from
11953 destroy_linespec_result. Update.
11954 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
11956 * breakpoint.c (create_breakpoint, break_range_command)
11957 (decode_location_default): Update.
11958 * ax-gdb.c (agent_command_1): Update.
11960 2017-04-12 Tom Tromey <tom@tromey.com>
11962 * remote.c (remote_download_tracepoint): Update.
11963 * python/py-breakpoint.c (bppy_get_location): Update.
11964 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
11965 (gdbscm_breakpoint_location): Update.
11966 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
11967 * breakpoint.h (struct breakpoint) <location, location_range_end>:
11968 Change type to event_location_up.
11969 * breakpoint.c (create_overlay_event_breakpoint)
11970 (create_longjmp_master_breakpoint)
11971 (create_std_terminate_master_breakpoint)
11972 (create_exception_master_breakpoint)
11973 (breakpoint_event_location_empty_p, print_breakpoint_location)
11974 (print_one_breakpoint_location, create_thread_event_breakpoint)
11975 (init_breakpoint_sal, create_breakpoint)
11976 (print_recreate_ranged_breakpoint, break_range_command)
11977 (init_ada_exception_breakpoint, say_where): Update.
11978 (base_breakpoint_dtor): Don't call delete_event_location.
11979 (bkpt_print_recreate, tracepoint_print_recreate)
11980 (dprintf_print_recreate, update_static_tracepoint)
11981 (breakpoint_re_set_default): Update.
11983 2017-04-12 Tom Tromey <tom@tromey.com>
11985 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
11986 type of "to_do". Update.
11987 (compute_stack_depth): Use std::vector.
11989 2017-04-12 Tom Tromey <tom@tromey.com>
11991 * printcmd.c (find_instruction_backward): Use std::vector.
11993 2017-04-12 Tom Tromey <tom@tromey.com>
11995 * symfile.c (objfilep): Remove typedef.
11996 (reread_symbols): Use a std::vector.
11998 2017-04-12 Tom Tromey <tom@tromey.com>
12000 * mi/mi-main.c (exec_direction_forward): Remove.
12001 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
12002 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
12004 * guile/guile.c (guile_repl_command, guile_command)
12005 (gdbscm_execute_gdb_command): Use scoped_restore.
12006 * go-exp.y (go_parse): Use scoped_restore.
12007 * d-exp.y (d_parse): Use scoped_restore.
12008 * cli/cli-decode.c (cmd_func): Use scoped_restore.
12009 * c-exp.y (c_parse): Use scoped_restore.
12011 2017-04-12 Tom Tromey <tom@tromey.com>
12013 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
12014 (mi_parse): Update return type.
12015 (mi_parse_free): Remove.
12016 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
12017 (mi_parse::~mi_parse): Rename from mi_parse_free.
12018 (mi_parse_cleanup): Remove.
12019 (mi_parse): Return a unique_ptr. Use new.
12020 * mi/mi-main.c (mi_execute_command): Update.
12022 2017-04-12 Tom Tromey <tom@tromey.com>
12024 * location.c (explicit_location_lex_one): Return a
12025 unique_xmalloc_ptr.
12026 (string_to_explicit_location): Update. Remove cleanups.
12028 2017-04-12 Tom Tromey <tom@tromey.com>
12030 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
12031 (compare_value_and_voffset): Change type. Update.
12032 (compute_vtable_size): Change type of "offset_vec".
12033 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
12034 (gnuv3_get_typeid): Remove extraneous declaration.
12036 2017-04-12 Tom Tromey <tom@tromey.com>
12038 * charset.h (wchar_iterator): Fix comment.
12040 2017-04-12 Tom Tromey <tom@tromey.com>
12042 * charset.c (iconv_wrapper): New class.
12043 (cleanup_iconv): Remove.
12044 (convert_between_encodings): Use it.
12046 2017-04-12 Tom Tromey <tom@tromey.com>
12048 * symfile.h (increment_reading_symtab): Update type.
12049 * symfile.c (decrement_reading_symtab): Remove.
12050 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
12051 * psymtab.c (psymtab_to_symtab): Update.
12052 * dwarf2read.c (dw2_instantiate_symtab): Update.
12054 2017-04-12 Tom Tromey <tom@tromey.com>
12056 * jit.c (struct jit_reader): Declare separately. Add constructor
12057 and destructor. Change type of "handle".
12058 (loaded_jit_reader): Define separately.
12059 (jit_reader_load): Update. New "new".
12060 (jit_reader_unload_command): Use "delete".
12061 * gdb-dlfcn.h (struct dlclose_deleter): New.
12062 (gdb_dlhandle_up): New typedef.
12063 (gdb_dlopen, gdb_dlsym): Update types.
12064 (gdb_dlclose): Remove.
12065 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
12066 (gdb_dlsym): Change type of "handle".
12067 (make_cleanup_dlclose): Remove.
12068 (dlclose_deleter::operator()): Rename from gdb_dlclose.
12069 * compile/compile-c-support.c (load_libcc): Update.
12071 2017-04-12 Tom Tromey <tom@tromey.com>
12073 * symtab.h (find_pcs_for_symtab_line): Change return type.
12074 * symtab.c (find_pcs_for_symtab_line): Change return type.
12075 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
12076 type of "vec". Update.
12077 (ltpy_get_pcs_for_line): Update.
12078 * linespec.c (decode_digits_ordinary): Update.
12080 2017-04-12 Tom Tromey <tom@tromey.com>
12082 * tracepoint.c (actions_command): Update.
12083 * python/python.c (python_command, python_interactive_command):
12085 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
12086 * guile/guile.c (guile_command): Update.
12087 * defs.h (read_command_lines, read_command_lines_1): Return
12089 (command_lines_deleter): New struct.
12090 (command_line_up): New typedef.
12091 * compile/compile.c (compile_code_command)
12092 (compile_print_command): Update.
12093 * cli/cli-script.h (get_command_line, copy_command_lines): Return
12095 (make_cleanup_free_command_lines): Remove.
12096 * cli/cli-script.c (get_command_line, read_command_lines_1)
12097 (copy_command_lines): Return command_line_up.
12098 (while_command, if_command, read_command_lines, define_command)
12099 (document_command): Update.
12100 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
12102 * breakpoint.h (breakpoint_set_commands): Change type of
12104 * breakpoint.c (breakpoint_set_commands): Change type of
12105 "commands". Update.
12106 (do_map_commands_command, update_dprintf_command_list)
12107 (create_tracepoint_from_upload): Update.
12109 2017-04-12 Tom Tromey <tom@tromey.com>
12111 * tracepoint.c (scope_info): Update.
12112 * spu-tdep.c (spu_catch_start): Update.
12113 * python/python.c (gdbpy_decode_line): Update.
12114 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
12115 * python/py-breakpoint.c (bppy_init): Update.
12116 * probe.c (parse_probes): Update.
12117 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
12118 * location.h (event_location_deleter): New struct.
12119 (event_location_up): New typedef.
12120 (new_linespec_location, new_address_location, new_probe_location)
12121 (new_explicit_location, copy_event_location)
12122 (string_to_event_location, string_to_event_location_basic)
12123 (string_to_explicit_location): Update return type.
12124 (make_cleanup_delete_event_location): Remove.
12125 * location.c (new_linespec_location, new_address_location)
12126 (new_probe_location, new_explicit_location, copy_event_location):
12127 Return event_location_up.
12128 (delete_event_location_cleanup)
12129 (make_cleanup_delete_event_location): Remove.
12130 (string_to_explicit_location, string_to_event_location_basic)
12131 (string_to_event_location): Return event_location_up.
12132 * linespec.c (canonicalize_linespec, event_location_to_sals)
12133 (decode_line_with_current_source)
12134 (decode_line_with_last_displayed, decode_objc): Update.
12135 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
12136 * completer.c (location_completer): Update.
12137 * cli/cli-cmds.c (edit_command, list_command): Update.
12138 * breakpoint.c (create_overlay_event_breakpoint)
12139 (create_longjmp_master_breakpoint)
12140 (create_std_terminate_master_breakpoint)
12141 (create_exception_master_breakpoint)
12142 (create_thread_event_breakpoint): Update.
12143 (init_breakpoint_sal): Update. Remove some dead code.
12144 (create_breakpoint_sal): Change type of "location". Update.
12145 (create_breakpoints_sal, create_breakpoint, break_command_1)
12146 (dprintf_command, break_range_command, until_break_command)
12147 (init_ada_exception_breakpoint)
12148 (strace_marker_create_sals_from_location)
12149 (update_static_tracepoint, trace_command, ftrace_command)
12150 (strace_command, create_tracepoint_from_upload): Update.
12151 * break-catch-throw.c (re_set_exception_catchpoint): Update.
12152 * ax-gdb.c (agent_command_1): Update.
12154 2017-04-12 Pedro Alves <palves@redhat.com>
12156 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
12157 * configure.tgt: Handle i[34567]86-*-go32* and
12158 i[34567]86-*-msdosdjgpp*.
12159 * i386-tdep.c (i386_svr4_reg_to_regnum):
12161 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
12163 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
12164 * i386-go32-tdep.c: New file.
12165 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
12168 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
12170 * aix-thread.c (pd_status2str): Change return type to const char *.
12172 2017-04-12 Pedro Alves <palves@redhat.com>
12174 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
12175 calls to set_gdbarch_gnu_triplet_regexp.
12177 2017-04-12 Pedro Alves <palves@redhat.com>
12180 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
12182 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
12183 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
12184 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
12185 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
12186 * gdbarch.h, gdbarch.c: Regenerate.
12187 * aarch64-tdep.c (aarch64_gdbarch_init): Override
12188 gdbarch_wchar_bit and gdbarch_wchar_signed.
12189 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
12190 * arm-tdep.c (arm_gdbarch_init): Likewise.
12191 * avr-tdep.c (avr_gdbarch_init): Likewise.
12192 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
12193 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
12194 * i386-tdep.c (i386_go32_init_abi): Likewise.
12195 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
12196 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
12197 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
12198 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
12199 * sh-tdep.c (sh_gdbarch_init): Likewise.
12200 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
12201 * sparc64-tdep.c (sparc64_init_abi): Likewise.
12202 * windows-tdep.c (windows_init_abi): Likewise.
12203 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
12205 2017-04-12 Pedro Alves <palves@redhat.com>
12208 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
12209 cplus_primitive_type_char32_t>: New enum values.
12210 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
12211 and cplus_primitive_type_char32_t.
12212 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
12213 32, use the archtecture's built-in type for char16_t and char32_t,
12214 respectively. Otherwise, fallback to init_integer_type as before,
12215 but make the type unsigned, and issue a complaint.
12216 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
12218 2017-04-12 Alan Hayward <alan.hayward@arm.com>
12220 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
12221 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
12223 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12225 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
12228 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
12230 * common/common-utils.c (free_vector_argv): New function.
12231 * common/common-utils.h: Include <vector>.
12232 (free_vector_argv): New prototype.
12233 * darwin-nat.c (darwin_create_inferior): Rewrite function
12234 prototype in order to constify "exec_file" and accept a
12235 "std::string" for "allargs".
12236 * fork-child.c: Include <vector>.
12237 (breakup_args): Rewrite function, using C++.
12238 (fork_inferior): Rewrite function header, constify "exec_file_arg"
12239 and accept "std::string" for "allargs". Update the code to
12240 calculate "argv" based on "allargs". Update calls to "exec_fun"
12242 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
12243 order to constify "exec_file" and accept a "std::string" for
12245 * go32-nat.c (go32_create_inferior): Likewise.
12246 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
12247 * infcmd.c (run_command_1): Constify "exec_file". Use
12248 "std::string" for inferior arguments.
12249 * inferior.h (fork_inferior): Update prototype.
12250 * linux-nat.c (linux_nat_create_inferior): Rewrite function
12251 prototype in order to constify "exec_file" and accept a
12252 "std::string" for "allargs".
12253 * nto-procfs.c (procfs_create_inferior): Likewise.
12254 * procfs.c (procfs_create_inferior): Likewise.
12255 * remote-sim.c (gdbsim_create_inferior): Likewise.
12256 * remote.c (extended_remote_run): Update code to accept
12257 "std::string" as argument.
12258 (extended_remote_create_inferior): Rewrite function prototype in
12259 order to constify "exec_file" and accept a "std::string" for
12261 * rs6000-nat.c (super_create_inferior): Likewise.
12262 (rs6000_create_inferior): Likewise.
12263 * target.h (struct target_ops) <to_create_inferior>: Likewise.
12264 * windows-nat.c (windows_create_inferior): Likewise.
12266 2017-04-11 Pedro Alves <palves@redhat.com>
12268 * thread.c: Fix whitespace throughout.
12270 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
12272 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
12274 2017-04-11 Alan Hayward <alan.hayward@arm.com>
12276 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
12278 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
12281 * osdata.c (info_osdata): Check if 'type' is an empty string
12284 2017-04-10 Pedro Alves <palves@redhat.com>
12286 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
12287 (ptid_to_global_thread_id, in_thread_list)
12288 (do_captured_list_thread_ids, set_resumed, set_running)
12289 (set_executing, set_stop_requested, finish_thread_state)
12290 (validate_registers_access, can_access_registers_ptid)
12291 (print_thread_info_1, switch_to_thread)
12292 (do_restore_current_thread_cleanup)
12293 (make_cleanup_restore_current_thread, thread_command)
12294 (thread_name_command): Use operator== instead of ptid_equal.
12296 2017-04-10 Pedro Alves <palves@redhat.com>
12298 * thread.c (struct current_thread_cleanup) <next>: Delete field.
12299 (current_thread_cleanup_chain): Delete.
12300 (restore_current_thread_cleanup_dtor)
12301 (make_cleanup_restore_current_thread): Remove references to
12302 current_thread_cleanup_chain.
12304 2017-04-10 Alan Hayward <alan.hayward@arm.com>
12306 * msp430-tdep.c (msp430_pseudo_register_read): Never return
12309 2017-04-10 Yao Qi <yao.qi@linaro.org>
12312 * gdbthread.h (thread_info::deletable): New method.
12313 (thread_info::incref): New method.
12314 (thread_info::decref): New method.
12315 (thread_info::refcount): Move it to private.
12316 * infrun.c (save_stop_context): Call inc_refcount.
12317 (release_stop_context_cleanup): Likewise.
12318 * thread.c (set_thread_exited): New function.
12319 (init_thread_list): Delete "tp" only it is deletable, otherwise
12320 call set_thread_exited.
12321 (delete_thread_1): Call set_thread_exited.
12322 (current_thread_cleanup) <inferior_pid>: Remove.
12323 <thread>: New field.
12324 (restore_current_thread_ptid_changed): Removed.
12325 (do_restore_current_thread_cleanup): Adjust.
12326 (restore_current_thread_cleanup_dtor): Don't call
12328 (set_thread_refcount): Use dec_refcount.
12329 (make_cleanup_restore_current_thread): Adjust.
12330 (thread_apply_all_command): Call inc_refcount.
12331 (_initialize_thread): Don't call
12332 observer_attach_thread_ptid_changed.
12334 2017-04-10 Yao Qi <yao.qi@linaro.org>
12336 * thread.c (delete_thread_1): Hoist code on marking thread as
12339 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
12341 * windows-nat.c (windows_detach): Initialize ptid with
12344 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
12346 * unittests/ptid-selftests.c: Fix erroneous assert messages.
12348 2017-04-07 Alan Hayward <alan.hayward@arm.com>
12350 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
12351 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
12352 (bfin_pseudo_register_write): Likewise
12354 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
12356 * common/ptid.h (struct ptid): Change to...
12357 (class ptid_t): ... this.
12358 <ptid_t>: New constructors.
12359 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
12360 matches>: New methods.
12361 <make_null, make_minus_one>: New static methods.
12362 <pid>: Rename to...
12364 <lwp>: Rename to...
12366 <tid>: Rename to...
12368 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
12369 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
12370 as references, move comment to class ptid_t.
12371 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
12372 ptid_t static methods.
12373 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
12374 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
12375 Take ptid arguments as references, implement using ptid_t methods.
12376 * unittests/ptid-selftests.c: New file.
12377 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12378 unittests/ptid-selftests.c.
12379 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
12381 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
12383 * python/python.c (python_run_simple_file): Cast mode literal to
12384 non-const char pointer as expected by PyFile_FromString.
12386 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
12388 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
12389 minus_one_ptid and null_ptid.
12391 2017-04-05 Pedro Alves <palves@redhat.com>
12393 * warning.m4 (build_warnings): Remove -Wno-write-strings.
12394 * configure: Regenerate.
12396 2017-04-05 Pedro Alves <palves@redhat.com>
12398 * ada-exp.y (yyerror): Constify.
12399 * ada-lang.c (bound_name, get_selections)
12400 (ada_variant_discrim_type)
12401 (ada_variant_discrim_name, ada_value_struct_elt)
12402 (ada_lookup_struct_elt_type, is_unchecked_variant)
12403 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
12404 (catch_ada_exception_command_split)
12405 (catch_ada_assert_command_split, catch_assert_command)
12406 (ada_op_name): Constify.
12407 * ada-lang.h (ada_yyerror, get_selections)
12408 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
12409 * arc-tdep.c (arc_print_frame_cache): Constify.
12410 * arm-tdep.c (arm_skip_stub): Constify.
12411 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
12412 (gen_aggregate_elt_ref): Constify.
12413 * bcache.c (print_bcache_statistics): Constify.
12414 * bcache.h (print_bcache_statistics): Constify.
12415 * break-catch-throw.c (catch_exception_command_1):
12416 * breakpoint.c (struct ep_type_description::description):
12418 (add_solib_catchpoint): Constify.
12419 (catch_fork_command_1): Add cast.
12420 (add_catch_command): Constify.
12421 * breakpoint.h (add_catch_command, add_solib_catchpoint):
12423 * bsd-uthread.c (bsd_uthread_state): Constify.
12424 * buildsym.c (patch_subfile_names): Constify.
12425 * buildsym.h (next_symbol_text_func, patch_subfile_names):
12427 * c-exp.y (yyerror): Constify.
12428 (token::oper): Constify.
12429 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
12430 * c-varobj.c (cplus_describe_child): Constify.
12431 * charset.c (find_charset_names): Add cast.
12432 (find_charset_names): Constify array and add const_cast.
12433 * cli/cli-cmds.c (complete_command, cd_command): Constify.
12434 (edit_command): Constify.
12435 * cli/cli-decode.c (lookup_cmd): Constify.
12436 * cli/cli-dump.c (dump_memory_command, dump_value_command):
12438 (struct dump_context): Constify.
12439 (add_dump_command, restore_command): Constify.
12440 * cli/cli-script.c (get_command_line): Constify.
12441 * cli/cli-script.h (get_command_line): Constify.
12442 * cli/cli-utils.c (check_for_argument): Constify.
12443 * cli/cli-utils.h (check_for_argument): Constify.
12444 * coff-pe-read.c (struct read_pe_section_data): Constify.
12445 * command.h (lookup_cmd): Constify.
12446 * common/print-utils.c (decimal2str): Constify.
12447 * completer.c (gdb_print_filename): Constify.
12448 * corefile.c (set_gnutarget): Constify.
12449 * cp-name-parser.y (yyerror): Constify.
12450 * cp-valprint.c (cp_print_class_member): Constify.
12451 * cris-tdep.c (cris_register_name, crisv32_register_name):
12453 * d-exp.y (yyerror): Constify.
12454 (struct token::oper): Constify.
12455 * d-lang.h (d_yyerror): Constify.
12456 * dbxread.c (struct header_file_location::name): Constify.
12457 (add_old_header_file, add_new_header_file, last_function_name)
12458 (dbx_next_symbol_text, add_bincl_to_list)
12459 (find_corresponding_bincl_psymtab, set_namestring)
12460 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
12461 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
12462 * defs.h (command_line_input, print_address_symbolic)
12463 (deprecated_readline_begin_hook): Constify.
12464 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
12466 * event-top.c (handle_line_of_input): Constify and add cast.
12467 * exceptions.c (catch_errors): Constify.
12468 * exceptions.h (catch_errors): Constify.
12469 * expprint.c (print_subexp_standard, op_string, op_name)
12470 (op_name_standard, dump_raw_expression, dump_raw_expression):
12471 * expression.h (op_name, op_string, dump_raw_expression):
12473 * f-exp.y (yyerror): Constify.
12474 (struct token::oper): Constify.
12475 (struct f77_boolean_val::name): Constify.
12476 * f-lang.c (f_word_break_characters): Constify.
12477 * f-lang.h (f_yyerror): Constify.
12478 * fork-child.c (fork_inferior): Add cast.
12479 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
12480 (new_variant): Constify.
12481 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
12482 * gdbarch.c: Regenerate.
12483 * gdbcore.h (set_gnutarget): Constify.
12484 * go-exp.y (yyerror): Constify.
12485 (token::oper): Constify.
12486 * go-lang.h (go_yyerror): Constify.
12487 * go32-nat.c (go32_sysinfo): Constify.
12488 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
12489 * guile/scm-cmd.c (cmdscm_function): Constify.
12490 * guile/scm-param.c (pascm_param_value): Constify.
12491 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
12492 (h8300sx_register_name): Constify.
12493 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
12495 * ia64-tdep.c (ia64_register_names): Constify.
12496 * infcmd.c (construct_inferior_arguments): Constify.
12497 (path_command, attach_post_wait): Constify.
12498 * language.c (show_range_command, show_case_command)
12499 (unk_lang_error): Constify.
12500 * language.h (language_defn::la_error)
12501 (language_defn::la_name_of_this): Constify.
12502 * linespec.c (decode_line_2): Constify.
12503 * linux-thread-db.c (thread_db_err_str): Constify.
12504 * lm32-tdep.c (lm32_register_name): Constify.
12505 * m2-exp.y (yyerror): Constify.
12506 * m2-lang.h (m2_yyerror): Constify.
12507 * m32r-tdep.c (m32r_register_names): Constify and make static.
12508 * m68hc11-tdep.c (m68hc11_register_names): Constify.
12509 * m88k-tdep.c (m88k_register_name): Constify.
12510 * macroexp.c (appendmem): Constify.
12511 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
12512 (upgrade_type, parse_external, parse_partial_symbols)
12513 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
12514 (new_symbol): Constify.
12515 * memattr.c (mem_info_command): Constify.
12516 * mep-tdep.c (register_name_from_keyword): Constify.
12517 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
12519 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
12520 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
12521 * mi/mi-main.c (captured_mi_execute_command): Constify and add
12523 (mi_execute_async_cli_command): Constify.
12524 * mips-tdep.c (mips_register_name): Constify.
12525 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
12526 (am33_register_name, am33_2_register_name)
12527 * moxie-tdep.c (moxie_register_names): Constify.
12528 * nat/linux-osdata.c (osdata_type): Constify fields.
12529 * nto-tdep.c (nto_parse_redirection): Constify.
12530 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
12531 (lookup_child_selector): Constify.
12532 (objc_methcall::name): Constify.
12533 * objc-lang.h (lookup_objc_class, lookup_child_selector)
12534 (lookup_struct_typedef): Constify.
12535 * objfiles.c (pc_in_section): Constify.
12536 * objfiles.h (pc_in_section): Constify.
12537 * p-exp.y (struct token::oper): Constify.
12538 (yyerror): Constify.
12539 * p-lang.h (pascal_yyerror): Constify.
12540 * parser-defs.h (op_name_standard): Constify.
12541 (op_print::string): Constify.
12542 (exp_descriptor::op_name): Constify.
12543 * printcmd.c (print_address_symbolic): Constify.
12544 * psymtab.c (print_partial_symbols): Constify.
12545 * python/py-breakpoint.c (stop_func): Constify.
12546 (bppy_get_expression): Constify.
12547 * python/py-cmd.c (cmdpy_completer::name): Constify.
12548 (cmdpy_function): Constify.
12549 * python/py-event.c (evpy_add_attribute)
12550 (gdbpy_initialize_event_generic): Constify.
12551 * python/py-event.h (evpy_add_attribute)
12552 (gdbpy_initialize_event_generic): Constify.
12553 * python/py-evts.c (add_new_registry): Constify.
12554 * python/py-finishbreakpoint.c (outofscope_func): Constify.
12555 * python/py-framefilter.c (get_py_iter_from_func): Constify.
12556 * python/py-inferior.c (get_buffer): Add cast.
12557 * python/py-param.c (parm_constant::name): Constify.
12558 * python/py-unwind.c (fprint_frame_id): Constify.
12559 * python/python.c (gdbpy_parameter_value): Constify.
12560 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
12561 * remote.c (memory_packet_config::name): Constify.
12562 (show_packet_config_cmd, remote_write_bytes)
12563 (remote_buffer_add_string):
12564 * reverse.c (exec_reverse_once): Constify.
12565 * rs6000-tdep.c (variant::name, variant::description): Constify.
12566 * rust-exp.y (rustyyerror): Constify.
12567 * rust-lang.c (rust_op_name): Constify.
12568 * rust-lang.h (rustyyerror): Constify.
12569 * serial.h (serial_ops::name): Constify.
12570 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
12571 (sh_sh3e_register_name, sh_sh2e_register_name)
12572 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
12573 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
12574 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
12575 (sh_sh4al_dsp_register_name): Constify.
12576 * sh64-tdep.c (sh64_register_name): Constify.
12577 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
12578 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
12579 * stabsread.c (patch_block_stabs, read_type_number)
12580 (ref_map::stabs, ref_add, process_reference)
12581 (symbol_reference_defined, define_symbol, define_symbol)
12582 (error_type, read_type, read_member_functions, read_cpp_abbrev)
12583 (read_one_struct_field, read_struct_fields, read_baseclasses)
12584 (read_tilde_fields, read_struct_type, read_array_type)
12585 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
12586 (read_huge_number, read_range_type, read_args, common_block_start)
12587 (find_name_end): Constify.
12588 * stabsread.h (common_block_start, define_symbol)
12589 (process_one_symbol, symbol_reference_defined, ref_add):
12590 * symfile.c (get_section_index, add_symbol_file_command):
12591 * symfile.h (get_section_index): Constify.
12592 * target-descriptions.c (tdesc_type::name): Constify.
12593 (tdesc_free_type): Add cast.
12594 * target.c (find_default_run_target):
12595 (add_deprecated_target_alias, find_default_run_target)
12596 (target_announce_detach): Constify.
12597 (do_option): Constify.
12598 * target.h (add_deprecated_target_alias): Constify.
12599 * thread.c (print_thread_info_1): Constify.
12600 * top.c (deprecated_readline_begin_hook, command_line_input):
12602 (init_main): Add casts.
12603 * top.h (handle_line_of_input): Constify.
12604 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
12605 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
12606 (tfind_command): Rename to ...
12607 (tfind_command_1): ... this and constify.
12608 (tfind_command): New function.
12609 (tfind_end_command, tfind_start_command): Adjust.
12610 (encode_source_string): Constify.
12611 * tracepoint.h (encode_source_string): Constify.
12612 * tui/tui-data.c (tui_partial_win_by_name): Constify.
12613 * tui/tui-data.h (tui_partial_win_by_name): Constify.
12614 * tui/tui-source.c (tui_set_source_content_nil): Constify.
12615 * tui/tui-source.h (tui_set_source_content_nil): Constify.
12616 * tui/tui-win.c (parse_scrolling_args): Constify.
12617 * tui/tui-windata.c (tui_erase_data_content): Constify.
12618 * tui/tui-windata.h (tui_erase_data_content): Constify.
12619 * tui/tui-winsource.c (tui_erase_source_content): Constify.
12620 * tui/tui.c (tui_enable): Add cast.
12621 * utils.c (defaulted_query): Constify.
12622 (init_page_info): Add cast.
12623 (puts_debug, subset_compare): Constify.
12624 * utils.h (subset_compare): Constify.
12625 * varobj.c (varobj_format_string): Constify.
12626 * varobj.h (varobj_format_string): Constify.
12627 * vax-tdep.c (vax_register_name): Constify.
12628 * windows-nat.c (windows_detach): Constify.
12629 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
12630 * xml-support.c (gdb_xml_end_element): Constify.
12631 * xml-tdesc.c (tdesc_start_reg): Constify.
12632 * xstormy16-tdep.c (xstormy16_register_name): Constify.
12633 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
12634 * xtensa-tdep.h (xtensa_register_t::name): Constify.
12636 2017-04-05 Pedro Alves <palves@redhat.com>
12638 * proc-api.c (struct trans): Constify.
12639 (procfs_note): Constify.
12640 * proc-events.c (struct trans, syscall_table):
12641 * proc-flags.c (struct trans): Constify.
12642 * proc-utils.h (procfs_note): Constify.
12643 * proc-why.c (struct trans): Constify.
12644 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
12645 (procfs_detach): Constify.
12646 * sol-thread.c (struct string_map): Constify.
12647 (td_err_string, td_state_string): Constify.
12649 2017-04-05 Pedro Alves <palves@redhat.com>
12651 * proc-api.c (procfs_filename): Don't initialize
12653 (prepare_to_trace): Assume procfs_filename is non-NULL.
12654 (_initialize_proc_api): Give procfs_filename a default value here.
12656 2017-04-05 Pedro Alves <palves@redhat.com>
12658 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
12659 'cond_string' parameter.
12660 (extract_exception_regexp): Constify 'string' parameter.
12661 (catch_exception_command_1): Constify.
12662 * breakpoint.c (init_catchpoint)
12663 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
12665 (ep_parse_optional_if_clause, catch_fork_command_1)
12666 (catch_exec_command_1): Constify.
12667 * breakpoint.h (init_catchpoint): Constify 'cond_string'
12669 (ep_parse_optional_if_clause): Constify.
12670 * cli/cli-utils.c (remove_trailing_whitespace)
12671 (check_for_argument): Constify.
12672 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
12673 non-const overload.
12674 (check_for_argument): Likewise.
12676 2017-04-05 Pedro Alves <palves@redhat.com>
12678 * event-top.c (command_line_handler): Add cast to execute_command
12680 * record-btrace.c (cmd_record_btrace_bts_start)
12681 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
12682 (cmd_record_btrace_start): Add cast to execute_command call.
12683 * record-full.c (record_full_goto_insn):
12684 * record.c (record_start, record_stop): Add cast to
12685 execute_command_to_string calls.
12686 (cmd_record_start): Add cast to execute_command calls.
12688 2017-04-05 Pedro Alves <palves@redhat.com>
12690 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
12691 static inline function.
12692 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
12693 array and use gdb_PyArg_ParseTupleAndKeywords.
12694 * python/py-cmd.c (cmdpy_init): Likewise.
12695 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
12696 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
12697 (infpy_search_memory): Likewise.
12698 * python/py-objfile.c (objfpy_add_separate_debug_file)
12699 (gdbpy_lookup_objfile): Likewise.
12700 * python/py-symbol.c (gdbpy_lookup_symbol)
12701 (gdbpy_lookup_global_symbol): Likewise.
12702 * python/py-type.c (gdbpy_lookup_type): Likewise.
12703 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
12704 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
12707 2017-04-05 Pedro Alves <palves@redhat.com>
12709 * python/python-internal.h (gdb_PyGetSetDef): New type.
12710 * python/py-block.c (block_object_getset)
12711 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
12712 * python/py-event.c (event_object_getset)
12713 (finish_breakpoint_object_getset): Likewise.
12714 * python/py-inferior.c (inferior_object_getset): Likewise.
12715 * python/py-infthread.c (thread_object_getset): Likewise.
12716 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
12717 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
12718 * python/py-objfile.c (objfile_getset): Likewise.
12719 * python/py-progspace.c (pspace_getset): Likewise.
12720 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
12722 * python/py-record.c (recpy_record_getset): Likewise.
12723 * python/py-symbol.c (symbol_object_getset): Likewise.
12724 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
12726 * python/py-type.c (type_object_getset, field_object_getset):
12728 * python/py-value.c (value_object_getset): Likewise.
12730 2017-04-05 Pedro Alves <palves@redhat.com>
12732 * python/python-internal.h (gdb_PyObject_CallMethod)
12733 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
12735 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
12736 (PySys_GetObject, PySys_SetPath): New macros.
12738 2017-04-05 Pedro Alves <palves@redhat.com>
12740 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
12741 info_osdata_command.
12742 * osdata.c (info_osdata_command): Rename to ...
12743 (info_osdata): ... this. Constify 'type' parameter, and remove
12744 the 'from_tty' parameter. Accept NULL TYPE.
12745 (info_osdata_command): New function.
12746 * osdata.h (info_osdata_command): Remove declaration.
12747 (info_osdata): New declaration.
12749 2017-04-05 Pedro Alves <palves@redhat.com>
12751 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
12752 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
12753 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
12755 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
12756 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
12757 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
12759 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
12760 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
12761 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
12762 (mi_cmd_file_list_exec_source_files)
12763 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
12764 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12765 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
12767 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
12768 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
12769 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
12770 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
12771 (mi_cmd_stack_info_frame): Constify 'command' parameter.
12772 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
12773 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
12774 'command' parameter.
12775 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
12776 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
12777 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
12778 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
12779 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
12780 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
12781 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
12782 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
12783 (mi_cmd_var_set_update_range): Constify 'command' parameter.
12784 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
12785 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
12787 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
12788 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
12789 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
12790 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
12791 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
12792 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
12793 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
12794 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
12795 (mi_cmd_data_list_changed_registers)
12796 (mi_cmd_data_write_register_values)
12797 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
12798 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
12799 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
12800 (mi_cmd_list_features, mi_cmd_list_target_features)
12801 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
12802 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
12803 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
12804 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
12805 (mi_cmd_trace_frame_collected): Constify 'command'
12807 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
12808 'command' parameter.
12810 2017-04-05 Pedro Alves <palves@redhat.com>
12812 * ada-lang.c (ada_completer_word_break_characters): Now a const
12814 (ada_get_gdb_completer_word_break_characters): Constify.
12815 * completer.c (gdb_completer_command_word_break_characters)
12816 (gdb_completer_file_name_break_characters)
12817 (gdb_completer_quote_characters): Now const arrays.
12818 (get_gdb_completer_quote_characters): Constify.
12819 (set_rl_completer_word_break_characters): New function.
12820 (set_gdb_completion_word_break_characters)
12821 (complete_line_internal): Use it.
12822 * completer.h (get_gdb_completer_quote_characters): Constify.
12823 (set_rl_completer_word_break_characters): Declare.
12824 * f-lang.c (f_word_break_characters): Constify.
12825 * language.c (default_word_break_characters): Constify.
12826 * language.h (language_defn::la_word_break_characters): Constify.
12827 (default_word_break_characters): Constify.
12828 * top.c (init_main): Use set_rl_completer_word_break_characters.
12830 2017-04-05 Pedro Alves <palves@redhat.com>
12832 * aix-thread.c (aix_thread_pid_to_str)
12833 (aix_thread_extra_thread_info): Constify.
12834 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
12835 * bsd-uthread.c (bsd_uthread_extra_thread_info)
12836 (bsd_uthread_pid_to_str): Constify.
12837 * corelow.c (core_pid_to_str): Constify.
12838 * darwin-nat.c (darwin_pid_to_str): Constify.
12839 * fbsd-nat.c (fbsd_pid_to_str): Constify.
12840 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
12842 * gnu-nat.c (gnu_pid_to_str): Constify.
12843 * go32-nat.c (go32_pid_to_str): Constify.
12844 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
12845 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
12846 * inferior.c (inferior_pid_to_str): Constify.
12847 * linux-nat.c (linux_nat_pid_to_str): Constify.
12848 * linux-tdep.c (linux_core_pid_to_str): Constify.
12849 * linux-thread-db.c (thread_db_pid_to_str)
12850 (thread_db_extra_thread_info): Constify.
12851 * nto-tdep.c (nto_extra_thread_info): Constify.
12852 * nto-tdep.h (nto_extra_thread_info): Constify.
12853 * obsd-nat.c (obsd_pid_to_str): Constify.
12854 * procfs.c (procfs_pid_to_str): Constify.
12855 * ravenscar-thread.c (ravenscar_extra_thread_info)
12856 (ravenscar_pid_to_str): Constify.
12857 * remote-sim.c (gdbsim_pid_to_str): Constify.
12858 * remote.c (remote_threads_extra_info, remote_pid_to_str):
12860 * sol-thread.c (solaris_pid_to_str): Constify.
12861 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
12862 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
12863 * target.c (default_pid_to_str, target_pid_to_str)
12864 (normal_pid_to_str, default_pid_to_str): Constify.
12865 * target.h (target_ops::to_pid_to_str)
12866 (target_ops::to_extra_thread_info): Constify.
12867 (target_pid_to_str, normal_pid_to_str): Constify.
12868 * windows-nat.c (windows_pid_to_str): Constify.
12869 * gdbarch.sh (core_pid_to_str): Constify.
12870 * target-delegates.c: Regenerate.
12871 * gdbarch.h, gdbarch.c: Regenerate.
12873 2017-04-05 Pedro Alves <palves@redhat.com>
12875 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
12876 the memory of the temporary warning_pre_print override.
12877 * utils.c (warning_pre_print): Constify.
12878 * utils.h (warning_pre_print): Constify.
12880 2017-04-05 Pedro Alves <palves@redhat.com>
12882 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
12883 (shell_command): New function.
12884 (make_command): Use std::string.
12885 (init_cli_cmds): Register shell_command instead of shell_escape.
12887 2017-04-05 Pedro Alves <palves@redhat.com>
12889 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
12890 * tracepoint.c (default_collect): Don't initialize.
12892 2017-04-05 Pedro Alves <palves@redhat.com>
12894 * macroexp.c (macro_buffer::shared): Now a bool.
12895 (init_buffer): Update.
12896 (init_shared_buffer): Constify 'addr' parameter.
12897 (substitute_args, expand, macro_expand, macro_expand_next): Remove
12900 2017-04-05 Pedro Alves <palves@redhat.com>
12902 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
12903 * disasm.c (set_disassembler_options): Constify local.
12904 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
12906 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
12909 * tracefile.c (tsave_command): Fix argument parsing for '-r'
12912 2017-04-05 Yao Qi <yao.qi@linaro.org>
12914 * frame.c (frame_unwind_register_unsigned): Call
12915 frame_unwind_register_value.
12917 2017-04-05 Yao Qi <yao.qi@linaro.org>
12919 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
12920 Use gdb_test_multiple, and don't match anchor.
12922 2017-04-05 Pedro Alves <palves@redhat.com>
12924 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
12925 (Write After Approval): Remove Simon Marchi.
12927 2017-04-05 Pedro Alves <palves@redhat.com>
12929 * common/gdb_optional.h (optional::optional): Make constexpr and
12930 initialize m_dummy.
12932 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12934 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12935 (amd64fbsd_jmp_buf_reg_offset): Remove.
12936 (amd64fbsd_supply_uthread): Remove function.
12937 (amd64fbsd_collect_uthread): Remove function.
12938 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
12939 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
12940 (x86_64-*-freebsd*): Remove bsd-uthread.o.
12941 (fbsd-nat.c): Update comment.
12942 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12943 (i386fbsd_jmp_buf_reg_offset): Remove.
12944 (i386fbsd_supply_uthread): Remove function.
12945 (i386fbsd_collect_uthread): Remove function.
12946 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
12948 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12950 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
12951 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
12952 * NEWS: Mention that support for FreeBSD/alpha was removed.
12953 * alpha-fbsd-tdep.c: Delete file.
12954 * config/alpha/fbsd.mh: Delete file.
12955 * configure.host: Delete alpha*-*-freebsd* and
12956 alpha*-*-kfreebsd*-gnu.
12957 * configure.tgt: Delete alpha*-*-freebsd* and
12958 alpha*-*-kfreebsd*-gnu.
12960 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12962 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
12963 amd64bsd_store_inferior_registers): Use ptid from regcache.
12965 2017-04-04 Pedro Alves <palves@redhat.com>
12967 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
12968 data fields, make them private and add "m_" prefixes.
12969 (lnp_state_machine::lnp_state_machine): New ctor.
12970 (record_line, check_line_address, handle_set_discriminator)
12971 (handle_set_address, handle_advance_pc, handle_special_opcode)
12972 (handle_advance_line, handle_set_file, handle_negate_stmt)
12973 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
12974 (end_sequence, advance_line): New methods.
12975 (m_gdbarch, m_record_lines_p): New fields.
12976 (lnp_reader_state): Delete.
12977 (dwarf_record_line): Rename to ...
12978 (lnp_state_machine::record_line): ... adjust.
12979 (init_lnp_state_machine): Delete.
12980 (lnp_state_machine::lnp_state_machine): New.
12981 (check_line_address): Rename to ...
12982 (lnp_state_machine::check_line_address): This.
12983 (dwarf_decode_lines_1): Remove reference to "reader_state".
12984 Adjust lnp_state_machine having a non-default ctor. Use bool.
12985 State machine internal state manipulation moved to
12986 lnp_state_machine methods.
12988 2017-04-04 Pedro Alves <palves@redhat.com>
12990 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12991 unittests/offset-type-selftests.c.
12992 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
12993 * common/offset-type.h: New file.
12994 * common/preprocessor.h: New file.
12995 * common/traits.h: New file.
12996 * common/valid-expr.h: New file.
12997 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
12998 sect_offset and cu_offset strong typedefs throughout.
12999 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
13000 typedefs throughout.
13001 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
13002 sect_offset and cu_offset strong typedefs throughout.
13003 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
13004 typedefs throughout.
13005 * gdbtypes.h: Include "common/offset-type.h".
13006 (cu_offset): Now an offset type (strong typedef) instead of a
13008 (sect_offset): Likewise.
13009 (union call_site_parameter_u): Rename "param_offset" field to
13011 * unittests/offset-type-selftests.c: New file.
13013 2017-04-04 Pedro Alves <palves@redhat.com>
13015 * common/underlying.h: New file.
13016 * dwarf2read.c: Include "common/gdb_optional.h" and
13017 "common/underlying.h".
13018 (dir_index, file_name_index): New types.
13019 (file_entry): Use them.
13020 (file_entry::include): Use to_underlying.
13021 (line_header::add_file_name): Use dir_index.
13022 (read_formatted_entries): Use gdb::optional. Read form before
13023 writting to file_entry.
13024 (dwarf_decode_line_header): Use dir_index.
13025 (lnp_state_machine::current_file): Use to_underlying.
13026 (lnp_state_machine::file): Change type to file_name_index.
13027 (dwarf_record_line): Use to_underlying.
13028 (init_lnp_state_machine): Use file_name_index.
13029 (dwarf_decode_lines_1): Use dir_index and file_name_index.
13031 2017-04-04 Pedro Alves <palves@redhat.com>
13033 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
13034 operator bool, has_value and get methods.
13036 2017-04-04 Pedro Alves <palves@redhat.com>
13038 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
13040 (line_header): Initialize all data fields. Change type of
13041 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
13042 Change type of include_dirs to std::vector<const char *>. Remove
13043 num_include_dirs, include_dirs_size. Change type of file_names to
13044 std::vector<file_entry>. Remove num_file_names, file_names_size.
13045 (line_header::line_header): New.
13046 (line_header::add_include_dir, line_header::add_file_name): New
13048 (line_header::include_dir_at): Remove NULL check.
13049 (line_header::file_name_at): Add const overload.
13050 (line_header_up): New unique_ptr typedef.
13051 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
13052 std::vector. Remove free_line_header call.
13053 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
13054 free_line_header call.
13055 (free_cu_line_header): Delete.
13056 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
13057 (setup_type_unit_groups): Use line_header_up instead of cleanups.
13058 Adjust to use std::vector.
13059 (free_line_header): Delete.
13060 (free_line_header_voidp): Use delete.
13061 (add_include_dir): Replace with ...
13062 (line_header::add_include_dir): ... this method. Use std::vector.
13063 (add_file_name): Replace with ...
13064 (line_header::add_file_name): ... this method. Use std::vector.
13065 (add_include_dir_stub): Delete.
13066 (read_formatted_entries): Remove memset.
13067 (dwarf_decode_line_header): Return a line_header_up instead of a
13068 raw pointer. Remove cleanup handling. Pass lambdas to
13069 read_formatted_entries. Adjust to use line_header methods.
13070 (dwarf_decode_lines_1): Adjust to use line_header methods.
13071 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
13074 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
13076 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
13077 instead of struct ptid.
13079 2017-05-04 Alan Hayward <alan.hayward@arm.com>
13081 * frame.c (get_frame_register_bytes): Unwind using value.
13082 (put_frame_register_bytes): Likewise.
13084 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
13086 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
13089 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
13091 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
13093 2017-03-29 Yao Qi <yao.qi@linaro.org>
13095 * gdbthread.h (struct thread_info): Declare constructor and
13096 destructor. Add some in-class member initializers.
13097 * thread.c (free_thread): Remove.
13098 (init_thread_list): Call delete instead of free_thread.
13099 (new_thread): Call thread_info constructor.
13100 (thread_info::thread_info): New function.
13101 (thread_info::~thread_info): New function.
13102 (delete_thread_1): Call delete instead of free_thread.
13103 (make_cleanup_restore_current_thread): Move tp and frame to
13106 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13108 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
13109 (arc_skip_prologue): Likewise.
13110 (arc_make_frame_cache): Likewise.
13111 (arc_pv_get_operand): New function.
13112 (arc_is_in_prologue): Likewise.
13113 (arc_analyze_prologue): Likewise.
13114 (arc_print_frame_cache): Likewise.
13115 (MAX_PROLOGUE_LENGTH): New constant.
13117 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13119 * configure.tgt: Add arc-insn.o.
13120 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
13121 (dump_arc_instruction_command): New function.
13122 (arc_fprintf_disasm): Likewise.
13123 (arc_disassemble_info): Likewise.
13124 (arc_insn_get_operand_value): Likewise.
13125 (arc_insn_get_operand_value_signed): Likewise.
13126 (arc_insn_get_memory_base_reg): Likewise.
13127 (arc_insn_get_memory_offset): Likewise.
13128 (arc_insn_get_branch_target): Likewise.
13129 (arc_insn_dump): Likewise.
13130 (arc_insn_get_linear_next_pc): Likewise.
13131 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
13132 (arc_disassemble_info): Likewise.
13133 (arc_insn_get_branch_target): Likewise.
13134 (arc_insn_get_linear_next_pc): Likewise.
13135 * NEWS: Mention new "maint print arc arc-instruction".
13137 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13139 * arc-tdep (maintenance_print_arc_list): New variable.
13140 (maintenance_print_arc_command): New function.
13142 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
13144 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
13145 Add "limm" and "reserved".
13146 (arc_cannot_fetch_register, arc_cannot_store_register): Add
13147 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
13148 * arc-tdep.h (arc_regnum): Likewise.
13150 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13152 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
13153 for THREADPTR register.
13154 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
13156 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
13157 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
13158 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
13160 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13162 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
13163 registers above gdbarch_num_regs (gdbarch) as privileged in
13166 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13168 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
13169 for a single specified register or for all registers in
13170 a0_base..a0_base + C0_NREGS range.
13171 (supply_gregset_reg): Call regcache_raw_supply for a single
13172 specified register or for all registers in a0_base..a0_base +
13175 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13177 * arch/xtensa.h (C0_NREGS): Add definition.
13178 * xtensa-tdep.c (C0_NREGS): Remove definition.
13180 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
13182 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
13183 Drop xtensa_default_isa initialization.
13184 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
13186 2017-03-27 Pedro Alves <palves@redhat.com>
13188 * dwarf2read.c (file_entry) <dir_index>: Add comment.
13189 (file_entry::include_dir): New method.
13190 (line_header::include_dir_at, line_header::file_name_at): New
13192 (setup_type_unit_groups, setup_type_unit_groups)
13193 (psymtab_include_file_name): Simplify using the new methods.
13194 (lnp_state_machine) <the_line_header>: New field.
13195 <file>: Add comment.
13196 (lnp_state_machine::current_file): New method.
13197 (dwarf_record_line): Simplify using the new methods.
13198 (init_lnp_state_machine): Initialize the "the_line_header" field.
13199 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
13200 Simplify using the new methods.
13202 2017-03-27 Pedro Alves <palves@redhat.com>
13204 * cp-name-parser.y (make_empty): Delete.
13205 (demangler_special, nested_name, ptr_operator, array_indicator)
13206 (direct_declarator, declarator_1): Use fill_comp instead of
13209 2017-03-27 Pedro Alves <palves@redhat.com>
13211 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
13212 to ATTRIBUTE_PRINTF.
13213 * solib-target.c (library_list_start_list): Print "string" not
13215 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
13216 gdb_xml_error call.
13218 2017-03-27 Pedro Alves <palves@redhat.com>
13220 * dwarf2read.c (struct file_and_directory): New.
13221 (dwarf2_get_dwz_file): Adjust to use std::string.
13222 (dw2_get_file_names_reader): Adjust to use file_and_directory.
13223 (find_file_and_directory): Adjust to return a file_and_directory
13225 (read_file_scope): Adjust to use file_and_directory. Remove
13226 make_cleanup/do_cleanups calls.
13227 (open_and_init_dwp_file): Adjust to use std::string. Remove
13228 make_cleanup/do_cleanups calls.
13229 * python/python.c (do_start_initialization): Adjust to ldirname
13230 returning a std::string.
13231 * utils.c (ldirname): Now returns a std::string.
13232 * utils.h (ldirname): Change return type to std::string.
13233 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
13234 returning a std::string.
13235 * xml-tdesc.c (file_read_description_xml): Likewise.
13237 2017-03-24 Alan Hayward <alan.hayward@arm.com>
13239 * regcache.c (regcache_debug_print_register): New function.
13240 * regcache.h (regcache_debug_print_register): New declaration.
13241 * target.c (debug_print_register): Remove.
13242 (target_fetch_registers): Call regcache_debug_print_register.
13243 (target_store_registers): Likewise.
13245 2017-03-24 Pádraig Brady <pbrady@fb.com>
13247 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
13248 reference beyond the 'lh->include_dirs' array before accessing to
13250 (psymtab_include_file_name): Likewise.
13251 (dwarf_decode_lines_1): Likewise.
13252 (dwarf_decode_lines): Likewise.
13253 (file_file_name): Likewise.
13255 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
13257 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
13259 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
13260 ps_lsetfpregs): Likewise.
13261 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
13262 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
13263 ps_lsetfpregs): Likewise.
13264 * target.c (target_fetch_registers, target_store_registers):
13267 2017-03-23 Alan Hayward <alan.hayward@arm.com>
13269 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
13271 2017-03-23 Yao Qi <yao.qi@linaro.org>
13273 * aarch64-tdep.c (aarch64_process_record_test): Declare.
13274 (_initialize_aarch64_tdep): Register it.
13275 (aarch64_record_load_store): Handle PRFM instruction.
13276 (aarch64_process_record_test): New function.
13278 2017-03-23 Yao Qi <yao.qi@linaro.org>
13280 * aarch64-tdep.c (aarch64_record_load_store): Fix code
13283 2017-03-23 Yao Qi <yao.qi@linaro.org>
13285 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
13287 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
13289 python/python.c (do_start_initialization): Fix memory leak.
13291 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
13293 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
13294 using get_ptrace_pid.
13295 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
13297 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
13298 inferior_ptid instead of pid.
13300 2017-03-22 Yao Qi <yao.qi@linaro.org>
13302 * aarch64-tdep.c: Wrap locally used classes in anonymous
13304 * arm-tdep.c: Likewise.
13305 * linespec.c: Likewise.
13306 * ui-out.c: Likewise.
13308 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
13311 * python/lib/gdb/printer/bound_registers.py: Import sys.
13313 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
13315 * windows-nat.c (do_windows_fetch_inferior_registers): Add
13316 windows_thread_info parameter and use it instead of
13318 (windows_fetch_inferior_registers): Don't set current_thread,
13319 pass the thread to do_windows_fetch_inferior_registers. Use
13320 ptid from regcache instead of inferior_ptid.
13321 (do_windows_store_inferior_registers): Add windows_thread_info
13322 parameter and use it instead of current_thread.
13323 (windows_store_inferior_registers): Don't set current_thread,
13324 pass the thread to do_windows_store_inferior_registers. Use
13325 ptid from regcache instead of inferior_ptid.
13327 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
13329 * ser-mingw.c (ser_windows_raw): Remove reference to
13330 struct serial::current_timeout.
13332 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
13335 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
13336 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
13337 (sparc64_fsr_type): Fix %fsr decoding.
13339 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
13341 * python/py-record-btrace.c (btpy_insn_data): Change return type
13344 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
13346 * spu-linux-nat.c (spu_fetch_inferior_registers,
13347 spu_store_inferior_registers): Use ptid from regcache, set and
13348 restore inferior_ptid.
13349 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
13352 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
13354 * i386-linux-nat.c (fetch_register, store_register,
13355 i386_linux_fetch_inferior_registers,
13356 i386_linux_store_inferior_registers): Use ptid from regcache.
13357 * ia64-linux-nat.c (ia64_linux_fetch_register,
13358 ia64_linux_store_register): Likewise.
13359 * inf-ptrace.c (inf_ptrace_fetch_register,
13360 inf_ptrace_store_register): Likewise.
13361 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
13362 m32r_linux_store_inferior_registers): Likewise.
13363 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
13364 m68kbsd_store_inferior_registers): Likewise.
13365 * m68k-linux-nat.c (fetch_register, store_register,
13366 m68k_linux_fetch_inferior_registers,
13367 m68k_linux_store_inferior_registers): Likewise.
13368 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
13369 m88kbsd_store_inferior_registers): Likewise.
13370 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
13371 mips_fbsd_store_inferior_registers): Likewise.
13372 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
13373 mips64_linux_regsets_store_registers): Likewise.
13374 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
13375 mipsnbsd_store_inferior_registers): Likewise.
13376 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
13377 mips64obsd_store_inferior_registers): Likewise.
13378 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
13380 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
13381 ppcfbsd_store_inferior_registers): Likewise.
13382 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
13383 ppc_linux_store_inferior_registers): Likewise.
13384 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
13385 ppcnbsd_store_inferior_registers): Likewise.
13386 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
13387 ppcobsd_store_registers): Likewise.
13388 * procfs.c (procfs_fetch_registers, procfs_store_registers):
13390 * ravenscar-thread.c (ravenscar_fetch_registers,
13391 ravenscar_store_registers, ravenscar_prepare_to_store):
13393 * record-btrace.c (record_btrace_fetch_registers,
13394 record_btrace_store_registers, record_btrace_prepare_to_store):
13396 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
13397 Lookup inferior using ptid from regcache, instead of
13399 * remote.c (remote_fetch_registers, remote_store_registers): Use
13400 ptid from regcache.
13401 * rs6000-nat.c (fetch_register, store_register): Likewise.
13402 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
13403 s390_linux_store_inferior_registers): Likewise.
13404 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
13405 shnbsd_store_inferior_registers): Likewise.
13406 * sol-thread.c (sol_thread_fetch_registers,
13407 sol_thread_store_registers): Likewise.
13408 * sparc-nat.c (sparc_fetch_inferior_registers,
13409 sparc_store_inferior_registers): Likewise.
13410 * tilegx-linux-nat.c (fetch_inferior_registers,
13411 store_inferior_registers): Likewise.
13412 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
13413 vaxbsd_store_inferior_registers): Likewise.
13414 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
13415 store_xtregs): Likewise.
13417 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13420 * NEWS: Mention support for rvalue references in GDB and python.
13421 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
13422 supports both lvalue and rvalue references.
13424 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13427 * gdbtypes.c (rank_one_type): Implement overloading
13428 resolution rules regarding rvalue references.
13430 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13433 * aarch64-tdep.c (aarch64_type_align)
13434 (aarch64_extract_return_value, aarch64_store_return_value): Change
13435 lvalue reference type checks to general reference type checks.
13436 * amd64-tdep.c (amd64_classify): Likewise.
13437 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
13439 * arm-tdep.c (arm_type_align, arm_extract_return_value)
13440 (arm_store_return_value): Likewise.
13441 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
13442 * c-typeprint.c (c_print_type): Likewise.
13443 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
13444 (cplus_number_of_children, cplus_describe_child): Likewise.
13445 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
13446 * completer.c (expression_completer): Likewise.
13447 * cp-support.c (make_symbol_overload_list_adl_namespace):
13449 * darwin-nat-info.c (info_mach_region_command): Likewise.
13450 * dwarf2loc.c (entry_data_value_coerce_ref)
13451 (value_of_dwarf_reg_entry): Likewise.
13452 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
13453 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
13455 * findvar.c (extract_typed_address, store_typed_address):
13457 * gdbtypes.c (rank_one_type): Likewise.
13458 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
13459 * infcall.c (value_arg_coerce): Likewise.
13460 * language.c (pointer_type): Likewise.
13461 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
13463 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
13464 * mn10300-tdep.c (mn10300_type_align): Likewise.
13465 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
13466 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
13467 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
13469 * printcmd.c (print_formatted, x_command): Likewise.
13470 * python/py-type.c (typy_get_composite, typy_template_argument):
13472 * python/py-value.c (valpy_referenced_value)
13473 (valpy_get_dynamic_type, value_has_field): Likewise.
13474 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
13475 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
13476 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
13477 * spu-tdep.c (spu_scalar_value_p): Likewise.
13478 * symtab.c (lookup_symbol_aux): Likewise.
13479 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
13480 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
13482 * valops.c (value_cast_pointers, value_cast)
13483 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
13484 (value_struct_elt, value_struct_elt_bitpos)
13485 (value_find_oload_method_list, find_overload_match)
13486 (value_rtti_indirect_type): Likewise.
13487 * valprint.c (val_print_scalar_type_p, generic_val_print):
13489 * value.c (value_actual_type, value_as_address, unpack_long)
13490 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
13491 (coerce_ref): Likewise.
13492 * varobj.c (varobj_get_value_type): Likewise.
13494 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13497 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
13498 table of constants.
13499 * python/lib/gdb/command/explore.py: Support exploring values
13500 of rvalue reference types.
13501 * python/lib/gdb/types.py: Implement get_basic_type() for
13502 rvalue reference types.
13503 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
13505 * python/py-value.c (valpy_getitem): Add an rvalue reference
13507 (valpy_reference_value): Add new parameter "refcode".
13508 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
13509 New wrappers for valpy_reference_value().
13510 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13511 (gdbpy_invoke_xmethod): Likewise.
13513 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13516 * dwarf2read.c (process_die, read_type_die_1): Handle the
13517 DW_TAG_rvalue_reference_type DIE.
13518 (read_tag_reference_type): Add new parameter "refcode".
13520 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13523 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
13524 (c_type_print_modifier, c_type_print_varspec_suffix)
13525 (c_type_print_base): Support printing rvalue reference types.
13526 * c-valprint.c (c_val_print, c_value_print): Support printing
13527 rvalue reference values.
13529 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13532 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
13534 * cp-support.c (replace_typedefs): Handle
13535 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
13536 * python/py-type.c (typy_lookup_type): Likewise.
13538 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13541 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
13542 * parse.c (insert_type): Change assert statement.
13543 (follow_types): Handle rvalue reference types.
13544 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
13547 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13550 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
13551 value_ref() interface.
13552 * c-valprint.c (c_value_print): Likewise.
13553 * infcall.c (value_arg_coerce): Likewise.
13554 * python/py-value.c (valpy_reference_value): Likewise.
13555 * valops.c (value_cast, value_reinterpret_cast)
13556 (value_dynamic_cast, typecmp): Likewise.
13557 (value_ref): Parameterize by kind of return value reference type.
13558 * value.h (value_ref): Add new parameter "refcode".
13560 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13563 * dwarf2read.c (read_tag_reference_type): Use
13564 lookup_lvalue_reference_type() instead of lookup_reference_type().
13565 * eval.c (evaluate_subexp_standard): Likewise.
13566 * f-exp.y: Likewise.
13567 * gdbtypes.c (make_reference_type, lookup_reference_type):
13568 Generalize with rvalue reference types.
13569 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
13570 convenience wrappers for lookup_reference_type().
13571 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
13572 reference kind parameter.
13573 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
13574 wrappers for lookup_reference_type().
13575 * guile/scm-type.c (gdbscm_type_reference): Use
13576 lookup_lvalue_reference_type() instead of lookup_reference_type().
13577 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
13578 * parse.c (follow_types): Likewise.
13579 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
13580 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
13582 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13583 (gdbpy_invoke_xmethod): Likewise.
13584 * stabsread.c: Provide extra argument to make_reference_type()
13586 * valops.c (value_ref, value_rtti_indirect_type): Use
13587 lookup_lvalue_reference_type() instead of lookup_reference_type().
13589 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13592 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
13593 (TYPE_IS_REFERENCE): New macro.
13594 (struct type): Add rvalue_reference_type field.
13595 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
13597 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13599 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
13600 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
13601 New function definition.
13602 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
13603 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
13604 New function declaration.
13605 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
13606 * mi/mi-interp.h: New file.
13607 * solib.c (info_sharedlibrary_command): Replace for loop with
13609 * solib.h (update_solib_list): New function declaration.
13610 (so_list_head): Move macro.
13611 * solist.h (ALL_SO_LIBS): New macro.
13613 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13615 * infcmd.c (post_create_inferior): Remove unused argument in
13617 * remote.c (remote_start_remote): Likewise.
13618 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
13619 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
13620 (enable_break): Likewise.
13621 * solib.c (update_solib_list): Remove unused target argument
13622 and its documentation.
13623 (solib_add): Remove unused target argument. Remove unused
13624 argument in call to update_solib_list.
13625 (info_sharedlibrary_command): Remove unused argument in call
13626 to update_solib_list.
13627 (sharedlibrary_command): Remove unused argument in call to
13629 (handle_solib_event): Likewise.
13630 (reload_shared_libraries): Likewise.
13631 * solib.h (solib_add): Remove unused target argument.
13633 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
13635 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
13636 (s390_displaced_step_fixup): Cover relative branches with the
13637 default fixup handling. This fixes lack of support for some
13638 relative branch instructions.
13640 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13642 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
13643 ptid from regcache.
13645 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13647 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
13648 i386_darwin_store_inferior_registers): Use ptid from regcache.
13650 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13652 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
13653 i386bsd_store_inferior_registers): Use ptid from regcache.
13655 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13657 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
13658 hppaobsd_store_registers): Use ptid from regcache.
13660 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13662 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
13663 hppanbsd_store_registers): Use ptid from regcache.
13665 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13667 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
13668 from regcache. Use get_ptrace_pid.
13670 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13672 * corelow.c (get_core_register_section): Use ptid from regcache,
13675 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13677 * bsd-uthread.c (bsd_uthread_fetch_registers,
13678 bsd_uthread_store_registers): Use ptid from regcache, set and
13679 restore inferior_ptid.
13681 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13683 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
13684 fetch_fp_regs, store_register, store_regs, store_fp_register,
13685 store_fp_regs): Use ptid from regcache.
13687 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13689 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
13690 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
13691 store_vfp_regs): Use ptid from regcache.
13693 2017-03-17 Pedro Alves <palves@redhat.com>
13696 * ser-base.c (ser_base_wait_for): Add comment.
13697 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
13699 * ser-unix.c (hardwire_raw): Remove reference to
13700 scb->current_timeout.
13701 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
13702 (hardwire_ops): Install ser_base_readchar instead of
13704 * serial.h (struct serial) <current_timeout, timeout_remaining>:
13707 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
13710 * python/lib/gdb/printer/bound_registers.py: Add support for
13713 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
13715 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
13716 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
13717 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
13718 byte_offset to subobj_byte_offset. Fix the handling of
13719 DWARF_VALUE_STACK on big-endian targets when coming via an
13721 (dwarf2_evaluate_loc_desc): Adjust call to
13722 dwarf2_evaluate_loc_desc_full.
13723 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
13724 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
13726 2017-03-16 Yao Qi <yao.qi@linaro.org>
13728 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
13729 and REVSH instructions.
13731 2017-03-16 Yao Qi <yao.qi@linaro.org>
13733 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
13734 (arm_record_test): Declare.
13735 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
13736 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
13737 align with the manual.
13738 (thumb_record_misc): Adjust the code order to align with the
13740 (thumb2_record_decode_insn_handler): Fix instruction matching.
13741 (instruction_reader_thumb): New class.
13742 (arm_record_test): New function.
13744 2017-03-16 Yao Qi <yao.qi@linaro.org>
13746 * arm-tdep.c (abstract_memory_reader): New class.
13747 (instruction_reader): New class.
13748 (extract_arm_insn): Add argument 'reader'. Callers updated.
13749 (decode_insn): Likewise.
13751 2017-03-16 Doug Evans <dje@google.com>
13753 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
13754 member. Change type of TYPE member to SCM. All uses updated.
13755 (lsscm_make_lazy_string_smob): Add assert.
13756 (lsscm_make_lazy_string): Flag bad length values.
13757 (lsscm_elt_type): New function.
13758 (gdbscm_lazy_string_to_value): Rewrite to use
13759 lsscm_safe_lazy_string_to_value.
13760 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
13761 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
13762 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
13764 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13765 * guile/scm-type.c (tyscm_scm_to_type): New function.
13767 2017-03-15 Doug Evans <dje@google.com>
13769 PR python/17728, python/18439, python/18779
13770 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
13771 member. Change type of TYPE member to PyObject *. All uses updated.
13772 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
13773 (gdbpy_create_lazy_string_object): Flag bad length values.
13774 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
13775 Handle typedefs in incoming type.
13776 (stpy_lazy_string_elt_type): New function.
13777 (gdbpy_extract_lazy_string): Call it.
13778 * python/py-value.c (valpy_lazy_string): Flag bad length values.
13779 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
13780 typedefs in incoming type.
13782 2017-03-16 Doug Evans <dje@google.com>
13784 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13785 * guile/scm-type.c (tyscm_scm_to_type): New function.
13787 2017-03-16 Jiong Wang <jiong.wang@arm.com>
13789 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
13790 "ULONGEST" for "skip".
13792 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13795 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
13796 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
13797 (inf_ptrace_peek_poke): ...here. New function. Now also loop
13798 over ptrace peek/poke until end of buffer or error.
13800 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
13802 * parse.c (length_of_subexp): Make static.
13803 * parser-defs.h (length_of_subexp): Remove.
13805 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13807 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
13810 2017-03-14 Pedro Alves <palves@redhat.com>
13812 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
13813 (main): Use std::unique_ptr. Remove calls to
13814 cp_demangled_name_parse_free.
13816 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13818 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
13819 alphabsd_store_inferior_registers): Use regcache->ptid instead
13822 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13824 * aix-thread.c (aix_thread_fetch_registers,
13825 aix_thread_store_registers): Use regcache->ptid instead of
13828 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13830 * aarch64-linux-nat.c (fetch_gregs_from_thread,
13831 store_gregs_to_thread, fetch_fpregs_from_thread,
13832 store_fpregs_to_thread): Use regcache->ptid instead of
13835 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13837 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
13838 amd64_linux_fetch_inferior_registers): Use regcache->ptid
13839 instead of inferior_ptid.
13841 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13843 * target.c (target_fetch_registers, target_store_registers): Add
13846 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13848 * regcache.h (regcache_get_ptid): New function.
13849 * regcache.c (regcache_get_ptid): New function.
13851 2017-03-13 Mark Wielaard <mark@klomp.org>
13853 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
13855 2017-03-10 Keith Seitz <keiths@redhat.com>
13858 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
13860 2017-03-08 Pedro Alves <palves@redhat.com>
13863 * infrun.c (start_step_over, do_target_resume, resume)
13864 (restart_threads): Assert we're not resuming a thread that is
13865 meant to be stopped.
13866 (infrun_thread_stop_requested_callback): Delete.
13867 (infrun_thread_stop_requested): If the thread is internally
13868 stopped, queue a pending stop event and clear the thread's
13869 inline-frame state.
13870 (handle_stop_requested): New function.
13871 (handle_syscall_event, handle_inferior_event_1): Use
13872 handle_stop_requested.
13873 (handle_stop_requested): New function.
13874 (handle_signal_stop): Set the thread's stop_signal here instead of
13876 (finish_step_over): Clear step over info unconditionally.
13877 (handle_signal_stop): If the user had interrupted the event
13878 thread, consider the stop a random signal.
13879 (handle_signal_stop) <signal arrived while stepping over
13880 breakpoint>: Don't restart threads here.
13881 (stop_waiting): Don't clear step-over info here.
13883 2017-03-08 Pedro Alves <palves@redhat.com>
13886 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
13887 goes to argument 2, not 1.
13889 2017-03-08 Pedro Alves <palves@redhat.com>
13892 * top.c (gdb_readline_wrapper): Avoid passing NULL to
13893 display_gdb_prompt.
13894 (command_line_input): Add comment.
13896 2017-03-08 Pedro Alves <palves@redhat.com>
13899 * tui/tui-file.c (tui_file::write): New.
13900 * tui/tui-file.h (tui_file): Override "write".
13901 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
13902 factored out from ...
13903 (tui_puts): ... here.
13904 (tui_putc): Use them.
13905 (tui_write): New function.
13906 * tui/tui-io.h (tui_write): Declare.
13908 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
13910 * Makefile.in (SFILES): Replace "environ.c" with
13911 "common/environ.c".
13912 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
13913 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
13915 * common/environ.c: ... here.
13916 * environ.h: Moved to...
13917 * common/environ.h: ... here.
13919 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13921 * gdbarch.sh (pstring_ptr): New static function.
13922 (gdbarch_disassembler_options): Use it.
13923 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
13924 not valid_disassembler_option->name.
13925 * gdbarch.c: Regenerate.
13927 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13929 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
13931 2017-03-07 Pedro Alves <palves@redhat.com>
13933 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
13935 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
13937 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
13938 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
13939 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
13940 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
13942 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
13944 * xtensa-linux-nat.c (fetch_gregs): Remove const.
13946 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
13948 * remote.c (remote_add_target_side_commands): Use range-based
13951 2017-03-03 Yao Qi <yao.qi@linaro.org>
13954 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
13956 * valprint.c (common_val_print): Likewise.
13958 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
13960 * NEWS: Mention new set/show disassembler-options commands.
13961 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
13962 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
13963 (prospective_options): New static variable.
13964 (gdb_disassembler::gdb_disassembler): Initialize
13965 m_di.disassembler_options.
13966 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
13967 (get_disassembler_options): New function.
13968 (set_disassembler_options): Likewise.
13969 (set_disassembler_options_sfunc): Likewise.
13970 (show_disassembler_options_sfunc): Likewise.
13971 (disassembler_options_completer): Likewise.
13972 (_initialize_disasm): Likewise.
13973 * disasm.h (get_disassembler_options): New prototype.
13974 (set_disassembler_options): Likewise.
13975 * gdbarch.sh (gdbarch_disassembler_options): New variable.
13976 (gdbarch_verify_disassembler_options): Likewise.
13977 * gdbarch.c: Regenerate.
13978 * gdbarch.h: Likewise.
13979 * arm-tdep.c (num_disassembly_options): Delete.
13980 (set_disassembly_style): Likewise.
13981 (arm_disassembler_options): New static variable.
13982 (set_disassembly_style_sfunc): Convert short style name into long
13983 option name. Call set_disassembler_options.
13984 (show_disassembly_style_sfunc): New function.
13985 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
13986 set_gdbarch_verify_disassembler_options.
13987 (_initialize_arm_tdep): Delete regnames variable and update callers.
13988 (arm_disassembler_options): Initialize.
13989 (disasm_options): New variable.
13990 (num_disassembly_options): Rename from this...
13991 (num_disassembly_styles): ...to this. Compute by scanning through
13993 (valid_disassembly_styles): Initialize using disasm_options.
13994 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
13995 set_arm_regname_option.
13996 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
13997 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
13998 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
13999 set_gdbarch_verify_disassembler_options.
14000 * s390-tdep.c (s390_disassembler_options): New static variable.
14001 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
14002 set_gdbarch_verify_disassembler_options.
14004 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14006 * remote.c (remote_add_target_side_condition): Remove "struct"
14007 keyword from range-based for loop.
14009 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
14011 * remote.c (remote_add_target_side_condition): Use range-based
14012 for loop. Update comment.
14014 2017-02-27 Yao Qi <yao.qi@linaro.org>
14016 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
14018 2017-02-26 Alan Hayward <alan.hayward@arm.com>
14020 * regcache.c (regcache_raw_update): New function.
14021 (regcache_raw_read): Move code to regcache_raw_update.
14022 * regcache.h (regcache_raw_update): New declaration.
14023 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
14025 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
14027 * dwarf2read.c (create_debug_type_hash_table): Initialize
14028 header.signature and header.type_offset_in_tu.
14030 2017-02-24 Pedro Alves <palves@redhat.com>
14032 * symtab.c (make_file_symbol_completion_list_1): Use
14033 add_symtab_completions.
14035 2017-02-24 Alan Hayward <alan.hayward@arm.com>
14037 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
14039 2017-02-24 Alan Hayward <alan.hayward@arm.com>
14041 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
14042 I386_MAX_REGISTER_SIZE.
14043 (i386_pseudo_register_write): Likewise.
14044 (i386_process_record): Likewise.
14045 * i387-tdep.c (i387_supply_xsave): Likewise.
14046 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
14047 (store_register): Likewise.
14049 2017-02-23 Pedro Alves <palves@redhat.com>
14051 * ada-lang.c: Include "common/function-view.h".
14052 (ada_iterate_over_symbols): Adjust to use function_view as
14054 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
14055 (ada_make_symbol_completion_list): Use a lambda.
14056 (ada_exc_search_name_matches): Delete.
14057 (name_matches_regex): New.
14058 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
14059 * compile/compile-c-support.c: Include "common/function-view.h".
14060 (print_one_macro): Change prototype to accept a ui_file pointer.
14061 (write_macro_definitions): Use a lambda.
14062 * dwarf2read.c: Include "common/function-view.h".
14063 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
14064 (dw2_expand_symtabs_matching): Adjust to use function_view as
14066 * language.h: Include "common/function-view.h".
14067 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
14068 function_view as callback type.
14069 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
14070 * linespec.c: Include "common/function-view.h".
14071 (collect_info::add_symbol): New method.
14072 (struct symbol_and_data_callback, iterate_inline_only, struct
14073 symbol_matcher_data, iterate_name_matcher): Delete.
14074 (iterate_over_all_matching_symtabs): Adjust to use function_view
14075 as callback type and lambdas.
14076 (iterate_over_file_blocks): Adjust to use function_view as
14078 (decode_compound_collector): Now a class with private fields.
14079 (decode_compound_collector::release_symbols): New method.
14080 (collect_one_symbol): Rename to...
14081 (decode_compound_collector::operator()): ... this and adjust.
14082 (lookup_prefix_sym): decode_compound_collector construction bits
14083 move to decode_compound_collector ctor. Pass the
14084 decode_compound_collector object directly as callback. Remove
14085 cleanups and use decode_compound_collector::release_symbols
14087 (symtab_collector): Now a class with private fields.
14088 (symtab_collector::release_symtabs): New method.
14089 (add_symtabs_to_list): Rename to...
14090 (symtab_collector::operator()): ... this and adjust.
14091 (collect_symtabs_from_filename): symtab_collector construction
14092 bits move to symtab_collector ctor. Pass the symtab_collector
14093 object directly as callback. Remove cleanups and use
14094 symtab_collector::release_symtabs instead.
14095 (collect_symbols): Delete.
14096 (add_matching_symbols_to_info): Use lambdas.
14097 * macrocmd.c (print_macro_callback): Delete.
14098 (info_macro_command): Use a lambda.
14099 (info_macros_command): Pass print_macro_definition as callable
14101 (print_one_macro): Remove 'ignore' parameter.
14102 (macro_list_command): Adjust.
14103 * macrotab.c (macro_for_each_data::fn): Now a function_view.
14104 (macro_for_each_data::user_data): Delete field.
14105 (foreach_macro): Adjust to call the function_view.
14106 (macro_for_each): Adjust to use function_view as callback type.
14107 (foreach_macro_in_scope): Adjust to call the function_view.
14108 (macro_for_each_in_scope): Adjust to use function_view as callback
14110 * macrotab.h: Include "common/function-view.h".
14111 (macro_callback_fn): Declare a prototype instead of a pointer.
14112 Remove "user_data" parameter.
14113 (macro_for_each, macro_for_each_in_scope): Adjust to use
14114 function_view as callback type.
14115 * psymtab.c (partial_map_expand_apply)
14116 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
14117 Adjust to use function_view as callback type and to return bool.
14118 (psym_expand_symtabs_matching): Adjust to use function_view as
14120 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
14121 to use function_view as callback type and to return bool.
14122 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
14124 * symfile.c (expand_symtabs_matching): Adjust to use function_view
14126 * symfile.h: Include "common/function-view.h".
14127 (expand_symtabs_file_matcher_ftype)
14128 (expand_symtabs_symbol_matcher_ftype)
14129 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
14131 (quick_symbol_functions::map_symtabs_matching_filename)
14132 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
14133 function_view as callback type and return bool.
14134 (expand_symtabs_matching): Adjust to use function_view as callback
14136 (maintenance_expand_name_matcher)
14137 (maintenance_expand_file_matcher): Delete.
14138 (maintenance_expand_symtabs): Use lambdas.
14139 * symtab.c (iterate_over_some_symtabs): Adjust to use
14140 function_view as callback types and return bool.
14141 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
14143 (lookup_symtab_callback): Delete.
14144 (lookup_symtab): Use a lambda.
14145 (iterate_over_symbols): Adjust to use function_view as callback
14147 (struct search_symbols_data, search_symbols_file_matches)
14148 (search_symbols_name_matches): Delete.
14149 (search_symbols): Use a pair of lambdas.
14150 (struct add_name_data, add_macro_name, symbol_completion_matcher)
14151 (symtab_expansion_callback): Delete.
14152 (default_make_symbol_completion_list_break_on_1): Use lambdas.
14153 * symtab.h: Include "common/function-view.h".
14154 (iterate_over_some_symtabs): Adjust to use function_view as
14155 callback type and return bool.
14156 (iterate_over_symtabs): Adjust to use function_view as callback
14158 (symbol_found_callback_ftype): Remove 'data' parameter and return
14160 (iterate_over_symbols): Adjust to use function_view as callback
14163 2017-02-23 Pedro Alves <palves@redhat.com>
14165 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
14166 (%.o) <unittests/%.c>: New pattern.
14167 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
14168 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
14169 * common/function-view.h: New file.
14170 * unittests/function-view-selftests.c: New file.
14171 * configure: Regenerate.
14173 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
14175 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
14177 * go32-nat.c (go32_thread_alive): Likewise.
14179 2017-02-23 Yao Qi <yao.qi@linaro.org>
14181 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
14184 2017-02-23 Yao Qi <yao.qi@linaro.org>
14186 * varobj.c (varobj_clear_saved_item): Use delete instead of
14188 (update_dynamic_varobj_children): Likewise.
14190 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
14192 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
14194 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
14196 * common/enum-flags.h (enum_flags::enum_flags): Initialize
14197 m_enum_value to 0 in default constructor.
14199 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
14201 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
14202 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
14203 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
14204 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
14205 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
14206 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
14207 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
14208 IS_STORE_CONDITIONAL_INSN.
14210 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
14212 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
14214 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14216 * NEWS (Changes since GDB 7.12): Add DWARF-5.
14218 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14220 * dwarf2read.c (skip_one_die, read_attribute_value)
14221 (dwarf2_const_value_attr, dump_die_shallow)
14222 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
14223 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
14225 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14227 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
14228 (dwarf_parse_macro_header): Accept DWARF version 5.
14229 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
14231 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14233 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
14235 * common/common-exceptions.h (enum errors): Likewise.
14236 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
14237 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
14238 (dwarf_expr_context::execute_stack_op): Likewise.
14239 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
14241 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
14242 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
14243 (show_entry_values_debug, call_site_to_target_addr)
14244 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
14245 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
14246 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
14247 (value_of_dwarf_block_entry, indirect_pieced_value)
14248 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
14249 (disassemble_dwarf_expression): Likewise.
14250 * dwarf2read.c (process_die, inherit_abstract_dies)
14251 (read_call_site_scope): Likewise.
14252 * gdbtypes.h (struct func_type, struct call_site_parameter)
14253 (struct call_site): Likewise.
14254 * stack.c (read_frame_arg): Likewise.
14255 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
14257 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14259 * defs.h (read_unsigned_leb128): New declaration.
14260 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
14261 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
14262 (dwarf2_find_location_expression): Call also
14263 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
14264 * dwarf2loc.h (dwarf2_version): New declaration.
14265 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
14267 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
14269 (struct dwop_section_names): Add loclists_dwo.
14270 (dwop_section_names): Add .debug_loclists.dwo.
14271 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
14272 (struct dwarf2_per_cu_data): Add dwarf_version.
14273 (struct dwo_sections): Add loclists.
14274 (struct attr_abbrev): Add implicit_const.
14275 (read_indirect_line_string): New declaration.
14276 (read_unsigned_leb128): Delete declaration.
14277 (rcuh_kind): New definition.
14278 (read_and_check_comp_unit_head): Change parameter
14279 is_debug_types_section to section_kind.
14280 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
14281 (read_comp_unit_head): Change parameter abfd to section, add parameter
14282 section_kind. Handle DWARF-5.
14283 (error_check_comp_unit_head): Accept also DWARF version 5.
14284 (read_and_check_comp_unit_head): Change parameter
14285 is_debug_types_section to section_kind.
14286 (read_and_check_type_unit_head): Delete function.
14287 (read_abbrev_offset): Handle DWARF-5.
14288 (create_debug_type_hash_table): Add parameter section_kind. Process
14289 only DW_UT_type. Use signature and type_offset_in_tu from struct
14291 (create_debug_types_hash_table): Update create_debug_type_hash_table
14293 (create_all_type_units): Call create_debug_type_hash_table.
14294 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
14295 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
14297 (skip_one_die): Handle DW_FORM_implicit_const.
14298 (dwarf2_rnglists_process): New function.
14299 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
14300 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
14301 (read_attribute_value): Handle DW_FORM_implicit_const,
14303 (read_attribute): Handle DW_FORM_implicit_const.
14304 (read_indirect_string_at_offset_from): New function from
14305 read_indirect_string_at_offset.
14306 (read_indirect_string_at_offset): Call
14307 read_indirect_string_at_offset_from.
14308 (read_indirect_line_string_at_offset): New function.
14309 (read_indirect_string): New function comment.
14310 (read_indirect_line_string): New function.
14311 (read_unsigned_leb128): Make it global.
14312 (dwarf2_string_attr): Handle DWARF-5.
14313 (add_include_dir_stub, read_formatted_entries): New functions.
14314 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
14316 (per_cu_header_read_in): Update read_comp_unit_head caller.
14317 (dwarf2_version): New function.
14318 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
14320 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
14323 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14325 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
14327 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14329 * dwarf2read.c (dwarf2_ranges_process): New function from
14330 dwarf2_ranges_read.
14331 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
14332 dwarf2_ranges_process.
14334 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
14336 * dwarf2read.c (create_debug_type_hash_table): New function from
14337 create_debug_types_hash_table.
14338 (create_debug_types_hash_table): Call create_debug_type_hash_table.
14339 (create_all_type_units, open_and_init_dwo_file): Update
14340 create_debug_types_hash_table callers.
14342 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
14345 * fork-child.c (trace_start_error): Fix thinko. va_end should
14346 refer to 'ap', not 'args'.
14348 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
14349 Pedro Alves <palves@redhat.com>
14352 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
14354 * fork-child.c (trace_start_error): New function.
14355 (trace_start_error_with_name): Likewise.
14356 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
14357 * inf-ptrace.c (inf_ptrace_me): Likewise.
14358 * inferior.h (trace_start_error): New prototype.
14359 (trace_start_error_with_name): Likewise.
14361 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
14364 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
14365 NULL before using it.
14366 * symmisc.c (maintenance_print_symbols): Likewise.
14367 (maintenance_print_msymbols): Likewise.
14369 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14371 * NEWS: Add record Python bindings entry.
14373 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14375 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
14377 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
14378 * python/py-record-btrace.c, python/py-record-btrace.h,
14379 python/py-record-full.c, python/py-record-full.h: New file.
14380 * python/py-record.c: Add include for py-record-btrace.h and
14382 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
14383 recpy_instruction_history, recpy_function_call_history, recpy_begin,
14384 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
14385 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
14387 (gdbpy_initialize_btrace): New export.
14388 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
14390 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14392 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
14393 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
14394 * python/py-record.c: New file.
14395 * python/python-internal.h (gdbpy_start_recording,
14396 gdbpy_current_recording, gdpy_stop_recording,
14397 gdbpy_initialize_record): New export.
14398 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
14399 (python_GdbMethods): Add gdbpy_start_recording,
14400 gdbpy_current_recording and gdbpy_stop_recording.
14402 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14404 * record-btrace.c (record_btrace_record_method): New function.
14405 (init_record_btrace_ops): Initialize to_record_method.
14406 * record-full.c (record_full_record_method): New function.
14407 (init_record_full_ops, init_record_full_core_ops): Add
14408 record_full_record_method.
14409 * record.h (enum record_method): New enum.
14410 * target-debug.h (target_debug_print_enum_record_method: New define.
14411 * target-delegates.c: Regenerate.
14412 * target.c (target_record_method): New function.
14413 * target.h: Include record.h.
14414 (struct target_ops) <to_record_method>: New field.
14415 (target_record_method): New export.
14417 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14419 * record.h (record_start, record_stop): New export.
14420 * record.c (record_start, record_stop): New function.
14422 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14424 * btrace.c (btrace_fetch): Copy function call segments pointer
14426 (btrace_clear): Clear the vector.
14427 (btrace_find_insn_by_number): Use binary search to find the correct
14428 function call segment.
14429 * btrace.h (brace_fun_p): New typedef.
14430 (struct btrace_thread_info) <functions>: New field.
14432 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14434 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
14435 * btrace.c (btrace_decode_error): ... here. New function.
14436 * btrace.h (btrace_decode_error): New export.
14438 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14440 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
14441 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
14442 btrace_find_insn_by_number): Remove special case for gaps.
14443 * btrace.h (btrace_insn_get_error): New export.
14444 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
14445 * record-btrace.c (btrace_insn_history): Print number for gaps.
14446 (record_btrace_info, record_btrace_goto): Handle gaps.
14448 2017-02-14 Tom Tromey <tom@tromey.com>
14451 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
14453 * python/py-evts.c (gdbpy_initialize_py_events): Add
14454 before_prompt registry.
14455 * python/py-events.h (events_object) <before_prompt>: New field.
14457 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
14459 * btrace.c (ftrace_new_switch): Preserve up link and flags.
14461 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
14463 * symfile (_initialize_symfile): Add usage text to the load command's
14466 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
14468 * utils.c (defaulted_query): Don't query on secondary UIs.
14470 2017-02-10 Tom Tromey <tom@tromey.com>
14472 * rust-lang.c (rust_get_disr_info): Remove unused variable.
14474 2017-02-10 Tom Tromey <tom@tromey.com>
14476 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
14478 * python/py-type.c (typy_legacy_template_argument): Remove
14479 unnecessary "cleanup" local.
14481 2017-02-10 Tom Tromey <tom@tromey.com>
14483 * python/python.c (do_start_initialization): New function, from
14484 _initialize_python.
14485 (_initialize_python): Call do_start_initialization.
14486 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
14489 2017-02-10 Tom Tromey <tom@tromey.com>
14491 * python/py-prettyprint.c (pretty_print_one_value): Use
14494 2017-02-10 Tom Tromey <tom@tromey.com>
14496 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
14497 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
14499 * python/py-type.c (field_new): Use gdbpy_ref.
14500 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
14502 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
14503 (py_free_pspace): Likewise.
14504 (pspace_to_pspace_object): Likewise.
14505 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
14506 (py_free_objfile): Likewise.
14507 (objfile_to_objfile_object): Likewise.
14508 * python/py-inferior.c (delete_thread_object): Use
14510 (infpy_read_memory): Likewise.
14511 (py_free_inferior): Likewise.
14512 * python/py-evtregistry.c (create_eventregistry_object): Use
14514 * python/py-event.c (create_event_object): Use gdbpy_ref.
14516 2017-02-10 Tom Tromey <tom@tromey.com>
14518 * python/py-ref.h (gdbpy_ref_policy): Now a template.
14519 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
14521 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
14522 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
14523 python/py-exitedevent.c, python/py-finishbreakpoint.c,
14524 python/py-framefilter.c, python/py-function.c,
14525 python/py-inferior.c, python/py-infevents.c,
14526 python/py-linetable.c, python/py-newobjfileevent.c,
14527 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
14528 python/py-signalevent.c, python/py-stopevent.c,
14529 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
14530 python/py-unwind.c, python/py-utils.c, python/py-value.c,
14531 python/py-varobj.c, python/py-xmethods.c, python/python.c,
14532 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
14534 2017-02-10 Tom Tromey <tom@tromey.com>
14536 * ui-out.h (ui_out_emit_type): New class.
14537 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
14538 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
14539 and ui_out_emit_tuple.
14540 (enumerate_locals): Likewise.
14541 (py_mi_print_variables, py_print_locals, py_print_args): Use
14543 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
14545 * common/gdb_optional.h: New file.
14547 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
14549 * MAINTAINERS (Write After Approval): Update my e-mail address.
14551 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
14554 * breakpoint.c (_initialize_breakpoint): Update the help description
14555 of the 'commands' command to indicate that it takes a list argument.
14557 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
14559 * interps.c (current_interp_set_logging): Remove "return".
14561 2017-02-09 Gary Benson <gbenson@redhat.com>
14563 * symtab.c (add_symtab_completions): Prevent NULL pointer
14566 2017-02-08 Pedro Alves <palves@redhat.com>
14568 * interps.c (interp::interp): Remove reference to quiet_p.
14569 (interp_set): Make static. Remove dead "Switching to" output
14571 (interp_quiet_p, interp_set_quiet): Delete.
14572 (interpreter_exec_cmd): Don't set the interpreter quiet.
14573 * interps.h (interp_quiet_p): Make static.
14574 (class interp) <quiet_p>: Remove field
14576 2017-02-08 Jerome Guitton <guitton@adacore.com>
14578 * cli/cli-decode.c (find_command_name_length): Make it extern.
14579 * cli/cli-decode.h (find_command_name_length): Declare.
14580 * cli/cli-script.c (command_name_equals, line_first_arg):
14582 (process_next_line): Use cli-decode to parse command names.
14583 (build_command_line): Make args a constant pointer.
14585 2017-02-08 Jerome Guitton <guitton@adacore.com>
14587 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
14588 Remove case-insensitive search.
14590 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
14592 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
14593 at the end of the line. Avoids an ARI warning.
14595 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
14597 * NEWS: Mention support for record/replay of Intel 64 rdrand and
14598 rdseed instructions.
14599 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
14601 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
14604 Provide and use sparc32 and sparc64 target description XML files.
14605 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
14606 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
14607 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
14608 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
14609 * features/sparc/sparc32-solaris.xml: New file.
14610 * features/sparc/sparc64-solaris.xml: New file.
14611 * features/sparc/sparc32-solaris.c: Generated.
14612 * features/sparc/sparc64-solaris.c: Generated.
14613 * sparc-tdep.h: Account for differences in target descriptions.
14614 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
14615 (sparc32_register_type): Use target provided registers.
14616 (validate_tdesc_registers): New function.
14617 (sparc32_gdbarch_init): Use tdesc_has_registers.
14618 Set pseudoregister functions.
14619 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
14620 (sparc64_register_type): Use target provided registers.
14621 (sparc64_init_abi): Set pseudoregister functions.
14623 2017-02-03 Tom Tromey <tom@tromey.com>
14626 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
14627 with a single member.
14629 2017-02-03 Pedro Alves <palves@redhat.com>
14631 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
14632 (cli_interp_base::~cli_interp_base): New.
14633 (cli_interp): New struct.
14634 (as_cli_interp): Cast the interp itself to cli_interp.
14635 (cli_interpreter_pre_command_loop): Rename to ...
14636 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
14638 (cli_interpreter_init): Rename to ...
14639 (cli_interp::init): ... this. Remove 'self' parameter. Use
14640 boolean. Make extern.
14641 (cli_interpreter_resume): Rename to ...
14642 (cli_interp::resume): ... this. Remove 'data' parameter. Make
14644 (cli_interpreter_suspend): Rename to ...
14645 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
14647 (cli_interpreter_exec): Rename to ...
14648 (cli_interp::exec): ... this. Remove 'data' parameter. Make
14650 (cli_interpreter_supports_command_editing): Rename to ...
14651 (cli_interp_base::supports_command_editing): ... this. Remove
14652 'interp' parameter. Make extern.
14653 (cli_ui_out): Rename to ...
14654 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
14656 (cli_set_logging): Rename to ...
14657 (cli_interp_base::set_logging): ... this. Remove 'interp'
14658 parameter. Make extern.
14659 (cli_interp_procs): Delete.
14660 (cli_interp_factory): Adjust to use "new".
14661 * cli/cli-interp.h: Include "interps.h".
14662 (struct cli_interp_base): New struct.
14663 * interps.c (struct interp): Delete. Fields moved to interps.h.
14664 (interp_new): Delete.
14665 (interp::interp, interp::~interp): New.
14666 (interp_set): Use bool, and return void. Assume the interpreter
14667 has suspend, init and resume methods, and that the all return
14669 (set_top_level_interpreter): interp_set returns void.
14670 (interp_ui_out): Adapt.
14671 (current_interp_set_logging): Adapt.
14672 (interp_data): Delete.
14673 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
14674 (interp_exec): Adapt.
14675 (top_level_interpreter_data): Delete.
14676 * interps.h (interp_init_ftype, interp_resume_ftype)
14677 (interp_suspend_ftype, interp_exec_ftype)
14678 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
14679 (class interp): New.
14680 (interp_new): Delete.
14681 (interp_set): Now returns void. Use bool.
14682 (interp_data, top_level_interpreter_data): Delete.
14683 * mi/mi-common.h: Include interps.h.
14684 (class mi_interp): Inherit from interp. Define a ctor. Declare
14685 init, resume, suspect, exec, interp_ui_out, set_logging and
14686 pre_command_loop methods.
14687 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
14688 (mi_interpreter_init): Rename to ...
14689 (mi_interp::init): ... this. Remove the 'interp' parameter, use
14690 bool, return void and make extern. Adjust.
14691 (mi_interpreter_resume): ... Rename to ...
14692 (mi_interp::resume): ... this. Remove the 'data' parameter,
14693 return void and make extern. Adjust.
14694 (mi_interpreter_suspend): ... Rename to ...
14695 (mi_interp::suspend): ... this. Remove the 'data' parameter,
14696 return void and make extern. Adjust.
14697 (mi_interpreter_exec): ... Rename to ...
14698 (mi_interp::exec): ... this. Remove the 'data' parameter and make
14700 (mi_interpreter_pre_command_loop): ... Rename to ...
14701 (mi_interp::pre_command_loop): ... this. Remove the 'self'
14702 parameter and make extern.
14703 (mi_on_normal_stop_1): Adjust.
14704 (mi_ui_out): Rename to ...
14705 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
14706 parameter and make extern. Adjust.
14707 (mi_set_logging): Rename to ...
14708 (mi_interp::set_logging): ... this. Remove the 'interp'
14709 parameter and make extern. Adjust.
14710 (mi_interp_procs): Delete.
14711 (mi_interp_factory): Adjust to use 'new'.
14712 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
14713 (mi_print_exception, mi_execute_command, mi_load_progress):
14715 * tui/tui-interp.c (tui_interp): New class.
14716 (as_tui_interp): Return a tui_interp pointer.
14717 (tui_on_normal_stop, tui_on_signal_received)
14718 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
14719 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
14720 to use interp::interp_ui_out.
14721 (tui_init): Rename to ...
14722 (tui_interp::init): ... this. Remove the 'self' parameter, use
14723 bool, return void and make extern. Adjust.
14724 (tui_resume): Rename to ...
14725 (tui_interp::resume): ... this. Remove the 'data' parameter,
14726 return void and make extern. Adjust.
14727 (tui_suspend): Rename to ...
14728 (tui_interp::suspend): ... this. Remove the 'data' parameter,
14729 return void and make extern. Adjust.
14730 (tui_ui_out): Rename to ...
14731 (tui_interp::interp_ui_out): ... this. Remove the 'self'
14732 parameter, and make extern. Adjust.
14733 (tui_exec): Rename to ...
14734 (tui_interp::exec): ... this. Remove the 'data' parameter and
14736 (tui_interp_procs): Delete.
14737 (tui_interp_factory): Use "new".
14739 2017-02-02 Tom Tromey <tom@tromey.com>
14741 * rust-exp.y (ends_raw_string, space_then_number)
14742 (rust_identifier_start_p): Return bool.
14743 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
14744 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
14745 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
14746 (rust_chartype_p): Return bool.
14747 (val_print_struct, rust_print_struct_def, rust_print_type):
14749 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
14752 2017-02-02 Tom Tromey <tom@tromey.com>
14754 * rust-lang.c: Reindent.
14756 2017-02-02 Tom Tromey <tom@tromey.com>
14758 * rust-lang.h (rust_crate_for_block): Update.
14759 * rust-lang.c (rust_crate_for_block): Return std::string.
14760 (rust_get_disr_info): Use std:;string, not
14761 gdb::unique_xmalloc_ptr.
14762 * rust-exp.y (crate_name): Update.
14764 2017-02-02 Pedro Alves <palves@redhat.com>
14766 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
14767 field out of gdb_disassembler_test and make it static.
14769 2017-02-02 Pedro Alves <palves@redhat.com>
14771 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
14772 mi1_interp and mi_interp fields.
14774 2017-02-02 Pedro Alves <palves@redhat.com>
14776 * cli/cli-interp.c (struct saved_output_files, saved_output):
14777 Moved from cli/cli-logging.c.
14778 (cli_set_logging): New function.
14779 (cli_interp_procs): Install cli_set_logging.
14780 * cli/cli-interp.h (make_logging_output, cli_set_logging):
14782 * cli/cli-logging.c (struct saved_output_files, saved_output):
14783 Moved to cli/cli-interp.c.
14784 (pop_output_files): Don't save outputs here.
14785 (make_logging_output): New function.
14786 (handle_redirections): Don't build tee nor save previous outputs
14788 * interps.c (current_interp_set_logging): Change prototype.
14789 Assume there's always a set_logging_proc method installed.
14790 * interps.h (interp_set_logging_ftype): Change prototype.
14791 (current_interp_set_logging): Change prototype and adjust comment.
14792 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
14793 use make_logging_output.
14794 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
14795 2017-02-02 Pedro Alves <palves@redhat.com>
14797 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
14799 (set_logging_overwrite): ... here.
14800 (logging_no_redirect_file): Delete.
14801 (set_logging_redirect): Don't handle redirection on the fly.
14802 Instead warn that "logging off" / "logging on" is necessary.
14803 (pop_output_files): Delete references to logging_no_redirect_file.
14804 (show_logging_command): Always speak in terms of what will happen
14805 once logging is reenabled.
14807 2017-02-02 Pedro Alves <palves@redhat.com>
14809 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
14811 2017-02-02 Pedro Alves <palves@redhat.com>
14813 * disasm.c (gdb_pretty_print_insn): Rename to ...
14814 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
14815 Remove gdbarch parameter. Adapt to clear the object's buffers
14816 instead of allocating new buffers, and to print using the object's
14817 gdb_disassembler instead of calling gdb_print_insn.
14818 (dump_insns): Use gdb_pretty_print_disassembler.
14819 * disasm.h (gdb_pretty_print_insn): Delete declaration.
14820 (gdb_pretty_print_disassembler): New class.
14821 * record-btrace.c (btrace_insn_history): Use
14822 gdb_pretty_print_disassembler.
14824 2017-02-02 Pedro Alves <palves@redhat.com>
14826 * ada-lang.c (type_as_string): Use string_file.
14827 * ada-valprint.c (ada_print_floating): Use string_file.
14828 * ada-varobj.c (ada_varobj_scalar_image)
14829 (ada_varobj_get_value_image): Use string_file.
14830 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
14831 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
14832 * breakpoint.c (update_inserted_breakpoint_locations)
14833 (insert_breakpoint_locations, reattach_breakpoints)
14834 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
14835 (print_it_watchpoint): Use string_file.
14836 (save_breakpoints): Use stdio_file.
14837 * c-exp.y (oper): Use string_file.
14838 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
14840 (pop_output_files): Use delete.
14841 (handle_redirections): Use stdio_file and tee_file.
14842 * cli/cli-setshow.c (do_show_command): Use string_file.
14843 * compile/compile-c-support.c (c_compute_program): Use
14845 * compile/compile-c-symbols.c (generate_vla_size): Take a
14846 'string_file &' instead of a 'ui_file *'.
14847 (generate_c_for_for_one_variable): Take a 'string_file &' instead
14848 of a 'ui_file *'. Use string_file.
14849 (generate_c_for_variable_locations): Take a 'string_file &'
14850 instead of a 'ui_file *'.
14851 * compile/compile-internal.h (generate_c_for_for_one_variable):
14852 Take a 'string_file &' instead of a 'ui_file *'.
14853 * compile/compile-loc2c.c (push, pushf, unary, binary)
14854 (print_label, pushf_register_address, pushf_register)
14855 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
14856 'ui_file *'. Adjust.
14857 * compile/compile.c (compile_to_object): Use string_file.
14858 * compile/compile.h (compile_dwarf_expr_to_c)
14859 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
14861 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
14862 (replace_typedefs_qualified_name): Use string_file and
14864 * disasm.c (gdb_pretty_print_insn): Use string_file.
14865 (gdb_disassembly): Adjust reference the null_stream global.
14866 (do_ui_file_delete): Delete.
14867 (gdb_insn_length): Use null_stream.
14868 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
14869 * dwarf2loc.c (dwarf2_compile_property_to_c)
14870 (locexpr_generate_c_location, loclist_generate_c_location): Take a
14871 'string_file &' instead of a 'ui_file *'.
14872 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
14873 * dwarf2read.c (do_ui_file_peek_last): Delete.
14874 (dwarf2_compute_name): Use string_file.
14875 * event-top.c (gdb_setup_readline): Use stdio_file.
14876 * gdbarch.sh (verify_gdbarch): Use string_file.
14877 * gdbtypes.c (safe_parse_type): Use null_stream.
14878 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
14880 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
14881 'string_file *' instead of a 'ui_file *'.
14882 (gdbscm_arch_disassemble): Use string_file.
14883 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
14884 * guile/scm-ports.c (class ioscm_file_port): Now a class that
14885 inherits from ui_file.
14886 (ioscm_file_port_delete, ioscm_file_port_rewind)
14887 (ioscm_file_port_put): Delete.
14888 (ioscm_file_port_write): Rename to ...
14889 (ioscm_file_port::write): ... this. Remove file_port_magic
14891 (ioscm_file_port_new): Delete.
14892 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
14894 * guile/scm-type.c (tyscm_type_name): Use string_file.
14895 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
14897 * infcmd.c (print_return_value_1): Use string_file.
14898 * infrun.c (print_target_wait_results): Use string_file.
14899 * language.c (add_language): Use string_file.
14900 * location.c (explicit_to_string_internal): Use string_file.
14901 * main.c (captured_main_1): Use null_file.
14902 * maint.c (maintenance_print_architecture): Use stdio_file.
14903 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
14904 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
14905 event_channel>: Change type to mi_console_file pointer.
14906 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
14907 (mi_console_file_delete): Delete.
14908 (struct mi_console_file): Delete.
14909 (mi_console_file_magic): Delete.
14910 (mi_console_file_new): Delete.
14911 (mi_console_file::mi_console_file): New.
14912 (mi_console_file_delete): Delete.
14913 (mi_console_file_fputs): Delete.
14914 (mi_console_file::write): New.
14915 (mi_console_raw_packet): Delete.
14916 (mi_console_file::flush): New.
14917 (mi_console_file_flush): Delete.
14918 (mi_console_set_raw): Rename to ...
14919 (mi_console_file::set_raw): ... this.
14920 * mi/mi-console.h (class mi_console_file): New class.
14921 (mi_console_file_new, mi_console_set_raw): Delete.
14922 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
14923 (mi_set_logging): Use delete and tee_file. Adjust.
14924 * mi/mi-main.c (output_register): Use string_file.
14925 (mi_cmd_data_evaluate_expression): Use string_file.
14926 (mi_cmd_data_read_memory): Use string_file.
14927 (mi_cmd_execute, print_variable_or_computed): Use string_file.
14928 * mi/mi-out.c (mi_ui_out::main_stream): New.
14929 (mi_ui_out::rewind): Use main_stream and
14931 (mi_ui_out::put): Use main_stream and string_file.
14932 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14933 Allocate a 'string_file' instead.
14934 (mi_out_new): Don't allocate a mem_fileopen stream here.
14935 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14936 (mi_ui_out::main_stream): Declare method.
14937 * printcmd.c (eval_command): Use string_file.
14938 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
14939 * python/py-arch.c (archpy_disassemble): Use string_file.
14940 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
14941 * python/py-frame.c (frapy_str): Use string_file.
14942 * python/py-framefilter.c (py_print_type, py_print_single_arg):
14944 * python/py-type.c (typy_str): Use string_file.
14945 * python/py-unwind.c (unwind_infopy_str): Use string_file.
14946 * python/py-value.c (valpy_str): Use string_file.
14947 * record-btrace.c (btrace_insn_history): Use string_file.
14948 * regcache.c (regcache_print): Use stdio_file.
14949 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
14950 * remote.c (escape_buffer): Use string_file.
14951 * rust-lang.c (rust_get_disr_info): Use string_file.
14952 * serial.c (serial_open_ops_1): Use stdio_file.
14953 (do_serial_close): Use delete.
14954 * stack.c (print_frame_arg): Use string_file.
14955 (print_frame_args): Remove local mem_fileopen stream, not used.
14956 (print_frame): Use string_file.
14957 * symmisc.c (maintenance_print_symbols): Use stdio_file.
14958 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
14959 Take a 'string_file *' instead of a 'ui_file *'.
14960 * top.c (new_ui): Use stdio_file and stderr_file.
14961 (free_ui): Use delete.
14962 (execute_command_to_string): Use string_file.
14963 (quit_confirm): Use string_file.
14964 * tracepoint.c (collection_list::append_exp): Use string_file.
14965 * tui/tui-disasm.c (tui_disassemble): Use string_file.
14966 * tui/tui-file.c: Don't include "ui-file.h".
14967 (enum streamtype, struct tui_stream): Delete.
14968 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
14969 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
14970 (tui_file::tui_file): New method.
14971 (tui_file_fputs): Delete.
14972 (tui_file_get_strbuf): Delete.
14973 (tui_file::puts): New method.
14974 (tui_file_adjust_strbuf): Delete.
14975 (tui_file_flush): Delete.
14976 (tui_file::flush): New method.
14977 * tui/tui-file.h: Tweak intro comment.
14979 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
14980 (tui_file_adjust_strbuf): Delete declarations.
14981 (class tui_file): New class.
14982 * tui/tui-io.c (tui_initialize_io): Use tui_file.
14983 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
14984 (tui_register_format): Use string_stream.
14985 * tui/tui-stack.c (tui_make_status_line): Use string_file.
14986 (tui_get_function_from_frame): Use string_file.
14987 * typeprint.c (type_to_string): Use string_file.
14988 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
14989 (null_stream): New global.
14990 (ui_file_delete): Delete.
14991 (ui_file::ui_file): New.
14992 (null_file_isatty): Delete.
14993 (ui_file::~ui_file): New.
14994 (null_file_rewind): Delete.
14995 (ui_file::printf): New.
14996 (null_file_put): Delete.
14997 (null_file_flush): Delete.
14998 (ui_file::putstr): New.
14999 (null_file_write): Delete.
15000 (ui_file::putstrn): New.
15001 (null_file_read): Delete.
15002 (ui_file::putc): New.
15003 (null_file_fputs): Delete.
15004 (null_file_write_async_safe): Delete.
15005 (ui_file::vprintf): New.
15006 (null_file_delete): Delete.
15007 (null_file::write): New.
15008 (null_file_fseek): Delete.
15009 (null_file::puts): New.
15010 (ui_file_data): Delete.
15011 (null_file::write_async_safe): New.
15012 (gdb_flush, ui_file_isatty): Adjust.
15013 (ui_file_put, ui_file_rewind): Delete.
15014 (ui_file_write): Adjust.
15015 (ui_file_write_for_put): Delete.
15016 (ui_file_write_async_safe, ui_file_read): Adjust.
15017 (ui_file_fseek): Delete.
15018 (fputs_unfiltered): Adjust.
15019 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
15020 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
15021 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
15022 (set_ui_file_data): Delete.
15023 (string_file::~string_file, string_file::write)
15024 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
15025 (do_ui_file_as_string, ui_file_as_string): Delete.
15026 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
15027 (struct mem_file): Delete.
15028 (mem_file_new): Delete.
15029 (stdio_file::stdio_file): New.
15030 (mem_file_delete): Delete.
15031 (stdio_file::stdio_file): New.
15032 (mem_fileopen): Delete.
15033 (stdio_file::~stdio_file): New.
15034 (mem_file_rewind): Delete.
15035 (stdio_file::set_stream): New.
15036 (mem_file_put): Delete.
15037 (stdio_file::open): New.
15038 (mem_file_write): Delete.
15039 (stdio_file_magic, struct stdio_file): Delete.
15040 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
15041 (stdio_file::flush): New.
15042 (stdio_file_read): Rename to ...
15043 (stdio_file::read): ... this. Adjust.
15044 (stdio_file_write): Rename to ...
15045 (stdio_file::write): ... this. Adjust.
15046 (stdio_file_write_async_safe): Rename to ...
15047 (stdio_file::write_async_safe) ... this. Adjust.
15048 (stdio_file_fputs): Rename to ...
15049 (stdio_file::puts) ... this. Adjust.
15050 (stdio_file_isatty): Delete.
15051 (stdio_file_fseek): Delete.
15052 (stdio_file::isatty): New.
15053 (stderr_file_write): Rename to ...
15054 (stderr_file::write) ... this. Adjust.
15055 (stderr_file_fputs): Rename to ...
15056 (stderr_file::puts) ... this. Adjust.
15057 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
15058 (stderr_file::stderr_file): New.
15059 (tee_file_magic): Delete.
15060 (struct tee_file): Delete.
15061 (tee_file::tee_file): New.
15062 (tee_file_new): Delete.
15063 (tee_file::~tee_file): New.
15064 (tee_file_delete): Delete.
15065 (tee_file_flush): Rename to ...
15066 (tee_file::flush): ... this. Adjust.
15067 (tee_file_write): Rename to ...
15068 (tee_file::write): ... this. Adjust.
15069 (tee_file::write_async_safe): New.
15070 (tee_file_fputs): Rename to ...
15071 (tee_file::puts): ... this. Adjust.
15072 (tee_file_isatty): Rename to ...
15073 (tee_file::isatty): ... this. Adjust.
15074 * ui-file.h (struct obstack, struct ui_file): Don't
15076 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
15077 (ui_file_write_ftype)
15078 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
15079 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
15080 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
15081 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
15082 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
15083 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
15084 (set_ui_file_fseek): Delete.
15085 (ui_file_data, ui_file_delete, ui_file_rewind)
15086 (struct ui_file): New.
15088 (class null_file): New.
15089 (null_stream): Declare.
15090 (ui_file_write_for_put, ui_file_put): Delete.
15091 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
15093 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
15094 (gdb_fopen, tee_file_new): Delete.
15095 (struct string_file): New.
15096 (struct stdio_file): New.
15097 (stdio_file_up): New.
15098 (struct stderr_file): New.
15099 (class tee_file): New.
15100 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
15101 of a 'ui_file *'. Adjust.
15102 * ui-out.h (class ui_out) <field_stream>: Likewise.
15103 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
15104 (null_stream): Delete.
15105 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
15107 * utils.h (struct ui_file): Delete forward declaration..
15108 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
15109 (error_stream): Take a 'string_file &' instead of a
15111 * varobj.c (varobj_value_get_print_value): Use string_file.
15112 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
15113 * gdbarch.c: Regenerate.
15115 2017-02-02 Pedro Alves <palves@redhat.com>
15117 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
15118 (gdb_pretty_print_insn): ... this. Now a free function. Add back
15119 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
15120 Adjust to call gdb_print_insn instead of
15121 gdb_disassembler::print_insn.
15122 (dump_insns, do_mixed_source_and_assembly_deprecated)
15123 (do_mixed_source_and_assembly, do_assembly_only): Add back a
15124 'gdbarch' parameter. Remove gdb_disassembler parameter.
15125 (gdb_disassembly): Don't allocate a gdb_disassembler here.
15126 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
15128 (gdb_pretty_print_insn): Re-add declaration.
15129 * record-btrace.c (btrace_insn_history): Don't allocate a
15130 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
15132 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
15134 * disasm.h (gdb_disassembly): Remove file_string parameter.
15135 * disasm.c (gdb_disassembly): Likewise.
15136 * cli/cli-cmds.c (print_disassembly): Adapt.
15137 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
15138 * stack.c (do_gdb_disassembly): Likewise.
15140 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
15142 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
15143 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
15144 targets. And if the implicit value is longer than needed, extract
15145 the first bytes instead of the "least significant" ones.
15147 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
15149 * btrace.c (btrace_enable): Do not call btrace_add_pc for
15150 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
15151 (btrace_fetch): Assert can_access_registers_ptid.
15152 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
15153 validate_registers_access.
15155 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
15157 * gdbthread.h (can_access_registers_ptid): New.
15158 * thread.c (can_access_registers_ptid): New.
15160 2017-02-01 Pedro Alves <palves@redhat.com>
15162 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
15164 2017-01-31 Pedro Alves <palves@redhat.com>
15166 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
15169 2017-01-31 Pedro Alves <palves@redhat.com>
15171 * stack.c (print_frame_args): Remove local mem_fileopen stream,
15174 2017-01-31 Pedro Alves <palves@redhat.com>
15176 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
15178 2017-01-31 Pedro Alves <palves@redhat.com>
15180 * common/scoped_restore.h
15181 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
15182 change the value's parameter type to T2.
15183 (make_scoped_restore): Likewise.
15185 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
15186 Richard Henderson <rth@redhat.com>
15188 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
15189 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
15190 GS_BASE for older kernels.
15191 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
15192 GS_BASE for older kernels.
15193 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
15194 and GS_BASE to the offset table.
15195 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
15196 system register group.
15197 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
15199 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
15201 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
15202 AMD64_GSBASE_REGNUM.
15203 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
15204 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
15205 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
15206 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
15207 i386/64bit-segments.xml in those rules.
15208 * features/i386/64bit-segments.xml: New file.
15209 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
15210 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
15211 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
15212 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
15213 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
15214 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
15215 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
15216 * features/i386/amd64-avx-linux.c: Regenerated.
15217 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
15218 * features/i386/amd64-avx-mpx.c: Regenerated.
15219 * features/i386/amd64-avx512-linux.c: Regenerated.
15220 * features/i386/amd64-linux.c: Regenerated.
15221 * features/i386/amd64-mpx-linux.c: Regenerated.
15222 * features/i386/i386-avx-mpx-linux.c: Regenerated.
15223 * features/i386/i386-avx-mpx.c: Regenerated.
15224 * features/i386/x32-avx-linux.c: Regenerated.
15225 * features/i386/x32-avx512-linux.c: Regenerated.
15226 * regformats/i386/amd64-avx-linux.dat: Regenerated.
15227 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
15228 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
15229 * regformats/i386/amd64-linux.dat: Regenerated.
15230 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
15231 * regformats/i386/x32-avx-linux.dat: Regenerated.
15232 * regformats/i386/x32-avx512-linux.dat: Regenerated.
15233 * regformats/i386/x32-linux.dat: Regenerated.
15235 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
15237 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
15238 Set to AMD64_NUM_REGS.
15240 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
15242 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
15243 that checks validity of a register number.
15245 2017-01-27 Kees Cook <keescook@google.com>
15247 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
15248 fetch_fpregs if target has fpa registers.
15249 (arm_linux_store_inferior_registers): Call store_fpregs if target
15252 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
15254 * cris-tdep.c (cris_gdbarch_init): Remove check for
15255 info.byte_order and force it to BFD_ENDIAN_LITTLE.
15257 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
15259 * corelow.c (get_core_register_section): Check for regset
15260 existence before checking for REGSET_VARIABLE_SIZE.
15262 2017-01-26 Yao Qi <yao.qi@linaro.org>
15263 Pedro Alves <palves@redhat.com>
15266 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
15267 call memory_error, save memaddr instead.
15268 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
15269 negative, cal memory_error.
15270 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
15272 2017-01-26 Yao Qi <yao.qi@linaro.org>
15274 * disasm-selftests.c (memory_error_test): New function.
15275 (_initialize_disasm_selftests): Register memory_error_test.
15277 2017-01-26 Yao Qi <yao.qi@linaro.org>
15279 * Makefile.in (SFILES): Add disasm-selftests.c and
15281 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
15282 * disasm-selftests.c: New file.
15283 * selftest-arch.c: New file.
15284 * selftest-arch.h: New file.
15286 2017-01-26 Yao Qi <yao.qi@linaro.org>
15288 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
15289 to bfd_arch_mep. Don't return 0 if section is not
15290 found. Call print_insn_mep.
15292 2017-01-26 Pedro Alves <palves@redhat.com>
15293 Yao Qi <yao.qi@linaro.org>
15295 * arm-tdep.c: Include "disasm.h".
15296 (gdb_print_insn_arm): Update code to get gdbarch.
15297 * disasm.c (dis_asm_read_memory): Change it to
15298 gdb_disassembler::dis_asm_read_memory.
15299 (dis_asm_memory_error): Likewise.
15300 (dis_asm_print_address): Likewise.
15301 (gdb_pretty_print_insn): Change it to
15302 gdb_disassembler::pretty_print_insn.
15303 (dump_insns): Add one argument gdb_disassemlber. All
15305 (do_mixed_source_and_assembly_deprecated): Likewise.
15306 (do_mixed_source_and_assembly): Likewise.
15307 (do_assembly_only): Likewise.
15308 (gdb_disassembler::gdb_disassembler): New.
15309 (gdb_disassembler::print_insn): New.
15310 * disasm.h (class gdb_disassembler): New.
15311 (gdb_pretty_print_insn): Remove declaration.
15312 (gdb_disassemble_info): Likewise.
15313 * guile/scm-disasm.c (class gdbscm_disassembler): New.
15314 (gdbscm_disasm_read_memory_worker): Update.
15315 (gdbscm_disasm_read_memory): Update.
15316 (gdbscm_disasm_memory_error): Remove.
15317 (gdbscm_disasm_print_address): Remove.
15318 (gdbscm_disassembler::gdbscm_disassembler): New.
15319 (gdbscm_print_insn_from_port): Update.
15320 * mips-tdep.c: Include disasm.h.
15321 (gdb_print_insn_mips): Update code to get gdbarch.
15322 * record-btrace.c (btrace_insn_history): Update.
15323 * spu-tdep.c: Include disasm.h.
15324 (struct spu_dis_asm_data): Remove.
15325 (struct spu_dis_asm_info): New.
15326 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
15328 (gdb_print_insn_spu): Cast disassemble_info to
15331 2017-01-26 Yao Qi <yao.qi@linaro.org>
15333 * disasm.c (do_ui_file_delete): Delete.
15334 (gdb_insn_length): Move code creating stream to ...
15335 * utils.c (null_stream): ... here. New function.
15336 * utils.h (null_stream): Declare.
15338 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
15340 * python/py-inferior.c (find_thread_object): Return directly
15341 from the loop. Remove "found" variable.
15343 2017-01-21 Joel Brobecker <brobecker@adacore.com>
15345 GDB 7.12.1 released.
15347 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
15349 * python/py-function.c (fnpy_call): Reorder declarations to have
15350 the gdbpy_enter object declared first.
15351 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
15353 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
15356 * python/python-internal.h (PyMem_RawMalloc): Define for
15358 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
15359 PyMem_RawMalloc instead of PyMem_Malloc.
15361 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
15362 Luis Machado <lgustavo@codesourcery.com>
15364 * NEWS (New commands): Mention flash-erase.
15365 (New MI commands): Mention target-flash-erase.
15366 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
15368 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
15369 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
15370 * target.c (flash_erase_command): New function.
15371 (initialize_targets): Add new flash-erase command.
15372 * target.h (flash_erase_command): New declaration.
15374 2017-01-20 Joel Brobecker <brobecker@adacore.com>
15376 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
15377 HAVE_SYS_PROCFS_H is defined.
15379 2017-01-18 Alan Hayward <alan.hayward@arm.com>
15381 * remote.c (struct cached_reg): Change data into a pointer.
15382 * (stop_reply_dtr): Free data pointers before deleting vector.
15383 (process_stop_reply): Likewise.
15384 (remote_parse_stop_reply): Allocate space for data
15386 2017-01-18 Alan Hayward <alan.hayward@arm.com>
15388 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
15390 (amd64_pseudo_register_read_value): Likewise.
15391 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
15392 (store_register_using_P): Likewise.
15393 * regcache.c (regcache_xfer_part): Likewise.
15395 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
15397 Split real and pseudo registers.
15398 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
15399 (sparc32_pseudo_regnum): New enum.
15400 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
15401 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
15402 (SPARC32_CP0_REGISTERS): New macro.
15403 (sparc32_pseudo_register_name): New function.
15404 (sparc32_register_name): Use sparc32_pseudo_register_name.
15405 (sparc32_pseudo_register_type): New function.
15406 (sparc32_register_type): Use sparc32_pseudo_register_type.
15407 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
15408 pseudo register numbers.
15409 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
15410 (SPARC64_CP0_REGISTERS): New macro.
15411 (sparc64_pseudo_register_name): New function.
15412 (sparc64_register_name): Use sparc64_pseudo_register_name.
15413 (sparc64_pseudo_register_type): New function.
15414 (sparc64_register_type): Use sparc64_pseudo_register_type.
15415 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
15416 pseudo register numbers.
15417 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
15418 sparc64_store_arguments): Handle pseudo register numbers.
15420 2017-01-13 Yao Qi <yao.qi@linaro.org>
15422 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
15423 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
15425 (getpkt_or_notif_sane_1): Likewise.
15427 2017-01-13 Yao Qi <yao.qi@linaro.org>
15429 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
15430 of CC. Pass "-x c++-header" instead of "-x c".
15432 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15434 * remote.c (remote_can_async_p): Update comment.
15436 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15438 * linux-nat.c (linux_nat_can_async_p): Update comment.
15440 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15442 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
15444 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
15446 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
15448 2017-01-10 Tom Tromey <tom@tromey.com>
15450 * python/py-type.c (typy_legacy_template_argument): Update.
15451 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
15452 ~demangle_parse_info): Declare new members.
15453 (cp_demangled_name_to_comp): Return unique_ptr.
15454 (cp_demangled_name_parse_free)
15455 (make_cleanup_cp_demangled_name_parse_free)
15456 (cp_new_demangle_parse_info): Remove.
15457 * cp-support.c (do_demangled_name_parse_free_cleanup)
15458 (make_cleanup_cp_demangled_name_parse_free): Remove.
15459 (inspect_type, cp_canonicalize_string_full)
15460 (cp_canonicalize_string): Update.
15461 (mangled_name_to_comp): Change return type.
15462 (cp_class_name_from_physname, method_name_from_physname)
15463 (cp_func_name, cp_remove_params): Update.
15464 * cp-name-parser.y (demangle_parse_info): New constructor, from
15465 cp_new_demangle_parse_info.
15466 (~demangle_parse_info): New destructor, from
15467 cp_demangled_name_parse_free.
15468 (cp_merge_demangle_parse_infos): Update.
15469 (cp_demangled_name_to_comp): Change return type.
15471 2017-01-10 Tom Tromey <tom@tromey.com>
15473 * top.c (prevent_dont_repeat): Change return type.
15474 * python/python.c (execute_gdb_command): Use std::string.
15476 * guile/guile.c (gdbscm_execute_gdb_command): Update.
15477 * command.h (prevent_dont_repeat): Change return type.
15478 * breakpoint.c (bpstat_do_actions_1): Update.
15480 2017-01-10 Tom Tromey <tom@tromey.com>
15482 * value.h (scoped_value_mark::~scoped_value_mark): Call
15484 (scoped_value_mark::free_to_mark): New method.
15485 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
15488 2017-01-10 Tom Tromey <tom@tromey.com>
15490 * python/py-value.c (valpy_dereference, valpy_referenced_value)
15491 (valpy_reference_value, valpy_const_value, valpy_get_address)
15492 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
15493 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
15494 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
15495 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
15497 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
15498 * value.h (scoped_value_mark): New class.
15500 2017-01-10 Tom Tromey <tom@tromey.com>
15502 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
15503 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
15504 * psymtab.c (discard_psymtabs_upto): Remove.
15505 (make_cleanup_discard_psymtabs): Remove.
15506 (struct psymtab_state): Remove.
15508 2017-01-10 Tom Tromey <tom@tromey.com>
15510 * record-full.c (record_full_save_cleanups): Remove.
15511 (record_full_save): Use gdb::unlinker.
15512 * gcore.c (do_bfd_delete_cleanup): Remove.
15513 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
15515 * dwarf2read.c (unlink_if_set): Remove.
15516 (write_psymtabs_to_index): Use gdb::unlinker.
15517 * common/gdb_unlinker.h: New file.
15519 2017-01-10 Tom Tromey <tom@tromey.com>
15521 * windows-tdep.c (windows_xfer_shared_library): Update.
15522 * windows-nat.c (windows_make_so): Update.
15523 * utils.h (make_cleanup_bfd_unref): Remove.
15524 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
15525 * symfile.h (symfile_bfd_open)
15526 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
15527 * symfile.c (read_symbols, symbol_file_add)
15528 (separate_debug_file_exists): Update.
15529 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
15530 (generic_load, reread_symbols): Update.
15531 * symfile-mem.c (symbol_file_add_from_memory): Update.
15532 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
15533 (spu_symbol_file_add_from_memory): Update.
15534 * solist.h (struct target_so_ops) <bfd_open>: Return
15536 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
15537 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
15539 (solib_map_sections, reload_shared_libraries_1): Update.
15540 * solib-svr4.c (enable_break): Update.
15541 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
15542 * solib-frv.c (enable_break2): Update.
15543 * solib-dsbt.c (enable_break): Update.
15544 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
15546 (darwin_solib_get_all_image_info_addr_at_init): Update.
15547 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
15548 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
15549 * record-full.c (record_full_save): Update.
15550 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
15551 * procfs.c (insert_dbx_link_bpt_in_file): Update.
15552 * minidebug.c (find_separate_debug_file_in_section): Return
15554 * machoread.c (macho_add_oso_symfile): Change abfd to
15556 (macho_symfile_read_all_oso): Update.
15557 (macho_check_dsym): Return gdb_bfd_ref_ptr.
15558 (macho_symfile_read): Update.
15559 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
15560 (jit_bfd_try_read_symtab): Update.
15561 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15562 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15563 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15565 (gdb_bfd_ref_policy): New struct.
15566 (gdb_bfd_ref_ptr): New typedef.
15567 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15568 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15569 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15571 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15572 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15573 (gcore_command): Update.
15574 * exec.c (exec_file_attach): Update.
15575 * elfread.c (elf_symfile_read): Update.
15576 * dwarf2read.c (dwarf2_get_dwz_file): Update.
15577 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
15578 (open_and_init_dwo_file): Update.
15579 (open_dwp_file): Return gdb_bfd_ref_ptr.
15580 (open_and_init_dwp_file): Update.
15581 * corelow.c (core_open): Update.
15582 * compile/compile-object-load.c (compile_object_load): Update.
15583 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
15584 * coffread.c (coff_symfile_read): Update.
15585 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
15586 gdb_bfd_ref_ptr. Rename.
15587 (dump_bfd_file, restore_command): Update.
15588 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15589 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15590 (find_separate_debug_file_by_buildid): Update.
15592 2017-01-10 Tom Tromey <tom@tromey.com>
15594 * common/gdb_ref_ptr.h: New file.
15595 * python/py-ref.h (struct gdbpy_ref_policy): New.
15596 (gdbpy_ref): Now a typedef.
15598 2017-01-10 Tom Tromey <tom@tromey.com>
15600 * utils.h (make_cleanup_htab_delete): Don't declare.
15601 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
15603 * linespec.c (decode_compound_collector): Add constructor,
15605 (lookup_prefix_sym): Remove cleanup.
15606 (symtab_collector): Add constructor, destructor.
15607 (collect_symtabs_from_filename): Remove cleanup.
15608 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
15609 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
15611 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
15612 * dwarf2read.c (dw2_expand_symtabs_matching)
15613 (dw2_map_symbol_filenames, dwarf_decode_macros)
15614 (write_psymtabs_to_index): Use htab_up.
15615 * dwarf2loc.c (func_verify_no_selftailcall)
15616 (call_site_find_chain_1, func_verify_no_selftailcall)
15617 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
15618 std::vector, gdb::unique_xmalloc_ptr.
15619 (call_sitep): Remove typedef.
15620 (dwarf2_locexpr_baton_eval): Remove unused variable.
15622 2017-01-10 Tom Tromey <tom@tromey.com>
15624 * python/python-internal.h (make_cleanup_py_decref)
15625 (make_cleanup_py_xdecref): Don't declare.
15626 * python/py-utils.c (py_decref, make_cleanup_py_decref)
15627 (py_xdecref, make_cleanup_py_xdecref): Remove.
15629 2017-01-10 Tom Tromey <tom@tromey.com>
15631 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
15632 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
15634 2017-01-10 Tom Tromey <tom@tromey.com>
15636 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
15638 2017-01-10 Tom Tromey <tom@tromey.com>
15640 * python/py-utils.c (unicode_to_encoded_string)
15641 (python_string_to_target_string)
15642 (python_string_to_target_python_string)
15643 (python_string_to_host_string, gdbpy_obj_to_string)
15644 (get_addr_from_python): Use gdbpy_ref.
15646 2017-01-10 Tom Tromey <tom@tromey.com>
15648 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
15651 2017-01-10 Tom Tromey <tom@tromey.com>
15653 * python/python.c (eval_python_command, gdbpy_decode_line)
15654 (gdbpy_run_events, gdbpy_start_type_printers)
15655 (gdbpy_apply_type_printers): Use gdbpy_ref.
15657 2017-01-10 Tom Tromey <tom@tromey.com>
15659 * python/py-param.c (get_doc_string, compute_enum_values): Use
15662 2017-01-10 Tom Tromey <tom@tromey.com>
15664 * python/py-inferior.c (find_thread_object, build_inferior_list):
15667 2017-01-10 Tom Tromey <tom@tromey.com>
15669 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15671 2017-01-10 Tom Tromey <tom@tromey.com>
15673 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
15676 2017-01-10 Tom Tromey <tom@tromey.com>
15678 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
15680 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
15683 2017-01-10 Tom Tromey <tom@tromey.com>
15685 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15688 2017-01-10 Tom Tromey <tom@tromey.com>
15690 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
15691 decref results of PyArg_ParseTupleAndKeywords.
15693 2017-01-10 Tom Tromey <tom@tromey.com>
15695 * python/python.c (python_run_simple_file): Use
15696 unique_xmalloc_ptr, gdbpy_ref.
15698 2017-01-10 Tom Tromey <tom@tromey.com>
15700 * python/py-prettyprint.c (print_stack_unless_memory_error)
15701 (print_string_repr, print_children): Use gdbpy_ref.
15702 (dummy_python_frame): New class.
15703 (dummy_python_frame::dummy_python_frame): Rename from
15704 push_dummy_python_frame.
15705 (py_restore_tstate): Remove.
15707 2017-01-10 Tom Tromey <tom@tromey.com>
15709 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15711 2017-01-10 Tom Tromey <tom@tromey.com>
15713 * python/python.c (ensure_python_env, restore_python_env):
15715 * python/python-internal.h (ensure_python_env): Don't declare.
15716 * varobj.h (varobj_ensure_python_env): Don't declare.
15717 * varobj.c (varobj_ensure_python_env): Remove.
15719 2017-01-10 Tom Tromey <tom@tromey.com>
15721 * varobj.c (varobj_value_get_print_value): Use
15722 gdbpy_enter_varobj.
15724 2017-01-10 Tom Tromey <tom@tromey.com>
15726 * python/py-prettyprint.c (print_string_repr, print_children):
15728 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
15730 * varobj.c (varobj_value_get_print_value): Update.
15731 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
15733 2017-01-10 Tom Tromey <tom@tromey.com>
15735 * varobj.c (varobj_get_display_hint)
15736 (dynamic_varobj_has_child_method, install_new_value_visualizer)
15737 (varobj_set_visualizer, free_variable): Use
15738 gdbpy_enter_varobj.
15740 2017-01-10 Tom Tromey <tom@tromey.com>
15742 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
15743 (do_finish_initialization): New function. Use gdbpy_ref.
15744 (gdbpy_finish_initialization): Use gdbpy_enter. Call
15745 do_finish_initialization.
15747 2017-01-10 Tom Tromey <tom@tromey.com>
15749 * python/py-param.c (get_set_value, get_show_value): Use
15750 gdbpy_enter, gdbpy_ref.
15752 2017-01-10 Tom Tromey <tom@tromey.com>
15754 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
15756 2017-01-10 Tom Tromey <tom@tromey.com>
15758 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
15760 2017-01-10 Tom Tromey <tom@tromey.com>
15762 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
15763 Use gdbpy_enter_varobj.
15765 2017-01-10 Tom Tromey <tom@tromey.com>
15767 * varobj.c (gdbpy_enter_varobj): New constructor.
15768 * python/python-internal.h (gdbpy_enter_varobj): New class.
15769 * python/py-varobj.c (py_varobj_get_iterator): Use
15770 gdbpy_enter_varobj.
15772 2017-01-10 Tom Tromey <tom@tromey.com>
15774 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
15775 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15776 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
15777 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
15778 unique_xmalloc_ptr.
15779 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
15781 2017-01-10 Tom Tromey <tom@tromey.com>
15783 * python/py-xmethods.c (invoke_match_method): Use
15786 2017-01-10 Tom Tromey <tom@tromey.com>
15788 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
15789 gdbpy_enter, gdbpy_ref.
15791 2017-01-10 Tom Tromey <tom@tromey.com>
15793 * python/python.c (python_interactive_command): Use gdbpy_enter.
15795 2017-01-10 Tom Tromey <tom@tromey.com>
15797 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
15800 2017-01-10 Tom Tromey <tom@tromey.com>
15802 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
15803 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15805 2017-01-10 Tom Tromey <tom@tromey.com>
15807 * utils.h (htab_deleter): New struct.
15808 (htab_up): New typedef.
15809 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
15810 gdbpy_enter, gdbpy_ref, htab_up.
15812 2017-01-10 Tom Tromey <tom@tromey.com>
15814 * python/py-unwind.c (pending_frame_invalidate): Remove.
15815 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
15817 2017-01-10 Tom Tromey <tom@tromey.com>
15819 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
15820 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
15822 2017-01-10 Tom Tromey <tom@tromey.com>
15824 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
15826 2017-01-10 Tom Tromey <tom@tromey.com>
15828 * python/python.c (gdbpy_eval_from_control_command)
15829 (gdbpy_source_script, gdbpy_run_events)
15830 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
15831 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
15834 2017-01-10 Tom Tromey <tom@tromey.com>
15836 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
15838 2017-01-10 Tom Tromey <tom@tromey.com>
15840 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
15842 2017-01-10 Tom Tromey <tom@tromey.com>
15844 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
15845 (python_on_inferior_call_pre, python_on_inferior_call_post)
15846 (python_on_memory_change, python_on_register_change)
15847 (python_inferior_exit, python_new_objfile, add_thread_object)
15848 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
15850 2017-01-10 Tom Tromey <tom@tromey.com>
15852 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
15853 (bpfinishpy_handle_exit): Use gdbpy_enter.
15855 2017-01-10 Tom Tromey <tom@tromey.com>
15857 * python/py-cmd.c (cmdpy_destroyer)
15858 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
15861 2017-01-10 Tom Tromey <tom@tromey.com>
15863 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15865 (gdbpy_breakpoint_has_cond): Likewise.
15867 2017-01-10 Tom Tromey <tom@tromey.com>
15869 * python/python.c (gdbpy_enter): New constructor.
15870 (~gdbpy_enter): New destructor.
15871 (restore_python_env, ensure_python_env): Rewrite.
15872 * python/python-internal.h (gdbpy_enter): New class.
15874 2017-01-10 Tom Tromey <tom@tromey.com>
15876 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
15878 2017-01-10 Tom Tromey <tom@tromey.com>
15880 * python/py-value.c (value_has_field, get_field_flag)
15881 (get_field_type, valpy_getitem, convert_value_from_python): Use
15884 2017-01-10 Tom Tromey <tom@tromey.com>
15886 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
15889 2017-01-10 Tom Tromey <tom@tromey.com>
15891 * python/py-prettyprint.c (search_pp_list)
15892 (find_pretty_printer_from_objfiles)
15893 (find_pretty_printer_from_progspace)
15894 (find_pretty_printer_from_gdb, find_pretty_printer)
15895 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
15898 2017-01-10 Tom Tromey <tom@tromey.com>
15900 * python/py-param.c (call_doc_function): Use gdbpy_ref.
15902 2017-01-10 Tom Tromey <tom@tromey.com>
15904 * python/py-linetable.c (build_line_table_tuple_from_pcs)
15905 (ltpy_get_all_source_lines): Use gdbpy_ref.
15907 2017-01-10 Tom Tromey <tom@tromey.com>
15909 * python/py-framefilter.c (extract_sym, extract_value)
15910 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
15913 2017-01-10 Tom Tromey <tom@tromey.com>
15915 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
15917 2017-01-10 Tom Tromey <tom@tromey.com>
15919 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
15921 2017-01-10 Tom Tromey <tom@tromey.com>
15923 * python/py-function.c (convert_values_to_python, fnpy_init): Use
15926 2017-01-10 Tom Tromey <tom@tromey.com>
15928 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
15930 2017-01-10 Tom Tromey <tom@tromey.com>
15932 * python/py-type.c (convert_field, make_fielditem, typy_fields)
15933 (typy_range): Use gdbpy_ref.
15935 2017-01-10 Tom Tromey <tom@tromey.com>
15937 * python/py-threadevent.c (create_thread_event_object): Use
15939 * python/py-stopevent.c (create_stop_event_object): Simplify.
15940 (emit_stop_event): Use gdbpy_ref.
15941 * python/py-signalevent.c (create_signal_event_object): Use
15943 * python/py-newobjfileevent.c (create_new_objfile_event_object)
15944 (emit_new_objfile_event, create_clear_objfiles_event_object)
15945 (emit_clear_objfiles_event): Use gdbpy_ref.
15946 * python/py-infevents.c (create_inferior_call_event_object)
15947 (create_register_changed_event_object)
15948 (create_memory_changed_event_object, emit_inferior_call_event)
15949 (emit_memory_changed_event, emit_register_changed_event): Use
15951 * python/py-exitedevent.c (create_exited_event_object)
15952 (emit_exited_event): Use gdbpy_ref.
15953 * python/py-event.h (evpy_emit_event): Remove
15954 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
15955 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
15956 * python/py-continueevent.c (emit_continue_event): Use
15958 * python/py-breakpoint.c (gdbpy_breakpoint_created)
15959 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
15961 * python/py-bpevent.c (create_breakpoint_event_object): Use
15964 2017-01-10 Tom Tromey <tom@tromey.com>
15966 * python/py-ref.h: New file.
15968 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15970 * cli-out.c (cli_ui_out::do_redirect): Change return type to
15972 * cli-out.h (cli_ui_out::do_redirect): Likewise.
15973 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
15974 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
15975 * ui-out.c (ui_out::redirect): Likewise.
15976 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
15977 * cli/cli-logging.c (set_logging_redirect): Update call site of
15979 (handle_redirections): Likewise.
15980 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
15981 * top.c (execute_command_to_string): Likewise.
15982 * utils.c (do_ui_out_redirect_pop): Likewise.
15984 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15986 * stack.c (_initialize_stack): Update "frame" command help message.
15988 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
15990 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
15992 2017-01-06 Yao Qi <yao.qi@linaro.org>
15994 * x86-linux-nat.h: Include gdb_proc_service.h.
15996 2017-01-06 Yao Qi <yao.qi@linaro.org>
15998 * ser-base.h: Include serial.h.
16000 2017-01-06 Yao Qi <yao.qi@linaro.org>
16002 * ppc-linux-tdep.h: Include ppc-tdep.h.
16004 2017-01-06 Yao Qi <yao.qi@linaro.org>
16006 * nat/amd64-linux-siginfo.h: Include signal.h.
16008 2017-01-06 Yao Qi <yao.qi@linaro.org>
16010 * nat/aarch64-linux-hw-point.h: Include break-common.h.
16012 2017-01-06 Yao Qi <yao.qi@linaro.org>
16014 * mi/mi-parse.h: Include mi-cmds.h.
16016 2017-01-06 Yao Qi <yao.qi@linaro.org>
16018 * inf-loop.c: Don't include "target.h".
16019 * inf-loop.h: Include it here.
16021 2017-01-06 Yao Qi <yao.qi@linaro.org>
16023 * dfp.h: Include "dboulest.h" and "expression.h".
16025 2017-01-06 Yao Qi <yao.qi@linaro.org>
16027 * ax-gdb.h: Include "ax.h".
16029 2017-01-06 Yao Qi <yao.qi@linaro.org>
16031 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
16032 with nat/gdb_ptrace.h.
16034 2017-01-05 Yao Qi <yao.qi@linaro.org>
16036 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
16038 (mips64_fbsd_sigframe_init): Likewise.
16040 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16042 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
16043 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
16045 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16047 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
16048 * NEWS: Mention new FreeBSD/mips native configuration.
16049 * config/mips/fbsd.mh: New file.
16050 * configure.host: Add mips*-*-freebsd*.
16051 * mips-fbsd-nat.c: New file.
16053 2017-01-04 John Baldwin <jhb@FreeBSD.org>
16055 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
16056 (ALLDEPFILES): Add mips-fbsd-tdep.c.
16057 * NEWS: Mention new FreeBSD/mips target.
16058 * configure.tgt: Add mips*-*-freebsd*.
16059 * mips-fbsd-tdep.c: New file.
16060 * mips-fbsd-tdep.h: New file.
16062 2017-01-04 Yao Qi <yao.qi@linaro.org>
16064 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
16065 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
16067 2017-01-01 Joel Brobecker <brobecker@adacore.com>
16069 Update copyright year range in all GDB files.
16071 2017-01-01 Joel Brobecker <brobecker@adacore.com>
16073 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
16075 For older changes see ChangeLog-2016.
16081 version-control: never