1 2018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
3 * target.h (target_options_to_string): Return an std::string.
4 * target.c (str_comma_list_concat_elem): Return void, use
7 (target_options_to_string): Return an std::string.
8 * linux-nat.c (linux_nat_target::wait): Adjust.
9 * target-debug.h (target_debug_print_options): Adjust.
11 2018-08-07 Tom Tromey <tom@tromey.com>
13 * Makefile.in (CPPFLAGS): New variable.
14 (INTERNAL_CPPFLAGS): Use it.
16 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
18 * NEWS: Mention the index cache.
20 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
22 * common/pathstuff.h (get_standard_cache_dir): New.
23 * common/pathstuff.c (get_standard_cache_dir): New.
24 * build-id.h (build_id_to_string): New.
25 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
26 DEBUG_STR_SUFFIX): Move to here.
27 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
28 DEBUG_STR_SUFFIX): Move from there.
29 (write_psymtabs_to_index): Make non-static, add basename
30 parameter. Write to temporary files, rename when done.
31 (save_gdb_index_command): Adjust call to
32 write_psymtabs_to_index.
33 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
35 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
36 (get_gdb_index_contents_from_cache): New.
37 (get_gdb_index_contents_from_cache_dwz): New.
38 (dwarf2_initialize_objfile): Read index from cache.
39 (dwarf2_build_psymtabs): Save to index.
40 * dwarf-index-cache.h: New file.
41 * dwarf-index-cache.c: New file.
42 * dwarf-index-write.h: New file.
44 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
46 * gnulib/aclocal.m4: Re-generate.
47 * gnulib/config.in: Re-generate.
48 * gnulib/configure: Re-generate.
49 * gnulib/import/Makefile.am: Re-generate.
50 * gnulib/import/Makefile.in: Re-generate.
51 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
52 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
53 * gnulib/import/m4/mkdir.m4: New file.
54 * gnulib/import/mkdir.c: New file.
55 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
58 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
60 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
61 * common/scoped_mmap.c: New file.
62 * common/scoped_mmap.h (destroy): New method.
63 (~scoped_mmap, reset): Use destroy.
64 (scoped_mmap): New move constructor.
65 (mmap_file): New declaration.
66 * unittests/scoped_mmap-selftests.c (test_normal,
67 test_invalid_filename, run_tests): New functions.
68 (_initialize_scoped_mmap_selftests): Register selftest.
70 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
72 * dwarf2read.c (read_gdb_index_from_section): Rename to...
73 (read_gdb_index_from_buffer): ... this. Remove section
74 parameter, add buffer parameter.
75 (get_gdb_index_contents_ftype,
76 get_gdb_index_contents_dwz_ftype): New typedefs.
77 (dwarf2_read_gdb_index): Add callback parameters to get the
79 (get_gdb_index_contents_from_section): New.
80 (dwarf2_initialize_objfile): Update call to
81 dwarf2_read_gdb_index.
83 2018-08-07 Simon Marchi <simon.marchi@ericsson.com>
85 * common/filestuff.h (gdb_fopen_cloexec): New overload.
86 (gdb_open_cloexec): Likewise.
87 * nat/linux-osdata.c (command_from_pid): Use string_printf.
88 (commandline_from_pid): Likewise.
89 (linux_xfer_osdata_threads): Likewise.
90 (linux_xfer_osdata_fds): Likewise.
91 * ada-lang.c (is_package_name): Likewise.
92 * auxv.c (procfs_xfer_auxv): Likewise.
93 * breakpoint.c (print_one_breakpoint_location): Use
95 (print_one_catch_solib): Use string_printf.
96 * coff-pe-read.c (add_pe_exported_sym): Likewise.
97 (add_pe_forwarded_sym): Likewise.
98 * dwarf2read.c (create_type_unit_group): Likewise.
99 (build_error_marker_type): Likewise.
100 * infcall.c (get_function_name): Likewise.
101 * valprint.c (print_converted_chars_to_obstack): Likewise.
102 * xtensa-tdep.c (xtensa_register_type): Likewise.
104 2018-08-06 Simon Marchi <simon.marchi@ericsson.com>
106 * remote.c (remote_target::download_tracepoint): Fix format
109 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
111 * tracefile.c: Include common/byte-vector.h.
112 (trace_save): Change type of buf to gdb::byte_vector. Initialize
113 with trace_regblock_size if needed. Update uses of buf.
115 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
117 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
118 std::vector<unsigned char>.
119 * tracepoint.c (collection_list::collection_list): Remove
120 m_regs_mask initializer from initializer list. Resize
121 m_regs_mask using the largest remote register number.
122 (collection_list::add_remote_register): Remove size check on
123 m_regs_mask. Use at to access element.
124 (collection_list::stringify): Change type of temp_buf to
125 gdb::char_vector. Update uses of temp_buf. Resize if needed to
126 stringify the register mask. Use pack_hex_byte for the register
129 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
131 * tracepoint.h (class collection_list) <add_register>: Remove.
132 <add_remote_register, add_ax_registers, add_local_register>:
134 <add_memrange>: Add scope parameter.
135 * tracepoint.c (encode_actions_1): Likewise.
136 (collection_list::add_register): Rename to ...
137 (collection_list::add_remote_register): ... this. Update
139 (collection_list::add_ax_registers, add_local_register): New
141 (collection_list::add_memrange): Add scope parameter. Call
142 add_local_register instead of add_register.
143 (finalize_tracepoint_aexpr): New function.
144 (collection_list::collect_symbol): Update calls to add_memrange.
145 Call add_local_register instead of add_register. Call
146 add_ax_registers. Call finalize_tracepoint_aexpr.
147 (encode_actions_1): Get remote regnos for $reg action. Call
148 add_remote_register, add_ax_registers, and add_local_register.
149 Update call to add_memrange. Call finalize_tracepoint_aexpr.
150 (validate_actionline): Call finalize_tracepoint_aexpr.
152 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
154 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
155 Replace array buf with gdb::char_vector buf, of size
156 get_remote_packet_size (). Replace references to buf and
157 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
158 and xsnprintf with snprintf. Raise errors if the buffer is too
161 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
163 * remote.c (remote_target::download_tracepoint): Fix the has_more
164 predicate in the QTDP action list iteration.
166 2018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
168 * remote.c (remote_target::download_tracepoint): Fix indentation
171 2018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
173 * proc-api.c (_initialize_proc_api): Remove c, unused.
174 * procfs.c (procfs_init_inferior): Remove signals, unused.
175 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
178 2018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
179 Andrew Burgess <andrew.burgess@embecosm.com>
181 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
182 'W_STOPCODE (0)' as this could be ambiguous.
184 2018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
186 * ser-tcp.c (net_open): Fix thinko when deciding whether to
187 disable TCP's Nagle algorithm (use "ai_protocol" instead of
190 2018-08-02 Tom Tromey <tom@tromey.com>
193 * dwarf2read.c (read_func_scope): Set symtab on template parameter
195 (process_structure_scope): Likewise.
197 2018-08-02 Xavier Roirand <roirand@adacore.com>
200 * darwin-nat.c (darwin_kill_inferior): Fix handling of
203 2018-08-02 Tom Tromey <tom@tromey.com>
205 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
206 (darwin_suspend_inferior, darwin_resume_inferior)
207 (darwin_decode_notify_message, darwin_resume_inferior_threads)
208 (darwin_check_new_threads): Check result of get_darwin_inferior.
210 2018-07-31 Joel Brobecker <brobecker@adacore.com>
214 2018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
216 * varobj.c (varobj_get_path_expr_parent): Report an error if
217 parent is a dynamic varobj.
219 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
221 * gnulib/aclocal.m4: Re-generate.
222 * gnulib/config.in: Re-generate.
223 * gnulib/configure: Re-generate.
224 * gnulib/import/Makefile.in: Re-generate.
225 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
226 * gnulib/import/m4/onceonly.m4: Re-generate.
228 2018-07-31 Simon Marchi <simon.marchi@ericsson.com>
230 * target-descriptions.c (struct xml_test_tdesc): New.
231 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
232 (record_xml_tdesc): Update.
233 (maintenance_check_xml_descriptions): Update.
234 * target-descriptions.h (record_xml_tdesc): Update comment.
236 2018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
238 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
239 checking array bounds are defined.
241 2018-07-30 Tom Tromey <tom@tromey.com>
243 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
244 irreflexivity violation.
246 2018-07-30 Tom Tromey <tom@tromey.com>
248 * cli/cli-decode.c (lookup_cmd): Remove lint code.
249 * value.c (unpack_long): Remove lint code.
250 * valops.c (value_ind): Remove lint code.
251 * valarith.c (value_x_binop, value_x_unop, value_equal)
252 (value_pos): Remove lint code.
254 2018-07-28 Tom de Vries <tdevries@suse.de>
256 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
257 with undefined upper bound as <optimized out>.
259 2018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
261 * gcore.in: Rename variable "name" to "prefix". Expand
264 2018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
266 * windows-nat.c (windows_nat_target::create_inferior): Update to
267 call close() in global namespace.
269 2018-07-26 Tom Tromey <tom@tromey.com>
271 * dwarf-index-write.c (add_address_entry): Don't add objfile
273 * dbxread.c (find_stab_function): Rename from
274 find_stab_function_addr. Return a bound_minimal_symbol.
275 (read_dbx_symtab): Use raw_text_low, raw_text_high.
276 Don't add objfile offsets.
277 (end_psymtab): Use raw_text_low, raw_text_high,
278 MSYMBOL_VALUE_RAW_ADDRESS.
279 (read_ofile_symtab): Update.
280 (process_one_symbol): Update.
281 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
283 (dw2_relocate): Remove.
284 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
286 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
288 (process_psymtab_comp_unit_reader, add_partial_symbol)
289 (add_partial_subprogram, dwarf2_ranges_read): Update.
290 (load_partial_dies): Update.
291 (add_address_entry): Don't add objfile offsets.
292 (dwarf2_build_include_psymtabs): Update.
293 (create_addrmap_from_aranges): Don't add objfile offsets.
294 (dw2_find_pc_sect_compunit_symtab): Update.
295 * mdebugread.c (parse_symbol): Don't add objfile offsets.
296 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
298 (parse_partial_symbols): Don't add objfile offsets. Use
299 raw_text_low, raw_text_high. Update.
300 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
301 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
302 or call 'relocate' quick function. Clear psymbol_map.
303 * psympriv.h (struct partial_symbol) <address>: Add section
305 <set_unrelocated_address>: Rename from set_address.
306 <raw_text_low, raw_text_high>: New methods.
307 <text_low, text_high>: Add objfile parameter.
308 (add_psymbol_to_bcache): Add 'section' parameter. Call
309 set_unrelocated_address.
310 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
311 (find_pc_psymbol): Update.
312 (fixup_psymbol_section, relocate_psymtabs): Remove.
313 (dump_psymtab, psym_functions): Update.
314 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
316 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
317 (start_psymtab_common): Update.
318 * symfile-debug.c (debug_qf_relocate): Remove.
319 (debug_sym_quick_functions): Update.
320 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
321 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
324 2018-07-26 Tom Tromey <tromey@redhat.com>
326 * dbxread.c (end_psymtab): Use text_high_valid and
328 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
329 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
330 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
332 <text_low_valid, text_high_valid>: New fields.
333 <set_text_low, set_text_high>: Update.
334 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
336 2018-07-26 Tom Tromey <tom@tromey.com>
338 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
340 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
341 textlow and texthigh fields.
342 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
344 * mdebugread.c (parse_lines, parse_partial_symbols)
345 (psymtab_to_symtab_1): Update.
346 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
347 Rename fields. Update comment. Now private.
348 <text_low, text_high, set_text_low, set_text_high>: New methods.
349 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
350 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
351 (start_psymtab_common, maintenance_info_psymtabs)
352 (maintenance_check_psymtabs): Update.
353 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
355 (scan_xcoff_symtab): Update.
357 2018-07-26 Tom Tromey <tromey@redhat.com>
359 * psympriv.h (struct partial_symbol) <unrelocated_address,
360 address, set_address>: New methods.
361 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
362 (fixup_psymbol_section, relocate_psymtabs): Update.
363 (print_partial_symbols): Add 'objfile' parameter. Update.
364 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
367 2018-07-26 Tom Tromey <tom@tromey.com>
369 * dwarf-index-write.c (write_psymbols, debug_names::insert)
370 (debug_names::write_psymbols): Update.
371 * psympriv.h (struct partial_symbol): Derive from
373 <obj_section>: New method.
374 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
375 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
376 (find_pc_sect_psymbol, fixup_psymbol_section)
377 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
378 (print_partial_symbols, recursively_search_psymtabs)
379 (compare_psymbols, psymbol_hash, psymbol_compare)
380 (add_psymbol_to_bcache, maintenance_check_psymtabs)
381 (psymbol_name_matches, psym_fill_psymbol_map): Update.
383 2018-07-26 Tom Tromey <tromey@redhat.com>
385 * dbxread.c (end_psymtab): Remove dead code.
387 2018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
389 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
390 DWARF unwinders are disabled.
391 * dwarf2-frame.c: Add dwarf2read.h include.
392 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
394 (dwarf2_frame_unwinders_enabled_p): Define.
395 (show_dwarf_unwinders_enabled_p): New function.
396 (_initialize_dwarf2_frame): Register switch to control DWARF
398 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
399 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
400 (show_dwarf_cmdlist): Remove static keyword.
401 * dwarf2read.h (set_dwarf_cmdlist): Declare.
402 (show_dwarf_cmdlist): Declare.
403 * NEWS: Document new feature.
405 2018-07-26 Tom de Vries <tdevries@suse.de>
408 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
410 2018-07-26 Tom de Vries <tdevries@suse.de>
412 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
413 DW_AT_count can't be translated to a dynamic prop.
415 2018-07-25 Tom de Vries <tdevries@suse.de>
417 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
420 2018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
422 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
424 2018-07-25 Joel Brobecker <brobecker@adacore.com>
426 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
428 2018-07-24 Keith Seitz <keiths@redhat.comt
431 * dwarf2read.c (dw2_add_symbol_to_list): New function.
432 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
433 instead of add_symbol_to_list.
434 (read_file_scope): Call prepare_one_comp_unit before reading
437 2018-07-24 Simon Marchi <simon.marchi@ericsson.com>
439 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
441 2018-07-24 Tom Tromey <tom@tromey.com>
443 * utils.c (malloc, realloc, free): Don't declare.
444 * configure, config.in: Rebuild.
445 * configure.ac: Don't check for declarations of free, malloc, or
448 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
450 * aarch64-linux-nat.c
451 (aarch64_linux_nat_target::stopped_data_address): Remove unused
453 * arm-linux-nat.c (fetch_regs): Likewise.
454 (store_regs): Likewise.
455 (fetch_vfp_regs): Likewise.
456 (store_vfp_regs): Likewise.
457 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
458 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
459 (arm_linux_nat_target::insert_watchpoint): Likewise.
460 (arm_linux_nat_target::remove_watchpoint): Likewise.
461 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
463 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
465 * ppc-linux-nat.c (fetch_register): Likewise.
466 (fetch_all_gp_regs): Likewise.
467 (fetch_ppc_registers): Likewise.
468 (store_all_gp_regs): Likewise.
469 (store_ppc_registers): Likewise.
470 (hwdebug_insert_point): Likewise.
471 (can_use_watchpoint_cond_accel): Likewise.
472 * remote-sim.c (gdb_os_write_stdout): Likewise.
474 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
475 Tom Tromey <tom@tromey.com>
477 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
479 * configure: Rebuild.
481 2018-07-22 Tom Tromey <tom@tromey.com>
483 * regformats/regdat.sh: Define xmltarget_${name} inside
484 #ifndef IN_PROCESS_AGENT.
486 2018-07-22 Tom Tromey <tom@tromey.com>
488 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
490 2018-07-22 Tom Tromey <tom@tromey.com>
492 * symfile.c (reread_symbols): Notify iter, not objfile.
494 2018-07-22 Tom Tromey <tom@tromey.com>
496 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
498 (ravenscar_thread_target::prepare_to_store): Likewise.
500 2018-07-22 Tom Tromey <tom@tromey.com>
502 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
503 unused variable. Call value_fetch_lazy when needed.
504 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
505 Remove unused variable. Call value_fetch_lazy when needed.
507 2018-07-22 Tom Tromey <tom@tromey.com>
509 * m32c-tdep.c (mark_dma): Return void.
510 (make_regs): Remove unused declarations.
512 2018-07-22 Tom Tromey <tom@tromey.com>
514 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
515 cmdscm_get_valid_command_smob_arg_unsafe for effect.
516 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
517 bkscm_get_valid_block_smob_arg_unsafe for effect.
519 2018-07-22 Tom Tromey <tom@tromey.com>
521 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
524 2018-07-22 Tom Tromey <tom@tromey.com>
526 * windows-nat.c (saved_context): Conditionally define.
527 * remote.c (remote_target::remote_btrace_maybe_reopen):
528 Conditionally declare "warned".
529 * inflow.c (sigquit_ours): Conditionally define.
530 (new_tty): Move "tty" declaration inside #if.
531 * guile/guile.c (guile_datadir): Conditionally define.
532 * charset.c (set_be_le_names): Move some declarations inside #if.
533 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
535 (parse_xml_btrace_conf): Likewise.
537 2018-07-22 Tom Tromey <tom@tromey.com>
539 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
541 2018-07-22 Tom Tromey <tom@tromey.com>
543 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
544 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
545 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
546 * buildsym-legacy.c (get_macro_table): Remove unused variable.
547 * stack.c (frame_apply_level_command): Remove unused variable.
548 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
549 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
550 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
552 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
553 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
554 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
556 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
557 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
559 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
560 Remove unused variable.
561 * cli/cli-script.c (recurse_read_control_structure): Remove unused
563 * common/tdesc.c (print_xml_feature::visit): Remove unused
565 * compile/compile-object-load.c (store_regs): Remove unused
567 * complaints.c (clear_complaints): Remove unused variable.
568 * corelow.c (core_target_open): Remove unused variable.
569 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
571 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
573 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
575 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
577 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
579 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
581 * ia64-tdep.c (examine_prologue): Remove unused variable.
582 * infcall.c (run_inferior_call): Remove unused variable.
583 * inferior.c (exit_inferior): Remove unused variable.
584 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
585 * linespec.c (decode_line_2): Remove unused variable.
586 * linux-nat.c (super_close): Remove.
587 * linux-tdep.c (linux_info_proc): Remove unused variable.
588 * mi/mi-main.c (mi_execute_command): Remove unused variable.
589 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
590 Remove unused variable.
591 * parse.c (find_minsym_type_and_address): Remove unused variable.
592 * printcmd.c (info_symbol_command, printf_floating): Remove unused
594 * python/py-breakpoint.c (bppy_set_commands): Remove unused
596 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
598 * record-btrace.c (record_btrace_target::store_registers): Remove
600 (cmd_show_record_btrace_cpu): Remove unused variable.
601 * riscv-tdep.c (riscv_register_reggroup_p)
602 (riscv_push_dummy_call, riscv_return_value): Remove unused
604 * rust-exp.y (literal): Remove unused variable.
605 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
607 <STRUCTOP_ANONYMOUS>: Likewise.
608 * s390-linux-tdep.c (s390_linux_init_abi_31)
609 (s390_linux_init_abi_64): Remove unused variable.
610 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
611 (file_select_thread, net_windows_open, _initialize_ser_windows):
612 Remove unused variables.
613 * symtab.c (find_pc_sect_line): Remove unused variable.
614 * target-memory.c (compute_garbled_blocks): Remove unused
616 (target_write_memory_blocks): Remove unused variable.
617 * target.c (target_stack::unpush): Remove unused variables.
618 * tracepoint.c (start_tracing, all_tracepoint_actions)
619 (merge_uploaded_trace_state_variables)
620 (print_one_static_tracepoint_marker): Remove unused variable.
621 * unittests/basic_string_view/element_access/char/1.cc (test01):
622 Remove unused variable.
623 * windows-nat.c (windows_continue, windows_add_all_dlls)
624 (do_initial_windows_stuff, windows_nat_target::create_inferior):
625 Remove unused variables.
627 2018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
629 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
630 attr_profile in HAVE_ELF.
631 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
634 2018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
636 * frame.c (frame_register_unwind): Change parameter name.
637 (frame_unwind_register): Likewise.
638 (frame_unwind_register_value): Likewise.
639 (frame_unwind_register_signed): Likewise.
640 (frame_unwind_register_unsigned): Likewise.
641 * frame.h (frame_register_unwind): Likewise.
642 (frame_unwind_register): Likewise.
643 (frame_unwind_register_value): Likewise.
644 (frame_unwind_register_signed): Likewise.
645 (frame_unwind_register_unsigned): Likewise.
646 (frame_unwind_arch): Likewise.
648 2018-07-20 Maciej W. Rozycki <macro@mips.com>
650 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
653 2018-07-20 Maciej W. Rozycki <macro@mips.com>
655 * mips-linux-nat.c (mips_linux_nat_target::read_description):
656 Call `get_ptrace_pid' rather than extracting the ptrace PID by
659 2018-07-20 Keith Seitz <keiths@redhat.com>
661 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
662 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
663 m_compunit_symtab, m_language>: Add "m_" prefix.
665 * buildsym.c: Update all uses.
667 2018-07-20 Tom Tromey <tom@tromey.com>
669 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
670 * buildsym.h (record_line_ftype): Remove typedef.
672 2018-07-20 Tom Tromey <tom@tromey.com>
674 * buildsym-legacy.h (augment_type_symtab): Don't declare.
675 (end_expandable_symtab): Likewise.
676 (end_symtab_get_static_block): Likewise.
677 (end_symtab_from_static_block): Likewise.
678 * buildsym-legacy.c (augment_type_symtab): Remove.
679 (end_expandable_symtab): Remove.
680 (end_symtab_get_static_block): Remove.
681 (end_symtab_from_static_block): Remove.
683 2018-07-20 Tom Tromey <tom@tromey.com>
685 * dwarf2read.c: Include buildsym.h.
686 (struct dwarf2_cu) <builder>: New method.
687 (fixup_go_packaging): Update.
688 (process_full_comp_unit, process_full_type_unit): Update. Don't
689 use scoped_free_pendings.
690 (using_directives): Add "cu" parameter, remove "language".
691 (read_import_statement, setup_type_unit_groups, )
692 (read_func_scope, read_lexical_block_scope)
693 (dwarf2_record_block_ranges, read_namespace): Update.
694 (lnp_state_machine::lnp_state_machine): Add cu parameter.
695 (lnp_state_machine::handle_end_sequence): Update.
696 (class lnp_state_machine) <m_cu>: New member.
697 <m_record_line_callback>: Remove.
698 <m_currently_recording_lines>: New member.
699 (lnp_state_machine::handle_set_file): Update.
700 (noop_record_line): Remove.
701 (dwarf_record_line_p): Add cu parameter.
702 (dwarf_record_line_1, dwarf_finish_line): Likewise.
703 (lnp_state_machine::record_line)
704 (lnp_state_machine::lnp_state_machine)
705 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
706 (dwarf_decode_lines): Update.
707 (dwarf2_start_subfile): Add cu parameter.
708 (dwarf2_start_symtab, new_symbol): Update.
709 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
710 Remove dwarf2_per_objfile parameter.
711 (dwarf_decode_macros): Update.
713 2018-07-20 Tom Tromey <tom@tromey.com>
715 * stabsread.c (define_symbol): Update.
716 * buildsym-legacy.h (get_buildsym_compunit): Declare.
717 * dwarf2read.c (new_symbol): Update.
718 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
719 * cp-namespace.c: Include buildsym.h.
720 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
721 * buildsym-legacy.c (get_buildsym_compunit): New function.
723 2018-07-20 Tom Tromey <tom@tromey.com>
725 * xcoffread.c: Include buildsym-legacy.h.
726 * windows-nat.c: Include buildsym-legacy.h.
727 * stabsread.c: Include buildsym-legacy.h.
728 * mdebugread.c: Include buildsym-legacy.h.
729 * buildsym-legacy.h: New file.
730 * buildsym-legacy.c: New file, from buildsym.c.
731 * go32-nat.c: Include buildsym-legacy.h.
732 * dwarf2read.c: Include buildsym-legacy.h.
733 * dbxread.c: Include buildsym-legacy.h.
734 * cp-namespace.c: Include buildsym-legacy.h.
735 * coffread.c: Include buildsym-legacy.h.
736 * buildsym.h: Move some contents to buildsym-legacy.h.
737 * buildsym.c: Include buildsym-legacy.h. Move many functions to
739 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
741 2018-07-20 Tom Tromey <tom@tromey.com>
743 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
744 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
745 (buildsym_compunit::buildsym_compunit)
746 (buildsym_compunit::~buildsym_compunit)
747 (buildsym_compunit::get_macro_table): Define.
749 2018-07-20 Tom Tromey <tom@tromey.com>
751 * buildsym.c (reset_symtab_globals): Remove.
752 (buildsym_compunit::end_symtab_from_static_block): Update.
753 (buildsym_compunit::augment_type_symtab): Update.
754 (end_symtab_from_static_block): Call free_buildsym_compunit.
755 (augment_type_symtab, end_symtab, end_expandable_symtab):
758 2018-07-20 Tom Tromey <tom@tromey.com>
760 * arch-utils.c: Do not include buildsym.h.
761 * mipsread.c: Do not include buildsym.h.
762 * machoread.c: Do not include buildsym.h.
763 * elfread.c: Do not include buildsym.h.
765 2018-07-20 Tom Tromey <tom@tromey.com>
767 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
769 (buildsym_compunit): Add new constructor.
770 (struct buildsym_compunit) <get_last_source_file, finish_block,
771 record_block_range, start_subfile, patch_subfile_names,
772 push_subfile, pop_subfile, record_line, get_compunit_symtab,
773 set_last_source_start_addr, get_last_source_start_addr,
774 get_local_using_directives, set_local_using_directives,
775 get_global_using_directives, outermost_context_p,
776 get_current_context_stack, get_context_stack_depth,
777 get_current_subfile, get_local_symbols, get_file_symbols,
778 get_global_symbols, record_debugformat, record_producer,
779 push_context, pop_context, end_symtab_get_static_block,
780 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
782 <record_pending_block, finish_block_internal, make_blockvector,
783 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
787 2018-05-22 Tom Tromey <tom@tromey.com>
789 * buildsym.c (record_pending_block): Move earlier. Remove objfile
791 (finish_block_internal): Update.
793 2018-07-20 Tom Tromey <tom@tromey.com>
795 * buildsym.c (record_pending_block): Move earlier. Remove objfile
797 (finish_block_internal): Update.
799 2018-07-20 Tom Tromey <tom@tromey.com>
801 * buildsym.h (EXTERN): Don't define or undef.
802 * buildsym.c (EXTERN): Don't define.
804 2018-07-20 Tom Tromey <tom@tromey.com>
806 * buildsym.c: Remove TODO comment.
808 2018-07-20 Tom Tromey <tom@tromey.com>
810 * coffread.c (coff_symtab_read): Update.
811 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
812 (xcoff_new_init): Update.
813 * mipsread.c (mipscoff_new_init): Update.
814 * mdebugread.c (mdebug_build_psymtabs): Update.
815 * elfread.c (elf_new_init): Update.
816 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
818 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
819 (coffstab_build_psymtabs, elfstab_build_psymtabs)
820 (stabsect_build_psymtabs): Update.
821 * buildsym.h (buildsym_init): Don't declare.
822 * buildsym.c: Update comment.
823 (prepare_for_building): Remove.
824 (start_symtab, restart_symtab): Update.
825 (reset_symtab_globals): Update comment.
826 (buildsym_init): Remove.
828 2018-07-20 Tom Tromey <tom@tromey.com>
830 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
831 * stabsread.c (patch_block_stabs, define_symbol, read_type)
832 (read_enum_type, common_block_start, common_block_end)
833 (cleanup_undefined_types_1, finish_global_stabs): Update.
834 * mdebugread.c (psymtab_to_symtab_1): Update.
835 * dwarf2read.c (fixup_go_packaging, read_func_scope)
836 (read_lexical_block_scope, new_symbol): Update.
837 * dbxread.c (process_one_symbol): Update.
838 * coffread.c (coff_symtab_read, process_coff_symbol)
839 (coff_read_enum_type): Update.
840 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
842 (get_local_symbols, get_file_symbols, get_global_symbols): New
844 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
846 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
847 (~scoped_free_pendings): Update.
848 (finish_block, prepare_for_building, reset_symtab_globals)
849 (end_symtab_get_static_block, end_symtab_with_blockvector)
850 (augment_type_symtab, push_context): Update.
851 (get_local_symbols, get_file_symbols, get_global_symbols): New
853 (buildsym_init): Update.
855 2018-07-20 Tom Tromey <tom@tromey.com>
857 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
858 (process_full_type_unit): Likewise.
859 (dwarf2_start_symtab): Set list_in_scope.
861 2018-07-20 Tom Tromey <tom@tromey.com>
863 * dwarf2read.c (process_psymtab_comp_unit_reader)
864 (build_type_psymtabs_reader): Do not set list_in_scope.
866 2018-07-20 Tom Tromey <tom@tromey.com>
868 * buildsym.c (free_pendings): Remove.
869 (add_symbol_to_list, scoped_free_pendings)
870 (finish_block_internal, buildsym_init): Update.
872 2018-07-20 Tom Tromey <tom@tromey.com>
874 * xcoffread.c (read_xcoff_symtab): Update.
875 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
877 * dbxread.c (process_one_symbol): Update.
878 * coffread.c (coff_symtab_read): Update.
879 * buildsym.h (finish_block): Update.
880 * buildsym.c (finish_block): Remove "listhead" argument.
881 (end_symtab_get_static_block): Update.
883 2018-07-20 Tom Tromey <tom@tromey.com>
885 * buildsym.h (class scoped_free_pendings): Remove constructor.
886 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
888 <m_pending_block_obstack, m_pending_blocks>: New members.
889 (pending_block_obstack, pending_blocks): Remove.
890 (scoped_free_pendings::scoped_free_pendings): Default.
891 (~scoped_free_pendings): Update.
892 (free_pending_blocks): Remove.
893 (finish_block_internal, record_pending_block, make_blockvector)
894 (end_symtab_get_static_block, augment_type_symtab, push_context)
895 (buildsym_init): Update.
897 2018-07-20 Tom Tromey <tom@tromey.com>
899 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
900 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
902 (pending_addrmap, pending_addrmap_obstack)
903 (pending_addrmap_interesting): Remove.
904 (scoped_free_pendings, record_block_range, make_blockvector)
905 (prepare_for_building, reset_symtab_globals, buildsym_init):
908 2018-07-20 Tom Tromey <tom@tromey.com>
910 * xcoffread.c (process_linenos): Update.
911 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
912 * mdebugread.c (psymtab_to_symtab_1): Update.
913 * dwarf2read.c (setup_type_unit_groups)
914 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
915 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
916 * dbxread.c (process_one_symbol): Update.
917 * coffread.c (coff_symtab_read, enter_linenos)
918 (process_coff_symbol): Update.
919 * buildsym.h (current_subfile): Don't declare.
920 (get_current_subfile): Declare.
921 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
923 (start_subfile, free_buildsym_compunit, push_subfile)
924 (prepare_for_building, start_symtab): Update.
925 (get_current_subfile): New function.
927 2018-07-20 Tom Tromey <tom@tromey.com>
929 * coffread.c (coff_symtab_read): Update.
930 * xcoffread.c (read_xcoff_symtab): Update.
931 * dwarf2read.c (new_symbol): Update.
932 (read_func_scope, read_lexical_block_scope): Update.
933 * dbxread.c (process_one_symbol): Update.
934 * buildsym.h (context_stack, context_stack_depth): Don't declare.
935 (outermost_context_p): Remove macro.
936 (outermost_context_p, get_current_context_stack)
937 (get_context_stack_depth): Declare.
938 (pop_context): Return struct context_stack.
939 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
941 (context_stack_size): Remove.
942 (INITIAL_CONTEXT_STACK_SIZE): Remove.
943 (prepare_for_building, end_symtab_get_static_block)
944 (augment_type_symtab, push_context): Update.
945 (pop_context): Return struct context_stack.
946 (outermost_context_p, get_current_context_stack)
947 (get_context_stack_depth): New functions.
948 (buildsym_init): Update.
950 2018-07-20 Tom Tromey <tom@tromey.com>
952 * rust-exp.y: Now a pure parser. Update all rules.
953 (%union): Move earlier.
954 (current_parser, work_obstack): Remove globals.
955 (rust_parser, ~rust_parser): Update.
956 (class rust_parser) <copy_name, concat3, crate_name, super_name,
957 lex_character, lex_number, lex_string, lex_identifier,
958 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
959 convert_name, convert_params_to_expression,
960 convert_ast_to_expression, ast_basic_type, ast_operation,
961 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
962 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
963 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
964 ast_array_type, ast_slice_type, ast_reference_type,
965 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
966 (rust_parse): Update.
967 (rustyyerror, rustyylex): Add parser parameter.
968 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
969 (rust_lex_stringish_test, rust_lex_test_sequence)
970 (rust_lex_test_trailing_dot, rust_lex_test_completion)
971 (rust_lex_test_push_back, rust_lex_tests): Update.
973 2018-07-19 Pedro Alves <palves@redhat.com>
975 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
976 gdb::unique_xmalloc_ptr.
977 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
978 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
979 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
981 * guile/scm-pretty-print.c (ppscm_print_children): Use
982 gdb::unique_xmalloc_ptr instead of cleanups.
983 (gdbscm_apply_val_pretty_printer): Remove cleanups.
984 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
985 gdb::unique_xmalloc_ptr.
986 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
987 Adjust to use gdb::unique_xmalloc_ptr.
988 * guile/scm-utils.c (extract_arg): Adjust.
989 * guile/scm-value.c (gdbscm_value_field): Adjust to use
990 gdb::unique_xmalloc_ptr instead of a cleanup.
992 2018-07-19 Tom Tromey <tom@tromey.com>
994 * utils.c (do_value_free_to_mark)
995 (make_cleanup_value_free_to_mark): Remove.
996 * utils.h (make_cleanup_value_free_to_mark): Remove.
998 2018-07-19 Pedro Alves <palves@redhat.com>
1000 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
1001 forwarding reference.
1003 2018-07-18 Pedro Alves <palves@redhat.com>
1005 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
1006 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
1009 2018-07-18 Pedro Alves <palves@redhat.com>
1011 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
1013 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
1015 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
1016 directly instead of a cleanup.
1017 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
1018 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
1019 (vlscm_binop_gdbthrow): New, factored out from ...
1020 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
1021 (vlscm_rich_compare): Use gdbscm_wrap.
1022 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
1023 instead of a cleanup.
1024 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
1026 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1027 Use xfree directly instead of a cleanup.
1028 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
1029 Adjust to use gdbscm_wrap and scoped_value_mark.
1030 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
1031 (gdbscm_value_address, gdbscm_value_dereference)
1032 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
1034 (gdbscm_value_dynamic_type): Use scoped_value_mark.
1035 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
1037 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
1038 gdbscm_wrap and scoped_value_mark.
1039 (gdbscm_value_to_string): Use xfree directly instead of a
1040 cleanup. Move 'buffer' unique_ptr to TRY scope.
1041 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
1042 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
1044 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
1045 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
1047 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
1050 2018-07-18 Tom de Vries <tdevries@suse.de>
1052 * findvar.c (default_read_var_value): Also resolve dynamic type for
1053 LOC_OPTIMIZED_OUT vars.
1055 2018-07-18 Maciej W. Rozycki <macro@mips.com>
1057 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
1060 2018-07-17 Tom Tromey <tom@tromey.com>
1062 * guile/scm-param.c (pascm_set_func, pascm_show_func)
1063 (compute_enum_list, pascm_set_param_value_x)
1064 (gdbscm_parameter_value): Update.
1065 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
1066 (gdbscm_scm_to_host_string): Update.
1067 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
1069 * guile/scm-cmd.c (cmdscm_add_completion): Update.
1070 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
1071 * guile/scm-string.c (gdbscm_scm_to_string): Return
1073 (gdbscm_scm_to_host_string): Likewise.
1075 2018-07-17 Tom Tromey <tom@tromey.com>
1077 * guile/guile.c (gdbscm_eval_from_control_command): Update.
1078 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
1079 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
1080 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
1083 2018-07-17 Tom Tromey <tom@tromey.com>
1085 * guile/scm-param.c (pascm_signal_setshow_error): Update.
1086 * guile/guile-internal.h (gdbscm_exception_message_to_string):
1088 * guile/scm-cmd.c (cmdscm_function): Update.
1089 * guile/scm-pretty-print.c
1090 (ppscm_print_exception_unless_memory_error): Update.
1091 * guile/scm-exception.c (gdbscm_exception_message_to_string):
1092 Return unique_xmalloc_ptr.
1094 2018-07-17 Tom Tromey <tom@tromey.com>
1096 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
1099 2018-07-17 Jim Wilson <jimw@sifive.com>
1101 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
1102 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
1103 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
1104 unecessary braces after EF_RISCV_RVC test. Delete call to
1105 set_gdbarch_decr_pc_after_break.
1107 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
1108 RISCV_LAST_FP_REGNUM + 1.
1109 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
1111 2018-07-17 Tom Tromey <tom@tromey.com>
1113 * configure.ac: Remove --disable-gdbcli.
1114 * configure: Rebuild.
1115 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
1116 (SUBDIR_CLI_CFLAGS): Remove.
1117 (SFILES): Use SUBDIR_CLI_SRCS.
1118 (COMMON_OBS): Use SUBDIR_CLI_OBS.
1120 2018-07-17 Tom Tromey <tom@tromey.com>
1123 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
1125 2018-07-16 Jim Wilson <jimw@sifive.com>
1127 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
1129 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1131 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
1133 (libunwind_frame_sniffer): Likewise.
1134 (libunwind_frame_prev_register): Likewise.
1135 (libunwind_sigtramp_frame_sniffer): Likewise.
1136 * ia64-tdep.c (ia64_access_reg): Likewise.
1137 (ia64_access_rse_reg): Likewise.
1138 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
1139 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
1141 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1143 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
1145 2018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1147 * remote-sim.c (gdbsim_target::close,
1148 gdbsim_target::mourn_inferior): Remove unused variables.
1150 2018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
1152 * ia64-tdep.c (ktab_buf): New global.
1153 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
1154 (get_kernel_table): Adjust.
1156 2018-07-16 Tom Tromey <tom@tromey.com>
1158 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
1159 * dwarf2read.c (using_directives, new_symbol): Use
1160 outermost_context_p.
1161 * dbxread.c (process_one_symbol): Use outermost_context_p.
1162 * coffread.c (coff_symtab_read): Use outermost_context_p.
1164 2018-07-16 Tom Tromey <tom@tromey.com>
1166 * dwarf2read.c (using_directives, read_func_scope)
1167 (read_lexical_block_scope): Update.
1168 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1169 * buildsym.h (local_using_directives, global_using_directives):
1171 (get_local_using_directives, set_local_using_directives)
1172 (get_global_using_directives): Declare.
1173 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
1174 m_global_using_directives>: New members.
1175 (finish_block_internal, prepare_for_building)
1176 (reset_symtab_globals, end_symtab_get_static_block)
1177 (push_context): Update.
1178 (get_local_using_directives, set_local_using_directives)
1179 (get_global_using_directives): New functions.
1180 (buildsym_init): Update.
1182 2018-07-16 Tom Tromey <tom@tromey.com>
1184 * xcoffread.c (xcoff_initial_scan): Don't call
1185 free_pending_blocks.
1186 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
1187 * buildsym.h (class scoped_free_pendings): Add constructor.
1188 (free_pending_blocks): Don't declare.
1189 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
1190 (free_pending_blocks): Now static.
1192 2018-07-16 Tom Tromey <tom@tromey.com>
1194 * buildsym.h (push_subfile, pop_subfile): Update declarations.
1195 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
1197 (struct subfile_stack): Remove.
1198 (subfile_stack): Remove.
1199 (push_subfile, pop_subfile, buildsym_init): Update.
1201 2018-07-16 Tom Tromey <tom@tromey.com>
1203 * buildsym.c (push_subfile): Use gdb_assert.
1204 (pop_subfile): Use gdb_assert.
1206 2018-07-16 Tom Tromey <tom@tromey.com>
1208 * buildsym.h (merge_symbol_lists): Remove.
1209 * buildsym.c (merge_symbol_lists): Remove.
1211 2018-07-16 Tom Tromey <tom@tromey.com>
1213 * stabsread.c (scan_file_globals): Update comment.
1214 * stabsread.h (scan_file_globals): Move from buildsym.h.
1215 * buildsym.h (scan_file_globals): Move to stabsread.h.
1217 2018-07-16 Tom Tromey <tom@tromey.com>
1219 * xcoffread.c (xcoff_new_init): Update.
1220 * mipsread.c (mipscoff_new_init): Update.
1221 * mdebugread.c (mdebug_build_psymtabs): Update.
1222 * elfread.c (elf_new_init): Update.
1223 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
1224 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
1225 * buildsym.h (buildsym_new_init): Don't declare.
1226 * buildsym.c (buildsym_new_init): Remove.
1228 2018-07-16 Tom Tromey <tom@tromey.com>
1230 * stabsread.h (within_function): Move from buildsym.h.
1231 * stabsread.c (start_stabs): Clear within_function.
1232 * coffread.c (coff_start_symtab): Clear within_function.
1233 * buildsym.h (within_function): Move to stabsread.h.
1234 * buildsym.c (prepare_for_building): Update.
1236 2018-07-16 Tom Tromey <tom@tromey.com>
1238 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1239 * dwarf2read.c (dwarf2_start_symtab): Don't set
1240 processing_gcc_compilation.
1241 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1243 2018-07-16 Tom Tromey <tom@tromey.com>
1245 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1246 (next_symbol_text_func): Move from buildsym.h.
1247 * stabsread.c (hashname): Move from buildsym.c.
1248 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1249 (next_symbol_text_func, hashname): Move to stabsread.h.
1250 * buildsym.c: Don't include bcache.h
1251 (hashname): Move to stasbread.c.
1253 2018-07-16 Tom Tromey <tom@tromey.com>
1255 * buildsym.h (context_stack_size): Don't declare.
1256 * buildsym.c (context_stack_size): New global.
1258 2018-07-16 Tom Tromey <tom@tromey.com>
1260 * dbxread.c (processing_acc_compilation): New global.
1261 * buildsym.h (processing_acc_compilation): Don't declare.
1263 2018-07-16 Tom Tromey <tom@tromey.com>
1265 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1266 * dbxread.c (read_ofile_symtab): Update.
1267 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1268 * buildsym.h (last_source_start_addr): Remove.
1269 (set_last_source_start_addr, get_last_source_start_addr):
1271 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1273 (struct buildsym_compunit) <m_last_source_start_addr>: New
1275 (prepare_for_building): Remove start_addr parameter.
1276 (start_symtab, restart_symtab, end_symtab_get_static_block)
1277 (end_symtab_with_blockvector): Update.
1278 (set_last_source_start_addr, get_last_source_start_addr): New
1281 2018-07-16 Tom Tromey <tom@tromey.com>
1283 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1285 (have_line_numbers): Remove.
1286 (record_line, prepare_for_building, end_symtab_get_static_block)
1287 (augment_type_symtab): Update.
1289 2018-07-16 Tom Tromey <tom@tromey.com>
1291 * buildsym.c (~buildsym_compunit): Free the macro table.
1292 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1294 <m_pending_macros>: New member.
1295 (pending_macros): Remove.
1296 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1297 (reset_symtab_globals, end_symtab_get_static_block)
1298 (end_symtab_with_blockvector, augment_type_symtab)
1299 (buildsym_init): Update.
1301 2018-07-16 Tom Tromey <tom@tromey.com>
1303 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
1305 (buildsym_compunit::set_last_source_file): New method.
1306 <m_last_source_file>: New member.
1307 (prepare_for_building): Remove "name" parameter.
1308 (start_symtab, restart_symtab, reset_symtab_globals): Update.
1309 (last_source_file): Remove.
1310 (set_last_source_file, get_last_source_file): Update.
1312 2018-07-16 Tom Tromey <tom@tromey.com>
1314 * buildsym.c (prepare_for_building): Add assert.
1316 2018-07-16 Tom Tromey <tom@tromey.com>
1318 * buildsym.c (~buildsym_compunit): Update.
1319 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
1320 (start_subfile, patch_subfile_names)
1321 (end_symtab_with_blockvector): Update.
1323 2018-07-16 Tom Tromey <tom@tromey.com>
1325 * buildsym.c (struct buildsym_compunit): Add constructor,
1326 destructor, initializers.
1327 (start_buildsym_compunit): Remove.
1328 (free_buildsym_compunit): Use "delete".
1329 (start_symtab, restart_symtab): Use "new".
1331 2018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
1333 * symfile.c (set_objfile_default_section_offset): Remove struct
1336 2018-07-14 Stafford Horne <shorne@gmail.com>
1338 * (Responsible Maintainers): Add myself as or1k maintainer.
1340 2018-07-13 Tom Tromey <tom@tromey.com>
1342 * symfile.c (set_objfile_default_section_offset): Use extra braces
1345 2018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
1347 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
1350 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1352 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1353 unittests/cli-utils-selftests.c
1354 * unittests/cli-utils-selftests.c: New file.
1356 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1358 * NEWS: Mention new commands. Mention change to 'thread apply'.
1360 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1362 * thread.c (thr_try_catch_cmd): New function.
1363 (thread_apply_all_command): Handle qcs flags.
1364 (thread_apply_command): Handle qcs flags.
1365 (taas_command): New function.
1366 (tfaas_command): New function.
1367 (_initialize_thread): Update to setup the new commands 'taas
1368 and 'tfaas'. Change doc string for 'thread apply'.
1370 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1372 * stack.c: (trailing_outermost_frame): New function, mostly
1373 extracted from backtrace_command_1.
1374 (leading_innermost_frame): New function.
1375 (backtrace_command_1): Update to call trailing_outermost_frame.
1376 (frame_apply_command_count): New function.
1377 (frame_apply_level_command): New function.
1378 (frame_apply_all_command): New function.
1379 (frame_apply_command): New function.
1380 (faas_command): New function.
1381 (frame_cmd_list): New variable.
1382 (_initialize_stack): Update to setup the new commands 'frame apply'
1385 2018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1387 * cli-utils.c (number_or_range_parser::get_number): Only handle
1388 numbers or convenience var as numbers.
1389 (parse_flags): New function.
1390 (parse_flags_qcs): New function.
1391 (number_or_range_parser::finished): Ensure parsing end is detected
1392 before end of string.
1393 * cli-utils.h (parse_flags): New function.
1394 (parse_flags_qcs): New function.
1395 (number_or_range_parser): Remove m_finished bool.
1396 (number_or_range_parser::skip_range): Set m_in_range to false.
1398 2018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
1400 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
1403 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1404 Jan Kratochvil <jan.kratochvil@redhat.com>
1405 Paul Fertser <fercerpav@gmail.com>
1406 Tsutomu Seki <sekiriki@gmail.com>
1407 Pedro Alves <palves@redhat.com>
1409 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1410 'unittests/parse-connection-spec-selftests.c'.
1411 (COMMON_SFILES): Add 'common/netstuff.c'.
1412 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
1413 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
1414 * common/netstuff.c: New file.
1415 * common/netstuff.h: New file.
1416 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
1417 (wait_for_connect): Update comment. New parameter
1418 'gdb::optional<int> sock' instead of 'struct serial *scb'.
1419 Use 'sock' directly instead of 'scb->fd'.
1420 (try_connect): New function, with code from 'net_open'.
1421 (net_open): Rewrite main loop to deal with multiple
1422 sockets/addresses. Handle IPv6-style hostnames; implement
1423 support for IPv6 connections.
1424 * unittests/parse-connection-spec-selftests.c: New file.
1426 2018-07-11 Pedro Alves <palves@redhat.com>
1429 * remote.c (remote_target::remote_detach_pid): Call
1430 set_current_process.
1432 2018-07-11 Pedro Alves <palves@redhat.com>
1434 * h8300-tdep.c (h8300_gdbarch_init): Remove
1435 set_gdbarch_ecoff_reg_to_regnum calls.
1437 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1440 * c-typeprint.c (c_type_print_base_struct_union): Don't print
1441 offsets/sizes for static members of a class/struct.
1443 2018-07-11 Alan Hayward <alan.hayward@arm.com>
1445 * target-descriptions.c (tdesc_register_bitsize): Rename.
1446 * target-descriptions.h (tdesc_register_bitsize): Likewise.
1447 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
1448 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
1450 2018-07-10 Tom Tromey <tom@tromey.com>
1452 * breakpoint.c (moribund_locations): Now static and a
1454 (breakpoint_init_inferior, moribund_breakpoint_here_p)
1455 (build_bpstat_chain, update_global_location_list)
1456 (breakpoint_retire_moribund): Update.
1457 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
1460 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1462 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
1463 (riscv_register_reggroup_p): Use new function, remove unneeded
1465 (riscv_push_dummy_call): Extend assert to compare against xlen or
1466 flen based on register type.
1468 2018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1470 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
1472 2018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
1474 * remote.c (show_hardware_watchpoint_limit): New function.
1475 (show_hardware_watchpoint_length_limit): New function.
1476 (show_hardware_breakpoint_limit): New function.
1477 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
1478 where appropriate, update help text.
1480 2018-07-09 Tom Tromey <tom@tromey.com>
1482 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
1483 (CLIBS): Don't mention NAT_CLIBS.
1485 2018-07-09 Tom Tromey <tom@tromey.com>
1487 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
1488 (LIBGDB_OBS, clean mostlyclean): Update.
1489 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
1491 2018-07-09 Tom Tromey <tom@tromey.com>
1493 * Makefile.in (%.c: %.y): Use ECHO_YACC.
1494 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
1495 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
1497 2018-07-09 Tom Tromey <tom@tromey.com>
1499 * Makefile.in (ALLDEPFILES): Remove exec.c.
1500 (COMMON_OBS): Remove exec.o.
1501 (COMMON_SFILES): Add exec.c.
1503 2018-07-09 Tom Tromey <tom@tromey.com>
1505 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
1507 2018-07-09 Tom Tromey <tom@tromey.com>
1509 * Makefile.in (clean mostlyclean): Remove stamp-version.
1510 (version.c): Depend on stamp-version.
1511 (stamp-version): New rule, from version.c rule.
1513 2018-07-09 Tom Tromey <tom@tromey.com>
1515 * Makefile.in (init.c): Depend on stamp-init.
1516 (stamp-init): New rule, from init.c rule.
1517 (clean mostlyclean): Remove stamp-init.
1519 2018-07-09 Tom Tromey <tom@tromey.com>
1521 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
1522 SUBDIR_GCC_COMPILE_SRCS.
1524 2018-07-09 Tom Tromey <tom@tromey.com>
1526 * Makefile.in (init.c): Remove some unused sed rules.
1528 2018-07-09 Tom Tromey <tom@tromey.com>
1530 * Makefile.in (TSOBS): Remove.
1531 (INIT_FILES): Update.
1532 (LIBGDB_OBS): Update.
1533 (COMMON_SFILES): Add inflow.c.
1534 (SFILES): Remove inflow.c.
1536 2018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
1538 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
1540 2018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
1542 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
1543 get_saveloc_name, is_signal_frame_name, step_name,
1544 init_remote_name, create_addr_space_name,
1545 destroy_addr_space_name, search_unwind_table_name,
1546 find_dyn_list_name): Constify.
1548 2018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
1550 * darwin-nat.c (darwin_pthread_kill): New function.
1551 (darwin_resume_thread): Use darwin_pthread_kill.
1553 2018-07-05 Tom de Vries <tdevries@suse.de>
1555 * macroexp.c (macro_buffer) <operator=>: New member function.
1557 2018-07-04 Tom Tromey <tom@tromey.com>
1559 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
1561 2018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
1563 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
1564 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
1565 * maint.c: Likewise.
1568 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1570 * NEWS: Create a new section for the next release branch.
1571 Rename the section of the current branch, now that it has
1574 2018-07-04 Joel Brobecker <brobecker@adacore.com>
1576 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
1577 * version.in: Bump version to 8.2.50.DATE-git.
1579 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1580 Pedro Alves <palves@redhat.com>
1582 * linux-nat.c (linux_init_ptrace): Rename to ...
1583 (linux_init_ptrace_procfs): ... this. Call
1584 linux_proc_init_warnings.
1585 (linux_nat_target::post_attach)
1586 (linux_nat_target::post_startup_inferior): Adjust.
1587 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
1588 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
1590 2018-07-04 Tom de Vries <tdevries@suse.de>
1592 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
1594 (read_comp_unit_head): ... here.
1596 2018-07-03 Tom Tromey <tom@tromey.com>
1598 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
1599 (stop_tracing, tstatus_command)
1600 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
1601 (print_one_static_tracepoint_marker): Update.
1602 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
1604 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
1606 (all_tracepoints, static_tracepoints_here): Return std::vector.
1608 2018-07-03 Tom Tromey <tom@tromey.com>
1610 * common/ptid.c (ptid_equal): Remove.
1611 * common/ptid.h (ptid_equal): Don't declare.
1612 * ada-tasks.c: Update.
1613 * breakpoint.c: Update.
1614 * common/agent.c: Update.
1615 * corelow.c: Update.
1616 * darwin-nat-info.c: Update.
1617 * darwin-nat.c: Update.
1619 * dtrace-probe.c: Update.
1620 * dummy-frame.c: Update.
1621 * fbsd-nat.c: Update.
1623 * gdbthread.h: Update.
1624 * gnu-nat.c: Update.
1625 * go32-nat.c: Update.
1626 * inf-loop.c: Update.
1627 * inf-ptrace.c: Update.
1628 * infcall.c: Update.
1632 * linux-fork.c: Update.
1633 * linux-nat.c: Update.
1634 * linux-thread-db.c: Update.
1635 * mi/mi-cmd-var.c: Update.
1636 * mi/mi-interp.c: Update.
1637 * mi/mi-main.c: Update.
1638 * nto-procfs.c: Update.
1639 * ppc-linux-tdep.c: Update.
1641 * python/py-inferior.c: Update.
1642 * python/py-record-btrace.c: Update.
1643 * python/py-record.c: Update.
1644 * ravenscar-thread.c: Update.
1645 * regcache.c: Update.
1646 * remote-sim.c: Update.
1648 * sol-thread.c: Update.
1651 * tui/tui-stack.c: Update.
1653 * windows-nat.c: Update.
1654 * windows-tdep.c: Update.
1656 2018-07-03 Tom Tromey <tom@tromey.com>
1658 * common/ptid.c (ptid_match): Remove.
1659 * common/ptid.h (ptid_match): Don't declare.
1660 * fbsd-nat.c: Update.
1663 * linux-nat.c: Update.
1664 * record-btrace.c: Update.
1665 * regcache.c: Update.
1668 2018-07-03 Tom Tromey <tom@tromey.com>
1670 * common/ptid.c (ptid_tid_p): Remove.
1671 * common/ptid.h (ptid_tid_p): Don't declare.
1672 * sol-thread.c: Update.
1674 2018-07-03 Tom Tromey <tom@tromey.com>
1676 * common/ptid.c (ptid_lwp_p): Remove.
1677 * common/ptid.h (ptid_lwp_p): Don't declare.
1678 * fbsd-nat.c: Update.
1679 * linux-nat.c: Update.
1680 * nat/linux-procfs.c: Update.
1681 * nat/x86-linux-dregs.c: Update.
1682 * sol-thread.c: Update.
1684 2018-07-03 Tom Tromey <tom@tromey.com>
1686 * common/ptid.c (ptid_is_pid): Remove.
1687 * common/ptid.h (ptid_is_pid): Don't declare.
1689 * linux-nat.c: Update.
1690 * mi/mi-interp.c: Update.
1694 2018-07-03 Tom Tromey <tom@tromey.com>
1696 * common/ptid.c (ptid_get_tid): Remove.
1697 * common/ptid.h (ptid_get_tid): Don't declare.
1698 * ada-tasks.c: Update.
1699 * aix-thread.c: Update.
1700 * bsd-uthread.c: Update.
1701 * darwin-nat.c: Update.
1702 * fbsd-nat.c: Update.
1703 * i386-darwin-nat.c: Update.
1705 * linux-tdep.c: Update.
1706 * nto-procfs.c: Update.
1707 * ppc-ravenscar-thread.c: Update.
1708 * python/py-infthread.c: Update.
1709 * ravenscar-thread.c: Update.
1710 * sol-thread.c: Update.
1711 * sparc-ravenscar-thread.c: Update.
1712 * windows-nat.c: Update.
1714 2018-07-03 Tom Tromey <tom@tromey.com>
1716 * common/ptid.c (ptid_get_lwp): Remove.
1717 * common/ptid.h (ptid_get_lwp): Don't declare.
1718 * aarch64-linux-nat.c: Update.
1719 * ada-tasks.c: Update.
1720 * aix-thread.c: Update.
1721 * amd64-linux-nat.c: Update.
1722 * arm-linux-nat.c: Update.
1723 * corelow.c: Update.
1724 * fbsd-nat.c: Update.
1725 * fbsd-tdep.c: Update.
1726 * gnu-nat.c: Update.
1727 * i386-cygwin-tdep.c: Update.
1728 * i386-gnu-nat.c: Update.
1729 * i386-linux-nat.c: Update.
1730 * ia64-linux-nat.c: Update.
1731 * inf-ptrace.c: Update.
1733 * linux-fork.c: Update.
1734 * linux-nat.c: Update.
1735 * linux-tdep.c: Update.
1736 * linux-thread-db.c: Update.
1737 * mips-linux-nat.c: Update.
1738 * nat/aarch64-linux-hw-point.c: Update.
1739 * nat/aarch64-linux.c: Update.
1740 * nat/linux-btrace.c: Update.
1741 * nat/linux-osdata.c: Update.
1742 * nat/linux-procfs.c: Update.
1743 * nat/x86-linux-dregs.c: Update.
1744 * obsd-nat.c: Update.
1745 * ppc-fbsd-nat.c: Update.
1746 * ppc-linux-nat.c: Update.
1748 * python/py-infthread.c: Update.
1749 * ravenscar-thread.c: Update.
1751 * s390-linux-nat.c: Update.
1752 * sol-thread.c: Update.
1753 * sol2-tdep.c: Update.
1754 * spu-linux-nat.c: Update.
1755 * x86-linux-nat.c: Update.
1756 * xtensa-linux-nat.c: Update.
1758 2018-07-03 Tom Tromey <tom@tromey.com>
1760 * common/ptid.c (ptid_get_pid): Remove.
1761 * common/ptid.h (ptid_get_pid): Don't declare.
1762 * aarch64-linux-nat.c: Update.
1763 * ada-lang.c: Update.
1764 * aix-thread.c: Update.
1765 * alpha-bsd-nat.c: Update.
1766 * amd64-fbsd-nat.c: Update.
1767 * amd64-linux-nat.c: Update.
1768 * arm-linux-nat.c: Update.
1769 * arm-nbsd-nat.c: Update.
1771 * break-catch-syscall.c: Update.
1772 * breakpoint.c: Update.
1773 * bsd-uthread.c: Update.
1774 * corelow.c: Update.
1776 * darwin-nat.c: Update.
1777 * fbsd-nat.c: Update.
1778 * fbsd-tdep.c: Update.
1780 * gnu-nat.c: Update.
1781 * hppa-nbsd-nat.c: Update.
1782 * hppa-obsd-nat.c: Update.
1783 * i386-fbsd-nat.c: Update.
1784 * ia64-linux-nat.c: Update.
1785 * inf-ptrace.c: Update.
1787 * inferior.c: Update.
1788 * inferior.h: Update.
1791 * linux-fork.c: Update.
1792 * linux-nat.c: Update.
1793 * linux-tdep.c: Update.
1794 * linux-thread-db.c: Update.
1795 * m68k-bsd-nat.c: Update.
1796 * mi/mi-interp.c: Update.
1797 * mi/mi-main.c: Update.
1798 * mips-linux-nat.c: Update.
1799 * mips-nbsd-nat.c: Update.
1800 * mips64-obsd-nat.c: Update.
1801 * nat/aarch64-linux-hw-point.c: Update.
1802 * nat/aarch64-linux.c: Update.
1803 * nat/linux-btrace.c: Update.
1804 * nat/linux-osdata.c: Update.
1805 * nat/linux-procfs.c: Update.
1806 * nat/x86-linux-dregs.c: Update.
1807 * nto-procfs.c: Update.
1808 * obsd-nat.c: Update.
1809 * ppc-linux-nat.c: Update.
1810 * ppc-nbsd-nat.c: Update.
1811 * ppc-obsd-nat.c: Update.
1812 * proc-service.c: Update.
1814 * python/py-inferior.c: Update.
1815 * python/py-infthread.c: Update.
1816 * ravenscar-thread.c: Update.
1818 * remote-sim.c: Update.
1820 * rs6000-nat.c: Update.
1821 * s390-linux-nat.c: Update.
1822 * sh-nbsd-nat.c: Update.
1823 * sol-thread.c: Update.
1824 * sparc-nat.c: Update.
1825 * sparc64-tdep.c: Update.
1826 * spu-linux-nat.c: Update.
1827 * spu-tdep.c: Update.
1828 * target-debug.h: Update.
1831 * tid-parse.c: Update.
1832 * tracefile-tfile.c: Update.
1833 * vax-bsd-nat.c: Update.
1834 * windows-nat.c: Update.
1835 * x86-linux-nat.c: Update.
1836 * x86-nat.c: Update.
1838 2018-07-03 Tom Tromey <tom@tromey.com>
1840 * common/ptid.c (pid_to_ptid): Remove.
1841 * common/ptid.h (pid_to_ptid): Don't declare.
1842 * aix-thread.c: Update.
1843 * arm-linux-nat.c: Update.
1844 * common/ptid.c: Update.
1845 * common/ptid.h: Update.
1846 * corelow.c: Update.
1848 * darwin-nat.c: Update.
1849 * fbsd-nat.c: Update.
1850 * fork-child.c: Update.
1851 * gnu-nat.c: Update.
1852 * go32-nat.c: Update.
1853 * inf-ptrace.c: Update.
1855 * inferior.c: Update.
1857 * linux-fork.c: Update.
1858 * linux-nat.c: Update.
1859 * nat/aarch64-linux-hw-point.c: Update.
1860 * nat/fork-inferior.c: Update.
1861 * nat/x86-linux-dregs.c: Update.
1862 * nto-procfs.c: Update.
1863 * obsd-nat.c: Update.
1865 * progspace.c: Update.
1867 * rs6000-nat.c: Update.
1868 * s390-linux-nat.c: Update.
1869 * sol-thread.c: Update.
1870 * spu-linux-nat.c: Update.
1873 * tracefile-tfile.c: Update.
1874 * windows-nat.c: Update.
1876 2018-07-03 Tom Tromey <tom@tromey.com>
1878 * common/ptid.h (ptid_build): Don't declare.
1879 * common/ptid.c (ptid_build): Remove.
1880 * aix-thread.c: Update.
1881 * bsd-kvm.c: Update.
1882 * bsd-uthread.c: Update.
1883 * common/agent.c: Update.
1884 * common/ptid.c: Update.
1885 * common/ptid.h: Update.
1886 * corelow.c: Update.
1887 * darwin-nat.c: Update.
1888 * fbsd-nat.c: Update.
1889 * gnu-nat.c: Update.
1890 * linux-fork.c: Update.
1891 * linux-nat.c: Update.
1892 * linux-thread-db.c: Update.
1893 * nat/linux-osdata.c: Update.
1894 * nat/linux-procfs.c: Update.
1895 * nto-procfs.c: Update.
1896 * obsd-nat.c: Update.
1897 * proc-service.c: Update.
1899 * ravenscar-thread.c: Update.
1900 * remote-sim.c: Update.
1902 * sol-thread.c: Update.
1904 * windows-nat.c: Update.
1906 2018-07-03 Tom Tromey <tom@tromey.com>
1908 * infrun.c (follow_exec): Use exit_inferior_silent.
1909 * inferior.c (exit_inferior_num_silent): Remove.
1910 * inferior.h (exit_inferior_num_silent): Don't declare.
1912 2018-07-03 Tom Tromey <tom@tromey.com>
1915 * darwin-nat.c (darwin_attach_pid): Reset inferior and
1916 inferior_ptid on error.
1918 2018-07-02 Maciej W. Rozycki <macro@mips.com>
1919 Simon Marchi <simon.marchi@polymtl.ca>
1922 * disasm.h (gdb_disassembler): Add
1923 `m_disassembler_options_holder'. member
1924 * disasm.c (get_all_disassembler_options): New function.
1925 (gdb_disassembler::gdb_disassembler): Use it.
1926 (gdb_buffered_insn_length_init_dis): Likewise.
1927 (gdb_buffered_insn_length): Adjust accordingly.
1928 (set_disassembler_options): Handle options with arguments.
1929 (show_disassembler_options_sfunc): Likewise. Add a leading new
1930 line if showing options with descriptions.
1931 (disassembler_options_completer): Adapt to using the
1932 `disasm_options_and_args_t' structure.
1933 * mips-tdep.c (mips_disassembler_options): New variable.
1934 (mips_disassembler_options_o32): Likewise.
1935 (mips_disassembler_options_n32): Likewise.
1936 (mips_disassembler_options_n64): Likewise.
1937 (gdb_print_insn_mips): Don't set `disassembler_options'.
1938 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
1940 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
1941 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
1942 `gdbarch_disassembler_options_implicit' and
1943 `gdbarch_valid_disassembler_options'.
1944 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
1945 `disasm_options_and_args_t' structure.
1946 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
1948 (valid_disassembler_options): Switch from `disasm_options_t' to
1949 the `disasm_options_and_args_t' structure.
1950 * NEWS: Document `set disassembler-options' support for the MIPS
1952 * gdbarch.h: Regenerate.
1953 * gdbarch.c: Regenerate.
1955 2018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
1957 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
1959 2018-06-29 Joel Brobecker <brobecker@adacore.com>
1961 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
1962 parameter in call to amd64_target_description.
1963 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
1964 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
1965 (amd64fbsd_init_abi): Likewise.
1966 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
1967 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
1968 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
1969 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
1971 2018-06-29 Pedro Alves <palves@redhat.com>
1973 * gdb/amd64-tdep.h (amd64_create_target_description): Add
1974 "segments" parameter.
1975 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
1976 (_initialize_amd64_tdep): Update call to
1977 amd64_create_target_description.
1978 (amd64_target_description): Add "segments" parameter. Adjust
1979 the implementation to use it.
1980 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
1981 call to amd64_create_target_description.
1982 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
1983 * gdb/arch/amd64.h (amd64_create_target_description): Add
1984 "segments" register.
1985 * gdb/arch/amd64.c (amd64_create_target_description): Add
1986 "segments" parameter. Call create_feature_i386_64bit_segments
1987 only if SEGMENTS is true.
1988 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
1989 call to amd64_create_target_description.
1991 2018-06-29 Pedro Alves <palves@redhat.com>
1993 * thread.c (thread_target_id_str): New, factored out from ...
1994 (print_thread_info_1): ... here. Use it to compute the max
1995 "Target Id" column width.
1997 2018-06-29 Pedro Alves <palves@redhat.com>
1999 * remote.c (remote_target::extra_thread_info): Delete
2000 'display_buf' and 'n' locals. from the cache, regardless of
2001 packet mechanims is in use. Use cache for qThreadExtra and qP
2004 2018-06-29 Pedro Alves <palves@redhat.com>
2006 * blockframe.c (find_pc_sect_containing_function): New function.
2007 * breakpoint.c (print_breakpoint_location): Don't call
2008 find_pc_sect_function.
2009 * linespec.c (create_sals_line_offset): Record the location's
2011 * linespec.c (convert_address_location_to_sals): Fill in sal's
2012 symbol with find_pc_sect_containing_function.
2013 * symtab.c (find_function_start_sal): Rename to ...
2014 (find_function_start_sal_1): ... this.
2015 (find_function_start_sal): Reimplement as wrapper around
2016 find_function_start_sal_1, and use
2017 find_pc_sect_containing_function to fill in the sal's symbol.
2018 (find_function_start_sal(symbol*, bool)): Adjust.
2019 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
2021 (find_pc_sect_containing_function): Declare.
2023 2018-06-29 Pedro Alves <palves@redhat.com>
2025 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
2026 true if the the location has no symbol.
2028 2018-06-28 Tom Tromey <tom@tromey.com>
2030 * NEWS: Mention --enable-codesign.
2031 * silent-rules.mk (ECHO_SIGN): New variable.
2032 * configure.ac: Add --enable-codesign.
2033 * configure: Rebuild.
2034 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
2035 (gdb$(EXEEXT)): Optionally invoke codesign.
2037 2018-06-28 Pedro Alves <palves@redhat.com>
2039 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
2041 (switch_to_thread_no_regs): Adjust comment.
2042 * infcmd.c (stop_pc): Delete.
2043 (post_create_inferior, info_program_command): Replace references
2044 to stop_pc with references to thread_info->suspend.stop_pc.
2045 * inferior.h (stop_pc): Delete declaration.
2046 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
2047 (handle_inferior_event_1, handle_signal_stop)
2048 (process_event_stop_test, keep_going_stepped_thread)
2049 (handle_step_into_function, handle_step_into_function_backward)
2050 (print_stop_location): Replace references to stop_pc with
2051 references to thread_info->suspend.stop_pc.
2052 (struct infcall_suspend_state) <stop_pc>: Delete field.
2053 (save_infcall_suspend_state, restore_infcall_suspend_state):
2054 Remove references to inf_stat->stop_pc.
2055 * linux-fork.c (fork_load_infrun_state): Likewise.
2056 * record-btrace.c (record_btrace_set_replay): Likewise.
2057 * record-full.c (record_full_goto_entry): Likewise.
2058 * remote.c (print_one_stopped_thread): Likewise.
2059 * target.c (target_resume): Extend comment.
2060 * thread.c (set_executing_thread): New.
2061 (set_executing): Use it.
2062 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
2063 Remove references to stop_pc.
2065 2018-06-28 Pedro Alves <palves@redhat.com>
2067 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
2068 Moving fetching stop_pc until after ecs->event_thread is refreshed.
2070 2018-06-28 Tom Tromey <tom@tromey.com>
2072 * coffread.c (coff_symfile_finish): Update.
2073 * xcoffread.c (xcoff_symfile_finish): Update.
2074 * elfread.c (elf_symfile_finish): Update.
2075 * symfile.h (dwarf2_free_objfile): Don't declare.
2076 * dwarf2read.c (_initialize_dwarf2_read): Use
2077 register_objfile_data_with_cleanup.
2078 (dwarf2_free_objfile): Now static. Change signature.
2080 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2082 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
2083 option "-o" to add-symbol-file-load to add an offset to each
2084 section's load address.
2085 * symfile.c (set_objfile_default_section_offset): New function.
2087 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2089 * symfile.c (add_symbol_file_command): Make sure that sections
2090 with the same name are sorted in the same order.
2092 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2094 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
2095 require the second argument. If omitted, load sections at the
2096 addresses specified in the file.
2098 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2100 * symfile.c (symbol_file_command, symbol_file_add_main_1)
2101 (_initialize_symfile): Add option "-o" to symbol-file to add an
2102 offset to each section of the symbol file.
2104 2018-06-28 Petr Tesarik <ptesarik@suse.cz>
2106 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
2108 2018-06-27 Tom Tromey <tom@tromey.com>
2110 * stack.c (_initialize_stack): Update "func" help text.
2112 2018-06-27 Tom Tromey <tom@tromey.com>
2114 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
2116 (unwind_infopy_str, pyuw_create_unwind_info)
2117 (unwind_infopy_add_saved_register, pyuw_sniffer)
2118 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
2120 (struct saved_reg): Add constructor.
2121 <value>: Now a gdbpy_ref<>.
2123 2018-06-27 Tom Tromey <tom@tromey.com>
2125 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
2127 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2129 * gdb-gdb.py.in: Format using autopep8.
2131 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2133 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
2134 (type_lookup_function): Recognize CORE_ADDR values.
2136 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2138 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
2141 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2143 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
2146 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2148 * gdb-gdb.py: Move to...
2149 * gdb-gdb.py.in: ... here.
2150 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
2151 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
2153 (distclean): Remove gdb-gdb.py when cleaning.
2154 (gdb-gdb.py, gdb-gdb.gdb): New rules.
2155 * configure: Re-generate.
2157 2018-06-27 Pedro Alves <palves@redhat.com>
2159 * proc-service.c (get_ps_regcache): New.
2160 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
2161 (ps_lsetfpregs): Use it.
2163 2018-06-27 Omair Javaid <omair.javaid@linaro.org>
2166 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
2167 (dwarf_decode_lines_1): Adjust.
2169 2018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2171 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
2173 <info_proc>: Likewise.
2175 2018-06-26 Joel Brobecker <brobecker@adacore.com>
2177 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
2178 to windows_fetch_one_register, and only handle the case of
2179 fetching one register. Move the code that reloads the context
2180 and iterates over all registers if R is negative to...
2181 (windows_nat_target::fetch_registers): ... here.
2182 (do_windows_store_inferior_registers): Rename to
2183 windows_store_one_register, and only handle the case of storing
2184 one register. Move the code that handles the case where r is
2186 (windows_nat_target::store_registers) ... here.
2188 2018-06-26 Tom Tromey <tom@tromey.com>
2191 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
2192 * rust-lang.c (rust_print_struct_def): Add podata parameter.
2194 (rust_internal_print_type): Add podata parameter.
2195 (rust_print_type): Update.
2197 2018-06-26 Tom Tromey <tom@tromey.com>
2199 * typeprint.h (struct print_offset_data) <update, finish,
2200 maybe_print_hole>: New methods.
2201 <indentation>: New constant.
2202 * typeprint.c (print_offset_data::indentation): Define.
2203 (print_offset_data::maybe_print_hole, print_offset_data::update)
2204 (print_offset_data::finish): Move from c-typeprint.c and rename.
2205 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
2206 (print_spaces_filtered_with_print_options): Update.
2207 (c_print_type_union_field_offset, maybe_print_hole)
2208 (c_print_type_struct_field_offset): Move to typeprint.c and
2210 (c_type_print_base_struct_union): Update.
2212 2018-06-25 Pedro Alves <palves@redhat.com>
2214 * gdbthread.h (thread_info_ref, delete_thread)
2215 (delete_thread_silent, first_thread_of_inferior)
2216 (any_thread_of_inferior, switch_to_thread)
2217 (enable_thread_stack_temporaries)
2218 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2219 (get_last_thread_stack_temporary)
2220 (value_in_thread_stack_temporaries, can_access_registers_thread):
2221 Spell out "struct thread_info" instead of just "thread_info".
2222 * inferior.h (notice_new_inferior): Likewise.
2224 2018-06-25 Pedro Alves <palves@redhat.com>
2226 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2227 pass thread_info pointer to delete_thread.
2228 (windows_nat_target::detach): Pass inferior pointer to
2230 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2232 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2233 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2234 and pass a thread_info pointer to delete_thread.
2235 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2236 pass thread_info pointer to delete_thread.
2237 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2238 delete_thread_silent call.
2239 * procfs.c (procfs_target::detach): Pass inferior pointer to
2241 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2242 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2243 delete_thread_silent call.
2244 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2245 pass thread_info pointer to delete_thread.
2246 (windows_nat_target::detach): Pass inferior pointer to
2249 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2251 * regcache.c (readable_regcache::read_part): Fix asserts.
2252 (reg_buffer::raw_collect_part): New function.
2253 (regcache::write_part): Fix asserts.
2254 (reg_buffer::raw_supply_part): New function.
2255 (regcache::transfer_regset_register): New helper function.
2256 (regcache::transfer_regset): Call new functions.
2257 (regcache_supply_regset): Use gdb_byte*.
2258 (regcache::supply_regset): Likewise.
2259 (regcache_collect_regset): Likewise.
2260 (regcache::collect_regset): Likewise.
2261 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2262 (reg_buffer::raw_supply_part): Likewise.
2263 (regcache::transfer_regset_register): Likewise.
2264 (regcache::transfer_regset): Use gdb_byte*.
2266 2018-06-22 Alan Hayward <alan.hayward@arm.com>
2268 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2270 2018-06-21 Pedro Alves <palves@redhat.com>
2272 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2273 instead of a ptid_t. All callers adjusted.
2274 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2276 (print_ada_task_info, display_current_task_id, task_command_1):
2278 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2280 (breakpoint_kind): Adjust.
2281 (remove_breakpoints_pid): Rename to ...
2282 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2283 pointer. All callers adjusted.
2284 (bpstat_clear_actions): Use inferior_thread.
2285 (get_bpstat_thread): New.
2286 (bpstat_do_actions): Use it.
2287 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2288 to take a thread_info pointer. All callers adjusted.
2289 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2290 (breakpoint_re_set_thread): Use inferior_thread.
2291 * breakpoint.h (struct inferior): Forward declare.
2292 (bpstat_stop_status): Update.
2293 (remove_breakpoints_pid): Delete.
2294 (remove_breakpoints_inf): New.
2295 * bsd-uthread.c (bsd_uthread_target::wait)
2296 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2297 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2298 (maint_btrace_packet_history_cmd)
2299 (maint_btrace_clear_packet_history_cmd): Adjust.
2300 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
2302 * cli/cli-interp.c: Include "inferior.h".
2303 * common/refcounted-object.h (struct
2304 refcounted_object_ref_policy): New.
2305 * compile/compile-object-load.c: Include gdbthread.h.
2306 (store_regs): Use inferior_thread.
2307 * corelow.c (core_target::close): Use current_inferior.
2308 (core_target_open): Adjust to use first_thread_of_inferior and use
2309 the current inferior.
2310 * ctf.c (ctf_target::close): Adjust to use current_inferior.
2311 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
2312 <thread>: ... this new field. All references adjusted.
2313 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
2314 Take a thread_info pointer instead of a ptid_t.
2315 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
2316 (dummy_frame_discard, register_dummy_frame_dtor): Take a
2317 thread_info pointer instead of a ptid_t.
2318 * elfread.c: Include "inferior.h".
2319 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
2320 Use inferior_thread.
2321 * eval.c (evaluate_subexp): Likewise.
2322 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
2324 * gdb_proc_service.h (struct thread_info): Forward declare.
2325 (struct ps_prochandle) <ptid>: Delete, replaced by ...
2326 <thread>: ... this new field. All references adjusted.
2327 * gdbarch.h, gdbarch.c: Regenerate.
2328 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
2329 'thread' parameter. All implementations and callers adjusted.
2330 * gdbthread.h (thread_info) <set_running>: New method.
2331 (delete_thread, delete_thread_silent): Take a thread_info pointer
2333 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
2334 (first_thread_of_process): Delete, replaced by ...
2335 (first_thread_of_inferior): ... this new function. All callers
2337 (any_live_thread_of_process): Delete, replaced by ...
2338 (any_live_thread_of_inferior): ... this new function. All callers
2340 (switch_to_thread, switch_to_no_thread): Declare.
2341 (is_executing): Delete.
2342 (enable_thread_stack_temporaries): Update comment.
2343 <enable_thread_stack_temporaries>: Take a thread_info pointer
2344 instead of a ptid_t. Incref the thread.
2345 <~enable_thread_stack_temporaries>: Decref the thread.
2348 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2349 (get_last_thread_stack_temporary)
2350 (value_in_thread_stack_temporaries, can_access_registers_thread):
2351 Take a thread_info pointer instead of a ptid_t. All callers
2353 * infcall.c (get_call_return_value): Use inferior_thread.
2354 (run_inferior_call): Work with thread pointers instead of ptid_t.
2355 (call_function_by_hand_dummy): Work with thread pointers instead
2356 of ptid_t. Use thread_info_ref.
2357 * infcmd.c (proceed_thread_callback): Access thread's state
2359 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
2360 access thread's state directly.
2361 (continue_command): Use inferior_thread.
2362 (info_program_command): Use find_thread_ptid and access thread
2364 (proceed_after_attach_callback): Use thread state directly.
2365 (notice_new_inferior): Take a thread_info pointer instead of a
2366 ptid_t. All callers adjusted.
2367 (exit_inferior): Take an inferior pointer instead of a pid. All
2369 (exit_inferior_silent): New.
2370 (detach_inferior): Delete.
2371 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
2372 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
2373 (detach_inferior_command, kill_inferior_command): Use
2374 find_inferior_id instead of valid_gdb_inferior_id and
2375 gdb_inferior_id_to_pid.
2376 (inferior_command): Use inferior and thread pointers.
2377 * inferior.h (struct thread_info): Forward declare.
2378 (notice_new_inferior): Take a thread_info pointer instead of a
2379 ptid_t. All callers adjusted.
2380 (detach_inferior): Delete declaration.
2381 (exit_inferior, exit_inferior_silent): Take an inferior pointer
2382 instead of a pid. All callers adjusted.
2383 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
2384 (valid_gdb_inferior_id): Delete.
2385 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
2386 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
2387 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
2389 <inf>: ... this new field.
2390 <step_ptid>: Delete, replaced by ...
2391 <step_thread>: ... this new field.
2392 (get_displaced_stepping_state): Take an inferior pointer instead
2393 of a pid. All callers adjusted.
2394 (displaced_step_in_progress_any_inferior): Adjust.
2395 (displaced_step_in_progress_thread): Take a thread pointer instead
2396 of a ptid_t. All callers adjusted.
2397 (displaced_step_in_progress, add_displaced_stepping_state): Take
2398 an inferior pointer instead of a pid. All callers adjusted.
2399 (get_displaced_step_closure_by_addr): Adjust.
2400 (remove_displaced_stepping_state): Take an inferior pointer
2401 instead of a pid. All callers adjusted.
2402 (displaced_step_prepare_throw, displaced_step_prepare)
2403 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
2404 All callers adjusted.
2405 (start_step_over): Adjust.
2406 (infrun_thread_ptid_changed): Remove bit updating ptids in the
2407 displaced step queue.
2408 (do_target_resume): Adjust.
2409 (fetch_inferior_event): Use inferior_thread.
2410 (context_switch, get_inferior_stop_soon): Take an
2411 execution_control_state pointer instead of a ptid_t. All callers
2413 (switch_to_thread_cleanup): Delete.
2414 (stop_all_threads): Use scoped_restore_current_thread.
2415 * inline-frame.c: Include "gdbthread.h".
2416 (inline_state) <inline_state>: Take a thread pointer instead of a
2417 ptid_t. All callers adjusted.
2418 <ptid>: Delete, replaced by ...
2419 <thread>: ... this new field.
2420 (find_inline_frame_state): Take a thread pointer instead of a
2421 ptid_t. All callers adjusted.
2422 (skip_inline_frames, step_into_inline_frame)
2423 (inline_skipped_frames, inline_skipped_symbol): Take a thread
2424 pointer instead of a ptid_t. All callers adjusted.
2425 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
2426 (inline_skipped_frames, inline_skipped_symbol): Likewise.
2427 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
2429 * linux-nat.c (get_detach_signal): Likewise.
2430 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
2431 (thread_db_notice_clone): Adjust.
2432 (thread_db_find_new_threads_silently)
2433 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
2434 a thread pointer instead of a ptid_t. All callers adjusted.
2435 * mi/mi-cmd-var.c: Include "inferior.h".
2436 (mi_cmd_var_update_iter): Update to use thread pointers.
2437 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
2439 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
2441 (mi_output_running): ... this new function.
2442 (mi_on_resume_1): Adjust to use it.
2443 (mi_user_selected_context_changed): Adjust to use inferior_thread.
2444 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
2446 (interrupt_thread_callback): : Adjust to use thread and inferior
2448 * proc-service.c: Include "gdbthread.h".
2449 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
2450 * progspace-and-thread.c: Include "inferior.h".
2451 * progspace.c: Include "inferior.h".
2452 * python/py-exitedevent.c (create_exited_event_object): Adjust to
2453 hold a reference to an inferior_object.
2454 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
2456 * python/py-inferior.c (struct inferior_object): Give the type a
2457 tag name instead of a typedef.
2458 (python_on_normal_stop): No need to check if the current thread is
2460 (inferior_to_inferior_object): Change return type to
2461 inferior_object. All callers adjusted.
2462 (find_thread_object): Delete, bits factored out to ...
2463 (thread_to_thread_object): ... this new function.
2464 * python/py-infthread.c (create_thread_object): Use
2465 inferior_to_inferior_object.
2466 (thpy_is_stopped): Use thread pointer directly.
2467 (gdbpy_selected_thread): Use inferior_thread.
2468 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
2469 field, replaced with ...
2470 <thread>: ... this new field. All users adjusted.
2471 (btpy_insn_or_gap_new): Drop const.
2472 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
2474 * python/py-record.c: Include "gdbthread.h".
2475 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2476 a ptid_t. All callers adjusted.
2477 (gdbpy_current_recording): Use inferior_thread.
2478 * python/py-record.h (recpy_record_object) <ptid>: Delete
2479 field, replaced with ...
2480 <thread>: ... this new field. All users adjusted.
2481 (recpy_element_object) <ptid>: Delete
2482 field, replaced with ...
2483 <thread>: ... this new field. All users adjusted.
2484 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2485 a ptid_t. All callers adjusted.
2486 * python/py-threadevent.c: Include "gdbthread.h".
2487 (get_event_thread): Use thread_to_thread_object.
2488 * python/python-internal.h (struct inferior_object): Forward
2490 (find_thread_object, find_inferior_object): Delete declarations.
2491 (thread_to_thread_object, inferior_to_inferior_object): New
2493 * record-btrace.c: Include "inferior.h".
2494 (require_btrace_thread): Use inferior_thread.
2495 (record_btrace_frame_sniffer)
2496 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
2497 (get_thread_current_frame): Use scoped_restore_current_thread and
2499 (get_thread_current_frame): Use thread pointer directly.
2500 (record_btrace_replay_at_breakpoint): Use thread's inferior
2502 * record-full.c: Include "inferior.h".
2503 * regcache.c: Include "gdbthread.h".
2504 (get_thread_arch_regcache): Use the inferior's address space
2506 (get_thread_regcache, registers_changed_thread): New.
2507 * regcache.h (get_thread_regcache(thread_info *thread)): New
2509 (registers_changed_thread): New.
2510 (remote_target) <remote_detach_1>: Swap order of parameters.
2511 (remote_add_thread): <remote_add_thread>: Return the new thread.
2512 (get_remote_thread_info(ptid_t)): New overload.
2513 (remote_target::remote_notice_new_inferior): Use thread pointers
2515 (remote_target::process_initial_stop_replies): Use
2516 thread_info::set_running.
2517 (remote_target::remote_detach_1, remote_target::detach)
2518 (extended_remote_target::detach): Adjust.
2519 * stack.c (frame_show_address): Use inferior_thread.
2520 * target-debug.h (target_debug_print_thread_info_pp): New.
2521 * target-delegates.c: Regenerate.
2522 * target.c (default_thread_address_space): Delete.
2523 (memory_xfer_partial_1): Use current_inferior.
2524 (target_detach): Use current_inferior.
2525 (target_thread_address_space): Delete.
2526 (generic_mourn_inferior): Use current_inferior.
2527 * target.h (struct target_ops) <thread_address_space>: Delete.
2528 (target_thread_address_space): Delete.
2529 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
2531 (delete_thread_1, delete_thread, delete_thread_silent): Take a
2532 thread pointer instead of a ptid_t. Adjust all callers.
2533 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
2534 (first_thread_of_process): Delete, replaced by ...
2535 (first_thread_of_inferior): ... this new function. All callers
2537 (any_thread_of_process): Rename to ...
2538 (any_thread_of_inferior): ... this, and take an inferior pointer.
2539 (any_live_thread_of_process): Rename to ...
2540 (any_live_thread_of_inferior): ... this, and take an inferior
2542 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2543 (value_in_thread_stack_temporaries)
2544 (get_last_thread_stack_temporary): Take a thread pointer instead
2545 of a ptid_t. Adjust all callers.
2546 (thread_info::set_running): New.
2547 (validate_registers_access): Use inferior_thread.
2548 (can_access_registers_ptid): Rename to ...
2549 (can_access_registers_thread): ... this, and take a thread
2551 (print_thread_info_1): Adjust to compare thread pointers instead
2553 (switch_to_no_thread, switch_to_thread): Make extern.
2554 (scoped_restore_current_thread::~scoped_restore_current_thread):
2555 Use m_thread pointer directly.
2556 (scoped_restore_current_thread::scoped_restore_current_thread):
2557 Use inferior_thread.
2558 (thread_command): Use thread pointer directly.
2559 (thread_num_make_value_helper): Use inferior_thread.
2560 * top.c (execute_command): Use inferior_thread.
2561 * tui/tui-interp.c: Include "inferior.h".
2562 * varobj.c (varobj_create): Use inferior_thread.
2563 (value_of_root_1): Use find_thread_global_id instead of
2564 global_thread_id_to_ptid.
2566 2018-06-21 Alan Hayward <alan.hayward@arm.com>
2568 * regcache.c (readable_regcache::read_part): Avoid memcpy when
2570 (regcache::write_part): Likewise.
2571 (readable_regcache::cooked_read_part): Update comment.
2572 (readable_regcache::cooked_write_part): Likewise.
2573 * regcache.h: (readable_regcache::read_part): Likewise.
2574 (regcache::write_part): Likewise.
2576 2018-06-21 Richard Bunt <richard.bunt@arm.com>
2577 Dirk Schubert <dirk.schubert@arm.com>
2579 * aarch64-linux-nat.c (post_attach): New.
2580 (aarch64_linux_nat_target::post_attach): Override post_attach to
2581 record the number of hardware debug registers.
2583 2018-06-20 Tom Tromey <tom@tromey.com>
2585 * python/py-param.c (add_setshow_generic): Make parameters const.
2586 (parmpy_init): Update.
2588 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2590 * regcache.h (regcache_cooked_read_ftype): Rename to...
2591 (register_read_ftype): ...this, change type to function_view.
2592 (class reg_buffer) <save>: Remove src parameter.
2593 (readonly_detached_regcache) <readonly_detached_regcache>: Make
2594 parameter non-const in first overload. Remove src parameter in
2596 * regcache.c (do_cooked_read): Remove.
2597 (readonly_detached_regcache::readonly_detached_regcache): Make
2598 parameter non-const, adjust call to other constructor.
2599 (reg_buffer::save): Remove src parameter.
2600 * frame.c (do_frame_register_read): Remove.
2601 (frame_save_as_regcache): Use lambda function.
2602 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
2603 parameter to ppu2spu_data *.
2604 (ppu2spu_sniffer): Use lambda function.
2606 2018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2608 * record-full.c (record_full_target::insert_breakpoint): Remove
2609 "struct" keyword, add const.
2611 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2613 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
2614 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
2615 * configure.ac: Remove AC_PREREQ, add missing quoting.
2616 * gnulib/configure.ac: Modernize usage of
2617 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
2618 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
2619 (AUTOMAKE_VERSION): Bump to 1.15.1.
2620 * configure: Re-generate.
2621 * config.in: Re-generate.
2622 * aclocal.m4: Re-generate.
2623 * gnulib/aclocal.m4: Re-generate.
2624 * gnulib/config.in: Re-generate.
2625 * gnulib/configure: Re-generate.
2626 * gnulib/import/Makefile.in: Re-generate.
2628 2018-06-19 Pedro Alves <palves@redhat.com>
2630 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
2631 (lookup_minimal_symbol_by_pc_section): ... here with
2632 gdb_assert_not_reached added.
2634 2018-06-19 Pedro Alves <palves@redhat.com>
2636 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
2637 parameter with a block parameter. Compare location's block symbol
2638 with the frame's block instead of addresses.
2639 (skip_inline_frames): Pass the current block instead of the
2640 frame's address. Break out as soon as we determine the frame
2641 should not be skipped.
2643 2018-06-18 Tom Tromey <tom@tromey.com>
2645 * solib-aix.c (solib_aix_get_section_offsets): Return
2647 (solib_aix_solib_create_inferior_hook): Update.
2649 2018-06-18 Tom Tromey <tom@tromey.com>
2651 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
2653 2018-06-18 Tom Tromey <tom@tromey.com>
2655 * solib-frv.c (frv_relocate_main_executable): Use
2657 * solib-dsbt.c (dsbt_relocate_main_executable): Use
2660 2018-06-18 Tom Tromey <tom@tromey.com>
2662 * objfiles.h (inhibit_section_map_updates): Update.
2663 (resume_section_map_updates, resume_section_map_updates_cleanup):
2665 * solib-svr4.c (svr4_handle_solib_event): Update.
2666 * objfiles.c (inhibit_section_map_updates): Return
2667 scoped_restore_tmpl<int>.
2668 (resume_section_map_updates, resume_section_map_updates_cleanup):
2671 2018-06-18 Tom Tromey <tom@tromey.com>
2673 * valprint.h (read_string): Update.
2674 * valprint.c (read_string): Change type of "buffer".
2675 (val_print_string): Update.
2676 * python/py-value.c (valpy_string): Update.
2677 * language.h (struct language_defn) <la_get_string>: Change
2679 (default_get_string, c_get_string): Update.
2680 * language.c (default_get_string): Change type of "buffer".
2681 * guile/scm-value.c (gdbscm_value_to_string): Update.
2682 * c-lang.c (c_get_string): Change type of "buffer".
2684 2018-06-18 Tom Tromey <tom@tromey.com>
2686 * ser-mingw.c (struct pipe_state_destroyer): New.
2687 (pipe_state_up): New typedef.
2688 (cleanup_pipe_state): Remove.
2689 (pipe_windows_open): Use pipe_state_up. Don't release argv.
2691 2018-06-18 Tom Tromey <tom@tromey.com>
2693 * rust-lang.h (rust_yyerror): Don't declare.
2694 * rust-lang.c (rust_language_defn): Update.
2695 * rust-exp.y (yyerror): Now static.
2696 * parse.c (parse_exp_in_context_1): Update.
2697 * p-lang.h (p_yyerror): Don't declare.
2698 * p-lang.c (p_language_defn): Update.
2699 * p-exp.y (yyerror): Now static.
2700 * opencl-lang.c (opencl_language_defn): Update.
2701 * objc-lang.c (objc_language_defn): Update.
2702 * m2-lang.h (m2_yyerror): Don't declare.
2703 * m2-lang.c (m2_language_defn): Update.
2704 * m2-exp.y (yyerror): Now static.
2705 * language.h (struct language_defn) <la_error>: Remove.
2706 * language.c (unk_lang_error): Remove.
2707 (unknown_language_defn, auto_language_defn): Remove.
2708 * go-lang.h (go_yyerror): Don't declare.
2709 * go-lang.c (go_language_defn): Update.
2710 * go-exp.y (yyerror): Now static.
2711 * f-lang.h (f_yyerror): Don't declare.
2712 * f-lang.c (f_language_defn): Update.
2713 * f-exp.y (yyerror): Now static.
2714 * d-lang.h (d_yyerror): Don't declare.
2715 * d-lang.c (d_language_defn): Update.
2716 * d-exp.y (yyerror): Now static.
2717 * c-lang.h (c_yyerror): Don't declare.
2718 * c-lang.c (c_language_defn, cplus_language_defn)
2719 (asm_language_defn, minimal_language_defn): Update.
2720 * c-exp.y (yyerror): Now static.
2721 * ada-lang.h (ada_yyerror): Don't declare.
2722 * ada-lang.c (ada_language_defn): Update.
2723 * ada-exp.y (yyerror): Now static.
2725 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2727 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
2728 (store_sveregs_to_thread): Likewise.
2729 (aarch64_linux_fetch_inferior_registers): Check for SVE.
2730 (aarch64_linux_store_inferior_registers): Likewise.
2731 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
2733 (aarch64_sve_regs_copy_to_regcache): Likewise.
2734 (aarch64_sve_regs_copy_from_regcache): Likewise.
2735 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
2737 (aarch64_sve_regs_copy_to_regcache): Likewise.
2738 (aarch64_sve_regs_copy_from_regcache): Likewise.
2739 (sve_context): Structure from Linux headers.
2740 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
2741 (SVE_SIG_ZREG_SIZE): Likewise.
2742 (SVE_SIG_PREG_SIZE): Likewise.
2743 (SVE_SIG_FFR_SIZE): Likewise.
2744 (SVE_SIG_REGS_OFFSET): Likewise.
2745 (SVE_SIG_ZREGS_OFFSET): Likewise.
2746 (SVE_SIG_ZREG_OFFSET): Likewise.
2747 (SVE_SIG_ZREGS_SIZE): Likewise.
2748 (SVE_SIG_PREGS_OFFSET): Likewise.
2749 (SVE_SIG_PREG_OFFSET): Likewise.
2750 (SVE_SIG_PREGS_SIZE): Likewise.
2751 (SVE_SIG_FFR_OFFSET): Likewise.
2752 (SVE_SIG_REGS_SIZE): Likewise.
2753 (SVE_SIG_CONTEXT_SIZE): Likewise.
2754 (SVE_PT_REGS_MASK): Likewise.
2755 (SVE_PT_REGS_FPSIMD): Likewise.
2756 (SVE_PT_REGS_SVE): Likewise.
2757 (SVE_PT_VL_INHERIT): Likewise.
2758 (SVE_PT_VL_ONEXEC): Likewise.
2759 (SVE_PT_REGS_OFFSET): Likewise.
2760 (SVE_PT_FPSIMD_OFFSET): Likewise.
2761 (SVE_PT_FPSIMD_SIZE): Likewise.
2762 (SVE_PT_SVE_ZREG_SIZE): Likewise.
2763 (SVE_PT_SVE_PREG_SIZE): Likewise.
2764 (SVE_PT_SVE_FFR_SIZE): Likewise.
2765 (SVE_PT_SVE_FPSR_SIZE): Likewise.
2766 (SVE_PT_SVE_FPCR_SIZE): Likewise.
2767 (__SVE_SIG_TO_PT): Likewise.
2768 (SVE_PT_SVE_OFFSET): Likewise.
2769 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
2770 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
2771 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
2772 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
2773 (SVE_PT_SVE_PREG_OFFSET): Likewise.
2774 (SVE_PT_SVE_PREGS_SIZE): Likewise.
2775 (SVE_PT_SVE_FFR_OFFSET): Likewise.
2776 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
2777 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
2778 (SVE_PT_SVE_SIZE): Likewise.
2779 (SVE_PT_SIZE): Likewise.
2780 (HAS_SVE_STATE): New define.
2782 2018-06-18 Alan Hayward <alan.hayward@arm.com>
2784 * nat/aarch64-sve-linux-sigcontext.h: New file.
2785 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
2787 (SVE_VQ_MIN): Likewise.
2788 (SVE_VQ_MAX): Likewise.
2789 (SVE_VL_MIN): Likewise.
2790 (SVE_VL_MAX): Likewise.
2791 (SVE_NUM_ZREGS): Likewise.
2792 (SVE_NUM_PREGS): Likewise.
2793 (sve_vl_valid): Likewise.
2794 (struct user_sve_header): Likewise.
2796 2018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
2797 Richard Bunt <Richard.Bunt@arm.com>
2799 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
2800 was requested by GDB.
2802 2018-06-15 Tom de Vries <tdevries@suse.de>
2804 * MAINTAINERS (Write After Approval): Add Tom de Vries.
2806 2018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
2808 * gnulib/update-gnulib.sh: Print expected versions of
2811 2018-06-14 Simon Marchi <simon.marchi@ericsson.com>
2813 * arch-utils.c (default_type_align): Use type_length_units.
2814 * gdbtypes.c (type_align): Use type_length_units.
2816 2018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2818 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
2819 of 'define' command.
2821 2018-06-14 Tom de Vries <tdevries@suse.de>
2824 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
2825 get_no_prettyformat_print_options.
2827 2018-06-13 Simon Marchi <simon.marchi@ericsson.com>
2829 * sparc-nat.h: Include target.h.
2830 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
2831 <fetch_registers>: Remove this argument in function call.
2832 <store_registers>: Remove this argument in function call, remove
2834 <low_forget_process>: Call sparc64_forget_process instead of
2835 sparc_forget_process.
2837 2018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2839 * procfs.c (_initialize_procfs): Use add_inf_child_target.
2840 (procfs_target::make_corefile_notes): Adjust to new
2841 target_read_alloc return type.
2843 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2844 Stephen Roberts <stephen.roberts@arm.com>
2847 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
2848 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
2849 Move should_notify_stop local into more inner scope.
2851 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2852 Stephen Roberts <stephen.roberts@arm.com>
2855 * infrun.c (resume_1): Add call to mark_async_event_handler.
2857 2018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2859 * infrun.c (do_target_wait): Change old version of $pc printed.
2861 2018-06-11 Simon Marchi <simon.marchi@ericsson.com>
2863 * dwarf2read.c (read_index_from_section): Rename to...
2864 (read_gdb_index_from_section): ... this, update all callers.
2865 (dwarf2_read_index): Rename to...
2866 (dwarf2_read_gdb_index): ... this, update all callers.
2868 2018-06-11 John David Anglin <danglin@gcc.gnu.org>
2870 * gdb/hppa-linux-nat.c
2871 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
2872 hppa_linux_nat_target::fetch_registers.
2874 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2876 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
2877 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
2878 (AARCH64_DWARF_SVE_FFR): Likewise.
2879 (AARCH64_DWARF_SVE_P0): Likewise.
2880 (AARCH64_DWARF_SVE_Z0): Likewise.
2882 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2884 * common/common-regcache.h (raw_compare): New function.
2885 * regcache.c (regcache::raw_compare): Likewise.
2886 * regcache.h (regcache::raw_compare): New declaration.
2888 2018-06-11 Alan Hayward <alan.hayward@arm.com>
2890 * common/common-regcache.h (reg_buffer_common): New structure.
2891 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
2892 (reg_buffer::raw_supply): Likewise.
2893 (reg_buffer::raw_supply_integer): Likewise.
2894 (reg_buffer::raw_supply_zeroed): Likewise.
2895 (reg_buffer::raw_collect): Likewise.
2896 (reg_buffer::raw_collect_integer): Likewise.
2897 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
2898 (reg_buffer::raw_supply): Likewise.
2899 (reg_buffer::raw_supply_integer): Likewise.
2900 (reg_buffer::raw_supply_zeroed): Likewise.
2901 (reg_buffer::raw_collect): Likewise.
2902 (reg_buffer::raw_collect_integer): Likewise.
2904 2018-06-10 Tom Tromey <tom@tromey.com>
2906 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
2907 (class remote_state) <stop_reply_queue>: Now std::vector.
2908 (remote_state::~remote_state)
2909 (remote_target::stop_reply_queue_length): Update.
2910 (struct queue_iter_param, remove_child_of_pending_fork)
2911 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
2912 (check_pending_event_prevents_wildcard_vcont_callback)
2913 (remove_stop_reply_for_inferior)
2914 (remove_stop_reply_of_remote_state)
2915 (remote_notif_remove_once_on_match)
2916 (stop_reply_match_ptid_and_ws)
2917 (remote_kill_child_of_pending_fork): Remove.
2918 (remote_target::remove_new_fork_children)
2919 (remote_target::check_pending_events_prevent_wildcard_vcont)
2920 (remote_target::discard_pending_stop_replies)
2921 (remote_target::discard_pending_stop_replies_in_queue)
2922 (remote_target::remote_notif_remove_queued_reply)
2923 (remote_target::queued_stop_reply)
2924 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
2925 (remote_target::wait, remote_target::kill_new_fork_children)
2926 (remote_target::async): Update.
2928 2018-06-10 Tom Tromey <tom@tromey.com>
2930 * record-full.c (record_full_arch_list_cleanups): Remove.
2931 (record_full_message): Use try/catch.
2932 (record_full_wait_cleanups): Remove.
2933 (record_full_wait_1): Use try/catch.
2934 (record_full_restore): Likewise.
2936 2018-06-10 Tom Tromey <tom@tromey.com>
2938 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
2939 declare VEC. Add constructor.
2940 <in_target_beneath>: Now bool.
2941 (record_full_breakpoints): Now a std::vector, static.
2942 (record_full_sync_record_breakpoints)
2943 (record_full_init_record_breakpoints)
2944 (record_full_target::insert_breakpoint)
2945 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
2947 2018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
2949 * dwarf2read.c (process_cu_includes): Remove struct keyword.
2950 * serial.c (serial_interface_lookup): Remove struct keyword.
2952 2018-06-10 Tom Tromey <tom@tromey.com>
2954 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
2956 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
2958 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
2960 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
2961 "beneath" as a method.
2962 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
2963 Use "beneath" as a method.
2965 2018-06-10 Tom Tromey <tom@tromey.com>
2967 * tracefile.c (struct trace_file_writer_deleter): New.
2968 <operator()>: Rename from trace_file_writer_xfree.
2969 (trace_file_writer_up): New typedef.
2970 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
2972 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
2974 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
2975 <m_registers, m_register_status>: Change type to
2977 * regcache.c (reg_buffer::reg_buffer): Use new instead of
2980 2018-06-09 Simon Marchi <simon.marchi@ericsson.com>
2982 * common/common-regcache.h (enum register_status): Add
2983 underlying type "signed char".
2984 * regcache.h (reg_buffer) <m_register_status>: Change type to
2986 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
2987 register_status instead of signed char.
2988 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
2989 (reg_buffer::get_register_status): Remove cast.
2990 (readable_regcache::raw_read): Remove cast.
2991 (readable_regcache::cooked_read): Remove cast.
2993 2018-06-09 Tom Tromey <tom@tromey.com>
2995 * source.c (reverse_search_command, forward_search_command): Use
2998 2018-06-09 Tom Tromey <tom@tromey.com>
3000 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
3001 (serial_ops_list): Now static, std::vector.
3002 (serial_interface_lookup, serial_add_interface): Update.
3004 2018-06-09 Tom Tromey <tom@tromey.com>
3006 * dwarf2read.c (process_cu_includes): Update.
3007 (process_full_comp_unit): Update.
3008 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
3011 2018-06-08 Paul Koning <paul_koning@dell.com>
3015 * python/python.c (do_start_initialization):
3016 Avoid call to internal Python API.
3017 (init__gdb_module): New function.
3019 2018-06-08 Gary Benson <gbenson@redhat.com>
3021 * linux-thread-db.c (valprint.h): New include.
3022 (struct check_thread_db_info): New structure.
3023 (check_thread_db_on_load, tdb_testinfo): New static globals.
3024 (check_thread_db, check_thread_db_callback): New functions.
3025 (try_thread_db_load_1): Run integrity checks if requested.
3026 (maintenance_check_libthread_db): New function.
3027 (_initialize_thread_db): Register "maint check libthread-db"
3028 and "maint set/show check-libthread-db".
3029 * NEWS: Mention the above new commands.
3031 2018-06-08 Tom Tromey <tom@tromey.com>
3033 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
3036 2018-06-08 Tom Tromey <tom@tromey.com>
3038 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
3040 2018-06-08 Tom Tromey <tom@tromey.com>
3042 * common/btrace-common.h (struct btrace_data): Add constructor,
3043 destructor, move assignment operator.
3044 <empty, clear, fini>: New methods.
3045 <format>: Initialize.
3046 (btrace_data_init, btrace_data_fini, btrace_data_clear)
3047 (btrace_data_empty): Don't declare.
3048 * common/btrace-common.c (btrace_data_init): Remove.
3049 (btrace_data::fini): Rename from btrace_data_fini.
3050 (btrace_data::empty): Rename from btrace_data_empty.
3051 (btrace_data::clear): Rename from btrace_data_clear. Return
3053 * btrace.h (make_cleanup_btrace_data): Don't declare.
3054 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
3055 (parse_xml_btrace): Update.
3056 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
3057 (maint_btrace_clear_packet_history_cmd): Update.
3059 2018-06-07 Pedro Alves <palves@redhat.com>
3061 * target.h (target_ops) <beneath>: Now a method. All references
3063 (class target_stack): New.
3064 * target.c (g_target_stack): New.
3065 (g_current_top_target): Delete.
3066 (current_top_target): Get the top target out of g_target_stack.
3067 (target_stack::push, target_stack::unpush): New.
3068 (push_target, unpush_target): Reimplement.
3069 (target_is_pushed): Reimplement in terms of g_target_stack.
3070 (target_ops::beneath, target_stack::find_beneath): New.
3072 2018-06-07 Pedro Alves <palves@redhat.com>
3074 * target.h (find_target_beneath): Delete declaration.
3075 * target.c (find_target_beneath): Delete definition.
3076 * aix-thread.c: All callers of find_target_beneath adjusted to
3077 call target_ops::beneath instead.
3078 * bsd-uthread.c: Likewise.
3079 * linux-thread-db.c: Likewise.
3080 * ravenscar-thread.c: Likewise.
3081 * sol-thread.c: Likewise.
3082 * spu-multiarch.c: Likewise.
3084 2018-06-07 Pedro Alves <palves@redhat.com>
3086 * target.h (target_ops) <beneath>: Now a method. All references
3088 (target_ops) <m_beneath>: New.
3089 * target.c (target_ops::beneath): New.
3090 * corelow.c: Adjust all references to target_ops::beneath.
3091 * linux-thread-db.c: Likewise.
3092 * make-target-delegates: Likewise.
3093 * record-btrace.c: Likewise.
3094 * record-full.c: Likewise.
3095 * remote.c: Likewise.
3096 * target.c: Likewise.
3097 * target-delegates.c: Regenerate.
3099 2018-06-07 Pedro Alves <palves@redhat.com>
3101 * target.h (target_stack): Delete.
3102 (current_top_target): Declare function.
3103 * target.c (target_stack): Delete.
3104 (g_current_top_target): New.
3105 (current_top_target): New function.
3106 * auxv.c: Use current_top_target instead of target_stack
3108 * avr-tdep.c: Likewise.
3109 * breakpoint.c: Likewise.
3110 * corefile.c: Likewise.
3111 * elfread.c: Likewise.
3113 * exceptions.c: Likewise.
3114 * frame.c: Likewise.
3115 * gdbarch-selftests.c: Likewise.
3116 * gnu-v3-abi.c: Likewise.
3117 * ia64-tdep.c: Likewise.
3118 * ia64-vms-tdep.c: Likewise.
3119 * infcall.c: Likewise.
3120 * infcmd.c: Likewise.
3121 * infrun.c: Likewise.
3122 * linespec.c: Likewise.
3123 * linux-tdep.c: Likewise.
3124 * minsyms.c: Likewise.
3125 * ppc-linux-nat.c: Likewise.
3126 * ppc-linux-tdep.c: Likewise.
3127 * procfs.c: Likewise.
3128 * regcache.c: Likewise.
3129 * remote.c: Likewise.
3130 * rs6000-tdep.c: Likewise.
3131 * s390-linux-nat.c: Likewise.
3132 * s390-tdep.c: Likewise.
3133 * solib-aix.c: Likewise.
3134 * solib-darwin.c: Likewise.
3135 * solib-dsbt.c: Likewise.
3136 * solib-spu.c: Likewise.
3137 * solib-svr4.c: Likewise.
3138 * solib-target.c: Likewise.
3139 * sparc-tdep.c: Likewise.
3140 * sparc64-tdep.c: Likewise.
3141 * spu-tdep.c: Likewise.
3142 * symfile.c: Likewise.
3143 * symtab.c: Likewise.
3144 * target-descriptions.c: Likewise.
3145 * target-memory.c: Likewise.
3146 * target.c: Likewise.
3147 * target.h: Likewise.
3148 * tracefile-tfile.c: Likewise.
3149 * tracepoint.c: Likewise.
3150 * valops.c: Likewise.
3151 * valprint.c: Likewise.
3152 * value.c: Likewise.
3153 * windows-tdep.c: Likewise.
3154 * mi/mi-main.c: Likewise.
3156 2018-06-07 Tom Tromey <tom@tromey.com>
3158 * valprint.h (build_address_symbolic): Declare.
3159 * printcmd.c (print_address_symbolic): Update.
3160 (build_address_symbolic): Change "name" and "filename" to
3162 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
3164 * defs.h (build_address_symbolic): Remove declaration.
3166 2018-06-07 Alan Hayward <alan.hayward@arm.com>
3168 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
3169 (aarch64_vnv_type): Add function.
3170 (aarch64_pseudo_register_name): Add V regs for SVE.
3171 (aarch64_pseudo_register_type): Likewise.
3172 (aarch64_pseudo_register_reggroup_p): Likewise.
3173 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
3174 (aarch64_pseudo_read_value): Add V regs for SVE.
3175 (aarch64_pseudo_write_2): Use V0 offset for SVE
3176 (aarch64_pseudo_write): Add V regs for SVE.
3177 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
3179 2018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
3181 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
3182 (sve_vl_from_vq): Likewise.
3184 2018-06-05 Tom Tromey <tom@tromey.com>
3186 * cli/cli-cmds.c (show_version): Update.
3187 * top.c (print_gdb_version): Add "interactive" parameter.
3189 * main.c (captured_main_1): Update.
3190 * top.h (print_gdb_version): Add "interactive" parameter and a
3193 2018-06-05 David Malcolm <dmalcolm@redhat.com>
3195 * common/enum-flags.h: Add trailing semicolon to example in
3198 2018-06-05 Tom Tromey <tom@tromey.com>
3201 * NEWS: Add entry about pager.
3202 * utils.c (pagination_disabled_for_command): New global.
3203 (prompt_for_continue): Allow "c" response to prompt.
3204 (reinitialize_more_filter): Clear
3205 pagination_disabled_for_command.
3206 (fputs_maybe_filtered): Check pagination_disabled_for_command.
3208 2018-06-04 Tom Tromey <tom@tromey.com>
3210 * ada-lang.h (ada_lookup_symbol_list): Update.
3211 * ada-lang.c (resolve_subexp): Update.
3212 (symbols_are_identical_enums): Change type of syms. Remove nsyms
3214 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
3215 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
3216 results parameter to std::vector.
3217 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
3219 * ada-exp.y (block_lookup): Update.
3220 (select_possible_type_sym): Change type of syms. Remove nsyms
3222 (write_var_or_type, write_name_assoc): Update.
3224 2018-06-04 Joel Brobecker <brobecker@adacore.com>
3226 * windows-nat.c (windows_nat_target::xfer_partial): Return
3227 TARGET_XFER_E_IO if we need to delegate to the target beneath
3228 but BENEATH is NULL.
3230 2018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3232 * Makefile.in (config.status): Add configure.nat as a
3235 2018-06-04 Tom Tromey <tom@tromey.com>
3237 * cp-name-parser.y (cpname_state): Add method declarations.
3238 (HANDLE_QUAL): Update.
3239 (cpname_state::d_grab, cpname_state::fill_comp)
3240 (cpname_state::make_operator, cpname_state::make_dtor)
3241 (cpname_state::make_builtin_type, cpname_state::make_name)
3242 (cpname_state::d_qualify, cpname_state::d_int_type)
3243 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3244 (%union): Move earlier.
3246 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3248 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3250 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3252 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3253 (aarch64_pseudo_write_1): Likewise.
3254 (aarch64_pseudo_read_value): Use helper.
3255 (aarch64_pseudo_write): Likewise.
3257 2018-06-04 Pedro Alves <palves@redhat.com>
3259 * darwin-nat.c (darwin_ops): Delete.
3260 (darwin_attach_pid): Use get_native_target.
3262 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3264 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3265 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3267 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3269 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3270 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3271 (aarch64_gdbarch_init): Check for SVE.
3272 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3274 2018-06-04 Alan Hayward <alan.hayward@arm.com>
3276 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3277 * aarch64-tdep.h (aarch64_read_description): Likewise.
3278 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3279 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3280 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3281 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3282 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3284 2018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3286 * value.c (value_fetch_lazy_bitfield): New.
3287 (value_fetch_lazy_memory): New.
3288 (value_fetch_lazy_register): New.
3289 (value_fetch_lazy): Factor out to smaller functions.
3291 2018-06-01 Tom Tromey <tom@tromey.com>
3293 * cp-name-parser.y (backslashable, represented): Now const.
3295 2018-06-01 Tom Tromey <tom@tromey.com>
3297 * cp-name-parser.y: Include parser-defs.h.
3298 (parser_fprintf): Remove declaration.
3300 2018-06-01 Tom Tromey <tom@tromey.com>
3302 * cp-name-parser.y: Use %pure-parser, %lex-param, and
3304 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
3305 (global_result): Remove globals.
3306 (struct cpname_state): New.
3307 (yyparse): Don't declare.
3308 (yylex, yyerror): Move declarations after %union.
3309 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
3310 (make_name): Add state parameter.
3312 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
3314 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
3316 (yylex): Add lvalp, state parameters.
3317 (yyerror): Add state parameter.
3318 (cp_demangled_name_to_comp): Update.
3320 2018-06-01 Tom Tromey <tom@tromey.com>
3322 * cp-name-parser.y (parser_fprintf): Declare.
3323 (GDB_YY_REMAP_PREFIX): Define.
3324 Include yy-remap.h. Don't redefine yy* identifiers.
3326 2018-06-01 Tom Tromey <tom@tromey.com>
3328 * python/py-type.c (typy_legacy_template_argument): Update.
3329 * cp-support.h (cp_demangled_name_to_comp): Update.
3330 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
3331 parameter to be a "std::string *".
3334 2018-06-01 H.J. Lu <hongjiu.lu@intel.com>
3336 * ada-lex.l: Include "diagnostics.h" instead of
3337 "common/diagnostics.h".
3338 * unittests/environ-selftests.c: Likewise.
3339 * common/diagnostics.h: Moved to ../include.
3341 2018-06-01 Joel Brobecker <brobecker@adacore.com>
3343 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
3344 to language_mode_manual while calling breakpoint_re_set_one.
3346 2018-06-01 Tom Tromey <tom@tromey.com>
3348 * valops.c (value_cast_structs, destructor_name_p): Update.
3349 * symtab.c (gdb_mangle_name): Update.
3350 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
3352 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
3353 (pascal_object_print_value_fields, pascal_object_print_value):
3355 * p-typeprint.c (pascal_type_print_derivation_info): Update.
3356 * linespec.c (find_methods): Update.
3357 * gdbtypes.h (type_name_no_tag): Remove.
3358 (type_name_or_error): Rename from type_name_no_tag_or_error.
3359 * gdbtypes.c (type_name_no_tag): Remove.
3360 (type_name_or_error): Rename from type_name_no_tag_or_error.
3361 (lookup_struct_elt_type, check_typedef): Update.
3362 * expprint.c (print_subexp_standard): Update.
3363 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
3364 * d-namespace.c (d_lookup_nested_symbol): Update.
3365 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
3366 (cp_print_class_member): Update.
3367 * cp-namespace.c (cp_lookup_nested_symbol): Update.
3368 * completer.c (add_struct_fields): Update.
3369 * c-typeprint.c (cp_type_print_derivation_info)
3370 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
3372 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
3373 (ada_prefer_type, ada_is_exception_sym): Update.
3375 2018-06-01 Tom Tromey <tom@tromey.com>
3377 * valops.c (enum_constant_from_type, value_namespace_elt)
3378 (value_maybe_namespace_elt): Update.
3379 * valarith.c (find_size_for_pointer_math): Update.
3380 * target-descriptions.c (make_gdb_type): Update.
3381 * symmisc.c (print_symbol): Update.
3382 * stabsread.c (define_symbol, read_type)
3383 (complain_about_struct_wipeout, add_undefined_type)
3384 (cleanup_undefined_types_1): Update.
3385 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
3386 (rust_range_type_p, val_print_struct, rust_print_struct_def)
3387 (rust_internal_print_type, rust_composite_type)
3388 (rust_evaluate_funcall, rust_evaluate_subexp)
3389 (rust_inclusive_range_type_p): Update.
3390 * python/py-type.c (typy_get_tag): Update.
3391 * p-typeprint.c (pascal_type_print_base): Update.
3392 * mdebugread.c (parse_symbol, parse_type): Update.
3393 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
3395 * guile/scm-type.c (gdbscm_type_tag): Update.
3396 * go-lang.c (sixg_string_p): Update.
3397 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
3399 * gdbtypes.h (struct main_type) <tag_name>: Remove.
3400 (TYPE_TAG_NAME): Remove.
3401 * gdbtypes.c (type_name_no_tag): Simplify.
3402 (check_typedef, check_types_equal, recursive_dump_type)
3403 (copy_type_recursive, arch_composite_type): Update.
3404 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
3405 in summary mode when needed.
3406 * eval.c (evaluate_funcall): Update.
3407 * dwarf2read.c (fixup_go_packaging, read_structure_type)
3408 (process_structure_scope, read_enumeration_type)
3409 (read_namespace_type, read_module_type, determine_prefix): Update.
3410 * cp-support.c (inspect_type): Update.
3411 * coffread.c (process_coff_symbol, decode_base_type): Update.
3412 * c-varobj.c (c_is_path_expr_parent): Update.
3413 * c-typeprint.c (c_type_print_base_struct_union): Update.
3414 (c_type_print_base_1): Update. Print struct/class/union/enum in
3415 summary when using C language.
3416 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
3417 (gen_maybe_namespace_elt): Update.
3418 * ada-lang.c (ada_type_name): Simplify.
3419 (empty_record, ada_template_to_fixed_record_type_1)
3420 (template_to_static_fixed_type)
3421 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
3423 2018-06-01 Tom Tromey <tom@tromey.com>
3425 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
3427 * c-typeprint.c (c_print_type_1): Add "language" parameter.
3428 (c_print_type): Update.
3429 (c_print_type): New overload.
3430 (c_type_print_varspec_prefix, c_type_print_args)
3431 (c_type_print_varspec_suffix, c_print_type_no_offsets)
3432 (c_type_print_base_struct_union, c_type_print_base_1)
3433 (cp_type_print_method_args): Add "language" parameter.
3434 (c_type_print_base): Update.
3435 * c-lang.h (c_print_type): Add new overload.
3437 2018-06-01 Tom Tromey <tom@tromey.com>
3439 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
3440 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
3442 2018-06-01 Alan Hayward <alan.hayward@arm.com>
3444 * aarch64-tdep.c (aarch64_sve_register_names): New const
3446 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
3447 (AARCH64_SVE_Z_REGS_NUM): New define.
3448 (AARCH64_SVE_P_REGS_NUM): Likewise.
3449 (AARCH64_SVE_NUM_REGS): Likewise.
3451 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
3453 * nat/linux-ptrace.h [__alpha__]
3454 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
3457 2018-05-31 Maciej W. Rozycki <macro@mips.com>
3459 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
3460 the endianness selected.
3461 * NEWS: Document `set endian auto' mode operation update.
3463 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3465 * Makefile.in: Add new header.
3466 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
3467 (sve_vl_from_vg): Likewise.
3468 (sve_vq_from_vl): Likewise.
3469 (sve_vl_from_vq): Likewise.
3470 (sve_vq_from_vg): Likewise.
3471 (sve_vg_from_vq): Likewise.
3472 * configure.nat: Add new c file.
3473 * nat/aarch64-sve-linux-ptrace.c: New file.
3474 * nat/aarch64-sve-linux-ptrace.h: New file.
3476 2018-05-31 Alan Hayward <alan.hayward@arm.com>
3478 * aarch64-linux-nat.c (aarch64_linux_read_description):
3480 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
3482 * aarch64-tdep.c (tdesc_aarch64_list): Add.
3483 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
3484 (aarch64_gdbarch_init): Add parmeter zero.
3485 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
3486 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
3487 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
3489 * doc/gdb.texinfo: Describe SVE feature
3490 * features/aarch64-sve.c: New file.
3492 2018-05-31 Omair Javaid <omair.javaid@linaro.org>
3495 * gdbarch.sh (significant_addr_bit): Default to zero when
3496 not set by target architecture.
3497 * gdbarch.c: Re-generated.
3498 * utils.c (address_significant): Update.
3500 2018-05-30 Joel Brobecker <brobecker@adacore.com>
3502 * stack.c (func_command): Remove trailing newline in call to error.
3504 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3506 * regcache.h (regcache_raw_collect): Remove, update callers to
3507 use regcache::raw_collect.
3508 * regcache.c (regcache_raw_collect): Remove.
3510 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3512 * regcache.h (regcache_raw_supply): Remove, update callers to
3513 use detached_regcache::raw_supply.
3514 * regcache.c (regcache_raw_supply): Remove.
3516 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3518 * regcache.h (regcache_cooked_write_part): Remove, update
3519 callers to use regcache::cooked_write_part.
3520 * regcache.c (regcache_cooked_write_part): Remove.
3522 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3524 * regcache.h (regcache_cooked_read_part): Remove, update callers
3525 to use readable_regcache::cooked_read_part.
3526 * regcache.c (regcache_cooked_read_part): Remove.
3528 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3530 * regcache.h (regcache_cooked_read_value): Remove, update
3531 callers to use readable_regcache::cooked_read_value.
3532 * regcache.c (regcache_cooked_read_value): Remove.
3534 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3536 * regcache.h (regcache_cooked_write): Remove, update callers to
3537 use regcache::cooked_write.
3538 * regcache.c (regcache_cooked_write): Remove.
3540 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3542 * regcache.h (regcache_invalidate): Remove, update callers to
3543 use detached_regcache::invalidate instead.
3544 * regcache.c (regcache_invalidate): Remove.
3546 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3548 * regcache.h (regcache_raw_write_part): Remove, update callers
3549 to use regcache::raw_write_part instead.
3550 * regcache.c (regcache_raw_write_part): Remove.
3552 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3554 * regcache.h (regcache_raw_read_part): Remove, update callers to
3555 use readable_regcache::raw_read_part instead.
3556 * regcache.c (regcache_raw_read_part): Remove.
3558 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3560 * regcache.h (regcache_cooked_read): Remove, update callers to
3561 use readable_regcache::cooked_read instead.
3562 * regcache.c (regcache_cooked_read): Remove.
3564 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3566 * regcache.h (regcache_raw_write): Remove, update callers to use
3567 regcache::raw_write instead.
3568 * regcache.c (regcache_raw_write): Remove.
3570 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3572 * regcache.h (regcache_raw_read): Remove, update callers to use
3573 readable_regcache::raw_read instead.
3574 * regcache.c (regcache_raw_read): Remove.
3576 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3578 * regcache.h (regcache_raw_update): Remove, update callers to
3579 use readable_regcache::raw_update instead.
3580 * regcache.c (regcache_raw_update): Remove.
3582 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3584 * regcache.h (regcache_register_status): Remove, update callers
3585 to use reg_buffer::get_register_status directly instead.
3586 * regcache.c (regcache_register_status): Remove.
3588 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3590 * regcache.h (regcache_get_ptid): Remove, update all callers to
3591 call regcache::ptid instead.
3592 * regcache.c (regcache_get_ptid): Remove.
3594 2018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3596 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
3598 2018-05-30 Pedro Alves <palves@redhat.com>
3600 * common/common-exceptions.h (exception_rethrow): Use
3603 2018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
3605 * breakpoint.c (print_solib_event, check_status_catch_solib):
3606 Remove struct keyword in range-based for loops.
3607 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
3608 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
3610 * linespec.c (find_superclass_methods, search_minsyms_for_name):
3612 * symfile.c (addr_info_make_relative): Likewise.
3613 * thread.c (value_in_thread_stack_temporaries): Likewise.
3615 2018-06-12 Weimin Pan <weimin.pan@oracle.com>
3618 * valops.c (value_struct_elt_for_reference): Call check_typedef on
3619 aggregate type to get its real type before accessing it.
3621 2018-05-29 Weimin Pan <weimin.pan@oracle.com>
3623 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
3624 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
3625 * coff-pe-read.c (add_pe_forwarded_sym): Replace
3626 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
3627 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
3628 * jit.c (jit_breakpoint_re_set_internal): Likewise.
3629 * printcmd.c (info_address_command): Likewise.
3631 2018-05-29 Tom Tromey <tom@tromey.com>
3633 * windows-nat.c (handle_exception): Update fall-through comment.
3635 2018-05-29 Tom Tromey <tom@tromey.com>
3637 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
3638 (struct program_space) <added_solibs>: Now a std::vector.
3639 * breakpoint.c (print_solib_event): Update.
3640 (check_status_catch_solib): Update.
3641 * progspace.c (clear_program_space_solib_cache): Update.
3642 * solib.c (update_solib_list): Update.
3644 2018-05-29 Tom Tromey <tom@tromey.com>
3646 * python/py-type.c (typy_richcompare): Update.
3647 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
3648 * gdbtypes.h (types_deeply_equal): Return bool.
3649 (types_equal): Likewise.
3650 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
3652 (check_types_equal): Change worklist to std::vector. Return
3654 (struct type_equality_entry): Add constructor.
3655 (compare_maybe_null_strings): Return bool.
3656 (check_types_worklist): Return bool. Change worklist to
3658 (types_deeply_equal): Use std::vector.
3659 (types_equal): Return bool.
3660 (compare_maybe_null_strings): Simplify.
3662 2018-05-29 Tom Tromey <tom@tromey.com>
3664 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
3666 2018-05-29 Tom Tromey <tom@tromey.com>
3668 * objc-lang.h: Don't include cp-support.h.
3669 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
3672 2018-05-27 Tom Tromey <tom@tromey.com>
3674 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
3676 2018-05-25 Tom Tromey <tom@tromey.com>
3678 * value.c (value::location): Initialize.
3680 2018-05-25 Tom Tromey <tom@tromey.com>
3682 * dbxread.c (init_bincl_list): Remove.
3683 (bincl_list): Now a std::vector.
3684 (bincls_allocated, next_bincl): Remove.
3685 (free_bincl_list, do_free_bincl_list_cleanup)
3686 (make_cleanup_free_bincl_list): Remove.
3687 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
3689 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
3690 (struct header_file_location): Add constructor.
3691 (add_bincl_to_list): Remove.
3693 2018-05-25 Tom Tromey <tom@tromey.com>
3695 * tui/tui.c (tui_enable): Update.
3696 * mi/mi-interp.c (mi_interp::init): Update.
3697 * interps.h (class interp) <name>: New method.
3698 <m_name>: Rename from name.
3699 (~scoped_restore_interp): Update.
3700 * interps.c (interp::interp): Update.
3701 (interp_add, interp_set, interp_lookup_existing)
3702 (current_interp_named_p): Update.
3704 2018-05-25 Tom Tromey <tom@tromey.com>
3706 * interps.c (interp_name): Remove.
3707 * mi/mi-interp.c (mi_interp::init): Update.
3708 * interps.h (interp_name): Remove.
3709 (~scoped_restore_interp): Update.
3710 * tui/tui.c (tui_enable): Update.
3712 2018-05-25 Tom Tromey <tom@tromey.com>
3714 * utils.c (fputs_maybe_filtered): Update.
3715 * linespec.c (decode_line_full): Update.
3716 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
3717 (mi_print_breakpoint_for_event, mi_solib_loaded)
3718 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3719 (mi_user_selected_context_changed): Update.
3720 * mi/mi-main.c (mi_execute_command): Update.
3721 * cli/cli-script.c (execute_control_command): Update.
3722 * python/python.c (execute_gdb_command): Update.
3723 * solib.c (info_sharedlibrary_command): Update.
3724 * interps.c (interp_ui_out): Remove.
3725 * interps.h (interp_ui_out): Remove.
3727 2018-05-25 Tom Tromey <tom@tromey.com>
3729 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
3730 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
3731 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
3733 2018-05-25 Tom Tromey <tom@tromey.com>
3735 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
3736 * interps.c (interp_exec): Use scoped_restore.
3738 2018-05-25 Tom Tromey <tom@tromey.com>
3740 * remote.c (remote_target::remote_file_get): Use
3742 (remote_target::remote_file_put): Likewise.
3744 2018-05-25 Tom Tromey <tom@tromey.com>
3746 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
3748 (get_pe_section_index, add_pe_exported_sym): Update.
3749 (read_pe_exported_syms): Use gdb::def_vector.
3751 2018-05-25 Tom Tromey <tom@tromey.com>
3753 * frame.c (remove_prev_frame): Remove.
3754 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
3756 2018-05-25 Maciej W. Rozycki <macro@mips.com>
3758 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
3760 * mips-linux-nat.c (supply_fpregset): Always call
3761 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
3762 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
3763 `mips_fill_fpregset'.
3764 * mips-linux-tdep.c (mips_supply_fpregset)
3765 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
3766 (mips_fill_fpregset_wrapper): Remove functions.
3767 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
3768 (mips_linux_fpregset): Remove variable.
3769 (mips_linux_iterate_over_regset_sections): Use
3770 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
3771 (mips_linux_o32_sigframe_init): Remove comment.
3773 2018-05-25 Pedro Alves <palves@redhat.com>
3775 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
3776 (struct readahead_cache, struct packet_reg, struct
3777 remote_arch_state, class remote_state): Move higher up in the
3779 (remote_target::m_remote_state): Now an object instead of a pointer.
3780 (remote_target::get_remote_state): Adjust.
3782 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3784 * stack.c (select_and_print_frame): Delete.
3785 (struct function_bounds): Move struct within function.
3786 (func_command): Most content moved into new function
3787 find_frame_for_function, use new function, print result, add
3789 (find_frame_for_function): New function, now returns a result.
3791 2018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3793 * stack.c (iterate_over_block_arg_vars): Fix comment.
3794 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
3796 2018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3800 (scoped_restore_selected_frame::scoped_restore_selected_frame):
3802 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
3804 * frame.h (class scoped_restore_selected_frame): New class.
3805 * stack.c (print_frame_local_vars): Remove catching and rethrowing
3806 of any exception, use scoped_restore_selected_frame to restore the
3809 2018-05-24 Pedro Alves <palves@redhat.com>
3811 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
3814 2018-05-23 Tom Tromey <tom@tromey.com>
3816 * complaints.c (struct complaints): Remove.
3817 (symfile_complaint_book): Remove.
3818 (series): New global.
3819 (complaint_internal): Update.
3820 (clear_complaints): Update.
3822 2018-05-23 Tom Tromey <tom@tromey.com>
3824 * complaints.c (counters): New global.
3825 (struct complain): Remove.
3826 (struct complaints) <root>: Remove.
3827 (complaint_sentinel): Remove.
3828 (symfile_complaint_book): Update.
3829 (find_complaint) Remove.
3830 (complaint_internal, clear_complaints): Update.
3832 2018-05-23 Tom Tromey <tom@tromey.com>
3834 * complaints.c (struct complain) <file, line>: Remove.
3835 (find_complaint): Remove file, line parameters.
3836 (complaint_internal): Update.
3838 2018-05-23 Tom Tromey <tom@tromey.com>
3840 * complaints.c (vcomplaint): Remove.
3841 (complaint_internal) Merge in contents of vcomplaint.
3843 2018-05-23 Tom Tromey <tom@tromey.com>
3845 * complaints.c (struct complaints) <explanation>: Remove.
3846 (symfile_explanations): Remove.
3847 (symfile_complaint_book): Update.
3848 (vcomplaint): Update.
3849 (struct explanation): Remove.
3851 2018-05-23 Tom Tromey <tom@tromey.com>
3853 * complaints.c (symfile_complaints): Remove.
3854 (complaint_internal): Remove "complaints" parameter.
3855 (clear_complaints, vcomplaint): Remove "c" parameter.
3856 (get_complaints): Remove.
3857 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
3858 (dwarf2_debug_line_missing_file_complaint)
3859 (dwarf2_debug_line_missing_end_sequence_complaint)
3860 (dwarf2_complex_location_expr_complaint)
3861 (dwarf2_const_value_length_mismatch_complaint)
3862 (dwarf2_section_buffer_overflow_complaint)
3863 (dwarf2_macro_malformed_definition_complaint)
3864 (dwarf2_invalid_attrib_class_complaint)
3865 (create_addrmap_from_index, dw2_symtab_iter_next)
3866 (dw2_expand_marked_cus)
3867 (dw2_debug_names_iterator::find_vec_in_debug_names)
3868 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
3869 (create_debug_type_hash_table, init_cutu_and_read_dies)
3870 (partial_die_parent_scope, add_partial_enumeration)
3871 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
3872 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
3873 (read_import_statement, read_file_scope, create_dwo_cu_reader)
3874 (create_cus_hash_table, create_dwp_hash_table)
3875 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
3876 (dwarf2_rnglists_process, dwarf2_ranges_process)
3877 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
3878 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
3879 (handle_struct_member_die, process_structure_scope)
3880 (read_array_type, read_common_block, read_module_type)
3881 (read_tag_pointer_type, read_typedef, read_base_type)
3882 (read_subrange_type, load_partial_dies, partial_die_info::read)
3883 (partial_die_info::read, partial_die_info::read)
3884 (partial_die_info::read, read_checked_initial_length_and_offset)
3885 (dwarf2_string_attr, read_formatted_entries)
3886 (dwarf_decode_line_header)
3887 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3888 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
3889 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
3890 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3891 (get_signatured_type, get_DW_AT_signature_type)
3892 (decode_locdesc, file_file_name, consume_improper_spaces)
3893 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
3894 (dwarf_decode_macro_bytes, dwarf_decode_macros)
3895 (dwarf2_symbol_mark_computed, set_die_type)
3896 (read_attribute_value): Update.
3897 * stap-probe.c (handle_stap_probe, get_stap_base_address):
3899 * dbxread.c (unknown_symtype_complaint)
3900 (lbrac_mismatch_complaint, repeated_header_complaint)
3901 (set_namestring, function_outside_compilation_unit_complaint)
3902 (read_dbx_symtab, process_one_symbol): Update.
3903 * gdbtypes.c (stub_noname_complaint): Update.
3904 * windows-nat.c (handle_unload_dll): Update.
3905 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
3906 (decode_base_type): Update.
3907 * xcoffread.c (bf_notfound_complaint, ef_complaint)
3908 (eb_complaint, record_include_begin, record_include_end)
3909 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
3910 (process_xcoff_symbol, read_symbol)
3911 (function_outside_compilation_unit_complaint)
3912 (scan_xcoff_symtab): Update.
3913 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
3914 * buildsym.c (finish_block_internal, make_blockvector)
3915 (end_symtab_get_static_block, augment_type_symtab): Update.
3916 * dtrace-probe.c (dtrace_process_dof)
3917 (dtrace_static_probe_ops::get_probes): Update.
3918 * complaints.h (struct complaint): Don't declare.
3919 (symfile_complaints): Remove.
3920 (complaint_internal): Remove "complaints" parameter.
3921 (complaint): Likewise.
3922 (clear_complaints): Likewise.
3923 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3924 (reread_symbols): Update.
3925 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
3926 (dwarf2_frame_cache, decode_frame_entry): Update.
3927 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
3928 * objc-lang.c (lookup_objc_class, lookup_child_selector)
3929 (info_selectors_command): Update.
3930 * macrotab.c (macro_include, check_for_redefinition)
3931 (macro_undef): Update.
3932 * objfiles.c (filter_overlapping_sections): Update.
3933 * stabsread.c (invalid_cpp_abbrev_complaint)
3934 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
3935 (define_symbol, error_type, read_type, rs6000_builtin_type)
3936 (stabs_method_name_from_physname, read_member_functions)
3937 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
3938 (attach_fields_to_type, complain_about_struct_wipeout)
3939 (read_range_type, read_args, common_block_start)
3940 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
3942 * mdebugread.c (index_complaint, unknown_ext_complaint)
3943 (basic_type_complaint, bad_tag_guess_complaint)
3944 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
3945 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
3946 (parse_procedure, parse_lines)
3947 (function_outside_compilation_unit_complaint)
3948 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
3949 (bad_tag_guess_complaint, reg_value_complaint): Update.
3950 * cp-support.c (demangled_name_complaint): Update.
3951 * macroscope.c (sal_macro_scope): Update.
3952 * dwarf-index-write.c (class debug_names): Update.
3954 2018-05-23 Tom Tromey <tom@tromey.com>
3956 * complaints.c (clear_complaints): Remove "noisy" parameter.
3957 * complaints.h (clear_complaints): Update.
3958 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3959 (reread_symbols): Update.
3961 2018-05-23 Tom Tromey <tom@tromey.com>
3963 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
3965 (vcomplaint, clear_complaints): Update.
3966 (symfile_explanations): Remove some messages.
3968 2018-05-23 Tom Tromey <tom@tromey.com>
3970 * complaints.c (internal_complaint): Remove.
3971 * complaints.h (internal_complaint): Remove.
3973 2018-05-22 Maciej W. Rozycki <macro@mips.com>
3975 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
3977 2018-05-22 Pedro Alves <palves@redhat.com>
3979 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
3980 (remote_fileio_badfd, remote_fileio_return_errno)
3981 (remote_fileio_return_success, remote_fileio_func_open)
3982 (remote_fileio_func_open, remote_fileio_func_close)
3983 (remote_fileio_func_read, remote_fileio_func_write)
3984 (remote_fileio_func_lseek, remote_fileio_func_rename)
3985 (remote_fileio_func_unlink, remote_fileio_func_stat)
3986 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
3987 (remote_fileio_func_isatty, remote_fileio_func_system): Add
3988 remote_target parameter.
3989 (remote_fio_func_map) <func>: Add remote_target parameter.
3990 (do_remote_fileio_request, remote_fileio_request):
3991 * remote-fileio.h (remote_fileio_request):
3992 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
3993 remote_target parameter.
3994 (remote_notif_process, handle_notification): Adjust to pass down
3996 (remote_notif_state_allocate): Add remote_target parameter. Save
3998 * remote-notif.h (struct remote_target): Forward declare.
3999 (struct notif_client) <parse, ack, can_get_pending_events>: Add
4000 remote_target parameter.
4001 (struct remote_notif_state) <remote>: New field.
4002 (remote_notif_ack, remote_notif_parse): Add remote_target
4004 (remote_notif_state_allocate, remote_notif_state_allocate): Add
4005 remote_target parameter.
4006 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
4007 (threads_listing_context, rmt_thread_action, protocol_feature)
4008 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
4009 (packet_result, struct threads_listing_context, remote_state):
4010 Move definitions and declarations higher up.
4011 (remote_target) <~remote_target>: Declare.
4012 (remote_download_command_source, remote_file_put, remote_file_get)
4013 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
4014 (remote_hostio_pread_vFile, remote_hostio_send_command)
4015 (remote_hostio_set_filesystem, remote_hostio_open)
4016 (remote_hostio_close, remote_hostio_unlink, remote_state)
4017 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
4018 (get_memory_write_packet_size, get_memory_read_packet_size)
4019 (append_pending_thread_resumptions, remote_detach_1)
4020 (append_resumption, remote_resume_with_vcont)
4021 (add_current_inferior_and_thread, wait_ns, wait_as)
4022 (process_stop_reply, remote_notice_new_inferior)
4023 (process_initial_stop_replies, remote_add_thread)
4024 (btrace_sync_conf, remote_btrace_maybe_reopen)
4025 (remove_new_fork_children, kill_new_fork_children)
4026 (discard_pending_stop_replies, stop_reply_queue_length)
4027 (check_pending_events_prevent_wildcard_vcont)
4028 (discard_pending_stop_replies_in_queue, stop_reply)
4029 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
4030 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
4031 (remote_interrupt_as, remote_interrupt_ns)
4032 (remote_get_noisy_reply, remote_query_attached)
4033 (remote_add_inferior, remote_current_thread, get_current_thread)
4034 (set_thread, set_general_thread, set_continue_thread)
4035 (set_general_process, write_ptid)
4036 (remote_unpack_thread_info_response, remote_get_threadinfo)
4037 (parse_threadlist_response, remote_get_threadlist)
4038 (remote_threadlist_iterator, remote_get_threads_with_ql)
4039 (remote_get_threads_with_qxfer)
4040 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
4041 (get_offsets, remote_check_symbols, remote_supported_packet)
4042 (remote_query_supported, remote_packet_size)
4043 (remote_serial_quit_handler, remote_detach_pid)
4044 (remote_vcont_probe, remote_resume_with_hc)
4045 (send_interrupt_sequence, interrupt_query)
4046 (remote_notif_get_pending_events, fetch_register_using_p)
4047 (send_g_packet, process_g_packet, fetch_registers_using_g)
4048 (store_register_using_P, store_registers_using_G)
4049 (set_remote_traceframe, check_binary_download)
4050 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
4051 (remote_xfer_live_readonly_partial, remote_read_bytes)
4052 (remote_send_printf, remote_flash_write, readchar)
4053 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
4054 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
4055 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
4056 (extended_remote_disable_randomization, extended_remote_run)
4057 (send_environment_packet, extended_remote_environment_support)
4058 (extended_remote_set_inferior_cwd, remote_write_qxfer)
4059 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
4060 (packet_command): Now methods of ...
4061 (remote_target): ... this class.
4062 (m_remote_state) <remote_target>: New field.
4063 (struct remote_state) <stop_reply_queue,
4064 remote_async_inferior_event_token, wait_forever_enabled_p>: New
4066 (remote_state::remote_state): Allocate stop_reply_queue.
4067 (remote_state): Delete global.
4068 (get_remote_state_raw): Delete.
4069 (remote_target::get_remote_state): Allocate m_remote_state on
4071 (get_current_remote_target): New.
4072 (remote_ops, extended_remote_ops): Delete.
4073 (wait_forever_enabled_p, remote_async_inferior_event_token):
4074 Delete, moved to struct remote_state.
4075 (remote_target::close): Delete self. Destruction bits split to
4077 (remote_target::~remote_target): ... this.
4078 (show_memory_packet_size): Adjust to use
4079 get_current_remote_target.
4080 (struct protocol_feature) <func>: Add remote_target parameter.
4081 All callers adjusted.
4082 (curr_quit_handler_target): New.
4083 (remote_serial_quit_handler): Reimplement.
4084 (remote_target::open_1): Adjust to use get_current_remote_target.
4085 Heap-allocate remote_target/extended_remote_target instances.
4086 (vcont_builder::vcont_builder): Add remote_target parameter, and
4087 save it in m_remote. All callers adjusted.
4088 (vcont_builder::m_remote): New field.
4089 (vcont_builder::restart, vcont_builder::flush)
4090 (vcont_builder::push_action): Use it.
4091 (remote_target::commit_resume): Use it.
4092 (struct queue_iter_param) <remote>: New field.
4093 (remote_target::remove_new_fork_children): Fill in 'remote' field.
4094 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
4095 (check_pending_event_prevents_wildcard_vcont_callback)
4096 (remote_target::check_pending_events_prevent_wildcard_vcont)
4097 (remote_target::discard_pending_stop_replies)
4098 (remote_target::discard_pending_stop_replies_in_queue)
4099 (remote_target::remote_notif_remove_queued_reply): Fill in
4101 (remote_notif_get_pending_events): New.
4102 (remote_target::readchar, remote_target::remote_serial_write):
4103 Save/restore curr_quit_handler_target.
4105 (kill_new_fork_children): Fill in 'remote' field.
4106 (packet_command): Use get_current_remote_target, defer to
4107 remote_target method of same name.
4108 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
4109 parameter, and save it in m_remote. All callers adjusted.
4110 (scoped_remote_fd::release): Use m_remote.
4111 (scoped_remote_fd::m_remote): New field.
4112 (remote_file_put, remote_file_get, remote_file_delete): Use
4113 get_current_remote_target, defer to remote_target method of same
4115 (remote_btrace_reset): Add remote_state paremeter. Update all
4117 (remote_async_inferior_event_handler). Pass down 'data'.
4118 (remote_new_objfile): Use get_current_remote_target.
4119 (remote_target::vcont_r_supported): New.
4120 (set_range_stepping): Use get_current_remote_target and
4121 remote_target::vcont_r_supported.
4122 (_initialize_remote): Don't allocate 'remote_state' and
4123 'stop_reply_queue' globals.
4124 * remote.h (struct remote_target): Forward declare.
4125 (getpkt, putpkt, remote_notif_get_pending_events): Add
4126 'remote_target' parameter.
4128 2018-05-22 Pedro Alves <palves@redhat.com>
4130 * remote.c (vcont_builder): Now a class. Make all data members
4132 (vcont_builder) <vcont_builder, restart, flush, push_action>:
4134 (vcont_builder_restart): Rename to ...
4135 (vcont_builder::restart): ... this.
4136 (vcont_builder_flush): Rename to ...
4137 (vcont_builder::flush): ... this.
4138 (vcont_builder_push_action): Rename to ...
4139 (vcont_builder::push_action): ... this.
4140 (remote_target::commit_resume): Adjust.
4142 2018-05-22 Pedro Alves <palves@redhat.com>
4144 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
4145 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
4146 (get_fixed_memory_packet_size): New.
4147 (get_memory_packet_size): Use it.
4148 (set_memory_packet_size): Don't override the config size with
4149 DEFAULT_MAX_MEMORY_PACKET_SIZE.
4150 (show_memory_packet_size): Use get_fixed_memory_packet_size.
4151 Don't refer to get_memory_packet_size if not connected to a remote
4152 target. Show "(default)" if configured size is 0.
4154 2018-05-22 Pedro Alves <palves@redhat.com>
4156 * remote.c (remote_target::mourn_inferior): Move
4157 discard_pending_stop_replies call here from ...
4158 (_initialize_remote): ... here.
4160 2018-05-22 Pedro Alves <palves@redhat.com>
4162 * remote.c (compare_section_command): Remove set_general_process
4165 2018-05-22 Pedro Alves <palves@redhat.com>
4167 * remote.c (struct packet_reg, struct remote_arch_state):
4168 Move higher up in the file.
4169 (remote_state) <m_arch_states>: Store remote_arch_state values
4170 instead of remote_arch_state pointers.
4171 (remote_state::get_remote_arch_state): Adjust.
4173 2018-05-22 Pedro Alves <palves@redhat.com>
4175 * remote.c: Include <unordered_map>.
4176 (remote_state): Now a class.
4177 (remote_state) <get_remote_arch_state>: Declare method.
4178 <get_remote_arch_state>: New field.
4179 (remote_arch_state) <remote_arch_state>: Declare ctor.
4180 <regs>: Now a unique_ptr.
4181 (remote_gdbarch_data_handle): Delete.
4182 (get_remote_arch_state): Delete.
4183 (remote_state::get_remote_arch_state): New.
4184 (get_remote_state): Adjust to call remote_state's
4185 get_remote_arch_state method.
4186 (init_remote_state): Delete, bits factored out to ...
4187 (remote_arch_state::remote_arch_state): ... this new method.
4188 (get_remote_packet_size, get_memory_packet_size)
4189 (process_g_packet, remote_target::fetch_registers)
4190 (remote_target::prepare_to_store, store_registers_using_G)
4191 (remote_target::store_registers, remote_target::get_trace_status):
4192 Adjust to call remote_state's method.
4193 (_initialize_remote): Remove reference to
4194 remote_gdbarch_data_handle.
4196 2018-05-22 Pedro Alves <palves@redhat.com>
4198 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
4199 pread>: New method declarations.
4200 (remote_target::open_1): Adjust.
4201 (readahead_cache_invalidate): Rename to ...
4202 (readahead_cache::invalidate): ... this, and adjust to be a class
4204 (readahead_cache_invalidate_fd): Rename to ...
4205 (readahead_cache::invalidate_fd): ... this, and adjust to be a
4207 (remote_hostio_pwrite): Adjust.
4208 (remote_hostio_pread_from_cache): Rename to ...
4209 (readahead_cache::pread): ... this, and adjust to be a class
4211 (remote_hostio_close): Adjust.
4213 2018-05-22 Pedro Alves <palves@redhat.com>
4215 * remote.c (remote_hostio_close_cleanup): Delete.
4216 (class scoped_remote_fd): New.
4217 (remote_file_put, remote_file_get): Use it.
4219 2018-05-22 Pedro Alves <palves@redhat.com>
4221 (struct vCont_action_support): Use bool and initialize all fields.
4222 (struct readahead_cache): Initialize all fields.
4223 (remote_state): Use bool and initialize all fields.
4224 (remote_state::remote_state, remote_state::~remote_state): New.
4225 (new_remote_state): Delete.
4226 (_initialize_remote): Use new to allocate remote_state.
4228 2018-05-22 Pedro Alves <palves@redhat.com>
4232 * c-exp.y: Include "c-support.h".
4233 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4234 of tolower. Use c_ident_is_alpha to scan names.
4235 * c-lang.c: Include "c-support.h".
4236 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4237 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4238 * c-support.h: New file, with bits factored out from ...
4239 * cp-name-parser.y: ... this file.
4240 Include "c-support.h".
4241 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4242 c-support.h and renamed.
4243 (symbol_end, yylex): Adjust.
4245 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4247 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4248 parameter type to CORE_ADDR.
4249 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4250 parameter type in declaration to CORE_ADDR.
4251 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4252 target_auxv_search to get AT_HWCAP and use the result to get the
4254 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4255 to CORE_ADDR. Remove the cast of the return value to unsigned
4256 long. Fix error predicate of target_auxv_search.
4257 (ppc_linux_nat_target::read_description): Change the type of the
4258 hwcap variable to CORE_ADDR.
4260 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4262 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4263 if the size of fpscr is larger than 32 bits.
4265 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4267 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4268 (ppc32_linux_vsxregmap): New global.
4269 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4270 regcache_supply_regset, and regcache_collect_regset.
4271 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4272 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4273 (fetch_vsx_register, store_vsx_register): Remove.
4274 (fetch_vsx_registers): Add regno parameter. Get regset using
4275 ppc_linux_vsxregset. Use regset to supply registers.
4276 (store_vsx_registers): Add regno parameter. Get regset using
4277 ppc_linux_vsxregset. Use regset to collect registers.
4278 (fetch_register): Call fetch_vsx_registers instead of
4280 (store_register): Call store_vsx_registers instead of
4282 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4283 new regno parameter.
4284 (store_ppc_registers): Call store_vsx_registers with -1 for the
4285 new regno parameter.
4286 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4287 (ppc_collect_vsxregset): Remove.
4289 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4291 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4293 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4294 for vector register offset fields.
4295 (ppc64_fbsd_reg_offsets): Likewise.
4296 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4297 to vector register offset fields.
4298 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4299 to vector register offset fields.
4300 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
4301 vector register offset fields.
4302 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
4303 initializers for vector register offset fields.
4304 (rs6000_aix64_reg_offsets): Likewise.
4305 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
4306 (ppc_supply_vrregset): Remove.
4307 (ppc_collect_vrregset): Remove.
4308 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
4309 (ppc_linux_vrregset) : New function.
4310 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
4311 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
4312 (ppc32_linux_vrregset): Remove.
4313 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
4314 and use result instead of ppc32_linux_vrregset.
4315 (ppc32_linux_reg_offsets): Remove initializers for vector register
4317 (ppc64_linux_reg_offsets): Likewise.
4318 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
4319 * ppc-linux-nat.c: Include regset.h.
4320 (gdb_vrregset_t): Adjust comment to account for little-endian
4322 (supply_vrregset, fill_vrregset): Remove.
4323 (fetch_altivec_register, store_altivec_register): Remove.
4324 (fetch_altivec_registers): Add regno parameter. Get regset using
4325 ppc_linux_vrregset. Use regset to supply registers.
4326 (store_altivec_registers): Add regno parameter. Get regset using
4327 ppc_linux_vrregset. Use regset to collect registers.
4328 (fetch_register): Call fetch_altivec_registers instead of
4329 fetch_altivec_register.
4330 (store_register): Call store_altivec_registers instead of
4331 store_altivec_register.
4332 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
4333 the new regno parameter.
4334 (store_ppc_registers): Call store_altivec_registers with -1 for
4335 the new regno parameter.
4337 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4339 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
4340 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
4341 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4342 (gdb_vrregset_t): Change array type size to
4343 PPC_LINUX_SIZEOF_VRREGSET.
4344 (gdb_vsxregset_t): Change array type size to
4345 PPC_LINUX_SIZEOF_VSXREGSET.
4346 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
4347 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
4348 PPC_LINUX_SIZEOF_VSXREGSET.
4350 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4352 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
4353 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
4355 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
4356 ppc_linux_target_wordsize with tid.
4357 (ppc_linux_nat_target::read_description): Call ppc_linux_target
4359 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
4360 (ppc64_64bit_inferior_p): Add static and inline specifiers.
4361 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
4362 tid parameter. Remove static specifier.
4363 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
4364 (ppc_linux_target_wordsize): New declaration.
4366 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4368 * arch/ppc-linux-common.c: New file.
4369 * arch/ppc-linux-common.h: New file.
4370 * arch/ppc-linux-tdesc.h: New file.
4371 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
4372 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
4373 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
4374 arch/ppc-linux-tdesc.h.
4375 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
4376 arch/ppc-linux-tdesc.h.
4377 (ppc_linux_nat_target::read_description): Remove target
4378 description matching code. Fill a ppc_linux_features struct and
4379 call ppc_linux_match_description with it. Move comment about ISA
4380 2.05 to ppc-linux-common.c.
4381 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
4382 arch/ppc-linux-tdesc.h.
4383 (ppc_linux_core_read_description): Remove target description
4384 matching code. Fill a ppc_linux_features struct and call
4385 ppc_linux_match_description with it.
4386 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4387 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4388 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4389 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4390 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4391 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4392 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4393 (tdesc_powerpc_e500l): Remove.
4395 2018-05-22 Joel Brobecker <brobecker@adacore.com>
4397 * ada-lang.c (catch_assert_command): Pass empty string instead
4398 of NULL for excep_string argument.
4400 2018-05-22 Maciej W. Rozycki <macro@mips.com>
4402 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
4403 the width of the requested register exceeds the width of the
4406 2018-05-21 Tom Tromey <tom@tromey.com>
4408 * printcmd.c (output_command): Remove.
4409 (output_command_const): Rename to output_command.
4410 * valprint.h (output_command): Rename from output_command_const.
4411 * tracepoint.c (trace_dump_actions): Call output_command.
4413 2018-05-21 Tom Tromey <tom@tromey.com>
4415 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
4416 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
4417 * ada-lang.h (create_ada_exception_catchpoint): Update.
4418 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
4420 (create_excep_cond_exprs, ~ada_catchpoint)
4421 (should_stop_exception, print_one_exception)
4422 (print_mention_exception, print_recreate_exception): Update.
4423 (ada_get_next_arg): Remove.
4424 (catch_ada_exception_command_split): Use std::string. Change type
4425 of "excep_string", "cond_string".
4426 (catch_ada_exception_command): Update.
4427 (create_ada_exception_catchpoint): Change type of excep_string.
4428 (ada_exception_sal): Remove excep_string parameter.
4429 (~ada_catchpoint): Remove.
4431 2018-05-21 Tom Tromey <tom@tromey.com>
4433 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
4436 2018-05-21 Tom Tromey <tom@tromey.com>
4438 * ada-lang.c (ada_exception_message_1, ada_exception_message):
4439 Return unique_xmalloc_ptr.
4440 (print_it_exception): Update.
4442 2018-05-21 Tom Tromey <tom@tromey.com>
4444 * tracepoint.c (trace_dump_actions): Use std::string.
4446 2018-05-21 Tom Tromey <tom@tromey.com>
4448 * symfile.c (reread_symbols): Use std::string for original_name.
4450 2018-05-21 Tom Tromey <tom@tromey.com>
4452 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
4453 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
4456 2018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
4458 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
4460 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
4461 * objfiles.c (get_objfile_bfd_data): Allocate
4462 objfile_per_bfd_storage with obstack_new when allocating on
4465 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4467 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
4469 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
4470 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
4471 * mdebugread.c (mdebug_build_psymtabs): Likewise.
4472 (add_pending): Likewise.
4473 (parse_symbol): Likewise.
4474 (parse_partial_symbols): Likewise.
4475 (psymtab_to_symtab_1): Likewise.
4476 (new_psymtab): Likewise.
4477 (elfmdebug_build_psymtabs): Likewise.
4478 * minsyms.c (terminate_minimal_symbol_table): Likewise.
4479 * objfiles.c (get_objfile_bfd_data): Likewise.
4480 (objfile_register_static_link): Likewise.
4481 * psymtab.c (allocate_psymtab): Likewise.
4482 * stabsread.c (read_member_functions): Likewise.
4483 * xcoffread.c (xcoff_end_psymtab): Likewise.
4485 2018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4487 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
4488 compiler supports std::is_trivially_constructible.
4489 * common/poison.h: Include obstack.h.
4490 (IsMallocable): Define to is_trivially_constructible if the
4491 compiler supports it, define to true_type otherwise.
4495 (XOBNEWVEC): Redefine.
4496 * gdb_obstack.h (obstack_zalloc): New.
4497 (OBSTACK_ZALLOC): Redefine.
4498 (obstack_calloc): New.
4499 (OBSTACK_CALLOC): Redefine.
4501 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
4502 (gdbarch_obstack): New declaration in gdbarch.h, definition in
4504 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
4505 obstack_calloc/obstack_zalloc.
4506 (gdbarch_obstack_zalloc): Remove.
4507 * target-descriptions.c (tdesc_data_init): Use obstack_new.
4509 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4511 * stack.c (backtrace_command_1): Remove useless variable int i.
4513 2018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4515 * stack.c (print_frame_info): Fix comment.
4517 2018-05-18 Tom Tromey <tom@tromey.com>
4519 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
4520 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
4521 (~dwarf2_per_objfile): Update
4522 (dwarf2_get_dwz_file): Use new.
4523 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
4526 2018-05-18 Tom Tromey <tom@tromey.com>
4528 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
4530 * dwarf2read.c (struct dwp_file): Add constructor and
4532 (open_and_init_dwp_file): Return a unique_ptr.
4533 (dwarf2_per_objfile, create_dwp_hash_table)
4534 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
4535 (lookup_dwo_unit_in_dwp): Update.
4536 (open_and_init_dwp_file, get_dwp_file): Update.
4538 2018-05-18 Tom Tromey <tom@tromey.com>
4540 * dwarf2read.c (dwarf2_per_objfile): Update.
4541 (struct mapped_index): Add initializers.
4542 (dwarf2_read_index): Use new.
4543 (dw2_symtab_iter_init): Update.
4544 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
4547 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4549 * dwarf2read.c (mapped_index) <total_size>: Remove.
4551 2018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4553 * unittests/format_pieces-selftests.c (test_format_specifier):
4556 2018-05-18 Tom Tromey <tom@tromey.com>
4558 * c-typeprint.c (maybe_print_hole): New function.
4559 (c_print_type_struct_field_offset): Update.
4560 (c_type_print_base_struct_union): Call maybe_print_hole.
4562 2018-05-17 Keith Seitz <keiths@redhat.com>
4564 * breakpoint.c (build_bpstat_chain): New function, moved from
4566 (bpstat_stop_status): Add optional parameter, `stop_chain'.
4567 If no stop chain is passed, call build_bpstat_chain to build it.
4568 * breakpoint.h (build_bpstat_chain): Declare.
4569 (bpstat_stop_status): Move documentation here from breakpoint.c.
4570 * infrun.c (handle_signal_stop): Before eliding inlined frames,
4571 build the stop chain and pass it to skip_inline_frames.
4572 Pass this stop chain to bpstat_stop_status.
4573 * inline-frame.c: Include breakpoint.h.
4574 (stopped_by_user_bp_inline_frame): New function.
4575 (skip_inline_frames): Add parameter `stop_chain'.
4576 Move documention to inline-frame.h.
4577 If non-NULL, use stopped_by_user_bp_inline_frame to determine
4578 whether the frame should be elided.
4579 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
4580 Add moved documentation and update for new parameter.
4582 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4585 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4586 unittests/format_pieces-selftests.c.
4587 * common/format.h (format_piece) <operator==>: New.
4588 (format_pieces) <operator[]>: Remove.
4589 * common/format.c (format_pieces::format_pieces): Handle \e.
4590 * unittests/format_pieces-selftests.c: New.
4592 2018-05-17 Tom Tromey <tom@tromey.com>
4595 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
4596 (dw2_instantiate_symtab): Add skip_partial parameter.
4597 (dw2_find_last_source_symtab, dw2_map_expand_apply)
4598 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
4599 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
4600 (dw2_expand_symtabs_matching_one)
4601 (dw2_find_pc_sect_compunit_symtab)
4602 (dw2_debug_names_lookup_symbol)
4603 (dw2_debug_names_expand_symtabs_for_function): Update.
4604 (init_cutu_and_read_dies): Add skip_partial parameter.
4605 (process_psymtab_comp_unit, build_type_psymtabs_1)
4606 (process_skeletonless_type_unit, load_partial_comp_unit)
4607 (psymtab_to_symtab_1): Update.
4608 (load_full_comp_unit): Add skip_partial parameter.
4609 (process_imported_unit_die, dwarf2_read_addr_index)
4610 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
4611 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
4612 (read_signatured_type): Update.
4614 2018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4616 * value.c (release_value): Remove unused variable.
4617 (record_latest_value): Likewise.
4618 (access_value_history): Likewise.
4619 (preserve_values): Likewise.
4621 2018-05-17 Tom Tromey <tom@tromey.com>
4623 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
4626 2018-05-16 Maciej W. Rozycki <macro@mips.com>
4629 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
4630 Also handle registers whose width is not a multiple of
4632 (linux_nat_trad_target::store_register): Likewise.
4634 2018-05-16 Tom Tromey <tom@tromey.com>
4636 * gdbcore.h (core_bfd): Redefine.
4637 * corelow.c (core_target::close): Update.
4638 (core_target_open): Update.
4639 * progspace.h (struct program_space) <cbfd>: Now a
4642 2018-05-16 Tom Tromey <tom@tromey.com>
4645 * symfile-add-flags.h (enum symfile_add_flags)
4646 <SYMFILE_NOT_FILENAME>: New constant.
4647 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
4648 objfile name from BFD.
4649 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
4650 * minidebug.c (find_separate_debug_file_in_section): Put
4651 ".gnu_debugdata" into BFD's file name.
4653 2018-05-16 Simon Marchi <simon.marchi@ericsson.com>
4655 * regcache.c (regcache_read_ftype, regcache_write_ftype):
4658 2018-05-15 Tamar Christina <tamar.christina@arm.com>
4661 * aarch64-tdep.c (aarch64_analyze_prologue,
4662 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
4663 Indicate not interested in errors.
4665 2018-05-15 Maciej W. Rozycki <macro@mips.com>
4667 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
4668 Supply the MIPS_ZERO_REGNUM register.
4670 2018-05-15 Maciej W. Rozycki <macro@mips.com>
4672 * mips-tdep.c (mask_address_var): Make variable static.
4674 2018-05-14 Tom Tromey <tom@tromey.com>
4676 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
4678 2018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
4680 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
4681 FXSAVE_ADDR for the mxcsr register.
4683 2018-05-11 Max Filippov <jcmvbkbc@gmail.com>
4685 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
4687 2018-05-11 Pedro Alves <palves@redhat.com>
4689 * corelow.c (core_target) <core_target>: No longer inline.
4690 Initialize m_core_gdbarch, m_core_vec and build the section table
4692 <~core_target>: New.
4693 <core_gdbarch, get_core_register_section>: New methods.
4694 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
4695 factored out from ...
4696 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
4698 (sniff_core_bfd): Add gdbarch parameter.
4699 (core_close): Delete, merged into ...
4700 (core_target::close): ... here. Delete self.
4701 (core_close_cleanup): Delete.
4702 (core_target_open): Allocate a core_target on the heap. Use a
4703 unique_ptr instead of a cleanup. Bits moved into the core_target
4704 ctor. Adjust to use core_target methods instead of globals.
4705 (get_core_register_section): Rename to ...
4706 (core_target::get_core_register_section): ... this and adjust.
4707 (struct get_core_registers_cb_data): New.
4708 (get_core_registers_cb): Use it. Use bool.
4709 (core_target::fetch_registers, core_target::files_info)
4710 (core_target::xfer_partial, core_target::read_description)
4711 (core_target::pid_to, core_target::thread_name): Adjust to
4712 reference class fields instead of globals.
4713 * target.h (struct target_ops_deleter, target_ops_up): New.
4715 2018-05-11 Pedro Alves <palves@redhat.com>
4717 * corefile.c (core_file_command): Move to corelow.c.
4718 * corelow.c (the_core_target): Delete.
4719 (core_file_command): Moved from corefile.c. Check exec_bfd
4720 instead of the_core_target. Use target_detach instead of calling
4721 into the_core_target directly.
4722 (maybe_say_no_core_file_now): New.
4723 (core_target::detach): Use it.
4724 (_initialize_corelow): Remove references to the_core_target.
4725 * gdbcore.h (the_core_target): Delete.
4727 2018-05-11 Tom Tromey <tromey@redhat.com>
4728 Pedro Alves <palves@redhat.com>
4730 * corefile.c (core_bfd): Remove.
4731 * gdbcore.h (core_bfd): Now a macro.
4732 * progspace.h (struct program_space) <cbfd>: New field.
4734 2018-05-11 Tom Tromey <tom@tromey.com>
4736 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
4739 2018-05-10 Tom Tromey <tom@tromey.com>
4741 * configure: Rebuild.
4742 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
4744 2018-05-10 Joel Brobecker <brobecker@adacore.com>
4747 * regformats/regdat.sh: Adjust script, following the addition
4748 of the new expedite_regs parameter to init_target_desc.
4750 2018-05-10 Omair Javaid <omair.javaid@linaro.org>
4753 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
4754 set_gdbarch_significant_addr_bit.
4755 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
4756 set_gdbarch_significant_addr_bit.
4757 * utils.c (address_significant): Update to sign extend addr.
4759 2018-05-09 Max Filippov <jcmvbkbc@gmail.com>
4761 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
4762 (xtensa_linux_init_abi): Limit tdep->num_regs by
4763 tdep->num_nopriv_regs.
4764 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
4765 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
4768 2018-05-08 Simon Marchi <simon.marchi@ericsson.com>
4770 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
4772 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
4774 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
4775 (I387_MXCSR_INIT_VAL): New constant.
4776 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
4777 buffer if it was supplied by the inferior.
4778 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
4779 (i387_xsave_get_clear_bv): New function.
4780 (i387_supply_xsave): Only read x87 control registers from the
4781 xsave buffer if the feature is enabled, and the state will have
4782 been written, otherwise, provide a suitable default.
4783 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
4784 including x87 control registers. Update control registers if they
4785 have changed from the default value, and mark features as enabled
4787 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
4789 2018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
4791 * spu-tdep.c (info_spu_event_command): Fix output formatting.
4793 2018-05-07 Tom Tromey <tom@tromey.com>
4795 * configure: Rebuild.
4796 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
4798 2018-05-07 Tom Tromey <tom@tromey.com>
4801 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
4802 bit. Use correct value for VDIV.
4804 2018-05-04 Tom Tromey <tom@tromey.com>
4806 * configure: Rebuild.
4807 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
4809 2018-05-04 Tom Tromey <tom@tromey.com>
4811 * linux-record.c (record_linux_system_call) <case
4812 RECORD_SYS_RECVFROM>: Add "break".
4814 2018-05-04 Tom Tromey <tom@tromey.com>
4816 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
4817 Add missing "break".
4818 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
4819 Add missing "break".
4821 2018-05-04 Tom Tromey <tom@tromey.com>
4823 * rs6000-tdep.c (ppc_process_record_op4)
4824 (ppc_process_record_op63): Add fall-through comment.
4826 2018-05-04 Tom Tromey <tom@tromey.com>
4828 * i386-tdep.c (i386_process_record): Add fall-through comment.
4830 2018-05-04 Tom Tromey <tom@tromey.com>
4832 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
4835 2018-05-04 Tom Tromey <tom@tromey.com>
4837 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
4838 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
4839 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
4841 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
4843 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
4846 2018-05-04 Tom Tromey <tom@tromey.com>
4848 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
4850 2018-05-04 Tom Tromey <tom@tromey.com>
4852 * s390-tdep.c (s390_process_record): Fix fall-through comments.
4853 * xcoffread.c (scan_xcoff_symtab): Move comment later.
4854 * symfile.c (section_is_mapped): Fix fall-through comment.
4855 * stabsread.c (define_symbol, read_member_functions): Fix
4856 fall-through comment.
4857 * s390-linux-tdep.c (s390_process_record): Fix fall-through
4859 * remote.c (remote_wait_as): Fix fall-through comment.
4860 * p-exp.y (yylex): Fix fall-through comment.
4861 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
4863 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
4864 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
4865 * jv-exp.y (yylex): Fix fall-through comment.
4866 * go-exp.y (lex_one_token): Fix fall-through comment.
4867 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
4868 fall-through comment.
4869 * f-exp.y (yylex): Fix fall-through comment.
4870 * dwarf2read.c (process_die): Fix fall-through comments.
4871 * dbxread.c (process_one_symbol): Fix fall-through comment.
4872 * d-exp.y (lex_one_token): Fix fall-through comment.
4873 * cp-name-parser.y (yylex): Fix fall-through comment.
4874 * coffread.c (coff_symtab_read): Fix fall-through comment.
4875 * c-exp.y (lex_one_token): Fix fall-through comment.
4876 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
4878 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
4881 2018-05-04 Tom Tromey <tom@tromey.com>
4884 * NEWS: Mention gdb.execute change.
4885 * gdbcmd.h (execute_control_command): Don't declare.
4886 * python/python.c (execute_gdb_command): Use read_command_lines_1,
4887 execute_control_commands, execute_control_commands_to_string.
4888 * cli/cli-script.h (execute_control_commands)
4889 (execute_control_commands_to_string): Declare.
4890 (execute_control_command): Add from_tty parameter.
4891 * cli/cli-script.c (execute_control_commands)
4892 (execute_control_commands_to_string): New functions.
4893 (execute_user_command): Use execute_control_commands.
4894 (execute_control_command_1): Add "from_tty" parameter. Update.
4895 (execute_control_command): Likewise.
4897 2018-05-04 Tom Tromey <tom@tromey.com>
4900 * NEWS: Mention that breakpoint commands are writable.
4901 * python/py-breakpoint.c (bppy_set_commands): New function.
4902 (breakpoint_object_getset) <"commands">: Use it.
4904 2018-05-04 Tom Tromey <tom@tromey.com>
4906 * tracepoint.c (actions_command): Update.
4907 * mi/mi-cmd-break.c (mi_command_line_array)
4908 (mi_command_line_array_cnt, mi_command_line_array_ptr)
4909 (mi_read_next_line): Remove.
4910 (mi_cmd_break_commands): Update.
4911 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
4913 * cli/cli-script.c (get_command_line): Update.
4914 (process_next_line): Use function_view. Constify.
4915 (recurse_read_control_structure, read_command_lines)
4916 (read_command_lines_1): Change argument types to function_view.
4917 (do_define_command, document_command): Update.
4918 * breakpoint.h (check_tracepoint_command): Don't declare.
4919 * breakpoint.c (check_tracepoint_command): Remove.
4920 (commands_command_1, create_tracepoint_from_upload): Update.
4922 2018-05-04 Tom Tromey <tom@tromey.com>
4925 * cli/cli-script.h (enum command_control_type) <define_control>:
4927 * cli/cli-script.c (multi_line_command_p): Handle define_control.
4928 (build_command_line, execute_control_command_1)
4929 (process_next_line): Likewise.
4930 (do_define_command): New function, extracted from define_command.
4931 (define_command): Use it.
4933 2018-05-04 Tom Tromey <tom@tromey.com>
4935 * tracepoint.c (actions_command): Update.
4936 * cli/cli-script.h (read_command_lines): Update.
4937 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
4938 (MAX_TMPBUF): Remove define.
4939 (define_command): Use string_printf.
4940 (document_command): Likewise.
4941 * breakpoint.c (commands_command_1): Update.
4943 2018-05-04 Tom Tromey <tom@tromey.com>
4945 * top.c (execute_command): Update.
4946 * cli/cli-script.h (print_command_lines): Now varargs.
4947 * cli/cli-script.c (print_command_lines): Now varargs.
4948 (execute_control_command_1) <case while_control, case if_control>:
4951 2018-05-04 Tom Tromey <tom@tromey.com>
4953 * tracepoint.c (all_tracepoint_actions): Rename from
4954 all_tracepoint_actions_and_cleanup. Change return type.
4955 (actions_command, encode_actions_1, encode_actions)
4956 (trace_dump_actions, tdump_command): Update.
4957 * remote.c (remote_download_command_source): Update.
4958 * python/python.c (gdbpy_eval_from_control_command)
4959 (python_command, python_interactive_command): Update.
4960 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
4961 * guile/guile.c (guile_command)
4962 (gdbscm_eval_from_control_command, guile_command): Update.
4963 * compile/compile.c (compile_code_command)
4964 (compile_print_command, compile_to_object): Update.
4965 * cli/cli-script.h (struct command_lines_deleter): New.
4966 (counted_command_line): New typedef.
4967 (struct command_line): Add constructor, destructor.
4968 <body_list>: Remove.
4969 <body_list_0, body_list_1>: New members.
4970 (command_line_up): Remove typedef.
4971 (read_command_lines, read_command_lines_1, get_command_line):
4973 (copy_command_lines): Don't declare.
4974 * cli/cli-script.c (build_command_line): Use "new".
4975 (get_command_line): Return counted_command_line.
4976 (print_command_lines, execute_user_command)
4977 (execute_control_command_1, while_command, if_command): Update.
4978 (realloc_body_list): Remove.
4979 (process_next_line, recurse_read_control_structure): Update.
4980 (read_command_lines, read_command_lines_1): Return counted_command_line.
4981 (free_command_lines): Use "delete".
4982 (copy_command_lines): Remove.
4983 (define_command, document_command, show_user_1): Update.
4984 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
4985 a counted_command_line.
4986 * breakpoint.h (counted_command_line): Remove typedef.
4987 (breakpoint_set_commands): Update.
4988 * breakpoint.c (check_no_tracepoint_commands)
4989 (validate_commands_for_breakpoint): Update.
4990 (breakpoint_set_commands): Change commands to be a
4991 counted_command_line.
4992 (commands_command_1, update_dprintf_command_list)
4993 (create_tracepoint_from_upload): Update.
4995 2018-05-04 Tom Tromey <tom@tromey.com>
4997 * cli/cli-decode.h (cmd_list_element): New constructor.
4998 (~cmd_list_element): New destructor.
4999 (struct cmd_list_element): Add initializers.
5000 * cli/cli-decode.c (do_add_cmd): Use "new".
5001 (delete_cmd): Use "delete".
5003 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5004 Pedro Alves <palves@redhat.com>
5006 PR breakpoints/19806 and support for PR external/20207.
5007 * NEWS: Mention Aarch64 watchpoint improvements.
5008 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
5009 watchpoints and PR external/20207 watchpoints.
5010 * nat/aarch64-linux-hw-point.c
5011 (kernel_supports_any_contiguous_range): New.
5012 (aarch64_watchpoint_offset): New.
5013 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
5014 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
5015 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
5016 (aarch64_align_watchpoint): New parameters aligned_offset_p and
5017 next_addr_orig_p. Support PR external/20207 watchpoints.
5018 (aarch64_downgrade_regs): New.
5019 (aarch64_dr_state_insert_one_point): New parameters offset and
5021 (aarch64_dr_state_remove_one_point): Likewise.
5022 (aarch64_handle_breakpoint): Update caller.
5023 (aarch64_handle_aligned_watchpoint): Likewise.
5024 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
5026 (aarch64_linux_set_debug_regs): Remove const from state. Call
5027 aarch64_downgrade_regs.
5028 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
5029 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
5030 (DR_CONTROL_MASK): ... this.
5031 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
5032 (unsigned int aarch64_watchpoint_offset): New prototype.
5033 (aarch64_linux_set_debug_regs): Remove const from state.
5034 * utils.c (align_up, align_down): Move to ...
5035 * common/common-utils.c (align_up, align_down): ... here.
5036 * utils.h (align_up, align_down): Move to ...
5037 * common/common-utils.h (align_up, align_down): ... here.
5039 2018-05-04 Joel Brobecker <brobecker@adacore.com>
5041 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
5042 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
5043 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
5044 Re-implement to match the ABI as summarized in GCC's
5045 gcc/config/sparc/sparc.c. All callers updated.
5046 (sparc32_store_arguments): Remove assertion.
5048 2018-05-04 Tom Tromey <tom@tromey.com>
5050 * printcmd.c: Don't include tui.h.
5051 (decode_format): Use skip_spaces.
5053 2018-05-04 Tom Tromey <tom@tromey.com>
5056 * printcmd.c (last_count): New global.
5057 (x_command): Use saved count when repeating.
5059 2018-05-04 Tom Tromey <tom@tromey.com>
5061 * nto-procfs.c (do_closedir_cleanup): Remove.
5062 (procfs_pidlist): Use gdb_dir_up.
5063 * procfs.c (do_closedir_cleanup): Remove.
5064 (proc_update_threads): Use gdb_dir_up.
5065 * common/filestuff.h (struct gdb_dir_deleter): New.
5066 (gdb_dir_up): New typedef.
5068 2018-05-04 Tom Tromey <tom@tromey.com>
5070 * ada-lang.c (print_mention_exception): Use std::string.
5072 2018-05-04 Tom Tromey <tom@tromey.com>
5074 * ada-lang.c (create_excep_cond_exprs): Update.
5075 (ada_exception_catchpoint_cond_string): Use std::string.
5077 2018-05-04 Tom Tromey <tom@tromey.com>
5079 * ada-lang.c (xget_renaming_scope): Return std::string.
5080 (old_renaming_is_invisible): Update.
5082 2018-05-04 Tom Tromey <tom@tromey.com>
5084 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
5085 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
5087 2018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5089 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
5091 2018-05-04 Tom Tromey <tom@tromey.com>
5093 * remote.c (remote_query_supported_append): Change type.
5094 (remote_check_symbols): Update.
5096 2018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
5099 * configure.ac: Prepend libpython.
5100 * python/python-config.py: Likewise.
5101 * configure: Regenerate.
5103 2018-05-03 Simon Marchi <simon.marchi@ericsson.com>
5105 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
5107 2018-05-03 Pedro Alves <palves@redhat.com>
5110 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
5111 override. Write 'true' instead of '1'.
5112 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
5115 2018-05-02 Pedro Alves <palves@redhat.com>
5117 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
5118 add_inf_child_target.
5119 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
5120 add_inf_child_target.
5121 * aix-thread.c (aix_thread_target_info): New.
5122 (aix_thread_target) <shortname, longname, doc>: Delete.
5124 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
5125 add_inf_child_target.
5126 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
5127 add_inf_child_target.
5128 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
5129 add_inf_child_target.
5130 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
5131 add_inf_child_target.
5132 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
5133 add_inf_child_target.
5134 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
5135 add_inf_child_target.
5136 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
5137 add_inf_child_target.
5138 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
5139 add_inf_child_target.
5140 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
5141 add_inf_child_target.
5142 * bfd-target.c (target_bfd_target_info): New.
5143 (target_bfd) <shortname, longname, doc>: Delete.
5145 * bsd-kvm.c (bsd_kvm_target_info): New.
5146 (bsd_kvm_target) <shortname, longname, doc>: Delete.
5148 (bsd_kvm_target::open): Rename to ...
5149 (bsd_kvm_target_open): ... this. Adjust.
5150 * bsd-uthread.c (bsd_uthread_target_info): New.
5151 (bsd_uthread_target) <shortname, longname, doc>: Delete.
5153 * corefile.c (core_file_command): Adjust.
5154 * corelow.c (core_target_info): New.
5155 (core_target) <shortname, longname, doc>: Delete.
5157 (core_target::open): Rename to ...
5158 (core_target_open): ... this. Adjust.
5159 * ctf.c (ctf_target_info): New.
5160 (ctf_target) <shortname, longname, doc>: Delete.
5162 (ctf_target::open): Rename to ...
5163 (ctf_target_open): ... this.
5164 (_initialize_ctf): Adjust.
5165 * exec.c (exec_target_info): New.
5166 (exec_target) <shortname, longname, doc>: Delete.
5168 (exec_target::open): Rename to ...
5169 (exec_target_open): ... this.
5170 * gdbcore.h (core_target_open): Declare.
5171 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
5172 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
5173 add_inf_child_target.
5174 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
5175 add_inf_child_target.
5176 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
5177 add_inf_child_target.
5178 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
5179 add_inf_child_target.
5180 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
5181 add_inf_child_target.
5182 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
5183 add_inf_child_target.
5184 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
5185 add_inf_child_target.
5186 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
5187 add_inf_child_target.
5188 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
5189 add_inf_child_target.
5190 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
5191 add_inf_child_target.
5192 * inf-child.c (inf_child_target_info): New.
5193 (inf_child_target::info): New.
5194 (inf_child_open_target): Remove 'target' parameter. Use
5195 get_native_target instead.
5196 (inf_child_target::open): Delete.
5197 (add_inf_child_target): New.
5198 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
5201 (add_inf_child_target): Declare.
5202 (inf_child_open_target): Declare.
5203 * linux-thread-db.c (thread_db_target_info): New.
5204 (thread_db_target) <shortname, longname, doc>: Delete.
5206 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
5207 add_inf_child_target.
5208 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
5209 add_inf_child_target.
5210 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
5211 add_inf_child_target.
5212 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
5213 add_inf_child_target.
5214 * make-target-delegates (print_class): Adjust.
5215 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
5216 add_inf_child_target.
5217 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
5218 add_inf_child_target.
5219 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
5220 add_inf_child_target.
5221 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
5222 add_inf_child_target.
5223 * nto-procfs.c (nto_native_target_info): New.
5224 (nto_procfs_target_native) <shortname, longname, doc>:
5227 (nto_procfs_target_info): New.
5228 (nto_procfs_target_procfs) <shortname, longname, doc>:
5231 (init_procfs_targets): Adjust.
5232 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5233 add_inf_child_target.
5234 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5235 add_inf_child_target.
5236 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5237 add_inf_child_target.
5238 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5239 add_inf_child_target.
5240 * ravenscar-thread.c (ravenscar_target_info): New.
5241 (ravenscar_thread_target) <shortname, longname, doc>:
5244 * record-btrace.c (record_btrace_target_info):
5245 (record_btrace_target) <shortname, longname, doc>: Delete.
5247 (record_btrace_target::open): Rename to ...
5248 (record_btrace_target_open): ... this. Adjust.
5249 * record-full.c (record_longname, record_doc): New.
5250 (record_full_base_target) <shortname, longname, doc>: Delete.
5252 (record_full_target_info): New.
5253 (record_full_target): <shortname>: Delete.
5255 (record_full_core_open_1, record_full_open_1): Update comments.
5256 (record_full_base_target::open): Rename to ...
5257 (record_full_open): ... this.
5258 (cmd_record_full_restore): Update.
5259 (_initialize_record_full): Update.
5260 * remote-sim.c (remote_sim_target_info): New.
5261 (gdbsim_target) <shortname, longname, doc>: Delete.
5263 (gdbsim_target::open): Rename to ...
5264 (gdbsim_target_open): ... this.
5265 (_initialize_remote_sim): Adjust.
5266 * remote.c (remote_doc): New.
5267 (remote_target_info): New.
5268 (remote_target) <shortname, longname, doc>: Delete.
5270 (extended_remote_target_info): New.
5271 (extended_remote_target) <shortname, longname, doc>: Delete.
5273 (remote_target::open_1): Make static. Adjust.
5274 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5275 * s390-linux-nat.c (_initialize_s390_nat): Use
5276 add_inf_child_target.
5277 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5278 add_inf_child_target.
5279 * sol-thread.c (thread_db_target_info): New.
5280 (sol_thread_target) <shortname, longname, doc>: Delete.
5282 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5283 add_inf_child_target.
5284 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5285 add_inf_child_target.
5286 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5287 add_inf_child_target.
5288 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5289 add_inf_child_target.
5290 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5291 add_inf_child_target.
5292 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5293 add_inf_child_target.
5294 * spu-linux-nat.c (_initialize_spu_nat): Use
5295 add_inf_child_target.
5296 * spu-multiarch.c (spu_multiarch_target_info): New.
5297 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5299 * target-delegates.c: Regenerate.
5300 * target.c: Include <unordered_map>.
5301 (target_ops_p): Delete.
5302 (DEF_VEC_P(target_ops_p)): Delete.
5303 (target_factories): New.
5304 (test_target_info): New.
5305 (test_target_ops::info): New.
5306 (open_target): Adjust to use target_factories.
5307 (add_target_with_completer): Rename to ...
5308 (add_target): ... this. Change prototype. Register target_info
5309 and open callback in target_factories. Register target_info in
5310 command context instead of target_ops.
5311 (add_target): Delete old implementation.
5312 (add_deprecated_target_alias): Change prototype. Adjust.
5313 (the_native_target): New.
5314 (set_native_target, get_native_target): New.
5315 (find_default_run_target): Use the_native_target.
5316 (find_attach_target, find_run_target): Simplify.
5317 (target_ops::open): Delete.
5318 (dummy_target_info): New.
5319 (dummy_target::shortname, dummy_target::longname)
5320 (dummy_target::doc): Delete.
5321 (dummy_target::info): New.
5322 (debug_target::shortname, debug_target::longname)
5323 (debug_target::doc): Delete.
5324 (debug_target::info): New.
5325 * target.h (struct target_info): New.
5326 (target_ops::~target_ops): Add comment.
5327 (target_ops::info): New.
5328 (target_ops::shortname, target_ops::longname, target_ops::doc): No
5329 longer virtual. Implement in terms of target_info.
5330 (set_native_target, get_native_target): Declare.
5331 (target_open_ftype): New.
5332 (add_target, add_target_with_completer)
5333 (add_deprecated_target_alias): Change prototype.
5334 (test_target) <shortname, longname, doc>: Delete.
5336 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
5337 add_inf_child_target.
5338 * tracefile-tfile.c (tfile_target_info): New.
5339 (tfile_target) <shortname, longname, doc>: Delete.
5341 (tfile_target::open): Rename to ...
5342 (tfile_target_open): ... this.
5343 (_initialize_tracefile_tfile): Adjust.
5344 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
5345 add_inf_child_target.
5346 * windows-nat.c (_initialize_windows_nat): Use
5347 add_inf_child_target.
5348 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
5349 add_inf_child_target.
5351 2018-05-02 Pedro Alves <palves@redhat.com>
5353 * linux-nat.h (linux_nat_target) <low_new_thread,
5354 low_delete_thread, low_new_fork, low_forget_process,
5355 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
5356 New virtual methods.
5357 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5358 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
5359 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
5360 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5361 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
5363 * linux-fork.c (delete_fork): Adjust to call low method.
5364 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
5365 (linux_nat_new_fork, linux_nat_forget_process_hook)
5366 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
5367 (linux_nat_status_is_event):
5368 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
5369 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
5371 (sigtrap_is_event): Rename to ...
5372 (linux_nat_target::low_status_is_event): ... this.
5373 (linux_nat_set_status_is_event): Delete.
5374 (save_stop_reason, linux_nat_wait_1)
5375 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
5377 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5378 (linux_nat_set_new_fork, linux_nat_set_forget_process)
5379 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5380 (linux_nat_set_prepare_to_resume): Delete.
5381 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
5382 low virtual methods.
5383 * amd64-linux-nat.c: Likewise.
5384 * arm-linux-nat.c: Likewise.
5385 * i386-linux-nat.c: Likewise.
5386 * ia64-linux-nat.c: Likewise.
5387 * mips-linux-nat.c: Likewise.
5388 * ppc-linux-nat.c: Likewise.
5389 * s390-linux-nat.c: Likewise.
5390 * sparc64-linux-nat.c: Likewise.
5391 * x86-linux-nat.c: Likewise.
5392 * x86-linux-nat.h: Include "nat/x86-linux.h".
5393 (x86_linux_nat_target) <low_new_fork, low_forget_process,
5394 low_prepare_to_resume, low_new_thread, low_delete_thread>:
5397 2018-05-02 Pedro Alves <palves@redhat.com>
5399 * target.h (target_ops)
5400 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5401 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
5402 stopped_by_watchpoint, have_continuable_watchpoint,
5403 stopped_data_address, watchpoint_addr_within_range,
5404 can_accel_watchpoint_condition, can_run, thread_alive,
5405 has_all_memory, has_memory, has_stack, has_registers,
5406 has_execution, can_async_p, is_async_p, supports_non_stop,
5407 always_non_stop_p, can_execute_reverse, supports_multi_process,
5408 supports_enable_disable_tracepoint,
5409 supports_disable_randomization, supports_string_tracing,
5410 supports_evaluation_of_breakpoint_conditions,
5411 can_run_breakpoint_commands, filesystem_is_local,
5412 can_download_tracepoint, get_trace_state_variable_value,
5413 set_trace_notes, get_tib_address, use_agent, can_use_agent,
5414 record_is_replaying, record_will_replay,
5415 augmented_libraries_svr4_read>: Adjust to return bool.
5416 * aarch64-linux-nat.c: All implementations adjusted.
5417 * aix-thread.c: All implementations adjusted.
5418 * arm-linux-nat.c: All implementations adjusted.
5419 * breakpoint.c: All implementations adjusted.
5420 * bsd-kvm.c: All implementations adjusted.
5421 * bsd-uthread.c: All implementations adjusted.
5422 * corelow.c: All implementations adjusted.
5423 * ctf.c: All implementations adjusted.
5424 * darwin-nat.c: All implementations adjusted.
5425 * darwin-nat.h: All implementations adjusted.
5426 * exec.c: All implementations adjusted.
5427 * fbsd-nat.c: All implementations adjusted.
5428 * fbsd-nat.h: All implementations adjusted.
5429 * gnu-nat.c: All implementations adjusted.
5430 * gnu-nat.h: All implementations adjusted.
5431 * go32-nat.c: All implementations adjusted.
5432 * ia64-linux-nat.c: All implementations adjusted.
5433 * inf-child.c: All implementations adjusted.
5434 * inf-child.h: All implementations adjusted.
5435 * inf-ptrace.c: All implementations adjusted.
5436 * inf-ptrace.h: All implementations adjusted.
5437 * linux-nat.c: All implementations adjusted.
5438 * linux-nat.h: All implementations adjusted.
5439 * mips-linux-nat.c: All implementations adjusted.
5440 * nto-procfs.c: All implementations adjusted.
5441 * ppc-linux-nat.c: All implementations adjusted.
5442 * procfs.c: All implementations adjusted.
5443 * ravenscar-thread.c: All implementations adjusted.
5444 * record-btrace.c: All implementations adjusted.
5445 * record-full.c: All implementations adjusted.
5446 * remote-sim.c: All implementations adjusted.
5447 * remote.c: All implementations adjusted.
5448 * s390-linux-nat.c: All implementations adjusted.
5449 * sol-thread.c: All implementations adjusted.
5450 * spu-multiarch.c: All implementations adjusted.
5451 * target-delegates.c: All implementations adjusted.
5452 * target.c: All implementations adjusted.
5453 * target.h: All implementations adjusted.
5454 * tracefile-tfile.c: All implementations adjusted.
5455 * tracefile.c: All implementations adjusted.
5456 * tracefile.h: All implementations adjusted.
5457 * windows-nat.c: All implementations adjusted.
5458 * x86-linux-nat.h: All implementations adjusted.
5459 * x86-nat.h: All implementations adjusted.
5461 2018-05-02 Pedro Alves <palves@redhat.com>
5463 * make-target-delegates (scan_target_h): Don't trim lines here.
5464 Replace sequences of tabs and/or whitespace with a single
5466 (top level, parsing methods): Trim each line before processing it
5469 2018-05-02 Pedro Alves <palves@redhat.com>
5470 John Baldwin <jhb@freebsd.org>
5472 * target.h (enum strata) <debug_stratum>: New.
5473 (struct target_ops) <all delegation methods>: Replace by C++
5474 virtual methods, and drop "to_" prefix. All references updated
5476 <to_shortname, to_longname, to_doc, to_data,
5477 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
5478 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
5479 virtual methods. All references updated throughout.
5480 <can_attach, supports_terminal_ours, can_create_inferior,
5481 get_thread_control_capabilities, attach_no_wait>: New
5483 <insert_breakpoint, remove_breakpoint>: Now
5484 TARGET_DEFAULT_NORETURN methods.
5485 <info_proc>: Now returns bool.
5487 (OPS_MAGIC): Delete.
5488 (current_target): Delete. All references replaced by references
5490 (target_stack): ... this. New.
5491 (target_shortname, target_longname): Adjust.
5492 (target_can_run): Now a function declaration.
5493 (default_child_has_all_memory, default_child_has_memory)
5494 (default_child_has_stack, default_child_has_registers)
5495 (default_child_has_execution): Remove target_ops parameter.
5496 (complete_target_initialization): Delete.
5497 (memory_breakpoint_target): New template class.
5498 (test_target_ops): Refactor as a C++ class with virtual methods.
5499 * make-target-delegates (NAME_PART): Tighten.
5500 (POINTER_PART, CP_SYMBOL): New.
5501 (SIMPLE_RETURN_PART): Reimplement.
5502 (VEC_RETURN_PART): Expect less.
5503 (RETURN_PART, VIRTUAL_PART): New.
5504 (METHOD): Adjust to C++ virtual methods.
5505 (scan_target_h): Remove reference to C99.
5506 (dname): Output "target_ops::" prefix.
5507 (write_function_header): Adjust to output a C++ class method.
5508 (write_declaration): New.
5509 (write_delegator): Adjust to output a C++ class method.
5510 (tdname): Output "dummy_target::" prefix.
5511 (write_tdefault, write_debugmethod): Adjust to output a C++ class
5513 (tdefault_names, debug_names): Delete.
5514 (return_types, tdefaults, styles, argtypes_array): New.
5515 (top level): All methods are delegators.
5517 (top level): Print dummy_target and debug_target classes.
5518 * target-delegates.c: Regenerate.
5519 * target-debug.h (target_debug_print_enum_info_proc_what)
5520 (target_debug_print_thread_control_capabilities)
5521 (target_debug_print_thread_info_p): New.
5522 * target.c (dummy_target): Delete.
5523 (the_dummy_target, the_debug_target): New.
5524 (target_stack): Now extern.
5525 (set_targetdebug): Push/unpush debug target.
5526 (default_child_has_all_memory, default_child_has_memory)
5527 (default_child_has_stack, default_child_has_registers)
5528 (default_child_has_execution): Remove target_ops parameter.
5529 (complete_target_initialization): Delete.
5530 (add_target_with_completer): No longer call
5531 complete_target_initialization.
5532 (target_supports_terminal_ours): Use regular delegation.
5533 (update_current_target): Delete.
5534 (push_target): No longer check magic number. Don't call
5535 update_current_target.
5536 (unpush_target): Don't call update_current_target.
5537 (target_is_pushed): No longer check magic number.
5538 (target_require_runnable): Skip for all stratums over
5540 (target_ops::info_proc): New.
5541 (target_info_proc): Use find_target_at and
5542 find_default_run_target.
5543 (target_supports_disable_randomization): Use regular delegation.
5544 (target_get_osdata): Use find_target_at.
5545 (target_ops::open, target_ops::close, target_ops::can_attach)
5546 (target_ops::attach, target_ops::can_create_inferior)
5547 (target_ops::create_inferior, target_ops::can_run)
5548 (target_can_run): New.
5549 (default_fileio_target): Use regular delegation.
5550 (target_ops::fileio_open, target_ops::fileio_pwrite)
5551 (target_ops::fileio_pread, target_ops::fileio_fstat)
5552 (target_ops::fileio_close, target_ops::fileio_unlink)
5553 (target_ops::fileio_readlink): New.
5554 (target_fileio_open_1, target_fileio_unlink)
5555 (target_fileio_readlink): Always call the target method. Handle
5557 (return_zero, return_zero_has_execution): Delete.
5558 (init_dummy_target): Delete.
5559 (dummy_target::dummy_target, dummy_target::shortname)
5560 (dummy_target::longname, dummy_target::doc)
5561 (debug_target::debug_target, debug_target::shortname)
5562 (debug_target::longname, debug_target::doc): New.
5563 (target_supports_delete_record): Use regular delegation.
5564 (setup_target_debug): Delete.
5565 (maintenance_print_target_stack): Skip debug_stratum.
5566 (initialize_targets): Instantiate the_dummy_target and
5568 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
5570 (target_auxv_search, fprint_target_auxv): Adjust.
5571 (info_auxv_command): Adjust to use target_stack.
5572 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
5573 * exceptions.c (print_flush): Handle a NULL target_stack.
5574 * regcache.c (target_ops_no_register): Refactor as class with
5577 * exec.c (exec_target): New class.
5578 (exec_ops): Now an exec_target.
5579 (exec_open, exec_close_1, exec_get_section_table)
5580 (exec_xfer_partial, exec_files_info, exec_has_memory)
5581 (exec_make_note_section): Refactor as exec_target methods.
5582 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
5584 (exec_target::find_memory_regions): New.
5585 (_initialize_exec): Don't call init_exec_ops.
5586 * gdbcore.h (exec_file_clear): Delete.
5588 * corefile.c (core_target): Delete.
5589 (core_file_command): Adjust.
5590 * corelow.c (core_target): New class.
5591 (the_core_target): New.
5592 (core_close): Remove target_ops parameter.
5593 (core_close_cleanup): Adjust.
5594 (core_target::close): New.
5595 (core_open, core_detach, get_core_registers, core_files_info)
5596 (core_xfer_partial, core_thread_alive, core_read_description)
5597 (core_pid_to_str, core_thread_name, core_has_memory)
5598 (core_has_stack, core_has_registers, core_info_proc): Rework as
5599 core_target methods.
5600 (ignore, core_remove_breakpoint, init_core_ops): Delete.
5601 (_initialize_corelow): Initialize the_core_target.
5602 * gdbcore.h (core_target): Delete.
5603 (the_core_target): New.
5605 * ctf.c: (ctf_target): New class.
5606 (ctf_ops): Now a ctf_target.
5607 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
5608 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
5609 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
5611 (init_ctf_ops): Delete.
5612 (_initialize_ctf): Don't call it.
5613 * tracefile-tfile.c (tfile_target): New class.
5614 (tfile_ops): Now a tfile_target.
5615 (tfile_open, tfile_close, tfile_files_info)
5616 (tfile_get_tracepoint_status, tfile_trace_find)
5617 (tfile_fetch_registers, tfile_xfer_partial)
5618 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
5619 Refactor as tfile_target methods.
5620 (tfile_xfer_partial_features): Remove target_ops parameter.
5621 (init_tfile_ops): Delete.
5622 (_initialize_tracefile_tfile): Don't call it.
5623 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
5624 (tracefile_has_stack, tracefile_has_registers)
5625 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
5626 tracefile_target methods.
5627 (init_tracefile_ops): Delete.
5628 (tracefile_target::tracefile_target): New.
5629 * tracefile.h: Include "target.h".
5630 (tracefile_target): New class.
5631 (init_tracefile_ops): Delete.
5633 * spu-multiarch.c (spu_multiarch_target): New class.
5634 (spu_ops): Now a spu_multiarch_target.
5635 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
5636 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
5637 (spu_search_memory, spu_mourn_inferior): Refactor as
5638 spu_multiarch_target methods.
5639 (init_spu_ops): Delete.
5640 (_initialize_spu_multiarch): Remove references to init_spu_ops,
5641 complete_target_initialization.
5643 * ravenscar-thread.c (ravenscar_thread_target): New class.
5644 (ravenscar_ops): Now a ravenscar_thread_target.
5645 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
5646 (ravenscar_thread_alive, ravenscar_pid_to_str)
5647 (ravenscar_fetch_registers, ravenscar_store_registers)
5648 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
5649 (ravenscar_stopped_by_hw_breakpoint)
5650 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
5651 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
5652 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
5654 (init_ravenscar_thread_ops): Delete.
5655 (_initialize_ravenscar): Remove references to
5656 init_ravenscar_thread_ops and complete_target_initialization.
5658 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
5659 (bsd_uthread_target): New class.
5660 (bsd_uthread_ops): Now a bsd_uthread_target.
5661 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
5662 (bsd_uthread_close, bsd_uthread_mourn_inferior)
5663 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
5664 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
5665 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
5666 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
5667 (bsd_uthread_target): Delete function.
5668 (_initialize_bsd_uthread): Remove reference to
5669 complete_target_initialization.
5671 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
5672 (target_bfd): ... this new class.
5673 (target_bfd_xfer_partial, target_bfd_get_section_table)
5674 (target_bfd_close): Refactor as target_bfd methods.
5675 (target_bfd::~target_bfd): New.
5676 (target_bfd_reopen): Adjust.
5677 (target_bfd::close): New.
5679 * record-btrace.c (record_btrace_target): New class.
5680 (record_btrace_ops): Now a record_btrace_target.
5681 (record_btrace_open, record_btrace_stop_recording)
5682 (record_btrace_disconnect, record_btrace_close)
5683 (record_btrace_async, record_btrace_info)
5684 (record_btrace_insn_history, record_btrace_insn_history_range)
5685 (record_btrace_insn_history_from, record_btrace_call_history)
5686 (record_btrace_call_history_range)
5687 (record_btrace_call_history_from, record_btrace_record_method)
5688 (record_btrace_is_replaying, record_btrace_will_replay)
5689 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
5690 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
5691 (record_btrace_store_registers, record_btrace_prepare_to_store)
5692 (record_btrace_to_get_unwinder)
5693 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
5694 (record_btrace_commit_resume, record_btrace_wait)
5695 (record_btrace_stop, record_btrace_can_execute_reverse)
5696 (record_btrace_stopped_by_sw_breakpoint)
5697 (record_btrace_supports_stopped_by_sw_breakpoint)
5698 (record_btrace_stopped_by_hw_breakpoint)
5699 (record_btrace_supports_stopped_by_hw_breakpoint)
5700 (record_btrace_update_thread_list, record_btrace_thread_alive)
5701 (record_btrace_goto_begin, record_btrace_goto_end)
5702 (record_btrace_goto, record_btrace_stop_replaying_all)
5703 (record_btrace_execution_direction)
5704 (record_btrace_prepare_to_generate_core)
5705 (record_btrace_done_generating_core): Refactor as
5706 record_btrace_target methods.
5707 (init_record_btrace_ops): Delete.
5708 (_initialize_record_btrace): Remove reference to
5709 init_record_btrace_ops.
5710 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
5711 the execution_direction global.
5712 (record_full_base_target, record_full_target)
5713 (record_full_core_target): New classes.
5714 (record_full_ops): Now a record_full_target.
5715 (record_full_core_ops): Now a record_full_core_target.
5716 (record_full_target::detach, record_full_target::disconnect)
5717 (record_full_core_target::disconnect)
5718 (record_full_target::mourn_inferior, record_full_target::kill):
5720 (record_full_open, record_full_close, record_full_async): Refactor
5721 as methods of the record_full_base_target class.
5722 (record_full_resume, record_full_commit_resume): Refactor
5723 as methods of the record_full_target class.
5724 (record_full_wait, record_full_stopped_by_watchpoint)
5725 (record_full_stopped_data_address)
5726 (record_full_stopped_by_sw_breakpoint)
5727 (record_full_supports_stopped_by_sw_breakpoint)
5728 (record_full_stopped_by_hw_breakpoint)
5729 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
5730 methods of the record_full_base_target class.
5731 (record_full_store_registers, record_full_xfer_partial)
5732 (record_full_insert_breakpoint, record_full_remove_breakpoint):
5733 Refactor as methods of the record_full_target class.
5734 (record_full_can_execute_reverse, record_full_get_bookmark)
5735 (record_full_goto_bookmark, record_full_execution_direction)
5736 (record_full_record_method, record_full_info, record_full_delete)
5737 (record_full_is_replaying, record_full_will_replay)
5738 (record_full_goto_begin, record_full_goto_end, record_full_goto)
5739 (record_full_stop_replaying): Refactor as methods of the
5740 record_full_base_target class.
5741 (record_full_core_resume, record_full_core_kill)
5742 (record_full_core_fetch_registers)
5743 (record_full_core_prepare_to_store)
5744 (record_full_core_store_registers, record_full_core_xfer_partial)
5745 (record_full_core_insert_breakpoint)
5746 (record_full_core_remove_breakpoint)
5747 (record_full_core_has_execution): Refactor
5748 as methods of the record_full_core_target class.
5749 (record_full_base_target::supports_delete_record): New.
5750 (init_record_full_ops): Delete.
5751 (init_record_full_core_ops): Delete.
5752 (record_full_save): Refactor as method of the
5753 record_full_base_target class.
5754 (_initialize_record_full): Remove references to
5755 init_record_full_ops and init_record_full_core_ops.
5757 * remote.c (remote_target, extended_remote_target): New classes.
5758 (remote_ops): Now a remote_target.
5759 (extended_remote_ops): Now an extended_remote_target.
5760 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
5761 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
5762 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
5763 (remote_pass_signals, remote_set_syscall_catchpoint)
5764 (remote_program_signals, )
5765 (remote_thread_always_alive): Remove target_ops parameter.
5766 (remote_thread_alive, remote_thread_name)
5767 (remote_update_thread_list, remote_threads_extra_info)
5768 (remote_static_tracepoint_marker_at)
5769 (remote_static_tracepoint_markers_by_strid)
5770 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
5771 (remote_open): Refactor as methods of remote_target.
5772 (extended_remote_open, extended_remote_detach)
5773 (extended_remote_attach, extended_remote_post_attach):
5774 (extended_remote_supports_disable_randomization)
5775 (extended_remote_create_inferior): : Refactor as method of
5776 extended_remote_target.
5777 (remote_set_permissions, remote_open_1, remote_detach)
5778 (remote_follow_fork, remote_follow_exec, remote_disconnect)
5779 (remote_resume, remote_commit_resume, remote_stop)
5780 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
5781 (remote_terminal_ours, remote_wait, remote_fetch_registers)
5782 (remote_prepare_to_store, remote_store_registers)
5783 (remote_flash_erase, remote_flash_done, remote_files_info)
5784 (remote_kill, remote_mourn, remote_insert_breakpoint)
5785 (remote_remove_breakpoint, remote_insert_watchpoint)
5786 (remote_watchpoint_addr_within_range)
5787 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
5788 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
5789 (remote_supports_stopped_by_sw_breakpoint)
5790 (remote_stopped_by_hw_breakpoint)
5791 (remote_supports_stopped_by_hw_breakpoint)
5792 (remote_stopped_by_watchpoint, remote_stopped_data_address)
5793 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
5794 (remote_verify_memory): Refactor as methods of remote_target.
5795 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
5797 (remote_xfer_partial, remote_get_memory_xfer_limit)
5798 (remote_search_memory, remote_rcmd, remote_memory_map)
5799 (remote_pid_to_str, remote_get_thread_local_address)
5800 (remote_get_tib_address, remote_read_description): Refactor as
5801 methods of remote_target.
5802 (remote_target::fileio_open, remote_target::fileio_pwrite)
5803 (remote_target::fileio_pread, remote_target::fileio_close): New.
5804 (remote_hostio_readlink, remote_hostio_fstat)
5805 (remote_filesystem_is_local, remote_can_execute_reverse)
5806 (remote_supports_non_stop, remote_supports_disable_randomization)
5807 (remote_supports_multi_process, remote_supports_cond_breakpoints)
5808 (remote_supports_enable_disable_tracepoint)
5809 (remote_supports_string_tracing)
5810 (remote_can_run_breakpoint_commands, remote_trace_init)
5811 (remote_download_tracepoint, remote_can_download_tracepoint)
5812 (remote_download_trace_state_variable, remote_enable_tracepoint)
5813 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
5814 (remote_trace_start, remote_get_trace_status)
5815 (remote_get_tracepoint_status, remote_trace_stop)
5816 (remote_trace_find, remote_get_trace_state_variable_value)
5817 (remote_save_trace_data, remote_get_raw_trace_data)
5818 (remote_set_disconnected_tracing, remote_core_of_thread)
5819 (remote_set_circular_trace_buffer, remote_traceframe_info)
5820 (remote_get_min_fast_tracepoint_insn_len)
5821 (remote_set_trace_buffer_size, remote_set_trace_notes)
5822 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
5823 (remote_disable_btrace, remote_teardown_btrace)
5824 (remote_read_btrace, remote_btrace_conf)
5825 (remote_augmented_libraries_svr4_read, remote_load)
5826 (remote_pid_to_exec_file, remote_can_do_single_step)
5827 (remote_execution_direction, remote_thread_handle_to_thread_info):
5828 Refactor as methods of remote_target.
5829 (init_remote_ops, init_extended_remote_ops): Delete.
5830 (remote_can_async_p, remote_is_async_p, remote_async)
5831 (remote_thread_events, remote_upload_tracepoints)
5832 (remote_upload_trace_state_variables): Refactor as methods of
5834 (_initialize_remote): Remove references to init_remote_ops and
5835 init_extended_remote_ops.
5837 * remote-sim.c (gdbsim_target): New class.
5838 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
5839 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
5840 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
5841 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
5842 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
5843 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
5844 Refactor as methods of gdbsim_target.
5845 (gdbsim_ops): Now a gdbsim_target.
5846 (init_gdbsim_ops): Delete.
5847 (gdbsim_cntrl_c): Adjust.
5848 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
5850 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
5851 (the_amd64_linux_nat_target): New.
5852 (amd64_linux_fetch_inferior_registers)
5853 (amd64_linux_store_inferior_registers): Refactor as methods of
5854 amd64_linux_nat_target.
5855 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
5856 * i386-linux-nat.c: Don't include "linux-nat.h".
5857 (i386_linux_nat_target): New class.
5858 (the_i386_linux_nat_target): New.
5859 (i386_linux_fetch_inferior_registers)
5860 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
5861 as methods of i386_linux_nat_target.
5862 (_initialize_i386_linux_nat): Adjust. Set linux_target.
5863 * inf-child.c (inf_child_ops): Delete.
5864 (inf_child_fetch_inferior_registers)
5865 (inf_child_store_inferior_registers): Delete.
5866 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
5867 methods of inf_child_target.
5868 (inf_child_target::supports_terminal_ours)
5869 (inf_child_target::terminal_init)
5870 (inf_child_target::terminal_inferior)
5871 (inf_child_target::terminal_ours_for_output)
5872 (inf_child_target::terminal_ours, inf_child_target::interrupt)
5873 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
5875 (inf_child_open, inf_child_disconnect, inf_child_close)
5876 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
5877 (inf_child_post_startup_inferior, inf_child_can_run)
5878 (inf_child_pid_to_exec_file): Refactor as methods of
5880 (inf_child_follow_fork): Delete.
5881 (inf_child_target::can_create_inferior)
5882 (inf_child_target::can_attach): New.
5883 (inf_child_target::has_all_memory, inf_child_target::has_memory)
5884 (inf_child_target::has_stack, inf_child_target::has_registers)
5885 (inf_child_target::has_execution): New.
5886 (inf_child_fileio_open, inf_child_fileio_pwrite)
5887 (inf_child_fileio_pread, inf_child_fileio_fstat)
5888 (inf_child_fileio_close, inf_child_fileio_unlink)
5889 (inf_child_fileio_readlink, inf_child_use_agent)
5890 (inf_child_can_use_agent): Refactor as methods of
5892 (return_zero, inf_child_target): Delete.
5893 (inf_child_target::inf_child_target): New.
5894 * inf-child.h: Include "target.h".
5895 (inf_child_target): Delete function prototype.
5896 (inf_child_target): New class.
5897 (inf_child_open_target, inf_child_mourn_inferior)
5898 (inf_child_maybe_unpush_target): Delete.
5899 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
5900 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
5901 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
5902 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
5903 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
5904 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
5905 (inf_ptrace_wait, inf_ptrace_xfer_partial)
5906 (inf_ptrace_thread_alive, inf_ptrace_files_info)
5907 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
5908 methods of inf_ptrace_target.
5909 (inf_ptrace_target): Delete function.
5910 * inf-ptrace.h: Include "inf-child.h".
5911 (inf_ptrace_target): Delete function declaration.
5912 (inf_ptrace_target): New class.
5913 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
5914 * linux-nat.c (linux_target): New.
5915 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
5916 (linux_nat_target::~linux_nat_target): New.
5917 (linux_child_post_attach, linux_child_post_startup_inferior)
5918 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
5919 (linux_child_remove_fork_catchpoint)
5920 (linux_child_insert_vfork_catchpoint)
5921 (linux_child_remove_vfork_catchpoint)
5922 (linux_child_insert_exec_catchpoint)
5923 (linux_child_remove_exec_catchpoint)
5924 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
5925 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
5926 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
5927 (linux_nat_stopped_data_address)
5928 (linux_nat_stopped_by_sw_breakpoint)
5929 (linux_nat_supports_stopped_by_sw_breakpoint)
5930 (linux_nat_stopped_by_hw_breakpoint)
5931 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
5932 (linux_nat_kill, linux_nat_mourn_inferior)
5933 (linux_nat_xfer_partial, linux_nat_thread_alive)
5934 (linux_nat_update_thread_list, linux_nat_pid_to_str)
5935 (linux_nat_thread_name, linux_child_pid_to_exec_file)
5936 (linux_child_static_tracepoint_markers_by_strid)
5937 (linux_nat_is_async_p, linux_nat_can_async_p)
5938 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
5939 (linux_nat_supports_multi_process)
5940 (linux_nat_supports_disable_randomization, linux_nat_async)
5941 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
5942 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
5943 (linux_nat_fileio_open, linux_nat_fileio_readlink)
5944 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
5945 methods of linux_nat_target.
5946 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
5947 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
5949 (check_stopped_by_watchpoint): Adjust.
5950 (linux_xfer_partial): Delete.
5951 (linux_target_install_ops, linux_target, linux_nat_add_target):
5953 (linux_nat_target::linux_nat_target): New.
5954 * linux-nat.h: Include "inf-ptrace.h".
5955 (linux_nat_target): New.
5956 (linux_target, linux_target_install_ops, linux_nat_add_target):
5957 Delete function declarations.
5958 (linux_target): Declare global.
5959 * linux-thread-db.c (thread_db_target): New.
5960 (thread_db_target::thread_db_target): New.
5961 (thread_db_ops): Delete.
5962 (the_thread_db_target): New.
5963 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
5964 (thread_db_update_thread_list, thread_db_pid_to_str)
5965 (thread_db_extra_thread_info)
5966 (thread_db_thread_handle_to_thread_info)
5967 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
5968 (thread_db_resume): Refactor as methods of thread_db_target.
5969 (init_thread_db_ops): Delete.
5970 (_initialize_thread_db): Remove reference to init_thread_db_ops.
5971 * x86-linux-nat.c: Don't include "linux-nat.h".
5972 (super_post_startup_inferior): Delete.
5973 (x86_linux_nat_target::~x86_linux_nat_target): New.
5974 (x86_linux_child_post_startup_inferior)
5975 (x86_linux_read_description, x86_linux_enable_btrace)
5976 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
5977 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
5978 methods of x86_linux_nat_target.
5979 (x86_linux_create_target): Delete. Bits folded ...
5980 (x86_linux_add_target): ... here. Now takes a linux_nat_target
5982 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
5983 (x86_linux_nat_target): New class.
5984 (x86_linux_create_target): Delete.
5985 (x86_linux_add_target): Now takes a linux_nat_target pointer.
5986 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
5987 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
5988 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
5989 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
5990 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
5992 (x86_use_watchpoints): Delete.
5993 * x86-nat.h: Include "breakpoint.h" and "target.h".
5994 (x86_use_watchpoints): Delete.
5995 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
5996 (x86_stopped_by_watchpoint, x86_stopped_data_address)
5997 (x86_insert_watchpoint, x86_remove_watchpoint)
5998 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
5999 (x86_stopped_by_hw_breakpoint): New declarations.
6000 (x86_nat_target): New template class.
6002 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
6003 (the_ppc_linux_nat_target): New.
6004 (ppc_linux_fetch_inferior_registers)
6005 (ppc_linux_can_use_hw_breakpoint)
6006 (ppc_linux_region_ok_for_hw_watchpoint)
6007 (ppc_linux_ranged_break_num_registers)
6008 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
6009 (ppc_linux_insert_mask_watchpoint)
6010 (ppc_linux_remove_mask_watchpoint)
6011 (ppc_linux_can_accel_watchpoint_condition)
6012 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
6013 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
6014 (ppc_linux_watchpoint_addr_within_range)
6015 (ppc_linux_masked_watch_num_registers)
6016 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
6017 (ppc_linux_read_description): Refactor as methods of
6018 ppc_linux_nat_target.
6019 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
6021 * procfs.c (procfs_xfer_partial): Delete forward declaration.
6022 (procfs_target): New class.
6023 (the_procfs_target): New.
6024 (procfs_target): Delete function.
6025 (procfs_auxv_parse, procfs_attach, procfs_detach)
6026 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
6027 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
6028 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
6029 (procfs_create_inferior, procfs_update_thread_list)
6030 (procfs_thread_alive, procfs_pid_to_str)
6031 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
6032 (procfs_stopped_data_address, procfs_insert_watchpoint)
6033 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
6034 (proc_find_memory_regions, procfs_info_proc)
6035 (procfs_make_note_section): Refactor as methods of procfs_target.
6036 (_initialize_procfs): Adjust.
6037 * sol-thread.c (sol_thread_target): New class.
6038 (sol_thread_ops): Now a sol_thread_target.
6039 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
6040 (sol_thread_fetch_registers, sol_thread_store_registers)
6041 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
6042 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
6043 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
6044 (init_sol_thread_ops): Delete.
6045 (_initialize_sol_thread): Adjust. Remove references to
6046 init_sol_thread_ops and complete_target_initialization.
6048 * windows-nat.c (windows_nat_target): New class.
6049 (windows_fetch_inferior_registers)
6050 (windows_store_inferior_registers, windows_resume, windows_wait)
6051 (windows_attach, windows_detach, windows_pid_to_exec_file)
6052 (windows_files_info, windows_create_inferior)
6053 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
6054 (windows_close, windows_pid_to_str, windows_xfer_partial)
6055 (windows_get_tib_address, windows_get_ada_task_ptid)
6056 (windows_thread_name, windows_thread_alive): Refactor as
6057 windows_nat_target methods.
6058 (do_initial_windows_stuff): Adjust.
6059 (windows_target): Delete function.
6060 (_initialize_windows_nat): Adjust.
6062 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
6063 (darwin_mourn_inferior, darwin_kill_inferior)
6064 (darwin_create_inferior, darwin_attach, darwin_detach)
6065 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
6066 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
6067 (darwin_supports_multi_process): Refactor as darwin_nat_target
6069 (darwin_resume_to, darwin_files_info): Delete.
6070 (_initialize_darwin_inferior): Rename to ...
6071 (_initialize_darwin_nat): ... this. Adjust to C++ification.
6072 * darwin-nat.h: Include "inf-child.h".
6073 (darwin_nat_target): New class.
6074 (darwin_complete_target): Delete.
6075 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
6076 (darwin_target): New.
6077 (i386_darwin_fetch_inferior_registers)
6078 (i386_darwin_store_inferior_registers): Refactor as methods of
6080 (darwin_complete_target): Delete, with ...
6081 (_initialize_i386_darwin_nat): ... bits factored out here.
6083 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
6084 (the_alpha_linux_nat_target): New.
6085 (alpha_linux_register_u_offset): Refactor as
6086 alpha_linux_nat_target method.
6087 (_initialize_alpha_linux_nat): Adjust.
6088 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
6089 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6090 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
6091 methods of linux_nat_trad_target.
6092 (linux_trad_target): Delete.
6093 * linux-nat-trad.h (linux_trad_target): Delete function.
6094 (linux_nat_trad_target): New class.
6095 * mips-linux-nat.c (mips_linux_nat_target): New class.
6096 (super_fetch_registers, super_store_registers, super_close):
6098 (the_mips_linux_nat_target): New.
6099 (mips64_linux_regsets_fetch_registers)
6100 (mips64_linux_regsets_store_registers)
6101 (mips64_linux_fetch_registers, mips64_linux_store_registers)
6102 (mips_linux_register_u_offset, mips_linux_read_description)
6103 (mips_linux_can_use_hw_breakpoint)
6104 (mips_linux_stopped_by_watchpoint)
6105 (mips_linux_stopped_data_address)
6106 (mips_linux_region_ok_for_hw_watchpoint)
6107 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6108 (mips_linux_close): Refactor as methods of mips_linux_nat.
6109 (_initialize_mips_linux_nat): Adjust to C++ification.
6111 * aix-thread.c (aix_thread_target): New class.
6112 (aix_thread_ops): Now an aix_thread_target.
6113 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
6114 (aix_thread_fetch_registers, aix_thread_store_registers)
6115 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
6116 (aix_thread_thread_alive, aix_thread_pid_to_str)
6117 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
6118 Refactor as methods of aix_thread_target.
6119 (init_aix_thread_ops): Delete.
6120 (_initialize_aix_thread): Remove references to init_aix_thread_ops
6121 and complete_target_initialization.
6122 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
6123 (rs6000_nat_target): New class.
6124 (the_rs6000_nat_target): New.
6125 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
6126 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
6127 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
6128 (super_create_inferior): Delete.
6129 (_initialize_rs6000_nat): Adjust to C++ification.
6131 * arm-linux-nat.c (arm_linux_nat_target): New class.
6132 (the_arm_linux_nat_target): New.
6133 (arm_linux_fetch_inferior_registers)
6134 (arm_linux_store_inferior_registers, arm_linux_read_description)
6135 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
6136 (arm_linux_remove_hw_breakpoint)
6137 (arm_linux_region_ok_for_hw_watchpoint)
6138 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
6139 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
6140 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
6141 arm_linux_nat_target.
6142 (_initialize_arm_linux_nat): Adjust to C++ification.
6144 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
6145 (the_aarch64_linux_nat_target): New.
6146 (aarch64_linux_fetch_inferior_registers)
6147 (aarch64_linux_store_inferior_registers)
6148 (aarch64_linux_child_post_startup_inferior)
6149 (aarch64_linux_read_description)
6150 (aarch64_linux_can_use_hw_breakpoint)
6151 (aarch64_linux_insert_hw_breakpoint)
6152 (aarch64_linux_remove_hw_breakpoint)
6153 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
6154 (aarch64_linux_region_ok_for_hw_watchpoint)
6155 (aarch64_linux_stopped_data_address)
6156 (aarch64_linux_stopped_by_watchpoint)
6157 (aarch64_linux_watchpoint_addr_within_range)
6158 (aarch64_linux_can_do_single_step): Refactor as methods of
6159 aarch64_linux_nat_target.
6160 (super_post_startup_inferior): Delete.
6161 (_initialize_aarch64_linux_nat): Adjust to C++ification.
6163 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
6164 (the_hppa_linux_nat_target): New.
6165 (hppa_linux_fetch_inferior_registers)
6166 (hppa_linux_store_inferior_registers): Refactor as methods of
6167 hppa_linux_nat_target.
6168 (_initialize_hppa_linux_nat): Adjust to C++ification.
6170 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
6171 (the_ia64_linux_nat_target): New.
6172 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
6173 (ia64_linux_stopped_data_address)
6174 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
6175 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
6176 ia64_linux_nat_target methods.
6177 (super_xfer_partial): Delete.
6178 (_initialize_ia64_linux_nat): Adjust to C++ification.
6180 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
6181 (the_m32r_linux_nat_target): New.
6182 (m32r_linux_fetch_inferior_registers)
6183 (m32r_linux_store_inferior_registers): Refactor as
6184 m32r_linux_nat_target methods.
6185 (_initialize_m32r_linux_nat): Adjust to C++ification.
6187 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
6188 (the_m68k_linux_nat_target): New.
6189 (m68k_linux_fetch_inferior_registers)
6190 (m68k_linux_store_inferior_registers): Refactor as
6191 m68k_linux_nat_target methods.
6192 (_initialize_m68k_linux_nat): Adjust to C++ification.
6194 * s390-linux-nat.c (s390_linux_nat_target): New class.
6195 (the_s390_linux_nat_target): New.
6196 (s390_linux_fetch_inferior_registers)
6197 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
6198 (s390_insert_watchpoint, s390_remove_watchpoint)
6199 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
6200 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
6201 (s390_auxv_parse, s390_read_description): Refactor as methods of
6202 s390_linux_nat_target.
6203 (_initialize_s390_nat): Adjust to C++ification.
6205 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
6206 (the_sparc_linux_nat_target): New.
6207 (_initialize_sparc_linux_nat): Adjust to C++ification.
6208 * sparc-nat.c (sparc_fetch_inferior_registers)
6209 (sparc_store_inferior_registers): Remove target_ops parameter.
6210 * sparc-nat.h (sparc_fetch_inferior_registers)
6211 (sparc_store_inferior_registers): Remove target_ops parameter.
6212 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
6213 (the_sparc64_linux_nat_target): New.
6214 (_initialize_sparc64_linux_nat): Adjust to C++ification.
6216 * spu-linux-nat.c (spu_linux_nat_target): New class.
6217 (the_spu_linux_nat_target): New.
6218 (spu_child_post_startup_inferior, spu_child_post_attach)
6219 (spu_child_wait, spu_fetch_inferior_registers)
6220 (spu_store_inferior_registers, spu_xfer_partial)
6221 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
6223 (_initialize_spu_nat): Adjust to C++ification.
6225 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
6226 (the_tilegx_linux_nat_target): New.
6227 (fetch_inferior_registers, store_inferior_registers):
6228 Refactor as methods.
6229 (_initialize_tile_linux_nat): Adjust to C++ification.
6231 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6232 (the_xtensa_linux_nat_target): New.
6233 (xtensa_linux_fetch_inferior_registers)
6234 (xtensa_linux_store_inferior_registers): Refactor as
6235 xtensa_linux_nat_target methods.
6236 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6238 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6239 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6240 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6241 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6242 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6243 (fbsd_stopped_by_sw_breakpoint)
6244 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6245 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6246 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6247 (fbsd_post_startup_inferior, fbsd_post_attach)
6248 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6249 (fbsd_set_syscall_catchpoint)
6250 (super_xfer_partial, super_resume, super_wait)
6251 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6252 (fbsd_handle_debug_trap): Remove target_ops parameter.
6253 (fbsd_nat_add_target): Delete.
6254 * fbsd-nat.h: Include "inf-ptrace.h".
6255 (fbsd_nat_add_target): Delete.
6256 (USE_SIGTRAP_SIGINFO): Define.
6257 (fbsd_nat_target): New class.
6259 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6260 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6261 (amd64bsd_target): Delete.
6262 * amd64-bsd-nat.h: New file.
6263 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6265 (amd64_fbsd_nat_target): New class.
6266 (the_amd64_fbsd_nat_target): New.
6267 (amd64fbsd_read_description): Refactor as method of
6268 amd64_fbsd_nat_target.
6269 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6270 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6271 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6272 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6273 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6274 (i386bsd_target): Delete.
6275 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6276 (i386bsd_fetch_inferior_registers)
6277 (i386bsd_store_inferior_registers): Declare.
6278 (i386_bsd_nat_target): New class.
6279 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6280 (the_i386_fbsd_nat_target): New.
6281 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6282 i386_fbsd_nat_target methods.
6283 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6284 (_initialize_i386fbsd_nat): Adjust to C++ification.
6285 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6286 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6287 (_initialize_x86_bsd_nat): Adjust to C++ification.
6288 * x86-bsd-nat.h: Include "x86-nat.h".
6289 (x86bsd_target): Delete declaration.
6290 (x86bsd_nat_target): New class.
6292 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6293 (the_aarch64_fbsd_nat_target): New.
6294 (aarch64_fbsd_fetch_inferior_registers)
6295 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6296 aarch64_fbsd_nat_target.
6297 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6298 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
6299 (the_alpha_bsd_nat_target): New.
6300 (alphabsd_fetch_inferior_registers)
6301 (alphabsd_store_inferior_registers): Refactor as
6302 alpha_bsd_nat_target methods.
6303 (_initialize_alphabsd_nat): Refactor as methods of
6304 alpha_bsd_nat_target.
6305 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
6306 (the_amd64_nbsd_nat_target): New.
6307 (_initialize_amd64nbsd_nat): Adjust to C++ification.
6308 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
6309 (the_amd64_obsd_nat_target): New.
6310 (_initialize_amd64obsd_nat): Adjust to C++ification.
6311 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
6312 (the_arm_fbsd_nat_target): New.
6313 (arm_fbsd_fetch_inferior_registers)
6314 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
6315 (_initialize_arm_fbsd_nat): Refactor as methods of
6316 arm_fbsd_nat_target.
6317 (_initialize_arm_fbsd_nat): Adjust to C++ification.
6318 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
6319 (the_arm_netbsd_nat_target): New.
6320 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
6321 arm_netbsd_nat_target.
6322 (_initialize_arm_netbsd_nat): Adjust to C++ification.
6323 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
6324 (the_hppa_nbsd_nat_target): New.
6325 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
6326 hppa_nbsd_nat_target methods.
6327 (_initialize_hppanbsd_nat): Adjust to C++ification.
6328 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
6329 (the_hppa_obsd_nat_target): New.
6330 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
6331 methods of hppa_obsd_nat_target.
6332 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
6334 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
6335 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
6337 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
6338 (_initialize_i386obsd_nat): Use add_target.
6339 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
6340 (the_m68k_bsd_nat_target): New.
6341 (m68kbsd_fetch_inferior_registers)
6342 (m68kbsd_store_inferior_registers): Refactor as methods of
6343 m68k_bsd_nat_target.
6344 (_initialize_m68kbsd_nat): Adjust to C++ification.
6345 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
6346 (the_mips_fbsd_nat_target): New.
6347 (mips_fbsd_fetch_inferior_registers)
6348 (mips_fbsd_store_inferior_registers): Refactor as methods of
6349 mips_fbsd_nat_target.
6350 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
6352 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
6353 (the_mips_nbsd_nat_target): New.
6354 (mipsnbsd_fetch_inferior_registers)
6355 (mipsnbsd_store_inferior_registers): Refactor as methods of
6356 mips_nbsd_nat_target.
6357 (_initialize_mipsnbsd_nat): Adjust to C++ification.
6358 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
6359 (the_mips64_obsd_nat_target): New.
6360 (mips64obsd_fetch_inferior_registers)
6361 (mips64obsd_store_inferior_registers): Refactor as methods of
6362 mips64_obsd_nat_target.
6363 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
6365 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
6367 * nbsd-nat.h: Include "inf-ptrace.h".
6368 (nbsd_nat_target): New class.
6369 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
6370 (obsd_wait): Refactor as methods of obsd_nat_target.
6371 (obsd_add_target): Delete.
6372 * obsd-nat.h: Include "inf-ptrace.h".
6373 (obsd_nat_target): New class.
6374 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
6375 (the_ppc_fbsd_nat_target): New.
6376 (ppcfbsd_fetch_inferior_registers)
6377 (ppcfbsd_store_inferior_registers): Refactor as methods of
6378 ppc_fbsd_nat_target.
6379 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
6381 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
6382 (the_ppc_nbsd_nat_target): New.
6383 (ppcnbsd_fetch_inferior_registers)
6384 (ppcnbsd_store_inferior_registers): Refactor as methods of
6385 ppc_nbsd_nat_target.
6386 (_initialize_ppcnbsd_nat): Adjust to C++ification.
6387 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
6388 (the_ppc_obsd_nat_target): New.
6389 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
6390 methods of ppc_obsd_nat_target.
6391 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
6393 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
6394 (the_sh_nbsd_nat_target): New.
6395 (shnbsd_fetch_inferior_registers)
6396 (shnbsd_store_inferior_registers): Refactor as methods of
6398 (_initialize_shnbsd_nat): Adjust to C++ification.
6399 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
6400 (inf_ptrace_xfer_partial): Delete.
6401 (sparc_xfer_partial, sparc_target): Delete.
6402 * sparc-nat.h (sparc_fetch_inferior_registers)
6403 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
6404 (sparc_target): Delete function declaration.
6405 (sparc_target): New template class.
6406 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
6407 (_initialize_sparcnbsd_nat): Adjust to C++ification.
6408 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
6409 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
6411 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
6412 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
6413 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
6414 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
6416 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
6417 (the_vax_bsd_nat_target): New.
6418 (vaxbsd_fetch_inferior_registers)
6419 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
6421 (_initialize_vaxbsd_nat): Adjust to C++ification.
6423 * bsd-kvm.c (bsd_kvm_target): New class.
6424 (bsd_kvm_ops): Now a bsd_kvm_target.
6425 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
6426 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
6427 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
6429 (bsd_kvm_return_one): Delete.
6430 (bsd_kvm_add_target): Adjust to C++ification.
6432 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
6433 (nto_procfs_target_procfs): New classes.
6434 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
6435 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
6436 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
6437 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
6438 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
6439 (procfs_remove_hw_breakpoint, procfs_resume)
6440 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
6441 (procfs_kill_inferior, procfs_store_registers)
6442 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
6443 as methods of nto_procfs_target.
6444 (nto_procfs_ops): Now an nto_procfs_target_procfs.
6445 (nto_native_ops): Delete.
6446 (procfs_open, procfs_native_open): Delete.
6447 (nto_native_ops): Now an nto_procfs_target_native.
6448 (init_procfs_targets): Adjust to C++ification.
6449 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
6450 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
6451 Refactor as methods of nto_procfs_target.
6453 * go32-nat.c (go32_nat_target): New class.
6454 (the_go32_nat_target): New.
6455 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
6456 (go32_store_registers, go32_xfer_partial, go32_files_info)
6457 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
6458 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
6459 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
6460 (go32_pid_to_str): Refactor as methods of go32_nat_target.
6461 (go32_target): Delete.
6462 (_initialize_go32_nat): Adjust to C++ification.
6464 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
6465 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
6466 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
6467 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
6469 (gnu_target): Delete.
6470 * gnu-nat.h (gnu_target): Delete.
6471 (gnu_nat_target): New class.
6472 * i386-gnu-nat.c (gnu_base_target): New.
6473 (i386_gnu_nat_target): New class.
6474 (the_i386_gnu_nat_target): New.
6475 (_initialize_i386gnu_nat): Adjust to C++ification.
6477 2018-05-02 Pedro Alves <palves@redhat.com>
6479 * bfd-target.c (target_bfd_xclose): Rename to ...
6480 (target_bfd_close): ... this.
6481 (target_bfd_reopen): Adjust.
6482 * target.c (target_close): Remove references to to_xclose.
6483 * target.h (target_ops::to_xclose): Delete.
6484 (target_ops::to_close): Update comments.
6486 2018-05-02 Pedro Alves <palves@redhat.com>
6488 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
6490 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
6491 * inf-ptrace.c (inf_ptrace_register_u_offset)
6492 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6493 (inf_ptrace_store_register, inf_ptrace_store_registers)
6494 (inf_ptrace_trad_target): Move to ...
6495 * linux-nat-trad.c: ... this new file.
6496 * linux-nat-trad.h: New file.
6497 * linux-nat.c (linux_target_install_ops): Make extern.
6498 (linux_trad_target): Delete.
6499 * linux-nat.h (linux_trad_target): Delete declaration.
6500 (linux_target_install_ops): Declare.
6501 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
6504 2018-05-02 Pedro Alves <palves@redhat.com>
6506 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6507 procfs_target/add_target here.
6508 * procfs.c (procfs_target): Make static.
6509 (_initialize_procfs): Call add_target here.
6510 * procfs.h (struct target_ops): Remove forward declaration.
6511 (procfs_target): Remove declaration.
6512 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
6514 2018-05-02 Pedro Alves <palves@redhat.com>
6516 * procfs.c (procfs_stopped_by_watchpoint)
6517 (procfs_insert_watchpoint, procfs_remove_watchpoint)
6518 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
6520 (procfs_use_watchpoints): Delete, move contents...
6521 (procfs_target): ... here.
6522 * procfs.h (procfs_use_watchpoints): Delete declaration.
6523 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6524 procfs_use_watchpoints.
6525 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
6526 procfs_use_watchpoints.
6528 2018-05-02 Tom Tromey <tom@tromey.com>
6531 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
6532 and var_zuinteger_unlimited.
6533 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
6534 and PARAM_ZUINTEGER_UNLIMITED.
6535 (set_parameter_value): Handle var_zuinteger and
6536 var_zuinteger_unlimited.
6537 (add_setshow_generic): Likewise.
6538 (parmpy_init): Likewise.
6540 2018-04-28 Dan Robertson <danlrobertson89@gmail.com>
6543 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
6544 pointer is not null before dereferencing it.
6546 2018-04-30 Tom Tromey <tom@tromey.com>
6548 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
6551 2018-04-30 Tom Tromey <tom@tromey.com>
6553 * breakpoint.c (mention): Remove use of is_mi_like_p.
6554 (print_mention_ranged_breakpoint): Likewise.
6555 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
6558 2018-04-30 Tom Tromey <tom@tromey.com>
6560 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
6562 2018-04-30 Tom Tromey <tom@tromey.com>
6564 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
6565 (info_spu_event_command): Remove some uses of is_mi_like_p.
6567 2018-04-30 Tom Tromey <tom@tromey.com>
6569 * python/py-framefilter.c (py_print_single_arg)
6570 (enumerate_locals, py_print_args, py_print_frame): Remove some
6571 uses of is_mi_like_p.
6573 2018-04-30 Tom Tromey <tom@tromey.com>
6576 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
6577 * ui-out.h (ui_out::is_mi_like_p): Now const.
6578 (ui_out::do_is_mi_like_p): Now const.
6579 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
6581 2018-04-30 Tom Tromey <tom@tromey.com>
6583 * varobj.c (varobj_set_visualizer): Use new_reference.
6584 * python/python.c (gdbpy_decode_line): Use new_reference.
6585 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
6588 2018-04-30 Tom Tromey <tom@tromey.com>
6590 * varobj.c (install_new_value): Use new_reference.
6591 * value.h (value_incref): Return void. Swap intro comment with
6593 * value.c (set_value_parent): Use new_reference.
6594 (value_incref): Return void. Update intro comment.
6595 (release_value): Use new_reference.
6596 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
6598 2018-04-30 Tom Tromey <tom@tromey.com>
6600 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
6601 * gdb_bfd.h (new_bfd_ref): Remove.
6602 (gdb_bfd_open): Update comment.
6603 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
6604 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
6605 (gdb_bfd_fdopenr): Use new_reference.
6606 * exec.c (exec_file_attach): Use new_reference.
6608 2018-04-30 Tom Tromey <tom@tromey.com>
6610 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
6613 2018-04-30 Tom Tromey <tom@tromey.com>
6615 * jit.c (jit_read_code_entry): Use type_align.
6616 * i386-tdep.c (i386_gdbarch_init): Don't call
6617 set_gdbarch_long_long_align_bit.
6618 * gdbarch.sh: Remove long_long_align_bit.
6619 * gdbarch.c, gdbarch.h: Rebuild.
6620 * arc-tdep.c (arc_type_align): New function.
6621 (arc_gdbarch_init): Use arc_type_align. Don't call
6622 set_gdbarch_long_long_align_bit.
6624 2018-04-30 Tom Tromey <tom@tromey.com>
6626 * rust-lang.c (rust_type_alignment): Remove.
6627 (rust_composite_type): Use type_align.
6629 2018-04-30 Tom Tromey <tom@tromey.com>
6631 * NEWS: Mention Type.align.
6632 * python/py-type.c (typy_get_alignof): New function.
6633 (type_object_getset): Add "alignof".
6635 2018-04-30 Tom Tromey <tom@tromey.com>
6639 * std-operator.def (UNOP_ALIGNOF): New operator.
6640 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
6642 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
6643 * c-lang.c (c_op_print_tab): Add alignof.
6644 * c-exp.y (ALIGNOF): New token.
6645 (exp): Add "ALIGNOF" production.
6646 (ident_tokens): Add _Alignof and alignof.
6648 2018-04-30 Tom Tromey <tom@tromey.com>
6650 * i386-tdep.c (i386_type_align): New function.
6651 (i386_gdbarch_init): Update.
6652 * gdbarch.sh (type_align): New method.
6653 * gdbarch.c, gdbarch.h: Rebuild.
6654 * arch-utils.h (default_type_align): Declare.
6655 * arch-utils.c (default_type_align): New function.
6656 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
6657 (struct type) <align_log2>: New field.
6658 <instance_flags>: Now a bitfield.
6659 (TYPE_RAW_ALIGN): New macro.
6660 (type_align, type_raw_align, set_type_align): Declare.
6661 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
6663 * dwarf2read.c (quirk_rust_enum): Set type alignment.
6664 (get_alignment, maybe_set_alignment): New functions.
6665 (read_structure_type, read_enumeration_type, read_array_type)
6666 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
6667 (read_subrange_type, read_base_type): Set type alignment.
6669 2018-04-30 Simon Marchi <simon.marchi@ericsson.com>
6671 * dwarf2read.c (read_index_from_section): Use bool.
6673 2018-04-29 Fabian Groffen <grobian@gentoo.org>
6676 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
6679 2018-04-29 John Reiser <jreiser@BitWagon.com>
6682 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
6683 last step, and do it atomically.
6685 2018-04-27 Alexandre Oliva <aoliva@redhat.com>
6687 * compile/compile-c-types.c (convert_int, convert_float):
6690 2018-04-27 Tom Tromey <tom@tromey.com>
6693 * rust-lang.c (rust_inclusive_range_type_p): New function.
6694 (rust_range): Handle inclusive ranges.
6695 (rust_compute_range): Likewise.
6696 * rust-exp.y (struct rust_op) <inclusive>: New field.
6697 (DOTDOTEQ): New constant.
6698 (range_expr): Add "..=" productions.
6699 (operator_tokens): Add "..=" token.
6700 (ast_range): Add "inclusive" parameter.
6701 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
6703 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
6705 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
6706 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
6708 * expprint.c (print_subexp_standard): Handle new bounds values.
6709 (dump_subexp_body_standard): Likewise.
6711 2018-04-27 Tom Tromey <tom@tromey.com>
6713 * configure: Rebuild.
6714 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
6715 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
6717 (class symbol_needs_eval_context): Likewise.
6718 * dwarf2read.c (mock_mapped_index::symbol_name_count)
6719 (mock_mapped_index::symbol_name_at): Use "override". Remove
6721 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
6723 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
6724 * aarch64-tdep.c (instruction_reader::read): Use "override".
6725 (instruction_reader_test::read): Likewise.
6726 * arm-tdep.c (instruction_reader::read): Use "override".
6727 (instruction_reader_thumb::read): Likewise.
6729 2018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
6732 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
6733 instead of remote_send.
6734 (remote_send): Remove.
6736 2018-04-26 Pedro Alves <palves@redhat.com>
6738 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
6739 find_function_start_sal instead of find_pc_line.
6741 2018-04-26 Pedro Alves <palves@redhat.com>
6743 * breakpoint.c (set_breakpoint_location_function): Handle
6745 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
6746 * elfread.c (elf_symtab_read): Give data symbols with
6747 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
6748 (elf_rel_plt_read): Update comment.
6749 * linespec.c (convert_linespec_to_sals): Handle
6751 (minsym_found): Handle mst_data_gnu_ifunc.
6752 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
6753 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
6754 * parse.c (find_minsym_type_and_address): Handle
6756 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
6757 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
6758 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
6760 <mst_data_gnu_ifunc>: New enumerator.
6762 2018-04-26 Pedro Alves <palves@redhat.com>
6764 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
6765 (lookup_minimal_symbol_by_pc_section): ... this. Replace
6766 'want_trampoline' parameter by a lookup_msym_prefer parameter.
6768 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
6769 (lookup_minimal_symbol_by_pc): Adjust.
6770 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
6771 (lookup_solib_trampoline_symbol_by_pc): Adjust.
6772 * minsyms.h (lookup_msym_prefer): New enum.
6773 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6774 parameter by a lookup_msym_prefer parameter.
6776 2018-04-26 Pedro Alves <palves@redhat.com>
6778 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
6779 ends in "@plt" instead of looking at the symbol's section.
6781 2018-04-26 Pedro Alves <palves@redhat.com>
6783 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
6785 (find_pc_partial_function_gnu_ifunc): Rename to ...
6786 (find_pc_partial_function): ... this, and remove references to
6788 (find_pc_partial_function): Delete old implementation.
6789 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
6791 2018-04-26 Pedro Alves <palves@redhat.com>
6793 * linespec.c (struct bound_minimal_symbol_search_key): New.
6794 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
6795 skip first line if we found a GNU ifunc minimal symbol by name.
6796 (compare_msymbols): Change parameters to work with a destructured
6798 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
6801 2018-04-26 Pedro Alves <palves@redhat.com>
6803 * breakpoint.c (set_breakpoint_location_function): Don't resolve
6804 ifunc targets here. Instead, if we have an ifunc minsym, use its
6806 (add_location_to_breakpoint): Store the minsym and the objfile in
6807 the breakpoint location.
6808 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
6809 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
6810 Record the minsym in the sal.
6811 * symtab.h (symtab_and_line) <msymbol>: New field.
6813 2018-04-26 Pedro Alves <palves@redhat.com>
6815 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
6816 unless we actually resolved the ifunc.
6818 2018-04-26 Pedro Alves <palves@redhat.com>
6820 * c-exp.y (variable production): Prefer ifunc minsyms over
6821 regular function symbols.
6822 * symtab.c (find_gnu_ifunc): New function.
6823 * minsyms.h (lookup_msym_prefer): New enum.
6824 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6825 parameter by a lookup_msym_prefer parameter.
6826 * symtab.h (find_gnu_ifunc): New declaration.
6828 2018-04-26 Pedro Alves <palves@redhat.com>
6830 * blockframe.c (find_gnu_ifunc_target_type): New function.
6831 (find_function_type): New.
6832 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
6833 return a value with a memory address.
6834 (eval_call): For calls to GNU ifunc functions, try to find the
6835 type of the target function from the type that the resolver
6837 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
6839 * infcall.c (find_function_return_type): Delete.
6840 (find_function_addr): Add 'function_type' parameter. For calls to
6841 GNU ifunc functions, try to find the type of the target function
6842 from the type that the resolver returns, and return it via
6844 (call_function_by_hand_dummy): Adjust to use the function type
6845 returned by find_function_addr.
6846 (find_function_addr): Add 'function_type' parameter and move
6848 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
6851 2018-04-26 Pedro Alves <palves@redhat.com>
6853 * c-exp.y (variable production): Skip finding an alias for ifunc
6856 2018-04-26 Pedro Alves <palves@redhat.com>
6858 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
6860 2018-04-25 Pedro Alves <palves@redhat.com>
6862 * infcmd.c (kill_command): Print the pid as string, not the whole
6863 thread's ptid. Add comment. s/has been killed/killed/ in output
6865 * remote.c (remote_detach_1): Print the pid as string, not the
6866 whole thread's ptid.
6868 2018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6869 Sergio Durigan Junior <sergiodj@redhat.com>
6870 Pedro Alves <palves@redhat.com>
6872 * infcmd.c (kill_command): Print message when inferior has
6874 * inferior.c (print_inferior_events): Remove 'static'. Set as
6876 (add_inferior): Improve message printed when
6877 'print_inferior_events' is on.
6878 (exit_inferior): Remove message printed when
6879 'print_inferior_events' is on.
6880 (detach_inferior): Improve message printed when
6881 'print_inferior_events' is on.
6882 (initialize_inferiors): Use 'add_inferior_silent' to set
6883 'current_inferior_'.
6884 * inferior.h (print_inferior_events): Declare here as
6886 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
6887 '[Detaching...]' messages when 'print_inferior_events' is on.
6888 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
6889 as prefix/suffix for messages. Remove periods. Fix erroneous
6890 'Detaching after fork from child...', replace it by '... from
6892 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
6893 prefix/suffix when printing 'Detaching...' messages. Print
6894 them when 'print_inferior_events' is on.
6895 * remote.c (remote_detach_1): Print message when detaching
6896 from inferior and '!is_fork_parent'.
6898 2018-04-24 Tom Tromey <tom@tromey.com>
6900 * cli-out.h: Reindent.
6902 2018-04-24 Tom Tromey <tom@tromey.com>
6904 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
6905 (cli_ui_out::do_field_string): Use fputs_filtered.
6906 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
6908 2018-04-23 Tom Tromey <tom@tromey.com>
6910 * guile/scm-frame.c (gdbscm_frame_read_var): Use
6911 gdb::unique_xmalloc_ptr.
6913 2018-04-23 Tom Tromey <tom@tromey.com>
6915 * configure: Rebuild.
6917 2018-04-22 Rajendra SY <rajendra.sy@gmail.com>
6920 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
6921 prepare_for_testing. Set normal_bp to r_debug_state if target
6924 2018-04-21 Pedro Alves <palves@redhat.com>
6925 Rajendra SY <rajendra.sy@gmail.com>
6927 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
6928 * remote.c (extended_remote_attach): In all-stop mode, mark the
6929 thread as executing.
6931 2018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6933 * thread.c (thread_apply_all_command): Fix comment.
6934 (thread_command): Fix comment.
6936 2018-04-10 Alan Hayward <alan.hayward@arm.com>
6938 * common/tdesc.h (tdesc_create_feature): Remove xml filename
6940 * features/aarch64-core.c (create_feature_aarch64_core):
6942 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
6944 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
6946 * features/i386/32bit-avx512.c
6947 (create_feature_i386_32bit_avx512): Likewise.
6948 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
6950 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
6952 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
6954 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
6956 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
6958 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
6960 * features/i386/64bit-avx512.c
6961 (create_feature_i386_64bit_avx512): Likewise.
6962 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
6964 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
6966 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
6968 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
6970 * features/i386/64bit-segments.c
6971 (create_feature_i386_64bit_segments): Likewise.
6972 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
6974 * features/i386/x32-core.c
6975 (create_feature_i386_x32_core): Likewise.
6976 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
6977 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
6978 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
6979 * target-descriptions.c: In generated code, don't pass xml
6982 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6984 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
6985 (print_xml_feature::visit_post): Likewise.
6986 (print_xml_feature::visit): Likewise.
6987 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
6988 (print_xml_feature): Add new class.
6989 * regformats/regdat.sh: Null xmltarget on feature targets.
6990 * target-descriptions.c (struct target_desc): Add xmltarget.
6991 (maintenance_check_tdesc_xml_convert): Add unittest function.
6992 (tdesc_get_features_xml): Add function to get xml.
6993 (maintenance_check_xml_descriptions): Test xml generation.
6994 * xml-tdesc.c (string_read_description_xml): Add function.
6995 * xml-tdesc.h (string_read_description_xml): Add declaration.
6997 2018-04-18 Alan Hayward <alan.hayward@arm.com>
6999 * features/Makefile: Add feature marker to targets with new style
7000 target descriptions.
7001 * regformats/aarch64.dat: Regenerate.
7002 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
7003 * regformats/i386/amd64-avx-linux.dat: Likewise.
7004 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
7005 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
7006 * regformats/i386/amd64-linux.dat: Likewise.
7007 * regformats/i386/amd64-mpx-linux.dat: Likewise.
7008 * regformats/i386/amd64.dat: Likewise.
7009 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
7010 * regformats/i386/i386-avx-linux.dat: Likewise.
7011 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
7012 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
7013 * regformats/i386/i386-linux.dat: Likewise.
7014 * regformats/i386/i386-mmx-linux.dat: Likewise.
7015 * regformats/i386/i386-mpx-linux.dat: Likewise.
7016 * regformats/i386/i386.dat: Likewise.
7017 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
7018 * regformats/i386/x32-avx-linux.dat: Likewise.
7019 * regformats/i386/x32-linux.dat: Likewise.
7020 * regformats/tic6x-c62x-linux.dat: Likewise.
7021 * regformats/tic6x-c64x-linux.dat: Likewise.
7022 * regformats/tic6x-c64xp-linux.dat: Likewise.
7023 * regformats/regdat.sh: Parse feature marker.
7025 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7027 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
7028 (tdesc_osabi_name): Likewise.
7029 * target-descriptions.c (tdesc_architecture_name): Add new
7031 (tdesc_osabi_name): Likewise.
7033 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7035 * common/tdesc.c (tdesc_predefined_type): Move to here.
7036 (tdesc_named_type): Likewise.
7037 (tdesc_create_vector): Likewise.
7038 (tdesc_create_struct): Likewise.
7039 (tdesc_set_struct_size): Likewise.
7040 (tdesc_create_union): Likewise.
7041 (tdesc_create_flags): Likewise.
7042 (tdesc_create_enum): Likewise.
7043 (tdesc_add_field): Likewise.
7044 (tdesc_add_typed_bitfield): Likewise.
7045 (tdesc_add_bitfield): Likewise.
7046 (tdesc_add_flag): Likewise.
7047 (tdesc_add_enum_value): Likewise.
7048 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
7049 (struct tdesc_type_vector): Likewise.
7050 (struct tdesc_type_field): Likewise.
7051 (struct tdesc_type_with_fields): Likewise.
7052 (tdesc_create_enum): Add declaration.
7053 (tdesc_add_typed_bitfield): Likewise.
7054 (tdesc_add_enum_value): Likewise.
7055 * target-descriptions.c (tdesc_type_field): Move from here.
7056 (tdesc_type_builtin): Likewise.
7057 (tdesc_type_vector): Likewise.
7058 (tdesc_type_with_fields): Likewise.
7059 (tdesc_predefined_types): Likewise.
7060 (tdesc_named_type): Likewise.
7061 (tdesc_create_vector): Likewise.
7062 (tdesc_create_struct): Likewise.
7063 (tdesc_set_struct_size): Likewise.
7064 (tdesc_create_union): Likewise.
7065 (tdesc_create_flags): Likewise.
7066 (tdesc_create_enum): Likewise.
7067 (tdesc_add_field): Likewise.
7068 (tdesc_add_typed_bitfield): Likewise.
7069 (tdesc_add_bitfield): Likewise.
7070 (tdesc_add_flag): Likewise.
7071 (tdesc_add_enum_value): Likewise.
7072 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
7073 (tdesc_add_typed_bitfield): Likewise.
7074 (tdesc_add_enum_value): Likewise.
7076 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7078 * common/tdesc.c (tdesc_feature::accept): Move to here.
7079 (tdesc_feature::operator==): Likewise.
7080 (tdesc_create_reg): Likewise.
7081 * common/tdesc.h (tdesc_type_kind): Likewise.
7082 (struct tdesc_type): Likewise.
7083 (struct tdesc_feature): Likewise.
7084 * regformats/regdat.sh: Create a feature.
7085 * target-descriptions.c (tdesc_type_kind): Move from here.
7086 (tdesc_type): Likewise.
7087 (tdesc_type_up): Likewise.
7088 (tdesc_feature): Likewise.
7089 (tdesc_create_reg): Likewise.
7091 2018-04-18 Alan Hayward <alan.hayward@arm.com>
7093 * Makefile.in: Add arch/tdesc.c
7094 * common/tdesc.c: New file.
7095 * common/tdesc.h (tdesc_element_visitor): Move to here.
7096 (tdesc_element): Likewise.
7097 (tdesc_reg): Likewise.
7098 (tdesc_reg_up): Likewise.
7099 * regformats/regdef.h (reg): Add offset to constructors.
7100 * target-descriptions.c (tdesc_element_visitor): Move from here.
7101 (tdesc_element): Likewise.
7102 (tdesc_reg): Likewise.
7103 (tdesc_reg_up): Likewise.
7105 2018-04-17 Tom Tromey <tom@tromey.com>
7107 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
7110 2018-04-17 Tom Tromey <tom@tromey.com>
7112 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
7114 2018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
7116 * symtab.c (print_symbol_info): Skip printing filename and line
7117 number when `last' is NULL.
7118 (symtab_symbol_info): Use empty string instead of NULL for first
7119 invocation of print_symbol_info.
7120 (rbreak_command): Pass NULL to `last' parameter of
7123 2018-04-16 Simon Marchi <simon.marchi@ericsson.com>
7125 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
7128 2018-04-16 Pedro Alves <palves@redhat.com>
7130 * MAINTAINERS (sh): Remove.
7131 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
7132 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
7133 (ALLDEPFILES): Remove sh64-tdep.c.
7134 * NEWS: Mentions that support for SH-5/SH64 is removed.
7135 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
7136 (sh*-*-openbsd*): Ditto.
7137 (sh64-*-elf*): Remove.
7139 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
7140 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
7141 * sh-tdep.c: No longer include "sh64-tdep.h".
7142 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
7143 * sh64-tdep.c, sh64-tdep.h: Remove files.
7145 2018-04-16 Pedro Alves <palves@redhat.com>
7147 * MAINTAINERS: Remove m88k.
7148 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
7149 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
7150 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
7151 * NEWS: Mention that support for m88k was removed.
7152 * configure.host (m88*-*-*): Remove support.
7153 * configure.nat (m88k-*-*): Remove support.
7154 * configure.tgt (m88*-*-openbsd*): Remove.
7155 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
7157 2018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
7159 * configure.tgt (x86_tobjs): New variable.
7160 (amd64_tobjs, i386_tobjs): Use it.
7162 2018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7164 * symtab.c (print_symbol_info): Precede the symbol definition by
7165 the line number when available.
7166 * NEWS: Advertise this enhancement.
7168 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7170 * NEWS (New options): announce set/show record btrace cpu.
7171 * btrace.c: Include record-btrace.h.
7172 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
7173 the vendor is unknown.
7174 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
7175 Maybe overwrite the btrace configuration's cpu.
7176 (btrace_compute_ftrace): Add cpu parameter. Update callers.
7177 (btrace_fetch): Add cpu parameter. Update callers.
7178 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
7179 Maybe overwrite the btrace configuration's cpu. Skip enabling
7180 errata workarounds if the vendor is unknown.
7181 * python/py-record-btrace.c: Include record-btrace.h.
7182 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
7183 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
7184 * record-btrace.c (record_btrace_cpu_state_kind): New.
7185 (record_btrace_cpu): New.
7186 (set_record_btrace_cpu_cmdlist): New.
7187 (record_btrace_get_cpu): New.
7188 (require_btrace_thread, record_btrace_info)
7189 (record_btrace_resume_thread): Call record_btrace_get_cpu.
7190 (cmd_set_record_btrace_cpu_none): New.
7191 (cmd_set_record_btrace_cpu_auto): New.
7192 (cmd_set_record_btrace_cpu): New.
7193 (cmd_show_record_btrace_cpu): New.
7194 (_initialize_record_btrace): Initialize set/show record btrace cpu
7196 * record-btrace.h (record_btrace_get_cpu): New.
7198 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7200 * record.c (set_record_command): Fix typo in message.
7202 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7204 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
7206 2018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7208 * infrun.c (process_event_stop_test): Call
7209 gdbarch_in_indirect_branch_thunk.
7210 * gdbarch.sh (in_indirect_branch_thunk): New.
7211 * gdbarch.c: Regenerated.
7212 * gdbarch.h: Regenerated.
7215 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
7216 (HFILES_NO_SRCDIR): Add x86-tdep.h.
7217 (ALLDEPFILES): Add x86-tdep.c.
7218 * arch-utils.h (default_in_indirect_branch_thunk): New.
7219 * arch-utils.c (default_in_indirect_branch_thunk): New.
7220 * i386-tdep: Include x86-tdep.h.
7221 (i386_in_indirect_branch_thunk): New.
7222 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
7224 * amd64-tdep: Include x86-tdep.h.
7225 (amd64_in_indirect_branch_thunk): New.
7226 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7228 2018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7231 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7232 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7233 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7236 2018-04-12 Tom Tromey <tom@tromey.com>
7238 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7239 (rust_evaluate_subexp): Likewise.
7241 2018-04-12 Pedro Alves <palves@redhat.com>
7243 * procfs.c (procfs_detach): Make forward declaration's prototype
7244 match definition's protototype.
7245 (proc_get_LDT_entry): Remove stale do_cleanups call.
7247 2018-04-12 Pedro Alves <palves@redhat.com>
7249 * target.h (target_ops::to_has_exited): Delete.
7250 (target_has_exited): Delete.
7251 * target-delegates.c: Regenerate.
7253 2018-04-11 Pedro Alves <palves@redhat.com>
7255 * target.c (fileio_fh_t::t): Add comment.
7256 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7257 (target_fileio_close): Handle a NULL target.
7258 (invalidate_fileio_fh): New.
7259 (target_close): Call it.
7260 * remote.c (remote_hostio_send_command): No longer check whether
7261 remote_desc is open.
7263 2018-04-11 Pedro Alves <palves@redhat.com>
7265 * target.c (fileio_fh_t): Make it a named struct instead of a
7267 (fileio_fh_t::is_closed): New method.
7268 (DEF_VEC_O (fileio_fh_t)): Remove.
7269 (fileio_fhandles): Now a std::vector.
7270 (is_closed_fileio_fh): Delete.
7271 (acquire_fileio_fd): Adjust. Rename parameters.
7272 (release_fileio_fd): Adjust.
7273 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7274 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7275 (target_fileio_close): Adjust.
7277 2018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7279 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7282 2018-04-10 Pedro Alves <palves@redhat.com>
7284 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7285 (scoped_finish_thread_state): New class.
7286 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7288 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7289 (fetch_inferior_event, normal_stop): Likewise.
7290 * thread.c (finish_thread_state_cleanup): Delete.
7292 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7293 Pedro Alves <palves@redhat.com>
7295 * value.c: Include "selftest.h" and "common/array-view.h".
7296 (struct range) <operator ==>: New.
7297 (test_ranges_contain): New.
7298 (check_ranges_vector): New.
7299 (test_insert_into_bit_range_vector): New.
7300 (_initialize_values): Register selftests.
7301 * common/array-view.h (operator==, operator!=): New.
7303 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7305 * common/gdb_vecs.h (unordered_remove): Add overload that takes
7307 * inline-frame.c: Include <algorithm>.
7308 (struct inline_state): Add constructor.
7309 (inline_state_s): Remove.
7310 (DEF_VEC_O(inline_state_s)): Remove.
7311 (inline_states): Change type to std::vector.
7312 (find_inline_frame_state): Adjust to std::vector.
7313 (allocate_inline_frame_state): Remove.
7314 (clear_inline_frame_state): Adjust to std::vector.
7315 (skip_inline_frames): Adjust to std::vector.
7317 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7319 * tracepoint.h (struct trace_state_variable): Add constructor.
7320 <name>: Change type to std::string.
7321 * tracepoint.c (tsv_s): Remove.
7322 (DEF_VEC_O(tsv_s)): Remove.
7323 (tvariables): Change to std::vector.
7324 (create_trace_state_variable): Adjust to std::vector.
7325 (find_trace_state_variable): Likewise.
7326 (find_trace_state_variable_by_number): Likewise.
7327 (delete_trace_state_variable): Likewise.
7328 (trace_variable_command): Adjust to std::string.
7329 (delete_trace_variable_command): Likewise.
7330 (tvariables_info_1): Adjust to std::vector.
7331 (save_trace_state_variables): Likewise.
7332 (start_tracing): Likewise.
7333 (merge_uploaded_trace_state_variables): Adjust to std::vector
7335 * target.h (struct target_ops)
7336 <to_download_trace_state_variable>: Pass reference to
7337 trace_state_variable.
7338 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
7339 * target-delegates.c: Re-generate.
7340 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
7341 (mi_tsv_deleted): Likewise.
7342 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
7343 * remote.c (remote_download_trace_state_variable): Change
7344 pointer to reference and adjust.
7345 * make-target-delegates (parse_argtypes): Handle references.
7346 (write_function_header): Likewise.
7347 (munge_type): Likewise.
7349 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7351 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7352 string_view-selftests.c.
7353 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
7355 * unittests/basic_string_view/cons/char/1.cc: Likewise.
7356 * unittests/basic_string_view/cons/char/2.cc: Likewise.
7357 * unittests/basic_string_view/cons/char/3.cc: Likewise.
7358 * unittests/basic_string_view/element_access/char/1.cc:
7360 * unittests/basic_string_view/element_access/char/empty.cc:
7362 * unittests/basic_string_view/element_access/char/front_back.cc:
7364 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
7365 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
7367 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
7369 * unittests/basic_string_view/modifiers/swap/char/1.cc:
7371 * unittests/basic_string_view/operations/compare/char/1.cc:
7373 * unittests/basic_string_view/operations/compare/char/13650.cc:
7375 * unittests/basic_string_view/operations/copy/char/1.cc:
7377 * unittests/basic_string_view/operations/data/char/1.cc:
7379 * unittests/basic_string_view/operations/find/char/1.cc:
7381 * unittests/basic_string_view/operations/find/char/2.cc:
7383 * unittests/basic_string_view/operations/find/char/3.cc:
7385 * unittests/basic_string_view/operations/find/char/4.cc:
7387 * unittests/basic_string_view/operations/rfind/char/1.cc:
7389 * unittests/basic_string_view/operations/rfind/char/2.cc:
7391 * unittests/basic_string_view/operations/rfind/char/3.cc:
7393 * unittests/basic_string_view/operations/substr/char/1.cc:
7395 * unittests/basic_string_view/operators/char/2.cc: Likewise.
7396 * unittests/string_view-selftests.c: New file.
7398 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7400 * unittests/basic_string_view/capacity/1.cc: New file.
7401 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
7402 * unittests/basic_string_view/cons/char/1.cc: New file.
7403 * unittests/basic_string_view/cons/char/2.cc: New file.
7404 * unittests/basic_string_view/cons/char/3.cc: New file.
7405 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
7406 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
7407 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
7408 * unittests/basic_string_view/element_access/char/1.cc: New file.
7409 * unittests/basic_string_view/element_access/char/2.cc: New file.
7410 * unittests/basic_string_view/element_access/char/empty.cc: New file.
7411 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
7412 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
7413 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
7414 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
7415 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
7416 * unittests/basic_string_view/include.cc: New file.
7417 * unittests/basic_string_view/inserters/char/1.cc: New file.
7418 * unittests/basic_string_view/inserters/char/2.cc: New file.
7419 * unittests/basic_string_view/inserters/char/3.cc: New file.
7420 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
7421 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
7422 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
7423 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
7424 * unittests/basic_string_view/literals/types.cc: New file.
7425 * unittests/basic_string_view/literals/values.cc: New file.
7426 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
7427 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
7428 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
7429 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
7430 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
7431 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
7432 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
7433 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
7434 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
7435 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
7436 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
7437 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
7438 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
7439 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
7440 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
7441 * unittests/basic_string_view/operations/data/char/1.cc: New file.
7442 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
7443 * unittests/basic_string_view/operations/find/char/1.cc: New file.
7444 * unittests/basic_string_view/operations/find/char/2.cc: New file.
7445 * unittests/basic_string_view/operations/find/char/3.cc: New file.
7446 * unittests/basic_string_view/operations/find/char/4.cc: New file.
7447 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
7448 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
7449 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
7450 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
7451 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
7452 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
7453 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
7454 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
7455 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
7456 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
7457 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
7458 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
7459 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
7460 * unittests/basic_string_view/operators/char/2.cc: New file.
7461 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
7462 * unittests/basic_string_view/range_access/char/1.cc: New file.
7463 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
7464 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
7465 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
7466 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
7467 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
7468 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
7469 * unittests/basic_string_view/requirements/typedefs.cc: New file.
7470 * unittests/basic_string_view/typedefs.cc: New file.
7471 * unittests/basic_string_view/types/1.cc: New file.
7473 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7475 * common/gdb_string_view.h: Remove libstdc++ implementation
7476 details, adjust to gdb reality.
7477 * common/gdb_string_view.tcc: Likewise.
7478 * cli/cli-script.c (struct string_view): Remove.
7479 (user_args) <m_args>: Change element type to gdb::string_view.
7480 (user_args::insert_args): Adjust.
7482 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7484 * common/gdb_string_view.h: New file.
7485 * common/gdb_string_view.tcc: New file.
7487 2018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7489 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
7490 * configure: Re-generate.
7492 2018-04-09 Pedro Alves <palves@redhat.com>
7494 * gdbarch.sh: Include "observable.h" instead of "observer.h".
7495 (set_target_gdbarch): Call
7496 gdb::observers::architecture_changed.notify instead of
7497 observer_notify_architecture_changed.
7499 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7501 * tracepoint.c (struct current_traceframe_cleanup): Remove.
7502 (do_restore_current_traceframe_cleanup): Remove.
7503 (restore_current_traceframe_cleanup_dtor): Remove.
7504 (make_cleanup_restore_current_traceframe): Remove.
7505 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
7507 * tracepoint.h (struct scoped_restore_current_traceframe): New.
7508 * infrun.c (fetch_inferior_event): Use
7509 scoped_restore_current_traceframe.
7511 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7513 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
7515 <n_allocated_type_units>: Remove.
7516 <all_type_units>: Change to std::vector.
7517 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7518 to std::vector change.
7519 (dwarf2_per_objfile::get_cutu): Likewise.
7520 (dwarf2_per_objfile::get_tu): Likewise.
7521 (create_signatured_type_table_from_index): Likewise.
7522 (create_signatured_type_table_from_debug_names): Likewise.
7523 (dw2_symtab_iter_next): Likewise.
7524 (dw2_print_stats): Likewise.
7525 (dw2_expand_all_symtabs): Likewise.
7526 (dw2_expand_marked_cus): Likewise.
7527 (dw2_debug_names_iterator::next): Likewise.
7528 (dwarf2_initialize_objfile): Likewise.
7529 (add_signatured_type_cu_to_table): Likewise.
7530 (create_all_type_units): Likewise.
7531 (add_type_unit): Likewise.
7532 (struct tu_abbrev_offset): Add constructor.
7533 (build_type_psymtabs_1): Adjust to std::vector change.
7534 (print_tu_stats): Likewise.
7535 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7536 (write_debug_names): Likewise.
7538 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7540 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
7541 Make an std::vector.
7542 <n_comp_units>: Remove.
7543 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7544 to std::vector change.
7545 (dwarf2_per_objfile::get_cutu): Likewise.
7546 (dwarf2_per_objfile::get_cu): Likewise.
7547 (create_cus_from_index): Likewise.
7548 (create_addrmap_from_index): Likewise.
7549 (create_addrmap_from_aranges): Likewise.
7550 (dwarf2_read_index): Likewise.
7551 (dw2_find_last_source_symtab): Likewise.
7552 (dw2_map_symtabs_matching_filename): Likewise.
7553 (dw2_symtab_iter_next): Likewise.
7554 (dw2_print_stats): Likewise.
7555 (dw2_expand_all_symtabs): Likewise.
7556 (dw2_expand_symtabs_with_fullname): Likewise.
7557 (dw2_expand_marked_cus): Likewise.
7558 (dw2_map_symbol_filenames): Likewise.
7559 (create_cus_from_debug_names): Likewise.
7560 (dwarf2_read_debug_names): Likewise.
7561 (dw2_debug_names_iterator::next): Likewise.
7562 (dwarf2_initialize_objfile): Likewise.
7563 (set_partial_user): Likewise.
7564 (dwarf2_build_psymtabs_hard): Likewise.
7565 (read_comp_units_from_section): Remove arguments, adjust to
7567 (create_all_comp_units): Adjust to std::vector and
7568 read_comp_units_from_section changes.
7569 (dwarf2_find_containing_comp_unit): Adjust to std::vector
7571 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7572 (psyms_seen_size): Likewise.
7573 (write_gdbindex): Likewise.
7574 (write_debug_names): Likewise.
7576 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7578 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
7579 with dwarf2_per_objfile.
7580 (create_cus_from_index): Likewise.
7581 (create_signatured_type_table_from_index): Likewise.
7582 (dwarf2_read_index): Likewise.
7583 (dwarf2_initialize_objfile): Likewise.
7584 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
7585 per_cu rather than get_dwarf2_per_objfile.
7587 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7589 * dwarf2read.h (struct signatured_type): Forward declare.
7590 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
7592 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
7593 (dw2_get_cutu): ...this.
7594 (dwarf2_per_objfile::get_cu): Rename from...
7595 (dw2_get_cu): ...this.
7596 (dwarf2_per_objfile::get_tu): New.
7597 (create_addrmap_from_index): Adjust.
7598 (create_addrmap_from_aranges): Adjust.
7599 (dw2_find_last_source_symtab): Adjust.
7600 (dw2_map_symtabs_matching_filename): Adjust.
7601 (dw2_symtab_iter_next): Adjust.
7602 (dw2_print_stats): Adjust.
7603 (dw2_expand_all_symtabs): Adjust.
7604 (dw2_expand_symtabs_with_fullname): Adjust.
7605 (dw2_expand_marked_cus): Adjust.
7606 (dw_expand_symtabs_matching_file_matcher): Adjust.
7607 (dw2_map_symbol_filenames): Adjust.
7608 (dw2_debug_names_iterator::next): Adjust.
7609 (dwarf2_initialize_objfile): Adjust.
7610 (set_partial_user): Adjust.
7611 (dwarf2_build_psymtabs_hard): Adjust.
7613 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7615 * dwarf2read.c (create_signatured_type_table_from_debug_names):
7616 Remove unused variables.
7617 (dw2_map_symtabs_matching_filename): Likewise.
7618 (dwarf2_record_block_ranges): Likewise.
7619 (dwarf2_read_addr_index): Likewise.
7620 (follow_die_offset): Likewise.
7622 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7624 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
7625 to symbol_file_add_main.
7627 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7630 * mi/mi-console.c (do_fputc_async_safe): New.
7631 (mi_console_file::write_async_safe): New.
7632 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
7633 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
7635 * ui-file.c (ui_file::putstrn): Adjust call to
7636 fputstrn_unfiltered.
7637 * utils.c (printchar): Replace do_fputs and do_fprintf
7638 parameters by do_fputc.
7639 (fputstr_filtered): Adjust call to printchar.
7640 (fputstr_unfiltered): Likewise.
7641 (fputstrn_filtered): Likewise.
7642 (fputstrn_unfiltered): Add do_fputc parameter, pass to
7644 * utils.h (do_fputc_ftype): New typedef.
7645 (fputstrn_unfiltered): Add do_fputc parameter.
7647 2018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7649 * regformats/i386/i386-avx.dat: Remove.
7651 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7654 * amd64-tdep.c (amd64_none_init_abi): New function.
7655 (amd64_x32_none_init_abi): New function.
7656 (_initialize_amd64_tdep): Register handlers for x86-64 and
7657 x64_32 with GDB_OSABI_NONE.
7658 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
7659 GDB_OSABI_NONE osabi.
7661 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7664 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
7666 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
7667 * osabi.c (gdb_osabi_names): Add "unknown" entry.
7669 2018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7671 * common/byte-vector.h (char_vector): New type.
7672 * target.h (target_read_alloc): Return
7673 gdb::optional<byte_vector>.
7674 (target_read_stralloc): Return gdb::optional<char_vector>.
7675 (target_get_osdata): Return gdb::optional<char_vector>.
7676 * target.c (target_read_alloc_1): Templatize. Replacement
7677 manual memory management with vector.
7678 (target_read_alloc): Change return type, adjust.
7679 (target_read_stralloc): Change return type, adjust.
7680 (target_get_osdata): Change return type, adjust.
7681 * auxv.c (struct auxv_info) <length>: Remove.
7682 <data>: Change type to gdb::optional<byte_vector>.
7683 (auxv_inferior_data_cleanup): Free auxv_info with delete.
7684 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
7685 (target_auxv_search): Adjust.
7686 (fprint_target_auxv): Adjust.
7687 * avr-tdep.c (avr_io_reg_read_command): Adjust.
7688 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
7689 (linux_make_corefile_notes): Adjust.
7690 * osdata.c (get_osdata): Adjust.
7691 * remote.c (remote_get_threads_with_qxfer): Adjust.
7692 (remote_memory_map): Adjust.
7693 (remote_traceframe_info): Adjust.
7694 (btrace_read_config): Adjust.
7695 (remote_read_btrace): Adjust.
7696 (remote_pid_to_exec_file): Adjust.
7697 * solib-aix.c (solib_aix_get_library_list): Adjust.
7698 * solib-dsbt.c (decode_loadmap): Don't free buf.
7699 (dsbt_get_initial_loadmaps): Adjust.
7700 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
7701 * solib-target.c (solib_target_current_sos): Adjust.
7702 * tracepoint.c (sdata_make_value): Adjust.
7703 * xml-support.c (xinclude_start_include): Adjust.
7704 (xml_fetch_content_from_file): Adjust.
7705 * xml-support.h (xml_fetch_another): Change return type.
7706 (xml_fetch_content_from_file): Change return type.
7707 * xml-syscall.c (xml_init_syscalls_info): Adjust.
7708 * xml-tdesc.c (file_read_description_xml): Adjust.
7709 (fetch_available_features_from_target): Change return type.
7710 (target_fetch_description_xml): Adjust.
7711 (target_read_description_xml): Adjust.
7713 2018-04-06 Tom Tromey <tom@tromey.com>
7715 * value.c (~value): Update.
7716 (struct value) <contents>: Now unique_xmalloc_ptr.
7717 (value_contents_bits_eq, allocate_value_contents)
7718 (value_contents_raw, value_contents_all_raw)
7719 (value_contents_for_printing, value_contents_for_printing_const)
7720 (set_value_enclosing_type): Update.
7722 2018-04-06 Tom Tromey <tom@tromey.com>
7724 * value.c (range_s): Remove typedef, VEC.
7725 (struct range): Add operator<.
7726 (range_lessthan): Remove.
7727 (ranges_contain): Change type.
7729 (struct value) <unavailable, optimized_out>: Now std::vector.
7730 (value_entirely_available)
7731 (value_entirely_covered_by_range_vector)
7732 (value_entirely_unavailable, value_entirely_optimized_out):
7734 (insert_into_bit_range_vector): Change argument type.
7735 (find_first_range_overlap): Likewise.
7736 (struct ranges_and_idx, value_contents_bits_eq)
7737 (require_not_optimized_out, require_available): Update.
7738 (ranges_copy_adjusted): Change argument types.
7739 (value_optimized_out, value_copy, value_fetch_lazy): Update.
7741 2018-04-06 Tom Tromey <tom@tromey.com>
7743 * value.c (~value): Update.
7744 (struct value) <parent>: Now a value_ref_ptr.
7745 (value_parent, set_value_parent, value_address, value_copy):
7748 2018-04-06 Tom Tromey <tom@tromey.com>
7750 * value.c (struct value): Add constructor, destructor, and member
7752 (allocate_value_lazy, value_decref): Update.
7754 2018-04-06 Tom Tromey <tom@tromey.com>
7756 * value.c (struct value) <released, next>: Remove.
7757 (all_values): Now a std::vector.
7758 (allocate_value_lazy): Update.
7759 (value_next): Remove.
7760 (value_mark, value_free_to_mark, release_value)
7761 (value_release_to_mark): Update.
7763 2018-04-06 Tom Tromey <tom@tromey.com>
7765 * value.h (fetch_subexp_value, value_release_to_mark): Update.
7766 (free_value_chain): Remove.
7767 * value.c (free_value_chain): Remove.
7768 (value_release_to_mark): Return a std::vector.
7769 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
7771 (check_condition): Update.
7772 * eval.c (fetch_subexp_value): Change "val_chain" to a
7774 * breakpoint.c (update_watchpoint): Update.
7775 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
7777 2018-04-06 Tom Tromey <tom@tromey.com>
7779 * value.h (free_all_values): Remove.
7780 * value.c (free_all_values): Remove.
7782 2018-04-06 Tom Tromey <tom@tromey.com>
7784 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
7785 (value_history_chain, value_history_count): Remove.
7786 (value_history): New global.
7787 (record_latest_value, access_value_history, show_values)
7788 (preserve_values): Update.
7790 2018-04-06 Tom Tromey <tom@tromey.com>
7792 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
7793 * varobj.c (varobj_set_display_format, varobj_set_value)
7794 (install_default_visualizer, construct_visualizer)
7795 (install_new_value, ~varobj, varobj_get_value_type)
7796 (my_value_of_variable, varobj_editable_p): Update.
7797 * c-varobj.c (c_describe_child, c_value_of_variable)
7798 (cplus_number_of_children, cplus_describe_child): Update.
7799 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
7800 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
7801 (ada_value_of_variable, ada_value_is_changeable_p): Update.
7803 2018-04-06 Tom Tromey <tom@tromey.com>
7805 * printcmd.c (last_examine_address): Change type to
7807 (do_examine, x_command): Update.
7809 2018-04-06 Tom Tromey <tom@tromey.com>
7811 * value.c (release_value): Update.
7812 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
7813 (struct bpstats) <val>: Now a value_ref_ptr.
7814 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7815 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7816 (~watchpoint, print_it_watchpoint, watch_command_1)
7817 (invalidate_bp_value_on_memory_change): Update.
7819 2018-04-06 Tom Tromey <tom@tromey.com>
7821 * varobj.c (varobj_clear_saved_item)
7822 (update_dynamic_varobj_children, install_new_value, ~varobj):
7824 * value.h (value_incref): Move declaration earlier.
7825 (value_decref): Rename from value_free.
7826 (struct value_ref_policy): New.
7827 (value_ref_ptr): New typedef.
7828 (struct value_deleter): Remove.
7829 (gdb_value_up): Remove typedef.
7830 (release_value): Change return type.
7831 (release_value_or_incref): Remove.
7832 * value.c (set_value_parent): Update.
7833 (value_incref): Change return type.
7834 (value_decref): Rename from value_free.
7835 (value_free_to_mark, free_all_values, free_value_chain): Update.
7836 (release_value): Return value_ref_ptr.
7837 (release_value_or_incref): Remove.
7838 (record_latest_value, set_internalvar, clear_internalvar):
7840 * stack.c (info_frame_command): Don't call value_free.
7841 * python/py-value.c (valpy_dealloc, valpy_new)
7842 (value_to_value_object): Update.
7843 * printcmd.c (do_examine): Update.
7844 * opencl-lang.c (lval_func_free_closure): Update.
7845 * mi/mi-main.c (register_changed_p): Don't call value_free.
7846 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
7847 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
7848 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
7850 * guile/scm-value.c (vlscm_free_value_smob)
7851 (vlscm_scm_from_value): Update.
7852 * frame.c (frame_register_unwind, frame_unwind_register_signed)
7853 (frame_unwind_register_unsigned, get_frame_register_bytes)
7854 (put_frame_register_bytes): Don't call value_free.
7855 * findvar.c (address_from_register): Don't call value_free.
7856 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
7857 * dwarf2loc.c (entry_data_value_free_closure)
7858 (value_of_dwarf_reg_entry, free_pieced_value_closure)
7859 (dwarf2_evaluate_loc_desc_full): Update.
7860 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7861 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7862 (~watchpoint, watch_command_1)
7863 (invalidate_bp_value_on_memory_change): Update.
7864 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
7866 2018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
7869 * warning.m4: Add -Wno-error=deprecated-register.
7870 * configure: Re-generate.
7872 2018-04-05 Tom Tromey <tom@tromey.com>
7874 * linespec.h: Remove include of "vec.h".
7876 2018-04-05 Tom Tromey <tom@tromey.com>
7878 * linespec.c (typep): Remove typedef.
7879 (find_methods, find_superclass_methods): Take a std::vector.
7880 (find_method): Use std::vector.
7882 2018-04-05 Tom Tromey <tom@tromey.com>
7884 * utils.c (compare_strings): Remove.
7885 * utils.h (compare_strings): Remove.
7886 * objc-lang.h (find_imps): Update.
7887 * objc-lang.c (find_methods): Take a std::vector.
7888 (uniquify_strings, find_imps): Likewise.
7889 * linespec.c (find_methods): Take a std::vector.
7890 (decode_objc): Use std::vector.
7891 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
7893 (find_method, find_function_symbols): Use std::vector.
7895 2018-04-05 Tom Tromey <tom@tromey.com>
7897 * completer.c (completion_tracker::completion_tracker): Remove
7899 (completion_tracker::discard_completions): Likewise.
7900 * breakpoint.c (ambiguous_names_p): Remove cast.
7901 * ada-lang.c (_initialize_ada_language): Remove cast.
7902 * utils.h (streq): Update.
7903 (streq_hash): Add new declaration.
7904 * utils.c (streq): Return bool.
7905 (streq_hash): New function.
7907 2018-04-05 Tom Tromey <tom@tromey.com>
7909 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
7910 Remove a string copy.
7912 2018-04-05 Tom Tromey <tom@tromey.com>
7914 * linespec.c (filter_results): Use std::vector.
7915 (decode_line_2, decode_line_full): Update.
7917 2018-04-05 Tom Tromey <tom@tromey.com>
7919 * linespec.c (canonical_to_fullform): Return std::string.
7920 (filter_results): Update.
7921 (struct decode_line_2_item): Add constructor.
7922 <fullform, displayform>: Now std::string.
7923 (decode_line_2_compare_items): Now a std::sort comparator.
7924 (decode_line_2): Update.
7926 2018-04-05 Tom Tromey <tom@tromey.com>
7928 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
7929 (unexpected_linespec_error): Update.
7930 (linespec_parse_basic, parse_linespec): Update.
7932 2018-04-05 Tom Tromey <tom@tromey.com>
7934 * linespec.c (linespec_parse_basic): Reindent.
7936 2018-04-05 Tom Tromey <tom@tromey.com>
7938 * minsyms.h (iterate_over_minimal_symbols): Update.
7939 * minsyms.c (iterate_over_minimal_symbols): Take a
7941 * linespec.c (struct collect_minsyms): Remove.
7942 (compare_msyms): Now a std::sort comparator.
7943 (add_minsym): Add parameters.
7944 (search_minsyms_for_name): Update. Use std::vector.
7946 2018-04-03 Tom Tromey <tom@tromey.com>
7948 * mipsread.c (read_alphacoff_dynamic_symtab): Use
7951 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
7953 * MAINTAINERS (Write After Approval): Add Weimin Pan.
7955 2018-04-02 Weimin Pan <weimin.pan@oracle.com>
7958 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
7959 printing static type.
7961 2018-04-01 Tom Tromey <tom@tromey.com>
7963 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
7964 (rs6000_xfer_shared_libraries): Update.
7966 2018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
7968 * common/gdb_vecs.h (char_ptr): Remove.
7969 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
7971 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
7973 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
7975 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
7977 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
7979 * tracepoint.h (struct uploaded_tp): Initialize fields.
7980 <actions, step_actions, cmd_strings>: Change type to
7981 std::vector<char *>.
7982 * tracepoint.c (get_uploaded_tp): Allocate with new.
7983 (free_uploaded_tps): Free with delete.
7984 (parse_tracepoint_definition): Adjust to std::vector change.
7985 * breakpoint.c (read_uploaded_action): Likewise.
7986 (create_tracepoint_from_upload): Likewise.
7987 * ctf.c (ctf_write_uploaded_tp): Likewise.
7988 (SET_ARRAY_FIELD): Likewise.
7989 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
7991 2018-03-30 Tom Tromey <tom@tromey.com>
7993 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
7995 (svr4_keep_data_in_core): Update.
7996 (svr4_read_so_list): Update.
7998 2018-03-30 Tom Tromey <tom@tromey.com>
8000 * windows-nat.c (handle_output_debug_string, handle_exception):
8002 * target.h (target_read_string): Update.
8003 * target.c (target_read_string): Change "string" to
8005 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8007 * solib-frv.c (frv_current_sos): Update.
8008 * solib-dsbt.c (dsbt_current_sos): Update.
8009 * solib-darwin.c (darwin_current_sos): Update.
8010 * linux-thread-db.c (inferior_has_bug): Update.
8011 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
8012 Update. Remove alloca.
8013 * ada-lang.c (ada_main_name): Update.
8015 2018-03-30 Tom Tromey <tom@tromey.com>
8017 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
8018 (struct dwo_file_deleter): New.
8019 (dwo_file_up): New typedef.
8020 (open_and_init_dwo_file): Use dwo_file_up.
8021 (free_dwo_file_cleanup): Remove.
8023 2018-03-30 Tom Tromey <tom@tromey.com>
8025 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
8026 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
8028 2018-03-30 Tom Tromey <tom@tromey.com>
8030 * dwarf2read.c (class free_cached_comp_units): New class.
8031 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
8032 (free_cached_comp_units): Remove function.
8034 2018-03-30 Tom Tromey <tom@tromey.com>
8036 * utils.h (make_cleanup_unpush_target): Remove.
8037 * inf-ptrace.c (struct target_unpusher): New.
8038 (target_unpush_up) New typedef.
8039 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
8041 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
8043 2018-03-27 Tom Tromey <tom@tromey.com>
8045 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
8047 2018-03-27 Pedro Alves <palves@redhat.com>
8048 Tom Tromey <tom@tromey.com>
8050 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
8051 destructor. Now a class.
8052 (gdb_readline_wrapper_cleanup): Remove function.
8053 (gdb_readline_wrapper): Remove cleanups.
8055 2018-03-27 Tom Tromey <tom@tromey.com>
8057 * typeprint.h (struct type_print_options) <local_typedefs,
8058 global_typedefs>: Remove "struct" keyword.
8059 (class typedef_hash_table): New class.
8060 (recursively_update_typedef_hash, add_template_parameters)
8061 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
8062 (find_typedef_in_hash): Don't declare.
8063 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
8064 (typedef_hash_table::recursively_update): Rename from
8065 recursively_update_typedef_hash. Now a member.
8066 (typedef_hash_table::add_template_parameters): Rename from
8067 add_template_parameters. Now a member.
8068 (typedef_hash_table::typedef_hash_table): Now a constructor;
8069 rename from create_typedef_hash.
8070 (typedef_hash_table::~typedef_hash_table): Now a destructor;
8071 rename from free_typedef_hash.
8072 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
8073 (do_free_global_table): Remove.
8074 (typedef_hash_table::typedef_hash_table): New constructor; renamed
8075 from copy_type_recursive.
8076 (create_global_typedef_table): Remove.
8077 (typedef_hash_table::find_global_typedef): Now a member of
8079 (typedef_hash_table::find_typedef): Rename from
8080 find_typedef_in_hash; now a member.
8081 (whatis_exp): Update.
8082 * extension.h (struct ext_lang_type_printers): Add constructor and
8084 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
8086 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
8087 Now a constructor; rename from start_ext_lang_type_printers.
8088 (ext_lang_type_printers): Now a destructor; rename from
8089 free_ext_lang_type_printers.
8090 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
8092 (c_type_print_base_struct_union): Update. Remove cleanups.
8094 2018-03-27 Tom Tromey <tom@tromey.com>
8096 * dwarf-index-write.c: Include <cmath>.
8098 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8100 * NEWS: Add entry describing new "set|show varsize-limit" command.
8101 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
8103 * printcmd.c (_initialize_printcmd): Add "set var" alias of
8106 2018-03-27 Simon Marchi <simon.marchi@ericsson.com>
8108 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
8110 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
8111 * dwarf-index-common.c: New file.
8112 * dwarf-index-common.h: New file.
8113 * dwarf-index-write.c: New file.
8114 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
8115 (struct dwarf2_section_info): Move from here.
8116 (dwarf2_section_info_def): Likewise.
8117 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
8118 (offset_type): Likewise.
8119 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
8120 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
8121 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
8122 (byte_swap): Likewise.
8123 (MAYBE_SWAP): Likewise.
8124 (dwarf2_per_cu_ptr): Likewise.
8125 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
8126 (struct tu_stats): Likewise.
8127 (struct dwarf2_per_objfile): Likewise.
8128 (struct dwarf2_per_cu_data): Likewise.
8129 (struct signatured_type): Likewise.
8130 (sig_type_ptr): Likewise.
8131 (DEF_VEC_P (sig_type_ptr)): Likewise.
8132 (INDEX4_SUFFIX): Likewise.
8133 (INDEX5_SUFFIX): Likewise.
8134 (DEBUG_STR_SUFFIX): Likewise.
8135 (dwarf2_read_section): Make non-static.
8136 (mapped_index_string_hash): Move from here.
8137 (dwarf5_djb_hash): Likewise.
8138 (file_write): Likewise.
8139 (class data_buf): Likewise.
8140 (struct symtab_index_entry): Likewise.
8141 (struct mapped_symtab): Likewise.
8142 (find_slot): Likewise.
8143 (hash_expand): Likewise.
8144 (add_index_entry): Likewise.
8145 (uniquify_cu_indices): Likewise.
8146 (class c_str_view): Likewise.
8147 (class c_str_view_hasher): Likewise.
8148 (class vector_hasher): Likewise.
8149 (write_hash_table): Likewise.
8150 (psym_index_map): Likewise.
8151 (struct addrmap_index_data): Likewise.
8152 (add_address_entry): Likewise.
8153 (add_address_entry_worker): Likewise.
8154 (write_address_map): Likewise.
8155 (symbol_kind): Likewise.
8156 (write_psymbols): Likewise.
8157 (struct signatured_type_index_data): Likewise.
8158 (write_one_signatured_type): Likewise.
8159 (recursively_count_psymbols): Likewise.
8160 (recursively_write_psymbols): Likewise.
8161 (class debug_names): Likewise.
8162 (check_dwarf64_offsets): Likewise.
8163 (psyms_seen_size): Likewise.
8164 (write_gdbindex): Likewise.
8165 (write_debug_names): Likewise.
8166 (assert_file_size): Likewise.
8167 (write_psymtabs_to_index): Likewise.
8168 (save_gdb_index_command): Likewise.
8169 (_initialize_dwarf2_read): Don't register the "save gdb-index"
8171 * dwarf2read.h: New file.
8173 2018-03-27 Joel Brobecker <brobecker@adacore.com>
8176 * dwarf2read.c (dwarf2_physname): Do not return the demangled
8177 symbol name if the CU's language stores symbol names in linkage
8179 * language.h (struct language_defn)
8180 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
8181 all instances of this struct.
8183 2018-03-26 Tom Tromey <tom@tromey.com>
8185 * stack.c (backtrace_command_1): Remove verbose code.
8187 2018-03-26 Tom Tromey <tom@tromey.com>
8189 * python/py-framefilter.c (py_print_type): Don't catch
8190 exceptions. Return void.
8191 (py_print_value): Likewise.
8192 (py_print_single_arg): Likewise.
8193 (enumerate_args): Don't catch exceptions.
8194 (py_print_args): Likewise.
8195 (py_print_frame): Likewise.
8196 (gdbpy_apply_frame_filter): Catch exceptions here.
8198 2018-03-26 Tom Tromey <tom@tromey.com>
8200 * stack.c (_initialize_stack): Remove trailing newlines from help
8201 text. Add "Usage" line to "backtrace" help.
8203 2018-03-26 Tom Tromey <tom@tromey.com>
8206 * python/py-framefilter.c (py_print_args): Call wrap_hint.
8208 2018-03-26 Tom Tromey <tom@tromey.com>
8210 * python/py-framefilter.c (py_print_single_arg): Return
8211 EXT_LANG_BT_ERROR from catch.
8213 2018-03-26 Tom Tromey <tom@tromey.com>
8216 * stack.c (backtrace_command_1): Move some code into no-filters
8219 2018-03-26 Tom Tromey <tom@tromey.com>
8221 * python/py-framefilter.c (throw_quit_or_print_exception): New
8223 (gdbpy_apply_frame_filter): Use it.
8225 2018-03-26 Tom Tromey <tom@tromey.com>
8228 * python/py-framefilter.c (py_print_type, py_print_value)
8229 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8232 2018-03-26 Tom Tromey <tom@tromey.com>
8234 * python/py-framefilter.c (enumerate_args): Use
8235 gdb::unique_xmalloc_ptr.
8237 2018-03-26 Tom Tromey <tom@tromey.com>
8239 * python/py-framefilter.c (py_print_frame): Return
8241 (gdbpy_apply_frame_filter): Update comment.
8242 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8244 <EXT_LANG_BT_NO_FILTERS>: Change value.
8246 2018-03-26 Tom Tromey <tom@tromey.com>
8249 * stack.c (backtrace_command): Parse "hide" argument.
8250 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8251 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8254 2018-03-26 Tom Tromey <tom@tromey.com>
8256 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8258 (backtrace_command): Remove "fulltrace", add "flags".
8260 2018-03-26 Tom Tromey <tom@tromey.com>
8262 * stack.c (backtrace_command): Rewrite command line parsing.
8264 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8266 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8268 2018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8270 * filename-seen-cache.h: Add include guard.
8272 2018-03-26 Keith Seitz <keiths@redhat.com>
8274 * symfile.c (place_section): Remove "struct" from section_addr_info
8276 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8277 "struct" keyword from section_addr_info.
8279 2018-03-26 Alan Hayward <alan.hayward@arm.com>
8281 * regformats/regdef.h (reg): Add constructors.
8283 2018-03-25 Pedro Alves <palves@redhat.com>
8285 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8286 if then/else bodies in var_func_name extraction.
8288 2018-03-23 Weimin Pan <weimin.pan@oracle.com>
8290 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8291 lookup_minimal_symbol() to find symbol entry.
8292 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8294 2018-03-23 Keith Seitz <keiths@redhat.com>
8297 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8298 nested type definitions for C++, too.
8300 2018-03-23 Tom Tromey <tom@tromey.com>
8302 * machoread.c (struct oso_el): Add a constructor. Don't define as
8304 (macho_register_oso): Remove.
8305 (macho_symtab_read): Take a std::vector.
8306 (oso_el_compare_name): Now a std::sort comparator.
8307 (macho_symfile_read_all_oso): Take a std::vector.
8308 (macho_symfile_read): Use std::vector. Remove cleanups.
8310 2018-03-22 Tom Tromey <tom@tromey.com>
8312 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
8313 (record_full_goto_bookmark): Use std::string.
8315 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8318 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
8321 2018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8323 * rs6000-tdep.c (store_insn_p): New function.
8324 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
8325 and cr_reg to their unshifted values. Use store_insn_p to
8326 match LR saves using either R1 or fdata->alloca_reg. Use
8327 store_insn_p to match CR saves. Set alloca_reg_offset
8328 when alloca_reg and framep are set. Remove lr_reg shift
8329 when assigning to fdata->lr_register.
8331 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
8333 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
8334 command line args instead of emitting a warning.
8336 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8338 * tracepoint.h (struct static_tracepoint_marker): Initialize
8339 fields, define default constructor, move constructor and move
8340 assignment, disable the rest.
8341 <str_id, extra>: Make std::string.
8342 (release_static_tracepoint_marker): Remove.
8343 (free_current_marker): Remove.
8344 * tracepoint.c (free_current_marker): Remove.
8345 (parse_static_tracepoint_marker_definition): Adjust to
8346 std::string, use new hex2str overload.
8347 (release_static_tracepoint_marker): Remove.
8348 (print_one_static_tracepoint_marker): Get marker by reference
8349 and adjust to std::string.
8350 (info_static_tracepoint_markers_command): Adjust to std::vector
8352 * target.h (static_tracepoint_marker_p): Remove typedef.
8353 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
8354 (struct target_ops) <to_static_tracepoint_marker_at>: Return
8356 <to_static_tracepoint_markers_by_strid>: Return std::vector.
8358 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
8359 (target_debug_print_std_vector_static_tracepoint_marker): New.
8360 (target_debug_print_struct_static_tracepoint_marker_p): Rename
8362 (target_debug_print_static_tracepoint_marker_p): ... this.
8363 * target-delegates.c: Re-generate.
8364 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
8366 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
8367 (decode_static_tracepoint_spec): Adjust to std::vector.
8368 (tracepoint_print_one_detail): Adjust to std::string.
8369 (strace_marker_decode_location): Adjust to std::string.
8370 (update_static_tracepoint): Adjust to std::string, remove call
8371 to release_static_tracepoint_marker.
8372 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
8373 Adjust to std::vector.
8374 * remote.c (remote_static_tracepoint_marker_at): Return bool.
8375 (remote_static_tracepoint_markers_by_strid): Adjust to
8377 * common/rsp-low.h (hex2str): New overload with explicit count
8379 * common/rsp-low.c (hex2str): New overload with explicit count
8381 * unittests/rsp-low-selftests.c (test_hex2str): New function.
8382 (_initialize_rsp_low_selftests): Add test_hex2str test.
8383 * unittests/tracepoint-selftests.c
8384 (test_parse_static_tracepoint_marker_definition): Adjust to
8387 2018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8389 * tracepoint.c (parse_static_tracepoint_marker_definition):
8390 Consider case where the definition is followed by more
8392 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8393 tracepoint-selftests.c.
8394 * unittests/tracepoint-selftests.c: New.
8396 2018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8398 * MAINTAINERS (Write After Approval): Add Pedro Franco de
8401 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8403 * symtab.c (find_pc_sect_line): fixed indentation.
8405 2018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8407 * symtab.c (find_pc_sect_line): now uses binary search.
8409 2018-03-19 Tom Tromey <tom@tromey.com>
8411 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
8414 2018-03-19 Pedro Alves <palves@redhat.com>
8415 Tom Tromey <tom@tromey.com>
8417 * unittests/observable-selftests.c: New file.
8418 * common/observable.h: New file.
8419 * observable.h: New file.
8420 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
8421 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
8422 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
8423 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
8424 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
8425 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
8426 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
8427 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
8428 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
8429 python/py-breakpoint.c, python/py-finishbreakpoint.c,
8430 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
8431 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
8432 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
8433 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
8434 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
8435 tui/tui-interp.c, valops.c: Update all users.
8436 * tui/tui-hooks.c (tui_bp_created_observer)
8437 (tui_bp_deleted_observer, tui_bp_modified_observer)
8438 (tui_inferior_exit_observer, tui_before_prompt_observer)
8439 (tui_normal_stop_observer, tui_register_changed_observer):
8441 (tui_observers_token): New global.
8442 (attach_or_detach, tui_attach_detach_observers): New functions.
8443 (tui_install_hooks, tui_remove_hooks): Use
8444 tui_attach_detach_observers.
8445 * record-btrace.c (record_btrace_thread_observer): Remove.
8446 (record_btrace_thread_observer_token): New global.
8447 * observer.sh: Remove.
8448 * observer.c: Rename to observable.c.
8449 * observable.c (namespace gdb_observers): Define new objects.
8450 (observer_debug): Move into gdb_observers namespace.
8451 (struct observer, struct observer_list, xalloc_observer_list_node)
8452 (xfree_observer_list_node, generic_observer_attach)
8453 (generic_observer_detach, generic_observer_notify): Remove.
8454 (_initialize_observer): Update.
8455 Don't include observer.inc.
8456 * Makefile.in (generated_files): Remove observer.h, observer.inc.
8457 (clean mostlyclean): Likewise.
8458 (observer.h, observer.inc): Remove targets.
8459 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
8460 (COMMON_SFILES): Use observable.c, not observer.c.
8461 * .gitignore: Remove observer.h.
8463 2018-03-18 Tom Tromey <tom@tromey.com>
8465 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
8467 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
8469 2018-03-17 Tom Tromey <tom@tromey.com>
8471 * auto-load.c (auto_load_objfile_script_1): Use std::string.
8473 2018-03-17 Tom Tromey <tom@tromey.com>
8475 * target.c (class scoped_target_fd): New.
8476 (target_fileio_close_cleanup): Remove.
8477 (target_fileio_read_alloc_1): Use scoped_target_fd.
8479 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
8481 * silent-rules.mk: New.
8482 * Makefile.in: Include silent-rules.mk
8483 (srcdir, VPATH, top_srcdir): Move up.
8484 (COMPILE): Add ECHO_CXX.
8485 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
8486 (init.c): Add ECHO_INIT_C.
8487 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
8488 (version.c): Add ECHO_GEN.
8489 (printcmd.o): Add ECHO_CXX.
8490 (target-float.o): Add ECHO_CXX.
8491 (ada-exp.o): Add ECHO_CXX.
8492 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
8493 (insight$(EXEEXT)): Add ECHO_CXXLD.
8494 * gnulib/configure.ac: Add AM_SILENT_RULES.
8495 * gnulib/aclocal.m4: Re-generate.
8496 * gnulib/configure: Re-generate.
8497 * gnulib/import/Makefile.in: Re-generate.
8499 2018-03-16 Tom Tromey <tom@tromey.com>
8501 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
8502 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
8503 * utils.c (do_free_section_addr_info)
8504 (make_cleanup_free_section_addr_info): Remove.
8505 * symfile.h (struct other_sections): Add constructor.
8506 (struct section_addr_info): Remove.
8507 (section_addr_info): New typedef.
8508 (struct sym_fns) <sym_offsets>: Change type of parameter.
8509 (build_section_addr_info_from_objfile)
8510 (relative_addr_info_to_section_offsets, addr_info_make_relative)
8511 (default_symfile_offsets, symbol_file_add)
8512 (symbol_file_add_from_bfd)
8513 (build_section_addr_info_from_section_table): Update.
8514 (alloc_section_addr_info, free_section_addr_info): Don't declare.
8515 * symfile.c (alloc_section_addr_info): Remove.
8516 (build_section_addr_info_from_section_table): Change return type.
8518 (build_section_addr_info_from_bfd)
8519 (build_section_addr_info_from_objfile): Likewise.
8520 (free_section_addr_info): Remove.
8521 (relative_addr_info_to_section_offsets): Change type of "addrs".
8522 (addrs_section_compar): Now a std::sort comparator.
8523 (addrs_section_sort): Change return type.
8524 (addr_info_make_relative): Change type of "addrs". Update.
8525 (default_symfile_offsets, syms_from_objfile_1)
8526 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
8527 (symbol_file_add_separate): Update.
8528 (symbol_file_add): Change type of "addrs". Update.
8529 (add_symbol_file_command): Update. Remove cleanups.
8530 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
8532 * symfile-debug.c (debug_sym_offsets): Change type of "info".
8533 * solib.c (solib_read_symbols): Update.
8534 * objfiles.c (objfile_relocate): Update. Remove cleanups.
8535 * machoread.c (macho_symfile_offsets): Update.
8536 * jit.c (jit_bfd_try_read_symtab): Update.
8538 2018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
8540 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8541 unittests/utils-selftests.c.
8542 * unittests/utils-selftests.c: New file.
8544 2018-03-14 Tom Tromey <tom@tromey.com>
8547 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
8550 2018-03-14 Tom Tromey <tom@tromey.com>
8553 * printcmd.c (printf_pointer): Allow "-" in format.
8555 2018-03-14 Tom Tromey <tom@tromey.com>
8557 * printcmd.c (_initialize_printcmd): Add usage to printf.
8559 2018-03-14 Yao Qi <qiyao@sourceware.org>
8561 * MAINTAINERS: Update my email address.
8563 2018-03-13 Tom Tromey <tom@tromey.com>
8565 * machoread.c (macho_check_dsym): Change filenamep to a
8567 (macho_symfile_read): Update.
8568 * symfile.c (load_command): Use std::string.
8570 2018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
8572 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
8573 to error message string.
8574 (riscv_register_name): Use xsnprintf instead of sprintf.
8575 (riscv_insn::fetch_instruction): Use gdb_assert instead of
8577 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
8579 (riscv_push_dummy_call): Likewise.
8581 2018-03-12 Tom Tromey <tom@tromey.com>
8583 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
8584 Use gdb::byte_vector.
8585 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
8587 2018-03-12 Yao Qi <yao.qi@linaro.org>
8589 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
8590 parameter type to readable_regcache.
8591 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
8594 2018-03-11 Tom Tromey <tom@tromey.com>
8596 * dwarf2read.c (struct nextfield): Add initializers.
8597 (struct nextfnfield): Remove.
8598 (struct fnfieldlist): Add initializers. Remove "length" and
8599 "head", use std::vector.
8600 (struct decl_field_list): Remove.
8601 (struct field_info): Add initializers.
8602 <fields, baseclasses>: Now std::vector.
8603 <nbaseclasses, nfnfields, typedef_field_list_count,
8604 nested_types_list_count>: Remove.
8605 (dwarf2_add_field, dwarf2_add_type_defn)
8606 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
8607 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
8608 (process_structure_scope): Update.
8610 2018-03-11 Tom Tromey <tom@tromey.com>
8612 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
8613 for use by std::sort.
8614 (build_type_psymtabs_1): Use std::vector.
8616 2018-03-09 Eli Zaretskii <eliz@gnu.org>
8618 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
8619 and LIBMPFR in the printed configuration.
8621 2018-03-08 Tom Tromey <tom@tromey.com>
8623 * source.c (get_filename_and_charpos): Use scoped_fd.
8624 * nto-procfs.c (procfs_open_1): Use scoped_fd.
8625 (procfs_pidlist): Likewise.
8626 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
8627 (iterate_over_mappings): Likewise.
8629 2018-03-08 Tom Tromey <tom@tromey.com>
8631 * infcall.c (struct call_return_meta_info)
8632 <stack_temporaries_enabled>: Remove.
8633 (get_call_return_value, call_function_by_hand_dummy): Update.
8634 * thread.c (disable_thread_stack_temporaries): Remove.
8635 (enable_thread_stack_temporaries): Remove.
8636 (thread_stack_temporaries_enabled_p): Return bool.
8637 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
8638 (get_last_thread_stack_temporary): Update.
8639 * eval.c (evaluate_subexp): Update.
8640 * gdbthread.h (class enable_thread_stack_temporaries): Now a
8641 class, not a function.
8642 (value_ptr, value_vec): Remove typedefs.
8643 (class thread_info) <stack_temporaries_enabled>: Now bool.
8644 <stack_temporaries>: Now a std::vector.
8645 (thread_stack_temporaries_enabled_p)
8646 (value_in_thread_stack_temporaries): Return bool.
8648 2018-03-08 Simon Marchi <simon.marchi@ericsson.com>
8650 * remote.c (putpkt_binary): Fix omitted bytes reporting.
8651 (getpkt_or_notif_sane_1): Likewise.
8653 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8655 * build-id.c (build_id_to_debug_bfd): Use std::string.
8657 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8659 * build-id.c (find_separate_debug_file_by_buildid): Return
8661 * build-id.h (find_separate_debug_file_by_buildid): Return
8663 * coffread.c (coff_symfile_read): Adjust to std::string.
8664 * elfread.c (elf_symfile_read): Adjust to std::string.
8665 * symfile.c (separate_debug_file_exists): Change parameter to
8667 (find_separate_debug_file): Return std::string.
8668 (find_separate_debug_file_by_debuglink): Return std::string.
8669 * symfile.h (find_separate_debug_file_by_debuglink): Return
8672 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8674 * common/xml-utils.c (xml_escape_text): Move code to...
8675 (xml_escape_text_append): ... this new function.
8676 * common/xml-utils.h (xml_escape_text_append): New declaration.
8677 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
8679 (_initialize_xml_utils): register test_xml_escape_text_append as
8682 2018-03-07 Alan Hayward <alan.hayward@arm.com>
8684 * defs.h: Remove MAX_REGISTER_SIZE.
8685 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
8687 * python/py-unwind.c (pyuw_sniffer): Likewise.
8689 2018-03-07 Tom Tromey <tom@tromey.com>
8691 * linux-tdep.c (linux_info_proc): Update.
8692 * target.h (struct target_ops) <to_fileio_readlink>: Return
8694 (target_fileio_readlink): Return optional<string>.
8695 * remote.c (remote_hostio_readlink): Return optional<string>.
8696 * inf-child.c (inf_child_fileio_readlink): Return
8698 * target.c (target_fileio_readlink): Return optional<string>.
8700 2018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
8702 * regcache.c (cooked_read_test): Add riscv to the list of
8703 architectures that have a save_reggroup.
8705 2018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
8707 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
8708 value is not a dynamic class object.
8710 2018-03-06 Tom Tromey <tom@tromey.com>
8712 * rust-exp.y: Formatting fixes.
8714 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8716 * riscv-tdep.c (riscv_register_name): Remove target description
8718 (riscv_gdbarch_init): Remove target description check.
8720 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8722 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
8724 * riscv-tdep.h: Likewise.
8726 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8728 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
8729 (riscv_pseudo_register_write): Delete.
8730 (riscv_gdbarch_init): Remove all use of pseudo registers.
8732 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8734 * record-btrace.c (btrace_print_lines): Replace cleanup
8735 parameter with RAII equivalents.
8736 (btrace_insn_history): Replace cleanup with RAII equivalents.
8737 * ui-out.h (make_cleanup_ui_out_list_begin_end,
8738 make_cleanup_ui_out_tuple_begin_end): Remove.
8739 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
8740 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
8741 make_cleanup_ui_out_list_begin_end): Remove.
8743 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8745 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
8746 parameter types to std::vector. Use bool.
8747 (record_btrace_wait): Replace VEC(tp_t) with
8748 std::vector<thread_info *>.
8749 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
8751 2018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8753 * record-btrace.c (record_btrace_disable_callback): Remove.
8754 (struct scoped_btrace_disable): New.
8755 (record_btrace_open): Use scoped_btrace_disable.
8757 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8759 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
8760 reading values from registers.
8762 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8764 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
8767 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8769 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
8770 change parameter type. Use GDB's print functions, and use
8771 core_addr_to_string where appropriate.
8772 (riscv_push_dummy_call): Use core_addr_to_string where
8773 appropriate, update call to riscv_print_arg_location, and reindent
8775 (riscv_return_value): Update call to riscv_print_arg_location.
8777 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8778 Tim Newsome <tim@sifive.com>
8779 Albert Ou <a0u@eecs.berkeley.edu>
8780 Darius Rad <darius@bluespec.com>
8782 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
8783 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
8784 (ALLDEPFILES): Add riscv-tdep.c
8785 * configure.tgt: Add riscv support.
8786 * riscv-tdep.c: New file.
8787 * riscv-tdep.h: New file.
8788 * NEWS: Mention new target.
8789 * MAINTAINERS: Add entry for riscv.
8791 2018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8793 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
8794 fields within aggregates.
8796 2018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
8798 * record-btrace.c (btrace_print_lines): Change type of flags to
8799 gdb_disassembly_flags.
8801 2018-03-04 John Baldwin <jhb@FreeBSD.org>
8803 * fbsd-nat.c: Include "inf-ptrace.h".
8804 (USE_SIGTRAP_SIGINFO): Conditionally define.
8805 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
8806 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
8807 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
8809 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
8811 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
8813 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
8814 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
8815 "supports_stopped_by_hw_breakpoint" target methods.
8817 2018-03-04 John Baldwin <jhb@FreeBSD.org>
8819 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
8820 * fbsd-nat.c (debug_fbsd_nat): New variable.
8821 (show_fbsd_nat_debug): New function.
8822 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
8823 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
8825 2018-03-04 John Baldwin <jhb@FreeBSD.org>
8827 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
8828 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
8830 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
8831 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
8834 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8836 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
8837 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
8839 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8841 * charset.c (struct charset_vector): New.
8842 (charsets): Change type to charset_vector.
8843 (find_charset_names): Adjust.
8845 (_initialize_charset): Adjust.
8847 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8849 * progspace.h (struct program_space) <deleted_solibs>: Change
8850 type to std::vector<std::string>.
8851 * progspace.c (clear_program_space_solib_cache): Adjust.
8852 * breakpoint.c (print_solib_event): Adjust.
8853 (check_status_catch_solib): Adjust.
8854 * solib.c (update_solib_list): Adjust.
8855 * ui-out.h (class ui_out) <field_string>: New overload.
8856 * ui-out.c (ui_out::field_string): New overload.
8858 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8860 * progspace.h (struct program_space): Add constructor and
8861 destructor, initialize fields.
8862 (add_program_space): Remove.
8863 * progspace.c (add_program_space): Rename to...
8864 (program_space::program_space): ... this.
8865 (release_program_space): Rename to...
8866 (program_space::~program_space): ... this.
8867 (delete_program_space): Use delete to delete program_space.
8868 (initialize_progspace): Use new to allocate program_space.
8869 * inferior.c (add_inferior_with_spaces): Likewise.
8870 (clone_inferior_command): Likewise.
8871 * infrun.c (follow_fork_inferior): Likewise.
8872 (handle_vfork_child_exec_or_exit): Likewise.
8874 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8876 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
8877 (delim_string_to_char_ptr_vec): Return std::vector of
8878 gdb::unique_xmalloc_ptr.
8879 (dirnames_to_char_ptr_vec_append): Take std::vector of
8880 gdb::unique_xmalloc_ptr.
8881 (dirnames_to_char_ptr_vec): Return std::vector of
8882 gdb::unique_xmalloc_ptr.
8883 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
8884 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
8885 (delim_string_to_char_ptr_vec): Return an std::vector of
8886 gdb::unique_xmalloc_ptr, adjust the code.
8887 (dirnames_to_char_ptr_vec_append): Take an std::vector of
8888 gdb::unique_xmalloc_ptr, adjust the code.
8889 (dirnames_to_char_ptr_vec): Return an std::vector of
8890 gdb::unique_xmalloc_ptr, adjust the code.
8891 * auto-load.c (auto_load_safe_path_vec): Change type to
8892 std::vector of gdb::unique_xmalloc_ptr.
8893 (auto_load_expand_dir_vars): Return an std::vector of
8894 gdb::unique_xmalloc_ptr, adjust the code.
8895 (auto_load_safe_path_vec_update): Adjust.
8896 (filename_is_in_auto_load_safe_path_vec): Adjust.
8897 (auto_load_objfile_script_1): Adjust.
8898 * build-id.c (build_id_to_debug_bfd): Adjust.
8899 * linux-thread-db.c (thread_db_load_search): Adjust.
8900 * source.c (add_path): Adjust.
8902 * symfile.c (find_separate_debug_file): Adjust.
8903 * utils.c (do_free_char_ptr_vec): Remove.
8904 (make_cleanup_free_char_ptr_vec): Remove.
8906 2018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
8909 * common/pathstuff.c: Conditionally include "<windows.h>".
8911 2018-03-01 Georg Sauthoff <mail@georg.so>
8914 * gcore.in: Quote variables and switch interpreter to bash.
8916 2018-03-01 Tom Tromey <tom@tromey.com>
8918 * dwarf2read.c (alloc_discriminant_info): Fix default_index
8919 assertion. Add assertion for discriminant_index.
8920 (quirk_rust_enum): Use correct base type name in univariant case.
8922 2018-03-01 Simon Marchi <simon.marchi@ericsson.com>
8924 * record.c (get_call_history_modifiers): Return a
8926 (cmd_record_call_history): Adjust.
8927 * record-btrace.c (record_btrace_call_history): Adjust.
8928 (record_btrace_call_history_range): Adjust.
8929 (record_btrace_call_history_from): Adjust.
8930 * target-debug.h (target_debug_print_record_print_flags): New.
8931 * target-delegates.c: Re-generate.
8932 * target.c (target_call_history): Change flags type.
8933 (target_call_history_from): Likewise.
8934 (target_call_history_range): Likewise.
8935 * target.h (struct target_ops) <target_call_history>: Likewise.
8936 (target_call_history_from): Likewise.
8937 (target_call_history_range): Likewise.
8939 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
8940 Simon Marchi <simon.marchi@polymtl.ca>
8942 * common/common-utils.c: Include "sys/stat.h".
8943 (is_regular_file): Move here from "source.c"; change return
8945 * common/common-utils.h (is_regular_file): New prototype.
8946 * common/pathstuff.c (contains_dir_separator): New function.
8947 * common/pathstuff.h (contains_dir_separator): New prototype.
8948 * source.c: Don't include "sys/stat.h".
8949 (is_regular_file): Move to "common/common-utils.c".
8951 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
8953 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
8954 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
8955 * auto-load.c: Include "common/pathstuff.h".
8956 * common/common-def.h (current_directory): Move here.
8957 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
8959 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
8961 * common/pathstuff.c: New file.
8962 * common/pathstuff.h: New file.
8963 * compile/compile.c: Include "common/pathstuff.h".
8964 * defs.h (current_directory): Move to "common/common-defs.h".
8965 * dwarf2read.c: Include "common/pathstuff.h".
8967 * guile/scm-safe-call.c: Likewise.
8968 * linux-thread-db.c: Likewise.
8970 * nto-tdep.c: Likewise.
8971 * objfiles.c: Likewise.
8972 * source.c: Likewise.
8973 * symtab.c: Likewise.
8974 * utils.c: Include "common/pathstuff.h".
8975 (gdb_realpath): Move to "common/pathstuff.c".
8976 (gdb_realpath_keepfile): Likewise.
8977 (gdb_abspath): Likewise.
8978 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
8979 (gdb_realpath_keepfile): Likewise.
8980 (gdb_abspath): Likewise.
8982 2018-02-28 John Baldwin <jhb@FreeBSD.org>
8984 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
8985 wildcard process pid for super_resume for kernels with a
8988 2018-02-27 Phil Muldoon <pmuldoon@redhat.com>
8990 * compile/compile.c (get_args): Add additional comments
8991 explaining function.
8993 2018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
8994 Tom Tromey <tom@tromey.com>
8996 * target.h (memory_write_request_s): Remove typedef. Don't define
8998 (target_write_memory_blocks): Change argument to std::vector.
8999 (struct memory_write_request): Add constructor.
9000 * target-memory.c (compare_block_starting_address): Return bool.
9001 Change argument types.
9002 (claim_memory): Change arguments to use std::vector.
9003 (split_regular_and_flash_blocks, blocks_to_erase)
9004 (compute_garbled_blocks): Likewise.
9005 (cleanup_request_data, cleanup_write_requests_vector): Remove.
9006 (target_write_memory_blocks): Change argument to std::vector.
9007 * symfile.c (struct load_section_data): Add constructor and
9008 destructor. Use std::vector for "requests".
9009 (struct load_progress_data): Add initializers.
9010 (load_section_callback): Update. Use "new".
9011 (clear_memory_write_data): Remove.
9012 (generic_load): Update.
9014 2018-02-27 Alan Hayward <alan.hayward@arm.com>
9016 * arch/aarch64.h: Use common/tdesc.h.
9018 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9020 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
9021 architecture with a 64-bit ABI.
9023 2018-02-26 Maciej W. Rozycki <macro@mips.com>
9025 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
9026 ahead of target description loading.
9028 2018-02-26 Tom Tromey <tom@tromey.com>
9030 * stack.c (backtrace_command_1): Update.
9031 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
9033 * python/py-framefilter.c (py_print_frame)
9034 (gdbpy_apply_frame_filter): Change type of "flags".
9035 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
9037 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
9038 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
9039 * extension.h (enum frame_filter_flag): Rename from
9041 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
9042 (apply_ext_lang_frame_filter): Change type of "flags".
9043 * extension.c (apply_ext_lang_frame_filter): Change type of
9045 * extension-priv.h (struct extension_language_ops)
9046 <apply_frame_filter>: Change type of "flags".
9048 2018-02-26 Tom Tromey <tom@tromey.com>
9051 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
9052 off-by-one in py_end computation.
9053 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
9055 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
9058 2018-02-26 Tom Tromey <tom@tromey.com>
9060 * dwarf2read.c (struct variant_field): New.
9061 (struct nextfield) <variant>: New field.
9062 (dwarf2_add_field): Handle DW_TAG_variant_part.
9063 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
9064 discriminated union.
9065 (read_structure_type): Handle DW_TAG_variant_part.
9066 (handle_struct_member_die): New function, extracted from
9067 process_structure_scope. Handle DW_TAG_variant.
9068 (process_structure_scope): Handle discriminated unions. Call
9069 handle_struct_member_die.
9071 2018-02-26 Tom Tromey <tom@tromey.com>
9073 * rust-lang.h (rust_last_path_segment): Declare.
9074 * rust-lang.c (rust_last_path_segment): Now public. Change
9076 (struct disr_info): Remove.
9077 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
9078 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
9079 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
9080 (rust_enum_p, rust_enum_variant): New function.
9081 (rust_underscore_fields): Remove "offset" parameter.
9082 (rust_print_enum): New function.
9083 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
9084 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
9085 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
9087 (rust_internal_print_type): New function, from rust_print_type.
9089 (rust_print_type): Call rust_internal_print_type.
9090 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
9091 Update enum handling.
9092 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
9093 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
9094 (rust_union_quirks): New functions.
9095 (process_full_comp_unit, process_full_type_unit): Call
9097 (process_structure_scope): Update rust_unions if necessary.
9099 2018-02-26 Tom Tromey <tom@tromey.com>
9101 * value.h (value_union_variant): Declare.
9102 * valops.c (value_union_variant): New function.
9103 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
9104 (struct discriminant_info): New.
9105 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
9107 (struct main_type) <flag_discriminated_union>: New field.
9109 2018-02-26 Tom Tromey <tom@tromey.com>
9111 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9112 unittests/unpack-selftests.c.
9113 * unittests/unpack-selftests.c: New file.
9114 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
9116 2018-02-26 Yao Qi <yao.qi@linaro.org>
9118 * dwarf2read.c (struct partial_die_info) <read>: New method.
9119 (read_partial_die): Remove the declaration.
9120 (load_partial_dies): Update.
9121 (partial_die_info::partial_die_info):
9122 (read_partial_die): Change it to partial_die_info::read.
9124 2018-02-26 Yao Qi <yao.qi@linaro.org>
9126 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
9127 (fixup_partial_die): Remove declaration.
9128 (scan_partial_symbols): Update.
9129 (partial_die_parent_scope): Likewise.
9130 (partial_die_full_name): Likewise.
9131 (fixup_partial_die): Change it to partial_die_info::fixup.
9133 2018-02-26 Yao Qi <yao.qi@linaro.org>
9135 * dwarf2read.c (read_partial_die): Update the declaration.
9136 (load_partial_dies): Caller update.
9137 (read_partial_die): Remove one argument abbrev_len.
9139 2018-02-26 Yao Qi <yao.qi@linaro.org>
9141 * dwarf2read.c (struct partial_die_info): Add ctor, delete
9142 assignment operator.
9143 (load_partial_dies): Use ctor and copy ctor.
9144 (read_partial_die): Update.
9145 (dwarf2_cu::find_partial_die): Use ctor.
9147 2018-02-26 Yao Qi <yao.qi@linaro.org>
9149 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
9150 (find_partial_die_in_comp_unit): Change it to
9151 dwarf2_cu::find_partial_die.
9152 (find_partial_die): Update.
9154 2018-02-26 Yao Qi <yao.qi@linaro.org>
9156 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
9159 2018-02-26 Yao Qi <yao.qi@linaro.org>
9161 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
9163 2018-02-26 Alan Hayward <alan.hayward@arm.com>
9165 * arch/amd64.h: Use common/tdesc.h.
9166 * arch/i386.c: Likewise.
9167 * arch/i386.h: Likewise.
9168 * arch/tic6x.c: Likewise.
9169 * arch/tdesc.h: Move file from here...
9170 * common/tdesc.h: ...to here.
9171 * features/aarch64-core.c: Regenerate.
9172 * features/aarch64-fpu.c: Regenerate.
9173 * features/i386/32bit-avx.c: Regenerate.
9174 * features/i386/32bit-avx512.c: Regenerate.
9175 * features/i386/32bit-core.c: Regenerate.
9176 * features/i386/32bit-linux.c: Regenerate.
9177 * features/i386/32bit-mpx.c: Regenerate.
9178 * features/i386/32bit-pkeys.c: Regenerate.
9179 * features/i386/32bit-sse.c: Regenerate.
9180 * features/i386/64bit-avx.c: Regenerate.
9181 * features/i386/64bit-avx512.c: Regenerate.
9182 * features/i386/64bit-core.c: Regenerate.
9183 * features/i386/64bit-linux.c: Regenerate.
9184 * features/i386/64bit-mpx.c: Regenerate.
9185 * features/i386/64bit-pkeys.c: Regenerate.
9186 * features/i386/64bit-segments.c: Regenerate.
9187 * features/i386/64bit-sse.c: Regenerate.
9188 * features/i386/x32-core.c: Regenerate.
9189 * features/tic6x-c6xp.c: Regenerate.
9190 * features/tic6x-core.c: Regenerate.
9191 * features/tic6x-gp.c: Regenerate.
9192 * target-descriptions.c: Use common/tdesc.h.
9193 * target-descriptions.h: Likewise.
9195 2018-02-24 Tom Tromey <tom@tromey.com>
9197 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
9198 (try_thread_db_load_from_dir, thread_db_load_search): Use
9200 (info_auto_load_libthread_db_compare): Return bool. Change
9202 (info_auto_load_libthread_db): Use std::vector, std::string.
9205 2018-02-24 Tom Tromey <tom@tromey.com>
9207 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
9209 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
9211 * gdbarch.c: Rebuild.
9212 * gdbarch.h: Rebuild.
9213 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
9214 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
9215 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
9218 2018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
9220 * gdbtypes.h (sect_offset): Change type to uint64_t.
9221 (sect_offset_str): New function.
9222 * dwarf2read.c (create_addrmap_from_aranges): Use
9224 (error_check_comp_unit_head): Likewise.
9225 (create_debug_type_hash_table): Likewise.
9226 (read_cutu_die_from_dwo): Likewise.
9227 (init_cutu_and_read_dies): Likewise.
9228 (init_cutu_and_read_dies_no_follow): Likewise.
9229 (process_psymtab_comp_unit_reader): Likewise.
9230 (partial_die_parent_scope): Likewise.
9231 (peek_die_abbrev): Likewise.
9232 (process_queue): Likewise.
9233 (dwarf2_physname): Likewise.
9234 (read_namespace_alias): Likewise.
9235 (read_import_statement): Likewise.
9236 (create_dwo_cu_reader): Likewise.
9237 (create_cus_hash_table): Likewise.
9238 (lookup_dwo_cutu): Likewise.
9239 (inherit_abstract_dies): Likewise.
9240 (read_func_scope): Likewise.
9241 (read_call_site_scope): Likewise.
9242 (dwarf2_add_member_fn): Likewise.
9243 (read_common_block): Likewise.
9244 (read_module_type): Likewise.
9245 (read_typedef): Likewise.
9246 (read_subrange_type): Likewise.
9247 (load_partial_dies): Likewise.
9248 (read_partial_die): Likewise.
9249 (find_partial_die): Likewise.
9250 (read_str_index): Likewise.
9251 (dwarf2_string_attr): Likewise.
9252 (build_error_marker_type): Likewise.
9253 (lookup_die_type): Likewise.
9254 (dump_die_shallow): Likewise.
9255 (follow_die_ref): Likewise.
9256 (dwarf2_fetch_die_loc_sect_off): Likewise.
9257 (dwarf2_fetch_constant_bytes): Likewise.
9258 (follow_die_sig): Likewise.
9259 (get_signatured_type): Likewise.
9260 (get_DW_AT_signature_type): Likewise.
9261 (dwarf2_find_containing_comp_unit): Likewise.
9262 (set_die_type): Likewise.
9264 2018-02-21 John Baldwin <jhb@FreeBSD.org>
9266 * arch/aarch64.c: Include "common-defs.h".
9267 * arch/amd64.c: Likewise.
9268 * arch/i386.c: Likewise.
9270 2018-02-21 Tom Tromey <tom@tromey.com>
9272 * value.h: (extract_field_op): Update.
9273 * eval.c (extract_field_op): Return a const char *.
9274 * expression.h (parse_expression_for_completion): Update.
9275 * completer.c (complete_expression): Update.
9276 (add_struct_fields): Make fieldname const.
9277 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9278 (mark_completion_tag, parse_exp_in_context_1): Update.
9279 (parse_expression_for_completion): Change "name" to
9280 unique_xmalloc_ptr*.
9282 2018-02-21 Tom Tromey <tom@tromey.com>
9284 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9286 2018-02-21 Yao Qi <yao.qi@linaro.org>
9288 * avr-tdep.c (avr_read_pc): Change parameter type to
9290 * gdbarch.sh (read_pc): Likewise.
9291 * gdbarch.c: Re-generated.
9292 * gdbarch.h: Re-generated.
9293 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9295 * ia64-tdep.c (ia64_read_pc): Likewise.
9296 * mips-tdep.c (mips_read_pc): Likewise.
9297 * spu-tdep.c (spu_read_pc): Likewise.
9299 2018-02-21 Yao Qi <yao.qi@linaro.org>
9301 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
9302 * regcache-dump.c: New file.
9303 * regcache.c: Move register_dump to regcache-dump.c.
9304 (maintenance_print_registers): Likewise.
9305 (maintenance_print_raw_registers): Likewise.
9306 (maintenance_print_cooked_registers): Likewise.
9307 (maintenance_print_register_groups): Likewise.
9308 (maintenance_print_remote_registers): Likewise.
9309 (_initialize_regcache): Likewise.
9310 * regcache.h (register_dump): Moved from regcache.c.
9312 2018-02-21 Yao Qi <yao.qi@linaro.org>
9314 * regcache.c (regcache::regcache): Update.
9315 (regcache::invalidate): Move it to detached_regcache::invalidate.
9316 (get_thread_arch_aspace_regcache): Update.
9317 (regcache::raw_update): Update.
9318 (regcache::cooked_read): Remove some code.
9319 (regcache::cooked_read_value): Likewise.
9320 (regcache::raw_write): Remove assert on m_readonly_p.
9321 (regcache::raw_supply_integer): Move it to
9322 detached_regcache::raw_supply_integer.
9323 (regcache::raw_supply_zeroed): Likewise.
9324 * regcache.h (detached_regcache) <raw_supply_integer>: New
9326 <raw_supply_zeroed, invalidate>: Likewise.
9327 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
9328 <invalidate>: Likewise.
9329 <m_readonly_p>: Removed.
9331 2018-02-21 Yao Qi <yao.qi@linaro.org>
9333 * infcmd.c (get_return_value): Let stop_regs point to
9334 get_current_regcache.
9335 * regcache.c (regcache::regcache): Remove.
9336 (register_dump_reg_buffer): New class.
9337 (regcache_print): Adjust.
9338 * regcache.h (regcache): Remove constructors.
9340 2018-02-21 Yao Qi <yao.qi@linaro.org>
9342 * regcache.c (class register_dump): New class.
9343 (register_dump_regcache, register_dump_none): New class.
9344 (register_dump_remote, register_dump_groups): New class.
9345 (regcache_print): Update.
9346 * regcache.h (regcache_dump_what): Move it to regcache.c.
9347 (regcache) <dump>: Remove.
9349 2018-02-21 Yao Qi <yao.qi@linaro.org>
9351 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
9353 (jit_unwind_reg_set_impl): Call raw_supply.
9354 (jit_frame_sniffer): Use reg_buffer_rw.
9355 * record-full.c (record_full_core_regbuf): Change its type.
9356 (record_full_core_open_1): Use reg_buffer_rw.
9357 (record_full_close): Likewise.
9358 (record_full_core_fetch_registers): Use regcache->raw_supply.
9359 (record_full_core_store_registers): Likewise.
9360 * regcache.c (regcache::get_register_status): Move it to
9362 (regcache_raw_set_cached_value): Remove.
9363 (regcache::raw_set_cached_value): Remove.
9364 (regcache::raw_write): Call raw_supply.
9365 (regcache::raw_supply): Move it to reg_buffer_rw.
9366 * regcache.h (regcache_raw_set_cached_value): Remove.
9367 (reg_buffer_rw): New class.
9369 2018-02-21 Yao Qi <yao.qi@linaro.org>
9371 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
9372 readonly_detached_regcache.
9373 (dummy_frame_prev_register): Use regcache->cooked_read.
9374 * frame.c (frame_save_as_regcache): Change return type.
9375 (frame_pop): Update.
9376 * frame.h (frame_save_as_regcache): Update declaration.
9377 * inferior.h (get_infcall_suspend_state_regcache): Update
9379 * infrun.c (infcall_suspend_state) <registers>: use
9380 readonly_detached_regcache.
9381 (save_infcall_suspend_state): Don't use regcache_dup.
9382 (get_infcall_suspend_state_regcache): Change return type.
9383 * linux-fork.c (struct fork_info) <savedregs>: Change to
9384 readonly_detached_regcache.
9386 (fork_save_infrun_state): Don't use regcache_dup.
9387 (info_checkpoints_command): Adjust.
9388 * mi/mi-main.c (register_changed_p): Update declaration.
9389 (mi_cmd_data_list_changed_registers): Use
9390 readonly_detached_regcache.
9391 (register_changed_p): Change parameter type to
9392 readonly_detached_regcache.
9393 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
9394 readonly_detached_regcache.
9395 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
9396 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
9398 (regcache::save): Move it to reg_buffer.
9399 (regcache::restore): Change parameter type.
9400 (regcache_dup): Remove.
9401 * regcache.h (reg_buffer) <save>: New method.
9402 (readonly_detached_regcache): New class.
9403 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
9404 readonly_detached_regcache.
9405 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
9407 2018-02-21 Yao Qi <yao.qi@linaro.org>
9409 * frame.c (frame_save_as_regcache): Use regcache method save.
9410 (frame_pop): Use regcache method restore.
9411 * infrun.c (restore_infcall_suspend_state): Likewise.
9412 * linux-fork.c (fork_load_infrun_state): Likewise.
9413 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
9415 * regcache.c (regcache_save): Remove.
9416 (regcache::restore): More asserts.
9417 (regcache_cpy): Remove.
9418 * regcache.h (regcache_save): Remove the declaration.
9419 (regcache::restore): Move from private to public.
9420 Remove the friend declaration of regcache_cpy.
9421 (regcache_cpy): Remove declaration.
9423 2018-02-21 Yao Qi <yao.qi@linaro.org>
9425 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
9426 parameter type to 'readable_regcache *'.
9427 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9428 * arm-tdep.c (arm_neon_quad_read): Likewise.
9429 (arm_pseudo_read): Likewise.
9430 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9431 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9432 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9433 * gdbarch.c: Re-generated.
9434 * gdbarch.h: Re-generated.
9435 * gdbarch.sh (pseudo_register_read): Change parameter type to
9436 'readable_regcache *'.
9437 (pseudo_register_read_value): Likewise.
9438 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
9439 (h8300_pseudo_register_read): Likewise.
9440 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
9441 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9442 (i386_pseudo_register_read_into_value): Likewise.
9443 (i386_pseudo_register_read_value): Likewise.
9444 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
9446 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
9447 * m32c-tdep.c (m32c_raw_read): Likewise.
9448 (m32c_read_flg): Likewise.
9449 (m32c_banked_register): Likewise.
9450 (m32c_banked_read): Likewise.
9451 (m32c_sb_read): Likewise.
9452 (m32c_part_read): Likewise.
9453 (m32c_cat_read): Likewise.
9454 (m32c_r3r2r1r0_read): Likewise.
9455 (m32c_pseudo_register_read): Likewise.
9456 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9457 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9458 (mep_pseudo_cr64_read): Likewise.
9459 (mep_pseudo_register_read): Likewise.
9460 * mips-tdep.c (mips_pseudo_register_read): Likewise.
9461 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9462 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9463 * regcache.c (regcache::raw_read): Move it to readable_regcache.
9464 (regcache::cooked_read): Likewise.
9465 (regcache::cooked_read_value): Likewise.
9466 (regcache_cooked_read_signed):
9467 (regcache::cooked_read): Likewise.
9468 * regcache.h (readable_regcache): New class.
9469 (regcache): Inherit readable_regcache. Move some methods to
9471 * rl78-tdep.c (rl78_pseudo_register_read): Change
9472 parameter type to 'readable_regcache *'.
9473 * rs6000-tdep.c (do_regcache_raw_read): Remove.
9474 (e500_pseudo_register_read): Change parameter type to
9475 'readable_regcache *'.
9476 (dfp_pseudo_register_read): Likewise.
9477 (vsx_pseudo_register_read): Likewise.
9478 (efpr_pseudo_register_read): Likewise.
9479 * s390-tdep.c (s390_pseudo_register_read): Likewise.
9480 * sh-tdep.c (sh_pseudo_register_read): Likewise.
9481 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
9482 (sh64_pseudo_register_read): Likewise.
9483 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9484 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9485 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9486 (spu_pseudo_register_read): Likewise.
9487 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9488 (xtensa_pseudo_register_read): Likewise.
9490 2018-02-21 Yao Qi <yao.qi@linaro.org>
9492 * regcache.c (regcache::regcache): Call reg_buffer ctor.
9493 (regcache::arch): Move it to reg_buffer::arch.
9494 (regcache::register_buffer): Likewise.
9495 (regcache::assert_regnum): Likewise.
9496 (regcache::num_raw_registers): Likewise.
9497 * regcache.h (reg_buffer): New class.
9498 (regcache): Inherit reg_buffer.
9500 2018-02-20 Simon Marchi <simon.marchi@ericsson.com>
9502 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
9503 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
9505 2018-02-20 Markus Metzger <markus.t.metzger@intel.com>
9507 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
9509 2018-02-19 Alan Hayward <alan.hayward@arm.com>
9511 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
9512 (SFILES): Remove common/*.c files.
9513 (COMMON_OBS): Remove some *.o files built from common/*.c files.
9514 * common/common.host: Add common reference.
9515 * configure.ac: Likewise.
9516 * configure: Regenerate.
9518 2018-02-16 Yao Qi <yao.qi@linaro.org>
9520 * block.c (block_namespace_info): Inherit allocate_on_obstack.
9521 (block_initialize_namespace): Use new.
9522 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
9523 (dwarf2_free_objfile): Use delete.
9524 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
9525 (copy_type_recursive): Use new.
9526 * gdb_obstack.h (allocate_on_obstack): New.
9528 2018-02-15 Yao Qi <yao.qi@linaro.org>
9531 * inferior.c (exit_inferior_1): Reset inf->control.
9533 2018-02-15 Joel Brobecker <brobecker@adacore.com>
9535 * ada-lang.c (ada_to_fixed_value_create): Delete advance
9538 2018-02-14 Pedro Alves <palves@redhat.com>
9540 * frame-unwind.c (frame_unwind_try_unwinder): Always call
9541 frame_cleanup_after_sniffer on exception.
9543 2018-02-14 Tom Tromey <tom@tromey.com>
9545 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
9547 (solib_bfd_open): Make pathname const.
9548 * solib.c (solib_bfd_open): Make pathname const.
9549 * solib-spu.c (spu_bfd_fopen): Make name const.
9550 (spu_bfd_open): Make pathname const.
9551 * solib-darwin.c (darwin_bfd_open): Make pathname const.
9552 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
9554 2018-02-14 Tom Tromey <tom@tromey.com>
9556 * symfile.c (symfile_bfd_open): Update.
9557 * source.h (openp, source_full_path_of, find_and_open_source):
9558 Change argument type to unique_xmalloc_ptr.
9559 * source.c (openp): Take a unique_xmalloc_ptr.
9560 (source_full_path_of, find_and_open_source): Likewise.
9561 (open_source_file, symtab_to_fullname): Update.
9562 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
9564 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
9565 (exec_file_find): Update.
9566 * psymtab.c (psymtab_to_fullname): Update.
9567 * nto-tdep.h (nto_find_and_open_solib): Update.
9568 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
9570 * exec.c (exec_file_attach): Update.
9571 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
9572 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
9574 2018-02-14 Tom Tromey <tom@tromey.com>
9576 * solib.c: Include source.h.
9577 * nto-tdep.c: Include source.h.
9578 * mi/mi-cmd-env.c: Include source.h.
9579 * infcmd.c: Include source.h.
9580 * exec.c: Include source.h.
9581 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
9582 (add_path, directory_switch, source_path, init_source_path): Move
9584 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
9585 (add_path, directory_switch, source_path, init_source_path):
9588 2018-02-14 Tom Tromey <tom@tromey.com>
9590 * solist.h (exec_file_find, solib_find): Return
9592 (solib_bfd_fopen): Take a const char *.
9593 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
9594 (exec_file_find, solib_find): Likewise.
9595 (solib_bfd_fopen): Do not take ownership of "pathname".
9596 (solib_bfd_open): Use unique_xmalloc_ptr.
9597 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
9598 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
9599 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
9600 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
9602 2018-02-14 Joel Brobecker <brobecker@adacore.com>
9604 * ada-lang.c (name_match_type_from_name): Remove reference to
9605 ada_name_for_lookup in function's documentation.
9606 * ada-lang.h (ada_name_for_lookup): Delete declaration.
9608 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9610 * defs.h (enum openp_flags): New enum.
9611 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
9612 Move to enum openp_flags.
9613 (openp_flags): New enum flags.
9614 (openp): Change parameter type to openp_flags.
9615 * source.c (openp): Change parameter type to openp_flags.
9616 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
9617 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
9619 2018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9621 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
9624 2018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
9626 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
9628 (class dwarf2_queue_guard): ...the destructor of this new class.
9629 (dw2_do_instantiate_symtab): Create instance of the new class
9630 dwarf2_queue_guard, remove cleanup.
9632 2018-02-09 Tom Tromey <tom@tromey.com>
9634 * source.c (find_source_lines): Don't reference past the end of
9637 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9639 * remote.c (remote_btrace_maybe_reopen): Change error message.
9640 * btrace.c (btrace_enable): Likewise.
9641 (parse_xml_btrace): Likewise.
9642 (parse_xml_btrace_conf): Likewise.
9644 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9646 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
9647 (linux_enable_pt, linux_enable_bts): Call
9648 diagnose_perf_event_open_fail.
9650 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9652 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
9653 Remove parameter and change return type. Update callers. Move it.
9654 (linux_enable_bts, linux_enable_pt): Improve error message.
9655 (linux_enable_pt): Remove zero buffer size check.
9656 (linux_enable_btrace): Improve error messages. Remove NULL return
9659 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9661 * btrace.c (btrace_enable): Remove target_supports_btrace call.
9662 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
9663 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
9664 (linux_supports_pt, linux_supports_btrace): Remove.
9665 (linux_enable_bts): Call cpu_supports_bts.
9666 * nat/linux-btrace.h (linux_supports_btrace): Remove.
9667 * remote.c (remote_supports_btrace): Remove.
9668 (init_remote_ops): Remove remote_supports_btrace.
9669 * target-delegates.c: Regenerated.
9670 * target.c (target_supports_btrace): Remove.
9671 * target.h (target_ops) <to_supports_btrace>: Remove
9672 (target_supports_btrace): Remove.
9673 * x86-linux-nat.c (x86_linux_create_target): Remove
9674 linux_supports_btrace.
9676 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9678 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
9680 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
9681 exception and use message in own exception.
9683 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9685 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
9686 (perf_event_pt_event_type): Use gdb_file_up.
9687 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
9688 scoped_fd, and scoped_mmap.
9690 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9692 * common/scoped_mmap.h: New.
9693 * unittests/scoped_mmap-selftest.c: New.
9694 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9695 unittests/scoped_mmap-selftest.c.
9697 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9699 * common/scoped_fd.h: New.
9700 * unittests/scoped_fd-selftest.c: New.
9701 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9702 unittests/scoped_fd-selftest.c.
9704 2018-02-09 Tom Tromey <tom@tromey.com>
9706 * auto-load.c (auto_load_section_scripts): Use
9707 gdb::unique_xmalloc_ptr.
9709 2018-02-09 Tom Tromey <tom@tromey.com>
9711 * auto-load.c (execute_script_contents): Use std::string.
9713 2018-02-09 Joel Brobecker <brobecker@adacore.com>
9715 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
9716 Python function, rather than a new command.
9718 2018-02-08 Tom Tromey <tom@tromey.com>
9720 * solib.c (solib_find_1): Use std::string.
9721 (solib_bfd_fopen): Use unique_xmalloc_ptr.
9723 2018-02-08 Tom Tromey <tom@tromey.com>
9725 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
9727 2018-02-08 Tom Tromey <tom@tromey.com>
9729 * source.c (find_source_lines): Use gdb::def_vector.
9731 2018-02-08 Tom Tromey <tom@tromey.com>
9733 * macrocmd.c (struct temporary_macro_definition): New.
9734 (macro_define_command): Use temporary_macro_definition. Remove
9736 (free_macro_definition_ptr): Remove.
9738 2018-02-08 Tom Tromey <tom@tromey.com>
9740 * macroexp.c (maybe_expand): Use std::string.
9742 2018-02-08 Tom Tromey <tom@tromey.com>
9744 * macroexp.c (struct macro_buffer): Add initializers for some
9746 (init_buffer, init_shared_buffer, free_buffer)
9747 (free_buffer_return_text): Remove.
9748 (macro_buffer): New constructors.
9749 (~macro_buffer): New destructor.
9750 (macro_buffer::set_shared): New method.
9751 (macro_buffer::resize_buffer, macro_buffer::appendc)
9752 (macro_buffer::appendmem): Now methods, not free functions.
9753 (set_token, append_tokens_without_splicing, stringify)
9754 (macro_stringify): Update.
9755 (gather_arguments): Change return type. Remove argc_p argument,
9756 add args_ptr argument. Use std::vector.
9757 (substitute_args): Remove argc argument. Accept std::vector.
9758 (expand): Update. Use std::vector.
9759 (scan, macro_expand, macro_expand_next): Update.
9761 2018-02-08 Tom Tromey <tom@tromey.com>
9763 * symtab.c (default_collect_symbol_completion_matches_break_on):
9764 Use unique_xmalloc_ptr.
9765 * macroscope.h: (sal_macro_scope, user_macro_scope)
9766 (default_macro_scope): Return unique_xmalloc_ptr.
9767 * macroscope.c (sal_macro_scope, user_macro_scope)
9768 (default_macro_scope): Return unique_xmalloc_ptr.
9769 * macroexp.h (macro_expand, macro_expand_once): Return
9771 * macroexp.c (macro_expand, macro_expand_once): Return
9773 * macrocmd.c (macro_expand_command, macro_expand_once_command)
9774 (info_macro_command, info_macros_command): Use
9776 * compile/compile-c-support.c (write_macro_definitions): Use
9778 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
9780 2018-02-07 Simon Marchi <simon.marchi@ericsson.com>
9782 * value.c (value_static_field): Assign field type instead of
9783 containing type when returning an optimized out value.
9785 2018-02-06 Yao Qi <yao.qi@linaro.org>
9787 * ft32-tdep.c (ft32_read_pc): Remove.
9788 (ft32_write_pc): Remove.
9789 (ft32_gdbarch_init): Update.
9790 * m32r-tdep.c (m32r_read_pc): Remove.
9791 (m32r_gdbarch_init): Update.
9792 * mep-tdep.c (mep_read_pc): Remove.
9793 (mep_gdbarch_init): Update.
9794 * microblaze-tdep.c (microblaze_write_pc): Remove.
9795 (microblaze_gdbarch_init): Update.
9796 * mn10300-tdep.c (mn10300_read_pc): Remove.
9797 (mn10300_write_pc): Remove.
9798 (mn10300_gdbarch_init): Update.
9799 * moxie-tdep.c (moxie_read_pc): Remove.
9800 (moxie_write_pc): Remove.
9801 (moxie_gdbarch_init): Update.
9803 2018-02-06 Yao Qi <yao.qi@linaro.org>
9805 * expprint.c (print_subexp_standard): Handle
9806 OP_F77_UNDETERMINED_ARGLIST.
9807 (dump_subexp_body_standard): Likewise.
9809 2018-02-05 Alan Hayward <alan.hayward@arm.com>
9811 * target-descriptions.c (tdesc_element_visitor) Add empty
9813 (tdesc_type): Move make_gdb_type from here.
9814 (tdesc_type_builtin): Likewise.
9815 (tdesc_type_vector): Likewise.
9816 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
9817 (make_gdb_type_struct): Move from tdesc_type_with_fields.
9818 (make_gdb_type_union): Likewise.
9819 (make_gdb_type_flags): Likewise.
9820 (make_gdb_type_enum): Likewise.
9821 (make_gdb_type): New function.
9822 (tdesc_register_type): Use static make_gdb_type.
9824 2018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
9826 * infcmd.c (default_print_one_register_info): Align natural-format
9827 column values consistently one under another.
9828 (pad_to_column): New function.
9830 2018-02-05 Joel Brobecker <brobecker@adacore.com>
9832 * dwarf2read.c (dwarf2_physname): Move commment.
9834 2018-02-01 Leszek Swirski <leszeks@google.com>
9836 * varobj.c (varobj_formatted_print_options): Allow recursive
9837 pretty printing if pretty printing is enabled.
9839 2018-02-01 Leszek Swirski <leszeks@google.com>
9841 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
9842 names after a structop as a filename.
9844 2018-02-01 Yao Qi <yao.qi@linaro.org>
9846 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
9847 (arm_record_coproc_data_proc): Likewise.
9849 2018-02-01 Yao Qi <yao.qi@linaro.org>
9851 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
9853 2018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
9855 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
9856 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
9858 2018-01-31 Pedro Alves <palves@redhat.com>
9860 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
9861 * inflow.c (child_terminal_save_inferior): Wrap reference to
9862 tcgetpgrp in HAVE_TERMIOS_H.
9863 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
9865 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
9866 always iterate over all inferiors.
9867 (gdbsim_cntrl_c): Adjust.
9868 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
9870 2018-01-31 Joel Brobecker <brobecker@adacore.com>
9872 * gdbtypes.c (lookup_array_range_type): Make sure the array's
9873 index type is objfile-owned if the element type is as well.
9875 2018-01-31 Joel Brobecker <brobecker@adacore.com>
9879 2018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
9881 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
9882 "features/s390x-linux64.c".
9883 (_initialize_s390_linux_tdep): Remove initialization of tdescs
9884 s390_linux32 and s390x_linux64.
9885 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
9887 * s390-tdep.c: Include "features/s390-linux32.c" and
9888 "features/s390x-linux64.c".
9889 (s390_tdesc_valid): Add check for tdesc_has_registers.
9890 (s390_gdbarch_init): Make sure there is always a valid tdesc.
9891 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
9892 tdesc_s390x_linux64.
9893 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
9894 tdesc_s390x_linux64 to...
9895 * s390-tdep.h: ...here.
9897 2018-01-30 Pedro Alves <palves@redhat.com>
9900 * config.in, configure: Regenerate.
9901 * configure.ac: Check for getpgid.
9902 * go32-nat.c (go32_pass_ctrlc): New.
9903 (go32_target): Install it.
9904 * inf-child.c (inf_child_target): Install
9905 child_terminal_save_inferior, child_pass_ctrlc and
9907 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
9908 (inf_ptrace_target): No longer install it.
9909 * infcmd.c (interrupt_target_1): Adjust.
9910 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
9911 (child_interrupt): Declare.
9912 (inferior::terminal_state): New.
9913 * inflow.c (struct terminal_info): Update comments.
9914 (inferior_process_group): Delete.
9915 (terminal_is_ours): Delete.
9916 (gdb_tty_state): New.
9917 (child_terminal_init): Adjust.
9918 (is_gdb_terminal, sharing_input_terminal_1)
9919 (sharing_input_terminal): New functions.
9920 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
9921 Set the process's actual process group in the foreground if
9922 possible. Handle is_ours_for_output/is_ours distinction. Don't
9923 mark terminal as the inferior's if not sharing GDB's terminal.
9924 Don't check attach_flag.
9925 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
9926 pass down a target_terminal_state.
9927 (child_terminal_save_inferior): New, factored out from ...
9928 (child_terminal_ours_1): ... this. Handle
9929 target_terminal_state::is_ours_for_output.
9930 (child_interrupt, child_pass_ctrlc): New.
9931 (inflow_inferior_exit): Clear the inferior's terminal_state.
9932 (copy_terminal_info): Copy the inferior's terminal state.
9933 (_initialize_inflow): Remove reference to terminal_is_ours.
9934 * inflow.h (inferior_process_group): Delete.
9935 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
9936 * procfs.c (procfs_target): Don't install procfs_interrupt.
9937 (procfs_interrupt): Delete.
9938 * remote.c (remote_serial_quit_handler): Adjust.
9939 (remote_interrupt): Remove ptid parameter. Adjust.
9940 * target-delegates.c: Regenerate.
9941 * target.c: Include "terminal.h".
9942 (target_terminal::terminal_state): Rename to ...
9943 (target_terminal::m_terminal_state): ... this.
9944 (target_terminal::init): Adjust.
9945 (target_terminal::inferior): Adjust to per-inferior
9947 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
9948 (target_terminal::ours, target_terminal::ours_for_output): Use
9949 target_terminal_is_ours_kind.
9950 (target_interrupt): Remove ptid parameter. Adjust.
9951 (default_target_pass_ctrlc): Adjust.
9952 * target.h (target_ops::to_terminal_save_inferior): New field.
9953 (target_ops::to_interrupt): Remove ptid_t parameter.
9954 (target_interrupt): Remove ptid_t parameter. Update comment.
9955 (target_pass_ctrlc): Update comment.
9956 * target/target.h (target_terminal_state): New scoped enum,
9958 (target_terminal::terminal_state): ... here.
9959 (target_terminal::inferior): Update comments.
9960 (target_terminal::restore_inferior): New.
9961 (target_terminal::is_inferior, target_terminal::is_ours)
9962 (target_terminal::is_ours_for_output): Adjust.
9963 (target_terminal::scoped_restore_terminal_state): Adjust to
9964 rename, and call restore_inferior() instead of inferior().
9965 (target_terminal::scoped_restore_terminal_state::m_state): Change
9967 (target_terminal::terminal_state): Rename to ...
9968 (target_terminal::m_terminal_state): ... this and change type.
9970 2018-01-30 Pedro Alves <palves@redhat.com>
9972 * linux-nat.c (wait_for_signal): New function.
9973 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
9975 (async_terminal_is_ours)
9976 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
9977 (linux_nat_add_target): Don't override
9978 to_terminal_inferior/to_terminal_ours.
9980 2018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
9982 * remote.c (remote_follow_fork): Don't call "detach_inferior".
9984 2018-01-28 Simon Marchi <simon.marchi@ericsson.com>
9986 * dwarf2read.c (free_dwo_files): Add forward-declaration.
9987 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
9988 dwarf2_per_objfile_free here.
9989 (dwarf2_per_objfile_free): Remove.
9990 (_initialize_dwarf2_read): Don't register
9991 dwarf2_per_objfile_free as a registry cleanup.
9993 2018-01-27 Eli Zaretskii <eliz@gnu.org>
9995 Avoid compilation errors in MinGW native builds
9997 The error is triggered by including python-internal.h, and the
10000 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
10001 from build-gnulib/import/math.h:27,
10002 from d:/usr/Python26/include/pyport.h:235,
10003 from d:/usr/Python26/include/Python.h:58,
10004 from python/python-internal.h:94,
10005 from python/py-arch.c:24:
10006 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
10010 This happens because Python headers define 'hypot' to expand t
10011 '_hypot' in the Windows builds.
10012 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
10013 'hypoth'. This avoids a compilation error.
10015 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10017 * MAINTAINERS (Write After Approval): Fix ordering.
10019 2018-01-26 Alan Hayward <alan.hayward@arm.com>
10021 * MAINTAINERS (Write After Approval): Add Alan Hayward.
10023 2018-01-26 Alan Modra <amodra@gmail.com>
10025 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
10026 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
10027 Remove nop. Make const. Comment.
10028 (powerpc32_plt_stub_so_2): New.
10029 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
10030 Correct count. Update uses.
10031 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
10032 Move common code reading PLT entry word. Correct
10033 powerpc32_plt_stub PLT address calculation.
10034 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
10035 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
10036 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
10037 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
10038 (ppc64_standard_linkage8): Likewise.
10039 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
10040 Correct insns description.
10041 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
10043 2018-01-24 Pedro Alves <palves@redhat.com>
10045 GCC PR libstdc++/83906
10046 * gdbtypes.c (operator==(const dynamic_prop &,
10047 const dynamic_prop &)): New.
10048 (operator==(const range_bounds &, const range_bounds &)): New.
10049 (check_types_equal): Use them instead of memcmp.
10050 * gdbtypes.h (operator==(const dynamic_prop &,
10051 const dynamic_prop &)): Declare.
10052 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
10053 (operator==(const range_bounds &, const range_bounds &)): Declare.
10054 (operator!=(const range_bounds &, const range_bounds &)): Declare.
10056 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10058 * s390-linux-tdep.c (s390_record_address_mask)
10059 (s390_record_calc_disp_common, s390_record_calc_disp)
10060 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10061 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10062 (s390_process_record): Move to s390-tdep.c.
10063 (s390_linux_init_abi_any): Adjust.
10064 * s390-tdep.c (s390_record_address_mask)
10065 (s390_record_calc_disp_common, s390_record_calc_disp)
10066 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10067 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10068 (s390_process_record): Moved from s390-linux-tdep.c
10069 (s390_gdbarch_init): Adjust.
10071 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10073 * s390-linux-nat.c (s390-tdep.h): New include.
10074 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
10075 (HFILES_NO_SRCDIR): Add s390-tdep.h.
10076 (ALLDEPFILES): Add s390-tdep.c.
10077 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
10078 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
10079 * s390-tdep.h: ...this. New file.
10080 * s390-linux-tdep.c (s390-tdep.h): New include.
10081 (_initialize_s390_tdep): Rename to...
10082 (_initialize_s390_linux_tdep): ...this and adjust.
10083 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
10084 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
10086 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
10087 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
10088 (s390_is_partial_instruction, s390_software_single_step)
10089 (is_non_branch_ril, s390_displaced_step_copy_insn)
10090 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
10091 (s390_prologue_data, s390_addr, s390_store, s390_load)
10092 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
10093 (s390_register_call_saved, s390_guess_tracepoint_registers)
10094 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
10095 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
10096 (s390_pseudo_register_name, s390_pseudo_register_type)
10097 (s390_pseudo_register_read, s390_pseudo_register_write)
10098 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
10099 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
10100 (s390_addr_bits_remove, s390_address_class_type_flags)
10101 (s390_address_class_type_flags_to_name)
10102 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
10103 (s390_function_arg_float, s390_function_arg_vector)
10104 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
10105 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
10106 (s390_frame_align, s390_register_return_value, s390_return_value)
10107 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
10108 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
10109 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
10110 (s390_trad_frame_prev_register, s390_unwind_cache)
10111 (s390_prologue_frame_unwind_cache)
10112 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
10113 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
10114 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
10115 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
10116 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
10117 (s390_frame_base_address, s390_local_base_address)
10118 (s390_frame_base, s390_gcc_target_options)
10119 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
10120 (s390_validate_reg_range, s390_tdesc_valid)
10121 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
10122 * s390-tdep.c: ...this. New file.
10124 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10126 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
10127 (s390_process_record, s390_gdbarch_tdep_alloc)
10128 (s390_linux_init_abi_any): Use/set new hook.
10130 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10132 * s390-linux-tdep.c (osabi.h): New include.
10133 (s390_linux_init_abi_31, s390_linux_init_abi_64)
10134 (s390_linux_init_abi_any): New functions.
10135 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
10137 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10139 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
10140 tdesc_has_registers check
10142 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10144 * s390-linux-tdep.c (s390_tdesc_valid): New function.
10145 (s390_validate_reg_range): New macro.
10146 (s390_gdbarch_init): Adjust.
10148 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10150 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
10151 (s390_gdbarch_tdep_alloc): Adjust.
10152 (s390_gdbarch_init): Adjust.
10154 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10156 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
10157 <have_tdb>: Change type to bool.
10158 (s390_gdbarch_tdep_alloc): Adjust.
10159 (s390_gdbarch_init): Adjust.
10161 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10163 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
10164 (gdbarch_tdep) <have_upper, have_vx>: New fields.
10165 (s390_gdbarch_tdep_alloc): New function.
10166 (s390_gdbarch_init): Allocate tdep at start and use its fields
10167 instead of separate variables.
10169 2018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10171 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
10172 when looking for cached gdbarch and add comment for remaining.
10174 2018-01-22 Pedro Alves <palves@redhat.com>
10175 Sergio Durigan Junior <sergiodj@redhat.com>
10177 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
10180 2018-01-22 Maciej W. Rozycki <macro@mips.com>
10182 * MAINTAINERS: Update my company e-mail address.
10184 2018-01-22 Yao Qi <yao.qi@linaro.org>
10186 * regcache.c (cooked_write_test): New function.
10187 (_initialize_regcache): Register the test.
10189 2018-01-22 Yao Qi <yao.qi@linaro.org>
10191 * ia64-tdep.c (ia64_pseudo_register_read): Call
10192 regcache->cooked_read instead of regcache_cooked_read_unsigned.
10193 * m32c-tdep.c (m32c_cat_read): Likewise.
10194 (m32c_r3r2r1r0_read): Likewise.
10195 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10196 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10198 2018-01-22 Yao Qi <yao.qi@linaro.org>
10200 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
10201 method raw_read instead of regcache_raw_read.
10202 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10203 * arm-tdep.c (arm_neon_quad_read): Likewise.
10204 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10205 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10206 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10207 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
10208 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10209 (i386_pseudo_register_read_into_value): Likewise.
10210 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10211 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10212 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10213 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
10214 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
10215 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10216 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10217 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10218 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
10220 2018-01-22 Yao Qi <yao.qi@linaro.org>
10222 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
10223 * configure.tgt: Remove target mt.
10224 * mt-tdep.c: Remove.
10225 * regcache.c (cooked_read_test): Remove the check for mt.
10227 2018-01-22 Yao Qi <yao.qi@linaro.org>
10229 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10230 instead of gdbarch_pseudo_register_read_value.
10232 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10234 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10237 2018-01-22 Joel Brobecker <brobecker@adacore.com>
10239 * linespec.c (create_sals_line_offset): Remove code that preserved
10240 the symtab_and_line's line number.
10242 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10244 * varobj.c (varobj_create): Don't set valid_block when creating a
10247 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10249 * varobj.c (varobj_create): Remove out of date comment.
10251 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10254 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10255 updating innermost block.
10256 * parse.c (innermost_block_tracker::update): Take extra type
10257 parameter, and check types match before updating innermost block.
10258 (write_dollar_variable): Update innermost block for registers.
10259 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10260 (innermost_block_tracker::innermost_block_tracker): Initialise
10262 (innermost_block_tracker::reset): Take type parameter.
10263 (innermost_block_tracker::update): Take type parameter, and pass
10264 type through as needed.
10265 (innermost_block_tracker::m_types): New member.
10266 * varobj.c (varobj_create): Pass type when reseting innermost
10269 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10271 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10272 * ada-lang.c (resolve_subexp): Likewise.
10273 * breakpoint.c (set_breakpoint_condition) Likewise.
10274 (watch_command_1) Likewise.
10275 * c-exp.y (variable): Likewise.
10276 * d-exp.y (PrimaryExpression): Likewise.
10277 * f-exp.y (variable): Likewise.
10278 * go-exp.y (variable): Likewise.
10279 * m2-exp.y (variable): Likewise.
10280 * objfiles.c (objfile::~objfile): Likewise.
10281 * p-exp.y (variable): Likewise.
10282 * parse.c (innermost_block): Change type.
10283 * parser-defs.h (class innermost_block_tracker): New.
10284 (innermost_block): Change to innermost_block_tracker.
10285 * printcmd.c (display_command): Switch to innermost_block API.
10286 (do_one_display): Likewise.
10287 * rust-exp.y (do_one_display): Likewise.
10288 * symfile.c (clear_symtab_users): Likewise.
10289 * varobj.c (varobj_create): Switch to innermost_block API, replace
10290 use of innermost_block with block stored on varobj object.
10292 2018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10294 * expression.h (innermost_block): Remove declaration.
10295 * varobj.c: Add 'parser-defs.h' include.
10297 2018-01-19 Tom Tromey <tom@tromey.com>
10299 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
10300 symbols in the static and global blocks.
10302 2018-01-19 James Clarke <jrtc27@jrtc27.com>
10304 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
10305 gdb_ptrace.h, and move including gdb_wait.h ...
10306 * nat/linux-ptrace.h: ... to here.
10308 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10310 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
10311 inf_ptrace_detach_success.
10312 (inf_ptrace_detach_success): Add inferior parameter, use it
10313 instead of inferior_ptid, pass it to detach_inferior.
10314 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
10316 * inferior.c (detach_inferior): Add overload that takes an
10318 * inferior.h (detach_inferior): Likewise.
10319 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
10320 use inferior_ptid, adjust call to inf_ptrace_detach_success.
10321 * linux-thread-db.c (thread_db_detach): Use inf parameter.
10323 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10325 * target.h (struct target_ops) <to_detach>: Add inferior
10327 (target_detach): Likewise.
10328 * target.c (dispose_inferior): Pass inferior down.
10329 (target_detach): Pass inferior down. Assert that it is equal to
10330 the current inferior.
10331 * aix-thread.c (aix_thread_detach): Pass inferior down.
10332 * corefile.c (core_file_command): Pass current_inferior() down.
10333 * corelow.c (core_detach): Add inferior parameter.
10334 * darwin-nat.c (darwin_detach): Likewise.
10335 * gnu-nat.c (gnu_detach): Likewise.
10336 * inf-ptrace.c (inf_ptrace_detach): Likewise.
10337 * infcmd.c (detach_command): Pass current_inferior() down to
10339 * infrun.c (follow_fork_inferior): Pass parent_inf to
10341 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
10343 * linux-nat.c (linux_nat_detach): Add inferior parameter.
10344 * linux-thread-db.c (thread_db_detach): Likewise.
10345 * nto-procfs.c (procfs_detach): Likewise.
10346 * procfs.c (procfs_detach): Likewise.
10347 * record.c (record_detach): Likewise.
10348 * record.h (struct inferior): Forward-declare.
10349 (record_detach): Add inferior parameter.
10350 * remote-sim.c (gdbsim_detach): Likewise.
10351 * remote.c (remote_detach_1): Likewise.
10352 (remote_detach): Likewise.
10353 (extended_remote_detach): Likewise.
10354 * sol-thread.c (sol_thread_detach): Likewise.
10355 * target-debug.h (target_debug_print_inferior_p): New macro.
10356 * target-delegates.c: Re-generate.
10357 * top.c (kill_or_detach): Pass inferior down to target_detach.
10358 * windows-nat.c (windows_detach): Add inferior parameter.
10360 2018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10362 * target.h (struct target_ops) <to_detach>: Remove args
10364 (target_detach): Likewise.
10365 * target.c (dispose_inferior): Adjust.
10366 (target_detach): Remove args parameter, adjust.
10367 * aix-thread.c (aix_thread_detach): Adjust.
10368 * corefile.c (core_file_command): Adjust.
10369 * corelow.c (core_detach): Adjust.
10370 * darwin-nat.c (darwin_detach): Adjust.
10371 * gnu-nat.c (gnu_detach): Adjust.
10372 * inf-ptrace.c (inf_ptrace_detach): Adjust.
10373 * infcmd.c (detach_command): Adjust
10374 * infrun.c (follow_fork_inferior): Adjust.
10375 (handle_vfork_child_exec_or_exit): Adjust.
10376 * linux-fork.c (linux_fork_detach): Remove args parameter.
10377 * linux-fork.h (linux_fork_detach): Likewise.
10378 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
10379 * linux-thread-db.c (thread_db_detach): Likewise.
10380 * nto-procfs.c (procfs_detach): Likewise.
10381 * procfs.c (procfs_detach): Likewise.
10382 (do_detach): Remove signo parameter.
10383 * record.c (record_detach): Remove args parameter.
10384 * record.h (record_detach): Likewise.
10385 * remote-sim.c (gdbsim_detach): Likewise.
10386 * remote.c (remote_detach_1): Likewise.
10387 (remote_detach): Likewise.
10388 (extended_remote_detach): Likewise.
10389 * sol-thread.c (sol_thread_detach): Likewise.
10390 * target-delegates.c: Re-generate.
10391 * top.c (struct qt_args) <args>: Remove field.
10392 (kill_or_detach): Don't pass args.
10393 (quit_force): Don't set args.
10394 * windows-nat.c (windows_detach): Remove args parameter.
10396 2018-01-19 Yao Qi <yao.qi@linaro.org>
10398 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
10399 (arm_linux_init_abi): Install it.
10401 2018-01-19 Yao Qi <yao.qi@linaro.org>
10403 * osabi.c (gdb_osabi_names): Extend the regexp for
10404 arm-linux-gnueabihf.
10406 2018-01-18 Yao Qi <yao.qi@linaro.org>
10408 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
10410 (abbrev_table::add_abbrev): Update.
10411 (abbrev_table::lookup_abbrev): Update.
10413 2018-01-18 Yao Qi <yao.qi@linaro.org>
10415 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
10417 2018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
10419 * compile/compile.c (compile_to_object): Convert "triplet_rx"
10422 2018-01-17 Tom Tromey <tom@tromey.com>
10424 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
10426 2018-01-17 Tom Tromey <tom@tromey.com>
10428 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
10429 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
10430 (create_array_type_with_stride): Update.
10431 * dwarf2read.c (set_die_type): Update.
10433 2018-01-17 Tom Tromey <tom@tromey.com>
10435 * dwarf2read.c (delayed_method_info): Remove typedef.
10436 (dwarf2_cu::method_info): Now a std::vector.
10437 (add_to_method_list): Update.
10438 (free_delayed_list): Remove.
10439 (compute_delayed_physnames): Update.
10440 (process_full_comp_unit, process_full_type_unit): Clear the method
10441 list. Remove cleanups.
10442 (psymtab_include_file_name): Add name_holder parameter. Use
10443 unique_xmalloc_ptr.
10444 (dwarf_decode_lines): Update.
10446 2018-01-17 Tom Tromey <tom@tromey.com>
10447 Simon Marchi <simon.marchi@ericsson.com>
10449 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
10450 (dwarf2_per_objfile::free_cached_comp_units)
10451 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10452 (init_cutu_and_read_dies_no_follow): Update.
10453 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
10454 (dwarf2_cu::~dwarf2_cu): New.
10455 (free_heap_comp_unit, free_stack_comp_unit): Remove.
10456 (age_cached_comp_units, free_one_cached_comp_unit): Update.
10458 2018-01-17 Tom Tromey <tom@tromey.com>
10459 Simon Marchi <simon.marchi@ericsson.com>
10461 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
10462 (struct die_reader_specs) <abbrev_table>: New member.
10463 (struct abbrev_table): Add constructor.
10464 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
10465 <abbrev_obstack>: Now an auto_obstack.
10466 (abbrev_table_up): New typedef.
10467 (init_cu_die_reader): Add abbrev_table parameter.
10468 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
10469 Add result_dwo_abbrev_table.
10470 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10471 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
10473 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
10475 (skip_children): Update.
10476 (abbrev_table::alloc_abbrev): Rename from
10477 abbrev_table_alloc_abbrev.
10478 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
10479 (abbrev_table::lookup_abbrev): Rename from
10480 abbrev_table_lookup_abbrev.
10481 (abbrev_table_read_table): Return abbrev_table_up.
10482 (abbrev_table_free, abbrev_table_free_cleanup)
10483 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
10484 (load_partial_dies): Update.
10486 2018-01-17 Tom Tromey <tom@tromey.com>
10488 * dwarf2read.c (dwarf2_compute_name): Update comment.
10489 (read_func_scope, read_variable): Update.
10490 (new_symbol): Remove.
10491 (new_symbol_full): Rename to new_symbol.
10493 2018-01-17 Mike Gulick <mgulick@mathworks.com>
10496 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
10497 a warning instead of throwing an error, set section size to 0 and return
10499 * gdb_bfd.h (gdb_bfd_map_section): Update description.
10501 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10503 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
10505 (linux_ptrace_attach_fail_reason_string): Likewise.
10506 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
10508 (linux_ptrace_attach_fail_reason_string): Likewise.
10509 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
10511 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10513 * linux-nat.c (linux_nat_attach): Remove xstrdup.
10515 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
10518 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
10519 checking for fs_base/gs_base fields in struct user_regs_struct.
10520 * configure: Regenerate.
10522 2018-01-17 Yao Qi <yao.qi@linaro.org>
10524 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
10526 (aarch64_linux_init_abi): Install it to gdbarch hook
10527 gcc_target_options.
10529 2018-01-15 Pedro Alves <palves@redhat.com>
10531 * common/signals-state-save-restore.c
10532 (save_original_signals_state): Fix typos.
10534 2017-01-12 Tom Tromey <tom@tromey.com>
10535 Sergio Durigan Junior <sergiodj@redhat.com>
10537 * Makefile.in (install-only): Install gdb-add-index.
10539 2018-01-12 John Baldwin <jhb@FreeBSD.org>
10541 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
10543 2018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10545 * infrun.c (keep_going_pass_signal): Clear step-over info when
10546 insert_breakpoints fails.
10548 2018-01-11 Pedro Alves <palves@redhat.com>
10551 * infrun.c (resume): Rename to ...
10552 (resume_1): ... this.
10553 (resume): Reimplement as wrapper around resume_1.
10555 2018-01-11 Pedro Alves <palves@redhat.com>
10558 * remote.c (remote_parse_stop_reply): Default to the last-set
10559 general thread instead of to 'magic_null_ptid'.
10561 2018-01-10 Pedro Alves <palves@redhat.com>
10563 * language.h (language_get_symbol_name_matcher): Rename ...
10564 (get_symbol_name_matcher): ... this.
10565 * language.c (language_get_symbol_name_matcher): Ditto.
10566 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
10569 2018-01-10 Pedro Alves <palves@redhat.com>
10573 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
10574 Adjust to use language_get_symbol_name_matcher instead of
10575 language_defn::la_get_symbol_name_matcher.
10576 * language.c (language_get_symbol_name_matcher): If in Ada mode
10577 and the lookup name is a verbatim match, return Ada's matcher.
10578 * language.h (language_get_symbol_name_matcher): Adjust comment.
10579 (ada_lookup_name_info::verbatim_p):: New method.
10581 2018-01-10 Pedro Alves <palves@redhat.com>
10584 * ada-lang.c (ada_collect_symbol_completion_matches): If the
10585 minsym's language is language_auto or language_cplus, pass down
10586 language_ada instead.
10587 * symtab.c (compare_symbol_name): Don't frob symbol language here.
10589 2018-01-10 Pedro Alves <palves@redhat.com>
10592 * minsyms.c (linkage_name_str): New function.
10593 (iterate_over_minimal_symbols): Use it.
10595 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10597 * NEWS: Document that 'info proc' now works on FreeBSD.
10599 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10601 * configure.ac: Check for kinfo_getfile in libutil.
10602 * configure: Regenerate.
10603 * config.in: Regenerate.
10604 * fbsd-nat.c: Include "fbsd-tdep.h".
10605 (fbsd_fetch_cmdline): New.
10606 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
10607 rather than calling error.
10608 (fbsd_info_proc): New.
10609 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
10610 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
10611 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
10613 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10615 * fbsd-nat.c (struct free_deleter): Remove.
10616 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
10618 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10620 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
10621 NULL for an empty pathname.
10623 2018-01-09 John Baldwin <jhb@FreeBSD.org>
10625 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
10626 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
10627 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
10628 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
10629 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
10630 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
10631 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
10632 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
10633 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
10634 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
10635 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
10636 (fbsd_core_fetch_timeval, fbsd_print_sigset)
10637 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
10638 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
10639 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
10641 2018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
10643 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
10644 (gnu_xfer_auxv): New function.
10645 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
10646 TARGET_OBJECT_AUXV.
10648 2018-01-08 Yao Qi <yao.qi@linaro.org>
10649 Simon Marchi <simon.marchi@ericsson.com>
10651 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
10653 (COMMON_OBS): Remove selftest.o.
10654 * configure.ac: Append selftest-arch.c and common/selftest.c to
10655 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
10656 * configure: Re-generated.
10657 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
10659 (maintenance_info_selftests): Likewise.
10661 2018-01-08 Xavier Roirand <roirand@adacore.com>
10663 * ada-valprint.c (val_print_packed_array_elements): Use
10664 proper number of elements when printing an array indexed
10665 by an enumeration type.
10667 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10669 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
10670 (dw2_get_file_names_reader): Adjust.
10671 (lookup_dwo_signatured_type): Adjust.
10672 (lookup_dwp_signatured_type): Adjust.
10673 (lookup_signatured_type): Adjust.
10674 (create_type_unit_group): Adjust.
10675 (get_type_unit_group): Adjust.
10676 (process_psymtab_comp_unit_reader): Adjust.
10677 (build_type_psymtabs_reader): Adjust.
10678 (scan_partial_symbols): Adjust.
10679 (add_partial_symbol): Adjust.
10680 (add_partial_subprogram): Adjust.
10681 (peek_die_abbrev): Adjust.
10682 (fixup_go_packaging): Adjust.
10683 (process_imported_unit_die): Adjust.
10684 (dwarf2_compute_name): Adjust.
10685 (dwarf2_physname): Adjust.
10686 (read_import_statement): Adjust.
10687 (handle_DW_AT_stmt_list): Adjust.
10688 (read_file_scope): Adjust.
10689 (read_func_scope): Adjust.
10690 (read_lexical_block_scope): Adjust.
10691 (read_call_site_scope): Adjust.
10692 (read_variable): Adjust.
10693 (dwarf2_rnglists_process): Adjust.
10694 (dwarf2_ranges_process): Adjust.
10695 (dwarf2_ranges_read): Adjust.
10696 (dwarf2_get_pc_bounds): Adjust.
10697 (dwarf2_record_block_ranges): Adjust.
10698 (dwarf2_add_field): Adjust.
10699 (dwarf2_add_member_fn): Adjust.
10700 (read_structure_type): Adjust.
10701 (process_structure_scope): Adjust.
10702 (read_enumeration_type): Adjust.
10703 (read_array_type): Adjust.
10704 (mark_common_block_symbol_computed): Adjust.
10705 (read_common_block): Adjust.
10706 (read_namespace_type): Adjust.
10707 (read_namespace): Adjust.
10708 (read_module_type): Adjust.
10709 (read_tag_pointer_type): Adjust.
10710 (read_tag_ptr_to_member_type): Adjust.
10711 (read_tag_string_type): Adjust.
10712 (read_subroutine_type): Adjust.
10713 (read_typedef): Adjust.
10714 (read_base_type): Adjust.
10715 (attr_to_dynamic_prop): Adjust.
10716 (read_subrange_type): Adjust.
10717 (read_unspecified_type): Adjust.
10718 (dwarf2_read_abbrevs): Adjust.
10719 (load_partial_dies): Adjust.
10720 (read_partial_die): Adjust.
10721 (find_partial_die): Adjust.
10722 (guess_partial_die_structure_name): Adjust.
10723 (fixup_partial_die): Adjust.
10724 (read_attribute_value): Adjust.
10725 (read_addr_index): Adjust.
10726 (read_addr_index_from_leb128): Adjust.
10727 (read_str_index): Adjust.
10728 (dwarf2_string_attr): Adjust.
10729 (get_debug_line_section): Adjust.
10730 (dwarf_decode_line_header): Adjust.
10731 (lnp_state_machine::check_line_address): Adjust.
10732 (dwarf_decode_lines_1): Adjust.
10733 (dwarf_decode_lines): Adjust.
10734 (dwarf2_start_symtab): Adjust.
10735 (var_decode_location): Adjust.
10736 (new_symbol_full): Adjust.
10737 (dwarf2_const_value_data): Adjust.
10738 (dwarf2_const_value_attr): Adjust.
10739 (dwarf2_const_value): Adjust.
10740 (die_type): Adjust.
10741 (die_containing_type): Adjust.
10742 (build_error_marker_type): Adjust.
10743 (lookup_die_type): Adjust.
10744 (guess_full_die_structure_name): Adjust.
10745 (anonymous_struct_prefix): Adjust.
10746 (determine_prefix): Adjust.
10747 (dwarf2_name): Adjust.
10748 (follow_die_ref_or_sig): Adjust.
10749 (follow_die_offset): Adjust.
10750 (follow_die_ref): Adjust.
10751 (follow_die_sig_1): Adjust.
10752 (follow_die_sig): Adjust.
10753 (get_signatured_type): Adjust.
10754 (get_DW_AT_signature_type): Adjust.
10755 (decode_locdesc): Adjust.
10756 (dwarf_decode_macros): Adjust.
10757 (cu_debug_loc_section): Adjust.
10758 (fill_in_loclist_baton): Adjust.
10759 (dwarf2_symbol_mark_computed): Adjust.
10760 (init_one_comp_unit): Don't assign
10761 dwarf2_cu::dwarf2_per_objfile.
10762 (set_die_type): Adjust.
10764 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10766 * dwarf2read.c (struct mapped_debug_names): Add constructor.
10767 <dwarf2_per_objfile>: New field.
10768 (dwarf2_per_objfile): Remove global.
10769 (get_dwarf2_per_objfile): New function.
10770 (set_dwarf2_per_objfile): New function.
10771 (dwarf2_build_psymtabs_hard): Change objfile parameter to
10772 dwarf2_per_objfile.
10773 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10774 (read_abbrev_offset): Likewise.
10775 (read_indirect_string): Likewise.
10776 (read_indirect_line_string): Likewise.
10777 (read_indirect_string_at_offset): Likewise.
10778 (read_indirect_string_from_dwz): Likewise.
10779 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10780 dwarf2_per_objfile.
10781 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10782 (create_all_comp_units): Change objfile parameter to
10783 dwarf2_per_objfile.
10784 (create_all_type_units): Likewise.
10785 (process_queue): Add dwarf2_per_objfile parameter.
10786 (read_and_check_comp_unit_head): Likewise.
10787 (lookup_dwo_unit_in_dwp): Likewise.
10788 (get_dwp_file): Likewise.
10789 (process_cu_includes): Likewise.
10790 (struct free_dwo_file_cleanup_data): New struct.
10791 (dwarf2_has_info): Use get_dwarf2_per_objfile and
10792 set_dwarf2_per_objfile.
10793 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
10794 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
10795 context, adjust calls.
10796 (dw2_instantiate_symtab): Likewise.
10797 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
10798 (dw2_get_cu): Likewise.
10799 (create_cu_from_index_list): Change objfile parameter to
10800 dwarf2_per_objfile.
10801 (create_cus_from_index_list): Get dwarf2_per_objfile from
10802 context, adjust calls.
10803 (create_cus_from_index): Likewise.
10804 (create_signatured_type_table_from_index): Change objfile
10805 parameter to dwarf2_per_objfile.
10806 (create_signatured_type_table_from_debug_names): Change objfile
10807 parameter to dwarf2_per_objfile.
10808 (create_addrmap_from_index): Likewise.
10809 (create_addrmap_from_aranges): Likewise.
10810 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
10811 (dw2_setup): Remove.
10812 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
10814 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
10815 get_dwarf2_per_objfile.
10816 (dw2_forget_cached_source_info): Likewise.
10817 (dw2_map_symtabs_matching_filename): Likewise.
10818 (struct dw2_symtab_iterator) <index>: Remove.
10819 <dwarf2_per_objfile>: New field.
10820 (dw2_symtab_iter_init): Replace index parameter with
10821 dwarf2_per_objfile.
10822 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
10823 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
10824 (dw2_print_stats): Likewise.
10825 (dw2_dump): Likewise.
10826 (dw2_expand_symtabs_for_function): Likewise.
10827 (dw2_expand_all_symtabs): Likewise.
10828 (dw2_expand_symtabs_with_fullname): Likewise.
10829 (dw2_expand_marked_cus): Replace index and objfile parameters
10830 with dwarf2_per_objfile.
10831 (dw_expand_symtabs_matching_file_matcher): Add
10832 dwarf2_per_objfile parameter and adjust calls.
10833 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
10835 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
10836 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
10838 (create_cus_from_debug_names_list): Replace objfile parameter
10839 with dwarf2_per_objfile and adjust calls.
10840 (create_cus_from_debug_names): Likewise.
10841 (dwarf2_read_debug_names): Likewise.
10842 (mapped_debug_names::namei_to_name): Adjust call.
10843 (dw2_debug_names_iterator::next): Likewise.
10844 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
10845 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
10846 (dw2_debug_names_dump): Likewise.
10847 (dw2_debug_names_expand_symtabs_for_function): Likewise.
10848 (dw2_debug_names_expand_symtabs_matching): Likewise.
10849 (dwarf2_initialize_objfile): Likewise.
10850 (dwarf2_build_psymtabs): Likewise.
10851 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
10853 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
10854 (read_and_check_comp_unit_head): Likewise.
10855 (read_abbrev_offset): Likewise.
10856 (create_debug_type_hash_table): Likewise.
10857 (create_debug_types_hash_table): Likewise.
10858 (create_all_type_units): Replace objfile parameter with
10859 dwarf2_per_objfile.
10860 (add_type_unit): Add dwarf2_per_objfile parameter.
10861 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
10862 with dwarf2_per_objfile.
10863 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
10864 (lookup_dwp_signatured_type): Likewise.
10865 (lookup_signatured_type): Likewise.
10866 (read_cutu_die_from_dwo): Likewise.
10867 (init_tu_and_read_dwo_dies): Likewise.
10868 (init_cutu_and_read_dies): Likewise.
10869 (init_cutu_and_read_dies_no_follow): Likewise.
10870 (allocate_type_unit_groups_table): Add objfile parameter.
10871 (create_type_unit_group): Use dwarf2_per_objfile from cu.
10872 (get_type_unit_group): Likewise.
10873 (process_psymtab_comp_unit): Update call.
10874 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
10875 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
10876 (print_tu_stats): Likewise.
10877 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
10878 in void* parameter.
10879 (build_type_psymtabs): Change objfile parameter to
10880 dwarf2_per_objfile.
10881 (process_skeletonless_type_unit): Use dwarf2_per_objfile
10882 passed in void* parameter.
10883 (process_skeletonless_type_units): Change objfile parameter to
10884 dwarf2_per_objfile.
10885 (set_partial_user): Likewise.
10886 (dwarf2_build_psymtabs_hard): Likewise.
10887 (read_comp_units_from_section): Likewise.
10888 (create_all_comp_units): Likewise.
10889 (scan_partial_symbols): Update calls.
10890 (add_partial_symbol): Likewise.
10891 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
10892 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
10893 (process_queue): Add dwarf2_per_objfile parameter.
10894 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
10895 (compute_compunit_symtab_includes): Likewise.
10896 (process_cu_includes): Add dwarf2_per_objfile parameter.
10897 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
10898 (process_full_type_unit): Likewise.
10899 (process_imported_unit_die): Update call.
10900 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
10901 (read_file_scope): Likewise.
10902 (allocate_dwo_file_hash_table): Add objfile parameter.
10903 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
10904 (create_cus_hash_table): Likewise.
10905 (create_dwp_hash_table): Likewise.
10906 (create_dwo_unit_in_dwp_v1): Likewise.
10907 (create_dwp_v2_section): Likewise.
10908 (create_dwo_unit_in_dwp_v2): Likewise.
10909 (lookup_dwo_unit_in_dwp): Likewise.
10910 (try_open_dwop_file): Likewise.
10911 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
10912 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
10913 cleanup to include a reference to dwarf2_per_objfile.
10914 (open_dwp_file): Add dwarf2_per_objfile parameter.
10915 (open_and_init_dwp_file): Likewise.
10916 (get_dwp_file): Likewise.
10917 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
10918 (queue_and_load_all_dwo_tus): Update call.
10919 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
10921 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
10922 (dwarf2_ranges_process): Likewise.
10923 (dwarf2_get_pc_bounds): Likewise.
10924 (mark_common_block_symbol_computed): Likewise.
10925 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10926 (dwarf2_read_abbrevs): Update call.
10927 (read_partial_die): Use dwarf2_per_objfile from cu.
10928 (find_partial_die): Likewise.
10929 (fixup_partial_die): Likewise.
10930 (read_attribute_value): Likewise.
10931 (read_indirect_string_at_offset_from): Add objfile parameter.
10932 (read_indirect_string_at_offset): Add dwarf2_per_objfile
10934 (read_indirect_string_from_dwz): Add objfile parameter.
10935 (read_indirect_string): Add objfile parameter.
10936 (read_addr_index_1): Add dwarf2_per_objfile parameter.
10937 (read_addr_index): Use dwarf2_per_objfile from cu.
10938 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
10940 (read_str_index): Use dwarf2_per_objfile from cu.
10941 (get_debug_line_section): Likewise.
10942 (read_formatted_entries): Add dwarf2_per_objfile parameter.
10943 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
10944 (new_symbol_full): Use dwarf2_per_objfile from cu.
10945 (build_error_marker_type): Likewise.
10946 (lookup_die_type): Likewise.
10947 (determine_prefix): Likewise.
10948 (follow_die_offset): Likewise.
10949 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
10950 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
10951 (dwarf2_fetch_die_type_sect_off): Likewise.
10952 (dwarf2_get_die_type): Likewise.
10953 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
10954 (get_signatured_type): Likewise.
10955 (get_DW_AT_signature_type): Likewise.
10956 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
10957 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
10958 (cu_debug_loc_section): Likewise.
10959 (fill_in_loclist_baton): Likewise.
10960 (dwarf2_symbol_mark_computed): Likewise.
10961 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10962 dwarf2_per_objfile.
10963 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
10965 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10966 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
10967 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
10968 (set_die_type): Use dwarf2_free_objfile from cu.
10969 (get_die_type_at_offset): Likewise.
10970 (dwarf2_per_objfile_free): Don't assign global variable.
10971 (debug_names) <constructor>: Add dwarf2_per_objfile
10972 parameter, update m_debugstrlookup construction.
10973 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
10975 <m_dwarf2_per_objfile>: New field.
10976 <lookup>: Use m_dwarf2_per_objfile.
10977 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
10978 (psyms_seen_size): Likewise.
10979 (write_gdbindex): Replace objfile parameter with
10980 dwarf2_per_objfile.
10981 (write_debug_names): Likewise.
10982 (write_psymtabs_to_index): Likewise.
10983 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
10986 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10988 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
10989 <dwarf2_per_objfile>: New field.
10990 (struct dwarf2_per_cu_data) <objfile>: Remove.
10991 <dwarf2_per_objfile>: New field.
10992 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
10994 (create_signatured_type_table_from_index): Likewise.
10995 (create_debug_type_hash_table): Likewise.
10996 (fill_in_sig_entry_from_dwo_entry): Likewise.
10997 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
10998 (create_type_unit_group): Assign dwarf2_per_objfile instead of
11000 (create_partial_symtab): Access objfile through
11001 dwarf2_per_objfile.
11002 (process_psymtab_comp_unit_reader): Likewise.
11003 (read_comp_units_from_section): Likewise.
11004 (scan_partial_symbols): Likewise.
11005 (add_partial_symbol): Likewise.
11006 (add_partial_subprogram): Likewise.
11007 (peek_die_abbrev): Likewise.
11008 (fixup_go_packaging): Likewise.
11009 (process_full_comp_unit): Likewise.
11010 (process_full_type_unit): Likewise.
11011 (process_imported_unit_die): Likewise.
11012 (dwarf2_compute_name): Likewise.
11013 (dwarf2_physname): Likewise.
11014 (read_import_statement): Likewise.
11015 (create_cus_hash_table): Assign dwarf2_physname instead of
11017 (read_func_scope): Access objfile through dwarf2_per_objfile.
11018 (read_lexical_block_scope): Likewise.
11019 (read_call_site_scope): Likewise.
11020 (read_variable): Likewise.
11021 (dwarf2_rnglists_process): Likewise.
11022 (dwarf2_ranges_process): Likewise.
11023 (dwarf2_ranges_read): Likewise.
11024 (dwarf2_record_block_ranges): Likewise.
11025 (dwarf2_add_field): Likewise.
11026 (dwarf2_add_member_fn): Likewise.
11027 (read_structure_type): Likewise.
11028 (process_structure_scope): Likewise.
11029 (read_enumeration_type): Likewise.
11030 (read_array_type): Likewise.
11031 (read_common_block): Likewise.
11032 (read_namespace_type): Likewise.
11033 (read_namespace): Likewise.
11034 (read_module_type): Likewise.
11035 (read_tag_pointer_type): Likewise.
11036 (read_tag_ptr_to_member_type): Likewise.
11037 (read_tag_string_type): Likewise.
11038 (read_subroutine_type): Likewise.
11039 (read_typedef): Likewise.
11040 (read_base_type): Likewise.
11041 (attr_to_dynamic_prop): Likewise.
11042 (read_subrange_type): Likewise.
11043 (read_unspecified_type): Likewise.
11044 (load_partial_dies): Likewise.
11045 (read_partial_die): Likewise.
11046 (find_partial_die): Likewise.
11047 (guess_partial_die_structure_name): Likewise.
11048 (fixup_partial_die): Likewise.
11049 (read_attribute_value): Likewise.
11050 (read_addr_index_from_leb128): Likewise.
11051 (dwarf2_read_addr_index): Likewise.
11052 (dwarf2_string_attr): Likewise.
11053 (lnp_state_machine::check_line_address): Likewise.
11054 (dwarf_decode_lines_1): Likewise.
11055 (dwarf_decode_lines): Likewise.
11056 (dwarf2_start_symtab): Likewise.
11057 (var_decode_location): Likewise.
11058 (new_symbol_full): Likewise.
11059 (dwarf2_const_value_data): Likewise.
11060 (dwarf2_const_value_attr): Likewise.
11061 (dwarf2_const_value): Likewise.
11062 (die_type): Likewise.
11063 (die_containing_type): Likewise.
11064 (lookup_die_type): Likewise.
11065 (guess_full_die_structure_name): Likewise.
11066 (anonymous_struct_prefix): Likewise.
11067 (dwarf2_name): Likewise.
11068 (follow_die_ref_or_sig): Likewise.
11069 (follow_die_offset): Likewise.
11070 (follow_die_ref): Likewise.
11071 (dwarf2_fetch_die_loc_sect_off): Likewise.
11072 (dwarf2_fetch_constant_bytes): Likewise.
11073 (dwarf2_fetch_die_type_sect_off): Likewise.
11074 (dwarf2_get_die_type): Likewise.
11075 (follow_die_sig): Likewise.
11076 (decode_locdesc): Likewise.
11077 (dwarf2_per_cu_objfile): Likewise.
11078 (dwarf2_per_cu_text_offset): Likewise.
11079 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
11081 (set_die_type): Access objfile through
11082 dwarf2_per_objfile.
11084 2018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11086 * valprint.c (converted_character_d): Remove typedef.
11087 (DEF_VEC_O (converted_character_d)): Remove.
11088 (count_next_character): Use std::vector.
11089 (print_converted_chars_to_obstack): Likewise.
11090 (generic_printstr): Likewise.
11092 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11094 * xml-support.h (struct gdb_xml_value): Add constructor.
11095 <value>: Change type to unique_xmalloc_ptr.
11096 (gdb_xml_value_s): Remove typedef.
11097 (DEF_VEC_O (gdb_xml_value_s)): Remove.
11098 (gdb_xml_element_start_handler): Change parameter type to
11100 (xml_find_attribute): Likewise.
11101 * xml-support.c (xml_find_attribute): Change parameter type to
11102 std::vector and adjust.
11103 (gdb_xml_values_cleanup): Remove.
11104 (gdb_xml_parser::start_element): Adjust to std::vector.
11105 (xinclude_start_include): Change paraeter type to std::vector
11107 * btrace.c (check_xml_btrace_version): Likewise.
11108 (parse_xml_btrace_block): Likewise.
11109 (parse_xml_btrace_pt_config_cpu): Likewise.
11110 (parse_xml_btrace_pt): Likewise.
11111 (parse_xml_btrace_conf_bts): Likewise.
11112 (parse_xml_btrace_conf_pt): Likewise.
11113 * memory-map.c (memory_map_start_memory): Likewise.
11114 (memory_map_start_property): Likewise.
11115 * osdata.c (osdata_start_osdata): Likewise.
11116 (osdata_start_item): Likewise.
11117 (osdata_start_column): Likewise.
11118 * remote.c (start_thread): Likewise.
11119 * solib-aix.c (library_list_start_library): Likewise.
11120 (library_list_start_list): Likewise.
11121 * solib-svr4.c (library_list_start_library): Likewise.
11122 (svr4_library_list_start_list): Likewise.
11123 * solib-target.c (library_list_start_segment): Likewise.
11124 (library_list_start_section): Likewise.
11125 (library_list_start_library): Likewise.
11126 (library_list_start_list): Likewise.
11127 * tracepoint.c (traceframe_info_start_memory): Likewise.
11128 (traceframe_info_start_tvar): Likewise.
11129 * xml-syscall.c (syscall_start_syscall): Likewise.
11130 * xml-tdesc.c (tdesc_start_target): Likewise.
11131 (tdesc_start_feature): Likewise.
11132 (tdesc_start_reg): Likewise.
11133 (tdesc_start_union): Likewise.
11134 (tdesc_start_struct): Likewise.
11135 (tdesc_start_flags): Likewise.
11136 (tdesc_start_enum): Likewise.
11137 (tdesc_start_field): Likewise.
11138 (tdesc_start_enum_value): Likewise.
11139 (tdesc_start_vector): Likewise.
11141 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11143 * extension.h (struct xmethod_worker) <clone>: Remove.
11144 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
11146 (python_xmethod_worker::clone): Remove.
11147 * valops.c (find_overload_match): Use std::move instead of
11150 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11152 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
11153 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
11154 <free_xmethod_worker_data>: Remove.
11155 <get_matching_xmethod_workers>: Chance VEC to std::vector.
11156 <get_xmethod_arg_types>: Remove.
11157 <get_xmethod_result_type>: Remove.
11158 <invoke_xmethod>: Remove.
11159 * extension.c (new_xmethod_worker): Remove.
11160 (clone_xmethod_worker): Remove.
11161 (get_matching_xmethod_workers): Return void, pass std::vector by
11163 (get_xmethod_arg_types): Rename to...
11164 (xmethod_worker::get_arg_types): ... this, and adjust.
11165 (get_xmethod_result_type): Rename to...
11166 (xmethod_worker::get_result_type): ... this, and adjust.
11167 (invoke_xmethod): Remove.
11168 (free_xmethod_worker): Remove.
11169 (free_xmethod_worker_vec): Remove.
11170 * extension.h (enum ext_lang_rc): Move here from
11172 (struct xmethod_worker): Add constructor and destructor.
11175 <invoke, clone, do_get_result_type, do_get_arg_types>: New
11176 virtual pure methods.
11177 <get_arg_types, get_result_type>: New methods.
11178 (xmethod_worker_ptr): Remove typedef.
11179 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
11180 (xmethod_worker_vec): Remove typedef.
11181 (xmethod_worker_up): New typedef.
11182 (invoke_xmethod): Remove.
11183 (clone_xmethod_worker): Remove.
11184 (free_xmethod_worker): Remove.
11185 (free_xmethod_worker_vec): Remove.
11186 (get_xmethod_arg_types): Remove.
11187 (get_xmethod_result_type): Remove.
11188 * valops.c (find_method_list): Use std::vector, don't use
11189 intermediate vector.
11190 (value_find_oload_method_list): Use std::vector.
11191 (find_overload_match): Use std::vector.
11192 (find_oload_champ): Use std::vector.
11193 * value.c (value_free): Use operator delete.
11194 (value_of_xmethod): Rename to...
11195 (value_from_xmethod): ... this. Don't assign
11196 xmethod_worker::value, take rvalue-reference.
11197 (result_type_of_xmethod): Adjust.
11198 (call_xmethod): Adjust.
11199 * value.h: Include extension.h.
11200 (struct xmethod_worker): Don't forward-declare.
11201 (value_of_xmethod): Rename to...
11202 (value_from_xmethod): ... this, take rvalue-reference.
11203 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
11204 (struct python_xmethod_worker): ... this, add constructor and
11206 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
11207 (gdbpy_free_xmethod_worker_data): Rename to...
11208 (python_xmethod_worker::~python_xmethod_worker): ... this and
11210 (gdbpy_clone_xmethod_worker_data): Rename to...
11211 (python_xmethod_worker::clone): ... this and adjust.
11212 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
11214 (gdbpy_get_xmethod_arg_types): Rename to...
11215 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
11216 (gdbpy_get_xmethod_result_type): Rename to...
11217 (python_xmethod_worker::do_get_result_type): ... this and
11219 (gdbpy_invoke_xmethod): Rename to...
11220 (python_xmethod_worker::invoke): ... this and adjust.
11221 (new_python_xmethod_worker): Rename to...
11222 (python_xmethod_worker::python_xmethod_worker): ... this and
11224 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
11226 (gdbpy_free_xmethod_worker_data): Remove.
11227 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11228 (gdbpy_get_xmethod_arg_types): Remove.
11229 (gdbpy_get_xmethod_result_type): Remove.
11230 (gdbpy_invoke_xmethod): Remove.
11231 * python/python.c (python_extension_ops): Remove obsolete
11234 2018-01-05 Pedro Alves <palves@redhat.com>
11237 * common/signals-state-save-restore.c
11238 (save_original_signals_state): New parameter 'quiet'. Warn if we
11239 find a custom handler preinstalled, instead of internal erroring.
11240 But only warn if !quiet.
11241 * common/signals-state-save-restore.h
11242 (save_original_signals_state): New parameter 'quiet'.
11243 * main.c (captured_main_1): Move save_original_signals_state call
11244 after option handling, and pass QUIET.
11246 2018-01-05 Pedro Alves <palves@redhat.com>
11248 * spu-tdep.c (spu_catch_start): Pass
11249 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11251 2018-01-05 Pedro Alves <palves@redhat.com>
11254 * ada-lang.c (literal_symbol_name_matcher): New function.
11255 (ada_get_symbol_name_matcher): Use it for
11256 symbol_name_match_type::SEARCH_NAME.
11257 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11258 it down instead of assuming symbol_name_match_type::FULL.
11259 * block.h (block_lookup_symbol): New parameter 'match_type'.
11260 * c-valprint.c (print_unpacked_pointer): Use
11261 lookup_symbol_search_name instead of lookup_symbol.
11262 * compile/compile-object-load.c (get_out_value_type): Pass down
11263 symbol_name_match_type::SEARCH_NAME.
11264 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11265 symbol_name_match_type::FULL.
11266 * cp-support.c (cp_get_symbol_name_matcher): Handle
11267 symbol_name_match_type::SEARCH_NAME.
11268 * infrun.c (insert_exception_resume_breakpoint): Use
11269 lookup_symbol_search_name.
11270 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11271 * psymtab.c (maintenance_check_psymtabs): Use
11272 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11273 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11274 SYMBOL_SEARCH_NAME.
11275 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11276 if symbol_name_match_type::SEARCH_NAME.
11277 (lookup_symbol_in_language): Pass down
11278 symbol_name_match_type::FULL.
11279 (lookup_symbol_search_name): New.
11280 (lookup_language_this): Pass down
11281 symbol_name_match_type::SEARCH_NAME.
11282 (lookup_symbol_aux, lookup_local_symbol): New parameter
11283 'match_type'. Pass it down.
11284 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11285 (lookup_symbol_search_name): New declaration.
11286 (lookup_symbol_in_block): New 'match_type' parameter.
11288 2018-01-05 Pedro Alves <palves@redhat.com>
11291 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11293 (ada_lookup_symbol): Reimplement in terms of
11294 ada_lookup_symbol_list, bits factored out from
11295 ada_lookup_encoded_symbol.
11297 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11299 * ada-exp.y (write_object_renaming): When subscripting an array
11300 using a symbol as the index, pass the block in call to
11301 ada_lookup_encoded_symbol when looking that symbol up.
11303 2018-01-05 Jerome Guitton <guitton@adacore.com>
11305 * ada-lang.c (ada_array_length): Use ada_index_type instead of
11308 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11310 * ada-lang.c (ada_to_fixed_value_create): Add handling of
11311 the case where VALUE_LVAL (val0) is not lval_memory.
11313 2018-01-05 Xavier Roirand <roirand@adacore.com>
11315 * ada-valprint.c (print_optional_low_bound): Handle
11316 character-indexed array printing like boolean-indexed array
11319 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11321 * NEWS: Create a new section for the next release branch.
11322 Rename the section of the current branch, now that it has
11325 2018-01-05 Joel Brobecker <brobecker@adacore.com>
11327 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
11328 * version.in: Bump version to 8.1.50.DATE-git.
11330 2018-01-03 Xavier Roirand <roirand@adacore.com>
11332 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
11334 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
11336 (default_exception_support_info) <catch_handlers_sym>: Add field.
11337 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
11338 (ada_exception_name_addr_1): Add "catch handlers" handling.
11339 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
11340 Update all callers.
11341 (create_excep_cond_exprs) <ex>: Add parameter.
11342 (re_set_exception): Update create_excep_cond_exprs call.
11343 (print_it_exception, print_one_exception, print_mention_exception)
11344 (print_recreate_exception): Add "catch handler" handling.
11345 (allocate_location_catch_handlers, re_set_catch_handlers)
11346 (check_status_catch_handlers, print_it_catch_handlers)
11347 (print_one_catch_handlers, print_mention_catch_handlers)
11348 (print_recreate_catch_handlers): New function.
11349 (catch_handlers_breakpoint_ops): New variable.
11350 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
11351 Add parameter. Add "catch handler" handling.
11352 (ada_exception_sym_name, ada_exception_breakpoint_ops):
11353 Add "catch handler" handling.
11354 (ada_exception_catchpoint_cond_string): Add "catch handler"
11356 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
11358 (catch_ada_handlers_command): New function.
11359 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
11360 operations structure.
11361 (_initialize_ada_language): Add "catch handlers" command entry.
11362 * NEWS: Document "catch handlers" feature.
11364 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11366 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
11367 account when creating the array type of the slice.
11368 (ada_value_slice): Likewise.
11370 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11372 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
11374 (create_array_type_with_stride): Add byte_stride_prop parameter.
11375 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
11376 New parameter. Update all callers in this file.
11377 (array_type_has_dynamic_stride): New function.
11378 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
11379 of arrays with dynamic byte strides.
11380 * dwarf2read.c (read_array_type): Add support for dynamic
11381 DW_AT_byte_stride attributes.
11383 2018-01-02 Joel Brobecker <brobecker@adacore.com>
11385 * dwarf2read.c (read_unspecified_type): Treat
11386 DW_TAG_enumeration_type DIEs from Ada units as stubs.
11388 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11390 Update copyright year range in all GDB files.
11392 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11394 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
11395 and gdb/testsuite/gdb.base/step-line.c.
11397 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11399 * copyright.py (main): Dump the contents of
11400 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
11401 even if BY_HAND is empty.
11403 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11405 * top.c (print_gdb_version): Update Copyright year in version
11408 2018-01-01 Joel Brobecker <brobecker@adacore.com>
11410 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
11412 For older changes see ChangeLog-2017.
11418 version-control: never