1 2017-11-08 Tom Tromey <tom@tromey.com>
3 * dwarf2read.c (symbolp): Remove typedef.
4 (read_func_scope): Use std::vector.
5 (process_structure_scope): Use std::vector.
7 2017-11-08 Pedro Alves <palves@redhat.com>
9 * ada-lang.c (ada_make_symbol_completion_list): Use
10 completion_skip_symbol.
11 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
12 (symbol_is_function_or_method(symbol*)): New.
13 (add_symtab_completions): Add complete_symbol_mode parameter. Use
14 completion_skip_symbol.
15 (default_collect_symbol_completion_matches_break_on): Use
16 completion_skip_symbol. Pass down mode.
17 (collect_file_symbol_completion_matches): Pass down mode.
18 * symtab.h (symbol_is_function_or_method): New declarations.
19 (completion_skip_symbol): New template function.
21 2017-11-08 Pedro Alves <palves@redhat.com>
23 * linespec.c (iterate_over_all_matching_symtabs): Add
24 search_domain parameter. Pass it down to expand_symtabs_matching.
25 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
26 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
28 (add_all_symbol_names_from_pspace): Add search_domain parameter.
30 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
32 (add_matching_symbols_to_info): Add search_domain parameter. Pass
35 2017-11-08 Pedro Alves <palves@redhat.com>
37 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
38 text_len locals and don't pass them down.
39 * symtab.c (completion_list_add_name): Remove
40 sym_text/sym_text_len parameters and adjust.
41 (completion_list_add_symbol, completion_list_add_msymbol)
42 (completion_list_objc_symbol, completion_list_add_fields)
43 (add_symtab_completions): Likewise.
44 (default_collect_symbol_completion_matches_break_on)
45 (collect_file_symbol_completion_matches): Remove sym_text_len
46 local and don't pass it down.
47 * symtab.h (completion_list_add_name): Remove
48 sym_text/sym_text_len parameters.
50 2017-11-08 Pedro Alves <palves@redhat.com>
52 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
53 unittests/lookup_name_info-selftests.c.
54 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
55 * cp-support.c: Include "selftest.h".
56 (cp_remove_params_1): Rename from cp_remove_params. Add
57 'require_param' parameter, and handle it.
58 (cp_remove_params): Reimplement.
59 (cp_remove_params_if_any): New.
60 (selftests::quote): New.
61 (selftests::check_remove_params): New.
62 (selftests::test_cp_remove_params): New.
63 (_initialize_cp_support): Install
64 selftests::test_cp_remove_params.
65 * cp-support.h (cp_remove_params_if_any): Declare.
66 * dwarf2read.c :Include "selftest.h".
67 (dw2_expand_symtabs_matching_symbol): Use
68 lookup_name_info::make_ignore_params.
69 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
70 (selftests::dw2_expand_symtabs_matching::string_or_null)
71 (selftests::dw2_expand_symtabs_matching::check_match)
72 (selftests::dw2_expand_symtabs_matching::test_symbols)
73 (selftests::dw2_expand_symtabs_matching::run_test): New.
74 (_initialize_dwarf2_read): Register
75 selftests::dw2_expand_symtabs_matching::run_test.
76 * psymtab.c (psym_expand_symtabs_matching): Use
77 lookup_name_info::make_ignore_params.
78 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
79 If the lookup name wants to ignore parameters, strip them.
80 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
82 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
83 (default_collect_symbol_completion_matches_break_on): Don't try to
85 * symtab.h (lookup_name_info::lookup_name_info): Add
86 'ignore_parameters' parameter.
87 (lookup_name_info::ignore_parameters)
88 (lookup_name_info::make_ignore_params): New methods.
89 (lookup_name_info::m_ignore_parameters): New field.
90 * unittests/lookup_name_info-selftests.c: New file.
92 2017-11-08 Pedro Alves <palves@redhat.com>
94 * dwarf2read.c (dw2_expand_marked_cus)
95 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
96 (dw2_expand_symtabs_matching): Move further below.
97 (dw2_expand_marked_cus): Reindent.
99 2017-11-08 Pedro Alves <palves@redhat.com>
101 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
102 (struct name_component): New.
103 (mapped_index::name_components): New field.
104 (mapped_index::symbol_name_at): New method.
105 (dwarf2_read_index): Call mapped_index ctor.
106 (dw2_map_matching_symbols): Add comment about name_components
108 (dw2_expand_symtabs_matching): Factor part to...
109 (dw2_expand_symtabs_matching_symbol): ... this new function.
110 Build name components table, and lookup symbols in it before
111 calling the name matcher.
112 (dw2_expand_marked_cus): New, factored out from
113 dw2_expand_symtabs_matching.
114 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
116 2017-11-08 Pedro Alves <palves@redhat.com>
118 * ada-lang.c (ada_encode): Rename to ..
119 (ada_encode_1): ... this. Add throw_errors parameter and handle
121 (ada_encode): Reimplement.
122 (match_name): Delete, folded into full_name.
123 (resolve_subexp): No longer pass the encoded name to
124 ada_lookup_symbol_list.
125 (should_use_wild_match): Delete.
126 (name_match_type_from_name): New.
127 (ada_lookup_simple_minsym): Use lookup_name_info and the
128 language's symbol_name_matcher_ftype.
129 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
130 (ada_add_block_renamings): Adjust to use lookup_name_info.
131 (ada_lookup_name): New.
132 (add_nonlocal_symbols, ada_add_all_symbols)
133 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
134 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
135 (ada_name_for_lookup): Delete.
136 (ada_lookup_encoded_symbol): Construct a verbatim name.
137 (wild_match): Reverse sense of return type. Use bool.
138 (full_match): Reverse sense of return type. Inline bits of old
140 (ada_add_block_symbols): Adjust to use lookup_name_info.
141 (symbol_completion_match): Delete, folded into...
142 (ada_lookup_name_info::matches): ... .this new method.
143 (symbol_completion_add): Delete.
144 (ada_collect_symbol_completion_matches): Add name_match_type
145 parameter. Adjust to use lookup_name_info and
146 completion_list_add_name.
147 (get_var_value, ada_add_global_exceptions): Adjust to use
149 (ada_get_symbol_name_cmp): Delete.
150 (do_wild_match, do_full_match): New functions.
151 (ada_lookup_name_info::ada_lookup_name_info): New method.
152 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
154 (ada_language_defn): Install ada_get_symbol_name_matcher.
155 * ada-lex.l (processId): If name starts with '<', copy it
157 * block.c (block_iter_match_step, block_iter_match_first)
158 (block_iter_match_next, block_lookup_symbol)
159 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
161 * block.h (block_iter_match_first, block_iter_match_next)
162 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
163 * c-lang.c (c_language_defn, cplus_language_defn)
164 (asm_language_defn, minimal_language_defn): Adjust comments to
165 refer to la_get_symbol_name_matcher.
166 * completer.c (complete_files_symbols)
167 (collect_explicit_location_matches, symbol_completer): Pass a
168 symbol_name_match_type down.
169 * completer.h (class completion_match, completion_match_result):
171 (completion_tracker::reset_completion_match_result): New method.
172 (completion_tracker::m_completion_match_result): New field.
173 * cp-support.c (make_symbol_overload_list_block): Adjust to use
175 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
177 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
178 * d-lang.c: Adjust comments to refer to
179 la_get_symbol_name_matcher.
180 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
181 Adjust to use lookup_name_info.
182 (dict_iter_match_first, dict_iter_match_next)
183 (iter_match_first_hashed, iter_match_next_hashed)
184 (iter_match_first_linear, iter_match_next_linear): Adjust to work
185 with a lookup_name_info.
186 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
188 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
189 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
190 (gdb_index_symbol_name_matcher): New class.
191 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
192 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
193 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
194 with a symbol_name_match_type.
195 (f_language_defn): Adjust comments to refer to
196 la_get_symbol_name_matcher.
197 * go-lang.c (go_language_defn): Adjust comments to refer to
198 la_get_symbol_name_matcher.
199 * language.c (default_symbol_name_matcher)
200 (language_get_symbol_name_matcher): New functions.
201 (unknown_language_defn, auto_language_defn): Adjust comments to
202 refer to la_get_symbol_name_matcher.
203 * language.h (symbol_name_cmp_ftype): Delete.
204 (language_defn) <la_collect_symbol_completion_matches>: Add match
206 <la_get_symbol_name_cmp>: Delete field.
207 <la_get_symbol_name_matcher>: New field.
208 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
209 (default_symbol_name_matcher, language_get_symbol_name_matcher):
211 * linespec.c (iterate_over_all_matching_symtabs)
212 (iterate_over_file_blocks): Adjust to use lookup_name_info.
213 (find_methods): Add language parameter, and use lookup_name_info
214 and the language's symbol_name_matcher_ftype.
215 (linespec_complete_function): Adjust.
216 (lookup_prefix_sym): Use lookup_name_info.
217 (add_all_symbol_names_from_pspace): Adjust.
218 (find_superclass_methods): Add language parameter and pass it
220 (find_method): Pass symbol language down.
221 (find_linespec_symbols): Don't demangle or Ada encode here.
222 (search_minsyms_for_name): Add lookup_name_info parameter.
223 (add_matching_symbols_to_info): Add name_match_type parameter.
224 Use lookup_name_info.
225 * m2-lang.c (m2_language_defn): Adjust comments to refer to
226 la_get_symbol_name_matcher.
227 * minsyms.c: Include <algorithm>.
228 (add_minsym_to_demangled_hash_table): Remove table parameter and
229 add objfile parameter. Use search_name_hash, and add language to
230 demangled languages vector.
231 (struct found_minimal_symbols): New struct.
232 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
234 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
235 input names here. Use lookup_name_info instead. Lookup up
236 demangled names once for each language in the demangled names
238 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
239 demangled names once for each language in the demangled names
241 (build_minimal_symbol_hash_tables): Adjust.
242 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
244 * objc-lang.c (objc_language_defn): Adjust comment to refer to
245 la_get_symbol_name_matcher.
246 * objfiles.h: Include <vector>.
247 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
248 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
249 la_get_symbol_name_matcher.
250 * p-lang.c (pascal_language_defn): Adjust comment to refer to
251 la_get_symbol_name_matcher.
252 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
253 (match_partial_symbol): Use symbol_name_match_type,
254 lookup_name_info and psymbol_name_matches.
255 (lookup_partial_symbol): Use lookup_name_info.
256 (map_block): Use symbol_name_match_type and lookup_name_info.
257 (psym_map_matching_symbols): Use symbol_name_match_type.
258 (psymbol_name_matches): New.
259 (recursively_search_psymtabs): Use lookup_name_info and
260 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
261 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
262 'kind' parameter to 'domain'.
263 * rust-lang.c (rust_language_defn): Adjust comment to refer to
264 la_get_symbol_name_matcher.
265 * symfile-debug.c (debug_qf_map_matching_symbols)
266 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
267 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
268 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
269 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
270 Adjust to use symbol_name_match_type.
271 <expand_symtabs_matching>: Adjust to use lookup_name_info.
272 (expand_symtabs_matching): Adjust to use lookup_name_info.
273 * symmisc.c (maintenance_expand_symtabs): Use
274 lookup_name_info::match_any ().
275 * symtab.c (symbol_matches_search_name): New.
276 (eq_symbol_entry): Adjust to use lookup_name_info and the
278 (demangle_for_lookup_info::demangle_for_lookup_info): New.
279 (lookup_name_info::match_any): New.
280 (iterate_over_symbols, search_symbols): Use lookup_name_info.
281 (compare_symbol_name): Add language, lookup_name_info and
282 completion_match_result parameters, and use them.
283 (completion_list_add_name): Make extern. Add language and
284 lookup_name_info parameters. Use them.
285 (completion_list_add_symbol, completion_list_add_msymbol)
286 (completion_list_objc_symbol): Add lookup_name_info parameters and
287 adjust. Pass down language.
288 (completion_list_add_fields): Add lookup_name_info parameters and
289 adjust. Pass down language.
290 (add_symtab_completions): Add lookup_name_info parameters and
292 (default_collect_symbol_completion_matches_break_on): Add
293 name_match_type parameter, and use it. Use lookup_name_info.
294 (default_collect_symbol_completion_matches)
295 (collect_symbol_completion_matches): Add name_match_type
296 parameter, and pass it down.
297 (collect_symbol_completion_matches_type): Adjust.
298 (collect_file_symbol_completion_matches): Add name_match_type
299 parameter, and use lookup_name_info.
300 * symtab.h: Include <string> and "common/gdb_optional.h".
301 (enum class symbol_name_match_type): New.
302 (class ada_lookup_name_info): New.
303 (struct demangle_for_lookup_info): New.
304 (class lookup_name_info): New.
305 (symbol_name_matcher_ftype): New.
306 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
307 (symbol_matches_search_name): Declare.
308 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
309 (default_collect_symbol_completion_matches)
310 (collect_symbol_completion_matches)
311 (collect_file_symbol_completion_matches): Add name_match_type
313 (iterate_over_symbols): Use lookup_name_info.
314 (completion_list_add_name): Declare.
315 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
316 (strncmp_iw_with_mode): Now extern.
317 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
318 (strncmp_iw_with_mode): Declare.
320 2017-11-08 Keith Seitz <keiths@redhat.com>
321 Pedro Alves <palves@redhat.com>
323 * ada-lang.c (ada_language_defn): Install
324 default_search_name_hash.
325 * buildsym.c (struct buildsym_compunit): <language>: New field.
326 (finish_block_internal): Pass language when creating dictionaries.
327 (start_buildsym_compunit, start_symtab): New language parameters.
329 (restart_symtab): Pass down compilation unit's language.
330 * buildsym.h (enum language): Forward declare.
331 (start_symtab): New 'language' parameter.
332 * c-lang.c (c_language_defn, cplus_language_defn)
333 (asm_language_defn, minimal_language_defn): Install
334 default_search_name_hash.
335 * coffread.c (coff_start_symtab): Adjust.
336 * d-lang.c (d_language_defn): Install default_search_name_hash.
337 * dbxread.c (struct symloc): Add 'pst_language' field.
338 (PST_LANGUAGE): Define.
339 (start_psymtab, read_ofile_symtab): Use it.
340 (process_one_symbol): New 'language' parameter. Pass it down.
341 * dictionary.c (struct dictionary) <language>: New field.
342 (DICT_LANGUAGE): Define.
343 (dict_create_hashed, dict_create_hashed_expandable)
344 (dict_create_linear, dict_create_linear_expandable): New parameter
345 'language'. Set the dictionary's language.
346 (iter_match_first_hashed): Adjust to rename.
347 (insert_symbol_hashed): Assert we don't see mismatching
348 languages. Adjust to rename.
349 (dict_hash): Rename to ...
350 (default_search_name_hash): ... this and make extern.
351 * dictionary.h (struct language_defn): Forward declare.
352 (dict_create_hashed): New parameter 'language'.
353 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
354 * f-lang.c (f_language_defn): Install default_search_name_hash.
355 * go-lang.c (go_language_defn): Install default_search_name_hash.
356 * jit.c (finalize_symtab): Pass compunit's language to dictionary
358 * language.c (unknown_language_defn, auto_language_defn):
359 * language.h (language_defn::la_search_name_hash): New field.
360 (default_search_name_hash): Declare.
361 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
362 * mdebugread.c (new_block): New parameter 'language'.
363 * mdebugread.c (parse_symbol): Pass symbol language to block
365 (psymtab_to_symtab_1): Pass down language.
366 (new_symtab): Pass compunit's language to block allocation.
367 * objc-lang.c (objc_language_defn): Install
368 default_search_name_hash.
369 * opencl-lang.c (opencl_language_defn):
370 * p-lang.c (pascal_language_defn): Install
371 default_search_name_hash.
372 * rust-lang.c (rust_language_defn): Install
373 default_search_name_hash.
374 * stabsread.h (enum language): Forward declare.
375 (process_one_symbol): Add 'language' parameter.
376 * symtab.c (search_name_hash): New function.
377 * symtab.h (search_name_hash): Declare.
378 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
380 2017-11-08 Pedro Alves <palves@redhat.com>
382 * cp-name-parser.y (main): Don't initialize extra_chars.
384 2017-11-07 Tom Tromey <tom@tromey.com>
386 * event-top.h (command_handler): Constify.
387 * record-full.c (cmd_record_full_start): Update.
388 * thread.c (thread_apply_all_command): Update.
389 * printcmd.c (eval_command): Update.
390 * mi/mi-main.c (mi_execute_cli_command): Update.
391 (mi_execute_async_cli_command): Update.
392 * tui/tui-stack.c (tui_update_command): Update.
393 * cli/cli-interp.c (safe_execute_command): Constify.
394 * record.c (record_start): Update.
395 (record_start, record_stop, cmd_record_start): Update.
396 * record-btrace.c (cmd_record_btrace_bts_start): Update.
397 (cmd_record_btrace_pt_start): Update.
398 (cmd_record_btrace_start): Update.
399 (cmd_record_btrace_start): Update.
400 * reverse.c (exec_reverse_once): Update.
401 * python/python.c (execute_gdb_command): Don't copy the command.
402 * event-top.c (command_line_handler): Update.
403 (command_handler): Constify.
404 * defs.h (deprecated_call_command_hook): Constify.
405 * cli/cli-script.h (execute_user_command): Constify.
406 * cli/cli-script.c (execute_user_command): Constify.
407 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
408 (enum command_control_type): Update.
409 * main.c (catch_command_errors): Remove non-const overload.
410 (catch_command_errors_ftype): Remove.
411 * python/py-cmd.c (cmdpy_function): Constify.
412 * guile/scm-cmd.c (cmdscm_function): Constify.
413 * cli/cli-dump.c (call_dump_func): Constify.
414 * cli/cli-decode.c (do_const_cfunc): Constify.
415 (do_sfunc): Constify.
416 (cmd_func): Constify.
417 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
418 * top.h (execute_command): Constify.
419 * top.c (execute_command): Constify.
420 (execute_command_to_string): Constify.
421 (deprecated_call_command_hook): Constify.
422 * command.h (cmd_func): Constify.
423 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
425 2017-11-07 Tom Tromey <tom@tromey.com>
427 * ada-lang.c (catch_ada_exception_command): Constify.
428 (catch_assert_command): Constify.
429 * break-catch-throw.c (catch_catch_command, catch_throw_command)
430 (catch_rethrow_command): Constify.
431 (catch_exception_command_1): Constify.
432 * breakpoint.h (add_catch_command): Constify.
433 * break-catch-syscall.c (catch_syscall_command_1): Constify.
434 (catch_syscall_split_args): Constify.
435 * break-catch-sig.c (catch_signal_command): Constify.
436 (catch_signal_split_args): Constify.
437 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
438 cmd_const_sfunc_ftype.
439 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
440 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
441 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
442 (add_setshow_string_cmd, struct cmd_list_element)
443 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
444 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
445 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
447 (set_cmd_sfunc): Constify.
448 (empty_sfunc): Constify.
449 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
450 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
451 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
452 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
453 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
454 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
456 (set_cmd_sfunc): Constify.
457 (cmd_sfunc_ftype): Remove.
458 * compile/compile.c (set_compile_args): Constify.
459 * infrun.c (set_disable_randomization): Constify.
460 * infcmd.c (set_args_command, set_cwd_command): Constify.
461 * breakpoint.c (set_condition_evaluation_mode): Constify.
462 (add_catch_command): Constify.
463 (catch_fork_command_1, catch_exec_command_1)
464 (catch_load_command_1, catch_unload_command_1): Constify.
465 (catch_load_or_unload): Constify.
466 * guile/scm-param.c (pascm_set_func): Constify.
467 (add_setshow_generic): Constify.
468 * python/py-param.c (get_set_value): Constify.
469 * top.h (set_verbose): Constify.
470 * tui/tui-win.c (tui_set_var_cmd): Constify.
471 * mi/mi-main.c (set_mi_async_command): Constify.
472 * cli/cli-logging.c (set_logging_overwrite)
473 (set_logging_redirect): Constify.
474 * value.c (set_max_value_size): Constify.
475 * valprint.c (set_input_radix, set_output_radix): Constify.
476 * utils.c (set_width_command, set_height_command): Constify.
477 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
478 * tracepoint.c (set_disconnected_tracing)
479 (set_circular_trace_buffer, set_trace_buffer_size)
480 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
481 * top.c (set_history_size_command, set_verbose, set_editing)
482 (set_gdb_datadir, set_history_filename): Constify.
483 * target.c (set_targetdebug, maint_set_target_async_command)
484 (maint_set_target_non_stop_command, set_target_permissions)
485 (set_write_memory_permission): Constify.
486 (open_target): Constify.
487 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
488 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
489 * symtab.c (set_symbol_cache_size_handler): Constify.
490 * symfile.c (set_ext_lang_command): Constify.
491 * symfile-debug.c (set_debug_symfile): Constify.
492 * source.c (set_directories_command): Constify.
493 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
494 * serial.c (set_parity): Constify.
495 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
496 * remote.c (set_remote_exec_file, set_remotebreak)
497 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
498 * record.c (set_record_insn_history_size)
499 (set_record_call_history_size): Constify.
500 * record-full.c (set_record_full_insn_max_num): Constify.
501 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
502 * osabi.c (set_osabi): Constify.
503 * mips-tdep.c (set_mips64_transfers_32bit_regs)
504 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
505 * maint.c (maintenance_set_profile_cmd): Constify.
506 * linux-thread-db.c (set_libthread_db_search_path): Constify.
507 * language.c (set_language_command, set_range_command)
508 (set_case_command): Constify.
509 * infrun.c (set_non_stop, set_observer_mode)
510 (set_stop_on_solib_events, set_schedlock_func)
511 (set_exec_direction_func): Constify.
512 * infcmd.c (set_inferior_tty_command): Constify.
513 * disasm.c (set_disassembler_options_sfunc): Constify.
514 * demangle.c (set_demangling_command): Constify.
515 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
516 * cris-tdep.c (set_cris_version, set_cris_mode)
517 (set_cris_dwarf2_cfi): Constify.
518 * corefile.c (set_gnutarget_command): Constify.
519 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
520 (set_target_wide_charset_sfunc): Constify.
521 * breakpoint.c (update_dprintf_commands): Constify.
522 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
523 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
524 (set_disassembly_style_sfunc): Constify.
525 * arch-utils.c (set_endian, set_architecture): Constify.
526 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
527 * agent.c (set_can_use_agent): Constify.
529 2017-11-07 Tom Tromey <tom@tromey.com>
531 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
532 (go32_pde, go32_pte, go32_pte_for_address): Constify.
533 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
534 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
535 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
536 (parse_int_arg, show_thread_default_detach_sc_cmd)
537 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
538 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
539 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
540 (show_task_pause_cmd, set_task_detach_sc_cmd)
541 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
542 (set_noninvasive_cmd, set_thread_pause_cmd)
543 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
544 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
545 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
546 * windows-nat.c (display_selectors): Constify.
547 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
549 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
550 (cmd_cfunc_eq): Likewise.
551 (struct cmd_list_element): Likewise.
553 (cli_user_command_p): Update.
554 * command.h (add_cmd): Remove non-const overload.
555 (cmd_cfunc_ftype): Remove typedef.
556 (cmd_cfunc_eq): Remove non-const overload.
557 * value.c (show_values): Constify.
558 * thread.c (thread_apply_all_command): Constify.
559 * symfile.c (load_command): Constify.
560 * source.c (directory_command): Constify.
561 * maint.c (maintenance_internal_error)
562 (maintenance_demangler_warning, maintenance_space_display)
563 (maintenance_print_architecture, maintenance_translate_address)
564 (maintenance_info_selftests, maintenance_internal_warning):
566 * breakpoint.c (disable_trace_command, enable_trace_command):
568 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
570 (add_auto_load_safe_path): Constify.
571 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
572 * top.h (show_commands): Constify.
573 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
574 * sparc64-tdep.c (adi_examine_command): Constify.
575 (adi_assign_command): Constify.
577 2017-11-07 Tom Tromey <tom@tromey.com>
579 * frame.h (info_locals_command, info_args_command): Constify.
580 * auto-load.h (auto_load_info_scripts): Constify.
581 * inferior.h (registers_info): Constify.
582 * copying.c: Rebuild.
583 * copying.awk: Constify generated commands.
584 * auto-load.c (auto_load_info_scripts)
585 (info_auto_load_gdb_scripts): Constify.
586 * cli/cli-decode.c (struct cmd_list_element): Take a
587 cmd_const_cfunc_ftype.
588 * command.h (add_info): Take a cmd_const_cfunc_ftype.
589 * tui/tui-win.c (tui_all_windows_info): Constify.
590 * python/py-auto-load.c (info_auto_load_python_scripts):
592 * cli/cli-cmds.c (show_command): Remove non-const overload.
593 * tracepoint.c (info_tvariables_command, info_scope_command):
595 (info_static_tracepoint_markers_command): Constify.
596 * thread.c (info_threads_command): Constify.
597 (print_thread_info_1): Constify.
598 * target.c (info_target_command): Constify.
599 * symtab.c (info_sources_command, info_functions_command)
600 (info_types_command): Constify.
601 (info_variables_command): Remove non-const overload.
602 * symfile.c (info_ext_lang_command): Constify.
603 * stack.c (info_frame_command, info_locals_command)
604 (info_args_command): Constify.
605 (backtrace_command): Remove non-const overload.
606 * source.c (info_source_command, info_line_command): Constify.
607 * solib.c (info_sharedlibrary_command): Constify.
608 * skip.c (info_skip_command): Constify.
609 * ser-go32.c (info_serial_command): Constify.
610 * reverse.c (info_bookmarks_command): Constify.
611 * printcmd.c (info_symbol_command, info_address_command)
612 (info_display_command): Constify.
613 * osdata.c (info_osdata_command): Constify.
614 * objc-lang.c (info_selectors_command, info_classes_command):
616 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
617 * memattr.c (info_mem_command): Constify.
618 * macrocmd.c (info_macro_command, info_macros_command): Constify.
619 * linux-fork.c (info_checkpoints_command): Constify.
620 * infrun.c (info_signals_command): Constify.
621 * inflow.c (info_terminal_command): Constify.
622 * inferior.c (info_inferiors_command): Constify.
623 (print_inferior): Constify.
624 * infcmd.c (info_program_command, info_all_registers_command)
625 (info_registers_command, info_vector_command)
626 (info_float_command): Constify.
627 (registers_info): Constify.
628 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
629 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
631 * f-valprint.c (info_common_command): Constify.
632 * dcache.c (info_dcache_command): Constify.
633 (dcache_info_1): Constify.
634 * darwin-nat-info.c (info_mach_tasks_command)
635 (info_mach_task_command, info_mach_ports_command)
636 (info_mach_port_command, info_mach_threads_command)
637 (info_mach_thread_command, info_mach_regions_command)
638 (info_mach_regions_recurse_command, info_mach_region_command)
639 (info_mach_exceptions_command): Constify.
640 (get_task_from_args): Constify.
641 * cp-support.c (info_vtbl_command): Constify.
642 * breakpoint.c (info_watchpoints_command)
643 (info_tracepoints_command): Constify.
644 (info_breakpoints_command): Remove non-const overload.
645 * avr-tdep.c (avr_io_reg_read_command): Constify.
646 * auxv.c (info_auxv_command): Constify.
647 * ada-tasks.c (info_tasks_command): Constify.
648 (info_task): Constify.
649 * ada-lang.c (info_exceptions_command): Constify.
651 2017-11-07 Tom Tromey <tom@tromey.com>
653 * solib.h (no_shared_libraries): Constify.
654 * frame.h (return_command): Constify.
655 * cli/cli-cmds.h (quit_command): Constify.
656 * top.h (quit_command, execute_command): Constify.
657 * target.h (flash_erase_command): Constify.
658 * inferior.h (set_inferior_args, attach_command): Constify.
659 * tracepoint.h (start_tracing, stop_tracing): Constify.
660 * breakpoint.h (break_command, tbreak_command)
661 (hbreak_command_wrapper, thbreak_command_wrapper)
662 (rbreak_command_wrapper, watch_command_wrapper)
663 (awatch_command_wrapper, rwatch_command_wrapper)
664 (get_tracepoint_by_number): Constify.
665 * symtab.c (info_variables_command, rbreak_command)
666 (symtab_symbol_info): Constify.
667 (info_variables_command): Add non-const overload.
668 * top.c (dont_repeat_command): Constify.
669 * breakpoint.c (ignore_command, commands_command)
670 (condition_command, tbreak_command, hbreak_command)
671 (thbreak_command, clear_command, break_command)
672 (info_breakpoints_command, watch_command, rwatch_command)
673 (awatch_command, trace_command, ftrace_command, strace_command)
674 (trace_pass_command, break_range_command, dprintf_command)
675 (agent_printf_command, get_tracepoint_by_number)
676 (watch_maybe_just_location, trace_pass_command): Constify.
677 (info_breakpoints_command): Add non-const overload.
678 * tracefile.c (tsave_command): Constify.
679 * infcmd.c (attach_command, disconnect_command, signal_command)
680 (queue_signal_command, stepi_command, nexti_command)
681 (finish_command, next_command, step_command, until_command)
682 (advance_command, jump_command, continue_command, run_command)
683 (start_command, starti_command, interrupt_command)
684 (run_command_1, set_inferior_args, step_1): Constify.
685 * inferior.c (add_inferior_command, remove_inferior_command)
686 (clone_inferior_command): Constify.
687 * linux-fork.c (checkpoint_command, restart_command): Constify.
688 * windows-nat.c (signal_event_command): Constify.
689 * guile/guile.c (guile_repl_command, guile_command): Constify.
690 * printcmd.c (x_command, display_command, printf_command)
691 (output_command, set_command, call_command, print_command)
692 (eval_command): Constify.
693 (non_const_set_command): Remove.
694 (_initialize_printcmd): Update.
695 * source.c (forward_search_command, reverse_search_command):
697 * jit.c (jit_reader_load_command, jit_reader_unload_command):
699 * infrun.c (handle_command): Constify.
700 * memattr.c (mem_command): Constify.
701 * stack.c (return_command, up_command, up_silently_command)
702 (down_command, down_silently_command, frame_command)
703 (backtrace_command, func_command, backtrace_command_1): Constify.
704 (backtrace_command): Add non-const overload.
705 * remote-sim.c (simulator_command): Constify.
706 * exec.c (set_section_command): Constify.
707 * tracepoint.c (tdump_command, trace_variable_command)
708 (tstatus_command, tstop_command, tstart_command)
709 (end_actions_pseudocommand, while_stepping_pseudocommand)
710 (collect_pseudocommand, teval_pseudocommand, actions_command)
711 (start_tracing, stop_tracing): Constify.
712 * value.c (init_if_undefined_command): Constify.
713 * tui/tui-stack.c (tui_update_command): Constify.
714 * tui/tui-win.c (tui_refresh_all_command)
715 (tui_set_tab_width_command, tui_set_win_height_command)
716 (tui_set_focus_command, tui_scroll_forward_command)
717 (tui_scroll_backward_command, tui_scroll_left_command)
718 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
719 (tui_set_win_height): Constify.
720 * tui/tui-layout.c (tui_layout_command): Constify.
721 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
722 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
723 (proc_untrace_sysexit_cmd): Constify.
724 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
725 (threadset_test_cmd, threadlist_update_test_cmd)
726 (threadalive_test): Constify.
727 * objc-lang.c (print_object_command): Constify.
728 * command.h (add_com): Constify.
729 * cli/cli-dump.c (restore_command): Constify.
730 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
731 (help_command, complete_command, shell_command, edit_command)
732 (list_command, disassemble_command, make_command)
733 (apropos_command, alias_command): Constify.
734 * cli/cli-script.c (document_command, define_command)
735 (while_command, if_command, validate_comname): Constify.
736 * cli/cli-decode.c (struct cmd_list_element): Change type of
738 * target.c (do_monitor_command, flash_erase_command): Constify.
739 * regcache.c (reg_flush_command): Constify.
740 * reverse.c (reverse_step, reverse_next, reverse_stepi)
741 (reverse_nexti, reverse_continue, reverse_finish)
742 (save_bookmark_command, goto_bookmark_command)
743 (exec_reverse_once): Constify.
744 * python/python.c (python_interactive_command, python_command):
746 * typeprint.c (ptype_command, whatis_command, whatis_exp):
748 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
749 * gcore.c (gcore_command): Constify.
751 2017-11-07 Tom Tromey <tom@tromey.com>
753 * printcmd.c (x_command): Call set_repeat_arguments.
754 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
755 * top.c (repeat_arguments): New global.
756 (set_repeat_arguments): New function.
757 (execute_command): Handle repeat_arguments.
758 (show_commands): Calls set_repeat_arguments.
759 * command.h (set_repeat_arguments): Declare.
761 2017-11-07 Tom Tromey <tom@tromey.com>
763 * stack.c (backtrace_command): Use std::string.
764 (backtrace_command_1): Make "count_exp" const.
766 2017-11-07 Tom Tromey <tom@tromey.com>
768 * source.c (directory_switch, mod_path, add_path): Constify.
769 * defs.h (add_path, mod_path, directory_switch): Constify.
770 * mi/mi-cmd-env.c (env_mod_path): Constify.
772 2017-11-07 Tom Tromey <tom@tromey.com>
774 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
775 (run_command_1, continue_command, step_1, jump_command)
776 (signal_command, until_command, advance_command, finish_command)
777 (attach_command): Update.
779 2017-11-07 Tom Tromey <tom@tromey.com>
781 * command.h (set_cmd_cfunc): Don't declare.
782 * cli/cli-decode.c (set_cmd_cfunc): Now static.
784 2017-11-07 Tom Tromey <tom@tromey.com>
786 * stack.c (select_frame_command): Constify.
787 * cli/cli-decode.c (add_com_suppress_notification): Constify.
788 * command.h (add_com_suppress_notification): Constify.
790 2017-11-07 Tom Tromey <tom@tromey.com>
792 * breakpoint.c (stop_command): Constify.
793 * cli/cli-decode.c (struct cmd_list_element): Constify.
794 * command.h (add_abbrev_prefix_cmd): Constify.
796 2017-11-07 Pedro Alves <palves@redhat.com>
798 * breakpoint.c (extract_bp_kind): New enum.
799 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
800 factored out from ...
801 (extract_bp_number_and_location): ... here.
802 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
804 2017-11-07 Pedro Alves <palves@redhat.com>
806 * breakpoint.c (extract_bp_number_and_location): Change return
807 type to void. Throw error instead of warning.
808 (enable_disable_command): Adjust.
810 2017-11-07 Xavier Roirand <roirand@adacore.com>
811 Pedro Alves <palves@redhat.com>
813 * breakpoint.c (map_breakpoint_number_range): New, factored out
815 (map_breakpoint_numbers): ... here.
816 (find_location_by_number): Change parameters from string to
817 breakpoint number and location.
818 (extract_bp_number_and_location): New function.
819 (enable_disable_bp_num_loc)
820 (enable_disable_breakpoint_location_range)
821 (enable_disable_command): New functions, factored out ...
822 (enable_command, disable_command): ... these functions, and
823 adjusted to support ranges.
824 * NEWS: Document enable/disable breakpoint location range feature.
826 2017-11-06 Luis Machado <luis.machado@linaro.org>
828 * MAINTAINERS (Write After Approval): Update my e-mail address.
830 2017-11-06 Pedro Alves <palves@redhat.com>
832 * gnu-nat.c (gnu_terminal_init): Delete.
833 (gnu_target): Don't install gnu_terminal_init.
834 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
835 (child_terminal_init): ... this function.
837 2017-11-06 Pedro Alves <palves@redhat.com>
839 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
841 * config.in, configure: Regenerate.
843 2017-11-06 Pedro Alves <palves@redhat.com>
845 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
846 (async_init_signals): Adjust.
847 (handle_stop_sig): Rename to ...
848 (handle_sigtstp): ... this.
849 (async_stop_sig): Rename to ...
850 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
852 * event-top.h: Move signal.h include to the top. Check SIGTSTP
853 instead of STOP_SIGNAL thoughout.
854 (handle_stop_sig): Rename to ...
855 (handle_sigtstp): ... this.
856 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
858 2017-11-06 Pedro Alves <palves@redhat.com>
860 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
861 longer set flags twice in row.
863 2017-11-06 Pedro Alves <palves@redhat.com>
865 * Makefile.in (SER_HARDWIRE): Update comment.
866 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
867 * common/gdb_termios.h: Delete file.
868 * common/job-control.c: Include termios.h and unistd.h instead of
870 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
872 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
874 * configure.ac: No longer check for termio.h and sgtty.h.
875 * configure: Regenerate.
876 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
877 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
878 Replace PROCESS_GROUP_TYPE references with pid_t references
880 (gdb_getpgrp): Delete.
881 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
882 (child_terminal_inferior): Remove comment. Remove sgtty code.
883 (child_terminal_ours_1): Use tcgetpgrp directly instead of
884 gdb_getpgrp. Use serial_set_tty_state instead aof
885 serial_noflush_set_tty_state. Remove sgtty code.
886 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
887 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
888 (inferior_process_group): Now returns pid_t.
889 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
890 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
891 * ser-event.c (serial_event_ops): Update.
892 * ser-go32.c (dos_noflush_set_tty_state): Delete.
894 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
895 * ser-pipe.c (pipe_ops): Update.
896 * ser-tcp.c (tcp_ops): Update.
897 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
899 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
900 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
901 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
903 (hardwire_noflush_set_tty_state): Delete.
904 (hardwire_print_tty_state, hardwire_drain_output)
905 (hardwire_flush_output, hardwire_flush_input)
906 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
907 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
908 code, and assume termios.
909 (hardwire_ops): Update.
910 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
911 * serial.c (serial_noflush_set_tty_state): Delete.
912 * serial.h (serial_noflush_set_tty_state): Delete.
913 (serial_ops::noflush_set_tty_state): Delete.
915 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
917 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
918 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
919 (COMMON_OBS): Remove doublest.o and dfp.o.
920 Do not build target-float.c (instead of doublest.c)
921 with -Wformat-nonliteral.
923 * doublest.c: Remove file.
924 * doublest.h: Remove file.
925 * dfp.c: Remove file.
926 * dfp.h: Remove file.
928 * target-float.c: Do not include "doublest.h" and "dfp.h".
929 (DOUBLEST): Move here from doublest.h.
930 (enum float_kind): Likewise.
931 (FLOATFORMAT_CHAR_BIT): Likewise.
932 (FLOATFORMAT_LARGEST_BYTES): Likewise.
933 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
934 (floatformat_precision): Likewise.
935 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
936 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
938 (host_float_format, host_double_format, host_long_double_format):
940 (floatformat_to_string, floatformat_from_string): Likewise.
941 (floatformat_to_doublest): Likewise. Also, inline the original
942 convert_floatformat_to_doublest.
943 (floatformat_from_doublest): Likewise. Also, inline the original
944 convert_floatformat_from_doublest.
946 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
947 (MAX_DECIMAL_STRING): Move here from dfp.c.
948 (match_endianness): Likewise.
949 (set_decnumber_context, decimal_check_errors): Likewise.
950 (decimal_from_number, decimal_to_number): Likewise.
951 (decimal_to_string, decimal_from_string): Likewise. Make static.
952 (decimal_from_longest, decimal_from_ulongest): Likewise.
953 (decimal_to_longest): Likewise.
954 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
955 (decimal_convert): Likewise.
957 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
959 * doublest.c: Do not include "gdbtypes.h".
960 (extract_typed_floating): Remove.
961 (store_typed_floating): Remove.
962 (convert_typed_floating): Remove.
963 * doublest.h (struct type): Remove.
964 (DOUBLEST_PRINT_FORMAT): Remove.
965 (DOUBLEST_SCAN_FORMAT): Remove.
966 (extract_typed_floating): Remove.
967 (store_typed_floating): Remove.
968 (convert_typed_floating): Remove.
970 * dfp.c (decimal_from_doublest): Remove.
971 (decimal_to_doublest): Remove.
972 * dfp.h: Do not include "doublest.h".
973 (decimal_from_doublest): Remove.
974 (decimal_to_doublest): Remove.
976 * value.c: Do not include "doublest.h" and "dfp.h".
977 (value_as_double): Remove.
978 (unpack_double): Remove.
979 (value_from_double): Remove.
980 (value_from_decfloat): Remove.
981 * value.h: Do not include "doublest.h".
982 (value_as_double): Remove.
983 (unpack_double): Remove.
984 (value_from_double): Remove.
985 (value_from_decfloat): Remove.
987 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
989 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
990 (i386_extract_return_value): Use target_float_convert.
991 (i386_store_return_value): Likewise.
992 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
993 (i387_value_to_register): Likewise.
994 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
995 (ia64_register_to_value): Use target_float_convert.
996 (ia64_value_to_register): Likewise.
997 (ia64_extract_return_value): Likewise.
998 (ia64_store_return_value): Likewise.
999 (ia64_push_dummy_call): Likewise.
1000 * m68k-tdep.c: Include "target-float.h".
1001 (m68k_register_to_value): Use target_float_convert.
1002 (m68k_value_to_register): Likewise.
1003 (m68k_svr4_extract_return_value): Likewise.
1004 (m68k_svr4_store_return_value): Likewise.
1005 * ppc-sysv-tdep.c: Include "target-float.h".
1006 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
1007 (do_ppc_sysv_return_value): Likewise.
1008 (ppc64_sysv_abi_push_freg): Likewise.
1009 (ppc64_sysv_abi_return_value_base): Likewise.
1010 * rs6000-aix-tdep.c: Include "target-float.h".
1011 (rs6000_push_dummy_call): Use target_float_convert.
1012 (rs6000_return_value): Likewise.
1013 * rs6000-lynx178-tdep.c: Include "target-float.h".
1014 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
1015 (rs6000_lynx178_return_value): Likewise.
1016 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
1017 (rs6000_register_to_value): Use target_float_convert.
1018 (rs6000_value_to_register): Likewise.
1019 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
1020 (arm_extract_return_value): Use target_float_convert.
1021 (arm_store_return_value): Likewise.
1022 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
1023 (sh_register_convert_to_virtual): Use target_float_convert.
1024 (sh_register_convert_to_raw): Likewise.
1025 * sh64-tdep.c: Include "target-float.h".
1026 (sh64_extract_return_value): Use target_float_convert.
1027 (sh64_register_convert_to_virtual): Likewise.
1028 (sh64_register_convert_to_raw): Likewise. Fix argument types.
1030 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1032 * target-float.c (floatformat_to_host_double): New function.
1033 (floatformat_from_host_double): Likewise.
1034 (target_float_to_host_double): Likewise.
1035 (target_float_from_host_double): Likewise.
1036 * target-float.h (target_float_to_host_double): Add prototype.
1037 (target_float_from_host_double): Likewise.
1039 * guile/scm-value.c: Include "target-float.h".
1040 (gdbscm_value_to_real): Use target_float_to_host_double.
1041 Handle integer source values via value_as_long.
1042 * guile/scm-math.c: Include "target-float.h". Do not include
1043 "doublest.h", "dfp.h", and "expression.h".
1044 (vlscm_convert_typed_number): Use target_float_from_host_double.
1045 (vlscm_convert_number): Likewise.
1047 * python/py-value.c (valpy_float): Use target_float_to_host_double.
1048 (convert_value_from_python): Use target_float_from_host_double.
1050 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1052 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
1053 (cast_from_fixed): Likewise.
1054 (ada_scaling_type): New function.
1055 (ada_delta): Return value instead of DOUBLEST. Perform target
1056 arithmetic instead of host arithmetic.
1057 (scaling_factor): Rename to ...
1058 (ada_scaling_factor) ... this. Make non-static. Return value instead
1059 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
1060 (ada_fixed_to_float): Remove.
1061 (ada_float_to_fixed): Remove.
1062 * ada-lang.h (ada_fixed_to_float): Remove.
1063 (ada_float_to_fixed): Remove.
1064 (ada_delta): Return value instead of DOUBLEST.
1065 (ada_scaling_factor): Add prototype.
1067 * ada-typeprint.c: Include "target-float.h".
1068 (print_fixed_point_type): Perform target arithmetic instead of
1070 * ada-valprint.c: Include "target-float.h".
1071 (ada_val_print_num): Perform target arithmetic instead of
1072 host arithmetic for fixed-point types.
1074 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1076 * target-float.c: Include <math.h>.
1077 (floatformat_binop): New function.
1078 (floatformat_compare): Likewise.
1079 (target_float_binop): Likewise.
1080 (target_float_compare): Likewise.
1081 * target-float.h: Include "expression.h".
1082 (target_float_binop): Add prototype.
1083 (target_float_compare): Likewise.
1085 * valarith.c: Do not include "doublest.h" and "dfp.h".
1086 Include "common/byte-vector.h".
1087 (value_args_as_decimal): Remove, replace by ...
1088 (value_args_as_target_float): ... this function. Handle both
1089 binary and decimal target floating-point formats.
1090 (scalar_binop): Handle both binary and decimal FP using
1091 value_args_as_target_float and target_float_binop.
1092 (value_equal): Handle both binary and decimal FP using
1093 value_args_as_target_float and target_float_compare.
1094 (value_less): Likewise.
1095 (value_pos): Handle all scalar types as simple copy.
1096 (value_neg): Handle all scalar types via BINOP_SUB from 0.
1097 * dfp.c (decimal_binop): Throw error instead of internal_error
1098 when called with an unsupported operation code.
1100 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1102 * target-float.c (target_float_to_string): New function.
1103 (target_float_from_string): New function.
1104 * target-float.h (target_float_to_string): Add prototype.
1105 (target_float_from_string): Add prototype.
1107 * valprint.c: Include "target-float.h". Do not include
1108 "doublest.h" and "dfp.h".
1109 (print_floating): Use target_float_to_string.
1110 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
1111 (printf_floating): Use target_float_to_string.
1112 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
1113 (print_i387_value): Use target_float_to_string.
1114 * mips-tdep.c: Include "target-float.h".
1115 (mips_print_fp_register): Use target_float_to_string.
1116 * sh64-tdep.c: Include "target-float.h".
1117 (sh64_do_fp_register): Use target_float_to_string.
1119 * parse.c: Include "target-float.h". Do not include
1120 "doublest.h" and "dfp.h".
1121 (parse_float): Use target_float_from_string.
1122 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
1123 (define_symbol): Use target_float_from_string.
1124 * gdbarch-selftests.c: Include "target-float.h".
1125 (register_to_value_test): Use target_float_from_string.
1127 2017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1129 * Makefile.c (SFILES): Add target-float.c.
1130 (HFILES_NO_SRCDIR): Add target-float.h.
1131 (COMMON_OBS): Add target-float.o.
1132 * target-float.h: New file.
1133 * target-float.c: New file.
1135 * doublest.c (floatformat_classify): Fix detection of float_zero.
1137 * gdbtypes.c (is_floating_type): New function.
1138 * gdbtypes.h (is_floating_type): Add prototype.
1140 * value.c: Do not include "floatformat.h".
1141 (unpack_double): Use target_float_is_valid.
1142 (is_floating_value): New function.
1143 * value.h (is_floating_value): Add prototype-
1145 * valarith.c: Include "target-float.h".
1146 (value_logical_not): Use target_float_is_zero.
1148 * python/py-value.c: Include "target-float.h".
1149 (valpy_nonzero): Use target_float_is_zero.
1151 2017-11-04 Tom Tromey <tom@tromey.com>
1153 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
1155 2017-11-04 Tom Tromey <tom@tromey.com>
1157 * breakpoint.c (set_momentary_breakpoint): Return
1159 (until_break_command): Update.
1160 (new_until_break_fsm): Change argument types to
1162 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1163 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
1165 * infcmd.c (finish_forward): Update.
1166 * breakpoint.h (set_momentary_breakpoint)
1167 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1168 (make_cleanup_delete_breakpoint): Remove.
1169 (struct breakpoint_deleter): New.
1170 (breakpoint_up): New typedef.
1171 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
1172 (insert_exception_resume_breakpoint): Update.
1173 (insert_exception_resume_from_probe): Update.
1174 (insert_longjmp_resume_breakpoint): Update.
1175 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
1176 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
1177 * infcall.c (call_function_by_hand_dummy): Update
1179 2017-11-04 Tom Tromey <tom@tromey.com>
1181 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
1183 2017-11-04 Tom Tromey <tom@tromey.com>
1185 * linux-tdep.c (linux_core_info_proc_mappings): Use
1187 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
1189 (linux_corefile_thread): Update.
1190 (linux_make_corefile_notes): Remove unused variable.
1192 2017-11-04 Tom Tromey <tom@tromey.com>
1194 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
1197 2017-11-04 Tom Tromey <tom@tromey.com>
1199 * objfiles.c (do_free_objfile_cleanup): Remove.
1200 * compile/compile-object-load.c (compile_object_load): Update.
1201 * objfiles.h (make_cleanup_free_objfile): Remove.
1203 2017-11-04 Tom Tromey <tom@tromey.com>
1205 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
1206 (adi_read_versions): Change "tags" to "gdb_byte *".
1207 (adi_print_versions): Likewise.
1209 2017-11-04 Tom Tromey <tom@tromey.com>
1212 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
1213 from start_rbreak_breakpoints.
1214 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
1215 * breakpoint.h (class scoped_rbreak_breakpoints): New.
1216 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
1217 * symtab.c (do_end_rbreak_breakpoints): Remove.
1218 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
1220 2017-11-04 Tom Tromey <tom@tromey.com>
1222 * cp-namespace.c (reset_directive_searched): Remove.
1223 (cp_lookup_symbol_via_imports): Use scoped_restore.
1224 * cp-support.c (reset_directive_searched): Remove.
1225 (make_symbol_overload_list_using): Use scoped_restore.
1226 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
1227 (reset_directive_searched): Remove.
1229 2017-11-04 Tom Tromey <tom@tromey.com>
1231 * symfile.c (find_separate_debug_file_by_debuglink): Use
1234 2017-11-04 Tom Tromey <tom@tromey.com>
1236 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
1238 (compute_stack_depth): Likewise.
1239 (do_compile_dwarf_expr_to_c): Use std::vector.
1241 2017-11-04 Tom Tromey <tom@tromey.com>
1243 * compile/compile-object-load.c (link_callbacks_einfo): Use
1246 2017-11-04 Tom Tromey <tom@tromey.com>
1248 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1249 Use scoped_free_pendings.
1250 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
1251 scoped_free_pendings.
1252 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
1253 (xcoff_initial_scan): Likewise.
1254 * buildsym.c (reset_symtab_globals): Update comment.
1255 (scoped_free_pendings): Rename from really_free_pendings.
1256 (prepare_for_building): Update comment.
1257 (buildsym_init): Likewise.
1258 * buildsym.h (class scoped_free_pendings): New class.
1259 (really_free_pendings): Don't declare.
1261 2017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
1263 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
1264 output when converting a zero value to a special byteorder format.
1266 2017-11-02 Yao Qi <yao.qi@linaro.org>
1268 * frame.c (do_frame_register_read): Remove aspace.
1269 * jit.c (jit_frame_sniffer): Likwise.
1270 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1271 * regcache.c (regcache::regcache): Pass nullptr.
1272 (regcache_print): Caller updated.
1273 * regcache.h (regcache::regcache): Remove one constructor
1276 2017-11-02 Yao Qi <yao.qi@linaro.org>
1278 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
1280 2017-11-02 Yao Qi <yao.qi@linaro.org>
1282 * breakpoint.c (insert_single_step_breakpoints): Update.
1283 * frame.c (struct frame_info) <aspace>: Add const.
1284 (frame_save_as_regcache): Add const.
1285 (get_frame_address_space): Return const address_space *.
1286 * frame.h (get_frame_address_space): Update declaration.
1287 * infrun.c (struct step_over_info) <aspace>: Add const.
1288 (set_step_over_info): Make aspace const.
1289 (displaced_step_prepare_throw): Change variable const.
1291 (proceed): Likewise.
1292 (adjust_pc_after_break): Likewise.
1293 (save_waitstatus): Likewise.
1294 (handle_signal_stop): Likewise.
1295 (keep_going_pass_signal): Likewise.
1296 * jit.c (jit_frame_sniffer): Add const.
1297 * mips-tdep.c (mips_single_step_through_delay): Likewise.
1298 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1299 * record-full.c (record_full_wait_1): Likewise.
1300 * regcache.c (regcache::regcache): Change parameter to const.
1301 * regcache.h (regcache::regcache): Likewise.
1302 (regcache::aspace): Return const address_space *.
1303 (regcache) <m_aspace>: Add const.
1305 2017-11-02 Yao Qi <yao.qi@linaro.org>
1307 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
1308 * frame.c (create_sentinel_frame): Likewise.
1309 * infrun.c (displaced_step_prepare_throw): Likewise.
1311 (thread_still_needs_step_over_bp): Likewise.
1312 (proceed): Likewise.
1313 (do_target_wait): Likewise.
1314 (adjust_pc_after_break): Likewise.
1315 (handle_syscall_event): Likewise.
1316 (save_waitstatus): Likewise.
1317 (handle_inferior_event_1): Likewise.
1318 (handle_signal_stop): Likewise.
1319 (keep_going_pass_signal): Likewise.
1320 * linux-nat.c (status_callback): Likewise.
1321 (save_stop_reason): Likewise.
1322 (resume_stopped_resumed_lwps): Likewise.
1323 * record-full.c (record_full_exec_insn): Likewise.
1324 (record_full_wait_1): Likewise.
1325 * regcache.c (get_regcache_aspace): Remove.
1326 * regcache.h (get_regcache_aspace): Remove.
1328 2017-11-02 Yao Qi <yao.qi@linaro.org>
1330 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
1331 (init_regcache_descr): Use gdbarch_num_regs.
1332 (regcache::regcache): Likewise.
1333 (regcache::get_register_status): Likewise.
1334 (regcache::assert_raw_regnum): Likewise.
1335 (regcache::cooked_read): Likewise.
1336 (regcache::cooked_read_value): Likewise.
1337 (regcache::cooked_write): Likewise.
1338 (regcache::dump): Likewise.
1339 (regcache::num_raw_registers): New method.
1340 * regcache.h (class regcache) <num_raw_registers>: New.
1342 2017-11-02 Yao Qi <yao.qi@linaro.org>
1344 * regcache.c (regcache::assert_regnum): New method.
1345 (regcache::invalidate): Call assert_regnum.
1346 (regcache::raw_update): Likewise.
1347 (regcache::raw_write): Likewise.
1348 (regcache::raw_read_part): Likewise.
1349 (regcache::raw_write_part): Likewise.
1350 (regcache::raw_supply): Likewise.
1351 (regcache::raw_supply_integer): Likewise.
1352 (regcache::raw_supply_zeroed): Likewise.
1353 (regcache::raw_collect): Likewise.
1354 (regcache::raw_collect_integer): Likewise.
1355 * regcache.h (regcache::assert_regnum): Declare.
1357 2017-11-02 Yao Qi <yao.qi@linaro.org>
1359 * regcache.c (regcache::dump): Remove code.
1361 2017-11-02 Yao Qi <yao.qi@linaro.org>
1363 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
1365 <sizeof_cooked_register_status>: Remove.
1366 (init_regcache_descr): Update.
1367 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
1368 (regcache::save): Likewise.
1369 (regcache::dump): Likewise.
1371 2017-11-01 James Bowman <james.bowman@ftdichip.com>
1373 * ft32-tdep.c (ft32_fetch_instruction): New function.
1374 (ft32_analyze_prologue): Use ft32_fetch_instruction().
1376 2017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
1378 * cli/cli-script.c (execute_control_command): Rename to ...
1379 (execute_control_command_1): ... this.
1380 (execute_control_command): New function.
1382 2017-10-31 Simon Marchi <simon.marchi@ericsson.com>
1384 * tracepoint.c (tfind_command): Remove const_cast.
1386 2017-10-30 Mike Gulick <mgulick@mathworks.com>
1388 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
1390 2017-10-30 Simon Marchi <simon.marchi@ericsson.com>
1392 * common/common-utils.h (in_inclusive_range): New function.
1393 * arm-tdep.c (arm_record_extension_space): Use
1395 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
1396 * cris-tdep.c (cris_spec_reg_applicable): Use
1399 2017-10-30 Pedro Alves <palves@redhat.com>
1400 Simon Marchi <simon.marchi@ericsson.com>
1402 * remote.c (remote_set_syscall_catchpoint): Build a std::string
1403 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
1405 2017-10-30 Pedro Alves <palves@redhat.com>
1407 * common/common-utils.c (string_appendf, string_vappendf): New
1409 * common/common-utils.h (string_appendf, string_vappendf): New
1411 * unittests/common-utils-selftests.c (string_appendf_func)
1412 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
1413 (string_vappendf_tests): New functions.
1414 (_initialize_common_utils_selftests): Register "string_appendf" and
1415 "string_vappendf tests".
1417 2017-10-30 Pedro Alves <palves@redhat.com>
1419 * unittests/common-utils-selftests.c (format_func): New typedef.
1420 (string_printf_tests, string_vprintf_tests): Tests factored out
1422 (test_format_func): ... this new function.
1423 (string_printf_tests, string_vprintf_tests): Reimplement on top of
1426 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1428 * darwin-nat.c: Remove include of gdb.h.
1430 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1432 * xtensa-xtregs.c: Fix formatting issues.
1434 2017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1436 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
1438 2017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
1441 * python/py-infthread.c (thpy_get_inferior): Increment reference
1442 of inferior before returning it.
1444 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1446 * unittests/common-utils-selftests.c (format): Add
1449 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1451 * xml-syscall.c (struct syscall_desc): Add constructor.
1452 <name>: Change type to std::string.
1453 (syscall_desc_up): New typedef.
1454 (syscall_desc_p): Remove typeder.
1455 (DEF_VEC_P(syscall_desc_p)): Remove.
1456 (struct syscall_group_desc): Add constructor.
1457 <name>: Change type to std::string.
1458 <syscalls>: Change type to std::vector.
1459 (syscall_group_desc_up): New typedef.
1460 (syscall_group_desc_p): Remove typedef.
1461 (DEF_VEC_P(syscall_group_desc_p)): Remove.
1462 (struct syscalls_info) <syscalls>: Change type to std::vector of
1465 <my_gdb_datadir>: Change type to std::string.
1466 (syscalls_info_up): New typedef.
1467 (allocate_syscalls_info): Remove.
1468 (syscalls_info_free_syscalls_desc): Remove.
1469 (syscalls_info_free_syscall_group_desc): Remove.
1470 (free_syscalls_info): Remove.
1471 (make_cleanup_free_syscalls_info): Remove.
1472 (syscall_group_create_syscall_group_desc): Adjust.
1473 (syscall_group_add_syscall): Adjust.
1474 (syscall_create_syscall_desc): Adjust.
1475 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
1476 (init_syscalls_info): Adjust.
1477 (syscall_group_get_group_by_name): Adjust.
1478 (xml_get_syscall_number): Adjust.
1479 (xml_get_syscall_name): Adjust.
1480 (xml_list_of_syscalls): Adjust.
1481 (xml_list_syscalls_by_group): Adjust.
1482 (xml_list_of_groups): Adjust.
1484 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1486 * probe.h: Don't include gdb_vecs.h.
1487 (DEF_VEC_P (probe_p)): Remove.
1488 (find_probes_in_objfile): Return an std::vector.
1489 * probe.c (find_probes_in_objfile): Likewise.
1490 * breakpoint.c (breakpoint_objfile_data)
1491 <longjmp_probes>: Change type to std::vector.
1492 <exception_probes>: Likewise.
1493 (free_breakpoint_probes): Don't manually free vectors.
1494 (create_longjmp_master_breakpoint): Adjust.
1495 (create_exception_master_breakpoint): Adjust.
1496 * solib-svr4.c (svr4_create_probe_breakpoints): Change
1497 parameter type, adjust.
1498 (svr4_create_solib_event_breakpoints): Adjust.
1500 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1502 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
1503 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
1505 (free_breakpoint_probes): Rename to ...
1506 (free_breakpoint_objfile_data): ... this, and call delete on
1509 2017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1511 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
1512 (loaded_script_ptr): Remove typedef.
1513 (DEF_VEC_P (loaded_script_ptr)): Remove.
1514 (struct collect_matching_scripts_data): Add constructor.
1515 <scripts_p>: Change type to (pointer to) std::vector.
1516 (collect_matching_scripts_data): Adjust.
1517 (sort_scripts_by_name): Make suitable for std::sort.
1518 (print_scripts): Don't sort vector, adjust to std::vector.
1519 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
1521 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1523 * symfile.c (filename_language): Make struct, not typedef. Add
1525 <ext>: Change type to std::string.
1526 (DEF_VEC_O (filename_language)): Remove.
1527 (filename_language_table): Change type to std::vector.
1528 (add_filename_language): Adjust.
1529 (set_ext_lang_command): Adjust.
1530 (info_ext_lang_command): Adjust.
1531 (deduce_language_from_filename): Adjust.
1532 (class scoped_restore_filename_language_table): Remove.
1533 (test_filename_language): Use scoped_restore.
1534 (test_set_ext_lang_command): Use scoped_restore, adjust to
1537 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1539 * symfile.c: Include selftest.h.
1540 (class scoped_restore_filename_language_table): New.
1541 (test_filename_language): New test.
1542 (test_set_ext_lang_command): New test.
1543 (_initialize_symfile): Register tests.
1545 2017-10-27 Keith Seitz <keiths@redhat.com>
1547 * breakpoint.c (print_breakpoint_location): Use the symbol saved
1548 in the bp_location, falling back to find_pc_sect_function when
1550 (add_location_to_breakpoint): Save sal->symbol.
1551 * breakpoint.h (struct bp_location) <symbol>: New field.
1552 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
1553 * symtab.h (struct symtab_and_line) <symbol>: New field.
1555 2017-10-26 Patrick Frants <osscontribute@gmail.com>
1558 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
1561 2017-10-26 Pedro Alves <palves@redhat.com>
1563 * remote.c (remote_async_terminal_ours_p): Delete.
1564 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
1565 Remove references to 'remote_async_terminal_ours_p'.
1567 2017-10-26 Yao Qi <yao.qi@linaro.org>
1569 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
1571 2017-10-26 Yao Qi <yao.qi@linaro.org>
1573 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
1575 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
1577 * breakpoint.c (bpstat_check_location): Remove cast.
1578 (breakpoint_hit_catch_fork): Make aspce const.
1579 (breakpoint_hit_catch_solib): Likewise.
1580 (breakpoint_hit_catch_exec): Likewise.
1581 (breakpoint_hit_ranged_breakpoint): Likewise.
1582 (breakpoint_hit_watchpoint): Likewise.
1583 (base_breakpoint_breakpoint_hit): Likewise.
1584 (bkpt_breakpoint_hit): Likewise.
1585 (dprintf_breakpoint_hit): Likewise.
1586 (tracepoint_breakpoint_hit): Likewise.
1587 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
1589 2017-10-26 Yao Qi <yao.qi@linaro.org>
1591 * breakpoint.c (breakpoint_location_address_match): Change
1592 "struct address_space *" to "const address_space".
1593 (breakpoint_location_address_range_overlap): Likewise.
1594 (breakpoint_here_p): Likewise.
1595 (breakpoint_in_range_p): Likewise.
1596 (moribund_breakpoint_here_p): Likewise.
1597 (bp_location_inserted_here_p): Likewise.
1598 (software_breakpoint_inserted_here_p): Likewise.
1599 (hardware_breakpoint_inserted_here_p): Likewise.
1600 (hardware_watchpoint_inserted_in_range): Likewise.
1601 (bpstat_check_location): Likewise.
1602 (bpstat_stop_status): Likewise.
1603 (breakpoint_address_match): Likewise.
1604 (breakpoint_address_match_range): Likewise.
1605 (breakpoint_location_address_match): Likewise.
1606 (breakpoint_location_address_range_overlap): Likewise.
1607 (insert_single_step_breakpoint): Likewise.
1608 (breakpoint_has_location_inserted_here): Likewise.
1609 (single_step_breakpoint_inserted_here_p): Likewise.
1610 (pc_at_non_inline_function): Likewise.
1611 * breakpoint.h (bpstat_stop_status): Update declaration.
1612 (breakpoint_here_p): Likewise.
1613 (breakpoint_in_range_p): Likewise.
1614 (moribund_breakpoint_here_p): Likewise.
1615 (breakpoint_inserted_here_p): Likewise.
1616 (software_breakpoint_inserted_here_p): Likewise.
1617 (hardware_breakpoint_inserted_here_p): Likewise.
1618 (breakpoint_has_location_inserted_here): Likewise.
1619 (single_step_breakpoint_inserted_here_p): Likewise.
1620 (hardware_watchpoint_inserted_in_range): Likewise.
1621 (breakpoint_address_match): Likewise.
1622 (insert_single_step_breakpoint): Likewise.
1623 (pc_at_non_inline_function): Likewise.
1624 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
1625 * record.c (record_check_stopped_by_breakpoint): Likewise.
1626 * record.h (record_check_stopped_by_breakpoint): Likewise.
1627 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
1629 2017-10-25 Yao Qi <yao.qi@linaro.org>
1631 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
1632 regcache->arch () instead get_regcache_arch.
1633 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
1635 (aarch64_fbsd_store_inferior_registers): Likewise.
1636 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
1637 (store_gregs_to_thread): Likewise.
1638 (fetch_fpregs_from_thread): Likewise.
1639 (store_fpregs_to_thread): Likewise.
1640 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
1641 (aarch64_store_return_value): Likewise.
1642 (aarch64_software_single_step): Likewise.
1643 * aix-thread.c (aix_thread_wait): Likewise.
1644 (supply_reg32): Likewise.
1645 (supply_sprs64): Likewise.
1646 (supply_sprs32): Likewise.
1647 (fill_gprs64): Likewise.
1648 (fill_gprs32): Likewise.
1649 (fill_sprs64): Likewise.
1650 (fill_sprs32): Likewise.
1651 (store_regs_user_thread): Likewise.
1652 (store_regs_kernel_thread): Likewise.
1653 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
1654 (alphabsd_store_inferior_registers): Likewise.
1655 * alpha-tdep.c (alpha_extract_return_value): Likewise.
1656 (alpha_store_return_value): Likewise.
1657 (alpha_deal_with_atomic_sequence): Likewise.
1658 (alpha_next_pc): Likewise.
1659 (alpha_software_single_step): Likewise.
1660 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
1661 (amd64bsd_store_inferior_registers): Likewise.
1662 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
1664 (amd64_linux_store_inferior_registers): Likewise.
1665 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
1666 (amd64_collect_native_gregset): Likewise.
1667 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
1668 (amd64obsd_collect_uthread): Likewise.
1669 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
1670 (amd64_collect_fpregset): Likewise.
1671 (amd64_supply_fxsave): Likewise.
1672 (amd64_supply_xsave): Likewise.
1673 (amd64_collect_fxsave): Likewise.
1674 (amd64_collect_xsave): Likewise.
1675 * arc-tdep.c (arc_write_pc): Likewise.
1676 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
1677 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
1678 (arm_fbsd_store_inferior_registers): Likewise.
1679 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
1680 (store_vfp_regs): Likewise.
1681 (arm_linux_fetch_inferior_registers): Likewise.
1682 (arm_linux_store_inferior_registers): Likewise.
1683 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
1684 (arm_linux_sigreturn_next_pc): Likewise.
1685 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
1686 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
1687 (fetch_register): Likewise.
1688 (store_register): Likewise.
1689 * arm-tdep.c (arm_is_thumb): Likewise.
1690 (displaced_in_arm_mode): Likewise.
1691 (bx_write_pc): Likewise.
1692 (arm_get_next_pcs_addr_bits_remove): Likewise.
1693 (arm_software_single_step): Likewise.
1694 (arm_extract_return_value): Likewise.
1695 (arm_store_return_value): Likewise.
1696 (arm_write_pc): Likewise.
1697 * bfin-tdep.c (bfin_extract_return_value): Likewise.
1698 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
1699 (bsd_uthread_store_registers): Likewise.
1700 * core-regset.c (fetch_core_registers): Likewise.
1701 * corelow.c (get_core_registers): Likewise.
1702 * cris-tdep.c (cris_store_return_value): Likewise.
1703 (cris_extract_return_value): Likewise.
1704 (find_step_target): Likewise.
1705 (find_step_target): Likewise.
1706 (cris_software_single_step): Likewise.
1707 * ctf.c (ctf_fetch_registers): Likewise.
1708 * darwin-nat.c (cancel_breakpoint): Likewise.
1709 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
1710 * frv-tdep.c (frv_extract_return_value): Likewise.
1711 * ft32-tdep.c (ft32_store_return_value): Likewise.
1712 (ft32_extract_return_value): Likewise.
1713 * go32-nat.c (fetch_register): Likewise.
1714 (go32_fetch_registers): Likewise.
1715 (go32_store_registers): Likewise.
1716 (store_register): Likewise.
1717 * h8300-tdep.c (h8300_extract_return_value): Likewise.
1718 (h8300_store_return_value): Likewise.
1719 * hppa-linux-nat.c (fetch_register): Likewise.
1720 (store_register): Likewise.
1721 (hppa_linux_fetch_inferior_registers): Likewise.
1722 (hppa_linux_store_inferior_registers): Likewise.
1723 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
1724 (i386_darwin_store_inferior_registers): Likewise.
1725 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
1726 (gnu_store_registers): Likewise.
1727 * i386-linux-nat.c (fetch_register): Likewise.
1728 (store_register): Likewise.
1729 (supply_gregset): Likewise.
1730 (fill_gregset): Likewise.
1731 (i386_linux_fetch_inferior_registers): Likewise.
1732 (i386_linux_store_inferior_registers): Likewise.
1733 (i386_linux_resume): Likewise.
1734 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
1736 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
1737 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
1738 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
1739 (i386obsd_collect_uthread): Likewise.
1740 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1741 (i386_supply_gregset): Likewise.
1742 (i386_collect_gregset): Likewise.
1743 (i386_supply_fpregset): Likewise.
1744 (i386_collect_fpregset): Likewise.
1745 (i386_mpx_bd_base): Likewise.
1746 * i386-v4-nat.c (supply_fpregset): Likewise.
1747 (fill_fpregset): Likewise.
1748 * i387-tdep.c (i387_supply_fsave): Likewise.
1749 (i387_collect_fsave): Likewise.
1750 (i387_supply_fxsave): Likewise.
1751 (i387_collect_fxsave): Likewise.
1752 (i387_supply_xsave): Likewise.
1753 (i387_collect_xsave): Likewise.
1754 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
1755 (ia64_linux_store_registers): Likewise.
1756 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
1757 (ia64_extract_return_value): Likewise.
1758 (ia64_store_return_value): Likewise.
1759 (find_func_descr): Likewise.
1760 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
1761 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
1762 (inf_ptrace_store_registers): Likewise.
1763 * infrun.c (use_displaced_stepping): Likewise.
1764 (displaced_step_prepare_throw): Likewise.
1766 (proceed): Likewise.
1767 (do_target_wait): Likewise.
1768 (adjust_pc_after_break): Likewise.
1769 (handle_inferior_event_1): Likewise.
1770 (handle_signal_stop): Likewise.
1771 (save_infcall_suspend_state): Likewise.
1772 (restore_infcall_suspend_state): Likewise.
1773 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
1774 * jit.c (jit_frame_prev_register): Likewise.
1775 * linux-nat.c (save_stop_reason): Likewise.
1776 (linux_nat_wait_1): Likewise.
1777 (resume_stopped_resumed_lwps): Likewise.
1778 * linux-record.c (record_linux_sockaddr): Likewise.
1779 (record_linux_msghdr): Likewise.
1780 (record_linux_system_call): Likewise.
1781 * linux-tdep.c (linux_collect_thread_registers): Likewise.
1782 * lm32-tdep.c (lm32_extract_return_value): Likewise.
1783 (lm32_store_return_value): Likewise.
1784 * m32c-tdep.c (m32c_read_flg): Likewise.
1785 (m32c_pseudo_register_read): Likewise.
1786 (m32c_pseudo_register_write): Likewise.
1787 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
1788 (m32r_linux_collect_gregset): Likewise.
1789 * m32r-tdep.c (m32r_store_return_value): Likewise.
1790 (m32r_extract_return_value): Likewise.
1791 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
1792 (m68kbsd_collect_fpregset): Likewise.
1793 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
1794 * m68k-linux-nat.c (fetch_register): Likewise.
1795 (old_fetch_inferior_registers): Likewise.
1796 (old_store_inferior_registers): Likewise.
1797 (store_regs): Likewise.
1798 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
1799 (m68k_svr4_store_return_value): Likewise.
1800 * m88k-tdep.c (m88k_store_arguments): Likewise.
1801 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
1802 (mi_cmd_data_write_register_values): Likewise.
1803 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
1804 (mips_fbsd_store_inferior_registers): Likewise.
1805 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
1806 (mips_fbsd_supply_gregs): Likewise.
1807 (mips_fbsd_collect_fpregs): Likewise.
1808 (mips_fbsd_collect_gregs): Likewise.
1809 (mips_fbsd_supply_fpregset): Likewise.
1810 (mips_fbsd_collect_fpregset): Likewise.
1811 (mips_fbsd_supply_gregset): Likewise.
1812 (mips_fbsd_collect_gregset): Likewise.
1813 * mips-linux-nat.c (supply_gregset): Likewise.
1814 (fill_gregset): Likewise.
1815 (supply_fpregset): Likewise.
1816 (fill_fpregset): Likewise.
1817 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
1818 (mips_fill_gregset): Likewise.
1819 (mips_supply_fpregset): Likewise.
1820 (mips_fill_fpregset): Likewise.
1821 (mips64_supply_gregset): Likewise.
1822 (micromips_linux_sigframe_validate): Likewise.
1823 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
1824 (mipsnbsd_fetch_inferior_registers): Likewise.
1825 (mipsnbsd_store_inferior_registers): Likewise.
1826 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
1827 (mipsnbsd_supply_gregset): Likewise.
1828 (mipsnbsd_iterate_over_regset_sections): Likewise.
1829 (mipsnbsd_supply_reg): Likewise.
1830 (mipsnbsd_supply_fpreg): Likewise.
1831 * mips-tdep.c (mips_in_frame_stub): Likewise.
1832 (mips_dummy_id): Likewise.
1833 (is_octeon_bbit_op): Likewise.
1834 (micromips_bc1_pc): Likewise.
1835 (extended_mips16_next_pc): Likewise.
1836 (mips16_next_pc): Likewise.
1837 (deal_with_atomic_sequence): Likewise.
1838 * moxie-tdep.c (moxie_process_readu): Likewise.
1839 * nios2-tdep.c (nios2_get_next_pc): Likewise.
1840 * nto-procfs.c (procfs_store_registers): Likewise.
1841 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
1842 (ppcfbsd_store_inferior_registers): Likewise.
1843 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
1844 (fetch_altivec_register): Likewise.
1845 (get_spe_registers): Likewise.
1846 (fetch_spe_register): Likewise.
1847 (fetch_altivec_registers): Likewise.
1848 (fetch_all_gp_regs): Likewise.
1849 (fetch_all_fp_regs): Likewise.
1850 (store_vsx_register): Likewise.
1851 (store_altivec_register): Likewise.
1852 (set_spe_registers): Likewise.
1853 (store_spe_register): Likewise.
1854 (store_altivec_registers): Likewise.
1855 (store_all_gp_regs): Likewise.
1856 (store_all_fp_regs): Likewise.
1857 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
1858 (ppc_linux_collect_gregset): Likewise.
1859 (ppc_canonicalize_syscall): Likewise.
1860 (ppc_linux_record_signal): Likewise.
1861 (ppu2spu_prev_register): Likewise.
1862 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
1863 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
1864 (ppcobsd_store_registers): Likewise.
1865 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
1867 (ppc_ravenscar_generic_store_registers): Likewise.
1868 * procfs.c (procfs_fetch_registers): Likewise.
1869 (procfs_store_registers): Likewise.
1870 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
1871 (ravenscar_store_registers): Likewise.
1872 (ravenscar_prepare_to_store): Likewise.
1873 * record-btrace.c (record_btrace_fetch_registers): Likewise.
1874 * record-full.c (record_full_wait_1): Likewise.
1875 (record_full_registers_change): Likewise.
1876 (record_full_store_registers): Likewise.
1877 (record_full_core_fetch_registers): Likewise.
1878 (record_full_save): Likewise.
1879 (record_full_goto_insn): Likewise.
1880 * regcache.c (regcache_register_size): Likewise.
1881 (get_regcache_arch): Remove.
1882 (regcache_read_pc): Likewise.
1883 * regcache.h (get_regcache_arch): Remove.
1884 * remote-sim.c (gdbsim_fetch_register): Likewise.
1885 (gdbsim_store_register): Likewise.
1886 * remote.c (fetch_register_using_p): Likewise.
1887 (send_g_packet): Likewise.
1888 (remote_prepare_to_store): Likewise.
1889 (store_registers_using_G): Likewise.
1890 * reverse.c (save_bookmark_command): Likewise.
1891 (goto_bookmark_command): Likewise.
1892 * rs6000-aix-tdep.c (branch_dest): Likewise.
1893 * rs6000-nat.c (rs6000_ptrace64): Likewise.
1894 (fetch_register): Likewise.
1895 * rs6000-tdep.c (ppc_supply_reg): Likewise.
1896 (ppc_collect_reg): Likewise.
1897 (ppc_collect_gregset): Likewise.
1898 (ppc_collect_fpregset): Likewise.
1899 (ppc_collect_vsxregset): Likewise.
1900 (ppc_collect_vrregset): Likewise.
1901 (ppc_displaced_step_hw_singlestep): Likewise.
1902 (rs6000_pseudo_register_read): Likewise.
1903 (rs6000_pseudo_register_write): Likewise.
1904 * s390-linux-nat.c (supply_gregset): Likewise.
1905 (fill_gregset): Likewise.
1906 (s390_linux_fetch_inferior_registers): Likewise.
1907 * s390-linux-tdep.c (s390_write_pc): Likewise.
1908 (s390_software_single_step): Likewise.
1909 (s390_all_but_pc_registers_record): Likewise.
1910 (s390_linux_syscall_record): Likewise.
1911 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
1912 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
1913 (shnbsd_store_inferior_registers): Likewise.
1914 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
1915 (sh_extract_return_value_fpu): Likewise.
1916 (sh_store_return_value_nofpu): Likewise.
1917 (sh_corefile_supply_regset): Likewise.
1918 (sh_corefile_collect_regset): Likewise.
1919 * sh64-tdep.c (sh64_extract_return_value): Likewise.
1920 (sh64_store_return_value): Likewise.
1921 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
1922 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
1923 (sparc_store_inferior_registers): Likewise.
1924 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
1925 (sparc_ravenscar_prepare_to_store): Likewise.
1926 * sparc-tdep.c (sparc32_store_arguments): Likewise.
1927 (sparc_analyze_control_transfer): Likewise.
1928 (sparc_step_trap): Likewise.
1929 (sparc_software_single_step): Likewise.
1930 (sparc32_gdbarch_init): Likewise.
1931 (sparc_supply_rwindow): Likewise.
1932 (sparc_collect_rwindow): Likewise.
1933 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
1934 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
1935 (sparc64nbsd_collect_gregset): Likewise.
1936 (sparc64nbsd_supply_fpregset): Likewise.
1937 (sparc64nbsd_collect_fpregset): Likewise.
1938 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
1939 (sparc64_supply_gregset): Likewise.
1940 (sparc64_collect_gregset): Likewise.
1941 (sparc64_supply_fpregset): Likewise.
1942 (sparc64_collect_fpregset): Likewise.
1943 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
1944 * spu-tdep.c (spu_unwind_sp): Likewise.
1945 (spu2ppu_prev_register): Likewise.
1946 (spu_memory_remove_breakpoint): Likewise.
1947 * stack.c (return_command): Likewise.
1948 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
1949 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
1950 * tracefile.c (trace_save_ctf): Likewise.
1951 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
1952 (do_windows_store_inferior_registers): Likewise.
1953 (windows_resume): Likewise.
1954 * xtensa-linux-nat.c (fill_gregset): Likewise.
1955 (supply_gregset_reg): Likewise.
1956 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
1957 (xtensa_register_read_masked): Likewise.
1958 (xtensa_supply_gregset): Likewise.
1959 (xtensa_extract_return_value): Likewise.
1960 (xtensa_store_return_value): Likewise.
1962 2017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
1964 * doublest.c (floatformat_from_string): New function.
1965 * doublest.h (floatformat_from_string): Add prototype.
1967 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
1968 (OP_FLOAT): ... this.
1969 * expression.h: Do not include "doublest.h".
1970 (union exp_element): Replace doubleconst and decfloatconst by
1971 new element floatconst.
1972 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
1973 (ada_evaluate_subexp): Likewise.
1974 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
1975 OP_DOUBLE and OP_DECFLOAT.
1976 * expprint.c (print_subexp_standard): Likewise.
1977 (dump_subexp_body_standard): Likewise.
1978 * breakpoint.c (watchpoint_exp_is_const): Likewise.
1980 * parse.c: Include "dfp.h".
1981 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
1982 (write_exp_elt_floatcst): New function.
1983 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
1985 (operator_check_standard): Likewise.
1986 (parse_float): Do not accept suffix. Take type as input. Return bool.
1987 Return target format buffer instead of host DOUBLEST.
1988 Use floatformat_from_string and decimal_from_string to parse
1989 either binary or decimal floating-point types.
1990 (parse_c_float): Remove.
1991 * parser-defs.h: Do not include "doublest.h".
1992 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
1993 (write_exp_elt_floatcst): Add prototype.
1994 (parse_float): Update prototype.
1995 (parse_c_float): Remove.
1997 * c-exp.y: Do not include "dfp.h".
1998 (typed_val_float): Use byte buffer instead of DOUBLEST.
1999 (typed_val_decfloat): Remove.
2001 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2002 (parse_number): Update to new parse_float interface.
2003 Parse suffixes and determine type before calling parse_float.
2004 Handle decimal and binary FP types the same way.
2006 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2007 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
2008 (parse_number): Update to new parse_float interface.
2009 Parse suffixes and determine type before calling parse_float.
2011 * f-exp.y: Replace dval by typed_val_float.
2012 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2013 (parse_number): Use parse_float instead of atof.
2015 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2016 (parse_go_float): Remove.
2017 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2018 (parse_number): Call parse_float instead of parse_go_float.
2019 Parse suffixes and determine type before calling parse_float.
2021 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2022 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2023 (parse_number): Update to new parse_float interface.
2024 Parse suffixes and determine type before calling parse_float.
2026 * m2-exp.y: Replace dval by byte buffer val.
2027 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2028 (parse_number): Call parse_float instead of atof.
2030 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2031 (lex_number): Call parse_float instead of strtod.
2032 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
2033 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
2034 Use write_exp_elt_floatcst.
2035 (unit_testing): Remove static variable.
2036 (rust_type): Do not check unit_testing.
2037 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
2039 * ada-exp.y (type_float, type_double): Remove.
2040 (typed_val_float): Use byte buffer instead of DOUBLEST.
2041 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2042 * ada-lex.l (processReal): Use parse_float instead of sscanf.
2044 2017-10-25 Alan Hayward <alan.hayward@arm.com>
2046 * aarch64-tdep.h (enum aarch64_regnum): Remove.
2047 * arch/aarch64.h: New file.
2049 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2051 * dfp.h (decimal_from_string): Use const reference for argument.
2052 * dfp.c (decimal_from_string): Likewise.
2054 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2056 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
2057 * sh64-tdep.c (sh64_do_fp_register): Likewise.
2058 * mips-tdep.c (mips_print_fp_register): Likewise.
2060 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2062 * common/format.h (enum argclass): Replace decfloat_arg by
2063 dec32float_arg, dec64float_arg, and dec128float_arg.
2064 * common/format.c (parse_format_string): Update to return
2065 new decimal float argument classes.
2067 * printcmd.c (printf_decfloat): Rename to ...
2068 (printf_floating): ... this. Add argclass argument, and use it
2069 instead of parsing the format string again. Add support for
2070 binary floating-point values, using floatformat_to_string.
2071 Convert value to the target format if it doesn't already match.
2072 (ui_printf): Call printf_floating instead of printf_decfloat,
2073 also for double_arg / long_double_arg. Pass argclass.
2075 * dfp.c (decimal_to_string): Add format string argument.
2076 * dfp.h (decimal_to_string): Likewise.
2078 * doublest.c (floatformat_to_string): Add format string argument.
2079 * doublest.h (floatformat_to_string): Likewise.
2081 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2083 * doublest.c (floatformat_precision): New routine.
2084 (floatformat_to_string): Likewise.
2085 * doublest.c (floatformat_to_string): Add prototype.
2087 * printcmd.c (print_scalar_formatted): Only call print_floating
2088 on floating-point types.
2089 * valprint.c: Do not include "floatformat.h".
2090 (generic_val_print_decfloat): Remove.
2091 (generic_val_print): Call generic_val_print_float for both
2092 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
2093 (print_floating): Use floatformat_to_string. Handle decimal float.
2094 (print_decimal_floating): Remove, merge into floatformat_to_string.
2095 * value.h (print_decimal_floating): Remove.
2097 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
2099 2017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2101 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
2103 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2105 * memattr.h: Don't include vec.h.
2106 (struct mem_attrib): Initialize fields.
2107 <unknown>: New static method.
2108 (struct mem_region): Add constructors, operator<, initialize
2110 * memattr.c: Include algorithm.
2111 (default_mem_attrib, unknown_mem_attrib): Remove.
2112 (user_mem_region_list): New global.
2113 (target_mem_region_list, mem_region_list): Change type to
2114 std::vector<mem_region>.
2115 (mem_use_target): Now a function.
2116 (target_mem_regions_valid): Change type to bool.
2117 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
2118 (require_user_regions): Adjust.
2119 (require_target_regions): Adjust.
2120 (create_mem_region): Adjust.
2121 (lookup_mem_region): Adjust.
2122 (invalidate_target_mem_regions): Adjust.
2123 (mem_clear): Rename to...
2124 (user_mem_clear): ... this, and adjust.
2125 (mem_command): Adjust.
2126 (info_mem_command): Adjust.
2127 (mem_enable, enable_mem_command, mem_disable,
2128 disable_mem_command): Adjust.
2129 (mem_delete): Adjust.
2130 (delete_mem_command): Adjust.
2131 * memory-map.h (parse_memory_map): Return an std::vector.
2132 * memory-map.c (parse_memory_map): Likewise.
2133 (struct memory_map_parsing_data): Add constructor.
2134 <memory_map>: Point to std::vector.
2135 (memory_map_start_memory): Adjust.
2136 (memory_map_end_memory): Adjust.
2137 (memory_map_end_property): Adjust.
2138 (clear_result): Remove.
2139 * remote.c (remote_memory_map): Return an std::vector.
2140 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
2142 (target_debug_print_mem_region_vector): New.
2143 * target-delegates.c: Regenerate.
2144 * target.h (mem_region_vector): New typedef.
2145 (to_memory_map): Return mem_region_vector.
2146 (target_memory_map): Return an std::vector.
2147 * target.c (target_memory_map): Return an std::vector.
2148 (flash_erase_command): Adjust.
2150 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2152 * memory-map.c (struct memory_map_parsing_data) <property_name>:
2153 Change type to std::string.
2154 (memory_map_start_property): Adjust.
2155 (memory_map_end_property): Adjust.
2157 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2159 * infrun.h: Include common/byte-vector.h.
2160 (struct displaced_step_closure): New struct.
2161 (struct buf_displaced_step_closure): New struct.
2162 * infrun.c (displaced_step_closure::~displaced_step_closure):
2163 Provide default implementation.
2164 (displaced_step_clear): Deallocate step closure with delete.
2165 * aarch64-tdep.c (displaced_step_closure): Rename to ...
2166 (aarch64_displaced_step_closure): ... this, extend
2167 displaced_step_closure.
2168 (aarch64_displaced_step_data) <dsc>: Change type to
2169 aarch64_displaced_step_closure.
2170 (aarch64_displaced_step_copy_insn): Adjust to type change, use
2172 (aarch64_displaced_step_fixup): Add cast for displaced step
2174 * amd64-tdep.c (displaced_step_closure): Rename to ...
2175 (amd64_displaced_step_closure): ... this, extend
2176 displaced_step_closure.
2177 <insn_buf>: Change type to std::vector<gdb_byte>.
2179 (fixup_riprel): Change type of DSC parameter, adjust to type
2181 (fixup_displaced_copy): Change type of DSC parameter.
2182 (amd64_displaced_step_copy_insn): Instantiate
2183 amd64_displaced_step_closure.
2184 (amd64_displaced_step_fixup): Add cast for closure type, adjust
2185 to type change of insn_buf.
2186 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
2188 (arm_linux_copy_svc): Likewise.
2189 (cleanup_kernel_helper_return): Likewise.
2190 (arm_catch_kernel_helper_return): Likewise.
2191 (arm_linux_displaced_step_copy_insn): Instantiate
2192 arm_displaced_step_closure.
2193 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
2194 (displaced_read_reg): Change type of parameter DSC.
2195 (branch_write_pc): Likewise.
2196 (load_write_pc): Likewise.
2197 (alu_write_pc): Likewise.
2198 (displaced_write_reg): Likewise.
2199 (arm_copy_unmodified): Likewise.
2200 (thumb_copy_unmodified_32bit): Likewise.
2201 (thumb_copy_unmodified_16bit): Likewise.
2202 (cleanup_preload): Likewise.
2203 (install_preload): Likewise.
2204 (arm_copy_preload): Likewise.
2205 (thumb2_copy_preload): Likewise.
2206 (install_preload_reg): Likewise.
2207 (arm_copy_preload_reg): Likewise.
2208 (cleanup_copro_load_store): Likewise.
2209 (install_copro_load_store): Likewise.
2210 (arm_copy_copro_load_store) Likewise.
2211 (thumb2_copy_copro_load_store): Likewise.
2212 (cleanup_branch): Likewise.
2213 (install_b_bl_blx): Likewise.
2214 (arm_copy_b_bl_blx): Likewise.
2215 (thumb2_copy_b_bl_blx): Likewise.
2216 (thumb_copy_b): Likewise.
2217 (install_bx_blx_reg): Likewise.
2218 (arm_copy_bx_blx_reg): Likewise.
2219 (thumb_copy_bx_blx_reg): Likewise.
2220 (cleanup_alu_imm): Likewise.
2221 (arm_copy_alu_imm): Likewise.
2222 (thumb2_copy_alu_imm): Likewise.
2223 (cleanup_alu_reg): Likewise.
2224 (install_alu_reg): Likewise.
2225 (arm_copy_alu_reg): Likewise.
2226 (thumb_copy_alu_reg): Likewise.
2227 (cleanup_alu_shifted_reg): Likewise.
2228 (install_alu_shifted_reg): Likewise.
2229 (arm_copy_alu_shifted_reg): Likewise.
2230 (cleanup_load): Likewise.
2231 (cleanup_store): Likewise.
2232 (arm_copy_extra_ld_st): Likewise.
2233 (install_load_store): Likewise.
2234 (thumb2_copy_load_literal): Likewise.
2235 (thumb2_copy_load_reg_imm): Likewise.
2236 (arm_copy_ldr_str_ldrb_strb): Likewise.
2237 (cleanup_block_load_all): Likewise.
2238 (cleanup_block_store_pc): Likewise.
2239 (cleanup_block_load_pc): Likewise.
2240 (arm_copy_block_xfer): Likewise.
2241 (thumb2_copy_block_xfer): Likewise.
2242 (cleanup_svc): Likewise.
2243 (install_svc): Likewise.
2244 (arm_copy_svc): Likewise.
2245 (thumb_copy_svc): Likewise.
2246 (arm_copy_undef): Likewise.
2247 (thumb_32bit_copy_undef): Likewise.
2248 (arm_copy_unpred): Likewise.
2249 (arm_decode_misc_memhint_neon): Likewise.
2250 (arm_decode_unconditional): Likewise.
2251 (arm_decode_miscellaneous): Likewise.
2252 (arm_decode_dp_misc): Likewise.
2253 (arm_decode_ld_st_word_ubyte): Likewise.
2254 (arm_decode_media): Likewise.
2255 (arm_decode_b_bl_ldmstm): Likewise.
2256 (arm_decode_ext_reg_ld_st): Likewise.
2257 (thumb2_decode_dp_shift_reg): Likewise.
2258 (thumb2_decode_ext_reg_ld_st): Likewise.
2259 (arm_decode_svc_copro): Likewise.
2260 (thumb2_decode_svc_copro): Likewise.
2261 (install_pc_relative): Likewise.
2262 (thumb_copy_pc_relative_16bit): Likewise.
2263 (thumb_decode_pc_relative_16bit): Likewise.
2264 (thumb_copy_pc_relative_32bit): Likewise.
2265 (thumb_copy_16bit_ldr_literal): Likewise.
2266 (thumb_copy_cbnz_cbz): Likewise.
2267 (thumb2_copy_table_branch): Likewise.
2268 (cleanup_pop_pc_16bit_all): Likewise.
2269 (thumb_copy_pop_pc_16bit): Likewise.
2270 (thumb_process_displaced_16bit_insn): Likewise.
2271 (decode_thumb_32bit_ld_mem_hints): Likewise.
2272 (thumb_process_displaced_32bit_insn): Likewise.
2273 (thumb_process_displaced_insn): Likewise.
2274 (arm_process_displaced_insn): Likewise.
2275 (arm_displaced_init_closure): Likewise.
2276 (arm_displaced_step_fixup): Add cast for closure.
2277 * arm-tdep.h: Include infrun.h.
2278 (displaced_step_closure): Rename to ...
2279 (arm_displaced_step_closure): ... this, extend
2280 displaced_step_closure.
2281 <u::svc::copy_svc_os>: Change type of parameter DSC.
2282 <cleanup>: Likewise.
2283 (arm_process_displaced_insn): Likewise.
2284 (arm_displaced_init_closure): Likewise.
2285 (displaced_read_reg): Likewise.
2286 (displaced_write_reg): Likewise.
2287 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2289 * i386-tdep.h: Include infrun.h.
2290 (i386_displaced_step_closure): New typedef.
2291 * i386-tdep.c (i386_displaced_step_copy_insn): Use
2292 i386_displaced_step_closure.
2293 (i386_displaced_step_fixup): Adjust.
2294 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
2295 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
2297 (ppc_displaced_step_fixup): Adjust.
2298 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
2299 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
2301 (s390_displaced_step_fixup): Adjust.
2303 2017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2305 * interps.h (interp_resume, interp_suspend, interp_set_temp):
2306 Remove declarations.
2308 2017-10-20 Tom Tromey <tom@tromey.com>
2310 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
2312 (gdb_bfd_record_inclusion): Update.
2313 (bfdp): Remove typedef.
2315 2017-10-20 Tom Tromey <tom@tromey.com>
2317 * gdb_bfd.c (gdb_bfd_ref): Use new.
2318 (struct gdb_bfd_data): Add constructor, destructor, and member
2320 (gdb_bfd_unref): Use delete.
2322 2017-10-20 Tom Tromey <tom@tromey.com>
2324 * exec.c (exec_file_attach): Use new_bfd_ref.
2325 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
2326 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
2327 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
2329 * gdb_bfd.h (new_bfd_ref): New function.
2331 2017-10-20 Pedro Alves <palves@redhat.com>
2333 * main.c (captured_command_loop): Add attribute noinline.
2335 2017-10-19 Simon Marchi <simon.marchi@ericsson.com>
2337 * interps.c (struct interp_factory): Add constructor.
2338 (interp_factory_p): Remove typedef.
2339 (DEF_VEC_P(interp_factory_p)): Remove.
2340 (interpreter_factories): Change type to std::vector.
2341 (interp_factory_register): Adjust.
2342 (interp_lookup): Adjust.
2343 (interpreter_completer): Adjust.
2345 2017-10-19 Tom Tromey <tom@tromey.com>
2347 * break-catch-syscall.c (catch_syscall_completer): Use
2348 std::string, gdb::unique_xmalloc_ptr.
2350 2017-10-19 Tom Tromey <tom@tromey.com>
2352 * infcall.c (call_function_by_hand_dummy): Use std::string.
2354 2017-10-19 Tom Tromey <tom@tromey.com>
2356 * mi/mi-main.c (mi_cmd_execute): Update.
2357 * top.h (prepare_execute_command): Return scoped_value_mark.
2358 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
2359 Add move constructor.
2360 * top.c (prepare_execute_command): Return scoped_value_mark.
2361 (execute_command): Update.
2363 2017-10-19 Pedro Alves <palves@redhat.com>
2365 * xml-support.c (xml_fetch_content_from_file): Check fread's
2368 2017-10-19 Pedro Alves <palves@redhat.com>
2370 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
2372 (handle_error_fd): New function.
2373 (ser_base_async): Add/delete an event loop file handler for
2376 2017-10-19 Pedro Alves <palves@redhat.com>
2378 * xml-support.c (xml_fetch_content_from_file): Don't read in
2379 chunks. Instead use fseek to determine the file's size, and read
2382 2017-11-18 Keith Seitz <keiths@redhat.com>
2384 * c-exp.y (oper): Canonicalize conversion operators of user-defined
2386 Add whitespace to front of type name.
2388 2017-10-18 Keith Seitz <keiths@redhat.com>
2390 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
2391 DW_AT_accessibility.
2393 2017-10-18 Yao Qi <yao.qi@linaro.org>
2395 * features/tic6x-c62x-linux.c: Remove.
2397 2017-10-17 Tom Tromey <tom@tromey.com>
2399 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
2400 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
2401 (do_mixed_source_and_assembly): Likewise.
2403 2017-10-17 Tom Tromey <tom@tromey.com>
2405 * regcache.c (regcache::xfer_part): Remove assertion.
2407 2017-10-17 Pedro Alves <palves@redhat.com>
2409 * xml-support.c (xml_fetch_content_from_file): Call
2410 unique_ptr::release() instead unique_ptr::get() when passing
2413 2017-10-17 Yao Qi <yao.qi@linaro.org>
2415 * regcache.c (regcache::xfer_part): Remove parameters read and
2416 write, add parameter is_raw. All callers are updated.
2418 2017-10-16 Keith Seitz <keiths@redhat.com>
2420 * c-typeprint.c (enum access_specifier): Moved here from
2422 (output_access_specifier): New function.
2423 (c_type_print_base): Consider typedefs when assessing
2424 whether access labels are needed.
2425 Use output_access_specifier as needed.
2426 Output access specifier for typedefs, if needed.
2427 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
2428 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
2430 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
2433 2017-10-16 Tom Tromey <tom@tromey.com>
2435 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
2436 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
2437 * target.c (target_fileio_read_stralloc): Update.
2438 * sparc64-tdep.c (adi_is_addr_mapped): Update.
2439 * target.h (target_fileio_read_stralloc): Return
2442 2017-10-16 Tom Tromey <tom@tromey.com>
2444 * xml-syscall.c (xml_init_syscalls_info): Update.
2445 * xml-support.c (xinclude_start_include): Update.
2446 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
2447 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
2448 (xml_fetch_content_from_file): Likewise.
2449 * osdata.c (get_osdata): Update.
2450 * target.h (target_read_stralloc, target_get_osdata): Return
2452 * solib-aix.c (solib_aix_get_library_list): Update.
2453 * solib-target.c (solib_target_current_sos): Update.
2454 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
2455 * xml-tdesc.c (fetch_available_features_from_target): Update.
2456 (target_fetch_description_xml): Update.
2457 (file_read_description_xml): Update.
2458 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
2459 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
2460 (remote_pid_to_exec_file): Update.
2461 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
2462 (target_get_osdata): Likewise.
2464 2017-10-16 Tom Tromey <tom@tromey.com>
2466 * remote.c (remote_register_number_and_offset): Use std::vector.
2467 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
2468 (putpkt_binary): Use gdb::def_vector.
2469 (compare_sections_command): Use gdb::byte_vector.
2471 2017-10-16 Tom Tromey <tom@tromey.com>
2473 * ppc-linux-nat.c (hwdebug_insert_point): Use
2474 gdb::unique_xmalloc_ptr, XDUP.
2476 2017-10-16 Tom Tromey <tom@tromey.com>
2478 * probe.c (parse_probes): Use std::string.
2479 (info_probes_for_ops, enable_probes_command)
2480 (disable_probes_command): Remove cleanups.
2482 2017-10-16 Tom Tromey <tom@tromey.com>
2484 * buildsym.c (block_compar): Remove.
2485 (end_symtab_get_static_block): Use std::vector.
2487 2017-10-16 Simon Marchi <simon.marchi@ericsson.com>
2489 * memrange.h (struct mem_range): Define operator< and operator==.
2490 (mem_range_s): Remove.
2491 (DEF_VEC_O (mem_range_s)): Remove.
2492 (normalize_mem_ranges): Change parameter type to std::vector.
2493 * memrange.c (compare_mem_ranges): Remove.
2494 (normalize_mem_ranges): Change parameter type to std::vector,
2495 adjust to vector change.
2496 * exec.c (section_table_available_memory): Return vector, remove
2498 (section_table_read_available_memory): Adjust to std::vector
2500 * remote.c (remote_read_bytes): Adjust to std::vector
2502 * tracepoint.h (traceframe_available_memory): Change parameter
2503 type to std::vector.
2504 * tracepoint.c (traceframe_available_memory): Change parameter
2505 type to std::vector, adjust.
2506 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
2508 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2509 unittests/memrange-selftests.c.
2510 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
2511 * gdb/unittests/memrange-selftests.c: New file.
2513 2017-10-16 Pedro Alves <palves@redhat.com>
2515 * elfread.c (probe_key_free): Rename range-for variable.
2516 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
2517 (find_probe_by_pc, collect_probes): Rename range-for variable.
2519 2017-10-16 Yao Qi <yao.qi@linaro.org>
2521 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
2522 * features/tic6x-c62x.c: Remove.
2523 * features/tic6x-c64x-linux.c: Remove.
2524 * features/tic6x-c64x.c: Remove.
2525 * features/tic6x-c64xp-linux.c: Remove.
2526 * features/tic6x-c64xp.c: Remove.
2527 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
2528 initialize_tdesc_tic6x_*_linux functions.
2529 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
2530 initialize_tdesc_tic6x_* functions.
2532 2017-10-16 Yao Qi <yao.qi@linaro.org>
2534 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
2536 * regformats/tic6x-c62x.dat: Remove.
2537 * regformats/tic6x-c64x.dat: Remove.
2538 * regformats/tic6x-c64xp.dat: Remove.
2540 2017-10-15 Simon Marchi <simon.marchi@ericsson.com>
2542 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
2543 (the !HAVE_LIBEXPAT version).
2545 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2547 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
2550 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2552 * target.h: Include tracepoint.h.
2553 (enum trace_find_type): Move to tracepoint.h.
2554 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
2555 * tracepoint.h: Don't include target.h
2556 (enum trace_find_type): Move from target.h.
2557 (parse_traceframe_info): Return a unique ptr.
2558 * tracepoint.c (current_traceframe_info): Change type to unique
2560 (free_traceframe_info): Remove.
2561 (clear_traceframe_info): Don't manually free
2562 current_traceframe_info.
2563 (free_result): Remove.
2564 (parse_traceframe_info): Return a unique ptr.
2565 (get_traceframe_info): Adjust to unique ptr.
2566 * ctf.c (ctf_traceframe_info): Return a unique ptr.
2567 * remote.c (remote_traceframe_info): Return a unique ptr.
2568 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
2570 * target-debug.h (target_debug_print_traceframe_info_up): New
2572 * target-delegates.c: Regenerate.
2574 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2576 * memrange.h (struct mem_range): Add constructors.
2577 * tracepoint.h (struct traceframe_info) <memory>: Change type to
2578 std::vector<mem_range>.
2579 * tracepoint.c (free_traceframe_info): Don't manually free
2581 (traceframe_info_start_memory): Adjust to vector change.
2582 (traceframe_available_memory): Likewise.
2583 * tracefile-tfile.c (build_traceframe_info): Likewise.
2584 * ctf.c (ctf_traceframe_info): Likewise.
2586 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2588 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
2590 * tracepoint.c (free_traceframe_info): Deallocate with delete.
2591 (traceframe_info_start_tvar): Adjust to vector change.
2592 (parse_traceframe_info): Allocate with new.
2593 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
2595 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
2597 tfile_traceframe_info): Allocate with new.
2598 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
2601 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2603 * tracepoint.c (traceframe_info): Rename to...
2604 (current_traceframe_info): ...this.
2605 (clear_traceframe_info): Adjust.
2606 (get_traceframe_info): Adjust.
2608 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2610 * nat/linux-osdata.c: Include algorithm.
2611 (compare_processes): Remove.
2612 (struct pid_pgid_entry): New struct.
2613 (linux_xfer_osdata_processgroups): Use std::vector instead of
2616 2017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2618 * objfiles.h: Don't include symfile.h.
2619 (struct partial_symbol): Remove forward-declaration.
2620 (struct objfile) <global_psymbols, static_psymbols>: Change type
2621 to std::vector<partial_symbol *>.
2622 * objfiles.c (objfile::objfile): Don't memset those fields.
2623 (objfile::~objfile): Don't free those fields.
2624 * psympriv.h (struct psymbol_allocation_list): Remove
2625 forward-declaration.
2626 (add_psymbol_to_list): Change psymbol_allocation_list parameter
2628 (start_psymtab_common): Change parameters to std::vector.
2629 * psymtab.c: Include algorithm.
2630 (require_partial_symbols): Call shrink_to_fit.
2631 (find_pc_sect_psymbol): Adjust to vector change.
2632 (match_partial_symbol): Likewise.
2633 (lookup_partial_symbol): Likewise.
2634 (psym_relocate): Likewise.
2635 (dump_psymtab): Likewise.
2636 (recursively_search_psymtabs): Likewise.
2637 (compare_psymbols): Remove.
2638 (sort_pst_symbols): Adjust to vector change.
2639 (start_psymtab_common): Likewise.
2640 (end_psymtab_common): Likewise.
2641 (psymbol_bcache_full): De-constify return value.
2642 (add_psymbol_to_bcache): Likewise.
2643 (extend_psymbol_list): Remove.
2644 (append_psymbol_to_list): Adjust to vector change.
2645 (add_psymbol_to_list): Likewise.
2646 (init_psymbol_list): Likewise.
2647 (maintenance_info_psymtabs): Likewise.
2648 (maintenance_check_psymtabs): Likewise.
2649 * symfile.h (struct psymbol_allocation_list): Remove.
2650 * symfile.c (reread_symbols): Adjust to vector change.
2651 * dbxread.c (start_psymtab): Change type of parameters.
2652 (dbx_symfile_read): Adjust to vector change.
2653 (read_dbx_symtab): Likewise.
2654 (start_psymtab): Change type of parameters.
2655 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
2656 (create_partial_symtab): Likewise.
2657 (add_partial_symbol): Likewise.
2658 (write_one_signatured_type): Likewise.
2659 (recursively_write_psymbols): Likewise.
2660 * mdebugread.c (parse_partial_symbols): Likewise.
2661 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
2662 (scan_xcoff_symtab): Adjust to vector change.
2663 (xcoff_initial_scan): Likewise.
2665 2017-10-13 Simon Marchi <simon.marchi@ericsson.com>
2667 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
2669 2017-10-13 Yao Qi <yao.qi@linaro.org>
2671 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
2672 Remove s390x-*-expedite, add s390x-expedite.
2674 2017-10-13 Yao Qi <yao.qi@linaro.org>
2676 * features/s390-gs-linux64.c: Regenerated.
2677 * features/s390x-gs-linux64.c: Regenerated.
2679 2017-10-13 Tom Tromey <tom@tromey.com>
2681 * compile/compile-object-run.c (do_module_cleanup): Use delete.
2682 * solib.c (update_solib_list, reload_shared_libraries_1): Use
2684 * symfile.c (symbol_file_add_with_addrs): Use new.
2685 (symbol_file_add_separate): Update comment.
2686 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
2687 * jit.c (jit_object_close_impl): Use new.
2688 (jit_unregister_code): Use delete.
2689 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
2690 (~objfile): Rename from free_objfile.
2691 (free_objfile_separate_debug, do_free_objfile_cleanup)
2692 (free_all_objfiles, objfile_purge_solibs): Use delete.
2693 * objfiles.h (struct objfile): Add constructor and destructor.
2694 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
2695 (allocate_objfile, free_objfile): Don't declare.
2696 (struct objstats): Add initializers.
2698 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2700 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
2701 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
2702 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
2703 * gdbarch.h: Regenerate.
2704 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2706 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
2707 (i386_displaced_step_fixup): Adjust comment.
2708 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
2710 2017-10-12 Tom Tromey <tom@tromey.com>
2712 * prologue-value.h (pv_area::store_would_trash): Return bool.
2713 (pv_area::find_reg): Likewise.
2714 * prologue-value.c (pv_area::store_would_trash): Return bool.
2715 (pv_area::find_reg): Likewise.
2717 2017-10-12 Tom Tromey <tom@tromey.com>
2719 * s390-linux-tdep.c (s390_store, s390_load)
2720 (s390_check_for_saved, s390_analyze_prologue): Update.
2721 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
2722 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
2723 * prologue-value.h (class pv_area): Move from prologue-value.c.
2724 Change names of members. Add constructor, destructor, member
2726 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
2727 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
2728 (pv_area_fetch, pv_area_scan): Don't declare.
2729 * prologue-value.c (struct pv_area::area_entry): Now member of
2731 (struct pv_area): Move to prologue-value.h.
2732 (pv_area::pv_area): Rename from make_pv_area.
2733 (pv_area::~pv_area): Rename from free_pv_area.
2734 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
2735 (clear_entries, find_entry, overlaps, store_would_trash, store)
2736 (fetch, find_reg, scan): Now member of pv_area.
2737 Remove "area" argument. Update.
2738 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
2740 * mn10300-tdep.c (push_reg, check_for_saved)
2741 (mn10300_analyze_prologue): Update.
2742 * mep-tdep.c (is_arg_spill, check_for_saved)
2743 (mep_analyze_prologue): Update.
2744 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
2745 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
2746 (m32c_is_struct_return, m32c_analyze_prologue): Update.
2747 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
2749 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
2750 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
2752 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2754 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
2755 * linux-nat.c (linux_nat_delete_thread): New variable.
2756 (lwp_free): Invoke linux_nat_delete_thread if set.
2757 (linux_nat_set_delete_thread): New function.
2758 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
2759 thread delete callback.
2760 * arm-linux-nat.c (arm_linux_delete_thread): New function.
2761 (_initialize_arm_linux_nat): Assign thread delete callback.
2762 * s390-linux-nat.c (s390_delete_thread): New function.
2763 (_initialize_s390_nat): Assign thread delete callback.
2764 * x86-linux-nat.c (x86_linux_add_target): Likewise.
2765 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
2767 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
2769 * nat/x86-linux.c (x86_linux_delete_thread): New function.
2770 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
2772 2017-10-09 Tom Tromey <tom@tromey.com>
2774 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
2776 * tui/tui-layout.c (enum tui_status): Use std::string.
2778 2017-10-11 Tom Tromey <tom@tromey.com>
2780 * gdbthread.h (thread_command): Constify.
2781 * inferior.h (detach_command): Constify.
2782 * top.h (set_history, show_history): Constify.
2783 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
2784 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
2785 * bsd-kvm.c (bsd_kvm_cmd): Constify.
2786 * printcmd.c (set_command): Constify.
2787 (non_const_set_command): New function.
2788 * dcache.c (set_dcache_command, show_dcache_command): Constify.
2789 * breakpoint.c (enable_command, disable_command, delete_command)
2790 (catch_command, tcatch_command, set_breakpoint_cmd)
2791 (show_breakpoint_cmd): Constify.
2792 * macrocmd.c (macro_command): Constify.
2793 * infcmd.c (unset_command, kill_command, detach_command)
2794 (info_proc_cmd): Constify.
2795 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
2796 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
2797 (info_auto_load_cmd): Constify.
2798 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
2799 (unset_tdesc_cmd): Constify.
2800 * ada-lang.c (set_ada_command, show_ada_command)
2801 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
2802 * guile/guile.c (set_guile_command, show_guile_command)
2803 (info_guile_command): Constify.
2804 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
2806 * skip.c (skip_command): Constify.
2807 * compile/compile.c (_initialize_compile): Constify.
2808 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
2809 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
2810 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
2811 (maint_btrace_pt_show_cmd): Constify.
2812 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
2814 * python/python.c (user_show_python, user_set_python): Constify.
2815 * mips-tdep.c (set_mips_command, show_mips_command)
2816 (set_mipsfpu_command): Constify.
2817 * record-btrace.c (cmd_record_btrace_start)
2818 (cmd_set_record_btrace, cmd_show_record_btrace)
2819 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
2820 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
2821 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
2823 * symfile.c (overlay_command): Constify.
2824 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
2825 * cli/cli-logging.c (set_logging_command, show_logging_command):
2827 * cli/cli-dump.c (dump_command, append_command)
2828 (srec_dump_command, ihex_dump_command, verilog_dump_command)
2829 (tekhex_dump_command, binary_dump_command)
2830 (binary_append_command): Constify.
2831 * cli/cli-decode.c (struct cmd_list_element): Change type of
2833 * cli/cli-cmds.c (info_command, show_command, set_debug)
2834 (show_debug): Constify.
2835 (show_command): Add non-const overload.
2836 * top.c (set_history, show_history): Constify.
2837 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
2838 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
2839 * target.c (target_command): Constify.
2840 * sparc64-tdep.c (info_adi_command): Constify.
2841 * record-full.c (cmd_record_full_start): Constify.
2842 (set_record_full_command): Constify. Fix typo.
2843 (show_record_full_command): Constify.
2844 * thread.c (thread_command, thread_apply_command): Constify.
2845 * memattr.c (dummy_cmd): Constify.
2846 * value.c (function_command): Constify.
2847 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
2848 * probe.c (info_probes_command): Constify.
2849 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
2850 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
2851 (show_thread_cmd, set_thread_default_cmd)
2852 (show_thread_default_cmd): Constify.
2853 (check_empty): Constify.
2854 * tracepoint.c (tfind_command): Constify.
2855 * cp-support.c (maint_cplus_command): Constify.
2856 * windows-tdep.c (info_w32_command): Constify.
2857 * record.c (cmd_record_start, set_record_command)
2858 (show_record_command, info_record_command, cmd_record_goto):
2860 * ravenscar-thread.c (set_ravenscar_command)
2861 (show_ravenscar_command): Constify.
2862 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
2864 (add_internal_problem_command): Remove casts.
2865 * arc-tdep.c (maintenance_print_arc_command): Constify.
2866 * valprint.c (set_print, show_print, set_print_raw)
2867 (show_print_raw): Constify.
2868 * maint.c (maintenance_command, maintenance_info_command)
2869 (maintenance_print_command, maintenance_set_cmd)
2870 (maintenance_show_cmd, set_per_command_cmd)
2871 (show_per_command_cmd, maintenance_check_command): Constify.
2872 * language.c (set_check, show_check): Constify.
2873 * typeprint.c (show_print_type, set_print_type): Constify.
2874 * go32-nat.c (go32_info_dos_command): Constify.
2876 2017-10-11 Tom Tromey <tom@tromey.com>
2878 * breakpoint.c (prepare_re_set_context): Remove.
2879 (breakpoint_re_set_one): Update. Don't use cleanups.
2880 (breakpoint_re_set): Use scoped_restore, std::string, and
2881 scoped_restore_current_language.
2883 2017-10-11 Tom Tromey <tom@tromey.com>
2885 * breakpoint.c (commands_command_1): Use std::string.
2886 (cleanup_executing_breakpoints): Remove.
2887 (bpstat_do_actions_1): Use scoped_restore.
2888 (bpstat_check_watchpoint): Use std::string.
2889 (decode_static_tracepoint_spec): Likewise.
2890 (break_range_command): Likewise.
2891 (watch_command_1): Likewise.
2892 (compare_breakpoints): Change argument types.
2893 (clear_command): Use std::vector.
2894 (cleanup_executing_breakpoints): Remove.
2895 (update_global_location_list): Use unique_xmalloc_ptr.
2896 (strace_command): Remove unused declaration.
2898 2017-10-11 John Baldwin <jhb@FreeBSD.org>
2900 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
2901 * NEWS: Mention new FreeBSD/arm native configuration.
2902 * configure.host: Add arm*-*-freebsd*.
2903 * configure.nat: Likewise.
2904 * arm-fbsd-nat.c: New file.
2906 2017-10-11 John Baldwin <jhb@FreeBSD.org>
2908 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
2909 (ALLDEPFILES): Add arm-fbsd-tdep.c.
2910 * NEWS: Mention new FreeBSD/arm target.
2911 * configure.tgt: Add arm*-*-freebsd*.
2912 * arm-fbsd-tdep.c: New file.
2913 * arm-fbsd-tdep.h: New file.
2915 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
2917 * linux-tdep.c (linux_make_corefile_notes): Remove call to
2918 `gdbarch_elfcore_write_linux_prpsinfo'.
2919 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
2921 (elf_internal_linux_prpsinfo): Remove declaration.
2922 * gdbarch.h: Regenerate.
2923 * gdbarch.c: Regenerate.
2925 2017-10-11 Maciej W. Rozycki <macro@imgtec.com>
2927 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
2928 `set_gdbarch_elfcore_write_linux_prpsinfo'.
2930 2017-10-11 Pedro Alves <palves@redhat.com>
2932 * breakpoint.c (reattach_breakpoints): Delete.
2933 * breakpoint.h (reattach_breakpoints): Delete.
2935 2017-10-11 Simon Marchi <simon.marchi@ericsson.com>
2937 * symfile.c (registered_sym_fns): Make struct, not typedef.
2938 (DEF_VEC_O (registered_sym_fns)): Remove.
2939 (symtab_fns): Change type to std::vector.
2940 (add_symtab_fns): Adjust.
2941 (find_sym_fns): Adjust.
2943 2017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
2945 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
2946 * arc-tdep.h (arc_arch_is_em): New function.
2947 (arc_arch_is_hs): Likewise.
2949 2017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
2951 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
2952 parentheses in the declaration.
2953 (macro_lookup_inclusion): Likewise.
2954 (macro_lookup_definition): Likewise.
2955 * p-lang.h (pascal_builtin_types): Likewise.
2956 * tui/tui-data.c (tui_win_list): Likewise.
2957 * tui/tui-data.h (tui_win_list): Likewise.
2958 * utils.h (make_cleanup_free_section_addr_info): Likewise.
2960 2017-10-11 Mark Rages <markrages@gmail.com>
2962 * target-memory.c (block_boundaries): Fix for block address not
2963 aligned on block size.
2965 2017-10-10 Pedro Alves <palves@redhat.com>
2966 Tom Tromey <tom@tromey.com>
2968 * breakpoint.c (struct captured_breakpoint_query_args)
2969 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
2970 (print_breakpoint): New.
2971 * breakpoint.h (print_breakpoint): Declare.
2972 * common/common-exceptions.h (enum return_reason): Remove
2973 references to catch_exceptions.
2974 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
2976 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
2977 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
2979 * gdbthread.h (thread_select): Declare.
2980 * mi/mi-cmd-break.c: Don't include gdb.h.
2981 (breakpoint_notify): Use print_breakpoint.
2982 * mi/mi-cmd-catch.c: Don't include gdb.h.
2983 * mi/mi-interp.c: Don't include gdb.h.
2984 (mi_print_breakpoint_for_event): New.
2985 (mi_breakpoint_created, mi_breakpoint_modified): Use
2986 mi_print_breakpoint_for_event.
2987 * mi/mi-main.c: Don't include gdb.h.
2988 (mi_cmd_thread_select): Parse the global thread ID here. Use
2989 thread_select instead of gdb_thread_select.
2990 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
2991 of using gdb_list_thread_ids.
2992 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
2994 (remote_fileio_request): Use TRY/CATCH instead of
2996 * symfile-mem.c (struct symbol_file_add_from_memory_args)
2997 (symbol_file_add_from_memory_wrapper): Delete.
2998 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
2999 * thread.c: Don't include gdb.h.
3000 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
3001 (thread_alive): Use thread_select.
3002 (do_captured_thread_select): Delete, parts salvaged as ...
3003 (thread_select): ... this new function.
3004 (gdb_thread_select): Delete.
3006 2017-10-10 Pedro Alves <palves@redhat.com>
3007 Tom Tromey <tom@tromey.com>
3009 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
3011 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
3012 No longer macros. Instead ...
3013 (enum wp_check_result): They're now values of this new
3015 (watchpoint_check): Change return type to wp_check_result and
3016 parameter type to bpstat.
3017 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
3018 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
3019 catch_errors. Reverse logic of watchpoint_check call.
3020 (breakpoint_re_set_one): Now returns void and takes a breakpoint
3021 pointer as parameter.
3022 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
3023 * common/common-exceptions.c (throw_exception_sjlj): Update
3024 comments to avoid mentioning catch_errors.
3025 * exceptions.c (catch_errors): Delete.
3026 * exceptions.h: Update comments to avoid mentioning catch_errors.
3027 (catch_errors_ftype, catch_errors): Delete.
3028 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
3029 (hook_stop_stub): Delete.
3030 (restore_selected_frame): Change return type to void, and
3031 parameter type to const frame_id &.
3032 (restore_infcall_control_state): Use TRY/CATCH instead of
3034 * main.c (captured_command_loop): Return void and remove
3035 parameter. Remove references to catch_errors.
3036 (captured_main): Use TRY/CATCH instead of catch_errors.
3037 * objc-lang.c (objc_submethod_helper_data)
3038 (find_objc_msgcall_submethod_helper): Delete.
3039 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
3041 * record-full.c (record_full_message): Return void.
3042 (record_full_message_args, record_full_message_wrapper): Delete.
3043 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
3044 instead of catch_errors.
3045 * solib-aix.c (solib_aix_open_symbol_file_object): Change
3046 parameter type to int.
3047 * solib-darwin.c (open_symbol_file_object): Ditto.
3048 * solib-dsbt.c (open_symbol_file_object): Ditto.
3049 * solib-frv.c (open_symbol_file_object): Ditto.
3050 * solib-svr4.c (open_symbol_file_object): Ditto.
3051 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
3052 * solib.c (update_solib_list): Use TRY/CATCH instead of
3054 * solist.h (struct target_so_ops) <open_symbol_file_object>:
3056 * symmisc.c (struct print_symbol_args): Remove.
3057 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
3058 (print_symbol): Change type.
3059 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
3060 and remove parameters.
3061 (catch_errors): New.
3062 (get_windows_debug_event): Adjust.
3064 2017-10-09 Tom Tromey <tom@tromey.com>
3066 * mi/mi-main.c (free_splay_tree): Remove.
3067 (list_available_thread_groups): Use splay_tree_up.
3068 * common/gdb_splay_tree.h: New file.
3070 2017-10-09 Tom Tromey <tom@tromey.com>
3072 * mi/mi-main.c (do_nothing): Remove.
3073 (list_available_thread_groups): Update.
3075 2017-10-09 Pedro Alves <palves@redhat.com>
3077 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
3078 reading registers when switching context.
3080 2017-10-09 John Baldwin <jhb@FreeBSD.org>
3082 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
3083 (fbsd_convert_siginfo): Likewise.
3084 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
3086 2017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
3088 * configure.ac (try_guile_versions): Remove guile-2.2.
3089 * configure: Regenerate.
3091 2017-10-09 Tom Tromey <tom@tromey.com>
3093 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
3094 (COMPILE.pre): Use $(CXX).
3096 2017-10-09 Pedro Alves <palves@redhat.com>
3098 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
3100 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3101 * cp-support.h (cp_remove_params): Now returns a
3102 gdb::unique_xmalloc_ptr.
3103 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
3104 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
3105 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
3106 returning a gdb::unique_xmalloc_ptr.
3107 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3108 * stack.c (find_frame_funname): Adjust to cp_remove_params
3109 returning a gdb::unique_xmalloc_ptr.
3111 2017-10-08 Tom Tromey <tom@tromey.com>
3113 * dwarf2read.c (dwarf2_get_dwz_file): Use
3114 gdb::unique_xmalloc_ptr.
3115 (find_slot_in_mapped_hash): Likewise.
3116 (dwarf2_physname): Likewise.
3117 (create_dwo_unit_in_dwp_v1): Use std::string.
3118 (create_dwo_unit_in_dwp_v2): Likewise.
3119 (lookup_dwo_cutu): Likewise.
3120 (inherit_abstract_dies): Use std::vector.
3121 (read_array_type): Likewise.
3122 (dwarf_decode_macros): Remove unused declaration.
3123 (unsigned_int_compar): Remove.
3124 (dwarf2_build_psymtabs_hard): Use scoped_restore.
3125 (psymtabs_addrmap_cleanup): Remove.
3127 2017-10-08 Tom Tromey <tom@tromey.com>
3129 * frame-unwind.c (frame_unwind_try_unwinder): Update.
3130 * frame.h (frame_cleanup_after_sniffer): Declare.
3131 (frame_prepare_for_sniffer): Return void.
3132 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
3134 (frame_prepare_for_sniffer): Return void.
3136 2017-10-08 Tom Tromey <tom@tromey.com>
3138 * utils.h (make_cleanup_value_free): Remove.
3139 * utils.c (do_value_free, struct cleanup): Remove.
3140 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
3142 * value.h (struct value_deleter): New.
3143 (gdb_value_up): New typedef.
3145 2017-10-08 Tom Tromey <tom@tromey.com>
3147 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
3148 (make_cleanup_free_search_symbols): Remove.
3149 (search_symbols): Return std::vector.
3150 (symbol_search::compare_search_syms): Now member of
3151 symbol_search. Change arguments.
3152 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
3153 (symtab_symbol_info, rbreak_command): Update.
3154 * symtab.h (struct symbol_search) <next>: Remove.
3156 (symbol_search::operator<): New function.
3157 (symbol_search::operator==): New function.
3158 (search_symbols): Remove std::vector.
3159 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
3160 (symbol_search::compare_search_syms): Declare.
3162 2017-10-06 Yao Qi <yao.qi@linaro.org>
3164 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
3165 arch/aarch64-insn.o.
3167 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
3169 2017-10-06 Yao Qi <yao.qi@linaro.org>
3171 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
3172 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
3173 arch/arm-linux.o respectively.
3174 * configure.tgt: Likewise.
3176 2017-10-06 Yao Qi <yao.qi@linaro.org>
3178 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
3179 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
3181 2017-10-06 Pedro Alves <palves@redhat.com>
3183 * windows-nat.c: Include <algorithm>.
3185 2017-10-06 Yao Qi <yao.qi@linaro.org>
3187 * configure.tgt (i386_tobjs): New variable.
3188 (amd64_tobjs): New variable.
3189 Set $cpu_obs and $os_obs.
3191 2017-10-06 Yao Qi <yao.qi@linaro.org>
3193 * Makefile.in (CONFIG_SRC_SUBDIR): New.
3194 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
3195 (clean): Remove object files and dependency files.
3196 (distclean): Remove the directory.
3197 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3198 * configure: Re-generated.
3199 * configure.tgt: Replace amd64.o with arch/amd64.o.
3201 2017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
3204 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
3207 2017-10-05 Pedro Alves <palves@redhat.com>
3209 * linux-nat.c (linux_child_follow_fork): When following the parent
3210 and detaching the child, consult the parent thread's architecture
3211 instead of the child's.
3213 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3215 * ax.h: Do not include "doublest.h".
3216 (union agent_val): Remove.
3218 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3220 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
3221 (decimal_to_string): Return std::string object.
3222 (decimal_from_string): Accept std::string object. Return bool.
3223 (decimal_from_integral, decimal_from_doublest): Remove.
3224 (decimal_from_longest): Add prototype.
3225 (decimal_from_ulongest): Likewise.
3226 (decimal_to_longest): Likewise.
3227 (decimal_from_doublest): Likewise.
3228 * dfp.c: Do not include "gdbtypes.h" or "value.h".
3229 (MAX_DECIMAL_STRING): Move here.
3230 (decimal_to_string): Return std::string object.
3231 (decimal_from_string): Accept std::string object. Return bool.
3232 (decimal_from_integral): Remove, replace by ...
3233 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
3234 (decimal_to_longest): New function.
3235 (decimal_from_floating): Remove, replace by ...
3236 (decimal_from_doublest): ... this new function.
3237 (decimal_to_doublest): Update to new decimal_to_string interface.
3239 * value.c (unpack_long): Use decimal_to_longest.
3240 * valops.c (value_cast): Use decimal_from_doublest instead of
3241 decimal_from_floating. Use decimal_from_[u]longest isntead of
3242 decimal_from_integral.
3243 * valarith.c (value_args_as_decimal): Likewise.
3244 * valprint.c (print_decimal_floating): Update to new
3245 decimal_to_string interface.
3246 * printcmd.c (printf_decfloat): Likewise.
3247 * c-exp.y (parse_number): Update to new decimal_from_string interface.
3249 2017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3251 * doublest.h: Do not include "floatformat.h". Remove stale comments.
3252 * gdbtypes.c: Include "floatformat.h".
3253 * value.c: Likewise.
3254 * m68k-tdep.c: Likewise.
3256 * findvar.c: Do not include "floatformat.h".
3257 * amd64-darwin-tdep.c: Likewise.
3258 * arm-linux-tdep.c: Likewise.
3259 * i386-darwin-tdep.c: Likewise.
3260 * i387-tdep.c: Likewise.
3261 * m68k-linux-tdep.c: Likewise.
3262 * mep-tdep.c: Likewise.
3263 * mips-tdep.c: Likewise.
3264 * nios2-tdep.c: Likewise.
3265 * s390-linux-tdep.c: Likewise.
3266 * sparc-obsd-tdep.c: Likewise.
3267 * sparc-tdep.c: Likewise.
3268 * sparc64-tdep.c: Likewise.
3269 * spu-tdep.c: Likewise.
3270 * tic6x-tdep.c: Likewise.
3271 * tilegx-tdep.c: Likewise.
3272 * vax-tdep.c: Likewise.
3273 * xstormy16-tdep.c: Likewise.
3274 * xtensa-tdep.c: Likewise.
3276 * top.c: Do not include "doublest.h".
3277 * aarch64-tdep.c: Likewise.
3278 * alpha-tdep.c: Likewise.
3279 * arm-linux-tdep.c: Likewise.
3280 * m68k-linux-tdep.c: Likewise.
3281 * tilegx-tdep.c: Likewise.
3282 * xstormy16-tdep.c: Likewise.
3284 2017-10-05 John Baldwin <jhb@FreeBSD.org>
3286 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
3287 (mipsn32_fbsd_sigframe): Define.
3288 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
3289 for FreeBSD/mipsn32.
3291 2017-10-05 John Baldwin <jhb@FreeBSD.org>
3293 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
3296 2017-10-05 Tristan Gingold <tgingold@free.fr>
3298 * MAINTAINERS (Misc): Update my email address.
3300 2017-10-04 Pedro Alves <palves@redhat.com>
3302 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
3303 it instead of target_gdbarch.
3304 (get_remote_state, get_remote_packet_size): Adjust
3305 get_remote_arch_state calls, passing down target_gdbarch
3307 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
3308 'gdbarch' and use it instead of target_gdbarch.
3309 (get_memory_packet_size): Adjust get_remote_arch_state calls,
3310 passing down target_gdbarch explicitly.
3311 (struct stop_reply) <arch>: New field.
3312 (remote_parse_stop_reply): Use the stopped thread's architecture,
3313 not the current inferior's. Save the architecture in the
3315 (process_stop_reply): Use the stop reply's architecture.
3316 (process_g_packet, remote_fetch_registers)
3317 (remote_prepare_to_store, store_registers_using_G)
3318 (remote_store_registers): Adjust get_remote_arch_state calls,
3319 using the regcache's architecture.
3320 (remote_get_trace_status): Adjust get_remote_arch_state calls,
3321 passing down target_gdbarch explicitly.
3322 * spu-multiarch.c (spu_thread_architecture): Defer to the target
3323 beneath instead of calling target_gdbarch.
3324 * target.c (default_thread_architecture): Use the specified
3325 inferior's architecture, instead of the current inferior's
3326 architecture (via target_gdbarch).
3328 2017-10-04 Pedro Alves <palves@redhat.com>
3330 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
3332 (regcache_print): Handle !target_has_registers here instead.
3334 2017-10-04 Pedro Alves <palves@redhat.com>
3336 * frame.c (create_test_frame): Delete.
3337 * frame.h (create_test_frame): Delete.
3338 * gdbarch-selftests.c: Include gdbthread.h and target.h.
3339 (class regcache_test): Delete.
3340 (test_target_has_registers, test_target_has_stack)
3341 (test_target_has_memory, test_target_prepare_to_store)
3342 (test_target_store_registers): New functions.
3343 (test_target_ops): New class.
3344 (register_to_value_test): Error out if there's already a
3345 process_stratum (or higher) target pushed. Create a fuller mock
3346 environment, with mock target_ops, inferior, address space, thread
3348 * progspace.c (struct address_space): Move to ...
3349 * progspace.h (struct address_space): ... here.
3350 * regcache.h (regcache::~regcache, regcache::raw_write)
3351 [GDB_SELF_TEST]: No longer virtual.
3353 2017-10-04 Simon Marchi <simon.marchi@ericsson.com>
3355 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
3357 2017-10-04 Pedro Alves <palves@redhat.com>
3359 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
3360 out of 'between TRY and CATCH'.
3362 2017-10-04 Pedro Alves <palves@redhat.com>
3364 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
3365 * common/common-exceptions.h (TRY): Open an outermost scope.
3366 Expand intro comment.
3368 (END_CATCH): Close the outermost scope.
3369 * completer.c (complete_line_internal): Add missing END_CATCH.
3371 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3373 * NEWS (Changes since GDB 8.0): Add entry about new
3374 'set-cwd-on-gdbserver' feature.
3375 (New remote packets): Add entry for QSetWorkingDir.
3376 * common/common-inferior.h (set_inferior_cwd): New prototype.
3377 * infcmd.c (set_inferior_cwd): Remove "static".
3378 (show_cwd_command): Expand text to include remote debugging.
3379 * remote.c: Add PACKET_QSetWorkingDir.
3380 (remote_protocol_features) <QSetWorkingDir>: New entry for
3381 PACKET_QSetWorkingDir.
3382 (extended_remote_set_inferior_cwd): New function.
3383 (extended_remote_create_inferior): Call
3384 "extended_remote_set_inferior_cwd".
3385 (_initialize_remote): Call "add_packet_config_cmd" for
3388 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3390 * NEWS (New commands): Mention "set/show cwd".
3391 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
3392 "cd" command's help text.
3393 * common/common-inferior.h (get_inferior_cwd): New prototype.
3394 * infcmd.c (inferior_cwd_scratch): New global variable.
3395 (set_inferior_cwd): New function.
3396 (get_inferior_cwd): Likewise.
3397 (set_cwd_command): Likewise.
3398 (show_cwd_command): Likewise.
3399 (_initialize_infcmd): Add "set/show cwd" commands.
3400 * inferior.h (class inferior) <cwd>: New field.
3401 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
3402 (fork_inferior): Change inferior's cwd before its execution.
3403 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
3406 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3408 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
3409 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
3410 (COMMON_OBS): Add gdb_tilde_expand.o.
3411 * common/gdb_tilde_expand.c: New file.
3412 * common/gdb_tilde_expand.h: Likewise.
3414 2017-10-03 Maciej W. Rozycki <macro@imgtec.com>
3416 * gdbarch.sh (objfile): Remove duplicate declaration.
3417 * gdbarch.h: Regenerate.
3419 2017-10-03 Tom Tromey <tom@tromey.com>
3421 * utils.c (internal_vproblem): Use string_vprintf.
3423 2017-10-03 Tom Tromey <tom@tromey.com>
3425 * printcmd.c (info_symbol_command): Use std::string.
3427 2017-10-03 Tom Tromey <tom@tromey.com>
3429 * top.c (gdb_safe_append_history): Use std::string.
3431 2017-10-03 Tom Tromey <tom@tromey.com>
3433 * event-top.c (stdin_event_handler): Update.
3434 * main.c (captured_main_1): Update.
3435 * top.h (make_delete_ui_cleanup): Remove.
3436 (struct ui): Add constructor and destructor.
3437 (new_ui, delete_ui): Remove.
3438 * top.c (make_delete_ui_cleanup): Remove.
3439 (new_ui_command): Use std::unique_ptr.
3440 (delete_ui_cleanup): Remove.
3441 (ui::ui): Rename from new_ui. Update.
3443 (ui::~ui): Rename from delete_ui. Update.
3445 2017-10-03 Tom Tromey <tom@tromey.com>
3447 * symfile.c (load_progress): Use gdb::byte_vector.
3449 2017-10-03 Tom Tromey <tom@tromey.com>
3451 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
3453 * printcmd.c (x_command): Remove unused declaration.
3454 * symfile.c (symbol_file_command): Remove unused declaration.
3456 2017-10-03 Tom Tromey <tom@tromey.com>
3458 * utils.c (internal_vproblem): Use std::string.
3459 (defaulted_query): Likewise.
3461 2017-10-03 Tom Tromey <tom@tromey.com>
3463 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
3464 * top.c (execute_command_to_string): Update.
3465 * utils.c (make_cleanup_restore_page_info): Remove.
3466 (do_restore_page_info_cleanup): Remove.
3467 (set_batch_flag_and_restore_page_info):
3469 (make_cleanup_restore_page_info): Remove.
3470 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3471 (~set_batch_flag_and_restore_page_info): New
3472 (make_cleanup_restore_uinteger): Remove.
3473 (make_cleanup_restore_integer): Remove.
3474 (struct restore_integer_closure): Remove.
3475 (restore_integer): Remove.
3476 * utils.h (struct set_batch_flag_and_restore_page_info): New
3478 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3479 (make_cleanup_restore_page_info): Remove.
3480 (make_cleanup_restore_uinteger) Remove.
3481 (make_cleanup_restore_integer) Remove.
3483 2017-10-03 Tom Tromey <tom@tromey.com>
3485 * record-full.h (record_full_gdb_operation_disable_set): Return
3486 scoped_restore_tmpl<int>.
3487 * infrun.c (adjust_pc_after_break): Update.
3488 (handle_signal_stop): Update.
3489 * record-full.c (record_full_gdb_operation_disable_set): Return
3490 scoped_restore_tmpl<int>.
3491 (record_full_wait_1, record_full_insert_breakpoint)
3492 (record_full_remove_breakpoint, record_full_save)
3493 (record_full_goto_insn): Update.
3495 2017-10-02 Tom Tromey <tom@tromey.com>
3498 * rust-lang.c (rust_val_print_str): New function.
3499 (val_print_struct): Call it.
3500 (rust_subscript): Preserve name of slice type.
3502 2017-10-02 Tom Tromey <tom@tromey.com>
3504 * rust-lang.c (rust_subscript): Handle slices in
3505 EVAL_AVOID_SIDE_EFFECTS case.
3507 2017-10-02 Tom Tromey <tom@tromey.com>
3509 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
3511 2017-10-02 Tom Tromey <tom@tromey.com>
3513 * rust-lang.h (rust_slice_type): Add "extern".
3515 2017-10-02 Tom Tromey <tom@tromey.com>
3516 Pedro Alves <palves@redhat.com>
3518 * ada-lang.h (ada_exc_info::operator<): Make const.
3519 (ada_exc_info::operator==): Make const.
3520 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
3523 2017-09-29 Tom Tromey <tom@tromey.com>
3525 * target.c (read_whatever_is_readable): Change type of "result".
3527 (free_memory_read_result_vector): Remove.
3528 (read_memory_robust): Change return type. Update.
3529 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
3530 bin2hex, std::string.
3531 * target.h (memory_read_result_s): Remove typedef.
3532 (free_memory_read_result_vector): Remove.
3533 (read_memory_robust): Return std::vector.
3535 2017-09-29 Tom Tromey <tom@tromey.com>
3537 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
3539 2017-09-29 Tom Tromey <tom@tromey.com>
3541 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
3542 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
3543 operator< and operator==.
3544 (ada_exceptions_list): Return a std::vector.
3545 * ada-lang.c (ada_exc_info::operator<): Rename from
3546 compare_ada_exception_info.
3547 (ada_exc_info::operator==): New.
3548 (sort_remove_dups_ada_exceptions_list): Change type of
3550 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
3551 (ada_add_global_exceptions): Likewise.
3552 (ada_exceptions_list_1): Return a std::vector.
3553 (ada_exceptions_list): Likewise.
3555 2017-09-29 Tom Tromey <tom@tromey.com>
3557 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
3559 (print_one_inferior): Update.
3560 (free_vector_of_ints): Remove.
3561 (list_available_thread_groups): Change "ids" to std::set.
3562 (mi_cmd_list_thread_groups): Update.
3563 (struct collect_cores_data) <core>: Now a std::set.
3564 (collect_cores): Update.
3566 (print_one_inferior): Update.
3568 2017-09-29 Tom Tromey <tom@tromey.com>
3570 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
3571 (mi_execute_async_cli_command): Likewise.
3572 (mi_cmd_trace_frame_collected): Use field_fmt.
3574 2017-09-29 Tom Tromey <tom@tromey.com>
3576 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
3579 2017-09-29 Tom Tromey <tom@tromey.com>
3581 * mi/mi-parse.c (mi_parse): Remove unused declaration.
3583 2017-09-29 Tom Tromey <tom@tromey.com>
3585 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
3587 2017-09-29 Tom Tromey <tom@tromey.com>
3589 * varobj.h (varobj_gen_name): Return std::string.
3590 * varobj.c (varobj_gen_name): Return std::string.
3591 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
3592 (mi_cmd_var_delete): Don't copy "name".
3594 2017-09-29 Tom Tromey <tom@tromey.com>
3596 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
3597 (mi_cmd_break_insert_1): Update.
3599 2017-09-29 Tom Tromey <tom@tromey.com>
3601 * target.h (make_scoped_defer_target_commit_resume): Update.
3602 * target.c (make_scoped_defer_target_commit_resume): Rename from
3603 make_cleanup_defer_target_commit_resume. Return a
3605 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
3607 2017-09-29 Tom Tromey <tom@tromey.com>
3609 * main.c (captured_main_1): Remove unused declaration.
3610 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
3612 2017-09-29 Tom Tromey <tom@tromey.com>
3614 * symtab.c (search_symbols): Remove unused outer cleanup.
3615 (make_source_files_completion_list): Remove unused declaration.
3617 2017-09-29 Tom Tromey <tom@tromey.com>
3619 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
3621 2017-09-29 Tom Tromey <tom@tromey.com>
3623 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
3626 2017-09-29 Tom Tromey <tom@tromey.com>
3628 * complaints.c (vcomplaint): Use std::string.
3630 2017-09-29 Tom Tromey <tom@tromey.com>
3632 * tracepoint.c (trace_variable_command): Use std::string.
3633 (encode_actions_1): Remove unused declarations.
3634 (create_tsv_from_upload): Use std::string.
3636 2017-09-29 Tom Tromey <tom@tromey.com>
3638 * cp-support.c (gdb_demangle): Use std::string.
3640 2017-09-29 Tom Tromey <tom@tromey.com>
3642 * stack.c (parse_frame_specification): Use std::string
3643 (info_frame_command): Use gdb::unique_xmalloc_ptr.
3645 2017-09-29 Tom Tromey <tom@tromey.com>
3647 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
3649 2017-09-29 Tom Tromey <tom@tromey.com>
3651 * utils.c (vfprintf_maybe_filtered): Use std::string.
3652 (vfprintf_unfiltered): Likewise.
3654 2017-09-29 Tom Tromey <tom@tromey.com>
3656 * event-top.c (top_level_prompt): Return std::string.
3657 (display_gdb_prompt): Update.
3659 2017-09-29 Tom Tromey <tom@tromey.com>
3661 * unittests/common-utils-selftests.c (format): New function.
3662 (string_vprintf_tests): New function.
3663 (_initialize_common_utils_selftests): Register new tests.
3664 * common/common-utils.c (string_vprintf): New function.
3665 * common/common-utils.h (string_vprintf): Declare.
3667 2017-09-29 Pedro Alves <palves@redhat.com>
3669 * common/rsp-low.c (unpack_varlen_hex): Constify.
3670 * common/rsp-low.h (unpack_varlen_hex): Constify.
3671 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
3673 * remote.c (remote_set_permissions, read_ptid)
3674 (remote_current_thread, remote_get_threads_with_qthreadinfo)
3675 (remote_static_tracepoint_marker_at)
3676 (remote_static_tracepoint_markers_by_strid)
3677 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
3678 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
3679 (parse_tracepoint_definition, parse_tsv_definition)
3680 (parse_static_tracepoint_marker_definition): Constify.
3681 * tracepoint.h (parse_static_tracepoint_marker_definition)
3682 (parse_trace_status, parse_tracepoint_status)
3683 (parse_tracepoint_definition, parse_tsv_definition): Constify.
3685 2017-09-29 Pedro Alves <palves@redhat.com>
3687 * remote.c (target_buf, target_buf_size): Delete.
3688 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
3689 Use the connection's packet buffer instead.
3690 All callers adjusted.
3691 (_initialize_remote): Remove references to target_buf and
3694 2017-09-28 Pedro Alves <palves@redhat.com>
3696 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3697 unittests/common-utils-selftests.c.
3698 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
3699 (COMMON_OBS): Remove utils-selftests.o.
3700 * utils-selftests.c: Move to ...
3701 * unittests/common-utils-selftests.c: ... here and rename self
3702 test to "string_printf".
3704 2017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
3706 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
3707 having NULL cus or tus.
3709 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3711 * arm-tdep.c: (convert_from_extended): Remove.
3712 (convert_to_extended): Likewise.
3713 (arm_extract_return_value): Use convert_typed_floating.
3714 (arm_store_return_value): Likewise.
3716 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3717 * sh-tdep.c: Do not include "floatformat.h".
3718 (sh_littlebyte_bigword_type): New function.
3719 (sh_register_convert_to_virtual): Use convert_typed_floating.
3720 (sh_register_convert_to_raw): Likewise.
3721 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3722 (sh64_littlebyte_bigword_type): New function.
3723 (sh64_extract_return_value): Use convert_typed_floating.
3724 (sh64_register_convert_to_virtual): Likewise.
3725 (sh64_register_convert_to_raw): Likewise.
3727 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3729 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
3730 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
3732 * gdbtypes.h (union type_specific): Make field floatformat hold
3733 just a single struct floatformat, not an array.
3734 (floatformat_from_type): Move here.
3735 * gdbtypes.c (floatformat_from_type): Move here. Update to
3736 changed TYPE_FLOATFORMAT definition.
3737 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
3738 (recursive_dump_type): Likewise.
3739 (init_float_type): Install correct floatformat for byte order.
3740 (arch_float_type): Likewise.
3742 2017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3744 * gdbtypes.c (init_type): Change incoming argument from
3745 length-in-bytes to length-in-bits. Assert length is a
3746 multiple of TARGET_CHAR_BITS.
3747 (arch_type, arch_flags_type): Likewise.
3748 (init_integer_type): Update call to init_type.
3749 (init_character_type): Likewise.
3750 (init_boolean_type): Likewise.
3751 (init_float_type): Likewise.
3752 (init_decfloat_type): Likewise.
3753 (init_complex_type): Likewise.
3754 (init_pointer_type): Likewise.
3755 (objfile_type): Likewise.
3756 (arch_integer_type): Update call to arch_type.
3757 (arch_character_type): Likewise.
3758 (arch_boolean_type): Likewise.
3759 (arch_float_type): Likewise.
3760 (arch_decfloat_type): Likewise.
3761 (arch_complex_type): Likewise.
3762 (arch_pointer_type): Likewise.
3763 (gdbtypes_post_init): Likewise.
3765 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
3766 (read_base_type): Likewise.
3767 * mdebugread.c (basic_type): Likewise.
3768 * stabsread.c (dbx_init_float_type): Likewise.
3769 (rs6000_builtin_type): Likewise.
3770 (read_range_type): Likewise. Also, fix call to init_integer_type
3771 with erroneous length argument.
3773 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
3774 * d-lang.c (build_d_types): Likewise.
3775 * f-lang.c (build_fortran_types): Likewise.
3776 * go-lang.c (build_go_types): Likewise.
3777 * opencl-lang.c (build_opencl_types): Likewise.
3778 * jit.c (finalize_symtab): Likewise.
3779 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
3780 (build_std_type_info_type): Likewise.
3781 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
3782 update call to arch_flags_type.
3784 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
3786 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
3787 * windows-tdep.c (windows_get_tlb_type): Likewise.
3789 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
3790 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
3791 * m32c-tdep.c (make_types): Likewise.
3792 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
3793 (rl78_psw_type): Update call to arch_flags_type.
3794 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
3795 * rx-tdep.c (rx_psw_type): Likewise.
3796 (rx_fpsw_type): Likewise.
3797 * sparc-tdep.c (sparc_psr_type): Likewise.
3798 (sparc_fsr_type): Likewise.
3799 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
3800 (sparc64_ccr_type): Likewise.
3801 (sparc64_fsr_type): Likewise.
3802 (sparc64_fprs_type): Likewise.
3804 2017-09-27 Tom Tromey <tom@tromey.com>
3806 * findcmd.c (find_command): Constify.
3808 2017-09-27 Tom Tromey <tom@tromey.com>
3810 * ada-tasks.c (task_command_1, task_command): Constify.
3812 2017-09-27 Tom Tromey <tom@tromey.com>
3814 * symtab.c (maintenance_print_symbol_cache)
3815 (maintenance_flush_symbol_cache)
3816 (maintenance_print_symbol_cache_statistics): Constify.
3818 2017-09-27 Tom Tromey <tom@tromey.com>
3820 * inferior.c (detach_inferior_command, kill_inferior_command)
3821 (inferior_command): Constify.
3823 2017-09-27 Tom Tromey <tom@tromey.com>
3825 * regcache.c (regcache_print, maintenance_print_registers)
3826 (maintenance_print_raw_registers)
3827 (maintenance_print_cooked_registers)
3828 (maintenance_print_register_groups)
3829 (maintenance_print_remote_registers): Constify.
3831 2017-09-27 Tom Tromey <tom@tromey.com>
3833 * printcmd.c (map_display_numbers, undisplay_command)
3834 (enable_disable_display_command, enable_display_command)
3835 (disable_display_command): Constify.
3837 2017-09-27 Tom Tromey <tom@tromey.com>
3839 * breakpoint.h (delete_command): Don't declare.
3840 * breakpoint.c (delete_command, enable_once_command)
3841 (enable_count_command, enable_delete_command, breakpoint_1)
3842 (maintenance_info_breakpoints, stopin_command, stopat_command)
3843 (delete_command, delete_trace_command, save_breakpoints)
3844 (save_breakpoints_command, save_tracepoints_command): Constify.
3846 2017-09-27 Tom Tromey <tom@tromey.com>
3848 * macrocmd.c (macro_expand_command, macro_expand_once_command)
3849 (skip_ws, extract_identifier, macro_define_command)
3850 (macro_undef_command, macro_list_command): Constify.
3852 2017-09-27 Tom Tromey <tom@tromey.com>
3854 * infcmd.c (environment_info, set_environment_command)
3855 (unset_environment_command, path_info, info_proc_cmd_1)
3856 (info_proc_cmd_mappings, info_proc_cmd_stat)
3857 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
3858 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
3860 2017-09-27 Tom Tromey <tom@tromey.com>
3862 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
3865 2017-09-27 Tom Tromey <tom@tromey.com>
3867 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
3869 2017-09-27 Tom Tromey <tom@tromey.com>
3871 * demangle.c (demangle_command): Constify.
3873 2017-09-27 Tom Tromey <tom@tromey.com>
3875 * progspace.c (maintenance_info_program_spaces_command):
3878 2017-09-27 Tom Tromey <tom@tromey.com>
3880 * compile/compile.c (check_raw_argument, compile_file_command)
3881 (compile_code_command, compile_print_command): Constify.
3883 2017-09-27 Tom Tromey <tom@tromey.com>
3885 * reggroups.c (maintenance_print_reggroups): Constify.
3887 2017-09-27 Tom Tromey <tom@tromey.com>
3889 * dwarf2read.c (save_gdb_index_command): Constify.
3891 2017-09-27 Tom Tromey <tom@tromey.com>
3893 * stap-probe.c (info_probes_stap_command): Constify.
3895 2017-09-27 Tom Tromey <tom@tromey.com>
3897 * fork-child.c (unset_exec_wrapper_command): Constify.
3899 2017-09-27 Tom Tromey <tom@tromey.com>
3901 * btrace.c (get_uint, get_context_size, no_chunk)
3902 (maint_btrace_packet_history_cmd)
3903 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
3904 (maint_info_btrace_cmd): Constify.
3906 2017-09-27 Tom Tromey <tom@tromey.com>
3908 * reverse.c (delete_bookmark_command): Constify.
3910 2017-09-27 Tom Tromey <tom@tromey.com>
3912 * remote.c (set_memory_packet_size)
3913 (set_memory_write_packet_size, show_memory_write_packet_size)
3914 (set_memory_read_packet_size, show_memory_read_packet_size)
3915 (compare_sections_command, packet_command, remote_put_command)
3916 (remote_get_command, remote_delete_command): Constify.
3918 2017-09-27 Tom Tromey <tom@tromey.com>
3920 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
3921 (set_mipsfpu_double_command, set_mipsfpu_none_command)
3922 (set_mipsfpu_auto_command): Constify.
3924 2017-09-27 Tom Tromey <tom@tromey.com>
3926 * cli/cli-cmds.h (cd_command): Constify.
3927 * cli/cli-cmds.c (cd_command): Constify.
3929 2017-09-27 Tom Tromey <tom@tromey.com>
3931 * thread.c (thread_name_command, thread_find_command): Constify.
3933 2017-09-27 Tom Tromey <tom@tromey.com>
3935 * probe.c (enable_probes_command, disable_probes_command):
3938 2017-09-27 Tom Tromey <tom@tromey.com>
3940 * symfile.c (symbol_file_command): Constify.
3941 * gdbcore.h (deprecated_file_changed_hook): Constify.
3942 * exec.c (deprecated_file_changed_hook, exec_file_command)
3943 (file_command): Constify.
3944 * defs.h (symbol_file_command): Constify.
3946 2017-09-27 Tom Tromey <tom@tromey.com>
3948 * remote-fileio.c (set_system_call_allowed)
3949 (show_system_call_allowed): Constify.
3951 2017-09-27 Tom Tromey <tom@tromey.com>
3953 * tracepoint.c (delete_trace_variable_command)
3954 (tfind_end_command, tfind_start_command, tfind_pc_command)
3955 (tfind_tracepoint_command, tfind_line_command)
3956 (tfind_range_command, tfind_outside_command): Constify.
3958 2017-09-27 Tom Tromey <tom@tromey.com>
3960 * ax-gdb.c (maint_agent_printf_command, agent_command)
3961 (agent_eval_command): Constify.
3963 2017-09-27 Tom Tromey <tom@tromey.com>
3965 * tracepoint.c (info_scope_command): Constify.
3966 * python/python.c (gdbpy_decode_line): Constify.
3967 * python/py-breakpoint.c (bppy_init): Constify.
3968 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
3969 * location.h: (new_linespec_location)
3970 (string_to_event_location_basic, string_to_event_location):
3972 * location.c (new_linespec_location)
3973 (string_to_event_location_basic, string_to_event_location):
3975 * linespec.h (decode_line_with_current_source)
3976 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
3977 * linespec.c (linespec_lex_to_end)
3978 (decode_line_with_current_source)
3979 (decode_line_with_last_displayed): Constify.
3980 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
3982 * cli/cli-cmds.c (edit_command, list_command): Constify.
3983 * breakpoint.h (until_break_command, watch_command_wrapper)
3984 (awatch_command_wrapper, rwatch_command_wrapper)
3985 (init_ada_exception_breakpoint): Constify.
3986 * breakpoint.c (break_command_1, dprintf_command)
3987 (break_range_command, watch_command_wrapper)
3988 (rwatch_command_wrapper, awatch_command_wrapper)
3989 (until_break_command, init_ada_exception_breakpoint)
3990 (strace_marker_create_sals_from_location, trace_command)
3991 (ftrace_command, strace_command, struct tracepoint): Constify.
3992 * ax-gdb.c (agent_command_1): Constify.
3993 * ada-lang.c (ada_exception_sal): Constify.
3995 2017-09-27 Tom Tromey <tom@tromey.com>
3997 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
3998 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
3999 (get_context_size, no_chunk, get_insn_history_modifiers)
4000 (cmd_record_insn_history, get_call_history_modifiers)
4001 (cmd_record_call_history): Constify.
4003 2017-09-27 Tom Tromey <tom@tromey.com>
4005 * source.c (show_substitute_path_command)
4006 (unset_substitute_path_command, set_substitute_path_command):
4009 2017-09-27 Tom Tromey <tom@tromey.com>
4011 * typeprint.c (maintenance_print_type): Constify.
4012 * maint.c (maintenance_dump_me, maintenance_demangle)
4013 (maintenance_time_display, maintenance_info_sections)
4014 (maintenance_print_statistics, maintenance_deprecate)
4015 (maintenance_undeprecate): Constify.
4016 (maintenance_do_deprecate): Constify. Use std::string.
4017 (maintenance_selftest): Constify.
4018 * gdbtypes.h (maintenance_print_type): Constify.
4020 2017-09-27 Tom Tromey <tom@tromey.com>
4022 * hppa-tdep.c (unwind_command): Constify.
4024 2017-09-27 Tom Tromey <tom@tromey.com>
4026 * target-descriptions.c (unset_tdesc_filename_cmd)
4027 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
4030 2017-09-27 Tom Tromey <tom@tromey.com>
4032 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
4034 2017-09-27 Tom Tromey <tom@tromey.com>
4036 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
4038 2017-09-27 Tom Tromey <tom@tromey.com>
4040 * tui/tui-regs.c (tui_reg_command): Constify.
4042 2017-09-27 Tom Tromey <tom@tromey.com>
4044 * skip.c (skip_file_command, skip_function_command)
4045 (skip_enable_command, skip_disable_command, skip_delete_command):
4048 2017-09-27 Tom Tromey <tom@tromey.com>
4050 * record-btrace.c (cmd_record_btrace_bts_start)
4051 (cmd_record_btrace_pt_start): Constify.
4053 2017-09-27 Tom Tromey <tom@tromey.com>
4055 * symmisc.c (maintenance_print_symbols)
4056 (maintenance_print_msymbols, maintenance_print_objfiles)
4057 (maintenance_info_symtabs, maintenance_check_symtabs)
4058 (maintenance_expand_symtabs, maintenance_info_line_tables):
4061 2017-09-27 Tom Tromey <tom@tromey.com>
4063 * top.c (new_ui_command): Constify.
4065 2017-09-27 Tom Tromey <tom@tromey.com>
4067 * symfile.c (add_symbol_file_command)
4068 (remove_symbol_file_command, list_overlays_command)
4069 (map_overlay_command, unmap_overlay_command)
4070 (overlay_auto_command, overlay_manual_command)
4071 (overlay_off_command, overlay_load_command): Constify.
4073 2017-09-27 Tom Tromey <tom@tromey.com>
4075 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
4076 (info_spu_mailbox_command, info_spu_dma_command)
4077 (info_spu_proxydma_command): Constify.
4079 2017-09-27 Tom Tromey <tom@tromey.com>
4081 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
4083 2017-09-27 Tom Tromey <tom@tromey.com>
4085 * cli/cli-script.c (user_defined_command): Constify.
4087 2017-09-27 Tom Tromey <tom@tromey.com>
4089 * cli/cli-dump.c (dump_memory_command, dump_value_command)
4090 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
4091 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
4092 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
4093 (dump_binary_value, append_binary_memory, append_binary_value):
4095 (struct dump_context) <func>: Constify.
4096 (add_dump_command): Update.
4098 2017-09-27 Tom Tromey <tom@tromey.com>
4100 * cli/cli-cmds.c (show_version, show_configuration)
4101 (source_command, show_user): Constify.
4103 2017-09-27 Tom Tromey <tom@tromey.com>
4105 * target.c (maintenance_print_target_stack): Constify.
4107 2017-09-27 Tom Tromey <tom@tromey.com>
4109 * interps.c (interpreter_exec_cmd): Constify.
4111 2017-09-27 Tom Tromey <tom@tromey.com>
4113 * record-full.c (cmd_record_full_restore): Constify.
4115 2017-09-27 Tom Tromey <tom@tromey.com>
4117 * memattr.c (enable_mem_command, disable_mem_command)
4118 (delete_mem_command): Constify.
4120 2017-09-27 Tom Tromey <tom@tromey.com>
4122 * value.c (show_convenience): Constify.
4124 2017-09-27 Tom Tromey <tom@tromey.com>
4126 * gdbcore.h (core_file_command): Update.
4127 * corefile.c (core_file_command): Constify.
4129 2017-09-27 Tom Tromey <tom@tromey.com>
4131 * user-regs.c (maintenance_print_user_registers): Constify.
4133 2017-09-27 Tom Tromey <tom@tromey.com>
4135 * cp-namespace.c (maintenance_cplus_namespace): Constify.
4137 2017-09-27 Tom Tromey <tom@tromey.com>
4139 * cp-support.c (first_component_command): Constify.
4141 2017-09-27 Tom Tromey <tom@tromey.com>
4143 * psymtab.c (maintenance_print_psymbols)
4144 (maintenance_info_psymtabs, maintenance_check_psymtabs):
4147 2017-09-27 Tom Tromey <tom@tromey.com>
4149 * windows-tdep.c (display_tib): Constify.
4151 2017-09-27 Tom Tromey <tom@tromey.com>
4153 * linux-fork.c (delete_checkpoint_command)
4154 (detach_checkpoint_command): Constify.
4156 2017-09-27 Tom Tromey <tom@tromey.com>
4158 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
4160 2017-09-27 Tom Tromey <tom@tromey.com>
4162 * arc-tdep.c (dump_arc_instruction_command): Constify.
4164 2017-09-27 Tom Tromey <tom@tromey.com>
4166 * valprint.c (set_radix, show_radix): Constify.
4168 2017-09-27 Tom Tromey <tom@tromey.com>
4170 * dtrace-probe.c (info_probes_dtrace_command): Constify.
4172 2017-09-27 Tom Tromey <tom@tromey.com>
4174 * command.h (not_just_help_class_command): Update.
4175 * cli/cli-decode.h (not_just_help_class_command): Update.
4176 * cli/cli-decode.c (not_just_help_class_command): Constify.
4178 2017-09-27 Tom Tromey <tom@tromey.com>
4180 * gdb_bfd.c (maintenance_info_bfds): Constify.
4182 2017-09-27 Tom Tromey <tom@tromey.com>
4184 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
4186 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
4187 (do_const_cfunc): New function.
4188 (cmd_cfunc_eq): New overload.
4189 (cli_user_command_p): Check do_const_cfunc.
4190 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
4192 * command.h (add_cmd): Add const overload and no-function
4194 (set_cmd_cfunc): Add const overload.
4195 (cmd_const_cfunc_ftype): Declare.
4196 (cmd_cfunc_eq): Add const overload.
4197 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
4198 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
4201 2017-09-27 Tom Tromey <tom@tromey.com>
4203 * macroexp.c (get_next_token_for_substitution): New function.
4204 (substitute_args): Call it. Check for __VA_OPT__.
4206 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4207 Pedro Alves <palves@redhat.com>
4209 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
4210 producer_is_icc_lt_14.
4211 (producer_is_icc_lt_14): New function.
4212 (check_producer): Add code for checking version of ICC.
4213 (producer_is_icc): Move to producer.c.
4214 (read_structure_type): Restrict ICC workaround to ICC<14.
4215 * producer.c: Include selftest.h.
4216 (producer_is_icc, producer_parsing_tests, _initialize_producer):
4218 * producer.h (producer_is_icc): New declaration.
4220 2017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4222 * Makefile.in (SFILES): Add producer.c.
4223 (COMMON_OBS): Add producer.o
4224 * amd64-tdep.c (producer.h): Add new include.
4225 * dwarf2read.c (producer.h): Add new include.
4226 * producer.c: New file.
4227 * producer.h: New file.
4228 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
4230 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
4233 2017-09-26 Matthias Klose <doko@ubuntu.com>
4235 * configure.ac: Search ncursesw before ncurses.
4236 Check ncursesw/ncurses.h before ncurses/ncurses.h.
4237 * gdb_curses.h: Include <ncursesw/ncurses.h>
4238 * config.in, configure: Regenerate.
4240 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4243 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
4245 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
4246 Remove i386sol2 support.
4247 * configure.nat <i386sol2>: Remove.
4248 <sol2-64>: Fold into ...
4250 Move common settings to default section.
4252 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
4253 x86_64-*-solaris2.1[0-9]*>: Rename to ...
4254 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
4255 <i[34567]86-*-solaris*>: Remove.
4256 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
4258 * configure.ac: Remove wctype in libw check.
4259 (_MSE_INT_H): Don't define on Solaris 7-9.
4260 <solaris*>: Remove libthread_db.so.1 check.
4261 * configure: Regenerate.
4262 * config.in: Regenerate.
4264 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
4265 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
4266 (gdb_ps_size_t): Remove.
4267 Use base types in users.
4268 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
4270 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
4272 2017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4275 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
4276 (adi_is_addr_mapped): Likewise.
4277 (PSR_ICC): Don't redefine.
4278 (PSR_IMPL): Likewise.
4280 2017-09-25 Tom Tromey <tom@tromey.com>
4282 * regcache.c (regcache::dump): Use string_printf.
4284 2017-09-25 Tom Tromey <tom@tromey.com>
4286 * regcache.c (class regcache_invalidator): New.
4287 (struct register_to_invalidate): Remove.
4288 (make_cleanup_regcache_invalidate): Remove.
4289 (regcache::raw_write): Use regcache_invalidator.
4291 2017-09-25 Tom Tromey <tom@tromey.com>
4293 * spu-tdep.c (spu2ppu_sniffer): Update.
4294 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
4295 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
4297 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
4298 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
4299 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
4300 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
4301 (frame_pop): Update.
4303 2017-09-25 Tom Tromey <tom@tromey.com>
4305 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
4306 * regcache.h (regcache_xfree): Don't declare.
4307 * regcache.c (regcache_xfree): Remove.
4308 (do_regcache_xfree): Use delete.
4309 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
4310 * linux-fork.c (free_fork): Use delete.
4311 (fork_save_infrun_state): Likewise.
4312 * jit.c (jit_dealloc_cache): Use delete.
4313 * infrun.c (discard_infcall_suspend_state): Use delete.
4315 2017-09-25 Tom Tromey <tom@tromey.com>
4317 * regcache.h (regcache_xmalloc): Don't declare.
4318 (regcache_raw_set_cached_value): Update comment.
4319 * regcache.c (regcache_xmalloc): Remove.
4320 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
4321 * jit.c (jit_frame_sniffer): Use new.
4322 * frame.c (frame_save_as_regcache): Use new.
4324 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4326 * NEWS: Advertise support for guarded-storage registers on IBM z.
4328 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4330 * s390-linux-nat.c (have_regset_gs): New static variable.
4331 (s390_linux_fetch_inferior_registers): Handle guarded-storage
4332 control block and guarded-storage broadcast control regsets.
4333 (s390_read_description): Detect whether the target has
4334 guarded-storage support, return appropriate tdesc.
4335 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
4336 (features/s390x-gs-linux64.c): Likewise.
4337 (struct gdbarch_tdep) <have_gs>: New field.
4338 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
4339 (s390_gsbc_regset): New variables.
4340 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
4341 and s390_gsbc_regset, if applicable.
4342 (s390_core_read_description): Check whether core file was from a
4343 target with guarded-storage support; include appropriate regsets.
4344 (s390_gdbarch_init): Add registers for guarded-storage support.
4345 (_initialize_s390_tdep): Initialize new target descriptions that
4346 include registers for guarded-storage support.
4347 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
4348 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
4349 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
4350 (S390_NUM_REGS): Adjust macro definition.
4351 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
4352 (tdesc_s390x_gs_linux64): New declarations.
4354 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4356 * features/s390-gs-linux64.xml: New file.
4357 * features/s390-gs.xml: New file.
4358 * features/s390-gsbc.xml: New file.
4359 * features/s390x-gs-linux64.xml: New file.
4360 * features/Makefile (WHICH): Add s390-gs-linux64 and
4362 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
4363 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
4364 * features/s390-gs-linux64.c: New generated file.
4365 * features/s390x-gs-linux64.c: New file.
4366 * regformats/s390-gs-linux64.dat: New file.
4367 * regformats/s390x-gs-linux64.dat: New file.
4369 2017-09-23 Tom Tromey <tom@tromey.com>
4371 * defs.h (make_cleanup_override_quit_handler): Don't declare.
4373 2017-09-22 Tom Tromey <tom@tromey.com>
4375 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
4376 type to scoped_restore_tmpl.
4377 <scoped_input_handler>: Initialize m_quit_handler directly.
4379 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4381 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
4382 (cd_command): Likewise. Free "current_directory" before
4384 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
4385 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
4386 * top.c (gdb_dirbuf): Remove global declaration.
4387 * top.h (gdb_dirbuf): Likewise.
4389 2017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4391 * gnulib/aclocal.m4: Regenerate.
4392 * gnulib/config.in: Regenerate.
4393 * gnulib/configure: Regenerate.
4394 * gnulib/import/Makefile.am: Regenerate.
4395 * gnulib/import/Makefile.in: Regenerate.
4396 * gnulib/import/assure.h: New file.
4397 * gnulib/import/at-func.c: Likewise
4398 * gnulib/import/chdir-long.c: New file.
4399 * gnulib/import/chdir-long.h: New file.
4400 * gnulib/import/cloexec.c: New file.
4401 * gnulib/import/cloexec.h: New file.
4402 * gnulib/import/close.c: New file.
4403 * gnulib/import/closedir.c: New file.
4404 * gnulib/import/dirent-private.h: New file.
4405 * gnulib/import/dup-safer.c: New file.
4406 * gnulib/import/dup.c: New file.
4407 * gnulib/import/dup2.c: New file.
4408 * gnulib/import/error.c: New file.
4409 * gnulib/import/error.h: New file.
4410 * gnulib/import/exitfail.c: New file.
4411 * gnulib/import/exitfail.h: New file.
4412 * gnulib/import/fchdir.c: New file.
4413 * gnulib/import/fcntl.c: New file.
4414 * gnulib/import/fcntl.in.h: New file.
4415 * gnulib/import/fd-hook.c: New file.
4416 * gnulib/import/fd-hook.h: New file.
4417 * gnulib/import/fd-safer.c: New file.
4418 * gnulib/import/fdopendir.c: New file.
4419 * gnulib/import/filename.h: New file.
4420 * gnulib/import/filenamecat-lgpl.c: New file.
4421 * gnulib/import/filenamecat.h: New file.
4422 * gnulib/import/fstat.c: New file.
4423 * gnulib/import/fstatat.c: New file.
4424 * gnulib/import/getcwd-lgpl.c: New file.
4425 * gnulib/import/getcwd.c: New file.
4426 * gnulib/import/getdtablesize.c: New file.
4427 * gnulib/import/getlogin_r.c: New file.
4428 * gnulib/import/getprogname.c: New file.
4429 * gnulib/import/getprogname.h: New file.
4430 * gnulib/import/gettext.h: New file.
4431 * gnulib/import/glob-libc.h: New file.
4432 * gnulib/import/glob.c: New file.
4433 * gnulib/import/glob.in.h: New file.
4434 * gnulib/import/intprops.h: New file.
4435 * gnulib/import/m4/chdir-long.m4: New file.
4436 * gnulib/import/m4/close.m4: New file.
4437 * gnulib/import/m4/closedir.m4: New file.
4438 * gnulib/import/m4/d-ino.m4: New file.
4439 * gnulib/import/m4/d-type.m4: New file.
4440 * gnulib/import/m4/dup.m4: New file.
4441 * gnulib/import/m4/dup2.m4: New file.
4442 * gnulib/import/m4/error.m4: New file.
4443 * gnulib/import/m4/fchdir.m4: New file.
4444 * gnulib/import/m4/fcntl.m4: New file.
4445 * gnulib/import/m4/fcntl_h.m4: New file.
4446 * gnulib/import/m4/fdopendir.m4: New file.
4447 * gnulib/import/m4/filenamecat.m4: New file.
4448 * gnulib/import/m4/fstat.m4: New file.
4449 * gnulib/import/m4/fstatat.m4: New file.
4450 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
4451 * gnulib/import/m4/getcwd-path-max.m4: New file.
4452 * gnulib/import/m4/getcwd.m4: New file.
4453 * gnulib/import/m4/getdtablesize.m4: New file.
4454 * gnulib/import/m4/getlogin_r.m4: New file.
4455 * gnulib/import/m4/getprogname.m4: New file.
4456 * gnulib/import/m4/glob.m4: New file.
4457 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4458 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4459 * gnulib/import/m4/mempcpy.m4: New file.
4460 * gnulib/import/m4/memrchr.m4: New file.
4461 * gnulib/import/m4/mode_t.m4: New file.
4462 * gnulib/import/m4/msvc-inval.m4: New file.
4463 * gnulib/import/m4/msvc-nothrow.m4: New file.
4464 * gnulib/import/m4/open.m4: New file.
4465 * gnulib/import/m4/openat.m4: New file.
4466 * gnulib/import/m4/opendir.m4: New file.
4467 * gnulib/import/m4/readdir.m4: New file.
4468 * gnulib/import/m4/realloc.m4: New file.
4469 * gnulib/import/m4/rewinddir.m4: New file.
4470 * gnulib/import/m4/save-cwd.m4: New file.
4471 * gnulib/import/m4/strdup.m4: New file.
4472 * gnulib/import/m4/strerror.m4: New file.
4473 * gnulib/import/m4/unistd-safer.m4: New file.
4474 * gnulib/import/mempcpy.c: New file.
4475 * gnulib/import/memrchr.c: New file.
4476 * gnulib/import/msvc-inval.c: New file.
4477 * gnulib/import/msvc-inval.h: New file.
4478 * gnulib/import/msvc-nothrow.c: New file.
4479 * gnulib/import/msvc-nothrow.h: New file.
4480 * gnulib/import/open.c: New file.
4481 * gnulib/import/openat-die.c: New file.
4482 * gnulib/import/openat-priv.h: New file.
4483 * gnulib/import/openat-proc.c: New file.
4484 * gnulib/import/openat.c: New file.
4485 * gnulib/import/openat.h: New file.
4486 * gnulib/import/opendir.c: New file.
4487 * gnulib/import/pipe-safer.c: New file.
4488 * gnulib/import/readdir.c: New file.
4489 * gnulib/import/realloc.c: New file.
4490 * gnulib/import/rewinddir.c: New file.
4491 * gnulib/import/save-cwd.c: New file.
4492 * gnulib/import/save-cwd.h: New file.
4493 * gnulib/import/strdup.c: New file.
4494 * gnulib/import/strerror-override.c: New file.
4495 * gnulib/import/strerror-override.h: New file.
4496 * gnulib/import/strerror.c: New file.
4497 * gnulib/import/unistd--.h: New file.
4498 * gnulib/import/unistd-safer.h: New file.
4499 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
4500 "getcwd" and "glob".
4501 * ser-tcp.c: Undefine "close" before redefining it.
4503 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4505 * guile/scm-value.c (gdbscm_value_address): Initialize address,
4508 2017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4510 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
4511 <sol2,sparc>: Likewise.
4512 <sol2-64,i386>: Likewise.
4514 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
4515 -Wdeprecated-declarations on *-*-solaris*.
4516 * configure: Regenerate.
4518 * procfs.c: Include "nat/inferior.h".
4519 (procfs_info_proc): Fix typo.
4521 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4523 * remote.c (vector): Include.
4524 (struct private_thread_info): Add field, thread_handle.
4525 (free_private_thread_info): Deallocate storage associated with
4527 (get_private_info_thread): Initialize `thread_handle' field.
4528 (struct thread_item): Add field, thread_handle.
4529 (clear_threads_listing_context): Deallocate storage associated
4531 (start_thread): Add support for "handle" attribute.
4532 (thread_attributes): Add "handle".
4533 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
4535 (remote_update_thread_list): Update thread_handle.
4536 (remote_thread_handle_to_thread_info): New function.
4537 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
4539 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4541 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
4543 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
4544 * python/python-internal.h (thread_object_type): Declare.
4546 2017-09-21 Kevin Buettner <kevinb@redhat.com>
4548 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
4549 (target_thread_handle_to_thread_info): Declare.
4550 * target.c (target_thread_handle_to_thread_info): New function.
4551 * target-delegates.c: Regenerate.
4552 * gdbthread.h (find_thread_by_handle): Declare.
4553 * thread.c (find_thread_by_handle): New function.
4554 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
4556 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
4558 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4560 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
4562 2017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4564 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
4566 2017-09-21 Yao Qi <yao.qi@linaro.org>
4568 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
4571 2017-09-20 Tom Tromey <tom@tromey.com>
4573 * breakpoint.c (struct counted_command_line): Remove.
4574 (breakpoint_commands): Update.
4575 (alloc_counted_command_line, incref_counted_command_line)
4576 (decref_counted_command_line, do_cleanup_counted_command_line)
4577 (make_cleanup_decref_counted_command_line): Remove.
4578 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
4579 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
4580 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
4581 (save_breakpoints): Update.
4582 * breakpoint.h (counted_command_line): Now a typedef to
4584 (struct breakpoint) <commands>: Now a counted_command_line.
4585 (struct bpstats) <command>: Likewise.
4587 2017-09-20 Tom Tromey <tom@tromey.com>
4589 * breakpoint.c (struct commands_info, do_map_commands_command):
4591 (commands_command_1): Update.
4592 (iterate_over_related_breakpoints): Take a function_view.
4593 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
4594 (delete_command): Update.
4595 (map_breakpoint_numbers): Take a function_view.
4596 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
4597 (disable_command): Update.
4598 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
4599 (enable_command): Update.
4600 (struct disp_data, do_enable_breakpoint_disp)
4601 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
4602 (do_map_enable_delete_breakpoint): Remove.
4603 (enable_once_command, enable_count_command, enable_delete_command)
4604 (delete_trace_variable_command): Update.
4606 2017-09-20 Tom Tromey <tom@tromey.com>
4608 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
4609 (bpstat_clear): Use delete.
4610 (bpstats): New constructors.
4611 (bpstat_copy, bpstat_stop_status): Use new.
4612 (dprintf_after_condition_true): Update.
4613 * breakpoint.h (bpstats::bpstats): Add constructors.
4614 (bpstats::~bpstats): Add destructor.
4616 2017-09-20 Pedro Alves <palves@redhat.com>
4618 * eval.c (make_params): Delete, refactored as ...
4619 (class fake_method): ... this new type's ctor.
4620 (fake_method::~fake_method): New.
4621 (evaluate_subexp_standard): Use 'fake_method'.
4623 2017-09-20 Tom Tromey <tom@tromey.com>
4625 * windows-nat.c (get_windows_debug_event, windows_wait)
4626 (do_initial_windows_stuff, windows_attach): Update.
4627 * utils.c (vwarning, internal_vproblem): Update.
4628 (ui_unregister_input_event_handler_cleanup)
4629 (prepare_to_handle_input): Remove.
4630 (class scoped_input_handler): New.
4631 (defaulted_query, prompt_for_continue): Update.
4632 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
4634 * top.c (undo_terminal_modifications_before_exit): Update.
4635 * target/target.h (target_terminal_init, target_terminal_inferior)
4636 (target_terminal_ours): Don't declare.
4637 (class target_terminal): New.
4638 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
4639 (target_terminal_ours_for_output)
4640 (make_cleanup_restore_target_terminal): Don't declare.
4641 (target_terminal_info): Remove.
4642 * target.c (enum terminal_state, terminal_state): Remove.
4643 (target_terminal::terminal_state): Define.
4644 (target_terminal::init): Rename from target_terminal_init.
4645 (target_terminal::inferior): Rename from
4646 target_terminal_inferior.
4647 (target_terminal::ours): Rename from target_terminal_ours.
4648 (target_terminal::ours_for_output): Rename from
4649 target_terminal_ours_for_output.
4650 (target_terminal::info): New method.
4651 (cleanup_restore_target_terminal)
4652 (make_cleanup_restore_target_terminal): Remove.
4653 * solib.c (handle_solib_event): Update.
4654 * remote.c (remote_serial_quit_handler): Update.
4655 (remote_terminal_inferior, remote_wait_as): Update.
4656 * record-full.c (record_full_wait_1): Update.
4657 * nto-procfs.c (procfs_create_inferior): Update.
4658 * nat/fork-inferior.c (startup_inferior): Update.
4659 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
4660 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
4661 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
4662 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
4663 (mi_breakpoint_created, mi_breakpoint_deleted)
4664 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
4665 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4666 (mi_user_selected_context_changed, report_initial_inferior):
4668 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
4669 (linux_nat_terminal_inferior): Update.
4670 * infrun.c (follow_fork_inferior)
4671 (handle_vfork_child_exec_or_exit, do_target_resume)
4672 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
4673 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
4675 * inflow.c (child_terminal_init, info_terminal_command): Update.
4676 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
4677 (attach_command): Update.
4678 * infcall.c (call_thread_fsm_should_stop): Update.
4679 * gnu-nat.c (gnu_attach): Update.
4680 * extension.c (struct active_ext_lang_state)
4681 (restore_active_ext_lang): Update.
4682 * exceptions.c (print_flush): Update.
4683 * event-top.c (async_enable_stdin, default_quit_handler): Update.
4684 (struct quit_handler_cleanup_data, restore_quit_handler)
4685 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
4687 * cp-support.c (gdb_demangle): Update.
4688 * breakpoint.c (update_inserted_breakpoint_locations)
4689 (insert_breakpoint_locations, handle_jit_event)
4690 (disable_breakpoints_in_unloaded_shlib): Update.
4691 * annotate.c (annotate_breakpoints_invalid)
4692 (annotate_frames_invalid): Update.
4694 2017-09-20 Tom Tromey <tom@tromey.com>
4696 * main.c (catch_command_errors): Rename from
4697 catch_command_errors_const.
4698 (captured_main_1): Update.
4700 2017-09-20 Pedro Alves <palves@redhat.com>
4702 * cli/cli-cmds.c (list_command): Use print_sal_location.
4703 (print_sal_location): New function.
4704 (ambiguous_line_spec): Use print_sal_location.
4705 * linespec.c (symbol_to_sal): Record the symbol in the sal.
4706 * symtab.c (find_function_start_sal): Likewise.
4707 * symtab.h (symtab_and_line::symbol): New field.
4709 2017-09-20 Pedro Alves <palves@redhat.com>
4711 * linespec.c (minsym_found): Handle non-text minsyms.
4712 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
4714 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4716 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
4719 2017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4721 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
4722 vmovups instead vmovaps.
4723 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
4725 2017-09-19 John Baldwin <jhb@FreeBSD.org>
4727 * NEWS (Changes since GDB 8.0): Add starti.
4728 * infcmd.c (enum run_break): New.
4729 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
4731 (run_command): Use enum run_how.
4732 (start_command): Likewise.
4733 (starti_command): New function.
4734 (RUN_ARGS_HELP): New macro.
4735 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
4736 commands. Add starti command.
4738 2017-09-19 Yao Qi <yao.qi@linaro.org>
4740 * Makefile.in (monitor.o): Remove the rule.
4742 2017-09-19 Yao Qi <yao.qi@linaro.org>
4744 * annotate.h (struct annotate_arg_emitter): Use
4745 DISABLE_COPY_AND_ASSIGN.
4746 * common/refcounted-object.h (refcounted_object): Likewise.
4747 * completer.h (struct completion_result): Likewise.
4748 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
4749 * filename-seen-cache.h (filename_seen_cache): Likewise.
4750 * gdbcore.h (thread_section_name): Likewise.
4751 * gdb_regex.h (compiled_regex): Likewise.
4752 * gdbthread.h (scoped_restore_current_thread): Likewise.
4753 * inferior.h (scoped_restore_current_inferior): Likewise.
4754 * jit.c (jit_reader): Likewise.
4755 * linespec.h (struct linespec_result): Likewise.
4756 * mi/mi-parse.h (struct mi_parse): Likewise.
4757 * nat/fork-inferior.c (execv_argv): Likewise.
4758 * progspace.h (scoped_restore_current_program_space): Likewise.
4759 * python/python-internal.h (class gdbpy_enter): Likewise.
4760 * regcache.h (regcache): Likewise.
4761 * target-descriptions.c (struct tdesc_reg): Likewise.
4762 (struct tdesc_type): Likewise.
4763 (struct tdesc_feature): Likewise.
4764 * ui-out.h (ui_out_emit_type): Likewise.
4766 2017-09-18 Simon Marchi <simon.marchi@ericsson.com>
4768 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
4769 label abort_expression.
4771 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4773 * common/buffer.c (buffer_xml_printf): Adjust.
4774 * common/xml-utils.c (xml_escape_text): Change return type to
4775 std::string, update code accordingly.
4776 * common/xml-utils.h (xml_escape_text): Change return type to
4778 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
4779 * windows-tdep.c (windows_xfer_shared_library): Adjust.
4780 * unittests/xml-utils-selftests.c (test_xml_escape_text):
4783 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4785 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
4786 (SUBDIR_UNITTESTS_OBS): Add new object file.
4787 * unittests/xml-utils-selftests.c: New file.
4789 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4791 * common/selftest.h (selftest): New struct/interface.
4792 (register_test): Add name parameter, add new overload.
4793 (run_tests): Add filter parameter.
4794 (for_each_selftest_ftype): New typedef.
4795 (for_each_selftest): New declaration.
4796 * common/selftest.c (tests): Change type to
4797 map<string, unique_ptr<selftest>>.
4798 (simple_selftest): New struct.
4799 (register_test): New function.
4800 (register_test): Add name parameter and use it.
4801 (run_tests): Add filter parameter and use it. Add prints.
4802 Adjust to vector -> map change.
4803 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
4804 registering selftests.
4805 * arm-tdep.c (_initialize_arm_tdep): Likewise.
4806 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
4807 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
4808 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
4809 * findvar.c (_initialize_findvar): Likewise.
4810 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
4811 * maint.c (maintenance_selftest): Update call to run_tests.
4812 (maintenance_info_selftests): New function.
4813 (_initialize_maint_cmds): Register "maintenance info selftests"
4814 command. Update "maintenance selftest" doc.
4815 * regcache.c (_initialize_regcache): Add names when registering
4817 * rust-exp.y (_initialize_rust_exp): Likewise.
4818 * selftest-arch.c (gdbarch_selftest): New struct.
4819 (gdbarch_tests): Remove.
4820 (register_test_foreach_arch): Add name parameter. Call
4822 (tests_with_arch): Remove, move most content to
4823 gdbarch_selftest::operator().
4824 (_initialize_selftests_foreach_arch): Remove.
4825 * selftest-arch.h (register_test_foreach_arch): Add name
4827 (run_tests_with_arch): New declaration.
4828 * utils-selftests.c (_initialize_utils_selftests): Add names
4829 when registering selftests.
4830 * utils.c (_initialize_utils): Likewise.
4831 * unittests/array-view-selftests.c
4832 (_initialize_array_view_selftests): Likewise.
4833 * unittests/environ-selftests.c (_initialize_environ_selftests):
4835 * unittests/function-view-selftests.c
4836 (_initialize_function_view_selftests): Likewise.
4837 * unittests/offset-type-selftests.c
4838 (_initialize_offset_type_selftests): Likewise.
4839 * unittests/optional-selftests.c
4840 (_initialize_optional_selftests): Likewise.
4841 * unittests/scoped_restore-selftests.c
4842 (_initialize_scoped_restore_selftests): Likewise.
4843 * NEWS: Document "maintenance selftest" and "maint info
4846 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4848 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
4851 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4853 * mi/mi-main.c (mi_load_progress): Make uiout variable
4856 2017-09-15 Pedro Alves <palves@redhat.com>
4858 * compile/compile-c-types.c (convert_enum, convert_int)
4859 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
4861 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4863 * dwarf2read.c (copy_string): Remove.
4864 (parse_macro_definition): Replace copy_string with savestring.
4866 2017-09-15 Yao Qi <yao.qi@linaro.org>
4868 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
4870 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
4872 (i[34567]86-*-linux*): Likewise.
4874 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4876 * dwarf2expr.h (dwarf_stack_value): Add constructor.
4877 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
4878 <stack>: Change type to std::vector.
4879 <stack_len, stack_allocated>: Remove.
4880 <grow_stack>: Remove.
4881 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
4882 (dwarf_expr_context::~dwarf_expr_context): Remove.
4883 (dwarf_expr_context::grow_stack): Remove.
4884 (dwarf_expr_context::push): Adjust.
4885 (dwarf_expr_context::pop): Adjust.
4886 (dwarf_expr_context::fetch): Adjust.
4887 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
4888 (dwarf_expr_context::stack_empty_p): Adjust.
4889 (dwarf_expr_context::execute_stack_op): Adjust.
4891 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4893 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
4894 return type to bool.
4895 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
4897 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4899 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
4900 Change type to bool.
4901 (dwarf_stack_value) <in_stack_memory>: Likewise.
4902 (dwarf_expr_context) <push_address>: Change parameter type to
4904 <fetch_in_stack_memory>: Change return type to bool.
4905 <push>: Change parameter type to bool.
4906 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
4908 (dwarf_expr_context::push_address): Likewise.
4909 (dwarf_expr_context::fetch_in_stack_memory): Change return type
4911 (dwarf_expr_context::execute_stack_op): Adjust.
4912 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
4914 2017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4916 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
4917 (struct dwarf_expr_context) <n_pieces>: Remove.
4918 <pieces>: Change type to std::vector.
4919 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
4920 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
4922 (dwarf_expr_context::add_piece): Adjust.
4923 * dwarf2loc.c (struct piece_closure): Initialize fields.
4925 <pieces>: Change type to std::vector.
4926 (allocate_piece_closure): Adjust, change parameter to
4927 std::vector rvalue and std::move it to piece_closure.
4928 (rw_pieced_value): Adjust.
4929 (check_pieced_synthetic_pointer): Adjust.
4930 (indirect_synthetic_pointer): Adjust.
4931 (coerce_pieced_ref): Adjust.
4932 (free_pieced_value_closure): Adjust. Use delete to free
4934 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
4935 to allocate_piece_closure.
4936 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
4938 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
4940 * probe.h (probe_ops_cp): Remove typedef.
4941 (DEF_VEC_P (probe_ops_cp)): Remove.
4942 (all_probe_ops): Change type to std::vector.
4943 * probe.c (info_probes_for_ops): Adjust to vector change.
4944 (probe_linespec_to_ops): Likewise.
4945 (all_probe_ops): Change type to std::vector.
4946 (_initialize_probe): Adjust to vector change.
4947 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
4948 * elfread.c (elf_get_probes): Likewise.
4949 * stap-probe.c (_initialize_stap_probe): Likewise.
4951 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
4953 * probe.h (struct bound_probe): Define constructors.
4954 * probe.c (bound_probe_s): Remove typedef.
4955 (DEF_VEC_O (bound_probe_s)): Remove VEC.
4956 (collect_probes): Change return type to std::vector, remove
4958 (compare_probes): Return bool, change parameter type. Change
4959 semantic to "less than".
4960 (gen_ui_out_table_header_info): Change parameter to std::vector
4962 (exists_probe_with_pops): Likewise.
4963 (info_probes_for_ops): Update to std::vector change.
4964 (enable_probes_command): Likewise.
4965 (disable_probes_command): Likewise.
4967 2017-09-12 Simon Marchi <simon.marchi@ericsson.com>
4969 * probe.h (struct probe_ops) <get_probes>: Change parameter from
4971 * probe.c (parse_probes_in_pspace): Update.
4972 (find_probes_in_objfile): Update.
4973 (find_probe_by_pc): Update.
4974 (collect_probes): Update.
4975 (probe_any_get_probes): Update.
4976 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
4977 return type to reference to std::vector.
4978 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
4979 std::vector and update.
4980 (dtrace_process_dof): Likewise.
4981 (dtrace_get_probes): Likewise.
4982 * elfread.c (elf_get_probes): Change return type to std::vector,
4983 store an std::vector in bfd_data.
4984 (probe_key_free): Update to std::vector.
4985 * stap-probe.c (handle_stap_probe): Change parameter to
4986 std::vector and update.
4987 (stap_get_probes): Likewise.
4988 * symfile-debug.c (debug_sym_get_probes): Change return type to
4989 std::vector and update.
4991 2017-09-11 Tom Tromey <tom@tromey.com>
4993 * breakpoint.c (program_breakpoint_here_p): Update.
4994 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
4995 from make_show_memory_breakpoints_cleanup. Return a
4996 scoped_restore_tmpl<int>.
4997 (restore_show_memory_breakpoints): Remove.
4998 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
4999 * mem-break.c (memory_validate_breakpoint): Update.
5000 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
5001 (ia64_memory_remove_breakpoint): Update.
5002 (ia64_breakpoint_from_pc): Update.
5003 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
5004 from make_show_memory_breakpoints_cleanup.
5006 2017-09-11 Tom Tromey <tom@tromey.com>
5008 * d-namespace.c (d_lookup_symbol): Use std::string.
5009 (find_symbol_in_baseclass): Likewise.
5011 2017-09-11 Tom Tromey <tom@tromey.com>
5013 * ctf.c (ctf_start): Use std::string.
5015 2017-09-11 Tom Tromey <tom@tromey.com>
5017 * ada-lang.c (is_known_support_routine): Update.
5018 (ada_unhandled_exception_name_addr_from_raise): Update.
5019 * guile/scm-frame.c (gdbscm_frame_name): Update.
5020 * python/py-frame.c (frapy_name): Update.
5021 (frapy_function): Update.
5022 * stack.h (find_frame_funname): Update.
5023 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
5024 (print_frame): Update.
5026 2017-09-11 Tom Tromey <tom@tromey.com>
5028 * findcmd.c (put_bits): Take a gdb::byte_vector.
5029 (parse_find_args): Return gdb::byte_vector. "args" now const.
5030 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
5032 (find_command): Update.
5034 2017-09-11 Tom Tromey <tom@tromey.com>
5036 * cli/cli-script.c (class scoped_restore_hook_in): New.
5037 (clear_hook_in_cleanup): Remove.
5038 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
5039 scoped_restore_hook_in.
5041 2017-09-11 Tom Tromey <tom@tromey.com>
5043 * cli/cli-script.c (restore_interp): Remove.
5044 (read_command_lines): Use scoped_restore_interp.
5045 * interps.c (scoped_restore_interp::set_temp): Rename from
5047 * interps.h (class scoped_restore_interp): New.
5048 (interp_set_temp): Remove.
5050 2017-09-11 Tom Tromey <tom@tromey.com>
5052 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5053 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
5054 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
5056 (mi_cmd_break_insert_1): Update.
5057 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
5060 2017-09-11 Tom Tromey <tom@tromey.com>
5062 * demangle.c (demangle_command): Update.
5063 * breakpoint.c (disable_command): Update.
5064 (enable_command): Update.
5065 (find_location_by_number): Make "number" const. Use
5067 * cli/cli-utils.c (extract_arg): Return std::string.
5068 * probe.c (parse_probe_linespec): Update. Change types.
5069 (collect_probes): Take string arguments.
5070 (parse_probe_linespec): Likewise.
5071 (info_probes_for_ops): Update.
5072 (enable_probes_command): Update.
5073 (disable_probes_command): Update.
5074 * break-catch-sig.c (catch_signal_split_args): Update.
5075 * mi/mi-parse.c (mi_parse): Update.
5077 2017-09-11 Tom Tromey <tom@tromey.com>
5079 * language.h (language_enum): Make argument const.
5080 * language.c (language_enum): Make argument const.
5082 2017-09-11 Tom Tromey <tom@tromey.com>
5084 * common/common-utils.h (skip_to_space): Remove macro, redeclare
5086 (skip_to_space): Rename from skip_to_space_const.
5087 * common/common-utils.c (skip_to_space): New function.
5088 (skip_to_space): Rename from skip_to_space_const.
5089 * cli/cli-utils.h (get_number): Rename from get_number_const.
5090 (extract_arg): Rename from extract_arg_const.
5091 * cli/cli-utils.c (get_number): Rename from get_number_const.
5092 (extract_arg): Rename from extract_arg_const.
5093 (number_or_range_parser::get_number): Use ::get_number.
5094 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
5095 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
5096 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
5097 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
5098 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
5099 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
5100 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
5101 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
5103 2017-09-11 Tom Tromey <tom@tromey.com>
5105 * python/python.c (do_start_initialization): Use
5106 py-event-types.def to initialize types.
5107 Define all object type structures.
5108 * python/python-internal.h: Don't declare event initialization
5110 * python/py-threadevent.c (thread_event_object_type): Don't
5112 * python/py-stopevent.c (stop_event_object_type): Don't define.
5113 * python/py-signalevent.c (signal_event_object_type): Don't
5115 * python/py-newobjfileevent.c (new_objfile_event_object_type)
5116 (clear_objfiles_event_object_type): Don't declare or define.
5117 * python/py-infevents.c (inferior_call_pre_event_object_type)
5118 (inferior_call_post_event_object_type)
5119 (register_changed_event_object_type)
5120 (memory_changed_event_object_type): Don't declare or define.
5121 * python/py-inferior.c (new_thread_event_object_type)
5122 (new_inferior_event_object_type)
5123 (inferior_deleted_event_object_type): Don't declare or define.
5124 * python/py-exitedevent.c (exited_event_object_type): Don't
5126 * python/py-evts.c (gdbpy_initialize_py_events): Use
5128 * python/py-events.h (thread_event_object_type): Don't declare.
5129 (events_object): Use py-all-events.def.
5130 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
5132 * python/py-event-types.def: New file.
5133 * python/py-continueevent.c (create_continue_event_object): Don't
5135 * python/py-bpevent.c (breakpoint_event_object_type): Don't
5137 * python/py-all-events.def: New file.
5139 2017-09-11 Tom Tromey <tom@tromey.com>
5141 * python/py-threadevent.c (create_thread_event_object): Return
5143 * python/py-stopevent.h (create_stop_event_object)
5144 (create_breakpoint_event_object, create_signal_event_object):
5146 * python/py-stopevent.c (create_stop_event_object): Return
5148 (emit_stop_event): Update.
5149 * python/py-signalevent.c (create_signal_event_object): Return
5151 * python/py-infevents.c (create_inferior_call_event_object):
5153 * python/py-event.h (create_event_object)
5154 (create_thread_event_object): Update.
5155 * python/py-event.c (create_event_object): Return gdbpy_ref.
5156 * python/py-continueevent.c: Return gdbpy_ref.
5157 * python/py-bpevent.c (create_breakpoint_event_object): Return
5160 2017-09-11 Tom Tromey <tom@tromey.com>
5164 * python/python.c (do_start_initialization): Initialize new event
5166 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
5167 (gdbpy_initialize_inferior_deleted_event)
5168 (gdbpy_initialize_new_thread_event): Declare.
5169 * python/py-threadevent.c (create_thread_event_object): Add option
5171 * python/py-inferior.c (new_thread_event_object_type)
5172 (new_inferior_event_object_type)
5173 (inferior_deleted_event_object_type): Declare.
5174 (python_new_inferior, python_inferior_deleted): New functions.
5175 (add_thread_object): Emit new_thread event.
5176 (gdbpy_initialize_inferior): Attach new functions to corresponding
5178 (new_thread, new_inferior, inferior_deleted): Define new event
5180 * python/py-evts.c (gdbpy_initialize_py_events): Add new
5182 * python/py-events.h (events_object) <new_inferior,
5183 inferior_deleted, new_thread>: New fields.
5184 * python/py-event.h (create_thread_event_breakpoint): Add optional
5187 2017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
5189 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
5190 check current_ui instead.
5191 (internal_vproblem): Likewise.
5193 2017-09-09 Simon Marchi <simon.marchi@ericsson.com>
5195 * thread.c (print_thread_info_1): Remove unnecessary calls to
5196 uiout->is_mi_like_p.
5198 2017-09-09 Tom Tromey <tom@tromey.com>
5200 * namespace.h (add_using_directive): Update.
5201 * namespace.c (add_using_directive): Change type of excludes to
5203 * dwarf2read.c (read_import_statement): Use std::vector.
5204 (read_namespace): Update.
5205 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
5207 2017-09-09 Tom Tromey <tom@tromey.com>
5209 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
5211 2017-09-09 Tom Tromey <tom@tromey.com>
5213 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
5215 2017-09-09 Tom Tromey <tom@tromey.com>
5217 * stack.c (func_command): Use gdb::def_vector.
5219 2017-09-09 Tom Tromey <tom@tromey.com>
5221 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
5222 ui_out_emit_list, ui_out_emit_tuple.
5223 (mi_cmd_var_update): Likewise.
5225 2017-09-09 Tom Tromey <tom@tromey.com>
5227 * mi/mi-interp.c (mi_user_selected_context_changed): Use
5228 ui_out_redirect_pop.
5229 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
5230 ui_out_redirect_pop.
5231 * utils.c (do_ui_out_redirect_pop)
5232 (make_cleanup_ui_out_redirect_pop): Remove.
5233 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
5234 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
5235 * ui-out.h (ui_out_redirect_pop): New class.
5237 2017-09-09 Tom Tromey <tom@tromey.com>
5239 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
5240 (list_available_thread_groups, mi_cmd_list_thread_groups)
5241 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
5242 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
5245 2017-09-09 Tom Tromey <tom@tromey.com>
5247 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
5250 2017-09-09 Tom Tromey <tom@tromey.com>
5252 * target.c (flash_erase_command): Use ui_out_emit_tuple.
5253 * stack.c (print_frame): Use ui_out_emit_tuple.
5254 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
5255 (info_spu_mailbox_command, info_spu_dma_command)
5256 (info_spu_proxydma_command): Likewise.
5257 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
5258 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
5259 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
5261 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
5263 2017-09-09 Tom Tromey <tom@tromey.com>
5265 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
5266 (class ui_out_emit_table): Update comment.
5267 * ui-out.c (do_cleanup_table_end)
5268 (make_cleanup_ui_out_table_begin_end): Remove.
5269 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
5270 (info_spu_dma_cmdlist): Likewise.
5271 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
5272 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
5275 2017-09-09 Tom Tromey <tom@tromey.com>
5277 * thread.c (print_thread_info_1): Use ui_out_emit_table,
5278 ui_out_emit_list, gdb::optional.
5280 2017-09-09 John Baldwin <jhb@FreeBSD.org>
5282 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
5284 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
5286 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
5288 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
5289 * ada-exp.y: Remove _initialize_ada_exp prototype.
5290 * ada-lang.c: Remove _initialize_ada_language prototype.
5291 * ada-tasks.c: Remove _initialize_tasks prototype.
5292 * addrmap.c: Remove _initialize_addrmap prototype.
5293 * agent.c: Remove _initialize_agent prototype.
5294 * aix-thread.c: Remove _initialize_aix_thread prototype.
5295 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
5296 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
5297 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
5299 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
5300 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
5301 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
5302 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
5304 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
5306 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
5307 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
5308 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
5309 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
5311 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
5312 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
5313 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
5314 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
5315 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5316 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
5317 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
5319 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
5321 * annotate.c: Remove _initialize_annotate prototype.
5322 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
5323 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
5324 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
5325 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
5326 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
5327 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
5328 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
5329 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
5331 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
5332 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
5333 * auto-load.c: Remove _initialize_auto_load prototype.
5334 * auxv.c: Remove _initialize_auxv prototype.
5335 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
5336 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
5337 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
5338 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
5339 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
5340 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
5342 * break-catch-throw.c: Remove _initialize_break_catch_throw
5344 * breakpoint.c: Remove _initialize_breakpoint prototype.
5345 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
5346 * btrace.c: Remove _initialize_btrace prototype.
5347 * charset.c: Remove _initialize_charset prototype.
5348 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
5349 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
5350 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
5351 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
5352 * cli/cli-script.c: Remove _initialize_cli_script prototype.
5353 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
5354 * coffread.c: Remove _initialize_coffread prototype.
5355 * compile/compile.c: Remove _initialize_compile prototype.
5356 * complaints.c: Remove _initialize_complaints prototype.
5357 * completer.c: Remove _initialize_completer prototype.
5358 * copying.awk: Remove _initialize_copying prototype.
5359 * copying.c: Regenerate.
5360 * core-regset.c: Remove _initialize_core_regset prototype.
5361 * corefile.c: Remove _initialize_core prototype.
5362 * corelow.c: Remove _initialize_corelow prototype.
5363 * cp-abi.c: Remove _initialize_cp_abi prototype.
5364 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
5365 * cp-support.c: Remove _initialize_cp_support prototype.
5366 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
5367 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
5368 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
5369 * ctf.c: Remove _initialize_ctf prototype.
5370 * d-lang.c: Remove _initialize_d_language prototype.
5371 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
5373 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
5374 * dbxread.c: Remove _initialize_dbxread prototype.
5375 * dcache.c: Remove _initialize_dcache prototype.
5376 * demangle.c: Remove _initialize_demangler prototype.
5377 * disasm-selftests.c: Remove _initialize_disasm_selftests
5379 * disasm.c: Remove _initialize_disasm prototype.
5380 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
5381 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
5382 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
5384 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
5385 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
5386 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
5387 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
5388 * elfread.c: Remove _initialize_elfread prototype.
5389 * exec.c: Remove _initialize_exec prototype.
5390 * extension.c: Remove _initialize_extension prototype.
5391 * f-lang.c: Remove _initialize_f_language prototype.
5392 * f-valprint.c: Remove _initialize_f_valprint prototype.
5393 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
5394 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
5395 * filesystem.c: Remove _initialize_filesystem prototype.
5396 * findcmd.c: Remove _initialize_mem_search prototype.
5397 * fork-child.c: Remove _initialize_fork_child prototype.
5398 * frame-base.c: Remove _initialize_frame_base prototype.
5399 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
5400 * frame.c: Remove _initialize_frame prototype.
5401 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
5402 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
5403 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
5404 * gcore.c: Remove _initialize_gcore prototype.
5405 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
5406 * gdbarch.c: Regenerate.
5407 * gdbarch.sh: Remove _initialize_gdbarch prototype.
5408 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
5409 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
5410 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
5411 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
5412 * go-lang.c: Remove _initialize_go_language prototype.
5413 * go32-nat.c: Remove _initialize_go32_nat prototype.
5414 * guile/guile.c: Remove _initialize_guile prototype.
5415 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
5416 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
5417 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
5418 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
5419 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
5420 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
5421 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
5422 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
5423 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
5424 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
5426 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
5428 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
5429 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
5430 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
5431 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
5432 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
5433 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
5434 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
5435 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
5436 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
5437 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
5438 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
5439 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
5440 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
5441 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5442 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
5443 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
5445 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
5447 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
5448 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
5449 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
5450 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
5451 * infcall.c: Remove _initialize_infcall prototype.
5452 * infcmd.c: Remove _initialize_infcmd prototype.
5453 * inferior.c: Remove _initialize_inferiors prototype.
5454 * inflow.c: Remove _initialize_inflow prototype.
5455 * infrun.c: Remove _initialize_infrun prototype.
5456 * interps.c: Remove _initialize_interpreter prototype.
5457 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
5458 * jit.c: Remove _initialize_jit prototype.
5459 * language.c: Remove _initialize_language prototype.
5460 * linux-fork.c: Remove _initialize_linux_fork prototype.
5461 * linux-nat.c: Remove _initialize_linux_nat prototype.
5462 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
5463 * linux-thread-db.c: Remove _initialize_thread_db prototype.
5464 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
5465 * m2-lang.c: Remove _initialize_m2_language prototype.
5466 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
5467 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
5468 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
5469 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
5470 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
5471 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5472 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5473 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
5474 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
5475 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
5476 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5477 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5478 * machoread.c: Remove _initialize_machoread prototype.
5479 * macrocmd.c: Remove _initialize_macrocmd prototype.
5480 * macroscope.c: Remove _initialize_macroscope prototype.
5481 * maint.c: Remove _initialize_maint_cmds prototype.
5482 * mdebugread.c: Remove _initialize_mdebugread prototype.
5483 * memattr.c: Remove _initialize_mem prototype.
5484 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
5485 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
5486 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
5487 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
5488 * mi/mi-main.c: Remove _initialize_mi_main prototype.
5489 * microblaze-linux-tdep.c: Remove
5490 _initialize_microblaze_linux_tdep prototype.
5491 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
5492 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
5493 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
5494 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
5495 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
5496 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
5497 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
5498 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
5499 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
5500 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
5501 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
5503 * mipsread.c: Remove _initialize_mipsread prototype.
5504 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
5506 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
5507 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
5508 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
5509 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
5510 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
5511 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
5513 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
5514 * nto-procfs.c: Remove _initialize_procfs prototype.
5515 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
5516 * objc-lang.c: Remove _initialize_objc_language prototype.
5517 * objfiles.c: Remove _initialize_objfiles prototype.
5518 * observer.c: Remove observer_test_first_notification_function,
5519 observer_test_second_notification_function,
5520 observer_test_third_notification_function, and
5521 _initialize_observer prototypes.
5522 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
5523 * osabi.c: Remove _initialize_gdb_osabi prototype.
5524 * osdata.c: Remove _initialize_osdata prototype.
5525 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
5526 * parse.c: Remove _initialize_parse prototype.
5527 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
5528 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
5529 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
5530 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
5531 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
5532 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
5533 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
5534 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
5535 * printcmd.c: Remove _initialize_printcmd prototype.
5536 * probe.c: Remove _initialize_probe prototype.
5537 * proc-api.c: Remove _initialize_proc_api prototype.
5538 * proc-events.c: Remove _initialize_proc_events prototype.
5539 * proc-service.c: Remove _initialize_proc_service prototype.
5540 * procfs.c: Remove _initialize_procfs prototype.
5541 * psymtab.c: Remove _initialize_psymtab prototype.
5542 * python/python.c: Remove _initialize_python prototype.
5543 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
5544 * record-btrace.c: Remove _initialize_record_btrace prototype.
5545 * record-full.c: Remove _initialize_record_full prototype.
5546 * record.c: Remove _initialize_record prototype.
5547 * regcache.c: Remove _initialize_regcache prototype.
5548 * reggroups.c: Remove _initialize_reggroup prototype.
5549 * remote-notif.c: Remove _initialize_notif prototype.
5550 * remote-sim.c: Remove _initialize_remote_sim prototype.
5551 * remote.c: Remove _initialize_remote prototype.
5552 * reverse.c: Remove _initialize_reverse prototype.
5553 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
5554 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
5555 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
5557 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
5558 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
5559 * rust-exp.y: Remove _initialize_rust_exp prototype.
5560 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
5561 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
5562 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
5563 * score-tdep.c: Remove _initialize_score_tdep prototype.
5564 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
5566 * ser-go32.c: Remove _initialize_ser_dos prototype.
5567 * ser-mingw.c: Remove _initialize_ser_windows prototype.
5568 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
5569 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
5570 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
5571 * serial.c: Remove _initialize_serial prototype.
5572 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
5573 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
5574 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
5575 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
5576 * skip.c: Remove _initialize_step_skip prototype.
5577 * sol-thread.c: Remove _initialize_sol_thread prototype.
5578 * solib-aix.c: Remove _initialize_solib_aix prototype.
5579 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
5580 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
5581 * solib-frv.c: Remove _initialize_frv_solib prototype.
5582 * solib-spu.c: Remove _initialize_spu_solib prototype.
5583 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
5584 * solib-target.c: Remove _initialize_solib_target prototype.
5585 * solib.c: Remove _initialize_solib prototype.
5586 * source.c: Remove _initialize_source prototype.
5587 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
5588 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
5590 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
5591 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
5592 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
5593 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
5595 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
5596 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
5597 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
5598 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
5600 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
5602 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
5604 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
5606 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
5607 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
5609 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
5611 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
5613 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
5615 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
5617 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
5618 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
5619 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
5620 * stabsread.c: Remove _initialize_stabsread prototype.
5621 * stack.c: Remove _initialize_stack prototype.
5622 * stap-probe.c: Remove _initialize_stap_probe prototype.
5623 * std-regs.c: Remove _initialize_frame_reg prototype.
5624 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
5625 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
5626 * symfile.c: Remove _initialize_symfile prototype.
5627 * symmisc.c: Remove _initialize_symmisc prototype.
5628 * symtab.c: Remove _initialize_symtab prototype.
5629 * target-dcache.c: Remove _initialize_target_dcache prototype.
5630 * target-descriptions.c: Remove _initialize_target_descriptions
5632 * thread.c: Remove _initialize_thread prototype.
5633 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
5635 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
5636 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
5637 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
5639 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
5640 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
5641 * tracefile.c: Remove _initialize_tracefile prototype.
5642 * tracepoint.c: Remove _initialize_tracepoint prototype.
5643 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
5644 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
5645 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
5646 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
5647 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
5648 * tui/tui-win.c: Remove _initialize_tui_win prototype.
5649 * tui/tui.c: Remove _initialize_tui prototype.
5650 * typeprint.c: Remove _initialize_typeprint prototype.
5651 * user-regs.c: Remove _initialize_user_regs prototype.
5652 * utils.c: Remove _initialize_utils prototype.
5653 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
5654 * valarith.c: Remove _initialize_valarith prototype.
5655 * valops.c: Remove _initialize_valops prototype.
5656 * valprint.c: Remove _initialize_valprint prototype.
5657 * value.c: Remove _initialize_values prototype.
5658 * varobj.c: Remove _initialize_varobj prototype.
5659 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
5660 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
5661 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
5662 * windows-nat.c: Remove _initialize_windows_nat,
5663 _initialize_check_for_gdb_ini, and _initialize_loadable
5665 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
5666 * xcoffread.c: Remove _initialize_xcoffread prototype.
5667 * xml-support.c: Remove _initialize_xml_support prototype.
5668 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
5669 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
5671 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
5673 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
5675 2017-09-08 Keith Seitz <keiths@redhat.com>
5677 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
5680 2017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
5682 * f-valprint.c (f_val_print): Remove check for one byte
5683 sized integers. Remove printing of character type.
5685 2017-09-08 Frank Penczek <frank.penczek@intel.com>
5686 Christoph Weinmann <christoph.t.weinmann@intel.com>
5687 Bernhard Heckel <bernhard.heckel@intel.com>
5689 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
5690 to maintain proper indentation when printing pointers/refs.
5692 2017-09-07 Joel Brobecker <brobecker@adacore.com>
5696 2017-09-07 Joel Brobecker <brobecker@adacore.com>
5698 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
5700 2017-09-05 Tom Tromey <tom@tromey.com>
5702 * parse.c (funcall_chain): Now a std::vector.
5703 (start_arglist, end_arglist): Simplify.
5704 (free_funcalls): Remove.
5705 (parse_exp_in_context_1): Remove cleanup.
5707 2017-09-05 Tom Tromey <tom@tromey.com>
5709 * go-exp.y (go_parse): Don't create a cleanup.
5711 2017-09-05 Tom Tromey <tom@tromey.com>
5713 * d-exp.y (PrimaryExpression): Use std::string.
5714 (d_parse): Don't create a cleanup.
5716 2017-09-05 Tom Tromey <tom@tromey.com>
5718 * utils.c (do_clear_parser_state): Remove.
5719 (make_cleanup_clear_parser_state): Remove.
5720 * p-exp.y (pascal_parse): Use scoped_restore.
5721 * m2-exp.y (m2_parse): Use scoped_restore.
5722 * f-exp.y (f_parse): Use scoped_restore.
5723 * d-exp.y (d_parse): Use scoped_restore.
5724 * c-exp.y (c_parse): Use scoped_restore.
5725 * ada-exp.y (ada_parse): Use scoped_restore.
5726 * utils.h (make_cleanup_clear_parser_state): Remove.
5728 2017-09-06 Keith Seitz <keiths@redhat.com>
5730 * dwarf2read.c (dw2_linkage_name_attr): New function.
5731 (dw2_linkage_name): New function.
5732 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
5733 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
5734 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
5736 2017-09-06 Kamil Rytarowski <n54@gmx.com>
5738 * config/djgpp/djconfig.sh: Correct shell portability issue.
5740 2017-09-06 Kamil Rytarowski <n54@gmx.com>
5742 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
5744 2017-09-06 John Baldwin <jhb@FreeBSD.org>
5746 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
5747 * NEWS: Mention new FreeBSD/mips native configuration.
5748 * configure.host: Add aarch64*-*-freebsd*.
5749 * configure.nat: Likewise.
5750 * aarch64-fbsd-nat.c: New file.
5752 2017-09-06 John Baldwin <jhb@FreeBSD.org>
5754 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
5755 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
5756 * NEWS: Mention new FreeBSD/aarch64 target.
5757 * configure.tgt: Add aarch64*-*-freebsd*.
5758 * aarch64-fbsd-tdep.c: New file.
5759 * aarch64-fbsd-tdep.h: New file.
5761 2017-09-06 Kamil Rytarowski <n54@gmx.com>
5763 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
5765 2017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
5767 * parse.c (find_minsym_type_and_address): Don't relocate addresses
5770 2017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5772 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
5775 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5777 * infrun.c (follow_exec): Call add_thread after
5778 target_find_description.
5780 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5782 * infrun.c (handle_inferior_event_1): When exec'ing, read
5783 stop_pc after follow_exec.
5785 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5787 * remote.c (process_g_packet): Update error message.
5789 2017-09-05 Yao Qi <yao.qi@linaro.org>
5791 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
5794 2017-09-05 Pedro Alves <palves@redhat.com>
5796 * eval.c (eval_call, evaluate_funcall): New functions, factored
5798 (evaluate_subexp_standard): ... this.
5800 2017-09-05 Yao Qi <yao.qi@linaro.org>
5802 * amd64-tdep.c (amd64_target_description): Create target
5804 (_initialize_amd64_tdep): Don't call functions
5805 initialize_tdesc_amd64_*. Add self tests.
5806 * arch/amd64.c (amd64_create_target_description): Add parameter
5807 is_linux. Call set_tdesc_osabi if is_linux is true.
5808 * arch/amd64.h (amd64_create_target_description): Update the
5810 * arch/i386.c (i386_create_target_description): Add parameter
5811 is_linux. Call set_tdesc_osabi if is_linux is true.
5812 * arch/i386.h (i386_create_target_description): Update
5814 * configure.tgt: Add i386.o to gdb_target_obs.
5815 * features/Makefile (XMLTOC): Remove i386/*.xml.
5816 * features/i386/amd64-avx-avx512.c: Remove.
5817 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
5818 * features/i386/amd64-avx-mpx.c: Remove.
5819 * features/i386/amd64-avx.c: Remove.
5820 * features/i386/amd64-mpx.c: Remove.
5821 * features/i386/amd64.c: Remove.
5822 * features/i386/i386-avx-avx512.c: Remove.
5823 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
5824 * features/i386/i386-avx-mpx.c: Remove.
5825 * features/i386/i386-avx.c: Remove.
5826 * features/i386/i386-mmx.c: Remove.
5827 * features/i386/i386-mpx.c: Remove.
5828 * features/i386/i386.c: Remove.
5829 * i386-tdep.c: Don't include features/i386/i386*.c., include
5830 target-descriptions.h and arch/i386.h.
5831 (i386_target_description): Create target descriptions.
5832 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
5833 functions. Do self tests.
5835 2017-09-05 Yao Qi <yao.qi@linaro.org>
5837 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
5838 * features/i386/amd64-avx-avx512-linux.c: Removed.
5839 * features/i386/amd64-avx-linux.c: Removed.
5840 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
5841 * features/i386/amd64-avx-mpx-linux.c: Removed.
5842 * features/i386/amd64-linux.c: Removed.
5843 * features/i386/amd64-mpx-linux.c: Removed.
5844 * features/i386/x32-avx-avx512-linux.c: Removed.
5845 * features/i386/x32-avx-linux.c: Removed.
5846 * features/i386/x32-linux.c: Removed.
5848 2017-09-05 Yao Qi <yao.qi@linaro.org>
5850 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
5852 (amd64_linux_read_description): Call
5853 amd64_create_target_description.
5854 * arch/amd64.c: New file.
5855 * arch/amd64.h: New file.
5856 * configure.tgt (x86_64-*-linux*): Append amd64.o.
5857 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
5859 2017-09-05 Yao Qi <yao.qi@linaro.org>
5861 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
5862 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
5863 (amd64_linux_read_description): Create target descriptions.
5864 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
5865 functions. Add unit tests.
5866 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
5868 * features/i386/64bit-avx.c: Generated.
5869 * features/i386/64bit-avx512.c: Generated.
5870 * features/i386/64bit-core.c: Generated.
5871 * features/i386/64bit-linux.c: Generated.
5872 * features/i386/64bit-mpx.c: Generated.
5873 * features/i386/64bit-pkeys.c: Generated.
5874 * features/i386/64bit-segments.c: Generated.
5875 * features/i386/64bit-sse.c: Generated.
5876 * features/i386/x32-core.c: Generated.
5877 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
5878 c files for amd64-linux and x32-linux.
5880 2017-09-05 Yao Qi <yao.qi@linaro.org>
5882 * amd64-linux-tdep.c (amd64_linux_read_description): New
5884 (amd64_linux_core_read_description): Call
5885 amd64_linux_read_description.
5886 (amd64_linux_init_abi): Likewise.
5887 (amd64_x32_linux_init_abi): Likewise.
5888 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
5889 * x86-linux-nat.c (x86_linux_read_description): Call
5890 amd64_linux_read_description.
5892 2017-09-05 Yao Qi <yao.qi@linaro.org>
5894 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
5897 2017-09-05 Yao Qi <yao.qi@linaro.org>
5899 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
5900 * features/i386/i386-avx-avx512-linux.c: Remove.
5901 * features/i386/i386-avx-linux.c: Remove.
5902 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
5903 * features/i386/i386-avx-mpx-linux.c: Remove.
5904 * features/i386/i386-linux.c: Remove.
5905 * features/i386/i386-mmx-linux.c: Remove.
5906 * features/i386/i386-mpx-linux.c: Remove.
5908 2017-09-05 Yao Qi <yao.qi@linaro.org>
5910 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
5911 (SFILES): Add arch/i386.c.
5912 (HFILES_NO_SRCDIR): Add arch/i386.h.
5913 * arch/i386.c: New file.
5914 * arch/i386.h: New file.
5915 * arch/tdesc.h (allocate_target_description): Declare.
5916 (set_tdesc_architecture): Declare.
5917 (set_tdesc_osabi): Declare.
5918 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
5919 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
5920 include arch/i386.h.
5921 (i386_linux_read_description): Remove code and call
5922 i386_create_target_description.
5923 (set_tdesc_architecture): New function.
5924 (set_tdesc_osabi): New function.
5925 * target-descriptions.h (allocate_target_description): Remove.
5927 2017-09-05 Yao Qi <yao.qi@linaro.org>
5929 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
5930 * target-descriptions.c (tdesc_create_feature): Likewise, and
5932 * features/i386/32bit-avx.c: Re-generated.
5933 * features/i386/32bit-avx512.c: Re-generated.
5934 * features/i386/32bit-core.c: Re-generated.
5935 * features/i386/32bit-linux.c: Re-generated.
5936 * features/i386/32bit-mpx.c: Re-generated.
5937 * features/i386/32bit-pkeys.c: Re-generated.
5938 * features/i386/32bit-sse.c: Re-generated.
5940 2017-09-05 Yao Qi <yao.qi@linaro.org>
5942 * regformats/regdef.h (struct reg): Override operator == and !=.
5944 2017-09-05 Yao Qi <yao.qi@linaro.org>
5946 * arch/tdesc.h: New file.
5947 * regformats/regdat.sh: Generate code using tdesc_create_reg.
5948 * target-descriptions.c: Update comments.
5949 * target-descriptions.h: Include "arch/tdesc.h". Remove the
5951 * features/i386/32bit-avx.c: Re-generated.
5952 * features/i386/32bit-avx512.c: Re-generated.
5953 * features/i386/32bit-core.c: Re-generated.
5954 * features/i386/32bit-linux.c: Re-generated.
5955 * features/i386/32bit-mpx.c: Re-generated.
5956 * features/i386/32bit-pkeys.c: Re-generated.
5957 * features/i386/32bit-sse.c: Re-generated.
5959 2017-09-05 Yao Qi <yao.qi@linaro.org>
5961 * regformats/regdat.sh: Update generated code.
5963 2017-09-05 Yao Qi <yao.qi@linaro.org>
5965 * regformats/regdat.sh: Adjust code order.
5967 2017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5969 * expprint.c (dump_subexp_body_standard): Use constant format
5970 string in fprintf_filtered call.
5972 2017-09-04 John Baldwin <jhb@FreeBSD.org>
5974 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
5976 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
5978 2017-09-04 John Baldwin <jhb@FreeBSD.org>
5980 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
5982 2017-09-04 John Baldwin <jhb@FreeBSD.org>
5984 * bsd-kvm.o: Define _KMEMUSER.
5985 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
5986 * configure: Regenerate.
5988 2017-09-04 John Baldwin <jhb@FreeBSD.org>
5990 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
5991 * i386-fbsd-nat.c: Likewise.
5993 2017-09-04 John Baldwin <jhb@FreeBSD.org>
5995 * unittests/array-view-selftests.c: Add include of <array>.
5997 2017-09-04 John Baldwin <jhb@FreeBSD.org>
5999 * spu-tdep.c (flush_ea_cache): Add missing argument to
6000 call_function_by_hand.
6002 2017-09-04 Pedro Alves <palves@redhat.com>
6004 * NEWS (Safer support for debugging with no debug info): New.
6006 2017-09-04 Pedro Alves <palves@redhat.com>
6008 * c-exp.y (function_method, function_method_void): Add current
6009 instance flags to TYPE_INSTANCE.
6010 * dwarf2read.c (check_modifier): New.
6011 (compute_delayed_physnames): Assert that only C++ adds delayed
6012 physnames. Mark fn_fields as const/volatile depending on
6014 * eval.c (make_params): New type_instance_flags parameter. Use
6015 it as the new type's instance flags.
6016 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
6017 flags element and pass it to make_params.
6018 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
6019 instance flags element.
6020 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
6021 * gdbtypes.h: Include "enum-flags.h".
6022 (type_instance_flags): New enum-flags type.
6023 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
6024 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
6025 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
6026 (follow_type_instance_flags): New function.
6027 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
6028 * parser-defs.h (follow_type_instance_flags): Declare.
6029 * valops.c (value_struct_elt_for_reference): const/volatile must
6032 2017-09-04 Pedro Alves <palves@redhat.com>
6034 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
6035 function/method scopes; lookup the nested name as a function local
6038 2017-09-04 Pedro Alves <palves@redhat.com>
6040 (%type <voidval>): Add function_method.
6041 * c-exp.y (exp): New production for calls with no arguments.
6042 (function_method, function_method_void_or_typelist): New
6044 (exp): New production for "method()::static_var".
6045 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
6046 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6047 Handle OP_FUNC_STATIC_VAR.
6048 * parse.c (operator_length_standard):
6049 Handle OP_FUNC_STATIC_VAR.
6051 2017-09-04 Pedro Alves <palves@redhat.com>
6053 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
6055 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6057 * parse.c (operator_length_standard, operator_check_standard):
6059 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
6061 2017-09-04 Pedro Alves <palves@redhat.com>
6063 * ax-gdb.c: Include "typeprint.h".
6064 (gen_expr_for_cast): New function.
6065 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
6066 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
6068 * dwarf2read.c (new_symbol_full): Fallback to int instead of
6069 nodebug_data_symbol.
6070 * eval.c: Include "typeprint.h".
6071 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
6072 Error out if symbol has unknown type.
6073 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
6074 evaluate_subexp_for_cast.
6075 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
6077 (evaluate_subexp_for_cast): New function.
6078 * gdbtypes.c (init_nodebug_var_type): New function.
6079 (objfile_type): Use it to initialize types of variables with no
6081 * typeprint.c (error_unknown_type): New.
6082 * typeprint.h (error_unknown_type): New declaration.
6083 * compile/compile-c-types.c (convert_type_basic): Handle
6084 TYPE_CODE_ERROR; warn and fallback to int for variables with
6087 2017-09-04 Pedro Alves <palves@redhat.com>
6089 * eval.c (evaluate_var_value): New function, factored out from ...
6090 (evaluate_subexp_standard): ... here.
6092 2017-09-04 Pedro Alves <palves@redhat.com>
6094 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
6095 Remove useless assignments to 'op'.
6097 2017-09-04 Pedro Alves <palves@redhat.com>
6099 * eval.c (eval_skip_value): New function.
6100 (evaluate_subexp_standard): Use it.
6102 2017-09-04 Pedro Alves <palves@redhat.com>
6104 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
6105 function name from symbol/minsym and pass it to
6106 error_call_unknown_return_type.
6108 2017-09-04 Pedro Alves <palves@redhat.com>
6110 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
6111 * ax-gdb.c (gen_msym_var_ref): New function.
6112 (gen_expr): Handle OP_VAR_MSYM_VALUE.
6113 * eval.c (evaluate_var_msym_value): New function.
6114 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
6115 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
6116 to call_function_by_hand.
6117 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6118 Handle OP_VAR_MSYM_VALUE.
6119 (union exp_element) <msymbol>: New field.
6120 * minsyms.h (struct type): Forward declare.
6121 (find_minsym_type_and_address): Declare.
6122 * parse.c (write_exp_elt_msym): New function.
6123 (write_exp_msymbol): Delete, refactored as ...
6124 (find_minsym_type_and_address): ... this new function.
6125 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
6126 (operator_length_standard, operator_check_standard): Handle
6128 * std-operator.def (OP_VAR_MSYM_VALUE): New.
6130 2017-09-04 Pedro Alves <palves@redhat.com>
6132 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
6133 TYPE_GNU_IFUNC specially here. Throw error if return type is
6135 * ada-typeprint.c (print_func_type): Handle functions with unknown
6137 * c-typeprint.c (c_type_print_base): Handle functions and methods
6138 with unknown return type.
6139 * compile/compile-c-symbols.c (convert_symbol_bmsym)
6140 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
6141 * compile/compile-c-types.c: Include "objfiles.h".
6142 (convert_func): For functions with unknown return type, warn and
6144 * compile/compile-object-run.c (compile_object_run): Adjust call
6145 to call_function_by_hand_dummy.
6146 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
6147 call_function_by_hand.
6148 * eval.c (evaluate_subexp_standard): Adjust calls to
6149 call_function_by_hand. Handle functions and methods with unknown
6150 return type. Pass expect_type to call_function_by_hand.
6151 * f-typeprint.c (f_type_print_base): Handle functions with unknown
6153 * gcore.c (call_target_sbrk): Adjust call to
6154 call_function_by_hand.
6155 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
6156 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
6157 an integer address type instead of nodebug.
6158 * guile/scm-value.c (gdbscm_value_call): Adjust call to
6159 call_function_by_hand.
6160 * infcall.c (error_call_unknown_return_type): New function.
6161 (call_function_by_hand): New "default_return_type" parameter.
6163 (call_function_by_hand_dummy): New "default_return_type"
6164 parameter. Use it instead of defaulting to int. If there's no
6165 default and the return type is unknown, throw an error. If
6166 there's a default return type, and the called function has no
6167 debug info, then assume the function is prototyped.
6168 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
6169 New "default_return_type" parameter.
6170 (error_call_unknown_return_type): New declaration.
6171 * linux-fork.c (call_lseek): Cast return type of lseek.
6172 (inferior_call_waitpid, checkpoint_command): Adjust calls to
6173 call_function_by_hand.
6174 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
6175 calls to call_function_by_hand.
6176 * m2-typeprint.c (m2_procedure): Handle functions with unknown
6178 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6179 (value_nsstring, print_object_command): Adjust calls to
6180 call_function_by_hand.
6181 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
6182 functions with unknown return type.
6183 (pascal_type_print_func_varspec_suffix): New function.
6184 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
6185 TYPE_CODE_METHOD>: Use it.
6186 * python/py-value.c (valpy_call): Adjust call to
6187 call_function_by_hand.
6188 * rust-lang.c (rust_evaluate_funcall): Adjust call to
6189 call_function_by_hand.
6190 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
6191 call_function_by_hand.
6192 * valops.c (value_allocate_space_in_inferior): Adjust call to
6193 call_function_by_hand.
6194 * typeprint.c (type_print_unknown_return_type): New function.
6195 * typeprint.h (type_print_unknown_return_type): New declaration.
6197 2017-09-04 Pedro Alves <palves@redhat.com>
6199 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
6200 types with more than one parameter as prototyped.
6202 2017-09-04 Pedro Alves <palves@redhat.com>
6204 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
6205 (disassemble_command): Use gdb_disassembly_flags instead of bare
6207 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
6208 (dump_insns, do_mixed_source_and_assembly_deprecated)
6209 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
6210 Use gdb_disassembly_flags instead of bare int.
6211 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
6212 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
6213 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
6214 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
6215 (enum gdb_disassembly_flag): ... values of this new enumeration.
6216 (gdb_disassembly_flags): Define.
6218 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
6219 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
6220 gdb_disassembly_flags instead of bare int.
6221 * record-btrace.c (btrace_insn_history)
6222 (record_btrace_insn_history, record_btrace_insn_history_range)
6223 (record_btrace_insn_history_from): Use gdb_disassembly_flags
6224 instead of bare int.
6225 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
6226 Use gdb_disassembly_flags instead of bare int.
6227 * target-debug.h (target_debug_print_gdb_disassembly_flags):
6229 * target-delegates.c: Regenerate.
6230 * target.c (target_insn_history, target_insn_history_from)
6231 (target_insn_history_range): Use gdb_disassembly_flags instead of
6233 * target.h: Include "disasm.h".
6234 (struct target_ops) <to_insn_history, to_insn_history_from,
6235 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
6237 (target_insn_history, target_insn_history_from)
6238 (target_insn_history_range): Use gdb_disassembly_flags instead of
6241 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6243 * cli/cli-script.c (build_command_line): For if/while commands,
6244 check whether args is empty.
6246 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6248 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
6249 (enum command_control_type): Likewise.
6250 (struct command_line): Likewise.
6251 (free_command_lines): Likewise.
6252 (struct command_lines_deleter): Likewise.
6253 (command_line_up): Likewise.
6254 (read_command_lines): Likewise.
6255 (read_command_lines_1): Likewise.
6256 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
6257 (enum command_control_type): Likewise.
6258 (struct command_line): Likewise.
6259 (free_command_lines): Likewise.
6260 (struct command_lines_deleter): Likewise.
6261 (command_line_up): Likewise.
6262 (read_command_lines): Likewise.
6263 (read_command_lines_1): Likewise.
6264 * breakpoint.h: Include cli/cli-script.h.
6265 * extension-priv.h: Likewise.
6266 * gdbcmd.h: Likewise.
6268 2017-09-04 Pedro Alves <palves@redhat.com>
6270 * ada-lang.c (is_known_support_routine): Move sal declaration to
6271 where it is initialized.
6272 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
6273 (parse_breakpoint_sals, decode_static_tracepoint_spec)
6274 (clear_command, update_static_tracepoint): Remove init_sal
6275 references. Move declarations closer to initializations.
6276 * cli/cli-cmds.c (list_command): Move sal declarations closer to
6278 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
6279 references. Move sal declarations closer to initializations.
6280 * frame.c (find_frame_sal): Return a symtab_and_line via function
6281 return instead of output parameter. Remove init_sal references.
6282 * frame.h (find_frame_sal): Return a symtab_and_line via function
6283 return instead of output parameter.
6284 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
6285 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
6287 (gdbscm_find_pc_line): Remove init_sal reference.
6288 * infcall.c (call_function_by_hand_dummy): Remove init_sal
6289 references. Move declarations closer to initializations.
6290 * infcmd.c (set_step_frame): Update. Move declarations closer to
6292 (finish_backward): Remove init_sal references. Move declarations
6293 closer to initializations.
6294 * infrun.c (process_event_stop_test, handle_step_into_function)
6295 (insert_hp_step_resume_breakpoint_at_frame)
6296 (insert_step_resume_breakpoint_at_caller): Likewise.
6297 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
6298 (symbol_to_sal): Likewise.
6299 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
6300 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
6301 to its initialization.
6302 * reverse.c (save_bookmark_command): Use new/delete. Remove
6303 init_sal references. Move declarations closer to initializations.
6304 * source.c (get_current_source_symtab_and_line): Remove brace
6306 (set_current_source_symtab_and_line): Now takes the sal by const
6307 reference. Remove brace initialization.
6308 (line_info): Remove init_sal reference.
6309 * source.h (set_current_source_symtab_and_line): Now takes a
6310 symtab_and_line via const reference.
6311 * stack.c (set_current_sal_from_frame): Adjust.
6312 (print_frame_info): Adjust.
6313 (get_last_displayed_sal): Return the sal via function return
6314 instead of via output parameter. Simplify.
6315 (frame_info): Adjust.
6316 * stack.h (get_last_displayed_sal): Return the sal via function
6317 return instead of via output parameter.
6318 * symtab.c (init_sal): Delete.
6319 (find_pc_sect_line): Remove init_sal references. Move
6320 declarations closer to initializations.
6321 (find_function_start_sal): Remove init_sal references. Move
6322 declarations closer to initializations.
6323 * symtab.h (struct symtab_and_line): In-class initialize all
6325 * tracepoint.c (set_traceframe_context)
6326 (print_one_static_tracepoint_marker): Remove init_sal references.
6327 Move declarations closer to initializations.
6328 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
6329 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
6330 declarations closer to initializations.
6331 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
6332 init_sal references. Adjust.
6334 2017-09-04 Pedro Alves <palves@redhat.com>
6336 * ax-gdb.c (agent_command_1): Use range-for.
6337 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6338 * breakpoint.c: Include "common/array-view.h".
6339 (init_breakpoint_sal, create_breakpoint_sal): Change sals
6340 parameter from struct symtabs_and_lines to
6341 array_view<symtab_and_line>. Adjust. Use range-for. Update.
6342 (breakpoint_sals_to_pc): Change sals parameter from struct
6343 symtabs_and_lines to std::vector reference.
6344 (check_fast_tracepoint_sals): Change sals parameter from struct
6345 symtabs_and_lines to std::array_view. Use range-for.
6346 (decode_static_tracepoint_spec): Return a std::vector instead of
6347 symtabs_and_lines. Update.
6348 (create_breakpoint): Update.
6349 (break_range_command, until_break_command, clear_command): Update.
6350 (base_breakpoint_decode_location, bkpt_decode_location)
6351 (bkpt_probe_create_sals_from_location)
6352 (bkpt_probe_decode_location, tracepoint_decode_location)
6353 (tracepoint_probe_decode_location)
6354 (strace_marker_create_sals_from_location): Return a std::vector
6355 instead of symtabs_and_lines.
6356 (strace_marker_create_breakpoints_sal): Update.
6357 (strace_marker_decode_location): Return a std::vector instead of
6358 symtabs_and_lines. Update.
6359 (update_breakpoint_locations): Change struct symtabs_and_lines
6360 parameters to gdb::array_view. Adjust.
6361 (location_to_sals): Return a std::vector instead of
6362 symtabs_and_lines. Update.
6363 (breakpoint_re_set_default): Use std::vector instead of struct
6365 (decode_location_default): Return a std::vector instead of
6366 symtabs_and_lines. Update.
6367 * breakpoint.h: Include "common/array-view.h".
6368 (struct breakpoint_ops) <decode_location>: Now returns a
6369 std::vector instead of returning a symtabs_and_lines via output
6371 (update_breakpoint_locations): Change sals parameters to use
6373 * cli/cli-cmds.c (edit_command, list_command): Update to use
6374 std::vector and gdb::array_view.
6375 (ambiguous_line_spec): Adjust to use gdb::array_view and
6377 (compare_symtabs): Rename to ...
6378 (cmp_symtabs): ... this. Change parameters to symtab_and_line
6379 const reference and adjust.
6380 (filter_sals): Rewrite using std::vector and standard algorithms.
6381 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
6382 (jump_command): Update to use std::vector.
6383 * linespec.c (struct linespec_state) <canonical_names>: Update
6385 (add_sal_to_sals_basic): Delete.
6386 (add_sal_to_sals, filter_results, convert_results_to_lsals)
6387 (decode_line_2, create_sals_line_offset)
6388 (convert_address_location_to_sals, convert_linespec_to_sals)
6389 (convert_explicit_location_to_sals, parse_linespec)
6390 (event_location_to_sals, decode_line_full, decode_line_1)
6391 (decode_line_with_current_source)
6392 (decode_line_with_last_displayed, decode_objc)
6393 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
6394 (linespec_result::~linespec_result): Adjust to use std::vector
6395 instead of symtabs_and_lines.
6396 * linespec.h (linespec_sals::sals): Now a std::vector.
6397 (struct linespec_result): Use std::vector, bool, and in-class
6399 (decode_line_1, decode_line_with_current_source)
6400 (decode_line_with_last_displayed): Return std::vector.
6401 * macrocmd.c (info_macros_command): Use std::vector.
6402 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
6403 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
6405 * probe.h (parse_probes): Return a std::vector.
6406 * python/python.c (gdbpy_decode_line): Use std::vector and
6408 * source.c (select_source_symtab, line_info): Use std::vector.
6409 * stack.c (func_command): Use std::vector.
6410 * symtab.h (struct symtabs_and_lines): Delete.
6411 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
6413 2017-09-04 Pedro Alves <palves@redhat.com>
6415 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6416 unittests/array-view-selftests.c.
6417 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
6418 * common/array-view.h: New file.
6419 * unittests/array-view-selftests.c: New file.
6421 2017-09-04 Pedro Alves <palves@redhat.com>
6423 * cli/cli-cmds.c (edit_command): Pass message to
6424 ambiguous_line_spec.
6425 (list_command): Pass message to ambiguous_line_spec. Say
6426 "first"/"last" instead of "start" and "end" to be consistent with
6428 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
6429 them to print formatted message.
6431 2017-09-04 Pedro Alves <palves@redhat.com>
6433 * btrace.c (ftrace_add_pt): Pass btrace_insn to
6434 ftrace_update_insns by reference instead of pointer.
6436 2017-09-04 Yao Qi <yao.qi@linaro.org>
6438 * i386-go32-tdep.c: Include x86-xstate.h.
6439 (i386_go32_init_abi): Call i386_target_description.
6440 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
6441 if xcr0 is X86_XSTATE_X87_MASK.
6442 * i386-tdep.h (tdesc_i386): Remove the declaration.
6443 (tdesc_i386_mmx): Likewise.
6445 2017-09-04 Yao Qi <yao.qi@linaro.org>
6447 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
6448 X86_XSTATE_SSE_MASK instead of 0.
6450 2017-09-04 Yao Qi <yao.qi@linaro.org>
6452 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
6453 i386_target_description.
6454 * i386-fbsd-nat.c (i386fbsd_read_description): Call
6455 i386_target_description.
6456 * i386-tdep.c (i386_gdbarch_init): Likewise.
6458 2017-09-04 Yao Qi <yao.qi@linaro.org>
6460 * amd64-darwin-tdep.c: Include "x86-xstate.h".
6461 (x86_darwin_init_abi_64): Call amd64_target_description.
6462 * amd64-dicos-tdep.c: Likewise.
6463 * amd64-fbsd-nat.c: Likewise.
6464 * amd64-fbsd-tdep.c: Likewise.
6465 * amd64-nbsd-tdep.c: Likewise.
6466 * amd64-obsd-tdep.c: Likewise.
6467 * amd64-sol2-tdep.c: Likewise.
6468 * amd64-windows-tdep.c: Likewise.
6469 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
6471 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6473 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
6474 (btrace_function) <insn>: Change type to use std::vector.
6475 * btrace.c (ftrace_debug, ftrace_call_num_insn,
6476 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
6477 ftrace_update_insns, ftrace_compute_global_level_offset,
6478 btrace_stitch_bts, btrace_clear, btrace_insn_get,
6479 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
6480 change to std::vector.
6481 (ftrace_update_insns): Adjust to change to std::vector, change
6482 type of INSN parameter.
6483 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
6484 * record-btrace.c (btrace_call_history_insn_range,
6485 btrace_compute_src_line_range,
6486 record_btrace_frame_prev_register): Adjust to change to
6488 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
6489 to change to std::vector.
6491 2017-09-03 Tom Tromey <tom@tromey.com>
6493 * corefile.c (reopen_exec_file): Use std::string.
6495 2017-09-03 Tom Tromey <tom@tromey.com>
6497 * compile/compile.c (compile_register_name_mangled): Return
6499 * compile/compile-loc2c.c (pushf_register_address): Update.
6500 (pushf_register): Update.
6501 * compile/compile-c-types.c (convert_array): Update.
6502 * compile/compile-c-symbols.c (generate_vla_size): Update.
6503 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
6504 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
6505 (convert_one_symbol): Update.
6506 (generate_c_for_for_one_variable): Update.
6507 * compile/compile-c-support.c (c_get_range_decl_name): Return a
6509 (generate_register_struct): Update.
6510 * compile/compile-internal.h (c_get_range_decl_name): Return a
6512 (compile_register_name_mangled): Return std::string.
6514 2017-09-03 Tom Tromey <tom@tromey.com>
6516 * utils.c (perror_string): Return a std::string.
6517 (throw_perror_with_name, perror_warning_with_name): Update.
6519 2017-09-03 Tom Tromey <tom@tromey.com>
6521 * demangle.c (demangle_command): Use std::string,
6524 2017-09-03 Tom Tromey <tom@tromey.com>
6526 * cli/cli-setshow.c (do_set_command): Use std::string.
6528 2017-09-03 Tom Tromey <tom@tromey.com>
6530 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
6532 2017-09-03 Tom Tromey <tom@tromey.com>
6534 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
6536 2017-09-03 Tom Tromey <tom@tromey.com>
6538 * mi/mi-cmd-env.c (env_execute_cli_command): Use
6539 gdb::unique_xmalloc_ptr.
6541 2017-09-03 Tom Tromey <tom@tromey.com>
6543 * thread.c (print_thread_info_1): Use string_printf.
6544 (thread_apply_command, thread_apply_all_command): Use
6547 2017-09-03 Tom Tromey <tom@tromey.com>
6549 * valprint.c (val_print_string): Update.
6550 * gdbcore.h (memory_error_message): Return std::string.
6551 * corefile.c (memory_error_message): Return std::string.
6552 (memory_error): Update.
6553 * breakpoint.c (insert_bp_location): Update.
6555 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6557 * target/waitstatus.h (target_waitstatus_to_string): Change
6558 return type to std::string.
6559 * target/waitstatus.c (target_waitstatus_to_string): Return
6561 * target.h (target_waitstatus_to_string): Remove declaration.
6562 * infrun.c (resume, clear_proceed_status_thread,
6563 print_target_wait_results, do_target_wait, save_waitstatus,
6564 stop_all_threads): Adjust.
6565 * record-btrace.c (record_btrace_wait): Adjust.
6567 (target_debug_print_struct_target_waitstatus_p): Adjust.
6569 2017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
6572 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
6575 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6577 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
6578 for setting/unsetting environment variables on the remote target.
6579 (New remote packets): Add entries for QEnvironmentHexEncoded,
6580 QEnvironmentUnset and QEnvironmentReset.
6581 * common/environ.c (gdb_environ::operator=): Extend method to
6582 handle m_user_set_env_list and m_user_unset_env_list.
6583 (gdb_environ::clear): Likewise.
6584 (match_var_in_string): Change type of first parameter from 'char
6585 *' to 'const char *'.
6586 (gdb_environ::set): Extend method to handle
6587 m_user_set_env_list and m_user_unset_env_list.
6588 (gdb_environ::unset): Likewise.
6589 (gdb_environ::clear_user_set_env): New method.
6590 (gdb_environ::user_set_envp): Likewise.
6591 (gdb_environ::user_unset_envp): Likewise.
6592 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
6593 m_user_unset_env_list on move constructor/assignment.
6594 (unset): Add new default parameter 'update_unset_list = true'.
6595 (clear_user_set_env): New method.
6596 (user_set_envp): Likewise.
6597 (user_unset_envp): Likewise.
6598 (m_user_set_env_list): New std::set.
6599 (m_user_unset_env_list): Likewise.
6600 * common/rsp-low.c (hex2str): New function.
6601 (bin2hex): New overload for bin2hex function.
6602 * common/rsp-low.c (hex2str): New prototype.
6603 (str2hex): New overload prototype.
6604 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
6605 QEnvironmentUnset and QEnvironmentReset.
6606 (remote_protocol_features): Add QEnvironmentHexEncoded,
6607 QEnvironmentUnset and QEnvironmentReset packets.
6608 (send_environment_packet): New function.
6609 (extended_remote_environment_support): Likewise.
6610 (extended_remote_create_inferior): Call
6611 extended_remote_environment_support.
6612 (_initialize_remote): Add QEnvironmentHexEncoded,
6613 QEnvironmentUnset and QEnvironmentReset packet configs.
6614 * unittests/environ-selftests.c (gdb_selftest_env_var):
6616 (test_vector_initialization): New function.
6617 (test_init_from_host_environ): Likewise.
6618 (test_reinit_from_host_environ): Likewise.
6619 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
6621 (test_unset_set_empty_vector): Likewise.
6622 (test_vector_clear): Likewise.
6623 (test_std_move): Likewise.
6624 (test_move_constructor):
6625 (test_self_move): Likewise.
6626 (test_set_unset_reset): Likewise.
6627 (run_tests): Rewrite in terms of the functions above.
6629 2017-08-31 Weimin Pan <weimin.pan@oracle.com>
6631 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
6632 (adi_available): Use a temp variable of type CORE_ADDR as argument
6633 3 when calling target_auxv_search.
6634 (adi_normalize_address): Use masks and xor operators to calculate
6636 (adi_read_versions, adi_write_versions, adi_print_versions)
6637 (do_examine, do_assign): Use paddress.
6639 2017-08-29 John Baldwin <jhb@FreeBSD.org>
6641 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
6642 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
6643 out of loop and add supply of FIR.
6644 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
6647 2017-08-28 Simon Marchi <simon.marchi@ericsson.com>
6650 * cli/cli-script.c (define_command): Don't convert command name
6653 2017-08-25 Joel Brobecker <brobecker@adacore.com>
6655 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
6656 Update all callers accordingly. Remove all code blocks handling
6657 the case where DISPP is not NULL.
6659 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6662 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
6663 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6664 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
6666 2017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6668 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
6669 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
6670 (read_comp_units_from_section): New parameter abbrev_section, use
6671 read_and_check_comp_unit_head, allocate signatured_type if needed.
6672 (create_all_comp_units): Update read_comp_units_from_section caller.
6674 2017-08-23 Pedro Alves <palves@redhat.com>
6677 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
6678 to null_ptid and switch to thread without reading the registers
6679 after adding the inferior.
6681 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6683 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
6685 * compile/compile.c (compile_gcc, show_compile_gcc): New.
6686 (compile_to_object): Implement compile_gcc.
6687 (_initialize_compile): Install "set compile-gcc". Initialize
6690 2017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6692 * compile/compile.c (compile_to_object): Conditionally call
6693 set_verbose. Conditionally call compile or compile_v0.
6695 2017-08-07 Weimin Pan <weimin.pan@oracle.com>
6697 * sparc64-tdep.h: (adi_normalize_address): New export.
6698 * sparc-nat.h: (open_adi_tag_fd): New export.
6699 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
6700 * sparc64-linux-tdep.c:
6701 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
6702 (sparc64_linux_handle_segmentation_fault): New function.
6703 (sparc64_linux_init_abi): Register
6704 sparc64_linux_handle_segmentation_fault
6705 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
6706 (sparc64_addr_bits_remove): New function.
6707 (sparc64_init_abi): Register sparc64_addr_bits_remove.
6708 (MAX_PROC_NAME_SIZE): New macro.
6709 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
6710 (sparc64adilist): New variable.
6711 (adi_proc_list): New variable.
6712 (find_adi_info): New function.
6713 (add_adi_info): New function.
6714 (get_adi_info_proc): New function.
6715 (get_adi_info): New function.
6716 (info_adi_command): New function.
6717 (read_maps_entry): New function.
6718 (adi_available): New function.
6719 (adi_normalize_address): New function.
6720 (adi_align_address): New function.
6721 (adi_convert_byte_count): New function.
6722 (adi_tag_fd): New function.
6723 (adi_is_addr_mapped): New function.
6724 (adi_read_versions): New function.
6725 (adi_write_versions): New function.
6726 (adi_print_versions): New function.
6727 (do_examine): New function.
6728 (do_assign): New function.
6729 (adi_examine_command): New function.
6730 (adi_assign_command): New function.
6731 (_initialize_sparc64_adi_tdep): New function.
6733 2017-08-22 Simon Marchi <simon.marchi@ericsson.com>
6735 * breakpoint.c (breakpoints_info): Rename to ...
6736 (info_breakpoints_command): ... this.
6737 (watchpoints_info): Rename to ...
6738 (info_watchpoints_command): ... this.
6739 (tracepoints_info): Rename to ...
6740 (info_tracepoints_command): ... this.
6741 (_initialize_breakpoint): Adjust.
6742 * dcache.c (dcache_info): Rename to ...
6743 (info_display_command): ... this.
6744 (_initialize_dcache): Adjust.
6745 * frame.h (args_info): Rename to ...
6746 (info_args_command): ... this.
6747 (locals_info): Rename to ...
6748 (info_locals_command): ... this.
6749 * infcmd.c (nofp_registers_info): Rename to ...
6750 (info_registers_command): ... this.
6751 (float_info): Rename to ...
6752 (info_float_command): ... this.
6753 (program_info): Rename to ...
6754 (info_program_command): ... this.
6755 (all_registers_info): Rename to ...
6756 (info_all_registers_command): ... this.
6757 (vector_info): Rename to ...
6758 (info_vector_command): ... this.
6759 (float_info): Rename to ...
6760 (info_float_command): ... this.
6761 (_initialize_infcmd): Adjust.
6762 * inferior.h (term_info): Rename to ...
6763 (info_terminal_command): ... this.
6764 * inflow.c (term_info): Rename to ...
6765 (info_terminal_command): ... this.
6766 (_initialize_inflow): Adjust.
6767 * infrun.c (signals_info): Rename to ...
6768 (info_signals_command): ... this.
6769 (_initialize_infrun): Adjust.
6770 * objc-lang.c (classes_info): Rename to ...
6771 (info_classes_command): ... this.
6772 (selectors_info): Rename to ...
6773 (info_selectors_command): ... this.
6774 (_initialize_objc_language): Adjust.
6775 * printcmd.c (sym_info): Rename to ...
6776 (info_symbol_command): ... this.
6777 (address_info): Rename to ...
6778 (info_address_command): ... this.
6779 (display_info): Rename to ...
6780 (info_display_command): ... this.
6781 (_initialize_printcmd): Adjust.
6782 * reverse.c (bookmarks_info): Rename to ...
6783 (info_breakpoints_command): ... this.
6784 (_initialize_reverse): Adjust.
6785 * ser-go32.c (dos_info): Rename to ...
6786 (info_serial_command): ... this.
6787 (_initialize_ser_dos): Adjust.
6788 * skip.c (skip_info): Rename to ...
6789 (info_skip_command): ... this.
6790 (_initialize_step_skip): Adjust.
6791 * source.c (line_info): Rename to ...
6792 (info_line_command): ... this.
6793 (source_info): Rename to ...
6794 (info_source_command)
6795 * stack.c (frame_info): Rename to ...
6796 (info_frame_command): ... this.
6797 (locals_info): Rename to ...
6798 (info_locals_command): ... this.
6799 (args_info): Rename to ...
6800 (info_args_command): ... this.
6801 (_initialize_stack): Adjust.
6802 * symtab.c (sources_info): Rename to ...
6803 (info_sources_command): ... this.
6804 (variables_info): Rename to ...
6805 (info_variables_command): ... this.
6806 (functions_info): Rename to ...
6807 (info_functions_command): ... this.
6808 (types_info): Rename to ...
6809 (info_types_command): ... this.
6810 (_initialize_symtab): Adjust.
6811 * target.c (target_info): Rename to ...
6812 (info_target_command): ... this.
6813 (initialize_targets): Adjust.
6814 * tracepoint.c (tvariables_info): Rename to ...
6815 (info_tvariables_command): ... this.
6816 (scope_info): Rename to ...
6817 (info_scope_command): ... this.
6818 (trace_dump_actions): Adjust.
6819 (_initialize_tracepoint): Adjust.
6821 2017-08-22 Tom Tromey <tom@tromey.com>
6823 * breakpoint.h (install_breakpoint): Update.
6824 * breakpoint.c (add_solib_catchpoint): Update.
6825 (install_breakpoint): Change argument to a std::unique_ptr.
6826 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
6827 (create_breakpoint_sal, create_breakpoint): Update.
6828 (watch_command_1, catch_exec_command_1)
6829 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
6830 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
6831 Return the breakpoint.
6832 (set_raw_breakpoint_without_location, set_raw_breakpoint)
6833 (new_single_step_breakpoint): Update.
6834 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
6836 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
6838 * break-catch-sig.c (create_signal_catchpoint): Use
6840 * ada-lang.c (create_ada_exception_catchpoint): Use
6843 2017-08-22 Tom Tromey <tom@tromey.com>
6845 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
6847 2017-08-22 Tom Tromey <tom@tromey.com>
6849 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
6850 (lookup_partial_symbol): Update.
6852 2017-08-22 Tom Tromey <tom@tromey.com>
6854 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
6855 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
6856 (find_and_open_source, symtab_to_fullname): Update.
6857 * psymtab.c (psymtab_to_fullname): Update.
6859 2017-08-22 Tom Tromey <tom@tromey.com>
6861 * exec.c (exec_file_attach): Update.
6862 * linux-thread-db.c (try_thread_db_load): Update.
6863 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
6864 * utils.c (gdb_realpath): Change return type.
6865 (gdb_realpath_keepfile): Update.
6866 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
6867 (_initialize_utils): Register the new self test.
6868 * source.c (openp): Update.
6869 (find_and_open_source): Update.
6870 * nto-tdep.c (nto_find_and_open_solib): Update.
6871 * main.c (set_gdb_data_directory): Update.
6872 (captured_main_1): Update.
6873 * dwarf2read.c (dwarf2_get_dwz_file): Update
6874 (dw2_map_symbol_filenames): Update.
6875 * auto-load.c (auto_load_safe_path_vec_update): Update.
6876 (filename_is_in_auto_load_safe_path_vec): Change type of
6878 (auto_load_objfile_script): Update.
6879 (file_is_auto_load_safe): Update. Use std::string.
6880 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
6882 2017-08-22 Tom Tromey <tom@tromey.com>
6884 * utils.c (gdb_realpath_keepfile): Return a
6885 gdb::unique_xmalloc_ptr.
6886 * exec.c (exec_file_attach): Update.
6887 * utils.h (gdb_realpath_keepfile): Return a
6888 gdb::unique_xmalloc_ptr.
6890 2017-08-22 Tom Tromey <tom@tromey.com>
6892 * compile/compile.c (compile_file_command): Use
6893 gdb::unique_xmalloc_ptr, std::string.
6894 * utils.c (gdb_abspath): Change return type.
6895 * source.c (openp): Update.
6896 * objfiles.c (allocate_objfile): Update.
6897 * main.c (set_gdb_data_directory): Update.
6898 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
6900 2017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
6902 * cli-cmds.c (list_commands): List actual code around more than
6905 2017-08-21 John Baldwin <jhb@FreeBSD.org>
6907 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
6909 2017-08-21 Pedro Alves <palves@redhat.com>
6912 * c-exp.y (variable production): Handle function aliases.
6913 * minsyms.c (msymbol_is_text): New function.
6914 * minsyms.h (msymbol_is_text): Declare.
6915 * symtab.c (find_function_alias_target): New function.
6916 * symtab.h (find_function_alias_target): Declare.
6918 2017-08-21 Pedro Alves <palves@redhat.com>
6920 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
6922 * typeprint.c (whatis_exp): If handling "whatis", and expression
6923 is OP_TYPE, strip one typedef level. Otherwise don't strip
6925 * valops.c (value_cast): Save "to" type before resolving
6926 stubs/typedefs. Use that type as resulting value's type.
6928 2017-08-18 Tom Tromey <tom@tromey.com>
6929 Pedro Alves <palves@redhat.com>
6931 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
6932 * sol-thread.c (sol_thread_resume, sol_thread_wait)
6933 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
6934 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
6935 * proc-service.c (ps_xfer_memory): Use scoped_restore.
6936 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
6937 (linux_get_siginfo_data): Add "thread" argument. Use
6939 * linux-nat.c (linux_child_follow_fork)
6940 (check_stopped_by_watchpoint): Use scoped_restore.
6941 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
6942 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
6943 (restore_inferior_ptid, save_inferior_ptid): Remove.
6944 * btrace.c (btrace_fetch): Use scoped_restore.
6945 * bsd-uthread.c (bsd_uthread_fetch_registers)
6946 (bsd_uthread_store_registers): Use scoped_restore.
6947 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
6949 * aix-thread.c (aix_thread_resume, aix_thread_wait)
6950 (aix_thread_xfer_partial): Use scoped_restore.
6951 * inferior.h (save_inferior_ptid): Remove.
6953 2017-08-18 Yao Qi <yao.qi@linaro.org>
6956 * arm-tdep.c (gdb_print_insn_arm): Mark
6957 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
6959 2017-08-18 Yao Qi <yao.qi@linaro.org>
6961 * NEWS: Mention GDBserver's new option "--selftest".
6962 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
6963 * selftest.c: Move it to common/selftest.c.
6964 * selftest.h: Move it to common/selftest.h.
6965 * selftest-arch.c (reset): New function.
6966 (tests_with_arch): Call reset.
6968 2017-08-18 Yao Qi <yao.qi@linaro.org>
6970 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
6971 instead of exception_fprintf and printf_filtered.
6973 2017-08-18 Yao Qi <yao.qi@linaro.org>
6975 * selftest.c (register_self_test): Rename it to
6976 selftests::register_test.
6977 (run_self_tests): selftest::run_tests.
6978 * selftest.h: Update declarations.
6979 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
6980 selftests::register_test_foreach_arch.
6981 * selftest-arch.h: Update declaration.
6982 * aarch64-tdep.c: Update.
6983 * arm-tdep.c: Likewise.
6984 * disasm-selftests.c: Likewise.
6985 * dwarf2loc.c: Likewise.
6986 * dwarf2-frame.c: Likewise.
6987 * findvar.c: Likewise.
6988 * gdbarch-selftests.c: Likewise.
6989 * maint.c (maintenance_selftest): Likewise.
6990 * regcache.c: Likewise.
6991 * rust-exp.y: Likewise.
6992 * selftest-arch.c: Likewise.
6993 * unittests/environ-selftests.c: Likewise.
6994 * unittests/function-view-selftests.c: Likewise.
6995 * unittests/offset-type-selftests.c: Likewise.
6996 * unittests/optional-selftests.c: Likewise.
6997 * unittests/scoped_restore-selftests.c: Likewise.
6998 * utils-selftests.c: Likewise.
7000 2017-08-17 Pedro Alves <palves@redhat.com>
7002 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
7005 2017-08-17 Pedro Alves <palves@redhat.com>
7007 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
7009 (reset_die_in_process): Delete, replaced by ...
7010 (process_die_scope): ... this new class. Make it responsible for
7011 freeing cu->line_header too.
7012 (process_die): Use process_die_scope.
7013 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
7014 cu->line_header_die_owner. Don't release the line header if it's
7016 (setup_type_unit_groups): Make the CU/DIE own the line header.
7017 Don't release the line header here.
7019 2017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
7021 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
7023 2017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
7025 * NEWS: Mention new shortcuts for nexti and stepi in TUI
7028 2017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
7030 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
7033 2017-08-15 Stafford Horne <shorne@gmail.com>
7035 * MAINTAINERS (Write After Approval): Add Stafford Horne.
7037 2017-08-15 Stafford Horne <shorne@gmail.com>
7039 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
7041 2017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
7044 * infcmd.c (unset_environment_command): Use the 'clear' method on
7045 the environment instead of resetting it.
7047 2017-08-15 John Baldwin <jhb@FreeBSD.org>
7049 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
7052 2017-08-14 Tom Tromey <tom@tromey.com>
7054 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
7055 (print_binary_chars): Likewise.
7056 (BITS_IN_BYTES): Remove.
7058 2017-08-14 Tom Tromey <tom@tromey.com>
7061 * valprint.c (LOW_ZERO): Change value to 034.
7062 (print_octal_chars): Add static_asserts for octal constants.
7063 * printcmd.c (print_scalar_formatted): Add 'd' case.
7065 2017-08-11 Tom Tromey <tom@tromey.com>
7067 * symfile.c (add_symbol_file_command): Use std::vector.
7069 2017-08-14 Tom Tromey <tom@tromey.com>
7071 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
7072 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7074 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
7076 2017-08-11 Pedro Alves <palves@redhat.com>
7078 * infrun.c (process_event_stop_test): Adjust
7079 function_name_is_marked_for_skip call.
7080 * skip.c: Include <list>.
7081 (skiplist_entry): Make it a class with private fields, and
7083 (skiplist_entry_chain): Delete.
7084 (skiplist_entries): New.
7085 (skiplist_entry_count): Delete.
7086 (highest_skiplist_entry_num): New.
7087 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
7088 (add_skiplist_entry): Delete.
7089 (skiplist_entry::skiplist_entry): New.
7090 (skiplist_entry::add_entry): New.
7091 (skip_file_command, skip_function): Adjust.
7092 (compile_skip_regexp): Delete.
7093 (skip_command): Don't compile regexp here. Adjust to use
7094 skiplist_entry::add_entry.
7095 (skip_info): Adjust to use range-for and getters.
7096 (skip_enable_command, skip_disable_command): Adjust to use
7097 range-for and setters.
7098 (skip_delete_command): Adjust to use std::list.
7099 (add_skiplist_entry): Delete.
7100 (skip_file_p): Delete, refactored as ...
7101 (skiplist_entry::do_skip_file_p): ... this new method.
7102 (skip_gfile_p): Delete, refactored as ...
7103 (skiplist_entry::do_gskip_file_p): ... this new method.
7104 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
7105 (skiplist_entry::skip_function_p): ... this new method.
7106 (function_name_is_marked_for_skip): Now returns bool, and takes
7107 the function sal by const reference. Adjust to use range-for and
7108 skiplist_entry methods.
7109 (_initialize_step_skip): Remove references to
7110 skiplist_entry_chain, skiplist_entry_count.
7111 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
7112 takes the function sal by const reference.
7114 2017-08-11 Yao Qi <yao.qi@linaro.org>
7116 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
7117 (dwarf2_frame_cache): Remove reset_cache_cleanup.
7118 (dwarf2_frame_cache):
7119 * frame-unwind.c (frame_unwind_try_unwinder): Catch
7120 RETURN_MASK_ALL and set *this_case to NULL.
7121 * frame-unwind.h: Update comments.
7123 2017-08-11 Yao Qi <yao.qi@linaro.org>
7125 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
7126 (dwarf2_frame_state_copy_regs): Remove.
7127 (dwarf2_frame_state_free_regs): Remove.
7128 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
7129 (dwarf2_restore_rule): Call method .alloc_regs instead of
7130 dwarf2_frame_state_alloc_regs.
7131 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
7132 constructor. Call std::move.
7133 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
7134 (dwarf2_frame_cache): Likewise.
7136 [GDB_SELF_TEST]: Include selftest.h and
7138 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
7139 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
7140 execute_cfa_program_test.
7142 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
7143 copy ctor, assignment operator, move assignment.
7144 <alloc_regs>: New method.
7146 (struct dwarf2_frame_state): Delete dtor.
7147 (dwarf2_frame_state_alloc_regs): Remove declaration.
7148 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
7149 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
7151 2017-08-11 Yao Qi <yao.qi@linaro.org>
7153 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
7154 (dwarf2_frame_state::dwarf2_frame_state): New.
7155 (dwarf2_frame_state::~dwarf2_frame_state): New.
7156 (dwarf2_fetch_cfa_info): Update.
7157 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
7158 rather than a pointer. Update code.
7159 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
7161 <data_align, code_align, retaddr_column>: Change them to const.
7162 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
7165 2017-08-11 Yao Qi <yao.qi@linaro.org>
7167 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
7168 <loc.exp>: New field.
7169 * dwarf2-frame.c (execute_cfa_program): Update.
7170 (dwarf2_frame_prev_register): Update.
7172 2017-08-10 Pedro Alves <palves@redhat.com>
7174 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
7176 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7178 * fbsd-nat.c (struct fbsd_fork_info): Remove.
7179 (fbsd_pending_children): Use std::list.
7180 (fbsd_remember_child): Likewise.
7181 (fbsd_is_child_pending): Likewise.
7182 (fbsd_pending_vfork_done): Use std::forward_list.
7183 (fbsd_add_vfork_done): Likewise.
7184 (fbsd_is_vfork_done_pending): Likewise.
7185 (fbsd_next_vfork_done): Likewise.
7187 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7189 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
7190 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
7191 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
7193 (fbsd_xfer_partial): Use gdb::byte_vector.
7194 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
7196 2017-08-09 John Baldwin <jhb@FreeBSD.org>
7198 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
7200 (fbsd_find_memory_regions): Fix `mapfile' initialization.
7202 2017-08-09 Tom Tromey <tom@tromey.com>
7204 * skip.c (skiplist_entry): New constructor.
7205 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
7206 (skiplist_entry::file_is_glob): Now bool.
7207 (skiplist_entry::file, skiplist_entry::function): Now
7209 (make_skip_entry): Return a unique_ptr. Use new.
7210 (free_skiplist_entry, free_skiplist_entry_cleanup)
7211 (make_free_skiplist_entry_cleanup): Remove.
7212 (skip_command, skip_disable_command, add_skiplist_entry)
7213 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
7214 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
7215 (function_name_is_marked_for_skip): Update.
7216 (skip_delete_command): Update. Use delete.
7218 2017-08-09 Jiong Wang <jiong.wang@arm.com>
7220 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
7221 (aarch64_linux_core_read_description): New function.
7222 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
7224 2017-08-09 Pedro Alves <palves@redhat.com>
7226 * cp-name-parser.y (cp_comp_to_string): Return a
7227 gdb::unique_xmalloc_ptr<char>.
7228 * cp-support.c (replace_typedefs_qualified_name)
7229 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
7230 (cp_canonicalize_string_full): Use op= instead of explicit
7232 (cp_class_name_from_physname, method_name_from_physname)
7233 (cp_func_name, cp_remove_params): Adjust to use
7234 gdb::unique_xmalloc_ptr<char>.
7235 * cp-support.h (cp_comp_to_string): Return a
7236 gdb::unique_xmalloc_ptr<char>.
7237 * python/py-type.c (typy_lookup_type): Adjust to use
7238 gdb::unique_xmalloc_ptr<char>.
7240 2017-08-09 H.J. Lu <hongjiu.lu@intel.com>
7242 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
7244 2017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
7245 Yao Qi <yao.qi@linaro.org>
7247 * cp-support.c (cp_canonicalize_string_full): Use
7248 gdb::unique_xmalloc_ptr<char>.
7249 (cp_canonicalize_string): Likewise.
7251 2017-08-09 Yao Qi <yao.qi@linaro.org>
7253 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
7254 * regformats/i386/amd64-avx-avx512.dat: Remove.
7255 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
7256 * regformats/i386/amd64-avx-mpx.dat:Remove.
7257 * regformats/i386/amd64-avx.dat: Remove.
7258 * regformats/i386/amd64-mpx.dat: Remove.
7259 * regformats/i386/i386-avx-avx512.dat: Remove.
7260 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
7261 * regformats/i386/i386-avx-mpx.dat: Remove.
7262 * regformats/i386/i386-mmx.dat: Remove.
7263 * regformats/i386/i386-mpx.dat: Remove.
7265 2017-08-09 Yao Qi <yao.qi@linaro.org>
7267 * amd64-tdep.h (tdesc_x32): Remove the declaration.
7268 * amd64-tdep.c: Don't include features/i386/x32*.c.
7269 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
7271 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
7272 and i386/x32-avx-avx512.
7273 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
7275 * features/i386/x32-avx-avx512.c: Removed.
7276 * features/i386/x32-avx-avx512.xml: Removed.
7277 * features/i386/x32-avx.c: Removed.
7278 * features/i386/x32-avx.xml: Removed.
7279 * features/i386/x32.c: Removed.
7280 * features/i386/x32.xml: Removed.
7281 * regformats/i386/x32-avx-avx512.dat: Removed.
7282 * regformats/i386/x32-avx.dat: Removed.
7283 * regformats/i386/x32.dat: Removed.
7285 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7287 PR breakpoints/21886
7288 * mem-break.c (default_memory_insert_breakpoint): Use
7289 `->placed_address' rather than `->reqstd_address' for the
7290 breakpoint location.
7292 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7294 * arch-utils.c (default_print_insn): Remove arch/mach/endian
7297 2017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7299 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
7300 a union of `tdep_info', `tdesc_data' and `id'.
7301 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
7302 rather than `info.tdep_info'.
7303 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
7304 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
7305 * i386-tdep.c (i386_gdbarch_init): Likewise.
7306 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
7307 * mips-tdep.c (mips_gdbarch_init): Likewise.
7308 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7309 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
7310 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
7312 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
7314 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7315 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
7317 * spu-tdep.c (spu_gdbarch_init): Likewise.
7318 * gdbarch.h: Regenerate.
7320 2017-08-07 Leszek Swirski <leszeks@google.com>
7323 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
7325 2017-08-07 Simon Marchi <simon.marchi@ericsson.com>
7327 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
7328 (gdbsim_open): Rename gdb_argv args object to argv.
7330 2017-08-05 Tom Tromey <tom@tromey.com>
7332 * compile/compile-object-load.c (compile_object_load): Use
7333 gdb::unique_xmalloc_ptr.
7334 * cli/cli-dump.c (scan_filename): Rename from
7335 scan_filename_with_cleanup. Change return type.
7336 (scan_expression): Rename from scan_expression_with_cleanup.
7338 (dump_memory_to_file, dump_value_to_file, restore_command):
7339 Use gdb::unique_xmalloc_ptr. Update.
7340 * cli/cli-cmds.c (find_and_open_script): Use
7341 gdb::unique_xmalloc_ptr.
7342 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
7343 * symmisc.c (maintenance_print_symbols)
7344 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
7345 * symfile.c (symfile_bfd_open, generic_load)
7346 (add_symbol_file_command, remove_symbol_file_command): Use
7347 gdb::unique_xmalloc_ptr.
7348 * source.c (openp): Use gdb::unique_xmalloc_ptr.
7349 * psymtab.c (maintenance_print_psymbols): Use
7350 gdb::unique_xmalloc_ptr.
7351 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
7352 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
7353 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
7354 (reload_shared_libraries_1): Likewise.
7356 2017-08-05 Tom Tromey <tom@tromey.com>
7358 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
7359 (rust_op_vector, rust_set_vector): New typedefs.
7360 (current_parser): New global.
7361 (work_obstack): Change to pointer type. Update all users.
7362 (rust_ast, pstate): Remove globals.
7363 (struct rust_parser): New.
7364 (%union) <params, field_inits>: Change type.
7365 (start, tuple_expr, unit_expr, struct_expr_list, literal)
7366 (field_expr, expr_list, maybe_expr_list, type_list): Update.
7367 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
7368 (convert_params_to_types, convert_params_to_expression): Change
7370 (ast_string): Change type of "fields".
7371 (rust_parse): Make a rust_parser. Remove cleanups.
7372 (rust_lex_tests): Make and install an auto_obstack.
7374 2017-08-04 Yao Qi <yao.qi@linaro.org>
7376 * configure.srv (ipa_x32_linux_regobj): New.
7377 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
7378 instead of X86_TDESC_AVX512.
7379 (initialize_low_tracepoint): Call
7380 init_registers_x32_avx_avx512_linux.
7382 2017-08-04 Yao Qi <yao.qi@linaro.org>
7384 * utils.h (gdb_argv): Add namespace std for nullptr_t.
7386 2017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
7388 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
7390 2017-08-03 Tom Tromey <tom@tromey.com>
7392 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
7394 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
7396 2017-08-03 Tom Tromey <tom@tromey.com>
7398 * python/py-param.c (compute_enum_values): Use gdb_argv.
7400 2017-08-03 Tom Tromey <tom@tromey.com>
7402 * utils.h (struct gdb_argv_deleter): New.
7403 (gdb_argv): New class.
7404 * utils.c (gdb_argv::reset): New method.
7405 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
7406 * tracefile.c (tsave_command): Use gdb_argv.
7407 * top.c (new_ui_command): Use gdb_argv.
7408 * symmisc.c (maintenance_print_symbols)
7409 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
7410 * symfile.c (symbol_file_command, generic_load)
7411 (remove_symbol_file_command): Use gdb_argv.
7412 * stack.c (backtrace_command): Use gdb_argv.
7413 * source.c (add_path, show_substitute_path_command)
7414 (unset_substitute_path_command, set_substitute_path_command):
7416 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
7417 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
7418 * remote.c (extended_remote_run, remote_put_command)
7419 (remote_get_command, remote_delete_command): Use gdb_argv.
7420 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
7421 (gdbsim_open): Use gdb_argv.
7422 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
7423 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
7424 * procfs.c (procfs_info_proc): Use gdb_argv.
7425 * interps.c (interpreter_exec_cmd): Use gdb_argv.
7426 * infrun.c (handle_command): Use gdb_argv.
7427 * inferior.c (add_inferior_command, clone_inferior_command):
7429 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
7430 * exec.c (exec_file_command): Use gdb_argv.
7431 * cli/cli-cmds.c (alias_command): Use gdb_argv.
7432 * compile/compile.c (build_argc_argv): Use gdb_argv.
7434 2017-08-03 Tom Tromey <tom@tromey.com>
7436 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
7438 2017-08-03 Tom Tromey <tom@tromey.com>
7440 * python/python.c (compute_python_string): Return std::string.
7441 (gdbpy_eval_from_control_command): Update.
7442 (do_start_initialization): Use std::string.
7443 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
7445 * python/py-breakpoint.c (local_setattro): Use string_printf, not
7448 2017-08-03 Tom Tromey <tom@tromey.com>
7450 * top.h (do_restore_instream_cleanup): Remove.
7451 * top.c (do_restore_instream_cleanup): Remove.
7452 (read_command_file): Use scoped_restore.
7453 * cli/cli-script.c (execute_user_command): Use scoped_restore.
7455 2017-08-03 Tom Tromey <tom@tromey.com>
7457 * cli/cli-script.c (execute_user_command)
7458 (execute_control_command): Use scoped_restore.
7460 2017-08-03 Tom Tromey <tom@tromey.com>
7462 * cli/cli-script.c (do_restore_user_call_depth): Remove.
7463 (execute_user_command): Remove user_call_depth; use
7464 user_args_stack's size instead.
7466 2017-08-03 Tom Tromey <tom@tromey.com>
7468 * top.h (in_user_command): Remove.
7469 * top.c (in_user_command): Remove.
7470 * cli/cli-script.c (do_restore_user_call_depth)
7471 (execute_user_command): Update.
7473 2017-08-03 Tom Tromey <tom@tromey.com>
7475 * valops.c (search_struct_method): Use gdb::byte_vector.
7476 * valarith.c (value_concat): Use std::vector.
7477 * target.c (memory_xfer_partial): Use gdb::byte_vector.
7478 (simple_search_memory): Likewise.
7479 * printcmd.c (find_string_backward): Use gdb::byte_vector.
7480 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
7481 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
7482 * elfread.c (elf_rel_plt_read): Use std::string.
7483 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
7484 * cli/cli-dump.c (restore_section_callback): Use
7487 2017-08-03 Tom Tromey <tom@tromey.com>
7489 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
7491 2017-08-03 Tom Tromey <tom@tromey.com>
7493 * tui/tui-regs.c (tui_restore_gdbout): Remove.
7494 (tui_register_format): Use scoped_restore.
7496 2017-08-03 Tom Tromey <tom@tromey.com>
7498 * reverse.c (exec_direction_default): Remove.
7499 (exec_reverse_once): Use scoped_restore.
7500 * remote.c (restore_remote_timeout): Remove.
7501 (remote_flash_erase, remote_flash_write, remote_flash_done)
7502 (readchar, remote_serial_write): Use scoped_restore.
7503 * cli/cli-script.c (struct source_cleanup_lines_args)
7504 (source_cleanup_lines): Remove.
7505 (script_from_file): Use scoped_restore.
7506 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
7507 (source_command): Use scoped_restore.
7509 2017-08-03 Tom Tromey <tom@tromey.com>
7511 * utils.h (make_cleanup_free_so): Remove.
7512 * utils.c (do_free_so, make_cleanup_free_so): Remove.
7513 * solist.h (struct so_deleter): New.
7514 (so_list_up): New typedef.
7515 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
7517 2017-08-03 Tom Tromey <tom@tromey.com>
7519 * utils.h (make_cleanup_restore_current_language): Remove.
7520 * utils.c (do_restore_current_language)
7521 (make_cleanup_restore_current_language): Remove.
7522 * parse.c (parse_exp_in_context_1)
7523 (parse_expression_with_language): Use
7524 scoped_restore_current_language.
7525 * mi/mi-main.c (mi_cmd_execute): Use
7526 scoped_restore_current_language.
7527 * language.h (scoped_restore_current_language): New class.
7529 2017-08-03 Tom Tromey <tom@tromey.com>
7531 * compile/compile.c (cleanup_unlink_file): Remove.
7532 (compile_to_object): Use gdb::unlinker.
7533 (eval_compile_command): Likewise.
7535 2017-08-03 Tom Tromey <tom@tromey.com>
7537 * utils.h (make_cleanup_fclose): Remove.
7538 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
7540 2017-08-03 Tom Tromey <tom@tromey.com>
7542 * top.c (open_terminal_stream): Return gdb_file_up.
7543 (new_ui_command): Update.
7545 2017-08-03 Tom Tromey <tom@tromey.com>
7547 * source.c (print_source_lines_base, forward_search_command)
7548 (reverse_search_command): Use gdb_file_up.
7550 2017-08-03 Tom Tromey <tom@tromey.com>
7552 * fbsd-nat.c (fbsd_find_memory_regions): Update.
7554 2017-08-03 Tom Tromey <tom@tromey.com>
7556 * cli/cli-cmds.c (find_and_open_script): Change return type.
7557 Remove "streamp" and "full_path" parameters.
7558 (source_script_with_search): Update.
7559 * auto-load.c (source_script_file): Update.
7560 * cli/cli-cmds.h (find_and_open_script): Change type.
7561 (open_script): New struct.
7563 2017-08-03 Tom Tromey <tom@tromey.com>
7565 * xml-support.c (xml_fetch_content_from_file): Update.
7566 * ui-file.c (stdio_file::open): Update.
7567 * tracefile-tfile.c (tfile_start): Update.
7568 * remote.c (remote_file_put, remote_file_get): Update.
7569 * nat/linux-procfs.c (linux_proc_get_int)
7570 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
7571 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
7572 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
7573 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
7574 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
7575 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
7576 * linux-nat.c (linux_proc_pending_signals): Update.
7577 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
7578 (file_closer): Remove.
7579 * compile/compile.c (compile_to_object): Update.
7580 * common/filestuff.h (struct gdb_file_deleter): New.
7581 (gdb_file_up): New typedef.
7582 (gdb_fopen_cloexec): Change return type.
7583 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
7584 * cli/cli-dump.c (fopen_with_cleanup): Remove.
7585 (dump_binary_file, restore_binary_file): Update.
7586 * auto-load.c (auto_load_objfile_script_1): Update.
7588 2017-08-03 Tom Tromey <tom@tromey.com>
7590 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
7591 (info_static_tracepoint_markers_command): Likewise.
7592 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
7593 * skip.c (skip_info): Use ui_out_emit_table.
7594 * progspace.c (print_program_space): Use ui_out_emit_table.
7595 * osdata.c (info_osdata): Use ui_out_emit_table.
7596 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
7598 * linux-thread-db.c (info_auto_load_libthread_db): Use
7600 * inferior.c (print_inferior): Use ui_out_emit_table.
7601 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
7602 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
7603 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
7604 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
7605 * ui-out.h (class ui_out_emit_table): New.
7607 2017-08-02 Maciej W. Rozycki <macro@imgtec.com>
7609 * mips-tdep.c (mips_fpu_type_str): New function.
7610 (mips_dump_tdep): Call it.
7612 2017-08-01 Maciej W. Rozycki <macro@imgtec.com>
7614 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
7617 2017-07-31 Xavier Roirand <roirand@adacore.com>
7619 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
7621 2017-07-27 Xavier Roirand <roirand@adacore.com>
7623 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
7625 2017-07-26 Yao Qi <yao.qi@linaro.org>
7627 * cli/cli-cmds.c (maintenancechecklist): New variable.
7628 * gdbcmd.h (maintenancechecklist): Declare it.
7629 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
7630 Call i386_linux_read_description with different masks.
7631 * maint.c (maintenance_check_command): New function.
7632 (_initialize_maint_cmds): Call add_prefix_cmd.
7633 * target-descriptions.c (tdesc_reg): override operator != and ==.
7634 (tdesc_type): Likewise.
7635 (tdesc_feature): Likewise.
7636 (target_desc): Likewise.
7637 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
7638 (maintenance_check_xml_descriptions): New function.
7639 (_initialize_target_descriptions) Add command "xml-descriptions".
7640 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
7642 2017-07-26 Yao Qi <yao.qi@linaro.org>
7644 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
7645 Include features/i386/32bit-*.c.
7646 (i386_linux_read_description): Generate target description if it
7648 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
7650 * features/i386/32bit-linux.c: Re-generated.
7651 * features/i386/32bit-sse.c: Likewise.
7652 * target-descriptions.c (print_c_feature::visit): Print code to
7653 set register number if needed.
7654 (print_c_feature) <m_next_regnum>: New field.
7656 2017-07-26 Yao Qi <yao.qi@linaro.org>
7658 * features/Makefile (CFILES): Rename with TDESC_CFILES.
7659 (FEATURE_XMLFILES): New.
7660 (FEATURE_CFILES): New.
7662 (clean-cfiles): Remove generated c files.
7663 * features/i386/32bit-avx.c: Generated.
7664 * features/i386/32bit-avx512.c: Generated.
7665 * features/i386/32bit-core.c: Generated.
7666 * features/i386/32bit-linux.c: Generated.
7667 * features/i386/32bit-mpx.c: Generated.
7668 * features/i386/32bit-pkeys.c: Generated.
7669 * features/i386/32bit-sse.c: Generated.
7670 * target-descriptions.c: Include algorithm.
7671 (tdesc_element_visitor): Add method visit_end.
7672 (print_c_tdesc): Implement visit_end.
7673 (print_c_tdesc:: m_filename_after_features): Move it to
7675 (print_c_feature): New class.
7676 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
7677 name starts with "i386/32bit-".
7679 2017-07-26 Yao Qi <yao.qi@linaro.org>
7681 * target-descriptions.c (tdesc_element_visitor): New class.
7682 (tdesc_element): New class.
7683 (tdesc_reg): Inherit from tdesc_element.
7684 (tdesc_reg::accept): New function.
7685 (tdesc_type): Inherit from tdesc_element.
7686 (tdesc_type::accept): New function.
7687 (tdesc_feature): Inherit from tdesc_element.
7688 (tdesc_feature::accept): New function.
7689 (target_desc): Inherit from tdesc_element.
7690 (target_desc::target_desc): New.
7691 (target_desc::~target_desc): New.
7692 (target_desc::accept): New.
7693 (allocate_target_description): Use new.
7694 (free_target_description): Use delete.
7695 (print_c_tdesc): New class.
7696 (maint_print_c_tdesc_cmd): Adjust.
7698 * features/aarch64.c: Re-generated.
7699 * features/arc-arcompact.c: Re-generated.
7700 * features/arc-v2.c: Re-generated.
7701 * features/arm/arm-with-iwmmxt.c: Re-generated.
7702 * features/arm/arm-with-m.c: Re-generated.
7703 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
7704 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
7705 * features/arm/arm-with-neon.c: Re-generated.
7706 * features/arm/arm-with-vfpv2.c: Re-generated.
7707 * features/arm/arm-with-vfpv3.c: Re-generated.
7708 * features/i386/amd64-avx-avx512.c: Re-generated.
7709 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7710 * features/i386/amd64-avx.c: Re-generated.
7711 * features/i386/amd64-avx-linux.c: Re-generated.
7712 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
7713 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7714 * features/i386/amd64-avx-mpx.c: Re-generated.
7715 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
7716 * features/i386/amd64.c: Re-generated.
7717 * features/i386/amd64-linux.c: Re-generated.
7718 * features/i386/amd64-mpx.c: Re-generated.
7719 * features/i386/amd64-mpx-linux.c: Re-generated.
7720 * features/i386/i386-avx-avx512.c: Re-generated.
7721 * features/i386/i386-avx-avx512-linux.c: Re-generated.
7722 * features/i386/i386-avx.c: Re-generated.
7723 * features/i386/i386-avx-linux.c: Re-generated.
7724 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
7725 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
7726 * features/i386/i386-avx-mpx.c: Re-generated.
7727 * features/i386/i386-avx-mpx-linux.c: Re-generated.
7728 * features/i386/i386.c: Re-generated.
7729 * features/i386/i386-linux.c: Re-generated.
7730 * features/i386/i386-mmx.c: Re-generated.
7731 * features/i386/i386-mmx-linux.c: Re-generated.
7732 * features/i386/i386-mpx.c: Re-generated.
7733 * features/i386/i386-mpx-linux.c: Re-generated.
7734 * features/i386/x32-avx-avx512.c: Re-generated.
7735 * features/i386/x32-avx-avx512-linux.c: Re-generated.
7736 * features/i386/x32-avx.c: Re-generated.
7737 * features/i386/x32-avx-linux.c: Re-generated.
7738 * features/i386/x32.c: Re-generated.
7739 * features/i386/x32-linux.c: Re-generated.
7740 * features/microblaze.c: Re-generated.
7741 * features/microblaze-with-stack-protect.c: Re-generated.
7742 * features/mips64-dsp-linux.c: Re-generated.
7743 * features/mips64-linux.c: Re-generated.
7744 * features/mips-dsp-linux.c: Re-generated.
7745 * features/mips-linux.c: Re-generated.
7746 * features/nds32.c: Re-generated.
7747 * features/nios2.c: Re-generated.
7748 * features/nios2-linux.c: Re-generated.
7749 * features/rs6000/powerpc-32.c: Re-generated.
7750 * features/rs6000/powerpc-32l.c: Re-generated.
7751 * features/rs6000/powerpc-403.c: Re-generated.
7752 * features/rs6000/powerpc-403gc.c : Re-generated.
7753 * features/rs6000/powerpc-405.c: Re-generated.
7754 * features/rs6000/powerpc-505.c: Re-generated.
7755 * features/rs6000/powerpc-601.c: Re-generated.
7756 * features/rs6000/powerpc-602.c: Re-generated.
7757 * features/rs6000/powerpc-603.c: Re-generated.
7758 * features/rs6000/powerpc-604.c: Re-generated.
7759 * features/rs6000/powerpc-64.c: Re-generated.
7760 * features/rs6000/powerpc-64l.c: Re-generated.
7761 * features/rs6000/powerpc-7400.c: Re-generated.
7762 * features/rs6000/powerpc-750.c: Re-generated.
7763 * features/rs6000/powerpc-860.c: Re-generated.
7764 * features/rs6000/powerpc-altivec32.c: Re-generated.
7765 * features/rs6000/powerpc-altivec32l.c: Re-generated.
7766 * features/rs6000/powerpc-altivec64.c: Re-generated.
7767 * features/rs6000/powerpc-altivec64l.c: Re-generated.
7768 * features/rs6000/powerpc-cell32l.c: Re-generated.
7769 * features/rs6000/powerpc-cell64l.c: Re-generated.
7770 * features/rs6000/powerpc-e500.c: Re-generated.
7771 * features/rs6000/powerpc-e500l.c: Re-generated.
7772 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
7773 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
7774 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
7775 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
7776 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
7777 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
7778 * features/rs6000/powerpc-vsx32.c: Re-generated.
7779 * features/rs6000/powerpc-vsx32l.c: Re-generated.
7780 * features/rs6000/powerpc-vsx64.c: Re-generated.
7781 * features/rs6000/powerpc-vsx64l.c: Re-generated.
7782 * features/rs6000/rs6000.c: Re-generated.
7783 * features/s390-linux32.c: Re-generated.
7784 * features/s390-linux32v1.c: Re-generated.
7785 * features/s390-linux32v2.c: Re-generated.
7786 * features/s390-linux64.c: Re-generated.
7787 * features/s390-linux64v1.c: Re-generated.
7788 * features/s390-linux64v2.c: Re-generated.
7789 * features/s390-te-linux64.c: Re-generated.
7790 * features/s390-tevx-linux64.c: Re-generated.
7791 * features/s390-vx-linux64.c: Re-generated.
7792 * features/s390x-linux64.c: Re-generated.
7793 * features/s390x-linux64v1.c: Re-generated.
7794 * features/s390x-linux64v2.c: Re-generated.
7795 * features/s390x-te-linux64.c: Re-generated.
7796 * features/s390x-tevx-linux64.c: Re-generated.
7797 * features/s390x-vx-linux64.c: Re-generated.
7798 * features/sparc/sparc32-solaris.c: Re-generated.
7799 * features/sparc/sparc64-solaris.c: Re-generated.
7800 * features/tic6x-c62x.c: Re-generated.
7801 * features/tic6x-c62x-linux.c: Re-generated.
7802 * features/tic6x-c64x.c: Re-generated.
7803 * features/tic6x-c64x-linux.c: Re-generated.
7804 * features/tic6x-c64xp.c: Re-generated.
7805 * features/tic6x-c64xp-linux.c: Re-generated.
7807 2017-07-26 Yao Qi <yao.qi@linaro.org>
7809 * i386-linux-tdep.c (i386_linux_read_description): New function.
7810 (i386_linux_core_read_description): Call
7811 i386_linux_read_description.
7812 * i386-linux-tdep.h (i386_linux_read_description): Declare.
7813 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
7814 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
7815 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
7816 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
7817 * x86-linux-nat.c (x86_linux_read_description): Call
7818 i386_linux_read_description.
7820 2017-07-26 Yao Qi <yao.qi@linaro.org>
7823 * features/Makefile (%.c: %.xml): Pass the xml file name to
7824 command "maint print c-tdesc".
7825 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
7828 2017-07-26 Yao Qi <yao.qi@linaro.org>
7830 * target-descriptions.c (target_desc): Add ctor and dtor. Do
7831 in-class initialization.
7832 (tdesc_create_feature): Call new instead of XCNEW.
7833 (free_target_description): Ue delete.
7835 2017-07-25 John Baldwin <jhb@FreeBSD.org>
7837 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
7839 2017-07-25 Yao Qi <yao.qi@linaro.org>
7841 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
7843 (amd64_x32_init_abi): Likewise.
7844 * amd64-tdep.h (amd64_init_abi): Update declaration.
7845 (amd64_x32_init_abi): Likewise.
7847 2017-07-25 Yao Qi <yao.qi@linaro.org>
7850 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
7851 condition for FPSCR.
7852 (arm_linux_store_inferior_registers): Likewise.
7854 2017-07-22 Tom Tromey <tom@tromey.com>
7856 * break-catch-syscall.c (struct catch_syscall_inferior_data)
7857 <syscalls_counts>: Now a std::vector.
7858 (get_catch_syscall_inferior_data): Use "new".
7859 (catch_syscall_inferior_data_cleanup): Use "delete".
7860 (insert_catch_syscall, remove_catch_syscall)
7861 (clear_syscall_counts): Update.
7863 2017-07-22 Tom Tromey <tom@tromey.com>
7865 * break-catch-syscall.c (syscall_catchpoint)
7866 <syscalls_to_be_caught>: Now a std::vector<int>
7867 (~syscall_catchpoint): Remove.
7868 (insert_catch_syscall, remove_catch_syscall)
7869 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
7870 (print_mention_catch_syscall, print_recreate_catch_syscall):
7872 (create_syscall_event_catchpoint): Change type of "filter"
7874 (catch_syscall_split_args): Return a std::vector.
7875 (catch_syscall_command_1, catching_syscall_number_1): Update.
7877 2017-07-22 Tom Tromey <tom@tromey.com>
7879 * break-catch-throw.c (struct exception_catchpoint)
7880 <exception_rx>: Now a std::string.
7881 (~exception_catchpoint): Remove.
7882 (print_one_detail_exception_catchpoint): Update.
7883 (handle_gnu_v3_exceptions): Change type of except_rx.
7884 (extract_exception_regexp): Return a std::string.
7885 (catch_exception_command_1): Update.
7887 2017-07-22 Tom Tromey <tom@tromey.com>
7889 * break-catch-sig.c (gdb_signal_type): Remove typedef.
7890 (struct signal_catchpoint) <signals_to_be_caught>: Now a
7892 <catch_all>: Now a bool.
7893 (~signal_catchpoint): Remove.
7894 (signal_catchpoint_insert_location)
7895 (signal_catchpoint_remove_location)
7896 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
7897 (signal_catchpoint_print_mention)
7898 (signal_catchpoint_print_recreate)
7899 (signal_catchpoint_explains_signal): Update.
7900 (create_signal_catchpoint): Change type of "filter" and
7902 (catch_signal_split_args): Return a std::vector. Change type of
7904 (catch_signal_command): Update.
7906 2017-07-20 Pedro Alves <palves@redhat.com>
7908 * ada-lang.c (ada_language_defn): Make extern.
7909 (_initialize_ada_language): Remove add_language call.
7910 * c-lang.c (c_language_defn, cplus_language_defn)
7911 (asm_language_defn, minimal_language_defn): Make extern.
7912 (_initialize_c_language): Delete.
7913 * completer.c (compare_cstrings): Delete, moved to utils.h.
7914 * d-lang.c (d_language_defn): Make extern.
7915 (_initialize_d_language): Remove add_language calls.
7916 * defs.h (enum language): Add comment.
7917 * f-lang.c (f_language_defn): Make extern.
7918 (_initialize_f_language): Remove add_language call.
7919 * go-lang.c (go_language_defn): Make extern.
7920 (_initialize_go_language): Remove add_language call.
7921 * language.c: Include <algorithm>.
7922 (languages): Redefine as const array.
7923 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
7924 (set_language_command): Handle "local". Use for-range loop.
7925 (set_language): Remove loop.
7926 (language_enum): Rewrite.
7927 (language_def, language_str): Remove loops.
7928 (add_language): Delete.
7929 (add_set_language_command): New, based on add_languages.
7930 (skip_language_trampoline): Adjust.
7931 (local_language_defn): Delete.
7932 (language_gdbarch_post_init): Adjust.
7933 (_initialize_language): Remove add_language calls. Call
7934 add_set_language_command.
7935 * language.h (add_language): Delete.
7936 (auto_language_defn)
7937 (unknown_language_defn, minimal_language_defn, ada_language_defn)
7938 (asm_language_defn, c_language_defn, cplus_language_defn)
7939 (d_language_defn, f_language_defn, go_language_defn)
7940 (m2_language_defn, objc_language_defn, opencl_language_defn)
7941 (pascal_language_defn, rust_language_defn): Declare.
7942 * m2-lang.c (m2_language_defn): Make extern.
7943 (_initialize_m2_language): Remove add_language call.
7944 * objc-lang.c (objc_language_defn): Make extern.
7945 (_initialize_objc_language): Remove add_language call.
7946 * opencl-lang.c (opencl_language_defn): Make extern.
7947 (_initialize_opencl_language): Remove add_language call.
7948 * p-lang.c (pascal_language_defn): Make extern.
7949 (_initialize_pascal_language): Delete.
7950 * rust-lang.c (rust_language_defn): Make extern.
7951 (_initialize_rust_language): Delete.
7952 * utils.h (compare_cstrings): New static inline function.
7954 2017-07-20 Pedro Alves <palves@redhat.com>
7956 * ada-lang.c (ada_to_fixed_type_1): Adjust.
7957 (get_var_value): Constify parameters.
7958 (get_int_var_value): Change prototype.
7959 (to_fixed_range_type): Adjust.
7960 * ada-lang.h (get_int_var_value): Change prototype.
7962 2017-07-20 Pedro Alves <palves@redhat.com>
7964 * dwarf2read.c (dw2_lookup_symbol): Use
7965 SYMBOL_MATCHES_SEARCH_NAME.
7966 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
7968 2017-07-20 Pedro Alves <palves@redhat.com>
7970 * block.c (block_iter_name_step, block_iter_name_first)
7971 (block_iter_name_next): Delete.
7972 (block_lookup_symbol_primary): Adjust to use
7973 dict_iter_match_first/dict_iter_match_next.
7974 * block.h (block_iter_name_first, block_iter_name_next): Delete
7976 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
7977 dict_iter_match_first/dict_iter_match_next.
7979 2017-07-20 Pedro Alves <palves@redhat.com>
7981 * cp-support.c (cp_find_first_component_aux): Add missing case for
7984 2017-07-18 David Blaikie <dblaikie@gmail.com>
7986 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
7987 of dwo_cu's dwo_file.
7989 2017-07-18 Yao Qi <yao.qi@linaro.org>
7991 * remote.c (store_registers_using_G): Remove one line comment.
7993 2017-07-18 Yao Qi <yao.qi@linaro.org>
7995 * regcache.c (regcache_cpy): Simplify it.
7996 (regcache::cpy_no_passthrough): Remove it.
7997 * regcache.h (cpy_no_passthrough): Remove it.
7998 (regcache_dup, regcache_cpy): Update comments.
8000 2017-07-18 Pedro Alves <palves@redhat.com>
8002 * remote-sim.c (sim_command_completer): Adjust to work with a
8003 completion_tracker instead of a VEC.
8005 2017-07-17 Pedro Alves <palves@redhat.com>
8007 * completer.c (complete_source_filenames): New function.
8008 (complete_address_and_linespec_locations): New function.
8009 (location_completer): Use complete_address_and_linespec_locations.
8010 (completion_tracker::build_completion_result): Honor the tracker's
8011 request to suppress append.
8012 * completer.h (completion_tracker::suppress_append_ws)
8013 (completion_tracker::set_suppress_append_ws): New methods.
8014 (completion_tracker::m_suppress_append_ws): New field.
8015 (complete_source_filenames): New declaration.
8016 * linespec.c (linespec_complete_what): New.
8017 (struct ls_parser) <complete_what, completion_word,
8018 completion_quote_char, completion_quote_end, completion_tracker>:
8020 (string_find_incomplete_keyword_at_end): New.
8021 (linespec_lexer_lex_string): Record quote char. If in completion
8023 (linespec_lexer_consume_token): Advance the completion word point.
8024 (linespec_lexer_peek_token): Save/restore completion info.
8025 (save_stream_and_consume_token): New.
8026 (set_completion_after_number): New.
8027 (linespec_parse_basic): Set what to complete next depending on
8028 token. Handle function and label completions specially.
8029 (parse_linespec): Disable objc shortcut in completion mode. Set
8030 what to complete next depending on token type. Skip keyword if in
8032 (complete_linespec_component, linespec_complete): New.
8033 * linespec.h (linespec_complete): Declare.
8035 2017-07-17 Pedro Alves <palves@redhat.com>
8037 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
8038 Handle 'operator<' / 'operator<<'.
8040 2017-07-17 Pedro Alves <palves@redhat.com>
8042 * completer.c (collect_explicit_location_matches): Handle
8044 (convert_explicit_location_to_linespec): New, factored out from
8046 (convert_explicit_location_to_sals): ... this.
8047 (complete_label): New.
8048 (linespec_complete_label, find_label_symbols_in_block): New.
8049 (find_label_symbols): Add completion_mode parameter and adjust to
8050 call find_label_symbols_in_block.
8051 * linespec.h (linespec_complete_label): Declare.
8053 2017-07-17 Pedro Alves <palves@redhat.com>
8055 * ada-lang.c (ada_collect_symbol_completion_matches): Add
8056 complete_symbol_mode parameter.
8057 * cli/cli-cmds.c (complete_command): Get the completion result out
8058 of the handle_brkchars tracker if used a custom word point.
8059 * completer.c: Include "linespec.h".
8060 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
8061 (advance_to_expression_complete_word_point): New.
8062 (completion_tracker::completes_to_completion_word): New.
8063 (complete_files_symbols): Pass down
8064 complete_symbol_mode::EXPRESSION.
8065 (explicit_options, probe_options): New.
8066 (collect_explicit_location_matches): Complete on the
8067 explictit_loc->foo instead of word. Use
8068 linespec_complete_function. Handle MATCH_LINE. Handle offering
8069 keyword and options completions.
8070 (backup_text_ptr): Delete.
8071 (skip_keyword): New.
8072 (complete_explicit_location): Remove 'word' parameter. Add
8073 language, quoted_arg_start and quoted_arg_end parameters.
8074 Rewrite, parsing left to right.
8075 (location_completer): Rewrite.
8076 (location_completer_handle_brkchars): New function.
8077 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
8078 (enum complete_line_internal_reason): Adjust comments.
8079 (completion_tracker::discard_completions): New.
8080 (completer_handle_brkchars_func_for_completer): Handle
8082 (gdb_custom_word_point_brkchars)
8083 (gdb_org_rl_basic_quote_characters): New.
8084 (gdb_completion_word_break_characters_throw)
8085 (completion_find_completion_word): Handle trackers that use a
8087 (completion_tracker::advance_custom_word_point_by): New.
8088 (completion_tracker::build_completion_result): Don't rely on
8089 readline appending the quote char.
8090 (gdb_rl_attempted_completion_function_throw): Handle trackers that
8091 use a custom word point.
8092 (gdb_rl_attempted_completion_function): Restore
8093 rl_basic_quote_characters.
8094 * completer.h (class completion_tracker): Extend intro comment.
8095 (completion_tracker::set_quote_char)
8096 (completion_tracker::quote_char)
8097 (completion_tracker::set_use_custom_word_point)
8098 (completion_tracker::use_custom_word_point)
8099 (completion_tracker::custom_word_point)
8100 (completion_tracker::set_custom_word_point)
8101 (completion_tracker::advance_custom_word_point_by)
8102 (completion_tracker::completes_to_completion_word)
8103 (completion_tracker::discard_completions): New methods.
8104 (completion_tracker::m_quote_char)
8105 (completion_tracker::m_use_custom_word_point)
8106 (completion_tracker::m_custom_word_point): New fields.
8107 (advance_to_expression_complete_word_point): Declare.
8108 * f-lang.c (f_collect_symbol_completion_matches): Add
8109 complete_symbol_mode parameter.
8110 * language.h (struct language_defn)
8111 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
8113 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
8114 (linespec_complete_function): New function.
8115 (linespec_lexer_lex_keyword): Adjust.
8116 * linespec.h (linespec_keywords, linespec_complete_function): New
8118 * location.c (find_end_quote): New function.
8119 (explicit_location_lex_one): Add explicit_completion_info
8120 parameter. Save quoting info. Don't throw if being called for
8121 completion. Don't handle Ada operators here.
8122 (is_cp_operator, skip_op_false_positives, first_of)
8123 (explicit_location_lex_one_function): New function.
8124 (string_to_explicit_location): Replace 'dont_throw' parameter with
8125 an explicit_completion_info pointer parameter. Handle it. Don't
8126 use explicit_location_lex_one to lex function names. Use
8127 explicit_location_lex_one_function instead.
8128 * location.h (struct explicit_completion_info): New.
8129 (string_to_explicit_location): Replace 'dont_throw' parameter with
8130 an explicit_completion_info pointer parameter.
8131 * symtab.c (default_collect_symbol_completion_matches_break_on):
8132 Add complete_symbol_mode parameter. Handle LINESPEC mode.
8133 (default_collect_symbol_completion_matches)
8134 (collect_symbol_completion_matches): Add complete_symbol_mode
8136 (collect_symbol_completion_matches_type): Pass down
8137 complete_symbol_mode::EXPRESSION.
8138 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8139 parameter. Handle LINESPEC mode.
8140 * symtab.h (complete_symbol_mode): New.
8141 (default_collect_symbol_completion_matches_break_on)
8142 (default_collect_symbol_completion_matches)
8143 (collect_symbol_completion_matches)
8144 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8147 2017-07-17 Pedro Alves <palves@redhat.com>
8149 * utils.c (enum class strncmp_iw_mode): New.
8150 (strcmp_iw): Rename to ...
8151 (strncmp_iw_with_mode): ... this. Add string2_len and mode
8152 parameters. Handle them.
8154 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
8155 * utils.h (strncmp_iw): Declare.
8156 (strcmp_iw): Move describing comments here.
8158 2017-07-17 Pedro Alves <palves@redhat.com>
8160 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
8162 * c-typeprint.c (is_type_conversion_operator): Use
8164 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
8165 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
8167 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
8168 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
8169 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
8170 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
8172 * location.c: Include "cp-support.h".
8173 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
8175 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
8178 2017-07-17 Pedro Alves <palves@redhat.com>
8180 * cli/cli-cmds.c (complete_command): Use a completion tracker
8181 along with completion_find_completion_word for handle_brkchars
8183 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
8184 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
8185 (struct gdb_rl_completion_word_info): New.
8186 (gdb_rl_find_completion_word): New.
8187 (completion_find_completion_word): New.
8188 * completer.h (completion_find_completion_word): Declare.
8190 2017-07-17 Pedro Alves <palves@redhat.com>
8192 * ada-lang.c (symbol_completion_match): Adjust comments.
8193 (symbol_completion_add): Replace vector parameter with
8194 completion_tracker parameter. Use it.
8195 (ada_make_symbol_completion_list): Rename to...
8196 (ada_collect_symbol_completion_matches): ... this. Add
8197 completion_tracker parameter and use it.
8198 (ada_language_defn): Adjust.
8199 * break-catch-syscall.c (catch_syscall_completer): Adjust
8200 prototype and work with completion_tracker instead of VEC.
8201 * breakpoint.c (condition_completer): Adjust prototype and work
8202 with completion_tracker instead of VEC.
8203 * c-lang.c (c_language_defn, cplus_language_defn)
8204 (asm_language_defn, minimal_language_defn): Adjust to renames.
8205 * cli/cli-cmds.c (complete_command): Rework using
8206 completion_tracker. Catch exceptions when completing.
8207 * cli/cli-decode.c (integer_unlimited_completer)
8208 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
8209 with completion_tracker instead of VEC.
8210 * command.h (struct completion_tracker): Forward declare.
8211 (completer_ftype, completer_handle_brkchars_ftype): Change
8213 (complete_on_cmdlist, complete_on_enum): Adjust.
8214 * completer.c: Include <algorithm>.
8215 (struct gdb_completer_state): New.
8216 (current_completion): New global.
8217 (readline_line_completion_function): Delete.
8218 (noop_completer, filename_completer)
8219 (filename_completer_handle_brkchars, complete_files_symbols)
8220 (linespec_location_completer): Adjust to work with a
8221 completion_tracker instead of a VEC.
8222 (string_or_empty): New.
8223 (collect_explicit_location_matches): Adjust to work with a
8224 completion_tracker instead of a VEC.
8225 (explicit_location_completer): Rename to ...
8226 (complete_explicit_location): ... this and adjust to work with a
8227 completion_tracker instead of a VEC.
8228 (location_completer): Adjust to work with a completion_tracker
8230 (add_struct_fields): Adjust to work with a completion_list instead
8232 (expression_completer): Rename to ...
8233 (complete_expression): ... this and adjust to work with a
8234 completion_tracker instead of a VEC. Use complete_files_symbols.
8235 (expression_completer): Reimplement on top of complete_expression.
8236 (symbol_completer): Adjust to work with a completion_tracker
8238 (enum complete_line_internal_reason): Add describing comments.
8239 (complete_line_internal_normal_command): Adjust to work with a
8240 completion_tracker instead of a VEC.
8241 (complete_line_internal): Rename to ...
8242 (complete_line_internal_1): ... this and adjust to work with a
8243 completion_tracker instead of a VEC. Assert TEXT is NULL in the
8244 handle_brkchars phase.
8245 (new_completion_tracker): Delete.
8246 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
8247 complete_line_internal_1.
8248 (free_completion_tracker): Delete.
8249 (INITIAL_COMPLETION_HTAB_SIZE): New.
8250 (completion_tracker::completion_tracker)
8251 (completion_tracker::~completion_tracker): New.
8252 (maybe_add_completion): Delete.
8253 (completion_tracker::maybe_add_completion)
8254 (completion_tracker::add_completion)
8255 (completion_tracker::add_completions): New.
8256 (throw_max_completions_reached_error): Delete.
8257 (complete_line): Adjust to work with a completion_tracker instead
8258 of a VEC. Don't create a completion_tracker_t or check for max
8260 (command_completer, command_completer_handle_brkchars)
8261 (signal_completer, reg_or_group_completer_1)
8262 (reg_or_group_completer, default_completer_handle_brkchars):
8263 Adjust to work with a completion_tracker.
8264 (gdb_completion_word_break_characters_throw): New.
8265 (gdb_completion_word_break_characters): Reimplement.
8266 (line_completion_function): Delete.
8267 (completion_tracker::recompute_lowest_common_denominator)
8268 (expand_preserving_ws)
8269 (completion_tracker::build_completion_result)
8270 (completion_result::completion_result)
8271 (completion_result::completion_result)
8272 (completion_result::~completion_result)
8273 (completion_result::completion_result)
8274 (completion_result::release_match_list, compare_cstrings)
8275 (completion_result::sort_match_list)
8276 (completion_result::reset_match_list)
8277 (gdb_rl_attempted_completion_function_throw)
8278 (gdb_rl_attempted_completion_function): New.
8279 * completer.h (completion_list, struct completion_result)
8280 (class completion_tracker): New.
8281 (complete_line): Add completion_tracker parameter.
8282 (readline_line_completion_function): Delete.
8283 (gdb_rl_attempted_completion_function): New.
8284 (noop_completer, filename_completer, expression_completer)
8285 (location_completer, symbol_completer, command_completer)
8286 (signal_completer, reg_or_group_completer): Update prototypes.
8287 (completion_tracker_t, new_completion_tracker)
8288 (make_cleanup_free_completion_tracker): Delete.
8289 (enum maybe_add_completion_enum): Delete.
8290 (maybe_add_completion): Delete.
8291 (throw_max_completions_reached_error): Delete.
8292 * corefile.c (complete_set_gnutarget): Adjust to work with a
8293 completion_tracker instead of a VEC.
8294 * cp-abi.c (cp_abi_completer): Adjust to work with a
8295 completion_tracker instead of a VEC.
8296 * d-lang.c (d_language_defn): Adjust.
8297 * disasm.c (disassembler_options_completer): Adjust to work with a
8298 completion_tracker instead of a VEC.
8299 * f-lang.c (f_make_symbol_completion_list): Rename to ...
8300 (f_collect_symbol_completion_matches): ... this. Adjust to work
8301 with a completion_tracker instead of a VEC.
8302 (f_language_defn): Adjust.
8303 * go-lang.c (go_language_defn): Adjust.
8304 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
8305 Adjust to work with a completion_tracker instead of a VEC.
8306 * infrun.c (handle_completer): Likewise.
8307 * interps.c (interpreter_completer): Likewise.
8308 * interps.h (interpreter_completer): Likewise.
8309 * language.c (unknown_language_defn, auto_language_defn)
8310 (local_language_defn): Adjust.
8311 * language.h (language_defn::la_make_symbol_completion_list):
8313 (language_defn::la_collect_symbol_completion_matches): ... this
8314 and adjust to work with a completion_tracker instead of a VEC.
8315 * m2-lang.c (m2_language_defn): Adjust.
8316 * objc-lang.c (objc_language_defn): Adjust.
8317 * opencl-lang.c (opencl_language_defn): Adjust.
8318 * p-lang.c (pascal_language_defn): Adjust.
8319 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
8320 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
8321 with a completion_tracker.
8322 * rust-lang.c (rust_language_defn): Adjust.
8323 * symtab.c (free_completion_list, do_free_completion_list)
8324 (return_val, completion_tracker): Delete.
8325 (completion_list_add_name, completion_list_add_symbol)
8326 (completion_list_add_msymbol, completion_list_objc_symbol)
8327 (completion_list_add_fields, add_symtab_completions): Add
8328 completion_tracker parameter and use it.
8329 (default_make_symbol_completion_list_break_on_1): Rename to...
8330 (default_collect_symbol_completion_matches_break_on): ... this.
8331 Add completion_tracker parameter and use it instead of allocating
8332 a completion tracker here.
8333 (default_make_symbol_completion_list_break_on): Delete old
8335 (default_make_symbol_completion_list): Delete.
8336 (default_collect_symbol_completion_matches): New.
8337 (make_symbol_completion_list): Delete.
8338 (collect_symbol_completion_matches): New.
8339 (make_symbol_completion_type): Rename to ...
8340 (collect_symbol_completion_matches_type): ... this. Add
8341 completion_tracker parameter and use it instead of VEC.
8342 (make_file_symbol_completion_list_1): Rename to...
8343 (collect_file_symbol_completion_matches): ... this. Add
8344 completion_tracker parameter and use it instead of VEC.
8345 (make_file_symbol_completion_list): Delete.
8346 (add_filename_to_list): Use completion_list instead of a VEC.
8347 (add_partial_filename_data::list): Now a completion_list.
8348 (make_source_files_completion_list): Work with a completion_list
8350 * symtab.h: Include "completer.h".
8351 (default_make_symbol_completion_list_break_on)
8352 (default_make_symbol_completion_list, make_symbol_completion_list)
8353 (make_symbol_completion_type, make_file_symbol_completion_list)
8354 (make_source_files_completion_list): Delete.
8355 (default_collect_symbol_completion_matches_break_on)
8356 (default_collect_symbol_completion_matches)
8357 (collect_symbol_completion_matches)
8358 (collect_symbol_completion_matches_type)
8359 (collect_file_symbol_completion_matches)
8360 (make_source_files_completion_list): New.
8361 * top.c (init_main): Don't install a rl_completion_entry_function
8362 hook. Install a rl_attempted_completion_function hook instead.
8363 * tui/tui-layout.c (layout_completer): Adjust to work with a
8365 * tui/tui-regs.c (tui_reggroup_completer):
8366 * tui/tui-win.c (window_name_completer, focus_completer)
8367 (winheight_completer): Adjust to work with a completion_tracker.
8368 * value.c: Include "completer.h".
8369 (complete_internalvar): Adjust to work with a completion_tracker.
8370 * value.h (complete_internalvar): Likewise.
8372 2017-07-17 Pedro Alves <palves@redhat.com>
8374 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
8376 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
8377 comments to completer_ftype's declaration.
8378 <completer_handle_brkchars>: Change type to
8379 completer_handle_brkchars_ftype.
8380 * command.h (completer_ftype): Add describing comment and give
8381 names to parameters.
8382 (completer_ftype_void): Rename to ...
8383 (completer_handle_brkchars_ftype) ... this. Add describing comment.
8384 (set_cmd_completer_handle_brkchars): Adjust.
8385 * completer.c (filename_completer_handle_brkchars): New function.
8386 (complete_line_internal_normal_command): New function, factored
8388 (complete_line_internal): ... here.
8389 (command_completer_handle_brkchars)
8390 (default_completer_handle_brkchars)
8391 (completer_handle_brkchars_func_for_completer): New functions.
8392 * completer.h (set_gdb_completion_word_break_characters): Delete
8394 (completer_handle_brkchars_func_for_completer): New declaration.
8395 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
8396 completer_handle_brkchars_func_for_completer.
8398 2017-07-17 Pedro Alves <palves@redhat.com>
8400 * completer.c (symbol_completer): New function, based on
8401 make_symbol_completion_list_fn.
8402 * completer.h (symbol_completer): New declaration.
8403 * guile/scm-cmd.c (cmdscm_completers): Adjust.
8404 * python/py-cmd.c (completers): Adjust.
8405 * symtab.c (make_symbol_completion_list_fn): Delete.
8406 * symtab.h (make_symbol_completion_list_fn): Delete.
8407 * cli/cli-decode.c (add_cmd): Adjust.
8409 2017-07-17 Pedro Alves <palves@redhat.com>
8411 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
8412 * dwarf2read.c: Include "filename-seen-cache.h".
8413 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
8414 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
8415 * filename-seen-cache.c: New file.
8416 * filename-seen-cache.h: New file.
8417 * symtab.c: Include "filename-seen-cache.h".
8418 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
8419 (create_filename_seen_cache, clear_filename_seen_cache)
8420 (delete_filename_seen_cache, filename_seen): Delete, parts moved
8421 to filename-seen-cache.h/filename-seen-cache.c.
8422 (output_source_filename, sources_info)
8423 (maybe_add_partial_symtab_filename)
8424 (make_source_files_completion_list): Adjust to use
8425 filename_seen_cache.
8427 2017-07-17 Pedro Alves <palves@redhat.com>
8429 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
8431 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
8432 dwarf2_debug_sections*)): New.
8433 (dwarf2_per_objfile::dwarf2_per_objfile(const
8434 dwarf2_per_objfile&)): Declare as deleted.
8435 (dwarf2_per_objfile::operator=): Declare as deleted.
8436 (dwarf2_per_objfile::dwarf2_per_objfile)
8437 (dwarf2_per_objfile::~dwarf2_per_objfile)
8438 (dwarf2_per_objfile::free_cached_comp_units): New.
8439 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
8440 ctor. Call dwarf2_per_objfile's ctor manually.
8441 (dwarf2_locate_sections): Deleted/refactored as ...
8442 (dwarf2_per_objfile::locate_sections): ... this new method.
8443 (free_cached_comp_units): Defer to
8444 dwarf2_per_objfile::free_cached_comp_units.
8445 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
8447 2017-07-14 Tom Tromey <tom@tromey.com>
8450 * rust-exp.y (convert_ast_to_expression): Add "want_type"
8452 <UNOP_SIZEOF>: Split into separate case.
8453 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
8455 2017-07-14 Tom Tromey <tom@tromey.com>
8458 * symtab.c (symbol_matches_domain): Add language_rust to special
8460 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
8461 treat LOC_TYPEDEF symbols as variables.
8463 2017-07-14 Pedro Alves <palves@redhat.com>
8465 * symtab.c (make_file_symbol_completion_list_1): Iterate over
8466 symtabs matching all symtabs with SRCFILE as file name instead of
8467 only considering the first hit, with lookup_symtab.
8469 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8471 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
8472 operator_name parameters.
8473 (gen_expr): Update function call.
8475 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8477 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
8479 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
8481 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
8482 parameter, use agent_expr::gdbarch instead, update function
8484 (locexpr_tracepoint_var_ref): Likewise.
8485 (loclist_tracepoint_var_ref): Likewise.
8486 * ax-gdb.c (gen_trace_static_fields): Likewise.
8487 (gen_traced_pop): Likewise.
8488 (gen_frame_args_address): Likewise.
8489 (gen_frame_locals_address): Likewise.
8490 (gen_var_ref): Likewise.
8491 (gen_struct_ref_recursive): Likewise.
8492 (gen_static_field): Likewise.
8493 (gen_maybe_namespace_elt): Likewise.
8494 (gen_expr): Likewise.
8495 (gen_trace_for_var): Likewise.
8496 (gen_trace_for_expr): Likewise.
8497 (gen_trace_for_return_address): Likewise.
8499 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8501 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
8503 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
8505 2017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8507 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
8508 from ax, update calls.
8509 (gen_usual_arithmetic): Likewise.
8510 (gen_integral_promotions): Likewise.
8511 (gen_bitfield_ref): Likewise.
8512 (gen_primitive_field): Likewise.
8513 (gen_struct_ref_recursive): Likewise.
8514 (gen_struct_ref): Likewise.
8515 (gen_maybe_namespace_elt): Likewise.
8516 (gen_struct_elt_for_reference): Likewise.
8517 (gen_namespace_elt): Likewise.
8518 (gen_aggregate_elt_ref): Likewise.
8519 (gen_expr): Get gdbarch from ax, update calls.
8520 (gen_expr_binop_rest): Likewise.
8522 2017-07-13 Pedro Alves <palves@redhat.com>
8524 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
8526 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
8527 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
8528 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
8529 tdesc_amd64_linux as default tdesc. Get final tdesc from the
8531 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
8532 Get final tdesc from the tdep.
8533 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
8535 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
8536 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
8537 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
8538 Use it as default tdesc.
8539 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
8540 down to amd_init_abi. No longer handle fallback tdesc here.
8541 * amd64-tdep.h (tdesc_x32): Declare.
8542 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
8544 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
8547 2017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8549 * s390-linux-tdep.c (s390_process_record): Add support for
8550 instructions new in arch12.
8552 2017-07-11 John Baldwin <jhb@FreeBSD.org>
8554 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
8555 PT_GETFSBASE and PT_GETGSBASE.
8556 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
8559 2017-07-11 John Baldwin <jhb@FreeBSD.org>
8561 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
8562 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
8563 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
8565 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
8566 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
8567 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
8568 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
8569 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
8570 * features/i386/amd64.xml: Add 64bit-segments.xml.
8571 * features/i386/amd64-avx-avx512.c: Regenerated.
8572 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
8573 * features/i386/amd64-avx-mpx.c: Regenerated.
8574 * features/i386/amd64-avx.c: Regenerated.
8575 * features/i386/amd64-mpx.c: Regenerated.
8576 * features/i386/amd64.c: Regenerated.
8577 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
8578 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8579 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
8580 * regformats/i386/amd64-avx.dat: Regenerated.
8581 * regformats/i386/amd64-mpx.dat: Regenerated.
8582 * regformats/i386/amd64.dat: Regenerated.
8584 2017-07-10 Yao Qi <yao.qi@linaro.org>
8586 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
8587 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
8589 2017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
8591 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
8593 * gnulib/aclocal.m4: Regenerate.
8594 * gnulib/config.in: Regenerate.
8595 * gnulib/configure: Regenerate.
8596 * gnulib/import/Makefile.am: Regenerate.
8597 * gnulib/import/Makefile.in: Regenerate.
8598 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
8599 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
8600 * gnulib/import/m4/environ.m4: New file.
8601 * gnulib/import/m4/setenv.m4: New file.
8602 * gnulib/import/setenv.c: New file.
8603 * gnulib/import/unsetenv.c: New file.
8605 2017-07-09 Simon Marchi <simon.marchi@ericsson.com>
8607 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
8608 address when op is DW_OP_addr.
8610 2017-07-09 Tom Tromey <tom@tromey.com>
8612 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
8613 check and apply to outer type.
8615 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8617 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
8618 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
8619 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
8620 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
8622 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8624 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
8626 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8628 * corelow.c (get_core_siginfo): Remove.
8629 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
8630 instead of get_core_siginfo.
8631 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
8632 * gdbarch.h: Re-generate.
8633 * gdbarch.c: Re-generate.
8634 * linux-tdep.c (linux_core_xfer_siginfo): New.
8635 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
8637 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8639 * corelow.c (thread_section_name): Move to ...
8640 * gdbcore.h (thread_section_name): ... here.
8642 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8644 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
8645 (struct siginfo32): New.
8646 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
8647 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
8648 via ptrace(PT_LWPINFO).
8650 2017-07-07 John Baldwin <jhb@FreeBSD.org>
8652 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
8653 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
8654 (fbsd_get_siginfo_type): New.
8655 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
8656 (_initialize_fbsd_tdep): New.
8658 2017-07-06 David Blaikie <dblaikie@gmail.com>
8660 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
8661 a singular dwo_unit*) to support multiple CUs in the same way that
8662 multiple TUs are supported.
8663 (create_cus_hash_table): Replace create_dwo_cu with a function for
8664 parsing multiple CUs from a DWO file.
8665 (open_and_init_dwo_file): Use create_cus_hash_table rather than
8667 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
8668 htab_find, rather than comparing the signature to a singleton CU in
8671 2017-07-06 Pedro Alves <palves@redhat.com>
8673 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
8675 2017-07-04 Pedro Alves <palves@redhat.com>
8677 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
8678 * gdbtypes.h (TYPE_STATIC): Delete.
8679 (struct fn_field) <is_public, is_abstract, is_static, is_final,
8680 is_synchronized, is_native>: Delete.
8682 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
8683 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
8684 (TYPE_FN_FIELD_ABSTRACT): Delete.
8686 2017-07-03 Simon Marchi <simon.marchi@ericsson.com>
8688 * buffer.h (buffer_finish): Fix spelling mistakes.
8690 2017-07-01 Eli Zaretskii <eliz@gnu.org>
8692 * .dir-locals.el: Automatically switch to C-style comments in
8693 versions of Emacs that support the feature.
8695 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8696 Pedro Alves <palves@redhat.com>
8699 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
8700 (process_next_line): New variable 'inline_cmd'.
8701 Adjust 'if' clauses for "python", "compile" and "guile" to use
8702 'command_name_equals' and check for '!inline_cmd'.
8704 2017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8707 * cli/cli-script.c (command_name_equals_not_inline): New function.
8708 (process_next_line): Adjust 'if' clauses for "python", "compile"
8709 and "guile" to use command_name_equals_not_inline.
8711 2017-06-29 Pedro Alves <palves@redhat.com>
8713 * completer.c (expression_completer): Call
8714 linespec_location_completer instead of location_completer.
8716 2017-06-29 Pedro Alves <palves@redhat.com>
8718 * completer.c (expression_completer): Remove code that recomputes
8721 2017-06-29 Yao Qi <yao.qi@linaro.org>
8723 * regformats/regdat.sh: Generate code with
8724 "ifndef IN_PROCESS_AGENT".
8726 2017-06-28 Pedro Alves <palves@redhat.com>
8728 * command.h: Include "common/scoped_restore.h".
8730 2017-06-28 Yao Qi <yao.qi@linaro.org>
8732 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
8733 instead of obstack_grow.
8735 2017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
8738 * symfile.c (reread_symbols): Call objfiles_changed just before
8741 2017-06-27 Pedro Alves <palves@redhat.com>
8743 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
8744 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
8745 (completion_list_add_symbol, completion_list_add_msymbol):
8746 ... these new functions.
8747 (add_symtab_completions)
8748 (default_make_symbol_completion_list_break_on_1): Adjust.
8750 2017-06-27 Pedro Alves <palves@redhat.com>
8752 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
8753 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
8754 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
8756 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
8757 'storage_obstack' field an auto_obstack. In-class initialize all
8758 non-bitfield fields. Make minsyms_read bool.
8759 * symfile.c (read_symbols): Adjust.
8761 2017-06-27 Alan Hayward <alan.hayward@arm.com>
8763 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
8764 (gdbsim_store_register): Likewise.
8766 2017-06-27 Pedro Alves <palves@redhat.com>
8768 * c-exp.y (name_obstack): Now an auto_obstack.
8769 (yylex): Use auto_obstack::clear.
8770 (c_parse): Use auto_obstack::clear instead of reinitializing and
8771 freeing the obstack.
8772 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
8773 * d-exp.y (name_obstack): Now an auto_obstack.
8774 (yylex): Use auto_obstack::clear.
8775 (d_parse): Use auto_obstack::clear instead of reinitializing and
8776 freeing the obstack.
8777 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
8779 * dwarf2read.c (create_addrmap_from_index)
8780 (dwarf2_build_psymtabs_hard)
8781 (update_enumeration_type_from_children): Likewise.
8782 * gdb_obstack.h (auto_obstack): New type.
8783 * go-exp.y (name_obstack): Now an auto_obstack.
8784 (build_packaged_name): Use auto_obstack::clear.
8785 (go_parse): Use auto_obstack::clear instead of reinitializing and
8786 freeing the obstack.
8787 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
8789 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
8790 * rust-exp.y (work_obstack): Now an auto_obstack.
8791 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
8792 reinitializing and freeing the obstack.
8793 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
8794 (host_char_to_target): Use auto_obstack.
8795 * utils.h (make_cleanup_obstack_free): Delete declaration.
8796 * valprint.c (generic_emit_char, generic_printstr): Use
8799 2017-06-27 Simon Marchi <simon.marchi@ericsson.com>
8801 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
8803 (darwin_init_thread_list): Don't update dummy thread.
8804 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
8806 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8808 * record-full.c (netorder16): Remove.
8810 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8812 * common/diagnostics.h: Define macros for GCC.
8813 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
8814 * common/vec.h: Include diagnostics.h.
8815 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
8816 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
8819 2017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8821 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
8823 * ada-lex.l: Ignore deprecated register warnings.
8825 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8827 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
8828 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
8830 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8832 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
8835 2017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8837 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
8839 2017-06-23 Alan Hayward <alan.hayward@arm.com>
8841 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
8842 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
8843 (xtensa_register_read_masked): Likewise.
8845 2017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
8847 * common/environ.c (gdb_environ::unset): Update comment.
8849 2017-06-22 Alan Hayward <alan.hayward@arm.com>
8851 * python/py-unwind.c (pyuw_sniffer): Allocate space for
8854 2017-06-22 Alan Hayward <alan.hayward@arm.com>
8856 * record-full.c (record_full_exec_insn): Use byte_vector.
8858 2017-06-22 Yao Qi <yao.qi@linaro.org>
8860 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
8861 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8863 2017-06-22 Alan Hayward <alan.hayward@arm.com>
8865 * remote.c (cached_reg): Move from here...
8866 * regcache.h (cached_reg): ...to here.
8867 * python/py-unwind.c (struct reg_info): Remove.
8868 (cached_frame_info): Use cached_reg_t.
8869 (pyuw_prev_register): Likewise.
8870 (pyuw_sniffer): Use cached_reg_t and allocate registers.
8871 (pyuw_dealloc_cache): Free all registers.
8873 2017-06-22 Pedro Alves <palves@redhat.com>
8874 Simon Marchi <simon.marchi@ericsson.com>
8876 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
8878 * common/diagnostics.h: New file.
8880 2017-06-22 Pedro Alves <palves@redhat.com>
8882 * common/agent.h: Add include guards.
8884 2017-06-21 Simon Marchi <simon.marchi@ericsson.com>
8886 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
8887 talk about addressable units instead of bytes.
8889 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
8891 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
8892 of '::const_iterator'.
8894 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
8896 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8897 'unittests/environ-selftests.c'.
8898 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
8899 * charset.c (find_charset_names): Declare object 'iconv_env'.
8900 Update code to use 'iconv_env' object. Remove call to
8902 * common/environ.c: Include <utility>.
8903 (make_environ): Delete function.
8904 (free_environ): Delete function.
8905 (gdb_environ::clear): New function.
8906 (gdb_environ::operator=): New function.
8907 (gdb_environ::get): Likewise.
8908 (environ_vector): Delete function.
8909 (set_in_environ): Delete function.
8910 (gdb_environ::set): New function.
8911 (unset_in_environ): Delete function.
8912 (gdb_environ::unset): New function.
8913 (gdb_environ::envp): Likewise.
8914 * common/environ.h: Include <vector>.
8915 (struct gdb_environ): Delete; transform into...
8916 (class gdb_environ): ... this class.
8917 (free_environ): Delete prototype.
8918 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
8919 environ_vector): Likewise.
8920 * infcmd.c (run_command_1): Update code to call
8921 'envp' from 'gdb_environ' class.
8922 (environment_info): Update code to call methods from 'gdb_environ'
8924 (unset_environment_command): Likewise.
8925 (path_info): Likewise.
8926 (path_command): Likewise.
8927 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
8928 (inferior::inferior): Initialize 'environment' using the host's
8930 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
8931 Include "environ.h".
8932 (class inferior) <environment>: Change type from 'struct
8933 gdb_environ' to 'gdb_environ'.
8934 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
8935 methods from 'gdb_environ' class.
8936 * solib.c (solib_find_1): Likewise
8937 * unittests/environ-selftests.c: New file.
8939 2017-06-20 Yao Qi <yao.qi@linaro.org>
8941 * features/i386/i386-linux.xml: Exchange the order of including
8942 32bit-linux.xml and 32bit-sse.xml.
8943 * features/i386/i386-linux.c: Regenerated.
8945 2017-06-20 Yao Qi <yao.qi@linaro.org>
8947 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
8948 Delete copy ctor and assignment operator.
8949 (tdesc_type): Likewise.
8950 (tdesc_feature): Likewise.
8951 (tdesc_free_reg): Remove.
8952 (tdesc_create_reg): Use new.
8953 (tdesc_free_type): Remove.
8954 (tdesc_create_vector): Use new.
8955 (tdesc_create_union): Likewise.
8956 (tdesc_create_flags): Likewise.
8957 (tdesc_create_enum): Likewise.
8958 (tdesc_free_feature): Delete.
8959 (free_target_description): Use delete.
8961 2017-06-19 John Baldwin <jhb@FreeBSD.org>
8963 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
8966 2017-06-19 Pedro Alves <palves@redhat.com>
8968 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
8969 after gdb::unlinker.
8971 2017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
8973 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
8974 gdb_environ to access an environment variable.
8976 2017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
8978 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
8981 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
8983 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
8985 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
8987 * configure: Re-generate.
8988 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
8990 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
8992 * configure: Re-generate.
8993 * warning.m4: Pass -Werror to compiler when checking for
8994 supported warning flags.
8996 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
8998 * Makefile.in (COMPILE.pre): Add "-x c++".
9000 2017-06-16 Alan Hayward <alan.hayward@arm.com>
9001 Pedro Alves <palves@redhat.com>
9002 Yao Qi <yao.qi@linaro.org>
9004 * defs.h (RequireLongest): New.
9005 (extract_integer): Declare function template.
9006 (extract_signed_integer): Remove the declaration, but define it
9008 (extract_unsigned_integer): Likewise.
9009 (store_integer): Declare function template.
9010 (store_signed_integer): Remove the declaration, but define it
9012 (store_unsigned_integer): Likewise.
9013 * findvar.c (extract_integer): New function template.
9014 (extract_signed_integer): Remove.
9015 (extract_unsigned_integer): Remove.
9016 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
9018 (store_integer): New function template.
9019 (store_signed_integer): Remove.
9020 (store_unsigned_integer): Remove.
9021 (store_integer): Explicit instantiations.
9022 * regcache.c (regcache_raw_read_signed): Update.
9023 (regcache::raw_read): New function.
9024 (regcache::raw_read_signed): Remove.
9025 (regcache::raw_read_unsigned): Remove.
9026 (regcache_raw_read_unsigned): Update.
9027 (regcache_raw_write_unsigned): Update.
9028 (regcache::raw_write_signed): Remove.
9029 (regcache::raw_write): New function.
9030 (regcache_cooked_read_signed): Update.
9031 (regcache::raw_write_unsigned): Remove.
9032 (regcache::cooked_read_signed): Remove.
9033 (regcache_cooked_read_unsigned): Update.
9034 (regcache::cooked_read_unsigned): Remove.
9035 (regcache_cooked_write_signed): Update.
9036 (regcache_cooked_write_unsigned): Update.
9037 * regcache.h (regcache) <raw_read_signed>: Remove.
9038 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
9039 <raw_read, raw_write>: New.
9040 <cooked_read_signed, cooked_write_signed>: Remove.
9041 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
9042 <cooked_read, cooked_write>: New.
9043 * sh64-tdep.c (sh64_pseudo_register_read): Update.
9044 (sh64_pseudo_register_write): Update.
9046 2017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
9048 * arc-tdep.c (arc_disassembler_options): New variable.
9049 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
9050 of default_print_insn.
9051 (arc_delayed_print_insn): Set info->section when needed,
9052 use default_print_insn to retrieve a disassembler.
9054 2017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
9057 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
9058 to mention $SHELL and startup-with-shell.
9060 2017-06-14 Max Filippov <jcmvbkbc@gmail.com>
9062 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
9064 2017-06-14 Yao Qi <yao.qi@linaro.org>
9066 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
9067 default_print_insn instead of print_insn_aarch64.
9068 * arm-tdep.c (gdb_print_insn_arm): Call
9069 default_print_insn instead of print_insn_big_arm
9070 and print_insn_little_arm.
9071 * i386-tdep.c (i386_print_insn): Call default_print_insn
9072 instead of print_insn_i386.
9073 * ia64-tdep.c (ia64_print_insn): Call
9074 default_print_insn instead of print_insn_ia64.
9075 * mips-tdep.c (gdb_print_insn_mips): Call
9076 default_print_insn instead of print_insn_big_mips
9077 and print_insn_little_mips.
9078 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
9079 instead of print_insn_spu.
9081 2017-06-14 Pedro Alves <palves@redhat.com>
9083 * ada-lang.c: Include "common/byte-vector.h".
9084 (ada_value_primitive_packed_val): Use gdb::byte_vector.
9085 * charset.c (wchar_iterator::iterate): Resize the vector instead
9087 * common/byte-vector.h: Include "common/def-vector.h".
9088 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
9089 * cli/cli-dump.c: Include "common/byte-vector.h".
9090 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
9091 * common/byte-vector.h: New file.
9092 * common/def-vector.h: New file.
9093 * common/default-init-alloc.h: New file.
9094 * dwarf2loc.c: Include "common/byte-vector.h".
9095 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
9096 instead of reserving it.
9097 * dwarf2read.c: Include "common/byte-vector.h".
9098 (data_buf::m_vec): Now a gdb::byte_vector.
9099 * gdb_regex.c: Include "common/def-vector.h".
9100 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
9101 * mi/mi-main.c: Include "common/byte-vector.h".
9102 (mi_cmd_data_read_memory): Use gdb::byte_vector.
9103 * printcmd.c: Include "common/byte-vector.h".
9104 (print_scalar_formatted): Use gdb::byte_vector.
9105 * valprint.c: Include "common/byte-vector.h".
9106 (maybe_negate_by_bytes, print_decimal_chars): Use
9109 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9111 * darwin-nat.c: Include "nat/fork-inferior.h".
9113 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9115 * configure.nat: Factor out Darwin bits that are not
9116 architecture-specific. Add fork-inferior.o.
9118 2017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9120 * configure.nat: Factor out AIX bits that are not
9121 architecture-specific. Add fork-inferior.o.
9123 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9125 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
9126 (read_pieced_value, write_pieced_value): ...here. Reduce to
9127 wrappers that just call rw_pieced_value.
9129 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9131 * dwarf2loc.c (write_pieced_value): When writing the data for a
9132 memory piece, use write_memory_with_notification instead of
9135 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9137 * valops.c (read_value_memory): Change embedded_offset to
9138 represent a bit offset instead of a byte offset.
9139 * value.h (read_value_memory): Adjust comment.
9141 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9143 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
9144 dest_offset_bits and source_offset_bits.
9145 (write_pieced_value): Likewise.
9147 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9149 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
9150 given by DW_OP_bit_piece.
9151 (write_pieced_value): Likewise.
9153 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9155 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
9156 some other preparations to the places where sufficient information
9158 (write_pieced_value): Likewise.
9160 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9162 * dwarf2loc.c (bits_to_bytes): New function.
9163 (read_pieced_value): Fix offset calculations for register pieces
9164 on big-endian targets.
9165 (write_pieced_value): Likewise.
9167 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9169 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
9170 (write_pieced_value): Likewise.
9172 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9174 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
9175 transfer the source value's least significant bits, instead of its
9176 lowest-addressed ones. Rename type_len to max_offset.
9177 (read_pieced_value): Mirror above changes to write_pieced_value as
9180 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9182 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
9183 truncate full bytes from dest_offset_bits before using it as an
9184 offset into the buffer.
9186 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9188 * dwarf2loc.c (write_pieced_value): Include transfer size in
9191 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9193 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
9194 calculation of this_size.
9196 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9198 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
9199 when targeting a bit-field.
9200 (write_pieced_value): Likewise.
9202 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9204 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
9205 (allocate_piece_closure): Drop addr_size parameter.
9206 (dwarf2_evaluate_loc_desc_full): Adjust call to
9207 allocate_piece_closure.
9209 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9212 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
9213 the LSB end, independent of endianness.
9215 2017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9217 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
9220 2017-06-13 Yao Qi <yao.qi@linaro.org>
9222 * mips-linux-nat.c: Move include features/mips*-linux.c to
9224 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
9225 to mips-linux-tdep.c.
9226 * mips-linux-tdep.c: Include features/mips*-linux.c
9227 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
9229 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
9230 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
9231 (tdesc_mips64_dsp_linux): Declare.
9233 2017-06-12 Tom Tromey <tom@tromey.com>
9235 * valprint.h (val_print_type_code_int): Remove.
9236 * valprint.c (generic_val_print_int): Always call
9237 val_print_scalar_formatted.
9238 (val_print_type_code_int): Remove.
9239 * printcmd.c (print_scalar_formatted): Handle options->format==0.
9240 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
9241 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
9242 * ada-valprint.c (ada_val_print_num): Use
9243 val_print_scalar_formatted.
9245 2017-06-12 Tom Tromey <tom@tromey.com>
9247 * printcmd.c (print_scalar_formatted): Unify the two switches.
9248 Don't convert scalars to LONGEST.
9250 2017-06-12 Tom Tromey <tom@tromey.com>
9253 * valprint.h (print_decimal_chars): Update.
9254 * valprint.c (maybe_negate_by_bytes): New function.
9255 (print_decimal_chars): Add "is_signed" argument.
9256 * printcmd.c (print_scalar_formatted): Update.
9258 2017-06-12 Tom Tromey <tom@tromey.com>
9261 * valprint.h (print_binary_chars, print_hex_chars): Update.
9262 * valprint.c (val_print_type_code_int): Update.
9263 (print_binary_chars): Add "zero_pad" argument.
9264 (emit_octal_digit): New function.
9265 (print_octal_chars): Don't zero-pad.
9266 (print_decimal_chars): Likewise.
9267 (print_hex_chars): Add "zero_pad" argument.
9268 * sh64-tdep.c (sh64_do_fp_register): Update.
9269 * regcache.c (regcache::dump): Update.
9270 * printcmd.c (print_scalar_formatted): Update.
9271 * infcmd.c (default_print_one_register_info): Update.
9273 2017-06-12 Pedro Alves <palves@redhat.com>
9274 Alan Hayward <alan.hayward@arm.com>
9276 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
9277 (mips_eabi_push_dummy_call): Rename local 'regsize' to
9278 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
9279 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
9280 Assert that abi_regsize bytes fit in 'ref_valbuf'.
9282 2017-06-12 Pedro Alves <palves@redhat.com>
9284 * dwarf2read.c (mapped_symtab::data): Now a vector of
9285 symtab_index_entry instead of vector of
9286 std::unique_ptr<symtab_index_entry>. All users adjusted to check
9287 whether an element's name is NULL instead of checking whether the
9288 element itself is NULL.
9289 (find_slot): Change return type. Adjust.
9290 (hash_expand, , add_index_entry, uniquify_cu_indices)
9291 (write_hash_table): Adjust.
9293 2017-06-12 Pedro Alves <palves@redhat.com>
9295 * dwarf2read.c (recursively_count_psymbols): New function.
9296 (write_psymtabs_to_index): Call it to compute number of psyms and
9297 pass estimate size of psyms_seen to unordered_set's ctor.
9299 2017-06-12 Pedro Alves <palves@redhat.com>
9301 * dwarf2read.c (write_hash_table): Check if key already exists
9304 2017-06-12 Pedro Alves <palves@redhat.com>
9306 * dwarf2read.c (data_buf::append_space): Rename to...
9307 (data_buf::grow): ... this, and make private. Adjust all callers.
9308 (data_buf::append_uint): New method.
9309 (add_address_entry, write_one_signatured_type)
9310 (write_psymtabs_to_index): Use it.
9312 2017-06-12 Pedro Alves <palves@redhat.com>
9314 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
9315 (file_write (FILE *, const std::vector<Elem>&)): Delete.
9316 (data_buf::file_write): Call ::fwrite directly.
9318 2017-06-12 Pedro Alves <palves@redhat.com>
9320 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
9323 2017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9325 Code cleanup: C++ify .gdb_index producer.
9326 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
9327 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
9328 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
9329 (create_strtab, add_string): Remove.
9330 (file_write, data_buf): New.
9331 (struct symtab_index_entry): Use std::vector for cu_indices.
9332 (struct mapped_symtab): Use std::vector for data.
9333 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
9334 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
9336 (find_slot): Change return type. Update it to the new data structures.
9337 (hash_expand, add_index_entry): Update it to the new data structures.
9338 (offset_type_compare): Remove.
9339 (uniquify_cu_indices): Update it to the new data structures.
9340 (c_str_view, c_str_view_hasher, vector_hasher): New.
9341 (add_indices_to_cpool): Remove.
9342 (write_hash_table): Update it to the new data structures.
9343 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
9344 (eq_psymtab_cu_index): Remove.
9345 (psym_index_map): New typedef.
9346 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
9347 reference and std::unordered_map for cu_index_htab.
9348 (add_address_entry, add_address_entry_worker, write_address_map)
9349 (write_psymbols): Update it to the new data structures.
9350 (write_obstack): Remove.
9351 (struct signatured_type_index_data): Change types_list to a data_buf
9352 reference and psyms_seen to a std::unordered_set reference.
9353 (write_one_signatured_type, recursively_write_psymbols)
9354 (write_psymtabs_to_index): Update it to the new data structures.
9356 2017-06-11 Simon Marchi <simon.marchi@ericsson.com>
9358 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
9359 separate-debug-file commands.
9360 * symfile.h (separate_debug_file_debug): New global.
9361 * symfile.c (separate_debug_file_debug): New global.
9362 (separate_debug_file_exists, find_separate_debug_file): Add
9364 (_initialize_symfile): Add "set debug separate-debug-file"
9366 * build-id.c (build_id_to_debug_bfd,
9367 find_separate_debug_file_by_buildid): Add debug output.
9369 2017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
9371 * gdbarch.sh (displaced_step_free_closure): Remove.
9372 * gdbarch.h, gdbarch.c: Re-generate.
9373 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
9374 displaced_step_free_closure.
9375 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
9376 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
9377 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9378 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
9379 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9380 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
9381 * arch-utils.h (simple_displaced_step_free_closure): Remove.
9382 * arch-utils.c (simple_displaced_step_free_closure): Remove.
9383 * infrun.c (displaced_step_clear): Call xfree instead of
9384 gdbarch_displaced_step_free_closure.
9386 2017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
9388 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
9391 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9393 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
9394 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
9395 (mn10300_push_dummy_call): Likewise.
9397 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9399 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
9401 2017-06-08 Alan Hayward <alan.hayward@arm.com>
9403 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
9405 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9407 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
9408 able to start inferiors using a shell.
9409 (New remote packets): Announce new packet "QStartupWithShell".
9410 * remote.c: Add PACKET_QStartupWithShell.
9411 (extended_remote_create_inferior): Handle new
9412 PACKET_QStartupWithShell.
9413 (remote_protocol_features) <QStartupWithShell>: New entry for
9414 PACKET_QStartupWithShell.
9415 (_initialize_remote): Call "add_packet_config_cmd" for
9418 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9419 Pedro Alves <palves@redhat.com>
9421 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
9422 and "nat/fork-inferior.h".
9423 * common/common-inferior.h: New file, with contents from
9425 * commom/common-utils.c: Include "common-utils.h".
9426 (stringify_argv): New function.
9427 * common/common-utils.h (stringify_argv): New prototype.
9428 * configure.nat: Add "fork-inferior.o" as a dependency for
9429 "*linux*", "fbsd*" and "nbsd*" hosts.
9430 * corefile.c (get_exec_file): Update comment.
9431 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
9432 instead of "startup_inferior".
9433 (darwin_create_inferior): Call "add_thread_silent" after
9435 * fork-child.c: Cleanup unnecessary includes.
9436 (SHELL_FILE): Move to "common/common-fork-child.c".
9437 (environ): Likewise.
9438 (exec_wrapper): Initialize.
9439 (get_exec_wrapper): New function.
9440 (breakup_args): Move to "common/common-fork-child.c"; rename to
9441 "breakup_args_for_exec".
9442 (escape_bang_in_quoted_argument): Move to
9443 "common/common-fork-child.c".
9444 (saved_ui): New variable.
9445 (prefork_hook): New function.
9446 (postfork_hook): Likewise.
9447 (postfork_child_hook): Likewise.
9448 (gdb_startup_inferior): Likewise.
9449 (fork_inferior): Move to "common/common-fork-child.c". Update
9450 function to support gdbserver.
9451 (startup_inferior): Likewise.
9452 * gdbcore.h (get_exec_file): Remove declaration.
9453 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
9454 instead of "startup_inferior". Call "add_thread_silent" after
9456 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
9457 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
9458 instead of "startup_inferior". Call "add_thread_silent" after
9460 * inferior.h: Include "common-inferior.h".
9461 (trace_start_error): Move to "common/common-utils.h".
9462 (trace_start_error_with_name): Likewise.
9463 (fork_inferior): Move prototype to "nat/fork-inferior.h".
9464 (startup_inferior): Likewise.
9465 (gdb_startup_inferior): New prototype.
9466 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
9467 * nat/fork-inferior.h: New file.
9468 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
9469 instead of "startup_inferior". Call "add_thread_silent" after
9471 * target.h (target_terminal_init): Move prototype to
9473 (target_terminal_inferior): Likewise.
9474 (target_terminal_ours): Likewise.
9475 * target/target.h (target_terminal_init): New prototype, moved
9477 (target_terminal_inferior): Likewise.
9478 (target_terminal_ours): Likewise.
9479 * utils.c (gdb_flush_out_err): New function.
9481 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9483 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
9484 * common/common-gdbthread.h: New file, with parts from
9486 * gdbthread.h: Include "common-gdbthread.h".
9487 (switch_to_thread): Moved to "common/common-gdbthread.h".
9489 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9491 * Makefile.in (SFILES): Add "common/job-control.c".
9492 (HFILES_NO_SRCDIR): Add "common/job-control.h".
9493 (COMMON_OBS): Add "job-control.o".
9494 * common/job-control.c: New file, with contents from
9496 * common/job-control.h: New file, with contents from "terminal.h".
9497 * fork-child.c: Include "job-control.h".
9498 * inflow.c: Include "job-control.h".
9499 (gdb_setpgid): Move to "common/common-inflow.c".
9500 (_initialize_inflow): Move setting of "job_control" to
9501 "handle_job_control".
9502 * terminal.h (job_control): Moved to "common/common-terminal.h".
9503 (gdb_setpgid): Likewise.
9504 * top.c: Include "job_control.h".
9505 * utils.c: Likewise.
9506 (job_control): Moved to "job-control.c".
9508 2017-06-07 Pedro Alves <palves@redhat.com>
9510 * Makefile.in (SFILES): Add gdb_regex.c.
9511 (COMMON_OBS): Add gdb_regex.o.
9512 * ada-lang.c (ada_add_standard_exceptions)
9513 (ada_add_exceptions_from_frame, name_matches_regex)
9514 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
9515 parameter type to compiled_regex. Adjust.
9516 (ada_exceptions_list): Use compiled_regex.
9517 * break-catch-throw.c (exception_catchpoint::pattern): Now a
9518 std::unique_ptr<compiled_regex>.
9519 (exception_catchpoint::~exception_catchpoint): Remove regfree
9521 (check_status_exception_catchpoint): Adjust to use compiled_regex.
9522 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
9523 * breakpoint.c (solib_catchpoint::compiled): Now a
9524 std::unique_ptr<compiled_regex>.
9525 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
9526 (check_status_catch_solib): Adjust to use compiled_regex.
9527 (add_solib_catchpoint): Adjust to use compiled_regex.
9528 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
9529 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
9530 compiled_regex reference. Adjust to use it.
9531 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
9532 declaration. Include "gdb_regex.h".
9533 (apropos_cmd): Change regex parameter to compiled_regex reference.
9534 * gdb_regex.c: New file.
9535 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
9537 (class compiled_regex): New.
9538 * linux-tdep.c: Include "common/gdb_optional.h".
9539 (struct mapping_regexes): New, factored out from
9540 mapping_is_anonymous_p, and adjusted to use compiled_regex.
9541 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
9542 gdb::optional and remove cleanups. Adjust to compiled_regex.
9543 * probe.c: Include "common/gdb_optional.h".
9544 (collect_probes): Use compiled_regex and gdb::optional and remove
9546 * skip.c: Include "common/gdb_optional.h".
9547 (skiplist_entry::compiled_function_regexp): Now a
9548 gdb::optional<compiled_regex>.
9549 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
9550 (free_skiplist_entry): Remove regfree call.
9551 (compile_skip_regexp, skip_rfunction_p): Adjust to use
9552 compiled_regex and gdb::optional.
9553 * symtab.c: Include "common/gdb_optional.h".
9554 (search_symbols): Use compiled_regex and gdb::optional.
9555 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
9556 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
9559 2017-06-07 Alan Hayward <alan.hayward@arm.com>
9561 * regcache.c (regcache::save): Avoid buffer use.
9562 (regcache::dump): Likewise.
9564 2017-06-07 Alan Hayward <alan.hayward@arm.com>
9566 * sh-tdep.c (sh_pseudo_register_read): Remove
9568 (sh_pseudo_register_write): Likewise.
9569 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
9570 (sh64_pseudo_register_write): Likewise
9572 2017-06-07 Alan Hayward <alan.hayward@arm.com>
9574 * aarch64-tdep.c (aarch64_store_return_value): Use
9576 (aarch64_pseudo_read_value): Likewise.
9577 (aarch64_pseudo_write): Likewise.
9579 2017-06-06 Yao Qi <yao.qi@linaro.org>
9581 * regformats/regdef.h (set_register_cache): Remove the
9584 2017-06-06 Alan Hayward <alan.hayward@arm.com>
9586 * frame.c (frame_unwind_register_signed): Use
9587 frame_unwind_register_value.
9589 2017-06-06 Pedro Alves <palves@redhat.com>
9591 PR breakpoints/21553
9592 * breakpoint.c (create_breakpoints_sal_default)
9593 (init_breakpoint_sal, create_breakpoint_sal): Use
9594 gdb::unique_xmalloc_ptr for string parameters.
9595 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9596 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
9597 (base_breakpoint_create_breakpoints_sal)
9598 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
9599 (strace_marker_create_breakpoints_sal)
9600 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
9602 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
9603 gdb::unique_xmalloc_ptr for string parameters.
9604 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9607 2017-06-06 Alan Hayward <alan.hayward@arm.com>
9609 * alpha-tdep.c (alpha_register_to_value): Use
9610 get_frame_register_value.
9611 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
9613 2017-06-06 Alan Hayward <alan.hayward@arm.com>
9615 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
9616 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
9617 (ia64_value_to_register): Likewise.
9618 (ia64_extract_return_value): Likewise.
9619 (ia64_store_return_value): Likewise.
9620 (ia64_push_dummy_call): Likewise.
9622 2017-06-04 Joel Brobecker <brobecker@adacore.com>
9626 2017-06-03 Simon Marchi <simon.marchi@ericsson.com>
9628 * x86-linux-nat.c (struct arch_lwp_info): Remove.
9630 2017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
9632 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
9634 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
9636 2017-06-02 Simon Marchi <simon.marchi@ericsson.com>
9638 * event-loop.c (poll_timers): Unallocate timer using delete
9641 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9643 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
9644 (struct breakpoint) <~breakpoint>: New.
9645 (struct watchpoint): Inherit from breakpoint.
9648 (struct tracepoint): Inherit from breakpoint.
9650 * breakpoint.c (longjmp_breakpoint_ops): Remove.
9651 (struct longjmp_breakpoint): Inherit from breakpoint.
9652 <~longjmp_breakpoint>: New.
9654 (new_breakpoint_from_type): Remove casts.
9655 (watchpoint_in_thread_scope): Remove reference to base field.
9656 (watchpoint_del_at_next_stop): Likewise.
9657 (update_watchpoint): Likewise.
9658 (watchpoint_check): Likewise.
9659 (bpstat_check_watchpoint): Likewise.
9660 (set_longjmp_breakpoint): Likewise.
9661 (struct fork_catchpoint): Inherit from breakpoint.
9663 (struct solib_catchpoint): Inherit from breakpoint.
9664 <~solib_catchpoint>: New.
9666 (dtor_catch_solib): Change to ...
9667 (solib_catchpoint::~solib_catchpoint): ... this.
9668 (breakpoint_hit_catch_solib): Remove reference to base field.
9669 (add_solib_catchpoint): Likewise.
9670 (create_fork_vfork_event_catchpoint): Likewise.
9671 (struct exec_catchpoint): Inherit from breakpoint.
9672 <~exec_catchpoint>: New.
9674 (dtor_catch_exec): Change to ...
9675 (exec_catchpoint::~exec_catchpoint): ... this.
9676 (dtor_watchpoint): Change to ...
9677 (watchpoint::~watchpoint): ... this.
9678 (watch_command_1): Remove reference to base field.
9679 (catch_exec_command_1): Likewise.
9680 (base_breakpoint_dtor): Change to ...
9681 (breakpoint::~breakpoint): ... this.
9682 (base_breakpoint_ops): Remove dtor field value.
9683 (longjmp_bkpt_dtor): Change to ...
9684 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
9685 (strace_marker_create_breakpoints_sal): Remove reference to base
9687 (delete_breakpoint): Don't manually call breakpoint destructor.
9688 (create_tracepoint_from_upload): Remove reference to base field.
9689 (trace_pass_set_count): Likewise.
9690 (initialize_breakpoint_ops): Don't initialize
9691 momentary_breakpoint_ops, don't set dtors.
9692 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
9693 <~ada_catchpoint>: New.
9695 (create_excep_cond_exprs): Remove reference to base field.
9696 (dtor_exception): Change to ...
9697 (ada_catchpoint::~ada_catchpoint): ... this.
9698 (dtor_catch_exception): Remove.
9699 (dtor_catch_exception_unhandled): Remove.
9700 (dtor_catch_assert): Remove.
9701 (create_ada_exception_catchpoint): Remove reference to base
9703 (initialize_ada_catchpoint_ops): Don't set dtors.
9704 * break-catch-sig.c (struct signal_catchpoint): Inherit from
9706 <~signal_catchpoint>: New.
9708 (signal_catchpoint_dtor): Change to ...
9709 (signal_catchpoint::~signal_catchpoint): ... this.
9710 (create_signal_catchpoint): Remove reference to base field.
9711 (initialize_signal_catchpoint_ops): Don't set dtor.
9712 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
9714 <~syscall_catchpoint>: New.
9716 (dtor_catch_syscall): Change to ...
9717 (syscall_catchpoint::~syscall_catchpoint): ... this.
9718 (create_syscall_event_catchpoint): Remove reference to base
9720 (initialize_syscall_catchpoint_ops): Don't set dtor.
9721 * break-catch-throw.c (struct exception_catchpoint): Inherit
9723 <~exception_catchpoint>: New.
9725 (dtor_exception_catchpoint): Change to ...
9726 (exception_catchpoint::~exception_catchpoint): ... this.
9727 (handle_gnu_v3_exceptions): Remove reference to base field.
9728 (initialize_throw_catchpoint_ops): Don't set dtor.
9729 * ctf.c (ctf_get_traceframe_address): Remove reference to base
9731 * remote.c (remote_get_tracepoint_status): Likewise.
9732 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
9733 * tracefile.c (tracefile_fetch_registers): Likewise.
9734 * tracepoint.c (actions_command): Likewise.
9735 (validate_actionline): Likewise.
9736 (tfind_1): Likewise.
9737 (get_traceframe_location): Likewise.
9738 (find_matching_tracepoint_location): Likewise.
9739 (parse_tracepoint_status): Likewise.
9740 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
9742 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9744 * breakpoint.c (struct longjmp_breakpoint): New struct.
9745 (is_tracepoint_type): Change return type to bool.
9746 (is_longjmp_type): New function.
9747 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
9748 (set_raw_breakpoint_without_location): Use
9749 new_breakpoint_from_type.
9750 (set_raw_breakpoint): Likewise.
9752 2017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9754 * breakpoint.c (new_breakpoint_from_type): New function.
9755 (create_breakpoint_sal): Use new_breakpoint_from_type and
9757 (create_breakpoint): Likewise.
9759 2017-05-31 Simon Marchi <simon.marchi@ericsson.com>
9761 * memattr.c (mem_info_command): Rename to ...
9762 (info_mem_command): ... this.
9763 (mem_enable_command): Rename to ...
9764 (enable_mem_command): ... this.
9765 (mem_disable_command): Rename to ...
9766 (disable_mem_command): ... this.
9767 (mem_delete_command): Rename to ...
9768 (delete_mem_command): ... this.
9769 (_initialize_mem): Adjust function names.
9771 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9773 * btrace.c (handle_pt_insn_events): New.
9774 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
9775 STATUS. Split into this and ...
9776 (handle_pt_insn_event_flags): ... this.
9778 2017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9780 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
9781 and struct pt_insn.resynced.
9782 * configure: Regenerated.
9783 * config.in: Regenerated.
9785 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9787 * btrace.c (ftrace_find_call_by_number): New function.
9788 (ftrace_new_function): Store objects, not pointers.
9789 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
9790 ftrace_new_gap, ftrace_update_function,
9791 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
9792 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
9793 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
9794 btrace_ends_with_single_insn, btrace_call_get): Account for
9795 btrace_thread_info::functions now storing objects.
9796 * btrace.h (struct btrace_thread_info): Add constructor.
9797 (struct btrace_thread_info) <functions>: Make std::vector.
9798 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
9799 Initialize with default values.
9800 * record-btrace.c (record_btrace_frame_sniffer): Account for
9801 btrace_thread_info::functions now storing objects.
9803 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9805 * btrace.c: Remove typedef bfun_s.
9806 (ftrace_new_gap): Directly add gaps to the list of gaps.
9807 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
9808 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
9809 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
9812 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9814 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
9815 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
9816 with btrace_thread_info::next_segment and
9817 btrace_thread_info::prev_segment.
9818 * btrace.h: Remove struct btrace_func_link.
9819 (struct btrace_function): Replace pair of function segment pointers
9820 with pair of indices.
9821 * python/py-record-btrace.c (btpy_call_prev_sibling,
9822 btpy_call_next_sibling): Replace references to
9823 btrace_thread_info::segment with btrace_thread_info::next_segment and
9824 btrace_thread_info::prev_segment.
9825 * record-btrace.c (record_btrace_frame_this_id): Use
9826 btrace_find_call_by_number.
9828 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9830 * btrace.c (ftrace_new_function, ftrace_fixup_level,
9831 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
9832 btrace_insn_next, btrace_insn_prev): Remove references to
9833 btrace_thread_info::flow.
9834 * btrace.h (struct btrace_function): Remove FLOW.
9836 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9838 * btrace.c (ftrace_find_call_by_number): New function.
9839 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
9840 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
9841 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
9842 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
9844 * btrace.h (struct btrace_function): Turn UP into an index.
9845 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
9847 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
9848 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
9849 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
9851 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9853 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9854 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9855 ftrace_update_function, ftrace_compute_global_level_offset,
9856 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
9857 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
9858 btrace_insn_end, btrace_is_empty): Remove references to
9859 btrace_thread_info::begin and btrace_thread_info::end.
9860 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
9861 (struct btrace_thread_info) <functions>: Adjust comment.
9862 * record-btrace.c (record_btrace_start_replaying): Remove reference to
9863 btrace_thread_info::begin.
9865 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9867 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9868 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9869 ftrace_update_function): Remove arguments that implicitly were always
9871 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
9872 Don't pass BTINFO->END.
9874 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9876 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
9877 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
9878 btrace_find_insn_by_number): Replace function segment pointer with
9880 (btrace_insn_cmp): Simplify.
9881 * btrace.h: (struct btrace_insn_iterator) Rename index to
9882 insn_index. Replace function segment pointer with index into function
9884 * record-btrace.c (record_btrace_call_history): Replace function
9885 segment pointer use with index.
9886 (record_btrace_frame_sniffer): Retrieve function call segment through
9888 (record_btrace_set_replay): Remove defunc't safety check.
9890 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9892 * btrace.c (btrace_ends_with_single_insn): New function.
9893 (btrace_call_get, btrace_call_number, btrace_call_begin,
9894 btrace_call_end, btrace_call_next, btrace_call_prev,
9895 btrace_find_call_by_number): Use index into call segment vector
9897 (btrace_call_cmp): Simplify.
9898 * btrace.h (struct btrace_call_iterator): Replace function call segment
9899 pointer with index into vector.
9900 * record-btrace.c (record_btrace_call_history): Use index instead of
9903 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9905 * btrace.c (btrace_insn_begin, btrace_insn_end,
9906 btrace_find_insn_by_number): Add btinfo to iterator.
9907 * btrace.h (struct btrace_insn_iterator): Add btinfo.
9909 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9911 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
9912 and save pointers directly.
9913 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
9914 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
9915 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
9916 changed signature of functions.
9917 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
9918 (btrace_fetch): Remove code that adds btrace_function pointers to
9919 vector of btrace_functions.
9920 (btrace_clear): Simplify freeing vector of btrace_functions.
9922 2017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9924 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
9925 Replace VEC_* with std::vector functions.
9926 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
9927 (struct btrace_thread_info)<functions>: Change type to std::vector.
9929 2017-05-30 Simon Marchi <simon.marchi@ericsson.com>
9931 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
9932 "Removed targets and native configurations" up. Merge duplicate
9933 "New commands" sub-sections. Add "New options" sub-sections.
9935 2017-05-26 Alan Hayward <alan.hayward@arm.com>
9937 * defs.h (copy_integer_to_size): New declaration.
9938 * findvar.c (copy_integer_to_size): New function.
9939 (do_cint_test): New selftest function.
9940 (copy_integer_to_size_test): Likewise.
9941 (_initialize_findvar): Likewise.
9942 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
9943 (mips_fbsd_collect_reg): Use raw_collect_integer.
9944 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
9945 (mips64_fill_gregset): Use raw_collect_integer
9946 (mips64_fill_fpregset): Use raw_supply_integer.
9947 * regcache.c (regcache::raw_supply_integer): New function.
9948 (regcache::raw_collect_integer): Likewise.
9949 * regcache.h: (regcache::raw_supply_integer): New declaration.
9950 (regcache::raw_collect_integer): Likewise.
9952 2017-05-24 Yao Qi <yao.qi@linaro.org>
9954 * Makefile.in (SFILES): Add gdbarch-selftests.c.
9955 (COMMON_OBS): Add gdbarch-selftests.o.
9956 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
9957 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
9958 * gdbarch-selftests.c: New file.
9959 * regcache.h (regcache) <~regcache>: Mark it virtual if
9961 <raw_write>: Likewise.
9963 2017-05-24 Yao Qi <yao.qi@linaro.org>
9965 * regcache.c (current_regcache): Change it to
9966 regcache::current_regcache.
9967 (regcache_observer_target_changed): Update.
9968 (regcache_thread_ptid_changed): Make it a regcache static
9970 (regcache_thread_ptid_changed): Update.
9971 (class regcache_access): New.
9972 (current_regcache_test): Update.
9973 (_initialize_regcache): Update.
9974 * regcache.h: Include forward_list.
9975 (regcache): Declare regcache_thread_ptid_changed and declare
9976 registers_changed_ptid as friend.
9978 2017-05-24 Yao Qi <yao.qi@linaro.org>
9980 * i387-tdep.c (i387_register_to_value): Use register_size
9981 instead of TYPE_LENGTH.
9982 * m68k-tdep.c (m68k_register_to_value): Likewise.
9984 2017-05-24 Yao Qi <yao.qi@linaro.org>
9986 * i387-tdep.c (i387_convert_register_p): Return false if type
9987 code isn't TYPE_CODE_FLT.
9989 2017-05-24 Yao Qi <yao.qi@linaro.org>
9991 * alpha-tdep.c (alpha_convert_register_p): Return true if type
9993 (alpha_register_to_value): Remove type length check.
9994 (alpha_value_to_register): Likewise.
9996 2017-05-24 Yao Qi <yao.qi@linaro.org>
9998 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
10001 2017-05-24 Yao Qi <yao.qi@linaro.org>
10003 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
10004 TYPE_CODE_FLT or not.
10006 2017-05-24 Yao Qi <yao.qi@linaro.org>
10008 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
10009 * avr-tdep.c (avr_gdbarch_init): Likewise.
10010 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10011 * cris-tdep.c (cris_gdbarch_init): Likewise.
10012 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10013 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10014 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10015 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
10016 * mep-tdep.c (mep_gdbarch_init): Likewise.
10017 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10018 * mips-tdep.c (mips_gdbarch_init): Likewise.
10019 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10020 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10021 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10022 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10023 * v850-tdep.c (v850_gdbarch_init): Likewise.
10025 2017-05-24 Yao Qi <yao.qi@linaro.org>
10027 * selftest-arch.c (tests_with_arch): Call registers_changed
10028 and reinit_frame_cache.
10029 * selftest.c (run_self_tests): Likewise.
10031 2017-05-24 Yao Qi <yao.qi@linaro.org>
10033 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
10034 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
10036 2017-05-24 Yao Qi <yao.qi@linaro.org>
10038 * rl78-tdep.c (rl78_gdbarch_init): Don't call
10039 set_gdbarch_print_insn.
10041 2017-05-24 Yao Qi <yao.qi@linaro.org>
10043 * h8300-tdep.c (h8300_gdbarch_init): Don't call
10044 set_gdbarch_print_insn.
10046 2017-05-24 Yao Qi <yao.qi@linaro.org>
10048 * alpha-tdep.c (alpha_gdbarch_init): Don't call
10049 set_gdbarch_print_insn.
10050 * arc-tdep.c (arc_gdbarch_init): Likewise.
10051 * arch-utils.c: include dis-asm.h.
10052 (default_print_insn): New function.
10053 * arch-utils.h (default_print_insn): Declare.
10054 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
10055 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10056 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
10057 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
10058 * frv-tdep.c (frv_gdbarch_init): Likewise.
10059 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10060 * gdbarch.sh (print_insn): Use default_print_insn.
10061 * gdbarch.c: Regenerated.
10062 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
10063 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
10064 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10065 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
10066 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10067 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
10068 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
10069 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
10070 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
10071 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10072 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10073 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10074 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10075 * mt-tdep.c (mt_gdbarch_init): Likewise.
10076 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10077 * nios2-tdep.c (nios2_print_insn): Remove.
10078 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
10079 * rx-tdep.c (rx_gdbarch_init): Likewise.
10080 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10081 * score-tdep.c (score_print_insn): Remove.
10082 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
10083 * sh-tdep.c (sh_gdbarch_init): Likewise.
10084 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10085 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10086 * tic6x-tdep.c (tic6x_print_insn): Remove.
10087 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
10088 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
10089 * v850-tdep.c (v850_gdbarch_init): Likewise.
10090 * vax-tdep.c (vax_gdbarch_init): Likewise.
10091 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10092 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
10094 2017-05-23 John Baldwin <jhb@FreeBSD.org>
10096 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
10097 (MIPS_FP0_REGNUM): Remove.
10098 (MIPS_FSR_REGNUM): Remove.
10099 (mips_fbsd_supply_fpregs): Use mips_regnum.
10100 (mips_fbsd_supply_gregs): Likewise.
10101 (mips_fbsd_collect_fpregs): Likewise.
10102 (mips_fbsd_collect_gregs): Likewise.
10104 2017-05-23 John Baldwin <jhb@FreeBSD.org>
10106 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
10107 (getpfpregs_supplies): New function.
10108 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
10109 getfpregs_supplies.
10110 (mips_fbsd_store_inferior_registers): Likewise.
10112 2017-05-22 Pedro Alves <palves@redhat.com>
10114 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
10117 2017-05-22 Alan Hayward <alan.hayward@arm.com>
10119 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
10120 (store_register): Likewise.
10121 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
10122 (get_decimal_float_return_value): Likewise.
10123 (do_ppc_sysv_return_value): Likewise.
10124 (ppc64_sysv_abi_push_integer): Likewise.
10125 (ppc64_sysv_abi_push_freg): Likewise.
10126 (ppc64_sysv_abi_return_value_base): Likewise.
10127 (ppc64_sysv_abi_return_value): Likewise.
10128 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
10129 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
10130 * rs6000-nat.c: Likewise.
10131 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
10132 (rs6000_value_to_register): Likewise.
10133 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
10135 2017-05-21 Tom Tromey <tom@tromey.com>
10138 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
10139 arrays as "[T]", not "[T; ]".
10141 2017-05-19 Tom Tromey <tom@tromey.com>
10144 * rust-lang.c (exp_descriptor_rust): New function.
10145 (rust_language_defn): Use it.
10146 * p-lang.c (pascal_language_defn): Update.
10147 * opencl-lang.c (opencl_language_defn): Update.
10148 * objc-lang.c (objc_language_defn): Update.
10149 * m2-lang.c (m2_language_defn): Update.
10150 * language.h (struct language_defn)
10151 <la_watch_location_expression>: New member.
10152 * language.c (unknown_language_defn, auto_language_defn)
10153 (local_language_defn): Update.
10154 * go-lang.c (go_language_defn): Update.
10155 * f-lang.c (f_language_defn): Update.
10156 * d-lang.c (d_language_defn): Update.
10157 * c-lang.h (c_watch_location_expression): Declare.
10158 * c-lang.c (c_watch_location_expression): New function.
10159 (c_language_defn, cplus_language_defn, asm_language_defn)
10160 (minimal_language_defn): Use it.
10161 * breakpoint.c (watch_command_1): Call
10162 la_watch_location_expression.
10163 * ada-lang.c (ada_language_defn): Update.
10165 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10168 * gdb_curses.h (NOMACROS): Define.
10169 (NCURSES_NOMACROS): Define.
10171 2017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10174 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
10176 * tui/tui-wingeneral.c (box_win): Likewise.
10177 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
10178 (tui_show_source_line): Likewise.
10179 (tui_show_exec_info_content): Likewise.
10181 2017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
10183 * sparc-tdep.c (sparc_structure_return_p)
10184 (sparc_arg_on_registers_p): New functions.
10185 (sparc32_store_arguments): Use them.
10186 * sparc64-tdep.c (sparc64_16_byte_align_p)
10187 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
10188 Handle TYPE_CODE_ARRAY.
10190 2017-05-17 Yao Qi <yao.qi@linaro.org>
10192 * cli/cli-decode.c (add_alias_cmd): New function.
10193 * command.h (add_alias_cmd): Declare.
10194 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
10195 instead call add_alias_cmd.
10197 2017-05-17 Pedro Alves <palves@redhat.com>
10199 * Makefile.in (nat_extra_makefile_frag): Rename to ...
10200 (nat_makefile_frag): ... this. All references updated.
10201 * configure.ac: Likewise.
10202 * configure.nat: Likewise. Enhance comments.
10203 * configure: Regenerate.
10205 2017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10207 * procfs.c (procfs_create_inferior): Change prototype to match
10210 2017-05-13 Eli Zaretskii <eliz@gnu.org>
10212 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
10213 C++ compiler warning.
10215 2017-05-12 Tom Tromey <tom@tromey.com>
10218 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
10219 recurse, just call value_struct_elt directly.
10221 2017-05-12 Tom Tromey <tom@tromey.com>
10223 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
10224 OP_RUST_ARRAY>: Fix.
10226 2017-05-12 Tom Tromey <tom@tromey.com>
10228 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
10230 2017-05-09 Yao Qi <yao.qi@linaro.org>
10232 * regcache.c: Include <forward_list>.
10233 (struct regcache_list): Remove.
10234 (current_regcache): Update.
10235 (get_thread_arch_aspace_regcache): Update for std::forward_list.
10236 (regcache_thread_ptid_changed): Likewise.
10237 (registers_changed_ptid): Likewise.
10238 (current_regcache_size): Likewise.
10240 2017-05-09 Yao Qi <yao.qi@linaro.org>
10242 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
10243 (current_regcache_size): New function.
10244 (current_regcache_test): New function.
10245 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
10247 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10249 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
10250 (print_gp_register_row): Use get_frame_register_value.
10252 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10254 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
10255 (mips_supply_fpregset): Likewise.
10256 (mips64_supply_gregset): Likewise.
10258 2017-05-08 Alan Hayward <alan.hayward@arm.com>
10260 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
10261 regcache->raw_supply_zeroed.
10263 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10265 * configure.nat: Rearrange 'case' statements to match
10268 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10270 * Makefile.in: Remove "@host_makefile_frag@". Add variables
10271 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
10272 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
10273 "@nat_extra_makefile_frag@".
10274 (Makefile): Remove dependency on "@frags@".
10275 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
10276 (data-directory/Makefile): Likewise.
10277 * config/aarch64/linux.mh: Deleted; moved contents to
10278 "gdb/configure.nat".
10279 * config/alpha/alpha-linux.mh: Likewise.
10280 * config/alpha/nbsd.mh: Likewise.
10281 * config/arm/linux.mh: Likewise.
10282 * config/arm/nbsdelf.mh: Likewise.
10283 * config/i386/cygwin.mh: Likewise.
10284 * config/i386/cygwin64.mh: Likewise.
10285 * config/i386/darwin.mh: Likewise.
10286 * config/i386/fbsd.mh: Likewise.
10287 * config/i386/fbsd64.mh: Likewise.
10288 * config/i386/go32.mh: Likewise.
10289 * config/i386/i386gnu.mh: Likewise.
10290 * config/i386/i386sol2.mh: Likewise.
10291 * config/i386/linux.mh: Likewise.
10292 * config/i386/linux64.mh: Likewise.
10293 * config/i386/mingw.mh: Likewise.
10294 * config/i386/mingw64.mh: Likewise.
10295 * config/i386/nbsd64.mh: Likewise.
10296 * config/i386/nbsdelf.mh: Likewise.
10297 * config/i386/nto.mh: Likewise.
10298 * config/i386/obsd.mh: Likewise.
10299 * config/i386/obsd64.mh: Likewise.
10300 * config/i386/sol2-64.mh: Likewise.
10301 * config/ia64/linux.mh: Likewise.
10302 * config/m32r/linux.mh: Likewise.
10303 * config/m68k/linux.mh: Likewise.
10304 * config/m68k/nbsdelf.mh: Likewise.
10305 * config/m68k/obsd.mh: Likewise.
10306 * config/m88k/obsd.mh: Likewise.
10307 * config/mips/fbsd.mh: Likewise.
10308 * config/mips/linux.mh: Likewise.
10309 * config/mips/nbsd.mh: Likewise.
10310 * config/mips/obsd64.mh: Likewise.
10311 * config/pa/linux.mh: Likewise.
10312 * config/pa/nbsd.mh: Likewise.
10313 * config/pa/obsd.mh: Likewise.
10314 * config/powerpc/aix.mh: Likewise.
10315 * config/powerpc/fbsd.mh: Likewise.
10316 * config/powerpc/linux.mh: Likewise.
10317 * config/powerpc/nbsd.mh: Likewise.
10318 * config/powerpc/obsd.mh: Likewise.
10319 * config/powerpc/ppc64-linux.mh: Likewise.
10320 * config/powerpc/spu-linux.mh: Likewise.
10321 * config/s390/linux.mh: Likewise.
10322 * config/sh/nbsd.mh: Likewise.
10323 * config/sparc/fbsd.mh: Likewise.
10324 * config/sparc/linux.mh: Likewise.
10325 * config/sparc/linux64.mh: Likewise.
10326 * config/sparc/nbsd64.mh: Likewise.
10327 * config/sparc/nbsdelf.mh: Likewise.
10328 * config/sparc/obsd64.mh: Likewise.
10329 * config/sparc/sol2.mh: Likewise.
10330 * config/tilegx/linux.mh: Likewise.
10331 * config/vax/nbsdelf.mh: Likewise.
10332 * config/vax/obsd.mh: Likewise.
10333 * config/xtensa/linux.mh: Likewise.
10334 * config/i386/i386gnu.mn: New file, with excerpts from
10335 "config/i386/i386gnu.mh".
10336 * configure: Regenerate.
10337 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
10338 *.mh files under "gdb/config".
10339 * configure.nat: New file, with contents from the
10340 "gdb/config/*/*.mh" files.
10342 2017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
10344 * btrace.c (btrace_clear): Free insn vector.
10346 2017-05-05 Pedro Alves <palves@redhat.com>
10348 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
10349 * configure: Regenerate.
10351 2017-05-04 Pedro Alves <palves@redhat.com>
10353 * Makefile.in (SFILES): Add progspace-and-thread.c.
10354 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
10355 (COMMON_OBS): Add progspace-and-thread.o.
10356 * breakpoint.c: Include "progspace-and-thread.h".
10357 (update_inserted_breakpoint_locations)
10358 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
10359 Use scoped_restore_current_pspace_and_thread.
10360 (create_std_terminate_master_breakpoint): Use
10361 scoped_restore_current_program_space.
10362 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
10363 (print_breakpoint_location): Use
10364 scoped_restore_current_program_space.
10365 (bp_loc_is_permanent): Use
10366 scoped_restore_current_pspace_and_thread.
10367 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
10368 (download_tracepoint_locations): Use
10369 scoped_restore_current_pspace_and_thread.
10370 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
10371 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
10372 (enum step_over_calls_kind): Moved from inferior.h.
10373 (class scoped_restore_current_thread): New class.
10374 * gdbthread.h (make_cleanup_restore_current_thread): Delete
10376 (scoped_restore_current_thread): New class.
10377 * infcmd.c: Include "common/gdb_optional.h".
10378 (continue_1, proceed_after_attach): Use
10379 scoped_restore_current_thread.
10380 (notice_new_inferior): Use scoped_restore_current_thread.
10381 * inferior.c: Include "progspace-and-thread.h".
10382 (restore_inferior, save_current_inferior): Delete.
10383 (add_inferior_command, clone_inferior_command): Use
10384 scoped_restore_current_pspace_and_thread.
10385 * inferior.h (scoped_restore_current_inferior): New class.
10386 * infrun.c: Include "progspace-and-thread.h" and
10387 "common/gdb_optional.h".
10388 (follow_fork_inferior): Use
10389 scoped_restore_current_pspace_and_thread.
10390 (scoped_restore_exited_inferior): New class.
10391 (handle_vfork_child_exec_or_exit): Use
10392 scoped_restore_exited_inferior,
10393 scoped_restore_current_pspace_and_thread,
10394 scoped_restore_current_thread and scoped_restore.
10395 (fetch_inferior_event): Use scoped_restore_current_thread.
10396 * linespec.c (decode_line_full, decode_line_1): Use
10397 scoped_restore_current_program_space.
10398 * mi/mi-main.c: Include "progspace-and-thread.h".
10399 (exec_continue): Use scoped_restore_current_thread.
10400 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
10401 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
10402 * proc-service.c (ps_pglobal_lookup): Use
10403 scoped_restore_current_program_space.
10404 * progspace-and-thread.c: New file.
10405 * progspace-and-thread.h: New file.
10406 * progspace.c (release_program_space, clone_program_space): Use
10407 scoped_restore_current_program_space.
10408 (restore_program_space, save_current_program_space)
10409 (save_current_space_and_thread): Delete.
10410 (switch_to_program_space_and_thread): Moved to
10411 progspace-and-thread.c.
10412 * progspace.h (save_current_program_space)
10413 (save_current_space_and_thread): Delete declarations.
10414 (scoped_restore_current_program_space): New class.
10415 * remote.c (remote_btrace_maybe_reopen): Use
10416 scoped_restore_current_thread.
10417 * symtab.c: Include "progspace-and-thread.h".
10418 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
10419 * thread.c (print_thread_info_1): Use
10420 scoped_restore_current_thread.
10421 (struct current_thread_cleanup): Delete.
10422 (do_restore_current_thread_cleanup)
10423 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
10424 (scoped_restore_current_thread::~scoped_restore_current_thread):
10426 (make_cleanup_restore_current_thread): Rename/convert to ...
10427 (scoped_restore_current_thread::scoped_restore_current_thread):
10429 (thread_apply_all_command): Use scoped_restore_current_thread.
10430 (thread_apply_command): Use scoped_restore_current_thread.
10431 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
10432 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
10434 2017-05-04 Pedro Alves <palves@redhat.com>
10436 * thread.c (make_cleanup_restore_current_thread): Move
10437 find_thread_ptid call before the is_stopped call. Assert that the
10438 thread is found. Replace is_stopped call by checking the thread's
10439 state directly. Remove unnecessary NULL-thread check.
10441 2017-05-04 Pedro Alves <palves@redhat.com>
10443 * corelow.c (thread_section_name): New class.
10444 (get_core_register_section, get_core_siginfo): Use it.
10446 2017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
10448 * corelow.c (sniff_core_bfd): Remove extra semicolon.
10449 (get_core_register_section): Remove xfree of NULL pointer.
10451 2017-05-03 Alan Hayward <alan.hayward@arm.com>
10453 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
10454 * regcache.c (regcache::raw_supply_zeroed): New function.
10455 * regcache.h (regcache::raw_supply_zeroed): New declaration.
10457 2017-05-03 Simon Marchi <simon.marchi@ericsson.com>
10459 * gdbarch.sh: Remove commented out definition of
10461 * gdbarch.h: Re-generate.
10463 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
10465 * configure: Regenerate.
10467 2017-05-02 Simon Marchi <simon.marchi@ericsson.com>
10469 * solib-target.c (solib_target_relocate_section_addresses):
10470 Remove num_section_bases, num_bases, segment_bases variables.
10472 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10474 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
10476 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10478 * solib-target.c: Include <vector>
10479 (struct lm_info_target) <~lm_info_target>: Remove.
10480 <segment_bases, section_bases>: Change type to
10481 std::vector<CORE_ADDR>.
10482 (library_list_start_segment, library_list_start_section,
10483 library_list_end_library,
10484 solib_target_relocate_section_addresses): Adjust.
10486 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10488 * gdbarch.sh (software_single_step): Change return type to
10489 std::vector<CORE_ADDR>.
10490 * gdbarch.c, gdbarch.h: Re-generate.
10491 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
10493 (arm_deal_with_atomic_sequence_raw): Adjust.
10494 (thumb_get_next_pcs_raw): Adjust.
10495 (arm_get_next_pcs_raw): Adjust.
10496 (arm_get_next_pcs): Adjust.
10497 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
10498 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
10499 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
10500 (alpha_software_single_step): Adjust.
10501 * alpha-tdep.h (alpha_software_single_step): Adjust.
10502 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
10503 * arm-tdep.c (arm_software_single_step): Adjust.
10504 (arm_breakpoint_kind_from_current_state): Adjust.
10505 * arm-tdep.h (arm_software_single_step): Adjust.
10506 * breakpoint.c (insert_single_step_breakpoint): Adjust.
10507 * cris-tdep.c (cris_software_single_step): Adjust.
10508 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
10509 (micromips_deal_with_atomic_sequence): Adjust.
10510 (deal_with_atomic_sequence): Adjust.
10511 (mips_software_single_step): Adjust.
10512 * mips-tdep.h (mips_software_single_step): Adjust.
10513 * moxie-tdep.c (moxie_software_single_step): Adjust.
10514 * nios2-tdep.c (nios2_software_single_step): Adjust.
10515 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
10516 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
10517 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
10518 * s390-linux-tdep.c (s390_software_single_step): Adjust.
10519 * sparc-tdep.c (sparc_software_single_step): Adjust.
10520 * spu-tdep.c (spu_software_single_step): Adjust.
10521 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
10523 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10525 * gdbarch.sh: Use semi-colon as field separator instead of colon.
10526 * gdbarch.h: Re-generate.
10528 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10530 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
10531 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
10532 * python/py-instruction.c, python/py-instruction.h: New file.
10533 * python/py-record.c: Add py-instruction.h include.
10534 (gdbpy_initialize_record): Make gdb.Instruction a super class of
10535 gdb.RecordInstruction.
10536 * python/python-internal.h: Add gdbpy_initialize_instruction
10538 * python/python.c (do_start_initialization): Add
10539 gdbpy_initialize_instruction.
10541 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10543 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
10545 (btrace_func_from_recpy_func): New function.
10546 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
10547 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
10548 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
10549 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
10550 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
10551 Also, use new helper functions.
10552 (btpy_list_item): Use new helper functions.
10553 (recpy_bt_function_call_history): Use new type name.
10554 (btpy_call_getset): Remove.
10555 (gdbpy_initialize_btrace): Remove code to initialize
10556 gdb.BtraceFunctionCall.
10557 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
10558 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
10559 recpy_bt_func_prev, recpy_bt_func_next): New export.
10560 * python/py-record.c (recpy_func_type): New static object.
10561 (recpy_func_new, recpy_func_level, recpy_func_symbol,
10562 recpy_func_instructions, recpy_func_up, recpy_func_prev,
10563 recpy_func_next): New function.
10564 (recpy_element_hash, recpy_element_richcompare): Updated comment.
10565 (recpy_func_getset): New static object.
10566 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
10567 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
10569 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10571 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
10572 (btpy_object, btpy_insn_type, btpy_new): Remove.
10573 (btpy_list_object): Use gdb.RecordInstruction type instead of
10574 gdb.BtraceInstruction type.
10575 (btrace_insn_from_recpy_insn): New function.
10576 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
10578 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
10579 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
10580 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
10581 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
10582 instead of btpy_object.
10583 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10584 btpy_insn_data, btpy_insn_decode): Rename to ...
10585 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
10586 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
10587 recpy_bt_insn_decode): This. Also, use new helper functions.
10588 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
10590 (btpy_insn_getset): Remove.
10591 (gdbpy_initialize_btrace): Remove code to initialize
10592 gdb.BtraceInstruction. Use recpy_element_object.
10593 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
10594 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
10595 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
10596 * python/py-record.c (recpy_insn_type): New static object.
10597 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
10598 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
10599 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
10601 (recpy_insn_getset): New static object.
10602 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
10603 * python/py-record.h (recpy_element_object): New typedef.
10604 (recpy_insn_type, recpy_insn_new): New export.
10606 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10608 * py-record-btrace.c (btpy_insn_new): Removed.
10609 (btpy_insn_or_gap_new): New function.
10610 (btpy_insn_error): Removed.
10611 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10612 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
10613 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
10614 btpy_insn_or_gap_new instead of btpy_insn_new.
10615 (btpy_insn_getset): Remove btpy_insn_error.
10616 * py-record.c (recpy_gap_type): New static object.
10617 (recpy_gap_object): New typedef.
10618 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
10619 recpy_gap_reason_string): New function.
10620 (recpy_gap_getset): New static object.
10621 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
10622 * py-record.h (recpy_gap_new): New export.
10624 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10626 * python/py-record.c (recpy_ptid): Remove.
10627 (recpy_record_getset): Remove recpy_ptid.
10629 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10631 * btrace.c (btrace_fetch): Set inferior_ptid.
10632 * python/py-record-btrace.c: Add "py-record.h" include.
10633 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
10634 recpy_bt_end, recpy_bt_instruction_history,
10635 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
10636 in gdb.Record object instead of current ptid.
10637 * python/py-record.c: Include new "py-record.h" file.
10638 (recpy_record_object): Moved to py-record.h.
10639 * python/py-record.h: New file.
10641 2017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10643 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
10644 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
10647 2017-05-01 Joel Brobecker <brobecker@adacore.com>
10649 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
10650 the past maintainers section.
10652 2017-04-28 Yao Qi <yao.qi@linaro.org>
10654 * infcmd.c (get_return_value): Use regcache ctor, and remove
10657 2017-04-28 Yao Qi <yao.qi@linaro.org>
10658 Pedro Alves <palves@redhat.com>
10660 * regcache.c (regcache::regcache): New tag dispatch ctor.
10661 (do_cooked_read): Moved above.
10662 (regcache_dup): Use the tag dispatch ctor..
10663 * regcache.h (regcache): Declare ctor, delete copy ctor and
10664 assignment operator, remove friend regcache_dup.
10666 2017-04-28 Yao Qi <yao.qi@linaro.org>
10668 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
10669 call method save instead of regcache_cpy.
10670 * regcache.h (struct regcache): Make regcache_dup a friend.
10672 2017-04-28 Yao Qi <yao.qi@linaro.org>
10674 * regcache.c (struct regcache): Move to regcache.h
10675 (regcache::arch): New method.
10676 (regcache_get_ptid): Update.
10677 (get_regcache_arch): Call arch method.
10678 (get_regcache_aspace): Call method aspace.
10679 (register_buffer): Change it to method.
10680 (regcache_save): Change it to regcache::save.
10681 (regcache_restore): Likewise.
10682 (regcache_cpy_no_passthrough): Remove the declaration.
10683 (regcache_cpy): Call methods restore and cpy_no_passthrough.
10684 (regcache_cpy_no_passthrough): Change it to method
10685 cpy_no_passthrough.
10686 (regcache_register_status): Change it to method
10687 get_register_status.
10688 (regcache_invalidate): Change it to method invalidate.
10689 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
10690 (regcache_raw_update): Change it to method raw_update.
10691 (regcache_raw_read): Likewise.
10692 (regcache_raw_read_signed): Likewise.
10693 (regcache_raw_read_unsigned): Likewise.
10694 (regcache_raw_write_signed): Likewise.
10695 (regcache_raw_write_unsigned): Likewise.
10696 (regcache_cooked_read): Likewise.
10697 (regcache_cooked_read_value): Likewise.
10698 (regcache_cooked_read_signed): Likewise.
10699 (regcache_cooked_read_unsigned): Likewise.
10700 (regcache_cooked_write_signed): Likewise.
10701 (regcache_cooked_write_unsigned): Likewise.
10702 (regcache_raw_set_cached_value): Likewise.
10703 (regcache_raw_write): Likewise.
10704 (regcache_cooked_write): Likewise.
10705 (regcache_xfer_part): Likewise.
10706 (regcache_raw_read_part): Likewise.
10707 (regcache_raw_write_part): Likewise.
10708 (regcache_cooked_read_part): Likewise.
10709 (regcache_cooked_write_part): Likewise.
10710 (regcache_raw_supply): Likewise.
10711 (regcache_raw_collect): Likewise.
10712 (regcache_transfer_regset): Likewise.
10713 (regcache_supply_regset): Likewise.
10714 (regcache_collect_regset): Likewise.
10715 (regcache_debug_print_register): Likewise.
10716 (enum regcache_dump_what): Move it to regcache.h.
10717 (regcache_dump): Change it to method dump.
10718 * regcache.h (enum regcache_dump_what): New.
10719 (class regcache): New.
10720 * target.c (target_fetch_registers): Call method
10721 debug_print_register.
10722 (target_store_registers): Likewise.
10724 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10726 * windows-nat.c (struct lm_info_windows): Initialize field.
10727 (windows_make_so): Allocate lm_info_windows with new.
10728 (windows_free_so): Free lm_info_windows with delete.
10730 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10732 * solib-darwin.c (struct lm_info_darwin): Initialize field.
10733 (darwin_current_sos): Allocate lm_info_darwin with new, remove
10735 (darwin_free_so): Free lm_info_darwin with delete.
10737 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10739 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
10740 <l_addr_p>: Change type to bool.
10741 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
10742 (svr4_free_so): Free lm_info_svr4 with delete.
10743 (svr4_copy_library_list): Replace memcpy with call to copy
10745 (library_list_start_library, svr4_default_sos): Allocate
10746 lm_info_svr4 with new.
10748 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10750 * solib-target.c (struct lm_info_target): Add destructor,
10752 <name>: Change type to std::string.
10753 (library_list_start_library): Allocate lm_info_target with new.
10754 (solib_target_free_library_list): Free lm_info_target with
10756 (solib_target_current_sos): Adapt to std::string.
10757 (solib_target_free_so): Free lm_info_target with delete.
10759 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10761 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
10763 (frv_current_sos): Allocate lm_info_frv with new.
10764 (frv_relocate_main_executable): Free lm_info_frv with delete,
10766 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
10768 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10770 * solib-frv.c (struct lm_info_frv): Fix indentation.
10772 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10774 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
10776 (dsbt_current_sos): Allocate lm_info_dsbt with new.
10777 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
10778 and allocate with new.
10779 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
10781 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10783 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
10784 <filename, member_name>: Change type to std::string.
10785 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
10786 (library_list_start_library): Allocate lm_info_aix with new.
10787 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
10788 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
10789 with copy constructor.
10791 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10793 * solist.h (struct lm_info): Remove.
10794 (struct lm_info_base): New class.
10795 (struct so_list) <lm_info>: Change type to lm_info_base *.
10796 * nto-tdep.c (struct lm_info): Remove.
10798 * solib-aix.c (struct lm_info): Rename to ...
10799 (struct lm_info_aix): ... this. Extend lm_info_base.
10800 (lm_info_p): Rename to ...
10801 (lm_info_aix_p): ... this, and adjust.
10802 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
10803 solib_aix_parse_libraries, library_list_start_library,
10804 solib_aix_free_library_list, solib_aix_parse_libraries,
10805 solib_aix_get_library_list,
10806 solib_aix_relocate_section_addresses, solib_aix_free_so,
10807 solib_aix_get_section_offsets,
10808 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
10810 (struct solib_aix_inferior_data) <library_list>: Adjust.
10811 * solib-darwin.c (struct lm_info): Rename to ...
10812 (struct lm_info_darwin): ... this. Extend lm_info_base.
10813 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
10814 * solib-dsbt.c (struct lm_info): Rename to ...
10815 (struct lm_info_dsbt): ... this. Extend lm_info_base.
10816 (struct dsbt_info) <main_executable_lm_info): Adjust.
10817 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
10818 dsbt_relocate_section_addresses): Adjust.
10819 * solib-frv.c (struct lm_info): Rename to ...
10820 (struct lm_info_frv): ... this. Extend lm_info_base.
10821 (main_executable_lm_info): Adjust.
10822 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
10823 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
10824 find_canonical_descriptor_in_load_object,
10825 frv_fdpic_find_canonical_descriptor): Adjust.
10826 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
10828 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
10829 svr4_clear_so, svr4_copy_library_list,
10830 library_list_start_library, svr4_default_sos, svr4_read_so_list,
10831 svr4_current_sos, svr4_fetch_objfile_link_map,
10832 solist_update_incremental): Adjust.
10833 * solib-svr4.h (struct lm_info_svr4): Move here from
10835 * solib-target.c (struct lm_info): Rename to ...
10836 (struct lm_info_target): ... this. Extend lm_info_base.
10837 (lm_info_p): Rename to ...
10838 (lm_info_target_p): ... this.
10839 (solib_target_parse_libraries, library_list_start_segment,
10840 library_list_start_section, library_list_start_library,
10841 library_list_end_library, solib_target_free_library_list,
10842 solib_target_current_sos, solib_target_free_so,
10843 solib_target_relocate_section_addresses): Adjust.
10844 * windows-nat.c (struct lm_info): Rename to ...
10845 (struct lm_info_windows): ... this. Extend lm_info_base.
10846 (windows_make_so, handle_load_dll, handle_unload_dll,
10847 windows_xfer_shared_libraries): Adjust.
10849 2017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10851 * solib-darwin.c (struct darwin_so_list): Remove.
10852 (darwin_current_sos): Allocate an so_list object instead of a
10853 darwin_so_list, separately allocate an lm_info object.
10854 (darwin_free_so): Free lm_info.
10856 2017-04-28 John Baldwin <jhb@FreeBSD.org>
10858 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
10859 with fprintf_filtered.
10861 2017-04-28 Yao Qi <yao.qi@linaro.org>
10863 * regcache.c (regcache::regcache): New function.
10864 (regcache::~regcache): New function.
10865 (regcache_xmalloc_1): Remove.
10866 (regcache_xmalloc): Call new regcache.
10867 (regcache_xfree): Call delete regcache.
10868 (get_thread_arch_aspace_regcache): Call new regcache.
10870 2017-04-28 Yao Qi <yao.qi@linaro.org>
10872 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
10873 lwp instead of ptid_get_lwp.
10875 2017-04-28 Yao Qi <yao.qi@linaro.org>
10877 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
10878 lwp_info instead of getting from inferior_ptid.
10880 2017-04-27 Keith Seitz <keiths@redhat.com>
10882 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
10883 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
10884 (CV_CONVERSION_BADNESS): Define.
10885 (rank_one_type): Remove overly restrictive rvalue reference
10887 Add cv-qualifier checks and subranks for type equality.
10888 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
10889 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
10890 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
10892 2017-04-27 Simon Marchi <simon.marchi@ericsson.com>
10894 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
10895 count when creating the object.
10897 2017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
10898 Ulrich Weigand <uweigand@de.ibm.com>
10900 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
10901 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
10903 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
10904 (process_xcoff_symbol): Likewise.
10905 (scan_xcoff_symtab): Likewise.
10907 2017-04-26 Alan Hayward <alan.hayward@arm.com>
10909 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
10910 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
10911 (ia64_access_reg): Use get_frame_register_unsigned.
10912 (ia64_access_rse_reg): Likewise.
10913 (ia64_libunwind_frame_prev_register): Likewise.
10915 2017-04-26 Jiong Wang <jiong.wang@arm.com>
10917 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
10918 * gdbarch.c: Regenerated.
10919 * gdbarch.h: Regenerated.
10920 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
10921 visibility external.
10922 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
10923 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
10924 (enum cfa_how_kind): Move to ...
10925 (struct dwarf2_frame_state_reg_info): Likewise.
10926 (struct dwarf2_frame_state): Likewise.
10927 * dwarf2-frame.h: ... here.
10928 (dwarf2_frame_state_alloc_regs): New declaration.
10929 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
10930 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
10932 2017-04-26 Alan Hayward <alan.hayward@arm.com>
10934 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
10935 regcache_raw_read_unsigned.
10936 (xtensa_pseudo_register_write): Likewise.
10938 2017-04-26 Alan Hayward <alan.hayward@arm.com>
10940 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
10941 (nds32_pseudo_register_write): Likewise.
10943 2017-04-25 Yao Qi <yao.qi@linaro.org>
10945 * regcache.c (struct regcache) <readonly_p>: Change its type
10947 (regcache_xmalloc_1): Update parameter type and callers update.
10949 2017-04-25 Yao Qi <yao.qi@linaro.org>
10951 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
10952 set_gdbarch_wchar_bit.
10953 * arm-tdep.c (arm_gdbarch_init): Likewise.
10955 2017-04-25 Pedro Alves <palves@redhat.com>
10957 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
10958 (BothAreRelocatable, memcopy, memmove): Don't define.
10959 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
10962 2017-04-25 Pedro Alves <palves@redhat.com>
10964 * common/common-defs.h: Include "common/poison.h".
10965 * common/function-view.h: (Not, Or, Requires): Move to traits.h
10967 * common/poison.h: New file.
10968 * common/traits.h: Include <type_traits>.
10969 (Not, Or, Requires): New, moved from common/function-view.h.
10971 2017-04-25 Pedro Alves <palves@redhat.com>
10973 * breakpoint.h (struct breakpoint): In-class initialize all
10974 fields. Make boolean fields "bool".
10975 * breakpoint.c (init_raw_breakpoint_without_location): Remove
10976 memset call and initializations no longer necessary.
10978 2017-04-25 Pedro Alves <palves@redhat.com>
10980 * btrace.c (pt_btrace_insn_flags): Change parameter type to
10982 (pt_btrace_insn): New function.
10983 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
10985 2017-04-25 Pedro Alves <palves@redhat.com>
10987 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
10988 "base" field and inherit from "bp_location" instead. Add
10990 (allocate_location_exception): Use new non-default ctor.
10991 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
10992 (init_bp_location): Convert to ...
10993 (bp_location::bp_location): ... this new ctor, and remove memset
10995 (base_breakpoint_allocate_location): Use the new non-default ctor.
10996 * breakpoint.h (bp_location): Now a class. Declare default and
10997 non-default ctors. In-class initialize all members.
10998 (init_bp_location): Remove declaration.
11000 2017-04-25 Pedro Alves <palves@redhat.com>
11002 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
11003 assignment operator.
11005 2017-04-24 Yao Qi <yao.qi@linaro.org>
11007 * doublest.c (convert_doublest_to_floatformat): Call
11008 floatformat_totalsize_bytes.
11010 2017-04-22 Tom Tromey <tom@tromey.com>
11012 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
11014 * stack.c (print_frame): Use ui_out_emit_list.
11015 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11017 * mi/mi-main.c (print_one_inferior)
11018 (mi_cmd_data_list_register_names)
11019 (mi_cmd_data_list_register_values, mi_cmd_list_features)
11020 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
11022 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
11023 (mi_output_solib_attribs): Use ui_out_emit_list,
11025 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
11026 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
11027 (mi_cmd_stack_list_args, list_args_or_locals): Use
11029 * disasm.c (do_assembly_only): Use ui_out_emit_list.
11030 * breakpoint.c (print_solib_event, output_thread_groups): Use
11033 2017-04-22 Tom Tromey <tom@tromey.com>
11035 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
11036 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
11037 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
11039 2017-04-22 Tom Tromey <tom@tromey.com>
11041 * tracepoint.c (tvariables_info_1)
11042 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
11044 2017-04-22 Tom Tromey <tom@tromey.com>
11046 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
11047 annotate_arg_emitter.
11048 * breakpoint.c (print_mention_watchpoint)
11049 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
11050 * annotate.h (struct annotate_arg_emitter): New.
11052 2017-04-22 Tom Tromey <tom@tromey.com>
11054 * record-btrace.c (record_btrace_insn_history)
11055 (record_btrace_insn_history_range, record_btrace_call_history)
11056 (record_btrace_call_history_range): Use ui_out_emit_tuple.
11057 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
11059 * stack.c (print_frame_info): Use ui_out_emit_tuple.
11060 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
11061 * skip.c (skip_info): Use ui_out_emit_tuple.
11062 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
11063 * progspace.c (print_program_space): Use ui_out_emit_tuple.
11064 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
11065 * osdata.c (info_osdata): Use ui_out_emit_tuple.
11066 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11068 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
11069 (output_register, mi_cmd_data_read_memory)
11070 (mi_cmd_data_read_memory_bytes, mi_load_progress)
11071 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
11072 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
11073 Use ui_out_emit_tuple.
11074 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
11076 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11077 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
11078 * linux-thread-db.c (info_auto_load_libthread_db): Use
11080 * inferior.c (print_inferior): Use ui_out_emit_tuple.
11081 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
11082 * disasm.c (do_mixed_source_and_assembly_deprecated)
11083 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
11084 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
11085 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
11086 * breakpoint.c (print_one_breakpoint_location)
11087 (print_one_breakpoint): Use ui_out_emit_tuple.
11088 * auto-load.c (print_script, info_auto_load_cmd): Use
11090 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
11092 2017-04-21 Simon Marchi <simon.marchi@ericsson.com>
11094 * thread.c (print_thread_info_1): Remove dead code.
11096 2017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11098 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
11100 * arm-tdep.c (selftests::arm_record_test): Likewise.
11102 2017-04-21 Yao Qi <yao.qi@linaro.org>
11104 * regcache.c (regcache_restore): Remove argument 2. Replace
11105 argument 3 with regcache. Get register status from
11106 src->register_status and get register contents from
11107 register_buffer (src, regnum).
11108 (regcache_cpy): Update.
11110 2017-04-19 Pedro Alves <palves@redhat.com>
11112 * gdbthread.h (thread): Add missing closing parenthesis in
11115 2017-04-19 Pedro Alves <palves@redhat.com>
11117 * common/refcounted-object.h: New file.
11118 * gdbthread.h: Include "common/refcounted-object.h".
11119 (thread_info): Inherit from refcounted_object and add comments.
11120 (thread_info::incref, thread_info::decref)
11121 (thread_info::m_refcount): Delete.
11122 (thread_info::deletable): Use the refcounted_object::refcount()
11124 * inferior.c (current_inferior_): Add comment.
11125 (set_current_inferior): Increment/decrement refcounts.
11126 (prune_inferiors, remove_inferior_command): Skip inferiors marked
11127 not-deletable instead of comparing with the current inferior.
11128 (initialize_inferiors): Increment the initial inferior's refcount.
11129 * inferior.h (struct inferior): Forward declare.
11130 Include "common/refcounted-object.h".
11131 (current_inferior, set_current_inferior): Move declaration to
11132 before struct inferior's definition, and fix comment.
11133 (inferior): Inherit from refcounted_object. Add comments.
11134 * thread.c (switch_to_thread_no_regs): Reference the thread's
11135 inferior pointer directly instead of doing a ptid lookup.
11136 (switch_to_no_thread): New function.
11137 (switch_to_thread(thread_info *)): New function, factored out
11139 (switch_to_thread(ptid_t)): ... this.
11140 (restore_current_thread): Delete.
11141 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
11142 fields, and add 'inf' field.
11143 (do_restore_current_thread_cleanup): Check whether old->inf is
11144 alive instead of looking up an inferior by ptid. Use
11145 switch_to_thread and switch_to_no_thread.
11146 (restore_current_thread_cleanup_dtor): Use old->inf directly
11147 instead of lookup up an inferior by id. Decref the inferior.
11148 Don't restore 'removable'.
11149 (make_cleanup_restore_current_thread): Same the inferior pointer
11150 in old, instead of the inferior number. Incref the inferior.
11151 Don't save/clear 'removable'.
11153 2017-04-19 Pedro Alves <palves@redhat.com>
11155 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11156 unittests/scoped_restore-selftests.c.
11157 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
11158 * common/scoped_restore.h (scoped_restore_base): Make "class".
11159 (scoped_restore_base::release): New public method.
11160 (scoped_restore_base::scoped_restore_base): New protected ctor.
11161 (scoped_restore_base::m_saved_var): New protected field.
11162 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
11163 scoped_restore_base base class instead of m_saved_var directly.
11164 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
11165 (scoped_restore_tmpl::scoped_restore_tmpl(const
11166 scoped_restore_tmpl<T>&)): Likewise.
11167 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
11169 (scoped_restore_tmpl::saved_var): New method.
11170 (scoped_restore_tmpl::m_saved_var): Delete.
11171 * inferior.h (inferior::detaching): Now a bool.
11172 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
11174 * unittests/scoped_restore-selftests.c: New file.
11176 2017-04-19 Pedro Alves <palves@redhat.com>
11178 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
11179 Re-sort in alphabetic order.
11181 2017-04-18 Pedro Alves <palves@redhat.com>
11183 * xml-support.c (obstack_xml_printf): Delete.
11184 * xml-support.h (obstack_xml_printf): Delete.
11186 2017-04-18 Pedro Alves <palves@redhat.com>
11188 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
11189 vdebug, verror, body_text, start_element, end_element, name,
11190 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
11191 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
11192 is_xinclude>: Make private and add m_ prefix.
11193 (gdb_xml_parser::body_text): New method, based on ...
11194 (gdb_xml_body_text): ... this. Adjust.
11195 (gdb_xml_parser::vdebug): New method, based on ...
11196 (gdb_xml_debug): ... this. Adjust.
11197 (gdb_xml_parser::verror): New method, based on ...
11198 (gdb_xml_error): ... this. Adjust.
11199 (gdb_xml_parser::start_element): New method, based on ...
11200 (gdb_xml_start_element): ... this. Adjust.
11201 (gdb_xml_start_element_wrapper): Defer to
11202 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
11203 (gdb_xml_parser::end_element): New method, based on ...
11204 (gdb_xml_end_element_wrapper): ... this. Adjust.
11205 (gdb_xml_parser::~gdb_xml_parser): Adjust.
11206 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
11207 (gdb_xml_parser::use_dtd): New method, based on ...
11208 (gdb_xml_use_dtd): ... this. Adjust.
11209 (gdb_xml_parser::parse): New method, based on ...
11210 (gdb_xml_parse): ... this. Adjust.
11211 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
11212 (xinclude_start_include): Adjust to call the parser's name method.
11213 (xml_xinclude_default, xml_xinclude_start_doctype)
11214 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
11216 (xml_process_xincludes): Adjust to call parser methods.
11217 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
11220 2017-04-18 Pedro Alves <palves@redhat.com>
11222 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
11223 gdb::optional<std::string>.
11224 * xml-support.c: Include <string>.
11225 (scope_level::scope_level(scope_level &&))
11226 (scope_level::~scope_level): Delete.
11227 (scope_level::body): Now a std::string.
11228 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
11229 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
11231 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
11232 (xinclude_parsing_data::output): Now a std::string reference.
11233 (xinclude_start_include): Adjust.
11234 (xml_xinclude_default): Adjust.
11235 (xml_process_xincludes): Add 'output' parameter, and return bool.
11236 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
11238 * xml-tdesc.c: Include <unordered_map> and <string>.
11239 (tdesc_xml_cache): Delete.
11240 (tdesc_xml_cache_s): Delete.
11241 (xml_cache): Now an std::unordered_map.
11242 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
11243 (target_fetch_description_xml): Change return type to
11244 gdb::optional<std::string>, and adjust.
11245 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
11246 (target_fetch_description_xml): Change return type to
11247 gdb::optional<std::string>.
11249 2017-04-18 Pedro Alves <palves@redhat.com>
11251 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11252 unittests/optional-selftests.c.
11253 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
11254 * unittests/optional-selftests.c: New file.
11255 * unittests/optional/assignment/1.cc: New file.
11256 * unittests/optional/assignment/2.cc: New file.
11257 * unittests/optional/assignment/3.cc: New file.
11258 * unittests/optional/assignment/4.cc: New file.
11259 * unittests/optional/assignment/5.cc: New file.
11260 * unittests/optional/assignment/6.cc: New file.
11261 * unittests/optional/assignment/7.cc: New file.
11262 * unittests/optional/cons/copy.cc: New file.
11263 * unittests/optional/cons/default.cc: New file.
11264 * unittests/optional/cons/move.cc: New file.
11265 * unittests/optional/cons/value.cc: New file.
11266 * unittests/optional/in_place.cc: New file.
11267 * unittests/optional/observers/1.cc: New file.
11268 * unittests/optional/observers/2.cc: New file.
11270 2017-04-18 Pedro Alves <palves@redhat.com>
11272 * common/gdb_optional.h: Include common/traits.h.
11273 (in_place_t): New type.
11274 (in_place): New constexpr variable.
11275 (optional::optional): Remove member initialization of
11277 (optional::optional(in_place_t...)): New constructor.
11278 (optional::~optional): Use reset.
11279 (optional::optional(const optional&)): New.
11280 (optional::optional(const optional&&)): New.
11281 (optional::optional(T &)): New.
11282 (optional::optional(T &&)): New.
11283 (operator::operator=(const optional &)): New.
11284 (operator::operator=(optional &&)): New.
11285 (operator::operator= (const T &))
11286 (operator::operator= (T &&))
11287 (operator::emplace (Args &&... args)): Return a T&. Use reset.
11288 (operator::reset): New.
11289 (operator::m_instantiated):: Add in-class initializer.
11290 * common/traits.h: Include <type_traits>.
11291 (struct And): New types.
11293 2017-04-18 Pedro Alves <palves@redhat.com>
11295 * xml-support.c: Include <vector>.
11296 (scope_level::scope_level(const gdb_xml_element *))
11297 (scope_level::scope_level(scope_level&&)): New.
11298 (scope_level::~scope_level): New.
11299 (scope_level_s): Delete.
11300 (gdb_xml_parser::scopes): Now a std::vector.
11301 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
11303 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
11304 scope cleanup code.
11305 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
11306 of the scopes member. Use std::vector::emplace_back.
11308 2017-04-18 Pedro Alves <palves@redhat.com>
11310 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
11312 (gdb_xml_end_element): Change type of first parameter.
11313 (gdb_xml_cleanup): Rename to ...
11314 (gdb_xml_parser::~gdb_xml_parser): ... this.
11315 (gdb_xml_create_parser_and_cleanup): Delete with ...
11316 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
11318 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
11319 using gdb_xml_create_parser_and_cleanup.
11320 (xinclude_parsing_data): Add ctor/dtor.
11321 (xml_xinclude_cleanup): Delete.
11322 (xml_process_xincludes): Create a local xinclude_parsing_data
11323 instead of heap-allocating one. Create a local gdb_xml_parser
11324 instead of heap-allocating one with
11325 gdb_xml_create_parser_and_cleanup.
11327 2017-04-18 John Baldwin <jhb@FreeBSD.org>
11330 * fbsd-nat.c (resume_one_thread_cb): Remove.
11331 (resume_all_threads_cb): Remove.
11332 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
11333 iterate_over_threads.
11335 2017-04-17 Joel Brobecker <brobecker@adacore.com>
11337 * NEWS: Create a new section for the next release branch.
11338 Rename the section of the current branch, now that it has
11341 2017-04-17 Joel Brobecker <brobecker@adacore.com>
11343 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
11344 * version.in: Bump version to 8.0.50.DATE-git.
11346 2017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
11349 * windows-nat.c (windows_create_inferior): Declare 'allargs'
11350 independently of the host, and fix build breakage on Cygwin.
11352 2017-04-13 Pedro Alves <palves@redhat.com>
11354 * inferior.c (free_inferior): Convert to ...
11355 (inferior::~inferior): ... this dtor.
11356 (inferior::inferior): New ctor, factored out from ...
11357 (add_inferior_silent): ... here. Allocate the inferior with a new
11359 (delete_inferior): Call delete instead of free_inferior.
11360 * inferior.h (gdb_environ, continuation): Forward declare.
11361 (inferior): Now a class. Add in-class initialization to all
11362 members. Make boolean fields bool, except 'detaching'.
11363 (inferior::inferior): New explicit ctor.
11364 (inferior::~inferior): New.
11366 2017-04-13 Pedro Alves <palves@redhat.com>
11368 * inferior.c (init_inferior_list): Delete.
11369 * inferior.h (init_inferior_list): Delete.
11371 2017-04-13 Pedro Alves <palves@redhat.com>
11374 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
11375 (top level): Call it twice, with different thread sets.
11377 2017-04-13 Pedro Alves <palves@redhat.com>
11379 * thread.c: Include <algorithm>.
11380 (thread_array_cleanup): Delete.
11381 (scoped_inc_dec_ref): New class.
11382 (live_threads_count): New function.
11383 (set_thread_refcount): Delete.
11384 (tp_array_compar_ascending): Now a bool.
11385 (tp_array_compar): Convert to a std::sort comparison function.
11386 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
11387 and live_threads_count.
11389 2017-04-13 Pedro Alves <palves@redhat.com>
11391 * infrun.c (follow_fork_inferior): Also switch the current
11394 2017-04-13 Pedro Alves <palves@redhat.com>
11396 * breakpoint.c (watch_command_1): Save watchpoint-frame info
11397 before calling create_internal_breakpoint.
11399 2017-04-13 Pedro Alves <palves@redhat.com>
11401 * fork-child.c (execv_argv): New class.
11402 (breakup_args): Refactored as ...
11403 (execv_argv::init_for_no_shell): .. this method of execv_argv.
11404 Copy arguments to storage and replace separators with NULL
11405 terminators in place.
11406 (escape_bang_in_quoted_argument): Adjust to return bool.
11407 (execv_argv::execv_argv): New ctor.
11408 (execv_argv::init_for_shell): New method, factored out from
11409 fork_inferior. Don't strdup strings into the vector.
11410 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
11411 Remove free_vector_argv call.
11413 2017-04-13 Yao Qi <yao.qi@linaro.org>
11415 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
11418 2017-04-13 Yao Qi <yao.qi@linaro.org>
11420 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
11421 * rx-tdep.c (rx_gdbarch_init): Likewise.
11423 2017-04-13 Pedro Alves <palves@redhat.com>
11425 * breakpoint.h (struct breakpoint): Reindent.
11427 2017-04-13 Pedro Alves <palves@redhat.com>
11429 * breakpoint.c (bp_location): Rename to ...
11430 (bp_locations): ... this. All references updated.
11431 (bp_location_count): Rename to ...
11432 (bp_locations_count): ... this. All references updated.
11433 (bp_location_placed_address_before_address_max): Rename to ...
11434 (bp_locations_placed_address_before_address_max): ... this. All
11435 references updated.
11436 (bp_location_shadow_len_after_address_max): Rename to ...
11437 (bp_locations_shadow_len_after_address_max): ... this. All
11438 references updated.
11439 (bp_location_compare_addrs): Rename to ...
11440 (bp_locations_compare_addrs): ... this. All references updated.
11441 (bp_location_compare):Rename to ...
11442 (bp_locations_compare): ... this. All references updated.
11443 (bp_location_target_extensions_update): Rename to ...
11444 (bp_locations_target_extensions_update): ... this. All references
11447 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11449 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
11450 * common/common.m4: Check headers 'termios.h', 'termio.h' and
11452 * common/gdb_termios.h: New file, with parts of "terminal.h".
11453 * inflow.c: Include "gdb_termios.h".
11454 * ser-unix.c: Include "gdb_termios.h".
11455 * terminal.h: Move terminal-related defines to
11456 "common/gdb_termios.h".
11458 2017-04-12 Tom Tromey <tom@tromey.com>
11460 * probe.c (parse_probes): Update.
11461 * location.h (delete_event_location): Don't declare.
11462 (event_location_deleter::operator()): Update.
11463 * location.c (event_location_deleter::operator()): Rename from
11464 delete_event_location.
11465 * linespec.h (linespec_result) <location>: Change type to
11467 * linespec.c (canonicalize_linespec, event_location_to_sals)
11468 (decode_objc): Update.
11469 (linespec_result): Don't call delete_event_location.
11470 * breakpoint.c (create_breakpoints_sal)
11471 (bkpt_probe_create_sals_from_location)
11472 (strace_marker_create_sals_from_location): Update.
11474 2017-04-12 Tom Tromey <tom@tromey.com>
11476 * linespec.h (struct linespec_result): Add constructor and
11478 (init_linespec_result, destroy_linespec_result)
11479 (make_cleanup_destroy_linespec_result): Don't declare.
11480 * linespec.c (init_linespec_result): Remove.
11481 (linespec_result::~linespec_result): Rename from
11482 destroy_linespec_result. Update.
11483 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
11485 * breakpoint.c (create_breakpoint, break_range_command)
11486 (decode_location_default): Update.
11487 * ax-gdb.c (agent_command_1): Update.
11489 2017-04-12 Tom Tromey <tom@tromey.com>
11491 * remote.c (remote_download_tracepoint): Update.
11492 * python/py-breakpoint.c (bppy_get_location): Update.
11493 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
11494 (gdbscm_breakpoint_location): Update.
11495 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
11496 * breakpoint.h (struct breakpoint) <location, location_range_end>:
11497 Change type to event_location_up.
11498 * breakpoint.c (create_overlay_event_breakpoint)
11499 (create_longjmp_master_breakpoint)
11500 (create_std_terminate_master_breakpoint)
11501 (create_exception_master_breakpoint)
11502 (breakpoint_event_location_empty_p, print_breakpoint_location)
11503 (print_one_breakpoint_location, create_thread_event_breakpoint)
11504 (init_breakpoint_sal, create_breakpoint)
11505 (print_recreate_ranged_breakpoint, break_range_command)
11506 (init_ada_exception_breakpoint, say_where): Update.
11507 (base_breakpoint_dtor): Don't call delete_event_location.
11508 (bkpt_print_recreate, tracepoint_print_recreate)
11509 (dprintf_print_recreate, update_static_tracepoint)
11510 (breakpoint_re_set_default): Update.
11512 2017-04-12 Tom Tromey <tom@tromey.com>
11514 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
11515 type of "to_do". Update.
11516 (compute_stack_depth): Use std::vector.
11518 2017-04-12 Tom Tromey <tom@tromey.com>
11520 * printcmd.c (find_instruction_backward): Use std::vector.
11522 2017-04-12 Tom Tromey <tom@tromey.com>
11524 * symfile.c (objfilep): Remove typedef.
11525 (reread_symbols): Use a std::vector.
11527 2017-04-12 Tom Tromey <tom@tromey.com>
11529 * mi/mi-main.c (exec_direction_forward): Remove.
11530 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
11531 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
11533 * guile/guile.c (guile_repl_command, guile_command)
11534 (gdbscm_execute_gdb_command): Use scoped_restore.
11535 * go-exp.y (go_parse): Use scoped_restore.
11536 * d-exp.y (d_parse): Use scoped_restore.
11537 * cli/cli-decode.c (cmd_func): Use scoped_restore.
11538 * c-exp.y (c_parse): Use scoped_restore.
11540 2017-04-12 Tom Tromey <tom@tromey.com>
11542 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
11543 (mi_parse): Update return type.
11544 (mi_parse_free): Remove.
11545 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
11546 (mi_parse::~mi_parse): Rename from mi_parse_free.
11547 (mi_parse_cleanup): Remove.
11548 (mi_parse): Return a unique_ptr. Use new.
11549 * mi/mi-main.c (mi_execute_command): Update.
11551 2017-04-12 Tom Tromey <tom@tromey.com>
11553 * location.c (explicit_location_lex_one): Return a
11554 unique_xmalloc_ptr.
11555 (string_to_explicit_location): Update. Remove cleanups.
11557 2017-04-12 Tom Tromey <tom@tromey.com>
11559 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
11560 (compare_value_and_voffset): Change type. Update.
11561 (compute_vtable_size): Change type of "offset_vec".
11562 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
11563 (gnuv3_get_typeid): Remove extraneous declaration.
11565 2017-04-12 Tom Tromey <tom@tromey.com>
11567 * charset.h (wchar_iterator): Fix comment.
11569 2017-04-12 Tom Tromey <tom@tromey.com>
11571 * charset.c (iconv_wrapper): New class.
11572 (cleanup_iconv): Remove.
11573 (convert_between_encodings): Use it.
11575 2017-04-12 Tom Tromey <tom@tromey.com>
11577 * symfile.h (increment_reading_symtab): Update type.
11578 * symfile.c (decrement_reading_symtab): Remove.
11579 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
11580 * psymtab.c (psymtab_to_symtab): Update.
11581 * dwarf2read.c (dw2_instantiate_symtab): Update.
11583 2017-04-12 Tom Tromey <tom@tromey.com>
11585 * jit.c (struct jit_reader): Declare separately. Add constructor
11586 and destructor. Change type of "handle".
11587 (loaded_jit_reader): Define separately.
11588 (jit_reader_load): Update. New "new".
11589 (jit_reader_unload_command): Use "delete".
11590 * gdb-dlfcn.h (struct dlclose_deleter): New.
11591 (gdb_dlhandle_up): New typedef.
11592 (gdb_dlopen, gdb_dlsym): Update types.
11593 (gdb_dlclose): Remove.
11594 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
11595 (gdb_dlsym): Change type of "handle".
11596 (make_cleanup_dlclose): Remove.
11597 (dlclose_deleter::operator()): Rename from gdb_dlclose.
11598 * compile/compile-c-support.c (load_libcc): Update.
11600 2017-04-12 Tom Tromey <tom@tromey.com>
11602 * symtab.h (find_pcs_for_symtab_line): Change return type.
11603 * symtab.c (find_pcs_for_symtab_line): Change return type.
11604 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
11605 type of "vec". Update.
11606 (ltpy_get_pcs_for_line): Update.
11607 * linespec.c (decode_digits_ordinary): Update.
11609 2017-04-12 Tom Tromey <tom@tromey.com>
11611 * tracepoint.c (actions_command): Update.
11612 * python/python.c (python_command, python_interactive_command):
11614 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
11615 * guile/guile.c (guile_command): Update.
11616 * defs.h (read_command_lines, read_command_lines_1): Return
11618 (command_lines_deleter): New struct.
11619 (command_line_up): New typedef.
11620 * compile/compile.c (compile_code_command)
11621 (compile_print_command): Update.
11622 * cli/cli-script.h (get_command_line, copy_command_lines): Return
11624 (make_cleanup_free_command_lines): Remove.
11625 * cli/cli-script.c (get_command_line, read_command_lines_1)
11626 (copy_command_lines): Return command_line_up.
11627 (while_command, if_command, read_command_lines, define_command)
11628 (document_command): Update.
11629 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
11631 * breakpoint.h (breakpoint_set_commands): Change type of
11633 * breakpoint.c (breakpoint_set_commands): Change type of
11634 "commands". Update.
11635 (do_map_commands_command, update_dprintf_command_list)
11636 (create_tracepoint_from_upload): Update.
11638 2017-04-12 Tom Tromey <tom@tromey.com>
11640 * tracepoint.c (scope_info): Update.
11641 * spu-tdep.c (spu_catch_start): Update.
11642 * python/python.c (gdbpy_decode_line): Update.
11643 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
11644 * python/py-breakpoint.c (bppy_init): Update.
11645 * probe.c (parse_probes): Update.
11646 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
11647 * location.h (event_location_deleter): New struct.
11648 (event_location_up): New typedef.
11649 (new_linespec_location, new_address_location, new_probe_location)
11650 (new_explicit_location, copy_event_location)
11651 (string_to_event_location, string_to_event_location_basic)
11652 (string_to_explicit_location): Update return type.
11653 (make_cleanup_delete_event_location): Remove.
11654 * location.c (new_linespec_location, new_address_location)
11655 (new_probe_location, new_explicit_location, copy_event_location):
11656 Return event_location_up.
11657 (delete_event_location_cleanup)
11658 (make_cleanup_delete_event_location): Remove.
11659 (string_to_explicit_location, string_to_event_location_basic)
11660 (string_to_event_location): Return event_location_up.
11661 * linespec.c (canonicalize_linespec, event_location_to_sals)
11662 (decode_line_with_current_source)
11663 (decode_line_with_last_displayed, decode_objc): Update.
11664 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
11665 * completer.c (location_completer): Update.
11666 * cli/cli-cmds.c (edit_command, list_command): Update.
11667 * breakpoint.c (create_overlay_event_breakpoint)
11668 (create_longjmp_master_breakpoint)
11669 (create_std_terminate_master_breakpoint)
11670 (create_exception_master_breakpoint)
11671 (create_thread_event_breakpoint): Update.
11672 (init_breakpoint_sal): Update. Remove some dead code.
11673 (create_breakpoint_sal): Change type of "location". Update.
11674 (create_breakpoints_sal, create_breakpoint, break_command_1)
11675 (dprintf_command, break_range_command, until_break_command)
11676 (init_ada_exception_breakpoint)
11677 (strace_marker_create_sals_from_location)
11678 (update_static_tracepoint, trace_command, ftrace_command)
11679 (strace_command, create_tracepoint_from_upload): Update.
11680 * break-catch-throw.c (re_set_exception_catchpoint): Update.
11681 * ax-gdb.c (agent_command_1): Update.
11683 2017-04-12 Pedro Alves <palves@redhat.com>
11685 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
11686 * configure.tgt: Handle i[34567]86-*-go32* and
11687 i[34567]86-*-msdosdjgpp*.
11688 * i386-tdep.c (i386_svr4_reg_to_regnum):
11690 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
11692 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
11693 * i386-go32-tdep.c: New file.
11694 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
11697 2017-04-12 Simon Marchi <simon.marchi@ericsson.com>
11699 * aix-thread.c (pd_status2str): Change return type to const char *.
11701 2017-04-12 Pedro Alves <palves@redhat.com>
11703 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
11704 calls to set_gdbarch_gnu_triplet_regexp.
11706 2017-04-12 Pedro Alves <palves@redhat.com>
11709 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
11711 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
11712 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
11713 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
11714 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
11715 * gdbarch.h, gdbarch.c: Regenerate.
11716 * aarch64-tdep.c (aarch64_gdbarch_init): Override
11717 gdbarch_wchar_bit and gdbarch_wchar_signed.
11718 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
11719 * arm-tdep.c (arm_gdbarch_init): Likewise.
11720 * avr-tdep.c (avr_gdbarch_init): Likewise.
11721 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
11722 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
11723 * i386-tdep.c (i386_go32_init_abi): Likewise.
11724 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11725 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11726 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11727 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11728 * sh-tdep.c (sh_gdbarch_init): Likewise.
11729 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11730 * sparc64-tdep.c (sparc64_init_abi): Likewise.
11731 * windows-tdep.c (windows_init_abi): Likewise.
11732 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11734 2017-04-12 Pedro Alves <palves@redhat.com>
11737 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
11738 cplus_primitive_type_char32_t>: New enum values.
11739 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
11740 and cplus_primitive_type_char32_t.
11741 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
11742 32, use the archtecture's built-in type for char16_t and char32_t,
11743 respectively. Otherwise, fallback to init_integer_type as before,
11744 but make the type unsigned, and issue a complaint.
11745 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
11747 2017-04-12 Alan Hayward <alan.hayward@arm.com>
11749 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
11750 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
11752 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11754 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
11757 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11759 * common/common-utils.c (free_vector_argv): New function.
11760 * common/common-utils.h: Include <vector>.
11761 (free_vector_argv): New prototype.
11762 * darwin-nat.c (darwin_create_inferior): Rewrite function
11763 prototype in order to constify "exec_file" and accept a
11764 "std::string" for "allargs".
11765 * fork-child.c: Include <vector>.
11766 (breakup_args): Rewrite function, using C++.
11767 (fork_inferior): Rewrite function header, constify "exec_file_arg"
11768 and accept "std::string" for "allargs". Update the code to
11769 calculate "argv" based on "allargs". Update calls to "exec_fun"
11771 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
11772 order to constify "exec_file" and accept a "std::string" for
11774 * go32-nat.c (go32_create_inferior): Likewise.
11775 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
11776 * infcmd.c (run_command_1): Constify "exec_file". Use
11777 "std::string" for inferior arguments.
11778 * inferior.h (fork_inferior): Update prototype.
11779 * linux-nat.c (linux_nat_create_inferior): Rewrite function
11780 prototype in order to constify "exec_file" and accept a
11781 "std::string" for "allargs".
11782 * nto-procfs.c (procfs_create_inferior): Likewise.
11783 * procfs.c (procfs_create_inferior): Likewise.
11784 * remote-sim.c (gdbsim_create_inferior): Likewise.
11785 * remote.c (extended_remote_run): Update code to accept
11786 "std::string" as argument.
11787 (extended_remote_create_inferior): Rewrite function prototype in
11788 order to constify "exec_file" and accept a "std::string" for
11790 * rs6000-nat.c (super_create_inferior): Likewise.
11791 (rs6000_create_inferior): Likewise.
11792 * target.h (struct target_ops) <to_create_inferior>: Likewise.
11793 * windows-nat.c (windows_create_inferior): Likewise.
11795 2017-04-11 Pedro Alves <palves@redhat.com>
11797 * thread.c: Fix whitespace throughout.
11799 2017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
11801 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
11803 2017-04-11 Alan Hayward <alan.hayward@arm.com>
11805 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
11807 2017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
11810 * osdata.c (info_osdata): Check if 'type' is an empty string
11813 2017-04-10 Pedro Alves <palves@redhat.com>
11815 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
11816 (ptid_to_global_thread_id, in_thread_list)
11817 (do_captured_list_thread_ids, set_resumed, set_running)
11818 (set_executing, set_stop_requested, finish_thread_state)
11819 (validate_registers_access, can_access_registers_ptid)
11820 (print_thread_info_1, switch_to_thread)
11821 (do_restore_current_thread_cleanup)
11822 (make_cleanup_restore_current_thread, thread_command)
11823 (thread_name_command): Use operator== instead of ptid_equal.
11825 2017-04-10 Pedro Alves <palves@redhat.com>
11827 * thread.c (struct current_thread_cleanup) <next>: Delete field.
11828 (current_thread_cleanup_chain): Delete.
11829 (restore_current_thread_cleanup_dtor)
11830 (make_cleanup_restore_current_thread): Remove references to
11831 current_thread_cleanup_chain.
11833 2017-04-10 Alan Hayward <alan.hayward@arm.com>
11835 * msp430-tdep.c (msp430_pseudo_register_read): Never return
11838 2017-04-10 Yao Qi <yao.qi@linaro.org>
11841 * gdbthread.h (thread_info::deletable): New method.
11842 (thread_info::incref): New method.
11843 (thread_info::decref): New method.
11844 (thread_info::refcount): Move it to private.
11845 * infrun.c (save_stop_context): Call inc_refcount.
11846 (release_stop_context_cleanup): Likewise.
11847 * thread.c (set_thread_exited): New function.
11848 (init_thread_list): Delete "tp" only it is deletable, otherwise
11849 call set_thread_exited.
11850 (delete_thread_1): Call set_thread_exited.
11851 (current_thread_cleanup) <inferior_pid>: Remove.
11852 <thread>: New field.
11853 (restore_current_thread_ptid_changed): Removed.
11854 (do_restore_current_thread_cleanup): Adjust.
11855 (restore_current_thread_cleanup_dtor): Don't call
11857 (set_thread_refcount): Use dec_refcount.
11858 (make_cleanup_restore_current_thread): Adjust.
11859 (thread_apply_all_command): Call inc_refcount.
11860 (_initialize_thread): Don't call
11861 observer_attach_thread_ptid_changed.
11863 2017-04-10 Yao Qi <yao.qi@linaro.org>
11865 * thread.c (delete_thread_1): Hoist code on marking thread as
11868 2017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11870 * windows-nat.c (windows_detach): Initialize ptid with
11873 2017-04-07 Simon Marchi <simon.marchi@ericsson.com>
11875 * unittests/ptid-selftests.c: Fix erroneous assert messages.
11877 2017-04-07 Alan Hayward <alan.hayward@arm.com>
11879 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
11880 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
11881 (bfin_pseudo_register_write): Likewise
11883 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
11885 * common/ptid.h (struct ptid): Change to...
11886 (class ptid_t): ... this.
11887 <ptid_t>: New constructors.
11888 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
11889 matches>: New methods.
11890 <make_null, make_minus_one>: New static methods.
11891 <pid>: Rename to...
11893 <lwp>: Rename to...
11895 <tid>: Rename to...
11897 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
11898 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
11899 as references, move comment to class ptid_t.
11900 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
11901 ptid_t static methods.
11902 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
11903 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
11904 Take ptid arguments as references, implement using ptid_t methods.
11905 * unittests/ptid-selftests.c: New file.
11906 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11907 unittests/ptid-selftests.c.
11908 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
11910 2017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
11912 * python/python.c (python_run_simple_file): Cast mode literal to
11913 non-const char pointer as expected by PyFile_FromString.
11915 2017-04-05 Simon Marchi <simon.marchi@ericsson.com>
11917 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
11918 minus_one_ptid and null_ptid.
11920 2017-04-05 Pedro Alves <palves@redhat.com>
11922 * warning.m4 (build_warnings): Remove -Wno-write-strings.
11923 * configure: Regenerate.
11925 2017-04-05 Pedro Alves <palves@redhat.com>
11927 * ada-exp.y (yyerror): Constify.
11928 * ada-lang.c (bound_name, get_selections)
11929 (ada_variant_discrim_type)
11930 (ada_variant_discrim_name, ada_value_struct_elt)
11931 (ada_lookup_struct_elt_type, is_unchecked_variant)
11932 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
11933 (catch_ada_exception_command_split)
11934 (catch_ada_assert_command_split, catch_assert_command)
11935 (ada_op_name): Constify.
11936 * ada-lang.h (ada_yyerror, get_selections)
11937 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
11938 * arc-tdep.c (arc_print_frame_cache): Constify.
11939 * arm-tdep.c (arm_skip_stub): Constify.
11940 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
11941 (gen_aggregate_elt_ref): Constify.
11942 * bcache.c (print_bcache_statistics): Constify.
11943 * bcache.h (print_bcache_statistics): Constify.
11944 * break-catch-throw.c (catch_exception_command_1):
11945 * breakpoint.c (struct ep_type_description::description):
11947 (add_solib_catchpoint): Constify.
11948 (catch_fork_command_1): Add cast.
11949 (add_catch_command): Constify.
11950 * breakpoint.h (add_catch_command, add_solib_catchpoint):
11952 * bsd-uthread.c (bsd_uthread_state): Constify.
11953 * buildsym.c (patch_subfile_names): Constify.
11954 * buildsym.h (next_symbol_text_func, patch_subfile_names):
11956 * c-exp.y (yyerror): Constify.
11957 (token::oper): Constify.
11958 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
11959 * c-varobj.c (cplus_describe_child): Constify.
11960 * charset.c (find_charset_names): Add cast.
11961 (find_charset_names): Constify array and add const_cast.
11962 * cli/cli-cmds.c (complete_command, cd_command): Constify.
11963 (edit_command): Constify.
11964 * cli/cli-decode.c (lookup_cmd): Constify.
11965 * cli/cli-dump.c (dump_memory_command, dump_value_command):
11967 (struct dump_context): Constify.
11968 (add_dump_command, restore_command): Constify.
11969 * cli/cli-script.c (get_command_line): Constify.
11970 * cli/cli-script.h (get_command_line): Constify.
11971 * cli/cli-utils.c (check_for_argument): Constify.
11972 * cli/cli-utils.h (check_for_argument): Constify.
11973 * coff-pe-read.c (struct read_pe_section_data): Constify.
11974 * command.h (lookup_cmd): Constify.
11975 * common/print-utils.c (decimal2str): Constify.
11976 * completer.c (gdb_print_filename): Constify.
11977 * corefile.c (set_gnutarget): Constify.
11978 * cp-name-parser.y (yyerror): Constify.
11979 * cp-valprint.c (cp_print_class_member): Constify.
11980 * cris-tdep.c (cris_register_name, crisv32_register_name):
11982 * d-exp.y (yyerror): Constify.
11983 (struct token::oper): Constify.
11984 * d-lang.h (d_yyerror): Constify.
11985 * dbxread.c (struct header_file_location::name): Constify.
11986 (add_old_header_file, add_new_header_file, last_function_name)
11987 (dbx_next_symbol_text, add_bincl_to_list)
11988 (find_corresponding_bincl_psymtab, set_namestring)
11989 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
11990 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
11991 * defs.h (command_line_input, print_address_symbolic)
11992 (deprecated_readline_begin_hook): Constify.
11993 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
11995 * event-top.c (handle_line_of_input): Constify and add cast.
11996 * exceptions.c (catch_errors): Constify.
11997 * exceptions.h (catch_errors): Constify.
11998 * expprint.c (print_subexp_standard, op_string, op_name)
11999 (op_name_standard, dump_raw_expression, dump_raw_expression):
12000 * expression.h (op_name, op_string, dump_raw_expression):
12002 * f-exp.y (yyerror): Constify.
12003 (struct token::oper): Constify.
12004 (struct f77_boolean_val::name): Constify.
12005 * f-lang.c (f_word_break_characters): Constify.
12006 * f-lang.h (f_yyerror): Constify.
12007 * fork-child.c (fork_inferior): Add cast.
12008 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
12009 (new_variant): Constify.
12010 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
12011 * gdbarch.c: Regenerate.
12012 * gdbcore.h (set_gnutarget): Constify.
12013 * go-exp.y (yyerror): Constify.
12014 (token::oper): Constify.
12015 * go-lang.h (go_yyerror): Constify.
12016 * go32-nat.c (go32_sysinfo): Constify.
12017 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
12018 * guile/scm-cmd.c (cmdscm_function): Constify.
12019 * guile/scm-param.c (pascm_param_value): Constify.
12020 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
12021 (h8300sx_register_name): Constify.
12022 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
12024 * ia64-tdep.c (ia64_register_names): Constify.
12025 * infcmd.c (construct_inferior_arguments): Constify.
12026 (path_command, attach_post_wait): Constify.
12027 * language.c (show_range_command, show_case_command)
12028 (unk_lang_error): Constify.
12029 * language.h (language_defn::la_error)
12030 (language_defn::la_name_of_this): Constify.
12031 * linespec.c (decode_line_2): Constify.
12032 * linux-thread-db.c (thread_db_err_str): Constify.
12033 * lm32-tdep.c (lm32_register_name): Constify.
12034 * m2-exp.y (yyerror): Constify.
12035 * m2-lang.h (m2_yyerror): Constify.
12036 * m32r-tdep.c (m32r_register_names): Constify and make static.
12037 * m68hc11-tdep.c (m68hc11_register_names): Constify.
12038 * m88k-tdep.c (m88k_register_name): Constify.
12039 * macroexp.c (appendmem): Constify.
12040 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
12041 (upgrade_type, parse_external, parse_partial_symbols)
12042 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
12043 (new_symbol): Constify.
12044 * memattr.c (mem_info_command): Constify.
12045 * mep-tdep.c (register_name_from_keyword): Constify.
12046 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
12048 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
12049 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
12050 * mi/mi-main.c (captured_mi_execute_command): Constify and add
12052 (mi_execute_async_cli_command): Constify.
12053 * mips-tdep.c (mips_register_name): Constify.
12054 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
12055 (am33_register_name, am33_2_register_name)
12056 * moxie-tdep.c (moxie_register_names): Constify.
12057 * nat/linux-osdata.c (osdata_type): Constify fields.
12058 * nto-tdep.c (nto_parse_redirection): Constify.
12059 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
12060 (lookup_child_selector): Constify.
12061 (objc_methcall::name): Constify.
12062 * objc-lang.h (lookup_objc_class, lookup_child_selector)
12063 (lookup_struct_typedef): Constify.
12064 * objfiles.c (pc_in_section): Constify.
12065 * objfiles.h (pc_in_section): Constify.
12066 * p-exp.y (struct token::oper): Constify.
12067 (yyerror): Constify.
12068 * p-lang.h (pascal_yyerror): Constify.
12069 * parser-defs.h (op_name_standard): Constify.
12070 (op_print::string): Constify.
12071 (exp_descriptor::op_name): Constify.
12072 * printcmd.c (print_address_symbolic): Constify.
12073 * psymtab.c (print_partial_symbols): Constify.
12074 * python/py-breakpoint.c (stop_func): Constify.
12075 (bppy_get_expression): Constify.
12076 * python/py-cmd.c (cmdpy_completer::name): Constify.
12077 (cmdpy_function): Constify.
12078 * python/py-event.c (evpy_add_attribute)
12079 (gdbpy_initialize_event_generic): Constify.
12080 * python/py-event.h (evpy_add_attribute)
12081 (gdbpy_initialize_event_generic): Constify.
12082 * python/py-evts.c (add_new_registry): Constify.
12083 * python/py-finishbreakpoint.c (outofscope_func): Constify.
12084 * python/py-framefilter.c (get_py_iter_from_func): Constify.
12085 * python/py-inferior.c (get_buffer): Add cast.
12086 * python/py-param.c (parm_constant::name): Constify.
12087 * python/py-unwind.c (fprint_frame_id): Constify.
12088 * python/python.c (gdbpy_parameter_value): Constify.
12089 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
12090 * remote.c (memory_packet_config::name): Constify.
12091 (show_packet_config_cmd, remote_write_bytes)
12092 (remote_buffer_add_string):
12093 * reverse.c (exec_reverse_once): Constify.
12094 * rs6000-tdep.c (variant::name, variant::description): Constify.
12095 * rust-exp.y (rustyyerror): Constify.
12096 * rust-lang.c (rust_op_name): Constify.
12097 * rust-lang.h (rustyyerror): Constify.
12098 * serial.h (serial_ops::name): Constify.
12099 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
12100 (sh_sh3e_register_name, sh_sh2e_register_name)
12101 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
12102 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
12103 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
12104 (sh_sh4al_dsp_register_name): Constify.
12105 * sh64-tdep.c (sh64_register_name): Constify.
12106 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
12107 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
12108 * stabsread.c (patch_block_stabs, read_type_number)
12109 (ref_map::stabs, ref_add, process_reference)
12110 (symbol_reference_defined, define_symbol, define_symbol)
12111 (error_type, read_type, read_member_functions, read_cpp_abbrev)
12112 (read_one_struct_field, read_struct_fields, read_baseclasses)
12113 (read_tilde_fields, read_struct_type, read_array_type)
12114 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
12115 (read_huge_number, read_range_type, read_args, common_block_start)
12116 (find_name_end): Constify.
12117 * stabsread.h (common_block_start, define_symbol)
12118 (process_one_symbol, symbol_reference_defined, ref_add):
12119 * symfile.c (get_section_index, add_symbol_file_command):
12120 * symfile.h (get_section_index): Constify.
12121 * target-descriptions.c (tdesc_type::name): Constify.
12122 (tdesc_free_type): Add cast.
12123 * target.c (find_default_run_target):
12124 (add_deprecated_target_alias, find_default_run_target)
12125 (target_announce_detach): Constify.
12126 (do_option): Constify.
12127 * target.h (add_deprecated_target_alias): Constify.
12128 * thread.c (print_thread_info_1): Constify.
12129 * top.c (deprecated_readline_begin_hook, command_line_input):
12131 (init_main): Add casts.
12132 * top.h (handle_line_of_input): Constify.
12133 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
12134 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
12135 (tfind_command): Rename to ...
12136 (tfind_command_1): ... this and constify.
12137 (tfind_command): New function.
12138 (tfind_end_command, tfind_start_command): Adjust.
12139 (encode_source_string): Constify.
12140 * tracepoint.h (encode_source_string): Constify.
12141 * tui/tui-data.c (tui_partial_win_by_name): Constify.
12142 * tui/tui-data.h (tui_partial_win_by_name): Constify.
12143 * tui/tui-source.c (tui_set_source_content_nil): Constify.
12144 * tui/tui-source.h (tui_set_source_content_nil): Constify.
12145 * tui/tui-win.c (parse_scrolling_args): Constify.
12146 * tui/tui-windata.c (tui_erase_data_content): Constify.
12147 * tui/tui-windata.h (tui_erase_data_content): Constify.
12148 * tui/tui-winsource.c (tui_erase_source_content): Constify.
12149 * tui/tui.c (tui_enable): Add cast.
12150 * utils.c (defaulted_query): Constify.
12151 (init_page_info): Add cast.
12152 (puts_debug, subset_compare): Constify.
12153 * utils.h (subset_compare): Constify.
12154 * varobj.c (varobj_format_string): Constify.
12155 * varobj.h (varobj_format_string): Constify.
12156 * vax-tdep.c (vax_register_name): Constify.
12157 * windows-nat.c (windows_detach): Constify.
12158 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
12159 * xml-support.c (gdb_xml_end_element): Constify.
12160 * xml-tdesc.c (tdesc_start_reg): Constify.
12161 * xstormy16-tdep.c (xstormy16_register_name): Constify.
12162 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
12163 * xtensa-tdep.h (xtensa_register_t::name): Constify.
12165 2017-04-05 Pedro Alves <palves@redhat.com>
12167 * proc-api.c (struct trans): Constify.
12168 (procfs_note): Constify.
12169 * proc-events.c (struct trans, syscall_table):
12170 * proc-flags.c (struct trans): Constify.
12171 * proc-utils.h (procfs_note): Constify.
12172 * proc-why.c (struct trans): Constify.
12173 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
12174 (procfs_detach): Constify.
12175 * sol-thread.c (struct string_map): Constify.
12176 (td_err_string, td_state_string): Constify.
12178 2017-04-05 Pedro Alves <palves@redhat.com>
12180 * proc-api.c (procfs_filename): Don't initialize
12182 (prepare_to_trace): Assume procfs_filename is non-NULL.
12183 (_initialize_proc_api): Give procfs_filename a default value here.
12185 2017-04-05 Pedro Alves <palves@redhat.com>
12187 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
12188 'cond_string' parameter.
12189 (extract_exception_regexp): Constify 'string' parameter.
12190 (catch_exception_command_1): Constify.
12191 * breakpoint.c (init_catchpoint)
12192 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
12194 (ep_parse_optional_if_clause, catch_fork_command_1)
12195 (catch_exec_command_1): Constify.
12196 * breakpoint.h (init_catchpoint): Constify 'cond_string'
12198 (ep_parse_optional_if_clause): Constify.
12199 * cli/cli-utils.c (remove_trailing_whitespace)
12200 (check_for_argument): Constify.
12201 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
12202 non-const overload.
12203 (check_for_argument): Likewise.
12205 2017-04-05 Pedro Alves <palves@redhat.com>
12207 * event-top.c (command_line_handler): Add cast to execute_command
12209 * record-btrace.c (cmd_record_btrace_bts_start)
12210 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
12211 (cmd_record_btrace_start): Add cast to execute_command call.
12212 * record-full.c (record_full_goto_insn):
12213 * record.c (record_start, record_stop): Add cast to
12214 execute_command_to_string calls.
12215 (cmd_record_start): Add cast to execute_command calls.
12217 2017-04-05 Pedro Alves <palves@redhat.com>
12219 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
12220 static inline function.
12221 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
12222 array and use gdb_PyArg_ParseTupleAndKeywords.
12223 * python/py-cmd.c (cmdpy_init): Likewise.
12224 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
12225 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
12226 (infpy_search_memory): Likewise.
12227 * python/py-objfile.c (objfpy_add_separate_debug_file)
12228 (gdbpy_lookup_objfile): Likewise.
12229 * python/py-symbol.c (gdbpy_lookup_symbol)
12230 (gdbpy_lookup_global_symbol): Likewise.
12231 * python/py-type.c (gdbpy_lookup_type): Likewise.
12232 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
12233 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
12236 2017-04-05 Pedro Alves <palves@redhat.com>
12238 * python/python-internal.h (gdb_PyGetSetDef): New type.
12239 * python/py-block.c (block_object_getset)
12240 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
12241 * python/py-event.c (event_object_getset)
12242 (finish_breakpoint_object_getset): Likewise.
12243 * python/py-inferior.c (inferior_object_getset): Likewise.
12244 * python/py-infthread.c (thread_object_getset): Likewise.
12245 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
12246 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
12247 * python/py-objfile.c (objfile_getset): Likewise.
12248 * python/py-progspace.c (pspace_getset): Likewise.
12249 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
12251 * python/py-record.c (recpy_record_getset): Likewise.
12252 * python/py-symbol.c (symbol_object_getset): Likewise.
12253 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
12255 * python/py-type.c (type_object_getset, field_object_getset):
12257 * python/py-value.c (value_object_getset): Likewise.
12259 2017-04-05 Pedro Alves <palves@redhat.com>
12261 * python/python-internal.h (gdb_PyObject_CallMethod)
12262 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
12264 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
12265 (PySys_GetObject, PySys_SetPath): New macros.
12267 2017-04-05 Pedro Alves <palves@redhat.com>
12269 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
12270 info_osdata_command.
12271 * osdata.c (info_osdata_command): Rename to ...
12272 (info_osdata): ... this. Constify 'type' parameter, and remove
12273 the 'from_tty' parameter. Accept NULL TYPE.
12274 (info_osdata_command): New function.
12275 * osdata.h (info_osdata_command): Remove declaration.
12276 (info_osdata): New declaration.
12278 2017-04-05 Pedro Alves <palves@redhat.com>
12280 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
12281 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
12282 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
12284 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
12285 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
12286 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
12288 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
12289 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
12290 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
12291 (mi_cmd_file_list_exec_source_files)
12292 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
12293 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12294 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
12296 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
12297 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
12298 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
12299 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
12300 (mi_cmd_stack_info_frame): Constify 'command' parameter.
12301 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
12302 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
12303 'command' parameter.
12304 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
12305 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
12306 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
12307 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
12308 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
12309 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
12310 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
12311 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
12312 (mi_cmd_var_set_update_range): Constify 'command' parameter.
12313 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
12314 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
12316 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
12317 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
12318 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
12319 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
12320 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
12321 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
12322 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
12323 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
12324 (mi_cmd_data_list_changed_registers)
12325 (mi_cmd_data_write_register_values)
12326 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
12327 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
12328 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
12329 (mi_cmd_list_features, mi_cmd_list_target_features)
12330 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
12331 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
12332 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
12333 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
12334 (mi_cmd_trace_frame_collected): Constify 'command'
12336 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
12337 'command' parameter.
12339 2017-04-05 Pedro Alves <palves@redhat.com>
12341 * ada-lang.c (ada_completer_word_break_characters): Now a const
12343 (ada_get_gdb_completer_word_break_characters): Constify.
12344 * completer.c (gdb_completer_command_word_break_characters)
12345 (gdb_completer_file_name_break_characters)
12346 (gdb_completer_quote_characters): Now const arrays.
12347 (get_gdb_completer_quote_characters): Constify.
12348 (set_rl_completer_word_break_characters): New function.
12349 (set_gdb_completion_word_break_characters)
12350 (complete_line_internal): Use it.
12351 * completer.h (get_gdb_completer_quote_characters): Constify.
12352 (set_rl_completer_word_break_characters): Declare.
12353 * f-lang.c (f_word_break_characters): Constify.
12354 * language.c (default_word_break_characters): Constify.
12355 * language.h (language_defn::la_word_break_characters): Constify.
12356 (default_word_break_characters): Constify.
12357 * top.c (init_main): Use set_rl_completer_word_break_characters.
12359 2017-04-05 Pedro Alves <palves@redhat.com>
12361 * aix-thread.c (aix_thread_pid_to_str)
12362 (aix_thread_extra_thread_info): Constify.
12363 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
12364 * bsd-uthread.c (bsd_uthread_extra_thread_info)
12365 (bsd_uthread_pid_to_str): Constify.
12366 * corelow.c (core_pid_to_str): Constify.
12367 * darwin-nat.c (darwin_pid_to_str): Constify.
12368 * fbsd-nat.c (fbsd_pid_to_str): Constify.
12369 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
12371 * gnu-nat.c (gnu_pid_to_str): Constify.
12372 * go32-nat.c (go32_pid_to_str): Constify.
12373 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
12374 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
12375 * inferior.c (inferior_pid_to_str): Constify.
12376 * linux-nat.c (linux_nat_pid_to_str): Constify.
12377 * linux-tdep.c (linux_core_pid_to_str): Constify.
12378 * linux-thread-db.c (thread_db_pid_to_str)
12379 (thread_db_extra_thread_info): Constify.
12380 * nto-tdep.c (nto_extra_thread_info): Constify.
12381 * nto-tdep.h (nto_extra_thread_info): Constify.
12382 * obsd-nat.c (obsd_pid_to_str): Constify.
12383 * procfs.c (procfs_pid_to_str): Constify.
12384 * ravenscar-thread.c (ravenscar_extra_thread_info)
12385 (ravenscar_pid_to_str): Constify.
12386 * remote-sim.c (gdbsim_pid_to_str): Constify.
12387 * remote.c (remote_threads_extra_info, remote_pid_to_str):
12389 * sol-thread.c (solaris_pid_to_str): Constify.
12390 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
12391 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
12392 * target.c (default_pid_to_str, target_pid_to_str)
12393 (normal_pid_to_str, default_pid_to_str): Constify.
12394 * target.h (target_ops::to_pid_to_str)
12395 (target_ops::to_extra_thread_info): Constify.
12396 (target_pid_to_str, normal_pid_to_str): Constify.
12397 * windows-nat.c (windows_pid_to_str): Constify.
12398 * gdbarch.sh (core_pid_to_str): Constify.
12399 * target-delegates.c: Regenerate.
12400 * gdbarch.h, gdbarch.c: Regenerate.
12402 2017-04-05 Pedro Alves <palves@redhat.com>
12404 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
12405 the memory of the temporary warning_pre_print override.
12406 * utils.c (warning_pre_print): Constify.
12407 * utils.h (warning_pre_print): Constify.
12409 2017-04-05 Pedro Alves <palves@redhat.com>
12411 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
12412 (shell_command): New function.
12413 (make_command): Use std::string.
12414 (init_cli_cmds): Register shell_command instead of shell_escape.
12416 2017-04-05 Pedro Alves <palves@redhat.com>
12418 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
12419 * tracepoint.c (default_collect): Don't initialize.
12421 2017-04-05 Pedro Alves <palves@redhat.com>
12423 * macroexp.c (macro_buffer::shared): Now a bool.
12424 (init_buffer): Update.
12425 (init_shared_buffer): Constify 'addr' parameter.
12426 (substitute_args, expand, macro_expand, macro_expand_next): Remove
12429 2017-04-05 Pedro Alves <palves@redhat.com>
12431 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
12432 * disasm.c (set_disassembler_options): Constify local.
12433 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
12435 2017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
12438 * tracefile.c (tsave_command): Fix argument parsing for '-r'
12441 2017-04-05 Yao Qi <yao.qi@linaro.org>
12443 * frame.c (frame_unwind_register_unsigned): Call
12444 frame_unwind_register_value.
12446 2017-04-05 Yao Qi <yao.qi@linaro.org>
12448 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
12449 Use gdb_test_multiple, and don't match anchor.
12451 2017-04-05 Pedro Alves <palves@redhat.com>
12453 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
12454 (Write After Approval): Remove Simon Marchi.
12456 2017-04-05 Pedro Alves <palves@redhat.com>
12458 * common/gdb_optional.h (optional::optional): Make constexpr and
12459 initialize m_dummy.
12461 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12463 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12464 (amd64fbsd_jmp_buf_reg_offset): Remove.
12465 (amd64fbsd_supply_uthread): Remove function.
12466 (amd64fbsd_collect_uthread): Remove function.
12467 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
12468 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
12469 (x86_64-*-freebsd*): Remove bsd-uthread.o.
12470 (fbsd-nat.c): Update comment.
12471 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12472 (i386fbsd_jmp_buf_reg_offset): Remove.
12473 (i386fbsd_supply_uthread): Remove function.
12474 (i386fbsd_collect_uthread): Remove function.
12475 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
12477 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12479 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
12480 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
12481 * NEWS: Mention that support for FreeBSD/alpha was removed.
12482 * alpha-fbsd-tdep.c: Delete file.
12483 * config/alpha/fbsd.mh: Delete file.
12484 * configure.host: Delete alpha*-*-freebsd* and
12485 alpha*-*-kfreebsd*-gnu.
12486 * configure.tgt: Delete alpha*-*-freebsd* and
12487 alpha*-*-kfreebsd*-gnu.
12489 2017-04-04 John Baldwin <jhb@FreeBSD.org>
12491 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
12492 amd64bsd_store_inferior_registers): Use ptid from regcache.
12494 2017-04-04 Pedro Alves <palves@redhat.com>
12496 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
12497 data fields, make them private and add "m_" prefixes.
12498 (lnp_state_machine::lnp_state_machine): New ctor.
12499 (record_line, check_line_address, handle_set_discriminator)
12500 (handle_set_address, handle_advance_pc, handle_special_opcode)
12501 (handle_advance_line, handle_set_file, handle_negate_stmt)
12502 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
12503 (end_sequence, advance_line): New methods.
12504 (m_gdbarch, m_record_lines_p): New fields.
12505 (lnp_reader_state): Delete.
12506 (dwarf_record_line): Rename to ...
12507 (lnp_state_machine::record_line): ... adjust.
12508 (init_lnp_state_machine): Delete.
12509 (lnp_state_machine::lnp_state_machine): New.
12510 (check_line_address): Rename to ...
12511 (lnp_state_machine::check_line_address): This.
12512 (dwarf_decode_lines_1): Remove reference to "reader_state".
12513 Adjust lnp_state_machine having a non-default ctor. Use bool.
12514 State machine internal state manipulation moved to
12515 lnp_state_machine methods.
12517 2017-04-04 Pedro Alves <palves@redhat.com>
12519 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12520 unittests/offset-type-selftests.c.
12521 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
12522 * common/offset-type.h: New file.
12523 * common/preprocessor.h: New file.
12524 * common/traits.h: New file.
12525 * common/valid-expr.h: New file.
12526 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
12527 sect_offset and cu_offset strong typedefs throughout.
12528 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
12529 typedefs throughout.
12530 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
12531 sect_offset and cu_offset strong typedefs throughout.
12532 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
12533 typedefs throughout.
12534 * gdbtypes.h: Include "common/offset-type.h".
12535 (cu_offset): Now an offset type (strong typedef) instead of a
12537 (sect_offset): Likewise.
12538 (union call_site_parameter_u): Rename "param_offset" field to
12540 * unittests/offset-type-selftests.c: New file.
12542 2017-04-04 Pedro Alves <palves@redhat.com>
12544 * common/underlying.h: New file.
12545 * dwarf2read.c: Include "common/gdb_optional.h" and
12546 "common/underlying.h".
12547 (dir_index, file_name_index): New types.
12548 (file_entry): Use them.
12549 (file_entry::include): Use to_underlying.
12550 (line_header::add_file_name): Use dir_index.
12551 (read_formatted_entries): Use gdb::optional. Read form before
12552 writting to file_entry.
12553 (dwarf_decode_line_header): Use dir_index.
12554 (lnp_state_machine::current_file): Use to_underlying.
12555 (lnp_state_machine::file): Change type to file_name_index.
12556 (dwarf_record_line): Use to_underlying.
12557 (init_lnp_state_machine): Use file_name_index.
12558 (dwarf_decode_lines_1): Use dir_index and file_name_index.
12560 2017-04-04 Pedro Alves <palves@redhat.com>
12562 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
12563 operator bool, has_value and get methods.
12565 2017-04-04 Pedro Alves <palves@redhat.com>
12567 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
12569 (line_header): Initialize all data fields. Change type of
12570 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
12571 Change type of include_dirs to std::vector<const char *>. Remove
12572 num_include_dirs, include_dirs_size. Change type of file_names to
12573 std::vector<file_entry>. Remove num_file_names, file_names_size.
12574 (line_header::line_header): New.
12575 (line_header::add_include_dir, line_header::add_file_name): New
12577 (line_header::include_dir_at): Remove NULL check.
12578 (line_header::file_name_at): Add const overload.
12579 (line_header_up): New unique_ptr typedef.
12580 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
12581 std::vector. Remove free_line_header call.
12582 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
12583 free_line_header call.
12584 (free_cu_line_header): Delete.
12585 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
12586 (setup_type_unit_groups): Use line_header_up instead of cleanups.
12587 Adjust to use std::vector.
12588 (free_line_header): Delete.
12589 (free_line_header_voidp): Use delete.
12590 (add_include_dir): Replace with ...
12591 (line_header::add_include_dir): ... this method. Use std::vector.
12592 (add_file_name): Replace with ...
12593 (line_header::add_file_name): ... this method. Use std::vector.
12594 (add_include_dir_stub): Delete.
12595 (read_formatted_entries): Remove memset.
12596 (dwarf_decode_line_header): Return a line_header_up instead of a
12597 raw pointer. Remove cleanup handling. Pass lambdas to
12598 read_formatted_entries. Adjust to use line_header methods.
12599 (dwarf_decode_lines_1): Adjust to use line_header methods.
12600 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
12603 2017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
12605 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
12606 instead of struct ptid.
12608 2017-05-04 Alan Hayward <alan.hayward@arm.com>
12610 * frame.c (get_frame_register_bytes): Unwind using value.
12611 (put_frame_register_bytes): Likewise.
12613 2017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
12615 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
12618 2017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
12620 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
12622 2017-03-29 Yao Qi <yao.qi@linaro.org>
12624 * gdbthread.h (struct thread_info): Declare constructor and
12625 destructor. Add some in-class member initializers.
12626 * thread.c (free_thread): Remove.
12627 (init_thread_list): Call delete instead of free_thread.
12628 (new_thread): Call thread_info constructor.
12629 (thread_info::thread_info): New function.
12630 (thread_info::~thread_info): New function.
12631 (delete_thread_1): Call delete instead of free_thread.
12632 (make_cleanup_restore_current_thread): Move tp and frame to
12635 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12637 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
12638 (arc_skip_prologue): Likewise.
12639 (arc_make_frame_cache): Likewise.
12640 (arc_pv_get_operand): New function.
12641 (arc_is_in_prologue): Likewise.
12642 (arc_analyze_prologue): Likewise.
12643 (arc_print_frame_cache): Likewise.
12644 (MAX_PROLOGUE_LENGTH): New constant.
12646 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12648 * configure.tgt: Add arc-insn.o.
12649 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
12650 (dump_arc_instruction_command): New function.
12651 (arc_fprintf_disasm): Likewise.
12652 (arc_disassemble_info): Likewise.
12653 (arc_insn_get_operand_value): Likewise.
12654 (arc_insn_get_operand_value_signed): Likewise.
12655 (arc_insn_get_memory_base_reg): Likewise.
12656 (arc_insn_get_memory_offset): Likewise.
12657 (arc_insn_get_branch_target): Likewise.
12658 (arc_insn_dump): Likewise.
12659 (arc_insn_get_linear_next_pc): Likewise.
12660 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
12661 (arc_disassemble_info): Likewise.
12662 (arc_insn_get_branch_target): Likewise.
12663 (arc_insn_get_linear_next_pc): Likewise.
12664 * NEWS: Mention new "maint print arc arc-instruction".
12666 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12668 * arc-tdep (maintenance_print_arc_list): New variable.
12669 (maintenance_print_arc_command): New function.
12671 2017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12673 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
12674 Add "limm" and "reserved".
12675 (arc_cannot_fetch_register, arc_cannot_store_register): Add
12676 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
12677 * arc-tdep.h (arc_regnum): Likewise.
12679 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12681 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12682 for THREADPTR register.
12683 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
12685 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
12686 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
12687 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
12689 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12691 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
12692 registers above gdbarch_num_regs (gdbarch) as privileged in
12695 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12697 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12698 for a single specified register or for all registers in
12699 a0_base..a0_base + C0_NREGS range.
12700 (supply_gregset_reg): Call regcache_raw_supply for a single
12701 specified register or for all registers in a0_base..a0_base +
12704 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12706 * arch/xtensa.h (C0_NREGS): Add definition.
12707 * xtensa-tdep.c (C0_NREGS): Remove definition.
12709 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12711 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
12712 Drop xtensa_default_isa initialization.
12713 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
12715 2017-03-27 Pedro Alves <palves@redhat.com>
12717 * dwarf2read.c (file_entry) <dir_index>: Add comment.
12718 (file_entry::include_dir): New method.
12719 (line_header::include_dir_at, line_header::file_name_at): New
12721 (setup_type_unit_groups, setup_type_unit_groups)
12722 (psymtab_include_file_name): Simplify using the new methods.
12723 (lnp_state_machine) <the_line_header>: New field.
12724 <file>: Add comment.
12725 (lnp_state_machine::current_file): New method.
12726 (dwarf_record_line): Simplify using the new methods.
12727 (init_lnp_state_machine): Initialize the "the_line_header" field.
12728 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
12729 Simplify using the new methods.
12731 2017-03-27 Pedro Alves <palves@redhat.com>
12733 * cp-name-parser.y (make_empty): Delete.
12734 (demangler_special, nested_name, ptr_operator, array_indicator)
12735 (direct_declarator, declarator_1): Use fill_comp instead of
12738 2017-03-27 Pedro Alves <palves@redhat.com>
12740 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
12741 to ATTRIBUTE_PRINTF.
12742 * solib-target.c (library_list_start_list): Print "string" not
12744 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
12745 gdb_xml_error call.
12747 2017-03-27 Pedro Alves <palves@redhat.com>
12749 * dwarf2read.c (struct file_and_directory): New.
12750 (dwarf2_get_dwz_file): Adjust to use std::string.
12751 (dw2_get_file_names_reader): Adjust to use file_and_directory.
12752 (find_file_and_directory): Adjust to return a file_and_directory
12754 (read_file_scope): Adjust to use file_and_directory. Remove
12755 make_cleanup/do_cleanups calls.
12756 (open_and_init_dwp_file): Adjust to use std::string. Remove
12757 make_cleanup/do_cleanups calls.
12758 * python/python.c (do_start_initialization): Adjust to ldirname
12759 returning a std::string.
12760 * utils.c (ldirname): Now returns a std::string.
12761 * utils.h (ldirname): Change return type to std::string.
12762 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
12763 returning a std::string.
12764 * xml-tdesc.c (file_read_description_xml): Likewise.
12766 2017-03-24 Alan Hayward <alan.hayward@arm.com>
12768 * regcache.c (regcache_debug_print_register): New function.
12769 * regcache.h (regcache_debug_print_register): New declaration.
12770 * target.c (debug_print_register): Remove.
12771 (target_fetch_registers): Call regcache_debug_print_register.
12772 (target_store_registers): Likewise.
12774 2017-03-24 Pádraig Brady <pbrady@fb.com>
12776 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
12777 reference beyond the 'lh->include_dirs' array before accessing to
12779 (psymtab_include_file_name): Likewise.
12780 (dwarf_decode_lines_1): Likewise.
12781 (dwarf_decode_lines): Likewise.
12782 (file_file_name): Likewise.
12784 2017-03-23 Simon Marchi <simon.marchi@ericsson.com>
12786 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
12788 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12789 ps_lsetfpregs): Likewise.
12790 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
12791 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12792 ps_lsetfpregs): Likewise.
12793 * target.c (target_fetch_registers, target_store_registers):
12796 2017-03-23 Alan Hayward <alan.hayward@arm.com>
12798 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
12800 2017-03-23 Yao Qi <yao.qi@linaro.org>
12802 * aarch64-tdep.c (aarch64_process_record_test): Declare.
12803 (_initialize_aarch64_tdep): Register it.
12804 (aarch64_record_load_store): Handle PRFM instruction.
12805 (aarch64_process_record_test): New function.
12807 2017-03-23 Yao Qi <yao.qi@linaro.org>
12809 * aarch64-tdep.c (aarch64_record_load_store): Fix code
12812 2017-03-23 Yao Qi <yao.qi@linaro.org>
12814 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
12816 2017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12818 python/python.c (do_start_initialization): Fix memory leak.
12820 2017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12822 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
12823 using get_ptrace_pid.
12824 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
12826 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
12827 inferior_ptid instead of pid.
12829 2017-03-22 Yao Qi <yao.qi@linaro.org>
12831 * aarch64-tdep.c: Wrap locally used classes in anonymous
12833 * arm-tdep.c: Likewise.
12834 * linespec.c: Likewise.
12835 * ui-out.c: Likewise.
12837 2017-03-22 Jonah Graham <jonah@kichwacoders.com>
12840 * python/lib/gdb/printer/bound_registers.py: Import sys.
12842 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12844 * windows-nat.c (do_windows_fetch_inferior_registers): Add
12845 windows_thread_info parameter and use it instead of
12847 (windows_fetch_inferior_registers): Don't set current_thread,
12848 pass the thread to do_windows_fetch_inferior_registers. Use
12849 ptid from regcache instead of inferior_ptid.
12850 (do_windows_store_inferior_registers): Add windows_thread_info
12851 parameter and use it instead of current_thread.
12852 (windows_store_inferior_registers): Don't set current_thread,
12853 pass the thread to do_windows_store_inferior_registers. Use
12854 ptid from regcache instead of inferior_ptid.
12856 2017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12858 * ser-mingw.c (ser_windows_raw): Remove reference to
12859 struct serial::current_timeout.
12861 2017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
12864 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
12865 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
12866 (sparc64_fsr_type): Fix %fsr decoding.
12868 2017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
12870 * python/py-record-btrace.c (btpy_insn_data): Change return type
12873 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
12875 * spu-linux-nat.c (spu_fetch_inferior_registers,
12876 spu_store_inferior_registers): Use ptid from regcache, set and
12877 restore inferior_ptid.
12878 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
12881 2017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
12883 * i386-linux-nat.c (fetch_register, store_register,
12884 i386_linux_fetch_inferior_registers,
12885 i386_linux_store_inferior_registers): Use ptid from regcache.
12886 * ia64-linux-nat.c (ia64_linux_fetch_register,
12887 ia64_linux_store_register): Likewise.
12888 * inf-ptrace.c (inf_ptrace_fetch_register,
12889 inf_ptrace_store_register): Likewise.
12890 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
12891 m32r_linux_store_inferior_registers): Likewise.
12892 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
12893 m68kbsd_store_inferior_registers): Likewise.
12894 * m68k-linux-nat.c (fetch_register, store_register,
12895 m68k_linux_fetch_inferior_registers,
12896 m68k_linux_store_inferior_registers): Likewise.
12897 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
12898 m88kbsd_store_inferior_registers): Likewise.
12899 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
12900 mips_fbsd_store_inferior_registers): Likewise.
12901 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
12902 mips64_linux_regsets_store_registers): Likewise.
12903 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
12904 mipsnbsd_store_inferior_registers): Likewise.
12905 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
12906 mips64obsd_store_inferior_registers): Likewise.
12907 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
12909 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
12910 ppcfbsd_store_inferior_registers): Likewise.
12911 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
12912 ppc_linux_store_inferior_registers): Likewise.
12913 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
12914 ppcnbsd_store_inferior_registers): Likewise.
12915 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
12916 ppcobsd_store_registers): Likewise.
12917 * procfs.c (procfs_fetch_registers, procfs_store_registers):
12919 * ravenscar-thread.c (ravenscar_fetch_registers,
12920 ravenscar_store_registers, ravenscar_prepare_to_store):
12922 * record-btrace.c (record_btrace_fetch_registers,
12923 record_btrace_store_registers, record_btrace_prepare_to_store):
12925 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
12926 Lookup inferior using ptid from regcache, instead of
12928 * remote.c (remote_fetch_registers, remote_store_registers): Use
12929 ptid from regcache.
12930 * rs6000-nat.c (fetch_register, store_register): Likewise.
12931 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
12932 s390_linux_store_inferior_registers): Likewise.
12933 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
12934 shnbsd_store_inferior_registers): Likewise.
12935 * sol-thread.c (sol_thread_fetch_registers,
12936 sol_thread_store_registers): Likewise.
12937 * sparc-nat.c (sparc_fetch_inferior_registers,
12938 sparc_store_inferior_registers): Likewise.
12939 * tilegx-linux-nat.c (fetch_inferior_registers,
12940 store_inferior_registers): Likewise.
12941 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
12942 vaxbsd_store_inferior_registers): Likewise.
12943 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
12944 store_xtregs): Likewise.
12946 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
12949 * NEWS: Mention support for rvalue references in GDB and python.
12950 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
12951 supports both lvalue and rvalue references.
12953 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
12956 * gdbtypes.c (rank_one_type): Implement overloading
12957 resolution rules regarding rvalue references.
12959 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
12962 * aarch64-tdep.c (aarch64_type_align)
12963 (aarch64_extract_return_value, aarch64_store_return_value): Change
12964 lvalue reference type checks to general reference type checks.
12965 * amd64-tdep.c (amd64_classify): Likewise.
12966 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
12968 * arm-tdep.c (arm_type_align, arm_extract_return_value)
12969 (arm_store_return_value): Likewise.
12970 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
12971 * c-typeprint.c (c_print_type): Likewise.
12972 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
12973 (cplus_number_of_children, cplus_describe_child): Likewise.
12974 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
12975 * completer.c (expression_completer): Likewise.
12976 * cp-support.c (make_symbol_overload_list_adl_namespace):
12978 * darwin-nat-info.c (info_mach_region_command): Likewise.
12979 * dwarf2loc.c (entry_data_value_coerce_ref)
12980 (value_of_dwarf_reg_entry): Likewise.
12981 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
12982 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
12984 * findvar.c (extract_typed_address, store_typed_address):
12986 * gdbtypes.c (rank_one_type): Likewise.
12987 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
12988 * infcall.c (value_arg_coerce): Likewise.
12989 * language.c (pointer_type): Likewise.
12990 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
12992 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
12993 * mn10300-tdep.c (mn10300_type_align): Likewise.
12994 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
12995 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
12996 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
12998 * printcmd.c (print_formatted, x_command): Likewise.
12999 * python/py-type.c (typy_get_composite, typy_template_argument):
13001 * python/py-value.c (valpy_referenced_value)
13002 (valpy_get_dynamic_type, value_has_field): Likewise.
13003 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
13004 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
13005 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
13006 * spu-tdep.c (spu_scalar_value_p): Likewise.
13007 * symtab.c (lookup_symbol_aux): Likewise.
13008 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
13009 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
13011 * valops.c (value_cast_pointers, value_cast)
13012 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
13013 (value_struct_elt, value_struct_elt_bitpos)
13014 (value_find_oload_method_list, find_overload_match)
13015 (value_rtti_indirect_type): Likewise.
13016 * valprint.c (val_print_scalar_type_p, generic_val_print):
13018 * value.c (value_actual_type, value_as_address, unpack_long)
13019 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
13020 (coerce_ref): Likewise.
13021 * varobj.c (varobj_get_value_type): Likewise.
13023 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13026 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
13027 table of constants.
13028 * python/lib/gdb/command/explore.py: Support exploring values
13029 of rvalue reference types.
13030 * python/lib/gdb/types.py: Implement get_basic_type() for
13031 rvalue reference types.
13032 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
13034 * python/py-value.c (valpy_getitem): Add an rvalue reference
13036 (valpy_reference_value): Add new parameter "refcode".
13037 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
13038 New wrappers for valpy_reference_value().
13039 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13040 (gdbpy_invoke_xmethod): Likewise.
13042 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13045 * dwarf2read.c (process_die, read_type_die_1): Handle the
13046 DW_TAG_rvalue_reference_type DIE.
13047 (read_tag_reference_type): Add new parameter "refcode".
13049 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13052 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
13053 (c_type_print_modifier, c_type_print_varspec_suffix)
13054 (c_type_print_base): Support printing rvalue reference types.
13055 * c-valprint.c (c_val_print, c_value_print): Support printing
13056 rvalue reference values.
13058 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13061 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
13063 * cp-support.c (replace_typedefs): Handle
13064 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
13065 * python/py-type.c (typy_lookup_type): Likewise.
13067 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13070 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
13071 * parse.c (insert_type): Change assert statement.
13072 (follow_types): Handle rvalue reference types.
13073 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
13076 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13079 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
13080 value_ref() interface.
13081 * c-valprint.c (c_value_print): Likewise.
13082 * infcall.c (value_arg_coerce): Likewise.
13083 * python/py-value.c (valpy_reference_value): Likewise.
13084 * valops.c (value_cast, value_reinterpret_cast)
13085 (value_dynamic_cast, typecmp): Likewise.
13086 (value_ref): Parameterize by kind of return value reference type.
13087 * value.h (value_ref): Add new parameter "refcode".
13089 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13092 * dwarf2read.c (read_tag_reference_type): Use
13093 lookup_lvalue_reference_type() instead of lookup_reference_type().
13094 * eval.c (evaluate_subexp_standard): Likewise.
13095 * f-exp.y: Likewise.
13096 * gdbtypes.c (make_reference_type, lookup_reference_type):
13097 Generalize with rvalue reference types.
13098 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
13099 convenience wrappers for lookup_reference_type().
13100 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
13101 reference kind parameter.
13102 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
13103 wrappers for lookup_reference_type().
13104 * guile/scm-type.c (gdbscm_type_reference): Use
13105 lookup_lvalue_reference_type() instead of lookup_reference_type().
13106 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
13107 * parse.c (follow_types): Likewise.
13108 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
13109 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
13111 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13112 (gdbpy_invoke_xmethod): Likewise.
13113 * stabsread.c: Provide extra argument to make_reference_type()
13115 * valops.c (value_ref, value_rtti_indirect_type): Use
13116 lookup_lvalue_reference_type() instead of lookup_reference_type().
13118 2017-03-20 Artemiy Volkov <artemiyv@acm.org>
13121 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
13122 (TYPE_IS_REFERENCE): New macro.
13123 (struct type): Add rvalue_reference_type field.
13124 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
13126 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13128 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
13129 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
13130 New function definition.
13131 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
13132 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
13133 New function declaration.
13134 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
13135 * mi/mi-interp.h: New file.
13136 * solib.c (info_sharedlibrary_command): Replace for loop with
13138 * solib.h (update_solib_list): New function declaration.
13139 (so_list_head): Move macro.
13140 * solist.h (ALL_SO_LIBS): New macro.
13142 2017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13144 * infcmd.c (post_create_inferior): Remove unused argument in
13146 * remote.c (remote_start_remote): Likewise.
13147 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
13148 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
13149 (enable_break): Likewise.
13150 * solib.c (update_solib_list): Remove unused target argument
13151 and its documentation.
13152 (solib_add): Remove unused target argument. Remove unused
13153 argument in call to update_solib_list.
13154 (info_sharedlibrary_command): Remove unused argument in call
13155 to update_solib_list.
13156 (sharedlibrary_command): Remove unused argument in call to
13158 (handle_solib_event): Likewise.
13159 (reload_shared_libraries): Likewise.
13160 * solib.h (solib_add): Remove unused target argument.
13162 2017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
13164 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
13165 (s390_displaced_step_fixup): Cover relative branches with the
13166 default fixup handling. This fixes lack of support for some
13167 relative branch instructions.
13169 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13171 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
13172 ptid from regcache.
13174 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13176 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
13177 i386_darwin_store_inferior_registers): Use ptid from regcache.
13179 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13181 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
13182 i386bsd_store_inferior_registers): Use ptid from regcache.
13184 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13186 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
13187 hppaobsd_store_registers): Use ptid from regcache.
13189 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13191 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
13192 hppanbsd_store_registers): Use ptid from regcache.
13194 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13196 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
13197 from regcache. Use get_ptrace_pid.
13199 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13201 * corelow.c (get_core_register_section): Use ptid from regcache,
13204 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13206 * bsd-uthread.c (bsd_uthread_fetch_registers,
13207 bsd_uthread_store_registers): Use ptid from regcache, set and
13208 restore inferior_ptid.
13210 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13212 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
13213 fetch_fp_regs, store_register, store_regs, store_fp_register,
13214 store_fp_regs): Use ptid from regcache.
13216 2017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13218 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
13219 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
13220 store_vfp_regs): Use ptid from regcache.
13222 2017-03-17 Pedro Alves <palves@redhat.com>
13225 * ser-base.c (ser_base_wait_for): Add comment.
13226 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
13228 * ser-unix.c (hardwire_raw): Remove reference to
13229 scb->current_timeout.
13230 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
13231 (hardwire_ops): Install ser_base_readchar instead of
13233 * serial.h (struct serial) <current_timeout, timeout_remaining>:
13236 2017-03-17 Jonah Graham <jonah@kichwacoders.com>
13239 * python/lib/gdb/printer/bound_registers.py: Add support for
13242 2017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
13244 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
13245 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
13246 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
13247 byte_offset to subobj_byte_offset. Fix the handling of
13248 DWARF_VALUE_STACK on big-endian targets when coming via an
13250 (dwarf2_evaluate_loc_desc): Adjust call to
13251 dwarf2_evaluate_loc_desc_full.
13252 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
13253 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
13255 2017-03-16 Yao Qi <yao.qi@linaro.org>
13257 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
13258 and REVSH instructions.
13260 2017-03-16 Yao Qi <yao.qi@linaro.org>
13262 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
13263 (arm_record_test): Declare.
13264 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
13265 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
13266 align with the manual.
13267 (thumb_record_misc): Adjust the code order to align with the
13269 (thumb2_record_decode_insn_handler): Fix instruction matching.
13270 (instruction_reader_thumb): New class.
13271 (arm_record_test): New function.
13273 2017-03-16 Yao Qi <yao.qi@linaro.org>
13275 * arm-tdep.c (abstract_memory_reader): New class.
13276 (instruction_reader): New class.
13277 (extract_arm_insn): Add argument 'reader'. Callers updated.
13278 (decode_insn): Likewise.
13280 2017-03-16 Doug Evans <dje@google.com>
13282 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
13283 member. Change type of TYPE member to SCM. All uses updated.
13284 (lsscm_make_lazy_string_smob): Add assert.
13285 (lsscm_make_lazy_string): Flag bad length values.
13286 (lsscm_elt_type): New function.
13287 (gdbscm_lazy_string_to_value): Rewrite to use
13288 lsscm_safe_lazy_string_to_value.
13289 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
13290 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
13291 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
13293 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13294 * guile/scm-type.c (tyscm_scm_to_type): New function.
13296 2017-03-15 Doug Evans <dje@google.com>
13298 PR python/17728, python/18439, python/18779
13299 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
13300 member. Change type of TYPE member to PyObject *. All uses updated.
13301 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
13302 (gdbpy_create_lazy_string_object): Flag bad length values.
13303 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
13304 Handle typedefs in incoming type.
13305 (stpy_lazy_string_elt_type): New function.
13306 (gdbpy_extract_lazy_string): Call it.
13307 * python/py-value.c (valpy_lazy_string): Flag bad length values.
13308 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
13309 typedefs in incoming type.
13311 2017-03-16 Doug Evans <dje@google.com>
13313 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13314 * guile/scm-type.c (tyscm_scm_to_type): New function.
13316 2017-03-16 Jiong Wang <jiong.wang@arm.com>
13318 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
13319 "ULONGEST" for "skip".
13321 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13324 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
13325 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
13326 (inf_ptrace_peek_poke): ...here. New function. Now also loop
13327 over ptrace peek/poke until end of buffer or error.
13329 2017-03-14 Simon Marchi <simon.marchi@ericsson.com>
13331 * parse.c (length_of_subexp): Make static.
13332 * parser-defs.h (length_of_subexp): Remove.
13334 2017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13336 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
13339 2017-03-14 Pedro Alves <palves@redhat.com>
13341 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
13342 (main): Use std::unique_ptr. Remove calls to
13343 cp_demangled_name_parse_free.
13345 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13347 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
13348 alphabsd_store_inferior_registers): Use regcache->ptid instead
13351 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13353 * aix-thread.c (aix_thread_fetch_registers,
13354 aix_thread_store_registers): Use regcache->ptid instead of
13357 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13359 * aarch64-linux-nat.c (fetch_gregs_from_thread,
13360 store_gregs_to_thread, fetch_fpregs_from_thread,
13361 store_fpregs_to_thread): Use regcache->ptid instead of
13364 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13366 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
13367 amd64_linux_fetch_inferior_registers): Use regcache->ptid
13368 instead of inferior_ptid.
13370 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13372 * target.c (target_fetch_registers, target_store_registers): Add
13375 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13377 * regcache.h (regcache_get_ptid): New function.
13378 * regcache.c (regcache_get_ptid): New function.
13380 2017-03-13 Mark Wielaard <mark@klomp.org>
13382 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
13384 2017-03-10 Keith Seitz <keiths@redhat.com>
13387 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
13389 2017-03-08 Pedro Alves <palves@redhat.com>
13392 * infrun.c (start_step_over, do_target_resume, resume)
13393 (restart_threads): Assert we're not resuming a thread that is
13394 meant to be stopped.
13395 (infrun_thread_stop_requested_callback): Delete.
13396 (infrun_thread_stop_requested): If the thread is internally
13397 stopped, queue a pending stop event and clear the thread's
13398 inline-frame state.
13399 (handle_stop_requested): New function.
13400 (handle_syscall_event, handle_inferior_event_1): Use
13401 handle_stop_requested.
13402 (handle_stop_requested): New function.
13403 (handle_signal_stop): Set the thread's stop_signal here instead of
13405 (finish_step_over): Clear step over info unconditionally.
13406 (handle_signal_stop): If the user had interrupted the event
13407 thread, consider the stop a random signal.
13408 (handle_signal_stop) <signal arrived while stepping over
13409 breakpoint>: Don't restart threads here.
13410 (stop_waiting): Don't clear step-over info here.
13412 2017-03-08 Pedro Alves <palves@redhat.com>
13415 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
13416 goes to argument 2, not 1.
13418 2017-03-08 Pedro Alves <palves@redhat.com>
13421 * top.c (gdb_readline_wrapper): Avoid passing NULL to
13422 display_gdb_prompt.
13423 (command_line_input): Add comment.
13425 2017-03-08 Pedro Alves <palves@redhat.com>
13428 * tui/tui-file.c (tui_file::write): New.
13429 * tui/tui-file.h (tui_file): Override "write".
13430 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
13431 factored out from ...
13432 (tui_puts): ... here.
13433 (tui_putc): Use them.
13434 (tui_write): New function.
13435 * tui/tui-io.h (tui_write): Declare.
13437 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
13439 * Makefile.in (SFILES): Replace "environ.c" with
13440 "common/environ.c".
13441 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
13442 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
13444 * common/environ.c: ... here.
13445 * environ.h: Moved to...
13446 * common/environ.h: ... here.
13448 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13450 * gdbarch.sh (pstring_ptr): New static function.
13451 (gdbarch_disassembler_options): Use it.
13452 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
13453 not valid_disassembler_option->name.
13454 * gdbarch.c: Regenerate.
13456 2017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13458 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
13460 2017-03-07 Pedro Alves <palves@redhat.com>
13462 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
13464 2017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
13466 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
13467 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
13468 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
13469 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
13471 2017-03-06 Simon Marchi <simon.marchi@ericsson.com>
13473 * xtensa-linux-nat.c (fetch_gregs): Remove const.
13475 2017-03-03 Simon Marchi <simon.marchi@ericsson.com>
13477 * remote.c (remote_add_target_side_commands): Use range-based
13480 2017-03-03 Yao Qi <yao.qi@linaro.org>
13483 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
13485 * valprint.c (common_val_print): Likewise.
13487 2017-02-28 Peter Bergner <bergner@vnet.ibm.com>
13489 * NEWS: Mention new set/show disassembler-options commands.
13490 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
13491 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
13492 (prospective_options): New static variable.
13493 (gdb_disassembler::gdb_disassembler): Initialize
13494 m_di.disassembler_options.
13495 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
13496 (get_disassembler_options): New function.
13497 (set_disassembler_options): Likewise.
13498 (set_disassembler_options_sfunc): Likewise.
13499 (show_disassembler_options_sfunc): Likewise.
13500 (disassembler_options_completer): Likewise.
13501 (_initialize_disasm): Likewise.
13502 * disasm.h (get_disassembler_options): New prototype.
13503 (set_disassembler_options): Likewise.
13504 * gdbarch.sh (gdbarch_disassembler_options): New variable.
13505 (gdbarch_verify_disassembler_options): Likewise.
13506 * gdbarch.c: Regenerate.
13507 * gdbarch.h: Likewise.
13508 * arm-tdep.c (num_disassembly_options): Delete.
13509 (set_disassembly_style): Likewise.
13510 (arm_disassembler_options): New static variable.
13511 (set_disassembly_style_sfunc): Convert short style name into long
13512 option name. Call set_disassembler_options.
13513 (show_disassembly_style_sfunc): New function.
13514 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
13515 set_gdbarch_verify_disassembler_options.
13516 (_initialize_arm_tdep): Delete regnames variable and update callers.
13517 (arm_disassembler_options): Initialize.
13518 (disasm_options): New variable.
13519 (num_disassembly_options): Rename from this...
13520 (num_disassembly_styles): ...to this. Compute by scanning through
13522 (valid_disassembly_styles): Initialize using disasm_options.
13523 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
13524 set_arm_regname_option.
13525 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
13526 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
13527 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
13528 set_gdbarch_verify_disassembler_options.
13529 * s390-tdep.c (s390_disassembler_options): New static variable.
13530 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
13531 set_gdbarch_verify_disassembler_options.
13533 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13535 * remote.c (remote_add_target_side_condition): Remove "struct"
13536 keyword from range-based for loop.
13538 2017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13540 * remote.c (remote_add_target_side_condition): Use range-based
13541 for loop. Update comment.
13543 2017-02-27 Yao Qi <yao.qi@linaro.org>
13545 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
13547 2017-02-26 Alan Hayward <alan.hayward@arm.com>
13549 * regcache.c (regcache_raw_update): New function.
13550 (regcache_raw_read): Move code to regcache_raw_update.
13551 * regcache.h (regcache_raw_update): New declaration.
13552 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
13554 2017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
13556 * dwarf2read.c (create_debug_type_hash_table): Initialize
13557 header.signature and header.type_offset_in_tu.
13559 2017-02-24 Pedro Alves <palves@redhat.com>
13561 * symtab.c (make_file_symbol_completion_list_1): Use
13562 add_symtab_completions.
13564 2017-02-24 Alan Hayward <alan.hayward@arm.com>
13566 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
13568 2017-02-24 Alan Hayward <alan.hayward@arm.com>
13570 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
13571 I386_MAX_REGISTER_SIZE.
13572 (i386_pseudo_register_write): Likewise.
13573 (i386_process_record): Likewise.
13574 * i387-tdep.c (i387_supply_xsave): Likewise.
13575 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
13576 (store_register): Likewise.
13578 2017-02-23 Pedro Alves <palves@redhat.com>
13580 * ada-lang.c: Include "common/function-view.h".
13581 (ada_iterate_over_symbols): Adjust to use function_view as
13583 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
13584 (ada_make_symbol_completion_list): Use a lambda.
13585 (ada_exc_search_name_matches): Delete.
13586 (name_matches_regex): New.
13587 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
13588 * compile/compile-c-support.c: Include "common/function-view.h".
13589 (print_one_macro): Change prototype to accept a ui_file pointer.
13590 (write_macro_definitions): Use a lambda.
13591 * dwarf2read.c: Include "common/function-view.h".
13592 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
13593 (dw2_expand_symtabs_matching): Adjust to use function_view as
13595 * language.h: Include "common/function-view.h".
13596 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
13597 function_view as callback type.
13598 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
13599 * linespec.c: Include "common/function-view.h".
13600 (collect_info::add_symbol): New method.
13601 (struct symbol_and_data_callback, iterate_inline_only, struct
13602 symbol_matcher_data, iterate_name_matcher): Delete.
13603 (iterate_over_all_matching_symtabs): Adjust to use function_view
13604 as callback type and lambdas.
13605 (iterate_over_file_blocks): Adjust to use function_view as
13607 (decode_compound_collector): Now a class with private fields.
13608 (decode_compound_collector::release_symbols): New method.
13609 (collect_one_symbol): Rename to...
13610 (decode_compound_collector::operator()): ... this and adjust.
13611 (lookup_prefix_sym): decode_compound_collector construction bits
13612 move to decode_compound_collector ctor. Pass the
13613 decode_compound_collector object directly as callback. Remove
13614 cleanups and use decode_compound_collector::release_symbols
13616 (symtab_collector): Now a class with private fields.
13617 (symtab_collector::release_symtabs): New method.
13618 (add_symtabs_to_list): Rename to...
13619 (symtab_collector::operator()): ... this and adjust.
13620 (collect_symtabs_from_filename): symtab_collector construction
13621 bits move to symtab_collector ctor. Pass the symtab_collector
13622 object directly as callback. Remove cleanups and use
13623 symtab_collector::release_symtabs instead.
13624 (collect_symbols): Delete.
13625 (add_matching_symbols_to_info): Use lambdas.
13626 * macrocmd.c (print_macro_callback): Delete.
13627 (info_macro_command): Use a lambda.
13628 (info_macros_command): Pass print_macro_definition as callable
13630 (print_one_macro): Remove 'ignore' parameter.
13631 (macro_list_command): Adjust.
13632 * macrotab.c (macro_for_each_data::fn): Now a function_view.
13633 (macro_for_each_data::user_data): Delete field.
13634 (foreach_macro): Adjust to call the function_view.
13635 (macro_for_each): Adjust to use function_view as callback type.
13636 (foreach_macro_in_scope): Adjust to call the function_view.
13637 (macro_for_each_in_scope): Adjust to use function_view as callback
13639 * macrotab.h: Include "common/function-view.h".
13640 (macro_callback_fn): Declare a prototype instead of a pointer.
13641 Remove "user_data" parameter.
13642 (macro_for_each, macro_for_each_in_scope): Adjust to use
13643 function_view as callback type.
13644 * psymtab.c (partial_map_expand_apply)
13645 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
13646 Adjust to use function_view as callback type and to return bool.
13647 (psym_expand_symtabs_matching): Adjust to use function_view as
13649 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
13650 to use function_view as callback type and to return bool.
13651 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
13653 * symfile.c (expand_symtabs_matching): Adjust to use function_view
13655 * symfile.h: Include "common/function-view.h".
13656 (expand_symtabs_file_matcher_ftype)
13657 (expand_symtabs_symbol_matcher_ftype)
13658 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
13660 (quick_symbol_functions::map_symtabs_matching_filename)
13661 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
13662 function_view as callback type and return bool.
13663 (expand_symtabs_matching): Adjust to use function_view as callback
13665 (maintenance_expand_name_matcher)
13666 (maintenance_expand_file_matcher): Delete.
13667 (maintenance_expand_symtabs): Use lambdas.
13668 * symtab.c (iterate_over_some_symtabs): Adjust to use
13669 function_view as callback types and return bool.
13670 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
13672 (lookup_symtab_callback): Delete.
13673 (lookup_symtab): Use a lambda.
13674 (iterate_over_symbols): Adjust to use function_view as callback
13676 (struct search_symbols_data, search_symbols_file_matches)
13677 (search_symbols_name_matches): Delete.
13678 (search_symbols): Use a pair of lambdas.
13679 (struct add_name_data, add_macro_name, symbol_completion_matcher)
13680 (symtab_expansion_callback): Delete.
13681 (default_make_symbol_completion_list_break_on_1): Use lambdas.
13682 * symtab.h: Include "common/function-view.h".
13683 (iterate_over_some_symtabs): Adjust to use function_view as
13684 callback type and return bool.
13685 (iterate_over_symtabs): Adjust to use function_view as callback
13687 (symbol_found_callback_ftype): Remove 'data' parameter and return
13689 (iterate_over_symbols): Adjust to use function_view as callback
13692 2017-02-23 Pedro Alves <palves@redhat.com>
13694 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
13695 (%.o) <unittests/%.c>: New pattern.
13696 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
13697 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
13698 * common/function-view.h: New file.
13699 * unittests/function-view-selftests.c: New file.
13700 * configure: Regenerate.
13702 2017-02-23 Simon Marchi <simon.marchi@ericsson.com>
13704 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
13706 * go32-nat.c (go32_thread_alive): Likewise.
13708 2017-02-23 Yao Qi <yao.qi@linaro.org>
13710 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
13713 2017-02-23 Yao Qi <yao.qi@linaro.org>
13715 * varobj.c (varobj_clear_saved_item): Use delete instead of
13717 (update_dynamic_varobj_children): Likewise.
13719 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13721 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
13723 2017-02-21 Simon Marchi <simon.marchi@ericsson.com>
13725 * common/enum-flags.h (enum_flags::enum_flags): Initialize
13726 m_enum_value to 0 in default constructor.
13728 2017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
13730 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
13731 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
13732 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
13733 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
13734 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
13735 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
13736 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
13737 IS_STORE_CONDITIONAL_INSN.
13739 2017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13741 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
13743 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13745 * NEWS (Changes since GDB 7.12): Add DWARF-5.
13747 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13749 * dwarf2read.c (skip_one_die, read_attribute_value)
13750 (dwarf2_const_value_attr, dump_die_shallow)
13751 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
13752 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
13754 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13756 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
13757 (dwarf_parse_macro_header): Accept DWARF version 5.
13758 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
13760 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13762 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
13764 * common/common-exceptions.h (enum errors): Likewise.
13765 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
13766 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
13767 (dwarf_expr_context::execute_stack_op): Likewise.
13768 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
13770 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
13771 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
13772 (show_entry_values_debug, call_site_to_target_addr)
13773 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
13774 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
13775 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
13776 (value_of_dwarf_block_entry, indirect_pieced_value)
13777 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
13778 (disassemble_dwarf_expression): Likewise.
13779 * dwarf2read.c (process_die, inherit_abstract_dies)
13780 (read_call_site_scope): Likewise.
13781 * gdbtypes.h (struct func_type, struct call_site_parameter)
13782 (struct call_site): Likewise.
13783 * stack.c (read_frame_arg): Likewise.
13784 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
13786 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13788 * defs.h (read_unsigned_leb128): New declaration.
13789 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
13790 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
13791 (dwarf2_find_location_expression): Call also
13792 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
13793 * dwarf2loc.h (dwarf2_version): New declaration.
13794 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
13796 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
13798 (struct dwop_section_names): Add loclists_dwo.
13799 (dwop_section_names): Add .debug_loclists.dwo.
13800 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
13801 (struct dwarf2_per_cu_data): Add dwarf_version.
13802 (struct dwo_sections): Add loclists.
13803 (struct attr_abbrev): Add implicit_const.
13804 (read_indirect_line_string): New declaration.
13805 (read_unsigned_leb128): Delete declaration.
13806 (rcuh_kind): New definition.
13807 (read_and_check_comp_unit_head): Change parameter
13808 is_debug_types_section to section_kind.
13809 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
13810 (read_comp_unit_head): Change parameter abfd to section, add parameter
13811 section_kind. Handle DWARF-5.
13812 (error_check_comp_unit_head): Accept also DWARF version 5.
13813 (read_and_check_comp_unit_head): Change parameter
13814 is_debug_types_section to section_kind.
13815 (read_and_check_type_unit_head): Delete function.
13816 (read_abbrev_offset): Handle DWARF-5.
13817 (create_debug_type_hash_table): Add parameter section_kind. Process
13818 only DW_UT_type. Use signature and type_offset_in_tu from struct
13820 (create_debug_types_hash_table): Update create_debug_type_hash_table
13822 (create_all_type_units): Call create_debug_type_hash_table.
13823 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
13824 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
13826 (skip_one_die): Handle DW_FORM_implicit_const.
13827 (dwarf2_rnglists_process): New function.
13828 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
13829 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
13830 (read_attribute_value): Handle DW_FORM_implicit_const,
13832 (read_attribute): Handle DW_FORM_implicit_const.
13833 (read_indirect_string_at_offset_from): New function from
13834 read_indirect_string_at_offset.
13835 (read_indirect_string_at_offset): Call
13836 read_indirect_string_at_offset_from.
13837 (read_indirect_line_string_at_offset): New function.
13838 (read_indirect_string): New function comment.
13839 (read_indirect_line_string): New function.
13840 (read_unsigned_leb128): Make it global.
13841 (dwarf2_string_attr): Handle DWARF-5.
13842 (add_include_dir_stub, read_formatted_entries): New functions.
13843 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
13845 (per_cu_header_read_in): Update read_comp_unit_head caller.
13846 (dwarf2_version): New function.
13847 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
13849 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
13852 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13854 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
13856 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13858 * dwarf2read.c (dwarf2_ranges_process): New function from
13859 dwarf2_ranges_read.
13860 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
13861 dwarf2_ranges_process.
13863 2017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13865 * dwarf2read.c (create_debug_type_hash_table): New function from
13866 create_debug_types_hash_table.
13867 (create_debug_types_hash_table): Call create_debug_type_hash_table.
13868 (create_all_type_units, open_and_init_dwo_file): Update
13869 create_debug_types_hash_table callers.
13871 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
13874 * fork-child.c (trace_start_error): Fix thinko. va_end should
13875 refer to 'ap', not 'args'.
13877 2017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
13878 Pedro Alves <palves@redhat.com>
13881 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
13883 * fork-child.c (trace_start_error): New function.
13884 (trace_start_error_with_name): Likewise.
13885 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
13886 * inf-ptrace.c (inf_ptrace_me): Likewise.
13887 * inferior.h (trace_start_error): New prototype.
13888 (trace_start_error_with_name): Likewise.
13890 2017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
13893 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
13894 NULL before using it.
13895 * symmisc.c (maintenance_print_symbols): Likewise.
13896 (maintenance_print_msymbols): Likewise.
13898 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13900 * NEWS: Add record Python bindings entry.
13902 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13904 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
13906 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
13907 * python/py-record-btrace.c, python/py-record-btrace.h,
13908 python/py-record-full.c, python/py-record-full.h: New file.
13909 * python/py-record.c: Add include for py-record-btrace.h and
13911 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
13912 recpy_instruction_history, recpy_function_call_history, recpy_begin,
13913 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
13914 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
13916 (gdbpy_initialize_btrace): New export.
13917 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
13919 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13921 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
13922 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
13923 * python/py-record.c: New file.
13924 * python/python-internal.h (gdbpy_start_recording,
13925 gdbpy_current_recording, gdpy_stop_recording,
13926 gdbpy_initialize_record): New export.
13927 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
13928 (python_GdbMethods): Add gdbpy_start_recording,
13929 gdbpy_current_recording and gdbpy_stop_recording.
13931 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13933 * record-btrace.c (record_btrace_record_method): New function.
13934 (init_record_btrace_ops): Initialize to_record_method.
13935 * record-full.c (record_full_record_method): New function.
13936 (init_record_full_ops, init_record_full_core_ops): Add
13937 record_full_record_method.
13938 * record.h (enum record_method): New enum.
13939 * target-debug.h (target_debug_print_enum_record_method: New define.
13940 * target-delegates.c: Regenerate.
13941 * target.c (target_record_method): New function.
13942 * target.h: Include record.h.
13943 (struct target_ops) <to_record_method>: New field.
13944 (target_record_method): New export.
13946 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13948 * record.h (record_start, record_stop): New export.
13949 * record.c (record_start, record_stop): New function.
13951 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13953 * btrace.c (btrace_fetch): Copy function call segments pointer
13955 (btrace_clear): Clear the vector.
13956 (btrace_find_insn_by_number): Use binary search to find the correct
13957 function call segment.
13958 * btrace.h (brace_fun_p): New typedef.
13959 (struct btrace_thread_info) <functions>: New field.
13961 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13963 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
13964 * btrace.c (btrace_decode_error): ... here. New function.
13965 * btrace.h (btrace_decode_error): New export.
13967 2017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13969 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
13970 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
13971 btrace_find_insn_by_number): Remove special case for gaps.
13972 * btrace.h (btrace_insn_get_error): New export.
13973 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
13974 * record-btrace.c (btrace_insn_history): Print number for gaps.
13975 (record_btrace_info, record_btrace_goto): Handle gaps.
13977 2017-02-14 Tom Tromey <tom@tromey.com>
13980 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
13982 * python/py-evts.c (gdbpy_initialize_py_events): Add
13983 before_prompt registry.
13984 * python/py-events.h (events_object) <before_prompt>: New field.
13986 2017-02-14 Markus Metzger <markus.t.metzger@intel.com>
13988 * btrace.c (ftrace_new_switch): Preserve up link and flags.
13990 2017-02-13 Luis Machado <lgustavo@codesourcery.com>
13992 * symfile (_initialize_symfile): Add usage text to the load command's
13995 2017-02-10 Simon Marchi <simon.marchi@ericsson.com>
13997 * utils.c (defaulted_query): Don't query on secondary UIs.
13999 2017-02-10 Tom Tromey <tom@tromey.com>
14001 * rust-lang.c (rust_get_disr_info): Remove unused variable.
14003 2017-02-10 Tom Tromey <tom@tromey.com>
14005 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
14007 * python/py-type.c (typy_legacy_template_argument): Remove
14008 unnecessary "cleanup" local.
14010 2017-02-10 Tom Tromey <tom@tromey.com>
14012 * python/python.c (do_start_initialization): New function, from
14013 _initialize_python.
14014 (_initialize_python): Call do_start_initialization.
14015 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
14018 2017-02-10 Tom Tromey <tom@tromey.com>
14020 * python/py-prettyprint.c (pretty_print_one_value): Use
14023 2017-02-10 Tom Tromey <tom@tromey.com>
14025 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
14026 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
14028 * python/py-type.c (field_new): Use gdbpy_ref.
14029 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
14031 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
14032 (py_free_pspace): Likewise.
14033 (pspace_to_pspace_object): Likewise.
14034 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
14035 (py_free_objfile): Likewise.
14036 (objfile_to_objfile_object): Likewise.
14037 * python/py-inferior.c (delete_thread_object): Use
14039 (infpy_read_memory): Likewise.
14040 (py_free_inferior): Likewise.
14041 * python/py-evtregistry.c (create_eventregistry_object): Use
14043 * python/py-event.c (create_event_object): Use gdbpy_ref.
14045 2017-02-10 Tom Tromey <tom@tromey.com>
14047 * python/py-ref.h (gdbpy_ref_policy): Now a template.
14048 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
14050 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
14051 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
14052 python/py-exitedevent.c, python/py-finishbreakpoint.c,
14053 python/py-framefilter.c, python/py-function.c,
14054 python/py-inferior.c, python/py-infevents.c,
14055 python/py-linetable.c, python/py-newobjfileevent.c,
14056 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
14057 python/py-signalevent.c, python/py-stopevent.c,
14058 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
14059 python/py-unwind.c, python/py-utils.c, python/py-value.c,
14060 python/py-varobj.c, python/py-xmethods.c, python/python.c,
14061 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
14063 2017-02-10 Tom Tromey <tom@tromey.com>
14065 * ui-out.h (ui_out_emit_type): New class.
14066 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
14067 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
14068 and ui_out_emit_tuple.
14069 (enumerate_locals): Likewise.
14070 (py_mi_print_variables, py_print_locals, py_print_args): Use
14072 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
14074 * common/gdb_optional.h: New file.
14076 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
14078 * MAINTAINERS (Write After Approval): Update my e-mail address.
14080 2017-02-10 Martin Galvan <martingalvan@sourceware.org>
14083 * breakpoint.c (_initialize_breakpoint): Update the help description
14084 of the 'commands' command to indicate that it takes a list argument.
14086 2017-02-09 Simon Marchi <simon.marchi@ericsson.com>
14088 * interps.c (current_interp_set_logging): Remove "return".
14090 2017-02-09 Gary Benson <gbenson@redhat.com>
14092 * symtab.c (add_symtab_completions): Prevent NULL pointer
14095 2017-02-08 Pedro Alves <palves@redhat.com>
14097 * interps.c (interp::interp): Remove reference to quiet_p.
14098 (interp_set): Make static. Remove dead "Switching to" output
14100 (interp_quiet_p, interp_set_quiet): Delete.
14101 (interpreter_exec_cmd): Don't set the interpreter quiet.
14102 * interps.h (interp_quiet_p): Make static.
14103 (class interp) <quiet_p>: Remove field
14105 2017-02-08 Jerome Guitton <guitton@adacore.com>
14107 * cli/cli-decode.c (find_command_name_length): Make it extern.
14108 * cli/cli-decode.h (find_command_name_length): Declare.
14109 * cli/cli-script.c (command_name_equals, line_first_arg):
14111 (process_next_line): Use cli-decode to parse command names.
14112 (build_command_line): Make args a constant pointer.
14114 2017-02-08 Jerome Guitton <guitton@adacore.com>
14116 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
14117 Remove case-insensitive search.
14119 2017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
14121 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
14122 at the end of the line. Avoids an ARI warning.
14124 2017-02-06 Luis Machado <lgustavo@codesourcery.com>
14126 * NEWS: Mention support for record/replay of Intel 64 rdrand and
14127 rdseed instructions.
14128 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
14130 2017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
14133 Provide and use sparc32 and sparc64 target description XML files.
14134 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
14135 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
14136 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
14137 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
14138 * features/sparc/sparc32-solaris.xml: New file.
14139 * features/sparc/sparc64-solaris.xml: New file.
14140 * features/sparc/sparc32-solaris.c: Generated.
14141 * features/sparc/sparc64-solaris.c: Generated.
14142 * sparc-tdep.h: Account for differences in target descriptions.
14143 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
14144 (sparc32_register_type): Use target provided registers.
14145 (validate_tdesc_registers): New function.
14146 (sparc32_gdbarch_init): Use tdesc_has_registers.
14147 Set pseudoregister functions.
14148 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
14149 (sparc64_register_type): Use target provided registers.
14150 (sparc64_init_abi): Set pseudoregister functions.
14152 2017-02-03 Tom Tromey <tom@tromey.com>
14155 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
14156 with a single member.
14158 2017-02-03 Pedro Alves <palves@redhat.com>
14160 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
14161 (cli_interp_base::~cli_interp_base): New.
14162 (cli_interp): New struct.
14163 (as_cli_interp): Cast the interp itself to cli_interp.
14164 (cli_interpreter_pre_command_loop): Rename to ...
14165 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
14167 (cli_interpreter_init): Rename to ...
14168 (cli_interp::init): ... this. Remove 'self' parameter. Use
14169 boolean. Make extern.
14170 (cli_interpreter_resume): Rename to ...
14171 (cli_interp::resume): ... this. Remove 'data' parameter. Make
14173 (cli_interpreter_suspend): Rename to ...
14174 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
14176 (cli_interpreter_exec): Rename to ...
14177 (cli_interp::exec): ... this. Remove 'data' parameter. Make
14179 (cli_interpreter_supports_command_editing): Rename to ...
14180 (cli_interp_base::supports_command_editing): ... this. Remove
14181 'interp' parameter. Make extern.
14182 (cli_ui_out): Rename to ...
14183 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
14185 (cli_set_logging): Rename to ...
14186 (cli_interp_base::set_logging): ... this. Remove 'interp'
14187 parameter. Make extern.
14188 (cli_interp_procs): Delete.
14189 (cli_interp_factory): Adjust to use "new".
14190 * cli/cli-interp.h: Include "interps.h".
14191 (struct cli_interp_base): New struct.
14192 * interps.c (struct interp): Delete. Fields moved to interps.h.
14193 (interp_new): Delete.
14194 (interp::interp, interp::~interp): New.
14195 (interp_set): Use bool, and return void. Assume the interpreter
14196 has suspend, init and resume methods, and that the all return
14198 (set_top_level_interpreter): interp_set returns void.
14199 (interp_ui_out): Adapt.
14200 (current_interp_set_logging): Adapt.
14201 (interp_data): Delete.
14202 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
14203 (interp_exec): Adapt.
14204 (top_level_interpreter_data): Delete.
14205 * interps.h (interp_init_ftype, interp_resume_ftype)
14206 (interp_suspend_ftype, interp_exec_ftype)
14207 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
14208 (class interp): New.
14209 (interp_new): Delete.
14210 (interp_set): Now returns void. Use bool.
14211 (interp_data, top_level_interpreter_data): Delete.
14212 * mi/mi-common.h: Include interps.h.
14213 (class mi_interp): Inherit from interp. Define a ctor. Declare
14214 init, resume, suspect, exec, interp_ui_out, set_logging and
14215 pre_command_loop methods.
14216 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
14217 (mi_interpreter_init): Rename to ...
14218 (mi_interp::init): ... this. Remove the 'interp' parameter, use
14219 bool, return void and make extern. Adjust.
14220 (mi_interpreter_resume): ... Rename to ...
14221 (mi_interp::resume): ... this. Remove the 'data' parameter,
14222 return void and make extern. Adjust.
14223 (mi_interpreter_suspend): ... Rename to ...
14224 (mi_interp::suspend): ... this. Remove the 'data' parameter,
14225 return void and make extern. Adjust.
14226 (mi_interpreter_exec): ... Rename to ...
14227 (mi_interp::exec): ... this. Remove the 'data' parameter and make
14229 (mi_interpreter_pre_command_loop): ... Rename to ...
14230 (mi_interp::pre_command_loop): ... this. Remove the 'self'
14231 parameter and make extern.
14232 (mi_on_normal_stop_1): Adjust.
14233 (mi_ui_out): Rename to ...
14234 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
14235 parameter and make extern. Adjust.
14236 (mi_set_logging): Rename to ...
14237 (mi_interp::set_logging): ... this. Remove the 'interp'
14238 parameter and make extern. Adjust.
14239 (mi_interp_procs): Delete.
14240 (mi_interp_factory): Adjust to use 'new'.
14241 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
14242 (mi_print_exception, mi_execute_command, mi_load_progress):
14244 * tui/tui-interp.c (tui_interp): New class.
14245 (as_tui_interp): Return a tui_interp pointer.
14246 (tui_on_normal_stop, tui_on_signal_received)
14247 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
14248 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
14249 to use interp::interp_ui_out.
14250 (tui_init): Rename to ...
14251 (tui_interp::init): ... this. Remove the 'self' parameter, use
14252 bool, return void and make extern. Adjust.
14253 (tui_resume): Rename to ...
14254 (tui_interp::resume): ... this. Remove the 'data' parameter,
14255 return void and make extern. Adjust.
14256 (tui_suspend): Rename to ...
14257 (tui_interp::suspend): ... this. Remove the 'data' parameter,
14258 return void and make extern. Adjust.
14259 (tui_ui_out): Rename to ...
14260 (tui_interp::interp_ui_out): ... this. Remove the 'self'
14261 parameter, and make extern. Adjust.
14262 (tui_exec): Rename to ...
14263 (tui_interp::exec): ... this. Remove the 'data' parameter and
14265 (tui_interp_procs): Delete.
14266 (tui_interp_factory): Use "new".
14268 2017-02-02 Tom Tromey <tom@tromey.com>
14270 * rust-exp.y (ends_raw_string, space_then_number)
14271 (rust_identifier_start_p): Return bool.
14272 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
14273 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
14274 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
14275 (rust_chartype_p): Return bool.
14276 (val_print_struct, rust_print_struct_def, rust_print_type):
14278 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
14281 2017-02-02 Tom Tromey <tom@tromey.com>
14283 * rust-lang.c: Reindent.
14285 2017-02-02 Tom Tromey <tom@tromey.com>
14287 * rust-lang.h (rust_crate_for_block): Update.
14288 * rust-lang.c (rust_crate_for_block): Return std::string.
14289 (rust_get_disr_info): Use std:;string, not
14290 gdb::unique_xmalloc_ptr.
14291 * rust-exp.y (crate_name): Update.
14293 2017-02-02 Pedro Alves <palves@redhat.com>
14295 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
14296 field out of gdb_disassembler_test and make it static.
14298 2017-02-02 Pedro Alves <palves@redhat.com>
14300 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
14301 mi1_interp and mi_interp fields.
14303 2017-02-02 Pedro Alves <palves@redhat.com>
14305 * cli/cli-interp.c (struct saved_output_files, saved_output):
14306 Moved from cli/cli-logging.c.
14307 (cli_set_logging): New function.
14308 (cli_interp_procs): Install cli_set_logging.
14309 * cli/cli-interp.h (make_logging_output, cli_set_logging):
14311 * cli/cli-logging.c (struct saved_output_files, saved_output):
14312 Moved to cli/cli-interp.c.
14313 (pop_output_files): Don't save outputs here.
14314 (make_logging_output): New function.
14315 (handle_redirections): Don't build tee nor save previous outputs
14317 * interps.c (current_interp_set_logging): Change prototype.
14318 Assume there's always a set_logging_proc method installed.
14319 * interps.h (interp_set_logging_ftype): Change prototype.
14320 (current_interp_set_logging): Change prototype and adjust comment.
14321 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
14322 use make_logging_output.
14323 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
14324 2017-02-02 Pedro Alves <palves@redhat.com>
14326 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
14328 (set_logging_overwrite): ... here.
14329 (logging_no_redirect_file): Delete.
14330 (set_logging_redirect): Don't handle redirection on the fly.
14331 Instead warn that "logging off" / "logging on" is necessary.
14332 (pop_output_files): Delete references to logging_no_redirect_file.
14333 (show_logging_command): Always speak in terms of what will happen
14334 once logging is reenabled.
14336 2017-02-02 Pedro Alves <palves@redhat.com>
14338 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
14340 2017-02-02 Pedro Alves <palves@redhat.com>
14342 * disasm.c (gdb_pretty_print_insn): Rename to ...
14343 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
14344 Remove gdbarch parameter. Adapt to clear the object's buffers
14345 instead of allocating new buffers, and to print using the object's
14346 gdb_disassembler instead of calling gdb_print_insn.
14347 (dump_insns): Use gdb_pretty_print_disassembler.
14348 * disasm.h (gdb_pretty_print_insn): Delete declaration.
14349 (gdb_pretty_print_disassembler): New class.
14350 * record-btrace.c (btrace_insn_history): Use
14351 gdb_pretty_print_disassembler.
14353 2017-02-02 Pedro Alves <palves@redhat.com>
14355 * ada-lang.c (type_as_string): Use string_file.
14356 * ada-valprint.c (ada_print_floating): Use string_file.
14357 * ada-varobj.c (ada_varobj_scalar_image)
14358 (ada_varobj_get_value_image): Use string_file.
14359 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
14360 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
14361 * breakpoint.c (update_inserted_breakpoint_locations)
14362 (insert_breakpoint_locations, reattach_breakpoints)
14363 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
14364 (print_it_watchpoint): Use string_file.
14365 (save_breakpoints): Use stdio_file.
14366 * c-exp.y (oper): Use string_file.
14367 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
14369 (pop_output_files): Use delete.
14370 (handle_redirections): Use stdio_file and tee_file.
14371 * cli/cli-setshow.c (do_show_command): Use string_file.
14372 * compile/compile-c-support.c (c_compute_program): Use
14374 * compile/compile-c-symbols.c (generate_vla_size): Take a
14375 'string_file &' instead of a 'ui_file *'.
14376 (generate_c_for_for_one_variable): Take a 'string_file &' instead
14377 of a 'ui_file *'. Use string_file.
14378 (generate_c_for_variable_locations): Take a 'string_file &'
14379 instead of a 'ui_file *'.
14380 * compile/compile-internal.h (generate_c_for_for_one_variable):
14381 Take a 'string_file &' instead of a 'ui_file *'.
14382 * compile/compile-loc2c.c (push, pushf, unary, binary)
14383 (print_label, pushf_register_address, pushf_register)
14384 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
14385 'ui_file *'. Adjust.
14386 * compile/compile.c (compile_to_object): Use string_file.
14387 * compile/compile.h (compile_dwarf_expr_to_c)
14388 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
14390 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
14391 (replace_typedefs_qualified_name): Use string_file and
14393 * disasm.c (gdb_pretty_print_insn): Use string_file.
14394 (gdb_disassembly): Adjust reference the null_stream global.
14395 (do_ui_file_delete): Delete.
14396 (gdb_insn_length): Use null_stream.
14397 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
14398 * dwarf2loc.c (dwarf2_compile_property_to_c)
14399 (locexpr_generate_c_location, loclist_generate_c_location): Take a
14400 'string_file &' instead of a 'ui_file *'.
14401 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
14402 * dwarf2read.c (do_ui_file_peek_last): Delete.
14403 (dwarf2_compute_name): Use string_file.
14404 * event-top.c (gdb_setup_readline): Use stdio_file.
14405 * gdbarch.sh (verify_gdbarch): Use string_file.
14406 * gdbtypes.c (safe_parse_type): Use null_stream.
14407 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
14409 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
14410 'string_file *' instead of a 'ui_file *'.
14411 (gdbscm_arch_disassemble): Use string_file.
14412 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
14413 * guile/scm-ports.c (class ioscm_file_port): Now a class that
14414 inherits from ui_file.
14415 (ioscm_file_port_delete, ioscm_file_port_rewind)
14416 (ioscm_file_port_put): Delete.
14417 (ioscm_file_port_write): Rename to ...
14418 (ioscm_file_port::write): ... this. Remove file_port_magic
14420 (ioscm_file_port_new): Delete.
14421 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
14423 * guile/scm-type.c (tyscm_type_name): Use string_file.
14424 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
14426 * infcmd.c (print_return_value_1): Use string_file.
14427 * infrun.c (print_target_wait_results): Use string_file.
14428 * language.c (add_language): Use string_file.
14429 * location.c (explicit_to_string_internal): Use string_file.
14430 * main.c (captured_main_1): Use null_file.
14431 * maint.c (maintenance_print_architecture): Use stdio_file.
14432 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
14433 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
14434 event_channel>: Change type to mi_console_file pointer.
14435 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
14436 (mi_console_file_delete): Delete.
14437 (struct mi_console_file): Delete.
14438 (mi_console_file_magic): Delete.
14439 (mi_console_file_new): Delete.
14440 (mi_console_file::mi_console_file): New.
14441 (mi_console_file_delete): Delete.
14442 (mi_console_file_fputs): Delete.
14443 (mi_console_file::write): New.
14444 (mi_console_raw_packet): Delete.
14445 (mi_console_file::flush): New.
14446 (mi_console_file_flush): Delete.
14447 (mi_console_set_raw): Rename to ...
14448 (mi_console_file::set_raw): ... this.
14449 * mi/mi-console.h (class mi_console_file): New class.
14450 (mi_console_file_new, mi_console_set_raw): Delete.
14451 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
14452 (mi_set_logging): Use delete and tee_file. Adjust.
14453 * mi/mi-main.c (output_register): Use string_file.
14454 (mi_cmd_data_evaluate_expression): Use string_file.
14455 (mi_cmd_data_read_memory): Use string_file.
14456 (mi_cmd_execute, print_variable_or_computed): Use string_file.
14457 * mi/mi-out.c (mi_ui_out::main_stream): New.
14458 (mi_ui_out::rewind): Use main_stream and
14460 (mi_ui_out::put): Use main_stream and string_file.
14461 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14462 Allocate a 'string_file' instead.
14463 (mi_out_new): Don't allocate a mem_fileopen stream here.
14464 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14465 (mi_ui_out::main_stream): Declare method.
14466 * printcmd.c (eval_command): Use string_file.
14467 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
14468 * python/py-arch.c (archpy_disassemble): Use string_file.
14469 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
14470 * python/py-frame.c (frapy_str): Use string_file.
14471 * python/py-framefilter.c (py_print_type, py_print_single_arg):
14473 * python/py-type.c (typy_str): Use string_file.
14474 * python/py-unwind.c (unwind_infopy_str): Use string_file.
14475 * python/py-value.c (valpy_str): Use string_file.
14476 * record-btrace.c (btrace_insn_history): Use string_file.
14477 * regcache.c (regcache_print): Use stdio_file.
14478 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
14479 * remote.c (escape_buffer): Use string_file.
14480 * rust-lang.c (rust_get_disr_info): Use string_file.
14481 * serial.c (serial_open_ops_1): Use stdio_file.
14482 (do_serial_close): Use delete.
14483 * stack.c (print_frame_arg): Use string_file.
14484 (print_frame_args): Remove local mem_fileopen stream, not used.
14485 (print_frame): Use string_file.
14486 * symmisc.c (maintenance_print_symbols): Use stdio_file.
14487 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
14488 Take a 'string_file *' instead of a 'ui_file *'.
14489 * top.c (new_ui): Use stdio_file and stderr_file.
14490 (free_ui): Use delete.
14491 (execute_command_to_string): Use string_file.
14492 (quit_confirm): Use string_file.
14493 * tracepoint.c (collection_list::append_exp): Use string_file.
14494 * tui/tui-disasm.c (tui_disassemble): Use string_file.
14495 * tui/tui-file.c: Don't include "ui-file.h".
14496 (enum streamtype, struct tui_stream): Delete.
14497 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
14498 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
14499 (tui_file::tui_file): New method.
14500 (tui_file_fputs): Delete.
14501 (tui_file_get_strbuf): Delete.
14502 (tui_file::puts): New method.
14503 (tui_file_adjust_strbuf): Delete.
14504 (tui_file_flush): Delete.
14505 (tui_file::flush): New method.
14506 * tui/tui-file.h: Tweak intro comment.
14508 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
14509 (tui_file_adjust_strbuf): Delete declarations.
14510 (class tui_file): New class.
14511 * tui/tui-io.c (tui_initialize_io): Use tui_file.
14512 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
14513 (tui_register_format): Use string_stream.
14514 * tui/tui-stack.c (tui_make_status_line): Use string_file.
14515 (tui_get_function_from_frame): Use string_file.
14516 * typeprint.c (type_to_string): Use string_file.
14517 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
14518 (null_stream): New global.
14519 (ui_file_delete): Delete.
14520 (ui_file::ui_file): New.
14521 (null_file_isatty): Delete.
14522 (ui_file::~ui_file): New.
14523 (null_file_rewind): Delete.
14524 (ui_file::printf): New.
14525 (null_file_put): Delete.
14526 (null_file_flush): Delete.
14527 (ui_file::putstr): New.
14528 (null_file_write): Delete.
14529 (ui_file::putstrn): New.
14530 (null_file_read): Delete.
14531 (ui_file::putc): New.
14532 (null_file_fputs): Delete.
14533 (null_file_write_async_safe): Delete.
14534 (ui_file::vprintf): New.
14535 (null_file_delete): Delete.
14536 (null_file::write): New.
14537 (null_file_fseek): Delete.
14538 (null_file::puts): New.
14539 (ui_file_data): Delete.
14540 (null_file::write_async_safe): New.
14541 (gdb_flush, ui_file_isatty): Adjust.
14542 (ui_file_put, ui_file_rewind): Delete.
14543 (ui_file_write): Adjust.
14544 (ui_file_write_for_put): Delete.
14545 (ui_file_write_async_safe, ui_file_read): Adjust.
14546 (ui_file_fseek): Delete.
14547 (fputs_unfiltered): Adjust.
14548 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
14549 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
14550 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
14551 (set_ui_file_data): Delete.
14552 (string_file::~string_file, string_file::write)
14553 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
14554 (do_ui_file_as_string, ui_file_as_string): Delete.
14555 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
14556 (struct mem_file): Delete.
14557 (mem_file_new): Delete.
14558 (stdio_file::stdio_file): New.
14559 (mem_file_delete): Delete.
14560 (stdio_file::stdio_file): New.
14561 (mem_fileopen): Delete.
14562 (stdio_file::~stdio_file): New.
14563 (mem_file_rewind): Delete.
14564 (stdio_file::set_stream): New.
14565 (mem_file_put): Delete.
14566 (stdio_file::open): New.
14567 (mem_file_write): Delete.
14568 (stdio_file_magic, struct stdio_file): Delete.
14569 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
14570 (stdio_file::flush): New.
14571 (stdio_file_read): Rename to ...
14572 (stdio_file::read): ... this. Adjust.
14573 (stdio_file_write): Rename to ...
14574 (stdio_file::write): ... this. Adjust.
14575 (stdio_file_write_async_safe): Rename to ...
14576 (stdio_file::write_async_safe) ... this. Adjust.
14577 (stdio_file_fputs): Rename to ...
14578 (stdio_file::puts) ... this. Adjust.
14579 (stdio_file_isatty): Delete.
14580 (stdio_file_fseek): Delete.
14581 (stdio_file::isatty): New.
14582 (stderr_file_write): Rename to ...
14583 (stderr_file::write) ... this. Adjust.
14584 (stderr_file_fputs): Rename to ...
14585 (stderr_file::puts) ... this. Adjust.
14586 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
14587 (stderr_file::stderr_file): New.
14588 (tee_file_magic): Delete.
14589 (struct tee_file): Delete.
14590 (tee_file::tee_file): New.
14591 (tee_file_new): Delete.
14592 (tee_file::~tee_file): New.
14593 (tee_file_delete): Delete.
14594 (tee_file_flush): Rename to ...
14595 (tee_file::flush): ... this. Adjust.
14596 (tee_file_write): Rename to ...
14597 (tee_file::write): ... this. Adjust.
14598 (tee_file::write_async_safe): New.
14599 (tee_file_fputs): Rename to ...
14600 (tee_file::puts): ... this. Adjust.
14601 (tee_file_isatty): Rename to ...
14602 (tee_file::isatty): ... this. Adjust.
14603 * ui-file.h (struct obstack, struct ui_file): Don't
14605 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
14606 (ui_file_write_ftype)
14607 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
14608 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
14609 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
14610 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
14611 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
14612 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
14613 (set_ui_file_fseek): Delete.
14614 (ui_file_data, ui_file_delete, ui_file_rewind)
14615 (struct ui_file): New.
14617 (class null_file): New.
14618 (null_stream): Declare.
14619 (ui_file_write_for_put, ui_file_put): Delete.
14620 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
14622 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
14623 (gdb_fopen, tee_file_new): Delete.
14624 (struct string_file): New.
14625 (struct stdio_file): New.
14626 (stdio_file_up): New.
14627 (struct stderr_file): New.
14628 (class tee_file): New.
14629 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
14630 of a 'ui_file *'. Adjust.
14631 * ui-out.h (class ui_out) <field_stream>: Likewise.
14632 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
14633 (null_stream): Delete.
14634 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
14636 * utils.h (struct ui_file): Delete forward declaration..
14637 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
14638 (error_stream): Take a 'string_file &' instead of a
14640 * varobj.c (varobj_value_get_print_value): Use string_file.
14641 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
14642 * gdbarch.c: Regenerate.
14644 2017-02-02 Pedro Alves <palves@redhat.com>
14646 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
14647 (gdb_pretty_print_insn): ... this. Now a free function. Add back
14648 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
14649 Adjust to call gdb_print_insn instead of
14650 gdb_disassembler::print_insn.
14651 (dump_insns, do_mixed_source_and_assembly_deprecated)
14652 (do_mixed_source_and_assembly, do_assembly_only): Add back a
14653 'gdbarch' parameter. Remove gdb_disassembler parameter.
14654 (gdb_disassembly): Don't allocate a gdb_disassembler here.
14655 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
14657 (gdb_pretty_print_insn): Re-add declaration.
14658 * record-btrace.c (btrace_insn_history): Don't allocate a
14659 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
14661 2017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
14663 * disasm.h (gdb_disassembly): Remove file_string parameter.
14664 * disasm.c (gdb_disassembly): Likewise.
14665 * cli/cli-cmds.c (print_disassembly): Adapt.
14666 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
14667 * stack.c (do_gdb_disassembly): Likewise.
14669 2017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
14671 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
14672 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
14673 targets. And if the implicit value is longer than needed, extract
14674 the first bytes instead of the "least significant" ones.
14676 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14678 * btrace.c (btrace_enable): Do not call btrace_add_pc for
14679 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
14680 (btrace_fetch): Assert can_access_registers_ptid.
14681 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
14682 validate_registers_access.
14684 2017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14686 * gdbthread.h (can_access_registers_ptid): New.
14687 * thread.c (can_access_registers_ptid): New.
14689 2017-02-01 Pedro Alves <palves@redhat.com>
14691 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
14693 2017-01-31 Pedro Alves <palves@redhat.com>
14695 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
14698 2017-01-31 Pedro Alves <palves@redhat.com>
14700 * stack.c (print_frame_args): Remove local mem_fileopen stream,
14703 2017-01-31 Pedro Alves <palves@redhat.com>
14705 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
14707 2017-01-31 Pedro Alves <palves@redhat.com>
14709 * common/scoped_restore.h
14710 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
14711 change the value's parameter type to T2.
14712 (make_scoped_restore): Likewise.
14714 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14715 Richard Henderson <rth@redhat.com>
14717 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
14718 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
14719 GS_BASE for older kernels.
14720 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
14721 GS_BASE for older kernels.
14722 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
14723 and GS_BASE to the offset table.
14724 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
14725 system register group.
14726 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
14728 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
14730 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
14731 AMD64_GSBASE_REGNUM.
14732 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
14733 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
14734 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
14735 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
14736 i386/64bit-segments.xml in those rules.
14737 * features/i386/64bit-segments.xml: New file.
14738 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
14739 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
14740 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
14741 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
14742 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
14743 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
14744 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
14745 * features/i386/amd64-avx-linux.c: Regenerated.
14746 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
14747 * features/i386/amd64-avx-mpx.c: Regenerated.
14748 * features/i386/amd64-avx512-linux.c: Regenerated.
14749 * features/i386/amd64-linux.c: Regenerated.
14750 * features/i386/amd64-mpx-linux.c: Regenerated.
14751 * features/i386/i386-avx-mpx-linux.c: Regenerated.
14752 * features/i386/i386-avx-mpx.c: Regenerated.
14753 * features/i386/x32-avx-linux.c: Regenerated.
14754 * features/i386/x32-avx512-linux.c: Regenerated.
14755 * regformats/i386/amd64-avx-linux.dat: Regenerated.
14756 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
14757 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
14758 * regformats/i386/amd64-linux.dat: Regenerated.
14759 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
14760 * regformats/i386/x32-avx-linux.dat: Regenerated.
14761 * regformats/i386/x32-avx512-linux.dat: Regenerated.
14762 * regformats/i386/x32-linux.dat: Regenerated.
14764 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14766 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
14767 Set to AMD64_NUM_REGS.
14769 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14771 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
14772 that checks validity of a register number.
14774 2017-01-27 Kees Cook <keescook@google.com>
14776 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
14777 fetch_fpregs if target has fpa registers.
14778 (arm_linux_store_inferior_registers): Call store_fpregs if target
14781 2017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
14783 * cris-tdep.c (cris_gdbarch_init): Remove check for
14784 info.byte_order and force it to BFD_ENDIAN_LITTLE.
14786 2017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
14788 * corelow.c (get_core_register_section): Check for regset
14789 existence before checking for REGSET_VARIABLE_SIZE.
14791 2017-01-26 Yao Qi <yao.qi@linaro.org>
14792 Pedro Alves <palves@redhat.com>
14795 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
14796 call memory_error, save memaddr instead.
14797 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
14798 negative, cal memory_error.
14799 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
14801 2017-01-26 Yao Qi <yao.qi@linaro.org>
14803 * disasm-selftests.c (memory_error_test): New function.
14804 (_initialize_disasm_selftests): Register memory_error_test.
14806 2017-01-26 Yao Qi <yao.qi@linaro.org>
14808 * Makefile.in (SFILES): Add disasm-selftests.c and
14810 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
14811 * disasm-selftests.c: New file.
14812 * selftest-arch.c: New file.
14813 * selftest-arch.h: New file.
14815 2017-01-26 Yao Qi <yao.qi@linaro.org>
14817 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
14818 to bfd_arch_mep. Don't return 0 if section is not
14819 found. Call print_insn_mep.
14821 2017-01-26 Pedro Alves <palves@redhat.com>
14822 Yao Qi <yao.qi@linaro.org>
14824 * arm-tdep.c: Include "disasm.h".
14825 (gdb_print_insn_arm): Update code to get gdbarch.
14826 * disasm.c (dis_asm_read_memory): Change it to
14827 gdb_disassembler::dis_asm_read_memory.
14828 (dis_asm_memory_error): Likewise.
14829 (dis_asm_print_address): Likewise.
14830 (gdb_pretty_print_insn): Change it to
14831 gdb_disassembler::pretty_print_insn.
14832 (dump_insns): Add one argument gdb_disassemlber. All
14834 (do_mixed_source_and_assembly_deprecated): Likewise.
14835 (do_mixed_source_and_assembly): Likewise.
14836 (do_assembly_only): Likewise.
14837 (gdb_disassembler::gdb_disassembler): New.
14838 (gdb_disassembler::print_insn): New.
14839 * disasm.h (class gdb_disassembler): New.
14840 (gdb_pretty_print_insn): Remove declaration.
14841 (gdb_disassemble_info): Likewise.
14842 * guile/scm-disasm.c (class gdbscm_disassembler): New.
14843 (gdbscm_disasm_read_memory_worker): Update.
14844 (gdbscm_disasm_read_memory): Update.
14845 (gdbscm_disasm_memory_error): Remove.
14846 (gdbscm_disasm_print_address): Remove.
14847 (gdbscm_disassembler::gdbscm_disassembler): New.
14848 (gdbscm_print_insn_from_port): Update.
14849 * mips-tdep.c: Include disasm.h.
14850 (gdb_print_insn_mips): Update code to get gdbarch.
14851 * record-btrace.c (btrace_insn_history): Update.
14852 * spu-tdep.c: Include disasm.h.
14853 (struct spu_dis_asm_data): Remove.
14854 (struct spu_dis_asm_info): New.
14855 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
14857 (gdb_print_insn_spu): Cast disassemble_info to
14860 2017-01-26 Yao Qi <yao.qi@linaro.org>
14862 * disasm.c (do_ui_file_delete): Delete.
14863 (gdb_insn_length): Move code creating stream to ...
14864 * utils.c (null_stream): ... here. New function.
14865 * utils.h (null_stream): Declare.
14867 2017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
14869 * python/py-inferior.c (find_thread_object): Return directly
14870 from the loop. Remove "found" variable.
14872 2017-01-21 Joel Brobecker <brobecker@adacore.com>
14874 GDB 7.12.1 released.
14876 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
14878 * python/py-function.c (fnpy_call): Reorder declarations to have
14879 the gdbpy_enter object declared first.
14880 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
14882 2017-01-20 Simon Marchi <simon.marchi@ericsson.com>
14885 * python/python-internal.h (PyMem_RawMalloc): Define for
14887 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
14888 PyMem_RawMalloc instead of PyMem_Malloc.
14890 2017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
14891 Luis Machado <lgustavo@codesourcery.com>
14893 * NEWS (New commands): Mention flash-erase.
14894 (New MI commands): Mention target-flash-erase.
14895 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
14897 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
14898 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
14899 * target.c (flash_erase_command): New function.
14900 (initialize_targets): Add new flash-erase command.
14901 * target.h (flash_erase_command): New declaration.
14903 2017-01-20 Joel Brobecker <brobecker@adacore.com>
14905 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
14906 HAVE_SYS_PROCFS_H is defined.
14908 2017-01-18 Alan Hayward <alan.hayward@arm.com>
14910 * remote.c (struct cached_reg): Change data into a pointer.
14911 * (stop_reply_dtr): Free data pointers before deleting vector.
14912 (process_stop_reply): Likewise.
14913 (remote_parse_stop_reply): Allocate space for data
14915 2017-01-18 Alan Hayward <alan.hayward@arm.com>
14917 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
14919 (amd64_pseudo_register_read_value): Likewise.
14920 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
14921 (store_register_using_P): Likewise.
14922 * regcache.c (regcache_xfer_part): Likewise.
14924 2017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
14926 Split real and pseudo registers.
14927 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
14928 (sparc32_pseudo_regnum): New enum.
14929 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
14930 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
14931 (SPARC32_CP0_REGISTERS): New macro.
14932 (sparc32_pseudo_register_name): New function.
14933 (sparc32_register_name): Use sparc32_pseudo_register_name.
14934 (sparc32_pseudo_register_type): New function.
14935 (sparc32_register_type): Use sparc32_pseudo_register_type.
14936 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
14937 pseudo register numbers.
14938 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
14939 (SPARC64_CP0_REGISTERS): New macro.
14940 (sparc64_pseudo_register_name): New function.
14941 (sparc64_register_name): Use sparc64_pseudo_register_name.
14942 (sparc64_pseudo_register_type): New function.
14943 (sparc64_register_type): Use sparc64_pseudo_register_type.
14944 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
14945 pseudo register numbers.
14946 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
14947 sparc64_store_arguments): Handle pseudo register numbers.
14949 2017-01-13 Yao Qi <yao.qi@linaro.org>
14951 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
14952 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
14954 (getpkt_or_notif_sane_1): Likewise.
14956 2017-01-13 Yao Qi <yao.qi@linaro.org>
14958 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
14959 of CC. Pass "-x c++-header" instead of "-x c".
14961 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
14963 * remote.c (remote_can_async_p): Update comment.
14965 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
14967 * linux-nat.c (linux_nat_can_async_p): Update comment.
14969 2017-01-12 Simon Marchi <simon.marchi@ericsson.com>
14971 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
14973 2017-01-11 Simon Marchi <simon.marchi@ericsson.com>
14975 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
14977 2017-01-10 Tom Tromey <tom@tromey.com>
14979 * python/py-type.c (typy_legacy_template_argument): Update.
14980 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
14981 ~demangle_parse_info): Declare new members.
14982 (cp_demangled_name_to_comp): Return unique_ptr.
14983 (cp_demangled_name_parse_free)
14984 (make_cleanup_cp_demangled_name_parse_free)
14985 (cp_new_demangle_parse_info): Remove.
14986 * cp-support.c (do_demangled_name_parse_free_cleanup)
14987 (make_cleanup_cp_demangled_name_parse_free): Remove.
14988 (inspect_type, cp_canonicalize_string_full)
14989 (cp_canonicalize_string): Update.
14990 (mangled_name_to_comp): Change return type.
14991 (cp_class_name_from_physname, method_name_from_physname)
14992 (cp_func_name, cp_remove_params): Update.
14993 * cp-name-parser.y (demangle_parse_info): New constructor, from
14994 cp_new_demangle_parse_info.
14995 (~demangle_parse_info): New destructor, from
14996 cp_demangled_name_parse_free.
14997 (cp_merge_demangle_parse_infos): Update.
14998 (cp_demangled_name_to_comp): Change return type.
15000 2017-01-10 Tom Tromey <tom@tromey.com>
15002 * top.c (prevent_dont_repeat): Change return type.
15003 * python/python.c (execute_gdb_command): Use std::string.
15005 * guile/guile.c (gdbscm_execute_gdb_command): Update.
15006 * command.h (prevent_dont_repeat): Change return type.
15007 * breakpoint.c (bpstat_do_actions_1): Update.
15009 2017-01-10 Tom Tromey <tom@tromey.com>
15011 * value.h (scoped_value_mark::~scoped_value_mark): Call
15013 (scoped_value_mark::free_to_mark): New method.
15014 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
15017 2017-01-10 Tom Tromey <tom@tromey.com>
15019 * python/py-value.c (valpy_dereference, valpy_referenced_value)
15020 (valpy_reference_value, valpy_const_value, valpy_get_address)
15021 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
15022 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
15023 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
15024 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
15026 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
15027 * value.h (scoped_value_mark): New class.
15029 2017-01-10 Tom Tromey <tom@tromey.com>
15031 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
15032 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
15033 * psymtab.c (discard_psymtabs_upto): Remove.
15034 (make_cleanup_discard_psymtabs): Remove.
15035 (struct psymtab_state): Remove.
15037 2017-01-10 Tom Tromey <tom@tromey.com>
15039 * record-full.c (record_full_save_cleanups): Remove.
15040 (record_full_save): Use gdb::unlinker.
15041 * gcore.c (do_bfd_delete_cleanup): Remove.
15042 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
15044 * dwarf2read.c (unlink_if_set): Remove.
15045 (write_psymtabs_to_index): Use gdb::unlinker.
15046 * common/gdb_unlinker.h: New file.
15048 2017-01-10 Tom Tromey <tom@tromey.com>
15050 * windows-tdep.c (windows_xfer_shared_library): Update.
15051 * windows-nat.c (windows_make_so): Update.
15052 * utils.h (make_cleanup_bfd_unref): Remove.
15053 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
15054 * symfile.h (symfile_bfd_open)
15055 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
15056 * symfile.c (read_symbols, symbol_file_add)
15057 (separate_debug_file_exists): Update.
15058 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
15059 (generic_load, reread_symbols): Update.
15060 * symfile-mem.c (symbol_file_add_from_memory): Update.
15061 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
15062 (spu_symbol_file_add_from_memory): Update.
15063 * solist.h (struct target_so_ops) <bfd_open>: Return
15065 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
15066 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
15068 (solib_map_sections, reload_shared_libraries_1): Update.
15069 * solib-svr4.c (enable_break): Update.
15070 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
15071 * solib-frv.c (enable_break2): Update.
15072 * solib-dsbt.c (enable_break): Update.
15073 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
15075 (darwin_solib_get_all_image_info_addr_at_init): Update.
15076 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
15077 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
15078 * record-full.c (record_full_save): Update.
15079 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
15080 * procfs.c (insert_dbx_link_bpt_in_file): Update.
15081 * minidebug.c (find_separate_debug_file_in_section): Return
15083 * machoread.c (macho_add_oso_symfile): Change abfd to
15085 (macho_symfile_read_all_oso): Update.
15086 (macho_check_dsym): Return gdb_bfd_ref_ptr.
15087 (macho_symfile_read): Update.
15088 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
15089 (jit_bfd_try_read_symtab): Update.
15090 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15091 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15092 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15094 (gdb_bfd_ref_policy): New struct.
15095 (gdb_bfd_ref_ptr): New typedef.
15096 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15097 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15098 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15100 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15101 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15102 (gcore_command): Update.
15103 * exec.c (exec_file_attach): Update.
15104 * elfread.c (elf_symfile_read): Update.
15105 * dwarf2read.c (dwarf2_get_dwz_file): Update.
15106 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
15107 (open_and_init_dwo_file): Update.
15108 (open_dwp_file): Return gdb_bfd_ref_ptr.
15109 (open_and_init_dwp_file): Update.
15110 * corelow.c (core_open): Update.
15111 * compile/compile-object-load.c (compile_object_load): Update.
15112 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
15113 * coffread.c (coff_symfile_read): Update.
15114 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
15115 gdb_bfd_ref_ptr. Rename.
15116 (dump_bfd_file, restore_command): Update.
15117 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15118 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15119 (find_separate_debug_file_by_buildid): Update.
15121 2017-01-10 Tom Tromey <tom@tromey.com>
15123 * common/gdb_ref_ptr.h: New file.
15124 * python/py-ref.h (struct gdbpy_ref_policy): New.
15125 (gdbpy_ref): Now a typedef.
15127 2017-01-10 Tom Tromey <tom@tromey.com>
15129 * utils.h (make_cleanup_htab_delete): Don't declare.
15130 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
15132 * linespec.c (decode_compound_collector): Add constructor,
15134 (lookup_prefix_sym): Remove cleanup.
15135 (symtab_collector): Add constructor, destructor.
15136 (collect_symtabs_from_filename): Remove cleanup.
15137 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
15138 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
15140 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
15141 * dwarf2read.c (dw2_expand_symtabs_matching)
15142 (dw2_map_symbol_filenames, dwarf_decode_macros)
15143 (write_psymtabs_to_index): Use htab_up.
15144 * dwarf2loc.c (func_verify_no_selftailcall)
15145 (call_site_find_chain_1, func_verify_no_selftailcall)
15146 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
15147 std::vector, gdb::unique_xmalloc_ptr.
15148 (call_sitep): Remove typedef.
15149 (dwarf2_locexpr_baton_eval): Remove unused variable.
15151 2017-01-10 Tom Tromey <tom@tromey.com>
15153 * python/python-internal.h (make_cleanup_py_decref)
15154 (make_cleanup_py_xdecref): Don't declare.
15155 * python/py-utils.c (py_decref, make_cleanup_py_decref)
15156 (py_xdecref, make_cleanup_py_xdecref): Remove.
15158 2017-01-10 Tom Tromey <tom@tromey.com>
15160 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
15161 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
15163 2017-01-10 Tom Tromey <tom@tromey.com>
15165 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
15167 2017-01-10 Tom Tromey <tom@tromey.com>
15169 * python/py-utils.c (unicode_to_encoded_string)
15170 (python_string_to_target_string)
15171 (python_string_to_target_python_string)
15172 (python_string_to_host_string, gdbpy_obj_to_string)
15173 (get_addr_from_python): Use gdbpy_ref.
15175 2017-01-10 Tom Tromey <tom@tromey.com>
15177 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
15180 2017-01-10 Tom Tromey <tom@tromey.com>
15182 * python/python.c (eval_python_command, gdbpy_decode_line)
15183 (gdbpy_run_events, gdbpy_start_type_printers)
15184 (gdbpy_apply_type_printers): Use gdbpy_ref.
15186 2017-01-10 Tom Tromey <tom@tromey.com>
15188 * python/py-param.c (get_doc_string, compute_enum_values): Use
15191 2017-01-10 Tom Tromey <tom@tromey.com>
15193 * python/py-inferior.c (find_thread_object, build_inferior_list):
15196 2017-01-10 Tom Tromey <tom@tromey.com>
15198 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15200 2017-01-10 Tom Tromey <tom@tromey.com>
15202 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
15205 2017-01-10 Tom Tromey <tom@tromey.com>
15207 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
15209 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
15212 2017-01-10 Tom Tromey <tom@tromey.com>
15214 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15217 2017-01-10 Tom Tromey <tom@tromey.com>
15219 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
15220 decref results of PyArg_ParseTupleAndKeywords.
15222 2017-01-10 Tom Tromey <tom@tromey.com>
15224 * python/python.c (python_run_simple_file): Use
15225 unique_xmalloc_ptr, gdbpy_ref.
15227 2017-01-10 Tom Tromey <tom@tromey.com>
15229 * python/py-prettyprint.c (print_stack_unless_memory_error)
15230 (print_string_repr, print_children): Use gdbpy_ref.
15231 (dummy_python_frame): New class.
15232 (dummy_python_frame::dummy_python_frame): Rename from
15233 push_dummy_python_frame.
15234 (py_restore_tstate): Remove.
15236 2017-01-10 Tom Tromey <tom@tromey.com>
15238 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15240 2017-01-10 Tom Tromey <tom@tromey.com>
15242 * python/python.c (ensure_python_env, restore_python_env):
15244 * python/python-internal.h (ensure_python_env): Don't declare.
15245 * varobj.h (varobj_ensure_python_env): Don't declare.
15246 * varobj.c (varobj_ensure_python_env): Remove.
15248 2017-01-10 Tom Tromey <tom@tromey.com>
15250 * varobj.c (varobj_value_get_print_value): Use
15251 gdbpy_enter_varobj.
15253 2017-01-10 Tom Tromey <tom@tromey.com>
15255 * python/py-prettyprint.c (print_string_repr, print_children):
15257 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
15259 * varobj.c (varobj_value_get_print_value): Update.
15260 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
15262 2017-01-10 Tom Tromey <tom@tromey.com>
15264 * varobj.c (varobj_get_display_hint)
15265 (dynamic_varobj_has_child_method, install_new_value_visualizer)
15266 (varobj_set_visualizer, free_variable): Use
15267 gdbpy_enter_varobj.
15269 2017-01-10 Tom Tromey <tom@tromey.com>
15271 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
15272 (do_finish_initialization): New function. Use gdbpy_ref.
15273 (gdbpy_finish_initialization): Use gdbpy_enter. Call
15274 do_finish_initialization.
15276 2017-01-10 Tom Tromey <tom@tromey.com>
15278 * python/py-param.c (get_set_value, get_show_value): Use
15279 gdbpy_enter, gdbpy_ref.
15281 2017-01-10 Tom Tromey <tom@tromey.com>
15283 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
15285 2017-01-10 Tom Tromey <tom@tromey.com>
15287 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
15289 2017-01-10 Tom Tromey <tom@tromey.com>
15291 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
15292 Use gdbpy_enter_varobj.
15294 2017-01-10 Tom Tromey <tom@tromey.com>
15296 * varobj.c (gdbpy_enter_varobj): New constructor.
15297 * python/python-internal.h (gdbpy_enter_varobj): New class.
15298 * python/py-varobj.c (py_varobj_get_iterator): Use
15299 gdbpy_enter_varobj.
15301 2017-01-10 Tom Tromey <tom@tromey.com>
15303 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
15304 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15305 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
15306 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
15307 unique_xmalloc_ptr.
15308 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
15310 2017-01-10 Tom Tromey <tom@tromey.com>
15312 * python/py-xmethods.c (invoke_match_method): Use
15315 2017-01-10 Tom Tromey <tom@tromey.com>
15317 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
15318 gdbpy_enter, gdbpy_ref.
15320 2017-01-10 Tom Tromey <tom@tromey.com>
15322 * python/python.c (python_interactive_command): Use gdbpy_enter.
15324 2017-01-10 Tom Tromey <tom@tromey.com>
15326 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
15329 2017-01-10 Tom Tromey <tom@tromey.com>
15331 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
15332 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15334 2017-01-10 Tom Tromey <tom@tromey.com>
15336 * utils.h (htab_deleter): New struct.
15337 (htab_up): New typedef.
15338 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
15339 gdbpy_enter, gdbpy_ref, htab_up.
15341 2017-01-10 Tom Tromey <tom@tromey.com>
15343 * python/py-unwind.c (pending_frame_invalidate): Remove.
15344 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
15346 2017-01-10 Tom Tromey <tom@tromey.com>
15348 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
15349 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
15351 2017-01-10 Tom Tromey <tom@tromey.com>
15353 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
15355 2017-01-10 Tom Tromey <tom@tromey.com>
15357 * python/python.c (gdbpy_eval_from_control_command)
15358 (gdbpy_source_script, gdbpy_run_events)
15359 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
15360 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
15363 2017-01-10 Tom Tromey <tom@tromey.com>
15365 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
15367 2017-01-10 Tom Tromey <tom@tromey.com>
15369 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
15371 2017-01-10 Tom Tromey <tom@tromey.com>
15373 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
15374 (python_on_inferior_call_pre, python_on_inferior_call_post)
15375 (python_on_memory_change, python_on_register_change)
15376 (python_inferior_exit, python_new_objfile, add_thread_object)
15377 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
15379 2017-01-10 Tom Tromey <tom@tromey.com>
15381 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
15382 (bpfinishpy_handle_exit): Use gdbpy_enter.
15384 2017-01-10 Tom Tromey <tom@tromey.com>
15386 * python/py-cmd.c (cmdpy_destroyer)
15387 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
15390 2017-01-10 Tom Tromey <tom@tromey.com>
15392 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15394 (gdbpy_breakpoint_has_cond): Likewise.
15396 2017-01-10 Tom Tromey <tom@tromey.com>
15398 * python/python.c (gdbpy_enter): New constructor.
15399 (~gdbpy_enter): New destructor.
15400 (restore_python_env, ensure_python_env): Rewrite.
15401 * python/python-internal.h (gdbpy_enter): New class.
15403 2017-01-10 Tom Tromey <tom@tromey.com>
15405 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
15407 2017-01-10 Tom Tromey <tom@tromey.com>
15409 * python/py-value.c (value_has_field, get_field_flag)
15410 (get_field_type, valpy_getitem, convert_value_from_python): Use
15413 2017-01-10 Tom Tromey <tom@tromey.com>
15415 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
15418 2017-01-10 Tom Tromey <tom@tromey.com>
15420 * python/py-prettyprint.c (search_pp_list)
15421 (find_pretty_printer_from_objfiles)
15422 (find_pretty_printer_from_progspace)
15423 (find_pretty_printer_from_gdb, find_pretty_printer)
15424 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
15427 2017-01-10 Tom Tromey <tom@tromey.com>
15429 * python/py-param.c (call_doc_function): Use gdbpy_ref.
15431 2017-01-10 Tom Tromey <tom@tromey.com>
15433 * python/py-linetable.c (build_line_table_tuple_from_pcs)
15434 (ltpy_get_all_source_lines): Use gdbpy_ref.
15436 2017-01-10 Tom Tromey <tom@tromey.com>
15438 * python/py-framefilter.c (extract_sym, extract_value)
15439 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
15442 2017-01-10 Tom Tromey <tom@tromey.com>
15444 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
15446 2017-01-10 Tom Tromey <tom@tromey.com>
15448 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
15450 2017-01-10 Tom Tromey <tom@tromey.com>
15452 * python/py-function.c (convert_values_to_python, fnpy_init): Use
15455 2017-01-10 Tom Tromey <tom@tromey.com>
15457 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
15459 2017-01-10 Tom Tromey <tom@tromey.com>
15461 * python/py-type.c (convert_field, make_fielditem, typy_fields)
15462 (typy_range): Use gdbpy_ref.
15464 2017-01-10 Tom Tromey <tom@tromey.com>
15466 * python/py-threadevent.c (create_thread_event_object): Use
15468 * python/py-stopevent.c (create_stop_event_object): Simplify.
15469 (emit_stop_event): Use gdbpy_ref.
15470 * python/py-signalevent.c (create_signal_event_object): Use
15472 * python/py-newobjfileevent.c (create_new_objfile_event_object)
15473 (emit_new_objfile_event, create_clear_objfiles_event_object)
15474 (emit_clear_objfiles_event): Use gdbpy_ref.
15475 * python/py-infevents.c (create_inferior_call_event_object)
15476 (create_register_changed_event_object)
15477 (create_memory_changed_event_object, emit_inferior_call_event)
15478 (emit_memory_changed_event, emit_register_changed_event): Use
15480 * python/py-exitedevent.c (create_exited_event_object)
15481 (emit_exited_event): Use gdbpy_ref.
15482 * python/py-event.h (evpy_emit_event): Remove
15483 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
15484 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
15485 * python/py-continueevent.c (emit_continue_event): Use
15487 * python/py-breakpoint.c (gdbpy_breakpoint_created)
15488 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
15490 * python/py-bpevent.c (create_breakpoint_event_object): Use
15493 2017-01-10 Tom Tromey <tom@tromey.com>
15495 * python/py-ref.h: New file.
15497 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15499 * cli-out.c (cli_ui_out::do_redirect): Change return type to
15501 * cli-out.h (cli_ui_out::do_redirect): Likewise.
15502 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
15503 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
15504 * ui-out.c (ui_out::redirect): Likewise.
15505 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
15506 * cli/cli-logging.c (set_logging_redirect): Update call site of
15508 (handle_redirections): Likewise.
15509 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
15510 * top.c (execute_command_to_string): Likewise.
15511 * utils.c (do_ui_out_redirect_pop): Likewise.
15513 2017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15515 * stack.c (_initialize_stack): Update "frame" command help message.
15517 2017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
15519 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
15521 2017-01-06 Yao Qi <yao.qi@linaro.org>
15523 * x86-linux-nat.h: Include gdb_proc_service.h.
15525 2017-01-06 Yao Qi <yao.qi@linaro.org>
15527 * ser-base.h: Include serial.h.
15529 2017-01-06 Yao Qi <yao.qi@linaro.org>
15531 * ppc-linux-tdep.h: Include ppc-tdep.h.
15533 2017-01-06 Yao Qi <yao.qi@linaro.org>
15535 * nat/amd64-linux-siginfo.h: Include signal.h.
15537 2017-01-06 Yao Qi <yao.qi@linaro.org>
15539 * nat/aarch64-linux-hw-point.h: Include break-common.h.
15541 2017-01-06 Yao Qi <yao.qi@linaro.org>
15543 * mi/mi-parse.h: Include mi-cmds.h.
15545 2017-01-06 Yao Qi <yao.qi@linaro.org>
15547 * inf-loop.c: Don't include "target.h".
15548 * inf-loop.h: Include it here.
15550 2017-01-06 Yao Qi <yao.qi@linaro.org>
15552 * dfp.h: Include "dboulest.h" and "expression.h".
15554 2017-01-06 Yao Qi <yao.qi@linaro.org>
15556 * ax-gdb.h: Include "ax.h".
15558 2017-01-06 Yao Qi <yao.qi@linaro.org>
15560 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
15561 with nat/gdb_ptrace.h.
15563 2017-01-05 Yao Qi <yao.qi@linaro.org>
15565 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
15567 (mips64_fbsd_sigframe_init): Likewise.
15569 2017-01-04 John Baldwin <jhb@FreeBSD.org>
15571 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
15572 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
15574 2017-01-04 John Baldwin <jhb@FreeBSD.org>
15576 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
15577 * NEWS: Mention new FreeBSD/mips native configuration.
15578 * config/mips/fbsd.mh: New file.
15579 * configure.host: Add mips*-*-freebsd*.
15580 * mips-fbsd-nat.c: New file.
15582 2017-01-04 John Baldwin <jhb@FreeBSD.org>
15584 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
15585 (ALLDEPFILES): Add mips-fbsd-tdep.c.
15586 * NEWS: Mention new FreeBSD/mips target.
15587 * configure.tgt: Add mips*-*-freebsd*.
15588 * mips-fbsd-tdep.c: New file.
15589 * mips-fbsd-tdep.h: New file.
15591 2017-01-04 Yao Qi <yao.qi@linaro.org>
15593 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
15594 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
15596 2017-01-01 Joel Brobecker <brobecker@adacore.com>
15598 Update copyright year range in all GDB files.
15600 2017-01-01 Joel Brobecker <brobecker@adacore.com>
15602 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
15604 For older changes see ChangeLog-2016.
15610 version-control: never