]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - gdb/ChangeLog
Constify the 'arg' passed to commands in bsd-kvm.c.
[thirdparty/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
94765011
JB
12017-11-15 John Baldwin <jhb@FreeBSD.org>
2
3 * bsd-kvm.c (bsd_kvm_cmd): Constify 'arg'.
4 (bsd_kvm_proc_cmd): Likewise.
5
625ad440
SM
62017-11-15 Simon Marchi <simon.marchi@ericsson.com>
7
8 * tui/tui-win.c (window_name_completer): Replace VEC with
9 std::vector.
10
c0c11fa9
AC
112017-11-15 Andrew Cagney <cagney@gnu.org>
12
13 * MAINTAINERS: Remove no-longer applicable entries.
14
34a7ebaf
AC
152017-11-15 Andrew Cagney <cagney@gnu.org>
16
17 * MAINTAINERS: Move self to Past Maintainers.
18
5334ef39
YQ
192017-11-15 Yao Qi <yao.qi@linaro.org>
20
21 * features/Makefile (XMLTOC): Remove nios2-linux.xml.
22 * features/nios2-linux.c: Remove.
23 * nios2-linux-tdep.c (_initialize_nios2_linux_tdep): Don't call
24 initialize_tdesc_nios2_linux.
25
a714b0d6
YQ
262017-11-15 Yao Qi <yao.qi@linaro.org>
27
28 * m68hc11-tdep.c (M68HC11_NUM_REGS): Change it to
29 M68HC11_LAST_HARD_REG + 1.
30
92ffd475
PC
312017-11-14 Paul Carroll <pcarroll@codesourcery.com>
32
33 PR gdb/22388
34 * remote.c (remote_write_bytes_aux, remote_read_bytes_1,
35 remote_read_bytes, remote_write_qxfer, remote_xfer_partial):
36 Return TARGET_XFER_EOF if size of returned data is 0.
37
07431908
SM
382017-11-14 Simon Marchi <simon.marchi@ericsson.com>
39
40 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
41 memory-map-selftests.c.
42 (SUBDIR_UNITTESTS_OBS): Add memory-map-selftests.o.
43 * memory-map.c (memory_map_start_memory): Fix computation of hi
44 address.
45 * unittests/memory-map-selftests.c: New file.
46
31432a67
JB
472017-11-09 Joel Brobecker <brobecker@adacore.com>
48
49 * ada-lang.c: Fix some typos in the general command documenting
50 how Ada expressions are being evaluated and how their result
51 is printed.
52
e793c052
TT
532017-11-09 Tom Tromey <tom@tromey.com>
54
55 * psymtab.c (psymbol_hash): Do not hash string contents.
56 (psymbol_compare): Add comment.
57
7e8835c5
TT
582017-11-09 Tom Tromey <tom@tromey.com>
59
60 * dictionary.c (dict_hash): Move "TKB" check into the "switch".
61
286acbb5
JB
622017-11-08 Joel Brobecker <brobecker@adacore.com>
63
64 * ada-exp.y (write_var_from_sym): Remove parameter
65 "orig_left_context". Update all callers.
66
b44ec619
SM
672017-11-08 Simon Marchi <simon.marchi@ericsson.com>
68
69 * tracepoint.h (class collection_list) <stringify>: Return
70 std::vector<std::string>.
71 (encode_actions_rsp): Change parameters to
72 std::vector<std::string> *.
73 * tracepoint.c (collection_list::stringify): Return
74 std::vector<std::string> and adjust accordingly.
75 (encode_actions_rsp): Changee parameters to
76 std::vector<std::string> and adjust accordingly.
77 * remote.c (free_actions_list),
78 free_actions_list_cleanup_wrapper): Remove.
79 (remote_download_tracepoint): Adjust to std::vector.
80
2f4732b0
TT
812017-11-08 Tom Tromey <tom@tromey.com>
82
83 * dwarf2read.c (symbolp): Remove typedef.
84 (read_func_scope): Use std::vector.
85 (process_structure_scope): Use std::vector.
86
f9d67a22
PA
872017-11-08 Pedro Alves <palves@redhat.com>
88
89 * ada-lang.c (ada_make_symbol_completion_list): Use
90 completion_skip_symbol.
91 * symtab.c (symbol_is_function_or_method(minimal_symbol*)): New.
92 (symbol_is_function_or_method(symbol*)): New.
93 (add_symtab_completions): Add complete_symbol_mode parameter. Use
94 completion_skip_symbol.
95 (default_collect_symbol_completion_matches_break_on): Use
96 completion_skip_symbol. Pass down mode.
97 (collect_file_symbol_completion_matches): Pass down mode.
98 * symtab.h (symbol_is_function_or_method): New declarations.
99 (completion_skip_symbol): New template function.
100
56d87ef7
PA
1012017-11-08 Pedro Alves <palves@redhat.com>
102
103 * linespec.c (iterate_over_all_matching_symtabs): Add
104 search_domain parameter. Pass it down to expand_symtabs_matching.
105 (decode_objc): Request FUNCTIONS_DOMAIN symbols only.
106 (lookup_prefix_sym): Adjust by passing ALL_DOMAIN as
107 search_domain.
108 (add_all_symbol_names_from_pspace): Add search_domain parameter.
109 Pass it down.
110 (find_method, find_function_symbols): Request FUNCTIONS_DOMAIN
111 symbols.
112 (add_matching_symbols_to_info): Add search_domain parameter. Pass
113 it down.
114
1b026119
PA
1152017-11-08 Pedro Alves <palves@redhat.com>
116
117 * ada-lang.c (ada_make_symbol_completion_list): Remove text and
118 text_len locals and don't pass them down.
119 * symtab.c (completion_list_add_name): Remove
120 sym_text/sym_text_len parameters and adjust.
121 (completion_list_add_symbol, completion_list_add_msymbol)
122 (completion_list_objc_symbol, completion_list_add_fields)
123 (add_symtab_completions): Likewise.
124 (default_collect_symbol_completion_matches_break_on)
125 (collect_file_symbol_completion_matches): Remove sym_text_len
126 local and don't pass it down.
127 * symtab.h (completion_list_add_name): Remove
128 sym_text/sym_text_len parameters.
129
c62446b1
PA
1302017-11-08 Pedro Alves <palves@redhat.com>
131
132 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
133 unittests/lookup_name_info-selftests.c.
134 (SUBDIR_UNITTESTS_OBS): Add lookup_name_info-selftests.o.
135 * cp-support.c: Include "selftest.h".
136 (cp_remove_params_1): Rename from cp_remove_params. Add
137 'require_param' parameter, and handle it.
138 (cp_remove_params): Reimplement.
139 (cp_remove_params_if_any): New.
140 (selftests::quote): New.
141 (selftests::check_remove_params): New.
142 (selftests::test_cp_remove_params): New.
143 (_initialize_cp_support): Install
144 selftests::test_cp_remove_params.
145 * cp-support.h (cp_remove_params_if_any): Declare.
146 * dwarf2read.c :Include "selftest.h".
147 (dw2_expand_symtabs_matching_symbol): Use
148 lookup_name_info::make_ignore_params.
149 (selftests::dw2_expand_symtabs_matching::mock_mapped_index)
150 (selftests::dw2_expand_symtabs_matching::string_or_null)
151 (selftests::dw2_expand_symtabs_matching::check_match)
152 (selftests::dw2_expand_symtabs_matching::test_symbols)
153 (selftests::dw2_expand_symtabs_matching::run_test): New.
154 (_initialize_dwarf2_read): Register
155 selftests::dw2_expand_symtabs_matching::run_test.
156 * psymtab.c (psym_expand_symtabs_matching): Use
157 lookup_name_info::make_ignore_params.
158 * symtab.c (demangle_for_lookup_info::demangle_for_lookup_info):
159 If the lookup name wants to ignore parameters, strip them.
160 (compare_symbol_name): Remove sym_text/sym_text_len parameters and
161 code handling '('.
162 (completion_list_add_name): Don't pass down sym_text/sym_text_len.
163 (default_collect_symbol_completion_matches_break_on): Don't try to
164 strip parameters.
165 * symtab.h (lookup_name_info::lookup_name_info): Add
166 'ignore_parameters' parameter.
167 (lookup_name_info::ignore_parameters)
168 (lookup_name_info::make_ignore_params): New methods.
169 (lookup_name_info::m_ignore_parameters): New field.
170 * unittests/lookup_name_info-selftests.c: New file.
171
61920122
PA
1722017-11-08 Pedro Alves <palves@redhat.com>
173
174 * dwarf2read.c (dw2_expand_marked_cus)
175 (dw2_expand_symtabs_matching_symbol): Remove forward declarations.
176 (dw2_expand_symtabs_matching): Move further below.
177 (dw2_expand_marked_cus): Reindent.
178
3f563c84
PA
1792017-11-08 Pedro Alves <palves@redhat.com>
180
181 * dwarf2read.c (byte_swap, MAYBE_SWAP): Move higher up in file.
182 (struct name_component): New.
183 (mapped_index::name_components): New field.
184 (mapped_index::symbol_name_at): New method.
185 (dwarf2_read_index): Call mapped_index ctor.
186 (dw2_map_matching_symbols): Add comment about name_components
187 table.
188 (dw2_expand_symtabs_matching): Factor part to...
189 (dw2_expand_symtabs_matching_symbol): ... this new function.
190 Build name components table, and lookup symbols in it before
191 calling the name matcher.
192 (dw2_expand_marked_cus): New, factored out from
193 dw2_expand_symtabs_matching.
194 (dwarf2_per_objfile_free): Call the mapped_index's dtor.
195
b5ec771e
PA
1962017-11-08 Pedro Alves <palves@redhat.com>
197
198 * ada-lang.c (ada_encode): Rename to ..
199 (ada_encode_1): ... this. Add throw_errors parameter and handle
200 it.
201 (ada_encode): Reimplement.
202 (match_name): Delete, folded into full_name.
203 (resolve_subexp): No longer pass the encoded name to
204 ada_lookup_symbol_list.
205 (should_use_wild_match): Delete.
206 (name_match_type_from_name): New.
207 (ada_lookup_simple_minsym): Use lookup_name_info and the
208 language's symbol_name_matcher_ftype.
209 (add_symbols_from_enclosing_procs, ada_add_local_symbols)
210 (ada_add_block_renamings): Adjust to use lookup_name_info.
211 (ada_lookup_name): New.
212 (add_nonlocal_symbols, ada_add_all_symbols)
213 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list)
214 (ada_iterate_over_symbols): Adjust to use lookup_name_info.
215 (ada_name_for_lookup): Delete.
216 (ada_lookup_encoded_symbol): Construct a verbatim name.
217 (wild_match): Reverse sense of return type. Use bool.
218 (full_match): Reverse sense of return type. Inline bits of old
219 match_name here.
220 (ada_add_block_symbols): Adjust to use lookup_name_info.
221 (symbol_completion_match): Delete, folded into...
222 (ada_lookup_name_info::matches): ... .this new method.
223 (symbol_completion_add): Delete.
224 (ada_collect_symbol_completion_matches): Add name_match_type
225 parameter. Adjust to use lookup_name_info and
226 completion_list_add_name.
227 (get_var_value, ada_add_global_exceptions): Adjust to use
228 lookup_name_info.
229 (ada_get_symbol_name_cmp): Delete.
230 (do_wild_match, do_full_match): New functions.
231 (ada_lookup_name_info::ada_lookup_name_info): New method.
232 (ada_symbol_name_matches, ada_get_symbol_name_matcher): New
233 functions.
234 (ada_language_defn): Install ada_get_symbol_name_matcher.
235 * ada-lex.l (processId): If name starts with '<', copy it
236 verbatim.
237 * block.c (block_iter_match_step, block_iter_match_first)
238 (block_iter_match_next, block_lookup_symbol)
239 (block_lookup_symbol_primary, block_find_symbol): Adjust to use
240 lookup_name_info.
241 * block.h (block_iter_match_first, block_iter_match_next)
242 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use lookup_name_info.
243 * c-lang.c (c_language_defn, cplus_language_defn)
244 (asm_language_defn, minimal_language_defn): Adjust comments to
245 refer to la_get_symbol_name_matcher.
246 * completer.c (complete_files_symbols)
247 (collect_explicit_location_matches, symbol_completer): Pass a
248 symbol_name_match_type down.
249 * completer.h (class completion_match, completion_match_result):
250 New classes.
251 (completion_tracker::reset_completion_match_result): New method.
252 (completion_tracker::m_completion_match_result): New field.
253 * cp-support.c (make_symbol_overload_list_block): Adjust to use
254 lookup_name_info.
255 (cp_fq_symbol_name_matches, cp_get_symbol_name_matcher): New
256 functions.
257 * cp-support.h (cp_get_symbol_name_matcher): New declaration.
258 * d-lang.c: Adjust comments to refer to
259 la_get_symbol_name_matcher.
260 * dictionary.c (dict_vector) <iter_match_first, iter_match_next>:
261 Adjust to use lookup_name_info.
262 (dict_iter_match_first, dict_iter_match_next)
263 (iter_match_first_hashed, iter_match_next_hashed)
264 (iter_match_first_linear, iter_match_next_linear): Adjust to work
265 with a lookup_name_info.
266 * dictionary.h (dict_iter_match_first, dict_iter_match_next):
267 Likewise.
268 * dwarf2read.c (dw2_lookup_symbol): Adjust to use lookup_name_info.
269 (dw2_map_matching_symbols): Adjust to use symbol_name_match_type.
270 (gdb_index_symbol_name_matcher): New class.
271 (dw2_expand_symtabs_matching) Adjust to use lookup_name_info and
272 gdb_index_symbol_name_matcher. Accept a NULL symbol_matcher.
273 * f-lang.c (f_collect_symbol_completion_matches): Adjust to work
274 with a symbol_name_match_type.
275 (f_language_defn): Adjust comments to refer to
276 la_get_symbol_name_matcher.
277 * go-lang.c (go_language_defn): Adjust comments to refer to
278 la_get_symbol_name_matcher.
279 * language.c (default_symbol_name_matcher)
280 (language_get_symbol_name_matcher): New functions.
281 (unknown_language_defn, auto_language_defn): Adjust comments to
282 refer to la_get_symbol_name_matcher.
283 * language.h (symbol_name_cmp_ftype): Delete.
284 (language_defn) <la_collect_symbol_completion_matches>: Add match
285 type parameter.
286 <la_get_symbol_name_cmp>: Delete field.
287 <la_get_symbol_name_matcher>: New field.
288 <la_iterate_over_symbols>: Adjust to use lookup_name_info.
289 (default_symbol_name_matcher, language_get_symbol_name_matcher):
290 Declare.
291 * linespec.c (iterate_over_all_matching_symtabs)
292 (iterate_over_file_blocks): Adjust to use lookup_name_info.
293 (find_methods): Add language parameter, and use lookup_name_info
294 and the language's symbol_name_matcher_ftype.
295 (linespec_complete_function): Adjust.
296 (lookup_prefix_sym): Use lookup_name_info.
297 (add_all_symbol_names_from_pspace): Adjust.
298 (find_superclass_methods): Add language parameter and pass it
299 down.
300 (find_method): Pass symbol language down.
301 (find_linespec_symbols): Don't demangle or Ada encode here.
302 (search_minsyms_for_name): Add lookup_name_info parameter.
303 (add_matching_symbols_to_info): Add name_match_type parameter.
304 Use lookup_name_info.
305 * m2-lang.c (m2_language_defn): Adjust comments to refer to
306 la_get_symbol_name_matcher.
307 * minsyms.c: Include <algorithm>.
308 (add_minsym_to_demangled_hash_table): Remove table parameter and
309 add objfile parameter. Use search_name_hash, and add language to
310 demangled languages vector.
311 (struct found_minimal_symbols): New struct.
312 (lookup_minimal_symbol_mangled, lookup_minimal_symbol_demangled):
313 New functions.
314 (lookup_minimal_symbol): Adjust to use them. Don't canonicalize
315 input names here. Use lookup_name_info instead. Lookup up
316 demangled names once for each language in the demangled names
317 vector.
318 (iterate_over_minimal_symbols): Use lookup_name_info. Lookup up
319 demangled names once for each language in the demangled names
320 vector.
321 (build_minimal_symbol_hash_tables): Adjust.
322 * minsyms.h (iterate_over_minimal_symbols): Adjust to pass down a
323 lookup_name_info.
324 * objc-lang.c (objc_language_defn): Adjust comment to refer to
325 la_get_symbol_name_matcher.
326 * objfiles.h: Include <vector>.
327 (objfile_per_bfd_storage) <demangled_hash_languages>: New field.
328 * opencl-lang.c (opencl_language_defn): Adjust comment to refer to
329 la_get_symbol_name_matcher.
330 * p-lang.c (pascal_language_defn): Adjust comment to refer to
331 la_get_symbol_name_matcher.
332 * psymtab.c (psym_lookup_symbol): Use lookup_name_info.
333 (match_partial_symbol): Use symbol_name_match_type,
334 lookup_name_info and psymbol_name_matches.
335 (lookup_partial_symbol): Use lookup_name_info.
336 (map_block): Use symbol_name_match_type and lookup_name_info.
337 (psym_map_matching_symbols): Use symbol_name_match_type.
338 (psymbol_name_matches): New.
339 (recursively_search_psymtabs): Use lookup_name_info and
340 psymbol_name_matches. Rename 'kind' parameter to 'domain'.
341 (psym_expand_symtabs_matching): Use lookup_name_info. Rename
342 'kind' parameter to 'domain'.
343 * rust-lang.c (rust_language_defn): Adjust comment to refer to
344 la_get_symbol_name_matcher.
345 * symfile-debug.c (debug_qf_map_matching_symbols)
346 (debug_qf_map_matching_symbols): Use symbol_name_match_type.
347 (debug_qf_expand_symtabs_matching): Use lookup_name_info.
348 * symfile.c (expand_symtabs_matching): Use lookup_name_info.
349 * symfile.h (quick_symbol_functions) <map_matching_symbols>:
350 Adjust to use symbol_name_match_type.
351 <expand_symtabs_matching>: Adjust to use lookup_name_info.
352 (expand_symtabs_matching): Adjust to use lookup_name_info.
353 * symmisc.c (maintenance_expand_symtabs): Use
354 lookup_name_info::match_any ().
355 * symtab.c (symbol_matches_search_name): New.
356 (eq_symbol_entry): Adjust to use lookup_name_info and the
357 language's matcher.
358 (demangle_for_lookup_info::demangle_for_lookup_info): New.
359 (lookup_name_info::match_any): New.
360 (iterate_over_symbols, search_symbols): Use lookup_name_info.
361 (compare_symbol_name): Add language, lookup_name_info and
362 completion_match_result parameters, and use them.
363 (completion_list_add_name): Make extern. Add language and
364 lookup_name_info parameters. Use them.
365 (completion_list_add_symbol, completion_list_add_msymbol)
366 (completion_list_objc_symbol): Add lookup_name_info parameters and
367 adjust. Pass down language.
368 (completion_list_add_fields): Add lookup_name_info parameters and
369 adjust. Pass down language.
370 (add_symtab_completions): Add lookup_name_info parameters and
371 adjust.
372 (default_collect_symbol_completion_matches_break_on): Add
373 name_match_type parameter, and use it. Use lookup_name_info.
374 (default_collect_symbol_completion_matches)
375 (collect_symbol_completion_matches): Add name_match_type
376 parameter, and pass it down.
377 (collect_symbol_completion_matches_type): Adjust.
378 (collect_file_symbol_completion_matches): Add name_match_type
379 parameter, and use lookup_name_info.
380 * symtab.h: Include <string> and "common/gdb_optional.h".
381 (enum class symbol_name_match_type): New.
382 (class ada_lookup_name_info): New.
383 (struct demangle_for_lookup_info): New.
384 (class lookup_name_info): New.
385 (symbol_name_matcher_ftype): New.
386 (SYMBOL_MATCHES_SEARCH_NAME): Use symbol_matches_search_name.
387 (symbol_matches_search_name): Declare.
388 (MSYMBOL_MATCHES_SEARCH_NAME): Delete.
389 (default_collect_symbol_completion_matches)
390 (collect_symbol_completion_matches)
391 (collect_file_symbol_completion_matches): Add name_match_type
392 parameter.
393 (iterate_over_symbols): Use lookup_name_info.
394 (completion_list_add_name): Declare.
395 * utils.c (enum class strncmp_iw_mode): Moved to utils.h.
396 (strncmp_iw_with_mode): Now extern.
397 * utils.h (enum class strncmp_iw_mode): Moved from utils.c.
398 (strncmp_iw_with_mode): Declare.
399
5ffa0793
PA
4002017-11-08 Keith Seitz <keiths@redhat.com>
401 Pedro Alves <palves@redhat.com>
402
403 * ada-lang.c (ada_language_defn): Install
404 default_search_name_hash.
405 * buildsym.c (struct buildsym_compunit): <language>: New field.
406 (finish_block_internal): Pass language when creating dictionaries.
407 (start_buildsym_compunit, start_symtab): New language parameters.
408 Use them.
409 (restart_symtab): Pass down compilation unit's language.
410 * buildsym.h (enum language): Forward declare.
411 (start_symtab): New 'language' parameter.
412 * c-lang.c (c_language_defn, cplus_language_defn)
413 (asm_language_defn, minimal_language_defn): Install
414 default_search_name_hash.
415 * coffread.c (coff_start_symtab): Adjust.
416 * d-lang.c (d_language_defn): Install default_search_name_hash.
417 * dbxread.c (struct symloc): Add 'pst_language' field.
418 (PST_LANGUAGE): Define.
419 (start_psymtab, read_ofile_symtab): Use it.
420 (process_one_symbol): New 'language' parameter. Pass it down.
421 * dictionary.c (struct dictionary) <language>: New field.
422 (DICT_LANGUAGE): Define.
423 (dict_create_hashed, dict_create_hashed_expandable)
424 (dict_create_linear, dict_create_linear_expandable): New parameter
425 'language'. Set the dictionary's language.
426 (iter_match_first_hashed): Adjust to rename.
427 (insert_symbol_hashed): Assert we don't see mismatching
428 languages. Adjust to rename.
429 (dict_hash): Rename to ...
430 (default_search_name_hash): ... this and make extern.
431 * dictionary.h (struct language_defn): Forward declare.
432 (dict_create_hashed): New parameter 'language'.
433 * dwarf2read.c (dwarf2_start_symtab): Pass down language.
434 * f-lang.c (f_language_defn): Install default_search_name_hash.
435 * go-lang.c (go_language_defn): Install default_search_name_hash.
436 * jit.c (finalize_symtab): Pass compunit's language to dictionary
437 creation.
438 * language.c (unknown_language_defn, auto_language_defn):
439 * language.h (language_defn::la_search_name_hash): New field.
440 (default_search_name_hash): Declare.
441 * m2-lang.c (m2_language_defn): Install default_search_name_hash.
442 * mdebugread.c (new_block): New parameter 'language'.
443 * mdebugread.c (parse_symbol): Pass symbol language to block
444 allocation.
445 (psymtab_to_symtab_1): Pass down language.
446 (new_symtab): Pass compunit's language to block allocation.
447 * objc-lang.c (objc_language_defn): Install
448 default_search_name_hash.
449 * opencl-lang.c (opencl_language_defn):
450 * p-lang.c (pascal_language_defn): Install
451 default_search_name_hash.
452 * rust-lang.c (rust_language_defn): Install
453 default_search_name_hash.
454 * stabsread.h (enum language): Forward declare.
455 (process_one_symbol): Add 'language' parameter.
456 * symtab.c (search_name_hash): New function.
457 * symtab.h (search_name_hash): Declare.
458 * xcoffread.c (read_xcoff_symtab): Pass language to start_symtab.
459
2a1dde5d
PA
4602017-11-08 Pedro Alves <palves@redhat.com>
461
462 * cp-name-parser.y (main): Don't initialize extra_chars.
463
95a6b0a1
TT
4642017-11-07 Tom Tromey <tom@tromey.com>
465
466 * event-top.h (command_handler): Constify.
467 * record-full.c (cmd_record_full_start): Update.
468 * thread.c (thread_apply_all_command): Update.
469 * printcmd.c (eval_command): Update.
470 * mi/mi-main.c (mi_execute_cli_command): Update.
471 (mi_execute_async_cli_command): Update.
472 * tui/tui-stack.c (tui_update_command): Update.
473 * cli/cli-interp.c (safe_execute_command): Constify.
474 * record.c (record_start): Update.
475 (record_start, record_stop, cmd_record_start): Update.
476 * record-btrace.c (cmd_record_btrace_bts_start): Update.
477 (cmd_record_btrace_pt_start): Update.
478 (cmd_record_btrace_start): Update.
479 (cmd_record_btrace_start): Update.
480 * reverse.c (exec_reverse_once): Update.
481 * python/python.c (execute_gdb_command): Don't copy the command.
482 * event-top.c (command_line_handler): Update.
483 (command_handler): Constify.
484 * defs.h (deprecated_call_command_hook): Constify.
485 * cli/cli-script.h (execute_user_command): Constify.
486 * cli/cli-script.c (execute_user_command): Constify.
487 (execute_cmd_pre_hook, execute_cmd_post_hook): Constify.
488 (enum command_control_type): Update.
489 * main.c (catch_command_errors): Remove non-const overload.
490 (catch_command_errors_ftype): Remove.
491 * python/py-cmd.c (cmdpy_function): Constify.
492 * guile/scm-cmd.c (cmdscm_function): Constify.
493 * cli/cli-dump.c (call_dump_func): Constify.
494 * cli/cli-decode.c (do_const_cfunc): Constify.
495 (do_sfunc): Constify.
496 (cmd_func): Constify.
497 * gdbcmd.h (execute_command, execute_command_to_string): Constify.
498 * top.h (execute_command): Constify.
499 * top.c (execute_command): Constify.
500 (execute_command_to_string): Constify.
501 (deprecated_call_command_hook): Constify.
502 * command.h (cmd_func): Constify.
503 * cli/cli-decode.h (struct cmd_list_element) <func>: Constify.
504
eb4c3f4a
TT
5052017-11-07 Tom Tromey <tom@tromey.com>
506
507 * ada-lang.c (catch_ada_exception_command): Constify.
508 (catch_assert_command): Constify.
509 * break-catch-throw.c (catch_catch_command, catch_throw_command)
510 (catch_rethrow_command): Constify.
511 (catch_exception_command_1): Constify.
512 * breakpoint.h (add_catch_command): Constify.
513 * break-catch-syscall.c (catch_syscall_command_1): Constify.
514 (catch_syscall_split_args): Constify.
515 * break-catch-sig.c (catch_signal_command): Constify.
516 (catch_signal_split_args): Constify.
517 * cli/cli-decode.h (struct cmd_list_element) <function>: Use
518 cmd_const_sfunc_ftype.
519 * cli/cli-decode.c (add_setshow_cmd_full): Constify.
520 (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
521 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
522 (add_setshow_string_cmd, struct cmd_list_element)
523 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
524 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
525 (add_setshow_zuinteger_unlimited_cmd, add_setshow_zuinteger_cmd):
526 Constify.
527 (set_cmd_sfunc): Constify.
528 (empty_sfunc): Constify.
529 * command.h (add_setshow_enum_cmd, add_setshow_auto_boolean_cmd)
530 (add_setshow_boolean_cmd, add_setshow_filename_cmd)
531 (add_setshow_string_cmd, add_setshow_string_noescape_cmd)
532 (add_setshow_optional_filename_cmd, add_setshow_integer_cmd)
533 (add_setshow_uinteger_cmd, add_setshow_zinteger_cmd)
534 (add_setshow_zuinteger_cmd, add_setshow_zuinteger_unlimited_cmd):
535 Constify.
536 (set_cmd_sfunc): Constify.
537 (cmd_sfunc_ftype): Remove.
538 * compile/compile.c (set_compile_args): Constify.
539 * infrun.c (set_disable_randomization): Constify.
540 * infcmd.c (set_args_command, set_cwd_command): Constify.
541 * breakpoint.c (set_condition_evaluation_mode): Constify.
542 (add_catch_command): Constify.
543 (catch_fork_command_1, catch_exec_command_1)
544 (catch_load_command_1, catch_unload_command_1): Constify.
545 (catch_load_or_unload): Constify.
546 * guile/scm-param.c (pascm_set_func): Constify.
547 (add_setshow_generic): Constify.
548 * python/py-param.c (get_set_value): Constify.
549 * top.h (set_verbose): Constify.
550 * tui/tui-win.c (tui_set_var_cmd): Constify.
551 * mi/mi-main.c (set_mi_async_command): Constify.
552 * cli/cli-logging.c (set_logging_overwrite)
553 (set_logging_redirect): Constify.
554 * value.c (set_max_value_size): Constify.
555 * valprint.c (set_input_radix, set_output_radix): Constify.
556 * utils.c (set_width_command, set_height_command): Constify.
557 * typeprint.c (set_print_type_methods, set_print_type_typedefs): Constify.
558 * tracepoint.c (set_disconnected_tracing)
559 (set_circular_trace_buffer, set_trace_buffer_size)
560 (set_trace_user, set_trace_notes, set_trace_stop_notes): Constify.
561 * top.c (set_history_size_command, set_verbose, set_editing)
562 (set_gdb_datadir, set_history_filename): Constify.
563 * target.c (set_targetdebug, maint_set_target_async_command)
564 (maint_set_target_non_stop_command, set_target_permissions)
565 (set_write_memory_permission): Constify.
566 (open_target): Constify.
567 * target-descriptions.c (set_tdesc_filename_cmd): Constify.
568 * target-dcache.c (set_stack_cache, set_code_cache): Constify.
569 * symtab.c (set_symbol_cache_size_handler): Constify.
570 * symfile.c (set_ext_lang_command): Constify.
571 * symfile-debug.c (set_debug_symfile): Constify.
572 * source.c (set_directories_command): Constify.
573 * solib.c (reload_shared_libraries, gdb_sysroot_changed): Constify.
574 * serial.c (set_parity): Constify.
575 * rs6000-tdep.c (powerpc_set_soft_float, powerpc_set_vector_abi): Constify.
576 * remote.c (set_remote_exec_file, set_remotebreak)
577 (set_remote_protocol_Z_packet_cmd, set_range_stepping): Constify.
578 * record.c (set_record_insn_history_size)
579 (set_record_call_history_size): Constify.
580 * record-full.c (set_record_full_insn_max_num): Constify.
581 * proc-api.c (set_procfs_trace_cmd, set_procfs_file_cmd): Constify.
582 * osabi.c (set_osabi): Constify.
583 * mips-tdep.c (set_mips64_transfers_32bit_regs)
584 (reinit_frame_cache_sfunc, mips_abi_update): Constify.
585 * maint.c (maintenance_set_profile_cmd): Constify.
586 * linux-thread-db.c (set_libthread_db_search_path): Constify.
587 * language.c (set_language_command, set_range_command)
588 (set_case_command): Constify.
589 * infrun.c (set_non_stop, set_observer_mode)
590 (set_stop_on_solib_events, set_schedlock_func)
591 (set_exec_direction_func): Constify.
592 * infcmd.c (set_inferior_tty_command): Constify.
593 * disasm.c (set_disassembler_options_sfunc): Constify.
594 * demangle.c (set_demangling_command): Constify.
595 * dcache.c (set_dcache_size, set_dcache_line_size): Constify.
596 * cris-tdep.c (set_cris_version, set_cris_mode)
597 (set_cris_dwarf2_cfi): Constify.
598 * corefile.c (set_gnutarget_command): Constify.
599 * charset.c (set_host_charset_sfunc, set_target_charset_sfunc)
600 (set_target_wide_charset_sfunc): Constify.
601 * breakpoint.c (update_dprintf_commands): Constify.
602 * auto-load.c (set_auto_load_dir, set_auto_load_safe_path): Constify.
603 * arm-tdep.c (set_fp_model_sfunc, arm_set_abi)
604 (set_disassembly_style_sfunc): Constify.
605 * arch-utils.c (set_endian, set_architecture): Constify.
606 * alpha-tdep.c (reinit_frame_cache_sfunc): Constify.
607 * agent.c (set_can_use_agent): Constify.
608
5fed81ff
TT
6092017-11-07 Tom Tromey <tom@tromey.com>
610
611 * go32-nat.c (go32_sysinfo, go32_sldt, go32_sgdt, go32_sidt)
612 (go32_pde, go32_pte, go32_pte_for_address): Constify.
613 * gnu-nat.c (_parse_bool_arg, show_thread_default_pause_cmd)
614 (set_thread_default_pause_cmd, set_thread_default_run_cmd)
615 (show_thread_default_run_cmd, set_thread_default_detach_sc_cmd)
616 (parse_int_arg, show_thread_default_detach_sc_cmd)
617 (set_signals_cmd, show_signals_cmd, set_sig_thread_cmd)
618 (show_sig_thread_cmd, set_stopped_cmd, show_stopped_cmd)
619 (set_exceptions_cmd, show_exceptions_cmd, set_task_pause_cmd)
620 (show_task_pause_cmd, set_task_detach_sc_cmd)
621 (show_task_detach_sc_cmd, set_task_exc_port_cmd)
622 (set_noninvasive_cmd, set_thread_pause_cmd)
623 (show_thread_pause_cmd, set_thread_run_cmd, show_thread_run_cmd)
624 (set_thread_detach_sc_cmd, show_thread_detach_sc_cmd)
625 (set_thread_exc_port_cmd, thread_takeover_sc_cmd): Constify.
626 * windows-nat.c (display_selectors): Constify.
627 * cli/cli-decode.h (struct cmd_list_element) <function>: Remove
628 non-const "cfunc".
629 * cli/cli-decode.c (set_cmd_cfunc): Remove non-const overload.
630 (cmd_cfunc_eq): Likewise.
631 (struct cmd_list_element): Likewise.
632 (do_cfunc): Remove.
633 (cli_user_command_p): Update.
634 * command.h (add_cmd): Remove non-const overload.
635 (cmd_cfunc_ftype): Remove typedef.
636 (cmd_cfunc_eq): Remove non-const overload.
637 * value.c (show_values): Constify.
638 * thread.c (thread_apply_all_command): Constify.
639 * symfile.c (load_command): Constify.
640 * source.c (directory_command): Constify.
641 * maint.c (maintenance_internal_error)
642 (maintenance_demangler_warning, maintenance_space_display)
643 (maintenance_print_architecture, maintenance_translate_address)
644 (maintenance_info_selftests, maintenance_internal_warning):
645 Constify.
646 * breakpoint.c (disable_trace_command, enable_trace_command):
647 Constify.
648 * auto-load.c (info_auto_load_local_gdbinit, add_auto_load_dir):
649 Constify.
650 (add_auto_load_safe_path): Constify.
651 * guile/scm-auto-load.c (info_auto_load_guile_scripts): Constify.
652 * top.h (show_commands): Constify.
653 * linux-thread-db.c (info_auto_load_libthread_db): Constify.
654 * sparc64-tdep.c (adi_examine_command): Constify.
655 (adi_assign_command): Constify.
656
1d12d88f
TT
6572017-11-07 Tom Tromey <tom@tromey.com>
658
659 * frame.h (info_locals_command, info_args_command): Constify.
660 * auto-load.h (auto_load_info_scripts): Constify.
661 * inferior.h (registers_info): Constify.
662 * copying.c: Rebuild.
663 * copying.awk: Constify generated commands.
664 * auto-load.c (auto_load_info_scripts)
665 (info_auto_load_gdb_scripts): Constify.
666 * cli/cli-decode.c (struct cmd_list_element): Take a
667 cmd_const_cfunc_ftype.
668 * command.h (add_info): Take a cmd_const_cfunc_ftype.
669 * tui/tui-win.c (tui_all_windows_info): Constify.
670 * python/py-auto-load.c (info_auto_load_python_scripts):
671 Constify.
672 * cli/cli-cmds.c (show_command): Remove non-const overload.
673 * tracepoint.c (info_tvariables_command, info_scope_command):
674 Constify.
675 (info_static_tracepoint_markers_command): Constify.
676 * thread.c (info_threads_command): Constify.
677 (print_thread_info_1): Constify.
678 * target.c (info_target_command): Constify.
679 * symtab.c (info_sources_command, info_functions_command)
680 (info_types_command): Constify.
681 (info_variables_command): Remove non-const overload.
682 * symfile.c (info_ext_lang_command): Constify.
683 * stack.c (info_frame_command, info_locals_command)
684 (info_args_command): Constify.
685 (backtrace_command): Remove non-const overload.
686 * source.c (info_source_command, info_line_command): Constify.
687 * solib.c (info_sharedlibrary_command): Constify.
688 * skip.c (info_skip_command): Constify.
689 * ser-go32.c (info_serial_command): Constify.
690 * reverse.c (info_bookmarks_command): Constify.
691 * printcmd.c (info_symbol_command, info_address_command)
692 (info_display_command): Constify.
693 * osdata.c (info_osdata_command): Constify.
694 * objc-lang.c (info_selectors_command, info_classes_command):
695 Constify.
696 * nto-procfs.c (procfs_pidlist, procfs_meminfo): Constify.
697 * memattr.c (info_mem_command): Constify.
698 * macrocmd.c (info_macro_command, info_macros_command): Constify.
699 * linux-fork.c (info_checkpoints_command): Constify.
700 * infrun.c (info_signals_command): Constify.
701 * inflow.c (info_terminal_command): Constify.
702 * inferior.c (info_inferiors_command): Constify.
703 (print_inferior): Constify.
704 * infcmd.c (info_program_command, info_all_registers_command)
705 (info_registers_command, info_vector_command)
706 (info_float_command): Constify.
707 (registers_info): Constify.
708 * gnu-nat.c (info_send_rights_cmd, info_recv_rights_cmd)
709 (info_port_sets_cmd, info_dead_names_cmd, info_port_rights_cmd):
710 Constify.
711 * f-valprint.c (info_common_command): Constify.
712 * dcache.c (info_dcache_command): Constify.
713 (dcache_info_1): Constify.
714 * darwin-nat-info.c (info_mach_tasks_command)
715 (info_mach_task_command, info_mach_ports_command)
716 (info_mach_port_command, info_mach_threads_command)
717 (info_mach_thread_command, info_mach_regions_command)
718 (info_mach_regions_recurse_command, info_mach_region_command)
719 (info_mach_exceptions_command): Constify.
720 (get_task_from_args): Constify.
721 * cp-support.c (info_vtbl_command): Constify.
722 * breakpoint.c (info_watchpoints_command)
723 (info_tracepoints_command): Constify.
724 (info_breakpoints_command): Remove non-const overload.
725 * avr-tdep.c (avr_io_reg_read_command): Constify.
726 * auxv.c (info_auxv_command): Constify.
727 * ada-tasks.c (info_tasks_command): Constify.
728 (info_task): Constify.
729 * ada-lang.c (info_exceptions_command): Constify.
730
0b39b52e
TT
7312017-11-07 Tom Tromey <tom@tromey.com>
732
733 * solib.h (no_shared_libraries): Constify.
734 * frame.h (return_command): Constify.
735 * cli/cli-cmds.h (quit_command): Constify.
736 * top.h (quit_command, execute_command): Constify.
737 * target.h (flash_erase_command): Constify.
738 * inferior.h (set_inferior_args, attach_command): Constify.
739 * tracepoint.h (start_tracing, stop_tracing): Constify.
740 * breakpoint.h (break_command, tbreak_command)
741 (hbreak_command_wrapper, thbreak_command_wrapper)
742 (rbreak_command_wrapper, watch_command_wrapper)
743 (awatch_command_wrapper, rwatch_command_wrapper)
744 (get_tracepoint_by_number): Constify.
745 * symtab.c (info_variables_command, rbreak_command)
746 (symtab_symbol_info): Constify.
747 (info_variables_command): Add non-const overload.
748 * top.c (dont_repeat_command): Constify.
749 * breakpoint.c (ignore_command, commands_command)
750 (condition_command, tbreak_command, hbreak_command)
751 (thbreak_command, clear_command, break_command)
752 (info_breakpoints_command, watch_command, rwatch_command)
753 (awatch_command, trace_command, ftrace_command, strace_command)
754 (trace_pass_command, break_range_command, dprintf_command)
755 (agent_printf_command, get_tracepoint_by_number)
756 (watch_maybe_just_location, trace_pass_command): Constify.
757 (info_breakpoints_command): Add non-const overload.
758 * tracefile.c (tsave_command): Constify.
759 * infcmd.c (attach_command, disconnect_command, signal_command)
760 (queue_signal_command, stepi_command, nexti_command)
761 (finish_command, next_command, step_command, until_command)
762 (advance_command, jump_command, continue_command, run_command)
763 (start_command, starti_command, interrupt_command)
764 (run_command_1, set_inferior_args, step_1): Constify.
765 * inferior.c (add_inferior_command, remove_inferior_command)
766 (clone_inferior_command): Constify.
767 * linux-fork.c (checkpoint_command, restart_command): Constify.
768 * windows-nat.c (signal_event_command): Constify.
769 * guile/guile.c (guile_repl_command, guile_command): Constify.
770 * printcmd.c (x_command, display_command, printf_command)
771 (output_command, set_command, call_command, print_command)
772 (eval_command): Constify.
773 (non_const_set_command): Remove.
774 (_initialize_printcmd): Update.
775 * source.c (forward_search_command, reverse_search_command):
776 Constify.
777 * jit.c (jit_reader_load_command, jit_reader_unload_command):
778 Constify.
779 * infrun.c (handle_command): Constify.
780 * memattr.c (mem_command): Constify.
781 * stack.c (return_command, up_command, up_silently_command)
782 (down_command, down_silently_command, frame_command)
783 (backtrace_command, func_command, backtrace_command_1): Constify.
784 (backtrace_command): Add non-const overload.
785 * remote-sim.c (simulator_command): Constify.
786 * exec.c (set_section_command): Constify.
787 * tracepoint.c (tdump_command, trace_variable_command)
788 (tstatus_command, tstop_command, tstart_command)
789 (end_actions_pseudocommand, while_stepping_pseudocommand)
790 (collect_pseudocommand, teval_pseudocommand, actions_command)
791 (start_tracing, stop_tracing): Constify.
792 * value.c (init_if_undefined_command): Constify.
793 * tui/tui-stack.c (tui_update_command): Constify.
794 * tui/tui-win.c (tui_refresh_all_command)
795 (tui_set_tab_width_command, tui_set_win_height_command)
796 (tui_set_focus_command, tui_scroll_forward_command)
797 (tui_scroll_backward_command, tui_scroll_left_command)
798 (tui_scroll_right_command, parse_scrolling_args, tui_set_focus)
799 (tui_set_win_height): Constify.
800 * tui/tui-layout.c (tui_layout_command): Constify.
801 * procfs.c (proc_trace_syscalls, proc_trace_sysentry_cmd)
802 (proc_trace_sysexit_cmd, proc_untrace_sysentry_cmd)
803 (proc_untrace_sysexit_cmd): Constify.
804 * remote.c (threadlist_test_cmd, threadinfo_test_cmd)
805 (threadset_test_cmd, threadlist_update_test_cmd)
806 (threadalive_test): Constify.
807 * objc-lang.c (print_object_command): Constify.
808 * command.h (add_com): Constify.
809 * cli/cli-dump.c (restore_command): Constify.
810 * cli/cli-cmds.c (pwd_command, echo_command, quit_command)
811 (help_command, complete_command, shell_command, edit_command)
812 (list_command, disassemble_command, make_command)
813 (apropos_command, alias_command): Constify.
814 * cli/cli-script.c (document_command, define_command)
815 (while_command, if_command, validate_comname): Constify.
816 * cli/cli-decode.c (struct cmd_list_element): Change type of
817 "fun".
818 * target.c (do_monitor_command, flash_erase_command): Constify.
819 * regcache.c (reg_flush_command): Constify.
820 * reverse.c (reverse_step, reverse_next, reverse_stepi)
821 (reverse_nexti, reverse_continue, reverse_finish)
822 (save_bookmark_command, goto_bookmark_command)
823 (exec_reverse_once): Constify.
824 * python/python.c (python_interactive_command, python_command):
825 Constify.
826 * typeprint.c (ptype_command, whatis_command, whatis_exp):
827 Constify.
828 * solib.c (sharedlibrary_command, no_shared_libraries): Constify.
829 * gcore.c (gcore_command): Constify.
830
85c4be7c
TT
8312017-11-07 Tom Tromey <tom@tromey.com>
832
833 * printcmd.c (x_command): Call set_repeat_arguments.
834 * cli/cli-cmds.c (list_command): Call set_repeat_arguments.
835 * top.c (repeat_arguments): New global.
836 (set_repeat_arguments): New function.
837 (execute_command): Handle repeat_arguments.
838 (show_commands): Calls set_repeat_arguments.
839 * command.h (set_repeat_arguments): Declare.
840
022643b4
TT
8412017-11-07 Tom Tromey <tom@tromey.com>
842
843 * stack.c (backtrace_command): Use std::string.
844 (backtrace_command_1): Make "count_exp" const.
845
5614fb77
TT
8462017-11-07 Tom Tromey <tom@tromey.com>
847
848 * source.c (directory_switch, mod_path, add_path): Constify.
849 * defs.h (add_path, mod_path, directory_switch): Constify.
850 * mi/mi-cmd-env.c (env_mod_path): Constify.
851
6be9a197
TT
8522017-11-07 Tom Tromey <tom@tromey.com>
853
854 * infcmd.c (strip_bg_char): Return gdb::unique_xmalloc_ptr.
855 (run_command_1, continue_command, step_1, jump_command)
856 (signal_command, until_command, advance_command, finish_command)
857 (attach_command): Update.
858
c2252c0d
TT
8592017-11-07 Tom Tromey <tom@tromey.com>
860
861 * command.h (set_cmd_cfunc): Don't declare.
862 * cli/cli-decode.c (set_cmd_cfunc): Now static.
863
1ee870c5
TT
8642017-11-07 Tom Tromey <tom@tromey.com>
865
866 * stack.c (select_frame_command): Constify.
867 * cli/cli-decode.c (add_com_suppress_notification): Constify.
868 * command.h (add_com_suppress_notification): Constify.
869
ee7ddd71
TT
8702017-11-07 Tom Tromey <tom@tromey.com>
871
872 * breakpoint.c (stop_command): Constify.
873 * cli/cli-decode.c (struct cmd_list_element): Constify.
874 * command.h (add_abbrev_prefix_cmd): Constify.
875
95e95a6d
PA
8762017-11-07 Pedro Alves <palves@redhat.com>
877
878 * breakpoint.c (extract_bp_kind): New enum.
879 (extract_bp_num, extract_bp_or_bp_range): New functions, partially
880 factored out from ...
881 (extract_bp_number_and_location): ... here.
882 * cli/cli-utils.c (get_number_trailer): Handle '-$variable'.
883
cc638e86
PA
8842017-11-07 Pedro Alves <palves@redhat.com>
885
886 * breakpoint.c (extract_bp_number_and_location): Change return
887 type to void. Throw error instead of warning.
888 (enable_disable_command): Adjust.
889
d0fe4701
XR
8902017-11-07 Xavier Roirand <roirand@adacore.com>
891 Pedro Alves <palves@redhat.com>
892
893 * breakpoint.c (map_breakpoint_number_range): New, factored out
894 from ...
895 (map_breakpoint_numbers): ... here.
896 (find_location_by_number): Change parameters from string to
897 breakpoint number and location.
898 (extract_bp_number_and_location): New function.
899 (enable_disable_bp_num_loc)
900 (enable_disable_breakpoint_location_range)
901 (enable_disable_command): New functions, factored out ...
902 (enable_command, disable_command): ... these functions, and
903 adjusted to support ranges.
904 * NEWS: Document enable/disable breakpoint location range feature.
905
635dc5b2
LM
9062017-11-06 Luis Machado <luis.machado@linaro.org>
907
908 * MAINTAINERS (Write After Approval): Update my e-mail address.
909
556e5da5
PA
9102017-11-06 Pedro Alves <palves@redhat.com>
911
912 * gnu-nat.c (gnu_terminal_init): Delete.
913 (gnu_target): Don't install gnu_terminal_init.
914 * inflow.c (child_terminal_init_with_pgrp): Delete, merged with ...
915 (child_terminal_init): ... this function.
916
d1928160
PA
9172017-11-06 Pedro Alves <palves@redhat.com>
918
919 * common/common.m4 (GDB_AC_COMMON): No longer check termio.h nor
920 sgtty.h.
921 * config.in, configure: Regenerate.
922
6aa899ce
PA
9232017-11-06 Pedro Alves <palves@redhat.com>
924
925 * event-top.c: Check SIGTSTP instead of STOP_SIGNAL thoughout.
926 (async_init_signals): Adjust.
927 (handle_stop_sig): Rename to ...
928 (handle_sigtstp): ... this.
929 (async_stop_sig): Rename to ...
930 (async_sigtstp_handler): ... this, and delete STOP_SIGNAL !=
931 SIGTSTP path.
932 * event-top.h: Move signal.h include to the top. Check SIGTSTP
933 instead of STOP_SIGNAL thoughout.
934 (handle_stop_sig): Rename to ...
935 (handle_sigtstp): ... this.
936 * top.c (command_line_input): Replace STOP_SIGNAL -> SIGTSTP.
937
a94799ac
PA
9382017-11-06 Pedro Alves <palves@redhat.com>
939
940 * inflow.c (child_terminal_inferior, child_terminal_ours_1): No
941 longer set flags twice in row.
942
726e1356
PA
9432017-11-06 Pedro Alves <palves@redhat.com>
944
945 * Makefile.in (SER_HARDWIRE): Update comment.
946 (HFILES_NO_SRCDIR): Remove gdb_termios.h.
947 * common/gdb_termios.h: Delete file.
948 * common/job-control.c: Include termios.h and unistd.h instead of
949 gdb_termios.h.
950 (gdb_setpgid): Remove HAVE_TERMIOS || TIOCGPGRP preprocessor
951 check.
952 (have_job_control): Check HAVE_TERMIOS_H instead of HAVE_TERMIOS.
953 Remove sgtty code.
954 * configure.ac: No longer check for termio.h and sgtty.h.
955 * configure: Regenerate.
956 * inflow.c: Include termios.h instead of gdb_termios.h. Replace
957 PROCESS_GROUP_TYPE checks with HAVE_TERMIOS_H checks throughout.
958 Replace PROCESS_GROUP_TYPE references with pid_t references
959 throughout.
960 (gdb_getpgrp): Delete.
961 (set_initial_gdb_ttystate): Use tcgetpgrp instead of gdb_getpgrp.
962 (child_terminal_inferior): Remove comment. Remove sgtty code.
963 (child_terminal_ours_1): Use tcgetpgrp directly instead of
964 gdb_getpgrp. Use serial_set_tty_state instead aof
965 serial_noflush_set_tty_state. Remove sgtty code.
966 * inflow.h: Include unistd.h instead of gdb_termios.h. Replace
967 PROCESS_GROUP_TYPE check with HAVE_TERMIOS_H check.
968 (inferior_process_group): Now returns pid_t.
969 * ser-base.c (ser_base_noflush_set_tty_state): Delete.
970 * ser-base.h (ser_base_noflush_set_tty_state): Delete.
971 * ser-event.c (serial_event_ops): Update.
972 * ser-go32.c (dos_noflush_set_tty_state): Delete.
973 (dos_ops): Update.
974 * ser-mingw.c (hardwire_ops, tty_ops, pipe_ops, tcp_ops): Update.
975 * ser-pipe.c (pipe_ops): Update.
976 * ser-tcp.c (tcp_ops): Update.
977 * ser-unix.c: Include termios.h instead of gdb_termios.h. Remove
978 HAVE_TERMIOS checks.
979 [HAVE_TERMIO] (struct hardwire_ttystate): Delete.
980 [HAVE_SGTTY] (struct hardwire_ttystate): Delete.
981 (get_tty_state, set_tty_state): Drop termio and sgtty code, and
982 assume termios.
983 (hardwire_noflush_set_tty_state): Delete.
984 (hardwire_print_tty_state, hardwire_drain_output)
985 (hardwire_flush_output, hardwire_flush_input)
986 (hardwire_send_break, hardwire_raw, hardwire_setbaudrate)
987 (hardwire_setstopbits, hardwire_setparity): Drop termio and sgtty
988 code, and assume termios.
989 (hardwire_ops): Update.
990 (_initialize_ser_hardwire): Remove HAVE_TERMIOS check.
991 * serial.c (serial_noflush_set_tty_state): Delete.
992 * serial.h (serial_noflush_set_tty_state): Delete.
993 (serial_ops::noflush_set_tty_state): Delete.
994
1cfb73db
UW
9952017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
996
997 * Makefile.in (SFILES): Remove doublest.c and dfp.c.
998 (HFILES_NO_SRCDIR): Remove doublest.h and dfp.h.
999 (COMMON_OBS): Remove doublest.o and dfp.o.
1000 Do not build target-float.c (instead of doublest.c)
1001 with -Wformat-nonliteral.
1002
1003 * doublest.c: Remove file.
1004 * doublest.h: Remove file.
1005 * dfp.c: Remove file.
1006 * dfp.h: Remove file.
1007
1008 * target-float.c: Do not include "doublest.h" and "dfp.h".
1009 (DOUBLEST): Move here from doublest.h.
1010 (enum float_kind): Likewise.
1011 (FLOATFORMAT_CHAR_BIT): Likewise.
1012 (FLOATFORMAT_LARGEST_BYTES): Likewise.
1013 (floatformat_totalsize_bytes): Move here from doublest.c. Make static.
1014 (floatformat_precision): Likewise.
1015 (floatformat_normalize_byteorder, get_field, put_field): Likewise.
1016 (floatformat_is_negative, floatformat_classify, floatformat_mantissa):
1017 Likewise.
1018 (host_float_format, host_double_format, host_long_double_format):
1019 Likewise.
1020 (floatformat_to_string, floatformat_from_string): Likewise.
1021 (floatformat_to_doublest): Likewise. Also, inline the original
1022 convert_floatformat_to_doublest.
1023 (floatformat_from_doublest): Likewise. Also, inline the original
1024 convert_floatformat_from_doublest.
1025
1026 Include "dpd/decimal128.h", "dpd/decimal64.h", and "dpd/decimal32.h".
1027 (MAX_DECIMAL_STRING): Move here from dfp.c.
1028 (match_endianness): Likewise.
1029 (set_decnumber_context, decimal_check_errors): Likewise.
1030 (decimal_from_number, decimal_to_number): Likewise.
1031 (decimal_to_string, decimal_from_string): Likewise. Make static.
1032 (decimal_from_longest, decimal_from_ulongest): Likewise.
1033 (decimal_to_longest): Likewise.
1034 (decimal_binop, decimal_is_zero, decimal_compare): Likewise.
1035 (decimal_convert): Likewise.
1036
b07e9c46
UW
10372017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1038
1039 * doublest.c: Do not include "gdbtypes.h".
1040 (extract_typed_floating): Remove.
1041 (store_typed_floating): Remove.
1042 (convert_typed_floating): Remove.
1043 * doublest.h (struct type): Remove.
1044 (DOUBLEST_PRINT_FORMAT): Remove.
1045 (DOUBLEST_SCAN_FORMAT): Remove.
1046 (extract_typed_floating): Remove.
1047 (store_typed_floating): Remove.
1048 (convert_typed_floating): Remove.
1049
1050 * dfp.c (decimal_from_doublest): Remove.
1051 (decimal_to_doublest): Remove.
1052 * dfp.h: Do not include "doublest.h".
1053 (decimal_from_doublest): Remove.
1054 (decimal_to_doublest): Remove.
1055
1056 * value.c: Do not include "doublest.h" and "dfp.h".
1057 (value_as_double): Remove.
1058 (unpack_double): Remove.
1059 (value_from_double): Remove.
1060 (value_from_decfloat): Remove.
1061 * value.h: Do not include "doublest.h".
1062 (value_as_double): Remove.
1063 (unpack_double): Remove.
1064 (value_from_double): Remove.
1065 (value_from_decfloat): Remove.
1066
3b2ca824
UW
10672017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1068
1069 * i386-tdep.c: Include "target-float.h". Do not include "doublest.h".
1070 (i386_extract_return_value): Use target_float_convert.
1071 (i386_store_return_value): Likewise.
1072 * i387-tdep.c (i387_register_to_value): Use target_float_convert.
1073 (i387_value_to_register): Likewise.
1074 * ia64-tdep.c: Include "target-float.h". Do not include "doublest.h".
1075 (ia64_register_to_value): Use target_float_convert.
1076 (ia64_value_to_register): Likewise.
1077 (ia64_extract_return_value): Likewise.
1078 (ia64_store_return_value): Likewise.
1079 (ia64_push_dummy_call): Likewise.
1080 * m68k-tdep.c: Include "target-float.h".
1081 (m68k_register_to_value): Use target_float_convert.
1082 (m68k_value_to_register): Likewise.
1083 (m68k_svr4_extract_return_value): Likewise.
1084 (m68k_svr4_store_return_value): Likewise.
1085 * ppc-sysv-tdep.c: Include "target-float.h".
1086 (ppc_sysv_abi_push_dummy_call): Use target_float_convert.
1087 (do_ppc_sysv_return_value): Likewise.
1088 (ppc64_sysv_abi_push_freg): Likewise.
1089 (ppc64_sysv_abi_return_value_base): Likewise.
1090 * rs6000-aix-tdep.c: Include "target-float.h".
1091 (rs6000_push_dummy_call): Use target_float_convert.
1092 (rs6000_return_value): Likewise.
1093 * rs6000-lynx178-tdep.c: Include "target-float.h".
1094 (rs6000_lynx178_push_dummy_call): Use target_float_convert.
1095 (rs6000_lynx178_return_value): Likewise.
1096 * rs6000-tdep.c: Include "target-float.h". Do not include "doublest.h".
1097 (rs6000_register_to_value): Use target_float_convert.
1098 (rs6000_value_to_register): Likewise.
1099 * arm-tdep.c: Include "target-float.h". Do not include "doublest.h".
1100 (arm_extract_return_value): Use target_float_convert.
1101 (arm_store_return_value): Likewise.
1102 * sh-tdep.c: Include "target-float.h". Do not include "doublest.h".
1103 (sh_register_convert_to_virtual): Use target_float_convert.
1104 (sh_register_convert_to_raw): Likewise.
1105 * sh64-tdep.c: Include "target-float.h".
1106 (sh64_extract_return_value): Use target_float_convert.
1107 (sh64_register_convert_to_virtual): Likewise.
1108 (sh64_register_convert_to_raw): Likewise. Fix argument types.
1109
14ad9311
UW
11102017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1111
1112 * target-float.c (floatformat_to_host_double): New function.
1113 (floatformat_from_host_double): Likewise.
1114 (target_float_to_host_double): Likewise.
1115 (target_float_from_host_double): Likewise.
1116 * target-float.h (target_float_to_host_double): Add prototype.
1117 (target_float_from_host_double): Likewise.
1118
1119 * guile/scm-value.c: Include "target-float.h".
1120 (gdbscm_value_to_real): Use target_float_to_host_double.
1121 Handle integer source values via value_as_long.
1122 * guile/scm-math.c: Include "target-float.h". Do not include
1123 "doublest.h", "dfp.h", and "expression.h".
1124 (vlscm_convert_typed_number): Use target_float_from_host_double.
1125 (vlscm_convert_number): Likewise.
1126
1127 * python/py-value.c (valpy_float): Use target_float_to_host_double.
1128 (convert_value_from_python): Use target_float_from_host_double.
1129
50eff16b
UW
11302017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1131
1132 * ada-lang.c (cast_to_fixed): Reimplement in target arithmetic.
1133 (cast_from_fixed): Likewise.
1134 (ada_scaling_type): New function.
1135 (ada_delta): Return value instead of DOUBLEST. Perform target
1136 arithmetic instead of host arithmetic.
1137 (scaling_factor): Rename to ...
1138 (ada_scaling_factor) ... this. Make non-static. Return value instead
1139 of DOUBLEST. Perform target arithmetic instead of host arithmetic.
1140 (ada_fixed_to_float): Remove.
1141 (ada_float_to_fixed): Remove.
1142 * ada-lang.h (ada_fixed_to_float): Remove.
1143 (ada_float_to_fixed): Remove.
1144 (ada_delta): Return value instead of DOUBLEST.
1145 (ada_scaling_factor): Add prototype.
1146
1147 * ada-typeprint.c: Include "target-float.h".
1148 (print_fixed_point_type): Perform target arithmetic instead of
1149 host arithmetic.
1150 * ada-valprint.c: Include "target-float.h".
1151 (ada_val_print_num): Perform target arithmetic instead of
1152 host arithmetic for fixed-point types.
1153
66c02b9e
UW
11542017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1155
1156 * target-float.c: Include <math.h>.
1157 (floatformat_binop): New function.
1158 (floatformat_compare): Likewise.
1159 (target_float_binop): Likewise.
1160 (target_float_compare): Likewise.
1161 * target-float.h: Include "expression.h".
1162 (target_float_binop): Add prototype.
1163 (target_float_compare): Likewise.
1164
1165 * valarith.c: Do not include "doublest.h" and "dfp.h".
1166 Include "common/byte-vector.h".
1167 (value_args_as_decimal): Remove, replace by ...
1168 (value_args_as_target_float): ... this function. Handle both
1169 binary and decimal target floating-point formats.
1170 (scalar_binop): Handle both binary and decimal FP using
1171 value_args_as_target_float and target_float_binop.
1172 (value_equal): Handle both binary and decimal FP using
1173 value_args_as_target_float and target_float_compare.
1174 (value_less): Likewise.
1175 (value_pos): Handle all scalar types as simple copy.
1176 (value_neg): Handle all scalar types via BINOP_SUB from 0.
1177 * dfp.c (decimal_binop): Throw error instead of internal_error
1178 when called with an unsupported operation code.
1179
f69fdf9b
UW
11802017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1181
1182 * target-float.c (target_float_to_string): New function.
1183 (target_float_from_string): New function.
1184 * target-float.h (target_float_to_string): Add prototype.
1185 (target_float_from_string): Add prototype.
1186
1187 * valprint.c: Include "target-float.h". Do not include
1188 "doublest.h" and "dfp.h".
1189 (print_floating): Use target_float_to_string.
1190 * printcmd.c: Include "target-float.h". Do not include "dfp.h".
1191 (printf_floating): Use target_float_to_string.
1192 * i387-tdep.c: Include "target-float.h". Do not include "doublest.h".
1193 (print_i387_value): Use target_float_to_string.
1194 * mips-tdep.c: Include "target-float.h".
1195 (mips_print_fp_register): Use target_float_to_string.
1196 * sh64-tdep.c: Include "target-float.h".
1197 (sh64_do_fp_register): Use target_float_to_string.
1198
1199 * parse.c: Include "target-float.h". Do not include
1200 "doublest.h" and "dfp.h".
1201 (parse_float): Use target_float_from_string.
1202 * stabsread.c: Include "target-float.h". Do not include "doublest.h".
1203 (define_symbol): Use target_float_from_string.
1204 * gdbarch-selftests.c: Include "target-float.h".
1205 (register_to_value_test): Use target_float_from_string.
1206
70100014
UW
12072017-11-06 Ulrich Weigand <uweigand@de.ibm.com>
1208
1209 * Makefile.c (SFILES): Add target-float.c.
1210 (HFILES_NO_SRCDIR): Add target-float.h.
1211 (COMMON_OBS): Add target-float.o.
1212 * target-float.h: New file.
1213 * target-float.c: New file.
1214
1215 * doublest.c (floatformat_classify): Fix detection of float_zero.
1216
1217 * gdbtypes.c (is_floating_type): New function.
1218 * gdbtypes.h (is_floating_type): Add prototype.
1219
1220 * value.c: Do not include "floatformat.h".
1221 (unpack_double): Use target_float_is_valid.
1222 (is_floating_value): New function.
1223 * value.h (is_floating_value): Add prototype-
1224
1225 * valarith.c: Include "target-float.h".
1226 (value_logical_not): Use target_float_is_zero.
1227
1228 * python/py-value.c: Include "target-float.h".
1229 (valpy_nonzero): Use target_float_is_zero.
1230
ab4b1c46
TT
12312017-11-04 Tom Tromey <tom@tromey.com>
1232
1233 * h8300-tdep.c (h8300_push_dummy_call): Use std::vector.
1234
454dafbd
TT
12352017-11-04 Tom Tromey <tom@tromey.com>
1236
1237 * breakpoint.c (set_momentary_breakpoint): Return
1238 breakpoint_up.
1239 (until_break_command): Update.
1240 (new_until_break_fsm): Change argument types to
1241 breakpoint_up.
1242 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1243 (do_delete_breakpoint_cleanup, make_cleanup_delete_breakpoint):
1244 Remove.
1245 * infcmd.c (finish_forward): Update.
1246 * breakpoint.h (set_momentary_breakpoint)
1247 (set_momentary_breakpoint_at_pc): Return breakpoint_up.
1248 (make_cleanup_delete_breakpoint): Remove.
1249 (struct breakpoint_deleter): New.
1250 (breakpoint_up): New typedef.
1251 * infrun.c (insert_step_resume_breakpoint_at_sal_1): Update.
1252 (insert_exception_resume_breakpoint): Update.
1253 (insert_exception_resume_from_probe): Update.
1254 (insert_longjmp_resume_breakpoint): Update.
1255 * arm-linux-tdep.c (arm_linux_copy_svc): Update.
1256 * elfread.c (elf_gnu_ifunc_resolver_stop): Update.
1257 * infcall.c (call_function_by_hand_dummy): Update
1258
331b71e5
TT
12592017-11-04 Tom Tromey <tom@tromey.com>
1260
1261 * c-typeprint.c (c_type_print_base): Use gdb::unique_xmalloc_ptr.
1262
9f584b37
TT
12632017-11-04 Tom Tromey <tom@tromey.com>
1264
1265 * linux-tdep.c (linux_core_info_proc_mappings): Use
1266 gdb::def_vector.
1267 (linux_get_siginfo_data): Return gdb::byte_vector. Remove
1268 "size" argument.
1269 (linux_corefile_thread): Update.
1270 (linux_make_corefile_notes): Remove unused variable.
1271
779bc38e
TT
12722017-11-04 Tom Tromey <tom@tromey.com>
1273
1274 * ppc-linux-tdep.c (ppc_linux_get_syscall_number): Use
1275 gdb::byte_vector.
1276
ed2b3126
TT
12772017-11-04 Tom Tromey <tom@tromey.com>
1278
1279 * objfiles.c (do_free_objfile_cleanup): Remove.
1280 * compile/compile-object-load.c (compile_object_load): Update.
1281 * objfiles.h (make_cleanup_free_objfile): Remove.
1282
7f6743fd
TT
12832017-11-04 Tom Tromey <tom@tromey.com>
1284
1285 * sparc64-tdep.c (do_examine): Use gdb::def_vector.
1286 (adi_read_versions): Change "tags" to "gdb_byte *".
1287 (adi_print_versions): Likewise.
1288
c80049d3
TT
12892017-11-04 Tom Tromey <tom@tromey.com>
1290
1291 * breakpoint.c
1292 (scoped_rbreak_breakpoints::scoped_rbreak_breakpoints): Rename
1293 from start_rbreak_breakpoints.
1294 (scoped_rbreak_breakpoints): Rename from end_rbreak_breakpoints.
1295 * breakpoint.h (class scoped_rbreak_breakpoints): New.
1296 (start_rbreak_breakpoints, end_rbreak_breakpoints): Remove.
1297 * symtab.c (do_end_rbreak_breakpoints): Remove.
1298 (rbreak_command): Use scoped_rbreak_breakpoints, std::string.
1299
167b0be1
TT
13002017-11-04 Tom Tromey <tom@tromey.com>
1301
1302 * cp-namespace.c (reset_directive_searched): Remove.
1303 (cp_lookup_symbol_via_imports): Use scoped_restore.
1304 * cp-support.c (reset_directive_searched): Remove.
1305 (make_symbol_overload_list_using): Use scoped_restore.
1306 * d-namespace.c (d_lookup_symbol_imports): Use scoped_restore.
1307 (reset_directive_searched): Remove.
1308
5eae7aea
TT
13092017-11-04 Tom Tromey <tom@tromey.com>
1310
1311 * symfile.c (find_separate_debug_file_by_debuglink): Use
1312 unique_xmalloc_ptr.
1313
c6bcad5f
TT
13142017-11-04 Tom Tromey <tom@tromey.com>
1315
1316 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
1317 type of "info".
1318 (compute_stack_depth): Likewise.
1319 (do_compile_dwarf_expr_to_c): Use std::vector.
1320
20dcd8ca
TT
13212017-11-04 Tom Tromey <tom@tromey.com>
1322
1323 * compile/compile-object-load.c (link_callbacks_einfo): Use
1324 std::string.
1325
33c7c59d
TT
13262017-11-04 Tom Tromey <tom@tromey.com>
1327
1328 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
1329 Use scoped_free_pendings.
1330 * dbxread.c (dbx_symfile_read, dbx_psymtab_to_symtab_1): Use
1331 scoped_free_pendings.
1332 * xcoffread.c (xcoff_psymtab_to_symtab_1): Use scoped_free_pendings.
1333 (xcoff_initial_scan): Likewise.
1334 * buildsym.c (reset_symtab_globals): Update comment.
1335 (scoped_free_pendings): Rename from really_free_pendings.
1336 (prepare_for_building): Update comment.
1337 (buildsym_init): Likewise.
1338 * buildsym.h (class scoped_free_pendings): New class.
1339 (really_free_pendings): Don't declare.
1340
67fa57cf
UW
13412017-11-03 Ulrich Weigand <uweigand@de.ibm.com>
1342
1343 * doublest.c (convert_doublest_to_floatformat): Fix uninitialized
1344 output when converting a zero value to a special byteorder format.
1345
f26ae15b
YQ
13462017-11-02 Yao Qi <yao.qi@linaro.org>
1347
1348 * frame.c (do_frame_register_read): Remove aspace.
1349 * jit.c (jit_frame_sniffer): Likwise.
1350 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1351 * regcache.c (regcache::regcache): Pass nullptr.
1352 (regcache_print): Caller updated.
1353 * regcache.h (regcache::regcache): Remove one constructor
1354 parameter aspace.
1355
6c6e9412
YQ
13562017-11-02 Yao Qi <yao.qi@linaro.org>
1357
1358 * regcache.h (regcache) <m_readonly_p>: Change it to const bool.
1359
8b86c959
YQ
13602017-11-02 Yao Qi <yao.qi@linaro.org>
1361
1362 * breakpoint.c (insert_single_step_breakpoints): Update.
1363 * frame.c (struct frame_info) <aspace>: Add const.
1364 (frame_save_as_regcache): Add const.
1365 (get_frame_address_space): Return const address_space *.
1366 * frame.h (get_frame_address_space): Update declaration.
1367 * infrun.c (struct step_over_info) <aspace>: Add const.
1368 (set_step_over_info): Make aspace const.
1369 (displaced_step_prepare_throw): Change variable const.
1370 (resume): Likewise.
1371 (proceed): Likewise.
1372 (adjust_pc_after_break): Likewise.
1373 (save_waitstatus): Likewise.
1374 (handle_signal_stop): Likewise.
1375 (keep_going_pass_signal): Likewise.
1376 * jit.c (jit_frame_sniffer): Add const.
1377 * mips-tdep.c (mips_single_step_through_delay): Likewise.
1378 * ppc-linux-tdep.c (ppu2spu_sniffer): Likewise.
1379 * record-full.c (record_full_wait_1): Likewise.
1380 * regcache.c (regcache::regcache): Change parameter to const.
1381 * regcache.h (regcache::regcache): Likewise.
1382 (regcache::aspace): Return const address_space *.
1383 (regcache) <m_aspace>: Add const.
1384
a01bda52
YQ
13852017-11-02 Yao Qi <yao.qi@linaro.org>
1386
1387 * darwin-nat.c (cancel_breakpoint): Use regcache->aspace ().
1388 * frame.c (create_sentinel_frame): Likewise.
1389 * infrun.c (displaced_step_prepare_throw): Likewise.
1390 (resume): Likewise.
1391 (thread_still_needs_step_over_bp): Likewise.
1392 (proceed): Likewise.
1393 (do_target_wait): Likewise.
1394 (adjust_pc_after_break): Likewise.
1395 (handle_syscall_event): Likewise.
1396 (save_waitstatus): Likewise.
1397 (handle_inferior_event_1): Likewise.
1398 (handle_signal_stop): Likewise.
1399 (keep_going_pass_signal): Likewise.
1400 * linux-nat.c (status_callback): Likewise.
1401 (save_stop_reason): Likewise.
1402 (resume_stopped_resumed_lwps): Likewise.
1403 * record-full.c (record_full_exec_insn): Likewise.
1404 (record_full_wait_1): Likewise.
1405 * regcache.c (get_regcache_aspace): Remove.
1406 * regcache.h (get_regcache_aspace): Remove.
1407
d999647b
YQ
14082017-11-02 Yao Qi <yao.qi@linaro.org>
1409
1410 * regcache.c (struct regcache_descr) <nr_raw_registers>: Remove.
1411 (init_regcache_descr): Use gdbarch_num_regs.
1412 (regcache::regcache): Likewise.
1413 (regcache::get_register_status): Likewise.
1414 (regcache::assert_raw_regnum): Likewise.
1415 (regcache::cooked_read): Likewise.
1416 (regcache::cooked_read_value): Likewise.
1417 (regcache::cooked_write): Likewise.
1418 (regcache::dump): Likewise.
1419 (regcache::num_raw_registers): New method.
1420 * regcache.h (class regcache) <num_raw_registers>: New.
1421
4e888c28
YQ
14222017-11-02 Yao Qi <yao.qi@linaro.org>
1423
1424 * regcache.c (regcache::assert_regnum): New method.
1425 (regcache::invalidate): Call assert_regnum.
1426 (regcache::raw_update): Likewise.
1427 (regcache::raw_write): Likewise.
1428 (regcache::raw_read_part): Likewise.
1429 (regcache::raw_write_part): Likewise.
1430 (regcache::raw_supply): Likewise.
1431 (regcache::raw_supply_integer): Likewise.
1432 (regcache::raw_supply_zeroed): Likewise.
1433 (regcache::raw_collect): Likewise.
1434 (regcache::raw_collect_integer): Likewise.
1435 * regcache.h (regcache::assert_regnum): Declare.
1436
2e1b49b3
YQ
14372017-11-02 Yao Qi <yao.qi@linaro.org>
1438
1439 * regcache.c (regcache::dump): Remove code.
1440
6c5218df
YQ
14412017-11-02 Yao Qi <yao.qi@linaro.org>
1442
1443 * regcache.c (struct regcache_descr) <sizeof_raw_register_status>:
1444 Remove.
1445 <sizeof_cooked_register_status>: Remove.
1446 (init_regcache_descr): Update.
1447 (regcache::regcache): Use nr_cooked_registers and nr_raw_registers.
1448 (regcache::save): Likewise.
1449 (regcache::dump): Likewise.
1450
dcc31d28
JB
14512017-11-01 James Bowman <james.bowman@ftdichip.com>
1452
1453 * ft32-tdep.c (ft32_fetch_instruction): New function.
1454 (ft32_analyze_prologue): Use ft32_fetch_instruction().
1455
3a87ae65
SM
14562017-10-31 Simon Marchi <simon.marchi@polymtl.ca>
1457
1458 * cli/cli-script.c (execute_control_command): Rename to ...
1459 (execute_control_command_1): ... this.
1460 (execute_control_command): New function.
1461
09b847f3
SM
14622017-10-31 Simon Marchi <simon.marchi@ericsson.com>
1463
1464 * tracepoint.c (tfind_command): Remove const_cast.
1465
f871c485
MG
14662017-10-30 Mike Gulick <mgulick@mathworks.com>
1467
1468 * Makefile.in (HFILES_NO_SRCDIR): Remove reference to gdb.h.
1469
b020ff80
SM
14702017-10-30 Simon Marchi <simon.marchi@ericsson.com>
1471
1472 * common/common-utils.h (in_inclusive_range): New function.
1473 * arm-tdep.c (arm_record_extension_space): Use
1474 in_inclusive_range.
1475 (thumb_record_ld_st_reg_offset): Use in_inclusive_range.
1476 * cris-tdep.c (cris_spec_reg_applicable): Use
1477 in_inclusive_range.
1478
1b81856f
PA
14792017-10-30 Pedro Alves <palves@redhat.com>
1480 Simon Marchi <simon.marchi@ericsson.com>
1481
1482 * remote.c (remote_set_syscall_catchpoint): Build a std::string
1483 instead of a gdb::unique_xmalloc_ptr, using string_appendf.
1484
31b833b3
PA
14852017-10-30 Pedro Alves <palves@redhat.com>
1486
1487 * common/common-utils.c (string_appendf, string_vappendf): New
1488 functions.
1489 * common/common-utils.h (string_appendf, string_vappendf): New
1490 declarations.
1491 * unittests/common-utils-selftests.c (string_appendf_func)
1492 (test_appendf_func, string_vappendf_wrapper, string_appendf_tests)
1493 (string_vappendf_tests): New functions.
1494 (_initialize_common_utils_selftests): Register "string_appendf" and
1495 "string_vappendf tests".
1496
4a250334
PA
14972017-10-30 Pedro Alves <palves@redhat.com>
1498
1499 * unittests/common-utils-selftests.c (format_func): New typedef.
1500 (string_printf_tests, string_vprintf_tests): Tests factored out
1501 and merged to ...
1502 (test_format_func): ... this new function.
1503 (string_printf_tests, string_vprintf_tests): Reimplement on top of
1504 test_format_func.
1505
16c5c17e
SM
15062017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1507
1508 * darwin-nat.c: Remove include of gdb.h.
1509
7ca51576
SM
15102017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1511
1512 * xtensa-xtregs.c: Fix formatting issues.
1513
c1342859
SM
15142017-10-29 Simon Marchi <simon.marchi@ericsson.com>
1515
1516 * xtensa-xtregs.c (xtensa_regtable_t) <name>: Constify.
1517
484d8d36
MD
15182017-10-28 Maksim Dzabraev <dzabraew@gmail.com>
1519
1520 PR python/21213
1521 * python/py-infthread.c (thpy_get_inferior): Increment reference
1522 of inferior before returning it.
1523
b5540b5f
SM
15242017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1525
1526 * unittests/common-utils-selftests.c (format): Add
1527 ATTRIBUTE_PRINTF.
1528
5a9dcda1
SM
15292017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1530
1531 * xml-syscall.c (struct syscall_desc): Add constructor.
1532 <name>: Change type to std::string.
1533 (syscall_desc_up): New typedef.
1534 (syscall_desc_p): Remove typeder.
1535 (DEF_VEC_P(syscall_desc_p)): Remove.
1536 (struct syscall_group_desc): Add constructor.
1537 <name>: Change type to std::string.
1538 <syscalls>: Change type to std::vector.
1539 (syscall_group_desc_up): New typedef.
1540 (syscall_group_desc_p): Remove typedef.
1541 (DEF_VEC_P(syscall_group_desc_p)): Remove.
1542 (struct syscalls_info) <syscalls>: Change type to std::vector of
1543 unique_ptr.
1544 <groups>: Likewise.
1545 <my_gdb_datadir>: Change type to std::string.
1546 (syscalls_info_up): New typedef.
1547 (allocate_syscalls_info): Remove.
1548 (syscalls_info_free_syscalls_desc): Remove.
1549 (syscalls_info_free_syscall_group_desc): Remove.
1550 (free_syscalls_info): Remove.
1551 (make_cleanup_free_syscalls_info): Remove.
1552 (syscall_group_create_syscall_group_desc): Adjust.
1553 (syscall_group_add_syscall): Adjust.
1554 (syscall_create_syscall_desc): Adjust.
1555 (syscall_parse_xml): Adjust, use unique_ptr instead of cleanup.
1556 (init_syscalls_info): Adjust.
1557 (syscall_group_get_group_by_name): Adjust.
1558 (xml_get_syscall_number): Adjust.
1559 (xml_get_syscall_name): Adjust.
1560 (xml_list_of_syscalls): Adjust.
1561 (xml_list_syscalls_by_group): Adjust.
1562 (xml_list_of_groups): Adjust.
1563
45461e0d
SM
15642017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1565
1566 * probe.h: Don't include gdb_vecs.h.
1567 (DEF_VEC_P (probe_p)): Remove.
1568 (find_probes_in_objfile): Return an std::vector.
1569 * probe.c (find_probes_in_objfile): Likewise.
1570 * breakpoint.c (breakpoint_objfile_data)
1571 <longjmp_probes>: Change type to std::vector.
1572 <exception_probes>: Likewise.
1573 (free_breakpoint_probes): Don't manually free vectors.
1574 (create_longjmp_master_breakpoint): Adjust.
1575 (create_exception_master_breakpoint): Adjust.
1576 * solib-svr4.c (svr4_create_probe_breakpoints): Change
1577 parameter type, adjust.
1578 (svr4_create_solib_event_breakpoints): Adjust.
1579
43dce439
SM
15802017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1581
1582 * breakpoint.c (breakpoint_objfile_data): Initialize fields.
1583 (get_breakpoint_objfile_data): Allocate breakpoint_objfile_data
1584 with new.
1585 (free_breakpoint_probes): Rename to ...
1586 (free_breakpoint_objfile_data): ... this, and call delete on
1587 bp_objfile_data..
1588
6a1b9516
SM
15892017-10-27 Simon Marchi <simon.marchi@polymtl.ca>
1590
1591 * auto-load.c: Don't include gdb_vecs.h, include algorithm.
1592 (loaded_script_ptr): Remove typedef.
1593 (DEF_VEC_P (loaded_script_ptr)): Remove.
1594 (struct collect_matching_scripts_data): Add constructor.
1595 <scripts_p>: Change type to (pointer to) std::vector.
1596 (collect_matching_scripts_data): Adjust.
1597 (sort_scripts_by_name): Make suitable for std::sort.
1598 (print_scripts): Don't sort vector, adjust to std::vector.
1599 (auto_load_info_scripts): Sort vectors, adjust to std::vector.
1600
593e3209
SM
16012017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1602
1603 * symfile.c (filename_language): Make struct, not typedef. Add
1604 constructor.
1605 <ext>: Change type to std::string.
1606 (DEF_VEC_O (filename_language)): Remove.
1607 (filename_language_table): Change type to std::vector.
1608 (add_filename_language): Adjust.
1609 (set_ext_lang_command): Adjust.
1610 (info_ext_lang_command): Adjust.
1611 (deduce_language_from_filename): Adjust.
1612 (class scoped_restore_filename_language_table): Remove.
1613 (test_filename_language): Use scoped_restore.
1614 (test_set_ext_lang_command): Use scoped_restore, adjust to
1615 std::vector change.
1616
32fa66eb
SM
16172017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1618
1619 * symfile.c: Include selftest.h.
1620 (class scoped_restore_filename_language_table): New.
1621 (test_filename_language): New test.
1622 (test_set_ext_lang_command): New test.
1623 (_initialize_symfile): Register tests.
1624
4a27f119
KS
16252017-10-27 Keith Seitz <keiths@redhat.com>
1626
1627 * breakpoint.c (print_breakpoint_location): Use the symbol saved
1628 in the bp_location, falling back to find_pc_sect_function when
1629 needed.
1630 (add_location_to_breakpoint): Save sal->symbol.
1631 * breakpoint.h (struct bp_location) <symbol>: New field.
1632 * symtab.c (find_function_start_sal): Save the symbol into the SaL.
1633 * symtab.h (struct symtab_and_line) <symbol>: New field.
1634
a43f3893
PF
16352017-10-26 Patrick Frants <osscontribute@gmail.com>
1636
7453e6b2 1637 PR gdb/13669
a43f3893
PF
1638 * cp-valprint.c (cp_print_value_fields): Use obstack_blank_fast
1639 to rewind obstack.
1640
23cc4e1b
PA
16412017-10-26 Pedro Alves <palves@redhat.com>
1642
1643 * remote.c (remote_async_terminal_ours_p): Delete.
1644 (remote_open_1, remote_terminal_inferior, remote_terminal_ours):
1645 Remove references to 'remote_async_terminal_ours_p'.
1646
6abc18bb
YQ
16472017-10-26 Yao Qi <yao.qi@linaro.org>
1648
1649 * breakpoint.h (regular_breakpoint_inserted_here_p): Remove.
1650
bd522513
YQ
16512017-10-26 Yao Qi <yao.qi@linaro.org>
1652
1653 * break-catch-sig.c (signal_catchpoint_breakpoint_hit): Make
1654 aspace const.
1655 * break-catch-syscall.c (breakpoint_hit_catch_syscall):
1656 Likewise.
1657 * breakpoint.c (bpstat_check_location): Remove cast.
1658 (breakpoint_hit_catch_fork): Make aspce const.
1659 (breakpoint_hit_catch_solib): Likewise.
1660 (breakpoint_hit_catch_exec): Likewise.
1661 (breakpoint_hit_ranged_breakpoint): Likewise.
1662 (breakpoint_hit_watchpoint): Likewise.
1663 (base_breakpoint_breakpoint_hit): Likewise.
1664 (bkpt_breakpoint_hit): Likewise.
1665 (dprintf_breakpoint_hit): Likewise.
1666 (tracepoint_breakpoint_hit): Likewise.
1667 * breakpoint.h (breakpoint_ops) <breakpoint_hit>: Likewise.
1668
accd0bcd
YQ
16692017-10-26 Yao Qi <yao.qi@linaro.org>
1670
1671 * breakpoint.c (breakpoint_location_address_match): Change
1672 "struct address_space *" to "const address_space".
1673 (breakpoint_location_address_range_overlap): Likewise.
1674 (breakpoint_here_p): Likewise.
1675 (breakpoint_in_range_p): Likewise.
1676 (moribund_breakpoint_here_p): Likewise.
1677 (bp_location_inserted_here_p): Likewise.
1678 (software_breakpoint_inserted_here_p): Likewise.
1679 (hardware_breakpoint_inserted_here_p): Likewise.
1680 (hardware_watchpoint_inserted_in_range): Likewise.
1681 (bpstat_check_location): Likewise.
1682 (bpstat_stop_status): Likewise.
1683 (breakpoint_address_match): Likewise.
1684 (breakpoint_address_match_range): Likewise.
1685 (breakpoint_location_address_match): Likewise.
1686 (breakpoint_location_address_range_overlap): Likewise.
1687 (insert_single_step_breakpoint): Likewise.
1688 (breakpoint_has_location_inserted_here): Likewise.
1689 (single_step_breakpoint_inserted_here_p): Likewise.
1690 (pc_at_non_inline_function): Likewise.
1691 * breakpoint.h (bpstat_stop_status): Update declaration.
1692 (breakpoint_here_p): Likewise.
1693 (breakpoint_in_range_p): Likewise.
1694 (moribund_breakpoint_here_p): Likewise.
1695 (breakpoint_inserted_here_p): Likewise.
1696 (software_breakpoint_inserted_here_p): Likewise.
1697 (hardware_breakpoint_inserted_here_p): Likewise.
1698 (breakpoint_has_location_inserted_here): Likewise.
1699 (single_step_breakpoint_inserted_here_p): Likewise.
1700 (hardware_watchpoint_inserted_in_range): Likewise.
1701 (breakpoint_address_match): Likewise.
1702 (insert_single_step_breakpoint): Likewise.
1703 (pc_at_non_inline_function): Likewise.
1704 * gdbthread.h (thread_has_single_step_breakpoint_here): Likewise.
1705 * record.c (record_check_stopped_by_breakpoint): Likewise.
1706 * record.h (record_check_stopped_by_breakpoint): Likewise.
1707 * thread.c (thread_has_single_step_breakpoint_here): Likewise.
1708
ac7936df
YQ
17092017-10-25 Yao Qi <yao.qi@linaro.org>
1710
1711 * aarch32-linux-nat.c (aarch32_gp_regcache_supply): Use
1712 regcache->arch () instead get_regcache_arch.
1713 * aarch64-fbsd-nat.c (aarch64_fbsd_fetch_inferior_registers):
1714 Likewise.
1715 (aarch64_fbsd_store_inferior_registers): Likewise.
1716 * aarch64-linux-nat.c (fetch_gregs_from_thread): Likewise.
1717 (store_gregs_to_thread): Likewise.
1718 (fetch_fpregs_from_thread): Likewise.
1719 (store_fpregs_to_thread): Likewise.
1720 * aarch64-tdep.c (aarch64_extract_return_value): Likewise.
1721 (aarch64_store_return_value): Likewise.
1722 (aarch64_software_single_step): Likewise.
1723 * aix-thread.c (aix_thread_wait): Likewise.
1724 (supply_reg32): Likewise.
1725 (supply_sprs64): Likewise.
1726 (supply_sprs32): Likewise.
1727 (fill_gprs64): Likewise.
1728 (fill_gprs32): Likewise.
1729 (fill_sprs64): Likewise.
1730 (fill_sprs32): Likewise.
1731 (store_regs_user_thread): Likewise.
1732 (store_regs_kernel_thread): Likewise.
1733 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers): Likewise.
1734 (alphabsd_store_inferior_registers): Likewise.
1735 * alpha-tdep.c (alpha_extract_return_value): Likewise.
1736 (alpha_store_return_value): Likewise.
1737 (alpha_deal_with_atomic_sequence): Likewise.
1738 (alpha_next_pc): Likewise.
1739 (alpha_software_single_step): Likewise.
1740 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Likewise.
1741 (amd64bsd_store_inferior_registers): Likewise.
1742 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers):
1743 Likewise.
1744 (amd64_linux_store_inferior_registers): Likewise.
1745 * amd64-nat.c (amd64_supply_native_gregset): Likewise.
1746 (amd64_collect_native_gregset): Likewise.
1747 * amd64-obsd-tdep.c (amd64obsd_supply_uthread): Likewise.
1748 (amd64obsd_collect_uthread): Likewise.
1749 * amd64-tdep.c (amd64_supply_fpregset): Likewise.
1750 (amd64_collect_fpregset): Likewise.
1751 (amd64_supply_fxsave): Likewise.
1752 (amd64_supply_xsave): Likewise.
1753 (amd64_collect_fxsave): Likewise.
1754 (amd64_collect_xsave): Likewise.
1755 * arc-tdep.c (arc_write_pc): Likewise.
1756 * arch-utils.c (default_skip_permanent_breakpoint): Likewise.
1757 * arm-fbsd-nat.c (arm_fbsd_fetch_inferior_registers): Likewise.
1758 (arm_fbsd_store_inferior_registers): Likewise.
1759 * arm-linux-nat.c (fetch_vfp_regs): Likewise.
1760 (store_vfp_regs): Likewise.
1761 (arm_linux_fetch_inferior_registers): Likewise.
1762 (arm_linux_store_inferior_registers): Likewise.
1763 * arm-linux-tdep.c (arm_linux_supply_gregset): Likewise.
1764 (arm_linux_sigreturn_next_pc): Likewise.
1765 (arm_linux_get_next_pcs_syscall_next_pc): Likewise.
1766 * arm-nbsd-nat.c (arm_supply_gregset): Likewise.
1767 (fetch_register): Likewise.
1768 (store_register): Likewise.
1769 * arm-tdep.c (arm_is_thumb): Likewise.
1770 (displaced_in_arm_mode): Likewise.
1771 (bx_write_pc): Likewise.
1772 (arm_get_next_pcs_addr_bits_remove): Likewise.
1773 (arm_software_single_step): Likewise.
1774 (arm_extract_return_value): Likewise.
1775 (arm_store_return_value): Likewise.
1776 (arm_write_pc): Likewise.
1777 * bfin-tdep.c (bfin_extract_return_value): Likewise.
1778 * bsd-uthread.c (bsd_uthread_fetch_registers): Likewise.
1779 (bsd_uthread_store_registers): Likewise.
1780 * core-regset.c (fetch_core_registers): Likewise.
1781 * corelow.c (get_core_registers): Likewise.
1782 * cris-tdep.c (cris_store_return_value): Likewise.
1783 (cris_extract_return_value): Likewise.
1784 (find_step_target): Likewise.
1785 (find_step_target): Likewise.
1786 (cris_software_single_step): Likewise.
1787 * ctf.c (ctf_fetch_registers): Likewise.
1788 * darwin-nat.c (cancel_breakpoint): Likewise.
1789 * fbsd-tdep.c (fbsd_collect_thread_registers): Likewise.
1790 * frv-tdep.c (frv_extract_return_value): Likewise.
1791 * ft32-tdep.c (ft32_store_return_value): Likewise.
1792 (ft32_extract_return_value): Likewise.
1793 * go32-nat.c (fetch_register): Likewise.
1794 (go32_fetch_registers): Likewise.
1795 (go32_store_registers): Likewise.
1796 (store_register): Likewise.
1797 * h8300-tdep.c (h8300_extract_return_value): Likewise.
1798 (h8300_store_return_value): Likewise.
1799 * hppa-linux-nat.c (fetch_register): Likewise.
1800 (store_register): Likewise.
1801 (hppa_linux_fetch_inferior_registers): Likewise.
1802 (hppa_linux_store_inferior_registers): Likewise.
1803 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers): Likewise.
1804 (i386_darwin_store_inferior_registers): Likewise.
1805 * i386-gnu-nat.c (gnu_fetch_registers): Likewise.
1806 (gnu_store_registers): Likewise.
1807 * i386-linux-nat.c (fetch_register): Likewise.
1808 (store_register): Likewise.
1809 (supply_gregset): Likewise.
1810 (fill_gregset): Likewise.
1811 (i386_linux_fetch_inferior_registers): Likewise.
1812 (i386_linux_store_inferior_registers): Likewise.
1813 (i386_linux_resume): Likewise.
1814 * i386-linux-tdep.c (i386_linux_get_syscall_number_from_regcache):
1815 Likewise.
1816 * i386-nto-tdep.c (i386nto_supply_gregset): Likewise.
1817 * i386-obsd-nat.c (i386obsd_supply_pcb): Likewise.
1818 * i386-obsd-tdep.c (i386obsd_supply_uthread): Likewise.
1819 (i386obsd_collect_uthread): Likewise.
1820 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
1821 (i386_supply_gregset): Likewise.
1822 (i386_collect_gregset): Likewise.
1823 (i386_supply_fpregset): Likewise.
1824 (i386_collect_fpregset): Likewise.
1825 (i386_mpx_bd_base): Likewise.
1826 * i386-v4-nat.c (supply_fpregset): Likewise.
1827 (fill_fpregset): Likewise.
1828 * i387-tdep.c (i387_supply_fsave): Likewise.
1829 (i387_collect_fsave): Likewise.
1830 (i387_supply_fxsave): Likewise.
1831 (i387_collect_fxsave): Likewise.
1832 (i387_supply_xsave): Likewise.
1833 (i387_collect_xsave): Likewise.
1834 * ia64-linux-nat.c (ia64_linux_fetch_registers): Likewise.
1835 (ia64_linux_store_registers): Likewise.
1836 * ia64-tdep.c (ia64_access_rse_reg): Likewise.
1837 (ia64_extract_return_value): Likewise.
1838 (ia64_store_return_value): Likewise.
1839 (find_func_descr): Likewise.
1840 * inf-child.c (inf_child_fetch_inferior_registers): Likewise.
1841 * inf-ptrace.c (inf_ptrace_fetch_registers): Likewise.
1842 (inf_ptrace_store_registers): Likewise.
1843 * infrun.c (use_displaced_stepping): Likewise.
1844 (displaced_step_prepare_throw): Likewise.
1845 (resume): Likewise.
1846 (proceed): Likewise.
1847 (do_target_wait): Likewise.
1848 (adjust_pc_after_break): Likewise.
1849 (handle_inferior_event_1): Likewise.
1850 (handle_signal_stop): Likewise.
1851 (save_infcall_suspend_state): Likewise.
1852 (restore_infcall_suspend_state): Likewise.
1853 * iq2000-tdep.c (iq2000_extract_return_value): Likewise.
1854 * jit.c (jit_frame_prev_register): Likewise.
1855 * linux-nat.c (save_stop_reason): Likewise.
1856 (linux_nat_wait_1): Likewise.
1857 (resume_stopped_resumed_lwps): Likewise.
1858 * linux-record.c (record_linux_sockaddr): Likewise.
1859 (record_linux_msghdr): Likewise.
1860 (record_linux_system_call): Likewise.
1861 * linux-tdep.c (linux_collect_thread_registers): Likewise.
1862 * lm32-tdep.c (lm32_extract_return_value): Likewise.
1863 (lm32_store_return_value): Likewise.
1864 * m32c-tdep.c (m32c_read_flg): Likewise.
1865 (m32c_pseudo_register_read): Likewise.
1866 (m32c_pseudo_register_write): Likewise.
1867 * m32r-linux-tdep.c (m32r_linux_supply_gregset): Likewise.
1868 (m32r_linux_collect_gregset): Likewise.
1869 * m32r-tdep.c (m32r_store_return_value): Likewise.
1870 (m32r_extract_return_value): Likewise.
1871 * m68k-bsd-nat.c (m68kbsd_supply_fpregset): Likewise.
1872 (m68kbsd_collect_fpregset): Likewise.
1873 * m68k-bsd-tdep.c (m68kbsd_supply_fpregset): Likewise.
1874 * m68k-linux-nat.c (fetch_register): Likewise.
1875 (old_fetch_inferior_registers): Likewise.
1876 (old_store_inferior_registers): Likewise.
1877 (store_regs): Likewise.
1878 * m68k-tdep.c (m68k_svr4_extract_return_value): Likewise.
1879 (m68k_svr4_store_return_value): Likewise.
1880 * m88k-tdep.c (m88k_store_arguments): Likewise.
1881 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Likewise.
1882 (mi_cmd_data_write_register_values): Likewise.
1883 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers): Likewise.
1884 (mips_fbsd_store_inferior_registers): Likewise.
1885 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Likewise.
1886 (mips_fbsd_supply_gregs): Likewise.
1887 (mips_fbsd_collect_fpregs): Likewise.
1888 (mips_fbsd_collect_gregs): Likewise.
1889 (mips_fbsd_supply_fpregset): Likewise.
1890 (mips_fbsd_collect_fpregset): Likewise.
1891 (mips_fbsd_supply_gregset): Likewise.
1892 (mips_fbsd_collect_gregset): Likewise.
1893 * mips-linux-nat.c (supply_gregset): Likewise.
1894 (fill_gregset): Likewise.
1895 (supply_fpregset): Likewise.
1896 (fill_fpregset): Likewise.
1897 * mips-linux-tdep.c (mips_supply_gregset): Likewise.
1898 (mips_fill_gregset): Likewise.
1899 (mips_supply_fpregset): Likewise.
1900 (mips_fill_fpregset): Likewise.
1901 (mips64_supply_gregset): Likewise.
1902 (micromips_linux_sigframe_validate): Likewise.
1903 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers): Likewise.
1904 (mipsnbsd_fetch_inferior_registers): Likewise.
1905 (mipsnbsd_store_inferior_registers): Likewise.
1906 * mips-nbsd-tdep.c (mipsnbsd_supply_fpregset): Likewise.
1907 (mipsnbsd_supply_gregset): Likewise.
1908 (mipsnbsd_iterate_over_regset_sections): Likewise.
1909 (mipsnbsd_supply_reg): Likewise.
1910 (mipsnbsd_supply_fpreg): Likewise.
1911 * mips-tdep.c (mips_in_frame_stub): Likewise.
1912 (mips_dummy_id): Likewise.
1913 (is_octeon_bbit_op): Likewise.
1914 (micromips_bc1_pc): Likewise.
1915 (extended_mips16_next_pc): Likewise.
1916 (mips16_next_pc): Likewise.
1917 (deal_with_atomic_sequence): Likewise.
1918 * moxie-tdep.c (moxie_process_readu): Likewise.
1919 * nios2-tdep.c (nios2_get_next_pc): Likewise.
1920 * nto-procfs.c (procfs_store_registers): Likewise.
1921 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers): Likewise.
1922 (ppcfbsd_store_inferior_registers): Likewise.
1923 * ppc-linux-nat.c (fetch_vsx_register): Likewise.
1924 (fetch_altivec_register): Likewise.
1925 (get_spe_registers): Likewise.
1926 (fetch_spe_register): Likewise.
1927 (fetch_altivec_registers): Likewise.
1928 (fetch_all_gp_regs): Likewise.
1929 (fetch_all_fp_regs): Likewise.
1930 (store_vsx_register): Likewise.
1931 (store_altivec_register): Likewise.
1932 (set_spe_registers): Likewise.
1933 (store_spe_register): Likewise.
1934 (store_altivec_registers): Likewise.
1935 (store_all_gp_regs): Likewise.
1936 (store_all_fp_regs): Likewise.
1937 * ppc-linux-tdep.c (ppc_linux_supply_gregset): Likewise.
1938 (ppc_linux_collect_gregset): Likewise.
1939 (ppc_canonicalize_syscall): Likewise.
1940 (ppc_linux_record_signal): Likewise.
1941 (ppu2spu_prev_register): Likewise.
1942 * ppc-nbsd-nat.c (ppcnbsd_supply_pcb): Likewise.
1943 * ppc-obsd-nat.c (ppcobsd_fetch_registers): Likewise.
1944 (ppcobsd_store_registers): Likewise.
1945 * ppc-ravenscar-thread.c (ppc_ravenscar_generic_fetch_registers):
1946 Likewise.
1947 (ppc_ravenscar_generic_store_registers): Likewise.
1948 * procfs.c (procfs_fetch_registers): Likewise.
1949 (procfs_store_registers): Likewise.
1950 * ravenscar-thread.c (ravenscar_fetch_registers): Likewise.
1951 (ravenscar_store_registers): Likewise.
1952 (ravenscar_prepare_to_store): Likewise.
1953 * record-btrace.c (record_btrace_fetch_registers): Likewise.
1954 * record-full.c (record_full_wait_1): Likewise.
1955 (record_full_registers_change): Likewise.
1956 (record_full_store_registers): Likewise.
1957 (record_full_core_fetch_registers): Likewise.
1958 (record_full_save): Likewise.
1959 (record_full_goto_insn): Likewise.
1960 * regcache.c (regcache_register_size): Likewise.
1961 (get_regcache_arch): Remove.
1962 (regcache_read_pc): Likewise.
1963 * regcache.h (get_regcache_arch): Remove.
1964 * remote-sim.c (gdbsim_fetch_register): Likewise.
1965 (gdbsim_store_register): Likewise.
1966 * remote.c (fetch_register_using_p): Likewise.
1967 (send_g_packet): Likewise.
1968 (remote_prepare_to_store): Likewise.
1969 (store_registers_using_G): Likewise.
1970 * reverse.c (save_bookmark_command): Likewise.
1971 (goto_bookmark_command): Likewise.
1972 * rs6000-aix-tdep.c (branch_dest): Likewise.
1973 * rs6000-nat.c (rs6000_ptrace64): Likewise.
1974 (fetch_register): Likewise.
1975 * rs6000-tdep.c (ppc_supply_reg): Likewise.
1976 (ppc_collect_reg): Likewise.
1977 (ppc_collect_gregset): Likewise.
1978 (ppc_collect_fpregset): Likewise.
1979 (ppc_collect_vsxregset): Likewise.
1980 (ppc_collect_vrregset): Likewise.
1981 (ppc_displaced_step_hw_singlestep): Likewise.
1982 (rs6000_pseudo_register_read): Likewise.
1983 (rs6000_pseudo_register_write): Likewise.
1984 * s390-linux-nat.c (supply_gregset): Likewise.
1985 (fill_gregset): Likewise.
1986 (s390_linux_fetch_inferior_registers): Likewise.
1987 * s390-linux-tdep.c (s390_write_pc): Likewise.
1988 (s390_software_single_step): Likewise.
1989 (s390_all_but_pc_registers_record): Likewise.
1990 (s390_linux_syscall_record): Likewise.
1991 * sentinel-frame.c (sentinel_frame_prev_arch): Likewise.
1992 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers): Likewise.
1993 (shnbsd_store_inferior_registers): Likewise.
1994 * sh-tdep.c (sh_extract_return_value_nofpu): Likewise.
1995 (sh_extract_return_value_fpu): Likewise.
1996 (sh_store_return_value_nofpu): Likewise.
1997 (sh_corefile_supply_regset): Likewise.
1998 (sh_corefile_collect_regset): Likewise.
1999 * sh64-tdep.c (sh64_extract_return_value): Likewise.
2000 (sh64_store_return_value): Likewise.
2001 * sparc-linux-tdep.c (sparc32_linux_collect_core_fpregset): Likewise.
2002 * sparc-nat.c (sparc_fetch_inferior_registers): Likewise.
2003 (sparc_store_inferior_registers): Likewise.
2004 * sparc-ravenscar-thread.c (register_in_thread_descriptor_p): Likewise.
2005 (sparc_ravenscar_prepare_to_store): Likewise.
2006 * sparc-tdep.c (sparc32_store_arguments): Likewise.
2007 (sparc_analyze_control_transfer): Likewise.
2008 (sparc_step_trap): Likewise.
2009 (sparc_software_single_step): Likewise.
2010 (sparc32_gdbarch_init): Likewise.
2011 (sparc_supply_rwindow): Likewise.
2012 (sparc_collect_rwindow): Likewise.
2013 * sparc64-linux-tdep.c (sparc64_linux_collect_core_fpregset): Likewise.
2014 * sparc64-nbsd-nat.c (sparc64nbsd_supply_gregset): Likewise.
2015 (sparc64nbsd_collect_gregset): Likewise.
2016 (sparc64nbsd_supply_fpregset): Likewise.
2017 (sparc64nbsd_collect_fpregset): Likewise.
2018 * sparc64-tdep.c (sparc64_store_arguments): Likewise.
2019 (sparc64_supply_gregset): Likewise.
2020 (sparc64_collect_gregset): Likewise.
2021 (sparc64_supply_fpregset): Likewise.
2022 (sparc64_collect_fpregset): Likewise.
2023 * spu-linux-nat.c (spu_fetch_inferior_registers): Likewise.
2024 * spu-tdep.c (spu_unwind_sp): Likewise.
2025 (spu2ppu_prev_register): Likewise.
2026 (spu_memory_remove_breakpoint): Likewise.
2027 * stack.c (return_command): Likewise.
2028 * tic6x-tdep.c (tic6x_extract_signed_field): Likewise.
2029 * tracefile-tfile.c (tfile_fetch_registers): Likewise.
2030 * tracefile.c (trace_save_ctf): Likewise.
2031 * windows-nat.c (do_windows_fetch_inferior_registers): Likewise.
2032 (do_windows_store_inferior_registers): Likewise.
2033 (windows_resume): Likewise.
2034 * xtensa-linux-nat.c (fill_gregset): Likewise.
2035 (supply_gregset_reg): Likewise.
2036 * xtensa-tdep.c (xtensa_register_write_masked): Likewise.
2037 (xtensa_register_read_masked): Likewise.
2038 (xtensa_supply_gregset): Likewise.
2039 (xtensa_extract_return_value): Likewise.
2040 (xtensa_store_return_value): Likewise.
2041
edd079d9
UW
20422017-10-25 Ulrich Weigand <uweigand@de.ibm.com>
2043
2044 * doublest.c (floatformat_from_string): New function.
2045 * doublest.h (floatformat_from_string): Add prototype.
2046
2047 * std-operator.def (OP_DOUBLE, OP_DECFLOAT): Remove, replace by ...
2048 (OP_FLOAT): ... this.
2049 * expression.h: Do not include "doublest.h".
2050 (union exp_element): Replace doubleconst and decfloatconst by
2051 new element floatconst.
2052 * ada-lang.c (resolve_subexp): Handle OP_FLOAT instead of OP_DOUBLE.
2053 (ada_evaluate_subexp): Likewise.
2054 * eval.c (evaluate_subexp_standard): Handle OP_FLOAT instead of
2055 OP_DOUBLE and OP_DECFLOAT.
2056 * expprint.c (print_subexp_standard): Likewise.
2057 (dump_subexp_body_standard): Likewise.
2058 * breakpoint.c (watchpoint_exp_is_const): Likewise.
2059
2060 * parse.c: Include "dfp.h".
2061 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2062 (write_exp_elt_floatcst): New function.
2063 (operator_length_standard): Handle OP_FLOAT instead of OP_DOUBLE
2064 and OP_DECFLOAT.
2065 (operator_check_standard): Likewise.
2066 (parse_float): Do not accept suffix. Take type as input. Return bool.
2067 Return target format buffer instead of host DOUBLEST.
2068 Use floatformat_from_string and decimal_from_string to parse
2069 either binary or decimal floating-point types.
2070 (parse_c_float): Remove.
2071 * parser-defs.h: Do not include "doublest.h".
2072 (write_exp_elt_dblcst, write_exp_elt_decfloatcst): Remove.
2073 (write_exp_elt_floatcst): Add prototype.
2074 (parse_float): Update prototype.
2075 (parse_c_float): Remove.
2076
2077 * c-exp.y: Do not include "dfp.h".
2078 (typed_val_float): Use byte buffer instead of DOUBLEST.
2079 (typed_val_decfloat): Remove.
2080 (DECFLOAT): Remove.
2081 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2082 (parse_number): Update to new parse_float interface.
2083 Parse suffixes and determine type before calling parse_float.
2084 Handle decimal and binary FP types the same way.
2085
2086 * d-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2087 (FLOAT_LITERAL): Use OP_FLOAT and write_exp_elt_floatcst.
2088 (parse_number): Update to new parse_float interface.
2089 Parse suffixes and determine type before calling parse_float.
2090
2091 * f-exp.y: Replace dval by typed_val_float.
2092 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2093 (parse_number): Use parse_float instead of atof.
2094
2095 * go-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2096 (parse_go_float): Remove.
2097 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2098 (parse_number): Call parse_float instead of parse_go_float.
2099 Parse suffixes and determine type before calling parse_float.
2100
2101 * p-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2102 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2103 (parse_number): Update to new parse_float interface.
2104 Parse suffixes and determine type before calling parse_float.
2105
2106 * m2-exp.y: Replace dval by byte buffer val.
2107 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2108 (parse_number): Call parse_float instead of atof.
2109
2110 * rust-exp.y (typed_val_float): Use byte buffer instead of DOUBLEST.
2111 (lex_number): Call parse_float instead of strtod.
2112 (ast_dliteral): Use OP_FLOAT instead of OP_DOUBLE.
2113 (convert_ast_to_expression): Handle OP_FLOAT instead of OP_DOUBLE.
2114 Use write_exp_elt_floatcst.
2115 (unit_testing): Remove static variable.
2116 (rust_type): Do not check unit_testing.
2117 (rust_lex_tests): Do not set uint_testing. Set up dummy rust_parser.
2118
2119 * ada-exp.y (type_float, type_double): Remove.
2120 (typed_val_float): Use byte buffer instead of DOUBLEST.
2121 (FLOAT): Use OP_FLOAT and write_exp_elt_floatcst.
2122 * ada-lex.l (processReal): Use parse_float instead of sscanf.
2123
cc628f3d
AH
21242017-10-25 Alan Hayward <alan.hayward@arm.com>
2125
2126 * aarch64-tdep.h (enum aarch64_regnum): Remove.
2127 * arch/aarch64.h: New file.
2128
09a7c6aa
UW
21292017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2130
2131 * dfp.h (decimal_from_string): Use const reference for argument.
2132 * dfp.c (decimal_from_string): Likewise.
2133
8ba0dd51
UW
21342017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2135
2136 * i387-tdep.c (print_i387_value): Use floatformat_to_string.
2137 * sh64-tdep.c (sh64_do_fp_register): Likewise.
2138 * mips-tdep.c (mips_print_fp_register): Likewise.
2139
16e812b2
UW
21402017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2141
2142 * common/format.h (enum argclass): Replace decfloat_arg by
2143 dec32float_arg, dec64float_arg, and dec128float_arg.
2144 * common/format.c (parse_format_string): Update to return
2145 new decimal float argument classes.
2146
2147 * printcmd.c (printf_decfloat): Rename to ...
2148 (printf_floating): ... this. Add argclass argument, and use it
2149 instead of parsing the format string again. Add support for
2150 binary floating-point values, using floatformat_to_string.
2151 Convert value to the target format if it doesn't already match.
2152 (ui_printf): Call printf_floating instead of printf_decfloat,
2153 also for double_arg / long_double_arg. Pass argclass.
2154
2155 * dfp.c (decimal_to_string): Add format string argument.
2156 * dfp.h (decimal_to_string): Likewise.
2157
2158 * doublest.c (floatformat_to_string): Add format string argument.
2159 * doublest.h (floatformat_to_string): Likewise.
2160
fdf0cbc2
UW
21612017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2162
2163 * doublest.c (floatformat_precision): New routine.
2164 (floatformat_to_string): Likewise.
2165 * doublest.c (floatformat_to_string): Add prototype.
2166
2167 * printcmd.c (print_scalar_formatted): Only call print_floating
2168 on floating-point types.
2169 * valprint.c: Do not include "floatformat.h".
2170 (generic_val_print_decfloat): Remove.
2171 (generic_val_print): Call generic_val_print_float for both
2172 TYPE_CODE_FLT and TYPE_CODE_DECFLOAT.
2173 (print_floating): Use floatformat_to_string. Handle decimal float.
2174 (print_decimal_floating): Remove, merge into floatformat_to_string.
2175 * value.h (print_decimal_floating): Remove.
2176
2177 * Makefile.in: Do not build doublest.c with -Wformat-nonliteral.
2178
5033013f
UW
21792017-10-24 Ulrich Weigand <uweigand@de.ibm.com>
2180
2181 * buildsym.c (end_symtab_get_static_block): Use std::stable_sort.
2182
a664f67e
SM
21832017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2184
2185 * memattr.h: Don't include vec.h.
2186 (struct mem_attrib): Initialize fields.
2187 <unknown>: New static method.
2188 (struct mem_region): Add constructors, operator<, initialize
2189 fields.
2190 * memattr.c: Include algorithm.
2191 (default_mem_attrib, unknown_mem_attrib): Remove.
2192 (user_mem_region_list): New global.
2193 (target_mem_region_list, mem_region_list): Change type to
2194 std::vector<mem_region>.
2195 (mem_use_target): Now a function.
2196 (target_mem_regions_valid): Change type to bool.
2197 (mem_region_lessthan, mem_region_cmp, mem_region_init): Remove.
2198 (require_user_regions): Adjust.
2199 (require_target_regions): Adjust.
2200 (create_mem_region): Adjust.
2201 (lookup_mem_region): Adjust.
2202 (invalidate_target_mem_regions): Adjust.
2203 (mem_clear): Rename to...
2204 (user_mem_clear): ... this, and adjust.
2205 (mem_command): Adjust.
2206 (info_mem_command): Adjust.
2207 (mem_enable, enable_mem_command, mem_disable,
2208 disable_mem_command): Adjust.
2209 (mem_delete): Adjust.
2210 (delete_mem_command): Adjust.
2211 * memory-map.h (parse_memory_map): Return an std::vector.
2212 * memory-map.c (parse_memory_map): Likewise.
2213 (struct memory_map_parsing_data): Add constructor.
2214 <memory_map>: Point to std::vector.
2215 (memory_map_start_memory): Adjust.
2216 (memory_map_end_memory): Adjust.
2217 (memory_map_end_property): Adjust.
2218 (clear_result): Remove.
2219 * remote.c (remote_memory_map): Return an std::vector.
2220 * target-debug.h (target_debug_print_VEC_mem_region_s__p):
2221 Remove.
2222 (target_debug_print_mem_region_vector): New.
2223 * target-delegates.c: Regenerate.
2224 * target.h (mem_region_vector): New typedef.
2225 (to_memory_map): Return mem_region_vector.
2226 (target_memory_map): Return an std::vector.
2227 * target.c (target_memory_map): Return an std::vector.
2228 (flash_erase_command): Adjust.
2229
6e17c565
SM
22302017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2231
2232 * memory-map.c (struct memory_map_parsing_data) <property_name>:
2233 Change type to std::string.
2234 (memory_map_start_property): Adjust.
2235 (memory_map_end_property): Adjust.
2236
cfba9872
SM
22372017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2238
2239 * infrun.h: Include common/byte-vector.h.
2240 (struct displaced_step_closure): New struct.
2241 (struct buf_displaced_step_closure): New struct.
2242 * infrun.c (displaced_step_closure::~displaced_step_closure):
2243 Provide default implementation.
2244 (displaced_step_clear): Deallocate step closure with delete.
2245 * aarch64-tdep.c (displaced_step_closure): Rename to ...
2246 (aarch64_displaced_step_closure): ... this, extend
2247 displaced_step_closure.
2248 (aarch64_displaced_step_data) <dsc>: Change type to
2249 aarch64_displaced_step_closure.
2250 (aarch64_displaced_step_copy_insn): Adjust to type change, use
2251 unique_ptr.
2252 (aarch64_displaced_step_fixup): Add cast for displaced step
2253 closure.
2254 * amd64-tdep.c (displaced_step_closure): Rename to ...
2255 (amd64_displaced_step_closure): ... this, extend
2256 displaced_step_closure.
2257 <insn_buf>: Change type to std::vector<gdb_byte>.
2258 <max_len>: Remove.
2259 (fixup_riprel): Change type of DSC parameter, adjust to type
2260 change of insn_buf.
2261 (fixup_displaced_copy): Change type of DSC parameter.
2262 (amd64_displaced_step_copy_insn): Instantiate
2263 amd64_displaced_step_closure.
2264 (amd64_displaced_step_fixup): Add cast for closure type, adjust
2265 to type change of insn_buf.
2266 * arm-linux-tdep.c (arm_linux_cleanup_svc): Change type of
2267 parameter DSC.
2268 (arm_linux_copy_svc): Likewise.
2269 (cleanup_kernel_helper_return): Likewise.
2270 (arm_catch_kernel_helper_return): Likewise.
2271 (arm_linux_displaced_step_copy_insn): Instantiate
2272 arm_displaced_step_closure.
2273 * arm-tdep.c (arm_pc_is_thumb): Add cast for closure.
2274 (displaced_read_reg): Change type of parameter DSC.
2275 (branch_write_pc): Likewise.
2276 (load_write_pc): Likewise.
2277 (alu_write_pc): Likewise.
2278 (displaced_write_reg): Likewise.
2279 (arm_copy_unmodified): Likewise.
2280 (thumb_copy_unmodified_32bit): Likewise.
2281 (thumb_copy_unmodified_16bit): Likewise.
2282 (cleanup_preload): Likewise.
2283 (install_preload): Likewise.
2284 (arm_copy_preload): Likewise.
2285 (thumb2_copy_preload): Likewise.
2286 (install_preload_reg): Likewise.
2287 (arm_copy_preload_reg): Likewise.
2288 (cleanup_copro_load_store): Likewise.
2289 (install_copro_load_store): Likewise.
2290 (arm_copy_copro_load_store) Likewise.
2291 (thumb2_copy_copro_load_store): Likewise.
2292 (cleanup_branch): Likewise.
2293 (install_b_bl_blx): Likewise.
2294 (arm_copy_b_bl_blx): Likewise.
2295 (thumb2_copy_b_bl_blx): Likewise.
2296 (thumb_copy_b): Likewise.
2297 (install_bx_blx_reg): Likewise.
2298 (arm_copy_bx_blx_reg): Likewise.
2299 (thumb_copy_bx_blx_reg): Likewise.
2300 (cleanup_alu_imm): Likewise.
2301 (arm_copy_alu_imm): Likewise.
2302 (thumb2_copy_alu_imm): Likewise.
2303 (cleanup_alu_reg): Likewise.
2304 (install_alu_reg): Likewise.
2305 (arm_copy_alu_reg): Likewise.
2306 (thumb_copy_alu_reg): Likewise.
2307 (cleanup_alu_shifted_reg): Likewise.
2308 (install_alu_shifted_reg): Likewise.
2309 (arm_copy_alu_shifted_reg): Likewise.
2310 (cleanup_load): Likewise.
2311 (cleanup_store): Likewise.
2312 (arm_copy_extra_ld_st): Likewise.
2313 (install_load_store): Likewise.
2314 (thumb2_copy_load_literal): Likewise.
2315 (thumb2_copy_load_reg_imm): Likewise.
2316 (arm_copy_ldr_str_ldrb_strb): Likewise.
2317 (cleanup_block_load_all): Likewise.
2318 (cleanup_block_store_pc): Likewise.
2319 (cleanup_block_load_pc): Likewise.
2320 (arm_copy_block_xfer): Likewise.
2321 (thumb2_copy_block_xfer): Likewise.
2322 (cleanup_svc): Likewise.
2323 (install_svc): Likewise.
2324 (arm_copy_svc): Likewise.
2325 (thumb_copy_svc): Likewise.
2326 (arm_copy_undef): Likewise.
2327 (thumb_32bit_copy_undef): Likewise.
2328 (arm_copy_unpred): Likewise.
2329 (arm_decode_misc_memhint_neon): Likewise.
2330 (arm_decode_unconditional): Likewise.
2331 (arm_decode_miscellaneous): Likewise.
2332 (arm_decode_dp_misc): Likewise.
2333 (arm_decode_ld_st_word_ubyte): Likewise.
2334 (arm_decode_media): Likewise.
2335 (arm_decode_b_bl_ldmstm): Likewise.
2336 (arm_decode_ext_reg_ld_st): Likewise.
2337 (thumb2_decode_dp_shift_reg): Likewise.
2338 (thumb2_decode_ext_reg_ld_st): Likewise.
2339 (arm_decode_svc_copro): Likewise.
2340 (thumb2_decode_svc_copro): Likewise.
2341 (install_pc_relative): Likewise.
2342 (thumb_copy_pc_relative_16bit): Likewise.
2343 (thumb_decode_pc_relative_16bit): Likewise.
2344 (thumb_copy_pc_relative_32bit): Likewise.
2345 (thumb_copy_16bit_ldr_literal): Likewise.
2346 (thumb_copy_cbnz_cbz): Likewise.
2347 (thumb2_copy_table_branch): Likewise.
2348 (cleanup_pop_pc_16bit_all): Likewise.
2349 (thumb_copy_pop_pc_16bit): Likewise.
2350 (thumb_process_displaced_16bit_insn): Likewise.
2351 (decode_thumb_32bit_ld_mem_hints): Likewise.
2352 (thumb_process_displaced_32bit_insn): Likewise.
2353 (thumb_process_displaced_insn): Likewise.
2354 (arm_process_displaced_insn): Likewise.
2355 (arm_displaced_init_closure): Likewise.
2356 (arm_displaced_step_fixup): Add cast for closure.
2357 * arm-tdep.h: Include infrun.h.
2358 (displaced_step_closure): Rename to ...
2359 (arm_displaced_step_closure): ... this, extend
2360 displaced_step_closure.
2361 <u::svc::copy_svc_os>: Change type of parameter DSC.
2362 <cleanup>: Likewise.
2363 (arm_process_displaced_insn): Likewise.
2364 (arm_displaced_init_closure): Likewise.
2365 (displaced_read_reg): Likewise.
2366 (displaced_write_reg): Likewise.
2367 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2368 Adjust.
2369 * i386-tdep.h: Include infrun.h.
2370 (i386_displaced_step_closure): New typedef.
2371 * i386-tdep.c (i386_displaced_step_copy_insn): Use
2372 i386_displaced_step_closure.
2373 (i386_displaced_step_fixup): Adjust.
2374 * rs6000-tdep.c (ppc_displaced_step_closure): New typedef.
2375 (ppc_displaced_step_copy_insn): Use ppc_displaced_step_closure
2376 and unique_ptr.
2377 (ppc_displaced_step_fixup): Adjust.
2378 * s390-linux-tdep.c (s390_displaced_step_closure): New typedef.
2379 (s390_displaced_step_copy_insn): Use s390_displaced_step_closure
2380 and unique_ptr.
2381 (s390_displaced_step_fixup): Adjust.
2382
b392b304
SM
23832017-10-21 Simon Marchi <simon.marchi@polymtl.ca>
2384
2385 * interps.h (interp_resume, interp_suspend, interp_set_temp):
2386 Remove declarations.
2387
d5833c62
TT
23882017-10-20 Tom Tromey <tom@tromey.com>
2389
2390 * gdb_bfd.c (struct gdb_bfd_data) <included_bfds>: Now a
2391 std::vector.
2392 (gdb_bfd_record_inclusion): Update.
2393 (bfdp): Remove typedef.
2394
06d5bbc8
TT
23952017-10-20 Tom Tromey <tom@tromey.com>
2396
2397 * gdb_bfd.c (gdb_bfd_ref): Use new.
2398 (struct gdb_bfd_data): Add constructor, destructor, and member
2399 initializers.
2400 (gdb_bfd_unref): Use delete.
2401
2712ce2e
TT
24022017-10-20 Tom Tromey <tom@tromey.com>
2403
2404 * exec.c (exec_file_attach): Use new_bfd_ref.
2405 * symfile-mem.c (symbol_file_add_from_memory): Use new_bfd_ref.
2406 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
2407 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_fdopenr): Use
2408 new_bfd_ref.
2409 * gdb_bfd.h (new_bfd_ref): New function.
2410
fcc8fb2f
PA
24112017-10-20 Pedro Alves <palves@redhat.com>
2412
2413 * main.c (captured_command_loop): Add attribute noinline.
2414
4c2287b0
SM
24152017-10-19 Simon Marchi <simon.marchi@ericsson.com>
2416
2417 * interps.c (struct interp_factory): Add constructor.
2418 (interp_factory_p): Remove typedef.
2419 (DEF_VEC_P(interp_factory_p)): Remove.
2420 (interpreter_factories): Change type to std::vector.
2421 (interp_factory_register): Adjust.
2422 (interp_lookup): Adjust.
2423 (interpreter_completer): Adjust.
2424
3d415c26
TT
24252017-10-19 Tom Tromey <tom@tromey.com>
2426
2427 * break-catch-syscall.c (catch_syscall_completer): Use
2428 std::string, gdb::unique_xmalloc_ptr.
2429
395423c4
TT
24302017-10-19 Tom Tromey <tom@tromey.com>
2431
2432 * infcall.c (call_function_by_hand_dummy): Use std::string.
2433
54f70bc1
TT
24342017-10-19 Tom Tromey <tom@tromey.com>
2435
2436 * mi/mi-main.c (mi_cmd_execute): Update.
2437 * top.h (prepare_execute_command): Return scoped_value_mark.
2438 * value.h (class scoped_value_mark): Use DISABLE_COPY_AND_ASSIGN.
2439 Add move constructor.
2440 * top.c (prepare_execute_command): Return scoped_value_mark.
2441 (execute_command): Update.
2442
63929e84
PA
24432017-10-19 Pedro Alves <palves@redhat.com>
2444
2445 * xml-support.c (xml_fetch_content_from_file): Check fread's
2446 return.
2447
a75868f5
PA
24482017-10-19 Pedro Alves <palves@redhat.com>
2449
2450 * ser-base.c (ser_base_read_error_fd): Delete the file handler if
2451 async.
2452 (handle_error_fd): New function.
2453 (ser_base_async): Add/delete an event loop file handler for
2454 error_fd.
2455
2edf834e
PA
24562017-10-19 Pedro Alves <palves@redhat.com>
2457
2458 * xml-support.c (xml_fetch_content_from_file): Don't read in
2459 chunks. Instead use fseek to determine the file's size, and read
2460 it in one go.
2461
c8ba13ad
KS
24622017-11-18 Keith Seitz <keiths@redhat.com>
2463
2464 * c-exp.y (oper): Canonicalize conversion operators of user-defined
2465 types.
2466 Add whitespace to front of type name.
2467
37534686
KS
24682017-10-18 Keith Seitz <keiths@redhat.com>
2469
2470 * dwarf2read.c (dwarf2_add_typedef): Issue a complaint on unhandled
2471 DW_AT_accessibility.
2472
28c7c158
YQ
24732017-10-18 Yao Qi <yao.qi@linaro.org>
2474
2475 * features/tic6x-c62x-linux.c: Remove.
2476
30f0b101
TT
24772017-10-17 Tom Tromey <tom@tromey.com>
2478
2479 * disasm.c (do_mixed_source_and_assembly_deprecated): Use
2480 gdb::optional, ui_out_emit_list, ui_out_emit_tuple.
2481 (do_mixed_source_and_assembly): Likewise.
2482
57e12da9
TT
24832017-10-17 Tom Tromey <tom@tromey.com>
2484
2485 * regcache.c (regcache::xfer_part): Remove assertion.
2486
7b700999
PA
24872017-10-17 Pedro Alves <palves@redhat.com>
2488
2489 * xml-support.c (xml_fetch_content_from_file): Call
2490 unique_ptr::release() instead unique_ptr::get() when passing
2491 through xrealloc.
2492
d3037ba6
YQ
24932017-10-17 Yao Qi <yao.qi@linaro.org>
2494
2495 * regcache.c (regcache::xfer_part): Remove parameters read and
2496 write, add parameter is_raw. All callers are updated.
2497
83d5a34d
KS
24982017-10-16 Keith Seitz <keiths@redhat.com>
2499
2500 * c-typeprint.c (enum access_specifier): Moved here from
2501 c_type_print_base.
2502 (output_access_specifier): New function.
2503 (c_type_print_base): Consider typedefs when assessing
2504 whether access labels are needed.
2505 Use output_access_specifier as needed.
2506 Output access specifier for typedefs, if needed.
2507 * dwarf2read.c (dwarf2_add_typedef): Record DW_AT_accessibility.
2508 * gdbtypes.h (struct typedef_field) <is_protected, is_private>: New
2509 fields.
2510 (TYPE_TYPEDEF_FIELD_PROTECTED, TYPE_TYPEDEF_FIELD_PRIVATE): New
2511 accessor macros.
2512
87028b87
TT
25132017-10-16 Tom Tromey <tom@tromey.com>
2514
2515 * linux-tdep.c (linux_info_proc, linux_find_memory_regions_full)
2516 (linux_fill_prpsinfo, linux_vsyscall_range_raw): Update.
2517 * target.c (target_fileio_read_stralloc): Update.
2518 * sparc64-tdep.c (adi_is_addr_mapped): Update.
2519 * target.h (target_fileio_read_stralloc): Return
2520 unique_xmalloc_ptr.
2521
b7b030ad
TT
25222017-10-16 Tom Tromey <tom@tromey.com>
2523
2524 * xml-syscall.c (xml_init_syscalls_info): Update.
2525 * xml-support.c (xinclude_start_include): Update.
2526 (xml_fetch_content_from_file): Return unique_xmalloc_ptr.
2527 * xml-support.h (xml_fetch_another): Return unique_xmalloc_ptr.
2528 (xml_fetch_content_from_file): Likewise.
2529 * osdata.c (get_osdata): Update.
2530 * target.h (target_read_stralloc, target_get_osdata): Return
2531 unique_xmalloc_ptr.
2532 * solib-aix.c (solib_aix_get_library_list): Update.
2533 * solib-target.c (solib_target_current_sos): Update.
2534 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Update.
2535 * xml-tdesc.c (fetch_available_features_from_target): Update.
2536 (target_fetch_description_xml): Update.
2537 (file_read_description_xml): Update.
2538 * remote.c (remote_get_threads_with_qxfer, remote_memory_map)
2539 (remote_traceframe_info, btrace_read_config, remote_read_btrace)
2540 (remote_pid_to_exec_file): Update.
2541 * target.c (target_read_stralloc): Return unique_xmalloc_ptr.
2542 (target_get_osdata): Likewise.
2543
b80406ac
TT
25442017-10-16 Tom Tromey <tom@tromey.com>
2545
2546 * remote.c (remote_register_number_and_offset): Use std::vector.
2547 (remote_set_syscall_catchpoint): Use gdb::unique_xmalloc_ptr.
2548 (putpkt_binary): Use gdb::def_vector.
2549 (compare_sections_command): Use gdb::byte_vector.
2550
a90ecff8
TT
25512017-10-16 Tom Tromey <tom@tromey.com>
2552
2553 * ppc-linux-nat.c (hwdebug_insert_point): Use
2554 gdb::unique_xmalloc_ptr, XDUP.
2555
2dc0e219
TT
25562017-10-16 Tom Tromey <tom@tromey.com>
2557
2558 * probe.c (parse_probes): Use std::string.
2559 (info_probes_for_ops, enable_probes_command)
2560 (disable_probes_command): Remove cleanups.
2561
b05628f0
TT
25622017-10-16 Tom Tromey <tom@tromey.com>
2563
2564 * buildsym.c (block_compar): Remove.
2565 (end_symtab_get_static_block): Use std::vector.
2566
a79b1bc6
SM
25672017-10-16 Simon Marchi <simon.marchi@ericsson.com>
2568
2569 * memrange.h (struct mem_range): Define operator< and operator==.
2570 (mem_range_s): Remove.
2571 (DEF_VEC_O (mem_range_s)): Remove.
2572 (normalize_mem_ranges): Change parameter type to std::vector.
2573 * memrange.c (compare_mem_ranges): Remove.
2574 (normalize_mem_ranges): Change parameter type to std::vector,
2575 adjust to vector change.
2576 * exec.c (section_table_available_memory): Return vector, remove
2577 parameter.
2578 (section_table_read_available_memory): Adjust to std::vector
2579 change.
2580 * remote.c (remote_read_bytes): Adjust to std::vector
2581 change.
2582 * tracepoint.h (traceframe_available_memory): Change parameter
2583 type to std::vector.
2584 * tracepoint.c (traceframe_available_memory): Change parameter
2585 type to std::vector, adjust.
2586 * gdb/mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to
2587 std::vector change.
2588 * gdb/Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
2589 unittests/memrange-selftests.c.
2590 (SUBDIR_UNITTESTS_OBS): Add memrange-selftests.o.
2591 * gdb/unittests/memrange-selftests.c: New file.
2592
63f0e930
PA
25932017-10-16 Pedro Alves <palves@redhat.com>
2594
2595 * elfread.c (probe_key_free): Rename range-for variable.
2596 * probe.c (parse_probes_in_pspace, find_probes_in_objfile)
2597 (find_probe_by_pc, collect_probes): Rename range-for variable.
2598
c40c7bfc
YQ
25992017-10-16 Yao Qi <yao.qi@linaro.org>
2600
2601 * features/Makefile (XMLTOC): Remove tic6x-*.xml.
2602 * features/tic6x-c62x.c: Remove.
2603 * features/tic6x-c64x-linux.c: Remove.
2604 * features/tic6x-c64x.c: Remove.
2605 * features/tic6x-c64xp-linux.c: Remove.
2606 * features/tic6x-c64xp.c: Remove.
2607 * tic6x-linux-tdep.c (_initialize_tic6x_linux_tdep): Don't call
2608 initialize_tdesc_tic6x_*_linux functions.
2609 * tic6x-tdep.c (_initialize_tic6x_tdep): Don't call
2610 initialize_tdesc_tic6x_* functions.
2611
df27ae6a
YQ
26122017-10-16 Yao Qi <yao.qi@linaro.org>
2613
2614 * features/Makefile (WHICH): Remove tic6x-c64xp, tic6x-c64x
2615 tic6x-c62x.
2616 * regformats/tic6x-c62x.dat: Remove.
2617 * regformats/tic6x-c64x.dat: Remove.
2618 * regformats/tic6x-c64xp.dat: Remove.
2619
86766165
SM
26202017-10-15 Simon Marchi <simon.marchi@ericsson.com>
2621
2622 * tracepoint.c (parse_traceframe_info): Return a unique_ptr
2623 (the !HAVE_LIBEXPAT version).
2624
824dfcc3
SM
26252017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2626
2627 * nat/linux-osdata.c (struct pid_pgid_entry) <operator<>: Make
2628 const.
2629
2098b393
SM
26302017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2631
2632 * target.h: Include tracepoint.h.
2633 (enum trace_find_type): Move to tracepoint.h.
2634 (struct target_ops) <to_traceframe_info>: Return a unique ptr.
2635 * tracepoint.h: Don't include target.h
2636 (enum trace_find_type): Move from target.h.
2637 (parse_traceframe_info): Return a unique ptr.
2638 * tracepoint.c (current_traceframe_info): Change type to unique
2639 ptr.
2640 (free_traceframe_info): Remove.
2641 (clear_traceframe_info): Don't manually free
2642 current_traceframe_info.
2643 (free_result): Remove.
2644 (parse_traceframe_info): Return a unique ptr.
2645 (get_traceframe_info): Adjust to unique ptr.
2646 * ctf.c (ctf_traceframe_info): Return a unique ptr.
2647 * remote.c (remote_traceframe_info): Return a unique ptr.
2648 * tracefile-tfile.c (tfile_traceframe_info): Return a unique
2649 ptr.
2650 * target-debug.h (target_debug_print_traceframe_info_up): New
2651 macro.
2652 * target-delegates.c: Regenerate.
2653
4cdd21a8
SM
26542017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2655
2656 * memrange.h (struct mem_range): Add constructors.
2657 * tracepoint.h (struct traceframe_info) <memory>: Change type to
2658 std::vector<mem_range>.
2659 * tracepoint.c (free_traceframe_info): Don't manually free
2660 vector.
2661 (traceframe_info_start_memory): Adjust to vector change.
2662 (traceframe_available_memory): Likewise.
2663 * tracefile-tfile.c (build_traceframe_info): Likewise.
2664 * ctf.c (ctf_traceframe_info): Likewise.
2665
d0d292a2
SM
26662017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2667
2668 * tracepoint.h (struct traceframe_info) <tvars>: Change type to
2669 std::vector<int>.
2670 * tracepoint.c (free_traceframe_info): Deallocate with delete.
2671 (traceframe_info_start_tvar): Adjust to vector change.
2672 (parse_traceframe_info): Allocate with new.
2673 * ctf.c (ctf_traceframe_info): Allocate with new, adjust to
2674 vector change.
2675 * tracefile-tfile.c (build_traceframe_info): Adjust to vector
2676 change.
2677 tfile_traceframe_info): Allocate with new.
2678 * mi/mi-main.c (mi_cmd_trace_frame_collected): Adjust to vector
2679 change.
2680
8d3c73ef
SM
26812017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2682
2683 * tracepoint.c (traceframe_info): Rename to...
2684 (current_traceframe_info): ...this.
2685 (clear_traceframe_info): Adjust.
2686 (get_traceframe_info): Adjust.
2687
b129dcac
SM
26882017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2689
2690 * nat/linux-osdata.c: Include algorithm.
2691 (compare_processes): Remove.
2692 (struct pid_pgid_entry): New struct.
2693 (linux_xfer_osdata_processgroups): Use std::vector instead of
2694 XNEWVEC.
2695
af5bf4ad
SM
26962017-10-14 Simon Marchi <simon.marchi@ericsson.com>
2697
2698 * objfiles.h: Don't include symfile.h.
2699 (struct partial_symbol): Remove forward-declaration.
2700 (struct objfile) <global_psymbols, static_psymbols>: Change type
2701 to std::vector<partial_symbol *>.
2702 * objfiles.c (objfile::objfile): Don't memset those fields.
2703 (objfile::~objfile): Don't free those fields.
2704 * psympriv.h (struct psymbol_allocation_list): Remove
2705 forward-declaration.
2706 (add_psymbol_to_list): Change psymbol_allocation_list parameter
2707 to std::vector.
2708 (start_psymtab_common): Change parameters to std::vector.
2709 * psymtab.c: Include algorithm.
2710 (require_partial_symbols): Call shrink_to_fit.
2711 (find_pc_sect_psymbol): Adjust to vector change.
2712 (match_partial_symbol): Likewise.
2713 (lookup_partial_symbol): Likewise.
2714 (psym_relocate): Likewise.
2715 (dump_psymtab): Likewise.
2716 (recursively_search_psymtabs): Likewise.
2717 (compare_psymbols): Remove.
2718 (sort_pst_symbols): Adjust to vector change.
2719 (start_psymtab_common): Likewise.
2720 (end_psymtab_common): Likewise.
2721 (psymbol_bcache_full): De-constify return value.
2722 (add_psymbol_to_bcache): Likewise.
2723 (extend_psymbol_list): Remove.
2724 (append_psymbol_to_list): Adjust to vector change.
2725 (add_psymbol_to_list): Likewise.
2726 (init_psymbol_list): Likewise.
2727 (maintenance_info_psymtabs): Likewise.
2728 (maintenance_check_psymtabs): Likewise.
2729 * symfile.h (struct psymbol_allocation_list): Remove.
2730 * symfile.c (reread_symbols): Adjust to vector change.
2731 * dbxread.c (start_psymtab): Change type of parameters.
2732 (dbx_symfile_read): Adjust to vector change.
2733 (read_dbx_symtab): Likewise.
2734 (start_psymtab): Change type of parameters.
2735 * dwarf2read.c (dwarf2_build_psymtabs): Adjust to vector change.
2736 (create_partial_symtab): Likewise.
2737 (add_partial_symbol): Likewise.
2738 (write_one_signatured_type): Likewise.
2739 (recursively_write_psymbols): Likewise.
2740 * mdebugread.c (parse_partial_symbols): Likewise.
2741 * xcoffread.c (xcoff_start_psymtab): Change type of parameters.
2742 (scan_xcoff_symtab): Adjust to vector change.
2743 (xcoff_initial_scan): Likewise.
2744
3ec5942f
SM
27452017-10-13 Simon Marchi <simon.marchi@ericsson.com>
2746
2747 * ada-typeprint.c (print_dynamic_range_bound): Use std::string.
2748
2399fe6a
YQ
27492017-10-13 Yao Qi <yao.qi@linaro.org>
2750
2751 * features/Makefile: Remove tic6x-*-expedite, add tic6x-expedite.
2752 Remove s390x-*-expedite, add s390x-expedite.
2753
4bf3f4a8
YQ
27542017-10-13 Yao Qi <yao.qi@linaro.org>
2755
2756 * features/s390-gs-linux64.c: Regenerated.
2757 * features/s390x-gs-linux64.c: Regenerated.
2758
9e86da07
TT
27592017-10-13 Tom Tromey <tom@tromey.com>
2760
2761 * compile/compile-object-run.c (do_module_cleanup): Use delete.
2762 * solib.c (update_solib_list, reload_shared_libraries_1): Use
2763 delete.
2764 * symfile.c (symbol_file_add_with_addrs): Use new.
2765 (symbol_file_add_separate): Update comment.
2766 (syms_from_objfile_1, remove_symbol_file_command): Use delete.
2767 * jit.c (jit_object_close_impl): Use new.
2768 (jit_unregister_code): Use delete.
2769 * objfiles.c (objfile::objfile): Rename from allocate_objfile.
2770 (~objfile): Rename from free_objfile.
2771 (free_objfile_separate_debug, do_free_objfile_cleanup)
2772 (free_all_objfiles, objfile_purge_solibs): Use delete.
2773 * objfiles.h (struct objfile): Add constructor and destructor.
2774 Use DISABLE_COPY_AND_ASSIGN. Add initializers to data members.
2775 (allocate_objfile, free_objfile): Don't declare.
2776 (struct objstats): Add initializers.
2777
c2508e90
SM
27782017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2779
2780 * arch-utils.h (simple_displaced_step_copy_insn): Remove.
2781 * arch-utils.c (simple_displaced_step_copy_insn): Remove.
2782 * gdbarch.sh (displaced_step_copy_insn): Adjust comment.
2783 * gdbarch.h: Regenerate.
2784 * i386-linux-tdep.c (i386_linux_displaced_step_copy_insn):
2785 Adjust comment.
2786 * i386-tdep.c (i386_displaced_step_copy_insn): Adjust comment.
2787 (i386_displaced_step_fixup): Adjust comment.
2788 * rs6000-tdep.c (ppc_displaced_step_copy_insn): Adjust comment.
2789
a900ff72
TT
27902017-10-12 Tom Tromey <tom@tromey.com>
2791
2792 * prologue-value.h (pv_area::store_would_trash): Return bool.
2793 (pv_area::find_reg): Likewise.
2794 * prologue-value.c (pv_area::store_would_trash): Return bool.
2795 (pv_area::find_reg): Likewise.
2796
f7b7ed97
TT
27972017-10-12 Tom Tromey <tom@tromey.com>
2798
2799 * s390-linux-tdep.c (s390_store, s390_load)
2800 (s390_check_for_saved, s390_analyze_prologue): Update.
2801 * rx-tdep.c (check_for_saved, rx_analyze_prologue): Update.
2802 * rl78-tdep.c (rl78_analyze_prologue, check_for_saved): Update.
2803 * prologue-value.h (class pv_area): Move from prologue-value.c.
2804 Change names of members. Add constructor, destructor, member
2805 functions.
2806 (make_pv_area, free_pv_area, make_cleanup_free_pv_area)
2807 (pv_area_store, pv_area_fetch, pv_area_store_would_trash)
2808 (pv_area_fetch, pv_area_scan): Don't declare.
2809 * prologue-value.c (struct pv_area::area_entry): Now member of
2810 pv_area.
2811 (struct pv_area): Move to prologue-value.h.
2812 (pv_area::pv_area): Rename from make_pv_area.
2813 (pv_area::~pv_area): Rename from free_pv_area.
2814 (do_free_pv_area_cleanup, make_cleanup_free_pv_area): Remove.
2815 (clear_entries, find_entry, overlaps, store_would_trash, store)
2816 (fetch, find_reg, scan): Now member of pv_area.
2817 Remove "area" argument. Update.
2818 * msp430-tdep.c (check_for_saved, msp430_analyze_prologue):
2819 Update.
2820 * mn10300-tdep.c (push_reg, check_for_saved)
2821 (mn10300_analyze_prologue): Update.
2822 * mep-tdep.c (is_arg_spill, check_for_saved)
2823 (mep_analyze_prologue): Update.
2824 * m32c-tdep.c (m32c_pv_push, m32c_srcdest_fetch)
2825 (m32c_srcdest_store, m32c_pv_enter, m32c_is_arg_spill)
2826 (m32c_is_struct_return, m32c_analyze_prologue): Update.
2827 * arm-tdep.c (thumb_analyze_prologue, arm_analyze_prologue):
2828 Update.
2829 * arc-tdep.c (arc_is_in_prologue, arc_analyze_prologue): Update.
2830 * aarch64-tdep.c (aarch64_analyze_prologue): Update.
2831
466eecee
SM
28322017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2833
2834 * linux-nat.h (linux_nat_set_delete_thread): New declaration.
2835 * linux-nat.c (linux_nat_delete_thread): New variable.
2836 (lwp_free): Invoke linux_nat_delete_thread if set.
2837 (linux_nat_set_delete_thread): New function.
2838 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Assign
2839 thread delete callback.
2840 * arm-linux-nat.c (arm_linux_delete_thread): New function.
2841 (_initialize_arm_linux_nat): Assign thread delete callback.
2842 * s390-linux-nat.c (s390_delete_thread): New function.
2843 (_initialize_s390_nat): Assign thread delete callback.
2844 * x86-linux-nat.c (x86_linux_add_target): Likewise.
2845 * nat/aarch64-linux.c (aarch64_linux_delete_thread): New
2846 function.
2847 * nat/aarch64-linux.h (aarch64_linux_delete_thread): New
2848 declaration.
2849 * nat/x86-linux.c (x86_linux_delete_thread): New function.
2850 * nat/x86-linux.h (x86_linux_delete_thread): New declaration.
2851
f71c8822
TT
28522017-10-09 Tom Tromey <tom@tromey.com>
2853
2854 * tui/tui-win.c (tui_set_win_height, parse_scrolling_args): Use
2855 std::string.
2856 * tui/tui-layout.c (enum tui_status): Use std::string.
2857
981a3fb3
TT
28582017-10-11 Tom Tromey <tom@tromey.com>
2859
2860 * gdbthread.h (thread_command): Constify.
2861 * inferior.h (detach_command): Constify.
2862 * top.h (set_history, show_history): Constify.
2863 * arm-tdep.c (set_arm_command, show_arm_command): Constify.
2864 * serial.c (serial_set_cmd, serial_show_cmd): Constify.
2865 * bsd-kvm.c (bsd_kvm_cmd): Constify.
2866 * printcmd.c (set_command): Constify.
2867 (non_const_set_command): New function.
2868 * dcache.c (set_dcache_command, show_dcache_command): Constify.
2869 * breakpoint.c (enable_command, disable_command, delete_command)
2870 (catch_command, tcatch_command, set_breakpoint_cmd)
2871 (show_breakpoint_cmd): Constify.
2872 * macrocmd.c (macro_command): Constify.
2873 * infcmd.c (unset_command, kill_command, detach_command)
2874 (info_proc_cmd): Constify.
2875 * i386-tdep.c (set_mpx_cmd, show_mpx_cmd): Constify.
2876 * auto-load.c (show_auto_load_cmd, set_auto_load_cmd)
2877 (info_auto_load_cmd): Constify.
2878 * target-descriptions.c (set_tdesc_cmd, show_tdesc_cmd)
2879 (unset_tdesc_cmd): Constify.
2880 * ada-lang.c (set_ada_command, show_ada_command)
2881 (maint_set_ada_cmd, maint_show_ada_cmd): Constify.
2882 * guile/guile.c (set_guile_command, show_guile_command)
2883 (info_guile_command): Constify.
2884 * tui/tui-win.c (tui_command, set_tui_cmd, show_tui_cmd):
2885 Constify.
2886 * skip.c (skip_command): Constify.
2887 * compile/compile.c (_initialize_compile): Constify.
2888 * dwarf2read.c (set_dwarf_cmd, show_dwarf_cmd): Constify.
2889 * btrace.c (maint_btrace_cmd, maint_btrace_set_cmd)
2890 (maint_btrace_show_cmd, maint_btrace_pt_set_cmd)
2891 (maint_btrace_pt_show_cmd): Constify.
2892 * remote.c (set_remote_cmd, show_remote_cmd, remote_command):
2893 Constify.
2894 * python/python.c (user_show_python, user_set_python): Constify.
2895 * mips-tdep.c (set_mips_command, show_mips_command)
2896 (set_mipsfpu_command): Constify.
2897 * record-btrace.c (cmd_record_btrace_start)
2898 (cmd_set_record_btrace, cmd_show_record_btrace)
2899 (cmd_set_record_btrace_bts, cmd_show_record_btrace_bts)
2900 (cmd_set_record_btrace_pt, cmd_show_record_btrace_pt): Constify.
2901 * rs6000-tdep.c (set_powerpc_command, show_powerpc_command):
2902 Constify.
2903 * symfile.c (overlay_command): Constify.
2904 * spu-tdep.c (set_spu_command, show_spu_command): Constify.
2905 * cli/cli-logging.c (set_logging_command, show_logging_command):
2906 Constify.
2907 * cli/cli-dump.c (dump_command, append_command)
2908 (srec_dump_command, ihex_dump_command, verilog_dump_command)
2909 (tekhex_dump_command, binary_dump_command)
2910 (binary_append_command): Constify.
2911 * cli/cli-decode.c (struct cmd_list_element): Change type of
2912 "fun".
2913 * cli/cli-cmds.c (info_command, show_command, set_debug)
2914 (show_debug): Constify.
2915 (show_command): Add non-const overload.
2916 * top.c (set_history, show_history): Constify.
2917 * sh-tdep.c (set_sh_command, show_sh_command): Constify.
2918 * command.h (add_prefix_cmd): Accept a cmd_const_cfunc_ftype.
2919 * target.c (target_command): Constify.
2920 * sparc64-tdep.c (info_adi_command): Constify.
2921 * record-full.c (cmd_record_full_start): Constify.
2922 (set_record_full_command): Constify. Fix typo.
2923 (show_record_full_command): Constify.
2924 * thread.c (thread_command, thread_apply_command): Constify.
2925 * memattr.c (dummy_cmd): Constify.
2926 * value.c (function_command): Constify.
2927 * frame.c (set_backtrace_cmd, show_backtrace_cmd): Constify.
2928 * probe.c (info_probes_command): Constify.
2929 * ser-tcp.c (set_tcp_cmd, show_tcp_cmd): Constify.
2930 * gnu-nat.c (set_task_cmd, show_task_cmd, set_thread_cmd)
2931 (show_thread_cmd, set_thread_default_cmd)
2932 (show_thread_default_cmd): Constify.
2933 (check_empty): Constify.
2934 * tracepoint.c (tfind_command): Constify.
2935 * cp-support.c (maint_cplus_command): Constify.
2936 * windows-tdep.c (info_w32_command): Constify.
2937 * record.c (cmd_record_start, set_record_command)
2938 (show_record_command, info_record_command, cmd_record_goto):
2939 Constify.
2940 * ravenscar-thread.c (set_ravenscar_command)
2941 (show_ravenscar_command): Constify.
2942 * utils.c (set_internal_problem_cmd, show_internal_problem_cmd):
2943 Constify.
2944 (add_internal_problem_command): Remove casts.
2945 * arc-tdep.c (maintenance_print_arc_command): Constify.
2946 * valprint.c (set_print, show_print, set_print_raw)
2947 (show_print_raw): Constify.
2948 * maint.c (maintenance_command, maintenance_info_command)
2949 (maintenance_print_command, maintenance_set_cmd)
2950 (maintenance_show_cmd, set_per_command_cmd)
2951 (show_per_command_cmd, maintenance_check_command): Constify.
2952 * language.c (set_check, show_check): Constify.
2953 * typeprint.c (show_print_type, set_print_type): Constify.
2954 * go32-nat.c (go32_info_dos_command): Constify.
2955
fdf44873
TT
29562017-10-11 Tom Tromey <tom@tromey.com>
2957
2958 * breakpoint.c (prepare_re_set_context): Remove.
2959 (breakpoint_re_set_one): Update. Don't use cleanups.
2960 (breakpoint_re_set): Use scoped_restore, std::string, and
2961 scoped_restore_current_language.
2962
81b1e71c
TT
29632017-10-11 Tom Tromey <tom@tromey.com>
2964
2965 * breakpoint.c (commands_command_1): Use std::string.
2966 (cleanup_executing_breakpoints): Remove.
2967 (bpstat_do_actions_1): Use scoped_restore.
2968 (bpstat_check_watchpoint): Use std::string.
2969 (decode_static_tracepoint_spec): Likewise.
2970 (break_range_command): Likewise.
2971 (watch_command_1): Likewise.
2972 (compare_breakpoints): Change argument types.
2973 (clear_command): Use std::vector.
2974 (cleanup_executing_breakpoints): Remove.
2975 (update_global_location_list): Use unique_xmalloc_ptr.
2976 (strace_command): Remove unused declaration.
2977
4f9d9906
JB
29782017-10-11 John Baldwin <jhb@FreeBSD.org>
2979
2980 * Makefile.in (ALLDEPFILES): Add arm-fbsd-nat.c.
2981 * NEWS: Mention new FreeBSD/arm native configuration.
2982 * configure.host: Add arm*-*-freebsd*.
2983 * configure.nat: Likewise.
2984 * arm-fbsd-nat.c: New file.
2985
7176dfd2
JB
29862017-10-11 John Baldwin <jhb@FreeBSD.org>
2987
2988 * Makefile.in (ALL_TARGET_OBS): Add arm-fbsd-tdep.o.
2989 (ALLDEPFILES): Add arm-fbsd-tdep.c.
2990 * NEWS: Mention new FreeBSD/arm target.
2991 * configure.tgt: Add arm*-*-freebsd*.
2992 * arm-fbsd-tdep.c: New file.
2993 * arm-fbsd-tdep.h: New file.
2994
fe220226
MR
29952017-10-11 Maciej W. Rozycki <macro@imgtec.com>
2996
2997 * linux-tdep.c (linux_make_corefile_notes): Remove call to
2998 `gdbarch_elfcore_write_linux_prpsinfo'.
2999 * gdbarch.sh (elfcore_write_linux_prpsinfo): Remove architecture
3000 method.
3001 (elf_internal_linux_prpsinfo): Remove declaration.
3002 * gdbarch.h: Regenerate.
3003 * gdbarch.c: Regenerate.
3004
a2f63b2e
MR
30052017-10-11 Maciej W. Rozycki <macro@imgtec.com>
3006
3007 * ppc-linux-tdep.c (ppc_linux_init_abi): Remove call to
3008 `set_gdbarch_elfcore_write_linux_prpsinfo'.
3009
458ca1d0
PA
30102017-10-11 Pedro Alves <palves@redhat.com>
3011
3012 * breakpoint.c (reattach_breakpoints): Delete.
3013 * breakpoint.h (reattach_breakpoints): Delete.
3014
905014d7
SM
30152017-10-11 Simon Marchi <simon.marchi@ericsson.com>
3016
3017 * symfile.c (registered_sym_fns): Make struct, not typedef.
3018 (DEF_VEC_O (registered_sym_fns)): Remove.
3019 (symtab_fns): Change type to std::vector.
3020 (add_symtab_fns): Adjust.
3021 (find_sym_fns): Adjust.
3022
56d704da
AK
30232017-10-11 Anton Kolesov <Anton.Kolesov@synopsys.com>
3024
3025 * arc-tdep.c (arc_gdbarch_init): Pass proper cpu value to disassembler.
3026 * arc-tdep.h (arc_arch_is_em): New function.
3027 (arc_arch_is_hs): Likewise.
3028
7fa29be9
EB
30292017-10-11 Egeyar Bagcioglu <egeyar.bagcioglu@oracle.com>
3030
3031 * macrotab.h (macro_lookup_inclusion): Remove unnecessary
3032 parentheses in the declaration.
3033 (macro_lookup_inclusion): Likewise.
3034 (macro_lookup_definition): Likewise.
3035 * p-lang.h (pascal_builtin_types): Likewise.
3036 * tui/tui-data.c (tui_win_list): Likewise.
3037 * tui/tui-data.h (tui_win_list): Likewise.
3038 * utils.h (make_cleanup_free_section_addr_info): Likewise.
3039
d9b477e3
KB
30402017-10-11 Mark Rages <markrages@gmail.com>
3041
3042 * target-memory.c (block_boundaries): Fix for block address not
3043 aligned on block size.
3044
65630365
PA
30452017-10-10 Pedro Alves <palves@redhat.com>
3046 Tom Tromey <tom@tromey.com>
3047
3048 * breakpoint.c (struct captured_breakpoint_query_args)
3049 (do_captured_breakpoint_query, gdb_breakpoint_query): Delete.
3050 (print_breakpoint): New.
3051 * breakpoint.h (print_breakpoint): Declare.
3052 * common/common-exceptions.h (enum return_reason): Remove
3053 references to catch_exceptions.
3054 * exceptions.c (catch_exceptions, catch_exceptions_with_msg):
3055 Delete.
3056 * exceptions.h (catch_exceptions_ftype, catch_exceptions)
3057 (catch_exception_ftype, catch_exceptions_with_msg): Delete.
3058 * gdb.h: Delete.
3059 * gdbthread.h (thread_select): Declare.
3060 * mi/mi-cmd-break.c: Don't include gdb.h.
3061 (breakpoint_notify): Use print_breakpoint.
3062 * mi/mi-cmd-catch.c: Don't include gdb.h.
3063 * mi/mi-interp.c: Don't include gdb.h.
3064 (mi_print_breakpoint_for_event): New.
3065 (mi_breakpoint_created, mi_breakpoint_modified): Use
3066 mi_print_breakpoint_for_event.
3067 * mi/mi-main.c: Don't include gdb.h.
3068 (mi_cmd_thread_select): Parse the global thread ID here. Use
3069 thread_select instead of gdb_thread_select.
3070 (mi_cmd_thread_list_ids): Output "thread-ids" tuple here instead
3071 of using gdb_list_thread_ids.
3072 * remote-fileio.c (do_remote_fileio_request): Change type. Reply
3073 FILEIO_ENOSYS here.
3074 (remote_fileio_request): Use TRY/CATCH instead of
3075 catch_exceptions.
3076 * symfile-mem.c (struct symbol_file_add_from_memory_args)
3077 (symbol_file_add_from_memory_wrapper): Delete.
3078 (add_vsyscall_page): Use TRY/CATCH instead of catch_exceptions.
3079 * thread.c: Don't include gdb.h.
3080 (do_captured_list_thread_ids, gdb_list_thread_ids): Delete.
3081 (thread_alive): Use thread_select.
3082 (do_captured_thread_select): Delete, parts salvaged as ...
3083 (thread_select): ... this new function.
3084 (gdb_thread_select): Delete.
3085
bf469271
PA
30862017-10-10 Pedro Alves <palves@redhat.com>
3087 Tom Tromey <tom@tromey.com>
3088
3089 * breakpoint.c (breakpoint_cond_eval): Change return type to bool
3090 and reverse logic.
3091 (WP_DELETED, WP_VALUE_CHANGED, WP_VALUE_NOT_CHANGED, WP_IGNORE):
3092 No longer macros. Instead ...
3093 (enum wp_check_result): They're now values of this new
3094 enumeration.
3095 (watchpoint_check): Change return type to wp_check_result and
3096 parameter type to bpstat.
3097 (bpstat_check_watchpoint): Use TRY/CATCH instead of catch_errors.
3098 (bpstat_check_breakpoint_conditions): Use TRY/CATCH instead of
3099 catch_errors. Reverse logic of watchpoint_check call.
3100 (breakpoint_re_set_one): Now returns void and takes a breakpoint
3101 pointer as parameter.
3102 (breakpoint_re_set): Use TRY/CATCH instead of catch_errors.
3103 * common/common-exceptions.c (throw_exception_sjlj): Update
3104 comments to avoid mentioning catch_errors.
3105 * exceptions.c (catch_errors): Delete.
3106 * exceptions.h: Update comments to avoid mentioning catch_errors.
3107 (catch_errors_ftype, catch_errors): Delete.
3108 * infrun.c (normal_stop): Use TRY/CATCH instead of catch_errors.
3109 (hook_stop_stub): Delete.
3110 (restore_selected_frame): Change return type to void, and
3111 parameter type to const frame_id &.
3112 (restore_infcall_control_state): Use TRY/CATCH instead of
3113 catch_errors.
3114 * main.c (captured_command_loop): Return void and remove
3115 parameter. Remove references to catch_errors.
3116 (captured_main): Use TRY/CATCH instead of catch_errors.
3117 * objc-lang.c (objc_submethod_helper_data)
3118 (find_objc_msgcall_submethod_helper): Delete.
3119 (find_objc_msgcall_submethod): Use TRY/CATCH instead of
3120 catch_errors.
3121 * record-full.c (record_full_message): Return void.
3122 (record_full_message_args, record_full_message_wrapper): Delete.
3123 (record_full_message_wrapper_safe): Return bool and use TRY/CATCH
3124 instead of catch_errors.
3125 * solib-aix.c (solib_aix_open_symbol_file_object): Change
3126 parameter type to int.
3127 * solib-darwin.c (open_symbol_file_object): Ditto.
3128 * solib-dsbt.c (open_symbol_file_object): Ditto.
3129 * solib-frv.c (open_symbol_file_object): Ditto.
3130 * solib-svr4.c (open_symbol_file_object): Ditto.
3131 * solib-target.c (solib_target_open_symbol_file_object): Ditto.
3132 * solib.c (update_solib_list): Use TRY/CATCH instead of
3133 catch_errors.
3134 * solist.h (struct target_so_ops) <open_symbol_file_object>:
3135 Change type.
3136 * symmisc.c (struct print_symbol_args): Remove.
3137 (dump_symtab_1): Use TRY/CATCH instead of catch_errors.
3138 (print_symbol): Change type.
3139 * windows-nat.c (handle_load_dll, handle_unload_dll): Return void
3140 and remove parameters.
3141 (catch_errors): New.
3142 (get_windows_debug_event): Adjust.
3143
1a56bfa5
TT
31442017-10-09 Tom Tromey <tom@tromey.com>
3145
3146 * mi/mi-main.c (free_splay_tree): Remove.
3147 (list_available_thread_groups): Use splay_tree_up.
3148 * common/gdb_splay_tree.h: New file.
3149
0c478e2d
TT
31502017-10-09 Tom Tromey <tom@tromey.com>
3151
3152 * mi/mi-main.c (do_nothing): Remove.
3153 (list_available_thread_groups): Update.
3154
cbd2b4e3
PA
31552017-10-09 Pedro Alves <palves@redhat.com>
3156
3157 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>: Skip
3158 reading registers when switching context.
3159
a181c0bf
JB
31602017-10-09 John Baldwin <jhb@FreeBSD.org>
3161
3162 * fbsd-nat.c (fbsd_siginfo_size): Use gdbarch_long_bit.
3163 (fbsd_convert_siginfo): Likewise.
3164 * fbsd-tdep.c (fbsd_core_xfer_siginfo): Likewise.
3165
6e66f753
SM
31662017-10-09 Simon Marchi <simon.marchi@polymtl.ca>
3167
3168 * configure.ac (try_guile_versions): Remove guile-2.2.
3169 * configure: Regenerate.
3170
890e9790
TT
31712017-10-09 Tom Tromey <tom@tromey.com>
3172
3173 * Makefile.in (COMPILE.post, POSTCOMPILE): Restore $(basename).
3174 (COMPILE.pre): Use $(CXX).
3175
109483d9
PA
31762017-10-09 Pedro Alves <palves@redhat.com>
3177
3178 * cp-support.c (cp_remove_params): Return a gdb::unique_xmalloc_ptr.
3179 Use bool.
3180 (overload_list_add_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3181 * cp-support.h (cp_remove_params): Now returns a
3182 gdb::unique_xmalloc_ptr.
3183 * dwarf2read.c (find_slot_in_mapped_hash): Now returns bool.
3184 Adjust to cp_remove_params returning a gdb::unique_xmalloc_ptr.
3185 * psymtab.c (psymtab_search_name): Adjust to cp_remove_params
3186 returning a gdb::unique_xmalloc_ptr.
3187 (lookup_partial_symbol): Adjust to use gdb::unique_xmalloc_ptr.
3188 * stack.c (find_frame_funname): Adjust to cp_remove_params
3189 returning a gdb::unique_xmalloc_ptr.
3190
791afaa2
TT
31912017-10-08 Tom Tromey <tom@tromey.com>
3192
3193 * dwarf2read.c (dwarf2_get_dwz_file): Use
3194 gdb::unique_xmalloc_ptr.
3195 (find_slot_in_mapped_hash): Likewise.
3196 (dwarf2_physname): Likewise.
3197 (create_dwo_unit_in_dwp_v1): Use std::string.
3198 (create_dwo_unit_in_dwp_v2): Likewise.
3199 (lookup_dwo_cutu): Likewise.
3200 (inherit_abstract_dies): Use std::vector.
3201 (read_array_type): Likewise.
3202 (dwarf_decode_macros): Remove unused declaration.
3203 (unsigned_int_compar): Remove.
3204 (dwarf2_build_psymtabs_hard): Use scoped_restore.
3205 (psymtabs_addrmap_cleanup): Remove.
3206
30a9c02f
TT
32072017-10-08 Tom Tromey <tom@tromey.com>
3208
3209 * frame-unwind.c (frame_unwind_try_unwinder): Update.
3210 * frame.h (frame_cleanup_after_sniffer): Declare.
3211 (frame_prepare_for_sniffer): Return void.
3212 * frame.c (frame_cleanup_after_sniffer): No longer static. Change
3213 type of argument.
3214 (frame_prepare_for_sniffer): Return void.
3215
757325a3
TT
32162017-10-08 Tom Tromey <tom@tromey.com>
3217
3218 * utils.h (make_cleanup_value_free): Remove.
3219 * utils.c (do_value_free, struct cleanup): Remove.
3220 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full) <DWARF_VALUE_STACK>:
3221 Use gdb_value_up.
3222 * value.h (struct value_deleter): New.
3223 (gdb_value_up): New typedef.
3224
b9c04fb2
TT
32252017-10-08 Tom Tromey <tom@tromey.com>
3226
3227 * symtab.c (free_search_symbols, do_free_search_symbols_cleanup)
3228 (make_cleanup_free_search_symbols): Remove.
3229 (search_symbols): Return std::vector.
3230 (symbol_search::compare_search_syms): Now member of
3231 symbol_search. Change arguments.
3232 (sort_search_symbols_remove_dups): Change arguments. Rewrite.
3233 (symtab_symbol_info, rbreak_command): Update.
3234 * symtab.h (struct symbol_search) <next>: Remove.
3235 Add constructors.
3236 (symbol_search::operator<): New function.
3237 (symbol_search::operator==): New function.
3238 (search_symbols): Remove std::vector.
3239 (free_search_symbols, make_cleanup_free_search_symbols): Remove.
3240 (symbol_search::compare_search_syms): Declare.
3241
0d28b0a5
YQ
32422017-10-06 Yao Qi <yao.qi@linaro.org>
3243
3244 * Makefile.in (ALL_64_TARGET_OBS): Replace aarch64-insn.o with
3245 arch/aarch64-insn.o.
3246 Remove one rule.
3247 * configure.tgt: Replace aarch64-insn.o with arch/aarch64-insn.o.
3248
71917808
YQ
32492017-10-06 Yao Qi <yao.qi@linaro.org>
3250
3251 * Makefile.in (ALL_TARGET_OBS): Replace arm.o, arm-get-next-pcs.o,
3252 and arm-linux.o with arch/arm.o, arch/arm-get-next-pcs.o and
3253 arch/arm-linux.o respectively.
3254 * configure.tgt: Likewise.
3255
2081b2b2
YQ
32562017-10-06 Yao Qi <yao.qi@linaro.org>
3257
3258 * Makefile.in (ALL_TARGET_OBS): Rename i386.o to arch/i386.o.
3259 * configure.tgt (i386_tobjs): Replace i386.o with arch/i386.o.
3260
a1b85d28
PA
32612017-10-06 Pedro Alves <palves@redhat.com>
3262
3263 * windows-nat.c: Include <algorithm>.
3264
d97987e2
YQ
32652017-10-06 Yao Qi <yao.qi@linaro.org>
3266
3267 * configure.tgt (i386_tobjs): New variable.
3268 (amd64_tobjs): New variable.
3269 Set $cpu_obs and $os_obs.
3270
f38307f5
YQ
32712017-10-06 Yao Qi <yao.qi@linaro.org>
3272
3273 * Makefile.in (CONFIG_SRC_SUBDIR): New.
3274 (ALL_64_TARGET_OBS): Replace amd64.o with arch/amd64.o.
3275 (clean): Remove object files and dependency files.
3276 (distclean): Remove the directory.
3277 * configure.ac: Invoke AC_CONFIG_COMMANDS.
3278 * configure: Re-generated.
3279 * configure.tgt: Replace amd64.o with arch/amd64.o.
3280
2f924de6
JM
32812017-10-05 Jose E. Marchesi <jose.marchesi@oracle.com>
3282
3283 PR build/22188
3284 * arm-tdep.c (arm_decode_misc_memhint_neon): Fix decoding of CPS
3285 and SETEND.
3286
2fd9d7ca
PA
32872017-10-05 Pedro Alves <palves@redhat.com>
3288
3289 * linux-nat.c (linux_child_follow_fork): When following the parent
3290 and detaching the child, consult the parent thread's architecture
3291 instead of the child's.
3292
d13b8493
UW
32932017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3294
3295 * ax.h: Do not include "doublest.h".
3296 (union agent_val): Remove.
3297
3b4b2f16
UW
32982017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3299
3300 * dfp.h (MAX_DECIMAL_STRING): Move to dfp.c.
3301 (decimal_to_string): Return std::string object.
3302 (decimal_from_string): Accept std::string object. Return bool.
3303 (decimal_from_integral, decimal_from_doublest): Remove.
3304 (decimal_from_longest): Add prototype.
3305 (decimal_from_ulongest): Likewise.
3306 (decimal_to_longest): Likewise.
3307 (decimal_from_doublest): Likewise.
3308 * dfp.c: Do not include "gdbtypes.h" or "value.h".
3309 (MAX_DECIMAL_STRING): Move here.
3310 (decimal_to_string): Return std::string object.
3311 (decimal_from_string): Accept std::string object. Return bool.
3312 (decimal_from_integral): Remove, replace by ...
3313 (decimal_from_longest, decimal_from_ulongest): ... these new functions.
3314 (decimal_to_longest): New function.
3315 (decimal_from_floating): Remove, replace by ...
3316 (decimal_from_doublest): ... this new function.
3317 (decimal_to_doublest): Update to new decimal_to_string interface.
3318
3319 * value.c (unpack_long): Use decimal_to_longest.
3320 * valops.c (value_cast): Use decimal_from_doublest instead of
3321 decimal_from_floating. Use decimal_from_[u]longest isntead of
3322 decimal_from_integral.
3323 * valarith.c (value_args_as_decimal): Likewise.
3324 * valprint.c (print_decimal_floating): Update to new
3325 decimal_to_string interface.
3326 * printcmd.c (printf_decfloat): Likewise.
3327 * c-exp.y (parse_number): Update to new decimal_from_string interface.
3328
1841ee5d
UW
33292017-10-05 Ulrich Weigand <uweigand@de.ibm.com>
3330
3331 * doublest.h: Do not include "floatformat.h". Remove stale comments.
3332 * gdbtypes.c: Include "floatformat.h".
3333 * value.c: Likewise.
3334 * m68k-tdep.c: Likewise.
3335
3336 * findvar.c: Do not include "floatformat.h".
3337 * amd64-darwin-tdep.c: Likewise.
3338 * arm-linux-tdep.c: Likewise.
3339 * i386-darwin-tdep.c: Likewise.
3340 * i387-tdep.c: Likewise.
3341 * m68k-linux-tdep.c: Likewise.
3342 * mep-tdep.c: Likewise.
3343 * mips-tdep.c: Likewise.
3344 * nios2-tdep.c: Likewise.
3345 * s390-linux-tdep.c: Likewise.
3346 * sparc-obsd-tdep.c: Likewise.
3347 * sparc-tdep.c: Likewise.
3348 * sparc64-tdep.c: Likewise.
3349 * spu-tdep.c: Likewise.
3350 * tic6x-tdep.c: Likewise.
3351 * tilegx-tdep.c: Likewise.
3352 * vax-tdep.c: Likewise.
3353 * xstormy16-tdep.c: Likewise.
3354 * xtensa-tdep.c: Likewise.
3355
3356 * top.c: Do not include "doublest.h".
3357 * aarch64-tdep.c: Likewise.
3358 * alpha-tdep.c: Likewise.
3359 * arm-linux-tdep.c: Likewise.
3360 * m68k-linux-tdep.c: Likewise.
3361 * tilegx-tdep.c: Likewise.
3362 * xstormy16-tdep.c: Likewise.
3363
a80a6471
JB
33642017-10-05 John Baldwin <jhb@FreeBSD.org>
3365
3366 * mips-fbsd-tdep.c (MIPS_INST_ADDIU_A0_SP_N32): Define.
3367 (mipsn32_fbsd_sigframe): Define.
3368 (mips_fbsd_init_abi): Install mipsn32_fbsd_sigframe unwinder
3369 for FreeBSD/mipsn32.
3370
12c4bd7f
JB
33712017-10-05 John Baldwin <jhb@FreeBSD.org>
3372
3373 * fbsd-tdep.c (fbsd_print_auxv_entry): Handle AT_EHDRFLAGS and
3374 AT_HWCAP.
3375
c91933e9
TG
33762017-10-05 Tristan Gingold <tgingold@free.fr>
3377
3378 * MAINTAINERS (Misc): Update my email address.
3379
5cd63fda
PA
33802017-10-04 Pedro Alves <palves@redhat.com>
3381
3382 * remote.c (get_remote_arch_state): New 'gdbarch' parameter. Use
3383 it instead of target_gdbarch.
3384 (get_remote_state, get_remote_packet_size): Adjust
3385 get_remote_arch_state calls, passing down target_gdbarch
3386 explicitly.
3387 (packet_reg_from_regnum, packet_reg_from_pnum): New parameter
3388 'gdbarch' and use it instead of target_gdbarch.
3389 (get_memory_packet_size): Adjust get_remote_arch_state calls,
3390 passing down target_gdbarch explicitly.
3391 (struct stop_reply) <arch>: New field.
3392 (remote_parse_stop_reply): Use the stopped thread's architecture,
3393 not the current inferior's. Save the architecture in the
3394 stop_reply.
3395 (process_stop_reply): Use the stop reply's architecture.
3396 (process_g_packet, remote_fetch_registers)
3397 (remote_prepare_to_store, store_registers_using_G)
3398 (remote_store_registers): Adjust get_remote_arch_state calls,
3399 using the regcache's architecture.
3400 (remote_get_trace_status): Adjust get_remote_arch_state calls,
3401 passing down target_gdbarch explicitly.
3402 * spu-multiarch.c (spu_thread_architecture): Defer to the target
3403 beneath instead of calling target_gdbarch.
3404 * target.c (default_thread_architecture): Use the specified
3405 inferior's architecture, instead of the current inferior's
3406 architecture (via target_gdbarch).
3407
ed4227b7
PA
34082017-10-04 Pedro Alves <palves@redhat.com>
3409
3410 * regcache.c (get_thread_arch_regcache): Remove null_ptid special
3411 case.
3412 (regcache_print): Handle !target_has_registers here instead.
3413
55b11ddf
PA
34142017-10-04 Pedro Alves <palves@redhat.com>
3415
3416 * frame.c (create_test_frame): Delete.
3417 * frame.h (create_test_frame): Delete.
3418 * gdbarch-selftests.c: Include gdbthread.h and target.h.
3419 (class regcache_test): Delete.
3420 (test_target_has_registers, test_target_has_stack)
3421 (test_target_has_memory, test_target_prepare_to_store)
3422 (test_target_store_registers): New functions.
3423 (test_target_ops): New class.
3424 (register_to_value_test): Error out if there's already a
3425 process_stratum (or higher) target pushed. Create a fuller mock
3426 environment, with mock target_ops, inferior, address space, thread
3427 and inferior_ptid.
3428 * progspace.c (struct address_space): Move to ...
3429 * progspace.h (struct address_space): ... here.
3430 * regcache.h (regcache::~regcache, regcache::raw_write)
3431 [GDB_SELF_TEST]: No longer virtual.
3432
4c71c105
SM
34332017-10-04 Simon Marchi <simon.marchi@ericsson.com>
3434
3435 * mi/mi-main.c (list_available_thread_groups): Reverse filter logic.
3436
73dcd72d
PA
34372017-10-04 Pedro Alves <palves@redhat.com>
3438
3439 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Move code
3440 out of 'between TRY and CATCH'.
3441
44704526
PA
34422017-10-04 Pedro Alves <palves@redhat.com>
3443
3444 * cli/cli-cmds.c (complete_command): Add missing END_CATCH.
3445 * common/common-exceptions.h (TRY): Open an outermost scope.
3446 Expand intro comment.
3447 (CATCH): Reindent.
3448 (END_CATCH): Close the outermost scope.
3449 * completer.c (complete_line_internal): Add missing END_CATCH.
3450
bc3b087d
SDJ
34512017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3452
3453 * NEWS (Changes since GDB 8.0): Add entry about new
3454 'set-cwd-on-gdbserver' feature.
3455 (New remote packets): Add entry for QSetWorkingDir.
3456 * common/common-inferior.h (set_inferior_cwd): New prototype.
3457 * infcmd.c (set_inferior_cwd): Remove "static".
3458 (show_cwd_command): Expand text to include remote debugging.
3459 * remote.c: Add PACKET_QSetWorkingDir.
3460 (remote_protocol_features) <QSetWorkingDir>: New entry for
3461 PACKET_QSetWorkingDir.
3462 (extended_remote_set_inferior_cwd): New function.
3463 (extended_remote_create_inferior): Call
3464 "extended_remote_set_inferior_cwd".
3465 (_initialize_remote): Call "add_packet_config_cmd" for
3466 QSetWorkingDir.
3467
d092c5a2
SDJ
34682017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3469
3470 * NEWS (New commands): Mention "set/show cwd".
3471 * cli/cli-cmds.c (_initialize_cli_cmds): Mention "set cwd" on
3472 "cd" command's help text.
3473 * common/common-inferior.h (get_inferior_cwd): New prototype.
3474 * infcmd.c (inferior_cwd_scratch): New global variable.
3475 (set_inferior_cwd): New function.
3476 (get_inferior_cwd): Likewise.
3477 (set_cwd_command): Likewise.
3478 (show_cwd_command): Likewise.
3479 (_initialize_infcmd): Add "set/show cwd" commands.
3480 * inferior.h (class inferior) <cwd>: New field.
3481 * nat/fork-inferior.c: Include "gdb_tilde_expand.h".
3482 (fork_inferior): Change inferior's cwd before its execution.
3483 * windows-nat.c (windows_create_inferior): Pass inferior's cwd
3484 to CreateProcess.
3485
7da0a886
SDJ
34862017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
3487
3488 * Makefile.in (SFILES): Add gdb_tilde_expand.c.
3489 (HFILES_NO_SRCDIR): Add gdb_tilde_expand.h.
3490 (COMMON_OBS): Add gdb_tilde_expand.o.
3491 * common/gdb_tilde_expand.c: New file.
3492 * common/gdb_tilde_expand.h: Likewise.
3493
db8dd160
MR
34942017-10-03 Maciej W. Rozycki <macro@imgtec.com>
3495
3496 * gdbarch.sh (objfile): Remove duplicate declaration.
3497 * gdbarch.h: Regenerate.
3498
f8bfbf22
TT
34992017-10-03 Tom Tromey <tom@tromey.com>
3500
3501 * utils.c (internal_vproblem): Use string_vprintf.
3502
5178ed48
TT
35032017-10-03 Tom Tromey <tom@tromey.com>
3504
3505 * printcmd.c (info_symbol_command): Use std::string.
3506
8cff8730
TT
35072017-10-03 Tom Tromey <tom@tromey.com>
3508
3509 * top.c (gdb_safe_append_history): Use std::string.
3510
895b8f30
TT
35112017-10-03 Tom Tromey <tom@tromey.com>
3512
3513 * event-top.c (stdin_event_handler): Update.
3514 * main.c (captured_main_1): Update.
3515 * top.h (make_delete_ui_cleanup): Remove.
3516 (struct ui): Add constructor and destructor.
3517 (new_ui, delete_ui): Remove.
3518 * top.c (make_delete_ui_cleanup): Remove.
3519 (new_ui_command): Use std::unique_ptr.
3520 (delete_ui_cleanup): Remove.
3521 (ui::ui): Rename from new_ui. Update.
3522 (free_ui): Remove.
3523 (ui::~ui): Rename from delete_ui. Update.
3524
0efef640
TT
35252017-10-03 Tom Tromey <tom@tromey.com>
3526
3527 * symfile.c (load_progress): Use gdb::byte_vector.
3528
245ad7d3
TT
35292017-10-03 Tom Tromey <tom@tromey.com>
3530
3531 * mi/mi-main.c (mi_cmd_trace_frame_collected): Remove unused
3532 declaration.
3533 * printcmd.c (x_command): Remove unused declaration.
3534 * symfile.c (symbol_file_command): Remove unused declaration.
3535
e05550d7
TT
35362017-10-03 Tom Tromey <tom@tromey.com>
3537
3538 * utils.c (internal_vproblem): Use std::string.
3539 (defaulted_query): Likewise.
3540
b95de2b7
TT
35412017-10-03 Tom Tromey <tom@tromey.com>
3542
3543 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Update.
3544 * top.c (execute_command_to_string): Update.
3545 * utils.c (make_cleanup_restore_page_info): Remove.
3546 (do_restore_page_info_cleanup): Remove.
3547 (set_batch_flag_and_restore_page_info):
3548 New.
3549 (make_cleanup_restore_page_info): Remove.
3550 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3551 (~set_batch_flag_and_restore_page_info): New
3552 (make_cleanup_restore_uinteger): Remove.
3553 (make_cleanup_restore_integer): Remove.
3554 (struct restore_integer_closure): Remove.
3555 (restore_integer): Remove.
3556 * utils.h (struct set_batch_flag_and_restore_page_info): New
3557 class.
3558 (set_batch_flag_and_make_cleanup_restore_page_info): Remove.
3559 (make_cleanup_restore_page_info): Remove.
3560 (make_cleanup_restore_uinteger) Remove.
3561 (make_cleanup_restore_integer) Remove.
3562
07036511
TT
35632017-10-03 Tom Tromey <tom@tromey.com>
3564
3565 * record-full.h (record_full_gdb_operation_disable_set): Return
3566 scoped_restore_tmpl<int>.
3567 * infrun.c (adjust_pc_after_break): Update.
3568 (handle_signal_stop): Update.
3569 * record-full.c (record_full_gdb_operation_disable_set): Return
3570 scoped_restore_tmpl<int>.
3571 (record_full_wait_1, record_full_insert_breakpoint)
3572 (record_full_remove_breakpoint, record_full_save)
3573 (record_full_goto_insn): Update.
3574
45320ffa
TT
35752017-10-02 Tom Tromey <tom@tromey.com>
3576
3577 PR rust/22236:
3578 * rust-lang.c (rust_val_print_str): New function.
3579 (val_print_struct): Call it.
3580 (rust_subscript): Preserve name of slice type.
3581
b3e3859b
TT
35822017-10-02 Tom Tromey <tom@tromey.com>
3583
3584 * rust-lang.c (rust_subscript): Handle slices in
3585 EVAL_AVOID_SIDE_EFFECTS case.
3586
01af5e0d
TT
35872017-10-02 Tom Tromey <tom@tromey.com>
3588
3589 * rust-lang.c (rust_slice_type_p): Recognize &str as a slice type.
3590
888e3ddb
TT
35912017-10-02 Tom Tromey <tom@tromey.com>
3592
3593 * rust-lang.h (rust_slice_type): Add "extern".
3594
cc536b21
PA
35952017-10-02 Tom Tromey <tom@tromey.com>
3596 Pedro Alves <palves@redhat.com>
3597
3598 * ada-lang.h (ada_exc_info::operator<): Make const.
3599 (ada_exc_info::operator==): Make const.
3600 * ada-lang.c (ada_exc_info::operator<, ada_exc_info::operator==):
3601 Make const.
3602
386c8614
TT
36032017-09-29 Tom Tromey <tom@tromey.com>
3604
3605 * target.c (read_whatever_is_readable): Change type of "result".
3606 Update.
3607 (free_memory_read_result_vector): Remove.
3608 (read_memory_robust): Change return type. Update.
3609 * mi/mi-main.c (mi_cmd_data_read_memory_bytes): Update. Use
3610 bin2hex, std::string.
3611 * target.h (memory_read_result_s): Remove typedef.
3612 (free_memory_read_result_vector): Remove.
3613 (read_memory_robust): Return std::vector.
3614
789c4b5e
TT
36152017-09-29 Tom Tromey <tom@tromey.com>
3616
3617 * mi/mi-main.c (captured_mi_execute_command): Use scope_restore.
3618
ab816a27
TT
36192017-09-29 Tom Tromey <tom@tromey.com>
3620
3621 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Update.
3622 * ada-lang.h (struct ada_exc_info): Remove typedef. Declare
3623 operator< and operator==.
3624 (ada_exceptions_list): Return a std::vector.
3625 * ada-lang.c (ada_exc_info::operator<): Rename from
3626 compare_ada_exception_info.
3627 (ada_exc_info::operator==): New.
3628 (sort_remove_dups_ada_exceptions_list): Change type of
3629 "exceptions".
3630 (ada_add_standard_exceptions, ada_add_exceptions_from_frame)
3631 (ada_add_global_exceptions): Likewise.
3632 (ada_exceptions_list_1): Return a std::vector.
3633 (ada_exceptions_list): Likewise.
3634
52f9abe4
TT
36352017-09-29 Tom Tromey <tom@tromey.com>
3636
3637 * mi/mi-main.c (struct print_one_inferior_data) <inferiors>: Now a
3638 'std::set *'.
3639 (print_one_inferior): Update.
3640 (free_vector_of_ints): Remove.
3641 (list_available_thread_groups): Change "ids" to std::set.
3642 (mi_cmd_list_thread_groups): Update.
3643 (struct collect_cores_data) <core>: Now a std::set.
3644 (collect_cores): Update.
3645 (unique): Remove.
3646 (print_one_inferior): Update.
3647
dcd5ddcc
TT
36482017-09-29 Tom Tromey <tom@tromey.com>
3649
3650 * mi/mi-main.c (mi_execute_cli_command): Use std::string.
3651 (mi_execute_async_cli_command): Likewise.
3652 (mi_cmd_trace_frame_collected): Use field_fmt.
3653
45d288cc
TT
36542017-09-29 Tom Tromey <tom@tromey.com>
3655
3656 * mi/mi-main.c (mi_cmd_data_write_memory_bytes): Use
3657 gdb::byte_vector.
3658
6afe2f4a
TT
36592017-09-29 Tom Tromey <tom@tromey.com>
3660
3661 * mi/mi-parse.c (mi_parse): Remove unused declaration.
3662
9813429a
TT
36632017-09-29 Tom Tromey <tom@tromey.com>
3664
3665 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Don't copy "oarg".
3666
2d6960b4
TT
36672017-09-29 Tom Tromey <tom@tromey.com>
3668
3669 * varobj.h (varobj_gen_name): Return std::string.
3670 * varobj.c (varobj_gen_name): Return std::string.
3671 * mi/mi-cmd-var.c (mi_cmd_var_create): Use std::string.
3672 (mi_cmd_var_delete): Don't copy "name".
3673
784c453a
TT
36742017-09-29 Tom Tromey <tom@tromey.com>
3675
3676 * mi/mi-cmd-break.c (mi_argv_to_format): Return std::string.
3677 (mi_cmd_break_insert_1): Update.
3678
a9bc57b9
TT
36792017-09-29 Tom Tromey <tom@tromey.com>
3680
3681 * target.h (make_scoped_defer_target_commit_resume): Update.
3682 * target.c (make_scoped_defer_target_commit_resume): Rename from
3683 make_cleanup_defer_target_commit_resume. Return a
3684 scoped_restore.
3685 * infrun.c (proceed): Use make_scoped_defer_target_commit_resume.
3686
9754d8c4
TT
36872017-09-29 Tom Tromey <tom@tromey.com>
3688
3689 * main.c (captured_main_1): Remove unused declaration.
3690 * spu-multiarch.c (parse_spufs_run): Remove unused declaration.
3691
99ef965c
TT
36922017-09-29 Tom Tromey <tom@tromey.com>
3693
3694 * symtab.c (search_symbols): Remove unused outer cleanup.
3695 (make_source_files_completion_list): Remove unused declaration.
3696
42518ba7
TT
36972017-09-29 Tom Tromey <tom@tromey.com>
3698
3699 * mt-tdep.c (mt_push_dummy_call): Use gdb::byte_vector.
3700
726b2169
TT
37012017-09-29 Tom Tromey <tom@tromey.com>
3702
3703 * xstormy16-tdep.c (xstormy16_push_dummy_call): Use
3704 gdb::byte_vector.
3705
55b06432
TT
37062017-09-29 Tom Tromey <tom@tromey.com>
3707
3708 * complaints.c (vcomplaint): Use std::string.
3709
8abcee91
TT
37102017-09-29 Tom Tromey <tom@tromey.com>
3711
3712 * tracepoint.c (trace_variable_command): Use std::string.
3713 (encode_actions_1): Remove unused declarations.
3714 (create_tsv_from_upload): Use std::string.
3715
6ad94bc7
TT
37162017-09-29 Tom Tromey <tom@tromey.com>
3717
3718 * cp-support.c (gdb_demangle): Use std::string.
3719
2003f3d8
TT
37202017-09-29 Tom Tromey <tom@tromey.com>
3721
3722 * stack.c (parse_frame_specification): Use std::string
3723 (info_frame_command): Use gdb::unique_xmalloc_ptr.
3724
8f8accb5
TT
37252017-09-29 Tom Tromey <tom@tromey.com>
3726
3727 * tilegx-tdep.c (tilegx_push_dummy_call): Use gdb::byte_vector.
3728
200aa7b1
TT
37292017-09-29 Tom Tromey <tom@tromey.com>
3730
3731 * utils.c (vfprintf_maybe_filtered): Use std::string.
3732 (vfprintf_unfiltered): Likewise.
3733
606aae8a
TT
37342017-09-29 Tom Tromey <tom@tromey.com>
3735
3736 * event-top.c (top_level_prompt): Return std::string.
3737 (display_gdb_prompt): Update.
3738
bd413795
TT
37392017-09-29 Tom Tromey <tom@tromey.com>
3740
3741 * unittests/common-utils-selftests.c (format): New function.
3742 (string_vprintf_tests): New function.
3743 (_initialize_common_utils_selftests): Register new tests.
3744 * common/common-utils.c (string_vprintf): New function.
3745 * common/common-utils.h (string_vprintf): Declare.
3746
256642e8
PA
37472017-09-29 Pedro Alves <palves@redhat.com>
3748
3749 * common/rsp-low.c (unpack_varlen_hex): Constify.
3750 * common/rsp-low.h (unpack_varlen_hex): Constify.
3751 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
3752 Constify.
3753 * remote.c (remote_set_permissions, read_ptid)
3754 (remote_current_thread, remote_get_threads_with_qthreadinfo)
3755 (remote_static_tracepoint_marker_at)
3756 (remote_static_tracepoint_markers_by_strid)
3757 (stop_reply_extract_thread, remote_parse_stop_reply): Constify.
3758 * tracepoint.c (parse_trace_status, parse_tracepoint_status)
3759 (parse_tracepoint_definition, parse_tsv_definition)
3760 (parse_static_tracepoint_marker_definition): Constify.
3761 * tracepoint.h (parse_static_tracepoint_marker_definition)
3762 (parse_trace_status, parse_tracepoint_status)
3763 (parse_tracepoint_definition, parse_tsv_definition): Constify.
3764
b6bb3468
PA
37652017-09-29 Pedro Alves <palves@redhat.com>
3766
3767 * remote.c (target_buf, target_buf_size): Delete.
3768 (remote_get_noisy_reply): Remove buf_p and sizeof_buf parameters.
3769 Use the connection's packet buffer instead.
3770 All callers adjusted.
3771 (_initialize_remote): Remove references to target_buf and
3772 target_buf_size.
3773
b2f8eb7a
PA
37742017-09-28 Pedro Alves <palves@redhat.com>
3775
3776 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
3777 unittests/common-utils-selftests.c.
3778 (SUBDIR_UNITTESTS_OBS): Add common-utils-selftests.o.
3779 (COMMON_OBS): Remove utils-selftests.o.
3780 * utils-selftests.c: Move to ...
3781 * unittests/common-utils-selftests.c: ... here and rename self
3782 test to "string_printf".
3783
08302ed2
DE
37842017-09-28 Alexander Shaposhnikov <alexander.v.shaposhnikov@gmail.com> (tiny patch)
3785
3786 * dwarf2read.c (open_and_init_dwp_file): Protect against dwp_file
3787 having NULL cus or tus.
3788
96a5a1d3
UW
37892017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3790
3791 * arm-tdep.c: (convert_from_extended): Remove.
3792 (convert_to_extended): Likewise.
3793 (arm_extract_return_value): Use convert_typed_floating.
3794 (arm_store_return_value): Likewise.
3795
3796 * sh-tdep.h (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3797 * sh-tdep.c: Do not include "floatformat.h".
3798 (sh_littlebyte_bigword_type): New function.
3799 (sh_register_convert_to_virtual): Use convert_typed_floating.
3800 (sh_register_convert_to_raw): Likewise.
3801 * sh64-tdep.c: (struct gdbarch_tdep): Add sh_littlebyte_bigword_type.
3802 (sh64_littlebyte_bigword_type): New function.
3803 (sh64_extract_return_value): Use convert_typed_floating.
3804 (sh64_register_convert_to_virtual): Likewise.
3805 (sh64_register_convert_to_raw): Likewise.
3806
0db7851f
UW
38072017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3808
3809 * doublest.h (floatformat_from_type): Move to gdbtypes.h.
3810 * doublest.c (floatformat_from_type): Move to gdbtypes.c.
3811
3812 * gdbtypes.h (union type_specific): Make field floatformat hold
3813 just a single struct floatformat, not an array.
3814 (floatformat_from_type): Move here.
3815 * gdbtypes.c (floatformat_from_type): Move here. Update to
3816 changed TYPE_FLOATFORMAT definition.
3817 (verify_floatformat): Update to changed TYPE_FLOATFORMAT.
3818 (recursive_dump_type): Likewise.
3819 (init_float_type): Install correct floatformat for byte order.
3820 (arch_float_type): Likewise.
3821
77b7c781
UW
38222017-09-27 Ulrich Weigand <uweigand@de.ibm.com>
3823
3824 * gdbtypes.c (init_type): Change incoming argument from
3825 length-in-bytes to length-in-bits. Assert length is a
3826 multiple of TARGET_CHAR_BITS.
3827 (arch_type, arch_flags_type): Likewise.
3828 (init_integer_type): Update call to init_type.
3829 (init_character_type): Likewise.
3830 (init_boolean_type): Likewise.
3831 (init_float_type): Likewise.
3832 (init_decfloat_type): Likewise.
3833 (init_complex_type): Likewise.
3834 (init_pointer_type): Likewise.
3835 (objfile_type): Likewise.
3836 (arch_integer_type): Update call to arch_type.
3837 (arch_character_type): Likewise.
3838 (arch_boolean_type): Likewise.
3839 (arch_float_type): Likewise.
3840 (arch_decfloat_type): Likewise.
3841 (arch_complex_type): Likewise.
3842 (arch_pointer_type): Likewise.
3843 (gdbtypes_post_init): Likewise.
3844
3845 * dwarf2read.c (dwarf2_init_float_type): Update call to init_type.
3846 (read_base_type): Likewise.
3847 * mdebugread.c (basic_type): Likewise.
3848 * stabsread.c (dbx_init_float_type): Likewise.
3849 (rs6000_builtin_type): Likewise.
3850 (read_range_type): Likewise. Also, fix call to init_integer_type
3851 with erroneous length argument.
3852
3853 * ada-lang.c (ada_language_arch_info): Update call to arch_type.
3854 * d-lang.c (build_d_types): Likewise.
3855 * f-lang.c (build_fortran_types): Likewise.
3856 * go-lang.c (build_go_types): Likewise.
3857 * opencl-lang.c (build_opencl_types): Likewise.
3858 * jit.c (finalize_symtab): Likewise.
3859 * gnu-v3-abi.c (build_gdb_vtable_type): Likewise.
3860 (build_std_type_info_type): Likewise.
3861 * target-descriptions.c (tdesc_gdb_type): Likewise. Also,
3862 update call to arch_flags_type.
3863
3864 * linux-tdep.c (linux_get_siginfo_type_with_fields): Update call to
3865 arch_type.
3866 * fbsd-tdep.c (fbsd_get_siginfo_type): Likewise.
3867 * windows-tdep.c (windows_get_tlb_type): Likewise.
3868
3869 * avr-tdep.c (avr_gdbarch_init): Update call to arch_type.
3870 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
3871 * m32c-tdep.c (make_types): Likewise.
3872 * rl78-tdep.c (rl78_gdbarch_init): Likewise.
3873 (rl78_psw_type): Update call to arch_flags_type.
3874 * m68k-tdep.c (m68k_ps_type): Update call to arch_flags_type.
3875 * rx-tdep.c (rx_psw_type): Likewise.
3876 (rx_fpsw_type): Likewise.
3877 * sparc-tdep.c (sparc_psr_type): Likewise.
3878 (sparc_fsr_type): Likewise.
3879 * sparc64-tdep.c (sparc64_pstate_type): Likewise.
3880 (sparc64_ccr_type): Likewise.
3881 (sparc64_fsr_type): Likewise.
3882 (sparc64_fprs_type): Likewise.
3883
f21b4d5c
TT
38842017-09-27 Tom Tromey <tom@tromey.com>
3885
3886 * findcmd.c (find_command): Constify.
3887
643c2ffa
TT
38882017-09-27 Tom Tromey <tom@tromey.com>
3889
3890 * ada-tasks.c (task_command_1, task_command): Constify.
3891
510e5e56
TT
38922017-09-27 Tom Tromey <tom@tromey.com>
3893
3894 * symtab.c (maintenance_print_symbol_cache)
3895 (maintenance_flush_symbol_cache)
3896 (maintenance_print_symbol_cache_statistics): Constify.
3897
e503b191
TT
38982017-09-27 Tom Tromey <tom@tromey.com>
3899
3900 * inferior.c (detach_inferior_command, kill_inferior_command)
3901 (inferior_command): Constify.
3902
4e001312
TT
39032017-09-27 Tom Tromey <tom@tromey.com>
3904
3905 * regcache.c (regcache_print, maintenance_print_registers)
3906 (maintenance_print_raw_registers)
3907 (maintenance_print_cooked_registers)
3908 (maintenance_print_register_groups)
3909 (maintenance_print_remote_registers): Constify.
3910
77763700
TT
39112017-09-27 Tom Tromey <tom@tromey.com>
3912
3913 * printcmd.c (map_display_numbers, undisplay_command)
3914 (enable_disable_display_command, enable_display_command)
3915 (disable_display_command): Constify.
3916
4495129a
TT
39172017-09-27 Tom Tromey <tom@tromey.com>
3918
3919 * breakpoint.h (delete_command): Don't declare.
3920 * breakpoint.c (delete_command, enable_once_command)
3921 (enable_count_command, enable_delete_command, breakpoint_1)
3922 (maintenance_info_breakpoints, stopin_command, stopat_command)
3923 (delete_command, delete_trace_command, save_breakpoints)
3924 (save_breakpoints_command, save_tracepoints_command): Constify.
3925
3088cf40
TT
39262017-09-27 Tom Tromey <tom@tromey.com>
3927
3928 * macrocmd.c (macro_expand_command, macro_expand_once_command)
3929 (skip_ws, extract_identifier, macro_define_command)
3930 (macro_undef_command, macro_list_command): Constify.
3931
69f476a3
TT
39322017-09-27 Tom Tromey <tom@tromey.com>
3933
3934 * infcmd.c (environment_info, set_environment_command)
3935 (unset_environment_command, path_info, info_proc_cmd_1)
3936 (info_proc_cmd_mappings, info_proc_cmd_stat)
3937 (info_proc_cmd_status, info_proc_cmd_cwd, info_proc_cmd_cmdline)
3938 (info_proc_cmd_exe, info_proc_cmd_all): Constify.
3939
c4a3e68e
TT
39402017-09-27 Tom Tromey <tom@tromey.com>
3941
3942 * i386-tdep.c (i386_mpx_info_bounds, i386_mpx_set_bounds):
3943 Constify.
3944
c9d31bd6
TT
39452017-09-27 Tom Tromey <tom@tromey.com>
3946
3947 * symfile-mem.c (add_symbol_file_from_memory_command): Constify.
3948
1f3f85eb
TT
39492017-09-27 Tom Tromey <tom@tromey.com>
3950
3951 * demangle.c (demangle_command): Constify.
3952
9c504b5d
TT
39532017-09-27 Tom Tromey <tom@tromey.com>
3954
3955 * progspace.c (maintenance_info_program_spaces_command):
3956 Constify.
3957
6663cf91
TT
39582017-09-27 Tom Tromey <tom@tromey.com>
3959
3960 * compile/compile.c (check_raw_argument, compile_file_command)
3961 (compile_code_command, compile_print_command): Constify.
3962
34e5fa26
TT
39632017-09-27 Tom Tromey <tom@tromey.com>
3964
3965 * reggroups.c (maintenance_print_reggroups): Constify.
3966
8384c356
TT
39672017-09-27 Tom Tromey <tom@tromey.com>
3968
3969 * dwarf2read.c (save_gdb_index_command): Constify.
3970
884beb0c
TT
39712017-09-27 Tom Tromey <tom@tromey.com>
3972
3973 * stap-probe.c (info_probes_stap_command): Constify.
3974
e0b2930c
TT
39752017-09-27 Tom Tromey <tom@tromey.com>
3976
3977 * fork-child.c (unset_exec_wrapper_command): Constify.
3978
f938677d
TT
39792017-09-27 Tom Tromey <tom@tromey.com>
3980
3981 * btrace.c (get_uint, get_context_size, no_chunk)
3982 (maint_btrace_packet_history_cmd)
3983 (maint_btrace_clear_packet_history_cmd, maint_btrace_clear_cmd)
3984 (maint_info_btrace_cmd): Constify.
3985
8949cb87
TT
39862017-09-27 Tom Tromey <tom@tromey.com>
3987
3988 * reverse.c (delete_bookmark_command): Constify.
3989
ac88e2de
TT
39902017-09-27 Tom Tromey <tom@tromey.com>
3991
3992 * remote.c (set_memory_packet_size)
3993 (set_memory_write_packet_size, show_memory_write_packet_size)
3994 (set_memory_read_packet_size, show_memory_read_packet_size)
3995 (compare_sections_command, packet_command, remote_put_command)
3996 (remote_get_command, remote_delete_command): Constify.
3997
bd4c9dfe
TT
39982017-09-27 Tom Tromey <tom@tromey.com>
3999
4000 * mips-tdep.c (show_mipsfpu_command, set_mipsfpu_single_command)
4001 (set_mipsfpu_double_command, set_mipsfpu_none_command)
4002 (set_mipsfpu_auto_command): Constify.
4003
5e93d4c6
TT
40042017-09-27 Tom Tromey <tom@tromey.com>
4005
4006 * cli/cli-cmds.h (cd_command): Constify.
4007 * cli/cli-cmds.c (cd_command): Constify.
4008
fc41a75b
TT
40092017-09-27 Tom Tromey <tom@tromey.com>
4010
4011 * thread.c (thread_name_command, thread_find_command): Constify.
4012
67810076
TT
40132017-09-27 Tom Tromey <tom@tromey.com>
4014
4015 * probe.c (enable_probes_command, disable_probes_command):
4016 Constify.
4017
1d8b34a7
TT
40182017-09-27 Tom Tromey <tom@tromey.com>
4019
4020 * symfile.c (symbol_file_command): Constify.
4021 * gdbcore.h (deprecated_file_changed_hook): Constify.
4022 * exec.c (deprecated_file_changed_hook, exec_file_command)
4023 (file_command): Constify.
4024 * defs.h (symbol_file_command): Constify.
4025
442019e1
TT
40262017-09-27 Tom Tromey <tom@tromey.com>
4027
4028 * remote-fileio.c (set_system_call_allowed)
4029 (show_system_call_allowed): Constify.
4030
2983f7cb
TT
40312017-09-27 Tom Tromey <tom@tromey.com>
4032
4033 * tracepoint.c (delete_trace_variable_command)
4034 (tfind_end_command, tfind_start_command, tfind_pc_command)
4035 (tfind_tracepoint_command, tfind_line_command)
4036 (tfind_range_command, tfind_outside_command): Constify.
4037
4fd41b24
TT
40382017-09-27 Tom Tromey <tom@tromey.com>
4039
4040 * ax-gdb.c (maint_agent_printf_command, agent_command)
4041 (agent_eval_command): Constify.
4042
f2fc3015
TT
40432017-09-27 Tom Tromey <tom@tromey.com>
4044
4045 * tracepoint.c (info_scope_command): Constify.
4046 * python/python.c (gdbpy_decode_line): Constify.
4047 * python/py-breakpoint.c (bppy_init): Constify.
4048 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Constify.
4049 * location.h: (new_linespec_location)
4050 (string_to_event_location_basic, string_to_event_location):
4051 Constify.
4052 * location.c (new_linespec_location)
4053 (string_to_event_location_basic, string_to_event_location):
4054 Constify.
4055 * linespec.h (decode_line_with_current_source)
4056 (decode_line_with_last_displayed, linespec_lex_to_end): Constify.
4057 * linespec.c (linespec_lex_to_end)
4058 (decode_line_with_current_source)
4059 (decode_line_with_last_displayed): Constify.
4060 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x):
4061 Constify.
4062 * cli/cli-cmds.c (edit_command, list_command): Constify.
4063 * breakpoint.h (until_break_command, watch_command_wrapper)
4064 (awatch_command_wrapper, rwatch_command_wrapper)
4065 (init_ada_exception_breakpoint): Constify.
4066 * breakpoint.c (break_command_1, dprintf_command)
4067 (break_range_command, watch_command_wrapper)
4068 (rwatch_command_wrapper, awatch_command_wrapper)
4069 (until_break_command, init_ada_exception_breakpoint)
4070 (strace_marker_create_sals_from_location, trace_command)
4071 (ftrace_command, strace_command, struct tracepoint): Constify.
4072 * ax-gdb.c (agent_command_1): Constify.
4073 * ada-lang.c (ada_exception_sal): Constify.
4074
8c2f95f4
TT
40752017-09-27 Tom Tromey <tom@tromey.com>
4076
4077 * record.c (cmd_record_delete, cmd_record_stop, cmd_record_save)
4078 (cmd_record_goto_begin, cmd_record_goto_end, get_insn_number)
4079 (get_context_size, no_chunk, get_insn_history_modifiers)
4080 (cmd_record_insn_history, get_call_history_modifiers)
4081 (cmd_record_call_history): Constify.
4082
a0d65762
TT
40832017-09-27 Tom Tromey <tom@tromey.com>
4084
4085 * source.c (show_substitute_path_command)
4086 (unset_substitute_path_command, set_substitute_path_command):
4087 Constify.
4088
58971144
TT
40892017-09-27 Tom Tromey <tom@tromey.com>
4090
4091 * typeprint.c (maintenance_print_type): Constify.
4092 * maint.c (maintenance_dump_me, maintenance_demangle)
4093 (maintenance_time_display, maintenance_info_sections)
4094 (maintenance_print_statistics, maintenance_deprecate)
4095 (maintenance_undeprecate): Constify.
4096 (maintenance_do_deprecate): Constify. Use std::string.
4097 (maintenance_selftest): Constify.
4098 * gdbtypes.h (maintenance_print_type): Constify.
4099
c482f52c
TT
41002017-09-27 Tom Tromey <tom@tromey.com>
4101
4102 * hppa-tdep.c (unwind_command): Constify.
4103
e100df1a
TT
41042017-09-27 Tom Tromey <tom@tromey.com>
4105
4106 * target-descriptions.c (unset_tdesc_filename_cmd)
4107 (maint_print_c_tdesc_cmd, maintenance_check_xml_descriptions):
4108 Constify.
4109
31d56ade
TT
41102017-09-27 Tom Tromey <tom@tromey.com>
4111
4112 * dummy-frame.c (maintenance_print_dummy_frames): Constify.
4113
b961da0b
TT
41142017-09-27 Tom Tromey <tom@tromey.com>
4115
4116 * tui/tui.c (tui_enable_command, tui_disable_command): Constify.
4117
e2d8ae16
TT
41182017-09-27 Tom Tromey <tom@tromey.com>
4119
4120 * tui/tui-regs.c (tui_reg_command): Constify.
4121
863779b0
TT
41222017-09-27 Tom Tromey <tom@tromey.com>
4123
4124 * skip.c (skip_file_command, skip_function_command)
4125 (skip_enable_command, skip_disable_command, skip_delete_command):
4126 Constify.
4127
cdb34d4a
TT
41282017-09-27 Tom Tromey <tom@tromey.com>
4129
4130 * record-btrace.c (cmd_record_btrace_bts_start)
4131 (cmd_record_btrace_pt_start): Constify.
4132
e99c83e7
TT
41332017-09-27 Tom Tromey <tom@tromey.com>
4134
4135 * symmisc.c (maintenance_print_symbols)
4136 (maintenance_print_msymbols, maintenance_print_objfiles)
4137 (maintenance_info_symtabs, maintenance_check_symtabs)
4138 (maintenance_expand_symtabs, maintenance_info_line_tables):
4139 Constify.
4140
32faf971
TT
41412017-09-27 Tom Tromey <tom@tromey.com>
4142
4143 * top.c (new_ui_command): Constify.
4144
2cf311eb
TT
41452017-09-27 Tom Tromey <tom@tromey.com>
4146
4147 * symfile.c (add_symbol_file_command)
4148 (remove_symbol_file_command, list_overlays_command)
4149 (map_overlay_command, unmap_overlay_command)
4150 (overlay_auto_command, overlay_manual_command)
4151 (overlay_off_command, overlay_load_command): Constify.
4152
e6738699
TT
41532017-09-27 Tom Tromey <tom@tromey.com>
4154
4155 * spu-tdep.c (info_spu_event_command, info_spu_signal_command)
4156 (info_spu_mailbox_command, info_spu_dma_command)
4157 (info_spu_proxydma_command): Constify.
4158
aa360cd5
TT
41592017-09-27 Tom Tromey <tom@tromey.com>
4160
4161 * cli/cli-logging.c (set_logging_on, set_logging_off): Constify.
4162
898241a5
TT
41632017-09-27 Tom Tromey <tom@tromey.com>
4164
4165 * cli/cli-script.c (user_defined_command): Constify.
4166
2d0ac106
TT
41672017-09-27 Tom Tromey <tom@tromey.com>
4168
4169 * cli/cli-dump.c (dump_memory_command, dump_value_command)
4170 (dump_srec_memory, dump_srec_value, dump_ihex_memory)
4171 (dump_ihex_value, dump_verilog_memory, dump_verilog_value)
4172 (dump_tekhex_memory, dump_tekhex_value, dump_binary_memory)
4173 (dump_binary_value, append_binary_memory, append_binary_value):
4174 Constify.
4175 (struct dump_context) <func>: Constify.
4176 (add_dump_command): Update.
4177
dede02ce
TT
41782017-09-27 Tom Tromey <tom@tromey.com>
4179
4180 * cli/cli-cmds.c (show_version, show_configuration)
4181 (source_command, show_user): Constify.
4182
d3cb6b99
TT
41832017-09-27 Tom Tromey <tom@tromey.com>
4184
4185 * target.c (maintenance_print_target_stack): Constify.
4186
1970a12f
TT
41872017-09-27 Tom Tromey <tom@tromey.com>
4188
4189 * interps.c (interpreter_exec_cmd): Constify.
4190
41243651
TT
41912017-09-27 Tom Tromey <tom@tromey.com>
4192
4193 * record-full.c (cmd_record_full_restore): Constify.
4194
4465d9db
TT
41952017-09-27 Tom Tromey <tom@tromey.com>
4196
4197 * memattr.c (enable_mem_command, disable_mem_command)
4198 (delete_mem_command): Constify.
4199
ad25e423
TT
42002017-09-27 Tom Tromey <tom@tromey.com>
4201
4202 * value.c (show_convenience): Constify.
4203
d64097b1
TT
42042017-09-27 Tom Tromey <tom@tromey.com>
4205
4206 * gdbcore.h (core_file_command): Update.
4207 * corefile.c (core_file_command): Constify.
4208
4d4589ef
TT
42092017-09-27 Tom Tromey <tom@tromey.com>
4210
4211 * user-regs.c (maintenance_print_user_registers): Constify.
4212
32a7bf17
TT
42132017-09-27 Tom Tromey <tom@tromey.com>
4214
4215 * cp-namespace.c (maintenance_cplus_namespace): Constify.
4216
4a475551
TT
42172017-09-27 Tom Tromey <tom@tromey.com>
4218
4219 * cp-support.c (first_component_command): Constify.
4220
990b9f9f
TT
42212017-09-27 Tom Tromey <tom@tromey.com>
4222
4223 * psymtab.c (maintenance_print_psymbols)
4224 (maintenance_info_psymtabs, maintenance_check_psymtabs):
4225 Constify.
4226
c281872e
TT
42272017-09-27 Tom Tromey <tom@tromey.com>
4228
4229 * windows-tdep.c (display_tib): Constify.
4230
5b64bf74
TT
42312017-09-27 Tom Tromey <tom@tromey.com>
4232
4233 * linux-fork.c (delete_checkpoint_command)
4234 (detach_checkpoint_command): Constify.
4235
4ada038f
TT
42362017-09-27 Tom Tromey <tom@tromey.com>
4237
4238 * cp-abi.c (set_cp_abi_cmd, show_cp_abi_cmd): Constify.
4239
57f5a81b
TT
42402017-09-27 Tom Tromey <tom@tromey.com>
4241
4242 * arc-tdep.c (dump_arc_instruction_command): Constify.
4243
b0a8e6c4
TT
42442017-09-27 Tom Tromey <tom@tromey.com>
4245
4246 * valprint.c (set_radix, show_radix): Constify.
4247
8d97dc1c
TT
42482017-09-27 Tom Tromey <tom@tromey.com>
4249
4250 * dtrace-probe.c (info_probes_dtrace_command): Constify.
4251
eb7c454d
TT
42522017-09-27 Tom Tromey <tom@tromey.com>
4253
4254 * command.h (not_just_help_class_command): Update.
4255 * cli/cli-decode.h (not_just_help_class_command): Update.
4256 * cli/cli-decode.c (not_just_help_class_command): Constify.
4257
e4e33335
TT
42582017-09-27 Tom Tromey <tom@tromey.com>
4259
4260 * gdb_bfd.c (maintenance_info_bfds): Constify.
4261
0450cc4c
TT
42622017-09-27 Tom Tromey <tom@tromey.com>
4263
4264 * cli/cli-decode.c (add_cmd, set_cmd_cfunc): New function
4265 overloads.
4266 (do_add_cmd): Rename from add_cmd. Don't call set_cmd_cfunc.
4267 (do_const_cfunc): New function.
4268 (cmd_cfunc_eq): New overload.
4269 (cli_user_command_p): Check do_const_cfunc.
4270 * cli/cli-decode.h (struct cmd_list_element) <function>: New field
4271 const_cfunc.
4272 * command.h (add_cmd): Add const overload and no-function
4273 overload.
4274 (set_cmd_cfunc): Add const overload.
4275 (cmd_const_cfunc_ftype): Declare.
4276 (cmd_cfunc_eq): Add const overload.
4277 * breakpoint.c, cli-cmds.c, cli-dump.c, guile/scm-cmd.c,
4278 python/py-cmd.c, target.c, tracepoint.c: Use no-function add_cmd
4279 overload.
4280
a9bbfbd8
TT
42812017-09-27 Tom Tromey <tom@tromey.com>
4282
4283 * macroexp.c (get_next_token_for_substitution): New function.
4284 (substitute_args): Call it. Check for __VA_OPT__.
4285
5230b05a
WT
42862017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4287 Pedro Alves <palves@redhat.com>
4288
4289 * dwarf2read.c (dwarf2_cu): Remove field producer_is_icc and add
4290 producer_is_icc_lt_14.
4291 (producer_is_icc_lt_14): New function.
4292 (check_producer): Add code for checking version of ICC.
4293 (producer_is_icc): Move to producer.c.
4294 (read_structure_type): Restrict ICC workaround to ICC<14.
4295 * producer.c: Include selftest.h.
4296 (producer_is_icc, producer_parsing_tests, _initialize_producer):
4297 New functions.
4298 * producer.h (producer_is_icc): New declaration.
4299
b32b108a
WT
43002017-09-26 Walfred Tedeschi <walfred.tedeschi@intel.com>
4301
4302 * Makefile.in (SFILES): Add producer.c.
4303 (COMMON_OBS): Add producer.o
4304 * amd64-tdep.c (producer.h): Add new include.
4305 * dwarf2read.c (producer.h): Add new include.
4306 * producer.c: New file.
4307 * producer.h: New file.
4308 * utils.c (producer_is_gcc, producer_is_gcc_ge_4): Move to
4309 producer.c.
4310 * utils.h (producer_is_gcc, producer_is_gcc_ge_4): Move to
4311 producer.h.
4312
5007d765
MK
43132017-09-26 Matthias Klose <doko@ubuntu.com>
4314
4315 * configure.ac: Search ncursesw before ncurses.
4316 Check ncursesw/ncurses.h before ncurses/ncurses.h.
4317 * gdb_curses.h: Include <ncursesw/ncurses.h>
4318 * config.in, configure: Regenerate.
4319
281c4447
RO
43202017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4321
4322 PR gdb/22185
4323 * configure.host <*-*-solaris2.[01], *-*-solaris2.[2-9]*>: Mark as
4324 obsolete.
4325 Use gdb_host sol2 for i[34567]86-*-solaris2*, x86_64-*-solaris2*.
4326 Remove i386sol2 support.
4327 * configure.nat <i386sol2>: Remove.
4328 <sol2-64>: Fold into ...
4329 <sol2>: ... this.
4330 Move common settings to default section.
4331 Add sol-thread.o.
4332 * configure.tgt <i[34567]86-*-solaris2.1[0-9]*,
4333 x86_64-*-solaris2.1[0-9]*>: Rename to ...
4334 <i[34567]86-*-solaris2*, x86_64-*-solaris2*>: ... this.
4335 <i[34567]86-*-solaris*>: Remove.
4336 <sparc-*-solaris2.[0-6], sparc-*-solaris2.[0-6].*>: Remove.
4337
4338 * configure.ac: Remove wctype in libw check.
4339 (_MSE_INT_H): Don't define on Solaris 7-9.
4340 <solaris*>: Remove libthread_db.so.1 check.
4341 * configure: Regenerate.
4342 * config.in: Regenerate.
4343
4344 * proc-service.c: Remove PROC_SERVICE_IS_OLD handling.
4345 (gdb_ps_prochandle_t, gdb_ps_read_buf_t, gdb_ps_write_buf_t)
4346 (gdb_ps_size_t): Remove.
4347 Use base types in users.
4348 * sol-thread.c: Likewise, also for gdb_ps_addr_t.
4349
4350 * NEWS (Changes since GDB 8.0): Document Solaris 2.0-9 removal.
4351
39b06c20
RO
43522017-09-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4353
4354 PR build/22206
4355 * sparc64-tdep.c (adi_tag_fd): Print pid as long.
4356 (adi_is_addr_mapped): Likewise.
4357 (PSR_ICC): Don't redefine.
4358 (PSR_IMPL): Likewise.
4359
6c3e20f1
TT
43602017-09-25 Tom Tromey <tom@tromey.com>
4361
4362 * regcache.c (regcache::dump): Use string_printf.
4363
b292235f
TT
43642017-09-25 Tom Tromey <tom@tromey.com>
4365
4366 * regcache.c (class regcache_invalidator): New.
4367 (struct register_to_invalidate): Remove.
4368 (make_cleanup_regcache_invalidate): Remove.
4369 (regcache::raw_write): Use regcache_invalidator.
4370
9ac86b52
TT
43712017-09-25 Tom Tromey <tom@tromey.com>
4372
4373 * spu-tdep.c (spu2ppu_sniffer): Update.
4374 * regcache.h (make_cleanup_regcache_xfree): Don't declare.
4375 * regcache.c (do_regcache_xfree, make_cleanup_regcache_xfree):
4376 Remove.
4377 * ppc-linux-tdep.c (ppu2spu_sniffer): Update.
4378 * mi/mi-main.c (mi_cmd_data_list_changed_registers): Update.
4379 * frame.h (frame_save_as_regcache): Return std::unique_ptr.
4380 * frame.c (frame_save_as_regcache): Return std::unique_ptr.
4381 (frame_pop): Update.
4382
c0e383c6
TT
43832017-09-25 Tom Tromey <tom@tromey.com>
4384
4385 * spu-tdep.c (spu2ppu_dealloc_cache): Use delete.
4386 * regcache.h (regcache_xfree): Don't declare.
4387 * regcache.c (regcache_xfree): Remove.
4388 (do_regcache_xfree): Use delete.
4389 * ppc-linux-tdep.c (ppu2spu_dealloc_cache): Use delete.
4390 * linux-fork.c (free_fork): Use delete.
4391 (fork_save_infrun_state): Likewise.
4392 * jit.c (jit_dealloc_cache): Use delete.
4393 * infrun.c (discard_infcall_suspend_state): Use delete.
4394
791199cc
TT
43952017-09-25 Tom Tromey <tom@tromey.com>
4396
4397 * regcache.h (regcache_xmalloc): Don't declare.
4398 (regcache_raw_set_cached_value): Update comment.
4399 * regcache.c (regcache_xmalloc): Remove.
4400 * ppc-linux-tdep.c (ppu2spu_sniffer): Use new.
4401 * jit.c (jit_frame_sniffer): Use new.
4402 * frame.c (frame_save_as_regcache): Use new.
4403
289e23aa
AA
44042017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4405
4406 * NEWS: Advertise support for guarded-storage registers on IBM z.
4407
1b63490c
AA
44082017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4409
4410 * s390-linux-nat.c (have_regset_gs): New static variable.
4411 (s390_linux_fetch_inferior_registers): Handle guarded-storage
4412 control block and guarded-storage broadcast control regsets.
4413 (s390_read_description): Detect whether the target has
4414 guarded-storage support, return appropriate tdesc.
4415 * s390-linux-tdep.c (features/s390-gs-linux64.c): New include.
4416 (features/s390x-gs-linux64.c): Likewise.
4417 (struct gdbarch_tdep) <have_gs>: New field.
4418 (s390_regmap_gs, s390_regmap_gsbc, s390_gs_regset)
4419 (s390_gsbc_regset): New variables.
4420 (s390_iterate_over_regset_sections): Iterate over s390_gs_regset
4421 and s390_gsbc_regset, if applicable.
4422 (s390_core_read_description): Check whether core file was from a
4423 target with guarded-storage support; include appropriate regsets.
4424 (s390_gdbarch_init): Add registers for guarded-storage support.
4425 (_initialize_s390_tdep): Initialize new target descriptions that
4426 include registers for guarded-storage support.
4427 * s390-linux-tdep.h (HWCAP_S390_GS, S390_GSD_REGNUM)
4428 (S390_GSSM_REGNUM, S390_GSEPLA_REGNUM)
4429 (S390_BC_GSD_REGNUM, S390_BC_GSSM_REGNUM): New defines.
4430 (S390_NUM_REGS): Adjust macro definition.
4431 (s390_gs_regset, s390_gsbc_regset, tdesc_s390_gs_linux64)
4432 (tdesc_s390x_gs_linux64): New declarations.
4433
96235dc1
AA
44342017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
4435
4436 * features/s390-gs-linux64.xml: New file.
4437 * features/s390-gs.xml: New file.
4438 * features/s390-gsbc.xml: New file.
4439 * features/s390x-gs-linux64.xml: New file.
4440 * features/Makefile (WHICH): Add s390-gs-linux64 and
4441 s390x-gs-linux64.
4442 (s390-gs-linux64-expedite, s390x-gs-linux64-expedite): New macros.
4443 (XMLTOC): Add s390-gs-linux64.xml and s390x-linux64.xml.
4444 * features/s390-gs-linux64.c: New generated file.
4445 * features/s390x-gs-linux64.c: New file.
4446 * regformats/s390-gs-linux64.dat: New file.
4447 * regformats/s390x-gs-linux64.dat: New file.
4448
b4a7c699
TT
44492017-09-23 Tom Tromey <tom@tromey.com>
4450
4451 * defs.h (make_cleanup_override_quit_handler): Don't declare.
4452
c2f97536
TT
44532017-09-22 Tom Tromey <tom@tromey.com>
4454
4455 * utils.c (class scoped_input_handler) <m_quit_handler>: Change
4456 type to scoped_restore_tmpl.
4457 <scoped_input_handler>: Initialize m_quit_handler directly.
4458
43573013
SDJ
44592017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4460
4461 * cli/cli-cmds.c (pwd_command): Use "getcwd (NULL, 0)".
4462 (cd_command): Likewise. Free "current_directory" before
4463 assigning to it.
4464 * main.c (captured_main_1): Use "getcwd (NULL, 0)".
4465 * mi/mi-cmd-env.c (mi_cmd_env_pwd): Likewise.
4466 * top.c (gdb_dirbuf): Remove global declaration.
4467 * top.h (gdb_dirbuf): Likewise.
4468
6ec2e0f5
SDJ
44692017-09-22 Sergio Durigan Junior <sergiodj@redhat.com>
4470
4471 * gnulib/aclocal.m4: Regenerate.
4472 * gnulib/config.in: Regenerate.
4473 * gnulib/configure: Regenerate.
4474 * gnulib/import/Makefile.am: Regenerate.
4475 * gnulib/import/Makefile.in: Regenerate.
4476 * gnulib/import/assure.h: New file.
4477 * gnulib/import/at-func.c: Likewise
4478 * gnulib/import/chdir-long.c: New file.
4479 * gnulib/import/chdir-long.h: New file.
4480 * gnulib/import/cloexec.c: New file.
4481 * gnulib/import/cloexec.h: New file.
4482 * gnulib/import/close.c: New file.
4483 * gnulib/import/closedir.c: New file.
4484 * gnulib/import/dirent-private.h: New file.
4485 * gnulib/import/dup-safer.c: New file.
4486 * gnulib/import/dup.c: New file.
4487 * gnulib/import/dup2.c: New file.
4488 * gnulib/import/error.c: New file.
4489 * gnulib/import/error.h: New file.
4490 * gnulib/import/exitfail.c: New file.
4491 * gnulib/import/exitfail.h: New file.
4492 * gnulib/import/fchdir.c: New file.
4493 * gnulib/import/fcntl.c: New file.
4494 * gnulib/import/fcntl.in.h: New file.
4495 * gnulib/import/fd-hook.c: New file.
4496 * gnulib/import/fd-hook.h: New file.
4497 * gnulib/import/fd-safer.c: New file.
4498 * gnulib/import/fdopendir.c: New file.
4499 * gnulib/import/filename.h: New file.
4500 * gnulib/import/filenamecat-lgpl.c: New file.
4501 * gnulib/import/filenamecat.h: New file.
4502 * gnulib/import/fstat.c: New file.
4503 * gnulib/import/fstatat.c: New file.
4504 * gnulib/import/getcwd-lgpl.c: New file.
4505 * gnulib/import/getcwd.c: New file.
4506 * gnulib/import/getdtablesize.c: New file.
4507 * gnulib/import/getlogin_r.c: New file.
4508 * gnulib/import/getprogname.c: New file.
4509 * gnulib/import/getprogname.h: New file.
4510 * gnulib/import/gettext.h: New file.
4511 * gnulib/import/glob-libc.h: New file.
4512 * gnulib/import/glob.c: New file.
4513 * gnulib/import/glob.in.h: New file.
4514 * gnulib/import/intprops.h: New file.
4515 * gnulib/import/m4/chdir-long.m4: New file.
4516 * gnulib/import/m4/close.m4: New file.
4517 * gnulib/import/m4/closedir.m4: New file.
4518 * gnulib/import/m4/d-ino.m4: New file.
4519 * gnulib/import/m4/d-type.m4: New file.
4520 * gnulib/import/m4/dup.m4: New file.
4521 * gnulib/import/m4/dup2.m4: New file.
4522 * gnulib/import/m4/error.m4: New file.
4523 * gnulib/import/m4/fchdir.m4: New file.
4524 * gnulib/import/m4/fcntl.m4: New file.
4525 * gnulib/import/m4/fcntl_h.m4: New file.
4526 * gnulib/import/m4/fdopendir.m4: New file.
4527 * gnulib/import/m4/filenamecat.m4: New file.
4528 * gnulib/import/m4/fstat.m4: New file.
4529 * gnulib/import/m4/fstatat.m4: New file.
4530 * gnulib/import/m4/getcwd-abort-bug.m4: New file.
4531 * gnulib/import/m4/getcwd-path-max.m4: New file.
4532 * gnulib/import/m4/getcwd.m4: New file.
4533 * gnulib/import/m4/getdtablesize.m4: New file.
4534 * gnulib/import/m4/getlogin_r.m4: New file.
4535 * gnulib/import/m4/getprogname.m4: New file.
4536 * gnulib/import/m4/glob.m4: New file.
4537 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
4538 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
4539 * gnulib/import/m4/mempcpy.m4: New file.
4540 * gnulib/import/m4/memrchr.m4: New file.
4541 * gnulib/import/m4/mode_t.m4: New file.
4542 * gnulib/import/m4/msvc-inval.m4: New file.
4543 * gnulib/import/m4/msvc-nothrow.m4: New file.
4544 * gnulib/import/m4/open.m4: New file.
4545 * gnulib/import/m4/openat.m4: New file.
4546 * gnulib/import/m4/opendir.m4: New file.
4547 * gnulib/import/m4/readdir.m4: New file.
4548 * gnulib/import/m4/realloc.m4: New file.
4549 * gnulib/import/m4/rewinddir.m4: New file.
4550 * gnulib/import/m4/save-cwd.m4: New file.
4551 * gnulib/import/m4/strdup.m4: New file.
4552 * gnulib/import/m4/strerror.m4: New file.
4553 * gnulib/import/m4/unistd-safer.m4: New file.
4554 * gnulib/import/mempcpy.c: New file.
4555 * gnulib/import/memrchr.c: New file.
4556 * gnulib/import/msvc-inval.c: New file.
4557 * gnulib/import/msvc-inval.h: New file.
4558 * gnulib/import/msvc-nothrow.c: New file.
4559 * gnulib/import/msvc-nothrow.h: New file.
4560 * gnulib/import/open.c: New file.
4561 * gnulib/import/openat-die.c: New file.
4562 * gnulib/import/openat-priv.h: New file.
4563 * gnulib/import/openat-proc.c: New file.
4564 * gnulib/import/openat.c: New file.
4565 * gnulib/import/openat.h: New file.
4566 * gnulib/import/opendir.c: New file.
4567 * gnulib/import/pipe-safer.c: New file.
4568 * gnulib/import/readdir.c: New file.
4569 * gnulib/import/realloc.c: New file.
4570 * gnulib/import/rewinddir.c: New file.
4571 * gnulib/import/save-cwd.c: New file.
4572 * gnulib/import/save-cwd.h: New file.
4573 * gnulib/import/strdup.c: New file.
4574 * gnulib/import/strerror-override.c: New file.
4575 * gnulib/import/strerror-override.h: New file.
4576 * gnulib/import/strerror.c: New file.
4577 * gnulib/import/unistd--.h: New file.
4578 * gnulib/import/unistd-safer.h: New file.
4579 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add
4580 "getcwd" and "glob".
4581 * ser-tcp.c: Undefine "close" before redefining it.
4582
432ae719
SM
45832017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4584
4585 * guile/scm-value.c (gdbscm_value_address): Initialize address,
4586 get rid of res_val.
4587
4fa7574e
RO
45882017-09-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
4589
4590 * configure.nat <i386sol2,i386>: Add fork-inferior.o to NATDEPFILES.
4591 <sol2,sparc>: Likewise.
4592 <sol2-64,i386>: Likewise.
4593
4594 * warning.m4 (AM_GDB_WARNINGS): Disable -Wunknown-pragmas,
4595 -Wdeprecated-declarations on *-*-solaris*.
4596 * configure: Regenerate.
4597
4598 * procfs.c: Include "nat/inferior.h".
4599 (procfs_info_proc): Fix typo.
4600
f6327dcb
KB
46012017-09-21 Kevin Buettner <kevinb@redhat.com>
4602
4603 * remote.c (vector): Include.
4604 (struct private_thread_info): Add field, thread_handle.
4605 (free_private_thread_info): Deallocate storage associated with
4606 thread handle.
4607 (get_private_info_thread): Initialize `thread_handle' field.
4608 (struct thread_item): Add field, thread_handle.
4609 (clear_threads_listing_context): Deallocate storage associated
4610 with thread handle.
4611 (start_thread): Add support for "handle" attribute.
4612 (thread_attributes): Add "handle".
4613 (remote_get_threads_with_qthreadinfo): Initialize thread_handle
4614 field.
4615 (remote_update_thread_list): Update thread_handle.
4616 (remote_thread_handle_to_thread_info): New function.
4617 (init_remote_ops): Initialize to_thread_handle_to_thread_info.
4618
fbbe5337
KB
46192017-09-21 Kevin Buettner <kevinb@redhat.com>
4620
4621 * python/py-inferior.c (gdbpy_thread_from_thread_handle): New
4622 function.
4623 (inferior_object_methods): Add gdbpy_thread_from_thread_handle.
4624 * python/python-internal.h (thread_object_type): Declare.
4625
e04ee09e
KB
46262017-09-21 Kevin Buettner <kevinb@redhat.com>
4627
4628 * target.h (struct target_ops): Add to_thread_handle_to_thread_info.
4629 (target_thread_handle_to_thread_info): Declare.
4630 * target.c (target_thread_handle_to_thread_info): New function.
4631 * target-delegates.c: Regenerate.
4632 * gdbthread.h (find_thread_by_handle): Declare.
4633 * thread.c (find_thread_by_handle): New function.
4634 * linux-thread-db.c (thread_db_thread_handle_to_thread_info): New
4635 function.
4636 (init_thread_db_ops): Register thread_db_thread_handle_to_thread_info.
4637
1e5b66ed
SM
46382017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4639
4640 * nat/linux-waitpid.c (linux_debug): Add ATTRIBUTE_PRINTF.
4641
ebe48ba0
SM
46422017-09-21 Simon Marchi <simon.marchi@ericsson.com>
4643
4644 * microblaze-tdep.c (microblaze_debug): Add ATTRIBUTE_PRINTF.
4645
0a0bf5dc
YQ
46462017-09-21 Yao Qi <yao.qi@linaro.org>
4647
4648 * configure.tgt (aarch64*-*-freebsd*): Add fbsd-tdep.o solib-svr4.o
4649 to gdb_target_obs.
4650
d1b0a7bf
TT
46512017-09-20 Tom Tromey <tom@tromey.com>
4652
4653 * breakpoint.c (struct counted_command_line): Remove.
4654 (breakpoint_commands): Update.
4655 (alloc_counted_command_line, incref_counted_command_line)
4656 (decref_counted_command_line, do_cleanup_counted_command_line)
4657 (make_cleanup_decref_counted_command_line): Remove.
4658 (breakpoint_set_commands, commands_command_1, ~bpstats, bpstats)
4659 (bpstat_clear_actions, bpstat_do_actions_1, watchpoint_check)
4660 (bpstat_stop_status, print_one_breakpoint_location, ~breakpoint)
4661 (save_breakpoints): Update.
4662 * breakpoint.h (counted_command_line): Now a typedef to
4663 shared_ptr.
4664 (struct breakpoint) <commands>: Now a counted_command_line.
4665 (struct bpstats) <command>: Likewise.
4666
48649e1b
TT
46672017-09-20 Tom Tromey <tom@tromey.com>
4668
4669 * breakpoint.c (struct commands_info, do_map_commands_command):
4670 Remove.
4671 (commands_command_1): Update.
4672 (iterate_over_related_breakpoints): Take a function_view.
4673 (do_delete_breakpoint, do_map_delete_breakpoint): Remove.
4674 (delete_command): Update.
4675 (map_breakpoint_numbers): Take a function_view.
4676 (do_disable_breakpoint, do_map_delete_breakpoint): Remove.
4677 (disable_command): Update.
4678 (do_enable_breakpoint, do_map_enable_breakpoint): Remove.
4679 (enable_command): Update.
4680 (struct disp_data, do_enable_breakpoint_disp)
4681 (do_map_enable_once_breakpoint, do_map_enable_count_breakpoint)
4682 (do_map_enable_delete_breakpoint): Remove.
4683 (enable_once_command, enable_count_command, enable_delete_command)
4684 (delete_trace_variable_command): Update.
4685
04afa70c
TT
46862017-09-20 Tom Tromey <tom@tromey.com>
4687
4688 * breakpoint.c (~bpstats): Rename from bpstat_free. Update.
4689 (bpstat_clear): Use delete.
4690 (bpstats): New constructors.
4691 (bpstat_copy, bpstat_stop_status): Use new.
4692 (dprintf_after_condition_true): Update.
4693 * breakpoint.h (bpstats::bpstats): Add constructors.
4694 (bpstats::~bpstats): Add destructor.
4695
c83833f4
PA
46962017-09-20 Pedro Alves <palves@redhat.com>
4697
4698 * eval.c (make_params): Delete, refactored as ...
4699 (class fake_method): ... this new type's ctor.
4700 (fake_method::~fake_method): New.
4701 (evaluate_subexp_standard): Use 'fake_method'.
4702
223ffa71
TT
47032017-09-20 Tom Tromey <tom@tromey.com>
4704
4705 * windows-nat.c (get_windows_debug_event, windows_wait)
4706 (do_initial_windows_stuff, windows_attach): Update.
4707 * utils.c (vwarning, internal_vproblem): Update.
4708 (ui_unregister_input_event_handler_cleanup)
4709 (prepare_to_handle_input): Remove.
4710 (class scoped_input_handler): New.
4711 (defaulted_query, prompt_for_continue): Update.
4712 * tui/tui-hooks.c (tui_refresh_frame_and_register_information):
4713 Update.
4714 * top.c (undo_terminal_modifications_before_exit): Update.
4715 * target/target.h (target_terminal_init, target_terminal_inferior)
4716 (target_terminal_ours): Don't declare.
4717 (class target_terminal): New.
4718 * target.h (target_terminal_is_inferior, target_terminal_is_ours)
4719 (target_terminal_ours_for_output)
4720 (make_cleanup_restore_target_terminal): Don't declare.
4721 (target_terminal_info): Remove.
4722 * target.c (enum terminal_state, terminal_state): Remove.
4723 (target_terminal::terminal_state): Define.
4724 (target_terminal::init): Rename from target_terminal_init.
4725 (target_terminal::inferior): Rename from
4726 target_terminal_inferior.
4727 (target_terminal::ours): Rename from target_terminal_ours.
4728 (target_terminal::ours_for_output): Rename from
4729 target_terminal_ours_for_output.
4730 (target_terminal::info): New method.
4731 (cleanup_restore_target_terminal)
4732 (make_cleanup_restore_target_terminal): Remove.
4733 * solib.c (handle_solib_event): Update.
4734 * remote.c (remote_serial_quit_handler): Update.
4735 (remote_terminal_inferior, remote_wait_as): Update.
4736 * record-full.c (record_full_wait_1): Update.
4737 * nto-procfs.c (procfs_create_inferior): Update.
4738 * nat/fork-inferior.c (startup_inferior): Update.
4739 * mi/mi-interp.c (mi_new_thread, mi_thread_exit)
4740 (mi_record_changed, mi_inferior_added, mi_inferior_appeared)
4741 (mi_inferior_exit, mi_inferior_removed, mi_traceframe_changed)
4742 (mi_tsv_created, mi_tsv_deleted, mi_tsv_modified)
4743 (mi_breakpoint_created, mi_breakpoint_deleted)
4744 (mi_breakpoint_modified, mi_on_resume, mi_solib_loaded)
4745 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
4746 (mi_user_selected_context_changed, report_initial_inferior):
4747 Update.
4748 * linux-nat.c (linux_nat_attach, linux_nat_terminal_ours)
4749 (linux_nat_terminal_inferior): Update.
4750 * infrun.c (follow_fork_inferior)
4751 (handle_vfork_child_exec_or_exit, do_target_resume)
4752 (check_curr_ui_sync_execution_done, handle_inferior_event_1)
4753 (handle_signal_stop, maybe_remove_breakpoints, normal_stop):
4754 Update.
4755 * inflow.c (child_terminal_init, info_terminal_command): Update.
4756 * infcmd.c (post_create_inferior, continue_1, prepare_one_step)
4757 (attach_command): Update.
4758 * infcall.c (call_thread_fsm_should_stop): Update.
4759 * gnu-nat.c (gnu_attach): Update.
4760 * extension.c (struct active_ext_lang_state)
4761 (restore_active_ext_lang): Update.
4762 * exceptions.c (print_flush): Update.
4763 * event-top.c (async_enable_stdin, default_quit_handler): Update.
4764 (struct quit_handler_cleanup_data, restore_quit_handler)
4765 (restore_quit_handler_dtor, make_cleanup_override_quit_handler):
4766 Remove.
4767 * cp-support.c (gdb_demangle): Update.
4768 * breakpoint.c (update_inserted_breakpoint_locations)
4769 (insert_breakpoint_locations, handle_jit_event)
4770 (disable_breakpoints_in_unloaded_shlib): Update.
4771 * annotate.c (annotate_breakpoints_invalid)
4772 (annotate_frames_invalid): Update.
4773
013af3fc
TT
47742017-09-20 Tom Tromey <tom@tromey.com>
4775
4776 * main.c (catch_command_errors): Rename from
4777 catch_command_errors_const.
4778 (captured_main_1): Update.
4779
06871ae8
PA
47802017-09-20 Pedro Alves <palves@redhat.com>
4781
4782 * cli/cli-cmds.c (list_command): Use print_sal_location.
4783 (print_sal_location): New function.
4784 (ambiguous_line_spec): Use print_sal_location.
4785 * linespec.c (symbol_to_sal): Record the symbol in the sal.
4786 * symtab.c (find_function_start_sal): Likewise.
4787 * symtab.h (symtab_and_line::symbol): New field.
4788
e5f25bc5
PA
47892017-09-20 Pedro Alves <palves@redhat.com>
4790
4791 * linespec.c (minsym_found): Handle non-text minsyms.
4792 (symbol_to_sal): Record a sal.pc for non-block, non-label symbols.
4793
1b7fa39e
WT
47942017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4795
4796 * features/Makefile (i386-avx-mpx-avx512-pku.dat): Add missing
4797 backslash.
4798
37dd0825
WT
47992017-09-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
4800
4801 * gdb.arch/i386-avx512.c (move_zmm_data_to_reg): Use
4802 vmovups instead vmovaps.
4803 (move_zmm_data_to_memory): Use vmovups instead vmovaps.
4804
4e5a4f58
JB
48052017-09-19 John Baldwin <jhb@FreeBSD.org>
4806
4807 * NEWS (Changes since GDB 8.0): Add starti.
4808 * infcmd.c (enum run_break): New.
4809 (run_command_1): Queue pending event for RUN_STOP_AT_FIRST_INSN
4810 case.
4811 (run_command): Use enum run_how.
4812 (start_command): Likewise.
4813 (starti_command): New function.
4814 (RUN_ARGS_HELP): New macro.
4815 (_initialize_infcmd): Use RUN_ARGS_HELP for run and start
4816 commands. Add starti command.
4817
aa70c9f1
YQ
48182017-09-19 Yao Qi <yao.qi@linaro.org>
4819
4820 * Makefile.in (monitor.o): Remove the rule.
4821
d6541620
YQ
48222017-09-19 Yao Qi <yao.qi@linaro.org>
4823
4824 * annotate.h (struct annotate_arg_emitter): Use
4825 DISABLE_COPY_AND_ASSIGN.
4826 * common/refcounted-object.h (refcounted_object): Likewise.
4827 * completer.h (struct completion_result): Likewise.
4828 * dwarf2read.c (struct dwarf2_per_objfile): Likewise.
4829 * filename-seen-cache.h (filename_seen_cache): Likewise.
4830 * gdbcore.h (thread_section_name): Likewise.
4831 * gdb_regex.h (compiled_regex): Likewise.
4832 * gdbthread.h (scoped_restore_current_thread): Likewise.
4833 * inferior.h (scoped_restore_current_inferior): Likewise.
4834 * jit.c (jit_reader): Likewise.
4835 * linespec.h (struct linespec_result): Likewise.
4836 * mi/mi-parse.h (struct mi_parse): Likewise.
4837 * nat/fork-inferior.c (execv_argv): Likewise.
4838 * progspace.h (scoped_restore_current_program_space): Likewise.
4839 * python/python-internal.h (class gdbpy_enter): Likewise.
4840 * regcache.h (regcache): Likewise.
4841 * target-descriptions.c (struct tdesc_reg): Likewise.
4842 (struct tdesc_type): Likewise.
4843 (struct tdesc_feature): Likewise.
4844 * ui-out.h (ui_out_emit_type): Likewise.
4845
0615127c
SM
48462017-09-18 Simon Marchi <simon.marchi@ericsson.com>
4847
4848 * dwarf2expr.c (dwarf_expr_context::execute_stack_op): Remove
4849 label abort_expression.
4850
5e187554
SM
48512017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4852
4853 * common/buffer.c (buffer_xml_printf): Adjust.
4854 * common/xml-utils.c (xml_escape_text): Change return type to
4855 std::string, update code accordingly.
4856 * common/xml-utils.h (xml_escape_text): Change return type to
4857 std::string.
4858 * rs6000-aix-tdep.c (rs6000_aix_shared_library_to_xml): Adjust.
4859 * windows-tdep.c (windows_xfer_shared_library): Adjust.
4860 * unittests/xml-utils-selftests.c (test_xml_escape_text):
4861 Adjust.
4862
c3d7b541
SM
48632017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4864
4865 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add new source file.
4866 (SUBDIR_UNITTESTS_OBS): Add new object file.
4867 * unittests/xml-utils-selftests.c: New file.
4868
1526853e
SM
48692017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4870
4871 * common/selftest.h (selftest): New struct/interface.
4872 (register_test): Add name parameter, add new overload.
4873 (run_tests): Add filter parameter.
4874 (for_each_selftest_ftype): New typedef.
4875 (for_each_selftest): New declaration.
4876 * common/selftest.c (tests): Change type to
4877 map<string, unique_ptr<selftest>>.
4878 (simple_selftest): New struct.
4879 (register_test): New function.
4880 (register_test): Add name parameter and use it.
4881 (run_tests): Add filter parameter and use it. Add prints.
4882 Adjust to vector -> map change.
4883 * aarch64-tdep.c (_initialize_aarch64_tdep): Add names when
4884 registering selftests.
4885 * arm-tdep.c (_initialize_arm_tdep): Likewise.
4886 * disasm-selftests.c (_initialize_disasm_selftests): Likewise.
4887 * dwarf2-frame.c (_initialize_dwarf2_frame): Likewise.
4888 * dwarf2loc.c (_initialize_dwarf2loc): Likewise.
4889 * findvar.c (_initialize_findvar): Likewise.
4890 * gdbarch-selftests.c (_initialize_gdbarch_selftests): Likewise.
4891 * maint.c (maintenance_selftest): Update call to run_tests.
4892 (maintenance_info_selftests): New function.
4893 (_initialize_maint_cmds): Register "maintenance info selftests"
4894 command. Update "maintenance selftest" doc.
4895 * regcache.c (_initialize_regcache): Add names when registering
4896 selftests.
4897 * rust-exp.y (_initialize_rust_exp): Likewise.
4898 * selftest-arch.c (gdbarch_selftest): New struct.
4899 (gdbarch_tests): Remove.
4900 (register_test_foreach_arch): Add name parameter. Call
4901 register_test.
4902 (tests_with_arch): Remove, move most content to
4903 gdbarch_selftest::operator().
4904 (_initialize_selftests_foreach_arch): Remove.
4905 * selftest-arch.h (register_test_foreach_arch): Add name
4906 parameter.
4907 (run_tests_with_arch): New declaration.
4908 * utils-selftests.c (_initialize_utils_selftests): Add names
4909 when registering selftests.
4910 * utils.c (_initialize_utils): Likewise.
4911 * unittests/array-view-selftests.c
4912 (_initialize_array_view_selftests): Likewise.
4913 * unittests/environ-selftests.c (_initialize_environ_selftests):
4914 Likewise.
4915 * unittests/function-view-selftests.c
4916 (_initialize_function_view_selftests): Likewise.
4917 * unittests/offset-type-selftests.c
4918 (_initialize_offset_type_selftests): Likewise.
4919 * unittests/optional-selftests.c
4920 (_initialize_optional_selftests): Likewise.
4921 * unittests/scoped_restore-selftests.c
4922 (_initialize_scoped_restore_selftests): Likewise.
4923 * NEWS: Document "maintenance selftest" and "maint info
4924 selftests".
4925
5846367a
SM
49262017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4927
4928 * mi/mi-main.c (mi_load_progress): Restore current_uiout using a
4929 scoped_restore.
4930
bd77e8ff
SM
49312017-09-16 Simon Marchi <simon.marchi@ericsson.com>
4932
4933 * mi/mi-main.c (mi_load_progress): Make uiout variable
4934 a unique_ptr.
4935
26a67918
PA
49362017-09-15 Pedro Alves <palves@redhat.com>
4937
4938 * compile/compile-c-types.c (convert_enum, convert_int)
4939 (convert_float): Adjust to refer to int_type_v0 and float_type_v0.
4940
3f8a7804
SM
49412017-09-15 Simon Marchi <simon.marchi@ericsson.com>
4942
4943 * dwarf2read.c (copy_string): Remove.
4944 (parse_macro_definition): Replace copy_string with savestring.
4945
8d200706
YQ
49462017-09-15 Yao Qi <yao.qi@linaro.org>
4947
4948 * configure.tgt (i[34567]86-*-darwin*): Append amd64.o to
4949 gdb_target_obs.
4950 (i[34567]86-*-solaris2.1[0-9]* | x86_64-*-solaris2.1[0-9]*):
4951 Likewise.
4952 (i[34567]86-*-linux*): Likewise.
4953
d185219d
SM
49542017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4955
4956 * dwarf2expr.h (dwarf_stack_value): Add constructor.
4957 (dwarf_expr_context) <~dwarf_expr_context>: Define as default.
4958 <stack>: Change type to std::vector.
4959 <stack_len, stack_allocated>: Remove.
4960 <grow_stack>: Remove.
4961 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
4962 (dwarf_expr_context::~dwarf_expr_context): Remove.
4963 (dwarf_expr_context::grow_stack): Remove.
4964 (dwarf_expr_context::push): Adjust.
4965 (dwarf_expr_context::pop): Adjust.
4966 (dwarf_expr_context::fetch): Adjust.
4967 (dwarf_expr_context::fetch_in_stack_memory): Adjust.
4968 (dwarf_expr_context::stack_empty_p): Adjust.
4969 (dwarf_expr_context::execute_stack_op): Adjust.
4970
eccd80d6
SM
49712017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4972
4973 * dwarf2expr.h (dwarf_expr_context) <stack_empty_p>: Change
4974 return type to bool.
4975 * dwarf2expr.c (dwarf_expr_context::stack_empty_p): Likewise.
4976
69009882
SM
49772017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4978
4979 * dwarf2expr.h (dwarf_expr_piece) <v.mem.in_stack_memory>:
4980 Change type to bool.
4981 (dwarf_stack_value) <in_stack_memory>: Likewise.
4982 (dwarf_expr_context) <push_address>: Change parameter type to
4983 bool.
4984 <fetch_in_stack_memory>: Change return type to bool.
4985 <push>: Change parameter type to bool.
4986 * dwarf2expr.c (dwarf_expr_context::push): Change parameter type
4987 to bool.
4988 (dwarf_expr_context::push_address): Likewise.
4989 (dwarf_expr_context::fetch_in_stack_memory): Change return type
4990 to bool.
4991 (dwarf_expr_context::execute_stack_op): Adjust.
4992 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Adjust.
4993
1e467161
SM
49942017-09-14 Simon Marchi <simon.marchi@ericsson.com>
4995
4996 * dwarf2expr.h (struct dwarf_expr_piece): Move up.
4997 (struct dwarf_expr_context) <n_pieces>: Remove.
4998 <pieces>: Change type to std::vector.
4999 * dwarf2expr.c (dwarf_expr_context::dwarf_expr_context): Adjust.
5000 (dwarf_expr_context::~dwarf_expr_context): Don't manually free
5001 pieces.
5002 (dwarf_expr_context::add_piece): Adjust.
5003 * dwarf2loc.c (struct piece_closure): Initialize fields.
5004 <n_pieces>: Remove.
5005 <pieces>: Change type to std::vector.
5006 (allocate_piece_closure): Adjust, change parameter to
5007 std::vector rvalue and std::move it to piece_closure.
5008 (rw_pieced_value): Adjust.
5009 (check_pieced_synthetic_pointer): Adjust.
5010 (indirect_synthetic_pointer): Adjust.
5011 (coerce_pieced_ref): Adjust.
5012 (free_pieced_value_closure): Adjust. Use delete to free
5013 piece_closure.
5014 (dwarf2_evaluate_loc_desc_full): Adjust. std::move ctx.pieces
5015 to allocate_piece_closure.
5016 (dwarf2_loc_desc_get_symbol_read_needs): Adjust.
5017
0782db84
SM
50182017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5019
5020 * probe.h (probe_ops_cp): Remove typedef.
5021 (DEF_VEC_P (probe_ops_cp)): Remove.
5022 (all_probe_ops): Change type to std::vector.
5023 * probe.c (info_probes_for_ops): Adjust to vector change.
5024 (probe_linespec_to_ops): Likewise.
5025 (all_probe_ops): Change type to std::vector.
5026 (_initialize_probe): Adjust to vector change.
5027 * dtrace-probe.c (_initialize_dtrace_probe): Likewise.
5028 * elfread.c (elf_get_probes): Likewise.
5029 * stap-probe.c (_initialize_stap_probe): Likewise.
5030
1eac6bea
SM
50312017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5032
5033 * probe.h (struct bound_probe): Define constructors.
5034 * probe.c (bound_probe_s): Remove typedef.
5035 (DEF_VEC_O (bound_probe_s)): Remove VEC.
5036 (collect_probes): Change return type to std::vector, remove
5037 cleanup.
5038 (compare_probes): Return bool, change parameter type. Change
5039 semantic to "less than".
5040 (gen_ui_out_table_header_info): Change parameter to std::vector
5041 and update.
5042 (exists_probe_with_pops): Likewise.
5043 (info_probes_for_ops): Update to std::vector change.
5044 (enable_probes_command): Likewise.
5045 (disable_probes_command): Likewise.
5046
aaa63a31
SM
50472017-09-12 Simon Marchi <simon.marchi@ericsson.com>
5048
5049 * probe.h (struct probe_ops) <get_probes>: Change parameter from
5050 vec to std::vector.
5051 * probe.c (parse_probes_in_pspace): Update.
5052 (find_probes_in_objfile): Update.
5053 (find_probe_by_pc): Update.
5054 (collect_probes): Update.
5055 (probe_any_get_probes): Update.
5056 * symfile.h (struct sym_probe_fns) <sym_get_probes> Change
5057 return type to reference to std::vector.
5058 * dtrace-probe.c (dtrace_process_dof_probe): Change parameter to
5059 std::vector and update.
5060 (dtrace_process_dof): Likewise.
5061 (dtrace_get_probes): Likewise.
5062 * elfread.c (elf_get_probes): Change return type to std::vector,
5063 store an std::vector in bfd_data.
5064 (probe_key_free): Update to std::vector.
5065 * stap-probe.c (handle_stap_probe): Change parameter to
5066 std::vector and update.
5067 (stap_get_probes): Likewise.
5068 * symfile-debug.c (debug_sym_get_probes): Change return type to
5069 std::vector and update.
5070
cb85b21b
TT
50712017-09-11 Tom Tromey <tom@tromey.com>
5072
5073 * breakpoint.c (program_breakpoint_here_p): Update.
5074 * target.c (make_scoped_restore_show_memory_breakpoints): Rename
5075 from make_show_memory_breakpoints_cleanup. Return a
5076 scoped_restore_tmpl<int>.
5077 (restore_show_memory_breakpoints): Remove.
5078 * ppc-linux-tdep.c (ppc_linux_memory_remove_breakpoint): Update.
5079 * mem-break.c (memory_validate_breakpoint): Update.
5080 * ia64-tdep.c (ia64_memory_insert_breakpoint): Update.
5081 (ia64_memory_remove_breakpoint): Update.
5082 (ia64_breakpoint_from_pc): Update.
5083 * target.h (make_scoped_restore_show_memory_breakpoints): Rename
5084 from make_show_memory_breakpoints_cleanup.
5085
8fbc99ef
TT
50862017-09-11 Tom Tromey <tom@tromey.com>
5087
5088 * d-namespace.c (d_lookup_symbol): Use std::string.
5089 (find_symbol_in_baseclass): Likewise.
5090
50feb4bd
TT
50912017-09-11 Tom Tromey <tom@tromey.com>
5092
5093 * ctf.c (ctf_start): Use std::string.
5094
c6dc63a1
TT
50952017-09-11 Tom Tromey <tom@tromey.com>
5096
5097 * ada-lang.c (is_known_support_routine): Update.
5098 (ada_unhandled_exception_name_addr_from_raise): Update.
5099 * guile/scm-frame.c (gdbscm_frame_name): Update.
5100 * python/py-frame.c (frapy_name): Update.
5101 (frapy_function): Update.
5102 * stack.h (find_frame_funname): Update.
5103 * stack.c (find_frame_funname): Return unique_xmalloc_ptr.
5104 (print_frame): Update.
5105
d6b9b80f
TT
51062017-09-11 Tom Tromey <tom@tromey.com>
5107
5108 * findcmd.c (put_bits): Take a gdb::byte_vector.
5109 (parse_find_args): Return gdb::byte_vector. "args" now const.
5110 Remove "pattern_bufp" and "pattern_lenp" parameters. Remove
5111 cleanups.
5112 (find_command): Update.
5113
a9921622
TT
51142017-09-11 Tom Tromey <tom@tromey.com>
5115
5116 * cli/cli-script.c (class scoped_restore_hook_in): New.
5117 (clear_hook_in_cleanup): Remove.
5118 (execute_cmd_pre_hook, execute_cmd_post_hook): Use
5119 scoped_restore_hook_in.
5120
be0d7abb
TT
51212017-09-11 Tom Tromey <tom@tromey.com>
5122
5123 * cli/cli-script.c (restore_interp): Remove.
5124 (read_command_lines): Use scoped_restore_interp.
5125 * interps.c (scoped_restore_interp::set_temp): Rename from
5126 interp_set_temp.
5127 * interps.h (class scoped_restore_interp): New.
5128 (interp_set_temp): Remove.
5129
00f675ff
TT
51302017-09-11 Tom Tromey <tom@tromey.com>
5131
5132 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
5133 (mi_cmd_catch_exception, mi_catch_load_unload): Update.
5134 * mi/mi-cmd-break.c (setup_breakpoint_reporting): Return a
5135 scoped_restore.
5136 (mi_cmd_break_insert_1): Update.
5137 * mi/mi-cmd-break.h (setup_breakpoint_reporting): Return a
5138 scoped_restore.
5139
cb791d59
TT
51402017-09-11 Tom Tromey <tom@tromey.com>
5141
5142 * demangle.c (demangle_command): Update.
5143 * breakpoint.c (disable_command): Update.
5144 (enable_command): Update.
5145 (find_location_by_number): Make "number" const. Use
5146 get_number_trailer.
5147 * cli/cli-utils.c (extract_arg): Return std::string.
5148 * probe.c (parse_probe_linespec): Update. Change types.
5149 (collect_probes): Take string arguments.
5150 (parse_probe_linespec): Likewise.
5151 (info_probes_for_ops): Update.
5152 (enable_probes_command): Update.
5153 (disable_probes_command): Update.
5154 * break-catch-sig.c (catch_signal_split_args): Update.
5155 * mi/mi-parse.c (mi_parse): Update.
5156
2039bd9f
TT
51572017-09-11 Tom Tromey <tom@tromey.com>
5158
5159 * language.h (language_enum): Make argument const.
5160 * language.c (language_enum): Make argument const.
5161
f1735a53
TT
51622017-09-11 Tom Tromey <tom@tromey.com>
5163
5164 * common/common-utils.h (skip_to_space): Remove macro, redeclare
5165 as function.
5166 (skip_to_space): Rename from skip_to_space_const.
5167 * common/common-utils.c (skip_to_space): New function.
5168 (skip_to_space): Rename from skip_to_space_const.
5169 * cli/cli-utils.h (get_number): Rename from get_number_const.
5170 (extract_arg): Rename from extract_arg_const.
5171 * cli/cli-utils.c (get_number): Rename from get_number_const.
5172 (extract_arg): Rename from extract_arg_const.
5173 (number_or_range_parser::get_number): Use ::get_number.
5174 * aarch64-linux-tdep.c, ada-lang.c, arm-linux-tdep.c, ax-gdb.c,
5175 break-catch-throw.c, breakpoint.c, cli/cli-cmds.c, cli/cli-dump.c,
5176 cli/cli-script.c, cli/cli-setshow.c, compile/compile.c,
5177 completer.c, demangle.c, disasm.c, findcmd.c, linespec.c,
5178 linux-tdep.c, linux-thread-db.c, location.c, mi/mi-parse.c,
5179 minsyms.c, nat/linux-procfs.c, printcmd.c, probe.c,
5180 python/py-breakpoint.c, record.c, rust-exp.y, serial.c, stack.c,
5181 stap-probe.c, tid-parse.c, tracepoint.c: Update all callers.
5182
7d221d74
TT
51832017-09-11 Tom Tromey <tom@tromey.com>
5184
5185 * python/python.c (do_start_initialization): Use
5186 py-event-types.def to initialize types.
5187 Define all object type structures.
5188 * python/python-internal.h: Don't declare event initialization
5189 functions.
5190 * python/py-threadevent.c (thread_event_object_type): Don't
5191 define.
5192 * python/py-stopevent.c (stop_event_object_type): Don't define.
5193 * python/py-signalevent.c (signal_event_object_type): Don't
5194 declare or define.
5195 * python/py-newobjfileevent.c (new_objfile_event_object_type)
5196 (clear_objfiles_event_object_type): Don't declare or define.
5197 * python/py-infevents.c (inferior_call_pre_event_object_type)
5198 (inferior_call_post_event_object_type)
5199 (register_changed_event_object_type)
5200 (memory_changed_event_object_type): Don't declare or define.
5201 * python/py-inferior.c (new_thread_event_object_type)
5202 (new_inferior_event_object_type)
5203 (inferior_deleted_event_object_type): Don't declare or define.
5204 * python/py-exitedevent.c (exited_event_object_type): Don't
5205 declare or define.
5206 * python/py-evts.c (gdbpy_initialize_py_events): Use
5207 py-all-events.def.
5208 * python/py-events.h (thread_event_object_type): Don't declare.
5209 (events_object): Use py-all-events.def.
5210 * python/py-event.h (GDBPY_NEW_EVENT_TYPE): Remove. Use
5211 py-event-types.def.
5212 * python/py-event-types.def: New file.
5213 * python/py-continueevent.c (create_continue_event_object): Don't
5214 declare or define.
5215 * python/py-bpevent.c (breakpoint_event_object_type): Don't
5216 declare or define.
5217 * python/py-all-events.def: New file.
5218
35c61a1d
TT
52192017-09-11 Tom Tromey <tom@tromey.com>
5220
5221 * python/py-threadevent.c (create_thread_event_object): Return
5222 gdbpy_ref.
5223 * python/py-stopevent.h (create_stop_event_object)
5224 (create_breakpoint_event_object, create_signal_event_object):
5225 Update.
5226 * python/py-stopevent.c (create_stop_event_object): Return
5227 gdbpy_ref.
5228 (emit_stop_event): Update.
5229 * python/py-signalevent.c (create_signal_event_object): Return
5230 gdbpy_ref.
5231 * python/py-infevents.c (create_inferior_call_event_object):
5232 Update.
5233 * python/py-event.h (create_event_object)
5234 (create_thread_event_object): Update.
5235 * python/py-event.c (create_event_object): Return gdbpy_ref.
5236 * python/py-continueevent.c: Return gdbpy_ref.
5237 * python/py-bpevent.c (create_breakpoint_event_object): Return
5238 gdbpy_ref.
5239
7c96f8c1
TT
52402017-09-11 Tom Tromey <tom@tromey.com>
5241
5242 PR python/15622:
5243 * NEWS: Add entry.
5244 * python/python.c (do_start_initialization): Initialize new event
5245 types.
5246 * python/python-internal.h (gdbpy_initialize_new_inferior_event)
5247 (gdbpy_initialize_inferior_deleted_event)
5248 (gdbpy_initialize_new_thread_event): Declare.
5249 * python/py-threadevent.c (create_thread_event_object): Add option
5250 "thread" parameter.
5251 * python/py-inferior.c (new_thread_event_object_type)
5252 (new_inferior_event_object_type)
5253 (inferior_deleted_event_object_type): Declare.
5254 (python_new_inferior, python_inferior_deleted): New functions.
5255 (add_thread_object): Emit new_thread event.
5256 (gdbpy_initialize_inferior): Attach new functions to corresponding
5257 observers.
5258 (new_thread, new_inferior, inferior_deleted): Define new event
5259 types.
5260 * python/py-evts.c (gdbpy_initialize_py_events): Add new
5261 registries.
5262 * python/py-events.h (events_object) <new_inferior,
5263 inferior_deleted, new_thread>: New fields.
5264 * python/py-event.h (create_thread_event_breakpoint): Add optional
5265 "thread" parameter.
5266
72542b8e
AB
52672017-09-10 Andrew Burgess <andrew.burgess@embecosm.com>
5268
5269 * utils.c (abort_with_message): Don't compare gdb_stderr to NULL,
5270 check current_ui instead.
5271 (internal_vproblem): Likewise.
5272
0d64823e
SM
52732017-09-09 Simon Marchi <simon.marchi@ericsson.com>
5274
5275 * thread.c (print_thread_info_1): Remove unnecessary calls to
5276 uiout->is_mi_like_p.
5277
eb1e02fd
TT
52782017-09-09 Tom Tromey <tom@tromey.com>
5279
5280 * namespace.h (add_using_directive): Update.
5281 * namespace.c (add_using_directive): Change type of excludes to
5282 std::vector.
5283 * dwarf2read.c (read_import_statement): Use std::vector.
5284 (read_namespace): Update.
5285 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
5286
0fc21fd8
TT
52872017-09-09 Tom Tromey <tom@tromey.com>
5288
5289 * linespec.c (create_sals_line_offset): Use gdb::def_vector.
5290
49663d05
TT
52912017-09-09 Tom Tromey <tom@tromey.com>
5292
5293 * p-valprint.c (pascal_object_print_value): Use gdb::byte_vector.
5294
0b868b60
TT
52952017-09-09 Tom Tromey <tom@tromey.com>
5296
5297 * stack.c (func_command): Use gdb::def_vector.
5298
c0470d48
TT
52992017-09-09 Tom Tromey <tom@tromey.com>
5300
5301 * mi/mi-cmd-var.c (mi_cmd_var_list_children): Use gdb::optional,
5302 ui_out_emit_list, ui_out_emit_tuple.
5303 (mi_cmd_var_update): Likewise.
5304
ca5909c7
TT
53052017-09-09 Tom Tromey <tom@tromey.com>
5306
5307 * mi/mi-interp.c (mi_user_selected_context_changed): Use
5308 ui_out_redirect_pop.
5309 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
5310 ui_out_redirect_pop.
5311 * utils.c (do_ui_out_redirect_pop)
5312 (make_cleanup_ui_out_redirect_pop): Remove.
5313 * top.c (execute_command_to_string): Use ui_out_redirect_pop.
5314 * utils.h (make_cleanup_ui_out_redirect_pop): Remove.
5315 * ui-out.h (ui_out_redirect_pop): New class.
5316
e6a2252a
TT
53172017-09-09 Tom Tromey <tom@tromey.com>
5318
5319 * mi/mi-main.c (output_cores): Use ui_out_emit_list.
5320 (list_available_thread_groups, mi_cmd_list_thread_groups)
5321 (mi_cmd_data_list_changed_registers, mi_cmd_data_read_memory)
5322 (mi_cmd_data_read_memory_bytes, mi_cmd_trace_frame_collected):
5323 Likewise.
5324
393702cd
TT
53252017-09-09 Tom Tromey <tom@tromey.com>
5326
5327 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn): Use
5328 ui_out_emit_tuple.
5329
76f9c9cf
TT
53302017-09-09 Tom Tromey <tom@tromey.com>
5331
5332 * target.c (flash_erase_command): Use ui_out_emit_tuple.
5333 * stack.c (print_frame): Use ui_out_emit_tuple.
5334 * spu-tdep.c (info_spu_event_command): Use ui_out_emit_tuple.
5335 (info_spu_mailbox_command, info_spu_dma_command)
5336 (info_spu_proxydma_command): Likewise.
5337 * mi/mi-main.c (mi_cmd_trace_frame_collected): Use
5338 ui_out_emit_tuple, gdb::byte_vector, bin2hex.
5339 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
5340 ui_out_emit_tuple.
5341 * breakpoint.c (print_it_watchpoint): Use ui_out_emit_tuple.
5342
dc9fe180
TT
53432017-09-09 Tom Tromey <tom@tromey.com>
5344
5345 * ui-out.h (make_cleanup_ui_out_table_begin_end): Remove.
5346 (class ui_out_emit_table): Update comment.
5347 * ui-out.c (do_cleanup_table_end)
5348 (make_cleanup_ui_out_table_begin_end): Remove.
5349 * spu-tdep.c (info_spu_mailbox_list): Use ui_out_emit_table.
5350 (info_spu_dma_cmdlist): Likewise.
5351 * probe.c (info_probes_for_ops): Use ui_out_emit_table.
5352 * darwin-nat-info.c (darwin_debug_regions_recurse): Use
5353 ui_out_emit_table.
5354
f8cc3da6
TT
53552017-09-09 Tom Tromey <tom@tromey.com>
5356
5357 * thread.c (print_thread_info_1): Use ui_out_emit_table,
5358 ui_out_emit_list, gdb::optional.
5359
481695ed
JB
53602017-09-09 John Baldwin <jhb@FreeBSD.org>
5361
5362 * aarch64-linux-nat.c: Remove _initialize_aarch64_linux_nat
5363 prototype.
5364 * aarch64-linux-tdep.c: Remove _initialize_aarch64_linux_tdep
5365 prototype.
5366 * aarch64-newlib-tdep.c: Remove _initialize_aarch64_newlib_tdep
5367 prototype.
5368 * aarch64-tdep.c: Remove _initialize_aarch64_tdep prototype.
5369 * ada-exp.y: Remove _initialize_ada_exp prototype.
5370 * ada-lang.c: Remove _initialize_ada_language prototype.
5371 * ada-tasks.c: Remove _initialize_tasks prototype.
5372 * addrmap.c: Remove _initialize_addrmap prototype.
5373 * agent.c: Remove _initialize_agent prototype.
5374 * aix-thread.c: Remove _initialize_aix_thread prototype.
5375 * alpha-bsd-nat.c: Remove _initialize_alphabsd_nat prototype.
5376 * alpha-linux-nat.c: Remove _initialize_alpha_linux_nat prototype.
5377 * alpha-linux-tdep.c: Remove _initialize_alpha_linux_tdep
5378 prototype.
5379 * alpha-nbsd-tdep.c: Remove _initialize_alphanbsd_tdep prototype.
5380 * alpha-obsd-tdep.c: Remove _initialize_alphaobsd_tdep prototype.
5381 * alpha-tdep.c: Remove _initialize_alpha_tdep prototype.
5382 * amd64-darwin-tdep.c: Remove _initialize_amd64_darwin_tdep
5383 prototype.
5384 * amd64-dicos-tdep.c: Remove _initialize_amd64_dicos_tdep
5385 prototype.
5386 * amd64-fbsd-nat.c: Remove _initialize_amd64fbsd_nat prototype.
5387 * amd64-fbsd-tdep.c: Remove _initialize_amd64fbsd_tdep prototype.
5388 * amd64-linux-nat.c: Remove _initialize_amd64_linux_nat prototype.
5389 * amd64-linux-tdep.c: Remove _initialize_amd64_linux_tdep
5390 prototype.
5391 * amd64-nbsd-nat.c: Remove _initialize_amd64nbsd_nat prototype.
5392 * amd64-nbsd-tdep.c: Remove _initialize_amd64nbsd_tdep prototype.
5393 * amd64-obsd-nat.c: Remove _initialize_amd64obsd_nat prototype.
5394 * amd64-obsd-tdep.c: Remove _initialize_amd64obsd_tdep prototype.
5395 * amd64-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5396 * amd64-tdep.c: Remove _initialize_amd64_tdep prototype.
5397 * amd64-windows-nat.c: Remove _initialize_amd64_windows_nat
5398 prototype.
5399 * amd64-windows-tdep.c: Remove _initialize_amd64_windows_tdep
5400 prototype.
5401 * annotate.c: Remove _initialize_annotate prototype.
5402 * arc-newlib-tdep.c: Remove _initialize_arc_newlib_tdep prototype.
5403 * arc-tdep.c: Remove _initialize_arc_tdep prototype.
5404 * arch-utils.c: Remove _initialize_gdbarch_utils prototype.
5405 * arm-linux-nat.c: Remove _initialize_arm_linux_nat prototype.
5406 * arm-linux-tdep.c: Remove _initialize_arm_linux_tdep prototype.
5407 * arm-nbsd-tdep.c: Remove _initialize_arm_netbsd_tdep prototype.
5408 * arm-obsd-tdep.c: Remove _initialize_armobsd_tdep prototype.
5409 * arm-symbian-tdep.c: Remove _initialize_arm_symbian_tdep
5410 prototype.
5411 * arm-tdep.c: Remove _initialize_arm_tdep prototype.
5412 * arm-wince-tdep.c: Remove _initialize_arm_wince_tdep prototype.
5413 * auto-load.c: Remove _initialize_auto_load prototype.
5414 * auxv.c: Remove _initialize_auxv prototype.
5415 * avr-tdep.c: Remove _initialize_avr_tdep prototype.
5416 * ax-gdb.c: Remove _initialize_ax_gdb prototype.
5417 * bfin-linux-tdep.c: Remove _initialize_bfin_linux_tdep prototype.
5418 * bfin-tdep.c: Remove _initialize_bfin_tdep prototype.
5419 * break-catch-sig.c: Remove _initialize_break_catch_sig prototype.
5420 * break-catch-syscall.c: Remove _initialize_break_catch_syscall
5421 prototype.
5422 * break-catch-throw.c: Remove _initialize_break_catch_throw
5423 prototype.
5424 * breakpoint.c: Remove _initialize_breakpoint prototype.
5425 * bsd-uthread.c: Remove _initialize_bsd_uthread prototype.
5426 * btrace.c: Remove _initialize_btrace prototype.
5427 * charset.c: Remove _initialize_charset prototype.
5428 * cli/cli-cmds.c: Remove _initialize_cli_cmds prototype.
5429 * cli/cli-dump.c: Remove _initialize_cli_dump prototype.
5430 * cli/cli-interp.c: Remove _initialize_cli_interp prototype.
5431 * cli/cli-logging.c: Remove _initialize_cli_logging prototype.
5432 * cli/cli-script.c: Remove _initialize_cli_script prototype.
5433 * coff-pe-read.c: Remove _initialize_coff_pe_read prototype.
5434 * coffread.c: Remove _initialize_coffread prototype.
5435 * compile/compile.c: Remove _initialize_compile prototype.
5436 * complaints.c: Remove _initialize_complaints prototype.
5437 * completer.c: Remove _initialize_completer prototype.
5438 * copying.awk: Remove _initialize_copying prototype.
5439 * copying.c: Regenerate.
5440 * core-regset.c: Remove _initialize_core_regset prototype.
5441 * corefile.c: Remove _initialize_core prototype.
5442 * corelow.c: Remove _initialize_corelow prototype.
5443 * cp-abi.c: Remove _initialize_cp_abi prototype.
5444 * cp-namespace.c: Remove _initialize_cp_namespace prototype.
5445 * cp-support.c: Remove _initialize_cp_support prototype.
5446 * cp-valprint.c: Remove _initialize_cp_valprint prototype.
5447 * cris-linux-tdep.c: Remove _initialize_cris_linux_tdep prototype.
5448 * cris-tdep.c: Remove _initialize_cris_tdep prototype.
5449 * ctf.c: Remove _initialize_ctf prototype.
5450 * d-lang.c: Remove _initialize_d_language prototype.
5451 * darwin-nat-info.c: Remove _initialize_darwin_info_commands
5452 prototype.
5453 * darwin-nat.c: Remove _initialize_darwin_inferior prototype.
5454 * dbxread.c: Remove _initialize_dbxread prototype.
5455 * dcache.c: Remove _initialize_dcache prototype.
5456 * demangle.c: Remove _initialize_demangler prototype.
5457 * disasm-selftests.c: Remove _initialize_disasm_selftests
5458 prototype.
5459 * disasm.c: Remove _initialize_disasm prototype.
5460 * dtrace-probe.c: Remove _initialize_dtrace_probe prototype.
5461 * dummy-frame.c: Remove _initialize_dummy_frame prototype.
5462 * dwarf2-frame-tailcall.c: Remove _initialize_tailcall_frame
5463 prototype.
5464 * dwarf2-frame.c: Remove _initialize_dwarf2_frame prototype.
5465 * dwarf2expr.c: Remove _initialize_dwarf2expr prototype.
5466 * dwarf2loc.c: Remove _initialize_dwarf2loc prototype.
5467 * dwarf2read.c: Remove _initialize_dwarf2_read prototype.
5468 * elfread.c: Remove _initialize_elfread prototype.
5469 * exec.c: Remove _initialize_exec prototype.
5470 * extension.c: Remove _initialize_extension prototype.
5471 * f-lang.c: Remove _initialize_f_language prototype.
5472 * f-valprint.c: Remove _initialize_f_valprint prototype.
5473 * fbsd-nat.c: Remove _initialize_fbsd_nat prototype.
5474 * fbsd-tdep.c: Remove _initialize_fbsd_tdep prototype.
5475 * filesystem.c: Remove _initialize_filesystem prototype.
5476 * findcmd.c: Remove _initialize_mem_search prototype.
5477 * fork-child.c: Remove _initialize_fork_child prototype.
5478 * frame-base.c: Remove _initialize_frame_base prototype.
5479 * frame-unwind.c: Remove _initialize_frame_unwind prototype.
5480 * frame.c: Remove _initialize_frame prototype.
5481 * frv-linux-tdep.c: Remove _initialize_frv_linux_tdep prototype.
5482 * frv-tdep.c: Remove _initialize_frv_tdep prototype.
5483 * ft32-tdep.c: Remove _initialize_ft32_tdep prototype.
5484 * gcore.c: Remove _initialize_gcore prototype.
5485 * gdb_bfd.c: Remove _initialize_gdb_bfd prototype.
5486 * gdbarch.c: Regenerate.
5487 * gdbarch.sh: Remove _initialize_gdbarch prototype.
5488 * gdbtypes.c: Remove _initialize_gdbtypes prototype.
5489 * gnu-nat.c: Remove _initialize_gnu_nat prototype.
5490 * gnu-v2-abi.c: Remove _initialize_gnu_v2_abi prototype.
5491 * gnu-v3-abi.c: Remove _initialize_gnu_v3_abi prototype.
5492 * go-lang.c: Remove _initialize_go_language prototype.
5493 * go32-nat.c: Remove _initialize_go32_nat prototype.
5494 * guile/guile.c: Remove _initialize_guile prototype.
5495 * h8300-tdep.c: Remove _initialize_h8300_tdep prototype.
5496 * hppa-linux-nat.c: Remove _initialize_hppa_linux_nat prototype.
5497 * hppa-linux-tdep.c: Remove _initialize_hppa_linux_tdep prototype.
5498 * hppa-nbsd-nat.c: Remove _initialize_hppanbsd_nat prototype.
5499 * hppa-nbsd-tdep.c: Remove _initialize_hppanbsd_tdep prototype.
5500 * hppa-obsd-nat.c: Remove _initialize_hppaobsd_nat prototype.
5501 * hppa-obsd-tdep.c: Remove _initialize_hppaobsd_tdep prototype.
5502 * hppa-tdep.c: Remove _initialize_hppa_tdep prototype.
5503 * i386-bsd-nat.c: Remove _initialize_i386bsd_nat prototype.
5504 * i386-cygwin-tdep.c: Remove _initialize_i386_cygwin_tdep
5505 prototype.
5506 * i386-darwin-tdep.c: Remove _initialize_i386_darwin_tdep
5507 prototype.
5508 * i386-dicos-tdep.c: Remove _initialize_i386_dicos_tdep prototype.
5509 * i386-fbsd-nat.c: Remove _initialize_i386fbsd_nat prototype.
5510 * i386-fbsd-tdep.c: Remove _initialize_i386fbsd_tdep prototype.
5511 * i386-gnu-nat.c: Remove _initialize_i386gnu_nat prototype.
5512 * i386-gnu-tdep.c: Remove _initialize_i386gnu_tdep prototype.
5513 * i386-linux-nat.c: Remove _initialize_i386_linux_nat prototype.
5514 * i386-linux-tdep.c: Remove _initialize_i386_linux_tdep prototype.
5515 * i386-nbsd-nat.c: Remove _initialize_i386nbsd_nat prototype.
5516 * i386-nbsd-tdep.c: Remove _initialize_i386nbsd_tdep prototype.
5517 * i386-nto-tdep.c: Remove _initialize_i386nto_tdep prototype.
5518 * i386-obsd-nat.c: Remove _initialize_i386obsd_nat prototype.
5519 * i386-obsd-tdep.c: Remove _initialize_i386obsd_tdep prototype.
5520 * i386-sol2-nat.c: Remove _initialize_amd64_sol2_nat prototype.
5521 * i386-sol2-tdep.c: Remove _initialize_amd64_sol2_tdep prototype.
5522 * i386-tdep.c: Remove _initialize_i386_tdep prototype.
5523 * i386-windows-nat.c: Remove _initialize_i386_windows_nat
5524 prototype.
5525 * ia64-libunwind-tdep.c: Remove _initialize_libunwind_frame
5526 prototype.
5527 * ia64-linux-nat.c: Remove _initialize_ia64_linux_nat prototype.
5528 * ia64-linux-tdep.c: Remove _initialize_ia64_linux_tdep prototype.
5529 * ia64-tdep.c: Remove _initialize_ia64_tdep prototype.
5530 * ia64-vms-tdep.c: Remove _initialize_ia64_vms_tdep prototype.
5531 * infcall.c: Remove _initialize_infcall prototype.
5532 * infcmd.c: Remove _initialize_infcmd prototype.
5533 * inferior.c: Remove _initialize_inferiors prototype.
5534 * inflow.c: Remove _initialize_inflow prototype.
5535 * infrun.c: Remove _initialize_infrun prototype.
5536 * interps.c: Remove _initialize_interpreter prototype.
5537 * iq2000-tdep.c: Remove _initialize_iq2000_tdep prototype.
5538 * jit.c: Remove _initialize_jit prototype.
5539 * language.c: Remove _initialize_language prototype.
5540 * linux-fork.c: Remove _initialize_linux_fork prototype.
5541 * linux-nat.c: Remove _initialize_linux_nat prototype.
5542 * linux-tdep.c: Remove _initialize_linux_tdep prototype.
5543 * linux-thread-db.c: Remove _initialize_thread_db prototype.
5544 * lm32-tdep.c: Remove _initialize_lm32_tdep prototype.
5545 * m2-lang.c: Remove _initialize_m2_language prototype.
5546 * m32c-tdep.c: Remove _initialize_m32c_tdep prototype.
5547 * m32r-linux-nat.c: Remove _initialize_m32r_linux_nat prototype.
5548 * m32r-linux-tdep.c: Remove _initialize_m32r_linux_tdep prototype.
5549 * m32r-tdep.c: Remove _initialize_m32r_tdep prototype.
5550 * m68hc11-tdep.c: Remove _initialize_m68hc11_tdep prototype.
5551 * m68k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5552 * m68k-bsd-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5553 * m68k-linux-nat.c: Remove _initialize_m68k_linux_tdep prototype.
5554 * m68k-linux-tdep.c: Remove _initialize_m68k_linux_tdep prototype.
5555 * m68k-tdep.c: Remove _initialize_m68k_tdep prototype.
5556 * m88k-bsd-nat.c: Remove _initialize_m68kbsd_nat prototype.
5557 * m88k-tdep.c: Remove _initialize_m68kbsd_tdep prototype.
5558 * machoread.c: Remove _initialize_machoread prototype.
5559 * macrocmd.c: Remove _initialize_macrocmd prototype.
5560 * macroscope.c: Remove _initialize_macroscope prototype.
5561 * maint.c: Remove _initialize_maint_cmds prototype.
5562 * mdebugread.c: Remove _initialize_mdebugread prototype.
5563 * memattr.c: Remove _initialize_mem prototype.
5564 * mep-tdep.c: Remove _initialize_mep_tdep prototype.
5565 * mi/mi-cmd-env.c: Remove _initialize_mi_cmd_env prototype.
5566 * mi/mi-cmds.c: Remove _initialize_mi_cmds prototype.
5567 * mi/mi-interp.c: Remove _initialize_mi_interp prototype.
5568 * mi/mi-main.c: Remove _initialize_mi_main prototype.
5569 * microblaze-linux-tdep.c: Remove
5570 _initialize_microblaze_linux_tdep prototype.
5571 * microblaze-tdep.c: Remove _initialize_microblaze_tdep prototype.
5572 * mips-fbsd-nat.c: Remove _initialize_mips_fbsd_nat prototype.
5573 * mips-fbsd-tdep.c: Remove _initialize_mips_fbsd_tdep prototype.
5574 * mips-linux-nat.c: Remove _initialize_mips_linux_nat prototype.
5575 * mips-linux-tdep.c: Remove _initialize_mips_linux_tdep prototype.
5576 * mips-nbsd-nat.c: Remove _initialize_mipsnbsd_nat prototype.
5577 * mips-nbsd-tdep.c: Remove _initialize_mipsnbsd_tdep prototype.
5578 * mips-sde-tdep.c: Remove _initialize_mips_sde_tdep prototype.
5579 * mips-tdep.c: Remove _initialize_mips_tdep prototype.
5580 * mips64-obsd-nat.c: Remove _initialize_mips64obsd_nat prototype.
5581 * mips64-obsd-tdep.c: Remove _initialize_mips64obsd_tdep
5582 prototype.
5583 * mipsread.c: Remove _initialize_mipsread prototype.
5584 * mn10300-linux-tdep.c: Remove _initialize_mn10300_linux_tdep
5585 prototype.
5586 * mn10300-tdep.c: Remove _initialize_mn10300_tdep prototype.
5587 * moxie-tdep.c: Remove _initialize_moxie_tdep prototype.
5588 * msp430-tdep.c: Remove _initialize_msp430_tdep prototype.
5589 * mt-tdep.c: Remove _initialize_mt_tdep prototype.
5590 * nds32-tdep.c: Remove _initialize_nds32_tdep prototype.
5591 * nios2-linux-tdep.c: Remove _initialize_nios2_linux_tdep
5592 prototype.
5593 * nios2-tdep.c: Remove _initialize_nios2_tdep prototype.
5594 * nto-procfs.c: Remove _initialize_procfs prototype.
5595 * nto-tdep.c: Remove _initialize_nto_tdep prototype.
5596 * objc-lang.c: Remove _initialize_objc_language prototype.
5597 * objfiles.c: Remove _initialize_objfiles prototype.
5598 * observer.c: Remove observer_test_first_notification_function,
5599 observer_test_second_notification_function,
5600 observer_test_third_notification_function, and
5601 _initialize_observer prototypes.
5602 * opencl-lang.c: Remove _initialize_opencl_language prototypes.
5603 * osabi.c: Remove _initialize_gdb_osabi prototype.
5604 * osdata.c: Remove _initialize_osdata prototype.
5605 * p-valprint.c: Remove _initialize_pascal_valprint prototype.
5606 * parse.c: Remove _initialize_parse prototype.
5607 * ppc-fbsd-nat.c: Remove _initialize_ppcfbsd_nat prototype.
5608 * ppc-fbsd-tdep.c: Remove _initialize_ppcfbsd_tdep prototype.
5609 * ppc-linux-nat.c: Remove _initialize_ppc_linux_nat prototype.
5610 * ppc-linux-tdep.c: Remove _initialize_ppc_linux_tdep prototype.
5611 * ppc-nbsd-nat.c: Remove _initialize_ppcnbsd_nat prototype.
5612 * ppc-nbsd-tdep.c: Remove _initialize_ppcnbsd_tdep prototype.
5613 * ppc-obsd-nat.c: Remove _initialize_ppcobsd_nat prototype.
5614 * ppc-obsd-tdep.c: Remove _initialize_ppcobsd_tdep prototype.
5615 * printcmd.c: Remove _initialize_printcmd prototype.
5616 * probe.c: Remove _initialize_probe prototype.
5617 * proc-api.c: Remove _initialize_proc_api prototype.
5618 * proc-events.c: Remove _initialize_proc_events prototype.
5619 * proc-service.c: Remove _initialize_proc_service prototype.
5620 * procfs.c: Remove _initialize_procfs prototype.
5621 * psymtab.c: Remove _initialize_psymtab prototype.
5622 * python/python.c: Remove _initialize_python prototype.
5623 * ravenscar-thread.c: Remove _initialize_ravenscar prototype.
5624 * record-btrace.c: Remove _initialize_record_btrace prototype.
5625 * record-full.c: Remove _initialize_record_full prototype.
5626 * record.c: Remove _initialize_record prototype.
5627 * regcache.c: Remove _initialize_regcache prototype.
5628 * reggroups.c: Remove _initialize_reggroup prototype.
5629 * remote-notif.c: Remove _initialize_notif prototype.
5630 * remote-sim.c: Remove _initialize_remote_sim prototype.
5631 * remote.c: Remove _initialize_remote prototype.
5632 * reverse.c: Remove _initialize_reverse prototype.
5633 * rl78-tdep.c: Remove _initialize_rl78_tdep prototype.
5634 * rs6000-aix-tdep.c: Remove _initialize_rs6000_aix_tdep prototype.
5635 * rs6000-lynx178-tdep.c: Remove _initialize_rs6000_lynx178_tdep
5636 prototype.
5637 * rs6000-nat.c: Remove _initialize_rs6000_nat prototype.
5638 * rs6000-tdep.c: Remove _initialize_rs6000_tdep prototype.
5639 * rust-exp.y: Remove _initialize_rust_exp prototype.
5640 * rx-tdep.c: Remove _initialize_rx_tdep prototype.
5641 * s390-linux-nat.c: Remove _initialize_s390_nat prototype.
5642 * s390-linux-tdep.c: Remove _initialize_s390_tdep prototype.
5643 * score-tdep.c: Remove _initialize_score_tdep prototype.
5644 * selftest-arch.c: Remove _initialize_selftests_foreach_arch
5645 prototype.
5646 * ser-go32.c: Remove _initialize_ser_dos prototype.
5647 * ser-mingw.c: Remove _initialize_ser_windows prototype.
5648 * ser-pipe.c: Remove _initialize_ser_pipe prototype.
5649 * ser-tcp.c: Remove _initialize_ser_tcp prototype.
5650 * ser-unix.c: Remove _initialize_ser_hardwire prototype.
5651 * serial.c: Remove _initialize_serial prototype.
5652 * sh-linux-tdep.c: Remove _initialize_sh_linux_tdep prototype.
5653 * sh-nbsd-nat.c: Remove _initialize_shnbsd_nat prototype.
5654 * sh-nbsd-tdep.c: Remove _initialize_shnbsd_tdep prototype.
5655 * sh-tdep.c: Remove _initialize_sh_tdep prototype.
5656 * skip.c: Remove _initialize_step_skip prototype.
5657 * sol-thread.c: Remove _initialize_sol_thread prototype.
5658 * solib-aix.c: Remove _initialize_solib_aix prototype.
5659 * solib-darwin.c: Remove _initialize_darwin_solib prototype.
5660 * solib-dsbt.c: Remove _initialize_dsbt_solib prototype.
5661 * solib-frv.c: Remove _initialize_frv_solib prototype.
5662 * solib-spu.c: Remove _initialize_spu_solib prototype.
5663 * solib-svr4.c: Remove _initialize_svr4_solib prototype.
5664 * solib-target.c: Remove _initialize_solib_target prototype.
5665 * solib.c: Remove _initialize_solib prototype.
5666 * source.c: Remove _initialize_source prototype.
5667 * sparc-linux-nat.c: Remove _initialize_sparc_linux_nat prototype.
5668 * sparc-linux-tdep.c: Remove _initialize_sparc_linux_tdep
5669 prototype.
5670 * sparc-nat.c: Remove _initialize_sparc_nat prototype.
5671 * sparc-nbsd-nat.c: Remove _initialize_sparcnbsd_nat prototype.
5672 * sparc-nbsd-tdep.c: Remove _initialize_sparcnbsd_tdep prototype.
5673 * sparc-obsd-tdep.c: Remove _initialize_sparc32obsd_tdep
5674 prototype.
5675 * sparc-sol2-nat.c: Remove _initialize_sparc_sol2_nat prototype.
5676 * sparc-sol2-tdep.c: Remove _initialize_sparc_sol2_tdep prototype.
5677 * sparc-tdep.c: Remove _initialize_sparc_tdep prototype.
5678 * sparc64-fbsd-nat.c: Remove _initialize_sparc64fbsd_nat
5679 prototype.
5680 * sparc64-fbsd-tdep.c: Remove _initialize_sparc64fbsd_tdep
5681 prototype.
5682 * sparc64-linux-nat.c: Remove _initialize_sparc64_linux_nat
5683 prototype.
5684 * sparc64-linux-tdep.c: Remove _initialize_sparc64_linux_tdep
5685 prototype.
5686 * sparc64-nat.c: Remove _initialize_sparc64_nat prototype.
5687 * sparc64-nbsd-nat.c: Remove _initialize_sparc64nbsd_nat
5688 prototype.
5689 * sparc64-nbsd-tdep.c: Remove _initialize_sparc64nbsd_tdep
5690 prototype.
5691 * sparc64-obsd-nat.c: Remove _initialize_sparc64obsd_nat
5692 prototype.
5693 * sparc64-obsd-tdep.c: Remove _initialize_sparc64obsd_tdep
5694 prototype.
5695 * sparc64-sol2-tdep.c: Remove _initialize_sparc64_sol2_tdep
5696 prototype.
5697 * spu-linux-nat.c: Remove _initialize_spu_nat prototype.
5698 * spu-multiarch.c: Remove _initialize_spu_multiarch prototype.
5699 * spu-tdep.c: Remove _initialize_spu_tdep prototype.
5700 * stabsread.c: Remove _initialize_stabsread prototype.
5701 * stack.c: Remove _initialize_stack prototype.
5702 * stap-probe.c: Remove _initialize_stap_probe prototype.
5703 * std-regs.c: Remove _initialize_frame_reg prototype.
5704 * symfile-debug.c: Remove _initialize_symfile_debug prototype.
5705 * symfile-mem.c: Remove _initialize_symfile_mem prototype.
5706 * symfile.c: Remove _initialize_symfile prototype.
5707 * symmisc.c: Remove _initialize_symmisc prototype.
5708 * symtab.c: Remove _initialize_symtab prototype.
5709 * target-dcache.c: Remove _initialize_target_dcache prototype.
5710 * target-descriptions.c: Remove _initialize_target_descriptions
5711 prototype.
5712 * thread.c: Remove _initialize_thread prototype.
5713 * tic6x-linux-tdep.c: Remove _initialize_tic6x_linux_tdep
5714 prototype.
5715 * tic6x-tdep.c: Remove _initialize_tic6x_tdep prototype.
5716 * tilegx-linux-nat.c: Remove _initialize_tile_linux_nat prototype.
5717 * tilegx-linux-tdep.c: Remove _initialize_tilegx_linux_tdep
5718 prototype.
5719 * tilegx-tdep.c: Remove _initialize_tilegx_tdep prototype.
5720 * tracefile-tfile.c: Remove _initialize_tracefile_tfile prototype.
5721 * tracefile.c: Remove _initialize_tracefile prototype.
5722 * tracepoint.c: Remove _initialize_tracepoint prototype.
5723 * tui/tui-hooks.c: Remove _initialize_tui_hooks prototype.
5724 * tui/tui-interp.c: Remove _initialize_tui_interp prototype.
5725 * tui/tui-layout.c: Remove _initialize_tui_layout prototype.
5726 * tui/tui-regs.c: Remove _initialize_tui_regs prototype.
5727 * tui/tui-stack.c: Remove _initialize_tui_stack prototype.
5728 * tui/tui-win.c: Remove _initialize_tui_win prototype.
5729 * tui/tui.c: Remove _initialize_tui prototype.
5730 * typeprint.c: Remove _initialize_typeprint prototype.
5731 * user-regs.c: Remove _initialize_user_regs prototype.
5732 * utils.c: Remove _initialize_utils prototype.
5733 * v850-tdep.c: Remove _initialize_v850_tdep prototype.
5734 * valarith.c: Remove _initialize_valarith prototype.
5735 * valops.c: Remove _initialize_valops prototype.
5736 * valprint.c: Remove _initialize_valprint prototype.
5737 * value.c: Remove _initialize_values prototype.
5738 * varobj.c: Remove _initialize_varobj prototype.
5739 * vax-bsd-nat.c: Remove _initialize_vaxbsd_nat prototype.
5740 * vax-nbsd-tdep.c: Remove _initialize_vaxnbsd_tdep prototype.
5741 * vax-tdep.c: Remove _initialize_vax_tdep prototype.
5742 * windows-nat.c: Remove _initialize_windows_nat,
5743 _initialize_check_for_gdb_ini, and _initialize_loadable
5744 prototypes.
5745 * windows-tdep.c: Remove _initialize_windows_tdep prototype.
5746 * xcoffread.c: Remove _initialize_xcoffread prototype.
5747 * xml-support.c: Remove _initialize_xml_support prototype.
5748 * xstormy16-tdep.c: Remove _initialize_xstormy16_tdep prototype.
5749 * xtensa-linux-nat.c: Remove _initialize_xtensa_linux_nat
5750 prototype.
5751 * xtensa-linux-tdep.c: Remove _initialize_xtensa_linux_tdep
5752 prototype.
5753 * xtensa-tdep.c: Remove _initialize_xtensa_tdep prototype.
5754
a611b5cb
KS
57552017-09-08 Keith Seitz <keiths@redhat.com>
5756
5757 * dwarf2read.c (struct field_info) <fnfields>: Remove unused
5758 field.
5759
469412dd
CW
57602017-09-08 Christoph Weinmann <christoph.t.weinmann@intel.com>
5761
5762 * f-valprint.c (f_val_print): Remove check for one byte
5763 sized integers. Remove printing of character type.
5764
a5ad232b
FP
57652017-09-08 Frank Penczek <frank.penczek@intel.com>
5766 Christoph Weinmann <christoph.t.weinmann@intel.com>
5767 Bernhard Heckel <bernhard.heckel@intel.com>
5768
5769 * f-typeprint.c (f_type_print_base): Use fprintfi_filtered
5770 to maintain proper indentation when printing pointers/refs.
5771
e5014227
JB
57722017-09-07 Joel Brobecker <brobecker@adacore.com>
5773
5774 GDB 8.0.1 released.
5775
63c99141
JB
57762017-09-07 Joel Brobecker <brobecker@adacore.com>
5777
5778 * NEWS (Changes in GDB 7.11): Remove entry for QStartupWithShell.
5779
69c1e056
TT
57802017-09-05 Tom Tromey <tom@tromey.com>
5781
5782 * parse.c (funcall_chain): Now a std::vector.
5783 (start_arglist, end_arglist): Simplify.
5784 (free_funcalls): Remove.
5785 (parse_exp_in_context_1): Remove cleanup.
5786
fef704bf
TT
57872017-09-05 Tom Tromey <tom@tromey.com>
5788
5789 * go-exp.y (go_parse): Don't create a cleanup.
5790
5613c585
TT
57912017-09-05 Tom Tromey <tom@tromey.com>
5792
5793 * d-exp.y (PrimaryExpression): Use std::string.
5794 (d_parse): Don't create a cleanup.
5795
eae49211
TT
57962017-09-05 Tom Tromey <tom@tromey.com>
5797
5798 * utils.c (do_clear_parser_state): Remove.
5799 (make_cleanup_clear_parser_state): Remove.
5800 * p-exp.y (pascal_parse): Use scoped_restore.
5801 * m2-exp.y (m2_parse): Use scoped_restore.
5802 * f-exp.y (f_parse): Use scoped_restore.
5803 * d-exp.y (d_parse): Use scoped_restore.
5804 * c-exp.y (c_parse): Use scoped_restore.
5805 * ada-exp.y (ada_parse): Use scoped_restore.
5806 * utils.h (make_cleanup_clear_parser_state): Remove.
5807
73b9be8b
KS
58082017-09-06 Keith Seitz <keiths@redhat.com>
5809
5810 * dwarf2read.c (dw2_linkage_name_attr): New function.
5811 (dw2_linkage_name): New function.
5812 (dwarf2_compute_name, dwarf2_physname, read_call_site_scope)
5813 (guess_full_die_structure_name, dwarf2_name): Use dw2_linkage_name.
5814 (anonymous_struct_prefix, dwarf2_name): Use dw2_linkage_name_attr.
5815
a102602b
KR
58162017-09-06 Kamil Rytarowski <n54@gmx.com>
5817
5818 * config/djgpp/djconfig.sh: Correct shell portability issue.
5819
28ad437d
KR
58202017-09-06 Kamil Rytarowski <n54@gmx.com>
5821
5822 * configure.nat: Define HAVE_NATIVE_GCORE_HOST on NetBSD.
5823
351787dd
JB
58242017-09-06 John Baldwin <jhb@FreeBSD.org>
5825
5826 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
5827 * NEWS: Mention new FreeBSD/mips native configuration.
5828 * configure.host: Add aarch64*-*-freebsd*.
5829 * configure.nat: Likewise.
5830 * aarch64-fbsd-nat.c: New file.
5831
c0f84956
JB
58322017-09-06 John Baldwin <jhb@FreeBSD.org>
5833
5834 * Makefile.in (ALL_64_TARGET_OBS): Add aarch64-fbsd-tdep.o.
5835 (ALLDEPFILES): Add aarch64-fbsd-tdep.c.
5836 * NEWS: Mention new FreeBSD/aarch64 target.
5837 * configure.tgt: Add aarch64*-*-freebsd*.
5838 * aarch64-fbsd-tdep.c: New file.
5839 * aarch64-fbsd-tdep.h: New file.
5840
7610297a
KR
58412017-09-06 Kamil Rytarowski <n54@gmx.com>
5842
5843 * MAINTAINERS (Write After Approval): Add Kamil Rytarowski.
5844
fbd1b771
JK
58452017-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
5846
5847 * parse.c (find_minsym_type_and_address): Don't relocate addresses
5848 of TLS symbols.
5849
5ca79eae
PW
58502017-09-05 Philippe Waroquiers <philippe.waroquiers@skynet.be>
5851
5852 * objfiles.c (get_objfile_bfd_data): Remove useless obstack_init
5853 call.
5854
bf93d7ba
SM
58552017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5856
5857 * infrun.c (follow_exec): Call add_thread after
5858 target_find_description.
5859
1bb7c059
SM
58602017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5861
5862 * infrun.c (handle_inferior_event_1): When exec'ing, read
5863 stop_pc after follow_exec.
5864
fc809827
SM
58652017-09-05 Simon Marchi <simon.marchi@ericsson.com>
5866
5867 * remote.c (process_g_packet): Update error message.
5868
d2fcdd85
YQ
58692017-09-05 Yao Qi <yao.qi@linaro.org>
5870
5871 * configure.tgt (gdb_target_obs): Add i386.o for x86_64-*
5872 targets.
5873
e69570ee
PA
58742017-09-05 Pedro Alves <palves@redhat.com>
5875
5876 * eval.c (eval_call, evaluate_funcall): New functions, factored
5877 out from ...
5878 (evaluate_subexp_standard): ... this.
5879
22916b07
YQ
58802017-09-05 Yao Qi <yao.qi@linaro.org>
5881
5882 * amd64-tdep.c (amd64_target_description): Create target
5883 descriptions.
5884 (_initialize_amd64_tdep): Don't call functions
5885 initialize_tdesc_amd64_*. Add self tests.
5886 * arch/amd64.c (amd64_create_target_description): Add parameter
5887 is_linux. Call set_tdesc_osabi if is_linux is true.
5888 * arch/amd64.h (amd64_create_target_description): Update the
5889 declaration.
5890 * arch/i386.c (i386_create_target_description): Add parameter
5891 is_linux. Call set_tdesc_osabi if is_linux is true.
5892 * arch/i386.h (i386_create_target_description): Update
5893 declaration.
5894 * configure.tgt: Add i386.o to gdb_target_obs.
5895 * features/Makefile (XMLTOC): Remove i386/*.xml.
5896 * features/i386/amd64-avx-avx512.c: Remove.
5897 * features/i386/amd64-avx-mpx-avx512-pku.c: Remove.
5898 * features/i386/amd64-avx-mpx.c: Remove.
5899 * features/i386/amd64-avx.c: Remove.
5900 * features/i386/amd64-mpx.c: Remove.
5901 * features/i386/amd64.c: Remove.
5902 * features/i386/i386-avx-avx512.c: Remove.
5903 * features/i386/i386-avx-mpx-avx512-pku.c: Remove.
5904 * features/i386/i386-avx-mpx.c: Remove.
5905 * features/i386/i386-avx.c: Remove.
5906 * features/i386/i386-mmx.c: Remove.
5907 * features/i386/i386-mpx.c: Remove.
5908 * features/i386/i386.c: Remove.
5909 * i386-tdep.c: Don't include features/i386/i386*.c., include
5910 target-descriptions.h and arch/i386.h.
5911 (i386_target_description): Create target descriptions.
5912 (i386_gdbarch_init): Don't call initialize_tdesc_i386_*
5913 functions. Do self tests.
5914
0854b7b1
YQ
59152017-09-05 Yao Qi <yao.qi@linaro.org>
5916
5917 * features/Makefile (XMLTOC): Remove i386/amd64XXX-linux.xml.
5918 * features/i386/amd64-avx-avx512-linux.c: Removed.
5919 * features/i386/amd64-avx-linux.c: Removed.
5920 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Removed.
5921 * features/i386/amd64-avx-mpx-linux.c: Removed.
5922 * features/i386/amd64-linux.c: Removed.
5923 * features/i386/amd64-mpx-linux.c: Removed.
5924 * features/i386/x32-avx-avx512-linux.c: Removed.
5925 * features/i386/x32-avx-linux.c: Removed.
5926 * features/i386/x32-linux.c: Removed.
5927
b4570e4b
YQ
59282017-09-05 Yao Qi <yao.qi@linaro.org>
5929
5930 * amd64-linux-tdep.c: Include arch/amd64.h. Don't include
5931 features/i386/*.c.
5932 (amd64_linux_read_description): Call
5933 amd64_create_target_description.
5934 * arch/amd64.c: New file.
5935 * arch/amd64.h: New file.
5936 * configure.tgt (x86_64-*-linux*): Append amd64.o.
5937 * Makefile.in (ALL_64_TARGET_OBS): Append amd64.o.
5938
6c73f67f
YQ
59392017-09-05 Yao Qi <yao.qi@linaro.org>
5940
5941 * amd64-linux-tdep.c: Don't include amd64-XXX-linux and
5942 x32-XXX-linux.c. Include 64bit-XX.c and x32-XX.c.
5943 (amd64_linux_read_description): Create target descriptions.
5944 (_initialize_amd64_linux_tdep): Don't call initialize_tdesc_XXX
5945 functions. Add unit tests.
5946 * features/Makefile (FEATURE_XMLFILES): Append 64bit-XXX.xml and
5947 x32-core.xml.
5948 * features/i386/64bit-avx.c: Generated.
5949 * features/i386/64bit-avx512.c: Generated.
5950 * features/i386/64bit-core.c: Generated.
5951 * features/i386/64bit-linux.c: Generated.
5952 * features/i386/64bit-mpx.c: Generated.
5953 * features/i386/64bit-pkeys.c: Generated.
5954 * features/i386/64bit-segments.c: Generated.
5955 * features/i386/64bit-sse.c: Generated.
5956 * features/i386/x32-core.c: Generated.
5957 * target-descriptions.c (maint_print_c_tdesc_cmd): Print feature
5958 c files for amd64-linux and x32-linux.
5959
9d3d478b
YQ
59602017-09-05 Yao Qi <yao.qi@linaro.org>
5961
5962 * amd64-linux-tdep.c (amd64_linux_read_description): New
5963 function.
5964 (amd64_linux_core_read_description): Call
5965 amd64_linux_read_description.
5966 (amd64_linux_init_abi): Likewise.
5967 (amd64_x32_linux_init_abi): Likewise.
5968 * amd64-linux-tdep.h (amd64_linux_read_description): Declare.
5969 * x86-linux-nat.c (x86_linux_read_description): Call
5970 amd64_linux_read_description.
5971
b9f1d50f
YQ
59722017-09-05 Yao Qi <yao.qi@linaro.org>
5973
5974 * amd64-linux-tdep.c (amd64_linux_core_read_description): Update
5975 comments.
5976
188c9e6d
YQ
59772017-09-05 Yao Qi <yao.qi@linaro.org>
5978
5979 * features/Makefile (XMLTOC): Remove i386/i386-XX-linux.xml.
5980 * features/i386/i386-avx-avx512-linux.c: Remove.
5981 * features/i386/i386-avx-linux.c: Remove.
5982 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Remove.
5983 * features/i386/i386-avx-mpx-linux.c: Remove.
5984 * features/i386/i386-linux.c: Remove.
5985 * features/i386/i386-mmx-linux.c: Remove.
5986 * features/i386/i386-mpx-linux.c: Remove.
5987
5f035c07
YQ
59882017-09-05 Yao Qi <yao.qi@linaro.org>
5989
5990 * Makefile.in (ALL_TARGET_OBS): Add i386.o.
5991 (SFILES): Add arch/i386.c.
5992 (HFILES_NO_SRCDIR): Add arch/i386.h.
5993 * arch/i386.c: New file.
5994 * arch/i386.h: New file.
5995 * arch/tdesc.h (allocate_target_description): Declare.
5996 (set_tdesc_architecture): Declare.
5997 (set_tdesc_osabi): Declare.
5998 * configure.tgt (i[34567]86-*-linux*): Add i386.o.
5999 * i386-linux-tdep.c: Don't include ../features/i386/32bit-XXX.c.
6000 include arch/i386.h.
6001 (i386_linux_read_description): Remove code and call
6002 i386_create_target_description.
6003 (set_tdesc_architecture): New function.
6004 (set_tdesc_osabi): New function.
6005 * target-descriptions.h (allocate_target_description): Remove.
6006
0abe8a89
YQ
60072017-09-05 Yao Qi <yao.qi@linaro.org>
6008
6009 * arch/tdesc.h (tdesc_create_feature): Add an argument xml.
6010 * target-descriptions.c (tdesc_create_feature): Likewise, and
6011 adjust code.
6012 * features/i386/32bit-avx.c: Re-generated.
6013 * features/i386/32bit-avx512.c: Re-generated.
6014 * features/i386/32bit-core.c: Re-generated.
6015 * features/i386/32bit-linux.c: Re-generated.
6016 * features/i386/32bit-mpx.c: Re-generated.
6017 * features/i386/32bit-pkeys.c: Re-generated.
6018 * features/i386/32bit-sse.c: Re-generated.
6019
0a188386
YQ
60202017-09-05 Yao Qi <yao.qi@linaro.org>
6021
6022 * regformats/regdef.h (struct reg): Override operator == and !=.
6023
f49ff000
YQ
60242017-09-05 Yao Qi <yao.qi@linaro.org>
6025
6026 * arch/tdesc.h: New file.
6027 * regformats/regdat.sh: Generate code using tdesc_create_reg.
6028 * target-descriptions.c: Update comments.
6029 * target-descriptions.h: Include "arch/tdesc.h". Remove the
6030 declarations.
6031 * features/i386/32bit-avx.c: Re-generated.
6032 * features/i386/32bit-avx512.c: Re-generated.
6033 * features/i386/32bit-core.c: Re-generated.
6034 * features/i386/32bit-linux.c: Re-generated.
6035 * features/i386/32bit-mpx.c: Re-generated.
6036 * features/i386/32bit-pkeys.c: Re-generated.
6037 * features/i386/32bit-sse.c: Re-generated.
6038
f7000548
YQ
60392017-09-05 Yao Qi <yao.qi@linaro.org>
6040
6041 * regformats/regdat.sh: Update generated code.
6042
c9a5e2a5
YQ
60432017-09-05 Yao Qi <yao.qi@linaro.org>
6044
6045 * regformats/regdat.sh: Adjust code order.
6046
d6b687ac
SM
60472017-09-05 Simon Marchi <simon.marchi@ericsson.com>
6048
6049 * expprint.c (dump_subexp_body_standard): Use constant format
6050 string in fprintf_filtered call.
6051
a379bfd0
JB
60522017-09-04 John Baldwin <jhb@FreeBSD.org>
6053
6054 * configure.nat: Add "x86-nat.o x86-dregs.o" for NetBSD/amd64 and
6055 NetBSD/i386.
6056 * x86-bsd-nat.c [!DBREG_DRX && __NetBSD__]: Define DBREG_DRX.
6057
f7efc967
JB
60582017-09-04 John Baldwin <jhb@FreeBSD.org>
6059
6060 * bsd-kvm.o: Make <sys/user.h> conditional on HAVE_SYS_USER_H.
6061
c49fbc6c
JB
60622017-09-04 John Baldwin <jhb@FreeBSD.org>
6063
6064 * bsd-kvm.o: Define _KMEMUSER.
6065 * configure.ac: Define _KMEMUSER when checking for "struct lwp".
6066 * configure: Regenerate.
6067
26562e73
JB
60682017-09-04 John Baldwin <jhb@FreeBSD.org>
6069
6070 * amd64-fbsd-nat.c: Add include of "x86-xstate.h".
6071 * i386-fbsd-nat.c: Likewise.
6072
31cf1487
JB
60732017-09-04 John Baldwin <jhb@FreeBSD.org>
6074
6075 * unittests/array-view-selftests.c: Add include of <array>.
6076
5b9f8a7c
JB
60772017-09-04 John Baldwin <jhb@FreeBSD.org>
6078
6079 * spu-tdep.c (flush_ea_cache): Add missing argument to
6080 call_function_by_hand.
6081
d69cf9b2
PA
60822017-09-04 Pedro Alves <palves@redhat.com>
6083
6084 * NEWS (Safer support for debugging with no debug info): New.
6085
3693fdb3
PA
60862017-09-04 Pedro Alves <palves@redhat.com>
6087
6088 * c-exp.y (function_method, function_method_void): Add current
6089 instance flags to TYPE_INSTANCE.
6090 * dwarf2read.c (check_modifier): New.
6091 (compute_delayed_physnames): Assert that only C++ adds delayed
6092 physnames. Mark fn_fields as const/volatile depending on
6093 physname.
6094 * eval.c (make_params): New type_instance_flags parameter. Use
6095 it as the new type's instance flags.
6096 (evaluate_subexp_standard) <TYPE_INSTANCE>: Extract the instance
6097 flags element and pass it to make_params.
6098 * expprint.c (print_subexp_standard) <TYPE_INSTANCE>: Handle
6099 instance flags element.
6100 (dump_subexp_body_standard) <TYPE_INSTANCE>: Likewise.
6101 * gdbtypes.h: Include "enum-flags.h".
6102 (type_instance_flags): New enum-flags type.
6103 (TYPE_CONST, TYPE_VOLATILE, TYPE_RESTRICT, TYPE_ATOMIC)
6104 (TYPE_CODE_SPACE, TYPE_DATA_SPACE): Return boolean.
6105 * parse.c (operator_length_standard) <TYPE_INSTANCE>: Adjust.
6106 (follow_type_instance_flags): New function.
6107 (operator_check_standard) <TYPE_INSTANCE>: Adjust.
6108 * parser-defs.h (follow_type_instance_flags): Declare.
6109 * valops.c (value_struct_elt_for_reference): const/volatile must
6110 match too.
6111
e68cb8e0
PA
61122017-09-04 Pedro Alves <palves@redhat.com>
6113
6114 * cp-namespace.c (cp_search_static_and_baseclasses): Handle
6115 function/method scopes; lookup the nested name as a function local
6116 static variable.
6117
858be34c
PA
61182017-09-04 Pedro Alves <palves@redhat.com>
6119
6120 (%type <voidval>): Add function_method.
6121 * c-exp.y (exp): New production for calls with no arguments.
6122 (function_method, function_method_void_or_typelist): New
6123 productions.
6124 (exp): New production for "method()::static_var".
6125 * eval.c (evaluate_subexp_standard): Handle OP_FUNC_STATIC_VAR.
6126 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6127 Handle OP_FUNC_STATIC_VAR.
6128 * parse.c (operator_length_standard):
6129 Handle OP_FUNC_STATIC_VAR.
6130
dd5901a6
PA
61312017-09-04 Pedro Alves <palves@redhat.com>
6132
6133 * eval.c (evaluate_subexp_standard): Remove UNOP_MEMVAL_TLS
6134 handling.
6135 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6136 Ditto.
6137 * parse.c (operator_length_standard, operator_check_standard):
6138 Ditto.
6139 * std-operator.def (UNOP_MEMVAL_TLS): Delete.
6140
46a4882b
PA
61412017-09-04 Pedro Alves <palves@redhat.com>
6142
6143 * ax-gdb.c: Include "typeprint.h".
6144 (gen_expr_for_cast): New function.
6145 (gen_expr) <OP_CAST, OP_CAST_TYPE>: Use it.
6146 <OP_VAR_VALUE, OP_MSYM_VAR_VALUE>: Error out if the variable's
6147 type is unknown.
6148 * dwarf2read.c (new_symbol_full): Fallback to int instead of
6149 nodebug_data_symbol.
6150 * eval.c: Include "typeprint.h".
6151 (evaluate_subexp_standard) <OP_VAR_VALUE, OP_VAR_MSYM_VALUE>:
6152 Error out if symbol has unknown type.
6153 <UNOP_CAST, UNOP_CAST_TYPE>: Common bits factored out to
6154 evaluate_subexp_for_cast.
6155 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof): Handle
6156 OP_VAR_MSYM_VALUE.
6157 (evaluate_subexp_for_cast): New function.
6158 * gdbtypes.c (init_nodebug_var_type): New function.
6159 (objfile_type): Use it to initialize types of variables with no
6160 debug info.
6161 * typeprint.c (error_unknown_type): New.
6162 * typeprint.h (error_unknown_type): New declaration.
6163 * compile/compile-c-types.c (convert_type_basic): Handle
6164 TYPE_CODE_ERROR; warn and fallback to int for variables with
6165 unknown type.
6166
fe13dfec
PA
61672017-09-04 Pedro Alves <palves@redhat.com>
6168
6169 * eval.c (evaluate_var_value): New function, factored out from ...
6170 (evaluate_subexp_standard): ... here.
6171
d008ee21
PA
61722017-09-04 Pedro Alves <palves@redhat.com>
6173
6174 * eval.c (evaluate_subexp_standard) <UNOP_COMPLEMENT, UNOP_ADDR>:
6175 Remove useless assignments to 'op'.
6176
827d0c51
PA
61772017-09-04 Pedro Alves <palves@redhat.com>
6178
6179 * eval.c (eval_skip_value): New function.
6180 (evaluate_subexp_standard): Use it.
6181
2c5a2be1
PA
61822017-09-04 Pedro Alves <palves@redhat.com>
6183
6184 * eval.c (evaluate_subexp_standard): <OP_FUNCALL>: Extract
6185 function name from symbol/minsym and pass it to
6186 error_call_unknown_return_type.
6187
74ea4be4
PA
61882017-09-04 Pedro Alves <palves@redhat.com>
6189
6190 * ada-lang.c (resolve_subexp): Handle OP_VAR_MSYM_VALUE.
6191 * ax-gdb.c (gen_msym_var_ref): New function.
6192 (gen_expr): Handle OP_VAR_MSYM_VALUE.
6193 * eval.c (evaluate_var_msym_value): New function.
6194 * eval.c (evaluate_subexp_standard): Handle OP_VAR_MSYM_VALUE.
6195 <OP_FUNCALL>: Extract function name from symbol/minsym and pass it
6196 to call_function_by_hand.
6197 * expprint.c (print_subexp_standard, dump_subexp_body_standard):
6198 Handle OP_VAR_MSYM_VALUE.
6199 (union exp_element) <msymbol>: New field.
6200 * minsyms.h (struct type): Forward declare.
6201 (find_minsym_type_and_address): Declare.
6202 * parse.c (write_exp_elt_msym): New function.
6203 (write_exp_msymbol): Delete, refactored as ...
6204 (find_minsym_type_and_address): ... this new function.
6205 (write_exp_msymbol): Reimplement using OP_VAR_MSYM_VALUE.
6206 (operator_length_standard, operator_check_standard): Handle
6207 OP_VAR_MSYM_VALUE.
6208 * std-operator.def (OP_VAR_MSYM_VALUE): New.
6209
7022349d
PA
62102017-09-04 Pedro Alves <palves@redhat.com>
6211
6212 * ada-lang.c (ada_evaluate_subexp) <TYPE_CODE_FUNC>: Don't handle
6213 TYPE_GNU_IFUNC specially here. Throw error if return type is
6214 unknown.
6215 * ada-typeprint.c (print_func_type): Handle functions with unknown
6216 return type.
6217 * c-typeprint.c (c_type_print_base): Handle functions and methods
6218 with unknown return type.
6219 * compile/compile-c-symbols.c (convert_symbol_bmsym)
6220 <mst_text_gnu_ifunc>: Use nodebug_text_gnu_ifunc_symbol.
6221 * compile/compile-c-types.c: Include "objfiles.h".
6222 (convert_func): For functions with unknown return type, warn and
6223 default to int.
6224 * compile/compile-object-run.c (compile_object_run): Adjust call
6225 to call_function_by_hand_dummy.
6226 * elfread.c (elf_gnu_ifunc_resolve_addr): Adjust call to
6227 call_function_by_hand.
6228 * eval.c (evaluate_subexp_standard): Adjust calls to
6229 call_function_by_hand. Handle functions and methods with unknown
6230 return type. Pass expect_type to call_function_by_hand.
6231 * f-typeprint.c (f_type_print_base): Handle functions with unknown
6232 return type.
6233 * gcore.c (call_target_sbrk): Adjust call to
6234 call_function_by_hand.
6235 * gdbtypes.c (objfile_type): Leave nodebug text symbol with NULL
6236 return type instead of int. Make nodebug_text_gnu_ifunc_symbol be
6237 an integer address type instead of nodebug.
6238 * guile/scm-value.c (gdbscm_value_call): Adjust call to
6239 call_function_by_hand.
6240 * infcall.c (error_call_unknown_return_type): New function.
6241 (call_function_by_hand): New "default_return_type" parameter.
6242 Pass it down.
6243 (call_function_by_hand_dummy): New "default_return_type"
6244 parameter. Use it instead of defaulting to int. If there's no
6245 default and the return type is unknown, throw an error. If
6246 there's a default return type, and the called function has no
6247 debug info, then assume the function is prototyped.
6248 * infcall.h (call_function_by_hand, call_function_by_hand_dummy):
6249 New "default_return_type" parameter.
6250 (error_call_unknown_return_type): New declaration.
6251 * linux-fork.c (call_lseek): Cast return type of lseek.
6252 (inferior_call_waitpid, checkpoint_command): Adjust calls to
6253 call_function_by_hand.
6254 * linux-tdep.c (linux_infcall_mmap, linux_infcall_munmap): Adjust
6255 calls to call_function_by_hand.
6256 * m2-typeprint.c (m2_procedure): Handle functions with unknown
6257 return type.
6258 * objc-lang.c (lookup_objc_class, lookup_child_selector)
6259 (value_nsstring, print_object_command): Adjust calls to
6260 call_function_by_hand.
6261 * p-typeprint.c (pascal_type_print_varspec_prefix): Handle
6262 functions with unknown return type.
6263 (pascal_type_print_func_varspec_suffix): New function.
6264 (pascal_type_print_varspec_suffix) <TYPE_CODE_FUNC,
6265 TYPE_CODE_METHOD>: Use it.
6266 * python/py-value.c (valpy_call): Adjust call to
6267 call_function_by_hand.
6268 * rust-lang.c (rust_evaluate_funcall): Adjust call to
6269 call_function_by_hand.
6270 * valarith.c (value_x_binop, value_x_unop): Adjust calls to
6271 call_function_by_hand.
6272 * valops.c (value_allocate_space_in_inferior): Adjust call to
6273 call_function_by_hand.
6274 * typeprint.c (type_print_unknown_return_type): New function.
6275 * typeprint.h (type_print_unknown_return_type): New declaration.
6276
54990598
PA
62772017-09-04 Pedro Alves <palves@redhat.com>
6278
6279 * gdbtypes.c (lookup_function_type_with_arguments): Mark function
6280 types with more than one parameter as prototyped.
6281
9a24775b
PA
62822017-09-04 Pedro Alves <palves@redhat.com>
6283
6284 * cli/cli-cmds.c (print_disassembly, disassemble_current_function)
6285 (disassemble_command): Use gdb_disassembly_flags instead of bare
6286 int.
6287 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn)
6288 (dump_insns, do_mixed_source_and_assembly_deprecated)
6289 (do_mixed_source_and_assembly, do_assembly_only, gdb_disassembly):
6290 Use gdb_disassembly_flags instead of bare int.
6291 * disasm.h (DISASSEMBLY_SOURCE_DEPRECATED, DISASSEMBLY_RAW_INSN)
6292 (DISASSEMBLY_OMIT_FNAME, DISASSEMBLY_FILENAME)
6293 (DISASSEMBLY_OMIT_PC, DISASSEMBLY_SOURCE)
6294 (DISASSEMBLY_SPECULATIVE): No longer macros. Instead they're...
6295 (enum gdb_disassembly_flag): ... values of this new enumeration.
6296 (gdb_disassembly_flags): Define.
6297 (gdb_disassembly)
6298 (gdb_pretty_print_disassembler::pretty_print_insn): Use it.
6299 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Use
6300 gdb_disassembly_flags instead of bare int.
6301 * record-btrace.c (btrace_insn_history)
6302 (record_btrace_insn_history, record_btrace_insn_history_range)
6303 (record_btrace_insn_history_from): Use gdb_disassembly_flags
6304 instead of bare int.
6305 * record.c (get_insn_history_modifiers, cmd_record_insn_history):
6306 Use gdb_disassembly_flags instead of bare int.
6307 * target-debug.h (target_debug_print_gdb_disassembly_flags):
6308 Define.
6309 * target-delegates.c: Regenerate.
6310 * target.c (target_insn_history, target_insn_history_from)
6311 (target_insn_history_range): Use gdb_disassembly_flags instead of
6312 bare int.
6313 * target.h: Include "disasm.h".
6314 (struct target_ops) <to_insn_history, to_insn_history_from,
6315 to_insn_history_range>: Use gdb_disassembly_flags instead of bare
6316 int.
6317 (target_insn_history, target_insn_history_from)
6318 (target_insn_history_range): Use gdb_disassembly_flags instead of
6319 bare int.
6320
80a65e9b
SM
63212017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6322
6323 * cli/cli-script.c (build_command_line): For if/while commands,
6324 check whether args is empty.
6325
6b66338c
SM
63262017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6327
6328 * cli/cli-script.h (enum misc_command_type): Move from defs.h.
6329 (enum command_control_type): Likewise.
6330 (struct command_line): Likewise.
6331 (free_command_lines): Likewise.
6332 (struct command_lines_deleter): Likewise.
6333 (command_line_up): Likewise.
6334 (read_command_lines): Likewise.
6335 (read_command_lines_1): Likewise.
6336 * defs.h (enum misc_command_type): Move to cli/cli-script.h.
6337 (enum command_control_type): Likewise.
6338 (struct command_line): Likewise.
6339 (free_command_lines): Likewise.
6340 (struct command_lines_deleter): Likewise.
6341 (command_line_up): Likewise.
6342 (read_command_lines): Likewise.
6343 (read_command_lines_1): Likewise.
6344 * breakpoint.h: Include cli/cli-script.h.
6345 * extension-priv.h: Likewise.
6346 * gdbcmd.h: Likewise.
6347
51abb421
PA
63482017-09-04 Pedro Alves <palves@redhat.com>
6349
6350 * ada-lang.c (is_known_support_routine): Move sal declaration to
6351 where it is initialized.
6352 * breakpoint.c (create_internal_breakpoint, init_catchpoint)
6353 (parse_breakpoint_sals, decode_static_tracepoint_spec)
6354 (clear_command, update_static_tracepoint): Remove init_sal
6355 references. Move declarations closer to initializations.
6356 * cli/cli-cmds.c (list_command): Move sal declarations closer to
6357 initializations.
6358 * elfread.c (elf_gnu_ifunc_resolver_stop): Remove init_sal
6359 references. Move sal declarations closer to initializations.
6360 * frame.c (find_frame_sal): Return a symtab_and_line via function
6361 return instead of output parameter. Remove init_sal references.
6362 * frame.h (find_frame_sal): Return a symtab_and_line via function
6363 return instead of output parameter.
6364 * guile/scm-frame.c (gdbscm_frame_sal): Adjust.
6365 * guile/scm-symtab.c (stscm_make_sal_smob): Use in-place new
6366 instead of memset.
6367 (gdbscm_find_pc_line): Remove init_sal reference.
6368 * infcall.c (call_function_by_hand_dummy): Remove init_sal
6369 references. Move declarations closer to initializations.
6370 * infcmd.c (set_step_frame): Update. Move declarations closer to
6371 initializations.
6372 (finish_backward): Remove init_sal references. Move declarations
6373 closer to initializations.
6374 * infrun.c (process_event_stop_test, handle_step_into_function)
6375 (insert_hp_step_resume_breakpoint_at_frame)
6376 (insert_step_resume_breakpoint_at_caller): Likewise.
6377 * linespec.c (create_sals_line_offset, decode_digits_ordinary)
6378 (symbol_to_sal): Likewise.
6379 * probe.c (parse_probes_in_pspace): Remove init_sal reference.
6380 * python/py-frame.c (frapy_find_sal): Move sal declaration closer
6381 to its initialization.
6382 * reverse.c (save_bookmark_command): Use new/delete. Remove
6383 init_sal references. Move declarations closer to initializations.
6384 * source.c (get_current_source_symtab_and_line): Remove brace
6385 initialization.
6386 (set_current_source_symtab_and_line): Now takes the sal by const
6387 reference. Remove brace initialization.
6388 (line_info): Remove init_sal reference.
6389 * source.h (set_current_source_symtab_and_line): Now takes a
6390 symtab_and_line via const reference.
6391 * stack.c (set_current_sal_from_frame): Adjust.
6392 (print_frame_info): Adjust.
6393 (get_last_displayed_sal): Return the sal via function return
6394 instead of via output parameter. Simplify.
6395 (frame_info): Adjust.
6396 * stack.h (get_last_displayed_sal): Return the sal via function
6397 return instead of via output parameter.
6398 * symtab.c (init_sal): Delete.
6399 (find_pc_sect_line): Remove init_sal references. Move
6400 declarations closer to initializations.
6401 (find_function_start_sal): Remove init_sal references. Move
6402 declarations closer to initializations.
6403 * symtab.h (struct symtab_and_line): In-class initialize all
6404 fields.
6405 * tracepoint.c (set_traceframe_context)
6406 (print_one_static_tracepoint_marker): Remove init_sal references.
6407 Move declarations closer to initializations.
6408 * tui/tui-disasm.c (tui_show_disassem_and_update_source): Adjust.
6409 * tui/tui-stack.c (tui_show_frame_info): Adjust. Move
6410 declarations closer to initializations.
6411 * tui/tui-winsource.c (tui_update_source_window_as_is): Remove
6412 init_sal references. Adjust.
6413
6c5b2ebe
PA
64142017-09-04 Pedro Alves <palves@redhat.com>
6415
6416 * ax-gdb.c (agent_command_1): Use range-for.
6417 * break-catch-throw.c (re_set_exception_catchpoint): Update.
6418 * breakpoint.c: Include "common/array-view.h".
6419 (init_breakpoint_sal, create_breakpoint_sal): Change sals
6420 parameter from struct symtabs_and_lines to
6421 array_view<symtab_and_line>. Adjust. Use range-for. Update.
6422 (breakpoint_sals_to_pc): Change sals parameter from struct
6423 symtabs_and_lines to std::vector reference.
6424 (check_fast_tracepoint_sals): Change sals parameter from struct
6425 symtabs_and_lines to std::array_view. Use range-for.
6426 (decode_static_tracepoint_spec): Return a std::vector instead of
6427 symtabs_and_lines. Update.
6428 (create_breakpoint): Update.
6429 (break_range_command, until_break_command, clear_command): Update.
6430 (base_breakpoint_decode_location, bkpt_decode_location)
6431 (bkpt_probe_create_sals_from_location)
6432 (bkpt_probe_decode_location, tracepoint_decode_location)
6433 (tracepoint_probe_decode_location)
6434 (strace_marker_create_sals_from_location): Return a std::vector
6435 instead of symtabs_and_lines.
6436 (strace_marker_create_breakpoints_sal): Update.
6437 (strace_marker_decode_location): Return a std::vector instead of
6438 symtabs_and_lines. Update.
6439 (update_breakpoint_locations): Change struct symtabs_and_lines
6440 parameters to gdb::array_view. Adjust.
6441 (location_to_sals): Return a std::vector instead of
6442 symtabs_and_lines. Update.
6443 (breakpoint_re_set_default): Use std::vector instead of struct
6444 symtabs_and_lines.
6445 (decode_location_default): Return a std::vector instead of
6446 symtabs_and_lines. Update.
6447 * breakpoint.h: Include "common/array-view.h".
6448 (struct breakpoint_ops) <decode_location>: Now returns a
6449 std::vector instead of returning a symtabs_and_lines via output
6450 parameter.
6451 (update_breakpoint_locations): Change sals parameters to use
6452 gdb::array_view.
6453 * cli/cli-cmds.c (edit_command, list_command): Update to use
6454 std::vector and gdb::array_view.
6455 (ambiguous_line_spec): Adjust to use gdb::array_view and
6456 range-for.
6457 (compare_symtabs): Rename to ...
6458 (cmp_symtabs): ... this. Change parameters to symtab_and_line
6459 const reference and adjust.
6460 (filter_sals): Rewrite using std::vector and standard algorithms.
6461 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Simplify.
6462 (jump_command): Update to use std::vector.
6463 * linespec.c (struct linespec_state) <canonical_names>: Update
6464 comment.
6465 (add_sal_to_sals_basic): Delete.
6466 (add_sal_to_sals, filter_results, convert_results_to_lsals)
6467 (decode_line_2, create_sals_line_offset)
6468 (convert_address_location_to_sals, convert_linespec_to_sals)
6469 (convert_explicit_location_to_sals, parse_linespec)
6470 (event_location_to_sals, decode_line_full, decode_line_1)
6471 (decode_line_with_current_source)
6472 (decode_line_with_last_displayed, decode_objc)
6473 (decode_digits_list_mode, decode_digits_ordinary, minsym_found)
6474 (linespec_result::~linespec_result): Adjust to use std::vector
6475 instead of symtabs_and_lines.
6476 * linespec.h (linespec_sals::sals): Now a std::vector.
6477 (struct linespec_result): Use std::vector, bool, and in-class
6478 initialization.
6479 (decode_line_1, decode_line_with_current_source)
6480 (decode_line_with_last_displayed): Return std::vector.
6481 * macrocmd.c (info_macros_command): Use std::vector.
6482 * mi/mi-main.c (mi_cmd_trace_find): Use std::vector.
6483 * probe.c (parse_probes_in_pspace, parse_probes): Adjust to use
6484 std::vector.
6485 * probe.h (parse_probes): Return a std::vector.
6486 * python/python.c (gdbpy_decode_line): Use std::vector and
6487 gdb::array_view.
6488 * source.c (select_source_symtab, line_info): Use std::vector.
6489 * stack.c (func_command): Use std::vector.
6490 * symtab.h (struct symtabs_and_lines): Delete.
6491 * tracepoint.c (tfind_line_command, scope_info): Use std::vector.
6492
7c44b49c
PA
64932017-09-04 Pedro Alves <palves@redhat.com>
6494
6495 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6496 unittests/array-view-selftests.c.
6497 (SUBDIR_UNITTESTS_OBS): Add array-view-selftests.o.
6498 * common/array-view.h: New file.
6499 * unittests/array-view-selftests.c: New file.
6500
e439fa14
PA
65012017-09-04 Pedro Alves <palves@redhat.com>
6502
6503 * cli/cli-cmds.c (edit_command): Pass message to
6504 ambiguous_line_spec.
6505 (list_command): Pass message to ambiguous_line_spec. Say
6506 "first"/"last" instead of "start" and "end" to be consistent with
6507 the manual.
6508 (ambiguous_line_spec): Add 'format' and vararg parameters. Use
6509 them to print formatted message.
6510
7525b645
PA
65112017-09-04 Pedro Alves <palves@redhat.com>
6512
6513 * btrace.c (ftrace_add_pt): Pass btrace_insn to
6514 ftrace_update_insns by reference instead of pointer.
6515
badc0020
YQ
65162017-09-04 Yao Qi <yao.qi@linaro.org>
6517
6518 * i386-go32-tdep.c: Include x86-xstate.h.
6519 (i386_go32_init_abi): Call i386_target_description.
6520 * i386-tdep.c (i386_target_description): Return tdesc_i386_mmx
6521 if xcr0 is X86_XSTATE_X87_MASK.
6522 * i386-tdep.h (tdesc_i386): Remove the declaration.
6523 (tdesc_i386_mmx): Likewise.
6524
d78bdb54
YQ
65252017-09-04 Yao Qi <yao.qi@linaro.org>
6526
6527 * i386-fbsd-tdep.c (i386fbsd_core_read_xcr0): Return
6528 X86_XSTATE_SSE_MASK instead of 0.
6529
ca1fa5ee
YQ
65302017-09-04 Yao Qi <yao.qi@linaro.org>
6531
6532 * amd64-fbsd-nat.c (amd64fbsd_read_description): Call
6533 i386_target_description.
6534 * i386-fbsd-nat.c (i386fbsd_read_description): Call
6535 i386_target_description.
6536 * i386-tdep.c (i386_gdbarch_init): Likewise.
6537
2434b019
YQ
65382017-09-04 Yao Qi <yao.qi@linaro.org>
6539
6540 * amd64-darwin-tdep.c: Include "x86-xstate.h".
6541 (x86_darwin_init_abi_64): Call amd64_target_description.
6542 * amd64-dicos-tdep.c: Likewise.
6543 * amd64-fbsd-nat.c: Likewise.
6544 * amd64-fbsd-tdep.c: Likewise.
6545 * amd64-nbsd-tdep.c: Likewise.
6546 * amd64-obsd-tdep.c: Likewise.
6547 * amd64-sol2-tdep.c: Likewise.
6548 * amd64-windows-tdep.c: Likewise.
6549 * amd64-tdep.h (tdesc_amd64): Remove the declaration.
6550
0860c437
SM
65512017-09-04 Simon Marchi <simon.marchi@ericsson.com>
6552
6553 * btrace.h (btrace_insn_s, DEF_VEC_O (btrace_insn_s)): Remove.
6554 (btrace_function) <insn>: Change type to use std::vector.
6555 * btrace.c (ftrace_debug, ftrace_call_num_insn,
6556 ftrace_find_call, ftrace_new_gap, ftrace_update_function,
6557 ftrace_update_insns, ftrace_compute_global_level_offset,
6558 btrace_stitch_bts, btrace_clear, btrace_insn_get,
6559 btrace_insn_end, btrace_insn_next, btrace_insn_prev): Adjust to
6560 change to std::vector.
6561 (ftrace_update_insns): Adjust to change to std::vector, change
6562 type of INSN parameter.
6563 (btrace_compute_ftrace_bts): Adjust call to ftrace_update_insns.
6564 * record-btrace.c (btrace_call_history_insn_range,
6565 btrace_compute_src_line_range,
6566 record_btrace_frame_prev_register): Adjust to change to
6567 std::vector.
6568 * python/py-record-btrace.c (recpy_bt_func_instructions): Adjust
6569 to change to std::vector.
6570
0638b7f9
TT
65712017-09-03 Tom Tromey <tom@tromey.com>
6572
6573 * corefile.c (reopen_exec_file): Use std::string.
6574
8f84fb0e
TT
65752017-09-03 Tom Tromey <tom@tromey.com>
6576
6577 * compile/compile.c (compile_register_name_mangled): Return
6578 std::string.
6579 * compile/compile-loc2c.c (pushf_register_address): Update.
6580 (pushf_register): Update.
6581 * compile/compile-c-types.c (convert_array): Update.
6582 * compile/compile-c-symbols.c (generate_vla_size): Update.
6583 (error_symbol_once): Use a gdb::unique_xmalloc_ptr.
6584 (symbol_substitution_name): Return a gdb::unique_xmalloc_ptr.
6585 (convert_one_symbol): Update.
6586 (generate_c_for_for_one_variable): Update.
6587 * compile/compile-c-support.c (c_get_range_decl_name): Return a
6588 std::string.
6589 (generate_register_struct): Update.
6590 * compile/compile-internal.h (c_get_range_decl_name): Return a
6591 std::string.
6592 (compile_register_name_mangled): Return std::string.
6593
18e9961f
TT
65942017-09-03 Tom Tromey <tom@tromey.com>
6595
6596 * utils.c (perror_string): Return a std::string.
6597 (throw_perror_with_name, perror_warning_with_name): Update.
6598
45343786
TT
65992017-09-03 Tom Tromey <tom@tromey.com>
6600
6601 * demangle.c (demangle_command): Use std::string,
6602 unique_xmalloc_ptr.
6603
b57af503
TT
66042017-09-03 Tom Tromey <tom@tromey.com>
6605
6606 * cli/cli-setshow.c (do_set_command): Use std::string.
6607
6eecf35f
TT
66082017-09-03 Tom Tromey <tom@tromey.com>
6609
6610 * cli/cli-cmds.c (cd_command): Use gdb::unique_xmalloc_ptr.
6611
56496dd4
TT
66122017-09-03 Tom Tromey <tom@tromey.com>
6613
6614 * mi/mi-interp.c (mi_cmd_interpreter_exec): Use std::string.
6615
e91a1fa7
TT
66162017-09-03 Tom Tromey <tom@tromey.com>
6617
6618 * mi/mi-cmd-env.c (env_execute_cli_command): Use
6619 gdb::unique_xmalloc_ptr.
6620
7ffd83d7
TT
66212017-09-03 Tom Tromey <tom@tromey.com>
6622
6623 * thread.c (print_thread_info_1): Use string_printf.
6624 (thread_apply_command, thread_apply_all_command): Use
6625 std::string.
6626
1ccbe998
TT
66272017-09-03 Tom Tromey <tom@tromey.com>
6628
6629 * valprint.c (val_print_string): Update.
6630 * gdbcore.h (memory_error_message): Return std::string.
6631 * corefile.c (memory_error_message): Return std::string.
6632 (memory_error): Update.
6633 * breakpoint.c (insert_bp_location): Update.
6634
23fdd69e
SM
66352017-09-03 Simon Marchi <simon.marchi@ericsson.com>
6636
6637 * target/waitstatus.h (target_waitstatus_to_string): Change
6638 return type to std::string.
6639 * target/waitstatus.c (target_waitstatus_to_string): Return
6640 std::string.
6641 * target.h (target_waitstatus_to_string): Remove declaration.
6642 * infrun.c (resume, clear_proceed_status_thread,
6643 print_target_wait_results, do_target_wait, save_waitstatus,
6644 stop_all_threads): Adjust.
6645 * record-btrace.c (record_btrace_wait): Adjust.
6646 * target-debug.h
6647 (target_debug_print_struct_target_waitstatus_p): Adjust.
6648
5c811d30
JK
66492017-09-01 Jan Kratochvil <jan.kratochvil@redhat.com>
6650
6651 PR gdb/22046
6652 * nat/linux-procfs.c (parse_proc_status_state): Fix PROC_STATE_STOPPED
6653 detection.
6654
0a2dde4a
SDJ
66552017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
6656
6657 * NEWS (Changes since GDB 8.0): Add entry mentioning new support
6658 for setting/unsetting environment variables on the remote target.
6659 (New remote packets): Add entries for QEnvironmentHexEncoded,
6660 QEnvironmentUnset and QEnvironmentReset.
6661 * common/environ.c (gdb_environ::operator=): Extend method to
6662 handle m_user_set_env_list and m_user_unset_env_list.
6663 (gdb_environ::clear): Likewise.
6664 (match_var_in_string): Change type of first parameter from 'char
6665 *' to 'const char *'.
6666 (gdb_environ::set): Extend method to handle
6667 m_user_set_env_list and m_user_unset_env_list.
6668 (gdb_environ::unset): Likewise.
6669 (gdb_environ::clear_user_set_env): New method.
6670 (gdb_environ::user_set_envp): Likewise.
6671 (gdb_environ::user_unset_envp): Likewise.
6672 * common/environ.h (gdb_environ): Handle m_user_set_env_list and
6673 m_user_unset_env_list on move constructor/assignment.
6674 (unset): Add new default parameter 'update_unset_list = true'.
6675 (clear_user_set_env): New method.
6676 (user_set_envp): Likewise.
6677 (user_unset_envp): Likewise.
6678 (m_user_set_env_list): New std::set.
6679 (m_user_unset_env_list): Likewise.
6680 * common/rsp-low.c (hex2str): New function.
6681 (bin2hex): New overload for bin2hex function.
6682 * common/rsp-low.c (hex2str): New prototype.
6683 (str2hex): New overload prototype.
6684 * remote.c: Include "environ.h". Add QEnvironmentHexEncoded,
6685 QEnvironmentUnset and QEnvironmentReset.
6686 (remote_protocol_features): Add QEnvironmentHexEncoded,
6687 QEnvironmentUnset and QEnvironmentReset packets.
6688 (send_environment_packet): New function.
6689 (extended_remote_environment_support): Likewise.
6690 (extended_remote_create_inferior): Call
6691 extended_remote_environment_support.
6692 (_initialize_remote): Add QEnvironmentHexEncoded,
6693 QEnvironmentUnset and QEnvironmentReset packet configs.
6694 * unittests/environ-selftests.c (gdb_selftest_env_var):
6695 New variable.
6696 (test_vector_initialization): New function.
6697 (test_init_from_host_environ): Likewise.
6698 (test_reinit_from_host_environ): Likewise.
6699 (test_set_A_unset_B_unset_A_cannot_find_A_can_find_B):
6700 Likewise.
6701 (test_unset_set_empty_vector): Likewise.
6702 (test_vector_clear): Likewise.
6703 (test_std_move): Likewise.
6704 (test_move_constructor):
6705 (test_self_move): Likewise.
6706 (test_set_unset_reset): Likewise.
6707 (run_tests): Rewrite in terms of the functions above.
6708
654670a4
WP
67092017-08-31 Weimin Pan <weimin.pan@oracle.com>
6710
6711 * sparc64-tdep.c (adi_stat_t): Fix comment formatting.
6712 (adi_available): Use a temp variable of type CORE_ADDR as argument
6713 3 when calling target_auxv_search.
6714 (adi_normalize_address): Use masks and xor operators to calculate
6715 normalized address.
6716 (adi_read_versions, adi_write_versions, adi_print_versions)
6717 (do_examine, do_assign): Use paddress.
6718
7755ddb7
JB
67192017-08-29 John Baldwin <jhb@FreeBSD.org>
6720
6721 * mips-fbsd-nat.c (getfpregs_supplies): Return true for FIR.
6722 * mips-fbsd-tdep.c (mips_fbsd_supply_fpregs): Split supply of FSR
6723 out of loop and add supply of FIR.
6724 (mips_fbsd_collect_fpregs): Split collect of FSR out of loop and
6725 add collect of FIR.
6726
fd437cbc
SM
67272017-08-28 Simon Marchi <simon.marchi@ericsson.com>
6728
3804a343 6729 PR gdb/21827
fd437cbc
SM
6730 * cli/cli-script.c (define_command): Don't convert command name
6731 to lower case.
6732
988f6b3d
JB
67332017-08-25 Joel Brobecker <brobecker@adacore.com>
6734
6735 * ada-lang.c (ada_lookup_struct_elt_type): Remove parameter "dispp".
6736 Update all callers accordingly. Remove all code blocks handling
6737 the case where DISPP is not NULL.
6738
663c44ac
JK
67392017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6740
6741 PR symtab/22003
6742 * dwarf2read.c (dwarf2_const_value_attr, dump_die_shallow)
6743 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
6744 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_implicit_const.
6745
f1902523
JK
67462017-08-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6747
6748 * dwarf2read.c (build_type_psymtabs_reader): New prototype.
6749 (process_psymtab_comp_unit): Accept IS_DEBUG_TYPES.
6750 (read_comp_units_from_section): New parameter abbrev_section, use
6751 read_and_check_comp_unit_head, allocate signatured_type if needed.
6752 (create_all_comp_units): Update read_comp_units_from_section caller.
6753
87215ad1
SDJ
67542017-08-23 Pedro Alves <palves@redhat.com>
6755
6756 PR remote/21852
6757 * remote.c (add_current_inferior_and_thread): Set inferior_ptid
6758 to null_ptid and switch to thread without reading the registers
6759 after adding the inferior.
6760
6e41ddec
JK
67612017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6762
6763 * NEWS (Changes since GDB 8.0): Add set compile-gcc and show
6764 compile-gcc.
6765 * compile/compile.c (compile_gcc, show_compile_gcc): New.
6766 (compile_to_object): Implement compile_gcc.
6767 (_initialize_compile): Install "set compile-gcc". Initialize
6768 compile_gcc.
6769
e68c32d5
JK
67702017-08-23 Jan Kratochvil <jan.kratochvil@redhat.com>
6771
6772 * compile/compile.c (compile_to_object): Conditionally call
6773 set_verbose. Conditionally call compile or compile_v0.
6774
58afddc6
WP
67752017-08-07 Weimin Pan <weimin.pan@oracle.com>
6776
6777 * sparc64-tdep.h: (adi_normalize_address): New export.
6778 * sparc-nat.h: (open_adi_tag_fd): New export.
6779 * sparc64-linux-nat.c: (open_adi_tag_fd): New function.
6780 * sparc64-linux-tdep.c:
6781 (SEGV_ACCADI, SEGV_ADIDERR, SEGV_ADIPERR) New defines.
6782 (sparc64_linux_handle_segmentation_fault): New function.
6783 (sparc64_linux_init_abi): Register
6784 sparc64_linux_handle_segmentation_fault
6785 * sparc64-tdep.c: Include cli-utils.h,gdbcmd.h,auxv.h.
6786 (sparc64_addr_bits_remove): New function.
6787 (sparc64_init_abi): Register sparc64_addr_bits_remove.
6788 (MAX_PROC_NAME_SIZE): New macro.
6789 (AT_ADI_BLKSZ, AT_ADI_NBITS, AT_ADI_UEONADI) New defines.
6790 (sparc64adilist): New variable.
6791 (adi_proc_list): New variable.
6792 (find_adi_info): New function.
6793 (add_adi_info): New function.
6794 (get_adi_info_proc): New function.
6795 (get_adi_info): New function.
6796 (info_adi_command): New function.
6797 (read_maps_entry): New function.
6798 (adi_available): New function.
6799 (adi_normalize_address): New function.
6800 (adi_align_address): New function.
6801 (adi_convert_byte_count): New function.
6802 (adi_tag_fd): New function.
6803 (adi_is_addr_mapped): New function.
6804 (adi_read_versions): New function.
6805 (adi_write_versions): New function.
6806 (adi_print_versions): New function.
6807 (do_examine): New function.
6808 (do_assign): New function.
6809 (adi_examine_command): New function.
6810 (adi_assign_command): New function.
6811 (_initialize_sparc64_adi_tdep): New function.
6812
11db9430
SM
68132017-08-22 Simon Marchi <simon.marchi@ericsson.com>
6814
6815 * breakpoint.c (breakpoints_info): Rename to ...
6816 (info_breakpoints_command): ... this.
6817 (watchpoints_info): Rename to ...
6818 (info_watchpoints_command): ... this.
6819 (tracepoints_info): Rename to ...
6820 (info_tracepoints_command): ... this.
6821 (_initialize_breakpoint): Adjust.
6822 * dcache.c (dcache_info): Rename to ...
6823 (info_display_command): ... this.
6824 (_initialize_dcache): Adjust.
6825 * frame.h (args_info): Rename to ...
6826 (info_args_command): ... this.
6827 (locals_info): Rename to ...
6828 (info_locals_command): ... this.
6829 * infcmd.c (nofp_registers_info): Rename to ...
6830 (info_registers_command): ... this.
6831 (float_info): Rename to ...
6832 (info_float_command): ... this.
6833 (program_info): Rename to ...
6834 (info_program_command): ... this.
6835 (all_registers_info): Rename to ...
6836 (info_all_registers_command): ... this.
6837 (vector_info): Rename to ...
6838 (info_vector_command): ... this.
6839 (float_info): Rename to ...
6840 (info_float_command): ... this.
6841 (_initialize_infcmd): Adjust.
6842 * inferior.h (term_info): Rename to ...
6843 (info_terminal_command): ... this.
6844 * inflow.c (term_info): Rename to ...
6845 (info_terminal_command): ... this.
6846 (_initialize_inflow): Adjust.
6847 * infrun.c (signals_info): Rename to ...
6848 (info_signals_command): ... this.
6849 (_initialize_infrun): Adjust.
6850 * objc-lang.c (classes_info): Rename to ...
6851 (info_classes_command): ... this.
6852 (selectors_info): Rename to ...
6853 (info_selectors_command): ... this.
6854 (_initialize_objc_language): Adjust.
6855 * printcmd.c (sym_info): Rename to ...
6856 (info_symbol_command): ... this.
6857 (address_info): Rename to ...
6858 (info_address_command): ... this.
6859 (display_info): Rename to ...
6860 (info_display_command): ... this.
6861 (_initialize_printcmd): Adjust.
6862 * reverse.c (bookmarks_info): Rename to ...
6863 (info_breakpoints_command): ... this.
6864 (_initialize_reverse): Adjust.
6865 * ser-go32.c (dos_info): Rename to ...
6866 (info_serial_command): ... this.
6867 (_initialize_ser_dos): Adjust.
6868 * skip.c (skip_info): Rename to ...
6869 (info_skip_command): ... this.
6870 (_initialize_step_skip): Adjust.
6871 * source.c (line_info): Rename to ...
6872 (info_line_command): ... this.
6873 (source_info): Rename to ...
6874 (info_source_command)
6875 * stack.c (frame_info): Rename to ...
6876 (info_frame_command): ... this.
6877 (locals_info): Rename to ...
6878 (info_locals_command): ... this.
6879 (args_info): Rename to ...
6880 (info_args_command): ... this.
6881 (_initialize_stack): Adjust.
6882 * symtab.c (sources_info): Rename to ...
6883 (info_sources_command): ... this.
6884 (variables_info): Rename to ...
6885 (info_variables_command): ... this.
6886 (functions_info): Rename to ...
6887 (info_functions_command): ... this.
6888 (types_info): Rename to ...
6889 (info_types_command): ... this.
6890 (_initialize_symtab): Adjust.
6891 * target.c (target_info): Rename to ...
6892 (info_target_command): ... this.
6893 (initialize_targets): Adjust.
6894 * tracepoint.c (tvariables_info): Rename to ...
6895 (info_tvariables_command): ... this.
6896 (scope_info): Rename to ...
6897 (info_scope_command): ... this.
6898 (trace_dump_actions): Adjust.
6899 (_initialize_tracepoint): Adjust.
6900
b270e6f9
TT
69012017-08-22 Tom Tromey <tom@tromey.com>
6902
6903 * breakpoint.h (install_breakpoint): Update.
6904 * breakpoint.c (add_solib_catchpoint): Update.
6905 (install_breakpoint): Change argument to a std::unique_ptr.
6906 (create_fork_vfork_event_catchpoint): Use std::unique_ptr.
6907 (create_breakpoint_sal, create_breakpoint): Update.
6908 (watch_command_1, catch_exec_command_1)
6909 (strace_marker_create_breakpoints_sal): Use std::unique_ptr.
6910 (add_to_breakpoint_chain): Change argument to a std::unique_ptr.
6911 Return the breakpoint.
6912 (set_raw_breakpoint_without_location, set_raw_breakpoint)
6913 (new_single_step_breakpoint): Update.
6914 * break-catch-throw.c (handle_gnu_v3_exceptions): Use
6915 std::unique_ptr.
6916 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
6917 std::unique_ptr.
6918 * break-catch-sig.c (create_signal_catchpoint): Use
6919 std::unique_ptr.
6920 * ada-lang.c (create_ada_exception_catchpoint): Use
6921 std::unique_ptr.
6922
36bd8eaa
TT
69232017-08-22 Tom Tromey <tom@tromey.com>
6924
6925 * breakpoint.c (add_solib_catchpoint): Use std::unique_ptr.
6926
56f37645
TT
69272017-08-22 Tom Tromey <tom@tromey.com>
6928
6929 * psymtab.c (psymtab_search_name): Return a unique_xmalloc_ptr.
6930 (lookup_partial_symbol): Update.
6931
0b581c69
TT
69322017-08-22 Tom Tromey <tom@tromey.com>
6933
6934 * source.h (rewrite_source_path): Return a unique_xmalloc_ptr.
6935 * source.c (rewrite_source_path): Return a unique_xmalloc_ptr.
6936 (find_and_open_source, symtab_to_fullname): Update.
6937 * psymtab.c (psymtab_to_fullname): Update.
6938
14278e1f
TT
69392017-08-22 Tom Tromey <tom@tromey.com>
6940
6941 * exec.c (exec_file_attach): Update.
6942 * linux-thread-db.c (try_thread_db_load): Update.
6943 * guile/scm-safe-call.c (gdbscm_safe_source_script): Update.
6944 * utils.c (gdb_realpath): Change return type.
6945 (gdb_realpath_keepfile): Update.
6946 (gdb_realpath_check_trailer, gdb_realpath_tests): New functions.
6947 (_initialize_utils): Register the new self test.
6948 * source.c (openp): Update.
6949 (find_and_open_source): Update.
6950 * nto-tdep.c (nto_find_and_open_solib): Update.
6951 * main.c (set_gdb_data_directory): Update.
6952 (captured_main_1): Update.
6953 * dwarf2read.c (dwarf2_get_dwz_file): Update
6954 (dw2_map_symbol_filenames): Update.
6955 * auto-load.c (auto_load_safe_path_vec_update): Update.
6956 (filename_is_in_auto_load_safe_path_vec): Change type of
6957 "filename_realp".
6958 (auto_load_objfile_script): Update.
6959 (file_is_auto_load_safe): Update. Use std::string.
6960 * utils.h (gdb_realpath): Return a gdb::unique_xmalloc_ptr.
6961
4971c9a7
TT
69622017-08-22 Tom Tromey <tom@tromey.com>
6963
6964 * utils.c (gdb_realpath_keepfile): Return a
6965 gdb::unique_xmalloc_ptr.
6966 * exec.c (exec_file_attach): Update.
6967 * utils.h (gdb_realpath_keepfile): Return a
6968 gdb::unique_xmalloc_ptr.
6969
e3e41d58
TT
69702017-08-22 Tom Tromey <tom@tromey.com>
6971
6972 * compile/compile.c (compile_file_command): Use
6973 gdb::unique_xmalloc_ptr, std::string.
6974 * utils.c (gdb_abspath): Change return type.
6975 * source.c (openp): Update.
6976 * objfiles.c (allocate_objfile): Update.
6977 * main.c (set_gdb_data_directory): Update.
6978 * utils.h (gdb_abspath): Return a gdb::unique_xmalloc_ptr.
6979
0d999a6e
ZZ
69802017-08-22 Zhouyi Zhou <zhouzhouyi@gmail.com>
6981
6982 * cli-cmds.c (list_commands): List actual code around more than
6983 one location.
6984
329d5e7e
JB
69852017-08-21 John Baldwin <jhb@FreeBSD.org>
6986
6987 * fbsd-nat.c (fbsd_add_threads): Use array type for `lwps'.
6988
bf223d3e
PA
69892017-08-21 Pedro Alves <palves@redhat.com>
6990
6991 PR gdb/19487
6992 * c-exp.y (variable production): Handle function aliases.
6993 * minsyms.c (msymbol_is_text): New function.
6994 * minsyms.h (msymbol_is_text): Declare.
6995 * symtab.c (find_function_alias_target): New function.
6996 * symtab.h (find_function_alias_target): Declare.
6997
c973d0aa
PA
69982017-08-21 Pedro Alves <palves@redhat.com>
6999
7000 * eval.c (evaluate_subexp_standard) <OP_TYPE>: Don't dig past
7001 typedefs.
7002 * typeprint.c (whatis_exp): If handling "whatis", and expression
7003 is OP_TYPE, strip one typedef level. Otherwise don't strip
7004 typedefs here.
7005 * valops.c (value_cast): Save "to" type before resolving
7006 stubs/typedefs. Use that type as resulting value's type.
7007
2989a365
TT
70082017-08-18 Tom Tromey <tom@tromey.com>
7009 Pedro Alves <palves@redhat.com>
7010
7011 * spu-multiarch.c (parse_spufs_run): Use scoped_restore.
7012 * sol-thread.c (sol_thread_resume, sol_thread_wait)
7013 (sol_thread_xfer_partial, rw_common): Use scoped_restore.
7014 * procfs.c (procfs_do_thread_registers): Use scoped_restore.
7015 * proc-service.c (ps_xfer_memory): Use scoped_restore.
7016 * linux-tdep.c (linux_corefile_thread): Remove a cleanup.
7017 (linux_get_siginfo_data): Add "thread" argument. Use
7018 scoped_restore.
7019 * linux-nat.c (linux_child_follow_fork)
7020 (check_stopped_by_watchpoint): Use scoped_restore.
7021 * infrun.c (displaced_step_prepare_throw, write_memory_ptid)
7022 (THREAD_STOPPED_BY, handle_signal_stop): Use scoped_restore.
7023 (restore_inferior_ptid, save_inferior_ptid): Remove.
7024 * btrace.c (btrace_fetch): Use scoped_restore.
7025 * bsd-uthread.c (bsd_uthread_fetch_registers)
7026 (bsd_uthread_store_registers): Use scoped_restore.
7027 * breakpoint.c (reattach_breakpoints, detach_breakpoints): Use
7028 scoped_restore.
7029 * aix-thread.c (aix_thread_resume, aix_thread_wait)
7030 (aix_thread_xfer_partial): Use scoped_restore.
7031 * inferior.h (save_inferior_ptid): Remove.
7032
e60eb288
YQ
70332017-08-18 Yao Qi <yao.qi@linaro.org>
7034
7035 PR tdep/21818
7036 * arm-tdep.c (gdb_print_insn_arm): Mark
7037 USER_SPECIFIED_MACHINE_TYPE if exec_bfd isn't NULL.
7038
6d580b63
YQ
70392017-08-18 Yao Qi <yao.qi@linaro.org>
7040
7041 * NEWS: Mention GDBserver's new option "--selftest".
7042 * Makefile.in (SFILES): Remove selftest.c, add common/selftest.c.
7043 * selftest.c: Move it to common/selftest.c.
7044 * selftest.h: Move it to common/selftest.h.
7045 * selftest-arch.c (reset): New function.
7046 (tests_with_arch): Call reset.
7047
86dcbf50
YQ
70482017-08-18 Yao Qi <yao.qi@linaro.org>
7049
7050 * selftest.c (run_tests): Don't call QUIT. Call debug_printf
7051 instead of exception_fprintf and printf_filtered.
7052
7649770c
YQ
70532017-08-18 Yao Qi <yao.qi@linaro.org>
7054
7055 * selftest.c (register_self_test): Rename it to
7056 selftests::register_test.
7057 (run_self_tests): selftest::run_tests.
7058 * selftest.h: Update declarations.
7059 * selftest-arch.c (register_self_test_foreach_arch): Rename it to
7060 selftests::register_test_foreach_arch.
7061 * selftest-arch.h: Update declaration.
7062 * aarch64-tdep.c: Update.
7063 * arm-tdep.c: Likewise.
7064 * disasm-selftests.c: Likewise.
7065 * dwarf2loc.c: Likewise.
7066 * dwarf2-frame.c: Likewise.
7067 * findvar.c: Likewise.
7068 * gdbarch-selftests.c: Likewise.
7069 * maint.c (maintenance_selftest): Likewise.
7070 * regcache.c: Likewise.
7071 * rust-exp.y: Likewise.
7072 * selftest-arch.c: Likewise.
7073 * unittests/environ-selftests.c: Likewise.
7074 * unittests/function-view-selftests.c: Likewise.
7075 * unittests/offset-type-selftests.c: Likewise.
7076 * unittests/optional-selftests.c: Likewise.
7077 * unittests/scoped_restore-selftests.c: Likewise.
7078 * utils-selftests.c: Likewise.
7079
b0cba12e
PA
70802017-08-17 Pedro Alves <palves@redhat.com>
7081
7082 * cli/cli-cmds.c (source_command): Delete 'old_source_verbose'
7083 local.
7084
4c8aa72d
PA
70852017-08-17 Pedro Alves <palves@redhat.com>
7086
7087 * dwarf2read.c (struct dwarf2_cu) <line_header_die_owner>: New
7088 field.
7089 (reset_die_in_process): Delete, replaced by ...
7090 (process_die_scope): ... this new class. Make it responsible for
7091 freeing cu->line_header too.
7092 (process_die): Use process_die_scope.
7093 (handle_DW_AT_stmt_list): Record the line header's owner CU/DIE in
7094 cu->line_header_die_owner. Don't release the line header if it's
7095 owned by the CU.
7096 (setup_type_unit_groups): Make the CU/DIE own the line header.
7097 Don't release the line header here.
7098
ba713918
AL
70992017-08-17 Alex Lindsay <alexlindsay239@gmail.com> (tiny change)
7100
7101 * elfread.c (elf_read_minimal_symbols): xfree synthsyms.
7102
44d0fb3a
RK
71032017-08-17 Ruslan Kabatsayev <b7.10110111@gmail.com>
7104
7105 * NEWS: Mention new shortcuts for nexti and stepi in TUI
7106 Single-Key mode
7107
a5afdb16
RK
71082017-08-16 Ruslan Kabatsayev <b7.10110111@gmail.com>
7109
7110 * tui/tui.c (tui_commands): Add "nexti" and "stepi" to the Single-Key
7111 mode command list.
7112
47613aeb
SH
71132017-08-15 Stafford Horne <shorne@gmail.com>
7114
7115 * MAINTAINERS (Write After Approval): Add Stafford Horne.
7116
9c3cc999
SH
71172017-08-15 Stafford Horne <shorne@gmail.com>
7118
7119 * xtensa-tdep.c (xtensa_init_reggroups): Use xstrdup for cpname.
7120
206726fb
SDJ
71212017-08-15 Sergio Durigan Junior <sergiodj@redhat.com>
7122
7123 PR gdb/21954
7124 * infcmd.c (unset_environment_command): Use the 'clear' method on
7125 the environment instead of resetting it.
7126
0335ac6d
JB
71272017-08-15 John Baldwin <jhb@FreeBSD.org>
7128
7129 * fbsd-nat.c (fbsd_convert_siginfo): Fix compile on big-endian
7130 platforms.
7131
d3abe1c8
TT
71322017-08-14 Tom Tromey <tom@tromey.com>
7133
7134 * valprint.c (print_octal_chars): Use HOST_CHAR_BIT.
7135 (print_binary_chars): Likewise.
7136 (BITS_IN_BYTES): Remove.
7137
d6382fff
TT
71382017-08-14 Tom Tromey <tom@tromey.com>
7139
7140 PR gdb/21675
7141 * valprint.c (LOW_ZERO): Change value to 034.
7142 (print_octal_chars): Add static_asserts for octal constants.
7143 * printcmd.c (print_scalar_formatted): Add 'd' case.
7144
f978cb06
TT
71452017-08-11 Tom Tromey <tom@tromey.com>
7146
7147 * symfile.c (add_symbol_file_command): Use std::vector.
7148
2f5404b3
TT
71492017-08-14 Tom Tromey <tom@tromey.com>
7150
7151 * break-catch-throw.c (handle_gnu_v3_exceptions): Use std::move.
7152 * break-catch-syscall.c (create_syscall_event_catchpoint): Use
7153 std::move.
7154 * break-catch-sig.c (create_signal_catchpoint): Use std::move.
7155
de7985c3
PA
71562017-08-11 Pedro Alves <palves@redhat.com>
7157
7158 * infrun.c (process_event_stop_test): Adjust
7159 function_name_is_marked_for_skip call.
7160 * skip.c: Include <list>.
7161 (skiplist_entry): Make it a class with private fields, and
7162 getters/setters.
7163 (skiplist_entry_chain): Delete.
7164 (skiplist_entries): New.
7165 (skiplist_entry_count): Delete.
7166 (highest_skiplist_entry_num): New.
7167 (ALL_SKIPLIST_ENTRIES, ALL_SKIPLIST_ENTRIES_SAFE): Delete.
7168 (add_skiplist_entry): Delete.
7169 (skiplist_entry::skiplist_entry): New.
7170 (skiplist_entry::add_entry): New.
7171 (skip_file_command, skip_function): Adjust.
7172 (compile_skip_regexp): Delete.
7173 (skip_command): Don't compile regexp here. Adjust to use
7174 skiplist_entry::add_entry.
7175 (skip_info): Adjust to use range-for and getters.
7176 (skip_enable_command, skip_disable_command): Adjust to use
7177 range-for and setters.
7178 (skip_delete_command): Adjust to use std::list.
7179 (add_skiplist_entry): Delete.
7180 (skip_file_p): Delete, refactored as ...
7181 (skiplist_entry::do_skip_file_p): ... this new method.
7182 (skip_gfile_p): Delete, refactored as ...
7183 (skiplist_entry::do_gskip_file_p): ... this new method.
7184 (skip_function_p, skip_rfunction_p): Delete, refactored as ...
7185 (skiplist_entry::skip_function_p): ... this new method.
7186 (function_name_is_marked_for_skip): Now returns bool, and takes
7187 the function sal by const reference. Adjust to use range-for and
7188 skiplist_entry methods.
7189 (_initialize_step_skip): Remove references to
7190 skiplist_entry_chain, skiplist_entry_count.
7191 * skip.h (function_name_is_marked_for_skip): Now returns bool, and
7192 takes the function sal by const reference.
7193
be7d3cd5
YQ
71942017-08-11 Yao Qi <yao.qi@linaro.org>
7195
7196 * dwarf2-frame.c (clear_pointer_cleanup): Remove.
7197 (dwarf2_frame_cache): Remove reset_cache_cleanup.
7198 (dwarf2_frame_cache):
7199 * frame-unwind.c (frame_unwind_try_unwinder): Catch
7200 RETURN_MASK_ALL and set *this_case to NULL.
7201 * frame-unwind.h: Update comments.
7202
1c90d9f0
YQ
72032017-08-11 Yao Qi <yao.qi@linaro.org>
7204
7205 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Remove.
7206 (dwarf2_frame_state_copy_regs): Remove.
7207 (dwarf2_frame_state_free_regs): Remove.
7208 (dwarf2_frame_state::~dwarf2_frame_state): Remove.
7209 (dwarf2_restore_rule): Call method .alloc_regs instead of
7210 dwarf2_frame_state_alloc_regs.
7211 (execute_cfa_program): Likewise. Call dwarf2_frame_state_reg_info
7212 constructor. Call std::move.
7213 (dwarf2_fetch_cfa_info): Don't call dwarf2_frame_state_copy_regs.
7214 (dwarf2_frame_cache): Likewise.
7215
7216 [GDB_SELF_TEST]: Include selftest.h and
7217 selftest-arch.h.
7218 [GDB_SELF_TEST] (execute_cfa_program_test): New function.
7219 (_initialize_dwarf2_frame) [GDB_SELF_TEST]: Register
7220 execute_cfa_program_test.
7221
7222 * dwarf2-frame.h (dwarf2_frame_state_reg_info): Add ctor, dtor,
7223 copy ctor, assignment operator, move assignment.
7224 <alloc_regs>: New method.
7225 <swap>: New method.
7226 (struct dwarf2_frame_state): Delete dtor.
7227 (dwarf2_frame_state_alloc_regs): Remove declaration.
7228 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): Don't call
7229 dwarf2_frame_state_alloc_regs, use .alloc_regs instead.
7230
afe37d6b
YQ
72312017-08-11 Yao Qi <yao.qi@linaro.org>
7232
7233 * dwarf2-frame.c (dwarf2_frame_state_free): Remove.
7234 (dwarf2_frame_state::dwarf2_frame_state): New.
7235 (dwarf2_frame_state::~dwarf2_frame_state): New.
7236 (dwarf2_fetch_cfa_info): Update.
7237 (dwarf2_frame_cache): Remove old_chain. Change 'fs' to an object
7238 rather than a pointer. Update code.
7239 * dwarf2-frame.h (struct dwarf2_frame_state): Declare ctor and
7240 dtor.
7241 <data_align, code_align, retaddr_column>: Change them to const.
7242 <armcc_cfa_offsets_sf, armcc_cfa_offsets_reversed>: Change them
7243 to bool.
7244
b348037f
YQ
72452017-08-11 Yao Qi <yao.qi@linaro.org>
7246
7247 * dwarf2-frame.h (struct dwarf2_frame_state_reg) <exp_len>: Remove.
7248 <loc.exp>: New field.
7249 * dwarf2-frame.c (execute_cfa_program): Update.
7250 (dwarf2_frame_prev_register): Update.
7251
e7c9de26
PA
72522017-08-10 Pedro Alves <palves@redhat.com>
7253
7254 * common/gdb_unique_ptr.h (xfree_deleter<T[]>): Define.
7255
e8c6b620
JB
72562017-08-09 John Baldwin <jhb@FreeBSD.org>
7257
7258 * fbsd-nat.c (struct fbsd_fork_info): Remove.
7259 (fbsd_pending_children): Use std::list.
7260 (fbsd_remember_child): Likewise.
7261 (fbsd_is_child_pending): Likewise.
7262 (fbsd_pending_vfork_done): Use std::forward_list.
7263 (fbsd_add_vfork_done): Likewise.
7264 (fbsd_is_vfork_done_pending): Likewise.
7265 (fbsd_next_vfork_done): Likewise.
7266
e4a26669
JB
72672017-08-09 John Baldwin <jhb@FreeBSD.org>
7268
7269 * fbsd-nat.c [HAVE_KINFO_GETVMMAP] (struct free_deleter): New.
7270 (fbsd_find_memory_regions): Use free_deleter with std::unique_ptr.
7271 [!HAVE_KINFO_GETVMMAP] (fbsd_find_memory_regions): Use std::string
7272 for `mapfilename'.
7273 (fbsd_xfer_partial): Use gdb::byte_vector.
af3881e6 7274 (fbsd_add_threads): Use gdb::unique_xmalloc_ptr.
e4a26669 7275
142311d3
JB
72762017-08-09 John Baldwin <jhb@FreeBSD.org>
7277
7278 * fbsd-nat.c: [!HAVE_KINFO_GETVMMAP]: Include <sys/user.h> and
7279 "filestuff.h".
7280 (fbsd_find_memory_regions): Fix `mapfile' initialization.
7281
42fa2e0e
TT
72822017-08-09 Tom Tromey <tom@tromey.com>
7283
7284 * skip.c (skiplist_entry): New constructor.
7285 (skiplist_entry::enabled, skiplist_entry::function_is_regexp)
7286 (skiplist_entry::file_is_glob): Now bool.
7287 (skiplist_entry::file, skiplist_entry::function): Now
7288 std::string.
7289 (make_skip_entry): Return a unique_ptr. Use new.
7290 (free_skiplist_entry, free_skiplist_entry_cleanup)
7291 (make_free_skiplist_entry_cleanup): Remove.
7292 (skip_command, skip_disable_command, add_skiplist_entry)
7293 (skip_form_bytes, compile_skip_regexp, skip_command, skip_info)
7294 (skip_file_p, skip_gfile_p, skip_function_p, skip_rfunction_p)
7295 (function_name_is_marked_for_skip): Update.
7296 (skip_delete_command): Update. Use delete.
7297
cd3af38d
JW
72982017-08-09 Jiong Wang <jiong.wang@arm.com>
7299
7300 * aarch64-linux-tdep.c: Include "auxv.h" and "elf/common.h".
7301 (aarch64_linux_core_read_description): New function.
7302 (aarch64_linux_init_abi): Register gdbarch_core_read_description.
7303
29592bde
PA
73042017-08-09 Pedro Alves <palves@redhat.com>
7305
7306 * cp-name-parser.y (cp_comp_to_string): Return a
7307 gdb::unique_xmalloc_ptr<char>.
7308 * cp-support.c (replace_typedefs_qualified_name)
7309 (replace_typedefs): Adjust to use gdb::unique_xmalloc_ptr<char>.
7310 (cp_canonicalize_string_full): Use op= instead of explicit
7311 convertion.
7312 (cp_class_name_from_physname, method_name_from_physname)
7313 (cp_func_name, cp_remove_params): Adjust to use
7314 gdb::unique_xmalloc_ptr<char>.
7315 * cp-support.h (cp_comp_to_string): Return a
7316 gdb::unique_xmalloc_ptr<char>.
7317 * python/py-type.c (typy_lookup_type): Adjust to use
7318 gdb::unique_xmalloc_ptr<char>.
7319
b3340438
L
73202017-08-09 H.J. Lu <hongjiu.lu@intel.com>
7321
7322 * dwarf2read.c (dwarf2_string_attr): Fix a typo.
7323
e88e8651
YQ
73242017-08-09 Alex Lindsay <alexlindsay239@gmail.com>
7325 Yao Qi <yao.qi@linaro.org>
7326
7327 * cp-support.c (cp_canonicalize_string_full): Use
7328 gdb::unique_xmalloc_ptr<char>.
7329 (cp_canonicalize_string): Likewise.
7330
f5a29eb0
YQ
73312017-08-09 Yao Qi <yao.qi@linaro.org>
7332
7333 * features/Makefile (WHICH): Remove i386/ non-linux stuff.
7334 * regformats/i386/amd64-avx-avx512.dat: Remove.
7335 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Remove.
7336 * regformats/i386/amd64-avx-mpx.dat:Remove.
7337 * regformats/i386/amd64-avx.dat: Remove.
7338 * regformats/i386/amd64-mpx.dat: Remove.
7339 * regformats/i386/i386-avx-avx512.dat: Remove.
7340 * regformats/i386/i386-avx-mpx-avx512-pku.dat: Remove.
7341 * regformats/i386/i386-avx-mpx.dat: Remove.
7342 * regformats/i386/i386-mmx.dat: Remove.
7343 * regformats/i386/i386-mpx.dat: Remove.
7344
57757c2f
YQ
73452017-08-09 Yao Qi <yao.qi@linaro.org>
7346
7347 * amd64-tdep.h (tdesc_x32): Remove the declaration.
7348 * amd64-tdep.c: Don't include features/i386/x32*.c.
7349 (_initialize_amd64_tdep): Don't call initialize_tdesc_x32*
7350 functions.
7351 * features/Makefile (WHICH): Remove i386/x32, i386/x32-avx,
7352 and i386/x32-avx-avx512.
7353 (XMLTOC): Remove i386/x32-avx.xml, i386/x32-avx-avx512.xml,
7354 and i386/x32.xml.
7355 * features/i386/x32-avx-avx512.c: Removed.
7356 * features/i386/x32-avx-avx512.xml: Removed.
7357 * features/i386/x32-avx.c: Removed.
7358 * features/i386/x32-avx.xml: Removed.
7359 * features/i386/x32.c: Removed.
7360 * features/i386/x32.xml: Removed.
7361 * regformats/i386/x32-avx-avx512.dat: Removed.
7362 * regformats/i386/x32-avx.dat: Removed.
7363 * regformats/i386/x32.dat: Removed.
7364
ba7b109b
MR
73652017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7366
7367 PR breakpoints/21886
7368 * mem-break.c (default_memory_insert_breakpoint): Use
7369 `->placed_address' rather than `->reqstd_address' for the
7370 breakpoint location.
7371
e347efc3
MR
73722017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7373
7374 * arch-utils.c (default_print_insn): Remove arch/mach/endian
7375 assertions.
7376
0dba2a6c
MR
73772017-08-07 Maciej W. Rozycki <macro@imgtec.com>
7378
7379 * gdbarch.sh (gdbarch_info): Replace the `tdep_info' member with
7380 a union of `tdep_info', `tdesc_data' and `id'.
7381 * aarch64-tdep.c (aarch64_gdbarch_init): Use `info.tdesc_data'
7382 rather than `info.tdep_info'.
7383 * amd64-linux-tdep.c (amd64_linux_init_abi): Likewise.
7384 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
7385 * i386-tdep.c (i386_gdbarch_init): Likewise.
7386 * mips-linux-tdep.c (mips_linux_init_abi): Likewise.
7387 * mips-tdep.c (mips_gdbarch_init): Likewise.
7388 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
7389 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
7390 * ppc-linux-tdep.c (ppu2spu_sniffer): Use `info.id' rather than
7391 `info.tdep_info'.
7392 (ppc_linux_init_abi): Use `info.tdesc_data' rather than
7393 `info.tdep_info'.
7394 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
7395 * spu-multiarch.c (spu_gdbarch): Use `info.id' rather than
7396 `info.tdep_info'.
7397 * spu-tdep.c (spu_gdbarch_init): Likewise.
7398 * gdbarch.h: Regenerate.
7399
16eb6b2d
LS
74002017-08-07 Leszek Swirski <leszeks@google.com>
7401
7b005726 7402 PR symtab/20899
16eb6b2d
LS
7403 * dwarf2read.c (dwarf2_string_attr): Allow DW_FORM_GNU_strp_alt.
7404
74cbb09e
SM
74052017-08-07 Simon Marchi <simon.marchi@ericsson.com>
7406
7407 * remote-sim.c (gdbsim_load): Remove char **argv local variable.
7408 (gdbsim_open): Rename gdb_argv args object to argv.
7409
ee0c3293
TT
74102017-08-05 Tom Tromey <tom@tromey.com>
7411
7412 * compile/compile-object-load.c (compile_object_load): Use
7413 gdb::unique_xmalloc_ptr.
7414 * cli/cli-dump.c (scan_filename): Rename from
7415 scan_filename_with_cleanup. Change return type.
7416 (scan_expression): Rename from scan_expression_with_cleanup.
7417 Change return type.
7418 (dump_memory_to_file, dump_value_to_file, restore_command):
7419 Use gdb::unique_xmalloc_ptr. Update.
7420 * cli/cli-cmds.c (find_and_open_script): Use
7421 gdb::unique_xmalloc_ptr.
7422 * tracefile-tfile.c (tfile_open): Use gdb::unique_xmalloc_ptr.
7423 * symmisc.c (maintenance_print_symbols)
7424 (maintenance_print_msymbols): Use gdb::unique_xmalloc_ptr.
7425 * symfile.c (symfile_bfd_open, generic_load)
7426 (add_symbol_file_command, remove_symbol_file_command): Use
7427 gdb::unique_xmalloc_ptr.
7428 * source.c (openp): Use gdb::unique_xmalloc_ptr.
7429 * psymtab.c (maintenance_print_psymbols): Use
7430 gdb::unique_xmalloc_ptr.
7431 * corelow.c (core_open): Use gdb::unique_xmalloc_ptr.
7432 * breakpoint.c (save_breakpoints): Use gdb::unique_xmalloc_ptr.
7433 * solib.c (solib_map_sections): Use gdb::unique_xmalloc_ptr.
7434 (reload_shared_libraries_1): Likewise.
7435
3232fabd
TT
74362017-08-05 Tom Tromey <tom@tromey.com>
7437
7438 * rust-exp.y (rust_op_ptr, set_field): Remove typedefs.
7439 (rust_op_vector, rust_set_vector): New typedefs.
7440 (current_parser): New global.
7441 (work_obstack): Change to pointer type. Update all users.
7442 (rust_ast, pstate): Remove globals.
7443 (struct rust_parser): New.
7444 (%union) <params, field_inits>: Change type.
7445 (start, tuple_expr, unit_expr, struct_expr_list, literal)
7446 (field_expr, expr_list, maybe_expr_list, type_list): Update.
7447 (ast_call_ish, ast_path, ast_function_type, ast_tuple_type)
7448 (convert_params_to_types, convert_params_to_expression): Change
7449 type of "params".
7450 (ast_string): Change type of "fields".
7451 (rust_parse): Make a rust_parser. Remove cleanups.
7452 (rust_lex_tests): Make and install an auto_obstack.
7453
f02fd774
YQ
74542017-08-04 Yao Qi <yao.qi@linaro.org>
7455
7456 * configure.srv (ipa_x32_linux_regobj): New.
7457 * linux-amd64-ipa.c (get_ipa_tdesc): Use X86_TDESC_AVX_AVX512
7458 instead of X86_TDESC_AVX512.
7459 (initialize_low_tracepoint): Call
7460 init_registers_x32_avx_avx512_linux.
7461
91975afd
YQ
74622017-08-04 Yao Qi <yao.qi@linaro.org>
7463
7464 * utils.h (gdb_argv): Add namespace std for nullptr_t.
7465
2331fa3a
RK
74662017-08-03 Ruslan Kabatsayev <b7.10110111@gmail.com>
7467
7468 * MAINTAINERS (Write After Approval): Add Ruslan Kabatsayev.
7469
744e4fe1
TT
74702017-08-03 Tom Tromey <tom@tromey.com>
7471
7472 * utils.c (make_cleanup_freeargv, do_freeargv, gdb_buildargv):
7473 Remove.
7474 * utils.h (make_cleanup_freeargv, gdb_buildargv): Remove.
7475
1c034b67
TT
74762017-08-03 Tom Tromey <tom@tromey.com>
7477
7478 * python/py-param.c (compute_enum_values): Use gdb_argv.
7479
773a1edc
TT
74802017-08-03 Tom Tromey <tom@tromey.com>
7481
7482 * utils.h (struct gdb_argv_deleter): New.
7483 (gdb_argv): New class.
7484 * utils.c (gdb_argv::reset): New method.
7485 * tracepoint.c (delete_trace_variable_command): Use gdb_argv.
7486 * tracefile.c (tsave_command): Use gdb_argv.
7487 * top.c (new_ui_command): Use gdb_argv.
7488 * symmisc.c (maintenance_print_symbols)
7489 (maintenance_print_msymbols, maintenance_expand_symtabs): Use gdb_argv.
7490 * symfile.c (symbol_file_command, generic_load)
7491 (remove_symbol_file_command): Use gdb_argv.
7492 * stack.c (backtrace_command): Use gdb_argv.
7493 * source.c (add_path, show_substitute_path_command)
7494 (unset_substitute_path_command, set_substitute_path_command):
7495 Use gdb_argv.
7496 * skip.c (skip_command): Use gdb_argv. Use gdb_buildargv.
7497 * ser-mingw.c (pipe_windows_open): Use gdb_argv.
7498 * remote.c (extended_remote_run, remote_put_command)
7499 (remote_get_command, remote_delete_command): Use gdb_argv.
7500 * remote-sim.c (gdbsim_load, gdbsim_create_inferior)
7501 (gdbsim_open): Use gdb_argv.
7502 * python/py-cmd.c (gdbpy_string_to_argv): Use gdb_argv.
7503 * psymtab.c (maintenance_print_psymbols): Use gdb_argv.
7504 * procfs.c (procfs_info_proc): Use gdb_argv.
7505 * interps.c (interpreter_exec_cmd): Use gdb_argv.
7506 * infrun.c (handle_command): Use gdb_argv.
7507 * inferior.c (add_inferior_command, clone_inferior_command):
7508 Use gdb_argv.
7509 * guile/scm-string.c (gdbscm_string_to_argv): Use gdb_argv.
7510 * exec.c (exec_file_command): Use gdb_argv.
7511 * cli/cli-cmds.c (alias_command): Use gdb_argv.
7512 * compile/compile.c (build_argc_argv): Use gdb_argv.
7513
0d50bde3
TT
75142017-08-03 Tom Tromey <tom@tromey.com>
7515
7516 * python/python.c (gdbpy_decode_line): Use unique_xmalloc_ptr.
7517
7f968c89
TT
75182017-08-03 Tom Tromey <tom@tromey.com>
7519
7520 * python/python.c (compute_python_string): Return std::string.
7521 (gdbpy_eval_from_control_command): Update.
7522 (do_start_initialization): Use std::string.
7523 * python/py-varobj.c (py_varobj_iter_next): Use string_printf, not
7524 xstrprintf.
7525 * python/py-breakpoint.c (local_setattro): Use string_printf, not
7526 xstrprintf.
7527
3c9ebddd
TT
75282017-08-03 Tom Tromey <tom@tromey.com>
7529
7530 * top.h (do_restore_instream_cleanup): Remove.
7531 * top.c (do_restore_instream_cleanup): Remove.
7532 (read_command_file): Use scoped_restore.
7533 * cli/cli-script.c (execute_user_command): Use scoped_restore.
7534
b51b225e
TT
75352017-08-03 Tom Tromey <tom@tromey.com>
7536
7537 * cli/cli-script.c (execute_user_command)
7538 (execute_control_command): Use scoped_restore.
7539
ac991630
TT
75402017-08-03 Tom Tromey <tom@tromey.com>
7541
7542 * cli/cli-script.c (do_restore_user_call_depth): Remove.
7543 (execute_user_command): Remove user_call_depth; use
7544 user_args_stack's size instead.
7545
898e0c8e
TT
75462017-08-03 Tom Tromey <tom@tromey.com>
7547
7548 * top.h (in_user_command): Remove.
7549 * top.c (in_user_command): Remove.
7550 * cli/cli-script.c (do_restore_user_call_depth)
7551 (execute_user_command): Update.
7552
26fcd5d7
TT
75532017-08-03 Tom Tromey <tom@tromey.com>
7554
7555 * valops.c (search_struct_method): Use gdb::byte_vector.
7556 * valarith.c (value_concat): Use std::vector.
7557 * target.c (memory_xfer_partial): Use gdb::byte_vector.
7558 (simple_search_memory): Likewise.
7559 * printcmd.c (find_string_backward): Use gdb::byte_vector.
7560 * mi/mi-main.c (mi_cmd_data_write_memory): Use gdb::byte_vector.
7561 * gcore.c (gcore_copy_callback): Use gdb::byte_vector.
7562 * elfread.c (elf_rel_plt_read): Use std::string.
7563 * cp-valprint.c (cp_print_value): Use gdb::byte_vector.
7564 * cli/cli-dump.c (restore_section_callback): Use
7565 gdb::byte_vector.
7566
7c218e6c
TT
75672017-08-03 Tom Tromey <tom@tromey.com>
7568
7569 * jit.c (jit_reader_load_command): Use unique_xmalloc_ptr.
7570
31b68d4a
TT
75712017-08-03 Tom Tromey <tom@tromey.com>
7572
7573 * tui/tui-regs.c (tui_restore_gdbout): Remove.
7574 (tui_register_format): Use scoped_restore.
7575
2ec845e7
TT
75762017-08-03 Tom Tromey <tom@tromey.com>
7577
7578 * reverse.c (exec_direction_default): Remove.
7579 (exec_reverse_once): Use scoped_restore.
7580 * remote.c (restore_remote_timeout): Remove.
7581 (remote_flash_erase, remote_flash_write, remote_flash_done)
7582 (readchar, remote_serial_write): Use scoped_restore.
7583 * cli/cli-script.c (struct source_cleanup_lines_args)
7584 (source_cleanup_lines): Remove.
7585 (script_from_file): Use scoped_restore.
7586 * cli/cli-cmds.c (source_verbose_cleanup): Remove.
7587 (source_command): Use scoped_restore.
7588
b3bc8453
TT
75892017-08-03 Tom Tromey <tom@tromey.com>
7590
7591 * utils.h (make_cleanup_free_so): Remove.
7592 * utils.c (do_free_so, make_cleanup_free_so): Remove.
7593 * solist.h (struct so_deleter): New.
7594 (so_list_up): New typedef.
7595 * solib-svr4.c (svr4_read_so_list): Use so_list_up.
7596
e3ad2841
TT
75972017-08-03 Tom Tromey <tom@tromey.com>
7598
7599 * utils.h (make_cleanup_restore_current_language): Remove.
7600 * utils.c (do_restore_current_language)
7601 (make_cleanup_restore_current_language): Remove.
7602 * parse.c (parse_exp_in_context_1)
7603 (parse_expression_with_language): Use
7604 scoped_restore_current_language.
7605 * mi/mi-main.c (mi_cmd_execute): Use
7606 scoped_restore_current_language.
7607 * language.h (scoped_restore_current_language): New class.
7608
b80cf838
TT
76092017-08-03 Tom Tromey <tom@tromey.com>
7610
7611 * compile/compile.c (cleanup_unlink_file): Remove.
7612 (compile_to_object): Use gdb::unlinker.
7613 (eval_compile_command): Likewise.
7614
fad0444a
TT
76152017-08-03 Tom Tromey <tom@tromey.com>
7616
7617 * utils.h (make_cleanup_fclose): Remove.
7618 * utils.c (do_fclose_cleanup, make_cleanup_fclose): Remove.
7619
6e7bc05c
TT
76202017-08-03 Tom Tromey <tom@tromey.com>
7621
7622 * top.c (open_terminal_stream): Return gdb_file_up.
7623 (new_ui_command): Update.
7624
4a45905b
TT
76252017-08-03 Tom Tromey <tom@tromey.com>
7626
7627 * source.c (print_source_lines_base, forward_search_command)
7628 (reverse_search_command): Use gdb_file_up.
7629
7cd06d6e
TT
76302017-08-03 Tom Tromey <tom@tromey.com>
7631
7632 * fbsd-nat.c (fbsd_find_memory_regions): Update.
7633
ed166945
TT
76342017-08-03 Tom Tromey <tom@tromey.com>
7635
7636 * cli/cli-cmds.c (find_and_open_script): Change return type.
7637 Remove "streamp" and "full_path" parameters.
7638 (source_script_with_search): Update.
7639 * auto-load.c (source_script_file): Update.
7640 * cli/cli-cmds.h (find_and_open_script): Change type.
7641 (open_script): New struct.
7642
d419f42d
TT
76432017-08-03 Tom Tromey <tom@tromey.com>
7644
7645 * xml-support.c (xml_fetch_content_from_file): Update.
7646 * ui-file.c (stdio_file::open): Update.
7647 * tracefile-tfile.c (tfile_start): Update.
7648 * remote.c (remote_file_put, remote_file_get): Update.
7649 * nat/linux-procfs.c (linux_proc_get_int)
7650 (linux_proc_pid_get_state, linux_proc_tid_get_name): Update.
7651 * nat/linux-osdata.c (linux_common_core_of_thread): Update.
7652 (command_from_pid, commandline_from_pid, linux_xfer_osdata_cpus)
7653 (print_sockets, linux_xfer_osdata_shm, linux_xfer_osdata_sem)
7654 (linux_xfer_osdata_msg, linux_xfer_osdata_modules): Update.
7655 * nat/linux-btrace.c (linux_determine_kernel_start): Update.
7656 * linux-nat.c (linux_proc_pending_signals): Update.
7657 * dwarf2read.c (write_psymtabs_to_index): Use gdb_file_up.
7658 (file_closer): Remove.
7659 * compile/compile.c (compile_to_object): Update.
7660 * common/filestuff.h (struct gdb_file_deleter): New.
7661 (gdb_file_up): New typedef.
7662 (gdb_fopen_cloexec): Change return type.
7663 * common/filestuff.c (gdb_fopen_cloexec): Return gdb_file_up.
7664 * cli/cli-dump.c (fopen_with_cleanup): Remove.
7665 (dump_binary_file, restore_binary_file): Update.
7666 * auto-load.c (auto_load_objfile_script_1): Update.
7667
4a2b031d
TT
76682017-08-03 Tom Tromey <tom@tromey.com>
7669
7670 * tracepoint.c (tvariables_info_1): Use ui_out_emit_table.
7671 (info_static_tracepoint_markers_command): Likewise.
7672 * solib.c (info_sharedlibrary_command): Use ui_out_emit_table.
7673 * skip.c (skip_info): Use ui_out_emit_table.
7674 * progspace.c (print_program_space): Use ui_out_emit_table.
7675 * osdata.c (info_osdata): Use ui_out_emit_table.
7676 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions): Use
7677 ui_out_emit_table.
7678 * linux-thread-db.c (info_auto_load_libthread_db): Use
7679 ui_out_emit_table.
7680 * inferior.c (print_inferior): Use ui_out_emit_table.
7681 * gdb_bfd.c (maintenance_info_bfds): Use ui_out_emit_table.
7682 * breakpoint.c (breakpoint_1): Use ui_out_emit_table.
7683 * auto-load.c (auto_load_info_scripts): Use ui_out_emit_table.
7684 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_table.
7685 * ui-out.h (class ui_out_emit_table): New.
7686
a4f320fd
MR
76872017-08-02 Maciej W. Rozycki <macro@imgtec.com>
7688
7689 * mips-tdep.c (mips_fpu_type_str): New function.
7690 (mips_dump_tdep): Call it.
7691
a2f1f308
MR
76922017-08-01 Maciej W. Rozycki <macro@imgtec.com>
7693
7694 * mips-tdep.c (mips_gdbarch_init): Use MIPS_FPU_TYPE to access
7695 `->mips_fpu_type'.
7696
7e5ed83b
XR
76972017-07-31 Xavier Roirand <roirand@adacore.com>
7698
7699 * solib-darwin.c (DYLD_VERSION_MAX): Increase value.
7700
4c9dc811
XR
77012017-07-27 Xavier Roirand <roirand@adacore.com>
7702
7703 * MAINTAINERS (Write After Approval): Add Xavier Roirand.
7704
27d41eac
YQ
77052017-07-26 Yao Qi <yao.qi@linaro.org>
7706
7707 * cli/cli-cmds.c (maintenancechecklist): New variable.
7708 * gdbcmd.h (maintenancechecklist): Declare it.
7709 * i386-linux-tdep.c (_initialize_i386_linux_tdep) [GDB_SELF_TEST]:
7710 Call i386_linux_read_description with different masks.
7711 * maint.c (maintenance_check_command): New function.
7712 (_initialize_maint_cmds): Call add_prefix_cmd.
7713 * target-descriptions.c (tdesc_reg): override operator != and ==.
7714 (tdesc_type): Likewise.
7715 (tdesc_feature): Likewise.
7716 (target_desc): Likewise.
7717 [GDB_SELF_TEST] (selftests::record_xml_tdesc): New function.
7718 (maintenance_check_xml_descriptions): New function.
7719 (_initialize_target_descriptions) Add command "xml-descriptions".
7720 * target-descriptions.h (selftests::record_xml_tdesc): Declare.
7721
ea03d0d3
YQ
77222017-07-26 Yao Qi <yao.qi@linaro.org>
7723
7724 * i386-linux-tdep.c: Don't include features/i386/i386-*linux.c.
7725 Include features/i386/32bit-*.c.
7726 (i386_linux_read_description): Generate target description if it
7727 doesn't exist.
7728 (_initialize_i386_linux_tdep): Don't call _initialize_tdesc_i386
7729 functions.
7730 * features/i386/32bit-linux.c: Re-generated.
7731 * features/i386/32bit-sse.c: Likewise.
7732 * target-descriptions.c (print_c_feature::visit): Print code to
7733 set register number if needed.
7734 (print_c_feature) <m_next_regnum>: New field.
7735
25aa13e5
YQ
77362017-07-26 Yao Qi <yao.qi@linaro.org>
7737
7738 * features/Makefile (CFILES): Rename with TDESC_CFILES.
7739 (FEATURE_XMLFILES): New.
7740 (FEATURE_CFILES): New.
7741 New rules.
7742 (clean-cfiles): Remove generated c files.
7743 * features/i386/32bit-avx.c: Generated.
7744 * features/i386/32bit-avx512.c: Generated.
7745 * features/i386/32bit-core.c: Generated.
7746 * features/i386/32bit-linux.c: Generated.
7747 * features/i386/32bit-mpx.c: Generated.
7748 * features/i386/32bit-pkeys.c: Generated.
7749 * features/i386/32bit-sse.c: Generated.
7750 * target-descriptions.c: Include algorithm.
7751 (tdesc_element_visitor): Add method visit_end.
7752 (print_c_tdesc): Implement visit_end.
7753 (print_c_tdesc:: m_filename_after_features): Move it to
7754 protected.
7755 (print_c_feature): New class.
7756 (maint_print_c_tdesc_cmd): Use print_c_feature if XML file
7757 name starts with "i386/32bit-".
7758
6eb1e6a8
YQ
77592017-07-26 Yao Qi <yao.qi@linaro.org>
7760
7761 * target-descriptions.c (tdesc_element_visitor): New class.
7762 (tdesc_element): New class.
7763 (tdesc_reg): Inherit from tdesc_element.
7764 (tdesc_reg::accept): New function.
7765 (tdesc_type): Inherit from tdesc_element.
7766 (tdesc_type::accept): New function.
7767 (tdesc_feature): Inherit from tdesc_element.
7768 (tdesc_feature::accept): New function.
7769 (target_desc): Inherit from tdesc_element.
7770 (target_desc::target_desc): New.
7771 (target_desc::~target_desc): New.
7772 (target_desc::accept): New.
7773 (allocate_target_description): Use new.
7774 (free_target_description): Use delete.
7775 (print_c_tdesc): New class.
7776 (maint_print_c_tdesc_cmd): Adjust.
7777
7778 * features/aarch64.c: Re-generated.
7779 * features/arc-arcompact.c: Re-generated.
7780 * features/arc-v2.c: Re-generated.
7781 * features/arm/arm-with-iwmmxt.c: Re-generated.
7782 * features/arm/arm-with-m.c: Re-generated.
7783 * features/arm/arm-with-m-fpa-layout.c: Re-generated.
7784 * features/arm/arm-with-m-vfp-d16.c: Re-generated.
7785 * features/arm/arm-with-neon.c: Re-generated.
7786 * features/arm/arm-with-vfpv2.c: Re-generated.
7787 * features/arm/arm-with-vfpv3.c: Re-generated.
7788 * features/i386/amd64-avx-avx512.c: Re-generated.
7789 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
7790 * features/i386/amd64-avx.c: Re-generated.
7791 * features/i386/amd64-avx-linux.c: Re-generated.
7792 * features/i386/amd64-avx-mpx-avx512-pku.c: Re-generated.
7793 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
7794 * features/i386/amd64-avx-mpx.c: Re-generated.
7795 * features/i386/amd64-avx-mpx-linux.c: Re-generated.
7796 * features/i386/amd64.c: Re-generated.
7797 * features/i386/amd64-linux.c: Re-generated.
7798 * features/i386/amd64-mpx.c: Re-generated.
7799 * features/i386/amd64-mpx-linux.c: Re-generated.
7800 * features/i386/i386-avx-avx512.c: Re-generated.
7801 * features/i386/i386-avx-avx512-linux.c: Re-generated.
7802 * features/i386/i386-avx.c: Re-generated.
7803 * features/i386/i386-avx-linux.c: Re-generated.
7804 * features/i386/i386-avx-mpx-avx512-pku.c: Re-generated.
7805 * features/i386/i386-avx-mpx-avx512-pku-linux.c: Re-generated.
7806 * features/i386/i386-avx-mpx.c: Re-generated.
7807 * features/i386/i386-avx-mpx-linux.c: Re-generated.
7808 * features/i386/i386.c: Re-generated.
7809 * features/i386/i386-linux.c: Re-generated.
7810 * features/i386/i386-mmx.c: Re-generated.
7811 * features/i386/i386-mmx-linux.c: Re-generated.
7812 * features/i386/i386-mpx.c: Re-generated.
7813 * features/i386/i386-mpx-linux.c: Re-generated.
7814 * features/i386/x32-avx-avx512.c: Re-generated.
7815 * features/i386/x32-avx-avx512-linux.c: Re-generated.
7816 * features/i386/x32-avx.c: Re-generated.
7817 * features/i386/x32-avx-linux.c: Re-generated.
7818 * features/i386/x32.c: Re-generated.
7819 * features/i386/x32-linux.c: Re-generated.
7820 * features/microblaze.c: Re-generated.
7821 * features/microblaze-with-stack-protect.c: Re-generated.
7822 * features/mips64-dsp-linux.c: Re-generated.
7823 * features/mips64-linux.c: Re-generated.
7824 * features/mips-dsp-linux.c: Re-generated.
7825 * features/mips-linux.c: Re-generated.
7826 * features/nds32.c: Re-generated.
7827 * features/nios2.c: Re-generated.
7828 * features/nios2-linux.c: Re-generated.
7829 * features/rs6000/powerpc-32.c: Re-generated.
7830 * features/rs6000/powerpc-32l.c: Re-generated.
7831 * features/rs6000/powerpc-403.c: Re-generated.
7832 * features/rs6000/powerpc-403gc.c : Re-generated.
7833 * features/rs6000/powerpc-405.c: Re-generated.
7834 * features/rs6000/powerpc-505.c: Re-generated.
7835 * features/rs6000/powerpc-601.c: Re-generated.
7836 * features/rs6000/powerpc-602.c: Re-generated.
7837 * features/rs6000/powerpc-603.c: Re-generated.
7838 * features/rs6000/powerpc-604.c: Re-generated.
7839 * features/rs6000/powerpc-64.c: Re-generated.
7840 * features/rs6000/powerpc-64l.c: Re-generated.
7841 * features/rs6000/powerpc-7400.c: Re-generated.
7842 * features/rs6000/powerpc-750.c: Re-generated.
7843 * features/rs6000/powerpc-860.c: Re-generated.
7844 * features/rs6000/powerpc-altivec32.c: Re-generated.
7845 * features/rs6000/powerpc-altivec32l.c: Re-generated.
7846 * features/rs6000/powerpc-altivec64.c: Re-generated.
7847 * features/rs6000/powerpc-altivec64l.c: Re-generated.
7848 * features/rs6000/powerpc-cell32l.c: Re-generated.
7849 * features/rs6000/powerpc-cell64l.c: Re-generated.
7850 * features/rs6000/powerpc-e500.c: Re-generated.
7851 * features/rs6000/powerpc-e500l.c: Re-generated.
7852 * features/rs6000/powerpc-isa205-32l.c: Re-generated.
7853 * features/rs6000/powerpc-isa205-64l.c: Re-generated.
7854 * features/rs6000/powerpc-isa205-altivec32l.c: Re-generated.
7855 * features/rs6000/powerpc-isa205-altivec64l.c: Re-generated.
7856 * features/rs6000/powerpc-isa205-vsx32l.c: Re-generated.
7857 * features/rs6000/powerpc-isa205-vsx64l.c: Re-generated.
7858 * features/rs6000/powerpc-vsx32.c: Re-generated.
7859 * features/rs6000/powerpc-vsx32l.c: Re-generated.
7860 * features/rs6000/powerpc-vsx64.c: Re-generated.
7861 * features/rs6000/powerpc-vsx64l.c: Re-generated.
7862 * features/rs6000/rs6000.c: Re-generated.
7863 * features/s390-linux32.c: Re-generated.
7864 * features/s390-linux32v1.c: Re-generated.
7865 * features/s390-linux32v2.c: Re-generated.
7866 * features/s390-linux64.c: Re-generated.
7867 * features/s390-linux64v1.c: Re-generated.
7868 * features/s390-linux64v2.c: Re-generated.
7869 * features/s390-te-linux64.c: Re-generated.
7870 * features/s390-tevx-linux64.c: Re-generated.
7871 * features/s390-vx-linux64.c: Re-generated.
7872 * features/s390x-linux64.c: Re-generated.
7873 * features/s390x-linux64v1.c: Re-generated.
7874 * features/s390x-linux64v2.c: Re-generated.
7875 * features/s390x-te-linux64.c: Re-generated.
7876 * features/s390x-tevx-linux64.c: Re-generated.
7877 * features/s390x-vx-linux64.c: Re-generated.
7878 * features/sparc/sparc32-solaris.c: Re-generated.
7879 * features/sparc/sparc64-solaris.c: Re-generated.
7880 * features/tic6x-c62x.c: Re-generated.
7881 * features/tic6x-c62x-linux.c: Re-generated.
7882 * features/tic6x-c64x.c: Re-generated.
7883 * features/tic6x-c64x-linux.c: Re-generated.
7884 * features/tic6x-c64xp.c: Re-generated.
7885 * features/tic6x-c64xp-linux.c: Re-generated.
7886
35b4818d
YQ
78872017-07-26 Yao Qi <yao.qi@linaro.org>
7888
7889 * i386-linux-tdep.c (i386_linux_read_description): New function.
7890 (i386_linux_core_read_description): Call
7891 i386_linux_read_description.
7892 * i386-linux-tdep.h (i386_linux_read_description): Declare.
7893 (tdesc_i386_linux, tdesc_i386_mmx_linux): Remove declarations.
7894 (tdesc_i386_avx_linux, tdesc_i386_mpx_linux): Likewise
7895 (tdesc_i386_avx_mpx_linux, tdesc_i386_avx_avx512_linux): Likewise.
7896 (tdesc_i386_avx_mpx_avx512_pku_linux): Likewise.
7897 * x86-linux-nat.c (x86_linux_read_description): Call
7898 i386_linux_read_description.
7899
8e2141c6
YQ
79002017-07-26 Yao Qi <yao.qi@linaro.org>
7901
7902 * NEWS: Mention it.
7903 * features/Makefile (%.c: %.xml): Pass the xml file name to
7904 command "maint print c-tdesc".
7905 * target-descriptions.c (maint_print_c_tdesc_cmd): Get file
7906 name from 'arg'.
7907
b468ff4c
YQ
79082017-07-26 Yao Qi <yao.qi@linaro.org>
7909
7910 * target-descriptions.c (target_desc): Add ctor and dtor. Do
7911 in-class initialization.
7912 (tdesc_create_feature): Call new instead of XCNEW.
7913 (free_target_description): Ue delete.
7914
b9c0e1b4
JB
79152017-07-25 John Baldwin <jhb@FreeBSD.org>
7916
7917 * configure.nat: Add "-lkvm" for NetBSD/sparc64 and fix typo.
7918
a04b5337
YQ
79192017-07-25 Yao Qi <yao.qi@linaro.org>
7920
7921 * amd64-tdep.c (amd64_init_abi): Make argument default_tdesc
7922 constant.
7923 (amd64_x32_init_abi): Likewise.
7924 * amd64-tdep.h (amd64_init_abi): Update declaration.
7925 (amd64_x32_init_abi): Likewise.
7926
02ad7fc2
YQ
79272017-07-25 Yao Qi <yao.qi@linaro.org>
7928
7929 PR tdep/21717
7930 * arm-linux-nat.c (arm_linux_fetch_inferior_registers): Update
7931 condition for FPSCR.
7932 (arm_linux_store_inferior_registers): Likewise.
7933
b6f48cb0
TT
79342017-07-22 Tom Tromey <tom@tromey.com>
7935
7936 * break-catch-syscall.c (struct catch_syscall_inferior_data)
7937 <syscalls_counts>: Now a std::vector.
7938 (get_catch_syscall_inferior_data): Use "new".
7939 (catch_syscall_inferior_data_cleanup): Use "delete".
7940 (insert_catch_syscall, remove_catch_syscall)
7941 (clear_syscall_counts): Update.
7942
e12c9b7a
TT
79432017-07-22 Tom Tromey <tom@tromey.com>
7944
7945 * break-catch-syscall.c (syscall_catchpoint)
7946 <syscalls_to_be_caught>: Now a std::vector<int>
7947 (~syscall_catchpoint): Remove.
7948 (insert_catch_syscall, remove_catch_syscall)
7949 (breakpoint_hit_catch_syscall, print_one_catch_syscall)
7950 (print_mention_catch_syscall, print_recreate_catch_syscall):
7951 Update.
7952 (create_syscall_event_catchpoint): Change type of "filter"
7953 parameter.
7954 (catch_syscall_split_args): Return a std::vector.
7955 (catch_syscall_command_1, catching_syscall_number_1): Update.
7956
4fa8aeac
TT
79572017-07-22 Tom Tromey <tom@tromey.com>
7958
7959 * break-catch-throw.c (struct exception_catchpoint)
7960 <exception_rx>: Now a std::string.
7961 (~exception_catchpoint): Remove.
7962 (print_one_detail_exception_catchpoint): Update.
7963 (handle_gnu_v3_exceptions): Change type of except_rx.
7964 (extract_exception_regexp): Return a std::string.
7965 (catch_exception_command_1): Update.
7966
f746a154
TT
79672017-07-22 Tom Tromey <tom@tromey.com>
7968
7969 * break-catch-sig.c (gdb_signal_type): Remove typedef.
7970 (struct signal_catchpoint) <signals_to_be_caught>: Now a
7971 std::vector.
7972 <catch_all>: Now a bool.
7973 (~signal_catchpoint): Remove.
7974 (signal_catchpoint_insert_location)
7975 (signal_catchpoint_remove_location)
7976 (signal_catchpoint_breakpoint_hit, signal_catchpoint_print_one)
7977 (signal_catchpoint_print_mention)
7978 (signal_catchpoint_print_recreate)
7979 (signal_catchpoint_explains_signal): Update.
7980 (create_signal_catchpoint): Change type of "filter" and
7981 "catch_all".
7982 (catch_signal_split_args): Return a std::vector. Change type of
7983 "catch_all".
7984 (catch_signal_command): Update.
7985
47e77640
PA
79862017-07-20 Pedro Alves <palves@redhat.com>
7987
7988 * ada-lang.c (ada_language_defn): Make extern.
7989 (_initialize_ada_language): Remove add_language call.
7990 * c-lang.c (c_language_defn, cplus_language_defn)
7991 (asm_language_defn, minimal_language_defn): Make extern.
7992 (_initialize_c_language): Delete.
7993 * completer.c (compare_cstrings): Delete, moved to utils.h.
7994 * d-lang.c (d_language_defn): Make extern.
7995 (_initialize_d_language): Remove add_language calls.
7996 * defs.h (enum language): Add comment.
7997 * f-lang.c (f_language_defn): Make extern.
7998 (_initialize_f_language): Remove add_language call.
7999 * go-lang.c (go_language_defn): Make extern.
8000 (_initialize_go_language): Remove add_language call.
8001 * language.c: Include <algorithm>.
8002 (languages): Redefine as const array.
8003 (languages_size, languages_allocsize, DEFAULT_ALLOCSIZE): Delete.
8004 (set_language_command): Handle "local". Use for-range loop.
8005 (set_language): Remove loop.
8006 (language_enum): Rewrite.
8007 (language_def, language_str): Remove loops.
8008 (add_language): Delete.
8009 (add_set_language_command): New, based on add_languages.
8010 (skip_language_trampoline): Adjust.
8011 (local_language_defn): Delete.
8012 (language_gdbarch_post_init): Adjust.
8013 (_initialize_language): Remove add_language calls. Call
8014 add_set_language_command.
8015 * language.h (add_language): Delete.
8016 (auto_language_defn)
8017 (unknown_language_defn, minimal_language_defn, ada_language_defn)
8018 (asm_language_defn, c_language_defn, cplus_language_defn)
8019 (d_language_defn, f_language_defn, go_language_defn)
8020 (m2_language_defn, objc_language_defn, opencl_language_defn)
8021 (pascal_language_defn, rust_language_defn): Declare.
8022 * m2-lang.c (m2_language_defn): Make extern.
8023 (_initialize_m2_language): Remove add_language call.
8024 * objc-lang.c (objc_language_defn): Make extern.
8025 (_initialize_objc_language): Remove add_language call.
8026 * opencl-lang.c (opencl_language_defn): Make extern.
8027 (_initialize_opencl_language): Remove add_language call.
8028 * p-lang.c (pascal_language_defn): Make extern.
8029 (_initialize_pascal_language): Delete.
8030 * rust-lang.c (rust_language_defn): Make extern.
8031 (_initialize_rust_language): Delete.
8032 * utils.h (compare_cstrings): New static inline function.
8033
edb0c9cb
PA
80342017-07-20 Pedro Alves <palves@redhat.com>
8035
8036 * ada-lang.c (ada_to_fixed_type_1): Adjust.
8037 (get_var_value): Constify parameters.
8038 (get_int_var_value): Change prototype.
8039 (to_fixed_range_type): Adjust.
8040 * ada-lang.h (get_int_var_value): Change prototype.
8041
a778f165
PA
80422017-07-20 Pedro Alves <palves@redhat.com>
8043
8044 * dwarf2read.c (dw2_lookup_symbol): Use
8045 SYMBOL_MATCHES_SEARCH_NAME.
8046 * psymtab.c (psym_lookup_symbol): Use SYMBOL_MATCHES_SEARCH_NAME.
8047
42edd901
PA
80482017-07-20 Pedro Alves <palves@redhat.com>
8049
8050 * block.c (block_iter_name_step, block_iter_name_first)
8051 (block_iter_name_next): Delete.
8052 (block_lookup_symbol_primary): Adjust to use
8053 dict_iter_match_first/dict_iter_match_next.
8054 * block.h (block_iter_name_first, block_iter_name_next): Delete
8055 declarations.
8056 (ALL_BLOCK_SYMBOLS_WITH_NAME): Adjust to use
8057 dict_iter_match_first/dict_iter_match_next.
8058
cf325299
PA
80592017-07-20 Pedro Alves <palves@redhat.com>
8060
8061 * cp-support.c (cp_find_first_component_aux): Add missing case for
8062 end of string.
8063
c5ed0576
DB
80642017-07-18 David Blaikie <dblaikie@gmail.com>
8065
8066 * dwarf2read.c (create_cus_hash_table): Re-add lost initialization
8067 of dwo_cu's dwo_file.
8068
27841e76
YQ
80692017-07-18 Yao Qi <yao.qi@linaro.org>
8070
8071 * remote.c (store_registers_using_G): Remove one line comment.
8072
cfb7e58b
YQ
80732017-07-18 Yao Qi <yao.qi@linaro.org>
8074
8075 * regcache.c (regcache_cpy): Simplify it.
8076 (regcache::cpy_no_passthrough): Remove it.
8077 * regcache.h (cpy_no_passthrough): Remove it.
8078 (regcache_dup, regcache_cpy): Update comments.
8079
386535dd
PA
80802017-07-18 Pedro Alves <palves@redhat.com>
8081
8082 * remote-sim.c (sim_command_completer): Adjust to work with a
8083 completion_tracker instead of a VEC.
8084
c45ec17c
PA
80852017-07-17 Pedro Alves <palves@redhat.com>
8086
8087 * completer.c (complete_source_filenames): New function.
8088 (complete_address_and_linespec_locations): New function.
8089 (location_completer): Use complete_address_and_linespec_locations.
8090 (completion_tracker::build_completion_result): Honor the tracker's
8091 request to suppress append.
8092 * completer.h (completion_tracker::suppress_append_ws)
8093 (completion_tracker::set_suppress_append_ws): New methods.
8094 (completion_tracker::m_suppress_append_ws): New field.
8095 (complete_source_filenames): New declaration.
8096 * linespec.c (linespec_complete_what): New.
8097 (struct ls_parser) <complete_what, completion_word,
8098 completion_quote_char, completion_quote_end, completion_tracker>:
8099 New fields.
8100 (string_find_incomplete_keyword_at_end): New.
8101 (linespec_lexer_lex_string): Record quote char. If in completion
8102 mode, don't throw.
8103 (linespec_lexer_consume_token): Advance the completion word point.
8104 (linespec_lexer_peek_token): Save/restore completion info.
8105 (save_stream_and_consume_token): New.
8106 (set_completion_after_number): New.
8107 (linespec_parse_basic): Set what to complete next depending on
8108 token. Handle function and label completions specially.
8109 (parse_linespec): Disable objc shortcut in completion mode. Set
8110 what to complete next depending on token type. Skip keyword if in
8111 completion mode.
8112 (complete_linespec_component, linespec_complete): New.
8113 * linespec.h (linespec_complete): Declare.
8114
be966d42
PA
81152017-07-17 Pedro Alves <palves@redhat.com>
8116
8117 * linespec.c (linespec_lexer_lex_string, find_toplevel_char):
8118 Handle 'operator<' / 'operator<<'.
8119
a2459270
PA
81202017-07-17 Pedro Alves <palves@redhat.com>
8121
8122 * completer.c (collect_explicit_location_matches): Handle
8123 MATCH_LABEL.
8124 (convert_explicit_location_to_linespec): New, factored out from
8125 ...
8126 (convert_explicit_location_to_sals): ... this.
8127 (complete_label): New.
8128 (linespec_complete_label, find_label_symbols_in_block): New.
8129 (find_label_symbols): Add completion_mode parameter and adjust to
8130 call find_label_symbols_in_block.
8131 * linespec.h (linespec_complete_label): Declare.
8132
c6756f62
PA
81332017-07-17 Pedro Alves <palves@redhat.com>
8134
8135 * ada-lang.c (ada_collect_symbol_completion_matches): Add
8136 complete_symbol_mode parameter.
8137 * cli/cli-cmds.c (complete_command): Get the completion result out
8138 of the handle_brkchars tracker if used a custom word point.
8139 * completer.c: Include "linespec.h".
8140 (enum explicit_location_match_type) <MATCH_LINE>: New enumerator.
8141 (advance_to_expression_complete_word_point): New.
8142 (completion_tracker::completes_to_completion_word): New.
8143 (complete_files_symbols): Pass down
8144 complete_symbol_mode::EXPRESSION.
8145 (explicit_options, probe_options): New.
8146 (collect_explicit_location_matches): Complete on the
8147 explictit_loc->foo instead of word. Use
8148 linespec_complete_function. Handle MATCH_LINE. Handle offering
8149 keyword and options completions.
8150 (backup_text_ptr): Delete.
8151 (skip_keyword): New.
8152 (complete_explicit_location): Remove 'word' parameter. Add
8153 language, quoted_arg_start and quoted_arg_end parameters.
8154 Rewrite, parsing left to right.
8155 (location_completer): Rewrite.
8156 (location_completer_handle_brkchars): New function.
8157 (symbol_completer): Pass down complete_symbol_mode::EXPRESSION.
8158 (enum complete_line_internal_reason): Adjust comments.
8159 (completion_tracker::discard_completions): New.
8160 (completer_handle_brkchars_func_for_completer): Handle
8161 location_completer.
8162 (gdb_custom_word_point_brkchars)
8163 (gdb_org_rl_basic_quote_characters): New.
8164 (gdb_completion_word_break_characters_throw)
8165 (completion_find_completion_word): Handle trackers that use a
8166 custom word point.
8167 (completion_tracker::advance_custom_word_point_by): New.
8168 (completion_tracker::build_completion_result): Don't rely on
8169 readline appending the quote char.
8170 (gdb_rl_attempted_completion_function_throw): Handle trackers that
8171 use a custom word point.
8172 (gdb_rl_attempted_completion_function): Restore
8173 rl_basic_quote_characters.
8174 * completer.h (class completion_tracker): Extend intro comment.
8175 (completion_tracker::set_quote_char)
8176 (completion_tracker::quote_char)
8177 (completion_tracker::set_use_custom_word_point)
8178 (completion_tracker::use_custom_word_point)
8179 (completion_tracker::custom_word_point)
8180 (completion_tracker::set_custom_word_point)
8181 (completion_tracker::advance_custom_word_point_by)
8182 (completion_tracker::completes_to_completion_word)
8183 (completion_tracker::discard_completions): New methods.
8184 (completion_tracker::m_quote_char)
8185 (completion_tracker::m_use_custom_word_point)
8186 (completion_tracker::m_custom_word_point): New fields.
8187 (advance_to_expression_complete_word_point): Declare.
8188 * f-lang.c (f_collect_symbol_completion_matches): Add
8189 complete_symbol_mode parameter.
8190 * language.h (struct language_defn)
8191 <la_collect_symbol_completion_matches>: Add complete_symbol_mode
8192 parameter.
8193 * linespec.c (linespec_keywords): Add NULL terminator. Make extern.
8194 (linespec_complete_function): New function.
8195 (linespec_lexer_lex_keyword): Adjust.
8196 * linespec.h (linespec_keywords, linespec_complete_function): New
8197 declarations.
8198 * location.c (find_end_quote): New function.
8199 (explicit_location_lex_one): Add explicit_completion_info
8200 parameter. Save quoting info. Don't throw if being called for
8201 completion. Don't handle Ada operators here.
8202 (is_cp_operator, skip_op_false_positives, first_of)
8203 (explicit_location_lex_one_function): New function.
8204 (string_to_explicit_location): Replace 'dont_throw' parameter with
8205 an explicit_completion_info pointer parameter. Handle it. Don't
8206 use explicit_location_lex_one to lex function names. Use
8207 explicit_location_lex_one_function instead.
8208 * location.h (struct explicit_completion_info): New.
8209 (string_to_explicit_location): Replace 'dont_throw' parameter with
8210 an explicit_completion_info pointer parameter.
8211 * symtab.c (default_collect_symbol_completion_matches_break_on):
8212 Add complete_symbol_mode parameter. Handle LINESPEC mode.
8213 (default_collect_symbol_completion_matches)
8214 (collect_symbol_completion_matches): Add complete_symbol_mode
8215 parameter.
8216 (collect_symbol_completion_matches_type): Pass down
8217 complete_symbol_mode::EXPRESSION.
8218 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8219 parameter. Handle LINESPEC mode.
8220 * symtab.h (complete_symbol_mode): New.
8221 (default_collect_symbol_completion_matches_break_on)
8222 (default_collect_symbol_completion_matches)
8223 (collect_symbol_completion_matches)
8224 (collect_file_symbol_completion_matches): Add complete_symbol_mode
8225 parameter.
8226
1d550c82
PA
82272017-07-17 Pedro Alves <palves@redhat.com>
8228
8229 * utils.c (enum class strncmp_iw_mode): New.
8230 (strcmp_iw): Rename to ...
8231 (strncmp_iw_with_mode): ... this. Add string2_len and mode
8232 parameters. Handle them.
8233 (strncmp_iw): New.
8234 (strcmp_iw): Reimplement as wrapper around strncmp_iw_with_mode.
8235 * utils.h (strncmp_iw): Declare.
8236 (strcmp_iw): Move describing comments here.
8237
8090b426
PA
82382017-07-17 Pedro Alves <palves@redhat.com>
8239
8240 * c-exp.y (operator_stoken): Use CP_OPERATOR_LEN and
8241 CP_OPERATOR_STR.
8242 * c-typeprint.c (is_type_conversion_operator): Use
8243 CP_OPERATOR_STR.
8244 * cp-support.c (LENGTH_OF_OPERATOR): Delete.
8245 (cp_find_first_component_aux): Use CP_OPERATOR_STR and
8246 CP_OPERATOR_LEN.
8247 * cp-support.h (CP_OPERATOR_STR, CP_OPERATOR_LEN): New.
8248 * gnu-v2-abi.c (gnuv2_is_operator_name): Use CP_OPERATOR_STR.
8249 * gnu-v3-abi.c (gnuv3_is_operator_name): Use CP_OPERATOR_STR.
8250 * linespec.c (linespec_lexer_lex_string): Use CP_OPERATOR_LEN and
8251 CP_OPERATOR_STR.
8252 * location.c: Include "cp-support.h".
8253 (explicit_location_lex_one): Use CP_OPERATOR_LEN and
8254 CP_OPERATOR_STR.
8255 * symtab.c (operator_chars): Use CP_OPERATOR_STR and
8256 CP_OPERATOR_LEN.
8257
6a2c1b87
PA
82582017-07-17 Pedro Alves <palves@redhat.com>
8259
8260 * cli/cli-cmds.c (complete_command): Use a completion tracker
8261 along with completion_find_completion_word for handle_brkchars
8262 phase.
8263 * completer.c (RL_QF_SINGLE_QUOTE, RL_QF_DOUBLE_QUOTE)
8264 (RL_QF_BACKSLASH, RL_QF_OTHER_QUOTE): New.
8265 (struct gdb_rl_completion_word_info): New.
8266 (gdb_rl_find_completion_word): New.
8267 (completion_find_completion_word): New.
8268 * completer.h (completion_find_completion_word): Declare.
8269
eb3ff9a5
PA
82702017-07-17 Pedro Alves <palves@redhat.com>
8271
8272 * ada-lang.c (symbol_completion_match): Adjust comments.
8273 (symbol_completion_add): Replace vector parameter with
8274 completion_tracker parameter. Use it.
8275 (ada_make_symbol_completion_list): Rename to...
8276 (ada_collect_symbol_completion_matches): ... this. Add
8277 completion_tracker parameter and use it.
8278 (ada_language_defn): Adjust.
8279 * break-catch-syscall.c (catch_syscall_completer): Adjust
8280 prototype and work with completion_tracker instead of VEC.
8281 * breakpoint.c (condition_completer): Adjust prototype and work
8282 with completion_tracker instead of VEC.
8283 * c-lang.c (c_language_defn, cplus_language_defn)
8284 (asm_language_defn, minimal_language_defn): Adjust to renames.
8285 * cli/cli-cmds.c (complete_command): Rework using
8286 completion_tracker. Catch exceptions when completing.
8287 * cli/cli-decode.c (integer_unlimited_completer)
8288 (complete_on_cmdlist, complete_on_enum): Adjust prototype and work
8289 with completion_tracker instead of VEC.
8290 * command.h (struct completion_tracker): Forward declare.
8291 (completer_ftype, completer_handle_brkchars_ftype): Change
8292 types.
8293 (complete_on_cmdlist, complete_on_enum): Adjust.
8294 * completer.c: Include <algorithm>.
8295 (struct gdb_completer_state): New.
8296 (current_completion): New global.
8297 (readline_line_completion_function): Delete.
8298 (noop_completer, filename_completer)
8299 (filename_completer_handle_brkchars, complete_files_symbols)
8300 (linespec_location_completer): Adjust to work with a
8301 completion_tracker instead of a VEC.
8302 (string_or_empty): New.
8303 (collect_explicit_location_matches): Adjust to work with a
8304 completion_tracker instead of a VEC.
8305 (explicit_location_completer): Rename to ...
8306 (complete_explicit_location): ... this and adjust to work with a
8307 completion_tracker instead of a VEC.
8308 (location_completer): Adjust to work with a completion_tracker
8309 instead of a VEC.
8310 (add_struct_fields): Adjust to work with a completion_list instead
8311 of VEC.
8312 (expression_completer): Rename to ...
8313 (complete_expression): ... this and adjust to work with a
8314 completion_tracker instead of a VEC. Use complete_files_symbols.
8315 (expression_completer): Reimplement on top of complete_expression.
8316 (symbol_completer): Adjust to work with a completion_tracker
8317 instead of a VEC.
8318 (enum complete_line_internal_reason): Add describing comments.
8319 (complete_line_internal_normal_command): Adjust to work with a
8320 completion_tracker instead of a VEC.
8321 (complete_line_internal): Rename to ...
8322 (complete_line_internal_1): ... this and adjust to work with a
8323 completion_tracker instead of a VEC. Assert TEXT is NULL in the
8324 handle_brkchars phase.
8325 (new_completion_tracker): Delete.
8326 (complete_line_internal): Reimplement as TRY/CATCH wrapper around
8327 complete_line_internal_1.
8328 (free_completion_tracker): Delete.
8329 (INITIAL_COMPLETION_HTAB_SIZE): New.
8330 (completion_tracker::completion_tracker)
8331 (completion_tracker::~completion_tracker): New.
8332 (maybe_add_completion): Delete.
8333 (completion_tracker::maybe_add_completion)
8334 (completion_tracker::add_completion)
8335 (completion_tracker::add_completions): New.
8336 (throw_max_completions_reached_error): Delete.
8337 (complete_line): Adjust to work with a completion_tracker instead
8338 of a VEC. Don't create a completion_tracker_t or check for max
8339 completions here.
8340 (command_completer, command_completer_handle_brkchars)
8341 (signal_completer, reg_or_group_completer_1)
8342 (reg_or_group_completer, default_completer_handle_brkchars):
8343 Adjust to work with a completion_tracker.
8344 (gdb_completion_word_break_characters_throw): New.
8345 (gdb_completion_word_break_characters): Reimplement.
8346 (line_completion_function): Delete.
8347 (completion_tracker::recompute_lowest_common_denominator)
8348 (expand_preserving_ws)
8349 (completion_tracker::build_completion_result)
8350 (completion_result::completion_result)
8351 (completion_result::completion_result)
8352 (completion_result::~completion_result)
8353 (completion_result::completion_result)
8354 (completion_result::release_match_list, compare_cstrings)
8355 (completion_result::sort_match_list)
8356 (completion_result::reset_match_list)
8357 (gdb_rl_attempted_completion_function_throw)
8358 (gdb_rl_attempted_completion_function): New.
8359 * completer.h (completion_list, struct completion_result)
8360 (class completion_tracker): New.
8361 (complete_line): Add completion_tracker parameter.
8362 (readline_line_completion_function): Delete.
8363 (gdb_rl_attempted_completion_function): New.
8364 (noop_completer, filename_completer, expression_completer)
8365 (location_completer, symbol_completer, command_completer)
8366 (signal_completer, reg_or_group_completer): Update prototypes.
8367 (completion_tracker_t, new_completion_tracker)
8368 (make_cleanup_free_completion_tracker): Delete.
8369 (enum maybe_add_completion_enum): Delete.
8370 (maybe_add_completion): Delete.
8371 (throw_max_completions_reached_error): Delete.
8372 * corefile.c (complete_set_gnutarget): Adjust to work with a
8373 completion_tracker instead of a VEC.
8374 * cp-abi.c (cp_abi_completer): Adjust to work with a
8375 completion_tracker instead of a VEC.
8376 * d-lang.c (d_language_defn): Adjust.
8377 * disasm.c (disassembler_options_completer): Adjust to work with a
8378 completion_tracker instead of a VEC.
8379 * f-lang.c (f_make_symbol_completion_list): Rename to ...
8380 (f_collect_symbol_completion_matches): ... this. Adjust to work
8381 with a completion_tracker instead of a VEC.
8382 (f_language_defn): Adjust.
8383 * go-lang.c (go_language_defn): Adjust.
8384 * guile/scm-cmd.c (cmdscm_add_completion, cmdscm_completer):
8385 Adjust to work with a completion_tracker instead of a VEC.
8386 * infrun.c (handle_completer): Likewise.
8387 * interps.c (interpreter_completer): Likewise.
8388 * interps.h (interpreter_completer): Likewise.
8389 * language.c (unknown_language_defn, auto_language_defn)
8390 (local_language_defn): Adjust.
8391 * language.h (language_defn::la_make_symbol_completion_list):
8392 Rename to ...
8393 (language_defn::la_collect_symbol_completion_matches): ... this
8394 and adjust to work with a completion_tracker instead of a VEC.
8395 * m2-lang.c (m2_language_defn): Adjust.
8396 * objc-lang.c (objc_language_defn): Adjust.
8397 * opencl-lang.c (opencl_language_defn): Adjust.
8398 * p-lang.c (pascal_language_defn): Adjust.
8399 * python/py-cmd.c (cmdpy_completer_helper): Handle NULL word.
8400 (cmdpy_completer_handle_brkchars, cmdpy_completer): Adjust to work
8401 with a completion_tracker.
8402 * rust-lang.c (rust_language_defn): Adjust.
8403 * symtab.c (free_completion_list, do_free_completion_list)
8404 (return_val, completion_tracker): Delete.
8405 (completion_list_add_name, completion_list_add_symbol)
8406 (completion_list_add_msymbol, completion_list_objc_symbol)
8407 (completion_list_add_fields, add_symtab_completions): Add
8408 completion_tracker parameter and use it.
8409 (default_make_symbol_completion_list_break_on_1): Rename to...
8410 (default_collect_symbol_completion_matches_break_on): ... this.
8411 Add completion_tracker parameter and use it instead of allocating
8412 a completion tracker here.
8413 (default_make_symbol_completion_list_break_on): Delete old
8414 implementation.
8415 (default_make_symbol_completion_list): Delete.
8416 (default_collect_symbol_completion_matches): New.
8417 (make_symbol_completion_list): Delete.
8418 (collect_symbol_completion_matches): New.
8419 (make_symbol_completion_type): Rename to ...
8420 (collect_symbol_completion_matches_type): ... this. Add
8421 completion_tracker parameter and use it instead of VEC.
8422 (make_file_symbol_completion_list_1): Rename to...
8423 (collect_file_symbol_completion_matches): ... this. Add
8424 completion_tracker parameter and use it instead of VEC.
8425 (make_file_symbol_completion_list): Delete.
8426 (add_filename_to_list): Use completion_list instead of a VEC.
8427 (add_partial_filename_data::list): Now a completion_list.
8428 (make_source_files_completion_list): Work with a completion_list
8429 instead of a VEC.
8430 * symtab.h: Include "completer.h".
8431 (default_make_symbol_completion_list_break_on)
8432 (default_make_symbol_completion_list, make_symbol_completion_list)
8433 (make_symbol_completion_type, make_file_symbol_completion_list)
8434 (make_source_files_completion_list): Delete.
8435 (default_collect_symbol_completion_matches_break_on)
8436 (default_collect_symbol_completion_matches)
8437 (collect_symbol_completion_matches)
8438 (collect_symbol_completion_matches_type)
8439 (collect_file_symbol_completion_matches)
8440 (make_source_files_completion_list): New.
8441 * top.c (init_main): Don't install a rl_completion_entry_function
8442 hook. Install a rl_attempted_completion_function hook instead.
8443 * tui/tui-layout.c (layout_completer): Adjust to work with a
8444 completion_tracker.
8445 * tui/tui-regs.c (tui_reggroup_completer):
8446 * tui/tui-win.c (window_name_completer, focus_completer)
8447 (winheight_completer): Adjust to work with a completion_tracker.
8448 * value.c: Include "completer.h".
8449 (complete_internalvar): Adjust to work with a completion_tracker.
8450 * value.h (complete_internalvar): Likewise.
8451
6e1dbf8c
PA
84522017-07-17 Pedro Alves <palves@redhat.com>
8453
8454 * cli/cli-decode.c (set_cmd_completer_handle_brkchars): Adjust to
8455 renames.
8456 * cli/cli-decode.h (struct cmd_list_element) <completer>: Move
8457 comments to completer_ftype's declaration.
8458 <completer_handle_brkchars>: Change type to
8459 completer_handle_brkchars_ftype.
8460 * command.h (completer_ftype): Add describing comment and give
8461 names to parameters.
8462 (completer_ftype_void): Rename to ...
8463 (completer_handle_brkchars_ftype) ... this. Add describing comment.
8464 (set_cmd_completer_handle_brkchars): Adjust.
8465 * completer.c (filename_completer_handle_brkchars): New function.
8466 (complete_line_internal_normal_command): New function, factored
8467 out from ...
8468 (complete_line_internal): ... here.
8469 (command_completer_handle_brkchars)
8470 (default_completer_handle_brkchars)
8471 (completer_handle_brkchars_func_for_completer): New functions.
8472 * completer.h (set_gdb_completion_word_break_characters): Delete
8473 declaration.
8474 (completer_handle_brkchars_func_for_completer): New declaration.
8475 * python/py-cmd.c (cmdpy_completer_handle_brkchars): Adjust to use
8476 completer_handle_brkchars_func_for_completer.
8477
78b13106
PA
84782017-07-17 Pedro Alves <palves@redhat.com>
8479
8480 * completer.c (symbol_completer): New function, based on
8481 make_symbol_completion_list_fn.
8482 * completer.h (symbol_completer): New declaration.
8483 * guile/scm-cmd.c (cmdscm_completers): Adjust.
8484 * python/py-cmd.c (completers): Adjust.
8485 * symtab.c (make_symbol_completion_list_fn): Delete.
8486 * symtab.h (make_symbol_completion_list_fn): Delete.
8487 * cli/cli-decode.c (add_cmd): Adjust.
8488
bbf2f4df
PA
84892017-07-17 Pedro Alves <palves@redhat.com>
8490
8491 * Makefile.in (COMMON_OBS): Add filename-seen-cache.o.
8492 * dwarf2read.c: Include "filename-seen-cache.h".
8493 * dwarf2read.c (dwarf2_per_objfile) <filenames_cache>: New field.
8494 (dw2_map_symbol_filenames): Build and use a filenames_seen_cache.
8495 * filename-seen-cache.c: New file.
8496 * filename-seen-cache.h: New file.
8497 * symtab.c: Include "filename-seen-cache.h".
8498 (struct filename_seen_cache, INITIAL_FILENAME_SEEN_CACHE_SIZE)
8499 (create_filename_seen_cache, clear_filename_seen_cache)
8500 (delete_filename_seen_cache, filename_seen): Delete, parts moved
8501 to filename-seen-cache.h/filename-seen-cache.c.
8502 (output_source_filename, sources_info)
8503 (maybe_add_partial_symtab_filename)
8504 (make_source_files_completion_list): Adjust to use
8505 filename_seen_cache.
8506
330cdd98
PA
85072017-07-17 Pedro Alves <palves@redhat.com>
8508
8509 * dwarf2read.c (dwarf2_per_objfile): In-class initialize all
8510 fields.
8511 (dwarf2_per_objfile::dwarf2_per_objfile(objfile*, const
8512 dwarf2_debug_sections*)): New.
8513 (dwarf2_per_objfile::dwarf2_per_objfile(const
8514 dwarf2_per_objfile&)): Declare as deleted.
8515 (dwarf2_per_objfile::operator=): Declare as deleted.
8516 (dwarf2_per_objfile::dwarf2_per_objfile)
8517 (dwarf2_per_objfile::~dwarf2_per_objfile)
8518 (dwarf2_per_objfile::free_cached_comp_units): New.
8519 (dwarf2_has_info): dwarf2_per_objfile initialization code moved to
8520 ctor. Call dwarf2_per_objfile's ctor manually.
8521 (dwarf2_locate_sections): Deleted/refactored as ...
8522 (dwarf2_per_objfile::locate_sections): ... this new method.
8523 (free_cached_comp_units): Defer to
8524 dwarf2_per_objfile::free_cached_comp_units.
8525 (dwarf2_free_objfile): Call dwarf2_per_objfile's dtor manually.
8526
8880f2a9
TT
85272017-07-14 Tom Tromey <tom@tromey.com>
8528
8529 PR rust/21764:
8530 * rust-exp.y (convert_ast_to_expression): Add "want_type"
8531 parameter.
8532 <UNOP_SIZEOF>: Split into separate case.
8533 <UNOP_VAR_VALUE>: Handle want_type. Add error case.
8534
65547233
TT
85352017-07-14 Tom Tromey <tom@tromey.com>
8536
8537 PR rust/21763:
8538 * symtab.c (symbol_matches_domain): Add language_rust to special
8539 case.
8540 * rust-exp.y (convert_ast_to_expression) <OP_VAR_VALUE>: Don't
8541 treat LOC_TYPEDEF symbols as variables.
8542
8f14146e
PA
85432017-07-14 Pedro Alves <palves@redhat.com>
8544
8545 * symtab.c (make_file_symbol_completion_list_1): Iterate over
8546 symtabs matching all symtabs with SRCFILE as file name instead of
8547 only considering the first hit, with lookup_symtab.
8548
2347965c
SM
85492017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8550
8551 * ax-gdb.c (gen_aggregate_elt_ref): Remove operand_name and
8552 operator_name parameters.
8553 (gen_expr): Update function call.
8554
40f4af28
SM
85552017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8556
8557 * dwarf2loc.h (dwarf2_compile_expr_to_ax): Remove gdbarch
8558 parameter.
8559 * symtab.h (struct symbol_computed_ops::tracepoint_var_ref):
8560 Likewise.
8561 * dwarf2loc.c (dwarf2_compile_expr_to_ax): Remove gdbarch
8562 parameter, use agent_expr::gdbarch instead, update function
8563 calls.
8564 (locexpr_tracepoint_var_ref): Likewise.
8565 (loclist_tracepoint_var_ref): Likewise.
8566 * ax-gdb.c (gen_trace_static_fields): Likewise.
8567 (gen_traced_pop): Likewise.
8568 (gen_frame_args_address): Likewise.
8569 (gen_frame_locals_address): Likewise.
8570 (gen_var_ref): Likewise.
8571 (gen_struct_ref_recursive): Likewise.
8572 (gen_static_field): Likewise.
8573 (gen_maybe_namespace_elt): Likewise.
8574 (gen_expr): Likewise.
8575 (gen_trace_for_var): Likewise.
8576 (gen_trace_for_expr): Likewise.
8577 (gen_trace_for_return_address): Likewise.
8578
053f8057
SM
85792017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8580
8581 * ax-gdb.c (gen_deref, gen_address_of): Remove unused ax
8582 parameter.
8583 (gen_struct_ref, gen_expr, gen_expr_binop_rest): Update call.
8584
6661ad48
SM
85852017-07-14 Simon Marchi <simon.marchi@ericsson.com>
8586
8587 * ax-gdb.c (gen_usual_unary): Remove exp parameter, get gdbarch
8588 from ax, update calls.
8589 (gen_usual_arithmetic): Likewise.
8590 (gen_integral_promotions): Likewise.
8591 (gen_bitfield_ref): Likewise.
8592 (gen_primitive_field): Likewise.
8593 (gen_struct_ref_recursive): Likewise.
8594 (gen_struct_ref): Likewise.
8595 (gen_maybe_namespace_elt): Likewise.
8596 (gen_struct_elt_for_reference): Likewise.
8597 (gen_namespace_elt): Likewise.
8598 (gen_aggregate_elt_ref): Likewise.
8599 (gen_expr): Get gdbarch from ax, update calls.
8600 (gen_expr_binop_rest): Likewise.
8601
c55a47e7
PA
86022017-07-13 Pedro Alves <palves@redhat.com>
8603
8604 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Pass tdesc_amd64
8605 as default tdesc.
8606 * amd64-dicos-tdep.c (amd64_dicos_init_abi):
8607 * amd64-fbsd-tdep.c (amd64fbsd_init_abi):
8608 * amd64-linux-tdep.c (amd64_linux_init_abi): Pass
8609 tdesc_amd64_linux as default tdesc. Get final tdesc from the
8610 tdep.
8611 (amd64_x32_linux_init_abi): Pass tdesc_x32_linux as default tdesc.
8612 Get final tdesc from the tdep.
8613 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Pass tdesc_amd64 as
8614 default tdesc.
8615 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
8616 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
8617 * amd64-tdep.c (amd64_init_abi): Add 'default_tdesc' parameter.
8618 Use it as default tdesc.
8619 (amd64_x32_init_abi): Add 'default_tdesc' parameter, and pass it
8620 down to amd_init_abi. No longer handle fallback tdesc here.
8621 * amd64-tdep.h (tdesc_x32): Declare.
8622 (amd64_init_abi, amd64_x32_init_abi): Add 'default_tdesc'
8623 parameter.
8624 * amd64-windows-tdep.c (amd64_windows_init_abi): Pass tdesc_amd64
8625 as default tdesc.
8626
55efceab
AA
86272017-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
8628
8629 * s390-linux-tdep.c (s390_process_record): Add support for
8630 instructions new in arch12.
8631
0aa37b65
JB
86322017-07-11 John Baldwin <jhb@FreeBSD.org>
8633
8634 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers): Use
8635 PT_GETFSBASE and PT_GETGSBASE.
8636 (amd64bsd_store_inferior_registers): Use PT_SETFSBASE and
8637 PT_SETGSBASE.
8638
48aeef91
JB
86392017-07-11 John Baldwin <jhb@FreeBSD.org>
8640
8641 * features/Makefile (amd64.dat, amd64-avx.dat, amd64-mpx.dat)
8642 (amd64-avx-mpx.dat, amd64-avx-avx512.dat)
8643 (amd64-avx-mpx-avx512-pku.dat): Add i386/64bit-segments.xml in
8644 those rules.
8645 * features/i386/amd64-avx-avx512.xml: Add 64bit-segments.xml.
8646 * features/i386/amd64-avx-mpx-avx512-pku.xml: Add 64bit-segments.xml.
8647 * features/i386/amd64-avx-mpx.xml: Add 64bit-segments.xml.
8648 * features/i386/amd64-avx.xml: Add 64bit-segments.xml.
8649 * features/i386/amd64-mpx.xml: Add 64bit-segments.xml.
8650 * features/i386/amd64.xml: Add 64bit-segments.xml.
8651 * features/i386/amd64-avx-avx512.c: Regenerated.
8652 * features/i386/amd64-avx-mpx-avx512-pku.c: Regenerated.
8653 * features/i386/amd64-avx-mpx.c: Regenerated.
8654 * features/i386/amd64-avx.c: Regenerated.
8655 * features/i386/amd64-mpx.c: Regenerated.
8656 * features/i386/amd64.c: Regenerated.
8657 * regformats/i386/amd64-avx-avx512.dat: Regenerated.
8658 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8659 * regformats/i386/amd64-avx-mpx.dat: Regenerated.
8660 * regformats/i386/amd64-avx.dat: Regenerated.
8661 * regformats/i386/amd64-mpx.dat: Regenerated.
8662 * regformats/i386/amd64.dat: Regenerated.
8663
77c501bc
YQ
86642017-07-10 Yao Qi <yao.qi@linaro.org>
8665
8666 * features/i386/amd64-avx-avx512-linux.c: Re-generated.
8667 * features/i386/amd64-avx-mpx-avx512-pku-linux.c: Re-generated.
8668
6dc8d757
AK
86692017-07-10 Anton Kolesov <Anton.Kolesov@synopsys.com>
8670
8671 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add setenv and
8672 unsetenv.
8673 * gnulib/aclocal.m4: Regenerate.
8674 * gnulib/config.in: Regenerate.
8675 * gnulib/configure: Regenerate.
8676 * gnulib/import/Makefile.am: Regenerate.
8677 * gnulib/import/Makefile.in: Regenerate.
8678 * gnulib/import/m4/gnulib-cache.m4: Regenerate.
8679 * gnulib/import/m4/gnulib-comp.m4: Regenerate.
8680 * gnulib/import/m4/environ.m4: New file.
8681 * gnulib/import/m4/setenv.m4: New file.
8682 * gnulib/import/setenv.c: New file.
8683 * gnulib/import/unsetenv.c: New file.
8684
266934d1
SM
86852017-07-09 Simon Marchi <simon.marchi@ericsson.com>
8686
8687 * compile/compile-loc2c.c (do_compile_dwarf_expr_to_c): Read
8688 address when op is DW_OP_addr.
8689
03278692
TT
86902017-07-09 Tom Tromey <tom@tromey.com>
8691
8692 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Reverse size
8693 check and apply to outer type.
8694
4b654465
JB
86952017-07-07 John Baldwin <jhb@FreeBSD.org>
8696
8697 * fbsd-tdep.c (LWPINFO_OFFSET, LWPINFO_PL_FLAGS)
8698 (LWPINFO64_PL_SIGINFO, LWPINFO32_PL_SIGINFO, PL_FLAG_SI)
8699 (SIZE64_SIGINFO_T, SIZE32_SIGINFO_T, fbsd_core_xfer_siginfo): New.
8700 (fbsd_init_abi): Install gdbarch "core_xfer_siginfo" method.
8701
2af9fc44
JB
87022017-07-07 John Baldwin <jhb@FreeBSD.org>
8703
8704 * fbsd-tdep.c (fbsd_core_thread_name): Use thread_section_name.
8705
382b69bb
JB
87062017-07-07 John Baldwin <jhb@FreeBSD.org>
8707
8708 * corelow.c (get_core_siginfo): Remove.
8709 (core_xfer_partial): Use the gdbarch "core_xfer_siginfo" method
8710 instead of get_core_siginfo.
8711 * gdbarch.sh (core_xfer_siginfo): New gdbarch callback.
8712 * gdbarch.h: Re-generate.
8713 * gdbarch.c: Re-generate.
8714 * linux-tdep.c (linux_core_xfer_siginfo): New.
8715 (linux_init_abi): Install gdbarch "core_xfer_siginfo" method.
8716
6e5eab33
JB
87172017-07-07 John Baldwin <jhb@FreeBSD.org>
8718
8719 * corelow.c (thread_section_name): Move to ...
8720 * gdbcore.h (thread_section_name): ... here.
8721
929edea9
JB
87222017-07-07 John Baldwin <jhb@FreeBSD.org>
8723
8724 * fbsd-nat.c [PT_LWPINFO && __LP64__] (union sigval32)
8725 (struct siginfo32): New.
8726 [PT_LWPINFO] (fbsd_siginfo_size, fbsd_convert_siginfo): New.
8727 (fbsd_xfer_partial) [PT_LWPINFO]: Handle TARGET_OBJECT_SIGNAL_INFO
8728 via ptrace(PT_LWPINFO).
8729
762c974a
JB
87302017-07-07 John Baldwin <jhb@FreeBSD.org>
8731
8732 * fbsd-tdep.c (fbsd_gdbarch_data_handle, struct fbsd_gdbarch_data)
8733 (init_fbsd_gdbarch_data, get_fbsd_gdbarch_data)
8734 (fbsd_get_siginfo_type): New.
8735 (fbsd_init_abi): Install gdbarch "get_siginfo_type" method.
8736 (_initialize_fbsd_tdep): New.
8737
33c5cd75
DB
87382017-07-06 David Blaikie <dblaikie@gmail.com>
8739
8740 * dwarf2read.c (struct dwo_file): Use a htab of dwo_unit* (rather than
8741 a singular dwo_unit*) to support multiple CUs in the same way that
8742 multiple TUs are supported.
8743 (create_cus_hash_table): Replace create_dwo_cu with a function for
8744 parsing multiple CUs from a DWO file.
8745 (open_and_init_dwo_file): Use create_cus_hash_table rather than
8746 create_dwo_cu.
8747 (lookup_dwo_cutu): Lookup CU in the hash table in the dwo_file with
8748 htab_find, rather than comparing the signature to a singleton CU in
8749 the dwo_file.
8750
8455d262
PA
87512017-07-06 Pedro Alves <palves@redhat.com>
8752
8753 * python/py-unwind.c (pyuw_dealloc_cache): Fix for loop condition.
8754
4da3eb35
PA
87552017-07-04 Pedro Alves <palves@redhat.com>
8756
8757 * gdbtypes.c (recursive_dump_type): Don't reference TYPE_STATIC.
8758 * gdbtypes.h (TYPE_STATIC): Delete.
8759 (struct fn_field) <is_public, is_abstract, is_static, is_final,
8760 is_synchronized, is_native>: Delete.
8761 <dummy>: Bump.
8762 (TYPE_FN_FIELD_PUBLIC, TYPE_FN_FIELD_STATIC, TYPE_FN_FIELD_FINAL)
8763 (TYPE_FN_FIELD_SYNCHRONIZED, TYPE_FN_FIELD_NATIVE)
8764 (TYPE_FN_FIELD_ABSTRACT): Delete.
8765
5bfd255c
SM
87662017-07-03 Simon Marchi <simon.marchi@ericsson.com>
8767
8768 * buffer.h (buffer_finish): Fix spelling mistakes.
8769
25c54127
EZ
87702017-07-01 Eli Zaretskii <eliz@gnu.org>
8771
8772 * .dir-locals.el: Automatically switch to C-style comments in
8773 versions of Emacs that support the feature.
8774
dc4bde35
SDJ
87752017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8776 Pedro Alves <palves@redhat.com>
8777
8778 PR cli/21688
8779 * cli/cli-script.c (command_name_equals_not_inline): Remove function.
8780 (process_next_line): New variable 'inline_cmd'.
8781 Adjust 'if' clauses for "python", "compile" and "guile" to use
8782 'command_name_equals' and check for '!inline_cmd'.
8783
51ed89aa
SDJ
87842017-06-30 Sergio Durigan Junior <sergiodj@redhat.com>
8785
8786 PR cli/21688
8787 * cli/cli-script.c (command_name_equals_not_inline): New function.
8788 (process_next_line): Adjust 'if' clauses for "python", "compile"
8789 and "guile" to use command_name_equals_not_inline.
8790
eb17d413
PA
87912017-06-29 Pedro Alves <palves@redhat.com>
8792
8793 * completer.c (expression_completer): Call
8794 linespec_location_completer instead of location_completer.
8795
195bcdd5
PA
87962017-06-29 Pedro Alves <palves@redhat.com>
8797
8798 * completer.c (expression_completer): Remove code that recomputes
8799 'text' from 'word'.
8800
adc764e7
YQ
88012017-06-29 Yao Qi <yao.qi@linaro.org>
8802
8803 * regformats/regdat.sh: Generate code with
8804 "ifndef IN_PROCESS_AGENT".
8805
6e75794e
PA
88062017-06-28 Pedro Alves <palves@redhat.com>
8807
8808 * command.h: Include "common/scoped_restore.h".
8809
bc491f2e
YQ
88102017-06-28 Yao Qi <yao.qi@linaro.org>
8811
8812 * mi/mi-cmd-break.c (mi_argv_to_format): Use obstack_grow_str
8813 instead of obstack_grow.
8814
41664b45
DG
88152017-06-28 Doug Gilmore <Doug.Gilmore@imgtec.com>
8816
8817 PR gdb/21337
8818 * symfile.c (reread_symbols): Call objfiles_changed just before
8819 read_symbols.
8820
6da67eb1
PA
88212017-06-27 Pedro Alves <palves@redhat.com>
8822
8823 * symtab.c (COMPLETION_LIST_ADD_SYMBOL)
8824 (MCOMPLETION_LIST_ADD_SYMBOL): Delete macros, replace with ...
8825 (completion_list_add_symbol, completion_list_add_msymbol):
8826 ... these new functions.
8827 (add_symtab_completions)
8828 (default_make_symbol_completion_list_break_on_1): Adjust.
8829
23732b1e
PA
88302017-06-27 Pedro Alves <palves@redhat.com>
8831
8832 * objfiles.c (get_objfile_bfd_data): Call bfd_alloc instead of
8833 bfd_zalloc. Call objfile_per_bfd_storage's ctor.
8834 (free_objfile_per_bfd_storage): Call objfile_per_bfd_storage's
8835 dtor.
8836 * objfiles.h (objfile_per_bfd_storage): Add ctor. Make
8837 'storage_obstack' field an auto_obstack. In-class initialize all
8838 non-bitfield fields. Make minsyms_read bool.
8839 * symfile.c (read_symbols): Adjust.
8840
a4d1e79a
AH
88412017-06-27 Alan Hayward <alan.hayward@arm.com>
8842
8843 * remote-sim.c (gdbsim_fetch_register): Use byte_vector.
8844 (gdbsim_store_register): Likewise.
8845
8268c778
PA
88462017-06-27 Pedro Alves <palves@redhat.com>
8847
8848 * c-exp.y (name_obstack): Now an auto_obstack.
8849 (yylex): Use auto_obstack::clear.
8850 (c_parse): Use auto_obstack::clear instead of reinitializing and
8851 freeing the obstack.
8852 * c-lang.c (evaluate_subexp_c): Use auto_obstack.
8853 * d-exp.y (name_obstack): Now an auto_obstack.
8854 (yylex): Use auto_obstack::clear.
8855 (d_parse): Use auto_obstack::clear instead of reinitializing and
8856 freeing the obstack.
8857 * dwarf2loc.c (fetch_const_value_from_synthetic_pointer): Use
8858 auto_obstack.
8859 * dwarf2read.c (create_addrmap_from_index)
8860 (dwarf2_build_psymtabs_hard)
8861 (update_enumeration_type_from_children): Likewise.
8862 * gdb_obstack.h (auto_obstack): New type.
8863 * go-exp.y (name_obstack): Now an auto_obstack.
8864 (build_packaged_name): Use auto_obstack::clear.
8865 (go_parse): Use auto_obstack::clear instead of reinitializing and
8866 freeing the obstack.
8867 * linux-tdep.c (linux_make_mappings_corefile_notes): Use
8868 auto_obstack.
8869 * printcmd.c (printf_wide_c_string, ui_printf): Use auto_obstack.
8870 * rust-exp.y (work_obstack): Now an auto_obstack.
8871 (rust_parse, rust_lex_tests): Use auto_obstack::clear instead of
8872 reinitializing and freeing the obstack.
8873 * utils.c (do_obstack_free, make_cleanup_obstack_free): Delete.
8874 (host_char_to_target): Use auto_obstack.
8875 * utils.h (make_cleanup_obstack_free): Delete declaration.
8876 * valprint.c (generic_emit_char, generic_printstr): Use
8877 auto_obstack.
8878
db665f42
SM
88792017-06-27 Simon Marchi <simon.marchi@ericsson.com>
8880
8881 * darwin-nat.c (darwin_check_new_threads): Don't handle dummy
8882 thread.
8883 (darwin_init_thread_list): Don't update dummy thread.
8884 (darwin_create_inferior, darwin_attach): Don't add a dummy thread.
8885
873c0814
SM
88862017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8887
8888 * record-full.c (netorder16): Remove.
8889
8b5a7a6e
SM
88902017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8891
8892 * common/diagnostics.h: Define macros for GCC.
8893 (DIAGNOSTIC_IGNORE_UNUSED_FUNCTION): New macro.
8894 * common/vec.h: Include diagnostics.h.
8895 (DIAGNOSTIC_IGNORE_UNUSED_VEC_FUNCTION): New macro.
8896 (DEF_VEC_I, DEF_VEC_P, DEF_VEC_O): Ignore -Wunused-function
8897 warning.
8898
d1435379
SM
88992017-06-26 Simon Marchi <simon.marchi@ericsson.com>
8900
8901 * common/diagnostics.h (DIAGNOSTIC_IGNORE_DEPRECATED_REGISTER):
8902 New macro.
8903 * ada-lex.l: Ignore deprecated register warnings.
8904
cc75e0fd
SM
89052017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8906
8907 * main.c (get_init_files): Replace "SYSTEM_GDBINIT +
8908 datadir_len" with "&SYSTEM_GDBINIT[datadir_len]".
8909
07809eaf
SM
89102017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8911
8912 * dtrace-probe.c (dtrace_process_dof_probe): Put semi-colon on
8913 its own line.
8914
f076f034
SM
89152017-06-25 Simon Marchi <simon.marchi@ericsson.com>
8916
8917 * nat/x86-dregs.c (x86_show_dr): Print registers one per line.
8918
0dd5cbc5
AH
89192017-06-23 Alan Hayward <alan.hayward@arm.com>
8920
8921 * xtensa-tdep.c (XTENSA_MAX_REGISTER_SIZE): Add.
8922 (xtensa_register_write_masked): Use XTENSA_MAX_REGISTER_SIZE.
8923 (xtensa_register_read_masked): Likewise.
8924
d4c6ce5b
SDJ
89252017-06-22 Sergio Durigan Junior <sergiodj@redhat.com>
8926
8927 * common/environ.c (gdb_environ::unset): Update comment.
8928
16892a03
AH
89292017-06-22 Alan Hayward <alan.hayward@arm.com>
8930
8931 * python/py-unwind.c (pyuw_sniffer): Allocate space for
8932 registers.
8933
d7dcbefc
AH
89342017-06-22 Alan Hayward <alan.hayward@arm.com>
8935
8936 * record-full.c (record_full_exec_insn): Use byte_vector.
8937
b30ff123
YQ
89382017-06-22 Yao Qi <yao.qi@linaro.org>
8939
8940 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Regenerated.
8941 * regformats/i386/amd64-avx-mpx-avx512-pku.dat: Regenerated.
8942
4fa847d7
AH
89432017-06-22 Alan Hayward <alan.hayward@arm.com>
8944
8945 * remote.c (cached_reg): Move from here...
8946 * regcache.h (cached_reg): ...to here.
8947 * python/py-unwind.c (struct reg_info): Remove.
8948 (cached_frame_info): Use cached_reg_t.
8949 (pyuw_prev_register): Likewise.
8950 (pyuw_sniffer): Use cached_reg_t and allocate registers.
8951 (pyuw_dealloc_cache): Free all registers.
8952
f4906a9a
PA
89532017-06-22 Pedro Alves <palves@redhat.com>
8954 Simon Marchi <simon.marchi@ericsson.com>
8955
8956 * unittests/environ-selftests.c (run_tests): Ignore -Wself-move
8957 warning.
8958 * common/diagnostics.h: New file.
8959
b45a1208
PA
89602017-06-22 Pedro Alves <palves@redhat.com>
8961
8962 * common/agent.h: Add include guards.
8963
e4da2c61
SM
89642017-06-21 Simon Marchi <simon.marchi@ericsson.com>
8965
8966 * target.h (struct target_ops) <to_xfer_partial>: Update doc to
8967 talk about addressable units instead of bytes.
8968
96160d60
SDJ
89692017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
8970
8971 * common/environ.c (gdb_environ::unset): Use '::iterator' instead
8972 of '::const_iterator'.
8973
9a6c7d9c
SDJ
89742017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
8975
8976 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8977 'unittests/environ-selftests.c'.
8978 (SUBDIR_UNITTESTS_OBS): Add 'environ-selftests.o'.
8979 * charset.c (find_charset_names): Declare object 'iconv_env'.
8980 Update code to use 'iconv_env' object. Remove call to
8981 'free_environ'.
8982 * common/environ.c: Include <utility>.
8983 (make_environ): Delete function.
8984 (free_environ): Delete function.
8985 (gdb_environ::clear): New function.
8986 (gdb_environ::operator=): New function.
8987 (gdb_environ::get): Likewise.
8988 (environ_vector): Delete function.
8989 (set_in_environ): Delete function.
8990 (gdb_environ::set): New function.
8991 (unset_in_environ): Delete function.
8992 (gdb_environ::unset): New function.
8993 (gdb_environ::envp): Likewise.
8994 * common/environ.h: Include <vector>.
8995 (struct gdb_environ): Delete; transform into...
8996 (class gdb_environ): ... this class.
8997 (free_environ): Delete prototype.
8998 (init_environ, get_in_environ, set_in_environ, unset_in_environ,
8999 environ_vector): Likewise.
9000 * infcmd.c (run_command_1): Update code to call
9001 'envp' from 'gdb_environ' class.
9002 (environment_info): Update code to call methods from 'gdb_environ'
9003 class.
9004 (unset_environment_command): Likewise.
9005 (path_info): Likewise.
9006 (path_command): Likewise.
9007 * inferior.c (inferior::~inferior): Delete call to 'free_environ'.
9008 (inferior::inferior): Initialize 'environment' using the host's
9009 information.
9010 * inferior.h: Remove forward declaration of 'struct gdb_environ'.
9011 Include "environ.h".
9012 (class inferior) <environment>: Change type from 'struct
9013 gdb_environ' to 'gdb_environ'.
9014 * mi/mi-cmd-env.c (mi_cmd_env_path): Update code to call
9015 methods from 'gdb_environ' class.
9016 * solib.c (solib_find_1): Likewise
9017 * unittests/environ-selftests.c: New file.
9018
75c554cf
YQ
90192017-06-20 Yao Qi <yao.qi@linaro.org>
9020
9021 * features/i386/i386-linux.xml: Exchange the order of including
9022 32bit-linux.xml and 32bit-sse.xml.
9023 * features/i386/i386-linux.c: Regenerated.
9024
72ddacb7
YQ
90252017-06-20 Yao Qi <yao.qi@linaro.org>
9026
9027 * target-descriptions.c (tdesc_reg): Add ctor, dtor.
9028 Delete copy ctor and assignment operator.
9029 (tdesc_type): Likewise.
9030 (tdesc_feature): Likewise.
9031 (tdesc_free_reg): Remove.
9032 (tdesc_create_reg): Use new.
9033 (tdesc_free_type): Remove.
9034 (tdesc_create_vector): Use new.
9035 (tdesc_create_union): Likewise.
9036 (tdesc_create_flags): Likewise.
9037 (tdesc_create_enum): Likewise.
9038 (tdesc_free_feature): Delete.
9039 (free_target_description): Use delete.
9040
325c9fd4
JB
90412017-06-19 John Baldwin <jhb@FreeBSD.org>
9042
9043 * mips-tdep.c (print_gp_register_row): Don't error for unavailable
9044 registers.
9045
16b7a719
PA
90462017-06-19 Pedro Alves <palves@redhat.com>
9047
9048 * dwarf2read.c (write_psymtabs_to_index): Construct file_closer
9049 after gdb::unlinker.
9050
1c8e01c9
SDJ
90512017-06-19 Sergio Durigan Junior <sergiodj@redhat.com>
9052
9053 * mi/mi-cm-env.c (_initialize_mi_cmd_env): Use getenv instead of
9054 gdb_environ to access an environment variable.
9055
ffce45d2
TP
90562017-06-18 Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
9057
9058 * nat/linux-ptrace.c (linux_fork_to_function): Add cast to
9059 gdb_byte*.
9060
1d4fbac9
SM
90612017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9062
9063 * nat/fork-inferior.h (trace_start_error): Add ATTRIBUTE_PRINTF.
9064
8465943a
SM
90652017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9066
9067 * configure: Re-generate.
9068 * warning.m4 (build_warnings): Add -Wno-mismatched-tags.
9069
3e019bdc
SM
90702017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9071
9072 * configure: Re-generate.
9073 * warning.m4: Pass -Werror to compiler when checking for
9074 supported warning flags.
9075
cf0dd6f0
SM
90762017-06-17 Simon Marchi <simon.marchi@ericsson.com>
9077
9078 * Makefile.in (COMPILE.pre): Add "-x c++".
9079
6f98355c
YQ
90802017-06-16 Alan Hayward <alan.hayward@arm.com>
9081 Pedro Alves <palves@redhat.com>
9082 Yao Qi <yao.qi@linaro.org>
9083
9084 * defs.h (RequireLongest): New.
9085 (extract_integer): Declare function template.
9086 (extract_signed_integer): Remove the declaration, but define it
9087 static inline.
9088 (extract_unsigned_integer): Likewise.
9089 (store_integer): Declare function template.
9090 (store_signed_integer): Remove the declaration, but define it
9091 static inline.
9092 (store_unsigned_integer): Likewise.
9093 * findvar.c (extract_integer): New function template.
9094 (extract_signed_integer): Remove.
9095 (extract_unsigned_integer): Remove.
9096 (extract_integer<LONGEST>, extract_integer<ULONGEST>): Explicit
9097 instantiations.
9098 (store_integer): New function template.
9099 (store_signed_integer): Remove.
9100 (store_unsigned_integer): Remove.
9101 (store_integer): Explicit instantiations.
9102 * regcache.c (regcache_raw_read_signed): Update.
9103 (regcache::raw_read): New function.
9104 (regcache::raw_read_signed): Remove.
9105 (regcache::raw_read_unsigned): Remove.
9106 (regcache_raw_read_unsigned): Update.
9107 (regcache_raw_write_unsigned): Update.
9108 (regcache::raw_write_signed): Remove.
9109 (regcache::raw_write): New function.
9110 (regcache_cooked_read_signed): Update.
9111 (regcache::raw_write_unsigned): Remove.
9112 (regcache::cooked_read_signed): Remove.
9113 (regcache_cooked_read_unsigned): Update.
9114 (regcache::cooked_read_unsigned): Remove.
9115 (regcache_cooked_write_signed): Update.
9116 (regcache_cooked_write_unsigned): Update.
9117 * regcache.h (regcache) <raw_read_signed>: Remove.
9118 <raw_write_signed, raw_read_unsigned, raw_write_unsigned>: Remove.
9119 <raw_read, raw_write>: New.
9120 <cooked_read_signed, cooked_write_signed>: Remove.
9121 <cooked_write_unsigned, cooked_read_unsigned>: Remove.
9122 <cooked_read, cooked_write>: New.
9123 * sh64-tdep.c (sh64_pseudo_register_read): Update.
9124 (sh64_pseudo_register_write): Update.
9125
a87dc45a
AK
91262017-06-16 Anton Kolesov <anton.kolesov@synopsys.com>
9127
9128 * arc-tdep.c (arc_disassembler_options): New variable.
9129 (arc_gdbarch_init): Set and use it. Use arc_delayed_print_insn instead
9130 of default_print_insn.
9131 (arc_delayed_print_insn): Set info->section when needed,
9132 use default_print_insn to retrieve a disassembler.
9133
45159d6a
SDJ
91342017-06-14 Sergio Durigan Junior <sergiodj@redhat.com>
9135
9136 PR gdb/21574
9137 * infcmd.c (_initialize_infcmd): Expand "help run" documentation
9138 to mention $SHELL and startup-with-shell.
9139
b46c4cf0
MF
91402017-06-14 Max Filippov <jcmvbkbc@gmail.com>
9141
9142 * MAINTAINERS: Move Maxim Grigoriev to the Past Maintainers.
9143
6394c606
YQ
91442017-06-14 Yao Qi <yao.qi@linaro.org>
9145
9146 * aarch64-tdep.c (aarch64_gdb_print_insn): Call
9147 default_print_insn instead of print_insn_aarch64.
9148 * arm-tdep.c (gdb_print_insn_arm): Call
9149 default_print_insn instead of print_insn_big_arm
9150 and print_insn_little_arm.
9151 * i386-tdep.c (i386_print_insn): Call default_print_insn
9152 instead of print_insn_i386.
9153 * ia64-tdep.c (ia64_print_insn): Call
9154 default_print_insn instead of print_insn_ia64.
9155 * mips-tdep.c (gdb_print_insn_mips): Call
9156 default_print_insn instead of print_insn_big_mips
9157 and print_insn_little_mips.
9158 * spu-tdep.c (gdb_print_insn_spu): Call default_print_insn
9159 instead of print_insn_spu.
9160
d5722aa2
PA
91612017-06-14 Pedro Alves <palves@redhat.com>
9162
9163 * ada-lang.c: Include "common/byte-vector.h".
9164 (ada_value_primitive_packed_val): Use gdb::byte_vector.
9165 * charset.c (wchar_iterator::iterate): Resize the vector instead
9166 of reserving it.
9167 * common/byte-vector.h: Include "common/def-vector.h".
9168 (wchar_iterator::m_out): Now a gdb::def_vector<gdb_wchar_t>.
9169 * cli/cli-dump.c: Include "common/byte-vector.h".
9170 (dump_memory_to_file, restore_binary_file): Use gdb::byte_vector.
9171 * common/byte-vector.h: New file.
9172 * common/def-vector.h: New file.
9173 * common/default-init-alloc.h: New file.
9174 * dwarf2loc.c: Include "common/byte-vector.h".
9175 (rw_pieced_value): Use gdb::byte_vector, and resize the vector
9176 instead of reserving it.
9177 * dwarf2read.c: Include "common/byte-vector.h".
9178 (data_buf::m_vec): Now a gdb::byte_vector.
9179 * gdb_regex.c: Include "common/def-vector.h".
9180 (compiled_regex::compiled_regex): Use gdb::def_vector<char>.
9181 * mi/mi-main.c: Include "common/byte-vector.h".
9182 (mi_cmd_data_read_memory): Use gdb::byte_vector.
9183 * printcmd.c: Include "common/byte-vector.h".
9184 (print_scalar_formatted): Use gdb::byte_vector.
9185 * valprint.c: Include "common/byte-vector.h".
9186 (maybe_negate_by_bytes, print_decimal_chars): Use
9187 gdb::byte_vector.
9188
01ec7a27
SM
91892017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9190
9191 * darwin-nat.c: Include "nat/fork-inferior.h".
9192
848d9074
SM
91932017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9194
9195 * configure.nat: Factor out Darwin bits that are not
9196 architecture-specific. Add fork-inferior.o.
9197
3b912944
SM
91982017-06-13 Simon Marchi <simon.marchi@ericsson.com>
9199
9200 * configure.nat: Factor out AIX bits that are not
9201 architecture-specific. Add fork-inferior.o.
9202
55acdf22
AA
92032017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9204
9205 * dwarf2loc.c (rw_pieced_value): New. Merge logic from...
9206 (read_pieced_value, write_pieced_value): ...here. Reduce to
9207 wrappers that just call rw_pieced_value.
9208
f65e2044
AA
92092017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9210
9211 * dwarf2loc.c (write_pieced_value): When writing the data for a
9212 memory piece, use write_memory_with_notification instead of
9213 write_memory.
9214
23f945bf
AA
92152017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9216
9217 * valops.c (read_value_memory): Change embedded_offset to
9218 represent a bit offset instead of a byte offset.
9219 * value.h (read_value_memory): Adjust comment.
9220
f236533e
AA
92212017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9222
9223 * dwarf2loc.c (read_pieced_value): Remove unnecessary variables
9224 dest_offset_bits and source_offset_bits.
9225 (write_pieced_value): Likewise.
9226
65d84b76
AA
92272017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9228
9229 * dwarf2loc.c (read_pieced_value): Respect the piece offset, as
9230 given by DW_OP_bit_piece.
9231 (write_pieced_value): Likewise.
9232
242d31ab
AA
92332017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9234
9235 * dwarf2loc.c (read_pieced_value): Move the buffer allocation and
9236 some other preparations to the places where sufficient information
9237 is available.
9238 (write_pieced_value): Likewise.
9239
03c8af18
AA
92402017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9241
9242 * dwarf2loc.c (bits_to_bytes): New function.
9243 (read_pieced_value): Fix offset calculations for register pieces
9244 on big-endian targets.
9245 (write_pieced_value): Likewise.
9246
840989c1
AA
92472017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9248
9249 * dwarf2loc.c (read_pieced_value): Remove buffer_size variable.
9250 (write_pieced_value): Likewise.
9251
359b19bb
AA
92522017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9253
9254 * dwarf2loc.c (write_pieced_value): When writing to a bit-field,
9255 transfer the source value's least significant bits, instead of its
9256 lowest-addressed ones. Rename type_len to max_offset.
9257 (read_pieced_value): Mirror above changes to write_pieced_value as
9258 applicable.
9259
07c9ca3b
AA
92602017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9261
9262 * dwarf2loc.c (write_pieced_value): In DWARF_VALUE_MEMORY,
9263 truncate full bytes from dest_offset_bits before using it as an
9264 offset into the buffer.
9265
f1cc9874
AA
92662017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9267
9268 * dwarf2loc.c (write_pieced_value): Include transfer size in
9269 byte-wise check.
9270
cdaac320
AA
92712017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9272
9273 * dwarf2loc.c (write_pieced_value): Fix copy/paste error in the
9274 calculation of this_size.
9275
af547a96
AA
92762017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9277
9278 * dwarf2loc.c (read_pieced_value): Respect parent value's offset
9279 when targeting a bit-field.
9280 (write_pieced_value): Likewise.
9281
ddd7882a
AA
92822017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9283
9284 * dwarf2loc.c (struct piece_closure) <addr_size>: Remove field.
9285 (allocate_piece_closure): Drop addr_size parameter.
9286 (dwarf2_evaluate_loc_desc_full): Adjust call to
9287 allocate_piece_closure.
9288
e9352324
AA
92892017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9290
9291 PR gdb/21226
9292 * dwarf2loc.c (read_pieced_value): Anchor stack value pieces at
9293 the LSB end, independent of endianness.
9294
d5d1163e
AA
92952017-06-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
9296
9297 * dwarf2loc.c (write_pieced_value): Fix order of calculations for
9298 size capping.
9299
032bb6ea
YQ
93002017-06-13 Yao Qi <yao.qi@linaro.org>
9301
9302 * mips-linux-nat.c: Move include features/mips*-linux.c to
9303 mips-linux-tdep.c.
9304 (_initialize_mips_linux_nat): Move initialize_tdesc_mips* calls
9305 to mips-linux-tdep.c.
9306 * mips-linux-tdep.c: Include features/mips*-linux.c
9307 (_initialize_mips_linux_tdep): Call initialize_tdesc_mips*
9308 functions.
9309 * mips-linux-tdep.h (tdesc_mips_linux): Declare.
9310 (tdesc_mips_dsp_linux, tdesc_mips64_linux): Declare.
9311 (tdesc_mips64_dsp_linux): Declare.
9312
f12f6bad
TT
93132017-06-12 Tom Tromey <tom@tromey.com>
9314
9315 * valprint.h (val_print_type_code_int): Remove.
9316 * valprint.c (generic_val_print_int): Always call
9317 val_print_scalar_formatted.
9318 (val_print_type_code_int): Remove.
9319 * printcmd.c (print_scalar_formatted): Handle options->format==0.
9320 * f-valprint.c (f_val_print): Use val_print_scalar_formatted.
9321 * c-valprint.c (c_val_print_int): Use val_print_scalar_formatted.
9322 * ada-valprint.c (ada_val_print_num): Use
9323 val_print_scalar_formatted.
9324
d9109c80
TT
93252017-06-12 Tom Tromey <tom@tromey.com>
9326
9327 * printcmd.c (print_scalar_formatted): Unify the two switches.
9328 Don't convert scalars to LONGEST.
9329
4ac0cb1c
TT
93302017-06-12 Tom Tromey <tom@tromey.com>
9331
9332 PR exp/16225:
9333 * valprint.h (print_decimal_chars): Update.
9334 * valprint.c (maybe_negate_by_bytes): New function.
9335 (print_decimal_chars): Add "is_signed" argument.
9336 * printcmd.c (print_scalar_formatted): Update.
9337
30a25466
TT
93382017-06-12 Tom Tromey <tom@tromey.com>
9339
9340 PR exp/16225:
9341 * valprint.h (print_binary_chars, print_hex_chars): Update.
9342 * valprint.c (val_print_type_code_int): Update.
9343 (print_binary_chars): Add "zero_pad" argument.
9344 (emit_octal_digit): New function.
9345 (print_octal_chars): Don't zero-pad.
9346 (print_decimal_chars): Likewise.
9347 (print_hex_chars): Add "zero_pad" argument.
9348 * sh64-tdep.c (sh64_do_fp_register): Update.
9349 * regcache.c (regcache::dump): Update.
9350 * printcmd.c (print_scalar_formatted): Update.
9351 * infcmd.c (default_print_one_register_info): Update.
9352
b3464d03
PA
93532017-06-12 Pedro Alves <palves@redhat.com>
9354 Alan Hayward <alan.hayward@arm.com>
9355
9356 * mips-tdep.c (MAX_MIPS_ABI_REGSIZE): New.
9357 (mips_eabi_push_dummy_call): Rename local 'regsize' to
9358 'abi_regsize'. Rename local array 'valbuf' to 'ref_valbuf', and
9359 use MAX_MIPS_ABI_REGSIZE instead of MAX_REGISTER_SIZE to size it.
9360 Assert that abi_regsize bytes fit in 'ref_valbuf'.
9361
4b76cda9
PA
93622017-06-12 Pedro Alves <palves@redhat.com>
9363
9364 * dwarf2read.c (mapped_symtab::data): Now a vector of
9365 symtab_index_entry instead of vector of
9366 std::unique_ptr<symtab_index_entry>. All users adjusted to check
9367 whether an element's name is NULL instead of checking whether the
9368 element itself is NULL.
9369 (find_slot): Change return type. Adjust.
9370 (hash_expand, , add_index_entry, uniquify_cu_indices)
9371 (write_hash_table): Adjust.
9372
e8f8bcb3
PA
93732017-06-12 Pedro Alves <palves@redhat.com>
9374
9375 * dwarf2read.c (recursively_count_psymbols): New function.
9376 (write_psymtabs_to_index): Call it to compute number of psyms and
9377 pass estimate size of psyms_seen to unordered_set's ctor.
9378
70a1152b
PA
93792017-06-12 Pedro Alves <palves@redhat.com>
9380
9381 * dwarf2read.c (write_hash_table): Check if key already exists
9382 before emplacing.
9383
c2f134ac
PA
93842017-06-12 Pedro Alves <palves@redhat.com>
9385
9386 * dwarf2read.c (data_buf::append_space): Rename to...
9387 (data_buf::grow): ... this, and make private. Adjust all callers.
9388 (data_buf::append_uint): New method.
9389 (add_address_entry, write_one_signatured_type)
9390 (write_psymtabs_to_index): Use it.
9391
a81e6d4d
PA
93922017-06-12 Pedro Alves <palves@redhat.com>
9393
9394 * dwarf2read.c (file_write(FILE *, const void *, size_t)): Delete.
9395 (file_write (FILE *, const std::vector<Elem>&)): Delete.
9396 (data_buf::file_write): Call ::fwrite directly.
9397
6fd931f2
PA
93982017-06-12 Pedro Alves <palves@redhat.com>
9399
9400 * dwarf2read.c (uniquify_cu_indices): Use std::unique and
9401 std::vector::erase.
9402
bc8f2430
JK
94032017-06-12 Jan Kratochvil <jan.kratochvil@redhat.com>
9404
9405 Code cleanup: C++ify .gdb_index producer.
9406 * dwarf2read.c: Include <unordered_set> and <unordered_map>.
9407 (MAYBE_SWAP) [WORDS_BIGENDIAN]: Cast to offset_type.
9408 (struct strtab_entry, hash_strtab_entry, eq_strtab_entry)
9409 (create_strtab, add_string): Remove.
9410 (file_write, data_buf): New.
9411 (struct symtab_index_entry): Use std::vector for cu_indices.
9412 (struct mapped_symtab): Use std::vector for data.
9413 (hash_symtab_entry, eq_symtab_entry, delete_symtab_entry)
9414 (create_symbol_hash_table, create_mapped_symtab, cleanup_mapped_symtab):
9415 Remove.
9416 (find_slot): Change return type. Update it to the new data structures.
9417 (hash_expand, add_index_entry): Update it to the new data structures.
9418 (offset_type_compare): Remove.
9419 (uniquify_cu_indices): Update it to the new data structures.
9420 (c_str_view, c_str_view_hasher, vector_hasher): New.
9421 (add_indices_to_cpool): Remove.
9422 (write_hash_table): Update it to the new data structures.
9423 (struct psymtab_cu_index_map, hash_psymtab_cu_index)
9424 (eq_psymtab_cu_index): Remove.
9425 (psym_index_map): New typedef.
9426 (struct addrmap_index_data): Change addr_obstack pointer to data_buf
9427 reference and std::unordered_map for cu_index_htab.
9428 (add_address_entry, add_address_entry_worker, write_address_map)
9429 (write_psymbols): Update it to the new data structures.
9430 (write_obstack): Remove.
9431 (struct signatured_type_index_data): Change types_list to a data_buf
9432 reference and psyms_seen to a std::unordered_set reference.
9433 (write_one_signatured_type, recursively_write_psymbols)
9434 (write_psymtabs_to_index): Update it to the new data structures.
9435
c4dcb155
SM
94362017-06-11 Simon Marchi <simon.marchi@ericsson.com>
9437
9438 * NEWS (Changes since GDB 8.0): Announce {set,show} debug
9439 separate-debug-file commands.
9440 * symfile.h (separate_debug_file_debug): New global.
9441 * symfile.c (separate_debug_file_debug): New global.
9442 (separate_debug_file_exists, find_separate_debug_file): Add
9443 debug output.
9444 (_initialize_symfile): Add "set debug separate-debug-file"
9445 command.
9446 * build-id.c (build_id_to_debug_bfd,
9447 find_separate_debug_file_by_buildid): Add debug output.
9448
6d45d4b4
SM
94492017-06-10 Simon Marchi <simon.marchi@polymtl.ca>
9450
9451 * gdbarch.sh (displaced_step_free_closure): Remove.
9452 * gdbarch.h, gdbarch.c: Re-generate.
9453 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Don't set
9454 displaced_step_free_closure.
9455 * amd64-linux-tdep.c (amd64_linux_init_abi_common): Likewise.
9456 * arm-linux-tdep.c (arm_linux_init_abi): Likewise.
9457 * i386-linux-tdep.c (i386_linux_init_abi): Likewise.
9458 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
9459 * rs6000-tdep.c (rs6000_gdbarch_init): Likewise.
9460 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
9461 * arch-utils.h (simple_displaced_step_free_closure): Remove.
9462 * arch-utils.c (simple_displaced_step_free_closure): Remove.
9463 * infrun.c (displaced_step_clear): Call xfree instead of
9464 gdbarch_displaced_step_free_closure.
9465
2f91880f
SDJ
94662017-06-08 Sergio Durigan Junior <sergiodj@redhat.com>
9467
9468 * common/common-utils.c (stringify_argv): Check for "arg[0] !=
9469 NULL".
9470
b8b6e72f
AH
94712017-06-08 Alan Hayward <alan.hayward@arm.com>
9472
9473 * mn10300-tdep.c (MN10300_MAX_REGISTER_SIZE): Add.
9474 (mn10300_extract_return_value): Use MN10300_MAX_REGISTER_SIZE.
9475 (mn10300_push_dummy_call): Likewise.
9476
5369082e
AH
94772017-06-08 Alan Hayward <alan.hayward@arm.com>
9478
9479 * mi/mi-main.c (register_changed_p): Use value_contents_eq.
9480
ff4ca5ac
AH
94812017-06-08 Alan Hayward <alan.hayward@arm.com>
9482
9483 * mi/mi-main.c (register_changed_p): Use cooked_read_value.
9484
aefd8b33
SDJ
94852017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9486
9487 * NEWS (Changes since GDB 8.0): Announce that GDBserver is now
9488 able to start inferiors using a shell.
9489 (New remote packets): Announce new packet "QStartupWithShell".
9490 * remote.c: Add PACKET_QStartupWithShell.
9491 (extended_remote_create_inferior): Handle new
9492 PACKET_QStartupWithShell.
9493 (remote_protocol_features) <QStartupWithShell>: New entry for
9494 PACKET_QStartupWithShell.
9495 (_initialize_remote): Call "add_packet_config_cmd" for
9496 QStartupShell.
9497
2090129c
SDJ
94982017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9499 Pedro Alves <palves@redhat.com>
9500
9501 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-inferior.h"
9502 and "nat/fork-inferior.h".
9503 * common/common-inferior.h: New file, with contents from
9504 "gdb/inferior.h".
9505 * commom/common-utils.c: Include "common-utils.h".
9506 (stringify_argv): New function.
9507 * common/common-utils.h (stringify_argv): New prototype.
9508 * configure.nat: Add "fork-inferior.o" as a dependency for
9509 "*linux*", "fbsd*" and "nbsd*" hosts.
9510 * corefile.c (get_exec_file): Update comment.
9511 * darwin-nat.c (darwin_ptrace_him): Call "gdb_startup_inferior"
9512 instead of "startup_inferior".
9513 (darwin_create_inferior): Call "add_thread_silent" after
9514 "fork_inferior".
9515 * fork-child.c: Cleanup unnecessary includes.
9516 (SHELL_FILE): Move to "common/common-fork-child.c".
9517 (environ): Likewise.
9518 (exec_wrapper): Initialize.
9519 (get_exec_wrapper): New function.
9520 (breakup_args): Move to "common/common-fork-child.c"; rename to
9521 "breakup_args_for_exec".
9522 (escape_bang_in_quoted_argument): Move to
9523 "common/common-fork-child.c".
9524 (saved_ui): New variable.
9525 (prefork_hook): New function.
9526 (postfork_hook): Likewise.
9527 (postfork_child_hook): Likewise.
9528 (gdb_startup_inferior): Likewise.
9529 (fork_inferior): Move to "common/common-fork-child.c". Update
9530 function to support gdbserver.
9531 (startup_inferior): Likewise.
9532 * gdbcore.h (get_exec_file): Remove declaration.
9533 * gnu-nat.c (gnu_create_inferior): Call "gdb_startup_inferior"
9534 instead of "startup_inferior". Call "add_thread_silent" after
9535 "fork_inferior".
9536 * inf-ptrace.c: Include "nat/fork-inferior.h" and "utils.h".
9537 (inf_ptrace_create_inferior): Call "gdb_startup_inferior"
9538 instead of "startup_inferior". Call "add_thread_silent" after
9539 "fork_inferior".
9540 * inferior.h: Include "common-inferior.h".
9541 (trace_start_error): Move to "common/common-utils.h".
9542 (trace_start_error_with_name): Likewise.
9543 (fork_inferior): Move prototype to "nat/fork-inferior.h".
9544 (startup_inferior): Likewise.
9545 (gdb_startup_inferior): New prototype.
9546 * nat/fork-inferior.c: New file, with contents from "fork-child.c".
9547 * nat/fork-inferior.h: New file.
9548 * procfs.c (procfs_init_inferior): Call "gdb_startup_inferior"
9549 instead of "startup_inferior". Call "add_thread_silent" after
9550 "fork_inferior".
9551 * target.h (target_terminal_init): Move prototype to
9552 "target/target.h".
9553 (target_terminal_inferior): Likewise.
9554 (target_terminal_ours): Likewise.
9555 * target/target.h (target_terminal_init): New prototype, moved
9556 from "target.h".
9557 (target_terminal_inferior): Likewise.
9558 (target_terminal_ours): Likewise.
9559 * utils.c (gdb_flush_out_err): New function.
9560
043a4934
SDJ
95612017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9562
9563 * Makefile.in (HFILES_NO_SRCDIR): Add "common/common-gdbthread.h".
9564 * common/common-gdbthread.h: New file, with parts from
9565 "gdb/gdbthread.h".
9566 * gdbthread.h: Include "common-gdbthread.h".
9567 (switch_to_thread): Moved to "common/common-gdbthread.h".
9568
15652511
SDJ
95692017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
9570
9571 * Makefile.in (SFILES): Add "common/job-control.c".
9572 (HFILES_NO_SRCDIR): Add "common/job-control.h".
9573 (COMMON_OBS): Add "job-control.o".
9574 * common/job-control.c: New file, with contents from
9575 "gdb/inflow.c".
9576 * common/job-control.h: New file, with contents from "terminal.h".
9577 * fork-child.c: Include "job-control.h".
9578 * inflow.c: Include "job-control.h".
9579 (gdb_setpgid): Move to "common/common-inflow.c".
9580 (_initialize_inflow): Move setting of "job_control" to
9581 "handle_job_control".
9582 * terminal.h (job_control): Moved to "common/common-terminal.h".
9583 (gdb_setpgid): Likewise.
9584 * top.c: Include "job_control.h".
9585 * utils.c: Likewise.
9586 (job_control): Moved to "job-control.c".
9587
2d7cc5c7
PA
95882017-06-07 Pedro Alves <palves@redhat.com>
9589
9590 * Makefile.in (SFILES): Add gdb_regex.c.
9591 (COMMON_OBS): Add gdb_regex.o.
9592 * ada-lang.c (ada_add_standard_exceptions)
9593 (ada_add_exceptions_from_frame, name_matches_regex)
9594 (ada_add_global_exceptions, ada_exceptions_list_1): Change regex
9595 parameter type to compiled_regex. Adjust.
9596 (ada_exceptions_list): Use compiled_regex.
9597 * break-catch-throw.c (exception_catchpoint::pattern): Now a
9598 std::unique_ptr<compiled_regex>.
9599 (exception_catchpoint::~exception_catchpoint): Remove regfree
9600 call.
9601 (check_status_exception_catchpoint): Adjust to use compiled_regex.
9602 (handle_gnu_v3_exceptions): Adjust to use compiled_regex.
9603 * breakpoint.c (solib_catchpoint::compiled): Now a
9604 std::unique_ptr<compiled_regex>.
9605 (solib_catchpoint::~solib_catchpoint): Remove regfree call.
9606 (check_status_catch_solib): Adjust to use compiled_regex.
9607 (add_solib_catchpoint): Adjust to use compiled_regex.
9608 * cli/cli-cmds.c (apropos_command): Use compiled_regex.
9609 * cli/cli-decode.c (apropos_cmd): Change regex parameter to
9610 compiled_regex reference. Adjust to use it.
9611 * cli/cli-decode.h: Remove struct re_pattern_buffer forward
9612 declaration. Include "gdb_regex.h".
9613 (apropos_cmd): Change regex parameter to compiled_regex reference.
9614 * gdb_regex.c: New file.
9615 * gdb_regex.h (make_regfree_cleanup, get_regcomp_error): Delete
9616 declarations.
9617 (class compiled_regex): New.
9618 * linux-tdep.c: Include "common/gdb_optional.h".
9619 (struct mapping_regexes): New, factored out from
9620 mapping_is_anonymous_p, and adjusted to use compiled_regex.
9621 (mapping_is_anonymous_p): Use mapping_regexes wrapped in a
9622 gdb::optional and remove cleanups. Adjust to compiled_regex.
9623 * probe.c: Include "common/gdb_optional.h".
9624 (collect_probes): Use compiled_regex and gdb::optional and remove
9625 cleanups.
9626 * skip.c: Include "common/gdb_optional.h".
9627 (skiplist_entry::compiled_function_regexp): Now a
9628 gdb::optional<compiled_regex>.
9629 (skiplist_entry::compiled_function_regexp_is_valid): Delete field.
9630 (free_skiplist_entry): Remove regfree call.
9631 (compile_skip_regexp, skip_rfunction_p): Adjust to use
9632 compiled_regex and gdb::optional.
9633 * symtab.c: Include "common/gdb_optional.h".
9634 (search_symbols): Use compiled_regex and gdb::optional.
9635 * utils.c (do_regfree_cleanup, make_regfree_cleanup)
9636 (get_regcomp_error, compile_rx_or_error): Delete. Some bits moved
9637 to gdb_regex.c.
9638
50d6adef
AH
96392017-06-07 Alan Hayward <alan.hayward@arm.com>
9640
9641 * regcache.c (regcache::save): Avoid buffer use.
9642 (regcache::dump): Likewise.
9643
4a8a33c8
AH
96442017-06-07 Alan Hayward <alan.hayward@arm.com>
9645
9646 * sh-tdep.c (sh_pseudo_register_read): Remove
9647 MAX_REGISTER_SIZE.
9648 (sh_pseudo_register_write): Likewise.
9649 * sh64-tdep.c (sh64_pseudo_register_read): Likewise.
9650 (sh64_pseudo_register_write): Likewise
9651
d1be909e
AH
96522017-06-07 Alan Hayward <alan.hayward@arm.com>
9653
9654 * aarch64-tdep.c (aarch64_store_return_value): Use
9655 V_REGISTER_SIZE.
9656 (aarch64_pseudo_read_value): Likewise.
9657 (aarch64_pseudo_write): Likewise.
9658
f4a65042
YQ
96592017-06-06 Yao Qi <yao.qi@linaro.org>
9660
9661 * regformats/regdef.h (set_register_cache): Remove the
9662 declaration.
9663
9f7fb0aa
AH
96642017-06-06 Alan Hayward <alan.hayward@arm.com>
9665
9666 * frame.c (frame_unwind_register_signed): Use
9667 frame_unwind_register_value.
9668
e1e01040
PA
96692017-06-06 Pedro Alves <palves@redhat.com>
9670
9671 PR breakpoints/21553
9672 * breakpoint.c (create_breakpoints_sal_default)
9673 (init_breakpoint_sal, create_breakpoint_sal): Use
9674 gdb::unique_xmalloc_ptr for string parameters.
9675 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9676 parameters. Replace cleanups with gdb::unique_xmalloc_ptr.
9677 (base_breakpoint_create_breakpoints_sal)
9678 (bkpt_create_breakpoints_sal, tracepoint_create_breakpoints_sal)
9679 (strace_marker_create_breakpoints_sal)
9680 (create_breakpoints_sal_default): Use gdb::unique_xmalloc_ptr for
9681 string parameters.
9682 * breakpoint.h (breakpoint_ops::create_breakpoints_sal): Use
9683 gdb::unique_xmalloc_ptr for string parameters.
9684 (create_breakpoint): Constify 'extra_string' and 'cond_string'
9685 parameters.
9686
fbe654c8
AH
96872017-06-06 Alan Hayward <alan.hayward@arm.com>
9688
9689 * alpha-tdep.c (alpha_register_to_value): Use
9690 get_frame_register_value.
9691 (alpha_value_to_register): Use ALPHA_REGISTER_SIZE.
9692
ae0d01d6
AH
96932017-06-06 Alan Hayward <alan.hayward@arm.com>
9694
9695 * ia64-tdep.c (IA64_MAX_FP_REGISTER_SIZE) Add.
9696 (ia64_register_to_value): Use IA64_MAX_FP_REGISTER_SIZE.
9697 (ia64_value_to_register): Likewise.
9698 (ia64_extract_return_value): Likewise.
9699 (ia64_store_return_value): Likewise.
9700 (ia64_push_dummy_call): Likewise.
9701
49cf576c
JB
97022017-06-04 Joel Brobecker <brobecker@adacore.com>
9703
9704 GDB 8.0 released.
9705
26b6a6ab
SM
97062017-06-03 Simon Marchi <simon.marchi@ericsson.com>
9707
9708 * x86-linux-nat.c (struct arch_lwp_info): Remove.
9709
22827c51
SM
97102017-06-03 Simon Marchi <simon.marchi@polymtl.ca>
9711
9712 * linux-nat.c (linux_nat_post_attach_wait): Remove FIRST
9713 parameter.
9714 (linux_nat_attach): Adjust call to linux_nat_post_attach_wait.
9715
0e05cf3a
SM
97162017-06-02 Simon Marchi <simon.marchi@ericsson.com>
9717
9718 * event-loop.c (poll_timers): Unallocate timer using delete
9719 instead of xfree.
9720
c1fc2657
SM
97212017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9722
9723 * breakpoint.h (struct breakpoint_ops) <dtor>: Remove.
9724 (struct breakpoint) <~breakpoint>: New.
9725 (struct watchpoint): Inherit from breakpoint.
9726 <~watchpoint>: New.
9727 <base>: Remove.
9728 (struct tracepoint): Inherit from breakpoint.
9729 <base>: Remove.
9730 * breakpoint.c (longjmp_breakpoint_ops): Remove.
9731 (struct longjmp_breakpoint): Inherit from breakpoint.
9732 <~longjmp_breakpoint>: New.
9733 <base>: Remove.
9734 (new_breakpoint_from_type): Remove casts.
9735 (watchpoint_in_thread_scope): Remove reference to base field.
9736 (watchpoint_del_at_next_stop): Likewise.
9737 (update_watchpoint): Likewise.
9738 (watchpoint_check): Likewise.
9739 (bpstat_check_watchpoint): Likewise.
9740 (set_longjmp_breakpoint): Likewise.
9741 (struct fork_catchpoint): Inherit from breakpoint.
9742 <base>: Remove.
9743 (struct solib_catchpoint): Inherit from breakpoint.
9744 <~solib_catchpoint>: New.
9745 <base>: Remove.
9746 (dtor_catch_solib): Change to ...
9747 (solib_catchpoint::~solib_catchpoint): ... this.
9748 (breakpoint_hit_catch_solib): Remove reference to base field.
9749 (add_solib_catchpoint): Likewise.
9750 (create_fork_vfork_event_catchpoint): Likewise.
9751 (struct exec_catchpoint): Inherit from breakpoint.
9752 <~exec_catchpoint>: New.
9753 <base>: Remove.
9754 (dtor_catch_exec): Change to ...
9755 (exec_catchpoint::~exec_catchpoint): ... this.
9756 (dtor_watchpoint): Change to ...
9757 (watchpoint::~watchpoint): ... this.
9758 (watch_command_1): Remove reference to base field.
9759 (catch_exec_command_1): Likewise.
9760 (base_breakpoint_dtor): Change to ...
9761 (breakpoint::~breakpoint): ... this.
9762 (base_breakpoint_ops): Remove dtor field value.
9763 (longjmp_bkpt_dtor): Change to ...
9764 (longjmp_breakpoint::~longjmp_breakpoint): ... this.
9765 (strace_marker_create_breakpoints_sal): Remove reference to base
9766 field.
9767 (delete_breakpoint): Don't manually call breakpoint destructor.
9768 (create_tracepoint_from_upload): Remove reference to base field.
9769 (trace_pass_set_count): Likewise.
9770 (initialize_breakpoint_ops): Don't initialize
9771 momentary_breakpoint_ops, don't set dtors.
9772 * ada-lang.c (struct ada_catchpoint): Inherit from breakpoint.
9773 <~ada_catchpoint>: New.
9774 <base>: Remove.
9775 (create_excep_cond_exprs): Remove reference to base field.
9776 (dtor_exception): Change to ...
9777 (ada_catchpoint::~ada_catchpoint): ... this.
9778 (dtor_catch_exception): Remove.
9779 (dtor_catch_exception_unhandled): Remove.
9780 (dtor_catch_assert): Remove.
9781 (create_ada_exception_catchpoint): Remove reference to base
9782 field.
9783 (initialize_ada_catchpoint_ops): Don't set dtors.
9784 * break-catch-sig.c (struct signal_catchpoint): Inherit from
9785 breakpoint.
9786 <~signal_catchpoint>: New.
9787 <base>: Remove.
9788 (signal_catchpoint_dtor): Change to ...
9789 (signal_catchpoint::~signal_catchpoint): ... this.
9790 (create_signal_catchpoint): Remove reference to base field.
9791 (initialize_signal_catchpoint_ops): Don't set dtor.
9792 * break-catch-syscall.c (struct syscall_catchpoint): Inherit
9793 from breakpoint.
9794 <~syscall_catchpoint>: New.
9795 <base>: Remove.
9796 (dtor_catch_syscall): Change to ...
9797 (syscall_catchpoint::~syscall_catchpoint): ... this.
9798 (create_syscall_event_catchpoint): Remove reference to base
9799 field.
9800 (initialize_syscall_catchpoint_ops): Don't set dtor.
9801 * break-catch-throw.c (struct exception_catchpoint): Inherit
9802 from breakpoint.
9803 <~exception_catchpoint>: New.
9804 <base>: Remove.
9805 (dtor_exception_catchpoint): Change to ...
9806 (exception_catchpoint::~exception_catchpoint): ... this.
9807 (handle_gnu_v3_exceptions): Remove reference to base field.
9808 (initialize_throw_catchpoint_ops): Don't set dtor.
9809 * ctf.c (ctf_get_traceframe_address): Remove reference to base
9810 field.
9811 * remote.c (remote_get_tracepoint_status): Likewise.
9812 * tracefile-tfile.c (tfile_get_traceframe_address): Likewise.
9813 * tracefile.c (tracefile_fetch_registers): Likewise.
9814 * tracepoint.c (actions_command): Likewise.
9815 (validate_actionline): Likewise.
9816 (tfind_1): Likewise.
9817 (get_traceframe_location): Likewise.
9818 (find_matching_tracepoint_location): Likewise.
9819 (parse_tracepoint_status): Likewise.
9820 * mi/mi-cmd-break.c (mi_cmd_break_passcount): Likewise.
9821
3b0871f4
SM
98222017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9823
9824 * breakpoint.c (struct longjmp_breakpoint): New struct.
9825 (is_tracepoint_type): Change return type to bool.
9826 (is_longjmp_type): New function.
9827 (new_breakpoint_from_type): Handle longjmp kinds of breakpoints.
9828 (set_raw_breakpoint_without_location): Use
9829 new_breakpoint_from_type.
9830 (set_raw_breakpoint): Likewise.
9831
a5e364af
SM
98322017-06-02 Simon Marchi <simon.marchi@polymtl.ca>
9833
9834 * breakpoint.c (new_breakpoint_from_type): New function.
9835 (create_breakpoint_sal): Use new_breakpoint_from_type and
9836 unique_ptr.
9837 (create_breakpoint): Likewise.
9838
ae3b3f34
SM
98392017-05-31 Simon Marchi <simon.marchi@ericsson.com>
9840
9841 * memattr.c (mem_info_command): Rename to ...
9842 (info_mem_command): ... this.
9843 (mem_enable_command): Rename to ...
9844 (enable_mem_command): ... this.
9845 (mem_disable_command): Rename to ...
9846 (disable_mem_command): ... this.
9847 (mem_delete_command): Rename to ...
9848 (delete_mem_command): ... this.
9849 (_initialize_mem): Adjust function names.
9850
13ace077
MM
98512017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9852
9853 * btrace.c (handle_pt_insn_events): New.
9854 (ftrace_add_pt): Call handle_pt_insn_events. Rename ERRCODE into
9855 STATUS. Split into this and ...
9856 (handle_pt_insn_event_flags): ... this.
9857
c56ccc05
MM
98582017-05-31 Markus Metzger <markus.t.metzger@intel.com>
9859
9860 * configure.ac: Check for pt_insn_event, struct pt_insn.enabled,
9861 and struct pt_insn.resynced.
9862 * configure: Regenerated.
9863 * config.in: Regenerated.
9864
08c3f6d2
TW
98652017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9866
9867 * btrace.c (ftrace_find_call_by_number): New function.
9868 (ftrace_new_function): Store objects, not pointers.
9869 (ftrace_find_call_by_number, ftrace_new_return, ftrace_new_switch,
9870 ftrace_new_gap, ftrace_update_function,
9871 ftrace_compute_global_level_offset, btrace_stich_bts, btrace_clear,
9872 btrace_insn_get, btrace_insn_get_error, btrace_insn_end,
9873 btrace_insn_next, btrace_insn_prev, ptrace_find_insn_by_number,
9874 btrace_ends_with_single_insn, btrace_call_get): Account for
9875 btrace_thread_info::functions now storing objects.
9876 * btrace.h (struct btrace_thread_info): Add constructor.
9877 (struct btrace_thread_info) <functions>: Make std::vector.
9878 (struct btrace_thread_info) <prev, next, up, insn, errcode, flags):
9879 Initialize with default values.
9880 * record-btrace.c (record_btrace_frame_sniffer): Account for
9881 btrace_thread_info::functions now storing objects.
9882
8ffd39f2
TW
98832017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9884
9885 * btrace.c: Remove typedef bfun_s.
9886 (ftrace_new_gap): Directly add gaps to the list of gaps.
9887 (btrace_bridge_gaps, btrace_compute_ftrace_bts, pt_btrace_insn_flags,
9888 ftrace_add_pt, btrace_compute_ftrace_pt, btrace_compute_ftrace_1,
9889 btrace_finalize_ftrace, btrace_compute_ftrace): Use std::vector
9890 instead of gdb VEC.
9891
4aeb0dfc
TW
98922017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9893
9894 * btrace.c (ftrace_fixup_caller, ftrace_new_return, ftrace_connect_bfun,
9895 ftrace_bridge_gap): Replace references to btrace_thread_info::segment
9896 with btrace_thread_info::next_segment and
9897 btrace_thread_info::prev_segment.
9898 * btrace.h: Remove struct btrace_func_link.
9899 (struct btrace_function): Replace pair of function segment pointers
9900 with pair of indices.
9901 * python/py-record-btrace.c (btpy_call_prev_sibling,
9902 btpy_call_next_sibling): Replace references to
9903 btrace_thread_info::segment with btrace_thread_info::next_segment and
9904 btrace_thread_info::prev_segment.
9905 * record-btrace.c (record_btrace_frame_this_id): Use
9906 btrace_find_call_by_number.
9907
eb8f2b9c
TW
99082017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9909
9910 * btrace.c (ftrace_new_function, ftrace_fixup_level,
9911 ftrace_connect_bfun, ftrace_bridge_gap, btrace_bridge_gaps,
9912 btrace_insn_next, btrace_insn_prev): Remove references to
9913 btrace_thread_info::flow.
9914 * btrace.h (struct btrace_function): Remove FLOW.
9915
42bfe59e
TW
99162017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9917
9918 * btrace.c (ftrace_find_call_by_number): New function.
9919 (ftrace_update_caller, ftrace_new_call, ftrace_new_tailcall,
9920 ftrace_get_caller, ftrace_find_call, ftrace_new_return,
9921 ftrace_match_backtrace, ftrace_connect_bfun, ftrace_connect_backtrace,
9922 ftrace_bridge_gap, btrace_bridge_gaps): Use btrace_function::up as an
9923 index.
9924 * btrace.h (struct btrace_function): Turn UP into an index.
9925 * python/py-record-btrace.c (btpy_call_up): Use btrace_function::up
9926 as an index.
9927 * record-btrace.c (record_btrace_frame_unwind_stop_reason,
9928 record_btrace_frame_prev_register, record_btrace_frame_sniffer,
9929 record_btrace_tailcall_frame_sniffe): Use btrace_find_call_by_number.
9930
b54b03bd
TW
99312017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9932
9933 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9934 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9935 ftrace_update_function, ftrace_compute_global_level_offset,
9936 btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt,
9937 btrace_stitch_bts, btrace_fetch, btrace_clear, btrace_insn_number,
9938 btrace_insn_end, btrace_is_empty): Remove references to
9939 btrace_thread_info::begin and btrace_thread_info::end.
9940 * btrace.h (struct btrace_thread_info): Remove BEGIN and END.
9941 (struct btrace_thread_info) <functions>: Adjust comment.
9942 * record-btrace.c (record_btrace_start_replaying): Remove reference to
9943 btrace_thread_info::begin.
9944
8286623c
TW
99452017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9946
9947 * btrace.c (ftrace_new_function, ftrace_new_call, ftrace_new_tailcall,
9948 ftrace_new_return, ftrace_new_switch, ftrace_new_gap,
9949 ftrace_update_function): Remove arguments that implicitly were always
9950 BTINFO->END.
9951 (btrace_compute_ftrace_bts, ftrace_add_pt, btrace_compute_ftrace_pt):
9952 Don't pass BTINFO->END.
9953
a0f1b963
TW
99542017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9955
9956 * btrace.c: (btrace_insn_get, btrace_insn_get_error, btrace_insn_number,
9957 btrace_insn_begin, btrace_insn_end, btrace_insn_next, btrace_insn_prev,
9958 btrace_find_insn_by_number): Replace function segment pointer with
9959 index.
9960 (btrace_insn_cmp): Simplify.
9961 * btrace.h: (struct btrace_insn_iterator) Rename index to
9962 insn_index. Replace function segment pointer with index into function
9963 segment vector.
9964 * record-btrace.c (record_btrace_call_history): Replace function
9965 segment pointer use with index.
9966 (record_btrace_frame_sniffer): Retrieve function call segment through
9967 vector.
9968 (record_btrace_set_replay): Remove defunc't safety check.
9969
f158f208
TW
99702017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9971
9972 * btrace.c (btrace_ends_with_single_insn): New function.
9973 (btrace_call_get, btrace_call_number, btrace_call_begin,
9974 btrace_call_end, btrace_call_next, btrace_call_prev,
9975 btrace_find_call_by_number): Use index into call segment vector
9976 instead of pointer.
9977 (btrace_call_cmp): Simplify.
9978 * btrace.h (struct btrace_call_iterator): Replace function call segment
9979 pointer with index into vector.
9980 * record-btrace.c (record_btrace_call_history): Use index instead of
9981 pointer.
9982
521103fd
TW
99832017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9984
9985 * btrace.c (btrace_insn_begin, btrace_insn_end,
9986 btrace_find_insn_by_number): Add btinfo to iterator.
9987 * btrace.h (struct btrace_insn_iterator): Add btinfo.
9988
17b89b34
TW
99892017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
9990
9991 * btrace.c (ftrace_new_function): Add btrace_thread_info to arguments
9992 and save pointers directly.
9993 (ftrace_new_call, ftrace_new_tailcall, ftrace_new_return,
9994 ftrace_new_switch, ftrace_new_gap, ftrace_update_function,
9995 ftrace_add_pt): Add btrace_thread_info to arguments. Adjust for
9996 changed signature of functions.
9997 (btrace_compute_ftrace_pt): Adjust for changed signature of functions.
9998 (btrace_fetch): Remove code that adds btrace_function pointers to
9999 vector of btrace_functions.
10000 (btrace_clear): Simplify freeing vector of btrace_functions.
10001
2b51eddc
TW
100022017-05-30 Tim Wiederhake <tim.wiederhake@intel.com>
10003
10004 * btrace.c (btrace_fetch, btrace_clear, btrace_find_insn_by_number):
10005 Replace VEC_* with std::vector functions.
10006 * btrace.h: Add include: vector. Remove typedef for DEF_VEC_P.
10007 (struct btrace_thread_info)<functions>: Change type to std::vector.
10008
db6be0d5
SM
100092017-05-30 Simon Marchi <simon.marchi@ericsson.com>
10010
10011 * NEWS (Changes in GDB 8.0): Remove extra empty line. Move
10012 "Removed targets and native configurations" up. Merge duplicate
10013 "New commands" sub-sections. Add "New options" sub-sections.
10014
b057297a
AH
100152017-05-26 Alan Hayward <alan.hayward@arm.com>
10016
10017 * defs.h (copy_integer_to_size): New declaration.
10018 * findvar.c (copy_integer_to_size): New function.
10019 (do_cint_test): New selftest function.
10020 (copy_integer_to_size_test): Likewise.
10021 (_initialize_findvar): Likewise.
10022 * mips-fbsd-tdep.c (mips_fbsd_supply_reg): Use raw_supply_integer.
10023 (mips_fbsd_collect_reg): Use raw_collect_integer.
10024 * mips-linux-tdep.c (supply_32bit_reg): Use raw_supply_integer.
10025 (mips64_fill_gregset): Use raw_collect_integer
10026 (mips64_fill_fpregset): Use raw_supply_integer.
10027 * regcache.c (regcache::raw_supply_integer): New function.
10028 (regcache::raw_collect_integer): Likewise.
10029 * regcache.h: (regcache::raw_supply_integer): New declaration.
10030 (regcache::raw_collect_integer): Likewise.
10031
b77b02a5
YQ
100322017-05-24 Yao Qi <yao.qi@linaro.org>
10033
10034 * Makefile.in (SFILES): Add gdbarch-selftests.c.
10035 (COMMON_OBS): Add gdbarch-selftests.o.
10036 * frame.c [GDB_SELF_TESTS] (create_new_frame): New function.
10037 * frame.h [GDB_SELF_TESTS] (create_new_frame): Declare.
10038 * gdbarch-selftests.c: New file.
10039 * regcache.h (regcache) <~regcache>: Mark it virtual if
10040 GDB_SELF_TEST.
10041 <raw_write>: Likewise.
10042
e521e87e
YQ
100432017-05-24 Yao Qi <yao.qi@linaro.org>
10044
10045 * regcache.c (current_regcache): Change it to
10046 regcache::current_regcache.
10047 (regcache_observer_target_changed): Update.
10048 (regcache_thread_ptid_changed): Make it a regcache static
10049 method.
10050 (regcache_thread_ptid_changed): Update.
10051 (class regcache_access): New.
10052 (current_regcache_test): Update.
10053 (_initialize_regcache): Update.
10054 * regcache.h: Include forward_list.
10055 (regcache): Declare regcache_thread_ptid_changed and declare
10056 registers_changed_ptid as friend.
10057
d8e07dda
YQ
100582017-05-24 Yao Qi <yao.qi@linaro.org>
10059
10060 * i387-tdep.c (i387_register_to_value): Use register_size
10061 instead of TYPE_LENGTH.
10062 * m68k-tdep.c (m68k_register_to_value): Likewise.
10063
8c8f9122
YQ
100642017-05-24 Yao Qi <yao.qi@linaro.org>
10065
10066 * i387-tdep.c (i387_convert_register_p): Return false if type
10067 code isn't TYPE_CODE_FLT.
10068
68fce50f
YQ
100692017-05-24 Yao Qi <yao.qi@linaro.org>
10070
10071 * alpha-tdep.c (alpha_convert_register_p): Return true if type
10072 length is 4.
10073 (alpha_register_to_value): Remove type length check.
10074 (alpha_value_to_register): Likewise.
10075
88954b49
YQ
100762017-05-24 Yao Qi <yao.qi@linaro.org>
10077
10078 * ia64-tdep.c (ia64_convert_register_p): Check type's code is
10079 TYPE_CODE_FLT.
10080
e3ec9b69
YQ
100812017-05-24 Yao Qi <yao.qi@linaro.org>
10082
10083 * m68k-tdep.c (m68k_convert_register_p): Check type's code is
10084 TYPE_CODE_FLT or not.
10085
cdd238da
YQ
100862017-05-24 Yao Qi <yao.qi@linaro.org>
10087
10088 * alpha-tdep.c (alpha_gdbarch_init): Use XCNEW instead of XNEW.
10089 * avr-tdep.c (avr_gdbarch_init): Likewise.
10090 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10091 * cris-tdep.c (cris_gdbarch_init): Likewise.
10092 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10093 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10094 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10095 * m68hc11-tdep.c (m68hc11_gdbarch_init): Likewise.
10096 * mep-tdep.c (mep_gdbarch_init): Likewise.
10097 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10098 * mips-tdep.c (mips_gdbarch_init): Likewise.
10099 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10100 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10101 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10102 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10103 * v850-tdep.c (v850_gdbarch_init): Likewise.
10104
7a3929c4
YQ
101052017-05-24 Yao Qi <yao.qi@linaro.org>
10106
10107 * selftest-arch.c (tests_with_arch): Call registers_changed
10108 and reinit_frame_cache.
10109 * selftest.c (run_self_tests): Likewise.
10110
f4985dba
YQ
101112017-05-24 Yao Qi <yao.qi@linaro.org>
10112
10113 * rs6000-tdep.c (gdb_print_insn_powerpc): Remove.
10114 (rs6000_gdbarch_init): Don't call set_gdbarch_print_insn.
10115
ab20fa4a
YQ
101162017-05-24 Yao Qi <yao.qi@linaro.org>
10117
10118 * rl78-tdep.c (rl78_gdbarch_init): Don't call
10119 set_gdbarch_print_insn.
10120
f532ab94
YQ
101212017-05-24 Yao Qi <yao.qi@linaro.org>
10122
10123 * h8300-tdep.c (h8300_gdbarch_init): Don't call
10124 set_gdbarch_print_insn.
10125
39503f82
YQ
101262017-05-24 Yao Qi <yao.qi@linaro.org>
10127
10128 * alpha-tdep.c (alpha_gdbarch_init): Don't call
10129 set_gdbarch_print_insn.
10130 * arc-tdep.c (arc_gdbarch_init): Likewise.
10131 * arch-utils.c: include dis-asm.h.
10132 (default_print_insn): New function.
10133 * arch-utils.h (default_print_insn): Declare.
10134 * avr-tdep.c (avr_gdbarch_init): Don't call set_gdbarch_print_insn.
10135 * bfin-tdep.c (bfin_gdbarch_init): Likewise.
10136 * cris-tdep.c (cris_delayed_get_disassembler): Remove.
10137 (cris_gdbarch_init): Don't call set_gdbarch_print_insn.
10138 * frv-tdep.c (frv_gdbarch_init): Likewise.
10139 * ft32-tdep.c (ft32_gdbarch_init): Likewise.
10140 * gdbarch.sh (print_insn): Use default_print_insn.
10141 * gdbarch.c: Regenerated.
10142 * hppa-tdep.c (hppa_gdbarch_init): Likewise.
10143 * iq2000-tdep.c (iq2000_gdbarch_init): Likewise.
10144 * lm32-tdep.c (lm32_gdbarch_init): Likewise.
10145 * m32c-tdep.c (m32c_gdbarch_init): Likewise.
10146 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
10147 * m68hc11-tdep.c (gdb_print_insn_m68hc11): Remove.
10148 (m68hc11_gdbarch_init): Don't call set_gdbarch_print_insn.
10149 * m68k-tdep.c (m68k_gdbarch_init): Likewise.
10150 * m88k-tdep.c (m88k_gdbarch_init): Likewise.
10151 * microblaze-tdep.c (microblaze_gdbarch_init): Likewise.
10152 * mn10300-tdep.c (mn10300_gdbarch_init): Likewise.
10153 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
10154 * msp430-tdep.c (msp430_gdbarch_init): Likewise.
10155 * mt-tdep.c (mt_gdbarch_init): Likewise.
10156 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
10157 * nios2-tdep.c (nios2_print_insn): Remove.
10158 (nios2_gdbarch_init): Don't call set_gdbarch_print_insn.
10159 * rx-tdep.c (rx_gdbarch_init): Likewise.
10160 * s390-linux-tdep.c (s390_gdbarch_init): Likewise.
10161 * score-tdep.c (score_print_insn): Remove.
10162 (score_gdbarch_init): Don't call set_gdbarch_print_insn.
10163 * sh-tdep.c (sh_gdbarch_init): Likewise.
10164 * sh64-tdep.c (sh64_gdbarch_init): Likewise.
10165 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
10166 * tic6x-tdep.c (tic6x_print_insn): Remove.
10167 (tic6x_gdbarch_init): Don't call set_gdbarch_print_insn.
10168 * tilegx-tdep.c (tilegx_gdbarch_init): Likewise.
10169 * v850-tdep.c (v850_gdbarch_init): Likewise.
10170 * vax-tdep.c (vax_gdbarch_init): Likewise.
10171 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
10172 * xtensa-tdep.c (xtensa_gdbarch_init): Likewise.
10173
f7241d4f
JB
101742017-05-23 John Baldwin <jhb@FreeBSD.org>
10175
10176 * mips-fbsd-tdep.c (MIPS_PC_REGNUM): Remove.
10177 (MIPS_FP0_REGNUM): Remove.
10178 (MIPS_FSR_REGNUM): Remove.
10179 (mips_fbsd_supply_fpregs): Use mips_regnum.
10180 (mips_fbsd_supply_gregs): Likewise.
10181 (mips_fbsd_collect_fpregs): Likewise.
10182 (mips_fbsd_collect_gregs): Likewise.
10183
d489d81d
JB
101842017-05-23 John Baldwin <jhb@FreeBSD.org>
10185
10186 * mips-fbsd-nat.c (getregs_supplies): Fix upper bound comparison.
10187 (getpfpregs_supplies): New function.
10188 (mips_fbsd_fetch_inferior_registers): Remove early exit and use
10189 getfpregs_supplies.
10190 (mips_fbsd_store_inferior_registers): Likewise.
10191
e11b3cdc
PA
101922017-05-22 Pedro Alves <palves@redhat.com>
10193
10194 * MAINTAINERS (Host/Native): Add John Baldwin as FreeBSD
10195 maintainer.
10196
0f068fb5
AH
101972017-05-22 Alan Hayward <alan.hayward@arm.com>
10198
10199 * ppc-linux-nat.c (fetch_register): Use PPC_MAX_REGISTER_SIZE.
10200 (store_register): Likewise.
10201 * ppc-sysv-tdep.c (ppc_sysv_abi_push_dummy_call): Likewise.
10202 (get_decimal_float_return_value): Likewise.
10203 (do_ppc_sysv_return_value): Likewise.
10204 (ppc64_sysv_abi_push_integer): Likewise.
10205 (ppc64_sysv_abi_push_freg): Likewise.
10206 (ppc64_sysv_abi_return_value_base): Likewise.
10207 (ppc64_sysv_abi_return_value): Likewise.
10208 * rs6000-aix-tdep.c (rs6000_push_dummy_call): Likewise.
10209 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Likewise.
10210 * rs6000-nat.c: Likewise.
10211 * rs6000-tdep.c (rs6000_register_to_value): Likewise.
10212 (rs6000_value_to_register): Likewise.
10213 * ppc-tdep.h (PPC_MAX_REGISTER_SIZE): Add.
10214
e6cf65f2
TT
102152017-05-21 Tom Tromey <tom@tromey.com>
10216
10217 PR rust/21466:
10218 * rust-lang.c (rust_print_type) <TYPE_CODE_ARRAY>: Print unsized
10219 arrays as "[T]", not "[T; ]".
10220
43cc5389
TT
102212017-05-19 Tom Tromey <tom@tromey.com>
10222
10223 PR rust/21484:
10224 * rust-lang.c (exp_descriptor_rust): New function.
10225 (rust_language_defn): Use it.
10226 * p-lang.c (pascal_language_defn): Update.
10227 * opencl-lang.c (opencl_language_defn): Update.
10228 * objc-lang.c (objc_language_defn): Update.
10229 * m2-lang.c (m2_language_defn): Update.
10230 * language.h (struct language_defn)
10231 <la_watch_location_expression>: New member.
10232 * language.c (unknown_language_defn, auto_language_defn)
10233 (local_language_defn): Update.
10234 * go-lang.c (go_language_defn): Update.
10235 * f-lang.c (f_language_defn): Update.
10236 * d-lang.c (d_language_defn): Update.
10237 * c-lang.h (c_watch_location_expression): Declare.
10238 * c-lang.c (c_watch_location_expression): New function.
10239 (c_language_defn, cplus_language_defn, asm_language_defn)
10240 (minimal_language_defn): Use it.
10241 * breakpoint.c (watch_command_1): Call
10242 la_watch_location_expression.
10243 * ada-lang.c (ada_language_defn): Update.
10244
7a6e7fcc
RO
102452017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10246
6e7e1744
RO
10247 PR tui/21482
10248 * gdb_curses.h (NOMACROS): Define.
10249 (NCURSES_NOMACROS): Define.
10250
102512017-05-19 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10252
10253 PR tui/21482
7a6e7fcc
RO
10254 * tui/tui-windata.c (tui_erase_data_content): Cast last mvwaddstr
10255 arg to char *.
10256 * tui/tui-wingeneral.c (box_win): Likewise.
10257 * tui/tui-winsource.c (tui_erase_source_content): Likewise.
10258 (tui_show_source_line): Likewise.
10259 (tui_show_exec_info_content): Likewise.
10260
1933fd8e
VM
102612017-05-19 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
10262
10263 * sparc-tdep.c (sparc_structure_return_p)
10264 (sparc_arg_on_registers_p): New functions.
10265 (sparc32_store_arguments): Use them.
10266 * sparc64-tdep.c (sparc64_16_byte_align_p)
10267 (sparc64_store_floating_fields, sparc64_extract_floating_fields):
10268 Handle TYPE_CODE_ARRAY.
10269
21873064
YQ
102702017-05-17 Yao Qi <yao.qi@linaro.org>
10271
10272 * cli/cli-decode.c (add_alias_cmd): New function.
10273 * command.h (add_alias_cmd): Declare.
10274 * infcmd.c (_initialize_infcmd): Don't call add_com_alias,
10275 instead call add_alias_cmd.
10276
2b351b19
PA
102772017-05-17 Pedro Alves <palves@redhat.com>
10278
10279 * Makefile.in (nat_extra_makefile_frag): Rename to ...
10280 (nat_makefile_frag): ... this. All references updated.
10281 * configure.ac: Likewise.
10282 * configure.nat: Likewise. Enhance comments.
10283 * configure: Regenerate.
10284
5f2ad7a3
RO
102852017-05-15 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10286
10287 * procfs.c (procfs_create_inferior): Change prototype to match
10288 definition.
10289
adf3dde5
EZ
102902017-05-13 Eli Zaretskii <eliz@gnu.org>
10291
10292 * tui/tui.c (tui_enable): Cast "unknown" to 'char *' to avoid a
10293 C++ compiler warning.
10294
6830f270
TT
102952017-05-12 Tom Tromey <tom@tromey.com>
10296
10297 PR rust/21483:
10298 * rust-lang.c (rust_evaluate_subexp) <STRUCTOP_STRUCT>: Don't
10299 recurse, just call value_struct_elt directly.
10300
68f2f2e3
TT
103012017-05-12 Tom Tromey <tom@tromey.com>
10302
10303 * rust-lang.c (rust_dump_subexp_body) <STRUCTOP_ANONYMOUS,
10304 OP_RUST_ARRAY>: Fix.
10305
256afbc2
TT
103062017-05-12 Tom Tromey <tom@tromey.com>
10307
10308 * rust-lang.c (rust_print_subexp): Replace "return" with "break".
10309
94bb8dfe
YQ
103102017-05-09 Yao Qi <yao.qi@linaro.org>
10311
10312 * regcache.c: Include <forward_list>.
10313 (struct regcache_list): Remove.
10314 (current_regcache): Update.
10315 (get_thread_arch_aspace_regcache): Update for std::forward_list.
10316 (regcache_thread_ptid_changed): Likewise.
10317 (registers_changed_ptid): Likewise.
10318 (current_regcache_size): Likewise.
10319
8248946c
YQ
103202017-05-09 Yao Qi <yao.qi@linaro.org>
10321
10322 * regcache.c [GDB_SELF_TEST]: Include selftest.h.
10323 (current_regcache_size): New function.
10324 (current_regcache_test): New function.
10325 (_initialize_regcache) [GDB_SELF_TEST]: Register the unit test.
10326
313c5961
AH
103272017-05-08 Alan Hayward <alan.hayward@arm.com>
10328
10329 * mips-tdep.c (mips_o32_return_value): Remove unused buffer.
10330 (print_gp_register_row): Use get_frame_register_value.
10331
27bfc1d1
AH
103322017-05-08 Alan Hayward <alan.hayward@arm.com>
10333
10334 * mips-linux-tdep.c (mips_supply_gregset): Use raw_supply_zeroed.
10335 (mips_supply_fpregset): Likewise.
10336 (mips64_supply_gregset): Likewise.
10337
146e6c5c
AH
103382017-05-08 Alan Hayward <alan.hayward@arm.com>
10339
10340 * mn10300-linux-tdep.c (am33_supply_gregset_method): Use
10341 regcache->raw_supply_zeroed.
10342
e50f25ec
SDJ
103432017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10344
10345 * configure.nat: Rearrange 'case' statements to match
10346 host before cpu.
10347
21ea5acd
SDJ
103482017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
10349
10350 * Makefile.in: Remove "@host_makefile_frag@". Add variables
10351 NAT_FILE, NATDEPFILES, NAT_CDEPS, LOADLIBES, MH_CFLAGS, XM_CLIBS,
10352 NAT_GENERATED_FILES, HAVE_NATIVE_GCORE_HOST. Add
10353 "@nat_extra_makefile_frag@".
10354 (Makefile): Remove dependency on "@frags@".
10355 ($(GNULIB_BUILDDIR)/Makefile): Likewise.
10356 (data-directory/Makefile): Likewise.
10357 * config/aarch64/linux.mh: Deleted; moved contents to
10358 "gdb/configure.nat".
10359 * config/alpha/alpha-linux.mh: Likewise.
10360 * config/alpha/nbsd.mh: Likewise.
10361 * config/arm/linux.mh: Likewise.
10362 * config/arm/nbsdelf.mh: Likewise.
10363 * config/i386/cygwin.mh: Likewise.
10364 * config/i386/cygwin64.mh: Likewise.
10365 * config/i386/darwin.mh: Likewise.
10366 * config/i386/fbsd.mh: Likewise.
10367 * config/i386/fbsd64.mh: Likewise.
10368 * config/i386/go32.mh: Likewise.
10369 * config/i386/i386gnu.mh: Likewise.
10370 * config/i386/i386sol2.mh: Likewise.
10371 * config/i386/linux.mh: Likewise.
10372 * config/i386/linux64.mh: Likewise.
10373 * config/i386/mingw.mh: Likewise.
10374 * config/i386/mingw64.mh: Likewise.
10375 * config/i386/nbsd64.mh: Likewise.
10376 * config/i386/nbsdelf.mh: Likewise.
10377 * config/i386/nto.mh: Likewise.
10378 * config/i386/obsd.mh: Likewise.
10379 * config/i386/obsd64.mh: Likewise.
10380 * config/i386/sol2-64.mh: Likewise.
10381 * config/ia64/linux.mh: Likewise.
10382 * config/m32r/linux.mh: Likewise.
10383 * config/m68k/linux.mh: Likewise.
10384 * config/m68k/nbsdelf.mh: Likewise.
10385 * config/m68k/obsd.mh: Likewise.
10386 * config/m88k/obsd.mh: Likewise.
10387 * config/mips/fbsd.mh: Likewise.
10388 * config/mips/linux.mh: Likewise.
10389 * config/mips/nbsd.mh: Likewise.
10390 * config/mips/obsd64.mh: Likewise.
10391 * config/pa/linux.mh: Likewise.
10392 * config/pa/nbsd.mh: Likewise.
10393 * config/pa/obsd.mh: Likewise.
10394 * config/powerpc/aix.mh: Likewise.
10395 * config/powerpc/fbsd.mh: Likewise.
10396 * config/powerpc/linux.mh: Likewise.
10397 * config/powerpc/nbsd.mh: Likewise.
10398 * config/powerpc/obsd.mh: Likewise.
10399 * config/powerpc/ppc64-linux.mh: Likewise.
10400 * config/powerpc/spu-linux.mh: Likewise.
10401 * config/s390/linux.mh: Likewise.
10402 * config/sh/nbsd.mh: Likewise.
10403 * config/sparc/fbsd.mh: Likewise.
10404 * config/sparc/linux.mh: Likewise.
10405 * config/sparc/linux64.mh: Likewise.
10406 * config/sparc/nbsd64.mh: Likewise.
10407 * config/sparc/nbsdelf.mh: Likewise.
10408 * config/sparc/obsd64.mh: Likewise.
10409 * config/sparc/sol2.mh: Likewise.
10410 * config/tilegx/linux.mh: Likewise.
10411 * config/vax/nbsdelf.mh: Likewise.
10412 * config/vax/obsd.mh: Likewise.
10413 * config/xtensa/linux.mh: Likewise.
10414 * config/i386/i386gnu.mn: New file, with excerpts from
10415 "config/i386/i386gnu.mh".
10416 * configure: Regenerate.
10417 * configure.ac: Rewrite code to use "gdb/configure.nat" instead of
10418 *.mh files under "gdb/config".
10419 * configure.nat: New file, with contents from the
10420 "gdb/config/*/*.mh" files.
10421
7ed1acaf
TW
104222017-05-05 Tim Wiederhake <tim.wiederhake@intel.com>
10423
10424 * btrace.c (btrace_clear): Free insn vector.
10425
e13cb306
PA
104262017-05-05 Pedro Alves <palves@redhat.com>
10427
10428 * warning.m4 (build_warnings): Add -Wno-error=maybe-uninitialized.
10429 * configure: Regenerate.
10430
5ed8105e
PA
104312017-05-04 Pedro Alves <palves@redhat.com>
10432
10433 * Makefile.in (SFILES): Add progspace-and-thread.c.
10434 (HFILES_NO_SRCDIR): Add progspace-and-thread.h.
10435 (COMMON_OBS): Add progspace-and-thread.o.
10436 * breakpoint.c: Include "progspace-and-thread.h".
10437 (update_inserted_breakpoint_locations)
10438 (insert_breakpoint_locations, create_longjmp_master_breakpoint):
10439 Use scoped_restore_current_pspace_and_thread.
10440 (create_std_terminate_master_breakpoint): Use
10441 scoped_restore_current_program_space.
10442 (remove_breakpoint): Use scoped_restore_current_pspace_and_thread.
10443 (print_breakpoint_location): Use
10444 scoped_restore_current_program_space.
10445 (bp_loc_is_permanent): Use
10446 scoped_restore_current_pspace_and_thread.
10447 (resolve_sal_pc): Use scoped_restore_current_pspace_and_thread.
10448 (download_tracepoint_locations): Use
10449 scoped_restore_current_pspace_and_thread.
10450 (breakpoint_re_set): Use scoped_restore_current_pspace_and_thread.
10451 * exec.c (exec_close_1): Use scoped_restore_current_program_space.
10452 (enum step_over_calls_kind): Moved from inferior.h.
10453 (class scoped_restore_current_thread): New class.
10454 * gdbthread.h (make_cleanup_restore_current_thread): Delete
10455 declaration.
10456 (scoped_restore_current_thread): New class.
10457 * infcmd.c: Include "common/gdb_optional.h".
10458 (continue_1, proceed_after_attach): Use
10459 scoped_restore_current_thread.
10460 (notice_new_inferior): Use scoped_restore_current_thread.
10461 * inferior.c: Include "progspace-and-thread.h".
10462 (restore_inferior, save_current_inferior): Delete.
10463 (add_inferior_command, clone_inferior_command): Use
10464 scoped_restore_current_pspace_and_thread.
10465 * inferior.h (scoped_restore_current_inferior): New class.
10466 * infrun.c: Include "progspace-and-thread.h" and
10467 "common/gdb_optional.h".
10468 (follow_fork_inferior): Use
10469 scoped_restore_current_pspace_and_thread.
10470 (scoped_restore_exited_inferior): New class.
10471 (handle_vfork_child_exec_or_exit): Use
10472 scoped_restore_exited_inferior,
10473 scoped_restore_current_pspace_and_thread,
10474 scoped_restore_current_thread and scoped_restore.
10475 (fetch_inferior_event): Use scoped_restore_current_thread.
10476 * linespec.c (decode_line_full, decode_line_1): Use
10477 scoped_restore_current_program_space.
10478 * mi/mi-main.c: Include "progspace-and-thread.h".
10479 (exec_continue): Use scoped_restore_current_thread.
10480 (mi_cmd_exec_run): Use scoped_restore_current_pspace_and_thread.
10481 (mi_cmd_trace_frame_collected): Use scoped_restore_current_thread.
10482 * proc-service.c (ps_pglobal_lookup): Use
10483 scoped_restore_current_program_space.
10484 * progspace-and-thread.c: New file.
10485 * progspace-and-thread.h: New file.
10486 * progspace.c (release_program_space, clone_program_space): Use
10487 scoped_restore_current_program_space.
10488 (restore_program_space, save_current_program_space)
10489 (save_current_space_and_thread): Delete.
10490 (switch_to_program_space_and_thread): Moved to
10491 progspace-and-thread.c.
10492 * progspace.h (save_current_program_space)
10493 (save_current_space_and_thread): Delete declarations.
10494 (scoped_restore_current_program_space): New class.
10495 * remote.c (remote_btrace_maybe_reopen): Use
10496 scoped_restore_current_thread.
10497 * symtab.c: Include "progspace-and-thread.h".
10498 (skip_prologue_sal): Use scoped_restore_current_pspace_and_thread.
10499 * thread.c (print_thread_info_1): Use
10500 scoped_restore_current_thread.
10501 (struct current_thread_cleanup): Delete.
10502 (do_restore_current_thread_cleanup)
10503 (restore_current_thread_cleanup_dtor): Rename/convert both to ...
10504 (scoped_restore_current_thread::~scoped_restore_current_thread):
10505 ... this new dtor.
10506 (make_cleanup_restore_current_thread): Rename/convert to ...
10507 (scoped_restore_current_thread::scoped_restore_current_thread):
10508 ... this new ctor.
10509 (thread_apply_all_command): Use scoped_restore_current_thread.
10510 (thread_apply_command): Use scoped_restore_current_thread.
10511 * tracepoint.c (tdump_command): Use scoped_restore_current_thread.
10512 * varobj.c (value_of_root_1): Use scoped_restore_current_thread.
10513
f6223dbb
PA
105142017-05-04 Pedro Alves <palves@redhat.com>
10515
10516 * thread.c (make_cleanup_restore_current_thread): Move
10517 find_thread_ptid call before the is_stopped call. Assert that the
10518 thread is found. Replace is_stopped call by checking the thread's
10519 state directly. Remove unnecessary NULL-thread check.
10520
3c3ae77e
PA
105212017-05-04 Pedro Alves <palves@redhat.com>
10522
10523 * corelow.c (thread_section_name): New class.
10524 (get_core_register_section, get_core_siginfo): Use it.
10525
45eba0ab
AA
105262017-05-04 Andreas Arnez <arnez@linux.vnet.ibm.com>
10527
10528 * corelow.c (sniff_core_bfd): Remove extra semicolon.
10529 (get_core_register_section): Remove xfree of NULL pointer.
10530
f81fdd35
AH
105312017-05-03 Alan Hayward <alan.hayward@arm.com>
10532
10533 * frv-linux-tdep.c (frv_linux_supply_gregset): Use raw_supply_zeroed.
10534 * regcache.c (regcache::raw_supply_zeroed): New function.
10535 * regcache.h (regcache::raw_supply_zeroed): New declaration.
10536
35837774
SM
105372017-05-03 Simon Marchi <simon.marchi@ericsson.com>
10538
10539 * gdbarch.sh: Remove commented out definition of
10540 TARGET_CHAR_BIT.
10541 * gdbarch.h: Re-generate.
10542
c94fee56
SDJ
105432017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
10544
10545 * configure: Regenerate.
10546
d17f7b36
SM
105472017-05-02 Simon Marchi <simon.marchi@ericsson.com>
10548
10549 * solib-target.c (solib_target_relocate_section_addresses):
10550 Remove num_section_bases, num_bases, segment_bases variables.
10551
b560ebd6
SM
105522017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10553
10554 * common/gdb_vecs.h (DEF_VEC_I (CORE_ADDR)): Remove.
10555
f2f46dfc
SM
105562017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10557
10558 * solib-target.c: Include <vector>
10559 (struct lm_info_target) <~lm_info_target>: Remove.
10560 <segment_bases, section_bases>: Change type to
10561 std::vector<CORE_ADDR>.
10562 (library_list_start_segment, library_list_start_section,
10563 library_list_end_library,
10564 solib_target_relocate_section_addresses): Adjust.
10565
a0ff9e1a
SM
105662017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10567
10568 * gdbarch.sh (software_single_step): Change return type to
10569 std::vector<CORE_ADDR>.
10570 * gdbarch.c, gdbarch.h: Re-generate.
10571 * arch/arm-get-next-pcs.c (thumb_deal_with_atomic_sequence_raw):
10572 Adjust.
10573 (arm_deal_with_atomic_sequence_raw): Adjust.
10574 (thumb_get_next_pcs_raw): Adjust.
10575 (arm_get_next_pcs_raw): Adjust.
10576 (arm_get_next_pcs): Adjust.
10577 * arch/arm-get-next-pcs.h (arm_get_next_pcs): Adjust.
10578 * aarch64-tdep.c (aarch64_software_single_step): Adjust.
10579 * alpha-tdep.c (alpha_deal_with_atomic_sequence): Adjust.
10580 (alpha_software_single_step): Adjust.
10581 * alpha-tdep.h (alpha_software_single_step): Adjust.
10582 * arm-linux-tdep.c (arm_linux_software_single_step): Adjust.
10583 * arm-tdep.c (arm_software_single_step): Adjust.
10584 (arm_breakpoint_kind_from_current_state): Adjust.
10585 * arm-tdep.h (arm_software_single_step): Adjust.
10586 * breakpoint.c (insert_single_step_breakpoint): Adjust.
10587 * cris-tdep.c (cris_software_single_step): Adjust.
10588 * mips-tdep.c (mips_deal_with_atomic_sequence): Adjust.
10589 (micromips_deal_with_atomic_sequence): Adjust.
10590 (deal_with_atomic_sequence): Adjust.
10591 (mips_software_single_step): Adjust.
10592 * mips-tdep.h (mips_software_single_step): Adjust.
10593 * moxie-tdep.c (moxie_software_single_step): Adjust.
10594 * nios2-tdep.c (nios2_software_single_step): Adjust.
10595 * ppc-tdep.h (ppc_deal_with_atomic_sequence): Adjust.
10596 * rs6000-aix-tdep.c (rs6000_software_single_step): Adjust.
10597 * rs6000-tdep.c (ppc_deal_with_atomic_sequence): Adjust.
10598 * s390-linux-tdep.c (s390_software_single_step): Adjust.
10599 * sparc-tdep.c (sparc_software_single_step): Adjust.
10600 * spu-tdep.c (spu_software_single_step): Adjust.
10601 * tic6x-tdep.c (tic6x_software_single_step): Adjust.
10602
ea480a30
SM
106032017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
10604
10605 * gdbarch.sh: Use semi-colon as field separator instead of colon.
10606 * gdbarch.h: Re-generate.
10607
d050f7d7
TW
106082017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10609
10610 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-instruction.o.
10611 (SUBDIR_PYTHON_SRCS): Add py-instruction.c.
10612 * python/py-instruction.c, python/py-instruction.h: New file.
10613 * python/py-record.c: Add py-instruction.h include.
10614 (gdbpy_initialize_record): Make gdb.Instruction a super class of
10615 gdb.RecordInstruction.
10616 * python/python-internal.h: Add gdbpy_initialize_instruction
10617 declaration.
10618 * python/python.c (do_start_initialization): Add
10619 gdbpy_initialize_instruction.
10620
14f819c8
TW
106212017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10622
10623 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_CALL, btpy_call_type):
10624 Remove.
10625 (btrace_func_from_recpy_func): New function.
10626 (btpy_call_new, btpy_number, btpy_hash, btpy_richcompare): Remove.
10627 (btpy_call_level, btpy_call_symbol, btpy_call_instructions,
10628 btpy_call_up, btpy_call_prev_sibling, btpy_call_next_sibling): Rename to ...
10629 (recpy_bt_func_level, recpy_bt_func_symbol, recpy_bt_func_instructions,
10630 recpy_bt_func_up, recpy_bt_func_prev, recpy_bt_func_next): This.
10631 Also, use new helper functions.
10632 (btpy_list_item): Use new helper functions.
10633 (recpy_bt_function_call_history): Use new type name.
10634 (btpy_call_getset): Remove.
10635 (gdbpy_initialize_btrace): Remove code to initialize
10636 gdb.BtraceFunctionCall.
10637 * python/py-record-btrace.h (recpy_bt_func_number, recpy_btb_func_level,
10638 recpy_btb_func_symbol, recpy_bt_func_instructions, recpy_bt_func_up,
10639 recpy_bt_func_prev, recpy_bt_func_next): New export.
10640 * python/py-record.c (recpy_func_type): New static object.
10641 (recpy_func_new, recpy_func_level, recpy_func_symbol,
10642 recpy_func_instructions, recpy_func_up, recpy_func_prev,
10643 recpy_func_next): New function.
10644 (recpy_element_hash, recpy_element_richcompare): Updated comment.
10645 (recpy_func_getset): New static object.
10646 (gdbpy_initialize_record): Add code to initialize gdb.RecordInstruction.
10647 * python/py-record.h (recpy_func_type, recpy_func_new): New export.
10648
0ed5da75
TW
106492017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10650
10651 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN): Remove.
10652 (btpy_object, btpy_insn_type, btpy_new): Remove.
10653 (btpy_list_object): Use gdb.RecordInstruction type instead of
10654 gdb.BtraceInstruction type.
10655 (btrace_insn_from_recpy_insn): New function.
10656 (btpy_insn_or_gap_new): Adjust comment. Use recpy_insn_new instead of
10657 btpy_new.
10658 (btpy_call_new, btpy_list_item): Do not use btpy_new anymore.
10659 (btpy_number, btpy_hash, btpy_call_level, btpy_call_symbol,
10660 btpy_call_instructions, btpy_call_up, btpy_call_prev_sibling,
10661 btpy_call_next_sibling, btpy_richcompare): Use recpy_element_object
10662 instead of btpy_object.
10663 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10664 btpy_insn_data, btpy_insn_decode): Rename to ...
10665 (recpy_bt_insn_sal, recpy_bt_insn_pc, recpy_bt_insn_size,
10666 recpy_bt_insn_is_speculative, recpy_bt_insn_data,
10667 recpy_bt_insn_decode): This. Also, use new helper functions.
10668 (btpy_list_position, recpy_bt_goto): Use recpy_element_object and
10669 recpy_insn_type.
10670 (btpy_insn_getset): Remove.
10671 (gdbpy_initialize_btrace): Remove code to initialize
10672 gdb.BtraceInstruction. Use recpy_element_object.
10673 * python/py-record-btrace.h (recpy_bt_insn_number, recpy_bt_insn_sal,
10674 recpy_bt_insn_pc, recpy_bt_insn_data, recpy_bt_insn_decoded,
10675 recpy_bt_insn_size, recpy_bt_insn_is_speculative): New export.
10676 * python/py-record.c (recpy_insn_type): New static object.
10677 (recpy_insn_new, recpy_insn_sal, recpy_insn_pc, recpy_insn_data,
10678 recpy_insn_decoded, recpy_insn_size, recpy_insn_is_speculative,
10679 recpy_element_number, recpy_element_hash, recpy_element_richcompare):
10680 New function.
10681 (recpy_insn_getset): New static object.
10682 (gdbpy_initialize_record): Initialize gdb.RecordInstruction.
10683 * python/py-record.h (recpy_element_object): New typedef.
10684 (recpy_insn_type, recpy_insn_new): New export.
10685
913aeadd
TW
106862017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10687
10688 * py-record-btrace.c (btpy_insn_new): Removed.
10689 (btpy_insn_or_gap_new): New function.
10690 (btpy_insn_error): Removed.
10691 (btpy_insn_sal, btpy_insn_pc, btpy_insn_size, btpy_insn_is_speculative,
10692 btpy_insn_data, btpy_insn_decode): Remove code path for gaps.
10693 (recpy_bt_replay_position, recpy_bt_begin, recpy_bt_end): Call
10694 btpy_insn_or_gap_new instead of btpy_insn_new.
10695 (btpy_insn_getset): Remove btpy_insn_error.
10696 * py-record.c (recpy_gap_type): New static object.
10697 (recpy_gap_object): New typedef.
10698 (recpy_gap_new, recpy_gap_number, recpy_gap_reason_code,
10699 recpy_gap_reason_string): New function.
10700 (recpy_gap_getset): New static object.
10701 (gdbpy_initialize_record): Initialize gdb.RecordGap type.
10702 * py-record.h (recpy_gap_new): New export.
10703
a3be24ad
TW
107042017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10705
10706 * python/py-record.c (recpy_ptid): Remove.
10707 (recpy_record_getset): Remove recpy_ptid.
10708
ae20e79a
TW
107092017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10710
10711 * btrace.c (btrace_fetch): Set inferior_ptid.
10712 * python/py-record-btrace.c: Add "py-record.h" include.
10713 (recpy_bt_format, recpy_bt_replay_position, recpy_bt_begin,
10714 recpy_bt_end, recpy_bt_instruction_history,
10715 recpy_bt_function_call_history, recpy_bt_goto): Use ptid stored
10716 in gdb.Record object instead of current ptid.
10717 * python/py-record.c: Include new "py-record.h" file.
10718 (recpy_record_object): Moved to py-record.h.
10719 * python/py-record.h: New file.
10720
8d0050ea
TW
107212017-05-01 Tim Wiederhake <tim.wiederhake@intel.com>
10722
10723 * python/py-record-btrace.c (BTPY_REQUIRE_VALID_INSN,
10724 BTPY_REQUIRE_VALID_CALL, recpy_bt_function_call_history): Fix
10725 indentation.
10726
3f380b50
JB
107272017-05-01 Joel Brobecker <brobecker@adacore.com>
10728
10729 * MAINTAINERS: Move Daniel Jacobowitz and Mark Kettenis to
10730 the past maintainers section.
10731
07495424
YQ
107322017-04-28 Yao Qi <yao.qi@linaro.org>
10733
10734 * infcmd.c (get_return_value): Use regcache ctor, and remove
10735 cleanup.
10736
deb1fa3e
YQ
107372017-04-28 Yao Qi <yao.qi@linaro.org>
10738 Pedro Alves <palves@redhat.com>
10739
10740 * regcache.c (regcache::regcache): New tag dispatch ctor.
10741 (do_cooked_read): Moved above.
10742 (regcache_dup): Use the tag dispatch ctor..
10743 * regcache.h (regcache): Declare ctor, delete copy ctor and
10744 assignment operator, remove friend regcache_dup.
10745
b421c83c
YQ
107462017-04-28 Yao Qi <yao.qi@linaro.org>
10747
10748 * regcache.c (regcache_dup): Assert !src->m_readonly_p and
10749 call method save instead of regcache_cpy.
10750 * regcache.h (struct regcache): Make regcache_dup a friend.
10751
ef79d9a3
YQ
107522017-04-28 Yao Qi <yao.qi@linaro.org>
10753
10754 * regcache.c (struct regcache): Move to regcache.h
10755 (regcache::arch): New method.
10756 (regcache_get_ptid): Update.
10757 (get_regcache_arch): Call arch method.
10758 (get_regcache_aspace): Call method aspace.
10759 (register_buffer): Change it to method.
10760 (regcache_save): Change it to regcache::save.
10761 (regcache_restore): Likewise.
10762 (regcache_cpy_no_passthrough): Remove the declaration.
10763 (regcache_cpy): Call methods restore and cpy_no_passthrough.
10764 (regcache_cpy_no_passthrough): Change it to method
10765 cpy_no_passthrough.
10766 (regcache_register_status): Change it to method
10767 get_register_status.
10768 (regcache_invalidate): Change it to method invalidate.
10769 (regcache_thread_ptid_changed): Use methods ptid and set_ptid.
10770 (regcache_raw_update): Change it to method raw_update.
10771 (regcache_raw_read): Likewise.
10772 (regcache_raw_read_signed): Likewise.
10773 (regcache_raw_read_unsigned): Likewise.
10774 (regcache_raw_write_signed): Likewise.
10775 (regcache_raw_write_unsigned): Likewise.
10776 (regcache_cooked_read): Likewise.
10777 (regcache_cooked_read_value): Likewise.
10778 (regcache_cooked_read_signed): Likewise.
10779 (regcache_cooked_read_unsigned): Likewise.
10780 (regcache_cooked_write_signed): Likewise.
10781 (regcache_cooked_write_unsigned): Likewise.
10782 (regcache_raw_set_cached_value): Likewise.
10783 (regcache_raw_write): Likewise.
10784 (regcache_cooked_write): Likewise.
10785 (regcache_xfer_part): Likewise.
10786 (regcache_raw_read_part): Likewise.
10787 (regcache_raw_write_part): Likewise.
10788 (regcache_cooked_read_part): Likewise.
10789 (regcache_cooked_write_part): Likewise.
10790 (regcache_raw_supply): Likewise.
10791 (regcache_raw_collect): Likewise.
10792 (regcache_transfer_regset): Likewise.
10793 (regcache_supply_regset): Likewise.
10794 (regcache_collect_regset): Likewise.
10795 (regcache_debug_print_register): Likewise.
10796 (enum regcache_dump_what): Move it to regcache.h.
10797 (regcache_dump): Change it to method dump.
10798 * regcache.h (enum regcache_dump_what): New.
10799 (class regcache): New.
10800 * target.c (target_fetch_registers): Call method
10801 debug_print_register.
10802 (target_store_registers): Likewise.
10803
f8fdb78e
SM
108042017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10805
10806 * windows-nat.c (struct lm_info_windows): Initialize field.
10807 (windows_make_so): Allocate lm_info_windows with new.
10808 (windows_free_so): Free lm_info_windows with delete.
10809
9ccbfd7b
SM
108102017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10811
10812 * solib-darwin.c (struct lm_info_darwin): Initialize field.
10813 (darwin_current_sos): Allocate lm_info_darwin with new, remove
10814 cleanup.
10815 (darwin_free_so): Free lm_info_darwin with delete.
10816
76e75227
SM
108172017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10818
10819 * solib-svr4.h (struct lm_info_svr4): Initialize fields.
10820 <l_addr_p>: Change type to bool.
10821 * solib-svr4.c (lm_info_read): Allocate lm_info_svr4 with new.
10822 (svr4_free_so): Free lm_info_svr4 with delete.
10823 (svr4_copy_library_list): Replace memcpy with call to copy
10824 constructor.
10825 (library_list_start_library, svr4_default_sos): Allocate
10826 lm_info_svr4 with new.
10827
51046d9e
SM
108282017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10829
10830 * solib-target.c (struct lm_info_target): Add destructor,
10831 initialize fields.
10832 <name>: Change type to std::string.
10833 (library_list_start_library): Allocate lm_info_target with new.
10834 (solib_target_free_library_list): Free lm_info_target with
10835 delete.
10836 (solib_target_current_sos): Adapt to std::string.
10837 (solib_target_free_so): Free lm_info_target with delete.
10838
4023ae76
SM
108392017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10840
10841 * solib-frv.c (struct lm_info_frv): Add destructor, initialize
10842 fields.
10843 (frv_current_sos): Allocate lm_info_frv with new.
10844 (frv_relocate_main_executable): Free lm_info_frv with delete,
10845 allocate with new.
10846 (frv_clear_solib, frv_free_so): Free lm_info_frv with delete.
10847
af43057b
SM
108482017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10849
10850 * solib-frv.c (struct lm_info_frv): Fix indentation.
10851
b0911207
SM
108522017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10853
10854 * solib-dsbt.c (struct lm_info_dsbt): Add destructor, initialize
10855 map field.
10856 (dsbt_current_sos): Allocate lm_info_dsbt with new.
10857 (dsbt_relocate_main_executable): Free lm_info_dsbt with delete
10858 and allocate with new.
10859 (dsbt_clear_solib, dsbt_free_so): Free lm_info_dsbt with delete.
10860
6c401f72
SM
108612017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10862
10863 * solib-aix.c (struct lm_info_aix): Initialize fields in-class.
10864 <filename, member_name>: Change type to std::string.
10865 (solib_aix_new_lm_info, solib_aix_xfree_lm_info): Remove.
10866 (library_list_start_library): Allocate lm_info_aix with new.
10867 (solib_aix_free_library_list, solib_aix_free_so): Free with delete.
10868 (solib_aix_current_sos): Adapt to std::string, copy lm_info_aix
10869 with copy constructor.
10870
d0e449a1
SM
108712017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10872
10873 * solist.h (struct lm_info): Remove.
10874 (struct lm_info_base): New class.
10875 (struct so_list) <lm_info>: Change type to lm_info_base *.
10876 * nto-tdep.c (struct lm_info): Remove.
10877 (lm_addr): Adjust.
10878 * solib-aix.c (struct lm_info): Rename to ...
10879 (struct lm_info_aix): ... this. Extend lm_info_base.
10880 (lm_info_p): Rename to ...
10881 (lm_info_aix_p): ... this, and adjust.
10882 (solib_aix_new_lm_info, solib_aix_xfree_lm_info,
10883 solib_aix_parse_libraries, library_list_start_library,
10884 solib_aix_free_library_list, solib_aix_parse_libraries,
10885 solib_aix_get_library_list,
10886 solib_aix_relocate_section_addresses, solib_aix_free_so,
10887 solib_aix_get_section_offsets,
10888 solib_aix_solib_create_inferior_hook, solib_aix_current_sos):
10889 Adjust.
10890 (struct solib_aix_inferior_data) <library_list>: Adjust.
10891 * solib-darwin.c (struct lm_info): Rename to ...
10892 (struct lm_info_darwin): ... this. Extend lm_info_base.
10893 (darwin_current_sos, darwin_relocate_section_addresses): Adjust.
10894 * solib-dsbt.c (struct lm_info): Rename to ...
10895 (struct lm_info_dsbt): ... this. Extend lm_info_base.
10896 (struct dsbt_info) <main_executable_lm_info): Adjust.
10897 (dsbt_current_sos, dsbt_relocate_main_executable, dsbt_free_so,
10898 dsbt_relocate_section_addresses): Adjust.
10899 * solib-frv.c (struct lm_info): Rename to ...
10900 (struct lm_info_frv): ... this. Extend lm_info_base.
10901 (main_executable_lm_info): Adjust.
10902 (frv_current_sos, frv_relocate_main_executable, frv_free_so,
10903 frv_relocate_section_addresses, frv_fdpic_find_global_pointer,
10904 find_canonical_descriptor_in_load_object,
10905 frv_fdpic_find_canonical_descriptor): Adjust.
10906 * solib-svr4.c (struct lm_info): Move to solib-svr4.h, renamed
10907 to lm_info_svr4.
10908 (lm_info_read, lm_addr_check, svr4_keep_data_in_core,
10909 svr4_clear_so, svr4_copy_library_list,
10910 library_list_start_library, svr4_default_sos, svr4_read_so_list,
10911 svr4_current_sos, svr4_fetch_objfile_link_map,
10912 solist_update_incremental): Adjust.
10913 * solib-svr4.h (struct lm_info_svr4): Move here from
10914 solib-svr4.c.
10915 * solib-target.c (struct lm_info): Rename to ...
10916 (struct lm_info_target): ... this. Extend lm_info_base.
10917 (lm_info_p): Rename to ...
10918 (lm_info_target_p): ... this.
10919 (solib_target_parse_libraries, library_list_start_segment,
10920 library_list_start_section, library_list_start_library,
10921 library_list_end_library, solib_target_free_library_list,
10922 solib_target_current_sos, solib_target_free_so,
10923 solib_target_relocate_section_addresses): Adjust.
10924 * windows-nat.c (struct lm_info): Rename to ...
10925 (struct lm_info_windows): ... this. Extend lm_info_base.
10926 (windows_make_so, handle_load_dll, handle_unload_dll,
10927 windows_xfer_shared_libraries): Adjust.
10928
434a4023
SM
109292017-04-28 Simon Marchi <simon.marchi@ericsson.com>
10930
10931 * solib-darwin.c (struct darwin_so_list): Remove.
10932 (darwin_current_sos): Allocate an so_list object instead of a
10933 darwin_so_list, separately allocate an lm_info object.
10934 (darwin_free_so): Free lm_info.
10935
428544e8
JB
109362017-04-28 John Baldwin <jhb@FreeBSD.org>
10937
10938 * mips-tdep.c (print_gp_register_row): Replace printf_filtered
10939 with fprintf_filtered.
10940
4621115f
YQ
109412017-04-28 Yao Qi <yao.qi@linaro.org>
10942
10943 * regcache.c (regcache::regcache): New function.
10944 (regcache::~regcache): New function.
10945 (regcache_xmalloc_1): Remove.
10946 (regcache_xmalloc): Call new regcache.
10947 (regcache_xfree): Call delete regcache.
10948 (get_thread_arch_aspace_regcache): Call new regcache.
10949
339053c2
YQ
109502017-04-28 Yao Qi <yao.qi@linaro.org>
10951
10952 * mips-linux-nat.c (mips_linux_new_thread): Use ptid method
10953 lwp instead of ptid_get_lwp.
10954
7974a605
YQ
109552017-04-28 Yao Qi <yao.qi@linaro.org>
10956
10957 * mips-linux-nat.c (mips_linux_new_thread): Get lwpid from
10958 lwp_info instead of getting from inferior_ptid.
10959
e15c3eb4
KS
109602017-04-27 Keith Seitz <keiths@redhat.com>
10961
10962 * gdbtypes.c (LVALUE_REFERENCE_TO_RVALUE_BINDING_BADNESS)
10963 DIFFERENT_REFERENCE_TYPE_BADNESS): Remove.
10964 (CV_CONVERSION_BADNESS): Define.
10965 (rank_one_type): Remove overly restrictive rvalue reference
10966 rank checks.
10967 Add cv-qualifier checks and subranks for type equality.
10968 * gdbtypes.h (REFERENCE_CONVERSION_RVALUE,
10969 REFERENCE_CONVERSION_CONST_LVALUE, CV_CONVERSION_BADNESS,
10970 CV_CONVERSION_CONST, CV_CONVERSION_VOLATILE): Declare.
10971
72bc1d24
SM
109722017-04-27 Simon Marchi <simon.marchi@ericsson.com>
10973
10974 * python/py-inferior.c (inferior_to_inferior_object): Increment reference
10975 count when creating the object.
10976
55bcecda
UW
109772017-04-27 Sangamesh Mallayya <sangamesh.swamy@in.ibm.com>
10978 Ulrich Weigand <uweigand@de.ibm.com>
10979
10980 * xcoffread.c (read_xcoff_symtab): Read correct function auxiliary
10981 entry if xlc -qfuncsect or gcc -ffunction-sections compiler option
10982 is used in AIX.
10983 (read_xcoff_symtab): Handle C_WEAKEXT storage class.
10984 (process_xcoff_symbol): Likewise.
10985 (scan_xcoff_symtab): Likewise.
10986
5c99fcf8
AH
109872017-04-26 Alan Hayward <alan.hayward@arm.com>
10988
10989 * ia64-tdep.c (examine_prologue): Use get_frame_register_unsigned.
10990 (ia64_sigtramp_frame_prev_register): Use read_memory_unsigned_integer.
10991 (ia64_access_reg): Use get_frame_register_unsigned.
10992 (ia64_access_rse_reg): Likewise.
10993 (ia64_libunwind_frame_prev_register): Likewise.
10994
b41c5a85
JW
109952017-04-26 Jiong Wang <jiong.wang@arm.com>
10996
10997 * gdbarch.sh: New gdbarch method execute_dwarf_cfa_vendor_op.
10998 * gdbarch.c: Regenerated.
10999 * gdbarch.h: Regenerated.
11000 * dwarf2-frame.c (dwarf2_frame_state_alloc_regs): Made the
11001 visibility external.
11002 (execute_cfa_program): Call execute_dwarf_cfa_vendor_op for CFI
11003 between DW_CFA_lo_user and DW_CFA_high_user inclusive.
11004 (enum cfa_how_kind): Move to ...
11005 (struct dwarf2_frame_state_reg_info): Likewise.
11006 (struct dwarf2_frame_state): Likewise.
11007 * dwarf2-frame.h: ... here.
11008 (dwarf2_frame_state_alloc_regs): New declaration.
11009 * sparc-tdep.c (sparc_execute_dwarf_cfa_vendor_op): New function.
11010 (sparc32_gdbarch_init): Register execute_dwarf_cfa_vendor_op hook.
11011
c185f580
AH
110122017-04-26 Alan Hayward <alan.hayward@arm.com>
11013
11014 * xtensa-tdep.c (xtensa_pseudo_register_read): Use
11015 regcache_raw_read_unsigned.
11016 (xtensa_pseudo_register_write): Likewise.
11017
19c45594
AH
110182017-04-26 Alan Hayward <alan.hayward@arm.com>
11019
11020 * nds32-tdep.c (nds32_pseudo_register_read): Abort on errors.
11021 (nds32_pseudo_register_write): Likewise.
11022
4658f12e
YQ
110232017-04-25 Yao Qi <yao.qi@linaro.org>
11024
11025 * regcache.c (struct regcache) <readonly_p>: Change its type
11026 to bool.
11027 (regcache_xmalloc_1): Update parameter type and callers update.
11028
d581dda8
YQ
110292017-04-25 Yao Qi <yao.qi@linaro.org>
11030
11031 * aarch64-tdep.c (aarch64_gdbarch_init): Don't call
11032 set_gdbarch_wchar_bit.
11033 * arm-tdep.c (arm_gdbarch_init): Likewise.
11034
debed3db
PA
110352017-04-25 Pedro Alves <palves@redhat.com>
11036
11037 * common/poison.h [!HAVE_IS_TRIVIALLY_COPYABLE] (IsRelocatable)
11038 (BothAreRelocatable, memcopy, memmove): Don't define.
11039 * common/traits.h (__has_feature, HAVE_IS_TRIVIALLY_COPYABLE): New
11040 macros.
11041
b0b92aeb
PA
110422017-04-25 Pedro Alves <palves@redhat.com>
11043
11044 * common/common-defs.h: Include "common/poison.h".
11045 * common/function-view.h: (Not, Or, Requires): Move to traits.h
11046 and adjust.
11047 * common/poison.h: New file.
11048 * common/traits.h: Include <type_traits>.
11049 (Not, Or, Requires): New, moved from common/function-view.h.
11050
16c4d54a
PA
110512017-04-25 Pedro Alves <palves@redhat.com>
11052
11053 * breakpoint.h (struct breakpoint): In-class initialize all
11054 fields. Make boolean fields "bool".
11055 * breakpoint.c (init_raw_breakpoint_without_location): Remove
11056 memset call and initializations no longer necessary.
11057
b5c36682
PA
110582017-04-25 Pedro Alves <palves@redhat.com>
11059
11060 * btrace.c (pt_btrace_insn_flags): Change parameter type to
11061 reference.
11062 (pt_btrace_insn): New function.
11063 (ftrace_add_pt): Remove memset call and use pt_btrace_insn.
11064
5625a286
PA
110652017-04-25 Pedro Alves <palves@redhat.com>
11066
11067 * ada-lang.c (ada_catchpoint_location): Now a "class". Remove
11068 "base" field and inherit from "bp_location" instead. Add
11069 non-default ctor.
11070 (allocate_location_exception): Use new non-default ctor.
11071 * breakpoint.c (get_first_locp_gte_addr): Remove memset call.
11072 (init_bp_location): Convert to ...
11073 (bp_location::bp_location): ... this new ctor, and remove memset
11074 call.
11075 (base_breakpoint_allocate_location): Use the new non-default ctor.
11076 * breakpoint.h (bp_location): Now a class. Declare default and
11077 non-default ctors. In-class initialize all members.
11078 (init_bp_location): Remove declaration.
11079
23bcc18f
PA
110802017-04-25 Pedro Alves <palves@redhat.com>
11081
11082 * common/enum-flags.h (enum_flags): Don't implement copy ctor and
11083 assignment operator.
11084
e1ba3053
YQ
110852017-04-24 Yao Qi <yao.qi@linaro.org>
11086
11087 * doublest.c (convert_doublest_to_floatformat): Call
11088 floatformat_totalsize_bytes.
11089
10f489e5
TT
110902017-04-22 Tom Tromey <tom@tromey.com>
11091
11092 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
11093 ui_out_emit_list.
11094 * stack.c (print_frame): Use ui_out_emit_list.
11095 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11096 ui_out_emit_list.
11097 * mi/mi-main.c (print_one_inferior)
11098 (mi_cmd_data_list_register_names)
11099 (mi_cmd_data_list_register_values, mi_cmd_list_features)
11100 (mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
11101 ui_out_emit_list.
11102 * mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
11103 (mi_output_solib_attribs): Use ui_out_emit_list,
11104 ui_out_emit_tuple.
11105 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
11106 * mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
11107 (mi_cmd_stack_list_args, list_args_or_locals): Use
11108 ui_out_emit_list.
11109 * disasm.c (do_assembly_only): Use ui_out_emit_list.
11110 * breakpoint.c (print_solib_event, output_thread_groups): Use
11111 ui_out_emit_list.
11112
0092b74d
TT
111132017-04-22 Tom Tromey <tom@tromey.com>
11114
11115 * mi/mi-main.c (print_variable_or_computed): Use ui_out_emit_tuple.
11116 * mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_tuple.
11117 * mi/mi-cmd-stack.c (list_arg_or_local): Use ui_out_emit_tuple.
11118
a14a62dd
TT
111192017-04-22 Tom Tromey <tom@tromey.com>
11120
11121 * tracepoint.c (tvariables_info_1)
11122 (print_one_static_tracepoint_marker): Use ui_out_emit_tuple.
11123
46b9c129
TT
111242017-04-22 Tom Tromey <tom@tromey.com>
11125
11126 * stack.c (print_frame_arg): Use ui_out_emit_tuple,
11127 annotate_arg_emitter.
11128 * breakpoint.c (print_mention_watchpoint)
11129 (print_mention_masked_watchpoint): Use ui_out_emit_tuple.
11130 * annotate.h (struct annotate_arg_emitter): New.
11131
2e783024
TT
111322017-04-22 Tom Tromey <tom@tromey.com>
11133
11134 * record-btrace.c (record_btrace_insn_history)
11135 (record_btrace_insn_history_range, record_btrace_call_history)
11136 (record_btrace_call_history_range): Use ui_out_emit_tuple.
11137 * thread.c (do_captured_list_thread_ids, print_thread_info_1): Use
11138 ui_out_emit_tuple.
11139 * stack.c (print_frame_info): Use ui_out_emit_tuple.
11140 * solib.c (info_sharedlibrary_command): Use ui_out_emit_tuple.
11141 * skip.c (skip_info): Use ui_out_emit_tuple.
11142 * remote.c (show_remote_cmd): Use ui_out_emit_tuple.
11143 * progspace.c (print_program_space): Use ui_out_emit_tuple.
11144 * probe.c (info_probes_for_ops): Use ui_out_emit_tuple.
11145 * osdata.c (info_osdata): Use ui_out_emit_tuple.
11146 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
11147 ui_out_emit_tuple.
11148 * mi/mi-main.c (print_one_inferior, list_available_thread_groups)
11149 (output_register, mi_cmd_data_read_memory)
11150 (mi_cmd_data_read_memory_bytes, mi_load_progress)
11151 (mi_cmd_trace_frame_collected): Use ui_out_emit_tuple.
11152 * mi/mi-cmd-var.c (mi_cmd_var_list_children, varobj_update_one):
11153 Use ui_out_emit_tuple.
11154 * mi/mi-cmd-stack.c (mi_cmd_stack_list_args): Use
11155 ui_out_emit_tuple.
11156 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
11157 (mi_cmd_info_gdb_mi_command): Use ui_out_emit_tuple.
11158 * linux-thread-db.c (info_auto_load_libthread_db): Use
11159 ui_out_emit_tuple.
11160 * inferior.c (print_inferior): Use ui_out_emit_tuple.
11161 * gdb_bfd.c (print_one_bfd): Use ui_out_emit_tuple.
11162 * disasm.c (do_mixed_source_and_assembly_deprecated)
11163 (do_mixed_source_and_assembly): Use ui_out_emit_tuple.
11164 * cp-abi.c (list_cp_abis): Use ui_out_emit_tuple.
11165 * cli/cli-setshow.c (cmd_show_list): Use ui_out_emit_tuple.
11166 * breakpoint.c (print_one_breakpoint_location)
11167 (print_one_breakpoint): Use ui_out_emit_tuple.
11168 * auto-load.c (print_script, info_auto_load_cmd): Use
11169 ui_out_emit_tuple.
11170 * ada-tasks.c (print_ada_task_info): Use ui_out_emit_tuple.
11171
9be21bb4
SM
111722017-04-21 Simon Marchi <simon.marchi@ericsson.com>
11173
11174 * thread.c (print_thread_info_1): Remove dead code.
11175
0d4c07af
JK
111762017-04-21 Jan Kratochvil <jan.kratochvil@redhat.com>
11177
11178 * aarch64-tdep.c (selftests::aarch64_process_record_test): Make it #if
11179 GDB_SELF_TEST.
11180 * arm-tdep.c (selftests::arm_record_test): Likewise.
11181
4daf993d
YQ
111822017-04-21 Yao Qi <yao.qi@linaro.org>
11183
11184 * regcache.c (regcache_restore): Remove argument 2. Replace
11185 argument 3 with regcache. Get register status from
11186 src->register_status and get register contents from
11187 register_buffer (src, regnum).
11188 (regcache_cpy): Update.
11189
a6c21d4a
PA
111902017-04-19 Pedro Alves <palves@redhat.com>
11191
11192 * gdbthread.h (thread): Add missing closing parenthesis in
11193 comment.
11194
3a3fd0fd
PA
111952017-04-19 Pedro Alves <palves@redhat.com>
11196
11197 * common/refcounted-object.h: New file.
11198 * gdbthread.h: Include "common/refcounted-object.h".
11199 (thread_info): Inherit from refcounted_object and add comments.
11200 (thread_info::incref, thread_info::decref)
11201 (thread_info::m_refcount): Delete.
11202 (thread_info::deletable): Use the refcounted_object::refcount()
11203 method.
11204 * inferior.c (current_inferior_): Add comment.
11205 (set_current_inferior): Increment/decrement refcounts.
11206 (prune_inferiors, remove_inferior_command): Skip inferiors marked
11207 not-deletable instead of comparing with the current inferior.
11208 (initialize_inferiors): Increment the initial inferior's refcount.
11209 * inferior.h (struct inferior): Forward declare.
11210 Include "common/refcounted-object.h".
11211 (current_inferior, set_current_inferior): Move declaration to
11212 before struct inferior's definition, and fix comment.
11213 (inferior): Inherit from refcounted_object. Add comments.
11214 * thread.c (switch_to_thread_no_regs): Reference the thread's
11215 inferior pointer directly instead of doing a ptid lookup.
11216 (switch_to_no_thread): New function.
11217 (switch_to_thread(thread_info *)): New function, factored out
11218 from ...
11219 (switch_to_thread(ptid_t)): ... this.
11220 (restore_current_thread): Delete.
11221 (current_thread_cleanup): Remove 'inf_id' and 'was_removable'
11222 fields, and add 'inf' field.
11223 (do_restore_current_thread_cleanup): Check whether old->inf is
11224 alive instead of looking up an inferior by ptid. Use
11225 switch_to_thread and switch_to_no_thread.
11226 (restore_current_thread_cleanup_dtor): Use old->inf directly
11227 instead of lookup up an inferior by id. Decref the inferior.
11228 Don't restore 'removable'.
11229 (make_cleanup_restore_current_thread): Same the inferior pointer
11230 in old, instead of the inferior number. Incref the inferior.
11231 Don't save/clear 'removable'.
11232
9bcb1f16
PA
112332017-04-19 Pedro Alves <palves@redhat.com>
11234
11235 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11236 unittests/scoped_restore-selftests.c.
11237 (SUBDIR_UNITTESTS_OBS): Add scoped_restore-selftests.o.
11238 * common/scoped_restore.h (scoped_restore_base): Make "class".
11239 (scoped_restore_base::release): New public method.
11240 (scoped_restore_base::scoped_restore_base): New protected ctor.
11241 (scoped_restore_base::m_saved_var): New protected field.
11242 (scoped_restore_tmpl::scoped_restore_tmpl(T*)): Initialize the
11243 scoped_restore_base base class instead of m_saved_var directly.
11244 (scoped_restore_tmpl::scoped_restore_tmpl(T*, T2)): Likewise.
11245 (scoped_restore_tmpl::scoped_restore_tmpl(const
11246 scoped_restore_tmpl<T>&)): Likewise.
11247 (scoped_restore_tmpl::~scoped_restore_tmpl): Use the saved_var
11248 method.
11249 (scoped_restore_tmpl::saved_var): New method.
11250 (scoped_restore_tmpl::m_saved_var): Delete.
11251 * inferior.h (inferior::detaching): Now a bool.
11252 * infrun.c (prepare_for_detach): Use a scoped_restore instead of a
11253 cleanup.
11254 * unittests/scoped_restore-selftests.c: New file.
11255
26fcd539
PA
112562017-04-19 Pedro Alves <palves@redhat.com>
11257
11258 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS):
11259 Re-sort in alphabetic order.
11260
fdd243b0
PA
112612017-04-18 Pedro Alves <palves@redhat.com>
11262
11263 * xml-support.c (obstack_xml_printf): Delete.
11264 * xml-support.h (obstack_xml_printf): Delete.
11265
4895cde2
PA
112662017-04-18 Pedro Alves <palves@redhat.com>
11267
11268 * xml-support.c (gdb_xml_parser) <use_dtd, dtd_name, parse,
11269 vdebug, verror, body_text, start_element, end_element, name,
11270 user_data, set_is_xinclude, set_error, expat_parser>: New methods.
11271 <name, user_data, expat_parser, scopes, error, last_line, dtd_name,
11272 is_xinclude>: Make private and add m_ prefix.
11273 (gdb_xml_parser::body_text): New method, based on ...
11274 (gdb_xml_body_text): ... this. Adjust.
11275 (gdb_xml_parser::vdebug): New method, based on ...
11276 (gdb_xml_debug): ... this. Adjust.
11277 (gdb_xml_parser::verror): New method, based on ...
11278 (gdb_xml_error): ... this. Adjust.
11279 (gdb_xml_parser::start_element): New method, based on ...
11280 (gdb_xml_start_element): ... this. Adjust.
11281 (gdb_xml_start_element_wrapper): Defer to
11282 gdb_xml_parser::start_element and gdb_xml_parser::set_error.
11283 (gdb_xml_parser::end_element): New method, based on ...
11284 (gdb_xml_end_element_wrapper): ... this. Adjust.
11285 (gdb_xml_parser::~gdb_xml_parser): Adjust.
11286 (gdb_xml_parser::gdb_xml_parser): Adjust to field renames.
11287 (gdb_xml_parser::use_dtd): New method, based on ...
11288 (gdb_xml_use_dtd): ... this. Adjust.
11289 (gdb_xml_parser::parse): New method, based on ...
11290 (gdb_xml_parse): ... this. Adjust.
11291 (gdb_xml_parse_quick): Adjust to call the parser's parse method.
11292 (xinclude_start_include): Adjust to call the parser's name method.
11293 (xml_xinclude_default, xml_xinclude_start_doctype)
11294 (xml_xinclude_end_doctype): Adjust to call the parser's user_data
11295 method.
11296 (xml_process_xincludes): Adjust to call parser methods.
11297 * xml-support.h (gdb_xml_use_dtd, gdb_xml_parse): Delete
11298 declarations.
11299
bd8a901f
PA
113002017-04-18 Pedro Alves <palves@redhat.com>
11301
11302 * tracefile-tfile.c (tfile_write_tdesc): Adjust to use
11303 gdb::optional<std::string>.
11304 * xml-support.c: Include <string>.
11305 (scope_level::scope_level(scope_level &&))
11306 (scope_level::~scope_level): Delete.
11307 (scope_level::body): Now a std::string.
11308 (gdb_xml_body_text, gdb_xml_end_element): Adjust.
11309 (xinclude_parsing_data::xinclude_parsing_data): Add 'output'
11310 parameter.
11311 (xinclude_parsing_data::~xinclude_parsing_data): Delete.
11312 (xinclude_parsing_data::output): Now a std::string reference.
11313 (xinclude_start_include): Adjust.
11314 (xml_xinclude_default): Adjust.
11315 (xml_process_xincludes): Add 'output' parameter, and return bool.
11316 * xml-support.h (xml_process_xincludes): Add 'output' parameter,
11317 and return bool.
11318 * xml-tdesc.c: Include <unordered_map> and <string>.
11319 (tdesc_xml_cache): Delete.
11320 (tdesc_xml_cache_s): Delete.
11321 (xml_cache): Now an std::unordered_map.
11322 (tdesc_parse_xml): Adjust to use std::string and unordered_map.
11323 (target_fetch_description_xml): Change return type to
11324 gdb::optional<std::string>, and adjust.
11325 * xml-tdesc.h: Include "common/gdb_optional.h" and <string>.
11326 (target_fetch_description_xml): Change return type to
11327 gdb::optional<std::string>.
11328
d35d1958
PA
113292017-04-18 Pedro Alves <palves@redhat.com>
11330
11331 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11332 unittests/optional-selftests.c.
11333 (SUBDIR_UNITTESTS_OBS): Add optional-selftests.o.
11334 * unittests/optional-selftests.c: New file.
11335 * unittests/optional/assignment/1.cc: New file.
11336 * unittests/optional/assignment/2.cc: New file.
11337 * unittests/optional/assignment/3.cc: New file.
11338 * unittests/optional/assignment/4.cc: New file.
11339 * unittests/optional/assignment/5.cc: New file.
11340 * unittests/optional/assignment/6.cc: New file.
11341 * unittests/optional/assignment/7.cc: New file.
11342 * unittests/optional/cons/copy.cc: New file.
11343 * unittests/optional/cons/default.cc: New file.
11344 * unittests/optional/cons/move.cc: New file.
11345 * unittests/optional/cons/value.cc: New file.
11346 * unittests/optional/in_place.cc: New file.
11347 * unittests/optional/observers/1.cc: New file.
11348 * unittests/optional/observers/2.cc: New file.
11349
22796e97
PA
113502017-04-18 Pedro Alves <palves@redhat.com>
11351
11352 * common/gdb_optional.h: Include common/traits.h.
11353 (in_place_t): New type.
11354 (in_place): New constexpr variable.
11355 (optional::optional): Remove member initialization of
11356 m_instantiated.
11357 (optional::optional(in_place_t...)): New constructor.
11358 (optional::~optional): Use reset.
11359 (optional::optional(const optional&)): New.
11360 (optional::optional(const optional&&)): New.
11361 (optional::optional(T &)): New.
11362 (optional::optional(T &&)): New.
11363 (operator::operator=(const optional &)): New.
11364 (operator::operator=(optional &&)): New.
11365 (operator::operator= (const T &))
11366 (operator::operator= (T &&))
11367 (operator::emplace (Args &&... args)): Return a T&. Use reset.
11368 (operator::reset): New.
11369 (operator::m_instantiated):: Add in-class initializer.
11370 * common/traits.h: Include <type_traits>.
11371 (struct And): New types.
11372
a7fc9b61
PA
113732017-04-18 Pedro Alves <palves@redhat.com>
11374
11375 * xml-support.c: Include <vector>.
11376 (scope_level::scope_level(const gdb_xml_element *))
11377 (scope_level::scope_level(scope_level&&)): New.
11378 (scope_level::~scope_level): New.
11379 (scope_level_s): Delete.
11380 (gdb_xml_parser::scopes): Now a std::vector.
11381 (gdb_xml_body_text, gdb_xml_start_element, gdb_xml_end_element):
11382 Use std::vector.
11383 (gdb_xml_parser::~gdb_xml_parser): Remove now unnecessary
11384 scope cleanup code.
11385 (gdb_xml_parser::gdb_xml_parser): Remove explicit initialization
11386 of the scopes member. Use std::vector::emplace_back.
11387
010151c9
PA
113882017-04-18 Pedro Alves <palves@redhat.com>
11389
11390 * xml-support.c (gdb_xml_parser): Add ctor/dtor. Make is_xinclude
11391 a bool.
11392 (gdb_xml_end_element): Change type of first parameter.
11393 (gdb_xml_cleanup): Rename to ...
11394 (gdb_xml_parser::~gdb_xml_parser): ... this.
11395 (gdb_xml_create_parser_and_cleanup): Delete with ...
11396 (gdb_xml_parser::gdb_xml_parser): ... creation parts factored out
11397 to this new ctor.
11398 (gdb_xml_parse_quick): Create a local gdb_xml_parser instead of
11399 using gdb_xml_create_parser_and_cleanup.
11400 (xinclude_parsing_data): Add ctor/dtor.
11401 (xml_xinclude_cleanup): Delete.
11402 (xml_process_xincludes): Create a local xinclude_parsing_data
11403 instead of heap-allocating one. Create a local gdb_xml_parser
11404 instead of heap-allocating one with
11405 gdb_xml_create_parser_and_cleanup.
11406
d56060f0
JB
114072017-04-18 John Baldwin <jhb@FreeBSD.org>
11408
11409 PR threads/20743
11410 * fbsd-nat.c (resume_one_thread_cb): Remove.
11411 (resume_all_threads_cb): Remove.
11412 (fbsd_resume): Use ALL_NON_EXITED_THREADS instead of
11413 iterate_over_threads.
11414
305d16a9
JB
114152017-04-17 Joel Brobecker <brobecker@adacore.com>
11416
11417 * NEWS: Create a new section for the next release branch.
11418 Rename the section of the current branch, now that it has
11419 been cut.
11420
8bb57231
JB
114212017-04-17 Joel Brobecker <brobecker@adacore.com>
11422
11423 GDB 8.0 branch created (725bf5cf125783c2a7ca4ab63d3768e220bab2db):
11424 * version.in: Bump version to 8.0.50.DATE-git.
11425
096c92dd
SDJ
114262017-04-13 Sergio Durigan Junior <sergiodj@redhat.com>
11427
11428 PR gdb/21385
11429 * windows-nat.c (windows_create_inferior): Declare 'allargs'
11430 independently of the host, and fix build breakage on Cygwin.
11431
0550c955
PA
114322017-04-13 Pedro Alves <palves@redhat.com>
11433
11434 * inferior.c (free_inferior): Convert to ...
11435 (inferior::~inferior): ... this dtor.
11436 (inferior::inferior): New ctor, factored out from ...
11437 (add_inferior_silent): ... here. Allocate the inferior with a new
11438 expression.
11439 (delete_inferior): Call delete instead of free_inferior.
11440 * inferior.h (gdb_environ, continuation): Forward declare.
11441 (inferior): Now a class. Add in-class initialization to all
11442 members. Make boolean fields bool, except 'detaching'.
11443 (inferior::inferior): New explicit ctor.
11444 (inferior::~inferior): New.
11445
e3d60dfc
PA
114462017-04-13 Pedro Alves <palves@redhat.com>
11447
11448 * inferior.c (init_inferior_list): Delete.
11449 * inferior.h (init_inferior_list): Delete.
11450
5fd69d0a
PA
114512017-04-13 Pedro Alves <palves@redhat.com>
11452
11453 PR threads/13217
11454 * gdb.threads/threadapply.exp (thr_apply_detach): New procedure.
11455 (top level): Call it twice, with different thread sets.
11456
c6609450
PA
114572017-04-13 Pedro Alves <palves@redhat.com>
11458
11459 * thread.c: Include <algorithm>.
11460 (thread_array_cleanup): Delete.
11461 (scoped_inc_dec_ref): New class.
11462 (live_threads_count): New function.
11463 (set_thread_refcount): Delete.
11464 (tp_array_compar_ascending): Now a bool.
11465 (tp_array_compar): Convert to a std::sort comparison function.
11466 (thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
11467 and live_threads_count.
11468
2a00d7ce
PA
114692017-04-13 Pedro Alves <palves@redhat.com>
11470
11471 * infrun.c (follow_fork_inferior): Also switch the current
11472 inferior.
11473
441d7c93
PA
114742017-04-13 Pedro Alves <palves@redhat.com>
11475
11476 * breakpoint.c (watch_command_1): Save watchpoint-frame info
11477 before calling create_internal_breakpoint.
11478
808480f6
PA
114792017-04-13 Pedro Alves <palves@redhat.com>
11480
11481 * fork-child.c (execv_argv): New class.
11482 (breakup_args): Refactored as ...
11483 (execv_argv::init_for_no_shell): .. this method of execv_argv.
11484 Copy arguments to storage and replace separators with NULL
11485 terminators in place.
11486 (escape_bang_in_quoted_argument): Adjust to return bool.
11487 (execv_argv::execv_argv): New ctor.
11488 (execv_argv::init_for_shell): New method, factored out from
11489 fork_inferior. Don't strdup strings into the vector.
11490 (fork_inferior): Eliminate "shell" local and use execv_argv. Use
11491 Remove free_vector_argv call.
11492
ad3d022a
YQ
114932017-04-13 Yao Qi <yao.qi@linaro.org>
11494
11495 * rx-tdep.c (rx_fpsw_type): Check tdep->rx_fpsw_type instead of
11496 tdep->rx_psw_type.
11497
e6ddc3bf
YQ
114982017-04-13 Yao Qi <yao.qi@linaro.org>
11499
11500 * rl78-tdep.c (rl78_gdbarch_init): Use XCNEW instead of XNEW.
11501 * rx-tdep.c (rx_gdbarch_init): Likewise.
11502
bfb8cf90
PA
115032017-04-13 Pedro Alves <palves@redhat.com>
11504
11505 * breakpoint.h (struct breakpoint): Reindent.
11506
f5336ca5
PA
115072017-04-13 Pedro Alves <palves@redhat.com>
11508
11509 * breakpoint.c (bp_location): Rename to ...
11510 (bp_locations): ... this. All references updated.
11511 (bp_location_count): Rename to ...
11512 (bp_locations_count): ... this. All references updated.
11513 (bp_location_placed_address_before_address_max): Rename to ...
11514 (bp_locations_placed_address_before_address_max): ... this. All
11515 references updated.
11516 (bp_location_shadow_len_after_address_max): Rename to ...
11517 (bp_locations_shadow_len_after_address_max): ... this. All
11518 references updated.
11519 (bp_location_compare_addrs): Rename to ...
11520 (bp_locations_compare_addrs): ... this. All references updated.
11521 (bp_location_compare):Rename to ...
11522 (bp_locations_compare): ... this. All references updated.
11523 (bp_location_target_extensions_update): Rename to ...
11524 (bp_locations_target_extensions_update): ... this. All references
11525 updated.
11526
be628ab8
SDJ
115272017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11528
11529 * Makefile.in (HFILES_NO_SRCDIR): Add "common/gdb_termios.h".
11530 * common/common.m4: Check headers 'termios.h', 'termio.h' and
11531 'sgtty.h'.
11532 * common/gdb_termios.h: New file, with parts of "terminal.h".
11533 * inflow.c: Include "gdb_termios.h".
11534 * ser-unix.c: Include "gdb_termios.h".
11535 * terminal.h: Move terminal-related defines to
11536 "common/gdb_termios.h".
11537
8e9e35b1
TT
115382017-04-12 Tom Tromey <tom@tromey.com>
11539
11540 * probe.c (parse_probes): Update.
11541 * location.h (delete_event_location): Don't declare.
11542 (event_location_deleter::operator()): Update.
11543 * location.c (event_location_deleter::operator()): Rename from
11544 delete_event_location.
11545 * linespec.h (linespec_result) <location>: Change type to
11546 event_location_up.
11547 * linespec.c (canonicalize_linespec, event_location_to_sals)
11548 (decode_objc): Update.
11549 (linespec_result): Don't call delete_event_location.
11550 * breakpoint.c (create_breakpoints_sal)
11551 (bkpt_probe_create_sals_from_location)
11552 (strace_marker_create_sals_from_location): Update.
11553
16e802b9
TT
115542017-04-12 Tom Tromey <tom@tromey.com>
11555
11556 * linespec.h (struct linespec_result): Add constructor and
11557 destructor.
11558 (init_linespec_result, destroy_linespec_result)
11559 (make_cleanup_destroy_linespec_result): Don't declare.
11560 * linespec.c (init_linespec_result): Remove.
11561 (linespec_result::~linespec_result): Rename from
11562 destroy_linespec_result. Update.
11563 (cleanup_linespec_result, make_cleanup_destroy_linespec_result):
11564 Remove.
11565 * breakpoint.c (create_breakpoint, break_range_command)
11566 (decode_location_default): Update.
11567 * ax-gdb.c (agent_command_1): Update.
11568
d28cd78a
TT
115692017-04-12 Tom Tromey <tom@tromey.com>
11570
11571 * remote.c (remote_download_tracepoint): Update.
11572 * python/py-breakpoint.c (bppy_get_location): Update.
11573 * guile/scm-breakpoint.c (bpscm_print_breakpoint_smob)
11574 (gdbscm_breakpoint_location): Update.
11575 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Update.
11576 * breakpoint.h (struct breakpoint) <location, location_range_end>:
11577 Change type to event_location_up.
11578 * breakpoint.c (create_overlay_event_breakpoint)
11579 (create_longjmp_master_breakpoint)
11580 (create_std_terminate_master_breakpoint)
11581 (create_exception_master_breakpoint)
11582 (breakpoint_event_location_empty_p, print_breakpoint_location)
11583 (print_one_breakpoint_location, create_thread_event_breakpoint)
11584 (init_breakpoint_sal, create_breakpoint)
11585 (print_recreate_ranged_breakpoint, break_range_command)
11586 (init_ada_exception_breakpoint, say_where): Update.
11587 (base_breakpoint_dtor): Don't call delete_event_location.
11588 (bkpt_print_recreate, tracepoint_print_recreate)
11589 (dprintf_print_recreate, update_static_tracepoint)
11590 (breakpoint_re_set_default): Update.
11591
711799d5
TT
115922017-04-12 Tom Tromey <tom@tromey.com>
11593
11594 * compile/compile-loc2c.c (compute_stack_depth_worker): Change
11595 type of "to_do". Update.
11596 (compute_stack_depth): Use std::vector.
11597
52d214d3
TT
115982017-04-12 Tom Tromey <tom@tromey.com>
11599
11600 * printcmd.c (find_instruction_backward): Use std::vector.
11601
4c404b8b
TT
116022017-04-12 Tom Tromey <tom@tromey.com>
11603
11604 * symfile.c (objfilep): Remove typedef.
11605 (reread_symbols): Use a std::vector.
11606
156d9eab
TT
116072017-04-12 Tom Tromey <tom@tromey.com>
11608
11609 * mi/mi-main.c (exec_direction_forward): Remove.
11610 (exec_reverse_continue, mi_execute_command): Use scoped_restore.
11611 * guile/scm-ports.c (ioscm_with_output_to_port_worker): Use
11612 scoped_restore.
11613 * guile/guile.c (guile_repl_command, guile_command)
11614 (gdbscm_execute_gdb_command): Use scoped_restore.
11615 * go-exp.y (go_parse): Use scoped_restore.
11616 * d-exp.y (d_parse): Use scoped_restore.
11617 * cli/cli-decode.c (cmd_func): Use scoped_restore.
11618 * c-exp.y (c_parse): Use scoped_restore.
11619
4d89769a
TT
116202017-04-12 Tom Tromey <tom@tromey.com>
11621
11622 * mi/mi-parse.h (struct mi_parse): Add constructor, destructor.
11623 (mi_parse): Update return type.
11624 (mi_parse_free): Remove.
11625 * mi/mi-parse.c (mi_parse::mi_parse): New constructor.
11626 (mi_parse::~mi_parse): Rename from mi_parse_free.
11627 (mi_parse_cleanup): Remove.
11628 (mi_parse): Return a unique_ptr. Use new.
11629 * mi/mi-main.c (mi_execute_command): Update.
11630
4b217cc7
TT
116312017-04-12 Tom Tromey <tom@tromey.com>
11632
11633 * location.c (explicit_location_lex_one): Return a
11634 unique_xmalloc_ptr.
11635 (string_to_explicit_location): Update. Remove cleanups.
11636
59d3651b
TT
116372017-04-12 Tom Tromey <tom@tromey.com>
11638
11639 * gnu-v3-abi.c (value_and_voffset_p): Remove typedef.
11640 (compare_value_and_voffset): Change type. Update.
11641 (compute_vtable_size): Change type of "offset_vec".
11642 (gnuv3_print_vtable): Use std::vector. Remove cleanups.
11643 (gnuv3_get_typeid): Remove extraneous declaration.
11644
b24b0d6c
TT
116452017-04-12 Tom Tromey <tom@tromey.com>
11646
11647 * charset.h (wchar_iterator): Fix comment.
11648
80a3b8c5
TT
116492017-04-12 Tom Tromey <tom@tromey.com>
11650
11651 * charset.c (iconv_wrapper): New class.
11652 (cleanup_iconv): Remove.
11653 (convert_between_encodings): Use it.
11654
c83dd867
TT
116552017-04-12 Tom Tromey <tom@tromey.com>
11656
11657 * symfile.h (increment_reading_symtab): Update type.
11658 * symfile.c (decrement_reading_symtab): Remove.
11659 (increment_reading_symtab): Return a scoped_restore_tmpl<int>.
11660 * psymtab.c (psymtab_to_symtab): Update.
11661 * dwarf2read.c (dw2_instantiate_symtab): Update.
11662
0e8621a0
TT
116632017-04-12 Tom Tromey <tom@tromey.com>
11664
11665 * jit.c (struct jit_reader): Declare separately. Add constructor
11666 and destructor. Change type of "handle".
11667 (loaded_jit_reader): Define separately.
11668 (jit_reader_load): Update. New "new".
11669 (jit_reader_unload_command): Use "delete".
11670 * gdb-dlfcn.h (struct dlclose_deleter): New.
11671 (gdb_dlhandle_up): New typedef.
11672 (gdb_dlopen, gdb_dlsym): Update types.
11673 (gdb_dlclose): Remove.
11674 * gdb-dlfcn.c (gdb_dlopen): Return a gdb_dlhandle_up.
11675 (gdb_dlsym): Change type of "handle".
11676 (make_cleanup_dlclose): Remove.
11677 (dlclose_deleter::operator()): Rename from gdb_dlclose.
11678 * compile/compile-c-support.c (load_libcc): Update.
11679
67d89901
TT
116802017-04-12 Tom Tromey <tom@tromey.com>
11681
11682 * symtab.h (find_pcs_for_symtab_line): Change return type.
11683 * symtab.c (find_pcs_for_symtab_line): Change return type.
11684 * python/py-linetable.c (build_line_table_tuple_from_pcs): Change
11685 type of "vec". Update.
11686 (ltpy_get_pcs_for_line): Update.
11687 * linespec.c (decode_digits_ordinary): Update.
11688
93921405
TT
116892017-04-12 Tom Tromey <tom@tromey.com>
11690
11691 * tracepoint.c (actions_command): Update.
11692 * python/python.c (python_command, python_interactive_command):
11693 Update.
11694 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
11695 * guile/guile.c (guile_command): Update.
11696 * defs.h (read_command_lines, read_command_lines_1): Return
11697 command_line_up.
11698 (command_lines_deleter): New struct.
11699 (command_line_up): New typedef.
11700 * compile/compile.c (compile_code_command)
11701 (compile_print_command): Update.
11702 * cli/cli-script.h (get_command_line, copy_command_lines): Return
11703 command_line_up.
11704 (make_cleanup_free_command_lines): Remove.
11705 * cli/cli-script.c (get_command_line, read_command_lines_1)
11706 (copy_command_lines): Return command_line_up.
11707 (while_command, if_command, read_command_lines, define_command)
11708 (document_command): Update.
11709 (do_free_command_lines_cleanup, make_cleanup_free_command_lines):
11710 Remove.
11711 * breakpoint.h (breakpoint_set_commands): Change type of
11712 "commands".
11713 * breakpoint.c (breakpoint_set_commands): Change type of
11714 "commands". Update.
11715 (do_map_commands_command, update_dprintf_command_list)
11716 (create_tracepoint_from_upload): Update.
11717
ffc2605c
TT
117182017-04-12 Tom Tromey <tom@tromey.com>
11719
11720 * tracepoint.c (scope_info): Update.
11721 * spu-tdep.c (spu_catch_start): Update.
11722 * python/python.c (gdbpy_decode_line): Update.
11723 * python/py-finishbreakpoint.c (bpfinishpy_init): Update.
11724 * python/py-breakpoint.c (bppy_init): Update.
11725 * probe.c (parse_probes): Update.
11726 * mi/mi-cmd-break.c (mi_cmd_break_insert_1): Update.
11727 * location.h (event_location_deleter): New struct.
11728 (event_location_up): New typedef.
11729 (new_linespec_location, new_address_location, new_probe_location)
11730 (new_explicit_location, copy_event_location)
11731 (string_to_event_location, string_to_event_location_basic)
11732 (string_to_explicit_location): Update return type.
11733 (make_cleanup_delete_event_location): Remove.
11734 * location.c (new_linespec_location, new_address_location)
11735 (new_probe_location, new_explicit_location, copy_event_location):
11736 Return event_location_up.
11737 (delete_event_location_cleanup)
11738 (make_cleanup_delete_event_location): Remove.
11739 (string_to_explicit_location, string_to_event_location_basic)
11740 (string_to_event_location): Return event_location_up.
11741 * linespec.c (canonicalize_linespec, event_location_to_sals)
11742 (decode_line_with_current_source)
11743 (decode_line_with_last_displayed, decode_objc): Update.
11744 * guile/scm-breakpoint.c (gdbscm_register_breakpoint_x): Update.
11745 * completer.c (location_completer): Update.
11746 * cli/cli-cmds.c (edit_command, list_command): Update.
11747 * breakpoint.c (create_overlay_event_breakpoint)
11748 (create_longjmp_master_breakpoint)
11749 (create_std_terminate_master_breakpoint)
11750 (create_exception_master_breakpoint)
11751 (create_thread_event_breakpoint): Update.
11752 (init_breakpoint_sal): Update. Remove some dead code.
11753 (create_breakpoint_sal): Change type of "location". Update.
11754 (create_breakpoints_sal, create_breakpoint, break_command_1)
11755 (dprintf_command, break_range_command, until_break_command)
11756 (init_ada_exception_breakpoint)
11757 (strace_marker_create_sals_from_location)
11758 (update_static_tracepoint, trace_command, ftrace_command)
11759 (strace_command, create_tracepoint_from_upload): Update.
11760 * break-catch-throw.c (re_set_exception_catchpoint): Update.
11761 * ax-gdb.c (agent_command_1): Update.
11762
8f10c932
PA
117632017-04-12 Pedro Alves <palves@redhat.com>
11764
11765 * Makefile.in (ALL_TARGET_OBS): Add i386-go32-tdep.o.
11766 * configure.tgt: Handle i[34567]86-*-go32* and
11767 i[34567]86-*-msdosdjgpp*.
11768 * i386-tdep.c (i386_svr4_reg_to_regnum):
11769 Make extern.
11770 (i386_go32_init_abi, i386_coff_osabi_sniffer): Moved to
11771 i386-go32-tdep.c.
11772 (_initialize_i386_tdep): DJGPP bits moved to i386-go32-tdep.c.
11773 * i386-go32-tdep.c: New file.
11774 * i386-tdep.h (tdesc_i386_mmx, i386_svr4_reg_to_regnum): New
11775 declarations.
11776
0a31ccfb
SM
117772017-04-12 Simon Marchi <simon.marchi@ericsson.com>
11778
11779 * aix-thread.c (pd_status2str): Change return type to const char *.
11780
e9bb3fbb
PA
117812017-04-12 Pedro Alves <palves@redhat.com>
11782
11783 * i386-tdep.c (i386_elf_init_abi, i386_go32_init_abi): Remove
11784 calls to set_gdbarch_gnu_triplet_regexp.
11785
53375380
PA
117862017-04-12 Pedro Alves <palves@redhat.com>
11787
11788 PR gdb/21323
11789 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_wchar_t>:
11790 New enum value.
11791 (cplus_language_arch_info): Register cplus_primitive_type_wchar_t.
11792 * gdbtypes.h (struct builtin_type) <builtin_wchar>: New field.
11793 * gdbtypes.c (gdbtypes_post_init): Create the "wchar_t" type.
11794 * gdbarch.sh (wchar_bit, wchar_signed): New per-arch values.
11795 * gdbarch.h, gdbarch.c: Regenerate.
11796 * aarch64-tdep.c (aarch64_gdbarch_init): Override
11797 gdbarch_wchar_bit and gdbarch_wchar_signed.
11798 * alpha-tdep.c (alpha_gdbarch_init): Likewise.
11799 * arm-tdep.c (arm_gdbarch_init): Likewise.
11800 * avr-tdep.c (avr_gdbarch_init): Likewise.
11801 * h8300-tdep.c (h8300_gdbarch_init): Likewise.
11802 * i386-nto-tdep.c (i386nto_init_abi): Likewise.
11803 * i386-tdep.c (i386_go32_init_abi): Likewise.
11804 * m32r-tdep.c (m32r_gdbarch_init): Likewise.
11805 * moxie-tdep.c (moxie_gdbarch_init): Likewise.
11806 * nds32-tdep.c (nds32_gdbarch_init): Likewise.
11807 * rs6000-aix-tdep.c (rs6000_aix_init_osabi): Likewise.
11808 * sh-tdep.c (sh_gdbarch_init): Likewise.
11809 * sparc-tdep.c (sparc32_gdbarch_init): Likewise.
11810 * sparc64-tdep.c (sparc64_init_abi): Likewise.
11811 * windows-tdep.c (windows_init_abi): Likewise.
11812 * xstormy16-tdep.c (xstormy16_gdbarch_init): Likewise.
11813
53e710ac
PA
118142017-04-12 Pedro Alves <palves@redhat.com>
11815
11816 PR c++/21323
11817 * c-lang.c (cplus_primitive_types) <cplus_primitive_type_char16_t,
11818 cplus_primitive_type_char32_t>: New enum values.
11819 (cplus_language_arch_info): Register cplus_primitive_type_char16_t
11820 and cplus_primitive_type_char32_t.
11821 * dwarf2read.c (read_base_type) <DW_ATE_UTF>: If bit size is 16 or
11822 32, use the archtecture's built-in type for char16_t and char32_t,
11823 respectively. Otherwise, fallback to init_integer_type as before,
11824 but make the type unsigned, and issue a complaint.
11825 * gdbtypes.c (gdbtypes_post_init): Make char16_t and char32_t unsigned.
11826
ab0538b8
AH
118272017-04-12 Alan Hayward <alan.hayward@arm.com>
11828
5e0e0422 11829 * m32r-tdep.c (M32R_ARG_REGISTER_SIZE): Added.
ab0538b8
AH
11830 (m32r_push_dummy_call): Use M32R_ARG_REGISTER_SIZE.
11831
5430098f
SDJ
118322017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11833
11834 * windows-nat.c (windows_create_inferior): Declare 'toexec' as
11835 'const char *'.
11836
7c5ded6a
SDJ
118372017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
11838
11839 * common/common-utils.c (free_vector_argv): New function.
11840 * common/common-utils.h: Include <vector>.
11841 (free_vector_argv): New prototype.
11842 * darwin-nat.c (darwin_create_inferior): Rewrite function
11843 prototype in order to constify "exec_file" and accept a
11844 "std::string" for "allargs".
11845 * fork-child.c: Include <vector>.
11846 (breakup_args): Rewrite function, using C++.
11847 (fork_inferior): Rewrite function header, constify "exec_file_arg"
11848 and accept "std::string" for "allargs". Update the code to
11849 calculate "argv" based on "allargs". Update calls to "exec_fun"
11850 and "execvp".
11851 * gnu-nat.c (gnu_create_inferior): Rewrite function prototype in
11852 order to constify "exec_file" and accept a "std::string" for
11853 "allargs".
11854 * go32-nat.c (go32_create_inferior): Likewise.
11855 * inf-ptrace.c (inf_ptrace_create_inferior): Likewise.
11856 * infcmd.c (run_command_1): Constify "exec_file". Use
11857 "std::string" for inferior arguments.
11858 * inferior.h (fork_inferior): Update prototype.
11859 * linux-nat.c (linux_nat_create_inferior): Rewrite function
11860 prototype in order to constify "exec_file" and accept a
11861 "std::string" for "allargs".
11862 * nto-procfs.c (procfs_create_inferior): Likewise.
11863 * procfs.c (procfs_create_inferior): Likewise.
11864 * remote-sim.c (gdbsim_create_inferior): Likewise.
11865 * remote.c (extended_remote_run): Update code to accept
11866 "std::string" as argument.
11867 (extended_remote_create_inferior): Rewrite function prototype in
11868 order to constify "exec_file" and accept a "std::string" for
11869 "allargs".
11870 * rs6000-nat.c (super_create_inferior): Likewise.
11871 (rs6000_create_inferior): Likewise.
11872 * target.h (struct target_ops) <to_create_inferior>: Likewise.
11873 * windows-nat.c (windows_create_inferior): Likewise.
11874
ae0eee42
PA
118752017-04-11 Pedro Alves <palves@redhat.com>
11876
11877 * thread.c: Fix whitespace throughout.
11878
a6acac06
PR
118792017-04-11 Philipp Rudo <prudo@linux.vnet.ibm.com>
11880
11881 * linux-nat.c (linux_nat_detach): Remove delete_lwp call.
11882
64403bd1
AH
118832017-04-11 Alan Hayward <alan.hayward@arm.com>
11884
11885 * arm-tdep.c (arm_store_return_value): Use FP_REGISTER_SIZE
11886
a5bef50f
SDJ
118872017-04-10 Sergio Durigan Junior <sergiodj@redhat.com>
11888
11889 PR gdb/21364
11890 * osdata.c (info_osdata): Check if 'type' is an empty string
11891 instead of NULL.
11892
9295a5a9
PA
118932017-04-10 Pedro Alves <palves@redhat.com>
11894
11895 * thread.c (add_thread_silent, delete_thread_1, find_thread_ptid)
11896 (ptid_to_global_thread_id, in_thread_list)
11897 (do_captured_list_thread_ids, set_resumed, set_running)
11898 (set_executing, set_stop_requested, finish_thread_state)
11899 (validate_registers_access, can_access_registers_ptid)
11900 (print_thread_info_1, switch_to_thread)
11901 (do_restore_current_thread_cleanup)
11902 (make_cleanup_restore_current_thread, thread_command)
11903 (thread_name_command): Use operator== instead of ptid_equal.
11904
996812e3
PA
119052017-04-10 Pedro Alves <palves@redhat.com>
11906
11907 * thread.c (struct current_thread_cleanup) <next>: Delete field.
11908 (current_thread_cleanup_chain): Delete.
11909 (restore_current_thread_cleanup_dtor)
11910 (make_cleanup_restore_current_thread): Remove references to
11911 current_thread_cleanup_chain.
11912
845b344f
AH
119132017-04-10 Alan Hayward <alan.hayward@arm.com>
11914
11915 * msp430-tdep.c (msp430_pseudo_register_read): Never return
11916 REG_UNKNOWN.
11917
803bdfe4
YQ
119182017-04-10 Yao Qi <yao.qi@linaro.org>
11919
11920 PR gdb/19942
11921 * gdbthread.h (thread_info::deletable): New method.
11922 (thread_info::incref): New method.
11923 (thread_info::decref): New method.
11924 (thread_info::refcount): Move it to private.
11925 * infrun.c (save_stop_context): Call inc_refcount.
11926 (release_stop_context_cleanup): Likewise.
11927 * thread.c (set_thread_exited): New function.
11928 (init_thread_list): Delete "tp" only it is deletable, otherwise
11929 call set_thread_exited.
11930 (delete_thread_1): Call set_thread_exited.
11931 (current_thread_cleanup) <inferior_pid>: Remove.
11932 <thread>: New field.
11933 (restore_current_thread_ptid_changed): Removed.
11934 (do_restore_current_thread_cleanup): Adjust.
11935 (restore_current_thread_cleanup_dtor): Don't call
11936 find_thread_ptid.
11937 (set_thread_refcount): Use dec_refcount.
11938 (make_cleanup_restore_current_thread): Adjust.
11939 (thread_apply_all_command): Call inc_refcount.
11940 (_initialize_thread): Don't call
11941 observer_attach_thread_ptid_changed.
11942
8c25b497
YQ
119432017-04-10 Yao Qi <yao.qi@linaro.org>
11944
11945 * thread.c (delete_thread_1): Hoist code on marking thread as
11946 exited.
11947
8473b447
SM
119482017-04-09 Simon Marchi <simon.marchi@polymtl.ca>
11949
11950 * windows-nat.c (windows_detach): Initialize ptid with
11951 minus_one_ptid.
11952
6670ec13
SM
119532017-04-07 Simon Marchi <simon.marchi@ericsson.com>
11954
11955 * unittests/ptid-selftests.c: Fix erroneous assert messages.
11956
ba2f91bb
AH
119572017-04-07 Alan Hayward <alan.hayward@arm.com>
11958
11959 * bfin-tdep.c (BFIN_MAX_REGISTER_SIZE): Add.
11960 (bfin_pseudo_register_read): Use BFIN_MAX_REGISTER_SIZE.
11961 (bfin_pseudo_register_write): Likewise
11962
436252de
SM
119632017-04-06 Simon Marchi <simon.marchi@ericsson.com>
11964
11965 * common/ptid.h (struct ptid): Change to...
11966 (class ptid_t): ... this.
11967 <ptid_t>: New constructors.
11968 <pid, lwp_p, lwp, tid_p, tid, is_pid, operator==, operator!=,
11969 matches>: New methods.
11970 <make_null, make_minus_one>: New static methods.
11971 <pid>: Rename to...
11972 <m_pid>: ...this.
11973 <lwp>: Rename to...
11974 <m_lwp>: ...this.
11975 <tid>: Rename to...
11976 <m_tid>: ...this.
11977 (ptid_build, ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal,
11978 ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match): Take ptid arguments
11979 as references, move comment to class ptid_t.
11980 * common/ptid.c (null_ptid, minus_one_ptid): Initialize with
11981 ptid_t static methods.
11982 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_tid,
11983 ptid_equal, ptid_is_pid, ptid_lwp_p, ptid_tid_p, ptid_match):
11984 Take ptid arguments as references, implement using ptid_t methods.
11985 * unittests/ptid-selftests.c: New file.
11986 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
11987 unittests/ptid-selftests.c.
11988 (SUBDIR_UNITTESTS_OBS): Add unittests/ptid-selftests.o.
11989
0dedf377
TP
119902017-04-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
11991
11992 * python/python.c (python_run_simple_file): Cast mode literal to
11993 non-const char pointer as expected by PyFile_FromString.
11994
4e9868d4
SM
119952017-04-05 Simon Marchi <simon.marchi@ericsson.com>
11996
11997 * common/ptid.c (ptid_lwp_p, ptid_tid_p): Remove comparison with
11998 minus_one_ptid and null_ptid.
11999
9bf2a700
PA
120002017-04-05 Pedro Alves <palves@redhat.com>
12001
12002 * warning.m4 (build_warnings): Remove -Wno-write-strings.
12003 * configure: Regenerate.
12004
a121b7c1
PA
120052017-04-05 Pedro Alves <palves@redhat.com>
12006
12007 * ada-exp.y (yyerror): Constify.
12008 * ada-lang.c (bound_name, get_selections)
12009 (ada_variant_discrim_type)
12010 (ada_variant_discrim_name, ada_value_struct_elt)
12011 (ada_lookup_struct_elt_type, is_unchecked_variant)
12012 (ada_which_variant_applies, standard_exc, ada_get_next_arg)
12013 (catch_ada_exception_command_split)
12014 (catch_ada_assert_command_split, catch_assert_command)
12015 (ada_op_name): Constify.
12016 * ada-lang.h (ada_yyerror, get_selections)
12017 (ada_variant_discrim_name, ada_value_struct_elt): Constify.
12018 * arc-tdep.c (arc_print_frame_cache): Constify.
12019 * arm-tdep.c (arm_skip_stub): Constify.
12020 * ax-gdb.c (gen_binop, gen_struct_ref_recursive, gen_struct_ref)
12021 (gen_aggregate_elt_ref): Constify.
12022 * bcache.c (print_bcache_statistics): Constify.
12023 * bcache.h (print_bcache_statistics): Constify.
12024 * break-catch-throw.c (catch_exception_command_1):
12025 * breakpoint.c (struct ep_type_description::description):
12026 Constify.
12027 (add_solib_catchpoint): Constify.
12028 (catch_fork_command_1): Add cast.
12029 (add_catch_command): Constify.
12030 * breakpoint.h (add_catch_command, add_solib_catchpoint):
12031 Constify.
12032 * bsd-uthread.c (bsd_uthread_state): Constify.
12033 * buildsym.c (patch_subfile_names): Constify.
12034 * buildsym.h (next_symbol_text_func, patch_subfile_names):
12035 Constify.
12036 * c-exp.y (yyerror): Constify.
12037 (token::oper): Constify.
12038 * c-lang.h (c_yyerror, cp_print_class_member): Constify.
12039 * c-varobj.c (cplus_describe_child): Constify.
12040 * charset.c (find_charset_names): Add cast.
12041 (find_charset_names): Constify array and add const_cast.
12042 * cli/cli-cmds.c (complete_command, cd_command): Constify.
12043 (edit_command): Constify.
12044 * cli/cli-decode.c (lookup_cmd): Constify.
12045 * cli/cli-dump.c (dump_memory_command, dump_value_command):
12046 Constify.
12047 (struct dump_context): Constify.
12048 (add_dump_command, restore_command): Constify.
12049 * cli/cli-script.c (get_command_line): Constify.
12050 * cli/cli-script.h (get_command_line): Constify.
12051 * cli/cli-utils.c (check_for_argument): Constify.
12052 * cli/cli-utils.h (check_for_argument): Constify.
12053 * coff-pe-read.c (struct read_pe_section_data): Constify.
12054 * command.h (lookup_cmd): Constify.
12055 * common/print-utils.c (decimal2str): Constify.
12056 * completer.c (gdb_print_filename): Constify.
12057 * corefile.c (set_gnutarget): Constify.
12058 * cp-name-parser.y (yyerror): Constify.
12059 * cp-valprint.c (cp_print_class_member): Constify.
12060 * cris-tdep.c (cris_register_name, crisv32_register_name):
12061 Constify.
12062 * d-exp.y (yyerror): Constify.
12063 (struct token::oper): Constify.
12064 * d-lang.h (d_yyerror): Constify.
12065 * dbxread.c (struct header_file_location::name): Constify.
12066 (add_old_header_file, add_new_header_file, last_function_name)
12067 (dbx_next_symbol_text, add_bincl_to_list)
12068 (find_corresponding_bincl_psymtab, set_namestring)
12069 (find_stab_function_addr, read_dbx_symtab, start_psymtab)
12070 (dbx_end_psymtab, read_ofile_symtab, process_one_symbol):
12071 * defs.h (command_line_input, print_address_symbolic)
12072 (deprecated_readline_begin_hook): Constify.
12073 * dwarf2read.c (anonymous_struct_prefix, dwarf_bool_name):
12074 Constify.
12075 * event-top.c (handle_line_of_input): Constify and add cast.
12076 * exceptions.c (catch_errors): Constify.
12077 * exceptions.h (catch_errors): Constify.
12078 * expprint.c (print_subexp_standard, op_string, op_name)
12079 (op_name_standard, dump_raw_expression, dump_raw_expression):
12080 * expression.h (op_name, op_string, dump_raw_expression):
12081 Constify.
12082 * f-exp.y (yyerror): Constify.
12083 (struct token::oper): Constify.
12084 (struct f77_boolean_val::name): Constify.
12085 * f-lang.c (f_word_break_characters): Constify.
12086 * f-lang.h (f_yyerror): Constify.
12087 * fork-child.c (fork_inferior): Add cast.
12088 * frv-tdep.c (struct gdbarch_tdep::register_names): Constify.
12089 (new_variant): Constify.
12090 * gdbarch.sh (pstring_ptr, pstring_list): Constify.
12091 * gdbarch.c: Regenerate.
12092 * gdbcore.h (set_gnutarget): Constify.
12093 * go-exp.y (yyerror): Constify.
12094 (token::oper): Constify.
12095 * go-lang.h (go_yyerror): Constify.
12096 * go32-nat.c (go32_sysinfo): Constify.
12097 * guile/scm-breakpoint.c (gdbscm_breakpoint_expression): Constify.
12098 * guile/scm-cmd.c (cmdscm_function): Constify.
12099 * guile/scm-param.c (pascm_param_value): Constify.
12100 * h8300-tdep.c (h8300_register_name, h8300s_register_name)
12101 (h8300sx_register_name): Constify.
12102 * hppa-tdep.c (hppa32_register_name, hppa64_register_name):
12103 Constify.
12104 * ia64-tdep.c (ia64_register_names): Constify.
12105 * infcmd.c (construct_inferior_arguments): Constify.
12106 (path_command, attach_post_wait): Constify.
12107 * language.c (show_range_command, show_case_command)
12108 (unk_lang_error): Constify.
12109 * language.h (language_defn::la_error)
12110 (language_defn::la_name_of_this): Constify.
12111 * linespec.c (decode_line_2): Constify.
12112 * linux-thread-db.c (thread_db_err_str): Constify.
12113 * lm32-tdep.c (lm32_register_name): Constify.
12114 * m2-exp.y (yyerror): Constify.
12115 * m2-lang.h (m2_yyerror): Constify.
12116 * m32r-tdep.c (m32r_register_names): Constify and make static.
12117 * m68hc11-tdep.c (m68hc11_register_names): Constify.
12118 * m88k-tdep.c (m88k_register_name): Constify.
12119 * macroexp.c (appendmem): Constify.
12120 * mdebugread.c (fdr_name, add_data_symbol, parse_type)
12121 (upgrade_type, parse_external, parse_partial_symbols)
12122 (mdebug_next_symbol_text, cross_ref, mylookup_symbol, new_psymtab)
12123 (new_symbol): Constify.
12124 * memattr.c (mem_info_command): Constify.
12125 * mep-tdep.c (register_name_from_keyword): Constify.
12126 * mi/mi-cmd-env.c (mi_cmd_env_path, _initialize_mi_cmd_env):
12127 Constify.
12128 * mi/mi-cmd-stack.c (list_args_or_locals): Constify.
12129 * mi/mi-cmd-var.c (mi_cmd_var_show_attributes): Constify.
12130 * mi/mi-main.c (captured_mi_execute_command): Constify and add
12131 cast.
12132 (mi_execute_async_cli_command): Constify.
12133 * mips-tdep.c (mips_register_name): Constify.
12134 * mn10300-tdep.c (register_name, mn10300_generic_register_name)
12135 (am33_register_name, am33_2_register_name)
12136 * moxie-tdep.c (moxie_register_names): Constify.
12137 * nat/linux-osdata.c (osdata_type): Constify fields.
12138 * nto-tdep.c (nto_parse_redirection): Constify.
12139 * objc-lang.c (lookup_struct_typedef, lookup_objc_class)
12140 (lookup_child_selector): Constify.
12141 (objc_methcall::name): Constify.
12142 * objc-lang.h (lookup_objc_class, lookup_child_selector)
12143 (lookup_struct_typedef): Constify.
12144 * objfiles.c (pc_in_section): Constify.
12145 * objfiles.h (pc_in_section): Constify.
12146 * p-exp.y (struct token::oper): Constify.
12147 (yyerror): Constify.
12148 * p-lang.h (pascal_yyerror): Constify.
12149 * parser-defs.h (op_name_standard): Constify.
12150 (op_print::string): Constify.
12151 (exp_descriptor::op_name): Constify.
12152 * printcmd.c (print_address_symbolic): Constify.
12153 * psymtab.c (print_partial_symbols): Constify.
12154 * python/py-breakpoint.c (stop_func): Constify.
12155 (bppy_get_expression): Constify.
12156 * python/py-cmd.c (cmdpy_completer::name): Constify.
12157 (cmdpy_function): Constify.
12158 * python/py-event.c (evpy_add_attribute)
12159 (gdbpy_initialize_event_generic): Constify.
12160 * python/py-event.h (evpy_add_attribute)
12161 (gdbpy_initialize_event_generic): Constify.
12162 * python/py-evts.c (add_new_registry): Constify.
12163 * python/py-finishbreakpoint.c (outofscope_func): Constify.
12164 * python/py-framefilter.c (get_py_iter_from_func): Constify.
12165 * python/py-inferior.c (get_buffer): Add cast.
12166 * python/py-param.c (parm_constant::name): Constify.
12167 * python/py-unwind.c (fprint_frame_id): Constify.
12168 * python/python.c (gdbpy_parameter_value): Constify.
12169 * remote-fileio.c (remote_fio_func_map): Make 'name' const.
12170 * remote.c (memory_packet_config::name): Constify.
12171 (show_packet_config_cmd, remote_write_bytes)
12172 (remote_buffer_add_string):
12173 * reverse.c (exec_reverse_once): Constify.
12174 * rs6000-tdep.c (variant::name, variant::description): Constify.
12175 * rust-exp.y (rustyyerror): Constify.
12176 * rust-lang.c (rust_op_name): Constify.
12177 * rust-lang.h (rustyyerror): Constify.
12178 * serial.h (serial_ops::name): Constify.
12179 * sh-tdep.c (sh_sh_register_name, sh_sh3_register_name)
12180 (sh_sh3e_register_name, sh_sh2e_register_name)
12181 (sh_sh2a_register_name, sh_sh2a_nofpu_register_name)
12182 (sh_sh_dsp_register_name, sh_sh3_dsp_register_name)
12183 (sh_sh4_register_name, sh_sh4_nofpu_register_name)
12184 (sh_sh4al_dsp_register_name): Constify.
12185 * sh64-tdep.c (sh64_register_name): Constify.
12186 * solib-darwin.c (lookup_symbol_from_bfd): Constify.
12187 * spu-tdep.c (spu_register_name, info_spu_dma_cmdlist): Constify.
12188 * stabsread.c (patch_block_stabs, read_type_number)
12189 (ref_map::stabs, ref_add, process_reference)
12190 (symbol_reference_defined, define_symbol, define_symbol)
12191 (error_type, read_type, read_member_functions, read_cpp_abbrev)
12192 (read_one_struct_field, read_struct_fields, read_baseclasses)
12193 (read_tilde_fields, read_struct_type, read_array_type)
12194 (read_enum_type, read_sun_builtin_type, read_sun_floating_type)
12195 (read_huge_number, read_range_type, read_args, common_block_start)
12196 (find_name_end): Constify.
12197 * stabsread.h (common_block_start, define_symbol)
12198 (process_one_symbol, symbol_reference_defined, ref_add):
12199 * symfile.c (get_section_index, add_symbol_file_command):
12200 * symfile.h (get_section_index): Constify.
12201 * target-descriptions.c (tdesc_type::name): Constify.
12202 (tdesc_free_type): Add cast.
12203 * target.c (find_default_run_target):
12204 (add_deprecated_target_alias, find_default_run_target)
12205 (target_announce_detach): Constify.
12206 (do_option): Constify.
12207 * target.h (add_deprecated_target_alias): Constify.
12208 * thread.c (print_thread_info_1): Constify.
12209 * top.c (deprecated_readline_begin_hook, command_line_input):
12210 Constify.
12211 (init_main): Add casts.
12212 * top.h (handle_line_of_input): Constify.
12213 * tracefile-tfile.c (tfile_write_uploaded_tsv): Constify.
12214 * tracepoint.c (tvariables_info_1, trace_status_mi): Constify.
12215 (tfind_command): Rename to ...
12216 (tfind_command_1): ... this and constify.
12217 (tfind_command): New function.
12218 (tfind_end_command, tfind_start_command): Adjust.
12219 (encode_source_string): Constify.
12220 * tracepoint.h (encode_source_string): Constify.
12221 * tui/tui-data.c (tui_partial_win_by_name): Constify.
12222 * tui/tui-data.h (tui_partial_win_by_name): Constify.
12223 * tui/tui-source.c (tui_set_source_content_nil): Constify.
12224 * tui/tui-source.h (tui_set_source_content_nil): Constify.
12225 * tui/tui-win.c (parse_scrolling_args): Constify.
12226 * tui/tui-windata.c (tui_erase_data_content): Constify.
12227 * tui/tui-windata.h (tui_erase_data_content): Constify.
12228 * tui/tui-winsource.c (tui_erase_source_content): Constify.
12229 * tui/tui.c (tui_enable): Add cast.
12230 * utils.c (defaulted_query): Constify.
12231 (init_page_info): Add cast.
12232 (puts_debug, subset_compare): Constify.
12233 * utils.h (subset_compare): Constify.
12234 * varobj.c (varobj_format_string): Constify.
12235 * varobj.h (varobj_format_string): Constify.
12236 * vax-tdep.c (vax_register_name): Constify.
12237 * windows-nat.c (windows_detach): Constify.
12238 * xcoffread.c (process_linenos, xcoff_next_symbol_text): Constify.
12239 * xml-support.c (gdb_xml_end_element): Constify.
12240 * xml-tdesc.c (tdesc_start_reg): Constify.
12241 * xstormy16-tdep.c (xstormy16_register_name): Constify.
12242 * xtensa-tdep.c (xtensa_find_register_by_name): Constify.
12243 * xtensa-tdep.h (xtensa_register_t::name): Constify.
12244
995816ba
PA
122452017-04-05 Pedro Alves <palves@redhat.com>
12246
12247 * proc-api.c (struct trans): Constify.
12248 (procfs_note): Constify.
12249 * proc-events.c (struct trans, syscall_table):
12250 * proc-flags.c (struct trans): Constify.
12251 * proc-utils.h (procfs_note): Constify.
12252 * proc-why.c (struct trans): Constify.
12253 * procfs.c (dead_procinfo, find_syscall, proc_warn, proc_error)
12254 (procfs_detach): Constify.
12255 * sol-thread.c (struct string_map): Constify.
12256 (td_err_string, td_state_string): Constify.
12257
3e83a920
PA
122582017-04-05 Pedro Alves <palves@redhat.com>
12259
12260 * proc-api.c (procfs_filename): Don't initialize
12261 procfs_filename.
12262 (prepare_to_trace): Assume procfs_filename is non-NULL.
12263 (_initialize_proc_api): Give procfs_filename a default value here.
12264
63160a43
PA
122652017-04-05 Pedro Alves <palves@redhat.com>
12266
12267 * break-catch-throw.c (handle_gnu_v3_exceptions): Constify
12268 'cond_string' parameter.
12269 (extract_exception_regexp): Constify 'string' parameter.
12270 (catch_exception_command_1): Constify.
12271 * breakpoint.c (init_catchpoint)
12272 (create_fork_vfork_event_catchpoint): Constify 'cond_string'
12273 parameter.
12274 (ep_parse_optional_if_clause, catch_fork_command_1)
12275 (catch_exec_command_1): Constify.
12276 * breakpoint.h (init_catchpoint): Constify 'cond_string'
12277 parameter.
12278 (ep_parse_optional_if_clause): Constify.
12279 * cli/cli-utils.c (remove_trailing_whitespace)
12280 (check_for_argument): Constify.
12281 * cli/cli-utils.h (remove_trailing_whitespace): Constify and add
12282 non-const overload.
12283 (check_for_argument): Likewise.
12284
9b2eba3d
PA
122852017-04-05 Pedro Alves <palves@redhat.com>
12286
12287 * event-top.c (command_line_handler): Add cast to execute_command
12288 call.
12289 * record-btrace.c (cmd_record_btrace_bts_start)
12290 (cmd_record_btrace_pt_start, cmd_record_btrace_start)
12291 (cmd_record_btrace_start): Add cast to execute_command call.
12292 * record-full.c (record_full_goto_insn):
12293 * record.c (record_start, record_stop): Add cast to
12294 execute_command_to_string calls.
12295 (cmd_record_start): Add cast to execute_command calls.
12296
2adadf51
PA
122972017-04-05 Pedro Alves <palves@redhat.com>
12298
12299 * python/python-internal.h (gdb_PyArg_ParseTupleAndKeywords): New
12300 static inline function.
12301 * python/py-arch.c (archpy_disassemble): Constify 'keywords'
12302 array and use gdb_PyArg_ParseTupleAndKeywords.
12303 * python/py-cmd.c (cmdpy_init): Likewise.
12304 * python/py-finishbreakpoint.c (bpfinishpy_init): Likewise.
12305 * python/py-inferior.c (infpy_read_memory, infpy_write_memory)
12306 (infpy_search_memory): Likewise.
12307 * python/py-objfile.c (objfpy_add_separate_debug_file)
12308 (gdbpy_lookup_objfile): Likewise.
12309 * python/py-symbol.c (gdbpy_lookup_symbol)
12310 (gdbpy_lookup_global_symbol): Likewise.
12311 * python/py-type.c (gdbpy_lookup_type): Likewise.
12312 * python/py-value.c (valpy_lazy_string, valpy_string): Likewise.
12313 * python/python.c (execute_gdb_command, gdbpy_write, gdbpy_flush):
12314 Likewise.
12315
0d1f4ceb
PA
123162017-04-05 Pedro Alves <palves@redhat.com>
12317
12318 * python/python-internal.h (gdb_PyGetSetDef): New type.
12319 * python/py-block.c (block_object_getset)
12320 (breakpoint_object_getset): Now a gdb_PyGetSetDef array.
12321 * python/py-event.c (event_object_getset)
12322 (finish_breakpoint_object_getset): Likewise.
12323 * python/py-inferior.c (inferior_object_getset): Likewise.
12324 * python/py-infthread.c (thread_object_getset): Likewise.
12325 * python/py-lazy-string.c (lazy_string_object_getset): Likewise.
12326 * python/py-linetable.c (linetable_entry_object_getset): Likewise.
12327 * python/py-objfile.c (objfile_getset): Likewise.
12328 * python/py-progspace.c (pspace_getset): Likewise.
12329 * python/py-record-btrace.c (btpy_insn_getset, btpy_call_getset):
12330 Likewise.
12331 * python/py-record.c (recpy_record_getset): Likewise.
12332 * python/py-symbol.c (symbol_object_getset): Likewise.
12333 * python/py-symtab.c (symtab_object_getset, sal_object_getset):
12334 Likewise.
12335 * python/py-type.c (type_object_getset, field_object_getset):
12336 Likewise.
12337 * python/py-value.c (value_object_getset): Likewise.
12338
4d759979
PA
123392017-04-05 Pedro Alves <palves@redhat.com>
12340
12341 * python/python-internal.h (gdb_PyObject_CallMethod)
12342 (gdb_PyErr_NewException, gdb_PySys_GetObject, gdb_PySys_SetPath):
12343 New functions.
12344 (GDB_PYSYS_SETPATH_CHAR, PyObject_CallMethod, PyErr_NewException)
12345 (PySys_GetObject, PySys_SetPath): New macros.
12346
fdf9e36f
PA
123472017-04-05 Pedro Alves <palves@redhat.com>
12348
12349 * mi/mi-cmd-info.c (mi_cmd_info_os): Call info_osdata instead of
12350 info_osdata_command.
12351 * osdata.c (info_osdata_command): Rename to ...
12352 (info_osdata): ... this. Constify 'type' parameter, and remove
12353 the 'from_tty' parameter. Accept NULL TYPE.
12354 (info_osdata_command): New function.
12355 * osdata.h (info_osdata_command): Remove declaration.
12356 (info_osdata): New declaration.
12357
9f33b8b7
PA
123582017-04-05 Pedro Alves <palves@redhat.com>
12359
12360 * mi/mi-cmd-break.c (mi_cmd_break_insert_1, mi_cmd_break_insert)
12361 (mi_cmd_dprintf_insert, mi_cmd_break_passcount)
12362 (mi_cmd_break_watch, mi_cmd_break_commands): Constify 'command'
12363 parameter.
12364 * mi/mi-cmd-catch.c (mi_cmd_catch_assert, mi_cmd_catch_exception)
12365 (mi_cmd_catch_load, mi_cmd_catch_unload): Constify cmd' parameter.
12366 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Constify 'command'
12367 parameter.
12368 * mi/mi-cmd-env.c (mi_cmd_env_pwd, mi_cmd_env_cd, mi_cmd_env_path)
12369 (mi_cmd_env_dir, mi_cmd_inferior_tty_set, _cmd_inferior_tty_show)
12370 * mi/mi-cmd-file.c (mi_cmd_file_list_exec_source_file)
12371 (mi_cmd_file_list_exec_source_files)
12372 (mi_cmd_file_list_shared_libraries): Constify 'command' parameter.
12373 * mi/mi-cmd-info.c (mi_cmd_info_ada_exceptions)
12374 (mi_cmd_info_gdb_mi_command, mi_cmd_info_os): Constify 'command'
12375 parameter.
12376 * mi/mi-cmd-stack.c (mi_cmd_enable_frame_filters)
12377 (mi_cmd_stack_list_frames, mi_cmd_stack_info_depth)
12378 (mi_cmd_stack_list_locals, mi_cmd_stack_list_args)
12379 (mi_cmd_stack_list_variables, mi_cmd_stack_select_frame)
12380 (mi_cmd_stack_info_frame): Constify 'command' parameter.
12381 * mi/mi-cmd-target.c (mi_cmd_target_file_get)
12382 (mi_cmd_target_file_put, mi_cmd_target_file_delete): Constify
12383 'command' parameter.
12384 * mi/mi-cmd-var.c (mi_cmd_var_create, mi_cmd_var_delete)
12385 (mi_cmd_var_set_format, mi_cmd_var_set_visualizer)
12386 (mi_cmd_var_set_frozen, mi_cmd_var_show_format)
12387 (mi_cmd_var_info_num_children, mi_cmd_var_list_children)
12388 (mi_cmd_var_info_type, mi_cmd_var_info_path_expression)
12389 (mi_cmd_var_info_expression, mi_cmd_var_show_attributes)
12390 (mi_cmd_var_evaluate_expression, mi_cmd_var_assign)
12391 (mi_cmd_var_update, mi_cmd_enable_pretty_printing)
12392 (mi_cmd_var_set_update_range): Constify 'command' parameter.
12393 * mi/mi-cmds.h (mi_cmd_argv_ftype): Constify 'command' parameter.
12394 * mi/mi-interp.c (mi_cmd_interpreter_exec): Constify 'command'
12395 parameter.
12396 * mi/mi-main.c (mi_cmd_gdb_exit, mi_cmd_exec_next)
12397 (mi_cmd_exec_next_instruction, mi_cmd_exec_step)
12398 (mi_cmd_exec_step_instruction, mi_cmd_exec_finish)
12399 (mi_cmd_exec_return ,mi_cmd_exec_jump, mi_cmd_exec_continue)
12400 (mi_cmd_exec_interrupt, mi_cmd_exec_run, mi_cmd_target_detach)
12401 (mi_cmd_target_flash_erase, mi_cmd_thread_select)
12402 (mi_cmd_thread_list_ids, mi_cmd_thread_info)
12403 (mi_cmd_list_thread_groups, mi_cmd_data_list_register_names)
12404 (mi_cmd_data_list_changed_registers)
12405 (mi_cmd_data_write_register_values)
12406 (mi_cmd_data_evaluate_expression, mi_cmd_data_read_memory)
12407 (mi_cmd_data_read_memory_bytes, mi_cmd_data_write_memory)
12408 (mi_cmd_data_write_memory_bytes, mi_cmd_enable_timings)
12409 (mi_cmd_list_features, mi_cmd_list_target_features)
12410 (mi_cmd_add_inferior, mi_cmd_remove_inferior)
12411 (mi_cmd_trace_define_variable, mi_cmd_trace_list_variables)
12412 (mi_cmd_trace_find, mi_cmd_trace_save, mi_cmd_trace_start)
12413 (mi_cmd_trace_status, mi_cmd_trace_stop, mi_cmd_ada_task_info)
12414 (mi_cmd_trace_frame_collected): Constify 'command'
12415 parameter.
12416 * mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Constify
12417 'command' parameter.
12418
67cb5b2d
PA
124192017-04-05 Pedro Alves <palves@redhat.com>
12420
12421 * ada-lang.c (ada_completer_word_break_characters): Now a const
12422 array.
12423 (ada_get_gdb_completer_word_break_characters): Constify.
12424 * completer.c (gdb_completer_command_word_break_characters)
12425 (gdb_completer_file_name_break_characters)
12426 (gdb_completer_quote_characters): Now const arrays.
12427 (get_gdb_completer_quote_characters): Constify.
12428 (set_rl_completer_word_break_characters): New function.
12429 (set_gdb_completion_word_break_characters)
12430 (complete_line_internal): Use it.
12431 * completer.h (get_gdb_completer_quote_characters): Constify.
12432 (set_rl_completer_word_break_characters): Declare.
12433 * f-lang.c (f_word_break_characters): Constify.
12434 * language.c (default_word_break_characters): Constify.
12435 * language.h (language_defn::la_word_break_characters): Constify.
12436 (default_word_break_characters): Constify.
12437 * top.c (init_main): Use set_rl_completer_word_break_characters.
12438
7a114964
PA
124392017-04-05 Pedro Alves <palves@redhat.com>
12440
12441 * aix-thread.c (aix_thread_pid_to_str)
12442 (aix_thread_extra_thread_info): Constify.
12443 * bsd-kvm.c (bsd_kvm_pid_to_str): Constify.
12444 * bsd-uthread.c (bsd_uthread_extra_thread_info)
12445 (bsd_uthread_pid_to_str): Constify.
12446 * corelow.c (core_pid_to_str): Constify.
12447 * darwin-nat.c (darwin_pid_to_str): Constify.
12448 * fbsd-nat.c (fbsd_pid_to_str): Constify.
12449 * fbsd-tdep.c (fbsd_core_pid_to_str, gdbarch_core_pid_to_str):
12450 Constify.
12451 * gnu-nat.c (gnu_pid_to_str): Constify.
12452 * go32-nat.c (go32_pid_to_str): Constify.
12453 * i386-cygwin-tdep.c (i386_windows_core_pid_to_str): Constify.
12454 * inf-ptrace.c (inf_ptrace_pid_to_str): Constify.
12455 * inferior.c (inferior_pid_to_str): Constify.
12456 * linux-nat.c (linux_nat_pid_to_str): Constify.
12457 * linux-tdep.c (linux_core_pid_to_str): Constify.
12458 * linux-thread-db.c (thread_db_pid_to_str)
12459 (thread_db_extra_thread_info): Constify.
12460 * nto-tdep.c (nto_extra_thread_info): Constify.
12461 * nto-tdep.h (nto_extra_thread_info): Constify.
12462 * obsd-nat.c (obsd_pid_to_str): Constify.
12463 * procfs.c (procfs_pid_to_str): Constify.
12464 * ravenscar-thread.c (ravenscar_extra_thread_info)
12465 (ravenscar_pid_to_str): Constify.
12466 * remote-sim.c (gdbsim_pid_to_str): Constify.
12467 * remote.c (remote_threads_extra_info, remote_pid_to_str):
12468 Constify.
12469 * sol-thread.c (solaris_pid_to_str): Constify.
12470 * sol2-tdep.c (sol2_core_pid_to_str): Constify.
12471 * sol2-tdep.h (sol2_core_pid_to_str): Constify.
12472 * target.c (default_pid_to_str, target_pid_to_str)
12473 (normal_pid_to_str, default_pid_to_str): Constify.
12474 * target.h (target_ops::to_pid_to_str)
12475 (target_ops::to_extra_thread_info): Constify.
12476 (target_pid_to_str, normal_pid_to_str): Constify.
12477 * windows-nat.c (windows_pid_to_str): Constify.
12478 * gdbarch.sh (core_pid_to_str): Constify.
12479 * target-delegates.c: Regenerate.
12480 * gdbarch.h, gdbarch.c: Regenerate.
12481
69bbf465
PA
124822017-04-05 Pedro Alves <palves@redhat.com>
12483
12484 * main.c (captured_main_1): Use gdb::unique_xmalloc_ptr to manage
12485 the memory of the temporary warning_pre_print override.
12486 * utils.c (warning_pre_print): Constify.
12487 * utils.h (warning_pre_print): Constify.
12488
be47f9e8
PA
124892017-04-05 Pedro Alves <palves@redhat.com>
12490
12491 * cli/cli-cmds.c (shell_escape): Constify 'arg' parameter.
12492 (shell_command): New function.
12493 (make_command): Use std::string.
12494 (init_cli_cmds): Register shell_command instead of shell_escape.
12495
bde6261a
PA
124962017-04-05 Pedro Alves <palves@redhat.com>
12497
12498 * breakpoint.c (dprintf_function, dprintf_channel): Don't initialize.
12499 * tracepoint.c (default_collect): Don't initialize.
12500
b38ef47f
PA
125012017-04-05 Pedro Alves <palves@redhat.com>
12502
12503 * macroexp.c (macro_buffer::shared): Now a bool.
12504 (init_buffer): Update.
12505 (init_shared_buffer): Constify 'addr' parameter.
12506 (substitute_args, expand, macro_expand, macro_expand_next): Remove
12507 casts.
12508
f995bbe8
PA
125092017-04-05 Pedro Alves <palves@redhat.com>
12510
12511 * arm-tdep.c (show_disassembly_style_sfunc): Constify local.
12512 * disasm.c (set_disassembler_options): Constify local.
12513 * i386-tdep.c (i386_print_insn): Remove cast and FIXME comment.
12514
4a596fe2
SDJ
125152017-04-05 Sergio Durigan Junior <sergiodj@redhat.com>
12516
12517 PR gdb/21352
12518 * tracefile.c (tsave_command): Fix argument parsing for '-r'
12519 option.
12520
2cad08ea
YQ
125212017-04-05 Yao Qi <yao.qi@linaro.org>
12522
12523 * frame.c (frame_unwind_register_unsigned): Call
12524 frame_unwind_register_value.
12525
55a98976
YQ
125262017-04-05 Yao Qi <yao.qi@linaro.org>
12527
12528 * gdb.threads/thread-specific-bp.exp (check_thread_specific_breakpoint):
12529 Use gdb_test_multiple, and don't match anchor.
12530
4ac40124
PA
125312017-04-05 Pedro Alves <palves@redhat.com>
12532
12533 * MAINTAINERS (Global Maintainers): Add Simon Marchi.
12534 (Write After Approval): Remove Simon Marchi.
12535
c053b654
PA
125362017-04-05 Pedro Alves <palves@redhat.com>
12537
12538 * common/gdb_optional.h (optional::optional): Make constexpr and
12539 initialize m_dummy.
12540
4c7bf4f9
JB
125412017-04-04 John Baldwin <jhb@FreeBSD.org>
12542
12543 * amd64-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12544 (amd64fbsd_jmp_buf_reg_offset): Remove.
12545 (amd64fbsd_supply_uthread): Remove function.
12546 (amd64fbsd_collect_uthread): Remove function.
12547 (amd64fbsd_init_abi): Don't set bsd-uthread callbacks.
12548 * configure.tgt (i[34567]86-*-freebsd*): Remove bsd-uthread.o.
12549 (x86_64-*-freebsd*): Remove bsd-uthread.o.
12550 (fbsd-nat.c): Update comment.
12551 * i386-fbsd-tdep.c: Remove "bsd-uthread.h" include.
12552 (i386fbsd_jmp_buf_reg_offset): Remove.
12553 (i386fbsd_supply_uthread): Remove function.
12554 (i386fbsd_collect_uthread): Remove function.
12555 (i386fbsd_init_abi): Don't set bsd-uthread callbacks.
12556
1e1a8bef
JB
125572017-04-04 John Baldwin <jhb@FreeBSD.org>
12558
12559 * Makefile.in (ALL_64_TARGET_OBS): Remove alpha-fbsd-tdep.o.
12560 (ALLDEPFILES): Remove alpha-fbsd-tdep.c
12561 * NEWS: Mention that support for FreeBSD/alpha was removed.
12562 * alpha-fbsd-tdep.c: Delete file.
12563 * config/alpha/fbsd.mh: Delete file.
12564 * configure.host: Delete alpha*-*-freebsd* and
12565 alpha*-*-kfreebsd*-gnu.
12566 * configure.tgt: Delete alpha*-*-freebsd* and
12567 alpha*-*-kfreebsd*-gnu.
12568
49907934
JB
125692017-04-04 John Baldwin <jhb@FreeBSD.org>
12570
12571 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers,
12572 amd64bsd_store_inferior_registers): Use ptid from regcache.
12573
6f77053d
PA
125742017-04-04 Pedro Alves <palves@redhat.com>
12575
12576 * dwarf2read.c (lnp_state_machine): Now a class. Initialize all
12577 data fields, make them private and add "m_" prefixes.
12578 (lnp_state_machine::lnp_state_machine): New ctor.
12579 (record_line, check_line_address, handle_set_discriminator)
12580 (handle_set_address, handle_advance_pc, handle_special_opcode)
12581 (handle_advance_line, handle_set_file, handle_negate_stmt)
12582 (handle_const_add_pc, handle_fixed_advance_pc, handle_copy)
12583 (end_sequence, advance_line): New methods.
12584 (m_gdbarch, m_record_lines_p): New fields.
12585 (lnp_reader_state): Delete.
12586 (dwarf_record_line): Rename to ...
12587 (lnp_state_machine::record_line): ... adjust.
12588 (init_lnp_state_machine): Delete.
12589 (lnp_state_machine::lnp_state_machine): New.
12590 (check_line_address): Rename to ...
12591 (lnp_state_machine::check_line_address): This.
12592 (dwarf_decode_lines_1): Remove reference to "reader_state".
12593 Adjust lnp_state_machine having a non-default ctor. Use bool.
12594 State machine internal state manipulation moved to
12595 lnp_state_machine methods.
12596
9c541725
PA
125972017-04-04 Pedro Alves <palves@redhat.com>
12598
12599 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
12600 unittests/offset-type-selftests.c.
12601 (SUBDIR_UNITTESTS_OBS): Add offset-type-selftests.o.
12602 * common/offset-type.h: New file.
12603 * common/preprocessor.h: New file.
12604 * common/traits.h: New file.
12605 * common/valid-expr.h: New file.
12606 * dwarf2expr.c: Include "common/underlying.h". Adjust to use
12607 sect_offset and cu_offset strong typedefs throughout.
12608 * dwarf2expr.h: Adjust to use sect_offset and cu_offset strong
12609 typedefs throughout.
12610 * dwarf2loc.c: Include "common/underlying.h". Adjust to use
12611 sect_offset and cu_offset strong typedefs throughout.
12612 * dwarf2read.c: Adjust to use sect_offset and cu_offset strong
12613 typedefs throughout.
12614 * gdbtypes.h: Include "common/offset-type.h".
12615 (cu_offset): Now an offset type (strong typedef) instead of a
12616 struct.
12617 (sect_offset): Likewise.
12618 (union call_site_parameter_u): Rename "param_offset" field to
12619 "param_cu_off".
12620 * unittests/offset-type-selftests.c: New file.
12621
ecfb656c
PA
126222017-04-04 Pedro Alves <palves@redhat.com>
12623
12624 * common/underlying.h: New file.
12625 * dwarf2read.c: Include "common/gdb_optional.h" and
12626 "common/underlying.h".
12627 (dir_index, file_name_index): New types.
12628 (file_entry): Use them.
12629 (file_entry::include): Use to_underlying.
12630 (line_header::add_file_name): Use dir_index.
12631 (read_formatted_entries): Use gdb::optional. Read form before
12632 writting to file_entry.
12633 (dwarf_decode_line_header): Use dir_index.
12634 (lnp_state_machine::current_file): Use to_underlying.
12635 (lnp_state_machine::file): Change type to file_name_index.
12636 (dwarf_record_line): Use to_underlying.
12637 (init_lnp_state_machine): Use file_name_index.
12638 (dwarf_decode_lines_1): Use dir_index and file_name_index.
12639
d194f1fe
PA
126402017-04-04 Pedro Alves <palves@redhat.com>
12641
12642 * common/gdb_optional.h (gdb::optiona): Add operator->, operator*,
12643 operator bool, has_value and get methods.
12644
fff8551c
PA
126452017-04-04 Pedro Alves <palves@redhat.com>
12646
12647 * dwarf2read.c (struct file_entry): Add ctors, and initialize all
12648 fields.
12649 (line_header): Initialize all data fields. Change type of
12650 standard_opcode_lengths to std::unique_ptr<unsigned char[]>.
12651 Change type of include_dirs to std::vector<const char *>. Remove
12652 num_include_dirs, include_dirs_size. Change type of file_names to
12653 std::vector<file_entry>. Remove num_file_names, file_names_size.
12654 (line_header::line_header): New.
12655 (line_header::add_include_dir, line_header::add_file_name): New
12656 methods.
12657 (line_header::include_dir_at): Remove NULL check.
12658 (line_header::file_name_at): Add const overload.
12659 (line_header_up): New unique_ptr typedef.
12660 (dw2_get_file_names_reader): Use line_header_up. Adjust to use
12661 std::vector. Remove free_line_header call.
12662 (dwarf2_build_include_psymtabs): Use line_header_up. Remove
12663 free_line_header call.
12664 (free_cu_line_header): Delete.
12665 (handle_DW_AT_stmt_list, handle_DW_AT_stmt_list)
12666 (setup_type_unit_groups): Use line_header_up instead of cleanups.
12667 Adjust to use std::vector.
12668 (free_line_header): Delete.
12669 (free_line_header_voidp): Use delete.
12670 (add_include_dir): Replace with ...
12671 (line_header::add_include_dir): ... this method. Use std::vector.
12672 (add_file_name): Replace with ...
12673 (line_header::add_file_name): ... this method. Use std::vector.
12674 (add_include_dir_stub): Delete.
12675 (read_formatted_entries): Remove memset.
12676 (dwarf_decode_line_header): Return a line_header_up instead of a
12677 raw pointer. Remove cleanup handling. Pass lambdas to
12678 read_formatted_entries. Adjust to use line_header methods.
12679 (dwarf_decode_lines_1): Adjust to use line_header methods.
12680 (dwarf_decode_lines, file_file_name, file_full_name): Adjust to
12681 use std::vector.
12682
d62a8ae2
SM
126832017-04-04 Simon Marchi <simon.marchi@polymtl.ca>
12684
12685 * remote.c (set_general_thread, set_continue_thread): Use ptid_t
12686 instead of struct ptid.
12687
db3a1dc7
AH
126882017-05-04 Alan Hayward <alan.hayward@arm.com>
12689
12690 * frame.c (get_frame_register_bytes): Unwind using value.
12691 (put_frame_register_bytes): Likewise.
12692
b1b45502
IB
126932017-03-30 Iain Buclaw <ibuclaw@gdcproject.org>
12694
12695 * d-exp.y (type_aggregate_p): Treat TYPE_CODE_MODULE as being
12696 aggregate-like.
12697
ec13808e
JK
126982017-03-29 Jan Kratochvil <jan.kratochvil@redhat.com>
12699
12700 * auto-load.c (auto_load_section_scripts): Check SEC_HAS_CONTENTS.
12701
12316564
YQ
127022017-03-29 Yao Qi <yao.qi@linaro.org>
12703
12704 * gdbthread.h (struct thread_info): Declare constructor and
12705 destructor. Add some in-class member initializers.
12706 * thread.c (free_thread): Remove.
12707 (init_thread_list): Call delete instead of free_thread.
12708 (new_thread): Call thread_info constructor.
12709 (thread_info::thread_info): New function.
12710 (thread_info::~thread_info): New function.
12711 (delete_thread_1): Call delete instead of free_thread.
12712 (make_cleanup_restore_current_thread): Move tp and frame to
12713 inner block.
12714
fe5f7374
AK
127152017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12716
12717 * arc-tdep.c (arc_frame_cache): Add support for prologue analysis.
12718 (arc_skip_prologue): Likewise.
12719 (arc_make_frame_cache): Likewise.
12720 (arc_pv_get_operand): New function.
12721 (arc_is_in_prologue): Likewise.
12722 (arc_analyze_prologue): Likewise.
12723 (arc_print_frame_cache): Likewise.
12724 (MAX_PROLOGUE_LENGTH): New constant.
12725
eea78757
AK
127262017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12727
12728 * configure.tgt: Add arc-insn.o.
12729 * arc-tdep.c (arc_delayed_print_insn): Make non-static.
12730 (dump_arc_instruction_command): New function.
12731 (arc_fprintf_disasm): Likewise.
12732 (arc_disassemble_info): Likewise.
12733 (arc_insn_get_operand_value): Likewise.
12734 (arc_insn_get_operand_value_signed): Likewise.
12735 (arc_insn_get_memory_base_reg): Likewise.
12736 (arc_insn_get_memory_offset): Likewise.
12737 (arc_insn_get_branch_target): Likewise.
12738 (arc_insn_dump): Likewise.
12739 (arc_insn_get_linear_next_pc): Likewise.
12740 * arc-tdep.h (arc_delayed_print_insn): Add function declaration.
12741 (arc_disassemble_info): Likewise.
12742 (arc_insn_get_branch_target): Likewise.
12743 (arc_insn_get_linear_next_pc): Likewise.
12744 * NEWS: Mention new "maint print arc arc-instruction".
12745
3be78afd
AK
127462017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12747
12748 * arc-tdep (maintenance_print_arc_list): New variable.
12749 (maintenance_print_arc_command): New function.
12750
296ec4fa
AK
127512017-03-28 Anton Kolesov <anton.kolesov@synopsys.com>
12752
12753 * arc-tdep.c (core_v2_register_names, core_arcompact_register_names)
12754 Add "limm" and "reserved".
12755 (arc_cannot_fetch_register, arc_cannot_store_register): Add
12756 ARC_RESERVED_REGNUM and ARC_LIMM_REGNUM.
12757 * arc-tdep.h (arc_regnum): Likewise.
12758
f74f865e
MF
127592017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12760
12761 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12762 for THREADPTR register.
12763 (supply_gregset_reg): Call regcache_raw_supply for THREADPTR
12764 register.
12765 * xtensa-tdep.c (XTENSA_DBREGN_UREG): New definition.
12766 (xtensa_derive_tdep): Initialize tdep->threadptr_regnum.
12767 * xtensa-tdep.h (gdbarch_tdep::threadptr_regnum): New field.
12768
0d0bf81a
MF
127692017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12770
12771 * xtensa-tdep.c (xtensa_pseudo_register_read): Treat all
12772 registers above gdbarch_num_regs (gdbarch) as privileged in
12773 call0 ABI.
12774
0ce4291e
MF
127752017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12776
12777 * xtensa-linux-nat.c (fill_gregset): Call regcache_raw_collect
12778 for a single specified register or for all registers in
12779 a0_base..a0_base + C0_NREGS range.
12780 (supply_gregset_reg): Call regcache_raw_supply for a single
12781 specified register or for all registers in a0_base..a0_base +
12782 C0_NREGS range.
12783
c56054f9
MF
127842017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12785
12786 * arch/xtensa.h (C0_NREGS): Add definition.
12787 * xtensa-tdep.c (C0_NREGS): Remove definition.
12788
a4398628
MF
127892017-03-27 Max Filippov <jcmvbkbc@gmail.com>
12790
12791 * xtensa-tdep.c (xtensa_scan_prologue, call0_analyze_prologue):
12792 Drop xtensa_default_isa initialization.
12793 (xtensa_gdbarch_init): Initialize xtensa_default_isa.
12794
8c43009f
PA
127952017-03-27 Pedro Alves <palves@redhat.com>
12796
12797 * dwarf2read.c (file_entry) <dir_index>: Add comment.
12798 (file_entry::include_dir): New method.
12799 (line_header::include_dir_at, line_header::file_name_at): New
12800 methods.
12801 (setup_type_unit_groups, setup_type_unit_groups)
12802 (psymtab_include_file_name): Simplify using the new methods.
12803 (lnp_state_machine) <the_line_header>: New field.
12804 <file>: Add comment.
12805 (lnp_state_machine::current_file): New method.
12806 (dwarf_record_line): Simplify using the new methods.
12807 (init_lnp_state_machine): Initialize the "the_line_header" field.
12808 (dwarf_decode_lines_1, dwarf_decode_lines, file_file_name):
12809 Simplify using the new methods.
12810
a7e80b9e
PA
128112017-03-27 Pedro Alves <palves@redhat.com>
12812
12813 * cp-name-parser.y (make_empty): Delete.
12814 (demangler_special, nested_name, ptr_operator, array_indicator)
12815 (direct_declarator, declarator_1): Use fill_comp instead of
12816 make_empty.
12817
21047726
PA
128182017-03-27 Pedro Alves <palves@redhat.com>
12819
12820 * xml-support.h (gdb_xml_debug): Pass a "first-to-check" argument
12821 to ATTRIBUTE_PRINTF.
12822 * solib-target.c (library_list_start_list): Print "string" not
12823 "version".
12824 * xml-tdesc.c (tdesc_start_field): Pass "field_name" to
12825 gdb_xml_error call.
12826
d721ba37
PA
128272017-03-27 Pedro Alves <palves@redhat.com>
12828
12829 * dwarf2read.c (struct file_and_directory): New.
12830 (dwarf2_get_dwz_file): Adjust to use std::string.
12831 (dw2_get_file_names_reader): Adjust to use file_and_directory.
12832 (find_file_and_directory): Adjust to return a file_and_directory
12833 object.
12834 (read_file_scope): Adjust to use file_and_directory. Remove
12835 make_cleanup/do_cleanups calls.
12836 (open_and_init_dwp_file): Adjust to use std::string. Remove
12837 make_cleanup/do_cleanups calls.
12838 * python/python.c (do_start_initialization): Adjust to ldirname
12839 returning a std::string.
12840 * utils.c (ldirname): Now returns a std::string.
12841 * utils.h (ldirname): Change return type to std::string.
12842 * xml-syscall.c (xml_init_syscalls_info): Adjust to ldirname
12843 returning a std::string.
12844 * xml-tdesc.c (file_read_description_xml): Likewise.
12845
ed771251
AH
128462017-03-24 Alan Hayward <alan.hayward@arm.com>
12847
12848 * regcache.c (regcache_debug_print_register): New function.
12849 * regcache.h (regcache_debug_print_register): New declaration.
12850 * target.c (debug_print_register): Remove.
12851 (target_fetch_registers): Call regcache_debug_print_register.
12852 (target_store_registers): Likewise.
12853
568c1b9f
PB
128542017-03-24 Pádraig Brady <pbrady@fb.com>
12855
12856 * dwarf2read.c (setup_type_unit_groups): Ensure dir_index doesn't
12857 reference beyond the 'lh->include_dirs' array before accessing to
12858 it.
12859 (psymtab_include_file_name): Likewise.
12860 (dwarf_decode_lines_1): Likewise.
12861 (dwarf_decode_lines): Likewise.
12862 (file_file_name): Likewise.
12863
3e00d44f
SM
128642017-03-23 Simon Marchi <simon.marchi@ericsson.com>
12865
12866 * fbsd-tdep.c (fbsd_corefile_thread): Don't set/restore
12867 inferior_ptid.
12868 * proc-service.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12869 ps_lsetfpregs): Likewise.
12870 * regcache.c (regcache_raw_update, regcache_raw_write): Likewise.
12871 * sol-thread.c (ps_lgetregs, ps_lsetregs, ps_lgetfpregs,
12872 ps_lsetfpregs): Likewise.
12873 * target.c (target_fetch_registers, target_store_registers):
12874 Remove asserts.
12875
077ae656
AH
128762017-03-23 Alan Hayward <alan.hayward@arm.com>
12877
12878 * sol-thread.c (sol_thread_store_registers): Remove regcache calls.
12879
1e2b521d
YQ
128802017-03-23 Yao Qi <yao.qi@linaro.org>
12881
12882 * aarch64-tdep.c (aarch64_process_record_test): Declare.
12883 (_initialize_aarch64_tdep): Register it.
12884 (aarch64_record_load_store): Handle PRFM instruction.
12885 (aarch64_process_record_test): New function.
12886
33877125
YQ
128872017-03-23 Yao Qi <yao.qi@linaro.org>
12888
12889 * aarch64-tdep.c (aarch64_record_load_store): Fix code
12890 indentation.
12891
a0eef940
YQ
128922017-03-23 Yao Qi <yao.qi@linaro.org>
12893
12894 * aarch64-tdep.c: Remove AARCH64_RECORD_FAILURE.
12895
3f2a3564
PR
128962017-03-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
12897
12898 python/python.c (do_start_initialization): Fix memory leak.
12899
b67aeab0
SM
129002017-03-22 Simon Marchi <simon.marchi@polymtl.ca>
12901
12902 * inf-ptrace.c (inf_ptrace_xfer_partial): Get pid from ptid
12903 using get_ptrace_pid.
12904 * linux-nat.c (linux_nat_xfer_partial): Don't set/restore
12905 inferior_ptid.
12906 (linux_proc_xfer_partial, linux_proc_xfer_spu): Use lwp of
12907 inferior_ptid instead of pid.
12908
ffdbe864
YQ
129092017-03-22 Yao Qi <yao.qi@linaro.org>
12910
12911 * aarch64-tdep.c: Wrap locally used classes in anonymous
12912 namespace.
12913 * arm-tdep.c: Likewise.
12914 * linespec.c: Likewise.
12915 * ui-out.c: Likewise.
12916
9d736fbf
JG
129172017-03-22 Jonah Graham <jonah@kichwacoders.com>
12918
12919 PR gdb/19637
12920 * python/lib/gdb/printer/bound_registers.py: Import sys.
12921
3de88e9a
SM
129222017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12923
12924 * windows-nat.c (do_windows_fetch_inferior_registers): Add
12925 windows_thread_info parameter and use it instead of
12926 current_thread.
12927 (windows_fetch_inferior_registers): Don't set current_thread,
12928 pass the thread to do_windows_fetch_inferior_registers. Use
12929 ptid from regcache instead of inferior_ptid.
12930 (do_windows_store_inferior_registers): Add windows_thread_info
12931 parameter and use it instead of current_thread.
12932 (windows_store_inferior_registers): Don't set current_thread,
12933 pass the thread to do_windows_store_inferior_registers. Use
12934 ptid from regcache instead of inferior_ptid.
12935
0e7b8f61
SM
129362017-03-21 Simon Marchi <simon.marchi@ericsson.com>
12937
12938 * ser-mingw.c (ser_windows_raw): Remove reference to
12939 struct serial::current_timeout.
12940
5badf10a
IR
129412017-03-21 Ivo Raisr <ivo.raisr@oracle.com>
12942
12943 PR tdep/20928
12944 * gdb/sparc-tdep.h (gdbarch_tdep) <sparc64_ccr_type>: New field.
12945 * gdb/sparc64-tdep.c (sparc64_ccr_type): New function.
12946 (sparc64_fsr_type): Fix %fsr decoding.
12947
cee59b3f
TW
129482017-03-21 Tim Wiederhake <tim.wiederhake@intel.com>
12949
12950 * python/py-record-btrace.c (btpy_insn_data): Change return type
12951 for Python 2.
12952
639a9038
SM
129532017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
12954
12955 * spu-linux-nat.c (spu_fetch_inferior_registers,
12956 spu_store_inferior_registers): Use ptid from regcache, set and
12957 restore inferior_ptid.
12958 * spu-multiarch.c (spu_fetch_registers, spu_store_registers):
12959 Likewise.
12960
bcc0c096
SM
129612017-03-20 Simon Marchi <simon.marchi@polymtl.ca>
12962
12963 * i386-linux-nat.c (fetch_register, store_register,
12964 i386_linux_fetch_inferior_registers,
12965 i386_linux_store_inferior_registers): Use ptid from regcache.
12966 * ia64-linux-nat.c (ia64_linux_fetch_register,
12967 ia64_linux_store_register): Likewise.
12968 * inf-ptrace.c (inf_ptrace_fetch_register,
12969 inf_ptrace_store_register): Likewise.
12970 * m32r-linux-nat.c (m32r_linux_fetch_inferior_registers,
12971 m32r_linux_store_inferior_registers): Likewise.
12972 * m68k-bsd-nat.c (m68kbsd_fetch_inferior_registers,
12973 m68kbsd_store_inferior_registers): Likewise.
12974 * m68k-linux-nat.c (fetch_register, store_register,
12975 m68k_linux_fetch_inferior_registers,
12976 m68k_linux_store_inferior_registers): Likewise.
12977 * m88k-bsd-nat.c (m88kbsd_fetch_inferior_registers,
12978 m88kbsd_store_inferior_registers): Likewise.
12979 * mips-fbsd-nat.c (mips_fbsd_fetch_inferior_registers,
12980 mips_fbsd_store_inferior_registers): Likewise.
12981 * mips-linux-nat.c (mips64_linux_regsets_fetch_registers,
12982 mips64_linux_regsets_store_registers): Likewise.
12983 * mips-nbsd-nat.c (mipsnbsd_fetch_inferior_registers,
12984 mipsnbsd_store_inferior_registers): Likewise.
12985 * mips-obsd-nat.c (mips64obsd_fetch_inferior_registers,
12986 mips64obsd_store_inferior_registers): Likewise.
12987 * nto-procfs.c (procfs_fetch_registers, procfs_store_registers):
12988 Likewise.
12989 * ppc-fbsd-nat.c (ppcfbsd_fetch_inferior_registers,
12990 ppcfbsd_store_inferior_registers): Likewise.
12991 * ppc-linux-nat.c (ppc_linux_fetch_inferior_registers,
12992 ppc_linux_store_inferior_registers): Likewise.
12993 * ppc-nbsd-nat.c (ppcnbsd_fetch_inferior_registers,
12994 ppcnbsd_store_inferior_registers): Likewise.
12995 * ppc-obsd-nat.c (ppcobsd_fetch_registers,
12996 ppcobsd_store_registers): Likewise.
12997 * procfs.c (procfs_fetch_registers, procfs_store_registers):
12998 Likewise.
12999 * ravenscar-thread.c (ravenscar_fetch_registers,
13000 ravenscar_store_registers, ravenscar_prepare_to_store):
13001 Likewise.
13002 * record-btrace.c (record_btrace_fetch_registers,
13003 record_btrace_store_registers, record_btrace_prepare_to_store):
13004 Likewise.
13005 * remote-sim.c (gdbsim_fetch_register, gdbsim_store_register):
13006 Lookup inferior using ptid from regcache, instead of
13007 current_inferior.
13008 * remote.c (remote_fetch_registers, remote_store_registers): Use
13009 ptid from regcache.
13010 * rs6000-nat.c (fetch_register, store_register): Likewise.
13011 * s390-linux-nat.c (s390_linux_fetch_inferior_registers,
13012 s390_linux_store_inferior_registers): Likewise.
13013 * sh-nbsd-nat.c (shnbsd_fetch_inferior_registers,
13014 shnbsd_store_inferior_registers): Likewise.
13015 * sol-thread.c (sol_thread_fetch_registers,
13016 sol_thread_store_registers): Likewise.
13017 * sparc-nat.c (sparc_fetch_inferior_registers,
13018 sparc_store_inferior_registers): Likewise.
13019 * tilegx-linux-nat.c (fetch_inferior_registers,
13020 store_inferior_registers): Likewise.
13021 * vax-bsd-nat.c (vaxbsd_fetch_inferior_registers,
13022 vaxbsd_store_inferior_registers): Likewise.
13023 * xtensa-linux-nat.c (fetch_gregs, store_gregs, fetch_xtregs,
13024 store_xtregs): Likewise.
13025
c0f55cc6
AV
130262017-03-20 Artemiy Volkov <artemiyv@acm.org>
13027
13028 PR gdb/14441
13029 * NEWS: Mention support for rvalue references in GDB and python.
13030 * doc/gdb.texinfo (C Plus Plus Expressions): Mention that GDB
13031 supports both lvalue and rvalue references.
13032
15c0a2a9
AV
130332017-03-20 Artemiy Volkov <artemiyv@acm.org>
13034
13035 PR gdb/14441
13036 * gdbtypes.c (rank_one_type): Implement overloading
13037 resolution rules regarding rvalue references.
13038
aa006118
AV
130392017-03-20 Artemiy Volkov <artemiyv@acm.org>
13040
13041 PR gdb/14441
13042 * aarch64-tdep.c (aarch64_type_align)
13043 (aarch64_extract_return_value, aarch64_store_return_value): Change
13044 lvalue reference type checks to general reference type checks.
13045 * amd64-tdep.c (amd64_classify): Likewise.
13046 * amd64-windows-tdep.c (amd64_windows_passed_by_integer_register):
13047 Likewise.
13048 * arm-tdep.c (arm_type_align, arm_extract_return_value)
13049 (arm_store_return_value): Likewise.
13050 * ax-gdb.c (gen_fetch, gen_cast): Likewise.
13051 * c-typeprint.c (c_print_type): Likewise.
13052 * c-varobj.c (adjust_value_for_child_access, c_value_of_variable)
13053 (cplus_number_of_children, cplus_describe_child): Likewise.
13054 * compile/compile-c-symbols.c (generate_vla_size): Likewise.
13055 * completer.c (expression_completer): Likewise.
13056 * cp-support.c (make_symbol_overload_list_adl_namespace):
13057 Likewise.
13058 * darwin-nat-info.c (info_mach_region_command): Likewise.
13059 * dwarf2loc.c (entry_data_value_coerce_ref)
13060 (value_of_dwarf_reg_entry): Likewise.
13061 * eval.c (ptrmath_type_p, evaluate_subexp_standard)
13062 (evaluate_subexp_for_address, evaluate_subexp_for_sizeof):
13063 Likewise.
13064 * findvar.c (extract_typed_address, store_typed_address):
13065 Likewise.
13066 * gdbtypes.c (rank_one_type): Likewise.
13067 * hppa-tdep.c (hppa64_integral_or_pointer_p): Likewise.
13068 * infcall.c (value_arg_coerce): Likewise.
13069 * language.c (pointer_type): Likewise.
13070 * m32c-tdep.c (m32c_reg_arg_type, m32c_m16c_address_to_pointer):
13071 Likewise.
13072 * m88k-tdep.c (m88k_integral_or_pointer_p): Likewise.
13073 * mn10300-tdep.c (mn10300_type_align): Likewise.
13074 * msp430-tdep.c (msp430_push_dummy_call): Likewise.
13075 * ppc-sysv-tdep.c (do_ppc_sysv_return_value)
13076 (ppc64_sysv_abi_push_param, ppc64_sysv_abi_return_value):
13077 Likewise.
13078 * printcmd.c (print_formatted, x_command): Likewise.
13079 * python/py-type.c (typy_get_composite, typy_template_argument):
13080 Likewise.
13081 * python/py-value.c (valpy_referenced_value)
13082 (valpy_get_dynamic_type, value_has_field): Likewise.
13083 * s390-linux-tdep.c (s390_function_arg_integer): Likewise.
13084 * sparc-tdep.c (sparc_integral_or_pointer_p): Likewise.
13085 * sparc64-tdep.c (sparc64_integral_or_pointer_p): Likewise.
13086 * spu-tdep.c (spu_scalar_value_p): Likewise.
13087 * symtab.c (lookup_symbol_aux): Likewise.
13088 * typeprint.c (whatis_exp, print_type_scalar): Likewise.
13089 * valarith.c (binop_types_user_defined_p, unop_user_defined_p):
13090 Likewise.
13091 * valops.c (value_cast_pointers, value_cast)
13092 (value_reinterpret_cast, value_dynamic_cast, value_addr, typecmp)
13093 (value_struct_elt, value_struct_elt_bitpos)
13094 (value_find_oload_method_list, find_overload_match)
13095 (value_rtti_indirect_type): Likewise.
13096 * valprint.c (val_print_scalar_type_p, generic_val_print):
13097 Likewise.
13098 * value.c (value_actual_type, value_as_address, unpack_long)
13099 (pack_long, pack_unsigned_long, coerce_ref_if_computed)
13100 (coerce_ref): Likewise.
13101 * varobj.c (varobj_get_value_type): Likewise.
13102
3fcf899d
AV
131032017-03-20 Artemiy Volkov <artemiyv@acm.org>
13104
13105 PR gdb/14441
13106 * doc/python.texi (Types in Python): Add TYPE_CODE_RVALUE_REF to
13107 table of constants.
13108 * python/lib/gdb/command/explore.py: Support exploring values
13109 of rvalue reference types.
13110 * python/lib/gdb/types.py: Implement get_basic_type() for
13111 rvalue reference types.
13112 * python/py-type.c (pyty_codes) <TYPE_CODE_RVALUE_REF>: New
13113 constant.
13114 * python/py-value.c (valpy_getitem): Add an rvalue reference
13115 check.
13116 (valpy_reference_value): Add new parameter "refcode".
13117 (valpy_lvalue_reference_value, valpy_rvalue_reference_value):
13118 New wrappers for valpy_reference_value().
13119 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13120 (gdbpy_invoke_xmethod): Likewise.
13121
4297a3f0
AV
131222017-03-20 Artemiy Volkov <artemiyv@acm.org>
13123
13124 PR gdb/14441
13125 * dwarf2read.c (process_die, read_type_die_1): Handle the
13126 DW_TAG_rvalue_reference_type DIE.
13127 (read_tag_reference_type): Add new parameter "refcode".
13128
e1cb3213
AV
131292017-03-20 Artemiy Volkov <artemiyv@acm.org>
13130
13131 PR gdb/14441
13132 * c-typeprint.c (c_print_type, c_type_print_varspec_prefix)
13133 (c_type_print_modifier, c_type_print_varspec_suffix)
13134 (c_type_print_base): Support printing rvalue reference types.
13135 * c-valprint.c (c_val_print, c_value_print): Support printing
13136 rvalue reference values.
13137
e4347c89
AV
131382017-03-20 Artemiy Volkov <artemiyv@acm.org>
13139
13140 PR gdb/14441
13141 * cp-name-parser.y (ptr_operator): Handle the '&&' token in
13142 typename.
13143 * cp-support.c (replace_typedefs): Handle
13144 DEMANGLE_COMPONENT_RVALUE_REFERENCE.
13145 * python/py-type.c (typy_lookup_type): Likewise.
13146
53cc15f5
AV
131472017-03-20 Artemiy Volkov <artemiyv@acm.org>
13148
13149 PR gdb/14441
13150 * c-exp.y (ptr_operator): Handle the '&&' token in the typename.
13151 * parse.c (insert_type): Change assert statement.
13152 (follow_types): Handle rvalue reference types.
13153 * parser-defs.h (enum type_pieces) <tp_rvalue_reference>: New
13154 constant.
13155
a65cfae5
AV
131562017-03-20 Artemiy Volkov <artemiyv@acm.org>
13157
13158 PR gdb/14441
13159 * ada-lang.c (ada_evaluate_subexp): Adhere to the new
13160 value_ref() interface.
13161 * c-valprint.c (c_value_print): Likewise.
13162 * infcall.c (value_arg_coerce): Likewise.
13163 * python/py-value.c (valpy_reference_value): Likewise.
13164 * valops.c (value_cast, value_reinterpret_cast)
13165 (value_dynamic_cast, typecmp): Likewise.
13166 (value_ref): Parameterize by kind of return value reference type.
13167 * value.h (value_ref): Add new parameter "refcode".
13168
3b224330
AV
131692017-03-20 Artemiy Volkov <artemiyv@acm.org>
13170
13171 PR gdb/14441
13172 * dwarf2read.c (read_tag_reference_type): Use
13173 lookup_lvalue_reference_type() instead of lookup_reference_type().
13174 * eval.c (evaluate_subexp_standard): Likewise.
13175 * f-exp.y: Likewise.
13176 * gdbtypes.c (make_reference_type, lookup_reference_type):
13177 Generalize with rvalue reference types.
13178 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): New
13179 convenience wrappers for lookup_reference_type().
13180 * gdbtypes.h (make_reference_type, lookup_reference_type): Add a
13181 reference kind parameter.
13182 (lookup_lvalue_reference_type, lookup_rvalue_reference_type): Add
13183 wrappers for lookup_reference_type().
13184 * guile/scm-type.c (gdbscm_type_reference): Use
13185 lookup_lvalue_reference_type() instead of lookup_reference_type().
13186 * guile/scm-value.c (gdbscm_value_dynamic_type): Likewise.
13187 * parse.c (follow_types): Likewise.
13188 * python/py-type.c (typy_reference, typy_lookup_type): Likewise.
13189 * python/py-value.c (valpy_get_dynamic_type, valpy_getitem):
13190 Likewise.
13191 * python/py-xmethods.c (gdbpy_get_xmethod_result_type)
13192 (gdbpy_invoke_xmethod): Likewise.
13193 * stabsread.c: Provide extra argument to make_reference_type()
13194 call.
13195 * valops.c (value_ref, value_rtti_indirect_type): Use
13196 lookup_lvalue_reference_type() instead of lookup_reference_type().
13197
f9aeb8d4
AV
131982017-03-20 Artemiy Volkov <artemiyv@acm.org>
13199
13200 PR gdb/14441
13201 * gdbtypes.h (enum type_code) <TYPE_CODE_RVALUE_REF>: New constant.
13202 (TYPE_IS_REFERENCE): New macro.
13203 (struct type): Add rvalue_reference_type field.
13204 (TYPE_RVALUE_REFERENCE_TYPE): New macro.
13205
51457a05
MAL
132062017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13207
13208 * NEWS: Add an entry about new '-file-list-shared-libraries' command.
13209 * mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries):
13210 New function definition.
13211 * mi/mi-cmds.c (mi_cmds): Add -file-list-shared-libraries command.
13212 * mi/mi-cmds.h (mi_cmd_file_list_shared_libraries):
13213 New function declaration.
13214 * mi/mi-interp.c (mi_output_solib_attribs): New Function.
13215 * mi/mi-interp.h: New file.
13216 * solib.c (info_sharedlibrary_command): Replace for loop with
13217 ALL_SO_LIBS macro
13218 * solib.h (update_solib_list): New function declaration.
13219 (so_list_head): Move macro.
13220 * solist.h (ALL_SO_LIBS): New macro.
13221
e696b3ad
MAL
132222017-03-20 Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
13223
13224 * infcmd.c (post_create_inferior): Remove unused argument in
13225 call to solib_add.
13226 * remote.c (remote_start_remote): Likewise.
13227 * solib-frv.c (frv_fetch_objfile_link_map): Likewise.
13228 * solib-svr4.c: (svr4_fetch_objfile_link_map): Likewise.
13229 (enable_break): Likewise.
13230 * solib.c (update_solib_list): Remove unused target argument
13231 and its documentation.
13232 (solib_add): Remove unused target argument. Remove unused
13233 argument in call to update_solib_list.
13234 (info_sharedlibrary_command): Remove unused argument in call
13235 to update_solib_list.
13236 (sharedlibrary_command): Remove unused argument in call to
13237 solib_add.
13238 (handle_solib_event): Likewise.
13239 (reload_shared_libraries): Likewise.
13240 * solib.h (solib_add): Remove unused target argument.
13241
dcb84eda
AA
132422017-03-20 Andreas Arnez <arnez@linux.vnet.ibm.com>
13243
13244 * s390-linux-tdep.c (is_rsi, is_rie): Remove functions.
13245 (s390_displaced_step_fixup): Cover relative branches with the
13246 default fixup handling. This fixes lack of support for some
13247 relative branch instructions.
13248
d9cb6cdc
SM
132492017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13250
13251 * i386-gnu-nat.c (gnu_fetch_registers, gnu_store_registers): Use
13252 ptid from regcache.
13253
1afaf9f4
SM
132542017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13255
13256 * i386-darwin-nat.c (i386_darwin_fetch_inferior_registers,
13257 i386_darwin_store_inferior_registers): Use ptid from regcache.
13258
aac12e24
SM
132592017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13260
13261 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers,
13262 i386bsd_store_inferior_registers): Use ptid from regcache.
13263
bbe1eef1
SM
132642017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13265
13266 * hppa-obsd-nat.c (hppaobsd_fetch_registers,
13267 hppaobsd_store_registers): Use ptid from regcache.
13268
10799020
SM
132692017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13270
13271 * hppa-nbsd-nat.c (hppanbsd_fetch_registers,
13272 hppanbsd_store_registers): Use ptid from regcache.
13273
00204cf7
SM
132742017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13275
13276 * hppa-linux-nat.c (fetch_register, store_register): Use ptid
13277 from regcache. Use get_ptrace_pid.
13278
11a33714
SM
132792017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13280
13281 * corelow.c (get_core_register_section): Use ptid from regcache,
13282 update doc.
13283
317cd492
SM
132842017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13285
13286 * bsd-uthread.c (bsd_uthread_fetch_registers,
13287 bsd_uthread_store_registers): Use ptid from regcache, set and
13288 restore inferior_ptid.
13289
9ac8a7c2
SM
132902017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13291
13292 * arm-nbsd-nat.c (fetch_register, fetch_regs, fetch_fp_register,
13293 fetch_fp_regs, store_register, store_regs, store_fp_register,
13294 store_fp_regs): Use ptid from regcache.
13295
4ac4bb6a
SM
132962017-03-17 Simon Marchi <simon.marchi@polymtl.ca>
13297
13298 * arm-linux-nat.c (fetch_fpregs, store_fpregs, fetch_regs,
13299 store_regs, fetch_wmmx_regs, store_wmmx_regs, fetch_vfp_regs,
13300 store_vfp_regs): Use ptid from regcache.
13301
9bcbdca8
PA
133022017-03-17 Pedro Alves <palves@redhat.com>
13303
13304 PR remote/21188
13305 * ser-base.c (ser_base_wait_for): Add comment.
13306 (do_ser_base_readchar): Improve comment based on the ser-unix.c's
13307 version.
13308 * ser-unix.c (hardwire_raw): Remove reference to
13309 scb->current_timeout.
13310 (wait_for, do_hardwire_readchar, hardwire_readchar): Delete.
13311 (hardwire_ops): Install ser_base_readchar instead of
13312 hardwire_readchar.
13313 * serial.h (struct serial) <current_timeout, timeout_remaining>:
13314 Remove fields.
13315
7503099f
JG
133162017-03-17 Jonah Graham <jonah@kichwacoders.com>
13317
13318 PR gdb/19637
13319 * python/lib/gdb/printer/bound_registers.py: Add support for
13320 Python 3.
13321
7942e96e
AA
133222017-03-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
13323
13324 * dwarf2loc.c (indirect_synthetic_pointer): Get data type of
13325 pointed-to DIE and pass it to dwarf2_evaluate_loc_desc_full.
13326 (dwarf2_evaluate_loc_desc_full): New parameter subobj_type; rename
13327 byte_offset to subobj_byte_offset. Fix the handling of
13328 DWARF_VALUE_STACK on big-endian targets when coming via an
13329 implicit pointer.
13330 (dwarf2_evaluate_loc_desc): Adjust call to
13331 dwarf2_evaluate_loc_desc_full.
13332 * dwarf2loc.h (dwarf2_fetch_die_type_sect_off): New declaration.
13333 * dwarf2read.c (dwarf2_fetch_die_type_sect_off): New function.
13334
ba14f379
YQ
133352017-03-16 Yao Qi <yao.qi@linaro.org>
13336
13337 * arm-tdep.c (thumb_record_misc): Decode CBNZ, CBZ, REV16,
13338 and REVSH instructions.
13339
b121eeb9
YQ
133402017-03-16 Yao Qi <yao.qi@linaro.org>
13341
13342 * arm-tdep.c [GDB_SELF_TEST]: include "selftests.h".
13343 (arm_record_test): Declare.
13344 (_initialize_arm_tdep) [GDB_SELF_TEST]: call register_self_test.
13345 (thumb_record_ld_st_reg_offset): Rewrite the opcode matching to
13346 align with the manual.
13347 (thumb_record_misc): Adjust the code order to align with the
13348 manual.
13349 (thumb2_record_decode_insn_handler): Fix instruction matching.
13350 (instruction_reader_thumb): New class.
13351 (arm_record_test): New function.
13352
728a7913
YQ
133532017-03-16 Yao Qi <yao.qi@linaro.org>
13354
13355 * arm-tdep.c (abstract_memory_reader): New class.
13356 (instruction_reader): New class.
13357 (extract_arm_insn): Add argument 'reader'. Callers updated.
13358 (decode_insn): Likewise.
13359
34b43320
DE
133602017-03-16 Doug Evans <dje@google.com>
13361
a7c0469f
DE
13362 * guile/scm-lazy-string.c (lazy_string_smob): Clarify use of LENGTH
13363 member. Change type of TYPE member to SCM. All uses updated.
13364 (lsscm_make_lazy_string_smob): Add assert.
13365 (lsscm_make_lazy_string): Flag bad length values.
13366 (lsscm_elt_type): New function.
13367 (gdbscm_lazy_string_to_value): Rewrite to use
13368 lsscm_safe_lazy_string_to_value.
13369 (lsscm_safe_lazy_string_to_value): Fix handling of TYPE_CODE_PTR.
13370 * guile/scm-value.c (gdbscm_value_to_lazy_string): Flag bad length
13371 values. Fix TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle typedefs
13372 in incoming type.
13373 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13374 * guile/scm-type.c (tyscm_scm_to_type): New function.
13375
133762017-03-15 Doug Evans <dje@google.com>
13377
34b43320
DE
13378 PR python/17728, python/18439, python/18779
13379 * python/py-lazy-string.c (lazy_string_object): Clarify use of LENGTH
13380 member. Change type of TYPE member to PyObject *. All uses updated.
13381 (stpy_convert_to_value): Fix handling of TYPE_CODE_PTR.
13382 (gdbpy_create_lazy_string_object): Flag bad length values.
13383 Handle TYPE_CODE_ARRAY with possibly different user-provided length.
13384 Handle typedefs in incoming type.
13385 (stpy_lazy_string_elt_type): New function.
13386 (gdbpy_extract_lazy_string): Call it.
13387 * python/py-value.c (valpy_lazy_string): Flag bad length values.
13388 Fix handling of TYPE_CODE_PTR. Handle TYPE_CODE_ARRAY. Handle
13389 typedefs in incoming type.
13390
a3a5fecc
DE
133912017-03-16 Doug Evans <dje@google.com>
13392
13393 * guile/guile-internal.h (tyscm_scm_to_type): Declare.
13394 * guile/scm-type.c (tyscm_scm_to_type): New function.
13395
28f1c605
JW
133962017-03-16 Jiong Wang <jiong.wang@arm.com>
13397
13398 * inf-ptrace.c (inf_ptrace_peek_poke): Change the type to
13399 "ULONGEST" for "skip".
13400
87c336f6
AA
134012017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13402
13403 PR gdb/21220
13404 * inf-ptrace.c (inf_ptrace_xfer_partial): In "case
13405 TARGET_OBJECT_MEMORY", extract the logic for ptrace peek/poke...
13406 (inf_ptrace_peek_poke): ...here. New function. Now also loop
13407 over ptrace peek/poke until end of buffer or error.
13408
cf81cf60
SM
134092017-03-14 Simon Marchi <simon.marchi@ericsson.com>
13410
13411 * parse.c (length_of_subexp): Make static.
13412 * parser-defs.h (length_of_subexp): Remove.
13413
a379284a
AA
134142017-03-14 Andreas Arnez <arnez@linux.vnet.ibm.com>
13415
13416 * linux-nat.c (linux_proc_xfer_partial): Handle write operations
13417 as well.
13418
8a6200ba
PA
134192017-03-14 Pedro Alves <palves@redhat.com>
13420
13421 * cp-name-parser.y (cp_demangled_name_to_comp): Update comment.
13422 (main): Use std::unique_ptr. Remove calls to
13423 cp_demangled_name_parse_free.
13424
f79ec206
SM
134252017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13426
13427 * alpha-bsd-nat.c (alphabsd_fetch_inferior_registers,
13428 alphabsd_store_inferior_registers): Use regcache->ptid instead
13429 of inferior_ptid.
13430
edb5fb00
SM
134312017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13432
13433 * aix-thread.c (aix_thread_fetch_registers,
13434 aix_thread_store_registers): Use regcache->ptid instead of
13435 inferior_ptid.
13436
55119686
SM
134372017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13438
13439 * aarch64-linux-nat.c (fetch_gregs_from_thread,
13440 store_gregs_to_thread, fetch_fpregs_from_thread,
13441 store_fpregs_to_thread): Use regcache->ptid instead of
13442 inferior_ptid.
13443
6a06fbb7
SM
134442017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13445
13446 * amd64-linux-nat.c (amd64_linux_fetch_inferior_registers,
13447 amd64_linux_fetch_inferior_registers): Use regcache->ptid
13448 instead of inferior_ptid.
13449
c6386875
SM
134502017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13451
13452 * target.c (target_fetch_registers, target_store_registers): Add
13453 assert.
13454
ddaaf0fb
SM
134552017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
13456
13457 * regcache.h (regcache_get_ptid): New function.
13458 * regcache.c (regcache_get_ptid): New function.
13459
b9da89d1 134602017-03-13 Mark Wielaard <mark@klomp.org>
13461
13462 * cp-name-parser.y (make_empty): Initialize d_printing to zero.
13463
5f4d1085
KS
134642017-03-10 Keith Seitz <keiths@redhat.com>
13465
13466 PR c++/8218
13467 * c-typeprint.c (cp_type_print_method_args): Skip artificial arguments.
13468
c65d6b55
PA
134692017-03-08 Pedro Alves <palves@redhat.com>
13470
13471 PR gdb/18360
13472 * infrun.c (start_step_over, do_target_resume, resume)
13473 (restart_threads): Assert we're not resuming a thread that is
13474 meant to be stopped.
13475 (infrun_thread_stop_requested_callback): Delete.
13476 (infrun_thread_stop_requested): If the thread is internally
13477 stopped, queue a pending stop event and clear the thread's
13478 inline-frame state.
13479 (handle_stop_requested): New function.
13480 (handle_syscall_event, handle_inferior_event_1): Use
13481 handle_stop_requested.
13482 (handle_stop_requested): New function.
13483 (handle_signal_stop): Set the thread's stop_signal here instead of
13484 at caller.
13485 (finish_step_over): Clear step over info unconditionally.
13486 (handle_signal_stop): If the user had interrupted the event
13487 thread, consider the stop a random signal.
13488 (handle_signal_stop) <signal arrived while stepping over
13489 breakpoint>: Don't restart threads here.
13490 (stop_waiting): Don't clear step-over info here.
13491
15c22686
PA
134922017-03-08 Pedro Alves <palves@redhat.com>
13493
13494 PR 21206
13495 * common/gdb_unlinker.h (unlinker::unlinker): Attribute nonnull
13496 goes to argument 2, not 1.
13497
6e5d74e7
PA
134982017-03-08 Pedro Alves <palves@redhat.com>
13499
13500 PR cli/21218
13501 * top.c (gdb_readline_wrapper): Avoid passing NULL to
13502 display_gdb_prompt.
13503 (command_line_input): Add comment.
13504
9753a2f6
PA
135052017-03-08 Pedro Alves <palves@redhat.com>
13506
13507 PR tui/21216
13508 * tui/tui-file.c (tui_file::write): New.
13509 * tui/tui-file.h (tui_file): Override "write".
13510 * tui/tui-io.c (do_tui_putc, update_start_line): New functions,
13511 factored out from ...
13512 (tui_puts): ... here.
13513 (tui_putc): Use them.
13514 (tui_write): New function.
13515 * tui/tui-io.h (tui_write): Declare.
13516
1672e0d9
SDJ
135172017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
13518
13519 * Makefile.in (SFILES): Replace "environ.c" with
13520 "common/environ.c".
13521 (HFILES_NO_SRCDIR): Likewise, for "environ.h".
13522 * environ.c: Include "common-defs.h" instead of "defs.h. Moved
13523 to...
13524 * common/environ.c: ... here.
13525 * environ.h: Moved to...
13526 * common/environ.h: ... here.
13527
f7bb4e3a
PB
135282017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13529
13530 * gdbarch.sh (pstring_ptr): New static function.
13531 (gdbarch_disassembler_options): Use it.
13532 (gdbarch_verify_disassembler_options): Print valid_disassembler_options,
13533 not valid_disassembler_option->name.
13534 * gdbarch.c: Regenerate.
13535
e45ced6c
PB
135362017-03-07 Peter Bergner <bergner@vnet.ibm.com>
13537
13538 * config/powerpc/ppc64-linux.mh (MH_CFLAGS): Delete.
13539
5f6fd321
PA
135402017-03-07 Pedro Alves <palves@redhat.com>
13541
13542 * tui/tui-regs.c (tui_restore_gdbout): Don't delete gdb_stdout.
13543
6dbb839a 135442017-03-07 Walfred Tedeschi <walfred.tedeschi@intel.com>
4a612d6f
WT
13545
13546 * i387-tdep.h (i387_reset_bnd_regs): Add function definition.
13547 * i387-tdep.c (i387_reset_bnd_regs): Add function implementation.
13548 * i386-tdep.c (i386_push_dummy_call): Call i387_reset_bnd_regs.
6dbb839a 13549 * amd64-tdep.c (amd64_push_dummy_call): Call i387_reset_bnd_regs.
4a612d6f 13550
d274ecf4
SM
135512017-03-06 Simon Marchi <simon.marchi@ericsson.com>
13552
13553 * xtensa-linux-nat.c (fetch_gregs): Remove const.
13554
df97be55
SM
135552017-03-03 Simon Marchi <simon.marchi@ericsson.com>
13556
13557 * remote.c (remote_add_target_side_commands): Use range-based
13558 for loop.
13559
7d45f3df
YQ
135602017-03-03 Yao Qi <yao.qi@linaro.org>
13561
13562 PR gdb/21165
13563 * ada-valprint.c (ada_val_print_ref): Call value_fetch_lazy if
13564 value is lazy.
13565 * valprint.c (common_val_print): Likewise.
13566
65b48a81
PB
135672017-02-28 Peter Bergner <bergner@vnet.ibm.com>
13568
13569 * NEWS: Mention new set/show disassembler-options commands.
13570 * doc/gdb.texinfo: Document new set/show disassembler-options commands.
13571 * disasm.c: Include "arch-utils.h", "gdbcmd.h" and "safe-ctype.h".
13572 (prospective_options): New static variable.
13573 (gdb_disassembler::gdb_disassembler): Initialize
13574 m_di.disassembler_options.
13575 (gdb_buffered_insn_length_init_dis): Initilize di->disassembler_options.
13576 (get_disassembler_options): New function.
13577 (set_disassembler_options): Likewise.
13578 (set_disassembler_options_sfunc): Likewise.
13579 (show_disassembler_options_sfunc): Likewise.
13580 (disassembler_options_completer): Likewise.
13581 (_initialize_disasm): Likewise.
13582 * disasm.h (get_disassembler_options): New prototype.
13583 (set_disassembler_options): Likewise.
13584 * gdbarch.sh (gdbarch_disassembler_options): New variable.
13585 (gdbarch_verify_disassembler_options): Likewise.
13586 * gdbarch.c: Regenerate.
13587 * gdbarch.h: Likewise.
13588 * arm-tdep.c (num_disassembly_options): Delete.
13589 (set_disassembly_style): Likewise.
13590 (arm_disassembler_options): New static variable.
13591 (set_disassembly_style_sfunc): Convert short style name into long
13592 option name. Call set_disassembler_options.
13593 (show_disassembly_style_sfunc): New function.
13594 (arm_gdbarch_init): Call set_gdbarch_disassembler_options and
13595 set_gdbarch_verify_disassembler_options.
13596 (_initialize_arm_tdep): Delete regnames variable and update callers.
13597 (arm_disassembler_options): Initialize.
13598 (disasm_options): New variable.
13599 (num_disassembly_options): Rename from this...
13600 (num_disassembly_styles): ...to this. Compute by scanning through
13601 disasm_options.
13602 (valid_disassembly_styles): Initialize using disasm_options.
13603 Remove calls to parse_arm_disassembler_option, get_arm_regnames and
13604 set_arm_regname_option.
13605 Pass show_disassembly_style_sfunc to the "disassembler" setshow command.
13606 * rs6000-tdep.c (powerpc_disassembler_options): New static variable.
13607 (rs6000_gdbarch_init): Call set_gdbarch_disassembler_options and
13608 set_gdbarch_verify_disassembler_options.
13609 * s390-tdep.c (s390_disassembler_options): New static variable.
13610 (s390_gdbarch_init):all set_gdbarch_disassembler_options and
13611 set_gdbarch_verify_disassembler_options.
13612
d538e36d
SM
136132017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13614
13615 * remote.c (remote_add_target_side_condition): Remove "struct"
13616 keyword from range-based for loop.
13617
83621223
SM
136182017-02-27 Simon Marchi <simon.marchi@ericsson.com>
13619
13620 * remote.c (remote_add_target_side_condition): Use range-based
13621 for loop. Update comment.
13622
2123df0e
YQ
136232017-02-27 Yao Qi <yao.qi@linaro.org>
13624
13625 * f-typeprint.c (f_print_type): Check "varstring" is empty first.
13626
8e368124
AH
136272017-02-26 Alan Hayward <alan.hayward@arm.com>
13628
13629 * regcache.c (regcache_raw_update): New function.
13630 (regcache_raw_read): Move code to regcache_raw_update.
13631 * regcache.h (regcache_raw_update): New declaration.
13632 * remote.c (remote_prepare_to_store): Call regcache_raw_update.
13633
a49dd8dd
JK
136342017-02-26 Jan Kratochvil <jan.kratochvil@redhat.com>
13635
13636 * dwarf2read.c (create_debug_type_hash_table): Initialize
13637 header.signature and header.type_offset_in_tu.
13638
34e4bae9
PA
136392017-02-24 Pedro Alves <palves@redhat.com>
13640
13641 * symtab.c (make_file_symbol_completion_list_1): Use
13642 add_symtab_completions.
13643
b0e4b369
AH
136442017-02-24 Alan Hayward <alan.hayward@arm.com>
13645
13646 * stack.c (frame_info): Use frame_unwind_register_value to avoid buf.
13647
975c21ab
AH
136482017-02-24 Alan Hayward <alan.hayward@arm.com>
13649
13650 * i386-tdep.c (i386_pseudo_register_read_into_value): Use
13651 I386_MAX_REGISTER_SIZE.
13652 (i386_pseudo_register_write): Likewise.
13653 (i386_process_record): Likewise.
13654 * i387-tdep.c (i387_supply_xsave): Likewise.
13655 * m68k-linux-nat.c (fetch_register): Use M68K_MAX_REGISTER_SIZE.
13656 (store_register): Likewise.
13657
14bc53a8
PA
136582017-02-23 Pedro Alves <palves@redhat.com>
13659
13660 * ada-lang.c: Include "common/function-view.h".
13661 (ada_iterate_over_symbols): Adjust to use function_view as
13662 callback type.
13663 (struct add_partial_datum, ada_complete_symbol_matcher): Delete.
13664 (ada_make_symbol_completion_list): Use a lambda.
13665 (ada_exc_search_name_matches): Delete.
13666 (name_matches_regex): New.
13667 (ada_add_global_exceptions): Use a lambda and name_matches_regex.
13668 * compile/compile-c-support.c: Include "common/function-view.h".
13669 (print_one_macro): Change prototype to accept a ui_file pointer.
13670 (write_macro_definitions): Use a lambda.
13671 * dwarf2read.c: Include "common/function-view.h".
13672 (dw2_map_expand_apply, dw2_map_symtabs_matching_filename)
13673 (dw2_expand_symtabs_matching): Adjust to use function_view as
13674 callback type.
13675 * language.h: Include "common/function-view.h".
13676 (struct language_defn) <la_iterate_over_symbols>: Adjust to use
13677 function_view as callback type.
13678 (LA_ITERATE_OVER_SYMBOLS): Remove DATA parameter.
13679 * linespec.c: Include "common/function-view.h".
13680 (collect_info::add_symbol): New method.
13681 (struct symbol_and_data_callback, iterate_inline_only, struct
13682 symbol_matcher_data, iterate_name_matcher): Delete.
13683 (iterate_over_all_matching_symtabs): Adjust to use function_view
13684 as callback type and lambdas.
13685 (iterate_over_file_blocks): Adjust to use function_view as
13686 callback type.
13687 (decode_compound_collector): Now a class with private fields.
13688 (decode_compound_collector::release_symbols): New method.
13689 (collect_one_symbol): Rename to...
13690 (decode_compound_collector::operator()): ... this and adjust.
13691 (lookup_prefix_sym): decode_compound_collector construction bits
13692 move to decode_compound_collector ctor. Pass the
13693 decode_compound_collector object directly as callback. Remove
13694 cleanups and use decode_compound_collector::release_symbols
13695 instead.
13696 (symtab_collector): Now a class with private fields.
13697 (symtab_collector::release_symtabs): New method.
13698 (add_symtabs_to_list): Rename to...
13699 (symtab_collector::operator()): ... this and adjust.
13700 (collect_symtabs_from_filename): symtab_collector construction
13701 bits move to symtab_collector ctor. Pass the symtab_collector
13702 object directly as callback. Remove cleanups and use
13703 symtab_collector::release_symtabs instead.
13704 (collect_symbols): Delete.
13705 (add_matching_symbols_to_info): Use lambdas.
13706 * macrocmd.c (print_macro_callback): Delete.
13707 (info_macro_command): Use a lambda.
13708 (info_macros_command): Pass print_macro_definition as callable
13709 directly.
13710 (print_one_macro): Remove 'ignore' parameter.
13711 (macro_list_command): Adjust.
13712 * macrotab.c (macro_for_each_data::fn): Now a function_view.
13713 (macro_for_each_data::user_data): Delete field.
13714 (foreach_macro): Adjust to call the function_view.
13715 (macro_for_each): Adjust to use function_view as callback type.
13716 (foreach_macro_in_scope): Adjust to call the function_view.
13717 (macro_for_each_in_scope): Adjust to use function_view as callback
13718 type.
13719 * macrotab.h: Include "common/function-view.h".
13720 (macro_callback_fn): Declare a prototype instead of a pointer.
13721 Remove "user_data" parameter.
13722 (macro_for_each, macro_for_each_in_scope): Adjust to use
13723 function_view as callback type.
13724 * psymtab.c (partial_map_expand_apply)
13725 (psym_map_symtabs_matching_filename, recursively_search_psymtabs):
13726 Adjust to use function_view as callback type and to return bool.
13727 (psym_expand_symtabs_matching): Adjust to use function_view as
13728 callback types.
13729 * symfile-debug.c (debug_qf_map_symtabs_matching_filename): Adjust
13730 to use function_view as callback type and to return bool.
13731 (debug_qf_expand_symtabs_matching): Adjust to use function_view as
13732 callback types.
13733 * symfile.c (expand_symtabs_matching): Adjust to use function_view
13734 as callback types.
13735 * symfile.h: Include "common/function-view.h".
13736 (expand_symtabs_file_matcher_ftype)
13737 (expand_symtabs_symbol_matcher_ftype)
13738 (expand_symtabs_exp_notify_ftype): Remove "data" parameter and
13739 return bool.
13740 (quick_symbol_functions::map_symtabs_matching_filename)
13741 (quick_symbol_functions::expand_symtabs_matching): Adjust to use
13742 function_view as callback type and return bool.
13743 (expand_symtabs_matching): Adjust to use function_view as callback
13744 type.
13745 (maintenance_expand_name_matcher)
13746 (maintenance_expand_file_matcher): Delete.
13747 (maintenance_expand_symtabs): Use lambdas.
13748 * symtab.c (iterate_over_some_symtabs): Adjust to use
13749 function_view as callback types and return bool.
13750 (iterate_over_symtabs): Likewise. Use unique_xmalloc_ptr instead
13751 of a cleanup.
13752 (lookup_symtab_callback): Delete.
13753 (lookup_symtab): Use a lambda.
13754 (iterate_over_symbols): Adjust to use function_view as callback
13755 type.
13756 (struct search_symbols_data, search_symbols_file_matches)
13757 (search_symbols_name_matches): Delete.
13758 (search_symbols): Use a pair of lambdas.
13759 (struct add_name_data, add_macro_name, symbol_completion_matcher)
13760 (symtab_expansion_callback): Delete.
13761 (default_make_symbol_completion_list_break_on_1): Use lambdas.
13762 * symtab.h: Include "common/function-view.h".
13763 (iterate_over_some_symtabs): Adjust to use function_view as
13764 callback type and return bool.
13765 (iterate_over_symtabs): Adjust to use function_view as callback
13766 type.
13767 (symbol_found_callback_ftype): Remove 'data' parameter and return
13768 bool.
13769 (iterate_over_symbols): Adjust to use function_view as callback
13770 type.
13771
07e253aa
PA
137722017-02-23 Pedro Alves <palves@redhat.com>
13773
13774 * Makefile.in (SUBDIR_UNITTESTS_SRCS, SUBDIR_UNITTESTS_OBS): New.
13775 (%.o) <unittests/%.c>: New pattern.
13776 * configure.ac ($development): Add $(SUBDIR_UNITTESTS_OBS) to
13777 CONFIG_OBS, and $(SUBDIR_UNITTESTS_SRCS) to CONFIG_SRCS.
13778 * common/function-view.h: New file.
13779 * unittests/function-view-selftests.c: New file.
13780 * configure: Regenerate.
13781
8eaf5320
SM
137822017-02-23 Simon Marchi <simon.marchi@ericsson.com>
13783
13784 * bsd-uthread.c (bsd_uthread_thread_alive): Use ptid instead of
13785 inferior_ptid.
13786 * go32-nat.c (go32_thread_alive): Likewise.
13787
38768751
YQ
137882017-02-23 Yao Qi <yao.qi@linaro.org>
13789
13790 * varobj-iter.h (varobj_iter_delete): Call xfree instead of
13791 delete.
13792
0a8beaba
YQ
137932017-02-23 Yao Qi <yao.qi@linaro.org>
13794
13795 * varobj.c (varobj_clear_saved_item): Use delete instead of
13796 xfree.
13797 (update_dynamic_varobj_children): Likewise.
13798
58fdfd2c
JK
137992017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13800
13801 * dwarf2read.c (dwarf2_record_block_ranges): Add forgotten BASEADDR.
13802
1b90b139
SM
138032017-02-21 Simon Marchi <simon.marchi@ericsson.com>
13804
13805 * common/enum-flags.h (enum_flags::enum_flags): Initialize
13806 m_enum_value to 0 in default constructor.
13807
2039d74e
EBM
138082017-02-21 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
13809
13810 * rs6000-tdep.c (LOAD_AND_RESERVE_MASK): Rename from LWARX_MASK.
13811 (STORE_CONDITIONAL_MASK): Rename from STWCX_MASK.
13812 (LBARX_INSTRUCTION, LHARX_INSTRUCTION, LQARX_INSTRUCTION,
13813 STBCX_INSTRUCTION, STHCX_INSTRUCTION, STQCX_INSTRUCTION): New defines.
13814 (IS_LOAD_AND_RESERVE_INSN, IS_STORE_CONDITIONAL_INSN): New macros.
13815 (ppc_displaced_step_copy_insn): Use IS_LOAD_AND_RESERVE_INSN.
13816 (ppc_deal_with_atomic_sequence): Use IS_LOAD_AND_RESERVE_INSN and
13817 IS_STORE_CONDITIONAL_INSN.
13818
7814882a
JK
138192017-02-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13820
13821 * dwarf2_rnglists_process: Initialize range_beginning and range_end.
13822
0ae60b63
JK
138232017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13824
13825 * NEWS (Changes since GDB 7.12): Add DWARF-5.
13826
0224619f
JK
138272017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13828
13829 * dwarf2read.c (skip_one_die, read_attribute_value)
13830 (dwarf2_const_value_attr, dump_die_shallow)
13831 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
13832 (skip_form_bytes, attr_form_is_constant): Handle DW_FORM_data16.
13833
0af92d60
JK
138342017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13835
13836 * dwarf2read.c (read_file_scope): Rename DW_MACRO_GNU_*.
13837 (dwarf_parse_macro_header): Accept DWARF version 5.
13838 (dwarf_decode_macro_bytes, dwarf_decode_macros): Rename DW_MACRO_GNU_*.
13839
216f72a1
JK
138402017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13841
13842 * block.c (call_site_for_pc): Rename DW_OP_GNU_*, DW_TAG_GNU_* and
13843 DW_AT_GNU_*.
13844 * common/common-exceptions.h (enum errors): Likewise.
13845 * dwarf2-frame.c (class dwarf_expr_executor): Likewise.
13846 * dwarf2expr.c (dwarf_block_to_dwarf_reg)
13847 (dwarf_expr_context::execute_stack_op): Likewise.
13848 * dwarf2expr.h (struct dwarf_expr_context, struct dwarf_expr_piece):
13849 Likewise.
13850 * dwarf2loc.c (dwarf_evaluate_loc_desc::get_base_type)
13851 (dwarf_evaluate_loc_desc::push_dwarf_reg_entry_value)
13852 (show_entry_values_debug, call_site_to_target_addr)
13853 (func_addr_to_tail_call_list, func_verify_no_selftailcall)
13854 (dwarf_expr_reg_to_entry_parameter, dwarf_entry_parameter_to_value)
13855 (entry_data_value_free_closure, value_of_dwarf_reg_entry)
13856 (value_of_dwarf_block_entry, indirect_pieced_value)
13857 (symbol_needs_eval_context::push_dwarf_reg_entry_value):
13858 (disassemble_dwarf_expression): Likewise.
13859 * dwarf2read.c (process_die, inherit_abstract_dies)
13860 (read_call_site_scope): Likewise.
13861 * gdbtypes.h (struct func_type, struct call_site_parameter)
13862 (struct call_site): Likewise.
13863 * stack.c (read_frame_arg): Likewise.
13864 * std-operator.def (OP_VAR_ENTRY_VALUE): Likewise.
13865
43988095
JK
138662017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13867
13868 * defs.h (read_unsigned_leb128): New declaration.
13869 * dwarf2loc.c (decode_debug_loclists_addresses): New function.
13870 (decode_debug_loc_dwo_addresses): Update DEBUG_LOC_* to DW_LLE_*.
13871 (dwarf2_find_location_expression): Call also
13872 decode_debug_loclists_addresses. Handle DWARF-5 ULEB128 length.
13873 * dwarf2loc.h (dwarf2_version): New declaration.
13874 * dwarf2read.c (struct dwarf2_per_objfile): Add loclists, line_str,
13875 rnglists.
13876 (dwarf2_elf_names): Add .debug_loclists, .debug_line_str,
13877 .debug_rnglists.
13878 (struct dwop_section_names): Add loclists_dwo.
13879 (dwop_section_names): Add .debug_loclists.dwo.
13880 (struct comp_unit_head): Add unit_type, signature, type_offset_in_tu.
13881 (struct dwarf2_per_cu_data): Add dwarf_version.
13882 (struct dwo_sections): Add loclists.
13883 (struct attr_abbrev): Add implicit_const.
13884 (read_indirect_line_string): New declaration.
13885 (read_unsigned_leb128): Delete declaration.
13886 (rcuh_kind): New definition.
13887 (read_and_check_comp_unit_head): Change parameter
13888 is_debug_types_section to section_kind.
13889 (dwarf2_locate_sections): Handle loclists, line_str and rnglists.
13890 (read_comp_unit_head): Change parameter abfd to section, add parameter
13891 section_kind. Handle DWARF-5.
13892 (error_check_comp_unit_head): Accept also DWARF version 5.
13893 (read_and_check_comp_unit_head): Change parameter
13894 is_debug_types_section to section_kind.
13895 (read_and_check_type_unit_head): Delete function.
13896 (read_abbrev_offset): Handle DWARF-5.
13897 (create_debug_type_hash_table): Add parameter section_kind. Process
13898 only DW_UT_type. Use signature and type_offset_in_tu from struct
13899 comp_unit_head.
13900 (create_debug_types_hash_table): Update create_debug_type_hash_table
13901 caller.
13902 (create_all_type_units): Call create_debug_type_hash_table.
13903 (read_cutu_die_from_dwo, init_cutu_and_read_dies): Change
13904 read_and_check_type_unit_head caller to read_and_check_comp_unit_head
13905 caller.
13906 (skip_one_die): Handle DW_FORM_implicit_const.
13907 (dwarf2_rnglists_process): New function.
13908 (dwarf2_ranges_process): Call dwarf2_rnglists_process for DWARF-5.
13909 (abbrev_table_read_table): Handle DW_FORM_implicit_const.
13910 (read_attribute_value): Handle DW_FORM_implicit_const,
13911 DW_FORM_line_strp.
13912 (read_attribute): Handle DW_FORM_implicit_const.
13913 (read_indirect_string_at_offset_from): New function from
13914 read_indirect_string_at_offset.
13915 (read_indirect_string_at_offset): Call
13916 read_indirect_string_at_offset_from.
13917 (read_indirect_line_string_at_offset): New function.
13918 (read_indirect_string): New function comment.
13919 (read_indirect_line_string): New function.
13920 (read_unsigned_leb128): Make it global.
13921 (dwarf2_string_attr): Handle DWARF-5.
13922 (add_include_dir_stub, read_formatted_entries): New functions.
13923 (dwarf_decode_line_header, dump_die_shallow, cu_debug_loc_section):
13924 Handle DWARF-5.
13925 (per_cu_header_read_in): Update read_comp_unit_head caller.
13926 (dwarf2_version): New function.
13927 * symfile.h (struct dwarf2_debug_sections): Add loclists, line_str and
13928 rnglists.
13929 * xcoffread.c (dwarf2_xcoff_names): Update struct dwarf2_debug_sections
13930 fields.
13931
22d2f3ab
JK
139322017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13933
13934 * dwarf2read.c (abbrev_table_read_table): Read the data only once.
13935
5f46c5a5
JK
139362017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13937
13938 * dwarf2read.c (dwarf2_ranges_process): New function from
13939 dwarf2_ranges_read.
13940 (dwarf2_ranges_read, dwarf2_record_block_ranges): Use
13941 dwarf2_ranges_process.
13942
78d4d2c5
JK
139432017-02-20 Jan Kratochvil <jan.kratochvil@redhat.com>
13944
13945 * dwarf2read.c (create_debug_type_hash_table): New function from
13946 create_debug_types_hash_table.
13947 (create_debug_types_hash_table): Call create_debug_type_hash_table.
13948 (create_all_type_units, open_and_init_dwo_file): Update
13949 create_debug_types_hash_table callers.
13950
1b076f25
SDJ
139512017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
13952
13953 PR gdb/16188
13954 * fork-child.c (trace_start_error): Fix thinko. va_end should
13955 refer to 'ap', not 'args'.
13956
0db8980c
SDJ
139572017-02-20 Sergio Durigan Junior <sergiodj@redhat.com>
13958 Pedro Alves <palves@redhat.com>
13959
13960 PR gdb/16188
13961 * darwin-nat.c (darwin_ptrace_me): Check if calls to system
13962 calls succeeded.
13963 * fork-child.c (trace_start_error): New function.
13964 (trace_start_error_with_name): Likewise.
13965 * gnu-nat.c (gnu_ptrace_me): Check if call to PTRACE succeeded.
13966 * inf-ptrace.c (inf_ptrace_me): Likewise.
13967 * inferior.h (trace_start_error): New prototype.
13968 (trace_start_error_with_name): Likewise.
13969
99e8a4f9
SDJ
139702017-02-15 Sergio Durigan Junior <sergiodj@redhat.com>
13971
13972 PR gdb/21164
13973 * psymtab.c (maintenance_print_psymbols): Verify if 'argv' is not
13974 NULL before using it.
13975 * symmisc.c (maintenance_print_symbols): Likewise.
13976 (maintenance_print_msymbols): Likewise.
13977
4e746bb6
TW
139782017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13979
13980 * NEWS: Add record Python bindings entry.
13981
139822017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
13983
13984 * Makefile.in (SUBDIR_PYTHON_OBS): Add py-record-btrace.o,
13985 py-record-full.o.
13986 (SUBDIR_PYTHON_SRCS): Add py-record-btrace.c, py-record-full.c.
13987 * python/py-record-btrace.c, python/py-record-btrace.h,
13988 python/py-record-full.c, python/py-record-full.h: New file.
13989 * python/py-record.c: Add include for py-record-btrace.h and
13990 py-record-full.h.
13991 (recpy_method, recpy_format, recpy_goto, recpy_replay_position,
13992 recpy_instruction_history, recpy_function_call_history, recpy_begin,
13993 recpy_end): Use functions from py-record-btrace.c and py-record-full.c.
13994 * python/python-internal.h (PyInt_FromSsize_t, PyInt_AsSsize_t):
13995 New definition.
13996 (gdbpy_initialize_btrace): New export.
13997 * python/python.c (_initialize_python): Add gdbpy_initialize_btrace.
13998
139992017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14000
14001 * Makefile.in (SUBDIR_PYTHON_OBS): Add python/py-record.o.
14002 (SUBDIR_PYTHON_SRCS): Add python/py-record.c.
14003 * python/py-record.c: New file.
14004 * python/python-internal.h (gdbpy_start_recording,
14005 gdbpy_current_recording, gdpy_stop_recording,
14006 gdbpy_initialize_record): New export.
14007 * python/python.c (_initialize_python): Add gdbpy_initialize_record.
14008 (python_GdbMethods): Add gdbpy_start_recording,
14009 gdbpy_current_recording and gdbpy_stop_recording.
14010
140112017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14012
14013 * record-btrace.c (record_btrace_record_method): New function.
14014 (init_record_btrace_ops): Initialize to_record_method.
14015 * record-full.c (record_full_record_method): New function.
14016 (init_record_full_ops, init_record_full_core_ops): Add
14017 record_full_record_method.
14018 * record.h (enum record_method): New enum.
14019 * target-debug.h (target_debug_print_enum_record_method: New define.
14020 * target-delegates.c: Regenerate.
14021 * target.c (target_record_method): New function.
14022 * target.h: Include record.h.
14023 (struct target_ops) <to_record_method>: New field.
14024 (target_record_method): New export.
14025
140262017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14027
14028 * record.h (record_start, record_stop): New export.
14029 * record.c (record_start, record_stop): New function.
14030
140312017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14032
14033 * btrace.c (btrace_fetch): Copy function call segments pointer
14034 into a vector.
14035 (btrace_clear): Clear the vector.
14036 (btrace_find_insn_by_number): Use binary search to find the correct
14037 function call segment.
14038 * btrace.h (brace_fun_p): New typedef.
14039 (struct btrace_thread_info) <functions>: New field.
14040
140412017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14042
14043 * record-btrace.c (btrace_ui_out_decode_error): Move most of it ...
14044 * btrace.c (btrace_decode_error): ... here. New function.
14045 * btrace.h (btrace_decode_error): New export.
14046
140472017-02-14 Tim Wiederhake <tim.wiederhake@intel.com>
14048
14049 * btrace.c (ftrace_call_num_insn, btrace_insn_get_error): New function.
14050 (ftrace_new_function, btrace_insn_number, btrace_insn_cmp,
14051 btrace_find_insn_by_number): Remove special case for gaps.
14052 * btrace.h (btrace_insn_get_error): New export.
14053 (btrace_insn_number, btrace_find_insn_by_number): Adjust comment.
14054 * record-btrace.c (btrace_insn_history): Print number for gaps.
14055 (record_btrace_info, record_btrace_goto): Handle gaps.
14056
3f77c769
TT
140572017-02-14 Tom Tromey <tom@tromey.com>
14058
14059 PR python/13598:
14060 * python/python.c (gdbpy_before_prompt_hook): Emit before_prompt
14061 event.
14062 * python/py-evts.c (gdbpy_initialize_py_events): Add
14063 before_prompt registry.
14064 * python/py-events.h (events_object) <before_prompt>: New field.
14065
4c2c7ac6
MM
140662017-02-14 Markus Metzger <markus.t.metzger@intel.com>
14067
14068 * btrace.c (ftrace_new_switch): Preserve up link and flags.
14069
5cf30ebf
LM
140702017-02-13 Luis Machado <lgustavo@codesourcery.com>
14071
14072 * symfile (_initialize_symfile): Add usage text to the load command's
14073 help text.
14074
26a06916
SM
140752017-02-10 Simon Marchi <simon.marchi@ericsson.com>
14076
14077 * utils.c (defaulted_query): Don't query on secondary UIs.
14078
0b145e37
TT
140792017-02-10 Tom Tromey <tom@tromey.com>
14080
14081 * rust-lang.c (rust_get_disr_info): Remove unused variable.
14082
2d8365c4
TT
140832017-02-10 Tom Tromey <tom@tromey.com>
14084
14085 * python/py-value.c (valpy_richcompare_throw): Remove unnecessary
14086 "cleanup" local.
14087 * python/py-type.c (typy_legacy_template_argument): Remove
14088 unnecessary "cleanup" local.
14089
2bb8f231
TT
140902017-02-10 Tom Tromey <tom@tromey.com>
14091
14092 * python/python.c (do_start_initialization): New function, from
14093 _initialize_python.
14094 (_initialize_python): Call do_start_initialization.
14095 * python/py-linetable.c (ltpy_iternext): Use explicit returns, not
14096 goto.
14097
1bdfaf42
TT
140982017-02-10 Tom Tromey <tom@tromey.com>
14099
14100 * python/py-prettyprint.c (pretty_print_one_value): Use
14101 gdbpy_ref.
14102
88b6faea
TT
141032017-02-10 Tom Tromey <tom@tromey.com>
14104
14105 * python/py-cmd.c (cmdpy_destroyer): Use gdbpy_ref.
14106 * python/py-breakpoint.c (gdbpy_breakpoint_deleted): Use
14107 gdbpy_ref.
14108 * python/py-type.c (field_new): Use gdbpy_ref.
14109 * python/py-symtab.c (symtab_and_line_to_sal_object): Use
14110 gdbpy_ref.
14111 * python/py-progspace.c (pspy_new): Use gdbpy_ref.
14112 (py_free_pspace): Likewise.
14113 (pspace_to_pspace_object): Likewise.
14114 * python/py-objfile.c (objfpy_new): Use gdbpy_ref.
14115 (py_free_objfile): Likewise.
14116 (objfile_to_objfile_object): Likewise.
14117 * python/py-inferior.c (delete_thread_object): Use
14118 gdbpy_ref.
14119 (infpy_read_memory): Likewise.
14120 (py_free_inferior): Likewise.
14121 * python/py-evtregistry.c (create_eventregistry_object): Use
14122 gdbpy_ref.
14123 * python/py-event.c (create_event_object): Use gdbpy_ref.
14124
7780f186
TT
141252017-02-10 Tom Tromey <tom@tromey.com>
14126
14127 * python/py-ref.h (gdbpy_ref_policy): Now a template.
14128 (gdbpy_ref): Now a template; allow subclasses of PyObject to be
14129 used.
14130 * python/py-arch.c, python/py-bpevent.c, python/py-breakpoint.c,
14131 python/py-cmd.c, python/py-continueevent.c, python/py-event.c,
14132 python/py-exitedevent.c, python/py-finishbreakpoint.c,
14133 python/py-framefilter.c, python/py-function.c,
14134 python/py-inferior.c, python/py-infevents.c,
14135 python/py-linetable.c, python/py-newobjfileevent.c,
14136 python/py-param.c, python/py-prettyprint.c, python/py-ref.h,
14137 python/py-signalevent.c, python/py-stopevent.c,
14138 python/py-symbol.c, python/py-threadevent.c, python/py-type.c,
14139 python/py-unwind.c, python/py-utils.c, python/py-value.c,
14140 python/py-varobj.c, python/py-xmethods.c, python/python.c,
14141 varobj.c: Change gdbpy_ref to gdbpy_ref<>.
14142
d4b0bb18
TT
141432017-02-10 Tom Tromey <tom@tromey.com>
14144
14145 * ui-out.h (ui_out_emit_type): New class.
14146 (ui_out_emit_tuple, ui_out_emit_list): New typedefs.
14147 * python/py-framefilter.c (py_print_single_arg): Use gdb::optional
14148 and ui_out_emit_tuple.
14149 (enumerate_locals): Likewise.
14150 (py_mi_print_variables, py_print_locals, py_print_args): Use
14151 ui_out_emit_list.
14152 (py_print_frame): Use gdb::optional, ui_out_emit_tuple,
14153 ui_out_emit_list.
14154 * common/gdb_optional.h: New file.
14155
f67f945c
MG
141562017-02-10 Martin Galvan <martingalvan@sourceware.org>
14157
14158 * MAINTAINERS (Write After Approval): Update my e-mail address.
14159
18da0c51
MG
141602017-02-10 Martin Galvan <martingalvan@sourceware.org>
14161
14162 PR gdb/21122
14163 * breakpoint.c (_initialize_breakpoint): Update the help description
14164 of the 'commands' command to indicate that it takes a list argument.
14165
62c14536
SM
141662017-02-09 Simon Marchi <simon.marchi@ericsson.com>
14167
14168 * interps.c (current_interp_set_logging): Remove "return".
14169
ff6fa247
GB
141702017-02-09 Gary Benson <gbenson@redhat.com>
14171
14172 * symtab.c (add_symtab_completions): Prevent NULL pointer
14173 dereference.
14174
a474bd8e
PA
141752017-02-08 Pedro Alves <palves@redhat.com>
14176
14177 * interps.c (interp::interp): Remove reference to quiet_p.
14178 (interp_set): Make static. Remove dead "Switching to" output
14179 code.
14180 (interp_quiet_p, interp_set_quiet): Delete.
14181 (interpreter_exec_cmd): Don't set the interpreter quiet.
14182 * interps.h (interp_quiet_p): Make static.
14183 (class interp) <quiet_p>: Remove field
14184
3d7b173c
JG
141852017-02-08 Jerome Guitton <guitton@adacore.com>
14186
604c4576
JG
14187 * cli/cli-decode.c (find_command_name_length): Make it extern.
14188 * cli/cli-decode.h (find_command_name_length): Declare.
14189 * cli/cli-script.c (command_name_equals, line_first_arg):
14190 New functions.
14191 (process_next_line): Use cli-decode to parse command names.
14192 (build_command_line): Make args a constant pointer.
14193
141942017-02-08 Jerome Guitton <guitton@adacore.com>
6dbb839a 14195
3d7b173c
JG
14196 * cli-decode.c (lookup_cmd_1, lookup_cmd_composition):
14197 Remove case-insensitive search.
14198
1291063d
JM
141992017-02-07 Jose E. Marchesi <jose.marchesi@oracle.com>
14200
14201 * sparc-tdep.c (sparc32_gdbarch_init): Do not place a + operator
14202 at the end of the line. Avoids an ARI warning.
14203
20b477a7
LM
142042017-02-06 Luis Machado <lgustavo@codesourcery.com>
14205
14206 * NEWS: Mention support for record/replay of Intel 64 rdrand and
14207 rdseed instructions.
14208 i386-tdep.c (i386_process_record): Handle Intel 64 rdrand and rseed.
14209
3f7b46f2
IR
142102017-02-06 Ivo Raisr <ivo.raisr@oracle.com>
14211
14212 PR tdep/20936
14213 Provide and use sparc32 and sparc64 target description XML files.
14214 * features/sparc/sparc32-cp0.xml, features/sparc/sparc32-cpu.xml,
14215 features/sparc/sparc32-fpu.xml: New files for sparc 32-bit.
14216 * features/sparc/sparc64-cp0.xml, features/sparc/sparc64-cpu.xml,
14217 features/sparc/sparc64-fpu.xml: New files for sparc 64-bit.
14218 * features/sparc/sparc32-solaris.xml: New file.
14219 * features/sparc/sparc64-solaris.xml: New file.
14220 * features/sparc/sparc32-solaris.c: Generated.
14221 * features/sparc/sparc64-solaris.c: Generated.
14222 * sparc-tdep.h: Account for differences in target descriptions.
14223 * sparc-tdep.c (sparc32_register_name): Use target provided registers.
14224 (sparc32_register_type): Use target provided registers.
14225 (validate_tdesc_registers): New function.
14226 (sparc32_gdbarch_init): Use tdesc_has_registers.
14227 Set pseudoregister functions.
14228 * sparc64-tdep.c (sparc64_register_name): Use target provided registers.
14229 (sparc64_register_type): Use target provided registers.
14230 (sparc64_init_abi): Set pseudoregister functions.
14231
f0fd41c1
TT
142322017-02-03 Tom Tromey <tom@tromey.com>
14233
14234 PR rust/21097:
14235 * rust-lang.c (rust_print_type) <TYPE_CODE_UNION>: Handle enums
14236 with a single member.
14237
d6f9b0fb
PA
142382017-02-03 Pedro Alves <palves@redhat.com>
14239
14240 * cli/cli-interp.c (cli_interp_base::cli_interp_base)
14241 (cli_interp_base::~cli_interp_base): New.
14242 (cli_interp): New struct.
14243 (as_cli_interp): Cast the interp itself to cli_interp.
14244 (cli_interpreter_pre_command_loop): Rename to ...
14245 (cli_interp_base::pre_command_loop): ... this. Remove 'self'
14246 parameter.
14247 (cli_interpreter_init): Rename to ...
14248 (cli_interp::init): ... this. Remove 'self' parameter. Use
14249 boolean. Make extern.
14250 (cli_interpreter_resume): Rename to ...
14251 (cli_interp::resume): ... this. Remove 'data' parameter. Make
14252 extern.
14253 (cli_interpreter_suspend): Rename to ...
14254 (cli_interp::suspend): ... this. Remove 'data' parameter. Make
14255 extern.
14256 (cli_interpreter_exec): Rename to ...
14257 (cli_interp::exec): ... this. Remove 'data' parameter. Make
14258 extern.
14259 (cli_interpreter_supports_command_editing): Rename to ...
14260 (cli_interp_base::supports_command_editing): ... this. Remove
14261 'interp' parameter. Make extern.
14262 (cli_ui_out): Rename to ...
14263 (cli_interp::interp_ui_out): ... this. Remove 'interp' parameter.
14264 Make extern.
14265 (cli_set_logging): Rename to ...
14266 (cli_interp_base::set_logging): ... this. Remove 'interp'
14267 parameter. Make extern.
14268 (cli_interp_procs): Delete.
14269 (cli_interp_factory): Adjust to use "new".
14270 * cli/cli-interp.h: Include "interps.h".
14271 (struct cli_interp_base): New struct.
14272 * interps.c (struct interp): Delete. Fields moved to interps.h.
14273 (interp_new): Delete.
14274 (interp::interp, interp::~interp): New.
14275 (interp_set): Use bool, and return void. Assume the interpreter
14276 has suspend, init and resume methods, and that the all return
14277 void.
14278 (set_top_level_interpreter): interp_set returns void.
14279 (interp_ui_out): Adapt.
14280 (current_interp_set_logging): Adapt.
14281 (interp_data): Delete.
14282 (interp_pre_command_loop, interp_supports_command_editing): Adapt.
14283 (interp_exec): Adapt.
14284 (top_level_interpreter_data): Delete.
14285 * interps.h (interp_init_ftype, interp_resume_ftype)
14286 (interp_suspend_ftype, interp_exec_ftype)
14287 (interp_pre_command_loop_ftype, interp_ui_out_ftype): Delete.
14288 (class interp): New.
14289 (interp_new): Delete.
14290 (interp_set): Now returns void. Use bool.
14291 (interp_data, top_level_interpreter_data): Delete.
14292 * mi/mi-common.h: Include interps.h.
14293 (class mi_interp): Inherit from interp. Define a ctor. Declare
14294 init, resume, suspect, exec, interp_ui_out, set_logging and
14295 pre_command_loop methods.
14296 * mi/mi-interp.c (as_mi_interp): Cast the interp itself.
14297 (mi_interpreter_init): Rename to ...
14298 (mi_interp::init): ... this. Remove the 'interp' parameter, use
14299 bool, return void and make extern. Adjust.
14300 (mi_interpreter_resume): ... Rename to ...
14301 (mi_interp::resume): ... this. Remove the 'data' parameter,
14302 return void and make extern. Adjust.
14303 (mi_interpreter_suspend): ... Rename to ...
14304 (mi_interp::suspend): ... this. Remove the 'data' parameter,
14305 return void and make extern. Adjust.
14306 (mi_interpreter_exec): ... Rename to ...
14307 (mi_interp::exec): ... this. Remove the 'data' parameter and make
14308 extern. Adjust.
14309 (mi_interpreter_pre_command_loop): ... Rename to ...
14310 (mi_interp::pre_command_loop): ... this. Remove the 'self'
14311 parameter and make extern.
14312 (mi_on_normal_stop_1): Adjust.
14313 (mi_ui_out): Rename to ...
14314 (mi_interp::interp_ui_out): ... this. Remove the 'interp'
14315 parameter and make extern. Adjust.
14316 (mi_set_logging): Rename to ...
14317 (mi_interp::set_logging): ... this. Remove the 'interp'
14318 parameter and make extern. Adjust.
14319 (mi_interp_procs): Delete.
14320 (mi_interp_factory): Adjust to use 'new'.
14321 * mi/mi-main.c (mi_cmd_gdb_exit, captured_mi_execute_command)
14322 (mi_print_exception, mi_execute_command, mi_load_progress):
14323 Adjust.
14324 * tui/tui-interp.c (tui_interp): New class.
14325 (as_tui_interp): Return a tui_interp pointer.
14326 (tui_on_normal_stop, tui_on_signal_received)
14327 (tui_on_end_stepping_range, tui_on_signal_exited, tui_on_exited)
14328 (tui_on_no_history, tui_on_user_selected_context_changed): Adjust
14329 to use interp::interp_ui_out.
14330 (tui_init): Rename to ...
14331 (tui_interp::init): ... this. Remove the 'self' parameter, use
14332 bool, return void and make extern. Adjust.
14333 (tui_resume): Rename to ...
14334 (tui_interp::resume): ... this. Remove the 'data' parameter,
14335 return void and make extern. Adjust.
14336 (tui_suspend): Rename to ...
14337 (tui_interp::suspend): ... this. Remove the 'data' parameter,
14338 return void and make extern. Adjust.
14339 (tui_ui_out): Rename to ...
14340 (tui_interp::interp_ui_out): ... this. Remove the 'self'
14341 parameter, and make extern. Adjust.
14342 (tui_exec): Rename to ...
14343 (tui_interp::exec): ... this. Remove the 'data' parameter and
14344 make extern.
14345 (tui_interp_procs): Delete.
14346 (tui_interp_factory): Use "new".
14347
65c40c95
TT
143482017-02-02 Tom Tromey <tom@tromey.com>
14349
14350 * rust-exp.y (ends_raw_string, space_then_number)
14351 (rust_identifier_start_p): Return bool.
14352 * rust-lang.c (rust_tuple_type_p, rust_underscore_fields)
14353 (rust_tuple_struct_type_p, rust_tuple_variant_type_p)
14354 (rust_slice_type_p, rust_range_type_p, rust_u8_type_p)
14355 (rust_chartype_p): Return bool.
14356 (val_print_struct, rust_print_struct_def, rust_print_type):
14357 Update.
14358 * rust-lang.h (rust_tuple_type_p, rust_tuple_struct_type_p):
14359 Return bool.
14360
b50f188d
TT
143612017-02-02 Tom Tromey <tom@tromey.com>
14362
14363 * rust-lang.c: Reindent.
14364
03c85b11
TT
143652017-02-02 Tom Tromey <tom@tromey.com>
14366
14367 * rust-lang.h (rust_crate_for_block): Update.
14368 * rust-lang.c (rust_crate_for_block): Return std::string.
14369 (rust_get_disr_info): Use std:;string, not
14370 gdb::unique_xmalloc_ptr.
14371 * rust-exp.y (crate_name): Update.
14372
9b6da501
PA
143732017-02-02 Pedro Alves <palves@redhat.com>
14374
14375 * disasm-selftests.c (print_one_insn_test): Move the "verbose"
14376 field out of gdb_disassembler_test and make it static.
14377
ec4cb20b
PA
143782017-02-02 Pedro Alves <palves@redhat.com>
14379
14380 * mi/mi-common.h (struct mi_interp): Delete the mi2_interp,
14381 mi1_interp and mi_interp fields.
14382
5be5dbf0
PA
143832017-02-02 Pedro Alves <palves@redhat.com>
14384
616268b6
PA
14385 * cli/cli-interp.c (struct saved_output_files, saved_output):
14386 Moved from cli/cli-logging.c.
14387 (cli_set_logging): New function.
14388 (cli_interp_procs): Install cli_set_logging.
14389 * cli/cli-interp.h (make_logging_output, cli_set_logging):
14390 Declare.
14391 * cli/cli-logging.c (struct saved_output_files, saved_output):
14392 Moved to cli/cli-interp.c.
14393 (pop_output_files): Don't save outputs here.
14394 (make_logging_output): New function.
14395 (handle_redirections): Don't build tee nor save previous outputs
14396 here.
14397 * interps.c (current_interp_set_logging): Change prototype.
14398 Assume there's always a set_logging_proc method installed.
14399 * interps.h (interp_set_logging_ftype): Change prototype.
14400 (current_interp_set_logging): Change prototype and adjust comment.
14401 * mi/mi-interp.c (mi_set_logging): Change protototype. Adjust to
14402 use make_logging_output.
14403 * tui/tui-interp.c (tui_interp_procs): Install cli_set_logging.
144042017-02-02 Pedro Alves <palves@redhat.com>
14405
5be5dbf0
PA
14406 * cli/cli-logging.c (maybe_warn_already_logging): New factored out
14407 from ...
14408 (set_logging_overwrite): ... here.
14409 (logging_no_redirect_file): Delete.
14410 (set_logging_redirect): Don't handle redirection on the fly.
14411 Instead warn that "logging off" / "logging on" is necessary.
14412 (pop_output_files): Delete references to logging_no_redirect_file.
14413 (show_logging_command): Always speak in terms of what will happen
14414 once logging is reenabled.
14415
c99cc448
PA
144162017-02-02 Pedro Alves <palves@redhat.com>
14417
14418 * disasm.h (gdb_pretty_print_disassembler): Tweak intro comment.
14419
8b172ce7
PA
144202017-02-02 Pedro Alves <palves@redhat.com>
14421
14422 * disasm.c (gdb_pretty_print_insn): Rename to ...
14423 (gdb_pretty_print_disassembler::pretty_print_insn): ... this.
14424 Remove gdbarch parameter. Adapt to clear the object's buffers
14425 instead of allocating new buffers, and to print using the object's
14426 gdb_disassembler instead of calling gdb_print_insn.
14427 (dump_insns): Use gdb_pretty_print_disassembler.
14428 * disasm.h (gdb_pretty_print_insn): Delete declaration.
14429 (gdb_pretty_print_disassembler): New class.
14430 * record-btrace.c (btrace_insn_history): Use
14431 gdb_pretty_print_disassembler.
14432
d7e74731
PA
144332017-02-02 Pedro Alves <palves@redhat.com>
14434
14435 * ada-lang.c (type_as_string): Use string_file.
14436 * ada-valprint.c (ada_print_floating): Use string_file.
14437 * ada-varobj.c (ada_varobj_scalar_image)
14438 (ada_varobj_get_value_image): Use string_file.
14439 * aix-thread.c (aix_thread_extra_thread_info): Use string_file.
14440 * arm-tdep.c (_initialize_arm_tdep): Use string_printf.
14441 * breakpoint.c (update_inserted_breakpoint_locations)
14442 (insert_breakpoint_locations, reattach_breakpoints)
14443 (print_breakpoint_location, print_one_detail_ranged_breakpoint)
14444 (print_it_watchpoint): Use string_file.
14445 (save_breakpoints): Use stdio_file.
14446 * c-exp.y (oper): Use string_file.
14447 * cli/cli-logging.c (set_logging_redirect): Use ui_file_up and
14448 tee_file.
14449 (pop_output_files): Use delete.
14450 (handle_redirections): Use stdio_file and tee_file.
14451 * cli/cli-setshow.c (do_show_command): Use string_file.
14452 * compile/compile-c-support.c (c_compute_program): Use
14453 string_file.
14454 * compile/compile-c-symbols.c (generate_vla_size): Take a
14455 'string_file &' instead of a 'ui_file *'.
14456 (generate_c_for_for_one_variable): Take a 'string_file &' instead
14457 of a 'ui_file *'. Use string_file.
14458 (generate_c_for_variable_locations): Take a 'string_file &'
14459 instead of a 'ui_file *'.
14460 * compile/compile-internal.h (generate_c_for_for_one_variable):
14461 Take a 'string_file &' instead of a 'ui_file *'.
14462 * compile/compile-loc2c.c (push, pushf, unary, binary)
14463 (print_label, pushf_register_address, pushf_register)
14464 (do_compile_dwarf_expr_to_c): Take a 'string_file &' instead of a
14465 'ui_file *'. Adjust.
14466 * compile/compile.c (compile_to_object): Use string_file.
14467 * compile/compile.h (compile_dwarf_expr_to_c)
14468 (compile_dwarf_bounds_to_c): Take a 'string_file &' instead of a
14469 'ui_file *'.
14470 * cp-support.c (inspect_type): Use string_file and obstack_copy0.
14471 (replace_typedefs_qualified_name): Use string_file and
14472 obstack_copy0.
14473 * disasm.c (gdb_pretty_print_insn): Use string_file.
14474 (gdb_disassembly): Adjust reference the null_stream global.
14475 (do_ui_file_delete): Delete.
14476 (gdb_insn_length): Use null_stream.
14477 * dummy-frame.c (maintenance_print_dummy_frames): Use stdio_file.
14478 * dwarf2loc.c (dwarf2_compile_property_to_c)
14479 (locexpr_generate_c_location, loclist_generate_c_location): Take a
14480 'string_file &' instead of a 'ui_file *'.
14481 * dwarf2loc.h (dwarf2_compile_property_to_c): Likewise.
14482 * dwarf2read.c (do_ui_file_peek_last): Delete.
14483 (dwarf2_compute_name): Use string_file.
14484 * event-top.c (gdb_setup_readline): Use stdio_file.
14485 * gdbarch.sh (verify_gdbarch): Use string_file.
14486 * gdbtypes.c (safe_parse_type): Use null_stream.
14487 * guile/scm-breakpoint.c (gdbscm_breakpoint_commands): Use
14488 string_file.
14489 * guile/scm-disasm.c (gdbscm_print_insn_from_port): Take a
14490 'string_file *' instead of a 'ui_file *'.
14491 (gdbscm_arch_disassemble): Use string_file.
14492 * guile/scm-frame.c (frscm_print_frame_smob): Use string_file.
14493 * guile/scm-ports.c (class ioscm_file_port): Now a class that
14494 inherits from ui_file.
14495 (ioscm_file_port_delete, ioscm_file_port_rewind)
14496 (ioscm_file_port_put): Delete.
14497 (ioscm_file_port_write): Rename to ...
14498 (ioscm_file_port::write): ... this. Remove file_port_magic
14499 checks.
14500 (ioscm_file_port_new): Delete.
14501 (ioscm_with_output_to_port_worker): Use ioscm_file_port and
14502 ui_file_up.
14503 * guile/scm-type.c (tyscm_type_name): Use string_file.
14504 * guile/scm-value.c (vlscm_print_value_smob, gdbscm_value_print):
14505 Use string_file.
14506 * infcmd.c (print_return_value_1): Use string_file.
14507 * infrun.c (print_target_wait_results): Use string_file.
14508 * language.c (add_language): Use string_file.
14509 * location.c (explicit_to_string_internal): Use string_file.
14510 * main.c (captured_main_1): Use null_file.
14511 * maint.c (maintenance_print_architecture): Use stdio_file.
14512 * mi/mi-cmd-stack.c (list_arg_or_local): Use string_file.
14513 * mi/mi-common.h (struct mi_interp) <out, err, log, targ,
14514 event_channel>: Change type to mi_console_file pointer.
14515 * mi/mi-console.c (mi_console_file_fputs, mi_console_file_flush)
14516 (mi_console_file_delete): Delete.
14517 (struct mi_console_file): Delete.
14518 (mi_console_file_magic): Delete.
14519 (mi_console_file_new): Delete.
14520 (mi_console_file::mi_console_file): New.
14521 (mi_console_file_delete): Delete.
14522 (mi_console_file_fputs): Delete.
14523 (mi_console_file::write): New.
14524 (mi_console_raw_packet): Delete.
14525 (mi_console_file::flush): New.
14526 (mi_console_file_flush): Delete.
14527 (mi_console_set_raw): Rename to ...
14528 (mi_console_file::set_raw): ... this.
14529 * mi/mi-console.h (class mi_console_file): New class.
14530 (mi_console_file_new, mi_console_set_raw): Delete.
14531 * mi/mi-interp.c (mi_interpreter_init): Use mi_console_file.
14532 (mi_set_logging): Use delete and tee_file. Adjust.
14533 * mi/mi-main.c (output_register): Use string_file.
14534 (mi_cmd_data_evaluate_expression): Use string_file.
14535 (mi_cmd_data_read_memory): Use string_file.
14536 (mi_cmd_execute, print_variable_or_computed): Use string_file.
14537 * mi/mi-out.c (mi_ui_out::main_stream): New.
14538 (mi_ui_out::rewind): Use main_stream and
14539 string_file.
14540 (mi_ui_out::put): Use main_stream and string_file.
14541 (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14542 Allocate a 'string_file' instead.
14543 (mi_out_new): Don't allocate a mem_fileopen stream here.
14544 * mi/mi-out.h (mi_ui_out::mi_ui_out): Remove 'stream' parameter.
14545 (mi_ui_out::main_stream): Declare method.
14546 * printcmd.c (eval_command): Use string_file.
14547 * psymtab.c (maintenance_print_psymbols): Use stdio_file.
14548 * python/py-arch.c (archpy_disassemble): Use string_file.
14549 * python/py-breakpoint.c (bppy_get_commands): Use string_file.
14550 * python/py-frame.c (frapy_str): Use string_file.
14551 * python/py-framefilter.c (py_print_type, py_print_single_arg):
14552 Use string_file.
14553 * python/py-type.c (typy_str): Use string_file.
14554 * python/py-unwind.c (unwind_infopy_str): Use string_file.
14555 * python/py-value.c (valpy_str): Use string_file.
14556 * record-btrace.c (btrace_insn_history): Use string_file.
14557 * regcache.c (regcache_print): Use stdio_file.
14558 * reggroups.c (maintenance_print_reggroups): Use stdio_file.
14559 * remote.c (escape_buffer): Use string_file.
14560 * rust-lang.c (rust_get_disr_info): Use string_file.
14561 * serial.c (serial_open_ops_1): Use stdio_file.
14562 (do_serial_close): Use delete.
14563 * stack.c (print_frame_arg): Use string_file.
14564 (print_frame_args): Remove local mem_fileopen stream, not used.
14565 (print_frame): Use string_file.
14566 * symmisc.c (maintenance_print_symbols): Use stdio_file.
14567 * symtab.h (struct symbol_computed_ops) <generate_c_location>:
14568 Take a 'string_file *' instead of a 'ui_file *'.
14569 * top.c (new_ui): Use stdio_file and stderr_file.
14570 (free_ui): Use delete.
14571 (execute_command_to_string): Use string_file.
14572 (quit_confirm): Use string_file.
14573 * tracepoint.c (collection_list::append_exp): Use string_file.
14574 * tui/tui-disasm.c (tui_disassemble): Use string_file.
14575 * tui/tui-file.c: Don't include "ui-file.h".
14576 (enum streamtype, struct tui_stream): Delete.
14577 (tui_file_new, tui_file_delete, tui_fileopen, tui_sfileopen)
14578 (tui_file_isatty, tui_file_rewind, tui_file_put): Delete.
14579 (tui_file::tui_file): New method.
14580 (tui_file_fputs): Delete.
14581 (tui_file_get_strbuf): Delete.
14582 (tui_file::puts): New method.
14583 (tui_file_adjust_strbuf): Delete.
14584 (tui_file_flush): Delete.
14585 (tui_file::flush): New method.
14586 * tui/tui-file.h: Tweak intro comment.
14587 Include ui-file.h.
14588 (tui_fileopen, tui_sfileopen, tui_file_get_strbuf)
14589 (tui_file_adjust_strbuf): Delete declarations.
14590 (class tui_file): New class.
14591 * tui/tui-io.c (tui_initialize_io): Use tui_file.
14592 * tui/tui-regs.c (tui_restore_gdbout): Use delete.
14593 (tui_register_format): Use string_stream.
14594 * tui/tui-stack.c (tui_make_status_line): Use string_file.
14595 (tui_get_function_from_frame): Use string_file.
14596 * typeprint.c (type_to_string): Use string_file.
14597 * ui-file.c (struct ui_file, ui_file_magic, ui_file_new): Delete.
14598 (null_stream): New global.
14599 (ui_file_delete): Delete.
14600 (ui_file::ui_file): New.
14601 (null_file_isatty): Delete.
14602 (ui_file::~ui_file): New.
14603 (null_file_rewind): Delete.
14604 (ui_file::printf): New.
14605 (null_file_put): Delete.
14606 (null_file_flush): Delete.
14607 (ui_file::putstr): New.
14608 (null_file_write): Delete.
14609 (ui_file::putstrn): New.
14610 (null_file_read): Delete.
14611 (ui_file::putc): New.
14612 (null_file_fputs): Delete.
14613 (null_file_write_async_safe): Delete.
14614 (ui_file::vprintf): New.
14615 (null_file_delete): Delete.
14616 (null_file::write): New.
14617 (null_file_fseek): Delete.
14618 (null_file::puts): New.
14619 (ui_file_data): Delete.
14620 (null_file::write_async_safe): New.
14621 (gdb_flush, ui_file_isatty): Adjust.
14622 (ui_file_put, ui_file_rewind): Delete.
14623 (ui_file_write): Adjust.
14624 (ui_file_write_for_put): Delete.
14625 (ui_file_write_async_safe, ui_file_read): Adjust.
14626 (ui_file_fseek): Delete.
14627 (fputs_unfiltered): Adjust.
14628 (set_ui_file_flush, set_ui_file_isatty, set_ui_file_rewind)
14629 (set_ui_file_put, set_ui_file_write, set_ui_file_write_async_safe)
14630 (set_ui_file_read, set_ui_file_fputs, set_ui_file_fseek)
14631 (set_ui_file_data): Delete.
14632 (string_file::~string_file, string_file::write)
14633 (struct accumulated_ui_file, do_ui_file_xstrdup, ui_file_xstrdup)
14634 (do_ui_file_as_string, ui_file_as_string): Delete.
14635 (do_ui_file_obsavestring, ui_file_obsavestring): Delete.
14636 (struct mem_file): Delete.
14637 (mem_file_new): Delete.
14638 (stdio_file::stdio_file): New.
14639 (mem_file_delete): Delete.
14640 (stdio_file::stdio_file): New.
14641 (mem_fileopen): Delete.
14642 (stdio_file::~stdio_file): New.
14643 (mem_file_rewind): Delete.
14644 (stdio_file::set_stream): New.
14645 (mem_file_put): Delete.
14646 (stdio_file::open): New.
14647 (mem_file_write): Delete.
14648 (stdio_file_magic, struct stdio_file): Delete.
14649 (stdio_file_new, stdio_file_delete, stdio_file_flush): Delete.
14650 (stdio_file::flush): New.
14651 (stdio_file_read): Rename to ...
14652 (stdio_file::read): ... this. Adjust.
14653 (stdio_file_write): Rename to ...
14654 (stdio_file::write): ... this. Adjust.
14655 (stdio_file_write_async_safe): Rename to ...
14656 (stdio_file::write_async_safe) ... this. Adjust.
14657 (stdio_file_fputs): Rename to ...
14658 (stdio_file::puts) ... this. Adjust.
14659 (stdio_file_isatty): Delete.
14660 (stdio_file_fseek): Delete.
14661 (stdio_file::isatty): New.
14662 (stderr_file_write): Rename to ...
14663 (stderr_file::write) ... this. Adjust.
14664 (stderr_file_fputs): Rename to ...
14665 (stderr_file::puts) ... this. Adjust.
14666 (stderr_fileopen, stdio_fileopen, gdb_fopen): Delete.
14667 (stderr_file::stderr_file): New.
14668 (tee_file_magic): Delete.
14669 (struct tee_file): Delete.
14670 (tee_file::tee_file): New.
14671 (tee_file_new): Delete.
14672 (tee_file::~tee_file): New.
14673 (tee_file_delete): Delete.
14674 (tee_file_flush): Rename to ...
14675 (tee_file::flush): ... this. Adjust.
14676 (tee_file_write): Rename to ...
14677 (tee_file::write): ... this. Adjust.
14678 (tee_file::write_async_safe): New.
14679 (tee_file_fputs): Rename to ...
14680 (tee_file::puts): ... this. Adjust.
14681 (tee_file_isatty): Rename to ...
14682 (tee_file::isatty): ... this. Adjust.
14683 * ui-file.h (struct obstack, struct ui_file): Don't
14684 forward-declare.
14685 (ui_file_new, ui_file_flush_ftype, set_ui_file_flush)
14686 (ui_file_write_ftype)
14687 (set_ui_file_write, ui_file_fputs_ftype, set_ui_file_fputs)
14688 (ui_file_write_async_safe_ftype, set_ui_file_write_async_safe)
14689 (ui_file_read_ftype, set_ui_file_read, ui_file_isatty_ftype)
14690 (set_ui_file_isatty, ui_file_rewind_ftype, set_ui_file_rewind)
14691 (ui_file_put_method_ftype, ui_file_put_ftype, set_ui_file_put)
14692 (ui_file_delete_ftype, set_ui_file_data, ui_file_fseek_ftype)
14693 (set_ui_file_fseek): Delete.
14694 (ui_file_data, ui_file_delete, ui_file_rewind)
14695 (struct ui_file): New.
14696 (ui_file_up): New.
14697 (class null_file): New.
14698 (null_stream): Declare.
14699 (ui_file_write_for_put, ui_file_put): Delete.
14700 (ui_file_xstrdup, ui_file_as_string, ui_file_obsavestring):
14701 Delete.
14702 (ui_file_fseek, mem_fileopen, stdio_fileopen, stderr_fileopen)
14703 (gdb_fopen, tee_file_new): Delete.
14704 (struct string_file): New.
14705 (struct stdio_file): New.
14706 (stdio_file_up): New.
14707 (struct stderr_file): New.
14708 (class tee_file): New.
14709 * ui-out.c (ui_out::field_stream): Take a 'string_file &' instead
14710 of a 'ui_file *'. Adjust.
14711 * ui-out.h (class ui_out) <field_stream>: Likewise.
14712 * utils.c (do_ui_file_delete, make_cleanup_ui_file_delete)
14713 (null_stream): Delete.
14714 (error_stream): Take a 'string_file &' instead of a 'ui_file *'.
14715 Adjust.
14716 * utils.h (struct ui_file): Delete forward declaration..
14717 (make_cleanup_ui_file_delete, null_stream): Delete declarations.
14718 (error_stream): Take a 'string_file &' instead of a
14719 'ui_file *'.
14720 * varobj.c (varobj_value_get_print_value): Use string_file.
14721 * xtensa-tdep.c (xtensa_verify_config): Use string_file.
14722 * gdbarch.c: Regenerate.
14723
187808b0
PA
147242017-02-02 Pedro Alves <palves@redhat.com>
14725
14726 * disasm.c (gdb_disassembler::pretty_print_insn): Rename to...
14727 (gdb_pretty_print_insn): ... this. Now a free function. Add back
14728 a 'gdbarch' parameter. Allocate a mem_fileopen stream here.
14729 Adjust to call gdb_print_insn instead of
14730 gdb_disassembler::print_insn.
14731 (dump_insns, do_mixed_source_and_assembly_deprecated)
14732 (do_mixed_source_and_assembly, do_assembly_only): Add back a
14733 'gdbarch' parameter. Remove gdb_disassembler parameter.
14734 (gdb_disassembly): Don't allocate a gdb_disassembler here.
14735 * disasm.h (gdb_disassembler::pretty_print_insn): Delete
14736 declaration.
14737 (gdb_pretty_print_insn): Re-add declaration.
14738 * record-btrace.c (btrace_insn_history): Don't allocate a
14739 gdb_disassembler here. Adjust to call gdb_pretty_print_insn.
14740
7a8eb317
SM
147412017-02-01 Simon Marchi <simon.marchi@polymtl.ca>
14742
14743 * disasm.h (gdb_disassembly): Remove file_string parameter.
14744 * disasm.c (gdb_disassembly): Likewise.
14745 * cli/cli-cmds.c (print_disassembly): Adapt.
14746 * mi/mi-cmd-disas.c (mi_cmd_disassemble): Likewise.
14747 * stack.c (do_gdb_disassembly): Likewise.
14748
7346ef59
AA
147492017-02-01 Andreas Arnez <arnez@linux.vnet.ibm.com>
14750
14751 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): For
14752 DWARF_VALUE_LITERAL, no longer ignore the offset on big-endian
14753 targets. And if the implicit value is longer than needed, extract
14754 the first bytes instead of the "least significant" ones.
14755
cd4007e4
MM
147562017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14757
14758 * btrace.c (btrace_enable): Do not call btrace_add_pc for
14759 BTRACE_FORMAT_PT or if can_access_registers_ptid returns false.
14760 (btrace_fetch): Assert can_access_registers_ptid.
14761 * record-btrace.c (require_btrace_thread, record_btrace_info): Call
14762 validate_registers_access.
14763
cf77c34e
MM
147642017-02-01 Markus Metzger <markus.t.metzger@intel.com>
14765
14766 * gdbthread.h (can_access_registers_ptid): New.
14767 * thread.c (can_access_registers_ptid): New.
14768
be85ce7d
PA
147692017-02-01 Pedro Alves <palves@redhat.com>
14770
14771 * i386-tdep.c (i386_fast_tracepoint_valid_at): Use gdb_insn_length.
14772
29b0b251
PA
147732017-01-31 Pedro Alves <palves@redhat.com>
14774
14775 * mi/mi-interp.c (mi_breakpoint_created, mi_breakpoint_modified):
14776 Fix typos.
14777
289b5b24
PA
147782017-01-31 Pedro Alves <palves@redhat.com>
14779
14780 * stack.c (print_frame_args): Remove local mem_fileopen stream,
14781 not used.
14782
b47413b4
PA
147832017-01-31 Pedro Alves <palves@redhat.com>
14784
14785 * varobj.c (varobj_value_get_print_value): Remove xstrdup call.
14786
60adb36c
PA
147872017-01-31 Pedro Alves <palves@redhat.com>
14788
14789 * common/scoped_restore.h
14790 (scoped_restore_tmpl::scoped_restore_tmpl): Template on T2, and
14791 change the value's parameter type to T2.
14792 (make_scoped_restore): Likewise.
14793
2735833d
WT
147942017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14795 Richard Henderson <rth@redhat.com>
14796
14797 * amd64-linux-nat.c (PTRACE_ARCH_PRCTL): New define.
14798 (amd64_linux_fetch_inferior_registers): Add case to fetch FS_BASE
14799 GS_BASE for older kernels.
14800 (amd64_linux_store_inferior_registers): Add case to store FS_BASE
14801 GS_BASE for older kernels.
14802 * amd64-linux-tdep.c (amd64_linux_gregset_reg_offset): Add FS_BASE
14803 and GS_BASE to the offset table.
14804 (amd64_linux_register_reggroup_p): Add FS_BASE and GS_BASE to the
14805 system register group.
14806 * amd64-nat.c (amd64_native_gregset_reg_offset): Implements case
14807 for older kernels.
14808 * amd64-tdep.c (amd64_init_abi): Add segment registers for the
14809 amd64 ABI.
14810 * amd64-tdep.h (amd64_regnum): Add AMD64_FSBASE_REGNUM and
14811 AMD64_GSBASE_REGNUM.
14812 (AMD64_NUM_REGS): Set to AMD64_GSBASE_REGNUM + 1.
14813 * features/Makefile (amd64-linux.dat, amd64-avx-linux.dat)
14814 (amd64-mpx-linux.dat, amd64-avx512-linux.dat, x32-linux.dat)
14815 (x32-avx-linux.dat, x32-avx512-linux.dat): Add
14816 i386/64bit-segments.xml in those rules.
14817 * features/i386/64bit-segments.xml: New file.
14818 * features/i386/amd64-avx-mpx-linux.xml: Add 64bit-segments.xml.
14819 * features/i386/amd64-avx-linux.xml: Add 64bit-segments.xml.
14820 * features/i386/amd64-avx512-linux.xml: Add 64bit-segments.xml.
14821 * features/i386/amd64-mpx-linux.xml: Add 64bit-segments.xml.
14822 * features/i386/x32-avx512-linux.xml: Add 64bit-segments.xml.
14823 * features/i386/x32-avx-linux.xml: Add 64bit-segments.xml.
14824 * features/i386/amd64-linux.xml: Add 64bit-segments.xml.
14825 * features/i386/amd64-avx-linux.c: Regenerated.
14826 * features/i386/amd64-avx-mpx-linux.c: Regenerated.
14827 * features/i386/amd64-avx-mpx.c: Regenerated.
14828 * features/i386/amd64-avx512-linux.c: Regenerated.
14829 * features/i386/amd64-linux.c: Regenerated.
14830 * features/i386/amd64-mpx-linux.c: Regenerated.
14831 * features/i386/i386-avx-mpx-linux.c: Regenerated.
14832 * features/i386/i386-avx-mpx.c: Regenerated.
14833 * features/i386/x32-avx-linux.c: Regenerated.
14834 * features/i386/x32-avx512-linux.c: Regenerated.
14835 * regformats/i386/amd64-avx-linux.dat: Regenerated.
14836 * regformats/i386/amd64-avx-mpx-linux.dat: Regenerated.
14837 * regformats/i386/amd64-avx512-linux.dat: Regenerated.
14838 * regformats/i386/amd64-linux.dat: Regenerated.
14839 * regformats/i386/amd64-mpx-linux.dat: Regenerated.
14840 * regformats/i386/x32-avx-linux.dat: Regenerated.
14841 * regformats/i386/x32-avx512-linux.dat: Regenerated.
14842 * regformats/i386/x32-linux.dat: Regenerated.
14843
8884e97e
WT
148442017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14845
14846 * amd64-linux-tdep.h (AMD64_LINUX_ORIG_RAX_REGNUM):
14847 Set to AMD64_NUM_REGS.
14848
7005d26a
WT
148492017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
14850
14851 * amd64-nat.c (amd64_native_gregset_reg_offset): Simplify logic
14852 that checks validity of a register number.
14853
4bd2e1b2
KC
148542017-01-27 Kees Cook <keescook@google.com>
14855
14856 * gdb/arm-linux-nat.c (arm_linux_fetch_inferior_registers): Call
14857 fetch_fpregs if target has fpa registers.
14858 (arm_linux_store_inferior_registers): Call store_fpregs if target
14859 has fpa registers.
14860
7cf1de6c
AA
148612017-01-26 Andreas Arnez <arnez@linux.vnet.ibm.com>
14862
14863 * cris-tdep.c (cris_gdbarch_init): Remove check for
14864 info.byte_order and force it to BFD_ENDIAN_LITTLE.
14865
874a1c8c
AT
148662017-01-26 Antoine Tremblay <antoine.tremblay@ericsson.com>
14867
14868 * corelow.c (get_core_register_section): Check for regset
14869 existence before checking for REGSET_VARIABLE_SIZE.
14870
d8b49cf0
YQ
148712017-01-26 Yao Qi <yao.qi@linaro.org>
14872 Pedro Alves <palves@redhat.com>
14873
14874 PR gdb/20939
14875 * disasm.c (gdb_disassembler::dis_asm_memory_error): Don't
14876 call memory_error, save memaddr instead.
14877 (gdb_disassembler::print_insn): If gdbarch_print_insn returns
14878 negative, cal memory_error.
14879 * disasm.h (gdb_disassembler) <m_err_memaddr>: New field.
14880
658ca58c
YQ
148812017-01-26 Yao Qi <yao.qi@linaro.org>
14882
14883 * disasm-selftests.c (memory_error_test): New function.
14884 (_initialize_disasm_selftests): Register memory_error_test.
14885
79843d45
YQ
148862017-01-26 Yao Qi <yao.qi@linaro.org>
14887
14888 * Makefile.in (SFILES): Add disasm-selftests.c and
14889 selftest-arch.c.
14890 (COMMON_OBS): Add disasm-selftests.o and selftest-arch.o.
14891 * disasm-selftests.c: New file.
14892 * selftest-arch.c: New file.
14893 * selftest-arch.h: New file.
14894
8cafda32
YQ
148952017-01-26 Yao Qi <yao.qi@linaro.org>
14896
14897 * mep-tdep.c (mep_gdb_print_insn): Set info->arch
14898 to bfd_arch_mep. Don't return 0 if section is not
14899 found. Call print_insn_mep.
14900
e47ad6c0
YQ
149012017-01-26 Pedro Alves <palves@redhat.com>
14902 Yao Qi <yao.qi@linaro.org>
14903
14904 * arm-tdep.c: Include "disasm.h".
14905 (gdb_print_insn_arm): Update code to get gdbarch.
14906 * disasm.c (dis_asm_read_memory): Change it to
14907 gdb_disassembler::dis_asm_read_memory.
14908 (dis_asm_memory_error): Likewise.
14909 (dis_asm_print_address): Likewise.
14910 (gdb_pretty_print_insn): Change it to
14911 gdb_disassembler::pretty_print_insn.
14912 (dump_insns): Add one argument gdb_disassemlber. All
14913 callers updated.
14914 (do_mixed_source_and_assembly_deprecated): Likewise.
14915 (do_mixed_source_and_assembly): Likewise.
14916 (do_assembly_only): Likewise.
14917 (gdb_disassembler::gdb_disassembler): New.
14918 (gdb_disassembler::print_insn): New.
14919 * disasm.h (class gdb_disassembler): New.
14920 (gdb_pretty_print_insn): Remove declaration.
14921 (gdb_disassemble_info): Likewise.
14922 * guile/scm-disasm.c (class gdbscm_disassembler): New.
14923 (gdbscm_disasm_read_memory_worker): Update.
14924 (gdbscm_disasm_read_memory): Update.
14925 (gdbscm_disasm_memory_error): Remove.
14926 (gdbscm_disasm_print_address): Remove.
14927 (gdbscm_disassembler::gdbscm_disassembler): New.
14928 (gdbscm_print_insn_from_port): Update.
14929 * mips-tdep.c: Include disasm.h.
14930 (gdb_print_insn_mips): Update code to get gdbarch.
14931 * record-btrace.c (btrace_insn_history): Update.
14932 * spu-tdep.c: Include disasm.h.
14933 (struct spu_dis_asm_data): Remove.
14934 (struct spu_dis_asm_info): New.
14935 (spu_dis_asm_print_address): Use spu_dis_asm_info to get
14936 SPU id.
14937 (gdb_print_insn_spu): Cast disassemble_info to
14938 spu_dis_asm_info.
14939
80d75874
YQ
149402017-01-26 Yao Qi <yao.qi@linaro.org>
14941
14942 * disasm.c (do_ui_file_delete): Delete.
14943 (gdb_insn_length): Move code creating stream to ...
14944 * utils.c (null_stream): ... here. New function.
14945 * utils.h (null_stream): Declare.
14946
60685cd0
SM
149472017-01-23 Simon Marchi <simon.marchi@polymtl.ca>
14948
14949 * python/py-inferior.c (find_thread_object): Return directly
14950 from the loop. Remove "found" variable.
14951
eb1cdb62
JB
149522017-01-21 Joel Brobecker <brobecker@adacore.com>
14953
14954 GDB 7.12.1 released.
14955
b1ce6568
SM
149562017-01-20 Simon Marchi <simon.marchi@ericsson.com>
14957
14958 * python/py-function.c (fnpy_call): Reorder declarations to have
14959 the gdbpy_enter object declared first.
14960 * python/py-xmethods.c (gdbpy_get_xmethod_arg_types): Likewise.
14961
6f8b0407
SM
149622017-01-20 Simon Marchi <simon.marchi@ericsson.com>
14963
fec93fb1 14964 PR python/21068
6f8b0407
SM
14965 * python/python-internal.h (PyMem_RawMalloc): Define for
14966 Python < 3.4.
14967 * python/py-gdb-readline.c (gdbpy_readline_wrapper): Use
14968 PyMem_RawMalloc instead of PyMem_Malloc.
14969
78cbbba8
LM
149702017-01-20 Mike Wrighton <mike_wrighton@codesourcery.com>
14971 Luis Machado <lgustavo@codesourcery.com>
14972
14973 * NEWS (New commands): Mention flash-erase.
14974 (New MI commands): Mention target-flash-erase.
14975 * mi/mi-cmds.c (mi_cmd_target_flash_erase): Add target-flash-erase MI
14976 command.
14977 * mi/mi-cmds.h (mi_cmd_target_flash_erase): New declaration.
14978 * mi/mi-main.c (mi_cmd_target_flash_erase): New function.
14979 * target.c (flash_erase_command): New function.
14980 (initialize_targets): Add new flash-erase command.
14981 * target.h (flash_erase_command): New declaration.
14982
2132fe85
JB
149832017-01-20 Joel Brobecker <brobecker@adacore.com>
14984
14985 * nat/linux-ptrace.c: Only include <sys/procfs.h> if
14986 HAVE_SYS_PROCFS_H is defined.
14987
d1dff226
AH
149882017-01-18 Alan Hayward <alan.hayward@arm.com>
14989
14990 * remote.c (struct cached_reg): Change data into a pointer.
14991 * (stop_reply_dtr): Free data pointers before deleting vector.
14992 (process_stop_reply): Likewise.
14993 (remote_parse_stop_reply): Allocate space for data
14994
9890e433
AH
149952017-01-18 Alan Hayward <alan.hayward@arm.com>
14996
14997 * amd64-tdep.c (amd64_pseudo_register_read_value): remove
14998 MAX_REGISTER_SIZE.
14999 (amd64_pseudo_register_read_value): Likewise.
15000 * remote.c (fetch_register_using_p): Remove MAX_REGISTER_SIZE.
15001 (store_register_using_P): Likewise.
15002 * regcache.c (regcache_xfer_part): Likewise.
15003
7a36499a
IR
150042017-01-16 Ivo Raisr <ivo.raisr@oracle.com>
15005
15006 Split real and pseudo registers.
15007 * sparc-tdep.h (SPARC_CORE_REGISTERS): New macro.
15008 (sparc32_pseudo_regnum): New enum.
15009 * sparc64-tdep.h (sparc64_pseudo_regnum): New enum.
15010 * sparc-tdep.c (SPARC32_FPU_REGISTERS): New macro.
15011 (SPARC32_CP0_REGISTERS): New macro.
15012 (sparc32_pseudo_register_name): New function.
15013 (sparc32_register_name): Use sparc32_pseudo_register_name.
15014 (sparc32_pseudo_register_type): New function.
15015 (sparc32_register_type): Use sparc32_pseudo_register_type.
15016 (sparc32_pseudo_register_read, sparc32_pseudo_register_write): Handle
15017 pseudo register numbers.
15018 * sparc64-tdep.c SPARC64_FPU_REGISTERS): New macro.
15019 (SPARC64_CP0_REGISTERS): New macro.
15020 (sparc64_pseudo_register_name): New function.
15021 (sparc64_register_name): Use sparc64_pseudo_register_name.
15022 (sparc64_pseudo_register_type): New function.
15023 (sparc64_register_type): Use sparc64_pseudo_register_type.
15024 (sparc64_pseudo_register_read, sparc64_pseudo_register_write): Handle
15025 pseudo register numbers.
15026 (sparc64_store_floating_fields, sparc64_extract_floating_fields,
15027 sparc64_store_arguments): Handle pseudo register numbers.
15028
6f8976bf
YQ
150292017-01-13 Yao Qi <yao.qi@linaro.org>
15030
15031 * remote.c (REMOTE_DEBUG_MAX_CHAR): New macro.
15032 (putpkt_binary): Print only REMOTE_DEBUG_MAX_CHAR chars in debug
15033 output.
15034 (getpkt_or_notif_sane_1): Likewise.
15035
e4241ace
YQ
150362017-01-13 Yao Qi <yao.qi@linaro.org>
15037
15038 * Makefile.in (checker-headers): Use CXX and CXX_DIALET instead
15039 of CC. Pass "-x c++-header" instead of "-x c".
15040
3015c064
SM
150412017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15042
15043 * remote.c (remote_can_async_p): Update comment.
15044
fde1b17d
SM
150452017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15046
15047 * linux-nat.c (linux_nat_can_async_p): Update comment.
15048
ca1ca08b
SM
150492017-01-12 Simon Marchi <simon.marchi@ericsson.com>
15050
15051 * serial.c (serial_open): Forget about "pc" and "lpt" serial interface.
15052
4ad2da73
SM
150532017-01-11 Simon Marchi <simon.marchi@ericsson.com>
15054
15055 * cli/cli-decode.c (lookup_cmd_1): Fix typo in comment.
15056
c8b23b3f
TT
150572017-01-10 Tom Tromey <tom@tromey.com>
15058
15059 * python/py-type.c (typy_legacy_template_argument): Update.
15060 * cp-support.h (struct demangle_parse_info) (demangle_parse_info,
15061 ~demangle_parse_info): Declare new members.
15062 (cp_demangled_name_to_comp): Return unique_ptr.
15063 (cp_demangled_name_parse_free)
15064 (make_cleanup_cp_demangled_name_parse_free)
15065 (cp_new_demangle_parse_info): Remove.
15066 * cp-support.c (do_demangled_name_parse_free_cleanup)
15067 (make_cleanup_cp_demangled_name_parse_free): Remove.
15068 (inspect_type, cp_canonicalize_string_full)
15069 (cp_canonicalize_string): Update.
15070 (mangled_name_to_comp): Change return type.
15071 (cp_class_name_from_physname, method_name_from_physname)
15072 (cp_func_name, cp_remove_params): Update.
15073 * cp-name-parser.y (demangle_parse_info): New constructor, from
15074 cp_new_demangle_parse_info.
15075 (~demangle_parse_info): New destructor, from
15076 cp_demangled_name_parse_free.
15077 (cp_merge_demangle_parse_infos): Update.
15078 (cp_demangled_name_to_comp): Change return type.
15079
1ac32117
TT
150802017-01-10 Tom Tromey <tom@tromey.com>
15081
15082 * top.c (prevent_dont_repeat): Change return type.
15083 * python/python.c (execute_gdb_command): Use std::string.
15084 Update.
15085 * guile/guile.c (gdbscm_execute_gdb_command): Update.
15086 * command.h (prevent_dont_repeat): Change return type.
15087 * breakpoint.c (bpstat_do_actions_1): Update.
15088
0cf08227
TT
150892017-01-10 Tom Tromey <tom@tromey.com>
15090
15091 * value.h (scoped_value_mark::~scoped_value_mark): Call
15092 free_to_mark.
15093 (scoped_value_mark::free_to_mark): New method.
15094 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use
15095 scoped_value_mark.
15096
eb115069
TT
150972017-01-10 Tom Tromey <tom@tromey.com>
15098
15099 * python/py-value.c (valpy_dereference, valpy_referenced_value)
15100 (valpy_reference_value, valpy_const_value, valpy_get_address)
15101 (valpy_get_dynamic_type, valpy_lazy_string, valpy_do_cast)
15102 (valpy_getitem, valpy_call, valpy_binop_throw, valpy_negative)
15103 (valpy_absolute, valpy_richcompare_throw): Use scoped_value_mark.
15104 * dwarf2loc.c (dwarf2_loc_desc_get_symbol_read_needs): Use
15105 scoped_value_mark.
15106 * dwarf2-frame.c (execute_stack_op): Use scoped_value_mark.
15107 * value.h (scoped_value_mark): New class.
15108
906768f9
TT
151092017-01-10 Tom Tromey <tom@tromey.com>
15110
15111 * dwarf2read.c (dwarf2_build_psymtabs): Use psymtab_discarder.
15112 * psympriv.h (make_cleanup_discard_psymtabs): Don't declare.
15113 * psymtab.c (discard_psymtabs_upto): Remove.
15114 (make_cleanup_discard_psymtabs): Remove.
15115 (struct psymtab_state): Remove.
15116
bef155c3
TT
151172017-01-10 Tom Tromey <tom@tromey.com>
15118
15119 * record-full.c (record_full_save_cleanups): Remove.
15120 (record_full_save): Use gdb::unlinker.
15121 * gcore.c (do_bfd_delete_cleanup): Remove.
15122 (gcore_command): Use gdb::unlinker, unique_xmalloc_ptr. Remove
15123 cleanups.
15124 * dwarf2read.c (unlink_if_set): Remove.
15125 (write_psymtabs_to_index): Use gdb::unlinker.
15126 * common/gdb_unlinker.h: New file.
15127
192b62ce
TT
151282017-01-10 Tom Tromey <tom@tromey.com>
15129
15130 * windows-tdep.c (windows_xfer_shared_library): Update.
15131 * windows-nat.c (windows_make_so): Update.
15132 * utils.h (make_cleanup_bfd_unref): Remove.
15133 * utils.c (do_bfd_close_cleanup, make_cleanup_bfd_unref): Remove.
15134 * symfile.h (symfile_bfd_open)
15135 (find_separate_debug_file_in_section): Return gdb_bfd_ref_ptr.
15136 * symfile.c (read_symbols, symbol_file_add)
15137 (separate_debug_file_exists): Update.
15138 (symfile_bfd_open): Return gdb_bfd_ref_ptr.
15139 (generic_load, reread_symbols): Update.
15140 * symfile-mem.c (symbol_file_add_from_memory): Update.
15141 * spu-linux-nat.c (spu_bfd_open): Return gdb_bfd_ref_ptr.
15142 (spu_symbol_file_add_from_memory): Update.
15143 * solist.h (struct target_so_ops) <bfd_open>: Return
15144 gdb_bfd_ref_ptr.
15145 (solib_bfd_fopen, solib_bfd_open): Return gdb_bfd_ref_ptr.
15146 * solib.c (solib_bfd_fopen, solib_bfd_open): Return
15147 gdb_bfd_ref_ptr.
15148 (solib_map_sections, reload_shared_libraries_1): Update.
15149 * solib-svr4.c (enable_break): Update.
15150 * solib-spu.c (spu_bfd_fopen): Return gdb_bfd_ref_ptr.
15151 * solib-frv.c (enable_break2): Update.
15152 * solib-dsbt.c (enable_break): Update.
15153 * solib-darwin.c (gdb_bfd_mach_o_fat_extract): Return
15154 gdb_bfd_ref_ptr.
15155 (darwin_solib_get_all_image_info_addr_at_init): Update.
15156 (darwin_bfd_open): Return gdb_bfd_ref_ptr.
15157 * solib-aix.c (solib_aix_bfd_open): Return gdb_bfd_ref_ptr.
15158 * record-full.c (record_full_save): Update.
15159 * python/py-objfile.c (objfpy_add_separate_debug_file): Update.
15160 * procfs.c (insert_dbx_link_bpt_in_file): Update.
15161 * minidebug.c (find_separate_debug_file_in_section): Return
15162 gdb_bfd_ref_ptr.
15163 * machoread.c (macho_add_oso_symfile): Change abfd to
15164 gdb_bfd_ref_ptr.
15165 (macho_symfile_read_all_oso): Update.
15166 (macho_check_dsym): Return gdb_bfd_ref_ptr.
15167 (macho_symfile_read): Update.
15168 * jit.c (bfd_open_from_target_memory): Return gdb_bfd_ref_ptr.
15169 (jit_bfd_try_read_symtab): Update.
15170 * gdb_bfd.h (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15171 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15172 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15173 gdb_bfd_ref_ptr.
15174 (gdb_bfd_ref_policy): New struct.
15175 (gdb_bfd_ref_ptr): New typedef.
15176 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
15177 (gdb_bfd_openw, gdb_bfd_openr_iovec)
15178 (gdb_bfd_openr_next_archived_file, gdb_bfd_fdopenr): Return
15179 gdb_bfd_ref_ptr.
15180 * gcore.h (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15181 * gcore.c (create_gcore_bfd): Return gdb_bfd_ref_ptr.
15182 (gcore_command): Update.
15183 * exec.c (exec_file_attach): Update.
15184 * elfread.c (elf_symfile_read): Update.
15185 * dwarf2read.c (dwarf2_get_dwz_file): Update.
15186 (try_open_dwop_file, open_dwo_file): Return gdb_bfd_ref_ptr.
15187 (open_and_init_dwo_file): Update.
15188 (open_dwp_file): Return gdb_bfd_ref_ptr.
15189 (open_and_init_dwp_file): Update.
15190 * corelow.c (core_open): Update.
15191 * compile/compile-object-load.c (compile_object_load): Update.
15192 * common/gdb_ref_ptr.h (ref_ptr::operator->): New operator.
15193 * coffread.c (coff_symfile_read): Update.
15194 * cli/cli-dump.c (bfd_openr_or_error, bfd_openw_or_error): Return
15195 gdb_bfd_ref_ptr. Rename.
15196 (dump_bfd_file, restore_command): Update.
15197 * build-id.h (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15198 * build-id.c (build_id_to_debug_bfd): Return gdb_bfd_ref_ptr.
15199 (find_separate_debug_file_by_buildid): Update.
15200
50315b21
TT
152012017-01-10 Tom Tromey <tom@tromey.com>
15202
15203 * common/gdb_ref_ptr.h: New file.
15204 * python/py-ref.h (struct gdbpy_ref_policy): New.
15205 (gdbpy_ref): Now a typedef.
15206
fc4007c9
TT
152072017-01-10 Tom Tromey <tom@tromey.com>
15208
15209 * utils.h (make_cleanup_htab_delete): Don't declare.
15210 * utils.c (do_htab_delete_cleanup, make_cleanup_htab_delete):
15211 Remove.
15212 * linespec.c (decode_compound_collector): Add constructor,
15213 destructor.
15214 (lookup_prefix_sym): Remove cleanup.
15215 (symtab_collector): Add constructor, destructor.
15216 (collect_symtabs_from_filename): Remove cleanup.
15217 * disasm.c (do_mixed_source_and_assembly): Use htab_up.
15218 * compile/compile-c-symbols.c (generate_c_for_variable_locations):
15219 Use htab_up.
15220 * gnu-v3-abi.c (gnuv3_print_vtable): Use htab_up.
15221 * dwarf2read.c (dw2_expand_symtabs_matching)
15222 (dw2_map_symbol_filenames, dwarf_decode_macros)
15223 (write_psymtabs_to_index): Use htab_up.
15224 * dwarf2loc.c (func_verify_no_selftailcall)
15225 (call_site_find_chain_1, func_verify_no_selftailcall)
15226 (chain_candidate, call_site_find_chain_1): Use std::unordered_set,
15227 std::vector, gdb::unique_xmalloc_ptr.
15228 (call_sitep): Remove typedef.
15229 (dwarf2_locexpr_baton_eval): Remove unused variable.
15230
8dbcee67
TT
152312017-01-10 Tom Tromey <tom@tromey.com>
15232
15233 * python/python-internal.h (make_cleanup_py_decref)
15234 (make_cleanup_py_xdecref): Don't declare.
15235 * python/py-utils.c (py_decref, make_cleanup_py_decref)
15236 (py_xdecref, make_cleanup_py_xdecref): Remove.
15237
13df46cc
TT
152382017-01-10 Tom Tromey <tom@tromey.com>
15239
15240 * python/py-framefilter.c (py_mi_print_variables): Use gdbpy_ref.
15241 (py_print_locals, enumerate_locals, py_print_args): Use gdbpy_ref.
15242
06fc9bf7
TT
152432017-01-10 Tom Tromey <tom@tromey.com>
15244
15245 * python/py-framefilter.c (enumerate_args): Use gdbpy_ref.
15246
830a4934
TT
152472017-01-10 Tom Tromey <tom@tromey.com>
15248
15249 * python/py-utils.c (unicode_to_encoded_string)
15250 (python_string_to_target_string)
15251 (python_string_to_target_python_string)
15252 (python_string_to_host_string, gdbpy_obj_to_string)
15253 (get_addr_from_python): Use gdbpy_ref.
15254
4586d543
TT
152552017-01-10 Tom Tromey <tom@tromey.com>
15256
15257 * python/py-unwind.c (pyuw_object_attribute_to_pointer): Use
15258 gdbpy_ref.
15259
59876f8f
TT
152602017-01-10 Tom Tromey <tom@tromey.com>
15261
15262 * python/python.c (eval_python_command, gdbpy_decode_line)
15263 (gdbpy_run_events, gdbpy_start_type_printers)
15264 (gdbpy_apply_type_printers): Use gdbpy_ref.
15265
97d83487
TT
152662017-01-10 Tom Tromey <tom@tromey.com>
15267
15268 * python/py-param.c (get_doc_string, compute_enum_values): Use
15269 gdbpy_ref.
15270
9205649a
TT
152712017-01-10 Tom Tromey <tom@tromey.com>
15272
15273 * python/py-inferior.c (find_thread_object, build_inferior_list):
15274 Use gdbpy_ref.
15275
74c49d45
TT
152762017-01-10 Tom Tromey <tom@tromey.com>
15277
15278 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15279
16361ffb
TT
152802017-01-10 Tom Tromey <tom@tromey.com>
15281
15282 * python/py-finishbreakpoint.c (bpfinishpy_out_of_scope): Use
15283 gdbpy_ref.
15284
905f2cca
TT
152852017-01-10 Tom Tromey <tom@tromey.com>
15286
15287 * python/py-cmd.c (cmdpy_completer_helper): Use gdbpy_ref. Remove
15288 extra incref.
15289 (cmdpy_completer_handle_brkchars, cmdpy_completer, cmdpy_init):
15290 Use gdbpy_ref.
15291
64081434
TT
152922017-01-10 Tom Tromey <tom@tromey.com>
15293
15294 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15295 gdbpy_ref.
15296
59e9e831
TT
152972017-01-10 Tom Tromey <tom@tromey.com>
15298
15299 * python/py-arch.c (archpy_disassemble): Use gdbpy_ref. Don't
15300 decref results of PyArg_ParseTupleAndKeywords.
15301
9de10f6d
TT
153022017-01-10 Tom Tromey <tom@tromey.com>
15303
15304 * python/python.c (python_run_simple_file): Use
15305 unique_xmalloc_ptr, gdbpy_ref.
15306
2bd5759d
TT
153072017-01-10 Tom Tromey <tom@tromey.com>
15308
15309 * python/py-prettyprint.c (print_stack_unless_memory_error)
15310 (print_string_repr, print_children): Use gdbpy_ref.
15311 (dummy_python_frame): New class.
15312 (dummy_python_frame::dummy_python_frame): Rename from
15313 push_dummy_python_frame.
15314 (py_restore_tstate): Remove.
15315
3b4e0e01
TT
153162017-01-10 Tom Tromey <tom@tromey.com>
15317
15318 * python/py-framefilter.c (py_print_frame): Use gdbpy_ref.
15319
17a22718
TT
153202017-01-10 Tom Tromey <tom@tromey.com>
15321
15322 * python/python.c (ensure_python_env, restore_python_env):
15323 Remove.
15324 * python/python-internal.h (ensure_python_env): Don't declare.
15325 * varobj.h (varobj_ensure_python_env): Don't declare.
15326 * varobj.c (varobj_ensure_python_env): Remove.
15327
68cdc557
TT
153282017-01-10 Tom Tromey <tom@tromey.com>
15329
15330 * varobj.c (varobj_value_get_print_value): Use
15331 gdbpy_enter_varobj.
15332
1eba6383
TT
153332017-01-10 Tom Tromey <tom@tromey.com>
15334
15335 * python/py-prettyprint.c (print_string_repr, print_children):
15336 Update.
15337 * python/py-lazy-string.c (gdbpy_extract_lazy_string): Change type
15338 of "encoding".
15339 * varobj.c (varobj_value_get_print_value): Update.
15340 * python/python-internal.h (gdbpy_extract_lazy_string): Update.
15341
bde7b3e3
TT
153422017-01-10 Tom Tromey <tom@tromey.com>
15343
15344 * varobj.c (varobj_get_display_hint)
15345 (dynamic_varobj_has_child_method, install_new_value_visualizer)
15346 (varobj_set_visualizer, free_variable): Use
15347 gdbpy_enter_varobj.
15348
a7785f8c
TT
153492017-01-10 Tom Tromey <tom@tromey.com>
15350
15351 * python/python.c (python_command): Use gdbpy_enter, gdbpy_ref.
15352 (do_finish_initialization): New function. Use gdbpy_ref.
15353 (gdbpy_finish_initialization): Use gdbpy_enter. Call
15354 do_finish_initialization.
15355
2865bfce
TT
153562017-01-10 Tom Tromey <tom@tromey.com>
15357
15358 * python/py-param.c (get_set_value, get_show_value): Use
15359 gdbpy_enter, gdbpy_ref.
15360
0e9dcc75
TT
153612017-01-10 Tom Tromey <tom@tromey.com>
15362
15363 * python/py-function.c (fnpy_call): Use gdbpy_enter, gdbpy_ref.
15364
12a5cedd
TT
153652017-01-10 Tom Tromey <tom@tromey.com>
15366
15367 * python/py-cmd.c (cmdpy_function): Use gdbpy_enter, gdbpy_ref.
15368
788f2586
TT
153692017-01-10 Tom Tromey <tom@tromey.com>
15370
15371 * python/py-varobj.c (py_varobj_iter_dtor, py_varobj_iter_next):
15372 Use gdbpy_enter_varobj.
15373
6cd67bea
TT
153742017-01-10 Tom Tromey <tom@tromey.com>
15375
15376 * varobj.c (gdbpy_enter_varobj): New constructor.
15377 * python/python-internal.h (gdbpy_enter_varobj): New class.
15378 * python/py-varobj.c (py_varobj_get_iterator): Use
15379 gdbpy_enter_varobj.
15380
14b122bf
TT
153812017-01-10 Tom Tromey <tom@tromey.com>
15382
15383 * python/py-xmethods.c (gdbpy_get_xmethod_result_type): Use
15384 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15385 (gdbpy_invoke_xmethod): Use gdbpy_ref, gdbpy_enter.
15386 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref,
15387 unique_xmalloc_ptr.
15388 (gdbpy_get_xmethod_arg_types): Use gdbpy_ref, gdbpy_enter.
15389
bf1ca3b9
TT
153902017-01-10 Tom Tromey <tom@tromey.com>
15391
15392 * python/py-xmethods.c (invoke_match_method): Use
15393 gdbpy_ref.
15394
572a5524
TT
153952017-01-10 Tom Tromey <tom@tromey.com>
15396
15397 * python/py-xmethods.c (gdbpy_get_matching_xmethod_workers): use
15398 gdbpy_enter, gdbpy_ref.
15399
396a78b6
TT
154002017-01-10 Tom Tromey <tom@tromey.com>
15401
15402 * python/python.c (python_interactive_command): Use gdbpy_enter.
15403
a88b13c7
TT
154042017-01-10 Tom Tromey <tom@tromey.com>
15405
15406 * python/python.c (gdbpy_before_prompt_hook): Use gdbpy_enter,
15407 gdbpy_ref.
15408
e9f0c363
TT
154092017-01-10 Tom Tromey <tom@tromey.com>
15410
15411 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Use
15412 gdbpy_enter, gdbpy_ref, unique_xmalloc_ptr.
15413
6349f452
TT
154142017-01-10 Tom Tromey <tom@tromey.com>
15415
15416 * utils.h (htab_deleter): New struct.
15417 (htab_up): New typedef.
15418 * python/py-framefilter.c (gdbpy_apply_frame_filter): Use
15419 gdbpy_enter, gdbpy_ref, htab_up.
15420
c0171de6
TT
154212017-01-10 Tom Tromey <tom@tromey.com>
15422
15423 * python/py-unwind.c (pending_frame_invalidate): Remove.
15424 (pyuw_sniffer): Use gdbpy_enter and gdbpy_ref.
15425
f18e226f
TT
154262017-01-10 Tom Tromey <tom@tromey.com>
15427
15428 * python/py-xmethods.c (gdbpy_free_xmethod_worker_data)
15429 (gdbpy_clone_xmethod_worker_data): Use gdbpy_enter.
15430
c57af3f1
TT
154312017-01-10 Tom Tromey <tom@tromey.com>
15432
15433 * python/py-type.c (save_objfile_types): Use gdbpy_enter.
15434
60e600ec
TT
154352017-01-10 Tom Tromey <tom@tromey.com>
15436
15437 * python/python.c (gdbpy_eval_from_control_command)
15438 (gdbpy_source_script, gdbpy_run_events)
15439 (gdbpy_source_objfile_script, gdbpy_execute_objfile_script)
15440 (gdbpy_free_type_printers, gdbpy_finish_initialization): Use
15441 gdbpy_enter.
15442
bf7da5b0
TT
154432017-01-10 Tom Tromey <tom@tromey.com>
15444
15445 * python/py-progspace.c (py_free_pspace): Use gdbpy_enter.
15446
2d38bced
TT
154472017-01-10 Tom Tromey <tom@tromey.com>
15448
15449 * python/py-objfile.c (py_free_objfile): Use gdbpy_enter.
15450
07bc7329
TT
154512017-01-10 Tom Tromey <tom@tromey.com>
15452
15453 * python/py-inferior.c (python_on_normal_stop, python_on_resume)
15454 (python_on_inferior_call_pre, python_on_inferior_call_post)
15455 (python_on_memory_change, python_on_register_change)
15456 (python_inferior_exit, python_new_objfile, add_thread_object)
15457 (delete_thread_object, py_free_inferior): Use gdbpy_enter.
15458
6e7c365e
TT
154592017-01-10 Tom Tromey <tom@tromey.com>
15460
15461 * python/py-finishbreakpoint.c (bpfinishpy_handle_stop)
15462 (bpfinishpy_handle_exit): Use gdbpy_enter.
15463
6ba0cd40
TT
154642017-01-10 Tom Tromey <tom@tromey.com>
15465
15466 * python/py-cmd.c (cmdpy_destroyer)
15467 (cmdpy_completer_handle_brkchars, cmdpy_completer): Use
15468 gdbpy_enter.
15469
de2dc875
TT
154702017-01-10 Tom Tromey <tom@tromey.com>
15471
15472 * python/py-breakpoint.c (gdbpy_breakpoint_cond_says_stop): Use
15473 gdbpy_enter.
15474 (gdbpy_breakpoint_has_cond): Likewise.
15475
4ecee2c4
TT
154762017-01-10 Tom Tromey <tom@tromey.com>
15477
15478 * python/python.c (gdbpy_enter): New constructor.
15479 (~gdbpy_enter): New destructor.
15480 (restore_python_env, ensure_python_env): Rewrite.
15481 * python/python-internal.h (gdbpy_enter): New class.
15482
37fce74f
TT
154832017-01-10 Tom Tromey <tom@tromey.com>
15484
15485 * python/py-symbol.c (gdbpy_lookup_symbol): Use gdbpy_ref.
15486
53a0cca3
TT
154872017-01-10 Tom Tromey <tom@tromey.com>
15488
15489 * python/py-value.c (value_has_field, get_field_flag)
15490 (get_field_type, valpy_getitem, convert_value_from_python): Use
15491 gdbpy_ref.
15492
ff3724f5
TT
154932017-01-10 Tom Tromey <tom@tromey.com>
15494
15495 * python/python.c (gdbpy_progspaces, gdbpy_objfiles): Use
15496 gdbpy_ref.
15497
0700aea5
TT
154982017-01-10 Tom Tromey <tom@tromey.com>
15499
15500 * python/py-prettyprint.c (search_pp_list)
15501 (find_pretty_printer_from_objfiles)
15502 (find_pretty_printer_from_progspace)
15503 (find_pretty_printer_from_gdb, find_pretty_printer)
15504 (gdbpy_get_display_hint, gdbpy_get_varobj_pretty_printer): Use
15505 gdbpy_ref.
15506
1bb44c9f
TT
155072017-01-10 Tom Tromey <tom@tromey.com>
15508
15509 * python/py-param.c (call_doc_function): Use gdbpy_ref.
15510
87ce03fd
TT
155112017-01-10 Tom Tromey <tom@tromey.com>
15512
15513 * python/py-linetable.c (build_line_table_tuple_from_pcs)
15514 (ltpy_get_all_source_lines): Use gdbpy_ref.
15515
ee0a3fb8
TT
155162017-01-10 Tom Tromey <tom@tromey.com>
15517
15518 * python/py-framefilter.c (extract_sym, extract_value)
15519 (get_py_iter_from_func, bootstrap_python_frame_filters): Use
15520 gdbpy_ref.
15521
bf2a52fa
TT
155222017-01-10 Tom Tromey <tom@tromey.com>
15523
15524 * python/py-breakpoint.c (gdbpy_breakpoints): Use gdbpy_ref.
15525
f59fe7f8
TT
155262017-01-10 Tom Tromey <tom@tromey.com>
15527
15528 * python/py-inferior.c (gdbpy_inferiors): Use gdbpy_ref.
15529
80bd970a
TT
155302017-01-10 Tom Tromey <tom@tromey.com>
15531
15532 * python/py-function.c (convert_values_to_python, fnpy_init): Use
15533 gdbpy_ref.
15534
d1b3de2e
TT
155352017-01-10 Tom Tromey <tom@tromey.com>
15536
15537 * python/py-cmd.c (gdbpy_string_to_argv): Use gdbpy_ref.
15538
3bb43384
TT
155392017-01-10 Tom Tromey <tom@tromey.com>
15540
15541 * python/py-type.c (convert_field, make_fielditem, typy_fields)
15542 (typy_range): Use gdbpy_ref.
15543
abf5651e
TT
155442017-01-10 Tom Tromey <tom@tromey.com>
15545
15546 * python/py-threadevent.c (create_thread_event_object): Use
15547 gdbpy_ref.
15548 * python/py-stopevent.c (create_stop_event_object): Simplify.
15549 (emit_stop_event): Use gdbpy_ref.
15550 * python/py-signalevent.c (create_signal_event_object): Use
15551 gdbpy_ref.
15552 * python/py-newobjfileevent.c (create_new_objfile_event_object)
15553 (emit_new_objfile_event, create_clear_objfiles_event_object)
15554 (emit_clear_objfiles_event): Use gdbpy_ref.
15555 * python/py-infevents.c (create_inferior_call_event_object)
15556 (create_register_changed_event_object)
15557 (create_memory_changed_event_object, emit_inferior_call_event)
15558 (emit_memory_changed_event, emit_register_changed_event): Use
15559 gdbpy_ref.
15560 * python/py-exitedevent.c (create_exited_event_object)
15561 (emit_exited_event): Use gdbpy_ref.
15562 * python/py-event.h (evpy_emit_event): Remove
15563 CPYCHECKER_STEALS_REFERENCE_TO_ARG annotation.
15564 * python/py-event.c (evpy_emit_event): Use gdbpy_ref.
15565 * python/py-continueevent.c (emit_continue_event): Use
15566 gdbpy_ref.
15567 * python/py-breakpoint.c (gdbpy_breakpoint_created)
15568 (gdbpy_breakpoint_deleted, gdbpy_breakpoint_modified): Use
15569 gdbpy_ref.
15570 * python/py-bpevent.c (create_breakpoint_event_object): Use
15571 gdbpy_ref.
15572
a68ff33e
TT
155732017-01-10 Tom Tromey <tom@tromey.com>
15574
15575 * python/py-ref.h: New file.
15576
7becfd03
SM
155772017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15578
15579 * cli-out.c (cli_ui_out::do_redirect): Change return type to
15580 void.
15581 * cli-out.h (cli_ui_out::do_redirect): Likewise.
15582 * mi/mi-out.c (mi_ui_out::do_redirect): Likewise.
15583 * mi/mi-out.h (mi_ui_out::do_redirect): Likewise.
15584 * ui-out.c (ui_out::redirect): Likewise.
15585 * ui-out.h (ui_out::redirect, ui_out::do_redirect): Likewise.
15586 * cli/cli-logging.c (set_logging_redirect): Update call site of
15587 ui_out::redirect.
15588 (handle_redirections): Likewise.
15589 * scm-ports.c (ioscm_with_output_to_port_worker): Likewise.
15590 * top.c (execute_command_to_string): Likewise.
15591 * utils.c (do_ui_out_redirect_pop): Likewise.
15592
df294654
SM
155932017-01-10 Simon Marchi <simon.marchi@ericsson.com>
15594
15595 * stack.c (_initialize_stack): Update "frame" command help message.
15596
f5e6296e
IB
155972017-01-08 Iain Buclaw <ibuclaw@gdcproject.org>
15598
15599 * d-exp.y (CastExpression): Emit UNOP_CAST_TYPE.
15600
0e2d6fa6
YQ
156012017-01-06 Yao Qi <yao.qi@linaro.org>
15602
15603 * x86-linux-nat.h: Include gdb_proc_service.h.
15604
44d6d3f9
YQ
156052017-01-06 Yao Qi <yao.qi@linaro.org>
15606
15607 * ser-base.h: Include serial.h.
15608
656731fe
YQ
156092017-01-06 Yao Qi <yao.qi@linaro.org>
15610
15611 * ppc-linux-tdep.h: Include ppc-tdep.h.
15612
1ca8f924
YQ
156132017-01-06 Yao Qi <yao.qi@linaro.org>
15614
15615 * nat/amd64-linux-siginfo.h: Include signal.h.
15616
bc3008c4
YQ
156172017-01-06 Yao Qi <yao.qi@linaro.org>
15618
15619 * nat/aarch64-linux-hw-point.h: Include break-common.h.
15620
66c80d03
YQ
156212017-01-06 Yao Qi <yao.qi@linaro.org>
15622
15623 * mi/mi-parse.h: Include mi-cmds.h.
15624
051d2dda
YQ
156252017-01-06 Yao Qi <yao.qi@linaro.org>
15626
15627 * inf-loop.c: Don't include "target.h".
15628 * inf-loop.h: Include it here.
15629
8018d34f
YQ
156302017-01-06 Yao Qi <yao.qi@linaro.org>
15631
15632 * dfp.h: Include "dboulest.h" and "expression.h".
15633
c0b8369c
YQ
156342017-01-06 Yao Qi <yao.qi@linaro.org>
15635
15636 * ax-gdb.h: Include "ax.h".
15637
ad5cba2a
YQ
156382017-01-06 Yao Qi <yao.qi@linaro.org>
15639
15640 * Makefile.in (HFILES_NO_SRCDIR): Replace gdb_ptrace.h
15641 with nat/gdb_ptrace.h.
15642
1c33cd7f
YQ
156432017-01-05 Yao Qi <yao.qi@linaro.org>
15644
15645 * mips-fbsd-tdep.c (mips_fbsd_sigframe_init): Move && to
15646 new line.
15647 (mips64_fbsd_sigframe_init): Likewise.
15648
c988ac1d
JB
156492017-01-04 John Baldwin <jhb@FreeBSD.org>
15650
15651 * mips-fbsd-tdep.c (_initialize_mips_fbsd_tdep): Use
15652 GDB_OSABI_FREEBSD instead of GDB_OSABI_FREEBSD_ELF.
15653
b268007c
JB
156542017-01-04 John Baldwin <jhb@FreeBSD.org>
15655
15656 * Makefile.in (ALLDEPFILES): Add mips-fbsd-nat.c.
15657 * NEWS: Mention new FreeBSD/mips native configuration.
15658 * config/mips/fbsd.mh: New file.
15659 * configure.host: Add mips*-*-freebsd*.
15660 * mips-fbsd-nat.c: New file.
15661
387360da
JB
156622017-01-04 John Baldwin <jhb@FreeBSD.org>
15663
15664 * Makefile.in (ALL_TARGET_OBS): Add mips-fbsd-tdep.o.
15665 (ALLDEPFILES): Add mips-fbsd-tdep.c.
15666 * NEWS: Mention new FreeBSD/mips target.
15667 * configure.tgt: Add mips*-*-freebsd*.
15668 * mips-fbsd-tdep.c: New file.
15669 * mips-fbsd-tdep.h: New file.
15670
2aaaf250
YQ
156712017-01-04 Yao Qi <yao.qi@linaro.org>
15672
15673 * dwarf2loc.c (write_pieced_value): Don't use VALUE_FRAME_ID (to),
15674 use c->frame_id when the piece location is DWARF_VALUE_REGISTER.
15675
61baf725
JB
156762017-01-01 Joel Brobecker <brobecker@adacore.com>
15677
6dbb839a 15678 Update copyright year range in all GDB files.
61baf725 15679
c113e7ff 156802017-01-01 Joel Brobecker <brobecker@adacore.com>
ce0db137 15681
c113e7ff 15682 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2016.
ce0db137 15683
c113e7ff 15684For older changes see ChangeLog-2016.
c906108c
SS
15685\f
15686Local Variables:
15687mode: change-log
15688left-margin: 8
15689fill-column: 74
15690version-control: never
57da7796 15691coding: utf-8
c906108c 15692End: