RISC-V: Add linux target support.
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
90ad3654
JW
12018-08-09 Jim Wilson <jimw@sifive.com>
2
3 * riscv-linux-tdep.c: New file.
4
aff4e175
AB
52018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
6
7 * infrun.c (resume): Make static, add forward declaration.
8 (proceed): Update header comment.
9 * infrun.h (resume): Delete declaration.
10
06ab9219
TT
112018-08-09 Tom Tromey <tom@tromey.com>
12
13 * riscv-tdep.h: Minor formatting fixes.
14
83c8d318
SM
152018-08-09 Simon Marchi <simon.marchi@ericsson.com>
16
17 * common/scoped_mmap.c (mmap_file): Silence ARI warning.
18 * dwarf-index-cache.c (create_dir_and_check): Likewise.
19 (test_mkdir_recursive): Likewise.
20 * dwarf-index-write.c (write_psymtabs_to_index): Likewise.
21
5ff2bbae
AB
222018-08-09 Andrew Burgess <andrew.burgess@embecosm.com>
23
24 * valarith.c (value_subscripted_rvalue): If an array is not in
25 memory, and we don't know the upper bound, then we can't know that
26 the requested element exists or not.
27
fdbac7d8
SM
282018-08-08 Simon Marchi <simon.marchi@ericsson.com>
29
30 * target.c (str_comma_list_concat_elem): Fix typo in comment.
31 (target_options_to_string): Add comment.
32
83202f7a
TT
332018-08-08 Tom Tromey <tom@tromey.com>
34
35 * unittests/scoped_mmap-selftests.c: Check result of "write".
36
411baa47
JW
372018-08-08 Jim Wilson <jimw@sifive.com>
38
5c720ed8
JW
39 * riscv-tdep.c (enum opcode): Add jump, branch, lr, and sc opcodes.
40 (decode_register_index_short): New.
41 (decode_j_type_insn, decode_cj_type_insn): New.
42 (decode_b_type_insn, decode_cb_type_insn): New.
43 (riscv_insn::decode): Add support for jumps, branches, lr, and sc. New
44 local xlen. Check xlen when decoding ambiguous compressed insns. In
45 compressed decode, use is_c_lui_insn instead of is_lui_insn, and
46 is_c_sw_insn instead of is_sw_insn.
47 (riscv_next_pc, riscv_next_pc_atomic_sequence): New.
48 (riscv_software_single_step): New.
49 * riscv-tdep.h (riscv_software_single_step): Declare.
50
411baa47
JW
51 * riscv-tdep.c (riscv_isa_xlen): Drop static.
52 * riscv-tdep.h (riscv_isa_xlen): Add extern declaration.
53
9d4a934c
AB
542018-08-08 Andrew Burgess <andrew.burgess@embecosm.com>
55
56 PR gdb/18050:
57 * target.c (dispose_inferior): Don't dispose of inferiors that are
58 already killed.
59
ff36536c
SN
602018-08-08 Szabolcs Nagy <szabolcs.nagy@arm.com>
61
62 * remote.c (remote_target::download_tracepoint): Change char* to
63 const char*.
64
09ce46f2
SM
652018-08-07 Simon Marchi <simon.marchi@polymtl.ca>
66
67 * target.h (target_options_to_string): Return an std::string.
68 * target.c (str_comma_list_concat_elem): Return void, use
69 std::string.
70 (do_option): Likewise.
71 (target_options_to_string): Return an std::string.
72 * linux-nat.c (linux_nat_target::wait): Adjust.
73 * target-debug.h (target_debug_print_options): Adjust.
74
9c612964
TT
752018-08-07 Tom Tromey <tom@tromey.com>
76
77 * Makefile.in (CPPFLAGS): New variable.
78 (INTERNAL_CPPFLAGS): Use it.
79
7d11235d
SM
802018-08-07 Simon Marchi <simon.marchi@ericsson.com>
81
82 * NEWS: Mention the index cache.
83
87d6a7aa
SM
842018-08-07 Simon Marchi <simon.marchi@ericsson.com>
85
86 * common/pathstuff.h (get_standard_cache_dir): New.
87 * common/pathstuff.c (get_standard_cache_dir): New.
88 * build-id.h (build_id_to_string): New.
89 * dwarf-index-common.h (INDEX4_SUFFIX, INDEX5_SUFFIX,
90 DEBUG_STR_SUFFIX): Move to here.
91 * dwarf-index-write.c (INDEX4_SUFFIX, INDEX5_SUFFIX,
92 DEBUG_STR_SUFFIX): Move from there.
93 (write_psymtabs_to_index): Make non-static, add basename
94 parameter. Write to temporary files, rename when done.
95 (save_gdb_index_command): Adjust call to
96 write_psymtabs_to_index.
97 * dwarf2read.h (dwarf2_per_objfile) <index_cache_res>: New
98 field.
99 * dwarf2read.c (dwz_file) <index_cache_res>: New field.
100 (get_gdb_index_contents_from_cache): New.
101 (get_gdb_index_contents_from_cache_dwz): New.
102 (dwarf2_initialize_objfile): Read index from cache.
103 (dwarf2_build_psymtabs): Save to index.
104 * dwarf-index-cache.h: New file.
105 * dwarf-index-cache.c: New file.
106 * dwarf-index-write.h: New file.
107
8a99096f
SM
1082018-08-07 Simon Marchi <simon.marchi@ericsson.com>
109
110 * gnulib/aclocal.m4: Re-generate.
111 * gnulib/config.in: Re-generate.
112 * gnulib/configure: Re-generate.
113 * gnulib/import/Makefile.am: Re-generate.
114 * gnulib/import/Makefile.in: Re-generate.
115 * gnulib/import/m4/gnulib-cache.m4: Re-generate.
116 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
117 * gnulib/import/m4/mkdir.m4: New file.
118 * gnulib/import/mkdir.c: New file.
119 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkdir
120 module.
121
5c831bb1
SM
1222018-08-07 Simon Marchi <simon.marchi@ericsson.com>
123
124 * Makefile.in (COMMON_SFILES): Add common/scoped_mmap.c.
125 * common/scoped_mmap.c: New file.
126 * common/scoped_mmap.h (destroy): New method.
127 (~scoped_mmap, reset): Use destroy.
128 (scoped_mmap): New move constructor.
129 (mmap_file): New declaration.
130 * unittests/scoped_mmap-selftests.c (test_normal,
131 test_invalid_filename, run_tests): New functions.
132 (_initialize_scoped_mmap_selftests): Register selftest.
133
4485a1c1
SM
1342018-08-07 Simon Marchi <simon.marchi@ericsson.com>
135
136 * dwarf2read.c (read_gdb_index_from_section): Rename to...
137 (read_gdb_index_from_buffer): ... this. Remove section
138 parameter, add buffer parameter.
139 (get_gdb_index_contents_ftype,
140 get_gdb_index_contents_dwz_ftype): New typedefs.
141 (dwarf2_read_gdb_index): Add callback parameters to get the
142 index contents.
143 (get_gdb_index_contents_from_section): New.
144 (dwarf2_initialize_objfile): Update call to
145 dwarf2_read_gdb_index.
146
528e1572
SM
1472018-08-07 Simon Marchi <simon.marchi@ericsson.com>
148
149 * common/filestuff.h (gdb_fopen_cloexec): New overload.
150 (gdb_open_cloexec): Likewise.
151 * nat/linux-osdata.c (command_from_pid): Use string_printf.
152 (commandline_from_pid): Likewise.
153 (linux_xfer_osdata_threads): Likewise.
154 (linux_xfer_osdata_fds): Likewise.
155 * ada-lang.c (is_package_name): Likewise.
156 * auxv.c (procfs_xfer_auxv): Likewise.
157 * breakpoint.c (print_one_breakpoint_location): Use
158 uiout::field_fmt.
159 (print_one_catch_solib): Use string_printf.
160 * coff-pe-read.c (add_pe_exported_sym): Likewise.
161 (add_pe_forwarded_sym): Likewise.
162 * dwarf2read.c (create_type_unit_group): Likewise.
163 (build_error_marker_type): Likewise.
164 * infcall.c (get_function_name): Likewise.
165 * valprint.c (print_converted_chars_to_obstack): Likewise.
166 * xtensa-tdep.c (xtensa_register_type): Likewise.
167
a7f25a84
SM
1682018-08-06 Simon Marchi <simon.marchi@ericsson.com>
169
170 * remote.c (remote_target::download_tracepoint): Fix format
171 string errors.
172
296956be
PFC
1732018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
174
175 * tracefile.c: Include common/byte-vector.h.
176 (trace_save): Change type of buf to gdb::byte_vector. Initialize
177 with trace_regblock_size if needed. Update uses of buf.
178
a04b9d62
PFC
1792018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
180
181 * tracepoint.h (collection_list) <m_regs_mask>: Change type to
182 std::vector<unsigned char>.
183 * tracepoint.c (collection_list::collection_list): Remove
184 m_regs_mask initializer from initializer list. Resize
185 m_regs_mask using the largest remote register number.
186 (collection_list::add_remote_register): Remove size check on
187 m_regs_mask. Use at to access element.
188 (collection_list::stringify): Change type of temp_buf to
189 gdb::char_vector. Update uses of temp_buf. Resize if needed to
190 stringify the register mask. Use pack_hex_byte for the register
191 mask.
192
4277c4b8
PFC
1932018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
194
195 * tracepoint.h (class collection_list) <add_register>: Remove.
196 <add_remote_register, add_ax_registers, add_local_register>:
197 Declare.
198 <add_memrange>: Add scope parameter.
199 * tracepoint.c (encode_actions_1): Likewise.
200 (collection_list::add_register): Rename to ...
201 (collection_list::add_remote_register): ... this. Update
202 comment.
203 (collection_list::add_ax_registers, add_local_register): New
204 methods.
205 (collection_list::add_memrange): Add scope parameter. Call
206 add_local_register instead of add_register.
207 (finalize_tracepoint_aexpr): New function.
208 (collection_list::collect_symbol): Update calls to add_memrange.
209 Call add_local_register instead of add_register. Call
210 add_ax_registers. Call finalize_tracepoint_aexpr.
211 (encode_actions_1): Get remote regnos for $reg action. Call
212 add_remote_register, add_ax_registers, and add_local_register.
213 Update call to add_memrange. Call finalize_tracepoint_aexpr.
214 (validate_actionline): Call finalize_tracepoint_aexpr.
215
3df3a985
PFC
2162018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
217
218 * remote.c (remote_target::download_tracepoint): Remove BUF_SIZE.
219 Replace array buf with gdb::char_vector buf, of size
220 get_remote_packet_size (). Replace references to buf and
221 BUF_SIZE to buf.data () and buf.size (). Replace strcpy, strcat
222 and xsnprintf with snprintf. Raise errors if the buffer is too
223 small.
224
aa6f3694
PFC
2252018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
226
227 * remote.c (remote_target::download_tracepoint): Fix the has_more
228 predicate in the QTDP action list iteration.
229
05abfc39
PFC
2302018-08-06 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
231
232 * remote.c (remote_target::download_tracepoint): Fix indentation
233 in for block.
234
821a2682
RO
2352018-08-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
236
237 * proc-api.c (_initialize_proc_api): Remove c, unused.
238 * procfs.c (procfs_init_inferior): Remove signals, unused.
239 (procfs_target::make_corefile_notes): Remove old_chain, fpregs,
240 unused.
241
95347337
AB
2422018-08-06 Sergey Korolev <s.korolev@ndmsystems.com>
243 Andrew Burgess <andrew.burgess@embecosm.com>
244
245 * linux-nat.c (linux_nat_target::follow_fork): Avoid using
246 'W_STOPCODE (0)' as this could be ambiguous.
247
425699f5
SDJ
2482018-08-03 Sergio Durigan Junior <sergiodj@redhat.com>
249
250 * ser-tcp.c (net_open): Fix thinko when deciding whether to
251 disable TCP's Nagle algorithm (use "ai_protocol" instead of
252 "ai_socktype").
253
3e1d3d8c
TT
2542018-08-02 Tom Tromey <tom@tromey.com>
255
256 PR symtab/16842.
257 * dwarf2read.c (read_func_scope): Set symtab on template parameter
258 symbols.
259 (process_structure_scope): Likewise.
260
15843549
XR
2612018-08-02 Xavier Roirand <roirand@adacore.com>
262
263 PR gdb/22629:
264 * darwin-nat.c (darwin_kill_inferior): Fix handling of
265 kill inferior.
266
b5bddbbb
TT
2672018-08-02 Tom Tromey <tom@tromey.com>
268
269 * darwin-nat.c (find_inferior_task_it, darwin_find_thread)
270 (darwin_suspend_inferior, darwin_resume_inferior)
271 (darwin_decode_notify_message, darwin_resume_inferior_threads)
272 (darwin_check_new_threads): Check result of get_darwin_inferior.
273
f61cfa07
JB
2742018-07-31 Joel Brobecker <brobecker@adacore.com>
275
276 GDB 8.1.1 released.
277
5abe0f0c
JV
2782018-07-31 Jan Vrany <jan.vrany@fit.cvut.cz>
279
280 * varobj.c (varobj_get_path_expr_parent): Report an error if
281 parent is a dynamic varobj.
282
472fa5ee
SM
2832018-07-31 Simon Marchi <simon.marchi@ericsson.com>
284
285 * gnulib/aclocal.m4: Re-generate.
286 * gnulib/config.in: Re-generate.
287 * gnulib/configure: Re-generate.
288 * gnulib/import/Makefile.in: Re-generate.
289 * gnulib/import/m4/gnulib-comp.m4: Re-generate.
290 * gnulib/import/m4/onceonly.m4: Re-generate.
291
1c28969e
SM
2922018-07-31 Simon Marchi <simon.marchi@ericsson.com>
293
294 * target-descriptions.c (struct xml_test_tdesc): New.
295 (xml_tdesc): Change type to std::vector<xml_test_tdesc>.
296 (record_xml_tdesc): Update.
297 (maintenance_check_xml_descriptions): Update.
298 * target-descriptions.h (record_xml_tdesc): Update comment.
299
c8f2dc0d
AB
3002018-07-30 Andrew Burgess <andrew.burgess@embecosm.com>
301
302 * eval.c (evaluate_subexp_for_sizeof): Check for array type before
303 checking array bounds are defined.
304
463c08d1
TT
3052018-07-30 Tom Tromey <tom@tromey.com>
306
307 * nat/linux-osdata.c (pid_pgid_entry::operator<): Fix
308 irreflexivity violation.
309
dba7455e
TT
3102018-07-30 Tom Tromey <tom@tromey.com>
311
312 * cli/cli-decode.c (lookup_cmd): Remove lint code.
313 * value.c (unpack_long): Remove lint code.
314 * valops.c (value_ind): Remove lint code.
315 * valarith.c (value_x_binop, value_x_unop, value_equal)
316 (value_pos): Remove lint code.
317
37cc0cae
TV
3182018-07-28 Tom de Vries <tdevries@suse.de>
319
320 * eval.c (evaluate_subexp_for_sizeof): Interpret size of dynamic type
321 with undefined upper bound as <optimized out>.
322
129eb0f1
SDJ
3232018-07-27 Sergio Durigan Junior <sergiodj@redhat.com>
324
325 * gcore.in: Rename variable "name" to "prefix". Expand
326 "usage" text.
327
6af79d7b
JT
3282018-07-14 Jon Turney <jon.turney@dronecode.org.uk>
329
330 * windows-nat.c (windows_nat_target::create_inferior): Update to
331 call close() in global namespace.
332
79748972
TT
3332018-07-26 Tom Tromey <tom@tromey.com>
334
335 * dwarf-index-write.c (add_address_entry): Don't add objfile
336 offsets.
337 * dbxread.c (find_stab_function): Rename from
338 find_stab_function_addr. Return a bound_minimal_symbol.
339 (read_dbx_symtab): Use raw_text_low, raw_text_high.
340 Don't add objfile offsets.
341 (end_psymtab): Use raw_text_low, raw_text_high,
342 MSYMBOL_VALUE_RAW_ADDRESS.
343 (read_ofile_symtab): Update.
344 (process_one_symbol): Update.
345 * dwarf2read.c (create_addrmap_from_index): Don't add objfile
346 offsets.
347 (dw2_relocate): Remove.
348 (dw2_find_pc_sect_symtab): Bias PC by the text offset before
349 searching addrmap.
350 (dwarf2_gdb_index_functions, dwarf2_debug_names_functions):
351 Update.
352 (process_psymtab_comp_unit_reader, add_partial_symbol)
353 (add_partial_subprogram, dwarf2_ranges_read): Update.
354 (load_partial_dies): Update.
355 (add_address_entry): Don't add objfile offsets.
356 (dwarf2_build_include_psymtabs): Update.
357 (create_addrmap_from_aranges): Don't add objfile offsets.
358 (dw2_find_pc_sect_compunit_symtab): Update.
359 * mdebugread.c (parse_symbol): Don't add objfile offsets.
360 (parse_lines): Remove 'pst' parameter, replace with 'textlow'.
361 Update.
362 (parse_partial_symbols): Don't add objfile offsets. Use
363 raw_text_low, raw_text_high. Update.
364 (handle_psymbol_enumerators, psymtab_to_symtab_1): Update.
365 * objfiles.c (objfile_relocate1): Don't relocate psymtabs_addrmap
366 or call 'relocate' quick function. Clear psymbol_map.
367 * psympriv.h (struct partial_symbol) <address>: Add section
368 offset.
369 <set_unrelocated_address>: Rename from set_address.
370 <raw_text_low, raw_text_high>: New methods.
371 <text_low, text_high>: Add objfile parameter.
372 (add_psymbol_to_bcache): Add 'section' parameter. Call
373 set_unrelocated_address.
374 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
375 (find_pc_psymbol): Update.
376 (fixup_psymbol_section, relocate_psymtabs): Remove.
377 (dump_psymtab, psym_functions): Update.
378 (add_psymbol_to_bcache, add_psymbol_to_list): Add 'section'
379 parameter.
380 (maintenance_info_psymtabs, maintenance_check_psymtabs): Update.
381 (start_psymtab_common): Update.
382 * symfile-debug.c (debug_qf_relocate): Remove.
383 (debug_sym_quick_functions): Update.
384 * symfile.h (struct quick_symbol_functions) <relocate>: Remove.
385 * xcoffread.c (scan_xcoff_symtab): Don't add objfile offsets.
386 Update.
387
52948f01
TT
3882018-07-26 Tom Tromey <tromey@redhat.com>
389
390 * dbxread.c (end_psymtab): Use text_high_valid and
391 text_low_valid.
392 * mdebugread.c (parse_partial_symbols): Use text_low_valid.
393 (psymtab_to_symtab_1): Use text_high_valid and text_low_valid.
394 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
395 Update comment.
396 <text_low_valid, text_high_valid>: New fields.
397 <set_text_low, set_text_high>: Update.
398 * xcoffread.c (scan_xcoff_symtab): Use text_low_valid.
399
4ae976d1
TT
4002018-07-26 Tom Tromey <tom@tromey.com>
401
402 * dbxread.c (read_dbx_symtab, end_psymtab, read_ofile_symtab):
403 Update.
404 * dwarf2read.c (dwarf2_create_include_psymtab): Don't initialize
405 textlow and texthigh fields.
406 (process_psymtab_comp_unit_reader, dwarf2_build_include_psymtabs):
407 Update.
408 * mdebugread.c (parse_lines, parse_partial_symbols)
409 (psymtab_to_symtab_1): Update.
410 * psympriv.h (struct partial_symtab) <m_text_low, m_text_high>:
411 Rename fields. Update comment. Now private.
412 <text_low, text_high, set_text_low, set_text_high>: New methods.
413 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
414 (find_pc_sect_psymbol, relocate_psymtabs, dump_psymtab)
415 (start_psymtab_common, maintenance_info_psymtabs)
416 (maintenance_check_psymtabs): Update.
417 * xcoffread.c (xcoff_end_psymtab): Don't initialize textlow and
418 texthigh fields.
419 (scan_xcoff_symtab): Update.
420
02e9e7f7
TT
4212018-07-26 Tom Tromey <tromey@redhat.com>
422
423 * psympriv.h (struct partial_symbol) <unrelocated_address,
424 address, set_address>: New methods.
425 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymbol)
426 (fixup_psymbol_section, relocate_psymtabs): Update.
427 (print_partial_symbols): Add 'objfile' parameter. Update.
428 (dump_psymtab, add_psymbol_to_bcache, psym_fill_psymbol_map):
429 Update.
430
8a6d4234
TT
4312018-07-26 Tom Tromey <tom@tromey.com>
432
433 * dwarf-index-write.c (write_psymbols, debug_names::insert)
434 (debug_names::write_psymbols): Update.
435 * psympriv.h (struct partial_symbol): Derive from
436 general_symbol_info.
437 <obj_section>: New method.
438 (PSYMBOL_DOMAIN, PSYMBOL_CLASS): Remove.n
439 * psymtab.c (find_pc_sect_psymtab_closer, find_pc_sect_psymtab)
440 (find_pc_sect_psymbol, fixup_psymbol_section)
441 (match_partial_symbol, lookup_partial_symbol, relocate_psymtabs)
442 (print_partial_symbols, recursively_search_psymtabs)
443 (compare_psymbols, psymbol_hash, psymbol_compare)
444 (add_psymbol_to_bcache, maintenance_check_psymtabs)
445 (psymbol_name_matches, psym_fill_psymbol_map): Update.
446
08994e1d
TT
4472018-07-26 Tom Tromey <tromey@redhat.com>
448
449 * dbxread.c (end_psymtab): Remove dead code.
450
3c3bb058
AB
4512018-07-26 Andrew Burgess <andrew.burgess@embecosm.com>
452
453 * dwarf2-frame-tailcall.c (tailcall_frame_sniffer): Exit early if
454 DWARF unwinders are disabled.
455 * dwarf2-frame.c: Add dwarf2read.h include.
456 (dwarf2_frame_sniffer): Exit early if DWARF unwinders are
457 disabled.
458 (dwarf2_frame_unwinders_enabled_p): Define.
459 (show_dwarf_unwinders_enabled_p): New function.
460 (_initialize_dwarf2_frame): Register switch to control DWARF
461 unwinder use.
462 * dwarf2-frame.h (dwarf2_frame_unwinders_enabled_p): Declare.
463 * dwarf2read.c (set_dwarf_cmdlist): Remove static keyword.
464 (show_dwarf_cmdlist): Remove static keyword.
465 * dwarf2read.h (set_dwarf_cmdlist): Declare.
466 (show_dwarf_cmdlist): Declare.
467 * NEWS: Document new feature.
468
9e7f3bbb
TV
4692018-07-26 Tom de Vries <tdevries@suse.de>
470
471 PR breakpoints/23366
472 * infcmd.c (info_program_command): Handle ptid == minus_one_ptid.
473
506f5c41
TV
4742018-07-26 Tom de Vries <tdevries@suse.de>
475
476 * dwarf2read.c (read_subrange_type): Warn if DW_AT_upper_bound or
477 DW_AT_count can't be translated to a dynamic prop.
478
16f808ec
TV
4792018-07-25 Tom de Vries <tdevries@suse.de>
480
481 * dwarf2loc.c (dwarf2_locexpr_baton_eval): Wrap ctx.eval call in
482 try/catch.
483
d7154a8d
JV
4842018-07-25 Jan Vrany <jan.vrany@fit.cvut.cz>
485
486 * breakpoint.c (enable_disable_bp_num_loc): Notify observers.
487
a45389f6
JB
4882018-07-25 Joel Brobecker <brobecker@adacore.com>
489
490 * MAINTAINERS (Global Maintainers): Add Tom Tromey.
491
380618d6
KS
4922018-07-24 Keith Seitz <keiths@redhat.comt
493
494 PR symtab/23010
495 * dwarf2read.c (dw2_add_symbol_to_list): New function.
496 (fixup_go_packaging, new_symbol): Use dw2_add_symbol_to_list
497 instead of add_symbol_to_list.
498 (read_file_scope): Call prepare_one_comp_unit before reading
499 any other DIEs.
500
4b17aefe
SM
5012018-07-24 Simon Marchi <simon.marchi@ericsson.com>
502
503 * common/scoped_mmap.h (class scoped_mmap): Fix indentation.
504
29d17e47
TT
5052018-07-24 Tom Tromey <tom@tromey.com>
506
507 * utils.c (malloc, realloc, free): Don't declare.
508 * configure, config.in: Rebuild.
509 * configure.ac: Don't check for declarations of free, malloc, or
510 realloc.
511
cf4088a9
SM
5122018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
513
514 * aarch64-linux-nat.c
515 (aarch64_linux_nat_target::stopped_data_address): Remove unused
516 variable.
517 * arm-linux-nat.c (fetch_regs): Likewise.
518 (store_regs): Likewise.
519 (fetch_vfp_regs): Likewise.
520 (store_vfp_regs): Likewise.
521 (arm_linux_nat_target::insert_hw_breakpoint): Likewise.
522 (arm_linux_nat_target::remove_hw_breakpoint): Likewise.
523 (arm_linux_nat_target::insert_watchpoint): Likewise.
524 (arm_linux_nat_target::remove_watchpoint): Likewise.
525 * mips-linux-nat.c (mips_linux_nat_target::insert_watchpoint):
526 Likewise.
527 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs):
528 Likewise.
529 * ppc-linux-nat.c (fetch_register): Likewise.
530 (fetch_all_gp_regs): Likewise.
531 (fetch_ppc_registers): Likewise.
532 (store_all_gp_regs): Likewise.
533 (store_ppc_registers): Likewise.
534 (hwdebug_insert_point): Likewise.
535 (can_use_watchpoint_cond_accel): Likewise.
536 * remote-sim.c (gdb_os_write_stdout): Likewise.
537
a0de763e
TT
5382018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
539 Tom Tromey <tom@tromey.com>
540
541 * warning.m4 (AM_GDB_WARNINGS): Add -Wunused-variable and special
542 test for it.
543 * configure: Rebuild.
544
3b20124b
TT
5452018-07-22 Tom Tromey <tom@tromey.com>
546
547 * regformats/regdat.sh: Define xmltarget_${name} inside
548 #ifndef IN_PROCESS_AGENT.
549
8c8807f4
TT
5502018-07-22 Tom Tromey <tom@tromey.com>
551
552 * value.c (value_fetch_lazy_bitfield): Remove unused variable.
553
c486b610
TT
5542018-07-22 Tom Tromey <tom@tromey.com>
555
556 * symfile.c (reread_symbols): Notify iter, not objfile.
557
494f80a9
TT
5582018-07-22 Tom Tromey <tom@tromey.com>
559
560 * ravenscar-thread.c (ravenscar_thread_target::store_registers):
561 Use arch_ops.
562 (ravenscar_thread_target::prepare_to_store): Likewise.
563
c51f6a54
TT
5642018-07-22 Tom Tromey <tom@tromey.com>
565
566 * python/py-prettyprint.c (gdbpy_apply_val_pretty_printer): Remove
567 unused variable. Call value_fetch_lazy when needed.
568 * guile/scm-pretty-print.c (gdbscm_apply_val_pretty_printer):
569 Remove unused variable. Call value_fetch_lazy when needed.
570
374fd1fd
TT
5712018-07-22 Tom Tromey <tom@tromey.com>
572
573 * m32c-tdep.c (mark_dma): Return void.
574 (make_regs): Remove unused declarations.
575
d5e9a511
TT
5762018-07-22 Tom Tromey <tom@tromey.com>
577
578 * guile/scm-cmd.c (gdbscm_dont_repeat): Call
579 cmdscm_get_valid_command_smob_arg_unsafe for effect.
580 * guile/scm-block.c (gdbscm_make_block_syms_iter): Call
581 bkscm_get_valid_block_smob_arg_unsafe for effect.
582
996d693a
TT
5832018-07-22 Tom Tromey <tom@tromey.com>
584
585 * bfin-tdep.c (bfin_push_dummy_call): Use arg_type, not
586 value_type.
587
15766370
TT
5882018-07-22 Tom Tromey <tom@tromey.com>
589
590 * windows-nat.c (saved_context): Conditionally define.
591 * remote.c (remote_target::remote_btrace_maybe_reopen):
592 Conditionally declare "warned".
593 * inflow.c (sigquit_ours): Conditionally define.
594 (new_tty): Move "tty" declaration inside #if.
595 * guile/guile.c (guile_datadir): Conditionally define.
596 * charset.c (set_be_le_names): Move some declarations inside #if.
597 * btrace.c (parse_xml_btrace): Move "errcode" declaration inside
598 #if.
599 (parse_xml_btrace_conf): Likewise.
600
f4e80e13
TT
6012018-07-22 Tom Tromey <tom@tromey.com>
602
603 * spu-tdep.c (spu_get_overlay_table): Remove unused variable.
604
8d49165d
TT
6052018-07-22 Tom Tromey <tom@tromey.com>
606
607 * guile/scm-value.c (gdbscm_value_call): Remove unused variables.
608 * guile/scm-math.c (vlscm_unop_gdbthrow, vlscm_binop_gdbthrow)
609 (vlscm_convert_typed_value_from_scheme): Remove unused variable.
610 * buildsym-legacy.c (get_macro_table): Remove unused variable.
611 * stack.c (frame_apply_level_command): Remove unused variable.
612 * tic6x-tdep.c (tic6x_push_dummy_call): Remove unused variable.
613 * sparc64-tdep.c (adi_examine_command): Remove unused variable.
614 * rs6000-lynx178-tdep.c (rs6000_lynx178_push_dummy_call): Remove
615 unused variable.
616 * nios2-tdep.c (nios2_push_dummy_call): Remove unused variable.
617 * mep-tdep.c (mep_push_dummy_call): Remove unused variable.
618 * ada-lang.c (ada_lookup_symbol_list_worker): Remove unused
619 variable.
620 * amd64-tdep.c (amd64_supply_xsave): Remove unused variable.
621 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Remove unused
622 variable.
623 * breakpoint.c (check_no_tracepoint_commands, update_watchpoint):
624 Remove unused variable.
625 * cli/cli-script.c (recurse_read_control_structure): Remove unused
626 variable.
627 * common/tdesc.c (print_xml_feature::visit): Remove unused
628 variable.
629 * compile/compile-object-load.c (store_regs): Remove unused
630 variables.
631 * complaints.c (clear_complaints): Remove unused variable.
632 * corelow.c (core_target_open): Remove unused variable.
633 * fbsd-tdep.c (fbsd_core_info_proc_status): Remove unused
634 variable.
635 * guile/scm-frame.c (gdbscm_frame_read_var): Remove unused
636 variable.
637 * guile/scm-symtab.c (stscm_print_sal_smob): Remove unused
638 variable.
639 * guile/scm-type.c (gdbscm_field_baseclass_p): Remove unused
640 variable.
641 * guile/scm-utils.c (gdbscm_parse_function_args): Remove unused
642 variable.
643 * hppa-tdep.c (hppa_stub_frame_unwind_cache): Remove unused
644 variable.
645 * ia64-tdep.c (examine_prologue): Remove unused variable.
646 * infcall.c (run_inferior_call): Remove unused variable.
647 * inferior.c (exit_inferior): Remove unused variable.
648 * infrun.c (infrun_thread_ptid_changed): Remove unused variable.
649 * linespec.c (decode_line_2): Remove unused variable.
650 * linux-nat.c (super_close): Remove.
651 * linux-tdep.c (linux_info_proc): Remove unused variable.
652 * mi/mi-main.c (mi_execute_command): Remove unused variable.
653 * microblaze-linux-tdep.c (microblaze_linux_sigtramp_cache):
654 Remove unused variable.
655 * parse.c (find_minsym_type_and_address): Remove unused variable.
656 * printcmd.c (info_symbol_command, printf_floating): Remove unused
657 variable.
658 * python/py-breakpoint.c (bppy_set_commands): Remove unused
659 variable.
660 * python/py-unwind.c (unwind_infopy_dealloc): Remove unused
661 variables.
662 * record-btrace.c (record_btrace_target::store_registers): Remove
663 unused variable.
664 (cmd_show_record_btrace_cpu): Remove unused variable.
665 * riscv-tdep.c (riscv_register_reggroup_p)
666 (riscv_push_dummy_call, riscv_return_value): Remove unused
667 variable.
668 * rust-exp.y (literal): Remove unused variable.
669 * rust-lang.c (rust_evaluate_subexp) <OP_RUST_ARARAY>: Remove
670 unused variable.
671 <STRUCTOP_ANONYMOUS>: Likewise.
672 * s390-linux-tdep.c (s390_linux_init_abi_31)
673 (s390_linux_init_abi_64): Remove unused variable.
674 * ser-ming2.c (ser_windows_read_prim, pipe_select_thread)
675 (file_select_thread, net_windows_open, _initialize_ser_windows):
676 Remove unused variables.
677 * symtab.c (find_pc_sect_line): Remove unused variable.
678 * target-memory.c (compute_garbled_blocks): Remove unused
679 variable.
680 (target_write_memory_blocks): Remove unused variable.
681 * target.c (target_stack::unpush): Remove unused variables.
682 * tracepoint.c (start_tracing, all_tracepoint_actions)
683 (merge_uploaded_trace_state_variables)
684 (print_one_static_tracepoint_marker): Remove unused variable.
685 * unittests/basic_string_view/element_access/char/1.cc (test01):
686 Remove unused variable.
687 * windows-nat.c (windows_continue, windows_add_all_dlls)
688 (do_initial_windows_stuff, windows_nat_target::create_inferior):
689 Remove unused variables.
690
17cbafdb
SM
6912018-07-21 Simon Marchi <simon.marchi@polymtl.ca>
692
693 * arm-tdep.c (arm_gdbarch_init): Declare attr_arch and
694 attr_profile in HAVE_ELF.
695 * rs6000-tdep.c (bfd_uses_spe_extensions): Declare vector_abi in
696 HAVE_ELF.
697
0ee6c332
SM
6982018-07-20 Simon Marchi <simon.marchi@polymtl.ca>
699
700 * frame.c (frame_register_unwind): Change parameter name.
701 (frame_unwind_register): Likewise.
702 (frame_unwind_register_value): Likewise.
703 (frame_unwind_register_signed): Likewise.
704 (frame_unwind_register_unsigned): Likewise.
705 * frame.h (frame_register_unwind): Likewise.
706 (frame_unwind_register): Likewise.
707 (frame_unwind_register_value): Likewise.
708 (frame_unwind_register_signed): Likewise.
709 (frame_unwind_register_unsigned): Likewise.
710 (frame_unwind_arch): Likewise.
711
e2e31f10
MR
7122018-07-20 Maciej W. Rozycki <macro@mips.com>
713
714 * MAINTAINERS: Update my e-mail address, downgrade to MIPS I-IV
715 ISA maintenance.
716
2d389915
MR
7172018-07-20 Maciej W. Rozycki <macro@mips.com>
718
719 * mips-linux-nat.c (mips_linux_nat_target::read_description):
720 Call `get_ptrace_pid' rather than extracting the ptrace PID by
721 hand.
722
cbb09508
KS
7232018-07-20 Keith Seitz <keiths@redhat.com>
724
725 * buildsym.h (struct buildsym_compunit) <m_objfile, m_subfiles,
726 m_main_subfile, m_comp_dir, m_producer, m_debugformat,
727 m_compunit_symtab, m_language>: Add "m_" prefix.
728 Update all uses.
729 * buildsym.c: Update all uses.
730
bfe2e011
TT
7312018-07-20 Tom Tromey <tom@tromey.com>
732
733 * buildsym-legacy.h (record_line): Don't use record_line_ftype.
734 * buildsym.h (record_line_ftype): Remove typedef.
735
0e6f3061
TT
7362018-07-20 Tom Tromey <tom@tromey.com>
737
738 * buildsym-legacy.h (augment_type_symtab): Don't declare.
739 (end_expandable_symtab): Likewise.
740 (end_symtab_get_static_block): Likewise.
741 (end_symtab_from_static_block): Likewise.
742 * buildsym-legacy.c (augment_type_symtab): Remove.
743 (end_expandable_symtab): Remove.
744 (end_symtab_get_static_block): Remove.
745 (end_symtab_from_static_block): Remove.
746
804d2729
TT
7472018-07-20 Tom Tromey <tom@tromey.com>
748
749 * dwarf2read.c: Include buildsym.h.
750 (struct dwarf2_cu) <builder>: New method.
751 (fixup_go_packaging): Update.
752 (process_full_comp_unit, process_full_type_unit): Update. Don't
753 use scoped_free_pendings.
754 (using_directives): Add "cu" parameter, remove "language".
755 (read_import_statement, setup_type_unit_groups, )
756 (read_func_scope, read_lexical_block_scope)
757 (dwarf2_record_block_ranges, read_namespace): Update.
758 (lnp_state_machine::lnp_state_machine): Add cu parameter.
759 (lnp_state_machine::handle_end_sequence): Update.
760 (class lnp_state_machine) <m_cu>: New member.
761 <m_record_line_callback>: Remove.
762 <m_currently_recording_lines>: New member.
763 (lnp_state_machine::handle_set_file): Update.
764 (noop_record_line): Remove.
765 (dwarf_record_line_p): Add cu parameter.
766 (dwarf_record_line_1, dwarf_finish_line): Likewise.
767 (lnp_state_machine::record_line)
768 (lnp_state_machine::lnp_state_machine)
769 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
770 (dwarf_decode_lines): Update.
771 (dwarf2_start_subfile): Add cu parameter.
772 (dwarf2_start_symtab, new_symbol): Update.
773 (macro_start_file, dwarf_decode_macro_bytes): Add cu parameter.
774 Remove dwarf2_per_objfile parameter.
775 (dwarf_decode_macros): Update.
776
80e649fc
TT
7772018-07-20 Tom Tromey <tom@tromey.com>
778
779 * stabsread.c (define_symbol): Update.
780 * buildsym-legacy.h (get_buildsym_compunit): Declare.
781 * dwarf2read.c (new_symbol): Update.
782 * cp-support.h (cp_scan_for_anonymous_namespaces): Update.
783 * cp-namespace.c: Include buildsym.h.
784 (cp_scan_for_anonymous_namespaces): Add "compunit" parameter.
785 * buildsym-legacy.c (get_buildsym_compunit): New function.
786
0baae8db
TT
7872018-07-20 Tom Tromey <tom@tromey.com>
788
789 * xcoffread.c: Include buildsym-legacy.h.
790 * windows-nat.c: Include buildsym-legacy.h.
791 * stabsread.c: Include buildsym-legacy.h.
792 * mdebugread.c: Include buildsym-legacy.h.
793 * buildsym-legacy.h: New file.
794 * buildsym-legacy.c: New file, from buildsym.c.
795 * go32-nat.c: Include buildsym-legacy.h.
796 * dwarf2read.c: Include buildsym-legacy.h.
797 * dbxread.c: Include buildsym-legacy.h.
798 * cp-namespace.c: Include buildsym-legacy.h.
799 * coffread.c: Include buildsym-legacy.h.
800 * buildsym.h: Move some contents to buildsym-legacy.h.
801 * buildsym.c: Include buildsym-legacy.h. Move many functions to
802 buildsym-legacy.c.
803 * Makefile.in (HFILES_NO_SRCDIR): Add buildsym-legacy.h.
804
ab209f6f
TT
8052018-07-20 Tom Tromey <tom@tromey.com>
806
807 * buildsym.h (struct buildsym_compunit): Move from buildsym.c.
808 * buildsym.c (struct buildsym_compunit): Move to buildsym.h.
809 (buildsym_compunit::buildsym_compunit)
810 (buildsym_compunit::~buildsym_compunit)
811 (buildsym_compunit::get_macro_table): Define.
812
74c72eac
TT
8132018-07-20 Tom Tromey <tom@tromey.com>
814
815 * buildsym.c (reset_symtab_globals): Remove.
816 (buildsym_compunit::end_symtab_from_static_block): Update.
817 (buildsym_compunit::augment_type_symtab): Update.
818 (end_symtab_from_static_block): Call free_buildsym_compunit.
819 (augment_type_symtab, end_symtab, end_expandable_symtab):
820 Likewise.
821
da6580e5
TT
8222018-07-20 Tom Tromey <tom@tromey.com>
823
824 * arch-utils.c: Do not include buildsym.h.
825 * mipsread.c: Do not include buildsym.h.
826 * machoread.c: Do not include buildsym.h.
827 * elfread.c: Do not include buildsym.h.
828
4a2125f5
TT
8292018-07-20 Tom Tromey <tom@tromey.com>
830
831 * buildsym.c (buildsym_compunit::buildsym_compunit): Do more
832 initialization.
833 (buildsym_compunit): Add new constructor.
834 (struct buildsym_compunit) <get_last_source_file, finish_block,
835 record_block_range, start_subfile, patch_subfile_names,
836 push_subfile, pop_subfile, record_line, get_compunit_symtab,
837 set_last_source_start_addr, get_last_source_start_addr,
838 get_local_using_directives, set_local_using_directives,
839 get_global_using_directives, outermost_context_p,
840 get_current_context_stack, get_context_stack_depth,
841 get_current_subfile, get_local_symbols, get_file_symbols,
842 get_global_symbols, record_debugformat, record_producer,
843 push_context, pop_context, end_symtab_get_static_block,
844 end_symtab_from_static_block, end_symtab, end_expandable_symtab>:
845 New public methods.
846 <record_pending_block, finish_block_internal, make_blockvector,
847 watch_main_source_file_lossage, end_symtab_with_blockvector>: New
848 private methods.
849 Update all users.
850
8512018-05-22 Tom Tromey <tom@tromey.com>
852
853 * buildsym.c (record_pending_block): Move earlier. Remove objfile
854 parameter.
855 (finish_block_internal): Update.
856
6b213a47
TT
8572018-07-20 Tom Tromey <tom@tromey.com>
858
859 * buildsym.c (record_pending_block): Move earlier. Remove objfile
860 parameter.
861 (finish_block_internal): Update.
862
b80a981d
TT
8632018-07-20 Tom Tromey <tom@tromey.com>
864
865 * buildsym.h (EXTERN): Don't define or undef.
866 * buildsym.c (EXTERN): Don't define.
867
ddb70602
TT
8682018-07-20 Tom Tromey <tom@tromey.com>
869
870 * buildsym.c: Remove TODO comment.
871
b37dd3bc
TT
8722018-07-20 Tom Tromey <tom@tromey.com>
873
874 * coffread.c (coff_symtab_read): Update.
875 * xcoffread.c (xcoff_psymtab_to_symtab_1): Update.
876 (xcoff_new_init): Update.
877 * mipsread.c (mipscoff_new_init): Update.
878 * mdebugread.c (mdebug_build_psymtabs): Update.
879 * elfread.c (elf_new_init): Update.
880 * dwarf2read.c (process_full_comp_unit, process_full_type_unit):
881 Update.
882 * dbxread.c (dbx_new_init, dbx_psymtab_to_symtab_1)
883 (coffstab_build_psymtabs, elfstab_build_psymtabs)
884 (stabsect_build_psymtabs): Update.
885 * buildsym.h (buildsym_init): Don't declare.
886 * buildsym.c: Update comment.
887 (prepare_for_building): Remove.
888 (start_symtab, restart_symtab): Update.
889 (reset_symtab_globals): Update comment.
890 (buildsym_init): Remove.
891
e148f09d
TT
8922018-07-20 Tom Tromey <tom@tromey.com>
893
894 * xcoffread.c (read_xcoff_symtab, process_xcoff_symbol): Update.
895 * stabsread.c (patch_block_stabs, define_symbol, read_type)
896 (read_enum_type, common_block_start, common_block_end)
897 (cleanup_undefined_types_1, finish_global_stabs): Update.
898 * mdebugread.c (psymtab_to_symtab_1): Update.
899 * dwarf2read.c (fixup_go_packaging, read_func_scope)
900 (read_lexical_block_scope, new_symbol): Update.
901 * dbxread.c (process_one_symbol): Update.
902 * coffread.c (coff_symtab_read, process_coff_symbol)
903 (coff_read_enum_type): Update.
904 * buildsym.h (file_symbols, global_symbols, local_symbols): Don't
905 declare.
906 (get_local_symbols, get_file_symbols, get_global_symbols): New
907 functions.
908 * buildsym.c (~buildsym_compunit): Clean up m_file_symbols and
909 m_global_symbols.
910 <m_file_symbols, m_local_symbols, m_global_symbols>: New members.
911 (~scoped_free_pendings): Update.
912 (finish_block, prepare_for_building, reset_symtab_globals)
913 (end_symtab_get_static_block, end_symtab_with_blockvector)
914 (augment_type_symtab, push_context): Update.
915 (get_local_symbols, get_file_symbols, get_global_symbols): New
916 functions.
917 (buildsym_init): Update.
918
93b8bea4
TT
9192018-07-20 Tom Tromey <tom@tromey.com>
920
921 * dwarf2read.c (process_full_comp_unit): Do not set list_in_scope.
922 (process_full_type_unit): Likewise.
923 (dwarf2_start_symtab): Set list_in_scope.
924
f62f6af5
TT
9252018-07-20 Tom Tromey <tom@tromey.com>
926
927 * dwarf2read.c (process_psymtab_comp_unit_reader)
928 (build_type_psymtabs_reader): Do not set list_in_scope.
929
1d376700
TT
9302018-07-20 Tom Tromey <tom@tromey.com>
931
932 * buildsym.c (free_pendings): Remove.
933 (add_symbol_to_list, scoped_free_pendings)
934 (finish_block_internal, buildsym_init): Update.
935
c233e9c6
TT
9362018-07-20 Tom Tromey <tom@tromey.com>
937
938 * xcoffread.c (read_xcoff_symtab): Update.
939 * dwarf2read.c (read_func_scope, read_lexical_block_scope):
940 Update.
941 * dbxread.c (process_one_symbol): Update.
942 * coffread.c (coff_symtab_read): Update.
943 * buildsym.h (finish_block): Update.
944 * buildsym.c (finish_block): Remove "listhead" argument.
945 (end_symtab_get_static_block): Update.
946
5ac04550
TT
9472018-07-20 Tom Tromey <tom@tromey.com>
948
949 * buildsym.h (class scoped_free_pendings): Remove constructor.
950 * buildsym.c (struct buildsym_compunit) <free_pending_blocks>: New
951 method.
952 <m_pending_block_obstack, m_pending_blocks>: New members.
953 (pending_block_obstack, pending_blocks): Remove.
954 (scoped_free_pendings::scoped_free_pendings): Default.
955 (~scoped_free_pendings): Update.
956 (free_pending_blocks): Remove.
957 (finish_block_internal, record_pending_block, make_blockvector)
958 (end_symtab_get_static_block, augment_type_symtab, push_context)
959 (buildsym_init): Update.
960
7ea05a7b
TT
9612018-07-20 Tom Tromey <tom@tromey.com>
962
963 * buildsym.c (struct buildsym_compunit) <m_pending_addrmap,
964 m_pending_addrmap_obstack, m_pending_addrmap_interesting>: New
965 members.
966 (pending_addrmap, pending_addrmap_obstack)
967 (pending_addrmap_interesting): Remove.
968 (scoped_free_pendings, record_block_range, make_blockvector)
969 (prepare_for_building, reset_symtab_globals, buildsym_init):
970 Update.
971
3c65e5b3
TT
9722018-07-20 Tom Tromey <tom@tromey.com>
973
974 * xcoffread.c (process_linenos): Update.
975 * stabsread.c (define_symbol, read_type, read_enum_type): Update.
976 * mdebugread.c (psymtab_to_symtab_1): Update.
977 * dwarf2read.c (setup_type_unit_groups)
978 (lnp_state_machine::handle_set_file, dwarf_record_line_p)
979 (lnp_state_machine::record_line, dwarf_decode_lines): Update.
980 * dbxread.c (process_one_symbol): Update.
981 * coffread.c (coff_symtab_read, enter_linenos)
982 (process_coff_symbol): Update.
983 * buildsym.h (current_subfile): Don't declare.
984 (get_current_subfile): Declare.
985 * buildsym.c (struct buildsym_compunit) <m_current_subfile>: New
986 member.
987 (start_subfile, free_buildsym_compunit, push_subfile)
988 (prepare_for_building, start_symtab): Update.
989 (get_current_subfile): New function.
990
a60f3166
TT
9912018-07-20 Tom Tromey <tom@tromey.com>
992
993 * coffread.c (coff_symtab_read): Update.
994 * xcoffread.c (read_xcoff_symtab): Update.
995 * dwarf2read.c (new_symbol): Update.
996 (read_func_scope, read_lexical_block_scope): Update.
997 * dbxread.c (process_one_symbol): Update.
998 * buildsym.h (context_stack, context_stack_depth): Don't declare.
999 (outermost_context_p): Remove macro.
1000 (outermost_context_p, get_current_context_stack)
1001 (get_context_stack_depth): Declare.
1002 (pop_context): Return struct context_stack.
1003 * buildsym.c (struct buildsym_compunit) <m_context_stack: New
1004 member.
1005 (context_stack_size): Remove.
1006 (INITIAL_CONTEXT_STACK_SIZE): Remove.
1007 (prepare_for_building, end_symtab_get_static_block)
1008 (augment_type_symtab, push_context): Update.
1009 (pop_context): Return struct context_stack.
1010 (outermost_context_p, get_current_context_stack)
1011 (get_context_stack_depth): New functions.
1012 (buildsym_init): Update.
1013
56ba65a0
TT
10142018-07-20 Tom Tromey <tom@tromey.com>
1015
1016 * rust-exp.y: Now a pure parser. Update all rules.
1017 (%union): Move earlier.
1018 (current_parser, work_obstack): Remove globals.
1019 (rust_parser, ~rust_parser): Update.
1020 (class rust_parser) <copy_name, concat3, crate_name, super_name,
1021 lex_character, lex_number, lex_string, lex_identifier,
1022 rust_lookup_type, convert_params_to_types, convert_ast_to_type,
1023 convert_name, convert_params_to_expression,
1024 convert_ast_to_expression, ast_basic_type, ast_operation,
1025 ast_compound_assignment, rust_op, ast_literal, ast_dliteral,
1026 ast_structop, ast_structop_anonymous, ast_unary, ast_cast,
1027 ast_call_ish, ast_path, ast_string, ast_struct, ast_range,
1028 ast_array_type, ast_slice_type, ast_reference_type,
1029 ast_pointer_type, ast_function_type, ast_tuple_type>: New methods.
1030 (rust_parse): Update.
1031 (rustyyerror, rustyylex): Add parser parameter.
1032 (rust_lex_test_one, rust_lex_int_test, rust_lex_exception_test)
1033 (rust_lex_stringish_test, rust_lex_test_sequence)
1034 (rust_lex_test_trailing_dot, rust_lex_test_completion)
1035 (rust_lex_test_push_back, rust_lex_tests): Update.
1036
4c693332
PA
10372018-07-19 Pedro Alves <palves@redhat.com>
1038
1039 * guile/guile-internal.h (gdbscm_scm_to_c_string): Now returns a
1040 gdb::unique_xmalloc_ptr.
1041 * guile/scm-breakpoint.c (gdbscm_set_breakpoint_condition_x):
1042 Adjust to use dbscm_wrap and gdb::unique_xmalloc_ptr.
1043 * guile/scm-exception.c (gdbscm_exception_message_to_string): Use
1044 copy-initialization.
1045 * guile/scm-pretty-print.c (ppscm_print_children): Use
1046 gdb::unique_xmalloc_ptr instead of cleanups.
1047 (gdbscm_apply_val_pretty_printer): Remove cleanups.
1048 * guile/scm-string.c (gdbscm_scm_to_c_string): Now returns a
1049 gdb::unique_xmalloc_ptr.
1050 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1051 Adjust to use gdb::unique_xmalloc_ptr.
1052 * guile/scm-utils.c (extract_arg): Adjust.
1053 * guile/scm-value.c (gdbscm_value_field): Adjust to use
1054 gdb::unique_xmalloc_ptr instead of a cleanup.
1055
4581dc82
TT
10562018-07-19 Tom Tromey <tom@tromey.com>
1057
1058 * utils.c (do_value_free_to_mark)
1059 (make_cleanup_value_free_to_mark): Remove.
1060 * utils.h (make_cleanup_value_free_to_mark): Remove.
1061
43cc6c3a
PA
10622018-07-19 Pedro Alves <palves@redhat.com>
1063
1064 * guile/guile-internal.h (gdbscm_wrap): Really make 'args' a
1065 forwarding reference.
1066
3a5f2a48
PA
10672018-07-18 Pedro Alves <palves@redhat.com>
1068
1069 * guile/guile.c (gdbscm_execute_gdb_command): Adjust to use
1070 gdbscm_wrap. Use gdb::unique_xmalloc_ptr<char> instead of a
1071 cleanup.
1072
557e56be
PA
10732018-07-18 Pedro Alves <palves@redhat.com>
1074
1075 * guile/guile-internal.h: Add comment about mixing GDB and Scheme
1076 exceptions.
1077 (GDBSCM_HANDLE_GDB_EXCEPTION_WITH_CLEANUPS): Delete.
1078 (gdbscm_wrap): New.
1079 * guile/scm-frame.c (gdbscm_frame_read_register): Use xfree
1080 directly instead of a cleanup.
1081 * guile/scm-math.c (vlscm_unop_gdbthrow): New, factored out from ...
1082 (vlscm_unop): ... this. Reimplement using gdbscm_wrap.
1083 (vlscm_binop_gdbthrow): New, factored out from ...
1084 (vlscm_binop): ... this. Reimplement using gdbscm_wrap.
1085 (vlscm_rich_compare): Use gdbscm_wrap.
1086 * guile/scm-symbol.c (gdbscm_lookup_symbol): Use xfree directly
1087 instead of a cleanup.
1088 (gdbscm_lookup_global_symbol): Use xfree directly instead of a
1089 cleanup.
1090 * guile/scm-type.c (gdbscm_type_field, gdbscm_type_has_field_p):
1091 Use xfree directly instead of a cleanup.
1092 * guile/scm-value.c (gdbscm_make_value, gdbscm_make_lazy_value):
1093 Adjust to use gdbscm_wrap and scoped_value_mark.
1094 (gdbscm_value_optimized_out_p): Adjust to use gdbscm_wrap.
1095 (gdbscm_value_address, gdbscm_value_dereference)
1096 (gdbscm_value_referenced_value): Adjust to use gdbscm_wrap and
1097 scoped_value_mark.
1098 (gdbscm_value_dynamic_type): Use scoped_value_mark.
1099 (vlscm_do_cast, gdbscm_value_field): Adjust to use gdbscm_wrap and
1100 scoped_value_mark.
1101 (gdbscm_value_subscript, gdbscm_value_call): Adjust to use
1102 gdbscm_wrap and scoped_value_mark.
1103 (gdbscm_value_to_string): Use xfree directly instead of a
1104 cleanup. Move 'buffer' unique_ptr to TRY scope.
1105 (gdbscm_value_to_lazy_string): Use xfree directly instead of a
1106 cleanup. Move 'buffer' unique_ptr to TRY scope. Use
1107 scoped_value_mark.
1108 (gdbscm_value_fetch_lazy_x): Use gdbscm_wrap.
1109 (gdbscm_parse_and_eval): Adjust to use gdbscm_wrap and
1110 scoped_value_mark.
1111 (gdbscm_history_ref, gdbscm_history_append_x): Adjust to use
1112 gdbscm_wrap.
1113
42dc7699
TV
11142018-07-18 Tom de Vries <tdevries@suse.de>
1115
1116 * findvar.c (default_read_var_value): Also resolve dynamic type for
1117 LOC_OPTIMIZED_OUT vars.
1118
6592ceed
MR
11192018-07-18 Maciej W. Rozycki <macro@mips.com>
1120
1121 * mips-tdep.c (micromips_next_pc): Add SYSCALL instruction
1122 decoding.
1123
c6c6149a
TT
11242018-07-17 Tom Tromey <tom@tromey.com>
1125
1126 * guile/scm-param.c (pascm_set_func, pascm_show_func)
1127 (compute_enum_list, pascm_set_param_value_x)
1128 (gdbscm_parameter_value): Update.
1129 * guile/guile-internal.h (gdbscm_scm_to_string): Update.
1130 (gdbscm_scm_to_host_string): Update.
1131 * guile/scm-math.c (vlscm_convert_typed_value_from_scheme):
1132 Update.
1133 * guile/scm-cmd.c (cmdscm_add_completion): Update.
1134 * guile/scm-pretty-print.c (ppscm_print_string_repr): Update.
1135 * guile/scm-string.c (gdbscm_scm_to_string): Return
1136 unique_xmalloc_ptr.
1137 (gdbscm_scm_to_host_string): Likewise.
1138
a1a31cb8
TT
11392018-07-17 Tom Tromey <tom@tromey.com>
1140
1141 * guile/guile.c (gdbscm_eval_from_control_command): Update.
1142 * guile/guile-internal.h (gdbscm_safe_eval_string): Update.
1143 * guile/scm-objfile.c (gdbscm_execute_objfile_script): Update.
1144 * guile/scm-safe-call.c (gdbscm_safe_eval_string): Return
1145 unique_xmalloc_ptr.
1146
15bf3002
TT
11472018-07-17 Tom Tromey <tom@tromey.com>
1148
1149 * guile/scm-param.c (pascm_signal_setshow_error): Update.
1150 * guile/guile-internal.h (gdbscm_exception_message_to_string):
1151 Update.
1152 * guile/scm-cmd.c (cmdscm_function): Update.
1153 * guile/scm-pretty-print.c
1154 (ppscm_print_exception_unless_memory_error): Update.
1155 * guile/scm-exception.c (gdbscm_exception_message_to_string):
1156 Return unique_xmalloc_ptr.
1157
7eb1a66c
TT
11582018-07-17 Tom Tromey <tom@tromey.com>
1159
1160 * guile/scm-pretty-print.c (ppscm_make_pp_type_error_exception):
1161 Use string_printf.
1162
ce73f310
JW
11632018-07-17 Jim Wilson <jimw@sifive.com>
1164
27724bad
JW
1165 * riscv-tdep.c (riscv_has_feature): Delete comment that refers to
1166 set_gdbarch_decr_pc_after_break. Call riscv_read_misa_reg always.
1167 (riscv_gdbarch_init): Delete local has_compressed_isa. Delete now
1168 unecessary braces after EF_RISCV_RVC test. Delete call to
1169 set_gdbarch_decr_pc_after_break.
1170
ce73f310
JW
1171 * riscv-tdep.h (DECLARE_CSR): Use RISCV_FIRST_CSR_REGNUM instead of
1172 RISCV_LAST_FP_REGNUM + 1.
1173 (RSICV_CSR_LEGACY_MISA_REGNUM): Add RISCV_FIRST_CSR_REGNUM.
1174
056dec39
TT
11752018-07-17 Tom Tromey <tom@tromey.com>
1176
1177 * configure.ac: Remove --disable-gdbcli.
1178 * configure: Rebuild.
1179 * Makefile.in (SUBDIR_CLI_DEPS, SUBDIR_CLI_LDFLAGS)
1180 (SUBDIR_CLI_CFLAGS): Remove.
1181 (SFILES): Use SUBDIR_CLI_SRCS.
1182 (COMMON_OBS): Use SUBDIR_CLI_OBS.
1183
4735f0ed
TT
11842018-07-17 Tom Tromey <tom@tromey.com>
1185
1186 PR gdb/18624:
1187 * coffread.c (coff_symtab_read): Use scoped_free_pendings.
1188
117a0e99
JW
11892018-07-16 Jim Wilson <jimw@sifive.com>
1190
1191 * riscv-tdep.c (riscv_gdbarch_init): Call gdbarch_init_osabi.
1192
8a67aaa8
SM
11932018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1194
1195 * ia64-libunwind-tdep.c (libunwind_frame_cache): Remove unused
1196 variable.
1197 (libunwind_frame_sniffer): Likewise.
1198 (libunwind_frame_prev_register): Likewise.
1199 (libunwind_sigtramp_frame_sniffer): Likewise.
1200 * ia64-tdep.c (ia64_access_reg): Likewise.
1201 (ia64_access_rse_reg): Likewise.
1202 (ia64_libunwind_sigtramp_frame_this_id): Likewise.
1203 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Likewise.
1204
ec74dcd8
SM
12052018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1206
1207 * ia64-vms-tdep.c (ia64_vms_find_proc_info_x): Add cast.
1208
a700e753
SM
12092018-07-16 Simon Marchi <simon.marchi@ericsson.com>
1210
1211 * remote-sim.c (gdbsim_target::close,
1212 gdbsim_target::mourn_inferior): Remove unused variables.
1213
8b411ff8
SM
12142018-07-16 Simon Marchi <simon.marchi@polymtl.ca>
1215
1216 * ia64-tdep.c (ktab_buf): New global.
1217 (getunwind_table): Return a gdb::optional<gdb::byte_vector>.
1218 (get_kernel_table): Adjust.
1219
edb0470b
TT
12202018-07-16 Tom Tromey <tom@tromey.com>
1221
1222 * xcoffread.c (read_xcoff_symtab): Use outermost_context_p.
1223 * dwarf2read.c (using_directives, new_symbol): Use
1224 outermost_context_p.
1225 * dbxread.c (process_one_symbol): Use outermost_context_p.
1226 * coffread.c (coff_symtab_read): Use outermost_context_p.
1227
6cccc9a8
TT
12282018-07-16 Tom Tromey <tom@tromey.com>
1229
1230 * dwarf2read.c (using_directives, read_func_scope)
1231 (read_lexical_block_scope): Update.
1232 * cp-namespace.c (cp_scan_for_anonymous_namespaces): Update.
1233 * buildsym.h (local_using_directives, global_using_directives):
1234 Don't declare.
1235 (get_local_using_directives, set_local_using_directives)
1236 (get_global_using_directives): Declare.
1237 * buildsym.c (struct buildsym_compunit) <m_local_using_directives,
1238 m_global_using_directives>: New members.
1239 (finish_block_internal, prepare_for_building)
1240 (reset_symtab_globals, end_symtab_get_static_block)
1241 (push_context): Update.
1242 (get_local_using_directives, set_local_using_directives)
1243 (get_global_using_directives): New functions.
1244 (buildsym_init): Update.
1245
652788a7
TT
12462018-07-16 Tom Tromey <tom@tromey.com>
1247
1248 * xcoffread.c (xcoff_initial_scan): Don't call
1249 free_pending_blocks.
1250 * dbxread.c (dbx_symfile_read): Don't call free_pending_blocks.
1251 * buildsym.h (class scoped_free_pendings): Add constructor.
1252 (free_pending_blocks): Don't declare.
1253 * buildsym.c (scoped_free_pendings::scoped_free_pendings): New.
1254 (free_pending_blocks): Now static.
1255
8419ee53
TT
12562018-07-16 Tom Tromey <tom@tromey.com>
1257
1258 * buildsym.h (push_subfile, pop_subfile): Update declarations.
1259 * buildsym.c (struct buildsym_compunit) <m_subfile_stack>: New
1260 member.
1261 (struct subfile_stack): Remove.
1262 (subfile_stack): Remove.
1263 (push_subfile, pop_subfile, buildsym_init): Update.
1264
ccdac490
TT
12652018-07-16 Tom Tromey <tom@tromey.com>
1266
1267 * buildsym.c (push_subfile): Use gdb_assert.
1268 (pop_subfile): Use gdb_assert.
1269
43130d6f
TT
12702018-07-16 Tom Tromey <tom@tromey.com>
1271
1272 * buildsym.h (merge_symbol_lists): Remove.
1273 * buildsym.c (merge_symbol_lists): Remove.
1274
77d6f1aa
TT
12752018-07-16 Tom Tromey <tom@tromey.com>
1276
1277 * stabsread.c (scan_file_globals): Update comment.
1278 * stabsread.h (scan_file_globals): Move from buildsym.h.
1279 * buildsym.h (scan_file_globals): Move to stabsread.h.
1280
2c722d18
TT
12812018-07-16 Tom Tromey <tom@tromey.com>
1282
1283 * xcoffread.c (xcoff_new_init): Update.
1284 * mipsread.c (mipscoff_new_init): Update.
1285 * mdebugread.c (mdebug_build_psymtabs): Update.
1286 * elfread.c (elf_new_init): Update.
1287 * dbxread.c (dbx_new_init, coffstab_build_psymtabs)
1288 (elfstab_build_psymtabs, stabsect_build_psymtabs): Update.
1289 * buildsym.h (buildsym_new_init): Don't declare.
1290 * buildsym.c (buildsym_new_init): Remove.
1291
5985ac61
TT
12922018-07-16 Tom Tromey <tom@tromey.com>
1293
1294 * stabsread.h (within_function): Move from buildsym.h.
1295 * stabsread.c (start_stabs): Clear within_function.
1296 * coffread.c (coff_start_symtab): Clear within_function.
1297 * buildsym.h (within_function): Move to stabsread.h.
1298 * buildsym.c (prepare_for_building): Update.
1299
6b84eeb2
TT
13002018-07-16 Tom Tromey <tom@tromey.com>
1301
1302 * stabsread.h (processing_gcc_compilation): Move from buildsym.h.
1303 * dwarf2read.c (dwarf2_start_symtab): Don't set
1304 processing_gcc_compilation.
1305 * buildsym.h (processing_gcc_compilation): Move to stabsread.h.
1306
2150c3ef
TT
13072018-07-16 Tom Tromey <tom@tromey.com>
1308
1309 * stabsread.h (HASHSIZE, hashname, symnum, next_symbol_text)
1310 (next_symbol_text_func): Move from buildsym.h.
1311 * stabsread.c (hashname): Move from buildsym.c.
1312 * buildsym.h (HASHSIZE, symnum, next_symbol_text)
1313 (next_symbol_text_func, hashname): Move to stabsread.h.
1314 * buildsym.c: Don't include bcache.h
1315 (hashname): Move to stasbread.c.
1316
0ec44fc0
TT
13172018-07-16 Tom Tromey <tom@tromey.com>
1318
1319 * buildsym.h (context_stack_size): Don't declare.
1320 * buildsym.c (context_stack_size): New global.
1321
81cc346d
TT
13222018-07-16 Tom Tromey <tom@tromey.com>
1323
1324 * dbxread.c (processing_acc_compilation): New global.
1325 * buildsym.h (processing_acc_compilation): Don't declare.
1326
2c99ee5c
TT
13272018-07-16 Tom Tromey <tom@tromey.com>
1328
1329 * xcoffread.c (aix_process_linenos, complete_symtab): Update.
1330 * dbxread.c (read_ofile_symtab): Update.
1331 * coffread.c (coff_start_symtab, coff_end_symtab): Update.
1332 * buildsym.h (last_source_start_addr): Remove.
1333 (set_last_source_start_addr, get_last_source_start_addr):
1334 Declare.
1335 * buildsym.c (buildsym_compunit::buildsym_compunit): Add last_addr
1336 parameter.
1337 (struct buildsym_compunit) <m_last_source_start_addr>: New
1338 member.
1339 (prepare_for_building): Remove start_addr parameter.
1340 (start_symtab, restart_symtab, end_symtab_get_static_block)
1341 (end_symtab_with_blockvector): Update.
1342 (set_last_source_start_addr, get_last_source_start_addr): New
1343 functions.
1344
530fedbc
TT
13452018-07-16 Tom Tromey <tom@tromey.com>
1346
1347 * buildsym.c (struct buildsym_compunit) <m_have_line_numbers>: New
1348 member.
1349 (have_line_numbers): Remove.
1350 (record_line, prepare_for_building, end_symtab_get_static_block)
1351 (augment_type_symtab): Update.
1352
6a976300
TT
13532018-07-16 Tom Tromey <tom@tromey.com>
1354
1355 * buildsym.c (~buildsym_compunit): Free the macro table.
1356 (struct buildsym_compunit) <get_macro_table, release_macros>: New
1357 methods.
1358 <m_pending_macros>: New member.
1359 (pending_macros): Remove.
1360 (~scoped_free_pendings, get_macro_table, prepare_for_building)
1361 (reset_symtab_globals, end_symtab_get_static_block)
1362 (end_symtab_with_blockvector, augment_type_symtab)
1363 (buildsym_init): Update.
1364
c0015d44
TT
13652018-07-16 Tom Tromey <tom@tromey.com>
1366
1367 * buildsym.c (buildsym_compunit::buildsym_compunit): Add name
1368 parameter.
1369 (buildsym_compunit::set_last_source_file): New method.
1370 <m_last_source_file>: New member.
1371 (prepare_for_building): Remove "name" parameter.
1372 (start_symtab, restart_symtab, reset_symtab_globals): Update.
1373 (last_source_file): Remove.
1374 (set_last_source_file, get_last_source_file): Update.
1375
e62cca7c
TT
13762018-07-16 Tom Tromey <tom@tromey.com>
1377
1378 * buildsym.c (prepare_for_building): Add assert.
1379
905eb0e2
TT
13802018-07-16 Tom Tromey <tom@tromey.com>
1381
1382 * buildsym.c (~buildsym_compunit): Update.
1383 (struct buildsym_compunit) <comp_unit>: Now a unique_xmalloc_ptr.
1384 (start_subfile, patch_subfile_names)
1385 (end_symtab_with_blockvector): Update.
1386
b248663f
TT
13872018-07-16 Tom Tromey <tom@tromey.com>
1388
1389 * buildsym.c (struct buildsym_compunit): Add constructor,
1390 destructor, initializers.
1391 (start_buildsym_compunit): Remove.
1392 (free_buildsym_compunit): Use "delete".
1393 (start_symtab, restart_symtab): Use "new".
1394
ff27d073
SM
13952018-07-13 Simon Marchi <simon.marchi@polymtl.ca>
1396
1397 * symfile.c (set_objfile_default_section_offset): Remove struct
1398 keyword.
1399
6a15ecf5
SH
14002018-07-14 Stafford Horne <shorne@gmail.com>
1401
1402 * (Responsible Maintainers): Add myself as or1k maintainer.
1403
027a4c30
TT
14042018-07-13 Tom Tromey <tom@tromey.com>
1405
1406 * symfile.c (set_objfile_default_section_offset): Use extra braces
1407 around initializer.
1408
5c1eda30
AA
14092018-07-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
1410
1411 * s390-tdep.c (s390_displaced_step_fixup): Adjust PC for a
1412 non-branching basr.
1413
bc7b042b
PW
14142018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1415
1416 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1417 unittests/cli-utils-selftests.c
1418 * unittests/cli-utils-selftests.c: New file.
1419
a14c4daa
PW
14202018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1421
1422 * NEWS: Mention new commands. Mention change to 'thread apply'.
1423
1fe75df7
PW
14242018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1425
1426 * thread.c (thr_try_catch_cmd): New function.
1427 (thread_apply_all_command): Handle qcs flags.
1428 (thread_apply_command): Handle qcs flags.
1429 (taas_command): New function.
1430 (tfaas_command): New function.
1431 (_initialize_thread): Update to setup the new commands 'taas
1432 and 'tfaas'. Change doc string for 'thread apply'.
1433
6a70eb7d
PW
14342018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1435
1436 * stack.c: (trailing_outermost_frame): New function, mostly
1437 extracted from backtrace_command_1.
1438 (leading_innermost_frame): New function.
1439 (backtrace_command_1): Update to call trailing_outermost_frame.
1440 (frame_apply_command_count): New function.
1441 (frame_apply_level_command): New function.
1442 (frame_apply_all_command): New function.
1443 (frame_apply_command): New function.
1444 (faas_command): New function.
1445 (frame_cmd_list): New variable.
1446 (_initialize_stack): Update to setup the new commands 'frame apply'
1447 and 'faas'.
1448
529c08b2
PW
14492018-07-12 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1450
1451 * cli-utils.c (number_or_range_parser::get_number): Only handle
1452 numbers or convenience var as numbers.
1453 (parse_flags): New function.
1454 (parse_flags_qcs): New function.
1455 (number_or_range_parser::finished): Ensure parsing end is detected
1456 before end of string.
1457 * cli-utils.h (parse_flags): New function.
1458 (parse_flags_qcs): New function.
1459 (number_or_range_parser): Remove m_finished bool.
1460 (number_or_range_parser::skip_range): Set m_in_range to false.
1461
64b58472
SDJ
14622018-07-12 Sergio Durigan Junior <sergiodj@redhat.com>
1463
1464 * ser-tcp.c (try_connect): Declare 'ioarg' as 'u_long' if building
1465 on Windows.
1466
c7ab0aef
SDJ
14672018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1468 Jan Kratochvil <jan.kratochvil@redhat.com>
1469 Paul Fertser <fercerpav@gmail.com>
1470 Tsutomu Seki <sekiriki@gmail.com>
1471 Pedro Alves <palves@redhat.com>
1472
1473 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1474 'unittests/parse-connection-spec-selftests.c'.
1475 (COMMON_SFILES): Add 'common/netstuff.c'.
1476 (HFILES_NO_SRCDIR): Add 'common/netstuff.h'.
1477 * NEWS (Changes since GDB 8.2): Mention IPv6 support.
1478 * common/netstuff.c: New file.
1479 * common/netstuff.h: New file.
1480 * ser-tcp.c: Include 'netstuff.h' and 'wspiapi.h'.
1481 (wait_for_connect): Update comment. New parameter
1482 'gdb::optional<int> sock' instead of 'struct serial *scb'.
1483 Use 'sock' directly instead of 'scb->fd'.
1484 (try_connect): New function, with code from 'net_open'.
1485 (net_open): Rewrite main loop to deal with multiple
1486 sockets/addresses. Handle IPv6-style hostnames; implement
1487 support for IPv6 connections.
1488 * unittests/parse-connection-spec-selftests.c: New file.
1489
4c7333b3
PA
14902018-07-11 Pedro Alves <palves@redhat.com>
1491
1492 PR gdb/23377
1493 * remote.c (remote_target::remote_detach_pid): Call
1494 set_current_process.
1495
a6f88f6e
PA
14962018-07-11 Pedro Alves <palves@redhat.com>
1497
1498 * h8300-tdep.c (h8300_gdbarch_init): Remove
1499 set_gdbarch_ecoff_reg_to_regnum calls.
1500
16ff70dd
SDJ
15012018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1502
1503 PR c++/23373
1504 * c-typeprint.c (c_type_print_base_struct_union): Don't print
1505 offsets/sizes for static members of a class/struct.
1506
12863263
AH
15072018-07-11 Alan Hayward <alan.hayward@arm.com>
1508
1509 * target-descriptions.c (tdesc_register_bitsize): Rename.
1510 * target-descriptions.h (tdesc_register_bitsize): Likewise.
1511 * rs6000-tdep.c (rs6000_gdbarch_init): Use new name.
1512 * aarch64-tdep.c (aarch64_get_tdesc_vq): Convert size.
1513
1123588c
TT
15142018-07-10 Tom Tromey <tom@tromey.com>
1515
1516 * breakpoint.c (moribund_locations): Now static and a
1517 std::vector.
1518 (breakpoint_init_inferior, moribund_breakpoint_here_p)
1519 (build_bpstat_chain, update_global_location_list)
1520 (breakpoint_retire_moribund): Update.
1521 * breakpoint.h (bp_location_p): Remove typedef. Don't declare
1522 VEC.
1523
8c49aa89
AB
15242018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1525
1526 * riscv-tdep.c (riscv_is_fp_regno_p): New function.
1527 (riscv_register_reggroup_p): Use new function, remove unneeded
1528 parenthesis.
1529 (riscv_push_dummy_call): Extend assert to compare against xlen or
1530 flen based on register type.
1531
42ecac17
AB
15322018-07-10 Andrew Burgess <andrew.burgess@embecosm.com>
1533
1534 * riscv-tdep.c (riscv_print_arg_location): Use TYPE_SAFE_NAME.
1535
055303e2
AB
15362018-07-09 Andrew Burgess <andrew.burgess@embecosm.com>
1537
1538 * remote.c (show_hardware_watchpoint_limit): New function.
1539 (show_hardware_watchpoint_length_limit): New function.
1540 (show_hardware_breakpoint_limit): New function.
1541 (_initialize_remote): Use add_setshow_zuinteger_unlimited_cmd
1542 where appropriate, update help text.
1543
8fd32c1c
TT
15442018-07-09 Tom Tromey <tom@tromey.com>
1545
1546 * Makefile.in (CDEPS): Don't mention XM_CDEPS.
1547 (CLIBS): Don't mention NAT_CLIBS.
1548
31278b51
TT
15492018-07-09 Tom Tromey <tom@tromey.com>
1550
1551 * Makefile.in (ADD_FILES, ADD_DEPS): Remove.
1552 (LIBGDB_OBS, clean mostlyclean): Update.
1553 (gdb$(EXEEXT), insight$(EXEEXT)): Update.
1554
e5fd1493
TT
15552018-07-09 Tom Tromey <tom@tromey.com>
1556
1557 * Makefile.in (%.c: %.y): Use ECHO_YACC.
1558 (%.c: %.l): Use ECHO_LEX. Just fail if flex not available.
1559 * silent-rules.mk (ECHO_YACC, ECHO_LEX): New variables.
1560
981e0c0c
TT
15612018-07-09 Tom Tromey <tom@tromey.com>
1562
1563 * Makefile.in (ALLDEPFILES): Remove exec.c.
1564 (COMMON_OBS): Remove exec.o.
1565 (COMMON_SFILES): Add exec.c.
1566
14ccceb2
TT
15672018-07-09 Tom Tromey <tom@tromey.com>
1568
1569 * Makefile.in (LINT, LINTFLAGS, LINTFILES, lint): Remove.
1570
5d3c3a68
TT
15712018-07-09 Tom Tromey <tom@tromey.com>
1572
1573 * Makefile.in (clean mostlyclean): Remove stamp-version.
1574 (version.c): Depend on stamp-version.
1575 (stamp-version): New rule, from version.c rule.
1576
1998086d
TT
15772018-07-09 Tom Tromey <tom@tromey.com>
1578
1579 * Makefile.in (init.c): Depend on stamp-init.
1580 (stamp-init): New rule, from init.c rule.
1581 (clean mostlyclean): Remove stamp-init.
1582
4c754949
TT
15832018-07-09 Tom Tromey <tom@tromey.com>
1584
1585 * Makefile.in (INIT_FILES): Remove CONFIG_SRCS,
1586 SUBDIR_GCC_COMPILE_SRCS.
1587
6497f1dd
TT
15882018-07-09 Tom Tromey <tom@tromey.com>
1589
1590 * Makefile.in (init.c): Remove some unused sed rules.
1591
97a34db9
TT
15922018-07-09 Tom Tromey <tom@tromey.com>
1593
1594 * Makefile.in (TSOBS): Remove.
1595 (INIT_FILES): Update.
1596 (LIBGDB_OBS): Update.
1597 (COMMON_SFILES): Add inflow.c.
1598 (SFILES): Remove inflow.c.
1599
25289ac1
JK
16002018-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
1601
1602 * contrib/gdb-add-index.sh ($dwarf5): New, use it.
1603
e83f4d97
SM
16042018-07-07 Simon Marchi <simon.marchi@polymtl.ca>
1605
4869c585
SM
1606 * ia64-libunwind-tdep.c (get_reg_name, get_fpreg_name,
1607 get_saveloc_name, is_signal_frame_name, step_name,
1608 init_remote_name, create_addr_space_name,
1609 destroy_addr_space_name, search_unwind_table_name,
1610 find_dyn_list_name): Constify.
e83f4d97 1611
6821842f
SM
16122018-07-05 Simon Marchi <simon.marchi@polymtl.ca>
1613
1614 * darwin-nat.c (darwin_pthread_kill): New function.
1615 (darwin_resume_thread): Use darwin_pthread_kill.
1616
c530603c
TV
16172018-07-05 Tom de Vries <tdevries@suse.de>
1618
1619 * macroexp.c (macro_buffer) <operator=>: New member function.
1620
a7d0f0f0
TT
16212018-07-04 Tom Tromey <tom@tromey.com>
1622
1623 * darwin-nat.c (darwin_attach_pid): Use exit_inferior.
1624
6242c6a6
SM
16252018-07-04 Simon Marchi <simon.marchi@polymtl.ca>
1626
1627 * common/common-defs.h (HAVE_USEFUL_SBRK): Define.
1628 * main.c: Use HAVE_USEFUL_SBRK instead of HAVE_SBRK.
1629 * maint.c: Likewise.
1630 * top.c: Likewise.
1631
4e5b2f89
JB
16322018-07-04 Joel Brobecker <brobecker@adacore.com>
1633
1634 * NEWS: Create a new section for the next release branch.
1635 Rename the section of the current branch, now that it has
1636 been cut.
1637
538ccc4a
JB
16382018-07-04 Joel Brobecker <brobecker@adacore.com>
1639
1640 GDB 8.2 branch created (1b919490e8ba30bf1d6941df0ed112b0e557017e):
1641 * version.in: Bump version to 8.2.50.DATE-git.
1642
1b919490
VB
16432018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1644 Pedro Alves <palves@redhat.com>
1645
1646 * linux-nat.c (linux_init_ptrace): Rename to ...
1647 (linux_init_ptrace_procfs): ... this. Call
1648 linux_proc_init_warnings.
1649 (linux_nat_target::post_attach)
1650 (linux_nat_target::post_startup_inferior): Adjust.
1651 * nat/linux-procfs.c (linux_proc_init_warnings): Define function.
1652 * nat/linux-procfs.h (linux_proc_init_warnings): Declare function.
1653
1ea5da02
TV
16542018-07-04 Tom de Vries <tdevries@suse.de>
1655
1656 * dwarf2read.c (error_check_comp_unit_head): Move dwarf version
1657 check ...
1658 (read_comp_unit_head): ... here.
1659
f51e0e20
TT
16602018-07-03 Tom Tromey <tom@tromey.com>
1661
1662 * tracepoint.c (process_tracepoint_on_disconnect, start_tracing)
1663 (stop_tracing, tstatus_command)
1664 (find_matching_tracepoint_location, merge_uploaded_tracepoints)
1665 (print_one_static_tracepoint_marker): Update.
1666 * breakpoint.c (static_tracepoints_here, all_tracepoints): Return
1667 std::vector.
1668 * breakpoint.h (breakpoint_p): Remove typedef. Don't declare
1669 VEC.
1670 (all_tracepoints, static_tracepoints_here): Return std::vector.
1671
d7e15655
TT
16722018-07-03 Tom Tromey <tom@tromey.com>
1673
1674 * common/ptid.c (ptid_equal): Remove.
1675 * common/ptid.h (ptid_equal): Don't declare.
1676 * ada-tasks.c: Update.
1677 * breakpoint.c: Update.
1678 * common/agent.c: Update.
1679 * corelow.c: Update.
1680 * darwin-nat-info.c: Update.
1681 * darwin-nat.c: Update.
1682 * dcache.c: Update.
1683 * dtrace-probe.c: Update.
1684 * dummy-frame.c: Update.
1685 * fbsd-nat.c: Update.
1686 * frame.c: Update.
1687 * gdbthread.h: Update.
1688 * gnu-nat.c: Update.
1689 * go32-nat.c: Update.
1690 * inf-loop.c: Update.
1691 * inf-ptrace.c: Update.
1692 * infcall.c: Update.
1693 * infcmd.c: Update.
1694 * inflow.c: Update.
1695 * infrun.c: Update.
1696 * linux-fork.c: Update.
1697 * linux-nat.c: Update.
1698 * linux-thread-db.c: Update.
1699 * mi/mi-cmd-var.c: Update.
1700 * mi/mi-interp.c: Update.
1701 * mi/mi-main.c: Update.
1702 * nto-procfs.c: Update.
1703 * ppc-linux-tdep.c: Update.
1704 * procfs.c: Update.
1705 * python/py-inferior.c: Update.
1706 * python/py-record-btrace.c: Update.
1707 * python/py-record.c: Update.
1708 * ravenscar-thread.c: Update.
1709 * regcache.c: Update.
1710 * remote-sim.c: Update.
1711 * remote.c: Update.
1712 * sol-thread.c: Update.
1713 * solib.c: Update.
1714 * target.c: Update.
1715 * tui/tui-stack.c: Update.
1716 * varobj.c: Update.
1717 * windows-nat.c: Update.
1718 * windows-tdep.c: Update.
1719
26a57c92
TT
17202018-07-03 Tom Tromey <tom@tromey.com>
1721
1722 * common/ptid.c (ptid_match): Remove.
1723 * common/ptid.h (ptid_match): Don't declare.
1724 * fbsd-nat.c: Update.
1725 * infcmd.c: Update.
1726 * infrun.c: Update.
1727 * linux-nat.c: Update.
1728 * record-btrace.c: Update.
1729 * regcache.c: Update.
1730 * remote.c: Update.
1731
d2a107e3
TT
17322018-07-03 Tom Tromey <tom@tromey.com>
1733
1734 * common/ptid.c (ptid_tid_p): Remove.
1735 * common/ptid.h (ptid_tid_p): Don't declare.
1736 * sol-thread.c: Update.
1737
15a9e13e
TT
17382018-07-03 Tom Tromey <tom@tromey.com>
1739
1740 * common/ptid.c (ptid_lwp_p): Remove.
1741 * common/ptid.h (ptid_lwp_p): Don't declare.
1742 * fbsd-nat.c: Update.
1743 * linux-nat.c: Update.
1744 * nat/linux-procfs.c: Update.
1745 * nat/x86-linux-dregs.c: Update.
1746 * sol-thread.c: Update.
1747
0e998d96
TT
17482018-07-03 Tom Tromey <tom@tromey.com>
1749
1750 * common/ptid.c (ptid_is_pid): Remove.
1751 * common/ptid.h (ptid_is_pid): Don't declare.
1752 * infrun.c: Update.
1753 * linux-nat.c: Update.
1754 * mi/mi-interp.c: Update.
1755 * remote.c: Update.
1756 * thread.c: Update.
1757
cc6bcb54
TT
17582018-07-03 Tom Tromey <tom@tromey.com>
1759
1760 * common/ptid.c (ptid_get_tid): Remove.
1761 * common/ptid.h (ptid_get_tid): Don't declare.
1762 * ada-tasks.c: Update.
1763 * aix-thread.c: Update.
1764 * bsd-uthread.c: Update.
1765 * darwin-nat.c: Update.
1766 * fbsd-nat.c: Update.
1767 * i386-darwin-nat.c: Update.
1768 * infrun.c: Update.
1769 * linux-tdep.c: Update.
1770 * nto-procfs.c: Update.
1771 * ppc-ravenscar-thread.c: Update.
1772 * python/py-infthread.c: Update.
1773 * ravenscar-thread.c: Update.
1774 * sol-thread.c: Update.
1775 * sparc-ravenscar-thread.c: Update.
1776 * windows-nat.c: Update.
1777
e38504b3
TT
17782018-07-03 Tom Tromey <tom@tromey.com>
1779
1780 * common/ptid.c (ptid_get_lwp): Remove.
1781 * common/ptid.h (ptid_get_lwp): Don't declare.
1782 * aarch64-linux-nat.c: Update.
1783 * ada-tasks.c: Update.
1784 * aix-thread.c: Update.
1785 * amd64-linux-nat.c: Update.
1786 * arm-linux-nat.c: Update.
1787 * corelow.c: Update.
1788 * fbsd-nat.c: Update.
1789 * fbsd-tdep.c: Update.
1790 * gnu-nat.c: Update.
1791 * i386-cygwin-tdep.c: Update.
1792 * i386-gnu-nat.c: Update.
1793 * i386-linux-nat.c: Update.
1794 * ia64-linux-nat.c: Update.
1795 * inf-ptrace.c: Update.
1796 * infrun.c: Update.
1797 * linux-fork.c: Update.
1798 * linux-nat.c: Update.
1799 * linux-tdep.c: Update.
1800 * linux-thread-db.c: Update.
1801 * mips-linux-nat.c: Update.
1802 * nat/aarch64-linux-hw-point.c: Update.
1803 * nat/aarch64-linux.c: Update.
1804 * nat/linux-btrace.c: Update.
1805 * nat/linux-osdata.c: Update.
1806 * nat/linux-procfs.c: Update.
1807 * nat/x86-linux-dregs.c: Update.
1808 * obsd-nat.c: Update.
1809 * ppc-fbsd-nat.c: Update.
1810 * ppc-linux-nat.c: Update.
1811 * procfs.c: Update.
1812 * python/py-infthread.c: Update.
1813 * ravenscar-thread.c: Update.
1814 * remote.c: Update.
1815 * s390-linux-nat.c: Update.
1816 * sol-thread.c: Update.
1817 * sol2-tdep.c: Update.
1818 * spu-linux-nat.c: Update.
1819 * x86-linux-nat.c: Update.
1820 * xtensa-linux-nat.c: Update.
1821
e99b03dc
TT
18222018-07-03 Tom Tromey <tom@tromey.com>
1823
1824 * common/ptid.c (ptid_get_pid): Remove.
1825 * common/ptid.h (ptid_get_pid): Don't declare.
1826 * aarch64-linux-nat.c: Update.
1827 * ada-lang.c: Update.
1828 * aix-thread.c: Update.
1829 * alpha-bsd-nat.c: Update.
1830 * amd64-fbsd-nat.c: Update.
1831 * amd64-linux-nat.c: Update.
1832 * arm-linux-nat.c: Update.
1833 * arm-nbsd-nat.c: Update.
1834 * auxv.c: Update.
1835 * break-catch-syscall.c: Update.
1836 * breakpoint.c: Update.
1837 * bsd-uthread.c: Update.
1838 * corelow.c: Update.
1839 * ctf.c: Update.
1840 * darwin-nat.c: Update.
1841 * fbsd-nat.c: Update.
1842 * fbsd-tdep.c: Update.
1843 * gcore.c: Update.
1844 * gnu-nat.c: Update.
1845 * hppa-nbsd-nat.c: Update.
1846 * hppa-obsd-nat.c: Update.
1847 * i386-fbsd-nat.c: Update.
1848 * ia64-linux-nat.c: Update.
1849 * inf-ptrace.c: Update.
1850 * infcmd.c: Update.
1851 * inferior.c: Update.
1852 * inferior.h: Update.
1853 * inflow.c: Update.
1854 * infrun.c: Update.
1855 * linux-fork.c: Update.
1856 * linux-nat.c: Update.
1857 * linux-tdep.c: Update.
1858 * linux-thread-db.c: Update.
1859 * m68k-bsd-nat.c: Update.
1860 * mi/mi-interp.c: Update.
1861 * mi/mi-main.c: Update.
1862 * mips-linux-nat.c: Update.
1863 * mips-nbsd-nat.c: Update.
1864 * mips64-obsd-nat.c: Update.
1865 * nat/aarch64-linux-hw-point.c: Update.
1866 * nat/aarch64-linux.c: Update.
1867 * nat/linux-btrace.c: Update.
1868 * nat/linux-osdata.c: Update.
1869 * nat/linux-procfs.c: Update.
1870 * nat/x86-linux-dregs.c: Update.
1871 * nto-procfs.c: Update.
1872 * obsd-nat.c: Update.
1873 * ppc-linux-nat.c: Update.
1874 * ppc-nbsd-nat.c: Update.
1875 * ppc-obsd-nat.c: Update.
1876 * proc-service.c: Update.
1877 * procfs.c: Update.
1878 * python/py-inferior.c: Update.
1879 * python/py-infthread.c: Update.
1880 * ravenscar-thread.c: Update.
1881 * record.c: Update.
1882 * remote-sim.c: Update.
1883 * remote.c: Update.
1884 * rs6000-nat.c: Update.
1885 * s390-linux-nat.c: Update.
1886 * sh-nbsd-nat.c: Update.
1887 * sol-thread.c: Update.
1888 * sparc-nat.c: Update.
1889 * sparc64-tdep.c: Update.
1890 * spu-linux-nat.c: Update.
1891 * spu-tdep.c: Update.
1892 * target-debug.h: Update.
1893 * target.c: Update.
1894 * thread.c: Update.
1895 * tid-parse.c: Update.
1896 * tracefile-tfile.c: Update.
1897 * vax-bsd-nat.c: Update.
1898 * windows-nat.c: Update.
1899 * x86-linux-nat.c: Update.
1900 * x86-nat.c: Update.
1901
f2907e49
TT
19022018-07-03 Tom Tromey <tom@tromey.com>
1903
1904 * common/ptid.c (pid_to_ptid): Remove.
1905 * common/ptid.h (pid_to_ptid): Don't declare.
1906 * aix-thread.c: Update.
1907 * arm-linux-nat.c: Update.
1908 * common/ptid.c: Update.
1909 * common/ptid.h: Update.
1910 * corelow.c: Update.
1911 * ctf.c: Update.
1912 * darwin-nat.c: Update.
1913 * fbsd-nat.c: Update.
1914 * fork-child.c: Update.
1915 * gnu-nat.c: Update.
1916 * go32-nat.c: Update.
1917 * inf-ptrace.c: Update.
1918 * infcmd.c: Update.
1919 * inferior.c: Update.
1920 * infrun.c: Update.
1921 * linux-fork.c: Update.
1922 * linux-nat.c: Update.
1923 * nat/aarch64-linux-hw-point.c: Update.
1924 * nat/fork-inferior.c: Update.
1925 * nat/x86-linux-dregs.c: Update.
1926 * nto-procfs.c: Update.
1927 * obsd-nat.c: Update.
1928 * procfs.c: Update.
1929 * progspace.c: Update.
1930 * remote.c: Update.
1931 * rs6000-nat.c: Update.
1932 * s390-linux-nat.c: Update.
1933 * sol-thread.c: Update.
1934 * spu-linux-nat.c: Update.
1935 * target.c: Update.
1936 * top.c: Update.
1937 * tracefile-tfile.c: Update.
1938 * windows-nat.c: Update.
1939
fd79271b
TT
19402018-07-03 Tom Tromey <tom@tromey.com>
1941
1942 * common/ptid.h (ptid_build): Don't declare.
1943 * common/ptid.c (ptid_build): Remove.
1944 * aix-thread.c: Update.
1945 * bsd-kvm.c: Update.
1946 * bsd-uthread.c: Update.
1947 * common/agent.c: Update.
1948 * common/ptid.c: Update.
1949 * common/ptid.h: Update.
1950 * corelow.c: Update.
1951 * darwin-nat.c: Update.
1952 * fbsd-nat.c: Update.
1953 * gnu-nat.c: Update.
1954 * linux-fork.c: Update.
1955 * linux-nat.c: Update.
1956 * linux-thread-db.c: Update.
1957 * nat/linux-osdata.c: Update.
1958 * nat/linux-procfs.c: Update.
1959 * nto-procfs.c: Update.
1960 * obsd-nat.c: Update.
1961 * proc-service.c: Update.
1962 * procfs.c: Update.
1963 * ravenscar-thread.c: Update.
1964 * remote-sim.c: Update.
1965 * remote.c: Update.
1966 * sol-thread.c: Update.
1967 * target.c: Update.
1968 * windows-nat.c: Update.
1969
057302ce
TT
19702018-07-03 Tom Tromey <tom@tromey.com>
1971
1972 * infrun.c (follow_exec): Use exit_inferior_silent.
1973 * inferior.c (exit_inferior_num_silent): Remove.
1974 * inferior.h (exit_inferior_num_silent): Don't declare.
1975
a50c11c6
TT
19762018-07-03 Tom Tromey <tom@tromey.com>
1977
1978 PR cli/23340:
1979 * darwin-nat.c (darwin_attach_pid): Reset inferior and
1980 inferior_ptid on error.
1981
471b9d15
MR
19822018-07-02 Maciej W. Rozycki <macro@mips.com>
1983 Simon Marchi <simon.marchi@polymtl.ca>
1984
1985 PR tdep/8282
1986 * disasm.h (gdb_disassembler): Add
1987 `m_disassembler_options_holder'. member
1988 * disasm.c (get_all_disassembler_options): New function.
1989 (gdb_disassembler::gdb_disassembler): Use it.
1990 (gdb_buffered_insn_length_init_dis): Likewise.
1991 (gdb_buffered_insn_length): Adjust accordingly.
1992 (set_disassembler_options): Handle options with arguments.
1993 (show_disassembler_options_sfunc): Likewise. Add a leading new
1994 line if showing options with descriptions.
1995 (disassembler_options_completer): Adapt to using the
1996 `disasm_options_and_args_t' structure.
1997 * mips-tdep.c (mips_disassembler_options): New variable.
1998 (mips_disassembler_options_o32): Likewise.
1999 (mips_disassembler_options_n32): Likewise.
2000 (mips_disassembler_options_n64): Likewise.
2001 (gdb_print_insn_mips): Don't set `disassembler_options'.
2002 (gdb_print_insn_mips_n32, gdb_print_insn_mips_n64): Remove
2003 functions.
2004 (mips_gdbarch_init): Always set `gdbarch_print_insn' to
2005 `gdb_print_insn_mips'. Set `gdbarch_disassembler_options',
2006 `gdbarch_disassembler_options_implicit' and
2007 `gdbarch_valid_disassembler_options'.
2008 * arm-tdep.c (_initialize_arm_tdep): Adapt to using the
2009 `disasm_options_and_args_t' structure.
2010 * gdbarch.sh (disassembler_options_implicit): New `gdbarch'
2011 method.
2012 (valid_disassembler_options): Switch from `disasm_options_t' to
2013 the `disasm_options_and_args_t' structure.
2014 * NEWS: Document `set disassembler-options' support for the MIPS
2015 target.
2016 * gdbarch.h: Regenerate.
2017 * gdbarch.c: Regenerate.
2018
41823f29
SH
20192018-07-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
2020
2021 * riscv-tdep.c (riscv_register_aliases): Swap "fp" and "s0" entries.
2022
41206e32
JB
20232018-06-29 Joel Brobecker <brobecker@adacore.com>
2024
2025 * amd64-darwin-tdep.c (x86_darwin_init_abi_64): Add missing
2026 parameter in call to amd64_target_description.
2027 * amd64-dicos-tdep.c (amd64_dicos_init_abi): Likewise.
2028 * amd64-fbsd-tdep.c (amd64fbsd_core_read_description)
2029 (amd64fbsd_init_abi): Likewise.
2030 * amd64-nbsd-tdep.c (amd64nbsd_init_abi): Likewise.
2031 * amd64-obsd-tdep.c (amd64obsd_init_abi): Likewise.
2032 * amd64-sol2-tdep.c (amd64_sol2_init_abi): Likewise.
2033 * amd64-fbsd-nat.c (amd64_fbsd_nat_target): Likewise.
2034
de52b960
PA
20352018-06-29 Pedro Alves <palves@redhat.com>
2036
2037 * gdb/amd64-tdep.h (amd64_create_target_description): Add
2038 "segments" parameter.
2039 * gdb/amd64-tdep.c (amd64_none_init_abi, amd64_x32_none_init_abi)
2040 (_initialize_amd64_tdep): Update call to
2041 amd64_create_target_description.
2042 (amd64_target_description): Add "segments" parameter. Adjust
2043 the implementation to use it.
2044 * gdb/amd64-linux-tdep.c (amd64_linux_read_description): Update
2045 call to amd64_create_target_description.
2046 * gdb/amd64-windows-tdep.c (amd64_windows_init_abi): Likewise.
2047 * gdb/arch/amd64.h (amd64_create_target_description): Add
2048 "segments" register.
2049 * gdb/arch/amd64.c (amd64_create_target_description): Add
2050 "segments" parameter. Call create_feature_i386_64bit_segments
2051 only if SEGMENTS is true.
2052 * gdb/gdbserver/win32-i386-low.c (i386_arch_setup): Update
2053 call to amd64_create_target_description.
2054
75acb486
PA
20552018-06-29 Pedro Alves <palves@redhat.com>
2056
2057 * thread.c (thread_target_id_str): New, factored out from ...
2058 (print_thread_info_1): ... here. Use it to compute the max
2059 "Target Id" column width.
2060
c76a8ea3
PA
20612018-06-29 Pedro Alves <palves@redhat.com>
2062
2063 * remote.c (remote_target::extra_thread_info): Delete
2064 'display_buf' and 'n' locals. from the cache, regardless of
2065 packet mechanims is in use. Use cache for qThreadExtra and qP
2066 methods too.
2067
cd2bb709
PA
20682018-06-29 Pedro Alves <palves@redhat.com>
2069
2070 * blockframe.c (find_pc_sect_containing_function): New function.
2071 * breakpoint.c (print_breakpoint_location): Don't call
2072 find_pc_sect_function.
2073 * linespec.c (create_sals_line_offset): Record the location's
2074 symbol in the sal.
2075 * linespec.c (convert_address_location_to_sals): Fill in sal's
2076 symbol with find_pc_sect_containing_function.
2077 * symtab.c (find_function_start_sal): Rename to ...
2078 (find_function_start_sal_1): ... this.
2079 (find_function_start_sal): Reimplement as wrapper around
2080 find_function_start_sal_1, and use
2081 find_pc_sect_containing_function to fill in the sal's symbol.
2082 (find_function_start_sal(symbol*, bool)): Adjust.
2083 * symtab.h (find_pc_function, find_pc_sect_function): Adjust
2084 comments.
2085 (find_pc_sect_containing_function): Declare.
2086
991ff292
PA
20872018-06-29 Pedro Alves <palves@redhat.com>
2088
2089 * inline-frame.c (stopped_by_user_bp_inline_frame): Return
2090 true if the the location has no symbol.
2091
44cee4fd
TT
20922018-06-28 Tom Tromey <tom@tromey.com>
2093
2094 * NEWS: Mention --enable-codesign.
2095 * silent-rules.mk (ECHO_SIGN): New variable.
2096 * configure.ac: Add --enable-codesign.
2097 * configure: Rebuild.
2098 * Makefile.in (CODESIGN, CODESIGN_CERT): New variables.
2099 (gdb$(EXEEXT)): Optionally invoke codesign.
2100
f2ffa92b
PA
21012018-06-28 Pedro Alves <palves@redhat.com>
2102
2103 * gdbthread.h (struct thread_suspend_state) <stop_pc>: Extend
2104 comments.
2105 (switch_to_thread_no_regs): Adjust comment.
2106 * infcmd.c (stop_pc): Delete.
2107 (post_create_inferior, info_program_command): Replace references
2108 to stop_pc with references to thread_info->suspend.stop_pc.
2109 * inferior.h (stop_pc): Delete declaration.
2110 * infrun.c (proceed, handle_syscall_event, fill_in_stop_func)
2111 (handle_inferior_event_1, handle_signal_stop)
2112 (process_event_stop_test, keep_going_stepped_thread)
2113 (handle_step_into_function, handle_step_into_function_backward)
2114 (print_stop_location): Replace references to stop_pc with
2115 references to thread_info->suspend.stop_pc.
2116 (struct infcall_suspend_state) <stop_pc>: Delete field.
2117 (save_infcall_suspend_state, restore_infcall_suspend_state):
2118 Remove references to inf_stat->stop_pc.
2119 * linux-fork.c (fork_load_infrun_state): Likewise.
2120 * record-btrace.c (record_btrace_set_replay): Likewise.
2121 * record-full.c (record_full_goto_entry): Likewise.
2122 * remote.c (print_one_stopped_thread): Likewise.
2123 * target.c (target_resume): Extend comment.
2124 * thread.c (set_executing_thread): New.
2125 (set_executing): Use it.
2126 (switch_to_thread_no_regs, switch_to_no_thread, switch_to_thread):
2127 Remove references to stop_pc.
2128
ecdc3a72
PA
21292018-06-28 Pedro Alves <palves@redhat.com>
2130
2131 * infrun.c (handle_inferior_event_1) <TARGET_WAITKIND_EXECD>:
2132 Moving fetching stop_pc until after ecs->event_thread is refreshed.
2133
d95d3aef
TT
21342018-06-28 Tom Tromey <tom@tromey.com>
2135
2136 * coffread.c (coff_symfile_finish): Update.
2137 * xcoffread.c (xcoff_symfile_finish): Update.
2138 * elfread.c (elf_symfile_finish): Update.
2139 * symfile.h (dwarf2_free_objfile): Don't declare.
2140 * dwarf2read.c (_initialize_dwarf2_read): Use
2141 register_objfile_data_with_cleanup.
2142 (dwarf2_free_objfile): Now static. Change signature.
2143
291f9a96
PT
21442018-06-28 Petr Tesarik <ptesarik@suse.cz>
2145
2146 * symfile.c (add_symbol_file_command, _initialize_symfile): Add
2147 option "-o" to add-symbol-file-load to add an offset to each
2148 section's load address.
2149 * symfile.c (set_objfile_default_section_offset): New function.
2150
d81a3eaf
PT
21512018-06-28 Petr Tesarik <ptesarik@suse.cz>
2152
2153 * symfile.c (add_symbol_file_command): Make sure that sections
2154 with the same name are sorted in the same order.
2155
ed6dfe51
PT
21562018-06-28 Petr Tesarik <ptesarik@suse.cz>
2157
2158 * symfile.c (add_symbol_file_command, _initialize_symfile): Do not
2159 require the second argument. If omitted, load sections at the
2160 addresses specified in the file.
2161
d4d429d5
PT
21622018-06-28 Petr Tesarik <ptesarik@suse.cz>
2163
2164 * symfile.c (symbol_file_command, symbol_file_add_main_1)
2165 (_initialize_symfile): Add option "-o" to symbol-file to add an
2166 offset to each section of the symbol file.
2167
39b27ab6
PT
21682018-06-28 Petr Tesarik <ptesarik@suse.cz>
2169
2170 * MAINTAINERS (Write After Approval): Add Petr Tesarik.
2171
41827fc3
TT
21722018-06-27 Tom Tromey <tom@tromey.com>
2173
2174 * stack.c (_initialize_stack): Update "func" help text.
2175
0c6aef22
TT
21762018-06-27 Tom Tromey <tom@tromey.com>
2177
2178 * python/py-unwind.c (unwind_info_object) <saved_regs>: Now a
2179 std::vector.
2180 (unwind_infopy_str, pyuw_create_unwind_info)
2181 (unwind_infopy_add_saved_register, pyuw_sniffer)
2182 (unwind_infopy_dealloc, unwind_infopy_add_saved_register):
2183 Update.
2184 (struct saved_reg): Add constructor.
2185 <value>: Now a gdbpy_ref<>.
2186
63177289
TT
21872018-06-27 Tom Tromey <tom@tromey.com>
2188
2189 * machoread.c (macho_symfile_read): Define "symbol_table" earlier.
2190
e76f78a0
SM
21912018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2192
2193 * gdb-gdb.py.in: Format using autopep8.
2194
9a14af7b
SM
21952018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2196
2197 * gdb-gdb.py.in (CoreAddrPrettyPrinter): New class.
2198 (type_lookup_function): Recognize CORE_ADDR values.
2199
189366cd
SM
22002018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2201
2202 * gdb-gdb.py.in (StructMainTypePrettyPrinter) <to_string>: Don't
2203 print tag_name.
2204
68ad5fb9
SM
22052018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2206
2207 * gdb-gdb.py.in (TypeFlag) <__cmp__>: Remove.
2208 <__lt__>: Add.
2209
141ec9f6
SM
22102018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2211
2212 * gdb-gdb.py: Move to...
2213 * gdb-gdb.py.in: ... here.
2214 * configure.ac (AC_CONFIG_FILES): Add gdb-gdb.py.
2215 * Makefile.in (all): Add gdb-gdb.gdb and gdb-gdb.py as
2216 dependencies.
2217 (distclean): Remove gdb-gdb.py when cleaning.
2218 (gdb-gdb.py, gdb-gdb.gdb): New rules.
2219 * configure: Re-generate.
2220
4c4e7ad4
PA
22212018-06-27 Pedro Alves <palves@redhat.com>
2222
2223 * proc-service.c (get_ps_regcache): New.
2224 (ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
2225 (ps_lsetfpregs): Use it.
2226
7ab6656f
OJ
22272018-06-27 Omair Javaid <omair.javaid@linaro.org>
2228
2229 PR gdb/21695
2230 * dwarf2read.c (lnp_state_machine::check_line_address): Update declaration.
2231 (dwarf_decode_lines_1): Adjust.
2232
bd583225
SM
22332018-06-27 Simon Marchi <simon.marchi@ericsson.com>
2234
2235 * fbsd-nat.h (class fbsd_nat_target) <find_memory_regions>: Add
2236 override.
2237 <info_proc>: Likewise.
2238
9a325b7b
JB
22392018-06-26 Joel Brobecker <brobecker@adacore.com>
2240
2241 * windows-nat.c (do_windows_fetch_inferior_registers): Rename
2242 to windows_fetch_one_register, and only handle the case of
2243 fetching one register. Move the code that reloads the context
2244 and iterates over all registers if R is negative to...
2245 (windows_nat_target::fetch_registers): ... here.
2246 (do_windows_store_inferior_registers): Rename to
2247 windows_store_one_register, and only handle the case of storing
2248 one register. Move the code that handles the case where r is
2249 negative to...
2250 (windows_nat_target::store_registers) ... here.
2251
a33ccfc7
TT
22522018-06-26 Tom Tromey <tom@tromey.com>
2253
2254 PR rust/22574:
2255 * typeprint.c (whatis_exp): Allow ptype/o for Rust.
2256 * rust-lang.c (rust_print_struct_def): Add podata parameter.
2257 Update.
2258 (rust_internal_print_type): Add podata parameter.
2259 (rust_print_type): Update.
2260
e0c547d1
TT
22612018-06-26 Tom Tromey <tom@tromey.com>
2262
2263 * typeprint.h (struct print_offset_data) <update, finish,
2264 maybe_print_hole>: New methods.
2265 <indentation>: New constant.
2266 * typeprint.c (print_offset_data::indentation): Define.
2267 (print_offset_data::maybe_print_hole, print_offset_data::update)
2268 (print_offset_data::finish): Move from c-typeprint.c and rename.
2269 * c-typeprint.c (OFFSET_SPC_LEN): Remove.
2270 (print_spaces_filtered_with_print_options): Update.
2271 (c_print_type_union_field_offset, maybe_print_hole)
2272 (c_print_type_struct_field_offset): Move to typeprint.c and
2273 rename.
2274 (c_type_print_base_struct_union): Update.
2275
75cbc781
PA
22762018-06-25 Pedro Alves <palves@redhat.com>
2277
2278 * gdbthread.h (thread_info_ref, delete_thread)
2279 (delete_thread_silent, first_thread_of_inferior)
2280 (any_thread_of_inferior, switch_to_thread)
2281 (enable_thread_stack_temporaries)
2282 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2283 (get_last_thread_stack_temporary)
2284 (value_in_thread_stack_temporaries, can_access_registers_thread):
2285 Spell out "struct thread_info" instead of just "thread_info".
2286 * inferior.h (notice_new_inferior): Likewise.
2287
b7a08269
PA
22882018-06-25 Pedro Alves <palves@redhat.com>
2289
2290 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2291 pass thread_info pointer to delete_thread.
2292 (windows_nat_target::detach): Pass inferior pointer to
2293 detach_inferior.
2294 * aix-thread.c (sync_threadlists): Pass thread_info pointer to
2295 delete_thread.
2296 * bsd-kvm.c (bsd_kvm_target::close): Use discard_all_inferiors.
2297 * darwin-nat.c (darwin_check_new_threads): Use find_thread_ptid
2298 and pass a thread_info pointer to delete_thread.
2299 * fbsd-nat.c (fbsd_nat_target::wait): Use find_thread_ptid and
2300 pass thread_info pointer to delete_thread.
2301 * go32-nat.c (go32_nat_target::mourn_inferior): Remove
2302 delete_thread_silent call.
2303 * procfs.c (procfs_target::detach): Pass inferior pointer to
2304 detach_inferior.
2305 (procfs_target::wait): Pass thread_info pointer to delete_thread.
2306 * remote-sim.c (gdbsim_target::mourn_inferior): Remove
2307 delete_thread_silent call.
2308 * windows-nat.c (windows_delete_thread): Use find_thread_ptid and
2309 pass thread_info pointer to delete_thread.
2310 (windows_nat_target::detach): Pass inferior pointer to
2311 delete_inferior.
2312
8e7767e3
AH
23132018-06-22 Alan Hayward <alan.hayward@arm.com>
2314
2315 * regcache.c (readable_regcache::read_part): Fix asserts.
2316 (reg_buffer::raw_collect_part): New function.
2317 (regcache::write_part): Fix asserts.
2318 (reg_buffer::raw_supply_part): New function.
2319 (regcache::transfer_regset_register): New helper function.
2320 (regcache::transfer_regset): Call new functions.
2321 (regcache_supply_regset): Use gdb_byte*.
2322 (regcache::supply_regset): Likewise.
2323 (regcache_collect_regset): Likewise.
2324 (regcache::collect_regset): Likewise.
2325 * regcache.h (reg_buffer::raw_collect_part): New declaration.
2326 (reg_buffer::raw_supply_part): Likewise.
2327 (regcache::transfer_regset_register): Likewise.
2328 (regcache::transfer_regset): Use gdb_byte*.
2329
bfd60e34
AH
23302018-06-22 Alan Hayward <alan.hayward@arm.com>
2331
2332 * nat/aarch64-sve-linux-ptrace.h (HAS_SVE_STATE): Use &.
2333
00431a78
PA
23342018-06-21 Pedro Alves <palves@redhat.com>
2335
2336 * ada-lang.h (ada_get_task_number): Take a thread_info pointer
2337 instead of a ptid_t. All callers adjusted.
2338 * ada-tasks.c (ada_get_task_number): Likewise. All callers
2339 adjusted.
2340 (print_ada_task_info, display_current_task_id, task_command_1):
2341 Adjust.
2342 * breakpoint.c (watchpoint_in_thread_scope): Adjust to use
2343 inferior_thread.
2344 (breakpoint_kind): Adjust.
2345 (remove_breakpoints_pid): Rename to ...
2346 (remove_breakpoints_inf): ... this. Adjust to take an inferior
2347 pointer. All callers adjusted.
2348 (bpstat_clear_actions): Use inferior_thread.
2349 (get_bpstat_thread): New.
2350 (bpstat_do_actions): Use it.
2351 (bpstat_check_breakpoint_conditions, bpstat_stop_status): Adjust
2352 to take a thread_info pointer. All callers adjusted.
2353 (set_longjmp_breakpoint_for_call_dummy, set_momentary_breakpoint)
2354 (breakpoint_re_set_thread): Use inferior_thread.
2355 * breakpoint.h (struct inferior): Forward declare.
2356 (bpstat_stop_status): Update.
2357 (remove_breakpoints_pid): Delete.
2358 (remove_breakpoints_inf): New.
2359 * bsd-uthread.c (bsd_uthread_target::wait)
2360 (bsd_uthread_target::update_thread_list): Use find_thread_ptid.
2361 * btrace.c (btrace_add_pc, btrace_enable, btrace_fetch)
2362 (maint_btrace_packet_history_cmd)
2363 (maint_btrace_clear_packet_history_cmd): Adjust.
2364 (maint_btrace_clear_cmd, maint_info_btrace_cmd): Adjust to use
2365 inferior_thread.
2366 * cli/cli-interp.c: Include "inferior.h".
2367 * common/refcounted-object.h (struct
2368 refcounted_object_ref_policy): New.
2369 * compile/compile-object-load.c: Include gdbthread.h.
2370 (store_regs): Use inferior_thread.
2371 * corelow.c (core_target::close): Use current_inferior.
2372 (core_target_open): Adjust to use first_thread_of_inferior and use
2373 the current inferior.
2374 * ctf.c (ctf_target::close): Adjust to use current_inferior.
2375 * dummy-frame.c (dummy_frame_id) <ptid>: Delete, replaced by ...
2376 <thread>: ... this new field. All references adjusted.
2377 (dummy_frame_pop, dummy_frame_discard, register_dummy_frame_dtor):
2378 Take a thread_info pointer instead of a ptid_t.
2379 * dummy-frame.h (dummy_frame_push, dummy_frame_pop)
2380 (dummy_frame_discard, register_dummy_frame_dtor): Take a
2381 thread_info pointer instead of a ptid_t.
2382 * elfread.c: Include "inferior.h".
2383 (elf_gnu_ifunc_resolver_stop, elf_gnu_ifunc_resolver_return_stop):
2384 Use inferior_thread.
2385 * eval.c (evaluate_subexp): Likewise.
2386 * frame.c (frame_pop, has_stack_frames, find_frame_sal): Use
2387 inferior_thread.
2388 * gdb_proc_service.h (struct thread_info): Forward declare.
2389 (struct ps_prochandle) <ptid>: Delete, replaced by ...
2390 <thread>: ... this new field. All references adjusted.
2391 * gdbarch.h, gdbarch.c: Regenerate.
2392 * gdbarch.sh (get_syscall_number): Replace 'ptid' parameter with a
2393 'thread' parameter. All implementations and callers adjusted.
2394 * gdbthread.h (thread_info) <set_running>: New method.
2395 (delete_thread, delete_thread_silent): Take a thread_info pointer
2396 instead of a ptid.
2397 (global_thread_id_to_ptid, ptid_to_global_thread_id): Delete.
2398 (first_thread_of_process): Delete, replaced by ...
2399 (first_thread_of_inferior): ... this new function. All callers
2400 adjusted.
2401 (any_live_thread_of_process): Delete, replaced by ...
2402 (any_live_thread_of_inferior): ... this new function. All callers
2403 adjusted.
2404 (switch_to_thread, switch_to_no_thread): Declare.
2405 (is_executing): Delete.
2406 (enable_thread_stack_temporaries): Update comment.
2407 <enable_thread_stack_temporaries>: Take a thread_info pointer
2408 instead of a ptid_t. Incref the thread.
2409 <~enable_thread_stack_temporaries>: Decref the thread.
2410 <m_ptid>: Delete
2411 <m_thr>: New.
2412 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2413 (get_last_thread_stack_temporary)
2414 (value_in_thread_stack_temporaries, can_access_registers_thread):
2415 Take a thread_info pointer instead of a ptid_t. All callers
2416 adjusted.
2417 * infcall.c (get_call_return_value): Use inferior_thread.
2418 (run_inferior_call): Work with thread pointers instead of ptid_t.
2419 (call_function_by_hand_dummy): Work with thread pointers instead
2420 of ptid_t. Use thread_info_ref.
2421 * infcmd.c (proceed_thread_callback): Access thread's state
2422 directly.
2423 (ensure_valid_thread, ensure_not_running): Use inferior_thread,
2424 access thread's state directly.
2425 (continue_command): Use inferior_thread.
2426 (info_program_command): Use find_thread_ptid and access thread
2427 state directly.
2428 (proceed_after_attach_callback): Use thread state directly.
2429 (notice_new_inferior): Take a thread_info pointer instead of a
2430 ptid_t. All callers adjusted.
2431 (exit_inferior): Take an inferior pointer instead of a pid. All
2432 callers adjusted.
2433 (exit_inferior_silent): New.
2434 (detach_inferior): Delete.
2435 (valid_gdb_inferior_id, pid_to_gdb_inferior_id)
2436 (gdb_inferior_id_to_pid, in_inferior_list): Delete.
2437 (detach_inferior_command, kill_inferior_command): Use
2438 find_inferior_id instead of valid_gdb_inferior_id and
2439 gdb_inferior_id_to_pid.
2440 (inferior_command): Use inferior and thread pointers.
2441 * inferior.h (struct thread_info): Forward declare.
2442 (notice_new_inferior): Take a thread_info pointer instead of a
2443 ptid_t. All callers adjusted.
2444 (detach_inferior): Delete declaration.
2445 (exit_inferior, exit_inferior_silent): Take an inferior pointer
2446 instead of a pid. All callers adjusted.
2447 (gdb_inferior_id_to_pid, pid_to_gdb_inferior_id, in_inferior_list)
2448 (valid_gdb_inferior_id): Delete.
2449 * infrun.c (follow_fork_inferior, proceed_after_vfork_done)
2450 (handle_vfork_child_exec_or_exit, follow_exec): Adjust.
2451 (struct displaced_step_inferior_state) <pid>: Delete, replaced by
2452 ...
2453 <inf>: ... this new field.
2454 <step_ptid>: Delete, replaced by ...
2455 <step_thread>: ... this new field.
2456 (get_displaced_stepping_state): Take an inferior pointer instead
2457 of a pid. All callers adjusted.
2458 (displaced_step_in_progress_any_inferior): Adjust.
2459 (displaced_step_in_progress_thread): Take a thread pointer instead
2460 of a ptid_t. All callers adjusted.
2461 (displaced_step_in_progress, add_displaced_stepping_state): Take
2462 an inferior pointer instead of a pid. All callers adjusted.
2463 (get_displaced_step_closure_by_addr): Adjust.
2464 (remove_displaced_stepping_state): Take an inferior pointer
2465 instead of a pid. All callers adjusted.
2466 (displaced_step_prepare_throw, displaced_step_prepare)
2467 (displaced_step_fixup): Take a thread pointer instead of a ptid_t.
2468 All callers adjusted.
2469 (start_step_over): Adjust.
2470 (infrun_thread_ptid_changed): Remove bit updating ptids in the
2471 displaced step queue.
2472 (do_target_resume): Adjust.
2473 (fetch_inferior_event): Use inferior_thread.
2474 (context_switch, get_inferior_stop_soon): Take an
2475 execution_control_state pointer instead of a ptid_t. All callers
2476 adjusted.
2477 (switch_to_thread_cleanup): Delete.
2478 (stop_all_threads): Use scoped_restore_current_thread.
2479 * inline-frame.c: Include "gdbthread.h".
2480 (inline_state) <inline_state>: Take a thread pointer instead of a
2481 ptid_t. All callers adjusted.
2482 <ptid>: Delete, replaced by ...
2483 <thread>: ... this new field.
2484 (find_inline_frame_state): Take a thread pointer instead of a
2485 ptid_t. All callers adjusted.
2486 (skip_inline_frames, step_into_inline_frame)
2487 (inline_skipped_frames, inline_skipped_symbol): Take a thread
2488 pointer instead of a ptid_t. All callers adjusted.
2489 * inline-frame.h (skip_inline_frames, step_into_inline_frame)
2490 (inline_skipped_frames, inline_skipped_symbol): Likewise.
2491 * linux-fork.c (delete_checkpoint_command): Adjust to use thread
2492 pointers directly.
2493 * linux-nat.c (get_detach_signal): Likewise.
2494 * linux-thread-db.c (thread_from_lwp): New 'stopped' parameter.
2495 (thread_db_notice_clone): Adjust.
2496 (thread_db_find_new_threads_silently)
2497 (thread_db_find_new_threads_2, thread_db_find_new_threads_1): Take
2498 a thread pointer instead of a ptid_t. All callers adjusted.
2499 * mi/mi-cmd-var.c: Include "inferior.h".
2500 (mi_cmd_var_update_iter): Update to use thread pointers.
2501 * mi/mi-interp.c (mi_new_thread): Update to use the thread's
2502 inferior directly.
2503 (mi_output_running_pid, mi_inferior_count): Delete, bits factored
2504 out to ...
2505 (mi_output_running): ... this new function.
2506 (mi_on_resume_1): Adjust to use it.
2507 (mi_user_selected_context_changed): Adjust to use inferior_thread.
2508 * mi/mi-main.c (proceed_thread): Adjust to use thread pointers
2509 directly.
2510 (interrupt_thread_callback): : Adjust to use thread and inferior
2511 pointers.
2512 * proc-service.c: Include "gdbthread.h".
2513 (ps_pglobal_lookup): Adjust to use the thread's inferior directly.
2514 * progspace-and-thread.c: Include "inferior.h".
2515 * progspace.c: Include "inferior.h".
2516 * python/py-exitedevent.c (create_exited_event_object): Adjust to
2517 hold a reference to an inferior_object.
2518 * python/py-finishbreakpoint.c (bpfinishpy_init): Adjust to use
2519 inferior_thread.
2520 * python/py-inferior.c (struct inferior_object): Give the type a
2521 tag name instead of a typedef.
2522 (python_on_normal_stop): No need to check if the current thread is
2523 listed.
2524 (inferior_to_inferior_object): Change return type to
2525 inferior_object. All callers adjusted.
2526 (find_thread_object): Delete, bits factored out to ...
2527 (thread_to_thread_object): ... this new function.
2528 * python/py-infthread.c (create_thread_object): Use
2529 inferior_to_inferior_object.
2530 (thpy_is_stopped): Use thread pointer directly.
2531 (gdbpy_selected_thread): Use inferior_thread.
2532 * python/py-record-btrace.c (btpy_list_object) <ptid>: Delete
2533 field, replaced with ...
2534 <thread>: ... this new field. All users adjusted.
2535 (btpy_insn_or_gap_new): Drop const.
2536 (btpy_list_new): Take a thread pointer instead of a ptid_t. All
2537 callers adjusted.
2538 * python/py-record.c: Include "gdbthread.h".
2539 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2540 a ptid_t. All callers adjusted.
2541 (gdbpy_current_recording): Use inferior_thread.
2542 * python/py-record.h (recpy_record_object) <ptid>: Delete
2543 field, replaced with ...
2544 <thread>: ... this new field. All users adjusted.
2545 (recpy_element_object) <ptid>: Delete
2546 field, replaced with ...
2547 <thread>: ... this new field. All users adjusted.
2548 (recpy_insn_new, recpy_func_new): Take a thread pointer instead of
2549 a ptid_t. All callers adjusted.
2550 * python/py-threadevent.c: Include "gdbthread.h".
2551 (get_event_thread): Use thread_to_thread_object.
2552 * python/python-internal.h (struct inferior_object): Forward
2553 declare.
2554 (find_thread_object, find_inferior_object): Delete declarations.
2555 (thread_to_thread_object, inferior_to_inferior_object): New
2556 declarations.
2557 * record-btrace.c: Include "inferior.h".
2558 (require_btrace_thread): Use inferior_thread.
2559 (record_btrace_frame_sniffer)
2560 (record_btrace_tailcall_frame_sniffer): Use inferior_thread.
2561 (get_thread_current_frame): Use scoped_restore_current_thread and
2562 switch_to_thread.
2563 (get_thread_current_frame): Use thread pointer directly.
2564 (record_btrace_replay_at_breakpoint): Use thread's inferior
2565 pointer directly.
2566 * record-full.c: Include "inferior.h".
2567 * regcache.c: Include "gdbthread.h".
2568 (get_thread_arch_regcache): Use the inferior's address space
2569 directly.
2570 (get_thread_regcache, registers_changed_thread): New.
2571 * regcache.h (get_thread_regcache(thread_info *thread)): New
2572 overload.
2573 (registers_changed_thread): New.
2574 (remote_target) <remote_detach_1>: Swap order of parameters.
2575 (remote_add_thread): <remote_add_thread>: Return the new thread.
2576 (get_remote_thread_info(ptid_t)): New overload.
2577 (remote_target::remote_notice_new_inferior): Use thread pointers
2578 directly.
2579 (remote_target::process_initial_stop_replies): Use
2580 thread_info::set_running.
2581 (remote_target::remote_detach_1, remote_target::detach)
2582 (extended_remote_target::detach): Adjust.
2583 * stack.c (frame_show_address): Use inferior_thread.
2584 * target-debug.h (target_debug_print_thread_info_pp): New.
2585 * target-delegates.c: Regenerate.
2586 * target.c (default_thread_address_space): Delete.
2587 (memory_xfer_partial_1): Use current_inferior.
2588 (target_detach): Use current_inferior.
2589 (target_thread_address_space): Delete.
2590 (generic_mourn_inferior): Use current_inferior.
2591 * target.h (struct target_ops) <thread_address_space>: Delete.
2592 (target_thread_address_space): Delete.
2593 * thread.c (init_thread_list): Use ALL_THREADS_SAFE. Use thread
2594 pointers directly.
2595 (delete_thread_1, delete_thread, delete_thread_silent): Take a
2596 thread pointer instead of a ptid_t. Adjust all callers.
2597 (ptid_to_global_thread_id, global_thread_id_to_ptid): Delete.
2598 (first_thread_of_process): Delete, replaced by ...
2599 (first_thread_of_inferior): ... this new function. All callers
2600 adjusted.
2601 (any_thread_of_process): Rename to ...
2602 (any_thread_of_inferior): ... this, and take an inferior pointer.
2603 (any_live_thread_of_process): Rename to ...
2604 (any_live_thread_of_inferior): ... this, and take an inferior
2605 pointer.
2606 (thread_stack_temporaries_enabled_p, push_thread_stack_temporary)
2607 (value_in_thread_stack_temporaries)
2608 (get_last_thread_stack_temporary): Take a thread pointer instead
2609 of a ptid_t. Adjust all callers.
2610 (thread_info::set_running): New.
2611 (validate_registers_access): Use inferior_thread.
2612 (can_access_registers_ptid): Rename to ...
2613 (can_access_registers_thread): ... this, and take a thread
2614 pointer.
2615 (print_thread_info_1): Adjust to compare thread pointers instead
2616 of ptids.
2617 (switch_to_no_thread, switch_to_thread): Make extern.
2618 (scoped_restore_current_thread::~scoped_restore_current_thread):
2619 Use m_thread pointer directly.
2620 (scoped_restore_current_thread::scoped_restore_current_thread):
2621 Use inferior_thread.
2622 (thread_command): Use thread pointer directly.
2623 (thread_num_make_value_helper): Use inferior_thread.
2624 * top.c (execute_command): Use inferior_thread.
2625 * tui/tui-interp.c: Include "inferior.h".
2626 * varobj.c (varobj_create): Use inferior_thread.
2627 (value_of_root_1): Use find_thread_global_id instead of
2628 global_thread_id_to_ptid.
2629
33bab475
AH
26302018-06-21 Alan Hayward <alan.hayward@arm.com>
2631
2632 * regcache.c (readable_regcache::read_part): Avoid memcpy when
2633 possible.
2634 (regcache::write_part): Likewise.
2635 (readable_regcache::cooked_read_part): Update comment.
2636 (readable_regcache::cooked_write_part): Likewise.
2637 * regcache.h: (readable_regcache::read_part): Likewise.
2638 (regcache::write_part): Likewise.
2639
8363f9d5
RB
26402018-06-21 Richard Bunt <richard.bunt@arm.com>
2641 Dirk Schubert <dirk.schubert@arm.com>
2642
2643 * aarch64-linux-nat.c (post_attach): New.
2644 (aarch64_linux_nat_target::post_attach): Override post_attach to
2645 record the number of hardware debug registers.
2646
0d0b0ea2
TT
26472018-06-20 Tom Tromey <tom@tromey.com>
2648
2649 * python/py-param.c (add_setshow_generic): Make parameters const.
2650 (parmpy_init): Update.
2651
302abd6e
SM
26522018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2653
2654 * regcache.h (regcache_cooked_read_ftype): Rename to...
2655 (register_read_ftype): ...this, change type to function_view.
2656 (class reg_buffer) <save>: Remove src parameter.
2657 (readonly_detached_regcache) <readonly_detached_regcache>: Make
2658 parameter non-const in first overload. Remove src parameter in
2659 second overload.
2660 * regcache.c (do_cooked_read): Remove.
2661 (readonly_detached_regcache::readonly_detached_regcache): Make
2662 parameter non-const, adjust call to other constructor.
2663 (reg_buffer::save): Remove src parameter.
2664 * frame.c (do_frame_register_read): Remove.
2665 (frame_save_as_regcache): Use lambda function.
2666 * ppc-linux-tdep.c (ppu2spu_unwind_register): Change type of src
2667 parameter to ppu2spu_data *.
2668 (ppu2spu_sniffer): Use lambda function.
2669
19f3f25f
SM
26702018-06-20 Simon Marchi <simon.marchi@polymtl.ca>
2671
2672 * record-full.c (record_full_target::insert_breakpoint): Remove
2673 "struct" keyword, add const.
2674
d0ac1c44
SM
26752018-06-19 Simon Marchi <simon.marchi@ericsson.com>
2676
2677 * common/common-defs.h (PACKAGE_NAME, PACKAGE_VERSION,
2678 PACKAGE_STRING, PACKAGE_TARNAME): Undefine.
2679 * configure.ac: Remove AC_PREREQ, add missing quoting.
2680 * gnulib/configure.ac: Modernize usage of
2681 AC_INIT/AM_INIT_AUTOMAKE. Remove AC_PREREQ.
2682 * gnulib/update-gnulib.sh (AUTOCONF_VERSION): Bump to 2.69.
2683 (AUTOMAKE_VERSION): Bump to 1.15.1.
2684 * configure: Re-generate.
2685 * config.in: Re-generate.
2686 * aclocal.m4: Re-generate.
2687 * gnulib/aclocal.m4: Re-generate.
2688 * gnulib/config.in: Re-generate.
2689 * gnulib/configure: Re-generate.
2690 * gnulib/import/Makefile.in: Re-generate.
2691
6ae50267
PA
26922018-06-19 Pedro Alves <palves@redhat.com>
2693
2694 * minsyms.c (msym_prefer_to_msym_type): New, factored out from ...
2695 (lookup_minimal_symbol_by_pc_section): ... here with
2696 gdb_assert_not_reached added.
2697
61b04dd0
PA
26982018-06-19 Pedro Alves <palves@redhat.com>
2699
2700 * inline-frame.c (stopped_by_user_bp_inline_frame): Replace PC
2701 parameter with a block parameter. Compare location's block symbol
2702 with the frame's block instead of addresses.
2703 (skip_inline_frames): Pass the current block instead of the
2704 frame's address. Break out as soon as we determine the frame
2705 should not be skipped.
2706
f709fabb
TT
27072018-06-18 Tom Tromey <tom@tromey.com>
2708
2709 * solib-aix.c (solib_aix_get_section_offsets): Return
2710 unique_xmalloc_ptr.
2711 (solib_aix_solib_create_inferior_hook): Update.
2712
668eb2f0
TT
27132018-06-18 Tom Tromey <tom@tromey.com>
2714
2715 * solib-darwin.c (darwin_current_sos): Use unique_xmalloc_ptr.
2716
309822ca
TT
27172018-06-18 Tom Tromey <tom@tromey.com>
2718
2719 * solib-frv.c (frv_relocate_main_executable): Use
2720 unique_xmalloc_ptr.
2721 * solib-dsbt.c (dsbt_relocate_main_executable): Use
2722 unique_xmalloc_ptr.
2723
06424eac
TT
27242018-06-18 Tom Tromey <tom@tromey.com>
2725
2726 * objfiles.h (inhibit_section_map_updates): Update.
2727 (resume_section_map_updates, resume_section_map_updates_cleanup):
2728 Remove.
2729 * solib-svr4.c (svr4_handle_solib_event): Update.
2730 * objfiles.c (inhibit_section_map_updates): Return
2731 scoped_restore_tmpl<int>.
2732 (resume_section_map_updates, resume_section_map_updates_cleanup):
2733 Remove.
2734
b4be9fad
TT
27352018-06-18 Tom Tromey <tom@tromey.com>
2736
2737 * valprint.h (read_string): Update.
2738 * valprint.c (read_string): Change type of "buffer".
2739 (val_print_string): Update.
2740 * python/py-value.c (valpy_string): Update.
2741 * language.h (struct language_defn) <la_get_string>: Change
2742 type of "buffer".
2743 (default_get_string, c_get_string): Update.
2744 * language.c (default_get_string): Change type of "buffer".
2745 * guile/scm-value.c (gdbscm_value_to_string): Update.
2746 * c-lang.c (c_get_string): Change type of "buffer".
2747
3f0dbd67
TT
27482018-06-18 Tom Tromey <tom@tromey.com>
2749
2750 * ser-mingw.c (struct pipe_state_destroyer): New.
2751 (pipe_state_up): New typedef.
2752 (cleanup_pipe_state): Remove.
2753 (pipe_windows_open): Use pipe_state_up. Don't release argv.
2754
69d340c6
TT
27552018-06-18 Tom Tromey <tom@tromey.com>
2756
2757 * rust-lang.h (rust_yyerror): Don't declare.
2758 * rust-lang.c (rust_language_defn): Update.
2759 * rust-exp.y (yyerror): Now static.
2760 * parse.c (parse_exp_in_context_1): Update.
2761 * p-lang.h (p_yyerror): Don't declare.
2762 * p-lang.c (p_language_defn): Update.
2763 * p-exp.y (yyerror): Now static.
2764 * opencl-lang.c (opencl_language_defn): Update.
2765 * objc-lang.c (objc_language_defn): Update.
2766 * m2-lang.h (m2_yyerror): Don't declare.
2767 * m2-lang.c (m2_language_defn): Update.
2768 * m2-exp.y (yyerror): Now static.
2769 * language.h (struct language_defn) <la_error>: Remove.
2770 * language.c (unk_lang_error): Remove.
2771 (unknown_language_defn, auto_language_defn): Remove.
2772 * go-lang.h (go_yyerror): Don't declare.
2773 * go-lang.c (go_language_defn): Update.
2774 * go-exp.y (yyerror): Now static.
2775 * f-lang.h (f_yyerror): Don't declare.
2776 * f-lang.c (f_language_defn): Update.
2777 * f-exp.y (yyerror): Now static.
2778 * d-lang.h (d_yyerror): Don't declare.
2779 * d-lang.c (d_language_defn): Update.
2780 * d-exp.y (yyerror): Now static.
2781 * c-lang.h (c_yyerror): Don't declare.
2782 * c-lang.c (c_language_defn, cplus_language_defn)
2783 (asm_language_defn, minimal_language_defn): Update.
2784 * c-exp.y (yyerror): Now static.
2785 * ada-lang.h (ada_yyerror): Don't declare.
2786 * ada-lang.c (ada_language_defn): Update.
2787 * ada-exp.y (yyerror): Now static.
2788
e9902bfc
AH
27892018-06-18 Alan Hayward <alan.hayward@arm.com>
2790
2791 * aarch64-linux-nat.c (fetch_sveregs_from_thread): New function.
2792 (store_sveregs_to_thread): Likewise.
2793 (aarch64_linux_fetch_inferior_registers): Check for SVE.
2794 (aarch64_linux_store_inferior_registers): Likewise.
2795 * nat/aarch64-sve-linux-ptrace.c (aarch64_sve_get_sveregs): New
2796 function.
2797 (aarch64_sve_regs_copy_to_regcache): Likewise.
2798 (aarch64_sve_regs_copy_from_regcache): Likewise.
2799 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_sveregs): New
2800 declaration.
2801 (aarch64_sve_regs_copy_to_regcache): Likewise.
2802 (aarch64_sve_regs_copy_from_regcache): Likewise.
2803 (sve_context): Structure from Linux headers.
2804 (SVE_SIG_ZREGS_SIZE): Define from Linux headers.
2805 (SVE_SIG_ZREG_SIZE): Likewise.
2806 (SVE_SIG_PREG_SIZE): Likewise.
2807 (SVE_SIG_FFR_SIZE): Likewise.
2808 (SVE_SIG_REGS_OFFSET): Likewise.
2809 (SVE_SIG_ZREGS_OFFSET): Likewise.
2810 (SVE_SIG_ZREG_OFFSET): Likewise.
2811 (SVE_SIG_ZREGS_SIZE): Likewise.
2812 (SVE_SIG_PREGS_OFFSET): Likewise.
2813 (SVE_SIG_PREG_OFFSET): Likewise.
2814 (SVE_SIG_PREGS_SIZE): Likewise.
2815 (SVE_SIG_FFR_OFFSET): Likewise.
2816 (SVE_SIG_REGS_SIZE): Likewise.
2817 (SVE_SIG_CONTEXT_SIZE): Likewise.
2818 (SVE_PT_REGS_MASK): Likewise.
2819 (SVE_PT_REGS_FPSIMD): Likewise.
2820 (SVE_PT_REGS_SVE): Likewise.
2821 (SVE_PT_VL_INHERIT): Likewise.
2822 (SVE_PT_VL_ONEXEC): Likewise.
2823 (SVE_PT_REGS_OFFSET): Likewise.
2824 (SVE_PT_FPSIMD_OFFSET): Likewise.
2825 (SVE_PT_FPSIMD_SIZE): Likewise.
2826 (SVE_PT_SVE_ZREG_SIZE): Likewise.
2827 (SVE_PT_SVE_PREG_SIZE): Likewise.
2828 (SVE_PT_SVE_FFR_SIZE): Likewise.
2829 (SVE_PT_SVE_FPSR_SIZE): Likewise.
2830 (SVE_PT_SVE_FPCR_SIZE): Likewise.
2831 (__SVE_SIG_TO_PT): Likewise.
2832 (SVE_PT_SVE_OFFSET): Likewise.
2833 (SVE_PT_SVE_ZREGS_OFFSET): Likewise.
2834 (SVE_PT_SVE_ZREG_OFFSET): Likewise.
2835 (SVE_PT_SVE_ZREGS_SIZE): Likewise.
2836 (SVE_PT_SVE_PREGS_OFFSET): Likewise.
2837 (SVE_PT_SVE_PREG_OFFSET): Likewise.
2838 (SVE_PT_SVE_PREGS_SIZE): Likewise.
2839 (SVE_PT_SVE_FFR_OFFSET): Likewise.
2840 (SVE_PT_SVE_FPSR_OFFSET): Likewise.
2841 (SVE_PT_SVE_FPCR_OFFSET): Likewise.
2842 (SVE_PT_SVE_SIZE): Likewise.
2843 (SVE_PT_SIZE): Likewise.
2844 (HAS_SVE_STATE): New define.
2845
17a1cc89
AH
28462018-06-18 Alan Hayward <alan.hayward@arm.com>
2847
2848 * nat/aarch64-sve-linux-sigcontext.h: New file.
2849 * nat/aarch64-sve-linux-ptrace.h (SVE_VQ_BYTES): Move to
2850 new files.
2851 (SVE_VQ_MIN): Likewise.
2852 (SVE_VQ_MAX): Likewise.
2853 (SVE_VL_MIN): Likewise.
2854 (SVE_VL_MAX): Likewise.
2855 (SVE_NUM_ZREGS): Likewise.
2856 (SVE_NUM_PREGS): Likewise.
2857 (sve_vl_valid): Likewise.
2858 (struct user_sve_header): Likewise.
2859
7010835a
AB
28602018-06-16 Andrew Burgess <andrew.burgess@embecosm.com>
2861 Richard Bunt <Richard.Bunt@arm.com>
2862
2863 * linux-nat.c (stop_wait_callback): Don't discard SIGSTOP if it
2864 was requested by GDB.
2865
479b3ef4
TV
28662018-06-15 Tom de Vries <tdevries@suse.de>
2867
2868 * MAINTAINERS (Write After Approval): Add Tom de Vries.
2869
8199b8f4
SM
28702018-06-14 Simon Marchi <simon.marchi@polymtl.ca>
2871
2872 * gnulib/update-gnulib.sh: Print expected versions of
2873 autoconf/aclocal.
2874
55c748a1
SM
28752018-06-14 Simon Marchi <simon.marchi@ericsson.com>
2876
2877 * arch-utils.c (default_type_align): Use type_length_units.
2878 * gdbtypes.c (type_align): Use type_length_units.
2879
87a8eca7
PW
28802018-06-14 Philippe Waroquiers <philippe.waroquiers@skynet.be>
2881
2882 * cli/cli-script.c (_initialize_cli_script): Fix online documentation
2883 of 'define' command.
2884
5d9a0608
TV
28852018-06-14 Tom de Vries <tdevries@suse.de>
2886
2887 PR cli/22573
2888 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
2889 get_no_prettyformat_print_options.
2890
ab89b5a5
SM
28912018-06-13 Simon Marchi <simon.marchi@ericsson.com>
2892
2893 * sparc-nat.h: Include target.h.
2894 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
2895 <fetch_registers>: Remove this argument in function call.
2896 <store_registers>: Remove this argument in function call, remove
2897 extra semicolon.
2898 <low_forget_process>: Call sparc64_forget_process instead of
2899 sparc_forget_process.
2900
62c808ae
RO
29012018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2902
2903 * procfs.c (_initialize_procfs): Use add_inf_child_target.
2904 (procfs_target::make_corefile_notes): Adjust to new
2905 target_read_alloc return type.
2906
1840d81a
AB
29072018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2908 Stephen Roberts <stephen.roberts@arm.com>
2909
2910 PR gdb/22882
2911 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
2912 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
2913 Move should_notify_stop local into more inner scope.
2914
9516f85a
AB
29152018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2916 Stephen Roberts <stephen.roberts@arm.com>
2917
2918 PR gdb/22882
2919 * infrun.c (resume_1): Add call to mark_async_event_handler.
2920
defd2172
AB
29212018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
2922
2923 * infrun.c (do_target_wait): Change old version of $pc printed.
2924
7b23e087
SM
29252018-06-11 Simon Marchi <simon.marchi@ericsson.com>
2926
2927 * dwarf2read.c (read_index_from_section): Rename to...
2928 (read_gdb_index_from_section): ... this, update all callers.
2929 (dwarf2_read_index): Rename to...
2930 (dwarf2_read_gdb_index): ... this, update all callers.
2931
69c67a0b
JDA
29322018-06-11 John David Anglin <danglin@gcc.gnu.org>
2933
2934 * gdb/hppa-linux-nat.c
2935 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
2936 hppa_linux_nat_target::fetch_registers.
2937
65d4cada
AH
29382018-06-11 Alan Hayward <alan.hayward@arm.com>
2939
2940 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
2941 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
2942 (AARCH64_DWARF_SVE_FFR): Likewise.
2943 (AARCH64_DWARF_SVE_P0): Likewise.
2944 (AARCH64_DWARF_SVE_Z0): Likewise.
2945
f868386e
AH
29462018-06-11 Alan Hayward <alan.hayward@arm.com>
2947
2948 * common/common-regcache.h (raw_compare): New function.
2949 * regcache.c (regcache::raw_compare): Likewise.
2950 * regcache.h (regcache::raw_compare): New declaration.
2951
9c861883
AH
29522018-06-11 Alan Hayward <alan.hayward@arm.com>
2953
2954 * common/common-regcache.h (reg_buffer_common): New structure.
2955 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
2956 (reg_buffer::raw_supply): Likewise.
2957 (reg_buffer::raw_supply_integer): Likewise.
2958 (reg_buffer::raw_supply_zeroed): Likewise.
2959 (reg_buffer::raw_collect): Likewise.
2960 (reg_buffer::raw_collect_integer): Likewise.
2961 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
2962 (reg_buffer::raw_supply): Likewise.
2963 (reg_buffer::raw_supply_integer): Likewise.
2964 (reg_buffer::raw_supply_zeroed): Likewise.
2965 (reg_buffer::raw_collect): Likewise.
2966 (reg_buffer::raw_collect_integer): Likewise.
2967
953edf2b
TT
29682018-06-10 Tom Tromey <tom@tromey.com>
2969
2970 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
2971 (class remote_state) <stop_reply_queue>: Now std::vector.
2972 (remote_state::~remote_state)
2973 (remote_target::stop_reply_queue_length): Update.
2974 (struct queue_iter_param, remove_child_of_pending_fork)
2975 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
2976 (check_pending_event_prevents_wildcard_vcont_callback)
2977 (remove_stop_reply_for_inferior)
2978 (remove_stop_reply_of_remote_state)
2979 (remote_notif_remove_once_on_match)
2980 (stop_reply_match_ptid_and_ws)
2981 (remote_kill_child_of_pending_fork): Remove.
2982 (remote_target::remove_new_fork_children)
2983 (remote_target::check_pending_events_prevent_wildcard_vcont)
2984 (remote_target::discard_pending_stop_replies)
2985 (remote_target::discard_pending_stop_replies_in_queue)
2986 (remote_target::remote_notif_remove_queued_reply)
2987 (remote_target::queued_stop_reply)
2988 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
2989 (remote_target::wait, remote_target::kill_new_fork_children)
2990 (remote_target::async): Update.
2991
1ddbba9d
TT
29922018-06-10 Tom Tromey <tom@tromey.com>
2993
2994 * record-full.c (record_full_arch_list_cleanups): Remove.
2995 (record_full_message): Use try/catch.
2996 (record_full_wait_cleanups): Remove.
2997 (record_full_wait_1): Use try/catch.
2998 (record_full_restore): Likewise.
2999
219605fd
TT
30002018-06-10 Tom Tromey <tom@tromey.com>
3001
3002 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
3003 declare VEC. Add constructor.
3004 <in_target_beneath>: Now bool.
3005 (record_full_breakpoints): Now a std::vector, static.
3006 (record_full_sync_record_breakpoints)
3007 (record_full_init_record_breakpoints)
3008 (record_full_target::insert_breakpoint)
3009 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
3010
71b73764
SM
30112018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
3012
3013 * dwarf2read.c (process_cu_includes): Remove struct keyword.
3014 * serial.c (serial_interface_lookup): Remove struct keyword.
3015
4360561f
TT
30162018-06-10 Tom Tromey <tom@tromey.com>
3017
3018 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
3019 method.
3020 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
3021 a method.
3022 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
3023 method.
3024 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
3025 "beneath" as a method.
3026 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
3027 Use "beneath" as a method.
3028
d14b92bf
TT
30292018-06-10 Tom Tromey <tom@tromey.com>
3030
3031 * tracefile.c (struct trace_file_writer_deleter): New.
3032 <operator()>: Rename from trace_file_writer_xfree.
3033 (trace_file_writer_up): New typedef.
3034 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
3035
835dcf92
SM
30362018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3037
3038 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
3039 <m_registers, m_register_status>: Change type to
3040 std::unique_ptr.
3041 * regcache.c (reg_buffer::reg_buffer): Use new instead of
3042 XCNEWVEC.
3043
aac0d564
SM
30442018-06-09 Simon Marchi <simon.marchi@ericsson.com>
3045
3046 * common/common-regcache.h (enum register_status): Add
3047 underlying type "signed char".
3048 * regcache.h (reg_buffer) <m_register_status>: Change type to
3049 register_status *.
3050 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
3051 register_status instead of signed char.
3052 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
3053 (reg_buffer::get_register_status): Remove cast.
3054 (readable_regcache::raw_read): Remove cast.
3055 (readable_regcache::cooked_read): Remove cast.
3056
77ad7394
TT
30572018-06-09 Tom Tromey <tom@tromey.com>
3058
3059 * source.c (reverse_search_command, forward_search_command): Use
3060 scoped_fd.
3061
191cca63
TT
30622018-06-09 Tom Tromey <tom@tromey.com>
3063
3064 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
3065 (serial_ops_list): Now static, std::vector.
3066 (serial_interface_lookup, serial_add_interface): Update.
3067
c5d0225d
TT
30682018-06-09 Tom Tromey <tom@tromey.com>
3069
3070 * dwarf2read.c (process_cu_includes): Update.
3071 (process_full_comp_unit): Update.
3072 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
3073 std::vector.
3074
aeab5128
PK
30752018-06-08 Paul Koning <paul_koning@dell.com>
3076
3077 PR gdb/23252
3078
3079 * python/python.c (do_start_initialization):
3080 Avoid call to internal Python API.
3081 (init__gdb_module): New function.
3082
5045b3d7
GB
30832018-06-08 Gary Benson <gbenson@redhat.com>
3084
3085 * linux-thread-db.c (valprint.h): New include.
3086 (struct check_thread_db_info): New structure.
3087 (check_thread_db_on_load, tdb_testinfo): New static globals.
3088 (check_thread_db, check_thread_db_callback): New functions.
3089 (try_thread_db_load_1): Run integrity checks if requested.
3090 (maintenance_check_libthread_db): New function.
3091 (_initialize_thread_db): Register "maint check libthread-db"
3092 and "maint set/show check-libthread-db".
3093 * NEWS: Mention the above new commands.
3094
2f4f025f
TT
30952018-06-08 Tom Tromey <tom@tromey.com>
3096
3097 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
3098 now a method.
3099
343b0027
TT
31002018-06-08 Tom Tromey <tom@tromey.com>
3101
3102 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
3103
8dcc53b3
TT
31042018-06-08 Tom Tromey <tom@tromey.com>
3105
3106 * common/btrace-common.h (struct btrace_data): Add constructor,
3107 destructor, move assignment operator.
3108 <empty, clear, fini>: New methods.
3109 <format>: Initialize.
3110 (btrace_data_init, btrace_data_fini, btrace_data_clear)
3111 (btrace_data_empty): Don't declare.
3112 * common/btrace-common.c (btrace_data_init): Remove.
3113 (btrace_data::fini): Rename from btrace_data_fini.
3114 (btrace_data::empty): Rename from btrace_data_empty.
3115 (btrace_data::clear): Rename from btrace_data_clear. Return
3116 bool.
3117 * btrace.h (make_cleanup_btrace_data): Don't declare.
3118 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
3119 (parse_xml_btrace): Update.
3120 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
3121 (maint_btrace_clear_packet_history_cmd): Update.
3122
a1740ee1
PA
31232018-06-07 Pedro Alves <palves@redhat.com>
3124
3125 * target.h (target_ops) <beneath>: Now a method. All references
3126 updated.
3127 (class target_stack): New.
3128 * target.c (g_target_stack): New.
3129 (g_current_top_target): Delete.
3130 (current_top_target): Get the top target out of g_target_stack.
3131 (target_stack::push, target_stack::unpush): New.
3132 (push_target, unpush_target): Reimplement.
3133 (target_is_pushed): Reimplement in terms of g_target_stack.
3134 (target_ops::beneath, target_stack::find_beneath): New.
3135
d6ca69cd
PA
31362018-06-07 Pedro Alves <palves@redhat.com>
3137
3138 * target.h (find_target_beneath): Delete declaration.
3139 * target.c (find_target_beneath): Delete definition.
3140 * aix-thread.c: All callers of find_target_beneath adjusted to
3141 call target_ops::beneath instead.
3142 * bsd-uthread.c: Likewise.
3143 * linux-thread-db.c: Likewise.
3144 * ravenscar-thread.c: Likewise.
3145 * sol-thread.c: Likewise.
3146 * spu-multiarch.c: Likewise.
3147
b6a8c27b
PA
31482018-06-07 Pedro Alves <palves@redhat.com>
3149
3150 * target.h (target_ops) <beneath>: Now a method. All references
3151 updated.
3152 (target_ops) <m_beneath>: New.
3153 * target.c (target_ops::beneath): New.
3154 * corelow.c: Adjust all references to target_ops::beneath.
3155 * linux-thread-db.c: Likewise.
3156 * make-target-delegates: Likewise.
3157 * record-btrace.c: Likewise.
3158 * record-full.c: Likewise.
3159 * remote.c: Likewise.
3160 * target.c: Likewise.
3161 * target-delegates.c: Regenerate.
3162
8b88a78e
PA
31632018-06-07 Pedro Alves <palves@redhat.com>
3164
3165 * target.h (target_stack): Delete.
3166 (current_top_target): Declare function.
3167 * target.c (target_stack): Delete.
3168 (g_current_top_target): New.
3169 (current_top_target): New function.
3170 * auxv.c: Use current_top_target instead of target_stack
3171 throughout.
3172 * avr-tdep.c: Likewise.
3173 * breakpoint.c: Likewise.
3174 * corefile.c: Likewise.
3175 * elfread.c: Likewise.
3176 * eval.c: Likewise.
3177 * exceptions.c: Likewise.
3178 * frame.c: Likewise.
3179 * gdbarch-selftests.c: Likewise.
3180 * gnu-v3-abi.c: Likewise.
3181 * ia64-tdep.c: Likewise.
3182 * ia64-vms-tdep.c: Likewise.
3183 * infcall.c: Likewise.
3184 * infcmd.c: Likewise.
3185 * infrun.c: Likewise.
3186 * linespec.c: Likewise.
3187 * linux-tdep.c: Likewise.
3188 * minsyms.c: Likewise.
3189 * ppc-linux-nat.c: Likewise.
3190 * ppc-linux-tdep.c: Likewise.
3191 * procfs.c: Likewise.
3192 * regcache.c: Likewise.
3193 * remote.c: Likewise.
3194 * rs6000-tdep.c: Likewise.
3195 * s390-linux-nat.c: Likewise.
3196 * s390-tdep.c: Likewise.
3197 * solib-aix.c: Likewise.
3198 * solib-darwin.c: Likewise.
3199 * solib-dsbt.c: Likewise.
3200 * solib-spu.c: Likewise.
3201 * solib-svr4.c: Likewise.
3202 * solib-target.c: Likewise.
3203 * sparc-tdep.c: Likewise.
3204 * sparc64-tdep.c: Likewise.
3205 * spu-tdep.c: Likewise.
3206 * symfile.c: Likewise.
3207 * symtab.c: Likewise.
3208 * target-descriptions.c: Likewise.
3209 * target-memory.c: Likewise.
3210 * target.c: Likewise.
3211 * target.h: Likewise.
3212 * tracefile-tfile.c: Likewise.
3213 * tracepoint.c: Likewise.
3214 * valops.c: Likewise.
3215 * valprint.c: Likewise.
3216 * value.c: Likewise.
3217 * windows-tdep.c: Likewise.
3218 * mi/mi-main.c: Likewise.
3219
c7110220
TT
32202018-06-07 Tom Tromey <tom@tromey.com>
3221
3222 * valprint.h (build_address_symbolic): Declare.
3223 * printcmd.c (print_address_symbolic): Update.
3224 (build_address_symbolic): Change "name" and "filename" to
3225 std::string.
3226 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
3227 Update.
3228 * defs.h (build_address_symbolic): Remove declaration.
3229
63bad7b6
AH
32302018-06-07 Alan Hayward <alan.hayward@arm.com>
3231
3232 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
3233 (aarch64_vnv_type): Add function.
3234 (aarch64_pseudo_register_name): Add V regs for SVE.
3235 (aarch64_pseudo_register_type): Likewise.
3236 (aarch64_pseudo_register_reggroup_p): Likewise.
3237 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
3238 (aarch64_pseudo_read_value): Add V regs for SVE.
3239 (aarch64_pseudo_write_2): Use V0 offset for SVE
3240 (aarch64_pseudo_write): Add V regs for SVE.
3241 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
3242
13e3c608
SDJ
32432018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
3244
3245 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
3246 (sve_vl_from_vq): Likewise.
3247
c61b06a1
TT
32482018-06-05 Tom Tromey <tom@tromey.com>
3249
3250 * cli/cli-cmds.c (show_version): Update.
3251 * top.c (print_gdb_version): Add "interactive" parameter.
3252 Update.
3253 * main.c (captured_main_1): Update.
3254 * top.h (print_gdb_version): Add "interactive" parameter and a
3255 comment.
3256
115f7325
DM
32572018-06-05 David Malcolm <dmalcolm@redhat.com>
3258
3259 * common/enum-flags.h: Add trailing semicolon to example in
3260 comment.
3261
eb6af809
TT
32622018-06-05 Tom Tromey <tom@tromey.com>
3263
3264 PR cli/12326:
3265 * NEWS: Add entry about pager.
3266 * utils.c (pagination_disabled_for_command): New global.
3267 (prompt_for_continue): Allow "c" response to prompt.
3268 (reinitialize_more_filter): Clear
3269 pagination_disabled_for_command.
3270 (fputs_maybe_filtered): Check pagination_disabled_for_command.
3271
54d343a2
TT
32722018-06-04 Tom Tromey <tom@tromey.com>
3273
3274 * ada-lang.h (ada_lookup_symbol_list): Update.
3275 * ada-lang.c (resolve_subexp): Update.
3276 (symbols_are_identical_enums): Change type of syms. Remove nsyms
3277 parameter.
3278 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
3279 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
3280 results parameter to std::vector.
3281 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
3282 Update.
3283 * ada-exp.y (block_lookup): Update.
3284 (select_possible_type_sym): Change type of syms. Remove nsyms
3285 parameter.
3286 (write_var_or_type, write_name_assoc): Update.
3287
178d6a63
JB
32882018-06-04 Joel Brobecker <brobecker@adacore.com>
3289
3290 * windows-nat.c (windows_nat_target::xfer_partial): Return
3291 TARGET_XFER_E_IO if we need to delegate to the target beneath
3292 but BENEATH is NULL.
3293
baf00c2d
SM
32942018-06-04 Simon Marchi <simon.marchi@ericsson.com>
3295
3296 * Makefile.in (config.status): Add configure.nat as a
3297 dependency.
3298
214b073c
TT
32992018-06-04 Tom Tromey <tom@tromey.com>
3300
3301 * cp-name-parser.y (cpname_state): Add method declarations.
3302 (HANDLE_QUAL): Update.
3303 (cpname_state::d_grab, cpname_state::fill_comp)
3304 (cpname_state::make_operator, cpname_state::make_dtor)
3305 (cpname_state::make_builtin_type, cpname_state::make_name)
3306 (cpname_state::d_qualify, cpname_state::d_int_type)
3307 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
3308 (%union): Move earlier.
3309
62b74cb8
AH
33102018-06-04 Alan Hayward <alan.hayward@arm.com>
3311
3312 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
3313
3c5cd5c3
AH
33142018-06-04 Alan Hayward <alan.hayward@arm.com>
3315
3316 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
3317 (aarch64_pseudo_write_1): Likewise.
3318 (aarch64_pseudo_read_value): Use helper.
3319 (aarch64_pseudo_write): Likewise.
3320
59f413d5
PA
33212018-06-04 Pedro Alves <palves@redhat.com>
3322
3323 * darwin-nat.c (darwin_ops): Delete.
3324 (darwin_attach_pid): Use get_native_target.
3325
1332a140
AH
33262018-06-04 Alan Hayward <alan.hayward@arm.com>
3327
3328 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
3329 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
3330
ba2d2bb2
AH
33312018-06-04 Alan Hayward <alan.hayward@arm.com>
3332
3333 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
3334 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
3335 (aarch64_gdbarch_init): Check for SVE.
3336 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
3337
33382018-06-04 Alan Hayward <alan.hayward@arm.com>
39bfb937
AH
3339
3340 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
3341 * aarch64-tdep.h (aarch64_read_description): Likewise.
3342 * arch/aarch64.c (aarch64_create_target_description): Likewise.
3343 * arch/aarch64.h (aarch64_create_target_description): Likewise.
3344 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
3345 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
3346 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
3347
41c60b4b
SM
33482018-06-02 Simon Marchi <simon.marchi@ericsson.com>
3349
3350 * value.c (value_fetch_lazy_bitfield): New.
3351 (value_fetch_lazy_memory): New.
3352 (value_fetch_lazy_register): New.
3353 (value_fetch_lazy): Factor out to smaller functions.
3354
7b640f72
TT
33552018-06-01 Tom Tromey <tom@tromey.com>
3356
3357 * cp-name-parser.y (backslashable, represented): Now const.
3358
98e69eb3
TT
33592018-06-01 Tom Tromey <tom@tromey.com>
3360
3361 * cp-name-parser.y: Include parser-defs.h.
3362 (parser_fprintf): Remove declaration.
3363
49265499
TT
33642018-06-01 Tom Tromey <tom@tromey.com>
3365
3366 * cp-name-parser.y: Use %pure-parser, %lex-param, and
3367 %parse-param.
3368 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
3369 (global_result): Remove globals.
3370 (struct cpname_state): New.
3371 (yyparse): Don't declare.
3372 (yylex, yyerror): Move declarations after %union.
3373 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
3374 (make_name): Add state parameter.
3375 Update all callers.
3376 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
3377 parameter.
3378 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
3379 Update.
3380 (yylex): Add lvalp, state parameters.
3381 (yyerror): Add state parameter.
3382 (cp_demangled_name_to_comp): Update.
3383
55b6c984
TT
33842018-06-01 Tom Tromey <tom@tromey.com>
3385
3386 * cp-name-parser.y (parser_fprintf): Declare.
3387 (GDB_YY_REMAP_PREFIX): Define.
3388 Include yy-remap.h. Don't redefine yy* identifiers.
3389
3513a6bb
TT
33902018-06-01 Tom Tromey <tom@tromey.com>
3391
3392 * python/py-type.c (typy_legacy_template_argument): Update.
3393 * cp-support.h (cp_demangled_name_to_comp): Update.
3394 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
3395 parameter to be a "std::string *".
3396 (main): Update.
3397
e9cb46ab
L
33982018-06-01 H.J. Lu <hongjiu.lu@intel.com>
3399
3400 * ada-lex.l: Include "diagnostics.h" instead of
3401 "common/diagnostics.h".
3402 * unittests/environ-selftests.c: Likewise.
3403 * common/diagnostics.h: Moved to ../include.
3404
8e817061
JB
34052018-06-01 Joel Brobecker <brobecker@adacore.com>
3406
3407 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
3408 to language_mode_manual while calling breakpoint_re_set_one.
3409
a737d952
TT
34102018-06-01 Tom Tromey <tom@tromey.com>
3411
3412 * valops.c (value_cast_structs, destructor_name_p): Update.
3413 * symtab.c (gdb_mangle_name): Update.
3414 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
3415 Update.
3416 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
3417 (pascal_object_print_value_fields, pascal_object_print_value):
3418 Update.
3419 * p-typeprint.c (pascal_type_print_derivation_info): Update.
3420 * linespec.c (find_methods): Update.
3421 * gdbtypes.h (type_name_no_tag): Remove.
3422 (type_name_or_error): Rename from type_name_no_tag_or_error.
3423 * gdbtypes.c (type_name_no_tag): Remove.
3424 (type_name_or_error): Rename from type_name_no_tag_or_error.
3425 (lookup_struct_elt_type, check_typedef): Update.
3426 * expprint.c (print_subexp_standard): Update.
3427 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
3428 * d-namespace.c (d_lookup_nested_symbol): Update.
3429 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
3430 (cp_print_class_member): Update.
3431 * cp-namespace.c (cp_lookup_nested_symbol): Update.
3432 * completer.c (add_struct_fields): Update.
3433 * c-typeprint.c (cp_type_print_derivation_info)
3434 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
3435 Update.
3436 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
3437 (ada_prefer_type, ada_is_exception_sym): Update.
3438
e86ca25f
TT
34392018-06-01 Tom Tromey <tom@tromey.com>
3440
3441 * valops.c (enum_constant_from_type, value_namespace_elt)
3442 (value_maybe_namespace_elt): Update.
3443 * valarith.c (find_size_for_pointer_math): Update.
3444 * target-descriptions.c (make_gdb_type): Update.
3445 * symmisc.c (print_symbol): Update.
3446 * stabsread.c (define_symbol, read_type)
3447 (complain_about_struct_wipeout, add_undefined_type)
3448 (cleanup_undefined_types_1): Update.
3449 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
3450 (rust_range_type_p, val_print_struct, rust_print_struct_def)
3451 (rust_internal_print_type, rust_composite_type)
3452 (rust_evaluate_funcall, rust_evaluate_subexp)
3453 (rust_inclusive_range_type_p): Update.
3454 * python/py-type.c (typy_get_tag): Update.
3455 * p-typeprint.c (pascal_type_print_base): Update.
3456 * mdebugread.c (parse_symbol, parse_type): Update.
3457 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
3458 Update.
3459 * guile/scm-type.c (gdbscm_type_tag): Update.
3460 * go-lang.c (sixg_string_p): Update.
3461 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
3462 Update.
3463 * gdbtypes.h (struct main_type) <tag_name>: Remove.
3464 (TYPE_TAG_NAME): Remove.
3465 * gdbtypes.c (type_name_no_tag): Simplify.
3466 (check_typedef, check_types_equal, recursive_dump_type)
3467 (copy_type_recursive, arch_composite_type): Update.
3468 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
3469 in summary mode when needed.
3470 * eval.c (evaluate_funcall): Update.
3471 * dwarf2read.c (fixup_go_packaging, read_structure_type)
3472 (process_structure_scope, read_enumeration_type)
3473 (read_namespace_type, read_module_type, determine_prefix): Update.
3474 * cp-support.c (inspect_type): Update.
3475 * coffread.c (process_coff_symbol, decode_base_type): Update.
3476 * c-varobj.c (c_is_path_expr_parent): Update.
3477 * c-typeprint.c (c_type_print_base_struct_union): Update.
3478 (c_type_print_base_1): Update. Print struct/class/union/enum in
3479 summary when using C language.
3480 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
3481 (gen_maybe_namespace_elt): Update.
3482 * ada-lang.c (ada_type_name): Simplify.
3483 (empty_record, ada_template_to_fixed_record_type_1)
3484 (template_to_static_fixed_type)
3485 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
3486
c1ec8cea
TT
34872018-06-01 Tom Tromey <tom@tromey.com>
3488
3489 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
3490 c_print_type.
3491 * c-typeprint.c (c_print_type_1): Add "language" parameter.
3492 (c_print_type): Update.
3493 (c_print_type): New overload.
3494 (c_type_print_varspec_prefix, c_type_print_args)
3495 (c_type_print_varspec_suffix, c_print_type_no_offsets)
3496 (c_type_print_base_struct_union, c_type_print_base_1)
3497 (cp_type_print_method_args): Add "language" parameter.
3498 (c_type_print_base): Update.
3499 * c-lang.h (c_print_type): Add new overload.
3500
bc8453a7
TT
35012018-06-01 Tom Tromey <tom@tromey.com>
3502
3503 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
3504 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
3505
739e8682
AH
35062018-06-01 Alan Hayward <alan.hayward@arm.com>
3507
3508 * aarch64-tdep.c (aarch64_sve_register_names): New const
3509 var.
3510 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
3511 (AARCH64_SVE_Z_REGS_NUM): New define.
3512 (AARCH64_SVE_P_REGS_NUM): Likewise.
3513 (AARCH64_SVE_NUM_REGS): Likewise.
3514
8a60efe7
UB
35152018-05-31 Uros Bizjak <ubizjak@gmail.com>
3516
3517 * nat/linux-ptrace.h [__alpha__]
3518 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
3519 definitions.
3520
4b2dfa9d
MR
35212018-05-31 Maciej W. Rozycki <macro@mips.com>
3522
3523 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
3524 the endianness selected.
3525 * NEWS: Document `set endian auto' mode operation update.
3526
122394f1
AH
35272018-05-31 Alan Hayward <alan.hayward@arm.com>
3528
3529 * Makefile.in: Add new header.
3530 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
3531 (sve_vl_from_vg): Likewise.
3532 (sve_vq_from_vl): Likewise.
3533 (sve_vl_from_vq): Likewise.
3534 (sve_vq_from_vg): Likewise.
3535 (sve_vg_from_vq): Likewise.
3536 * configure.nat: Add new c file.
3537 * nat/aarch64-sve-linux-ptrace.c: New file.
3538 * nat/aarch64-sve-linux-ptrace.h: New file.
3539
95228a0d
AH
35402018-05-31 Alan Hayward <alan.hayward@arm.com>
3541
3542 * aarch64-linux-nat.c (aarch64_linux_read_description):
3543 Add parmeter zero.
3544 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
3545 Likewise.
3546 * aarch64-tdep.c (tdesc_aarch64_list): Add.
3547 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
3548 (aarch64_gdbarch_init): Add parmeter zero.
3549 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
3550 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
3551 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
3552 parmeter.
3553 * doc/gdb.texinfo: Describe SVE feature
3554 * features/aarch64-sve.c: New file.
3555
5969f0db
OJ
35562018-05-31 Omair Javaid <omair.javaid@linaro.org>
3557
3558 PR gdb/23210
3559 * gdbarch.sh (significant_addr_bit): Default to zero when
3560 not set by target architecture.
3561 * gdbarch.c: Re-generated.
3562 * utils.c (address_significant): Update.
3563
61367c61
JB
35642018-05-30 Joel Brobecker <brobecker@adacore.com>
3565
3566 * stack.c (func_command): Remove trailing newline in call to error.
3567
34a79281
SM
35682018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3569
3570 * regcache.h (regcache_raw_collect): Remove, update callers to
3571 use regcache::raw_collect.
3572 * regcache.c (regcache_raw_collect): Remove.
3573
73e1c03f
SM
35742018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3575
3576 * regcache.h (regcache_raw_supply): Remove, update callers to
3577 use detached_regcache::raw_supply.
3578 * regcache.c (regcache_raw_supply): Remove.
3579
e4c4a59b
SM
35802018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3581
3582 * regcache.h (regcache_cooked_write_part): Remove, update
3583 callers to use regcache::cooked_write_part.
3584 * regcache.c (regcache_cooked_write_part): Remove.
3585
73bb0000
SM
35862018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3587
3588 * regcache.h (regcache_cooked_read_part): Remove, update callers
3589 to use readable_regcache::cooked_read_part.
3590 * regcache.c (regcache_cooked_read_part): Remove.
3591
46a45e9d
SM
35922018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3593
3594 * regcache.h (regcache_cooked_read_value): Remove, update
3595 callers to use readable_regcache::cooked_read_value.
3596 * regcache.c (regcache_cooked_read_value): Remove.
3597
b66f5587
SM
35982018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3599
3600 * regcache.h (regcache_cooked_write): Remove, update callers to
3601 use regcache::cooked_write.
3602 * regcache.c (regcache_cooked_write): Remove.
3603
6aa7d724
SM
36042018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3605
3606 * regcache.h (regcache_invalidate): Remove, update callers to
3607 use detached_regcache::invalidate instead.
3608 * regcache.c (regcache_invalidate): Remove.
3609
4f0420fd
SM
36102018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3611
3612 * regcache.h (regcache_raw_write_part): Remove, update callers
3613 to use regcache::raw_write_part instead.
3614 * regcache.c (regcache_raw_write_part): Remove.
3615
502fe83e
SM
36162018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3617
3618 * regcache.h (regcache_raw_read_part): Remove, update callers to
3619 use readable_regcache::raw_read_part instead.
3620 * regcache.c (regcache_raw_read_part): Remove.
3621
dca08e1f
SM
36222018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3623
3624 * regcache.h (regcache_cooked_read): Remove, update callers to
3625 use readable_regcache::cooked_read instead.
3626 * regcache.c (regcache_cooked_read): Remove.
3627
10eaee5f
SM
36282018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3629
3630 * regcache.h (regcache_raw_write): Remove, update callers to use
3631 regcache::raw_write instead.
3632 * regcache.c (regcache_raw_write): Remove.
3633
0b883586
SM
36342018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3635
3636 * regcache.h (regcache_raw_read): Remove, update callers to use
3637 readable_regcache::raw_read instead.
3638 * regcache.c (regcache_raw_read): Remove.
3639
0b47d985
SM
36402018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3641
3642 * regcache.h (regcache_raw_update): Remove, update callers to
3643 use readable_regcache::raw_update instead.
3644 * regcache.c (regcache_raw_update): Remove.
3645
0ec9f114
SM
36462018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3647
3648 * regcache.h (regcache_register_status): Remove, update callers
3649 to use reg_buffer::get_register_status directly instead.
3650 * regcache.c (regcache_register_status): Remove.
3651
222312d3
SM
36522018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3653
3654 * regcache.h (regcache_get_ptid): Remove, update all callers to
3655 call regcache::ptid instead.
3656 * regcache.c (regcache_get_ptid): Remove.
3657
fdbe37e3
SM
36582018-05-30 Simon Marchi <simon.marchi@ericsson.com>
3659
3660 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
3661
f7c6f423
PA
36622018-05-30 Pedro Alves <palves@redhat.com>
3663
3664 * common/common-exceptions.h (exception_rethrow): Use
3665 ATTRIBUTE_NORETURN.
3666
52941706
SM
36672018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
3668
3669 * breakpoint.c (print_solib_event, check_status_catch_solib):
3670 Remove struct keyword in range-based for loops.
3671 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
3672 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
3673 Likewise.
3674 * linespec.c (find_superclass_methods, search_minsyms_for_name):
3675 Likewise.
3676 * symfile.c (addr_info_make_relative): Likewise.
3677 * thread.c (value_in_thread_stack_temporaries): Likewise.
3678
bf2977b5
WP
36792018-06-12 Weimin Pan <weimin.pan@oracle.com>
3680
3681 PR gdb/16841
3682 * valops.c (value_struct_elt_for_reference): Call check_typedef on
3683 aggregate type to get its real type before accessing it.
3684
64cc34d8
WP
36852018-05-29 Weimin Pan <weimin.pan@oracle.com>
3686
3687 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
3688 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
3689 * coff-pe-read.c (add_pe_forwarded_sym): Replace
3690 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
3691 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
3692 * jit.c (jit_breakpoint_re_set_internal): Likewise.
3693 * printcmd.c (info_address_command): Likewise.
3694
e7ec8713
TT
36952018-05-29 Tom Tromey <tom@tromey.com>
3696
3697 * windows-nat.c (handle_exception): Update fall-through comment.
3698
bcb430e4
TT
36992018-05-29 Tom Tromey <tom@tromey.com>
3700
3701 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
3702 (struct program_space) <added_solibs>: Now a std::vector.
3703 * breakpoint.c (print_solib_event): Update.
3704 (check_status_catch_solib): Update.
3705 * progspace.c (clear_program_space_solib_cache): Update.
3706 * solib.c (update_solib_list): Update.
3707
894882e3
TT
37082018-05-29 Tom Tromey <tom@tromey.com>
3709
3710 * python/py-type.c (typy_richcompare): Update.
3711 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
3712 * gdbtypes.h (types_deeply_equal): Return bool.
3713 (types_equal): Likewise.
3714 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
3715 declare VEC.
3716 (check_types_equal): Change worklist to std::vector. Return
3717 bool.
3718 (struct type_equality_entry): Add constructor.
3719 (compare_maybe_null_strings): Return bool.
3720 (check_types_worklist): Return bool. Change worklist to
3721 std::vector.
3722 (types_deeply_equal): Use std::vector.
3723 (types_equal): Return bool.
3724 (compare_maybe_null_strings): Simplify.
3725
10b2ded4
TT
37262018-05-29 Tom Tromey <tom@tromey.com>
3727
3728 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
3729
4f7deebe
TT
37302018-05-29 Tom Tromey <tom@tromey.com>
3731
3732 * objc-lang.h: Don't include cp-support.h.
3733 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
3734 declare VEC.
3735
b8283aea
TT
37362018-05-27 Tom Tromey <tom@tromey.com>
3737
3738 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
3739
41a883c8
TT
37402018-05-25 Tom Tromey <tom@tromey.com>
3741
3742 * value.c (value::location): Initialize.
3743
bf259e25
TT
37442018-05-25 Tom Tromey <tom@tromey.com>
3745
3746 * dbxread.c (init_bincl_list): Remove.
3747 (bincl_list): Now a std::vector.
3748 (bincls_allocated, next_bincl): Remove.
3749 (free_bincl_list, do_free_bincl_list_cleanup)
3750 (make_cleanup_free_bincl_list): Remove.
3751 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
3752 unique_xmalloc_ptr.
3753 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
3754 (struct header_file_location): Add constructor.
3755 (add_bincl_to_list): Remove.
3756
d525a99b
TT
37572018-05-25 Tom Tromey <tom@tromey.com>
3758
3759 * tui/tui.c (tui_enable): Update.
3760 * mi/mi-interp.c (mi_interp::init): Update.
3761 * interps.h (class interp) <name>: New method.
3762 <m_name>: Rename from name.
3763 (~scoped_restore_interp): Update.
3764 * interps.c (interp::interp): Update.
3765 (interp_add, interp_set, interp_lookup_existing)
3766 (current_interp_named_p): Update.
3767
da505cff
TT
37682018-05-25 Tom Tromey <tom@tromey.com>
3769
3770 * interps.c (interp_name): Remove.
3771 * mi/mi-interp.c (mi_interp::init): Update.
3772 * interps.h (interp_name): Remove.
3773 (~scoped_restore_interp): Update.
3774 * tui/tui.c (tui_enable): Update.
3775
29f94340
TT
37762018-05-25 Tom Tromey <tom@tromey.com>
3777
3778 * utils.c (fputs_maybe_filtered): Update.
3779 * linespec.c (decode_line_full): Update.
3780 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
3781 (mi_print_breakpoint_for_event, mi_solib_loaded)
3782 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
3783 (mi_user_selected_context_changed): Update.
3784 * mi/mi-main.c (mi_execute_command): Update.
3785 * cli/cli-script.c (execute_control_command): Update.
3786 * python/python.c (execute_gdb_command): Update.
3787 * solib.c (info_sharedlibrary_command): Update.
3788 * interps.c (interp_ui_out): Remove.
3789 * interps.h (interp_ui_out): Remove.
3790
716b8bc5
TT
37912018-05-25 Tom Tromey <tom@tromey.com>
3792
3793 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
3794 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
3795 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
3796
753ff9bd
TT
37972018-05-25 Tom Tromey <tom@tromey.com>
3798
3799 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
3800 * interps.c (interp_exec): Use scoped_restore.
3801
5ca3b260
TT
38022018-05-25 Tom Tromey <tom@tromey.com>
3803
3804 * remote.c (remote_target::remote_file_get): Use
3805 gdb::byte_vector.
3806 (remote_target::remote_file_put): Likewise.
3807
3173aa2f
TT
38082018-05-25 Tom Tromey <tom@tromey.com>
3809
3810 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
3811 a std::string.
3812 (get_pe_section_index, add_pe_exported_sym): Update.
3813 (read_pe_exported_syms): Use gdb::def_vector.
3814
09a5e1b5
TT
38152018-05-25 Tom Tromey <tom@tromey.com>
3816
3817 * frame.c (remove_prev_frame): Remove.
3818 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
3819
d8dab6c3
MR
38202018-05-25 Maciej W. Rozycki <macro@mips.com>
3821
3822 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
3823 Remove prototypes.
3824 * mips-linux-nat.c (supply_fpregset): Always call
3825 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
3826 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
3827 `mips_fill_fpregset'.
3828 * mips-linux-tdep.c (mips_supply_fpregset)
3829 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
3830 (mips_fill_fpregset_wrapper): Remove functions.
3831 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
3832 (mips_linux_fpregset): Remove variable.
3833 (mips_linux_iterate_over_regset_sections): Use
3834 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
3835 (mips_linux_o32_sigframe_init): Remove comment.
3836
3c69da40
PA
38372018-05-25 Pedro Alves <palves@redhat.com>
3838
3839 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
3840 (struct readahead_cache, struct packet_reg, struct
3841 remote_arch_state, class remote_state): Move higher up in the
3842 file.
3843 (remote_target::m_remote_state): Now an object instead of a pointer.
3844 (remote_target::get_remote_state): Adjust.
3845
39f0c204
AB
38462018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3847
3848 * stack.c (select_and_print_frame): Delete.
3849 (struct function_bounds): Move struct within function.
3850 (func_command): Most content moved into new function
3851 find_frame_for_function, use new function, print result, add
3852 function comment.
3853 (find_frame_for_function): New function, now returns a result.
3854
d392224a
PW
38552018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3856
3857 * stack.c (iterate_over_block_arg_vars): Fix comment.
3858 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
3859
45f25d6c
AB
38602018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
3861
3862 PR gdb/23203
3863 * frame.c
3864 (scoped_restore_selected_frame::scoped_restore_selected_frame):
3865 Define.
3866 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
3867 Define.
3868 * frame.h (class scoped_restore_selected_frame): New class.
3869 * stack.c (print_frame_local_vars): Remove catching and rethrowing
3870 of any exception, use scoped_restore_selected_frame to restore the
3871 frame instead.
3872
da05d921
PA
38732018-05-24 Pedro Alves <palves@redhat.com>
3874
3875 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
3876 override.
3877
a8be540e
TT
38782018-05-23 Tom Tromey <tom@tromey.com>
3879
3880 * complaints.c (struct complaints): Remove.
3881 (symfile_complaint_book): Remove.
3882 (series): New global.
3883 (complaint_internal): Update.
3884 (clear_complaints): Update.
3885
ff1cf532
TT
38862018-05-23 Tom Tromey <tom@tromey.com>
3887
3888 * complaints.c (counters): New global.
3889 (struct complain): Remove.
3890 (struct complaints) <root>: Remove.
3891 (complaint_sentinel): Remove.
3892 (symfile_complaint_book): Update.
3893 (find_complaint) Remove.
3894 (complaint_internal, clear_complaints): Update.
3895
7ff88174
TT
38962018-05-23 Tom Tromey <tom@tromey.com>
3897
3898 * complaints.c (struct complain) <file, line>: Remove.
3899 (find_complaint): Remove file, line parameters.
3900 (complaint_internal): Update.
3901
de54e1a5
TT
39022018-05-23 Tom Tromey <tom@tromey.com>
3903
3904 * complaints.c (vcomplaint): Remove.
3905 (complaint_internal) Merge in contents of vcomplaint.
3906
2ac237e5
TT
39072018-05-23 Tom Tromey <tom@tromey.com>
3908
3909 * complaints.c (struct complaints) <explanation>: Remove.
3910 (symfile_explanations): Remove.
3911 (symfile_complaint_book): Update.
3912 (vcomplaint): Update.
3913 (struct explanation): Remove.
3914
b98664d3
TT
39152018-05-23 Tom Tromey <tom@tromey.com>
3916
3917 * complaints.c (symfile_complaints): Remove.
3918 (complaint_internal): Remove "complaints" parameter.
3919 (clear_complaints, vcomplaint): Remove "c" parameter.
3920 (get_complaints): Remove.
3921 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
3922 (dwarf2_debug_line_missing_file_complaint)
3923 (dwarf2_debug_line_missing_end_sequence_complaint)
3924 (dwarf2_complex_location_expr_complaint)
3925 (dwarf2_const_value_length_mismatch_complaint)
3926 (dwarf2_section_buffer_overflow_complaint)
3927 (dwarf2_macro_malformed_definition_complaint)
3928 (dwarf2_invalid_attrib_class_complaint)
3929 (create_addrmap_from_index, dw2_symtab_iter_next)
3930 (dw2_expand_marked_cus)
3931 (dw2_debug_names_iterator::find_vec_in_debug_names)
3932 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
3933 (create_debug_type_hash_table, init_cutu_and_read_dies)
3934 (partial_die_parent_scope, add_partial_enumeration)
3935 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
3936 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
3937 (read_import_statement, read_file_scope, create_dwo_cu_reader)
3938 (create_cus_hash_table, create_dwp_hash_table)
3939 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
3940 (dwarf2_rnglists_process, dwarf2_ranges_process)
3941 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
3942 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
3943 (handle_struct_member_die, process_structure_scope)
3944 (read_array_type, read_common_block, read_module_type)
3945 (read_tag_pointer_type, read_typedef, read_base_type)
3946 (read_subrange_type, load_partial_dies, partial_die_info::read)
3947 (partial_die_info::read, partial_die_info::read)
3948 (partial_die_info::read, read_checked_initial_length_and_offset)
3949 (dwarf2_string_attr, read_formatted_entries)
3950 (dwarf_decode_line_header)
3951 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
3952 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
3953 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
3954 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
3955 (get_signatured_type, get_DW_AT_signature_type)
3956 (decode_locdesc, file_file_name, consume_improper_spaces)
3957 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
3958 (dwarf_decode_macro_bytes, dwarf_decode_macros)
3959 (dwarf2_symbol_mark_computed, set_die_type)
3960 (read_attribute_value): Update.
3961 * stap-probe.c (handle_stap_probe, get_stap_base_address):
3962 Update.
3963 * dbxread.c (unknown_symtype_complaint)
3964 (lbrac_mismatch_complaint, repeated_header_complaint)
3965 (set_namestring, function_outside_compilation_unit_complaint)
3966 (read_dbx_symtab, process_one_symbol): Update.
3967 * gdbtypes.c (stub_noname_complaint): Update.
3968 * windows-nat.c (handle_unload_dll): Update.
3969 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
3970 (decode_base_type): Update.
3971 * xcoffread.c (bf_notfound_complaint, ef_complaint)
3972 (eb_complaint, record_include_begin, record_include_end)
3973 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
3974 (process_xcoff_symbol, read_symbol)
3975 (function_outside_compilation_unit_complaint)
3976 (scan_xcoff_symtab): Update.
3977 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
3978 * buildsym.c (finish_block_internal, make_blockvector)
3979 (end_symtab_get_static_block, augment_type_symtab): Update.
3980 * dtrace-probe.c (dtrace_process_dof)
3981 (dtrace_static_probe_ops::get_probes): Update.
3982 * complaints.h (struct complaint): Don't declare.
3983 (symfile_complaints): Remove.
3984 (complaint_internal): Remove "complaints" parameter.
3985 (complaint): Likewise.
3986 (clear_complaints): Likewise.
3987 * symfile.c (syms_from_objfile_1, finish_new_objfile)
3988 (reread_symbols): Update.
3989 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
3990 (dwarf2_frame_cache, decode_frame_entry): Update.
3991 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
3992 * objc-lang.c (lookup_objc_class, lookup_child_selector)
3993 (info_selectors_command): Update.
3994 * macrotab.c (macro_include, check_for_redefinition)
3995 (macro_undef): Update.
3996 * objfiles.c (filter_overlapping_sections): Update.
3997 * stabsread.c (invalid_cpp_abbrev_complaint)
3998 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
3999 (define_symbol, error_type, read_type, rs6000_builtin_type)
4000 (stabs_method_name_from_physname, read_member_functions)
4001 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
4002 (attach_fields_to_type, complain_about_struct_wipeout)
4003 (read_range_type, read_args, common_block_start)
4004 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
4005 Update.
4006 * mdebugread.c (index_complaint, unknown_ext_complaint)
4007 (basic_type_complaint, bad_tag_guess_complaint)
4008 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
4009 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
4010 (parse_procedure, parse_lines)
4011 (function_outside_compilation_unit_complaint)
4012 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
4013 (bad_tag_guess_complaint, reg_value_complaint): Update.
4014 * cp-support.c (demangled_name_complaint): Update.
4015 * macroscope.c (sal_macro_scope): Update.
4016 * dwarf-index-write.c (class debug_names): Update.
4017
4e9668d0
TT
40182018-05-23 Tom Tromey <tom@tromey.com>
4019
4020 * complaints.c (clear_complaints): Remove "noisy" parameter.
4021 * complaints.h (clear_complaints): Update.
4022 * symfile.c (syms_from_objfile_1, finish_new_objfile)
4023 (reread_symbols): Update.
4024
43ba33c7
TT
40252018-05-23 Tom Tromey <tom@tromey.com>
4026
4027 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
4028 SUBSEQUENT_MESSAGE.
4029 (vcomplaint, clear_complaints): Update.
4030 (symfile_explanations): Remove some messages.
4031
2b9496b2
TT
40322018-05-23 Tom Tromey <tom@tromey.com>
4033
4034 * complaints.c (internal_complaint): Remove.
4035 * complaints.h (internal_complaint): Remove.
4036
35f1fea3
MR
40372018-05-22 Maciej W. Rozycki <macro@mips.com>
4038
4039 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
4040
6b8edb51
PA
40412018-05-22 Pedro Alves <palves@redhat.com>
4042
4043 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
4044 (remote_fileio_badfd, remote_fileio_return_errno)
4045 (remote_fileio_return_success, remote_fileio_func_open)
4046 (remote_fileio_func_open, remote_fileio_func_close)
4047 (remote_fileio_func_read, remote_fileio_func_write)
4048 (remote_fileio_func_lseek, remote_fileio_func_rename)
4049 (remote_fileio_func_unlink, remote_fileio_func_stat)
4050 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
4051 (remote_fileio_func_isatty, remote_fileio_func_system): Add
4052 remote_target parameter.
4053 (remote_fio_func_map) <func>: Add remote_target parameter.
4054 (do_remote_fileio_request, remote_fileio_request):
4055 * remote-fileio.h (remote_fileio_request):
4056 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
4057 remote_target parameter.
4058 (remote_notif_process, handle_notification): Adjust to pass down
4059 the remote.
4060 (remote_notif_state_allocate): Add remote_target parameter. Save
4061 it.
4062 * remote-notif.h (struct remote_target): Forward declare.
4063 (struct notif_client) <parse, ack, can_get_pending_events>: Add
4064 remote_target parameter.
4065 (struct remote_notif_state) <remote>: New field.
4066 (remote_notif_ack, remote_notif_parse): Add remote_target
4067 parameter.
4068 (remote_notif_state_allocate, remote_notif_state_allocate): Add
4069 remote_target parameter.
4070 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
4071 (threads_listing_context, rmt_thread_action, protocol_feature)
4072 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
4073 (packet_result, struct threads_listing_context, remote_state):
4074 Move definitions and declarations higher up.
4075 (remote_target) <~remote_target>: Declare.
4076 (remote_download_command_source, remote_file_put, remote_file_get)
4077 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
4078 (remote_hostio_pread_vFile, remote_hostio_send_command)
4079 (remote_hostio_set_filesystem, remote_hostio_open)
4080 (remote_hostio_close, remote_hostio_unlink, remote_state)
4081 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
4082 (get_memory_write_packet_size, get_memory_read_packet_size)
4083 (append_pending_thread_resumptions, remote_detach_1)
4084 (append_resumption, remote_resume_with_vcont)
4085 (add_current_inferior_and_thread, wait_ns, wait_as)
4086 (process_stop_reply, remote_notice_new_inferior)
4087 (process_initial_stop_replies, remote_add_thread)
4088 (btrace_sync_conf, remote_btrace_maybe_reopen)
4089 (remove_new_fork_children, kill_new_fork_children)
4090 (discard_pending_stop_replies, stop_reply_queue_length)
4091 (check_pending_events_prevent_wildcard_vcont)
4092 (discard_pending_stop_replies_in_queue, stop_reply)
4093 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
4094 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
4095 (remote_interrupt_as, remote_interrupt_ns)
4096 (remote_get_noisy_reply, remote_query_attached)
4097 (remote_add_inferior, remote_current_thread, get_current_thread)
4098 (set_thread, set_general_thread, set_continue_thread)
4099 (set_general_process, write_ptid)
4100 (remote_unpack_thread_info_response, remote_get_threadinfo)
4101 (parse_threadlist_response, remote_get_threadlist)
4102 (remote_threadlist_iterator, remote_get_threads_with_ql)
4103 (remote_get_threads_with_qxfer)
4104 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
4105 (get_offsets, remote_check_symbols, remote_supported_packet)
4106 (remote_query_supported, remote_packet_size)
4107 (remote_serial_quit_handler, remote_detach_pid)
4108 (remote_vcont_probe, remote_resume_with_hc)
4109 (send_interrupt_sequence, interrupt_query)
4110 (remote_notif_get_pending_events, fetch_register_using_p)
4111 (send_g_packet, process_g_packet, fetch_registers_using_g)
4112 (store_register_using_P, store_registers_using_G)
4113 (set_remote_traceframe, check_binary_download)
4114 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
4115 (remote_xfer_live_readonly_partial, remote_read_bytes)
4116 (remote_send_printf, remote_flash_write, readchar)
4117 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
4118 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
4119 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
4120 (extended_remote_disable_randomization, extended_remote_run)
4121 (send_environment_packet, extended_remote_environment_support)
4122 (extended_remote_set_inferior_cwd, remote_write_qxfer)
4123 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
4124 (packet_command): Now methods of ...
4125 (remote_target): ... this class.
4126 (m_remote_state) <remote_target>: New field.
4127 (struct remote_state) <stop_reply_queue,
4128 remote_async_inferior_event_token, wait_forever_enabled_p>: New
4129 fields.
4130 (remote_state::remote_state): Allocate stop_reply_queue.
4131 (remote_state): Delete global.
4132 (get_remote_state_raw): Delete.
4133 (remote_target::get_remote_state): Allocate m_remote_state on
4134 demand.
4135 (get_current_remote_target): New.
4136 (remote_ops, extended_remote_ops): Delete.
4137 (wait_forever_enabled_p, remote_async_inferior_event_token):
4138 Delete, moved to struct remote_state.
4139 (remote_target::close): Delete self. Destruction bits split to
4140 ...
4141 (remote_target::~remote_target): ... this.
4142 (show_memory_packet_size): Adjust to use
4143 get_current_remote_target.
4144 (struct protocol_feature) <func>: Add remote_target parameter.
4145 All callers adjusted.
4146 (curr_quit_handler_target): New.
4147 (remote_serial_quit_handler): Reimplement.
4148 (remote_target::open_1): Adjust to use get_current_remote_target.
4149 Heap-allocate remote_target/extended_remote_target instances.
4150 (vcont_builder::vcont_builder): Add remote_target parameter, and
4151 save it in m_remote. All callers adjusted.
4152 (vcont_builder::m_remote): New field.
4153 (vcont_builder::restart, vcont_builder::flush)
4154 (vcont_builder::push_action): Use it.
4155 (remote_target::commit_resume): Use it.
4156 (struct queue_iter_param) <remote>: New field.
4157 (remote_target::remove_new_fork_children): Fill in 'remote' field.
4158 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
4159 (check_pending_event_prevents_wildcard_vcont_callback)
4160 (remote_target::check_pending_events_prevent_wildcard_vcont)
4161 (remote_target::discard_pending_stop_replies)
4162 (remote_target::discard_pending_stop_replies_in_queue)
4163 (remote_target::remote_notif_remove_queued_reply): Fill in
4164 'remote' field.
4165 (remote_notif_get_pending_events): New.
4166 (remote_target::readchar, remote_target::remote_serial_write):
4167 Save/restore curr_quit_handler_target.
4168 (putpkt): New.
4169 (kill_new_fork_children): Fill in 'remote' field.
4170 (packet_command): Use get_current_remote_target, defer to
4171 remote_target method of same name.
4172 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
4173 parameter, and save it in m_remote. All callers adjusted.
4174 (scoped_remote_fd::release): Use m_remote.
4175 (scoped_remote_fd::m_remote): New field.
4176 (remote_file_put, remote_file_get, remote_file_delete): Use
4177 get_current_remote_target, defer to remote_target method of same
4178 name.
4179 (remote_btrace_reset): Add remote_state paremeter. Update all
4180 callers.
4181 (remote_async_inferior_event_handler). Pass down 'data'.
4182 (remote_new_objfile): Use get_current_remote_target.
4183 (remote_target::vcont_r_supported): New.
4184 (set_range_stepping): Use get_current_remote_target and
4185 remote_target::vcont_r_supported.
4186 (_initialize_remote): Don't allocate 'remote_state' and
4187 'stop_reply_queue' globals.
4188 * remote.h (struct remote_target): Forward declare.
4189 (getpkt, putpkt, remote_notif_get_pending_events): Add
4190 'remote_target' parameter.
4191
f5db4863
PA
41922018-05-22 Pedro Alves <palves@redhat.com>
4193
4194 * remote.c (vcont_builder): Now a class. Make all data members
4195 private.
4196 (vcont_builder) <vcont_builder, restart, flush, push_action>:
4197 Declare methods.
4198 (vcont_builder_restart): Rename to ...
4199 (vcont_builder::restart): ... this.
4200 (vcont_builder_flush): Rename to ...
4201 (vcont_builder::flush): ... this.
4202 (vcont_builder_push_action): Rename to ...
4203 (vcont_builder::push_action): ... this.
4204 (remote_target::commit_resume): Adjust.
4205
cc0be08f
PA
42062018-05-22 Pedro Alves <palves@redhat.com>
4207
4208 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
4209 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
4210 (get_fixed_memory_packet_size): New.
4211 (get_memory_packet_size): Use it.
4212 (set_memory_packet_size): Don't override the config size with
4213 DEFAULT_MAX_MEMORY_PACKET_SIZE.
4214 (show_memory_packet_size): Use get_fixed_memory_packet_size.
4215 Don't refer to get_memory_packet_size if not connected to a remote
4216 target. Show "(default)" if configured size is 0.
4217
9607784a
PA
42182018-05-22 Pedro Alves <palves@redhat.com>
4219
4220 * remote.c (remote_target::mourn_inferior): Move
4221 discard_pending_stop_replies call here from ...
4222 (_initialize_remote): ... here.
4223
0e9a6b2f
PA
42242018-05-22 Pedro Alves <palves@redhat.com>
4225
4226 * remote.c (compare_section_command): Remove set_general_process
4227 call.
4228
43c3a0e4
PA
42292018-05-22 Pedro Alves <palves@redhat.com>
4230
4231 * remote.c (struct packet_reg, struct remote_arch_state):
4232 Move higher up in the file.
4233 (remote_state) <m_arch_states>: Store remote_arch_state values
4234 instead of remote_arch_state pointers.
4235 (remote_state::get_remote_arch_state): Adjust.
4236
9d6eea31
PA
42372018-05-22 Pedro Alves <palves@redhat.com>
4238
4239 * remote.c: Include <unordered_map>.
4240 (remote_state): Now a class.
4241 (remote_state) <get_remote_arch_state>: Declare method.
4242 <get_remote_arch_state>: New field.
4243 (remote_arch_state) <remote_arch_state>: Declare ctor.
4244 <regs>: Now a unique_ptr.
4245 (remote_gdbarch_data_handle): Delete.
4246 (get_remote_arch_state): Delete.
4247 (remote_state::get_remote_arch_state): New.
4248 (get_remote_state): Adjust to call remote_state's
4249 get_remote_arch_state method.
4250 (init_remote_state): Delete, bits factored out to ...
4251 (remote_arch_state::remote_arch_state): ... this new method.
4252 (get_remote_packet_size, get_memory_packet_size)
4253 (process_g_packet, remote_target::fetch_registers)
4254 (remote_target::prepare_to_store, store_registers_using_G)
4255 (remote_target::store_registers, remote_target::get_trace_status):
4256 Adjust to call remote_state's method.
4257 (_initialize_remote): Remove reference to
4258 remote_gdbarch_data_handle.
4259
dd194f6b
PA
42602018-05-22 Pedro Alves <palves@redhat.com>
4261
4262 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
4263 pread>: New method declarations.
4264 (remote_target::open_1): Adjust.
4265 (readahead_cache_invalidate): Rename to ...
4266 (readahead_cache::invalidate): ... this, and adjust to be a class
4267 method.
4268 (readahead_cache_invalidate_fd): Rename to ...
4269 (readahead_cache::invalidate_fd): ... this, and adjust to be a
4270 class method.
4271 (remote_hostio_pwrite): Adjust.
4272 (remote_hostio_pread_from_cache): Rename to ...
4273 (readahead_cache::pread): ... this, and adjust to be a class
4274 method.
4275 (remote_hostio_close): Adjust.
4276
440b7aec
PA
42772018-05-22 Pedro Alves <palves@redhat.com>
4278
4279 * remote.c (remote_hostio_close_cleanup): Delete.
4280 (class scoped_remote_fd): New.
4281 (remote_file_put, remote_file_get): Use it.
4282
de44f5a7
PA
42832018-05-22 Pedro Alves <palves@redhat.com>
4284
4285 (struct vCont_action_support): Use bool and initialize all fields.
4286 (struct readahead_cache): Initialize all fields.
4287 (remote_state): Use bool and initialize all fields.
4288 (remote_state::remote_state, remote_state::~remote_state): New.
4289 (new_remote_state): Delete.
4290 (_initialize_remote): Use new to allocate remote_state.
4291
b1b60145
PA
42922018-05-22 Pedro Alves <palves@redhat.com>
4293 張俊芝 <zjz@zjz.name>
4294
4295 PR gdb/22973
4296 * c-exp.y: Include "c-support.h".
4297 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
4298 of tolower. Use c_ident_is_alpha to scan names.
4299 * c-lang.c: Include "c-support.h".
4300 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
4301 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
4302 * c-support.h: New file, with bits factored out from ...
4303 * cp-name-parser.y: ... this file.
4304 Include "c-support.h".
4305 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
4306 c-support.h and renamed.
4307 (symbol_end, yylex): Adjust.
4308
0ec848ad
PFC
43092018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4310
4311 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
4312 parameter type to CORE_ADDR.
4313 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
4314 parameter type in declaration to CORE_ADDR.
4315 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
4316 target_auxv_search to get AT_HWCAP and use the result to get the
4317 target description.
4318 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
4319 to CORE_ADDR. Remove the cast of the return value to unsigned
4320 long. Fix error predicate of target_auxv_search.
4321 (ppc_linux_nat_target::read_description): Change the type of the
4322 hwcap variable to CORE_ADDR.
4323
0fb2aaa1
PFC
43242018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4325
4326 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
4327 if the size of fpscr is larger than 32 bits.
4328
2c3305f6
PFC
43292018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4330
4331 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
4332 (ppc32_linux_vsxregmap): New global.
4333 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
4334 regcache_supply_regset, and regcache_collect_regset.
4335 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
4336 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
4337 (fetch_vsx_register, store_vsx_register): Remove.
4338 (fetch_vsx_registers): Add regno parameter. Get regset using
4339 ppc_linux_vsxregset. Use regset to supply registers.
4340 (store_vsx_registers): Add regno parameter. Get regset using
4341 ppc_linux_vsxregset. Use regset to collect registers.
4342 (fetch_register): Call fetch_vsx_registers instead of
4343 fetch_vsx_register.
4344 (store_register): Call store_vsx_registers instead of
4345 store_vsx_register.
4346 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
4347 new regno parameter.
4348 (store_ppc_registers): Call store_vsx_registers with -1 for the
4349 new regno parameter.
4350 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
4351 (ppc_collect_vsxregset): Remove.
4352
1d75a658
PFC
43532018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4354
4355 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
4356 offset fields.
4357 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
4358 for vector register offset fields.
4359 (ppc64_fbsd_reg_offsets): Likewise.
4360 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4361 to vector register offset fields.
4362 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
4363 to vector register offset fields.
4364 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
4365 vector register offset fields.
4366 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
4367 initializers for vector register offset fields.
4368 (rs6000_aix64_reg_offsets): Likewise.
4369 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
4370 (ppc_supply_vrregset): Remove.
4371 (ppc_collect_vrregset): Remove.
4372 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
4373 (ppc_linux_vrregset) : New function.
4374 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
4375 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
4376 (ppc32_linux_vrregset): Remove.
4377 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
4378 and use result instead of ppc32_linux_vrregset.
4379 (ppc32_linux_reg_offsets): Remove initializers for vector register
4380 offset fields.
4381 (ppc64_linux_reg_offsets): Likewise.
4382 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
4383 * ppc-linux-nat.c: Include regset.h.
4384 (gdb_vrregset_t): Adjust comment to account for little-endian
4385 mode.
4386 (supply_vrregset, fill_vrregset): Remove.
4387 (fetch_altivec_register, store_altivec_register): Remove.
4388 (fetch_altivec_registers): Add regno parameter. Get regset using
4389 ppc_linux_vrregset. Use regset to supply registers.
4390 (store_altivec_registers): Add regno parameter. Get regset using
4391 ppc_linux_vrregset. Use regset to collect registers.
4392 (fetch_register): Call fetch_altivec_registers instead of
4393 fetch_altivec_register.
4394 (store_register): Call store_altivec_registers instead of
4395 store_altivec_register.
4396 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
4397 the new regno parameter.
4398 (store_ppc_registers): Call store_altivec_registers with -1 for
4399 the new regno parameter.
4400
d078308a
PFC
44012018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4402
4403 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
4404 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
4405 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
4406 (gdb_vrregset_t): Change array type size to
4407 PPC_LINUX_SIZEOF_VRREGSET.
4408 (gdb_vsxregset_t): Change array type size to
4409 PPC_LINUX_SIZEOF_VSXREGSET.
4410 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
4411 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
4412 PPC_LINUX_SIZEOF_VSXREGSET.
4413
2e077f5e
PFC
44142018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4415
4416 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
4417 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
4418 nat/ppc-linux.c.
4419 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
4420 ppc_linux_target_wordsize with tid.
4421 (ppc_linux_nat_target::read_description): Call ppc_linux_target
4422 wordsize with tid.
4423 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
4424 (ppc64_64bit_inferior_p): Add static and inline specifiers.
4425 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
4426 tid parameter. Remove static specifier.
4427 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
4428 (ppc_linux_target_wordsize): New declaration.
4429
bd64614e
PFC
44302018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
4431
4432 * arch/ppc-linux-common.c: New file.
4433 * arch/ppc-linux-common.h: New file.
4434 * arch/ppc-linux-tdesc.h: New file.
4435 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
4436 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
4437 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
4438 arch/ppc-linux-tdesc.h.
4439 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
4440 arch/ppc-linux-tdesc.h.
4441 (ppc_linux_nat_target::read_description): Remove target
4442 description matching code. Fill a ppc_linux_features struct and
4443 call ppc_linux_match_description with it. Move comment about ISA
4444 2.05 to ppc-linux-common.c.
4445 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
4446 arch/ppc-linux-tdesc.h.
4447 (ppc_linux_core_read_description): Remove target description
4448 matching code. Fill a ppc_linux_features struct and call
4449 ppc_linux_match_description with it.
4450 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
4451 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
4452 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
4453 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
4454 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
4455 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
4456 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
4457 (tdesc_powerpc_e500l): Remove.
4458
241db429
JB
44592018-05-22 Joel Brobecker <brobecker@adacore.com>
4460
4461 * ada-lang.c (catch_assert_command): Pass empty string instead
4462 of NULL for excep_string argument.
4463
75d74cca
MR
44642018-05-22 Maciej W. Rozycki <macro@mips.com>
4465
4466 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
4467 the width of the requested register exceeds the width of the
4468 `ptrace' data type.
4469
122b53ea
TT
44702018-05-21 Tom Tromey <tom@tromey.com>
4471
4472 * printcmd.c (output_command): Remove.
4473 (output_command_const): Rename to output_command.
4474 * valprint.h (output_command): Rename from output_command_const.
4475 * tracepoint.c (trace_dump_actions): Call output_command.
4476
bc18fbb5
TT
44772018-05-21 Tom Tromey <tom@tromey.com>
4478
4479 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
4480 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
4481 * ada-lang.h (create_ada_exception_catchpoint): Update.
4482 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
4483 std::string.
4484 (create_excep_cond_exprs, ~ada_catchpoint)
4485 (should_stop_exception, print_one_exception)
4486 (print_mention_exception, print_recreate_exception): Update.
4487 (ada_get_next_arg): Remove.
4488 (catch_ada_exception_command_split): Use std::string. Change type
4489 of "excep_string", "cond_string".
4490 (catch_ada_exception_command): Update.
4491 (create_ada_exception_catchpoint): Change type of excep_string.
4492 (ada_exception_sal): Remove excep_string parameter.
4493 (~ada_catchpoint): Remove.
4494
790217f6
TT
44952018-05-21 Tom Tromey <tom@tromey.com>
4496
4497 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
4498 cleanup.
4499
6f46ac85
TT
45002018-05-21 Tom Tromey <tom@tromey.com>
4501
4502 * ada-lang.c (ada_exception_message_1, ada_exception_message):
4503 Return unique_xmalloc_ptr.
4504 (print_it_exception): Update.
4505
15b6611c
TT
45062018-05-21 Tom Tromey <tom@tromey.com>
4507
4508 * tracepoint.c (trace_dump_actions): Use std::string.
4509
c0c9f665
TT
45102018-05-21 Tom Tromey <tom@tromey.com>
4511
4512 * symfile.c (reread_symbols): Use std::string for original_name.
4513
22ca247e
TT
45142018-05-21 Tom Tromey <tom@tromey.com>
4515
4516 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
4517 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
4518 constructor.
4519
184cde75
SM
45202018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
4521
4522 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
4523 instance to...
4524 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
4525 * objfiles.c (get_objfile_bfd_data): Allocate
4526 objfile_per_bfd_storage with obstack_new when allocating on
4527 obstack.
4528
e39db4db
SM
45292018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4530
4531 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
4532 OBSTACK_ZALLOC.
4533 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
4534 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
4535 * mdebugread.c (mdebug_build_psymtabs): Likewise.
4536 (add_pending): Likewise.
4537 (parse_symbol): Likewise.
4538 (parse_partial_symbols): Likewise.
4539 (psymtab_to_symtab_1): Likewise.
4540 (new_psymtab): Likewise.
4541 (elfmdebug_build_psymtabs): Likewise.
4542 * minsyms.c (terminate_minimal_symbol_table): Likewise.
4543 * objfiles.c (get_objfile_bfd_data): Likewise.
4544 (objfile_register_static_link): Likewise.
4545 * psymtab.c (allocate_psymtab): Likewise.
4546 * stabsread.c (read_member_functions): Likewise.
4547 * xcoffread.c (xcoff_end_psymtab): Likewise.
4548
284a0e3c
SM
45492018-05-20 Simon Marchi <simon.marchi@ericsson.com>
4550
4551 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
4552 compiler supports std::is_trivially_constructible.
4553 * common/poison.h: Include obstack.h.
4554 (IsMallocable): Define to is_trivially_constructible if the
4555 compiler supports it, define to true_type otherwise.
4556 (xobnew): New.
4557 (XOBNEW): Redefine.
4558 (xobnewvec): New.
4559 (XOBNEWVEC): Redefine.
4560 * gdb_obstack.h (obstack_zalloc): New.
4561 (OBSTACK_ZALLOC): Redefine.
4562 (obstack_calloc): New.
4563 (OBSTACK_CALLOC): Redefine.
4564 (obstack_new): New.
4565 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
4566 (gdbarch_obstack): New declaration in gdbarch.h, definition in
4567 gdbarch.c.
4568 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
4569 obstack_calloc/obstack_zalloc.
4570 (gdbarch_obstack_zalloc): Remove.
4571 * target-descriptions.c (tdesc_data_init): Use obstack_new.
4572
59f66be3
PW
45732018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4574
4575 * stack.c (backtrace_command_1): Remove useless variable int i.
4576
50c65c2d
PW
45772018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4578
4579 * stack.c (print_frame_info): Fix comment.
4580
7ff8cb8c
TT
45812018-05-18 Tom Tromey <tom@tromey.com>
4582
4583 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
4584 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
4585 (~dwarf2_per_objfile): Update
4586 (dwarf2_get_dwz_file): Use new.
4587 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
4588 unique_ptr.
4589
400174b1
TT
45902018-05-18 Tom Tromey <tom@tromey.com>
4591
4592 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
4593 unique_ptr.
4594 * dwarf2read.c (struct dwp_file): Add constructor and
4595 initializers.
4596 (open_and_init_dwp_file): Return a unique_ptr.
4597 (dwarf2_per_objfile, create_dwp_hash_table)
4598 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
4599 (lookup_dwo_unit_in_dwp): Update.
4600 (open_and_init_dwp_file, get_dwp_file): Update.
4601
3063847f
TT
46022018-05-18 Tom Tromey <tom@tromey.com>
4603
4604 * dwarf2read.c (dwarf2_per_objfile): Update.
4605 (struct mapped_index): Add initializers.
4606 (dwarf2_read_index): Use new.
4607 (dw2_symtab_iter_init): Update.
4608 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
4609 unique_ptr.
4610
d3d02dee
SM
46112018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4612
4613 * dwarf2read.c (mapped_index) <total_size>: Remove.
4614
1d143c36
SM
46152018-05-18 Simon Marchi <simon.marchi@ericsson.com>
4616
4617 * unittests/format_pieces-selftests.c (test_format_specifier):
4618 Add ARI comments.
4619
ce1e8424
TT
46202018-05-18 Tom Tromey <tom@tromey.com>
4621
4622 * c-typeprint.c (maybe_print_hole): New function.
4623 (c_print_type_struct_field_offset): Update.
4624 (c_type_print_base_struct_union): Call maybe_print_hole.
4625
ddfe970e
KS
46262018-05-17 Keith Seitz <keiths@redhat.com>
4627
4628 * breakpoint.c (build_bpstat_chain): New function, moved from
4629 bpstat_stop_status.
4630 (bpstat_stop_status): Add optional parameter, `stop_chain'.
4631 If no stop chain is passed, call build_bpstat_chain to build it.
4632 * breakpoint.h (build_bpstat_chain): Declare.
4633 (bpstat_stop_status): Move documentation here from breakpoint.c.
4634 * infrun.c (handle_signal_stop): Before eliding inlined frames,
4635 build the stop chain and pass it to skip_inline_frames.
4636 Pass this stop chain to bpstat_stop_status.
4637 * inline-frame.c: Include breakpoint.h.
4638 (stopped_by_user_bp_inline_frame): New function.
4639 (skip_inline_frames): Add parameter `stop_chain'.
4640 Move documention to inline-frame.h.
4641 If non-NULL, use stopped_by_user_bp_inline_frame to determine
4642 whether the frame should be elided.
4643 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
4644 Add moved documentation and update for new parameter.
4645
b17992c1
SM
46462018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4647
4648 PR cli/14975
4649 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4650 unittests/format_pieces-selftests.c.
4651 * common/format.h (format_piece) <operator==>: New.
4652 (format_pieces) <operator[]>: Remove.
4653 * common/format.c (format_pieces::format_pieces): Handle \e.
4654 * unittests/format_pieces-selftests.c: New.
4655
58f0c718
TT
46562018-05-17 Tom Tromey <tom@tromey.com>
4657
4658 PR symtab/23010:
4659 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
4660 (dw2_instantiate_symtab): Add skip_partial parameter.
4661 (dw2_find_last_source_symtab, dw2_map_expand_apply)
4662 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
4663 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
4664 (dw2_expand_symtabs_matching_one)
4665 (dw2_find_pc_sect_compunit_symtab)
4666 (dw2_debug_names_lookup_symbol)
4667 (dw2_debug_names_expand_symtabs_for_function): Update.
4668 (init_cutu_and_read_dies): Add skip_partial parameter.
4669 (process_psymtab_comp_unit, build_type_psymtabs_1)
4670 (process_skeletonless_type_unit, load_partial_comp_unit)
4671 (psymtab_to_symtab_1): Update.
4672 (load_full_comp_unit): Add skip_partial parameter.
4673 (process_imported_unit_die, dwarf2_read_addr_index)
4674 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
4675 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
4676 (read_signatured_type): Update.
4677
3e618834
SM
46782018-05-17 Simon Marchi <simon.marchi@ericsson.com>
4679
4680 * value.c (release_value): Remove unused variable.
4681 (record_latest_value): Likewise.
4682 (access_value_history): Likewise.
4683 (preserve_values): Likewise.
4684
fe10fe31
TT
46852018-05-17 Tom Tromey <tom@tromey.com>
4686
4687 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
4688 Initialize.
4689
1d761124
MR
46902018-05-16 Maciej W. Rozycki <macro@mips.com>
4691
4692 PR gdb/22286
4693 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
4694 Also handle registers whose width is not a multiple of
4695 PTRACE_TYPE_RET.
4696 (linux_nat_trad_target::store_register): Likewise.
4697
06333fea
TT
46982018-05-16 Tom Tromey <tom@tromey.com>
4699
4700 * gdbcore.h (core_bfd): Redefine.
4701 * corelow.c (core_target::close): Update.
4702 (core_target_open): Update.
4703 * progspace.h (struct program_space) <cbfd>: Now a
4704 gdb_bfd_ref_ptr.
4705
921222e2
TT
47062018-05-16 Tom Tromey <tom@tromey.com>
4707
4708 PR cli/19551:
4709 * symfile-add-flags.h (enum symfile_add_flags)
4710 <SYMFILE_NOT_FILENAME>: New constant.
4711 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
4712 objfile name from BFD.
4713 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
4714 * minidebug.c (find_separate_debug_file_in_section): Put
4715 ".gnu_debugdata" into BFD's file name.
4716
3acb7083
SM
47172018-05-16 Simon Marchi <simon.marchi@ericsson.com>
4718
4719 * regcache.c (regcache_read_ftype, regcache_write_ftype):
4720 Remove.
4721
561a72d4
TC
47222018-05-15 Tamar Christina <tamar.christina@arm.com>
4723
4724 PR binutils/21446
4725 * aarch64-tdep.c (aarch64_analyze_prologue,
4726 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
4727 Indicate not interested in errors.
4728
4e6ff0e1
MR
47292018-05-15 Maciej W. Rozycki <macro@mips.com>
4730
4731 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
4732 Supply the MIPS_ZERO_REGNUM register.
4733
ea33cd92
MR
47342018-05-15 Maciej W. Rozycki <macro@mips.com>
4735
4736 * mips-tdep.c (mask_address_var): Make variable static.
4737
2d79090e
TT
47382018-05-14 Tom Tromey <tom@tromey.com>
4739
4740 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
4741
cf4912ae
AB
47422018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
4743
4744 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
4745 FXSAVE_ADDR for the mxcsr register.
4746
67e6f569
MF
47472018-05-11 Max Filippov <jcmvbkbc@gmail.com>
4748
4749 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
4750
15244507
PA
47512018-05-11 Pedro Alves <palves@redhat.com>
4752
4753 * corelow.c (core_target) <core_target>: No longer inline.
4754 Initialize m_core_gdbarch, m_core_vec and build the section table
4755 here.
4756 <~core_target>: New.
4757 <core_gdbarch, get_core_register_section>: New methods.
4758 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
4759 factored out from ...
4760 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
4761 (core_ops): Delete.
4762 (sniff_core_bfd): Add gdbarch parameter.
4763 (core_close): Delete, merged into ...
4764 (core_target::close): ... here. Delete self.
4765 (core_close_cleanup): Delete.
4766 (core_target_open): Allocate a core_target on the heap. Use a
4767 unique_ptr instead of a cleanup. Bits moved into the core_target
4768 ctor. Adjust to use core_target methods instead of globals.
4769 (get_core_register_section): Rename to ...
4770 (core_target::get_core_register_section): ... this and adjust.
4771 (struct get_core_registers_cb_data): New.
4772 (get_core_registers_cb): Use it. Use bool.
4773 (core_target::fetch_registers, core_target::files_info)
4774 (core_target::xfer_partial, core_target::read_description)
4775 (core_target::pid_to, core_target::thread_name): Adjust to
4776 reference class fields instead of globals.
4777 * target.h (struct target_ops_deleter, target_ops_up): New.
4778
451953fa
PA
47792018-05-11 Pedro Alves <palves@redhat.com>
4780
4781 * corefile.c (core_file_command): Move to corelow.c.
4782 * corelow.c (the_core_target): Delete.
4783 (core_file_command): Moved from corefile.c. Check exec_bfd
4784 instead of the_core_target. Use target_detach instead of calling
4785 into the_core_target directly.
4786 (maybe_say_no_core_file_now): New.
4787 (core_target::detach): Use it.
4788 (_initialize_corelow): Remove references to the_core_target.
4789 * gdbcore.h (the_core_target): Delete.
4790
e540a5a2 47912018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 4792 Pedro Alves <palves@redhat.com>
e540a5a2
TT
4793
4794 * corefile.c (core_bfd): Remove.
4795 * gdbcore.h (core_bfd): Now a macro.
4796 * progspace.h (struct program_space) <cbfd>: New field.
4797
633cf254
TT
47982018-05-11 Tom Tromey <tom@tromey.com>
4799
4800 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
4801 gdb::def_vector.
4802
1a34f210
TT
48032018-05-10 Tom Tromey <tom@tromey.com>
4804
4805 * configure: Rebuild.
4806 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
4807
190852c8
JB
48082018-05-10 Joel Brobecker <brobecker@adacore.com>
4809
4810 PR server/23158:
4811 * regformats/regdat.sh: Adjust script, following the addition
4812 of the new expedite_regs parameter to init_target_desc.
4813
8727de56
OJ
48142018-05-10 Omair Javaid <omair.javaid@linaro.org>
4815
4816 PR gdb/23127
4817 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
4818 set_gdbarch_significant_addr_bit.
4819 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
4820 set_gdbarch_significant_addr_bit.
4821 * utils.c (address_significant): Update to sign extend addr.
4822
37d9e062
MF
48232018-05-09 Max Filippov <jcmvbkbc@gmail.com>
4824
4825 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
4826 (xtensa_linux_init_abi): Limit tdep->num_regs by
4827 tdep->num_nopriv_regs.
4828 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
4829 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
4830 not initialized.
4831
7402fbca
SM
48322018-05-08 Simon Marchi <simon.marchi@ericsson.com>
4833
4834 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
4835
8ee22052
AB
48362018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
4837
4838 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
4839 (I387_MXCSR_INIT_VAL): New constant.
4840 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
4841 buffer if it was supplied by the inferior.
4842 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
4843 (i387_xsave_get_clear_bv): New function.
4844 (i387_supply_xsave): Only read x87 control registers from the
4845 xsave buffer if the feature is enabled, and the state will have
4846 been written, otherwise, provide a suitable default.
4847 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
4848 including x87 control registers. Update control registers if they
4849 have changed from the default value, and mark features as enabled
4850 as required.
4851 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
4852
968ae51b
UW
48532018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
4854
4855 * spu-tdep.c (info_spu_event_command): Fix output formatting.
4856
aff689d3
TT
48572018-05-07 Tom Tromey <tom@tromey.com>
4858
4859 * configure: Rebuild.
4860 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
4861
ce887586
TT
48622018-05-07 Tom Tromey <tom@tromey.com>
4863
4864 PR tdep/20362:
4865 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
4866 bit. Use correct value for VDIV.
4867
85e26832
TT
48682018-05-04 Tom Tromey <tom@tromey.com>
4869
4870 * configure: Rebuild.
4871 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
4872
449b1ac7
TT
48732018-05-04 Tom Tromey <tom@tromey.com>
4874
4875 * linux-record.c (record_linux_system_call) <case
4876 RECORD_SYS_RECVFROM>: Add "break".
4877
15c9ffd6
TT
48782018-05-04 Tom Tromey <tom@tromey.com>
4879
4880 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
4881 Add missing "break".
4882 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
4883 Add missing "break".
4884
e3829d13
TT
48852018-05-04 Tom Tromey <tom@tromey.com>
4886
4887 * rs6000-tdep.c (ppc_process_record_op4)
4888 (ppc_process_record_op63): Add fall-through comment.
4889
da0e1563
TT
48902018-05-04 Tom Tromey <tom@tromey.com>
4891
4892 * i386-tdep.c (i386_process_record): Add fall-through comment.
4893
0019cd49
TT
48942018-05-04 Tom Tromey <tom@tromey.com>
4895
4896 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
4897 comment.
4898
565e0eda
TT
48992018-05-04 Tom Tromey <tom@tromey.com>
4900
4901 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
4902 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
4903 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
4904 comment.
4905 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
4906 comment.
4907 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
4908 comment.
4909
621846f4
TT
49102018-05-04 Tom Tromey <tom@tromey.com>
4911
4912 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
4913
86a73007
TT
49142018-05-04 Tom Tromey <tom@tromey.com>
4915
4916 * s390-tdep.c (s390_process_record): Fix fall-through comments.
4917 * xcoffread.c (scan_xcoff_symtab): Move comment later.
4918 * symfile.c (section_is_mapped): Fix fall-through comment.
4919 * stabsread.c (define_symbol, read_member_functions): Fix
4920 fall-through comment.
4921 * s390-linux-tdep.c (s390_process_record): Fix fall-through
4922 comment.
4923 * remote.c (remote_wait_as): Fix fall-through comment.
4924 * p-exp.y (yylex): Fix fall-through comment.
4925 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
4926 comment.
4927 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
4928 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
4929 * jv-exp.y (yylex): Fix fall-through comment.
4930 * go-exp.y (lex_one_token): Fix fall-through comment.
4931 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
4932 fall-through comment.
4933 * f-exp.y (yylex): Fix fall-through comment.
4934 * dwarf2read.c (process_die): Fix fall-through comments.
4935 * dbxread.c (process_one_symbol): Fix fall-through comment.
4936 * d-exp.y (lex_one_token): Fix fall-through comment.
4937 * cp-name-parser.y (yylex): Fix fall-through comment.
4938 * coffread.c (coff_symtab_read): Fix fall-through comment.
4939 * c-exp.y (lex_one_token): Fix fall-through comment.
4940 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
4941 comment.
4942 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
4943 comment.
4944
56bcdbea
TT
49452018-05-04 Tom Tromey <tom@tromey.com>
4946
4947 PR python/22730:
4948 * NEWS: Mention gdb.execute change.
4949 * gdbcmd.h (execute_control_command): Don't declare.
4950 * python/python.c (execute_gdb_command): Use read_command_lines_1,
4951 execute_control_commands, execute_control_commands_to_string.
4952 * cli/cli-script.h (execute_control_commands)
4953 (execute_control_commands_to_string): Declare.
4954 (execute_control_command): Add from_tty parameter.
4955 * cli/cli-script.c (execute_control_commands)
4956 (execute_control_commands_to_string): New functions.
4957 (execute_user_command): Use execute_control_commands.
4958 (execute_control_command_1): Add "from_tty" parameter. Update.
4959 (execute_control_command): Likewise.
4960
a913fffb
TT
49612018-05-04 Tom Tromey <tom@tromey.com>
4962
4963 PR python/22731:
4964 * NEWS: Mention that breakpoint commands are writable.
4965 * python/py-breakpoint.c (bppy_set_commands): New function.
4966 (breakpoint_object_getset) <"commands">: Use it.
4967
60b3cef2
TT
49682018-05-04 Tom Tromey <tom@tromey.com>
4969
4970 * tracepoint.c (actions_command): Update.
4971 * mi/mi-cmd-break.c (mi_command_line_array)
4972 (mi_command_line_array_cnt, mi_command_line_array_ptr)
4973 (mi_read_next_line): Remove.
4974 (mi_cmd_break_commands): Update.
4975 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
4976 function_view.
4977 * cli/cli-script.c (get_command_line): Update.
4978 (process_next_line): Use function_view. Constify.
4979 (recurse_read_control_structure, read_command_lines)
4980 (read_command_lines_1): Change argument types to function_view.
4981 (do_define_command, document_command): Update.
4982 * breakpoint.h (check_tracepoint_command): Don't declare.
4983 * breakpoint.c (check_tracepoint_command): Remove.
4984 (commands_command_1, create_tracepoint_from_upload): Update.
4985
7a2c85f2
TT
49862018-05-04 Tom Tromey <tom@tromey.com>
4987
4988 PR gdb/11750:
4989 * cli/cli-script.h (enum command_control_type) <define_control>:
4990 New constant.
4991 * cli/cli-script.c (multi_line_command_p): Handle define_control.
4992 (build_command_line, execute_control_command_1)
4993 (process_next_line): Likewise.
4994 (do_define_command): New function, extracted from define_command.
4995 (define_command): Use it.
4996
295dc222
TT
49972018-05-04 Tom Tromey <tom@tromey.com>
4998
4999 * tracepoint.c (actions_command): Update.
5000 * cli/cli-script.h (read_command_lines): Update.
5001 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
5002 (MAX_TMPBUF): Remove define.
5003 (define_command): Use string_printf.
5004 (document_command): Likewise.
5005 * breakpoint.c (commands_command_1): Update.
5006
1263a9d5
TT
50072018-05-04 Tom Tromey <tom@tromey.com>
5008
5009 * top.c (execute_command): Update.
5010 * cli/cli-script.h (print_command_lines): Now varargs.
5011 * cli/cli-script.c (print_command_lines): Now varargs.
5012 (execute_control_command_1) <case while_control, case if_control>:
5013 Update.
5014
12973681
TT
50152018-05-04 Tom Tromey <tom@tromey.com>
5016
5017 * tracepoint.c (all_tracepoint_actions): Rename from
5018 all_tracepoint_actions_and_cleanup. Change return type.
5019 (actions_command, encode_actions_1, encode_actions)
5020 (trace_dump_actions, tdump_command): Update.
5021 * remote.c (remote_download_command_source): Update.
5022 * python/python.c (gdbpy_eval_from_control_command)
5023 (python_command, python_interactive_command): Update.
5024 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
5025 * guile/guile.c (guile_command)
5026 (gdbscm_eval_from_control_command, guile_command): Update.
5027 * compile/compile.c (compile_code_command)
5028 (compile_print_command, compile_to_object): Update.
5029 * cli/cli-script.h (struct command_lines_deleter): New.
5030 (counted_command_line): New typedef.
5031 (struct command_line): Add constructor, destructor.
5032 <body_list>: Remove.
5033 <body_list_0, body_list_1>: New members.
5034 (command_line_up): Remove typedef.
5035 (read_command_lines, read_command_lines_1, get_command_line):
5036 Update.
5037 (copy_command_lines): Don't declare.
5038 * cli/cli-script.c (build_command_line): Use "new".
5039 (get_command_line): Return counted_command_line.
5040 (print_command_lines, execute_user_command)
5041 (execute_control_command_1, while_command, if_command): Update.
5042 (realloc_body_list): Remove.
5043 (process_next_line, recurse_read_control_structure): Update.
5044 (read_command_lines, read_command_lines_1): Return counted_command_line.
5045 (free_command_lines): Use "delete".
5046 (copy_command_lines): Remove.
5047 (define_command, document_command, show_user_1): Update.
5048 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
5049 a counted_command_line.
5050 * breakpoint.h (counted_command_line): Remove typedef.
5051 (breakpoint_set_commands): Update.
5052 * breakpoint.c (check_no_tracepoint_commands)
5053 (validate_commands_for_breakpoint): Update.
5054 (breakpoint_set_commands): Change commands to be a
5055 counted_command_line.
5056 (commands_command_1, update_dprintf_command_list)
5057 (create_tracepoint_from_upload): Update.
5058
e2fc72e2
TT
50592018-05-04 Tom Tromey <tom@tromey.com>
5060
5061 * cli/cli-decode.h (cmd_list_element): New constructor.
5062 (~cmd_list_element): New destructor.
5063 (struct cmd_list_element): Add initializers.
5064 * cli/cli-decode.c (do_add_cmd): Use "new".
5065 (delete_cmd): Use "delete".
5066
a3b60e45
JK
50672018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
5068 Pedro Alves <palves@redhat.com>
5069
5070 PR breakpoints/19806 and support for PR external/20207.
5071 * NEWS: Mention Aarch64 watchpoint improvements.
5072 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
5073 watchpoints and PR external/20207 watchpoints.
5074 * nat/aarch64-linux-hw-point.c
5075 (kernel_supports_any_contiguous_range): New.
5076 (aarch64_watchpoint_offset): New.
5077 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
5078 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
5079 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
5080 (aarch64_align_watchpoint): New parameters aligned_offset_p and
5081 next_addr_orig_p. Support PR external/20207 watchpoints.
5082 (aarch64_downgrade_regs): New.
5083 (aarch64_dr_state_insert_one_point): New parameters offset and
5084 addr_orig.
5085 (aarch64_dr_state_remove_one_point): Likewise.
5086 (aarch64_handle_breakpoint): Update caller.
5087 (aarch64_handle_aligned_watchpoint): Likewise.
5088 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
5089 aligned_offset.
5090 (aarch64_linux_set_debug_regs): Remove const from state. Call
5091 aarch64_downgrade_regs.
5092 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
5093 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
5094 (DR_CONTROL_MASK): ... this.
5095 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
5096 (unsigned int aarch64_watchpoint_offset): New prototype.
5097 (aarch64_linux_set_debug_regs): Remove const from state.
5098 * utils.c (align_up, align_down): Move to ...
5099 * common/common-utils.c (align_up, align_down): ... here.
5100 * utils.h (align_up, align_down): Move to ...
5101 * common/common-utils.h (align_up, align_down): ... here.
5102
05bc7456
JB
51032018-05-04 Joel Brobecker <brobecker@adacore.com>
5104
5105 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
5106 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
5107 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
5108 Re-implement to match the ABI as summarized in GCC's
5109 gcc/config/sparc/sparc.c. All callers updated.
5110 (sparc32_store_arguments): Remove assertion.
5111
2f433492
TT
51122018-05-04 Tom Tromey <tom@tromey.com>
5113
5114 * printcmd.c: Don't include tui.h.
5115 (decode_format): Use skip_spaces.
5116
9be2ae8f
TT
51172018-05-04 Tom Tromey <tom@tromey.com>
5118
5119 PR gdb/22619:
5120 * printcmd.c (last_count): New global.
5121 (x_command): Use saved count when repeating.
5122
f0b3976b
TT
51232018-05-04 Tom Tromey <tom@tromey.com>
5124
5125 * nto-procfs.c (do_closedir_cleanup): Remove.
5126 (procfs_pidlist): Use gdb_dir_up.
5127 * procfs.c (do_closedir_cleanup): Remove.
5128 (proc_update_threads): Use gdb_dir_up.
5129 * common/filestuff.h (struct gdb_dir_deleter): New.
5130 (gdb_dir_up): New typedef.
5131
862d101a
TT
51322018-05-04 Tom Tromey <tom@tromey.com>
5133
5134 * ada-lang.c (print_mention_exception): Use std::string.
5135
cb7de75e
TT
51362018-05-04 Tom Tromey <tom@tromey.com>
5137
5138 * ada-lang.c (create_excep_cond_exprs): Update.
5139 (ada_exception_catchpoint_cond_string): Use std::string.
5140
49d83361
TT
51412018-05-04 Tom Tromey <tom@tromey.com>
5142
5143 * ada-lang.c (xget_renaming_scope): Return std::string.
5144 (old_renaming_is_invisible): Update.
5145
ade72a34
TT
51462018-05-04 Tom Tromey <tom@tromey.com>
5147
5148 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
5149 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
5150
2be4d7f0
UW
51512018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
5152
5153 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
5154
69b6ecb0
TT
51552018-05-04 Tom Tromey <tom@tromey.com>
5156
5157 * remote.c (remote_query_supported_append): Change type.
5158 (remote_check_symbols): Update.
5159
bf27f0e2
PP
51602018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
5161
5162 PR gdb/11420
5163 * configure.ac: Prepend libpython.
5164 * python/python-config.py: Likewise.
5165 * configure: Regenerate.
5166
4ea17de8
SM
51672018-05-03 Simon Marchi <simon.marchi@ericsson.com>
5168
5169 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
5170
bd732259
PA
51712018-05-03 Pedro Alves <palves@redhat.com>
5172
5173 * s390-linux-nat.c
5174 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
5175 override. Write 'true' instead of '1'.
5176 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
5177 declaration.
5178
d9f719f1
PA
51792018-05-02 Pedro Alves <palves@redhat.com>
5180
5181 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
5182 add_inf_child_target.
5183 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
5184 add_inf_child_target.
5185 * aix-thread.c (aix_thread_target_info): New.
5186 (aix_thread_target) <shortname, longname, doc>: Delete.
5187 <info>: New.
5188 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
5189 add_inf_child_target.
5190 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
5191 add_inf_child_target.
5192 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
5193 add_inf_child_target.
5194 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
5195 add_inf_child_target.
5196 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
5197 add_inf_child_target.
5198 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
5199 add_inf_child_target.
5200 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
5201 add_inf_child_target.
5202 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
5203 add_inf_child_target.
5204 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
5205 add_inf_child_target.
5206 * bfd-target.c (target_bfd_target_info): New.
5207 (target_bfd) <shortname, longname, doc>: Delete.
5208 <info>: New.
5209 * bsd-kvm.c (bsd_kvm_target_info): New.
5210 (bsd_kvm_target) <shortname, longname, doc>: Delete.
5211 <info>: New.
5212 (bsd_kvm_target::open): Rename to ...
5213 (bsd_kvm_target_open): ... this. Adjust.
5214 * bsd-uthread.c (bsd_uthread_target_info): New.
5215 (bsd_uthread_target) <shortname, longname, doc>: Delete.
5216 <info>: New.
5217 * corefile.c (core_file_command): Adjust.
5218 * corelow.c (core_target_info): New.
5219 (core_target) <shortname, longname, doc>: Delete.
5220 <info>: New.
5221 (core_target::open): Rename to ...
5222 (core_target_open): ... this. Adjust.
5223 * ctf.c (ctf_target_info): New.
5224 (ctf_target) <shortname, longname, doc>: Delete.
5225 <info>: New.
5226 (ctf_target::open): Rename to ...
5227 (ctf_target_open): ... this.
5228 (_initialize_ctf): Adjust.
5229 * exec.c (exec_target_info): New.
5230 (exec_target) <shortname, longname, doc>: Delete.
5231 <info>: New.
5232 (exec_target::open): Rename to ...
5233 (exec_target_open): ... this.
5234 * gdbcore.h (core_target_open): Declare.
5235 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
5236 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
5237 add_inf_child_target.
5238 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
5239 add_inf_child_target.
5240 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
5241 add_inf_child_target.
5242 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
5243 add_inf_child_target.
5244 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
5245 add_inf_child_target.
5246 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
5247 add_inf_child_target.
5248 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
5249 add_inf_child_target.
5250 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
5251 add_inf_child_target.
5252 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
5253 add_inf_child_target.
5254 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
5255 add_inf_child_target.
5256 * inf-child.c (inf_child_target_info): New.
5257 (inf_child_target::info): New.
5258 (inf_child_open_target): Remove 'target' parameter. Use
5259 get_native_target instead.
5260 (inf_child_target::open): Delete.
5261 (add_inf_child_target): New.
5262 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
5263 Delete.
5264 <info>: New.
5265 (add_inf_child_target): Declare.
5266 (inf_child_open_target): Declare.
5267 * linux-thread-db.c (thread_db_target_info): New.
5268 (thread_db_target) <shortname, longname, doc>: Delete.
5269 <info>: New.
5270 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
5271 add_inf_child_target.
5272 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
5273 add_inf_child_target.
5274 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
5275 add_inf_child_target.
5276 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
5277 add_inf_child_target.
5278 * make-target-delegates (print_class): Adjust.
5279 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
5280 add_inf_child_target.
5281 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
5282 add_inf_child_target.
5283 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
5284 add_inf_child_target.
5285 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
5286 add_inf_child_target.
5287 * nto-procfs.c (nto_native_target_info): New.
5288 (nto_procfs_target_native) <shortname, longname, doc>:
5289 Delete.
5290 <info>: New.
5291 (nto_procfs_target_info): New.
5292 (nto_procfs_target_procfs) <shortname, longname, doc>:
5293 Delete.
5294 <info>: New.
5295 (init_procfs_targets): Adjust.
5296 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
5297 add_inf_child_target.
5298 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
5299 add_inf_child_target.
5300 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
5301 add_inf_child_target.
5302 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
5303 add_inf_child_target.
5304 * ravenscar-thread.c (ravenscar_target_info): New.
5305 (ravenscar_thread_target) <shortname, longname, doc>:
5306 Delete.
5307 <info>: New.
5308 * record-btrace.c (record_btrace_target_info):
5309 (record_btrace_target) <shortname, longname, doc>: Delete.
5310 <info>: New.
5311 (record_btrace_target::open): Rename to ...
5312 (record_btrace_target_open): ... this. Adjust.
5313 * record-full.c (record_longname, record_doc): New.
5314 (record_full_base_target) <shortname, longname, doc>: Delete.
5315 <info>: New.
5316 (record_full_target_info): New.
5317 (record_full_target): <shortname>: Delete.
5318 <info>: New.
5319 (record_full_core_open_1, record_full_open_1): Update comments.
5320 (record_full_base_target::open): Rename to ...
5321 (record_full_open): ... this.
5322 (cmd_record_full_restore): Update.
5323 (_initialize_record_full): Update.
5324 * remote-sim.c (remote_sim_target_info): New.
5325 (gdbsim_target) <shortname, longname, doc>: Delete.
5326 <info>: New.
5327 (gdbsim_target::open): Rename to ...
5328 (gdbsim_target_open): ... this.
5329 (_initialize_remote_sim): Adjust.
5330 * remote.c (remote_doc): New.
5331 (remote_target_info): New.
5332 (remote_target) <shortname, longname, doc>: Delete.
5333 <info>: New.
5334 (extended_remote_target_info): New.
5335 (extended_remote_target) <shortname, longname, doc>: Delete.
5336 <info>: New.
5337 (remote_target::open_1): Make static. Adjust.
5338 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
5339 * s390-linux-nat.c (_initialize_s390_nat): Use
5340 add_inf_child_target.
5341 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
5342 add_inf_child_target.
5343 * sol-thread.c (thread_db_target_info): New.
5344 (sol_thread_target) <shortname, longname, doc>: Delete.
5345 <info>: New.
5346 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
5347 add_inf_child_target.
5348 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
5349 add_inf_child_target.
5350 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
5351 add_inf_child_target.
5352 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
5353 add_inf_child_target.
5354 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
5355 add_inf_child_target.
5356 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
5357 add_inf_child_target.
5358 * spu-linux-nat.c (_initialize_spu_nat): Use
5359 add_inf_child_target.
5360 * spu-multiarch.c (spu_multiarch_target_info): New.
5361 (spu_multiarch_target) <shortname, longname, doc>: Delete.
5362 <info>: New.
5363 * target-delegates.c: Regenerate.
5364 * target.c: Include <unordered_map>.
5365 (target_ops_p): Delete.
5366 (DEF_VEC_P(target_ops_p)): Delete.
5367 (target_factories): New.
5368 (test_target_info): New.
5369 (test_target_ops::info): New.
5370 (open_target): Adjust to use target_factories.
5371 (add_target_with_completer): Rename to ...
5372 (add_target): ... this. Change prototype. Register target_info
5373 and open callback in target_factories. Register target_info in
5374 command context instead of target_ops.
5375 (add_target): Delete old implementation.
5376 (add_deprecated_target_alias): Change prototype. Adjust.
5377 (the_native_target): New.
5378 (set_native_target, get_native_target): New.
5379 (find_default_run_target): Use the_native_target.
5380 (find_attach_target, find_run_target): Simplify.
5381 (target_ops::open): Delete.
5382 (dummy_target_info): New.
5383 (dummy_target::shortname, dummy_target::longname)
5384 (dummy_target::doc): Delete.
5385 (dummy_target::info): New.
5386 (debug_target::shortname, debug_target::longname)
5387 (debug_target::doc): Delete.
5388 (debug_target::info): New.
5389 * target.h (struct target_info): New.
5390 (target_ops::~target_ops): Add comment.
5391 (target_ops::info): New.
5392 (target_ops::shortname, target_ops::longname, target_ops::doc): No
5393 longer virtual. Implement in terms of target_info.
5394 (set_native_target, get_native_target): Declare.
5395 (target_open_ftype): New.
5396 (add_target, add_target_with_completer)
5397 (add_deprecated_target_alias): Change prototype.
5398 (test_target) <shortname, longname, doc>: Delete.
5399 <info>: New.
5400 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
5401 add_inf_child_target.
5402 * tracefile-tfile.c (tfile_target_info): New.
5403 (tfile_target) <shortname, longname, doc>: Delete.
5404 <info>: New.
5405 (tfile_target::open): Rename to ...
5406 (tfile_target_open): ... this.
5407 (_initialize_tracefile_tfile): Adjust.
5408 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
5409 add_inf_child_target.
5410 * windows-nat.c (_initialize_windows_nat): Use
5411 add_inf_child_target.
5412 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
5413 add_inf_child_target.
5414
135340af
PA
54152018-05-02 Pedro Alves <palves@redhat.com>
5416
5417 * linux-nat.h (linux_nat_target) <low_new_thread,
5418 low_delete_thread, low_new_fork, low_forget_process,
5419 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
5420 New virtual methods.
5421 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5422 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
5423 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
5424 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5425 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
5426 Delete.
5427 * linux-fork.c (delete_fork): Adjust to call low method.
5428 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
5429 (linux_nat_new_fork, linux_nat_forget_process_hook)
5430 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
5431 (linux_nat_status_is_event):
5432 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
5433 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
5434 to call low method.
5435 (sigtrap_is_event): Rename to ...
5436 (linux_nat_target::low_status_is_event): ... this.
5437 (linux_nat_set_status_is_event): Delete.
5438 (save_stop_reason, linux_nat_wait_1)
5439 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
5440 low methods.
5441 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
5442 (linux_nat_set_new_fork, linux_nat_set_forget_process)
5443 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
5444 (linux_nat_set_prepare_to_resume): Delete.
5445 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
5446 low virtual methods.
5447 * amd64-linux-nat.c: Likewise.
5448 * arm-linux-nat.c: Likewise.
5449 * i386-linux-nat.c: Likewise.
5450 * ia64-linux-nat.c: Likewise.
5451 * mips-linux-nat.c: Likewise.
5452 * ppc-linux-nat.c: Likewise.
5453 * s390-linux-nat.c: Likewise.
5454 * sparc64-linux-nat.c: Likewise.
5455 * x86-linux-nat.c: Likewise.
5456 * x86-linux-nat.h: Include "nat/x86-linux.h".
5457 (x86_linux_nat_target) <low_new_fork, low_forget_process,
5458 low_prepare_to_resume, low_new_thread, low_delete_thread>:
5459 Override methods.
5460
57810aa7
PA
54612018-05-02 Pedro Alves <palves@redhat.com>
5462
5463 * target.h (target_ops)
5464 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
5465 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
5466 stopped_by_watchpoint, have_continuable_watchpoint,
5467 stopped_data_address, watchpoint_addr_within_range,
5468 can_accel_watchpoint_condition, can_run, thread_alive,
5469 has_all_memory, has_memory, has_stack, has_registers,
5470 has_execution, can_async_p, is_async_p, supports_non_stop,
5471 always_non_stop_p, can_execute_reverse, supports_multi_process,
5472 supports_enable_disable_tracepoint,
5473 supports_disable_randomization, supports_string_tracing,
5474 supports_evaluation_of_breakpoint_conditions,
5475 can_run_breakpoint_commands, filesystem_is_local,
5476 can_download_tracepoint, get_trace_state_variable_value,
5477 set_trace_notes, get_tib_address, use_agent, can_use_agent,
5478 record_is_replaying, record_will_replay,
5479 augmented_libraries_svr4_read>: Adjust to return bool.
5480 * aarch64-linux-nat.c: All implementations adjusted.
5481 * aix-thread.c: All implementations adjusted.
5482 * arm-linux-nat.c: All implementations adjusted.
5483 * breakpoint.c: All implementations adjusted.
5484 * bsd-kvm.c: All implementations adjusted.
5485 * bsd-uthread.c: All implementations adjusted.
5486 * corelow.c: All implementations adjusted.
5487 * ctf.c: All implementations adjusted.
5488 * darwin-nat.c: All implementations adjusted.
5489 * darwin-nat.h: All implementations adjusted.
5490 * exec.c: All implementations adjusted.
5491 * fbsd-nat.c: All implementations adjusted.
5492 * fbsd-nat.h: All implementations adjusted.
5493 * gnu-nat.c: All implementations adjusted.
5494 * gnu-nat.h: All implementations adjusted.
5495 * go32-nat.c: All implementations adjusted.
5496 * ia64-linux-nat.c: All implementations adjusted.
5497 * inf-child.c: All implementations adjusted.
5498 * inf-child.h: All implementations adjusted.
5499 * inf-ptrace.c: All implementations adjusted.
5500 * inf-ptrace.h: All implementations adjusted.
5501 * linux-nat.c: All implementations adjusted.
5502 * linux-nat.h: All implementations adjusted.
5503 * mips-linux-nat.c: All implementations adjusted.
5504 * nto-procfs.c: All implementations adjusted.
5505 * ppc-linux-nat.c: All implementations adjusted.
5506 * procfs.c: All implementations adjusted.
5507 * ravenscar-thread.c: All implementations adjusted.
5508 * record-btrace.c: All implementations adjusted.
5509 * record-full.c: All implementations adjusted.
5510 * remote-sim.c: All implementations adjusted.
5511 * remote.c: All implementations adjusted.
5512 * s390-linux-nat.c: All implementations adjusted.
5513 * sol-thread.c: All implementations adjusted.
5514 * spu-multiarch.c: All implementations adjusted.
5515 * target-delegates.c: All implementations adjusted.
5516 * target.c: All implementations adjusted.
5517 * target.h: All implementations adjusted.
5518 * tracefile-tfile.c: All implementations adjusted.
5519 * tracefile.c: All implementations adjusted.
5520 * tracefile.h: All implementations adjusted.
5521 * windows-nat.c: All implementations adjusted.
5522 * x86-linux-nat.h: All implementations adjusted.
5523 * x86-nat.h: All implementations adjusted.
5524
ad6a4e2d
PA
55252018-05-02 Pedro Alves <palves@redhat.com>
5526
5527 * make-target-delegates (scan_target_h): Don't trim lines here.
5528 Replace sequences of tabs and/or whitespace with a single
5529 whitespace.
5530 (top level, parsing methods): Trim each line before processing it
5531 here.
5532
f6ac5f3d
PA
55332018-05-02 Pedro Alves <palves@redhat.com>
5534 John Baldwin <jhb@freebsd.org>
5535
5536 * target.h (enum strata) <debug_stratum>: New.
5537 (struct target_ops) <all delegation methods>: Replace by C++
5538 virtual methods, and drop "to_" prefix. All references updated
5539 throughout.
5540 <to_shortname, to_longname, to_doc, to_data,
5541 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
5542 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
5543 virtual methods. All references updated throughout.
5544 <can_attach, supports_terminal_ours, can_create_inferior,
5545 get_thread_control_capabilities, attach_no_wait>: New
5546 virtual methods.
5547 <insert_breakpoint, remove_breakpoint>: Now
5548 TARGET_DEFAULT_NORETURN methods.
5549 <info_proc>: Now returns bool.
5550 <to_magic>: Delete.
5551 (OPS_MAGIC): Delete.
5552 (current_target): Delete. All references replaced by references
5553 to ...
5554 (target_stack): ... this. New.
5555 (target_shortname, target_longname): Adjust.
5556 (target_can_run): Now a function declaration.
5557 (default_child_has_all_memory, default_child_has_memory)
5558 (default_child_has_stack, default_child_has_registers)
5559 (default_child_has_execution): Remove target_ops parameter.
5560 (complete_target_initialization): Delete.
5561 (memory_breakpoint_target): New template class.
5562 (test_target_ops): Refactor as a C++ class with virtual methods.
5563 * make-target-delegates (NAME_PART): Tighten.
5564 (POINTER_PART, CP_SYMBOL): New.
5565 (SIMPLE_RETURN_PART): Reimplement.
5566 (VEC_RETURN_PART): Expect less.
5567 (RETURN_PART, VIRTUAL_PART): New.
5568 (METHOD): Adjust to C++ virtual methods.
5569 (scan_target_h): Remove reference to C99.
5570 (dname): Output "target_ops::" prefix.
5571 (write_function_header): Adjust to output a C++ class method.
5572 (write_declaration): New.
5573 (write_delegator): Adjust to output a C++ class method.
5574 (tdname): Output "dummy_target::" prefix.
5575 (write_tdefault, write_debugmethod): Adjust to output a C++ class
5576 method.
5577 (tdefault_names, debug_names): Delete.
5578 (return_types, tdefaults, styles, argtypes_array): New.
5579 (top level): All methods are delegators.
5580 (print_class): New.
5581 (top level): Print dummy_target and debug_target classes.
5582 * target-delegates.c: Regenerate.
5583 * target-debug.h (target_debug_print_enum_info_proc_what)
5584 (target_debug_print_thread_control_capabilities)
5585 (target_debug_print_thread_info_p): New.
5586 * target.c (dummy_target): Delete.
5587 (the_dummy_target, the_debug_target): New.
5588 (target_stack): Now extern.
5589 (set_targetdebug): Push/unpush debug target.
5590 (default_child_has_all_memory, default_child_has_memory)
5591 (default_child_has_stack, default_child_has_registers)
5592 (default_child_has_execution): Remove target_ops parameter.
5593 (complete_target_initialization): Delete.
5594 (add_target_with_completer): No longer call
5595 complete_target_initialization.
5596 (target_supports_terminal_ours): Use regular delegation.
5597 (update_current_target): Delete.
5598 (push_target): No longer check magic number. Don't call
5599 update_current_target.
5600 (unpush_target): Don't call update_current_target.
5601 (target_is_pushed): No longer check magic number.
5602 (target_require_runnable): Skip for all stratums over
5603 process_stratum.
5604 (target_ops::info_proc): New.
5605 (target_info_proc): Use find_target_at and
5606 find_default_run_target.
5607 (target_supports_disable_randomization): Use regular delegation.
5608 (target_get_osdata): Use find_target_at.
5609 (target_ops::open, target_ops::close, target_ops::can_attach)
5610 (target_ops::attach, target_ops::can_create_inferior)
5611 (target_ops::create_inferior, target_ops::can_run)
5612 (target_can_run): New.
5613 (default_fileio_target): Use regular delegation.
5614 (target_ops::fileio_open, target_ops::fileio_pwrite)
5615 (target_ops::fileio_pread, target_ops::fileio_fstat)
5616 (target_ops::fileio_close, target_ops::fileio_unlink)
5617 (target_ops::fileio_readlink): New.
5618 (target_fileio_open_1, target_fileio_unlink)
5619 (target_fileio_readlink): Always call the target method. Handle
5620 FILEIO_ENOSYS.
5621 (return_zero, return_zero_has_execution): Delete.
5622 (init_dummy_target): Delete.
5623 (dummy_target::dummy_target, dummy_target::shortname)
5624 (dummy_target::longname, dummy_target::doc)
5625 (debug_target::debug_target, debug_target::shortname)
5626 (debug_target::longname, debug_target::doc): New.
5627 (target_supports_delete_record): Use regular delegation.
5628 (setup_target_debug): Delete.
5629 (maintenance_print_target_stack): Skip debug_stratum.
5630 (initialize_targets): Instantiate the_dummy_target and
5631 the_debug_target.
5632 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
5633 use target_stack.
5634 (target_auxv_search, fprint_target_auxv): Adjust.
5635 (info_auxv_command): Adjust to use target_stack.
5636 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
5637 * exceptions.c (print_flush): Handle a NULL target_stack.
5638 * regcache.c (target_ops_no_register): Refactor as class with
5639 virtual methods.
5640
5641 * exec.c (exec_target): New class.
5642 (exec_ops): Now an exec_target.
5643 (exec_open, exec_close_1, exec_get_section_table)
5644 (exec_xfer_partial, exec_files_info, exec_has_memory)
5645 (exec_make_note_section): Refactor as exec_target methods.
5646 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
5647 Delete.
5648 (exec_target::find_memory_regions): New.
5649 (_initialize_exec): Don't call init_exec_ops.
5650 * gdbcore.h (exec_file_clear): Delete.
5651
5652 * corefile.c (core_target): Delete.
5653 (core_file_command): Adjust.
5654 * corelow.c (core_target): New class.
5655 (the_core_target): New.
5656 (core_close): Remove target_ops parameter.
5657 (core_close_cleanup): Adjust.
5658 (core_target::close): New.
5659 (core_open, core_detach, get_core_registers, core_files_info)
5660 (core_xfer_partial, core_thread_alive, core_read_description)
5661 (core_pid_to_str, core_thread_name, core_has_memory)
5662 (core_has_stack, core_has_registers, core_info_proc): Rework as
5663 core_target methods.
5664 (ignore, core_remove_breakpoint, init_core_ops): Delete.
5665 (_initialize_corelow): Initialize the_core_target.
5666 * gdbcore.h (core_target): Delete.
5667 (the_core_target): New.
5668
5669 * ctf.c: (ctf_target): New class.
5670 (ctf_ops): Now a ctf_target.
5671 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
5672 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
5673 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
5674 methods.
5675 (init_ctf_ops): Delete.
5676 (_initialize_ctf): Don't call it.
5677 * tracefile-tfile.c (tfile_target): New class.
5678 (tfile_ops): Now a tfile_target.
5679 (tfile_open, tfile_close, tfile_files_info)
5680 (tfile_get_tracepoint_status, tfile_trace_find)
5681 (tfile_fetch_registers, tfile_xfer_partial)
5682 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
5683 Refactor as tfile_target methods.
5684 (tfile_xfer_partial_features): Remove target_ops parameter.
5685 (init_tfile_ops): Delete.
5686 (_initialize_tracefile_tfile): Don't call it.
5687 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
5688 (tracefile_has_stack, tracefile_has_registers)
5689 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
5690 tracefile_target methods.
5691 (init_tracefile_ops): Delete.
5692 (tracefile_target::tracefile_target): New.
5693 * tracefile.h: Include "target.h".
5694 (tracefile_target): New class.
5695 (init_tracefile_ops): Delete.
5696
5697 * spu-multiarch.c (spu_multiarch_target): New class.
5698 (spu_ops): Now a spu_multiarch_target.
5699 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
5700 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
5701 (spu_search_memory, spu_mourn_inferior): Refactor as
5702 spu_multiarch_target methods.
5703 (init_spu_ops): Delete.
5704 (_initialize_spu_multiarch): Remove references to init_spu_ops,
5705 complete_target_initialization.
5706
5707 * ravenscar-thread.c (ravenscar_thread_target): New class.
5708 (ravenscar_ops): Now a ravenscar_thread_target.
5709 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
5710 (ravenscar_thread_alive, ravenscar_pid_to_str)
5711 (ravenscar_fetch_registers, ravenscar_store_registers)
5712 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
5713 (ravenscar_stopped_by_hw_breakpoint)
5714 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
5715 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
5716 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
5717 methods.
5718 (init_ravenscar_thread_ops): Delete.
5719 (_initialize_ravenscar): Remove references to
5720 init_ravenscar_thread_ops and complete_target_initialization.
5721
5722 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
5723 (bsd_uthread_target): New class.
5724 (bsd_uthread_ops): Now a bsd_uthread_target.
5725 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
5726 (bsd_uthread_close, bsd_uthread_mourn_inferior)
5727 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
5728 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
5729 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
5730 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
5731 (bsd_uthread_target): Delete function.
5732 (_initialize_bsd_uthread): Remove reference to
5733 complete_target_initialization.
5734
5735 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
5736 (target_bfd): ... this new class.
5737 (target_bfd_xfer_partial, target_bfd_get_section_table)
5738 (target_bfd_close): Refactor as target_bfd methods.
5739 (target_bfd::~target_bfd): New.
5740 (target_bfd_reopen): Adjust.
5741 (target_bfd::close): New.
5742
5743 * record-btrace.c (record_btrace_target): New class.
5744 (record_btrace_ops): Now a record_btrace_target.
5745 (record_btrace_open, record_btrace_stop_recording)
5746 (record_btrace_disconnect, record_btrace_close)
5747 (record_btrace_async, record_btrace_info)
5748 (record_btrace_insn_history, record_btrace_insn_history_range)
5749 (record_btrace_insn_history_from, record_btrace_call_history)
5750 (record_btrace_call_history_range)
5751 (record_btrace_call_history_from, record_btrace_record_method)
5752 (record_btrace_is_replaying, record_btrace_will_replay)
5753 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
5754 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
5755 (record_btrace_store_registers, record_btrace_prepare_to_store)
5756 (record_btrace_to_get_unwinder)
5757 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
5758 (record_btrace_commit_resume, record_btrace_wait)
5759 (record_btrace_stop, record_btrace_can_execute_reverse)
5760 (record_btrace_stopped_by_sw_breakpoint)
5761 (record_btrace_supports_stopped_by_sw_breakpoint)
5762 (record_btrace_stopped_by_hw_breakpoint)
5763 (record_btrace_supports_stopped_by_hw_breakpoint)
5764 (record_btrace_update_thread_list, record_btrace_thread_alive)
5765 (record_btrace_goto_begin, record_btrace_goto_end)
5766 (record_btrace_goto, record_btrace_stop_replaying_all)
5767 (record_btrace_execution_direction)
5768 (record_btrace_prepare_to_generate_core)
5769 (record_btrace_done_generating_core): Refactor as
5770 record_btrace_target methods.
5771 (init_record_btrace_ops): Delete.
5772 (_initialize_record_btrace): Remove reference to
5773 init_record_btrace_ops.
5774 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
5775 the execution_direction global.
5776 (record_full_base_target, record_full_target)
5777 (record_full_core_target): New classes.
5778 (record_full_ops): Now a record_full_target.
5779 (record_full_core_ops): Now a record_full_core_target.
5780 (record_full_target::detach, record_full_target::disconnect)
5781 (record_full_core_target::disconnect)
5782 (record_full_target::mourn_inferior, record_full_target::kill):
5783 New.
5784 (record_full_open, record_full_close, record_full_async): Refactor
5785 as methods of the record_full_base_target class.
5786 (record_full_resume, record_full_commit_resume): Refactor
5787 as methods of the record_full_target class.
5788 (record_full_wait, record_full_stopped_by_watchpoint)
5789 (record_full_stopped_data_address)
5790 (record_full_stopped_by_sw_breakpoint)
5791 (record_full_supports_stopped_by_sw_breakpoint)
5792 (record_full_stopped_by_hw_breakpoint)
5793 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
5794 methods of the record_full_base_target class.
5795 (record_full_store_registers, record_full_xfer_partial)
5796 (record_full_insert_breakpoint, record_full_remove_breakpoint):
5797 Refactor as methods of the record_full_target class.
5798 (record_full_can_execute_reverse, record_full_get_bookmark)
5799 (record_full_goto_bookmark, record_full_execution_direction)
5800 (record_full_record_method, record_full_info, record_full_delete)
5801 (record_full_is_replaying, record_full_will_replay)
5802 (record_full_goto_begin, record_full_goto_end, record_full_goto)
5803 (record_full_stop_replaying): Refactor as methods of the
5804 record_full_base_target class.
5805 (record_full_core_resume, record_full_core_kill)
5806 (record_full_core_fetch_registers)
5807 (record_full_core_prepare_to_store)
5808 (record_full_core_store_registers, record_full_core_xfer_partial)
5809 (record_full_core_insert_breakpoint)
5810 (record_full_core_remove_breakpoint)
5811 (record_full_core_has_execution): Refactor
5812 as methods of the record_full_core_target class.
5813 (record_full_base_target::supports_delete_record): New.
5814 (init_record_full_ops): Delete.
5815 (init_record_full_core_ops): Delete.
5816 (record_full_save): Refactor as method of the
5817 record_full_base_target class.
5818 (_initialize_record_full): Remove references to
5819 init_record_full_ops and init_record_full_core_ops.
5820
5821 * remote.c (remote_target, extended_remote_target): New classes.
5822 (remote_ops): Now a remote_target.
5823 (extended_remote_ops): Now an extended_remote_target.
5824 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
5825 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
5826 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
5827 (remote_pass_signals, remote_set_syscall_catchpoint)
5828 (remote_program_signals, )
5829 (remote_thread_always_alive): Remove target_ops parameter.
5830 (remote_thread_alive, remote_thread_name)
5831 (remote_update_thread_list, remote_threads_extra_info)
5832 (remote_static_tracepoint_marker_at)
5833 (remote_static_tracepoint_markers_by_strid)
5834 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
5835 (remote_open): Refactor as methods of remote_target.
5836 (extended_remote_open, extended_remote_detach)
5837 (extended_remote_attach, extended_remote_post_attach):
5838 (extended_remote_supports_disable_randomization)
5839 (extended_remote_create_inferior): : Refactor as method of
5840 extended_remote_target.
5841 (remote_set_permissions, remote_open_1, remote_detach)
5842 (remote_follow_fork, remote_follow_exec, remote_disconnect)
5843 (remote_resume, remote_commit_resume, remote_stop)
5844 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
5845 (remote_terminal_ours, remote_wait, remote_fetch_registers)
5846 (remote_prepare_to_store, remote_store_registers)
5847 (remote_flash_erase, remote_flash_done, remote_files_info)
5848 (remote_kill, remote_mourn, remote_insert_breakpoint)
5849 (remote_remove_breakpoint, remote_insert_watchpoint)
5850 (remote_watchpoint_addr_within_range)
5851 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
5852 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
5853 (remote_supports_stopped_by_sw_breakpoint)
5854 (remote_stopped_by_hw_breakpoint)
5855 (remote_supports_stopped_by_hw_breakpoint)
5856 (remote_stopped_by_watchpoint, remote_stopped_data_address)
5857 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
5858 (remote_verify_memory): Refactor as methods of remote_target.
5859 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
5860 parameter.
5861 (remote_xfer_partial, remote_get_memory_xfer_limit)
5862 (remote_search_memory, remote_rcmd, remote_memory_map)
5863 (remote_pid_to_str, remote_get_thread_local_address)
5864 (remote_get_tib_address, remote_read_description): Refactor as
5865 methods of remote_target.
5866 (remote_target::fileio_open, remote_target::fileio_pwrite)
5867 (remote_target::fileio_pread, remote_target::fileio_close): New.
5868 (remote_hostio_readlink, remote_hostio_fstat)
5869 (remote_filesystem_is_local, remote_can_execute_reverse)
5870 (remote_supports_non_stop, remote_supports_disable_randomization)
5871 (remote_supports_multi_process, remote_supports_cond_breakpoints)
5872 (remote_supports_enable_disable_tracepoint)
5873 (remote_supports_string_tracing)
5874 (remote_can_run_breakpoint_commands, remote_trace_init)
5875 (remote_download_tracepoint, remote_can_download_tracepoint)
5876 (remote_download_trace_state_variable, remote_enable_tracepoint)
5877 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
5878 (remote_trace_start, remote_get_trace_status)
5879 (remote_get_tracepoint_status, remote_trace_stop)
5880 (remote_trace_find, remote_get_trace_state_variable_value)
5881 (remote_save_trace_data, remote_get_raw_trace_data)
5882 (remote_set_disconnected_tracing, remote_core_of_thread)
5883 (remote_set_circular_trace_buffer, remote_traceframe_info)
5884 (remote_get_min_fast_tracepoint_insn_len)
5885 (remote_set_trace_buffer_size, remote_set_trace_notes)
5886 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
5887 (remote_disable_btrace, remote_teardown_btrace)
5888 (remote_read_btrace, remote_btrace_conf)
5889 (remote_augmented_libraries_svr4_read, remote_load)
5890 (remote_pid_to_exec_file, remote_can_do_single_step)
5891 (remote_execution_direction, remote_thread_handle_to_thread_info):
5892 Refactor as methods of remote_target.
5893 (init_remote_ops, init_extended_remote_ops): Delete.
5894 (remote_can_async_p, remote_is_async_p, remote_async)
5895 (remote_thread_events, remote_upload_tracepoints)
5896 (remote_upload_trace_state_variables): Refactor as methods of
5897 remote_target.
5898 (_initialize_remote): Remove references to init_remote_ops and
5899 init_extended_remote_ops.
5900
5901 * remote-sim.c (gdbsim_target): New class.
5902 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
5903 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
5904 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
5905 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
5906 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
5907 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
5908 Refactor as methods of gdbsim_target.
5909 (gdbsim_ops): Now a gdbsim_target.
5910 (init_gdbsim_ops): Delete.
5911 (gdbsim_cntrl_c): Adjust.
5912 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
5913
5914 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
5915 (the_amd64_linux_nat_target): New.
5916 (amd64_linux_fetch_inferior_registers)
5917 (amd64_linux_store_inferior_registers): Refactor as methods of
5918 amd64_linux_nat_target.
5919 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
5920 * i386-linux-nat.c: Don't include "linux-nat.h".
5921 (i386_linux_nat_target): New class.
5922 (the_i386_linux_nat_target): New.
5923 (i386_linux_fetch_inferior_registers)
5924 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
5925 as methods of i386_linux_nat_target.
5926 (_initialize_i386_linux_nat): Adjust. Set linux_target.
5927 * inf-child.c (inf_child_ops): Delete.
5928 (inf_child_fetch_inferior_registers)
5929 (inf_child_store_inferior_registers): Delete.
5930 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
5931 methods of inf_child_target.
5932 (inf_child_target::supports_terminal_ours)
5933 (inf_child_target::terminal_init)
5934 (inf_child_target::terminal_inferior)
5935 (inf_child_target::terminal_ours_for_output)
5936 (inf_child_target::terminal_ours, inf_child_target::interrupt)
5937 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
5938 New.
5939 (inf_child_open, inf_child_disconnect, inf_child_close)
5940 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
5941 (inf_child_post_startup_inferior, inf_child_can_run)
5942 (inf_child_pid_to_exec_file): Refactor as methods of
5943 inf_child_target.
5944 (inf_child_follow_fork): Delete.
5945 (inf_child_target::can_create_inferior)
5946 (inf_child_target::can_attach): New.
5947 (inf_child_target::has_all_memory, inf_child_target::has_memory)
5948 (inf_child_target::has_stack, inf_child_target::has_registers)
5949 (inf_child_target::has_execution): New.
5950 (inf_child_fileio_open, inf_child_fileio_pwrite)
5951 (inf_child_fileio_pread, inf_child_fileio_fstat)
5952 (inf_child_fileio_close, inf_child_fileio_unlink)
5953 (inf_child_fileio_readlink, inf_child_use_agent)
5954 (inf_child_can_use_agent): Refactor as methods of
5955 inf_child_target.
5956 (return_zero, inf_child_target): Delete.
5957 (inf_child_target::inf_child_target): New.
5958 * inf-child.h: Include "target.h".
5959 (inf_child_target): Delete function prototype.
5960 (inf_child_target): New class.
5961 (inf_child_open_target, inf_child_mourn_inferior)
5962 (inf_child_maybe_unpush_target): Delete.
5963 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
5964 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
5965 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
5966 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
5967 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
5968 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
5969 (inf_ptrace_wait, inf_ptrace_xfer_partial)
5970 (inf_ptrace_thread_alive, inf_ptrace_files_info)
5971 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
5972 methods of inf_ptrace_target.
5973 (inf_ptrace_target): Delete function.
5974 * inf-ptrace.h: Include "inf-child.h".
5975 (inf_ptrace_target): Delete function declaration.
5976 (inf_ptrace_target): New class.
5977 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
5978 * linux-nat.c (linux_target): New.
5979 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
5980 (linux_nat_target::~linux_nat_target): New.
5981 (linux_child_post_attach, linux_child_post_startup_inferior)
5982 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
5983 (linux_child_remove_fork_catchpoint)
5984 (linux_child_insert_vfork_catchpoint)
5985 (linux_child_remove_vfork_catchpoint)
5986 (linux_child_insert_exec_catchpoint)
5987 (linux_child_remove_exec_catchpoint)
5988 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
5989 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
5990 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
5991 (linux_nat_stopped_data_address)
5992 (linux_nat_stopped_by_sw_breakpoint)
5993 (linux_nat_supports_stopped_by_sw_breakpoint)
5994 (linux_nat_stopped_by_hw_breakpoint)
5995 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
5996 (linux_nat_kill, linux_nat_mourn_inferior)
5997 (linux_nat_xfer_partial, linux_nat_thread_alive)
5998 (linux_nat_update_thread_list, linux_nat_pid_to_str)
5999 (linux_nat_thread_name, linux_child_pid_to_exec_file)
6000 (linux_child_static_tracepoint_markers_by_strid)
6001 (linux_nat_is_async_p, linux_nat_can_async_p)
6002 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
6003 (linux_nat_supports_multi_process)
6004 (linux_nat_supports_disable_randomization, linux_nat_async)
6005 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
6006 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
6007 (linux_nat_fileio_open, linux_nat_fileio_readlink)
6008 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
6009 methods of linux_nat_target.
6010 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
6011 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
6012 parameter.
6013 (check_stopped_by_watchpoint): Adjust.
6014 (linux_xfer_partial): Delete.
6015 (linux_target_install_ops, linux_target, linux_nat_add_target):
6016 Delete.
6017 (linux_nat_target::linux_nat_target): New.
6018 * linux-nat.h: Include "inf-ptrace.h".
6019 (linux_nat_target): New.
6020 (linux_target, linux_target_install_ops, linux_nat_add_target):
6021 Delete function declarations.
6022 (linux_target): Declare global.
6023 * linux-thread-db.c (thread_db_target): New.
6024 (thread_db_target::thread_db_target): New.
6025 (thread_db_ops): Delete.
6026 (the_thread_db_target): New.
6027 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
6028 (thread_db_update_thread_list, thread_db_pid_to_str)
6029 (thread_db_extra_thread_info)
6030 (thread_db_thread_handle_to_thread_info)
6031 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
6032 (thread_db_resume): Refactor as methods of thread_db_target.
6033 (init_thread_db_ops): Delete.
6034 (_initialize_thread_db): Remove reference to init_thread_db_ops.
6035 * x86-linux-nat.c: Don't include "linux-nat.h".
6036 (super_post_startup_inferior): Delete.
6037 (x86_linux_nat_target::~x86_linux_nat_target): New.
6038 (x86_linux_child_post_startup_inferior)
6039 (x86_linux_read_description, x86_linux_enable_btrace)
6040 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
6041 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
6042 methods of x86_linux_nat_target.
6043 (x86_linux_create_target): Delete. Bits folded ...
6044 (x86_linux_add_target): ... here. Now takes a linux_nat_target
6045 pointer.
6046 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
6047 (x86_linux_nat_target): New class.
6048 (x86_linux_create_target): Delete.
6049 (x86_linux_add_target): Now takes a linux_nat_target pointer.
6050 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
6051 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
6052 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
6053 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
6054 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
6055 make extern.
6056 (x86_use_watchpoints): Delete.
6057 * x86-nat.h: Include "breakpoint.h" and "target.h".
6058 (x86_use_watchpoints): Delete.
6059 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
6060 (x86_stopped_by_watchpoint, x86_stopped_data_address)
6061 (x86_insert_watchpoint, x86_remove_watchpoint)
6062 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
6063 (x86_stopped_by_hw_breakpoint): New declarations.
6064 (x86_nat_target): New template class.
6065
6066 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
6067 (the_ppc_linux_nat_target): New.
6068 (ppc_linux_fetch_inferior_registers)
6069 (ppc_linux_can_use_hw_breakpoint)
6070 (ppc_linux_region_ok_for_hw_watchpoint)
6071 (ppc_linux_ranged_break_num_registers)
6072 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
6073 (ppc_linux_insert_mask_watchpoint)
6074 (ppc_linux_remove_mask_watchpoint)
6075 (ppc_linux_can_accel_watchpoint_condition)
6076 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
6077 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
6078 (ppc_linux_watchpoint_addr_within_range)
6079 (ppc_linux_masked_watch_num_registers)
6080 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
6081 (ppc_linux_read_description): Refactor as methods of
6082 ppc_linux_nat_target.
6083 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
6084
6085 * procfs.c (procfs_xfer_partial): Delete forward declaration.
6086 (procfs_target): New class.
6087 (the_procfs_target): New.
6088 (procfs_target): Delete function.
6089 (procfs_auxv_parse, procfs_attach, procfs_detach)
6090 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
6091 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
6092 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
6093 (procfs_create_inferior, procfs_update_thread_list)
6094 (procfs_thread_alive, procfs_pid_to_str)
6095 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
6096 (procfs_stopped_data_address, procfs_insert_watchpoint)
6097 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
6098 (proc_find_memory_regions, procfs_info_proc)
6099 (procfs_make_note_section): Refactor as methods of procfs_target.
6100 (_initialize_procfs): Adjust.
6101 * sol-thread.c (sol_thread_target): New class.
6102 (sol_thread_ops): Now a sol_thread_target.
6103 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
6104 (sol_thread_fetch_registers, sol_thread_store_registers)
6105 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
6106 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
6107 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
6108 (init_sol_thread_ops): Delete.
6109 (_initialize_sol_thread): Adjust. Remove references to
6110 init_sol_thread_ops and complete_target_initialization.
6111
6112 * windows-nat.c (windows_nat_target): New class.
6113 (windows_fetch_inferior_registers)
6114 (windows_store_inferior_registers, windows_resume, windows_wait)
6115 (windows_attach, windows_detach, windows_pid_to_exec_file)
6116 (windows_files_info, windows_create_inferior)
6117 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
6118 (windows_close, windows_pid_to_str, windows_xfer_partial)
6119 (windows_get_tib_address, windows_get_ada_task_ptid)
6120 (windows_thread_name, windows_thread_alive): Refactor as
6121 windows_nat_target methods.
6122 (do_initial_windows_stuff): Adjust.
6123 (windows_target): Delete function.
6124 (_initialize_windows_nat): Adjust.
6125
6126 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
6127 (darwin_mourn_inferior, darwin_kill_inferior)
6128 (darwin_create_inferior, darwin_attach, darwin_detach)
6129 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
6130 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
6131 (darwin_supports_multi_process): Refactor as darwin_nat_target
6132 methods.
6133 (darwin_resume_to, darwin_files_info): Delete.
6134 (_initialize_darwin_inferior): Rename to ...
6135 (_initialize_darwin_nat): ... this. Adjust to C++ification.
6136 * darwin-nat.h: Include "inf-child.h".
6137 (darwin_nat_target): New class.
6138 (darwin_complete_target): Delete.
6139 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
6140 (darwin_target): New.
6141 (i386_darwin_fetch_inferior_registers)
6142 (i386_darwin_store_inferior_registers): Refactor as methods of
6143 darwin_nat_target.
6144 (darwin_complete_target): Delete, with ...
6145 (_initialize_i386_darwin_nat): ... bits factored out here.
6146
6147 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
6148 (the_alpha_linux_nat_target): New.
6149 (alpha_linux_register_u_offset): Refactor as
6150 alpha_linux_nat_target method.
6151 (_initialize_alpha_linux_nat): Adjust.
6152 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
6153 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6154 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
6155 methods of linux_nat_trad_target.
6156 (linux_trad_target): Delete.
6157 * linux-nat-trad.h (linux_trad_target): Delete function.
6158 (linux_nat_trad_target): New class.
6159 * mips-linux-nat.c (mips_linux_nat_target): New class.
6160 (super_fetch_registers, super_store_registers, super_close):
6161 Delete.
6162 (the_mips_linux_nat_target): New.
6163 (mips64_linux_regsets_fetch_registers)
6164 (mips64_linux_regsets_store_registers)
6165 (mips64_linux_fetch_registers, mips64_linux_store_registers)
6166 (mips_linux_register_u_offset, mips_linux_read_description)
6167 (mips_linux_can_use_hw_breakpoint)
6168 (mips_linux_stopped_by_watchpoint)
6169 (mips_linux_stopped_data_address)
6170 (mips_linux_region_ok_for_hw_watchpoint)
6171 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
6172 (mips_linux_close): Refactor as methods of mips_linux_nat.
6173 (_initialize_mips_linux_nat): Adjust to C++ification.
6174
6175 * aix-thread.c (aix_thread_target): New class.
6176 (aix_thread_ops): Now an aix_thread_target.
6177 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
6178 (aix_thread_fetch_registers, aix_thread_store_registers)
6179 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
6180 (aix_thread_thread_alive, aix_thread_pid_to_str)
6181 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
6182 Refactor as methods of aix_thread_target.
6183 (init_aix_thread_ops): Delete.
6184 (_initialize_aix_thread): Remove references to init_aix_thread_ops
6185 and complete_target_initialization.
6186 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
6187 (rs6000_nat_target): New class.
6188 (the_rs6000_nat_target): New.
6189 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
6190 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
6191 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
6192 (super_create_inferior): Delete.
6193 (_initialize_rs6000_nat): Adjust to C++ification.
6194
6195 * arm-linux-nat.c (arm_linux_nat_target): New class.
6196 (the_arm_linux_nat_target): New.
6197 (arm_linux_fetch_inferior_registers)
6198 (arm_linux_store_inferior_registers, arm_linux_read_description)
6199 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
6200 (arm_linux_remove_hw_breakpoint)
6201 (arm_linux_region_ok_for_hw_watchpoint)
6202 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
6203 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
6204 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
6205 arm_linux_nat_target.
6206 (_initialize_arm_linux_nat): Adjust to C++ification.
6207
6208 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
6209 (the_aarch64_linux_nat_target): New.
6210 (aarch64_linux_fetch_inferior_registers)
6211 (aarch64_linux_store_inferior_registers)
6212 (aarch64_linux_child_post_startup_inferior)
6213 (aarch64_linux_read_description)
6214 (aarch64_linux_can_use_hw_breakpoint)
6215 (aarch64_linux_insert_hw_breakpoint)
6216 (aarch64_linux_remove_hw_breakpoint)
6217 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
6218 (aarch64_linux_region_ok_for_hw_watchpoint)
6219 (aarch64_linux_stopped_data_address)
6220 (aarch64_linux_stopped_by_watchpoint)
6221 (aarch64_linux_watchpoint_addr_within_range)
6222 (aarch64_linux_can_do_single_step): Refactor as methods of
6223 aarch64_linux_nat_target.
6224 (super_post_startup_inferior): Delete.
6225 (_initialize_aarch64_linux_nat): Adjust to C++ification.
6226
6227 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
6228 (the_hppa_linux_nat_target): New.
6229 (hppa_linux_fetch_inferior_registers)
6230 (hppa_linux_store_inferior_registers): Refactor as methods of
6231 hppa_linux_nat_target.
6232 (_initialize_hppa_linux_nat): Adjust to C++ification.
6233
6234 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
6235 (the_ia64_linux_nat_target): New.
6236 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
6237 (ia64_linux_stopped_data_address)
6238 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
6239 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
6240 ia64_linux_nat_target methods.
6241 (super_xfer_partial): Delete.
6242 (_initialize_ia64_linux_nat): Adjust to C++ification.
6243
6244 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
6245 (the_m32r_linux_nat_target): New.
6246 (m32r_linux_fetch_inferior_registers)
6247 (m32r_linux_store_inferior_registers): Refactor as
6248 m32r_linux_nat_target methods.
6249 (_initialize_m32r_linux_nat): Adjust to C++ification.
6250
6251 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
6252 (the_m68k_linux_nat_target): New.
6253 (m68k_linux_fetch_inferior_registers)
6254 (m68k_linux_store_inferior_registers): Refactor as
6255 m68k_linux_nat_target methods.
6256 (_initialize_m68k_linux_nat): Adjust to C++ification.
6257
6258 * s390-linux-nat.c (s390_linux_nat_target): New class.
6259 (the_s390_linux_nat_target): New.
6260 (s390_linux_fetch_inferior_registers)
6261 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
6262 (s390_insert_watchpoint, s390_remove_watchpoint)
6263 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
6264 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
6265 (s390_auxv_parse, s390_read_description): Refactor as methods of
6266 s390_linux_nat_target.
6267 (_initialize_s390_nat): Adjust to C++ification.
6268
6269 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
6270 (the_sparc_linux_nat_target): New.
6271 (_initialize_sparc_linux_nat): Adjust to C++ification.
6272 * sparc-nat.c (sparc_fetch_inferior_registers)
6273 (sparc_store_inferior_registers): Remove target_ops parameter.
6274 * sparc-nat.h (sparc_fetch_inferior_registers)
6275 (sparc_store_inferior_registers): Remove target_ops parameter.
6276 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
6277 (the_sparc64_linux_nat_target): New.
6278 (_initialize_sparc64_linux_nat): Adjust to C++ification.
6279
6280 * spu-linux-nat.c (spu_linux_nat_target): New class.
6281 (the_spu_linux_nat_target): New.
6282 (spu_child_post_startup_inferior, spu_child_post_attach)
6283 (spu_child_wait, spu_fetch_inferior_registers)
6284 (spu_store_inferior_registers, spu_xfer_partial)
6285 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
6286 methods.
6287 (_initialize_spu_nat): Adjust to C++ification.
6288
6289 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
6290 (the_tilegx_linux_nat_target): New.
6291 (fetch_inferior_registers, store_inferior_registers):
6292 Refactor as methods.
6293 (_initialize_tile_linux_nat): Adjust to C++ification.
6294
6295 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
6296 (the_xtensa_linux_nat_target): New.
6297 (xtensa_linux_fetch_inferior_registers)
6298 (xtensa_linux_store_inferior_registers): Refactor as
6299 xtensa_linux_nat_target methods.
6300 (_initialize_xtensa_linux_nat): Adjust to C++ification.
6301
6302 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
6303 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
6304 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
6305 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
6306 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
6307 (fbsd_stopped_by_sw_breakpoint)
6308 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
6309 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
6310 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
6311 (fbsd_post_startup_inferior, fbsd_post_attach)
6312 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
6313 (fbsd_set_syscall_catchpoint)
6314 (super_xfer_partial, super_resume, super_wait)
6315 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
6316 (fbsd_handle_debug_trap): Remove target_ops parameter.
6317 (fbsd_nat_add_target): Delete.
6318 * fbsd-nat.h: Include "inf-ptrace.h".
6319 (fbsd_nat_add_target): Delete.
6320 (USE_SIGTRAP_SIGINFO): Define.
6321 (fbsd_nat_target): New class.
6322
6323 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
6324 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
6325 (amd64bsd_target): Delete.
6326 * amd64-bsd-nat.h: New file.
6327 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
6328 "x86-bsd-nat.h".
6329 (amd64_fbsd_nat_target): New class.
6330 (the_amd64_fbsd_nat_target): New.
6331 (amd64fbsd_read_description): Refactor as method of
6332 amd64_fbsd_nat_target.
6333 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6334 (_initialize_amd64fbsd_nat): Adjust to C++ification.
6335 * amd64-nat.h (amd64bsd_target): Delete function declaration.
6336 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
6337 (i386bsd_store_inferior_registers): Remove target_ops parameter.
6338 (i386bsd_target): Delete.
6339 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
6340 (i386bsd_fetch_inferior_registers)
6341 (i386bsd_store_inferior_registers): Declare.
6342 (i386_bsd_nat_target): New class.
6343 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
6344 (the_i386_fbsd_nat_target): New.
6345 (i386fbsd_resume, i386fbsd_read_description): Refactor as
6346 i386_fbsd_nat_target methods.
6347 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
6348 (_initialize_i386fbsd_nat): Adjust to C++ification.
6349 * x86-bsd-nat.c (super_mourn_inferior): Delete.
6350 (x86bsd_mourn_inferior, x86bsd_target): Delete.
6351 (_initialize_x86_bsd_nat): Adjust to C++ification.
6352 * x86-bsd-nat.h: Include "x86-nat.h".
6353 (x86bsd_target): Delete declaration.
6354 (x86bsd_nat_target): New class.
6355
6356 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
6357 (the_aarch64_fbsd_nat_target): New.
6358 (aarch64_fbsd_fetch_inferior_registers)
6359 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
6360 aarch64_fbsd_nat_target.
6361 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
6362 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
6363 (the_alpha_bsd_nat_target): New.
6364 (alphabsd_fetch_inferior_registers)
6365 (alphabsd_store_inferior_registers): Refactor as
6366 alpha_bsd_nat_target methods.
6367 (_initialize_alphabsd_nat): Refactor as methods of
6368 alpha_bsd_nat_target.
6369 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
6370 (the_amd64_nbsd_nat_target): New.
6371 (_initialize_amd64nbsd_nat): Adjust to C++ification.
6372 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
6373 (the_amd64_obsd_nat_target): New.
6374 (_initialize_amd64obsd_nat): Adjust to C++ification.
6375 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
6376 (the_arm_fbsd_nat_target): New.
6377 (arm_fbsd_fetch_inferior_registers)
6378 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
6379 (_initialize_arm_fbsd_nat): Refactor as methods of
6380 arm_fbsd_nat_target.
6381 (_initialize_arm_fbsd_nat): Adjust to C++ification.
6382 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
6383 (the_arm_netbsd_nat_target): New.
6384 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
6385 arm_netbsd_nat_target.
6386 (_initialize_arm_netbsd_nat): Adjust to C++ification.
6387 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
6388 (the_hppa_nbsd_nat_target): New.
6389 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
6390 hppa_nbsd_nat_target methods.
6391 (_initialize_hppanbsd_nat): Adjust to C++ification.
6392 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
6393 (the_hppa_obsd_nat_target): New.
6394 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
6395 methods of hppa_obsd_nat_target.
6396 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
6397 add_target.
6398 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
6399 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
6400 add_target.
6401 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
6402 (_initialize_i386obsd_nat): Use add_target.
6403 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
6404 (the_m68k_bsd_nat_target): New.
6405 (m68kbsd_fetch_inferior_registers)
6406 (m68kbsd_store_inferior_registers): Refactor as methods of
6407 m68k_bsd_nat_target.
6408 (_initialize_m68kbsd_nat): Adjust to C++ification.
6409 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
6410 (the_mips_fbsd_nat_target): New.
6411 (mips_fbsd_fetch_inferior_registers)
6412 (mips_fbsd_store_inferior_registers): Refactor as methods of
6413 mips_fbsd_nat_target.
6414 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
6415 add_target.
6416 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
6417 (the_mips_nbsd_nat_target): New.
6418 (mipsnbsd_fetch_inferior_registers)
6419 (mipsnbsd_store_inferior_registers): Refactor as methods of
6420 mips_nbsd_nat_target.
6421 (_initialize_mipsnbsd_nat): Adjust to C++ification.
6422 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
6423 (the_mips64_obsd_nat_target): New.
6424 (mips64obsd_fetch_inferior_registers)
6425 (mips64obsd_store_inferior_registers): Refactor as methods of
6426 mips64_obsd_nat_target.
6427 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
6428 add_target.
6429 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
6430 nbsd_nat_target.
6431 * nbsd-nat.h: Include "inf-ptrace.h".
6432 (nbsd_nat_target): New class.
6433 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
6434 (obsd_wait): Refactor as methods of obsd_nat_target.
6435 (obsd_add_target): Delete.
6436 * obsd-nat.h: Include "inf-ptrace.h".
6437 (obsd_nat_target): New class.
6438 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
6439 (the_ppc_fbsd_nat_target): New.
6440 (ppcfbsd_fetch_inferior_registers)
6441 (ppcfbsd_store_inferior_registers): Refactor as methods of
6442 ppc_fbsd_nat_target.
6443 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
6444 add_target.
6445 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
6446 (the_ppc_nbsd_nat_target): New.
6447 (ppcnbsd_fetch_inferior_registers)
6448 (ppcnbsd_store_inferior_registers): Refactor as methods of
6449 ppc_nbsd_nat_target.
6450 (_initialize_ppcnbsd_nat): Adjust to C++ification.
6451 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
6452 (the_ppc_obsd_nat_target): New.
6453 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
6454 methods of ppc_obsd_nat_target.
6455 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
6456 add_target.
6457 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
6458 (the_sh_nbsd_nat_target): New.
6459 (shnbsd_fetch_inferior_registers)
6460 (shnbsd_store_inferior_registers): Refactor as methods of
6461 sh_nbsd_nat_target.
6462 (_initialize_shnbsd_nat): Adjust to C++ification.
6463 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
6464 (inf_ptrace_xfer_partial): Delete.
6465 (sparc_xfer_partial, sparc_target): Delete.
6466 * sparc-nat.h (sparc_fetch_inferior_registers)
6467 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
6468 (sparc_target): Delete function declaration.
6469 (sparc_target): New template class.
6470 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
6471 (_initialize_sparcnbsd_nat): Adjust to C++ification.
6472 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
6473 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
6474 add_target.
6475 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
6476 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
6477 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
6478 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
6479 add_target.
6480 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
6481 (the_vax_bsd_nat_target): New.
6482 (vaxbsd_fetch_inferior_registers)
6483 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
6484 methods.
6485 (_initialize_vaxbsd_nat): Adjust to C++ification.
6486
6487 * bsd-kvm.c (bsd_kvm_target): New class.
6488 (bsd_kvm_ops): Now a bsd_kvm_target.
6489 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
6490 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
6491 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
6492 bsd_kvm_target.
6493 (bsd_kvm_return_one): Delete.
6494 (bsd_kvm_add_target): Adjust to C++ification.
6495
6496 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
6497 (nto_procfs_target_procfs): New classes.
6498 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
6499 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
6500 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
6501 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
6502 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
6503 (procfs_remove_hw_breakpoint, procfs_resume)
6504 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
6505 (procfs_kill_inferior, procfs_store_registers)
6506 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
6507 as methods of nto_procfs_target.
6508 (nto_procfs_ops): Now an nto_procfs_target_procfs.
6509 (nto_native_ops): Delete.
6510 (procfs_open, procfs_native_open): Delete.
6511 (nto_native_ops): Now an nto_procfs_target_native.
6512 (init_procfs_targets): Adjust to C++ification.
6513 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
6514 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
6515 Refactor as methods of nto_procfs_target.
6516
6517 * go32-nat.c (go32_nat_target): New class.
6518 (the_go32_nat_target): New.
6519 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
6520 (go32_store_registers, go32_xfer_partial, go32_files_info)
6521 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
6522 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
6523 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
6524 (go32_pid_to_str): Refactor as methods of go32_nat_target.
6525 (go32_target): Delete.
6526 (_initialize_go32_nat): Adjust to C++ification.
6527
6528 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
6529 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
6530 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
6531 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
6532 gnu_nat_target.
6533 (gnu_target): Delete.
6534 * gnu-nat.h (gnu_target): Delete.
6535 (gnu_nat_target): New class.
6536 * i386-gnu-nat.c (gnu_base_target): New.
6537 (i386_gnu_nat_target): New class.
6538 (the_i386_gnu_nat_target): New.
6539 (_initialize_i386gnu_nat): Adjust to C++ification.
6540
3fffc070
PA
65412018-05-02 Pedro Alves <palves@redhat.com>
6542
6543 * bfd-target.c (target_bfd_xclose): Rename to ...
6544 (target_bfd_close): ... this.
6545 (target_bfd_reopen): Adjust.
6546 * target.c (target_close): Remove references to to_xclose.
6547 * target.h (target_ops::to_xclose): Delete.
6548 (target_ops::to_close): Update comments.
6549
6798487f
PA
65502018-05-02 Pedro Alves <palves@redhat.com>
6551
6552 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
6553 "linux-nat.h".
6554 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
6555 * inf-ptrace.c (inf_ptrace_register_u_offset)
6556 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
6557 (inf_ptrace_store_register, inf_ptrace_store_registers)
6558 (inf_ptrace_trad_target): Move to ...
6559 * linux-nat-trad.c: ... this new file.
6560 * linux-nat-trad.h: New file.
6561 * linux-nat.c (linux_target_install_ops): Make extern.
6562 (linux_trad_target): Delete.
6563 * linux-nat.h (linux_trad_target): Delete declaration.
6564 (linux_target_install_ops): Declare.
6565 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
6566 "linux-nat.h".
6567
c1955e17
PA
65682018-05-02 Pedro Alves <palves@redhat.com>
6569
6570 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6571 procfs_target/add_target here.
6572 * procfs.c (procfs_target): Make static.
6573 (_initialize_procfs): Call add_target here.
6574 * procfs.h (struct target_ops): Remove forward declaration.
6575 (procfs_target): Remove declaration.
6576 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
6577
b5c8fcb1
PA
65782018-05-02 Pedro Alves <palves@redhat.com>
6579
6580 * procfs.c (procfs_stopped_by_watchpoint)
6581 (procfs_insert_watchpoint, procfs_remove_watchpoint)
6582 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
6583 Forward declare.
6584 (procfs_use_watchpoints): Delete, move contents...
6585 (procfs_target): ... here.
6586 * procfs.h (procfs_use_watchpoints): Delete declaration.
6587 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
6588 procfs_use_watchpoints.
6589 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
6590 procfs_use_watchpoints.
6591
0489430a
TT
65922018-05-02 Tom Tromey <tom@tromey.com>
6593
6594 PR python/20084:
6595 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
6596 and var_zuinteger_unlimited.
6597 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
6598 and PARAM_ZUINTEGER_UNLIMITED.
6599 (set_parameter_value): Handle var_zuinteger and
6600 var_zuinteger_unlimited.
6601 (add_setshow_generic): Likewise.
6602 (parmpy_init): Likewise.
6603
1632f8ba
DR
66042018-04-28 Dan Robertson <danlrobertson89@gmail.com>
6605
6606 PR rust/23124
6607 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
6608 pointer is not null before dereferencing it.
6609
76761936
TT
66102018-04-30 Tom Tromey <tom@tromey.com>
6611
6612 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
6613 is_mi_like_p.
6614
2d33446d
TT
66152018-04-30 Tom Tromey <tom@tromey.com>
6616
6617 * breakpoint.c (mention): Remove use of is_mi_like_p.
6618 (print_mention_ranged_breakpoint): Likewise.
6619 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
6620 of is_mi_like_p.
6621
f3c6abab
TT
66222018-04-30 Tom Tromey <tom@tromey.com>
6623
6624 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
6625
40c03530
TT
66262018-04-30 Tom Tromey <tom@tromey.com>
6627
6628 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
6629 (info_spu_event_command): Remove some uses of is_mi_like_p.
6630
2038b7fd
TT
66312018-04-30 Tom Tromey <tom@tromey.com>
6632
6633 * python/py-framefilter.c (py_print_single_arg)
6634 (enumerate_locals, py_print_args, py_print_frame): Remove some
6635 uses of is_mi_like_p.
6636
4904c3c6
TT
66372018-04-30 Tom Tromey <tom@tromey.com>
6638
6639 * ui-out.c: Update.
6640 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
6641 * ui-out.h (ui_out::is_mi_like_p): Now const.
6642 (ui_out::do_is_mi_like_p): Now const.
6643 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
6644
7c66fffc
TT
66452018-04-30 Tom Tromey <tom@tromey.com>
6646
6647 * varobj.c (varobj_set_visualizer): Use new_reference.
6648 * python/python.c (gdbpy_decode_line): Use new_reference.
6649 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
6650 new_reference.
6651
bbfa6f00
TT
66522018-04-30 Tom Tromey <tom@tromey.com>
6653
6654 * varobj.c (install_new_value): Use new_reference.
6655 * value.h (value_incref): Return void. Swap intro comment with
6656 value_decref.
6657 * value.c (set_value_parent): Use new_reference.
6658 (value_incref): Return void. Update intro comment.
6659 (release_value): Use new_reference.
6660 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
6661
1831a9f9
TT
66622018-04-30 Tom Tromey <tom@tromey.com>
6663
6664 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
6665 * gdb_bfd.h (new_bfd_ref): Remove.
6666 (gdb_bfd_open): Update comment.
6667 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
6668 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
6669 (gdb_bfd_fdopenr): Use new_reference.
6670 * exec.c (exec_file_attach): Use new_reference.
6671
7c1b5f3d
TT
66722018-04-30 Tom Tromey <tom@tromey.com>
6673
6674 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
6675 method.
6676
e11fb955
TT
66772018-04-30 Tom Tromey <tom@tromey.com>
6678
6679 * jit.c (jit_read_code_entry): Use type_align.
6680 * i386-tdep.c (i386_gdbarch_init): Don't call
6681 set_gdbarch_long_long_align_bit.
6682 * gdbarch.sh: Remove long_long_align_bit.
6683 * gdbarch.c, gdbarch.h: Rebuild.
6684 * arc-tdep.c (arc_type_align): New function.
6685 (arc_gdbarch_init): Use arc_type_align. Don't call
6686 set_gdbarch_long_long_align_bit.
6687
2fff16dd
TT
66882018-04-30 Tom Tromey <tom@tromey.com>
6689
6690 * rust-lang.c (rust_type_alignment): Remove.
6691 (rust_composite_type): Use type_align.
6692
6d7bb824
TT
66932018-04-30 Tom Tromey <tom@tromey.com>
6694
6695 * NEWS: Mention Type.align.
6696 * python/py-type.c (typy_get_alignof): New function.
6697 (type_object_getset): Add "alignof".
6698
007e1530
TT
66992018-04-30 Tom Tromey <tom@tromey.com>
6700
6701 PR exp/17095:
6702 * NEWS: Update.
6703 * std-operator.def (UNOP_ALIGNOF): New operator.
6704 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
6705 New.
6706 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
6707 * c-lang.c (c_op_print_tab): Add alignof.
6708 * c-exp.y (ALIGNOF): New token.
6709 (exp): Add "ALIGNOF" production.
6710 (ident_tokens): Add _Alignof and alignof.
6711
2b4424c3
TT
67122018-04-30 Tom Tromey <tom@tromey.com>
6713
6714 * i386-tdep.c (i386_type_align): New function.
6715 (i386_gdbarch_init): Update.
6716 * gdbarch.sh (type_align): New method.
6717 * gdbarch.c, gdbarch.h: Rebuild.
6718 * arch-utils.h (default_type_align): Declare.
6719 * arch-utils.c (default_type_align): New function.
6720 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
6721 (struct type) <align_log2>: New field.
6722 <instance_flags>: Now a bitfield.
6723 (TYPE_RAW_ALIGN): New macro.
6724 (type_align, type_raw_align, set_type_align): Declare.
6725 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
6726 functions.
6727 * dwarf2read.c (quirk_rust_enum): Set type alignment.
6728 (get_alignment, maybe_set_alignment): New functions.
6729 (read_structure_type, read_enumeration_type, read_array_type)
6730 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
6731 (read_subrange_type, read_base_type): Set type alignment.
6732
d33bc52e
SM
67332018-04-30 Simon Marchi <simon.marchi@ericsson.com>
6734
6735 * dwarf2read.c (read_index_from_section): Use bool.
6736
e28b63a9
FG
67372018-04-29 Fabian Groffen <grobian@gentoo.org>
6738
6739 PR gdb/22950
6740 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
6741 with #ifdef.
6742
cd8c76e4
JR
67432018-04-29 John Reiser <jreiser@BitWagon.com>
6744
6745 PR build/22873
6746 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
6747 last step, and do it atomically.
6748
476d250e
AO
67492018-04-27 Alexandre Oliva <aoliva@redhat.com>
6750
6751 * compile/compile-c-types.c (convert_int, convert_float):
6752 Update for C FE v1.
6753
6873858b
TT
67542018-04-27 Tom Tromey <tom@tromey.com>
6755
6756 PR rust/22545:
6757 * rust-lang.c (rust_inclusive_range_type_p): New function.
6758 (rust_range): Handle inclusive ranges.
6759 (rust_compute_range): Likewise.
6760 * rust-exp.y (struct rust_op) <inclusive>: New field.
6761 (DOTDOTEQ): New constant.
6762 (range_expr): Add "..=" productions.
6763 (operator_tokens): Add "..=" token.
6764 (ast_range): Add "inclusive" parameter.
6765 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
6766 ranges.
6767 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
6768 bounds values.
6769 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
6770 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
6771 Update comments.
6772 * expprint.c (print_subexp_standard): Handle new bounds values.
6773 (dump_subexp_body_standard): Likewise.
6774
632e107b
TT
67752018-04-27 Tom Tromey <tom@tromey.com>
6776
6777 * configure: Rebuild.
6778 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
6779 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
6780 "OVERRIDE".
6781 (class symbol_needs_eval_context): Likewise.
6782 * dwarf2read.c (mock_mapped_index::symbol_name_count)
6783 (mock_mapped_index::symbol_name_at): Use "override". Remove
6784 "virtual".
6785 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
6786 "override".
6787 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
6788 * aarch64-tdep.c (instruction_reader::read): Use "override".
6789 (instruction_reader_test::read): Likewise.
6790 * arm-tdep.c (instruction_reader::read): Use "override".
6791 (instruction_reader_thumb::read): Likewise.
6792
b75abf5b
AK
67932018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
6794
6795 PR remote/9665
6796 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
6797 instead of remote_send.
6798 (remote_send): Remove.
6799
79188d8d
PA
68002018-04-26 Pedro Alves <palves@redhat.com>
6801
6802 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
6803 find_function_start_sal instead of find_pc_line.
6804
f50776aa
PA
68052018-04-26 Pedro Alves <palves@redhat.com>
6806
6807 * breakpoint.c (set_breakpoint_location_function): Handle
6808 mst_data_gnu_ifunc.
6809 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
6810 * elfread.c (elf_symtab_read): Give data symbols with
6811 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
6812 (elf_rel_plt_read): Update comment.
6813 * linespec.c (convert_linespec_to_sals): Handle
6814 mst_data_gnu_ifunc.
6815 (minsym_found): Handle mst_data_gnu_ifunc.
6816 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
6817 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
6818 * parse.c (find_minsym_type_and_address): Handle
6819 mst_data_gnu_ifunc.
6820 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
6821 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
6822 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
6823 comment.
6824 <mst_data_gnu_ifunc>: New enumerator.
6825
20944a6e
PA
68262018-04-26 Pedro Alves <palves@redhat.com>
6827
6828 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
6829 (lookup_minimal_symbol_by_pc_section): ... this. Replace
6830 'want_trampoline' parameter by a lookup_msym_prefer parameter.
6831 Handle it.
6832 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
6833 (lookup_minimal_symbol_by_pc): Adjust.
6834 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
6835 (lookup_solib_trampoline_symbol_by_pc): Adjust.
6836 * minsyms.h (lookup_msym_prefer): New enum.
6837 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6838 parameter by a lookup_msym_prefer parameter.
6839
1adeb822
PA
68402018-04-26 Pedro Alves <palves@redhat.com>
6841
6842 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
6843 ends in "@plt" instead of looking at the symbol's section.
6844
a0aca7b0
PA
68452018-04-26 Pedro Alves <palves@redhat.com>
6846
6847 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
6848 all references.
6849 (find_pc_partial_function_gnu_ifunc): Rename to ...
6850 (find_pc_partial_function): ... this, and remove references to
6851 'is_gnu_ifunc_p'.
6852 (find_pc_partial_function): Delete old implementation.
6853 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
6854
76af0f26
PA
68552018-04-26 Pedro Alves <palves@redhat.com>
6856
6857 * linespec.c (struct bound_minimal_symbol_search_key): New.
6858 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
6859 skip first line if we found a GNU ifunc minimal symbol by name.
6860 (compare_msymbols): Change parameters to work with a destructured
6861 lhs minsym.
6862 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
6863 functions.
6864
3467ec66
PA
68652018-04-26 Pedro Alves <palves@redhat.com>
6866
6867 * breakpoint.c (set_breakpoint_location_function): Don't resolve
6868 ifunc targets here. Instead, if we have an ifunc minsym, use its
6869 address/name.
6870 (add_location_to_breakpoint): Store the minsym and the objfile in
6871 the breakpoint location.
6872 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
6873 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
6874 Record the minsym in the sal.
6875 * symtab.h (symtab_and_line) <msymbol>: New field.
6876
28f4fa4d
PA
68772018-04-26 Pedro Alves <palves@redhat.com>
6878
6879 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
6880 unless we actually resolved the ifunc.
6881
ca31ab1d
PA
68822018-04-26 Pedro Alves <palves@redhat.com>
6883
6884 * c-exp.y (variable production): Prefer ifunc minsyms over
6885 regular function symbols.
6886 * symtab.c (find_gnu_ifunc): New function.
6887 * minsyms.h (lookup_msym_prefer): New enum.
6888 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
6889 parameter by a lookup_msym_prefer parameter.
6890 * symtab.h (find_gnu_ifunc): New declaration.
6891
8388016d
PA
68922018-04-26 Pedro Alves <palves@redhat.com>
6893
6894 * blockframe.c (find_gnu_ifunc_target_type): New function.
6895 (find_function_type): New.
6896 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
6897 return a value with a memory address.
6898 (eval_call): For calls to GNU ifunc functions, try to find the
6899 type of the target function from the type that the resolver
6900 returns.
6901 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
6902 symbols.
6903 * infcall.c (find_function_return_type): Delete.
6904 (find_function_addr): Add 'function_type' parameter. For calls to
6905 GNU ifunc functions, try to find the type of the target function
6906 from the type that the resolver returns, and return it via
6907 FUNCTION_TYPE.
6908 (call_function_by_hand_dummy): Adjust to use the function type
6909 returned by find_function_addr.
6910 (find_function_addr): Add 'function_type' parameter and move
6911 description here.
6912 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
6913 declarations.
6914
a376e11d
PA
69152018-04-26 Pedro Alves <palves@redhat.com>
6916
6917 * c-exp.y (variable production): Skip finding an alias for ifunc
6918 symbols.
6919
02e169e2
PA
69202018-04-26 Pedro Alves <palves@redhat.com>
6921
6922 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
6923
249b5733
PA
69242018-04-25 Pedro Alves <palves@redhat.com>
6925
6926 * infcmd.c (kill_command): Print the pid as string, not the whole
6927 thread's ptid. Add comment. s/has been killed/killed/ in output
6928 message.
6929 * remote.c (remote_detach_1): Print the pid as string, not the
6930 whole thread's ptid.
6931
f67c0c91
SDJ
69322018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
6933 Sergio Durigan Junior <sergiodj@redhat.com>
6934 Pedro Alves <palves@redhat.com>
6935
6936 * infcmd.c (kill_command): Print message when inferior has
6937 been killed.
6938 * inferior.c (print_inferior_events): Remove 'static'. Set as
6939 '1'.
6940 (add_inferior): Improve message printed when
6941 'print_inferior_events' is on.
6942 (exit_inferior): Remove message printed when
6943 'print_inferior_events' is on.
6944 (detach_inferior): Improve message printed when
6945 'print_inferior_events' is on.
6946 (initialize_inferiors): Use 'add_inferior_silent' to set
6947 'current_inferior_'.
6948 * inferior.h (print_inferior_events): Declare here as
6949 'extern'.
6950 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
6951 '[Detaching...]' messages when 'print_inferior_events' is on.
6952 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
6953 as prefix/suffix for messages. Remove periods. Fix erroneous
6954 'Detaching after fork from child...', replace it by '... from
6955 parent...'.
6956 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
6957 prefix/suffix when printing 'Detaching...' messages. Print
6958 them when 'print_inferior_events' is on.
6959 * remote.c (remote_detach_1): Print message when detaching
6960 from inferior and '!is_fork_parent'.
6961
e427af18
TT
69622018-04-24 Tom Tromey <tom@tromey.com>
6963
6964 * cli-out.h: Reindent.
6965
05b1d8d6
TT
69662018-04-24 Tom Tromey <tom@tromey.com>
6967
6968 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
6969 (cli_ui_out::do_field_string): Use fputs_filtered.
6970 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
6971
a95c7dab
TT
69722018-04-23 Tom Tromey <tom@tromey.com>
6973
6974 * guile/scm-frame.c (gdbscm_frame_read_var): Use
6975 gdb::unique_xmalloc_ptr.
6976
458412c3
TT
69772018-04-23 Tom Tromey <tom@tromey.com>
6978
6979 * configure: Rebuild.
6980
db86b02b
RS
69812018-04-22 Rajendra SY <rajendra.sy@gmail.com>
6982
6983 PR gdb/23095
6984 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
6985 prepare_for_testing. Set normal_bp to r_debug_state if target
6986 is bsd.
6987
00aecdcf
PA
69882018-04-21 Pedro Alves <palves@redhat.com>
6989 Rajendra SY <rajendra.sy@gmail.com>
6990
6991 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
6992 * remote.c (extended_remote_attach): In all-stop mode, mark the
6993 thread as executing.
6994
224608c3
PW
69952018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
6996
6997 * thread.c (thread_apply_all_command): Fix comment.
6998 (thread_command): Fix comment.
6999
3b74854b
AH
70002018-04-10 Alan Hayward <alan.hayward@arm.com>
7001
7002 * common/tdesc.h (tdesc_create_feature): Remove xml filename
7003 parameter.
7004 * features/aarch64-core.c (create_feature_aarch64_core):
7005 Regenerate.
7006 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
7007 Likewise.
7008 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
7009 Likewise.
7010 * features/i386/32bit-avx512.c
7011 (create_feature_i386_32bit_avx512): Likewise.
7012 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
7013 Likewise.
7014 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
7015 Likewise.
7016 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
7017 Likewise.
7018 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
7019 Likewise.
7020 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
7021 Likewise.
7022 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
7023 Likewise.
7024 * features/i386/64bit-avx512.c
7025 (create_feature_i386_64bit_avx512): Likewise.
7026 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
7027 Likewise.
7028 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
7029 Likewise.
7030 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
7031 Likewise.
7032 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
7033 Likewise.
7034 * features/i386/64bit-segments.c
7035 (create_feature_i386_64bit_segments): Likewise.
7036 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
7037 Likewise.
7038 * features/i386/x32-core.c
7039 (create_feature_i386_x32_core): Likewise.
7040 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
7041 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
7042 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
7043 * target-descriptions.c: In generated code, don't pass xml
7044 filename.
7045
e98577a9
AH
70462018-04-18 Alan Hayward <alan.hayward@arm.com>
7047
7048 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
7049 (print_xml_feature::visit_post): Likewise.
7050 (print_xml_feature::visit): Likewise.
7051 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
7052 (print_xml_feature): Add new class.
7053 * regformats/regdat.sh: Null xmltarget on feature targets.
7054 * target-descriptions.c (struct target_desc): Add xmltarget.
7055 (maintenance_check_tdesc_xml_convert): Add unittest function.
7056 (tdesc_get_features_xml): Add function to get xml.
7057 (maintenance_check_xml_descriptions): Test xml generation.
7058 * xml-tdesc.c (string_read_description_xml): Add function.
7059 * xml-tdesc.h (string_read_description_xml): Add declaration.
7060
ad7fc756
AH
70612018-04-18 Alan Hayward <alan.hayward@arm.com>
7062
7063 * features/Makefile: Add feature marker to targets with new style
7064 target descriptions.
7065 * regformats/aarch64.dat: Regenerate.
7066 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
7067 * regformats/i386/amd64-avx-linux.dat: Likewise.
7068 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
7069 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
7070 * regformats/i386/amd64-linux.dat: Likewise.
7071 * regformats/i386/amd64-mpx-linux.dat: Likewise.
7072 * regformats/i386/amd64.dat: Likewise.
7073 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
7074 * regformats/i386/i386-avx-linux.dat: Likewise.
7075 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
7076 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
7077 * regformats/i386/i386-linux.dat: Likewise.
7078 * regformats/i386/i386-mmx-linux.dat: Likewise.
7079 * regformats/i386/i386-mpx-linux.dat: Likewise.
7080 * regformats/i386/i386.dat: Likewise.
7081 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
7082 * regformats/i386/x32-avx-linux.dat: Likewise.
7083 * regformats/i386/x32-linux.dat: Likewise.
7084 * regformats/tic6x-c62x-linux.dat: Likewise.
7085 * regformats/tic6x-c64x-linux.dat: Likewise.
7086 * regformats/tic6x-c64xp-linux.dat: Likewise.
7087 * regformats/regdat.sh: Parse feature marker.
7088
d278f585
AH
70892018-04-18 Alan Hayward <alan.hayward@arm.com>
7090
7091 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
7092 (tdesc_osabi_name): Likewise.
7093 * target-descriptions.c (tdesc_architecture_name): Add new
7094 function.
7095 (tdesc_osabi_name): Likewise.
7096
eee8a18d
AH
70972018-04-18 Alan Hayward <alan.hayward@arm.com>
7098
7099 * common/tdesc.c (tdesc_predefined_type): Move to here.
7100 (tdesc_named_type): Likewise.
7101 (tdesc_create_vector): Likewise.
7102 (tdesc_create_struct): Likewise.
7103 (tdesc_set_struct_size): Likewise.
7104 (tdesc_create_union): Likewise.
7105 (tdesc_create_flags): Likewise.
7106 (tdesc_create_enum): Likewise.
7107 (tdesc_add_field): Likewise.
7108 (tdesc_add_typed_bitfield): Likewise.
7109 (tdesc_add_bitfield): Likewise.
7110 (tdesc_add_flag): Likewise.
7111 (tdesc_add_enum_value): Likewise.
7112 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
7113 (struct tdesc_type_vector): Likewise.
7114 (struct tdesc_type_field): Likewise.
7115 (struct tdesc_type_with_fields): Likewise.
7116 (tdesc_create_enum): Add declaration.
7117 (tdesc_add_typed_bitfield): Likewise.
7118 (tdesc_add_enum_value): Likewise.
7119 * target-descriptions.c (tdesc_type_field): Move from here.
7120 (tdesc_type_builtin): Likewise.
7121 (tdesc_type_vector): Likewise.
7122 (tdesc_type_with_fields): Likewise.
7123 (tdesc_predefined_types): Likewise.
7124 (tdesc_named_type): Likewise.
7125 (tdesc_create_vector): Likewise.
7126 (tdesc_create_struct): Likewise.
7127 (tdesc_set_struct_size): Likewise.
7128 (tdesc_create_union): Likewise.
7129 (tdesc_create_flags): Likewise.
7130 (tdesc_create_enum): Likewise.
7131 (tdesc_add_field): Likewise.
7132 (tdesc_add_typed_bitfield): Likewise.
7133 (tdesc_add_bitfield): Likewise.
7134 (tdesc_add_flag): Likewise.
7135 (tdesc_add_enum_value): Likewise.
7136 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
7137 (tdesc_add_typed_bitfield): Likewise.
7138 (tdesc_add_enum_value): Likewise.
7139
82ec9bc7
AH
71402018-04-18 Alan Hayward <alan.hayward@arm.com>
7141
7142 * common/tdesc.c (tdesc_feature::accept): Move to here.
7143 (tdesc_feature::operator==): Likewise.
7144 (tdesc_create_reg): Likewise.
7145 * common/tdesc.h (tdesc_type_kind): Likewise.
7146 (struct tdesc_type): Likewise.
7147 (struct tdesc_feature): Likewise.
7148 * regformats/regdat.sh: Create a feature.
7149 * target-descriptions.c (tdesc_type_kind): Move from here.
7150 (tdesc_type): Likewise.
7151 (tdesc_type_up): Likewise.
7152 (tdesc_feature): Likewise.
7153 (tdesc_create_reg): Likewise.
7154
ea3e7d71
AH
71552018-04-18 Alan Hayward <alan.hayward@arm.com>
7156
7157 * Makefile.in: Add arch/tdesc.c
7158 * common/tdesc.c: New file.
7159 * common/tdesc.h (tdesc_element_visitor): Move to here.
7160 (tdesc_element): Likewise.
7161 (tdesc_reg): Likewise.
7162 (tdesc_reg_up): Likewise.
7163 * regformats/regdef.h (reg): Add offset to constructors.
7164 * target-descriptions.c (tdesc_element_visitor): Move from here.
7165 (tdesc_element): Likewise.
7166 (tdesc_reg): Likewise.
7167 (tdesc_reg_up): Likewise.
7168
bedda9ac
TT
71692018-04-17 Tom Tromey <tom@tromey.com>
7170
7171 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
7172 discriminant field.
7173
a037790e
TT
71742018-04-17 Tom Tromey <tom@tromey.com>
7175
7176 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
7177
c7dcbf88
AA
71782018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
7179
7180 * symtab.c (print_symbol_info): Skip printing filename and line
7181 number when `last' is NULL.
7182 (symtab_symbol_info): Use empty string instead of NULL for first
7183 invocation of print_symbol_info.
7184 (rbreak_command): Pass NULL to `last' parameter of
7185 print_symbol_info.
7186
07d28c77
SM
71872018-04-16 Simon Marchi <simon.marchi@ericsson.com>
7188
7189 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
7190 instead of nullptr.
7191
8a3de5e1
PA
71922018-04-16 Pedro Alves <palves@redhat.com>
7193
7194 * MAINTAINERS (sh): Remove.
7195 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
7196 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
7197 (ALLDEPFILES): Remove sh64-tdep.c.
7198 * NEWS: Mentions that support for SH-5/SH64 is removed.
7199 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
7200 (sh*-*-openbsd*): Ditto.
7201 (sh64-*-elf*): Remove.
7202 (sh*): Remove.
7203 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
7204 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
7205 * sh-tdep.c: No longer include "sh64-tdep.h".
7206 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
7207 * sh64-tdep.c, sh64-tdep.h: Remove files.
7208
a2a79012
PA
72092018-04-16 Pedro Alves <palves@redhat.com>
7210
7211 * MAINTAINERS: Remove m88k.
7212 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
7213 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
7214 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
7215 * NEWS: Mention that support for m88k was removed.
7216 * configure.host (m88*-*-*): Remove support.
7217 * configure.nat (m88k-*-*): Remove support.
7218 * configure.tgt (m88*-*-openbsd*): Remove.
7219 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
7220
eda4efb1
SM
72212018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
7222
7223 * configure.tgt (x86_tobjs): New variable.
7224 (amd64_tobjs, i386_tobjs): Use it.
7225
b744723f
AA
72262018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
7227
7228 * symtab.c (print_symbol_info): Precede the symbol definition by
7229 the line number when available.
7230 * NEWS: Advertise this enhancement.
7231
4a4495d6
MM
72322018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7233
7234 * NEWS (New options): announce set/show record btrace cpu.
7235 * btrace.c: Include record-btrace.h.
7236 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
7237 the vendor is unknown.
7238 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
7239 Maybe overwrite the btrace configuration's cpu.
7240 (btrace_compute_ftrace): Add cpu parameter. Update callers.
7241 (btrace_fetch): Add cpu parameter. Update callers.
7242 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
7243 Maybe overwrite the btrace configuration's cpu. Skip enabling
7244 errata workarounds if the vendor is unknown.
7245 * python/py-record-btrace.c: Include record-btrace.h.
7246 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
7247 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
7248 * record-btrace.c (record_btrace_cpu_state_kind): New.
7249 (record_btrace_cpu): New.
7250 (set_record_btrace_cpu_cmdlist): New.
7251 (record_btrace_get_cpu): New.
7252 (require_btrace_thread, record_btrace_info)
7253 (record_btrace_resume_thread): Call record_btrace_get_cpu.
7254 (cmd_set_record_btrace_cpu_none): New.
7255 (cmd_set_record_btrace_cpu_auto): New.
7256 (cmd_set_record_btrace_cpu): New.
7257 (cmd_show_record_btrace_cpu): New.
7258 (_initialize_record_btrace): Initialize set/show record btrace cpu
7259 commands.
7260 * record-btrace.h (record_btrace_get_cpu): New.
7261
69f90c75
MM
72622018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7263
7264 * record.c (set_record_command): Fix typo in message.
7265
b85310e1
MM
72662018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7267
7268 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
7269
1d509aa6
MM
72702018-04-13 Markus Metzger <markus.t.metzger@intel.com>
7271
7272 * infrun.c (process_event_stop_test): Call
7273 gdbarch_in_indirect_branch_thunk.
7274 * gdbarch.sh (in_indirect_branch_thunk): New.
7275 * gdbarch.c: Regenerated.
7276 * gdbarch.h: Regenerated.
7277 * x86-tdep.h: New.
7278 * x86-tdep.c: New.
7279 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
7280 (HFILES_NO_SRCDIR): Add x86-tdep.h.
7281 (ALLDEPFILES): Add x86-tdep.c.
7282 * arch-utils.h (default_in_indirect_branch_thunk): New.
7283 * arch-utils.c (default_in_indirect_branch_thunk): New.
7284 * i386-tdep: Include x86-tdep.h.
7285 (i386_in_indirect_branch_thunk): New.
7286 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
7287 function.
7288 * amd64-tdep: Include x86-tdep.h.
7289 (amd64_in_indirect_branch_thunk): New.
7290 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
7291
b4be9bfd
JK
72922018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
7293
7294 PR gdb/23053
7295 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
7296 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
7297 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
7298 regression.
7299
53d7df28
TT
73002018-04-12 Tom Tromey <tom@tromey.com>
7301
7302 * rust-lang.c (rust_print_struct_def): Remove univariant code.
7303 (rust_evaluate_subexp): Likewise.
7304
70b33f19
PA
73052018-04-12 Pedro Alves <palves@redhat.com>
7306
7307 * procfs.c (procfs_detach): Make forward declaration's prototype
7308 match definition's protototype.
7309 (proc_get_LDT_entry): Remove stale do_cleanups call.
7310
436411b1
PA
73112018-04-12 Pedro Alves <palves@redhat.com>
7312
7313 * target.h (target_ops::to_has_exited): Delete.
7314 (target_has_exited): Delete.
7315 * target-delegates.c: Regenerate.
7316
20db9c52
PA
73172018-04-11 Pedro Alves <palves@redhat.com>
7318
7319 * target.c (fileio_fh_t::t): Add comment.
7320 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7321 (target_fileio_close): Handle a NULL target.
7322 (invalidate_fileio_fh): New.
7323 (target_close): Call it.
7324 * remote.c (remote_hostio_send_command): No longer check whether
7325 remote_desc is open.
7326
5ff79300
PA
73272018-04-11 Pedro Alves <palves@redhat.com>
7328
7329 * target.c (fileio_fh_t): Make it a named struct instead of a
7330 typedef.
7331 (fileio_fh_t::is_closed): New method.
7332 (DEF_VEC_O (fileio_fh_t)): Remove.
7333 (fileio_fhandles): Now a std::vector.
7334 (is_closed_fileio_fh): Delete.
7335 (acquire_fileio_fd): Adjust. Rename parameters.
7336 (release_fileio_fd): Adjust.
7337 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
7338 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
7339 (target_fileio_close): Adjust.
7340
6e22e10d
SM
73412018-04-10 Simon Marchi <simon.marchi@ericsson.com>
7342
7343 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
7344 index.
7345
731f534f
PA
73462018-04-10 Pedro Alves <palves@redhat.com>
7347
7348 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
7349 (scoped_finish_thread_state): New class.
7350 * infcmd.c (run_command_1): Use it instead of finish_thread_state
7351 cleanup.
7352 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
7353 (fetch_inferior_event, normal_stop): Likewise.
7354 * thread.c (finish_thread_state_cleanup): Delete.
7355
d5f4488f
SM
73562018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7357 Pedro Alves <palves@redhat.com>
7358
7359 * value.c: Include "selftest.h" and "common/array-view.h".
7360 (struct range) <operator ==>: New.
7361 (test_ranges_contain): New.
7362 (check_ranges_vector): New.
7363 (test_insert_into_bit_range_vector): New.
7364 (_initialize_values): Register selftests.
7365 * common/array-view.h (operator==, operator!=): New.
7366
b24531ed
SM
73672018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7368
7369 * common/gdb_vecs.h (unordered_remove): Add overload that takes
7370 an iterator.
7371 * inline-frame.c: Include <algorithm>.
7372 (struct inline_state): Add constructor.
7373 (inline_state_s): Remove.
7374 (DEF_VEC_O(inline_state_s)): Remove.
7375 (inline_states): Change type to std::vector.
7376 (find_inline_frame_state): Adjust to std::vector.
7377 (allocate_inline_frame_state): Remove.
7378 (clear_inline_frame_state): Adjust to std::vector.
7379 (skip_inline_frames): Adjust to std::vector.
7380
c252925c
SM
73812018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7382
7383 * tracepoint.h (struct trace_state_variable): Add constructor.
7384 <name>: Change type to std::string.
7385 * tracepoint.c (tsv_s): Remove.
7386 (DEF_VEC_O(tsv_s)): Remove.
7387 (tvariables): Change to std::vector.
7388 (create_trace_state_variable): Adjust to std::vector.
7389 (find_trace_state_variable): Likewise.
7390 (find_trace_state_variable_by_number): Likewise.
7391 (delete_trace_state_variable): Likewise.
7392 (trace_variable_command): Adjust to std::string.
7393 (delete_trace_variable_command): Likewise.
7394 (tvariables_info_1): Adjust to std::vector.
7395 (save_trace_state_variables): Likewise.
7396 (start_tracing): Likewise.
7397 (merge_uploaded_trace_state_variables): Adjust to std::vector
7398 and std::string.
7399 * target.h (struct target_ops)
7400 <to_download_trace_state_variable>: Pass reference to
7401 trace_state_variable.
7402 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
7403 * target-delegates.c: Re-generate.
7404 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
7405 (mi_tsv_deleted): Likewise.
7406 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
7407 * remote.c (remote_download_trace_state_variable): Change
7408 pointer to reference and adjust.
7409 * make-target-delegates (parse_argtypes): Handle references.
7410 (write_function_header): Likewise.
7411 (munge_type): Likewise.
7412
c9638d26
SM
74132018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7414
7415 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
7416 string_view-selftests.c.
7417 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
7418 testsuite.
7419 * unittests/basic_string_view/cons/char/1.cc: Likewise.
7420 * unittests/basic_string_view/cons/char/2.cc: Likewise.
7421 * unittests/basic_string_view/cons/char/3.cc: Likewise.
7422 * unittests/basic_string_view/element_access/char/1.cc:
7423 Likewise.
7424 * unittests/basic_string_view/element_access/char/empty.cc:
7425 Likewise.
7426 * unittests/basic_string_view/element_access/char/front_back.cc:
7427 Likewise.
7428 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
7429 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
7430 Likewise.
7431 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
7432 Likewise.
7433 * unittests/basic_string_view/modifiers/swap/char/1.cc:
7434 Likewise.
7435 * unittests/basic_string_view/operations/compare/char/1.cc:
7436 Likewise.
7437 * unittests/basic_string_view/operations/compare/char/13650.cc:
7438 Likewise.
7439 * unittests/basic_string_view/operations/copy/char/1.cc:
7440 Likewise.
7441 * unittests/basic_string_view/operations/data/char/1.cc:
7442 Likewise.
7443 * unittests/basic_string_view/operations/find/char/1.cc:
7444 Likewise.
7445 * unittests/basic_string_view/operations/find/char/2.cc:
7446 Likewise.
7447 * unittests/basic_string_view/operations/find/char/3.cc:
7448 Likewise.
7449 * unittests/basic_string_view/operations/find/char/4.cc:
7450 Likewise.
7451 * unittests/basic_string_view/operations/rfind/char/1.cc:
7452 Likewise.
7453 * unittests/basic_string_view/operations/rfind/char/2.cc:
7454 Likewise.
7455 * unittests/basic_string_view/operations/rfind/char/3.cc:
7456 Likewise.
7457 * unittests/basic_string_view/operations/substr/char/1.cc:
7458 Likewise.
7459 * unittests/basic_string_view/operators/char/2.cc: Likewise.
7460 * unittests/string_view-selftests.c: New file.
7461
fdc11678
SM
74622018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7463
7464 * unittests/basic_string_view/capacity/1.cc: New file.
7465 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
7466 * unittests/basic_string_view/cons/char/1.cc: New file.
7467 * unittests/basic_string_view/cons/char/2.cc: New file.
7468 * unittests/basic_string_view/cons/char/3.cc: New file.
7469 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
7470 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
7471 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
7472 * unittests/basic_string_view/element_access/char/1.cc: New file.
7473 * unittests/basic_string_view/element_access/char/2.cc: New file.
7474 * unittests/basic_string_view/element_access/char/empty.cc: New file.
7475 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
7476 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
7477 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
7478 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
7479 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
7480 * unittests/basic_string_view/include.cc: New file.
7481 * unittests/basic_string_view/inserters/char/1.cc: New file.
7482 * unittests/basic_string_view/inserters/char/2.cc: New file.
7483 * unittests/basic_string_view/inserters/char/3.cc: New file.
7484 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
7485 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
7486 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
7487 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
7488 * unittests/basic_string_view/literals/types.cc: New file.
7489 * unittests/basic_string_view/literals/values.cc: New file.
7490 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
7491 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
7492 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
7493 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
7494 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
7495 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
7496 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
7497 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
7498 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
7499 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
7500 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
7501 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
7502 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
7503 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
7504 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
7505 * unittests/basic_string_view/operations/data/char/1.cc: New file.
7506 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
7507 * unittests/basic_string_view/operations/find/char/1.cc: New file.
7508 * unittests/basic_string_view/operations/find/char/2.cc: New file.
7509 * unittests/basic_string_view/operations/find/char/3.cc: New file.
7510 * unittests/basic_string_view/operations/find/char/4.cc: New file.
7511 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
7512 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
7513 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
7514 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
7515 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
7516 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
7517 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
7518 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
7519 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
7520 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
7521 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
7522 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
7523 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
7524 * unittests/basic_string_view/operators/char/2.cc: New file.
7525 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
7526 * unittests/basic_string_view/range_access/char/1.cc: New file.
7527 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
7528 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
7529 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
7530 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
7531 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
7532 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
7533 * unittests/basic_string_view/requirements/typedefs.cc: New file.
7534 * unittests/basic_string_view/typedefs.cc: New file.
7535 * unittests/basic_string_view/types/1.cc: New file.
7536
8345c4a2
SM
75372018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7538
7539 * common/gdb_string_view.h: Remove libstdc++ implementation
7540 details, adjust to gdb reality.
7541 * common/gdb_string_view.tcc: Likewise.
7542 * cli/cli-script.c (struct string_view): Remove.
7543 (user_args) <m_args>: Change element type to gdb::string_view.
7544 (user_args::insert_args): Adjust.
7545
7adcdf08
SM
75462018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7547
7548 * common/gdb_string_view.h: New file.
7549 * common/gdb_string_view.tcc: New file.
7550
41260ac2
SM
75512018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
7552
7553 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
7554 * configure: Re-generate.
7555
0bee6dd4
PA
75562018-04-09 Pedro Alves <palves@redhat.com>
7557
7558 * gdbarch.sh: Include "observable.h" instead of "observer.h".
7559 (set_target_gdbarch): Call
7560 gdb::observers::architecture_changed.notify instead of
7561 observer_notify_architecture_changed.
7562
6f14adc5
SM
75632018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7564
7565 * tracepoint.c (struct current_traceframe_cleanup): Remove.
7566 (do_restore_current_traceframe_cleanup): Remove.
7567 (restore_current_traceframe_cleanup_dtor): Remove.
7568 (make_cleanup_restore_current_traceframe): Remove.
7569 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
7570 New.
7571 * tracepoint.h (struct scoped_restore_current_traceframe): New.
7572 * infrun.c (fetch_inferior_event): Use
7573 scoped_restore_current_traceframe.
7574
b2bdb8cf
SM
75752018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7576
7577 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
7578 Remove.
7579 <n_allocated_type_units>: Remove.
7580 <all_type_units>: Change to std::vector.
7581 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7582 to std::vector change.
7583 (dwarf2_per_objfile::get_cutu): Likewise.
7584 (dwarf2_per_objfile::get_tu): Likewise.
7585 (create_signatured_type_table_from_index): Likewise.
7586 (create_signatured_type_table_from_debug_names): Likewise.
7587 (dw2_symtab_iter_next): Likewise.
7588 (dw2_print_stats): Likewise.
7589 (dw2_expand_all_symtabs): Likewise.
7590 (dw2_expand_marked_cus): Likewise.
7591 (dw2_debug_names_iterator::next): Likewise.
7592 (dwarf2_initialize_objfile): Likewise.
7593 (add_signatured_type_cu_to_table): Likewise.
7594 (create_all_type_units): Likewise.
7595 (add_type_unit): Likewise.
7596 (struct tu_abbrev_offset): Add constructor.
7597 (build_type_psymtabs_1): Adjust to std::vector change.
7598 (print_tu_stats): Likewise.
7599 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7600 (write_debug_names): Likewise.
7601
b76e467d
SM
76022018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7603
7604 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
7605 Make an std::vector.
7606 <n_comp_units>: Remove.
7607 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
7608 to std::vector change.
7609 (dwarf2_per_objfile::get_cutu): Likewise.
7610 (dwarf2_per_objfile::get_cu): Likewise.
7611 (create_cus_from_index): Likewise.
7612 (create_addrmap_from_index): Likewise.
7613 (create_addrmap_from_aranges): Likewise.
7614 (dwarf2_read_index): Likewise.
7615 (dw2_find_last_source_symtab): Likewise.
7616 (dw2_map_symtabs_matching_filename): Likewise.
7617 (dw2_symtab_iter_next): Likewise.
7618 (dw2_print_stats): Likewise.
7619 (dw2_expand_all_symtabs): Likewise.
7620 (dw2_expand_symtabs_with_fullname): Likewise.
7621 (dw2_expand_marked_cus): Likewise.
7622 (dw2_map_symbol_filenames): Likewise.
7623 (create_cus_from_debug_names): Likewise.
7624 (dwarf2_read_debug_names): Likewise.
7625 (dw2_debug_names_iterator::next): Likewise.
7626 (dwarf2_initialize_objfile): Likewise.
7627 (set_partial_user): Likewise.
7628 (dwarf2_build_psymtabs_hard): Likewise.
7629 (read_comp_units_from_section): Remove arguments, adjust to
7630 std::vector change.
7631 (create_all_comp_units): Adjust to std::vector and
7632 read_comp_units_from_section changes.
7633 (dwarf2_find_containing_comp_unit): Adjust to std::vector
7634 change.
7635 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
7636 (psyms_seen_size): Likewise.
7637 (write_gdbindex): Likewise.
7638 (write_debug_names): Likewise.
7639
12359b5e
SM
76402018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7641
7642 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
7643 with dwarf2_per_objfile.
7644 (create_cus_from_index): Likewise.
7645 (create_signatured_type_table_from_index): Likewise.
7646 (dwarf2_read_index): Likewise.
7647 (dwarf2_initialize_objfile): Likewise.
7648 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
7649 per_cu rather than get_dwarf2_per_objfile.
7650
ff4c9fec
SM
76512018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7652
7653 * dwarf2read.h (struct signatured_type): Forward declare.
7654 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
7655 New methods.
7656 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
7657 (dw2_get_cutu): ...this.
7658 (dwarf2_per_objfile::get_cu): Rename from...
7659 (dw2_get_cu): ...this.
7660 (dwarf2_per_objfile::get_tu): New.
7661 (create_addrmap_from_index): Adjust.
7662 (create_addrmap_from_aranges): Adjust.
7663 (dw2_find_last_source_symtab): Adjust.
7664 (dw2_map_symtabs_matching_filename): Adjust.
7665 (dw2_symtab_iter_next): Adjust.
7666 (dw2_print_stats): Adjust.
7667 (dw2_expand_all_symtabs): Adjust.
7668 (dw2_expand_symtabs_with_fullname): Adjust.
7669 (dw2_expand_marked_cus): Adjust.
7670 (dw_expand_symtabs_matching_file_matcher): Adjust.
7671 (dw2_map_symbol_filenames): Adjust.
7672 (dw2_debug_names_iterator::next): Adjust.
7673 (dwarf2_initialize_objfile): Adjust.
7674 (set_partial_user): Adjust.
7675 (dwarf2_build_psymtabs_hard): Adjust.
7676
5ca3fcb6
SM
76772018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7678
7679 * dwarf2read.c (create_signatured_type_table_from_debug_names):
7680 Remove unused variables.
7681 (dw2_map_symtabs_matching_filename): Likewise.
7682 (dwarf2_record_block_ranges): Likewise.
7683 (dwarf2_read_addr_index): Likewise.
7684 (follow_die_offset): Likewise.
7685
b2e586e8
SM
76862018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7687
7688 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
7689 to symbol_file_add_main.
7690
7c4e78cf
SM
76912018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7692
7693 PR mi/22299
7694 * mi/mi-console.c (do_fputc_async_safe): New.
7695 (mi_console_file::write_async_safe): New.
7696 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
7697 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
7698 New.
7699 * ui-file.c (ui_file::putstrn): Adjust call to
7700 fputstrn_unfiltered.
7701 * utils.c (printchar): Replace do_fputs and do_fprintf
7702 parameters by do_fputc.
7703 (fputstr_filtered): Adjust call to printchar.
7704 (fputstr_unfiltered): Likewise.
7705 (fputstrn_filtered): Likewise.
7706 (fputstrn_unfiltered): Add do_fputc parameter, pass to
7707 printchar.
7708 * utils.h (do_fputc_ftype): New typedef.
7709 (fputstrn_unfiltered): Add do_fputc parameter.
7710
5dc026d3
SM
77112018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
7712
7713 * regformats/i386/i386-avx.dat: Remove.
7714
c912f608
SM
77152018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7716
7717 PR gdb/22979
7718 * amd64-tdep.c (amd64_none_init_abi): New function.
7719 (amd64_x32_none_init_abi): New function.
7720 (_initialize_amd64_tdep): Register handlers for x86-64 and
7721 x64_32 with GDB_OSABI_NONE.
7722 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
7723 GDB_OSABI_NONE osabi.
7724
26540402
SM
77252018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7726
7727 PR gdb/22980
7728 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
7729 GDB_OSABI_NONE.
7730 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
7731 * osabi.c (gdb_osabi_names): Add "unknown" entry.
7732
9018be22
SM
77332018-04-07 Simon Marchi <simon.marchi@ericsson.com>
7734
7735 * common/byte-vector.h (char_vector): New type.
7736 * target.h (target_read_alloc): Return
7737 gdb::optional<byte_vector>.
7738 (target_read_stralloc): Return gdb::optional<char_vector>.
7739 (target_get_osdata): Return gdb::optional<char_vector>.
7740 * target.c (target_read_alloc_1): Templatize. Replacement
7741 manual memory management with vector.
7742 (target_read_alloc): Change return type, adjust.
7743 (target_read_stralloc): Change return type, adjust.
7744 (target_get_osdata): Change return type, adjust.
7745 * auxv.c (struct auxv_info) <length>: Remove.
7746 <data>: Change type to gdb::optional<byte_vector>.
7747 (auxv_inferior_data_cleanup): Free auxv_info with delete.
7748 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
7749 (target_auxv_search): Adjust.
7750 (fprint_target_auxv): Adjust.
7751 * avr-tdep.c (avr_io_reg_read_command): Adjust.
7752 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
7753 (linux_make_corefile_notes): Adjust.
7754 * osdata.c (get_osdata): Adjust.
7755 * remote.c (remote_get_threads_with_qxfer): Adjust.
7756 (remote_memory_map): Adjust.
7757 (remote_traceframe_info): Adjust.
7758 (btrace_read_config): Adjust.
7759 (remote_read_btrace): Adjust.
7760 (remote_pid_to_exec_file): Adjust.
7761 * solib-aix.c (solib_aix_get_library_list): Adjust.
7762 * solib-dsbt.c (decode_loadmap): Don't free buf.
7763 (dsbt_get_initial_loadmaps): Adjust.
7764 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
7765 * solib-target.c (solib_target_current_sos): Adjust.
7766 * tracepoint.c (sdata_make_value): Adjust.
7767 * xml-support.c (xinclude_start_include): Adjust.
7768 (xml_fetch_content_from_file): Adjust.
7769 * xml-support.h (xml_fetch_another): Change return type.
7770 (xml_fetch_content_from_file): Change return type.
7771 * xml-syscall.c (xml_init_syscalls_info): Adjust.
7772 * xml-tdesc.c (file_read_description_xml): Adjust.
7773 (fetch_available_features_from_target): Change return type.
7774 (target_fetch_description_xml): Adjust.
7775 (target_read_description_xml): Adjust.
7776
14c88955
TT
77772018-04-06 Tom Tromey <tom@tromey.com>
7778
7779 * value.c (~value): Update.
7780 (struct value) <contents>: Now unique_xmalloc_ptr.
7781 (value_contents_bits_eq, allocate_value_contents)
7782 (value_contents_raw, value_contents_all_raw)
7783 (value_contents_for_printing, value_contents_for_printing_const)
7784 (set_value_enclosing_type): Update.
7785
0c7e6dd8
TT
77862018-04-06 Tom Tromey <tom@tromey.com>
7787
7788 * value.c (range_s): Remove typedef, VEC.
7789 (struct range): Add operator<.
7790 (range_lessthan): Remove.
7791 (ranges_contain): Change type.
7792 (~value): Update.
7793 (struct value) <unavailable, optimized_out>: Now std::vector.
7794 (value_entirely_available)
7795 (value_entirely_covered_by_range_vector)
7796 (value_entirely_unavailable, value_entirely_optimized_out):
7797 Update.
7798 (insert_into_bit_range_vector): Change argument type.
7799 (find_first_range_overlap): Likewise.
7800 (struct ranges_and_idx, value_contents_bits_eq)
7801 (require_not_optimized_out, require_available): Update.
7802 (ranges_copy_adjusted): Change argument types.
7803 (value_optimized_out, value_copy, value_fetch_lazy): Update.
7804
2c8331b9
TT
78052018-04-06 Tom Tromey <tom@tromey.com>
7806
7807 * value.c (~value): Update.
7808 (struct value) <parent>: Now a value_ref_ptr.
7809 (value_parent, set_value_parent, value_address, value_copy):
7810 Update.
7811
466ce3ae
TT
78122018-04-06 Tom Tromey <tom@tromey.com>
7813
7814 * value.c (struct value): Add constructor, destructor, and member
7815 initializers.
7816 (allocate_value_lazy, value_decref): Update.
7817
062d818d
TT
78182018-04-06 Tom Tromey <tom@tromey.com>
7819
7820 * value.c (struct value) <released, next>: Remove.
7821 (all_values): Now a std::vector.
7822 (allocate_value_lazy): Update.
7823 (value_next): Remove.
7824 (value_mark, value_free_to_mark, release_value)
7825 (value_release_to_mark): Update.
7826
a6535de1
TT
78272018-04-06 Tom Tromey <tom@tromey.com>
7828
7829 * value.h (fetch_subexp_value, value_release_to_mark): Update.
7830 (free_value_chain): Remove.
7831 * value.c (free_value_chain): Remove.
7832 (value_release_to_mark): Return a std::vector.
7833 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
7834 std::vector.
7835 (check_condition): Update.
7836 * eval.c (fetch_subexp_value): Change "val_chain" to a
7837 std::vector.
7838 * breakpoint.c (update_watchpoint): Update.
7839 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
7840
b5621201
TT
78412018-04-06 Tom Tromey <tom@tromey.com>
7842
7843 * value.h (free_all_values): Remove.
7844 * value.c (free_all_values): Remove.
7845
4d0266a0
TT
78462018-04-06 Tom Tromey <tom@tromey.com>
7847
7848 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
7849 (value_history_chain, value_history_count): Remove.
7850 (value_history): New global.
7851 (record_latest_value, access_value_history, show_values)
7852 (preserve_values): Update.
7853
b4d61099
TT
78542018-04-06 Tom Tromey <tom@tromey.com>
7855
7856 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
7857 * varobj.c (varobj_set_display_format, varobj_set_value)
7858 (install_default_visualizer, construct_visualizer)
7859 (install_new_value, ~varobj, varobj_get_value_type)
7860 (my_value_of_variable, varobj_editable_p): Update.
7861 * c-varobj.c (c_describe_child, c_value_of_variable)
7862 (cplus_number_of_children, cplus_describe_child): Update.
7863 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
7864 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
7865 (ada_value_of_variable, ada_value_is_changeable_p): Update.
7866
9b558729
TT
78672018-04-06 Tom Tromey <tom@tromey.com>
7868
7869 * printcmd.c (last_examine_address): Change type to
7870 value_ref_ptr.
7871 (do_examine, x_command): Update.
7872
850645cf
TT
78732018-04-06 Tom Tromey <tom@tromey.com>
7874
7875 * value.c (release_value): Update.
7876 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
7877 (struct bpstats) <val>: Now a value_ref_ptr.
7878 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7879 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7880 (~watchpoint, print_it_watchpoint, watch_command_1)
7881 (invalidate_bp_value_on_memory_change): Update.
7882
22bc8444
TT
78832018-04-06 Tom Tromey <tom@tromey.com>
7884
7885 * varobj.c (varobj_clear_saved_item)
7886 (update_dynamic_varobj_children, install_new_value, ~varobj):
7887 Update.
7888 * value.h (value_incref): Move declaration earlier.
7889 (value_decref): Rename from value_free.
7890 (struct value_ref_policy): New.
7891 (value_ref_ptr): New typedef.
7892 (struct value_deleter): Remove.
7893 (gdb_value_up): Remove typedef.
7894 (release_value): Change return type.
7895 (release_value_or_incref): Remove.
7896 * value.c (set_value_parent): Update.
7897 (value_incref): Change return type.
7898 (value_decref): Rename from value_free.
7899 (value_free_to_mark, free_all_values, free_value_chain): Update.
7900 (release_value): Return value_ref_ptr.
7901 (release_value_or_incref): Remove.
7902 (record_latest_value, set_internalvar, clear_internalvar):
7903 Update.
7904 * stack.c (info_frame_command): Don't call value_free.
7905 * python/py-value.c (valpy_dealloc, valpy_new)
7906 (value_to_value_object): Update.
7907 * printcmd.c (do_examine): Update.
7908 * opencl-lang.c (lval_func_free_closure): Update.
7909 * mi/mi-main.c (register_changed_p): Don't call value_free.
7910 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
7911 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
7912 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
7913 value_free.
7914 * guile/scm-value.c (vlscm_free_value_smob)
7915 (vlscm_scm_from_value): Update.
7916 * frame.c (frame_register_unwind, frame_unwind_register_signed)
7917 (frame_unwind_register_unsigned, get_frame_register_bytes)
7918 (put_frame_register_bytes): Don't call value_free.
7919 * findvar.c (address_from_register): Don't call value_free.
7920 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
7921 * dwarf2loc.c (entry_data_value_free_closure)
7922 (value_of_dwarf_reg_entry, free_pieced_value_closure)
7923 (dwarf2_evaluate_loc_desc_full): Update.
7924 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
7925 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
7926 (~watchpoint, watch_command_1)
7927 (invalidate_bp_value_on_memory_change): Update.
7928 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
7929
7f8a5d38
SM
79302018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
7931
7932 PR gdb/23022
7933 * warning.m4: Add -Wno-error=deprecated-register.
7934 * configure: Re-generate.
7935
8a76bd3b
TT
79362018-04-05 Tom Tromey <tom@tromey.com>
7937
7938 * linespec.h: Remove include of "vec.h".
7939
8e8d776e
TT
79402018-04-05 Tom Tromey <tom@tromey.com>
7941
7942 * linespec.c (typep): Remove typedef.
7943 (find_methods, find_superclass_methods): Take a std::vector.
7944 (find_method): Use std::vector.
7945
9b2f8581
TT
79462018-04-05 Tom Tromey <tom@tromey.com>
7947
7948 * utils.c (compare_strings): Remove.
7949 * utils.h (compare_strings): Remove.
7950 * objc-lang.h (find_imps): Update.
7951 * objc-lang.c (find_methods): Take a std::vector.
7952 (uniquify_strings, find_imps): Likewise.
7953 * linespec.c (find_methods): Take a std::vector.
7954 (decode_objc): Use std::vector.
7955 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
7956 a std::vector.
7957 (find_method, find_function_symbols): Use std::vector.
7958
459a2e4c
TT
79592018-04-05 Tom Tromey <tom@tromey.com>
7960
7961 * completer.c (completion_tracker::completion_tracker): Remove
7962 cast.
7963 (completion_tracker::discard_completions): Likewise.
7964 * breakpoint.c (ambiguous_names_p): Remove cast.
7965 * ada-lang.c (_initialize_ada_language): Remove cast.
7966 * utils.h (streq): Update.
7967 (streq_hash): Add new declaration.
7968 * utils.c (streq): Return bool.
7969 (streq_hash): New function.
7970
9be2c17a
TT
79712018-04-05 Tom Tromey <tom@tromey.com>
7972
7973 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
7974 Remove a string copy.
7975
f73c6ece
TT
79762018-04-05 Tom Tromey <tom@tromey.com>
7977
7978 * linespec.c (filter_results): Use std::vector.
7979 (decode_line_2, decode_line_full): Update.
7980
53a0f8a2
TT
79812018-04-05 Tom Tromey <tom@tromey.com>
7982
7983 * linespec.c (canonical_to_fullform): Return std::string.
7984 (filter_results): Update.
7985 (struct decode_line_2_item): Add constructor.
7986 <fullform, displayform>: Now std::string.
7987 (decode_line_2_compare_items): Now a std::sort comparator.
7988 (decode_line_2): Update.
7989
a5b5adf5
TT
79902018-04-05 Tom Tromey <tom@tromey.com>
7991
7992 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
7993 (unexpected_linespec_error): Update.
7994 (linespec_parse_basic, parse_linespec): Update.
7995
6a307fc5
TT
79962018-04-05 Tom Tromey <tom@tromey.com>
7997
7998 * linespec.c (linespec_parse_basic): Reindent.
7999
41c1efc6
TT
80002018-04-05 Tom Tromey <tom@tromey.com>
8001
8002 * minsyms.h (iterate_over_minimal_symbols): Update.
8003 * minsyms.c (iterate_over_minimal_symbols): Take a
8004 gdb::function_view.
8005 * linespec.c (struct collect_minsyms): Remove.
8006 (compare_msyms): Now a std::sort comparator.
8007 (add_minsym): Add parameters.
8008 (search_minsyms_for_name): Update. Use std::vector.
8009
c5edbf3d
TT
80102018-04-03 Tom Tromey <tom@tromey.com>
8011
8012 * mipsread.c (read_alphacoff_dynamic_symtab): Use
8013 gdb::byte_vector.
8014
b39efc48
WP
80152018-04-02 Weimin Pan <weimin.pan@oracle.com>
8016
8017 * MAINTAINERS (Write After Approval): Add Weimin Pan.
8018
121ad66c 80192018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
8020
8021 PR gdb/16959
8022 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
8023 printing static type.
8024
09473be8
TT
80252018-04-01 Tom Tromey <tom@tromey.com>
8026
8027 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
8028 (rs6000_xfer_shared_libraries): Update.
8029
ec1f2d91
SM
80302018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
8031
8032 * common/gdb_vecs.h (char_ptr): Remove.
8033 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
8034
d8611974
SM
80352018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8036
8037 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
8038 with std::vector.
8039 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
8040
a18ba4e4
SM
80412018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
8042
8043 * tracepoint.h (struct uploaded_tp): Initialize fields.
8044 <actions, step_actions, cmd_strings>: Change type to
8045 std::vector<char *>.
8046 * tracepoint.c (get_uploaded_tp): Allocate with new.
8047 (free_uploaded_tps): Free with delete.
8048 (parse_tracepoint_definition): Adjust to std::vector change.
8049 * breakpoint.c (read_uploaded_action): Likewise.
8050 (create_tracepoint_from_upload): Likewise.
8051 * ctf.c (ctf_write_uploaded_tp): Likewise.
8052 (SET_ARRAY_FIELD): Likewise.
8053 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
8054
a7961323
TT
80552018-03-30 Tom Tromey <tom@tromey.com>
8056
8057 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
8058 std::unique_ptr.
8059 (svr4_keep_data_in_core): Update.
8060 (svr4_read_so_list): Update.
8061
e83e4e24
TT
80622018-03-30 Tom Tromey <tom@tromey.com>
8063
8064 * windows-nat.c (handle_output_debug_string, handle_exception):
8065 Update.
8066 * target.h (target_read_string): Update.
8067 * target.c (target_read_string): Change "string" to
8068 unique_xmalloc_ptr.
8069 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
8070 Update.
8071 * solib-frv.c (frv_current_sos): Update.
8072 * solib-dsbt.c (dsbt_current_sos): Update.
8073 * solib-darwin.c (darwin_current_sos): Update.
8074 * linux-thread-db.c (inferior_has_bug): Update.
8075 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
8076 Update. Remove alloca.
8077 * ada-lang.c (ada_main_name): Update.
8078
263db9a1
TT
80792018-03-30 Tom Tromey <tom@tromey.com>
8080
8081 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
8082 (struct dwo_file_deleter): New.
8083 (dwo_file_up): New typedef.
8084 (open_and_init_dwo_file): Use dwo_file_up.
8085 (free_dwo_file_cleanup): Remove.
8086
5dafb3d1
TT
80872018-03-30 Tom Tromey <tom@tromey.com>
8088
8089 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
8090 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
8091
11ed8cad
TT
80922018-03-30 Tom Tromey <tom@tromey.com>
8093
8094 * dwarf2read.c (class free_cached_comp_units): New class.
8095 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
8096 (free_cached_comp_units): Remove function.
8097
9ae79dac
TT
80982018-03-30 Tom Tromey <tom@tromey.com>
8099
8100 * utils.h (make_cleanup_unpush_target): Remove.
8101 * inf-ptrace.c (struct target_unpusher): New.
8102 (target_unpush_up) New typedef.
8103 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
8104 target_unpush_up.
8105 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
8106
5aa89276
TT
81072018-03-27 Tom Tromey <tom@tromey.com>
8108
8109 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
8110
1dbeed45
TT
81112018-03-27 Pedro Alves <palves@redhat.com>
8112 Tom Tromey <tom@tromey.com>
8113
8114 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
8115 destructor. Now a class.
8116 (gdb_readline_wrapper_cleanup): Remove function.
8117 (gdb_readline_wrapper): Remove cleanups.
8118
c819b2c0
TT
81192018-03-27 Tom Tromey <tom@tromey.com>
8120
8121 * typeprint.h (struct type_print_options) <local_typedefs,
8122 global_typedefs>: Remove "struct" keyword.
8123 (class typedef_hash_table): New class.
8124 (recursively_update_typedef_hash, add_template_parameters)
8125 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
8126 (find_typedef_in_hash): Don't declare.
8127 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
8128 (typedef_hash_table::recursively_update): Rename from
8129 recursively_update_typedef_hash. Now a member.
8130 (typedef_hash_table::add_template_parameters): Rename from
8131 add_template_parameters. Now a member.
8132 (typedef_hash_table::typedef_hash_table): Now a constructor;
8133 rename from create_typedef_hash.
8134 (typedef_hash_table::~typedef_hash_table): Now a destructor;
8135 rename from free_typedef_hash.
8136 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
8137 (do_free_global_table): Remove.
8138 (typedef_hash_table::typedef_hash_table): New constructor; renamed
8139 from copy_type_recursive.
8140 (create_global_typedef_table): Remove.
8141 (typedef_hash_table::find_global_typedef): Now a member of
8142 typedef_hash_table.
8143 (typedef_hash_table::find_typedef): Rename from
8144 find_typedef_in_hash; now a member.
8145 (whatis_exp): Update.
8146 * extension.h (struct ext_lang_type_printers): Add constructor and
8147 destructor.
8148 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
8149 declare.
8150 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
8151 Now a constructor; rename from start_ext_lang_type_printers.
8152 (ext_lang_type_printers): Now a destructor; rename from
8153 free_ext_lang_type_printers.
8154 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
8155 Update.
8156 (c_type_print_base_struct_union): Update. Remove cleanups.
8157
608219fb
TT
81582018-03-27 Tom Tromey <tom@tromey.com>
8159
8160 * dwarf-index-write.c: Include <cmath>.
8161
3fcded8f
JB
81622018-03-27 Joel Brobecker <brobecker@adacore.com>
8163
8164 * NEWS: Add entry describing new "set|show varsize-limit" command.
8165 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
8166 command.
8167 * printcmd.c (_initialize_printcmd): Add "set var" alias of
8168 "set variable".
8169
cd4fb1b2
SM
81702018-03-27 Simon Marchi <simon.marchi@ericsson.com>
8171
8172 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
8173 dwarf-index-write.c
8174 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
8175 * dwarf-index-common.c: New file.
8176 * dwarf-index-common.h: New file.
8177 * dwarf-index-write.c: New file.
8178 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
8179 (struct dwarf2_section_info): Move from here.
8180 (dwarf2_section_info_def): Likewise.
8181 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
8182 (offset_type): Likewise.
8183 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
8184 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
8185 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
8186 (byte_swap): Likewise.
8187 (MAYBE_SWAP): Likewise.
8188 (dwarf2_per_cu_ptr): Likewise.
8189 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
8190 (struct tu_stats): Likewise.
8191 (struct dwarf2_per_objfile): Likewise.
8192 (struct dwarf2_per_cu_data): Likewise.
8193 (struct signatured_type): Likewise.
8194 (sig_type_ptr): Likewise.
8195 (DEF_VEC_P (sig_type_ptr)): Likewise.
8196 (INDEX4_SUFFIX): Likewise.
8197 (INDEX5_SUFFIX): Likewise.
8198 (DEBUG_STR_SUFFIX): Likewise.
8199 (dwarf2_read_section): Make non-static.
8200 (mapped_index_string_hash): Move from here.
8201 (dwarf5_djb_hash): Likewise.
8202 (file_write): Likewise.
8203 (class data_buf): Likewise.
8204 (struct symtab_index_entry): Likewise.
8205 (struct mapped_symtab): Likewise.
8206 (find_slot): Likewise.
8207 (hash_expand): Likewise.
8208 (add_index_entry): Likewise.
8209 (uniquify_cu_indices): Likewise.
8210 (class c_str_view): Likewise.
8211 (class c_str_view_hasher): Likewise.
8212 (class vector_hasher): Likewise.
8213 (write_hash_table): Likewise.
8214 (psym_index_map): Likewise.
8215 (struct addrmap_index_data): Likewise.
8216 (add_address_entry): Likewise.
8217 (add_address_entry_worker): Likewise.
8218 (write_address_map): Likewise.
8219 (symbol_kind): Likewise.
8220 (write_psymbols): Likewise.
8221 (struct signatured_type_index_data): Likewise.
8222 (write_one_signatured_type): Likewise.
8223 (recursively_count_psymbols): Likewise.
8224 (recursively_write_psymbols): Likewise.
8225 (class debug_names): Likewise.
8226 (check_dwarf64_offsets): Likewise.
8227 (psyms_seen_size): Likewise.
8228 (write_gdbindex): Likewise.
8229 (write_debug_names): Likewise.
8230 (assert_file_size): Likewise.
8231 (write_psymtabs_to_index): Likewise.
8232 (save_gdb_index_command): Likewise.
8233 (_initialize_dwarf2_read): Don't register the "save gdb-index"
8234 command.
8235 * dwarf2read.h: New file.
8236
59cc4834
JB
82372018-03-27 Joel Brobecker <brobecker@adacore.com>
8238
8239 PR gdb/22670
8240 * dwarf2read.c (dwarf2_physname): Do not return the demangled
8241 symbol name if the CU's language stores symbol names in linkage
8242 format.
8243 * language.h (struct language_defn)
8244 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
8245 all instances of this struct.
8246
67501539
TT
82472018-03-26 Tom Tromey <tom@tromey.com>
8248
8249 * stack.c (backtrace_command_1): Remove verbose code.
8250
76c939ac
TT
82512018-03-26 Tom Tromey <tom@tromey.com>
8252
8253 * python/py-framefilter.c (py_print_type): Don't catch
8254 exceptions. Return void.
8255 (py_print_value): Likewise.
8256 (py_print_single_arg): Likewise.
8257 (enumerate_args): Don't catch exceptions.
8258 (py_print_args): Likewise.
8259 (py_print_frame): Likewise.
8260 (gdbpy_apply_frame_filter): Catch exceptions here.
8261
9507b29c
TT
82622018-03-26 Tom Tromey <tom@tromey.com>
8263
8264 * stack.c (_initialize_stack): Remove trailing newlines from help
8265 text. Add "Usage" line to "backtrace" help.
8266
eb68e487
TT
82672018-03-26 Tom Tromey <tom@tromey.com>
8268
8269 PR python/16486:
8270 * python/py-framefilter.c (py_print_args): Call wrap_hint.
8271
1f111921
TT
82722018-03-26 Tom Tromey <tom@tromey.com>
8273
8274 * python/py-framefilter.c (py_print_single_arg): Return
8275 EXT_LANG_BT_ERROR from catch.
8276
fb7eb8b5
TT
82772018-03-26 Tom Tromey <tom@tromey.com>
8278
8279 PR backtrace/15584:
8280 * stack.c (backtrace_command_1): Move some code into no-filters
8281 "if".
8282
4ca59a9f
TT
82832018-03-26 Tom Tromey <tom@tromey.com>
8284
8285 * python/py-framefilter.c (throw_quit_or_print_exception): New
8286 function.
8287 (gdbpy_apply_frame_filter): Use it.
8288
92256134
TT
82892018-03-26 Tom Tromey <tom@tromey.com>
8290
8291 PR cli/17716:
8292 * python/py-framefilter.c (py_print_type, py_print_value)
8293 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
8294 RETURN_MASK_ERROR.
8295
7a630bc2
TT
82962018-03-26 Tom Tromey <tom@tromey.com>
8297
8298 * python/py-framefilter.c (enumerate_args): Use
8299 gdb::unique_xmalloc_ptr.
8300
63283d4a
TT
83012018-03-26 Tom Tromey <tom@tromey.com>
8302
8303 * python/py-framefilter.c (py_print_frame): Return
8304 EXT_LANG_BT_OK.
8305 (gdbpy_apply_frame_filter): Update comment.
8306 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
8307 Remove.
8308 <EXT_LANG_BT_NO_FILTERS>: Change value.
8309
978d6c75
TT
83102018-03-26 Tom Tromey <tom@tromey.com>
8311
8312 PR backtrace/15582:
8313 * stack.c (backtrace_command): Parse "hide" argument.
8314 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
8315 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
8316 constant.
8317
1cf7e640
TT
83182018-03-26 Tom Tromey <tom@tromey.com>
8319
8320 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
8321 add "flags".
8322 (backtrace_command): Remove "fulltrace", add "flags".
8323
ea3b0687
TT
83242018-03-26 Tom Tromey <tom@tromey.com>
8325
8326 * stack.c (backtrace_command): Rewrite command line parsing.
8327
9f034d75
SM
83282018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8329
8330 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
8331
ce1459e5
SM
83322018-03-26 Simon Marchi <simon.marchi@ericsson.com>
8333
8334 * filename-seen-cache.h: Add include guard.
8335
4f7ae6f5
KS
83362018-03-26 Keith Seitz <keiths@redhat.com>
8337
8338 * symfile.c (place_section): Remove "struct" from section_addr_info
8339 in comment.
8340 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
8341 "struct" keyword from section_addr_info.
8342
5cd3e386
AH
83432018-03-26 Alan Hayward <alan.hayward@arm.com>
8344
8345 * regformats/regdef.h (reg): Add constructors.
8346
3e5ef9a4
PA
83472018-03-25 Pedro Alves <palves@redhat.com>
8348
8349 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
8350 if then/else bodies in var_func_name extraction.
8351
c88d2fcc 83522018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
8353
8354 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
8355 lookup_minimal_symbol() to find symbol entry.
8356 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
8357
b7fee5a3
KS
83582018-03-23 Keith Seitz <keiths@redhat.com>
8359
8360 PR c++/22968
8361 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
8362 nested type definitions for C++, too.
8363
2cc9b304
TT
83642018-03-23 Tom Tromey <tom@tromey.com>
8365
8366 * machoread.c (struct oso_el): Add a constructor. Don't define as
8367 a typedef.
8368 (macho_register_oso): Remove.
8369 (macho_symtab_read): Take a std::vector.
8370 (oso_el_compare_name): Now a std::sort comparator.
8371 (macho_symfile_read_all_oso): Take a std::vector.
8372 (macho_symfile_read): Use std::vector. Remove cleanups.
8373
a2b2bc12
TT
83742018-03-22 Tom Tromey <tom@tromey.com>
8375
8376 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
8377 (record_full_goto_bookmark): Use std::string.
8378
7a8f494c
PFC
83792018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8380
8381 PR tdep/18295
8382 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
8383 a single mask.
8384
dd6d677f
PFC
83852018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8386
8387 * rs6000-tdep.c (store_insn_p): New function.
8388 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
8389 and cr_reg to their unshifted values. Use store_insn_p to
8390 match LR saves using either R1 or fdata->alloca_reg. Use
8391 store_insn_p to match CR saves. Set alloca_reg_offset
8392 when alloca_reg and framep are set. Remove lr_reg shift
8393 when assigning to fdata->lr_register.
8394
26d6cec4
AA
83952018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
8396
8397 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
8398 command line args instead of emitting a warning.
8399
5d9310c4
SM
84002018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8401
8402 * tracepoint.h (struct static_tracepoint_marker): Initialize
8403 fields, define default constructor, move constructor and move
8404 assignment, disable the rest.
8405 <str_id, extra>: Make std::string.
8406 (release_static_tracepoint_marker): Remove.
8407 (free_current_marker): Remove.
8408 * tracepoint.c (free_current_marker): Remove.
8409 (parse_static_tracepoint_marker_definition): Adjust to
8410 std::string, use new hex2str overload.
8411 (release_static_tracepoint_marker): Remove.
8412 (print_one_static_tracepoint_marker): Get marker by reference
8413 and adjust to std::string.
8414 (info_static_tracepoint_markers_command): Adjust to std::vector
8415 changes
8416 * target.h (static_tracepoint_marker_p): Remove typedef.
8417 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
8418 (struct target_ops) <to_static_tracepoint_marker_at>: Return
8419 bool.
8420 <to_static_tracepoint_markers_by_strid>: Return std::vector.
8421 * target-debug.h
8422 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
8423 (target_debug_print_std_vector_static_tracepoint_marker): New.
8424 (target_debug_print_struct_static_tracepoint_marker_p): Rename
8425 to...
8426 (target_debug_print_static_tracepoint_marker_p): ... this.
8427 * target-delegates.c: Re-generate.
8428 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
8429 Make std::string.
8430 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
8431 (decode_static_tracepoint_spec): Adjust to std::vector.
8432 (tracepoint_print_one_detail): Adjust to std::string.
8433 (strace_marker_decode_location): Adjust to std::string.
8434 (update_static_tracepoint): Adjust to std::string, remove call
8435 to release_static_tracepoint_marker.
8436 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
8437 Adjust to std::vector.
8438 * remote.c (remote_static_tracepoint_marker_at): Return bool.
8439 (remote_static_tracepoint_markers_by_strid): Adjust to
8440 std::vector.
8441 * common/rsp-low.h (hex2str): New overload with explicit count
8442 of bytes.
8443 * common/rsp-low.c (hex2str): New overload with explicit count
8444 of bytes.
8445 * unittests/rsp-low-selftests.c (test_hex2str): New function.
8446 (_initialize_rsp_low_selftests): Add test_hex2str test.
8447 * unittests/tracepoint-selftests.c
8448 (test_parse_static_tracepoint_marker_definition): Adjust to
8449 std::string.
8450
62c222b6
SM
84512018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
8452
8453 * tracepoint.c (parse_static_tracepoint_marker_definition):
8454 Consider case where the definition is followed by more
8455 definitions.
8456 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8457 tracepoint-selftests.c.
8458 * unittests/tracepoint-selftests.c: New.
8459
7eb2418f
PFC
84602018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
8461
8462 * MAINTAINERS (Write After Approval): Add Pedro Franco de
8463 Carvalho.
8464
7cbe16e9
SR
84652018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8466
3d6b3b82 8467 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 8468
4ee89e90
SR
84692018-03-20 Stephen Roberts <stephen.roberts@arm.com>
8470
3d6b3b82 8471 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 8472
92630041
TT
84732018-03-19 Tom Tromey <tom@tromey.com>
8474
8475 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
8476 "IDENT" production.
8477
76727919
TT
84782018-03-19 Pedro Alves <palves@redhat.com>
8479 Tom Tromey <tom@tromey.com>
8480
8481 * unittests/observable-selftests.c: New file.
8482 * common/observable.h: New file.
8483 * observable.h: New file.
8484 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
8485 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
8486 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
8487 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
8488 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
8489 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
8490 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
8491 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
8492 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
8493 python/py-breakpoint.c, python/py-finishbreakpoint.c,
8494 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
8495 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
8496 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
8497 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
8498 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
8499 tui/tui-interp.c, valops.c: Update all users.
8500 * tui/tui-hooks.c (tui_bp_created_observer)
8501 (tui_bp_deleted_observer, tui_bp_modified_observer)
8502 (tui_inferior_exit_observer, tui_before_prompt_observer)
8503 (tui_normal_stop_observer, tui_register_changed_observer):
8504 Remove.
8505 (tui_observers_token): New global.
8506 (attach_or_detach, tui_attach_detach_observers): New functions.
8507 (tui_install_hooks, tui_remove_hooks): Use
8508 tui_attach_detach_observers.
8509 * record-btrace.c (record_btrace_thread_observer): Remove.
8510 (record_btrace_thread_observer_token): New global.
8511 * observer.sh: Remove.
8512 * observer.c: Rename to observable.c.
8513 * observable.c (namespace gdb_observers): Define new objects.
8514 (observer_debug): Move into gdb_observers namespace.
8515 (struct observer, struct observer_list, xalloc_observer_list_node)
8516 (xfree_observer_list_node, generic_observer_attach)
8517 (generic_observer_detach, generic_observer_notify): Remove.
8518 (_initialize_observer): Update.
8519 Don't include observer.inc.
8520 * Makefile.in (generated_files): Remove observer.h, observer.inc.
8521 (clean mostlyclean): Likewise.
8522 (observer.h, observer.inc): Remove targets.
8523 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
8524 (COMMON_SFILES): Use observable.c, not observer.c.
8525 * .gitignore: Remove observer.h.
8526
1cb1f3da
TT
85272018-03-18 Tom Tromey <tom@tromey.com>
8528
8529 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
8530 gdb::def_vector.
8531 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
8532
a06ab151
TT
85332018-03-17 Tom Tromey <tom@tromey.com>
8534
8535 * auto-load.c (auto_load_objfile_script_1): Use std::string.
8536
770623f7
TT
85372018-03-17 Tom Tromey <tom@tromey.com>
8538
8539 * target.c (class scoped_target_fd): New.
8540 (target_fileio_close_cleanup): Remove.
8541 (target_fileio_read_alloc_1): Use scoped_target_fd.
8542
39be3c7e
SM
85432018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
8544
8545 * silent-rules.mk: New.
8546 * Makefile.in: Include silent-rules.mk
8547 (srcdir, VPATH, top_srcdir): Move up.
8548 (COMPILE): Add ECHO_CXX.
8549 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
8550 (init.c): Add ECHO_INIT_C.
8551 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
8552 (version.c): Add ECHO_GEN.
8553 (printcmd.o): Add ECHO_CXX.
8554 (target-float.o): Add ECHO_CXX.
8555 (ada-exp.o): Add ECHO_CXX.
8556 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
8557 (insight$(EXEEXT)): Add ECHO_CXXLD.
8558 * gnulib/configure.ac: Add AM_SILENT_RULES.
8559 * gnulib/aclocal.m4: Re-generate.
8560 * gnulib/configure: Re-generate.
8561 * gnulib/import/Makefile.in: Re-generate.
8562
37e136b1
TT
85632018-03-16 Tom Tromey <tom@tromey.com>
8564
8565 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
8566 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
8567 * utils.c (do_free_section_addr_info)
8568 (make_cleanup_free_section_addr_info): Remove.
8569 * symfile.h (struct other_sections): Add constructor.
8570 (struct section_addr_info): Remove.
8571 (section_addr_info): New typedef.
8572 (struct sym_fns) <sym_offsets>: Change type of parameter.
8573 (build_section_addr_info_from_objfile)
8574 (relative_addr_info_to_section_offsets, addr_info_make_relative)
8575 (default_symfile_offsets, symbol_file_add)
8576 (symbol_file_add_from_bfd)
8577 (build_section_addr_info_from_section_table): Update.
8578 (alloc_section_addr_info, free_section_addr_info): Don't declare.
8579 * symfile.c (alloc_section_addr_info): Remove.
8580 (build_section_addr_info_from_section_table): Change return type.
8581 Update.
8582 (build_section_addr_info_from_bfd)
8583 (build_section_addr_info_from_objfile): Likewise.
8584 (free_section_addr_info): Remove.
8585 (relative_addr_info_to_section_offsets): Change type of "addrs".
8586 (addrs_section_compar): Now a std::sort comparator.
8587 (addrs_section_sort): Change return type.
8588 (addr_info_make_relative): Change type of "addrs". Update.
8589 (default_symfile_offsets, syms_from_objfile_1)
8590 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
8591 (symbol_file_add_separate): Update.
8592 (symbol_file_add): Change type of "addrs". Update.
8593 (add_symbol_file_command): Update. Remove cleanups.
8594 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
8595 cleanups.
8596 * symfile-debug.c (debug_sym_offsets): Change type of "info".
8597 * solib.c (solib_read_symbols): Update.
8598 * objfiles.c (objfile_relocate): Update. Remove cleanups.
8599 * machoread.c (macho_symfile_offsets): Update.
8600 * jit.c (jit_bfd_try_read_symtab): Update.
8601
03afa6ef
SM
86022018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
8603
8604 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
8605 unittests/utils-selftests.c.
8606 * unittests/utils-selftests.c: New file.
8607
3ae9ce5d
TT
86082018-03-14 Tom Tromey <tom@tromey.com>
8609
8610 PR cli/14977:
8611 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
8612 for NULL.
8613
b8c2339b
TT
86142018-03-14 Tom Tromey <tom@tromey.com>
8615
8616 PR cli/19918:
8617 * printcmd.c (printf_pointer): Allow "-" in format.
8618
80ae639d
TT
86192018-03-14 Tom Tromey <tom@tromey.com>
8620
8621 * printcmd.c (_initialize_printcmd): Add usage to printf.
8622
0d671d99
YQ
86232018-03-14 Yao Qi <qiyao@sourceware.org>
8624
8625 * MAINTAINERS: Update my email address.
8626
b577b6af
TT
86272018-03-13 Tom Tromey <tom@tromey.com>
8628
8629 * machoread.c (macho_check_dsym): Change filenamep to a
8630 std::string*.
8631 (macho_symfile_read): Update.
8632 * symfile.c (load_command): Use std::string.
8633
89a3b63e
AB
86342018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
8635
8636 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
8637 to error message string.
8638 (riscv_register_name): Use xsnprintf instead of sprintf.
8639 (riscv_insn::fetch_instruction): Use gdb_assert instead of
8640 internal_error.
8641 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
8642 error.
8643 (riscv_push_dummy_call): Likewise.
8644
984c7238
TT
86452018-03-12 Tom Tromey <tom@tromey.com>
8646
8647 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
8648 Use gdb::byte_vector.
8649 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
8650
933522d1
YQ
86512018-03-12 Yao Qi <yao.qi@linaro.org>
8652
8653 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
8654 parameter type to readable_regcache.
8655 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
8656 the declaration.
8657
be2daae6
TT
86582018-03-11 Tom Tromey <tom@tromey.com>
8659
8660 * dwarf2read.c (struct nextfield): Add initializers.
8661 (struct nextfnfield): Remove.
8662 (struct fnfieldlist): Add initializers. Remove "length" and
8663 "head", use std::vector.
8664 (struct decl_field_list): Remove.
8665 (struct field_info): Add initializers.
8666 <fields, baseclasses>: Now std::vector.
8667 <nbaseclasses, nfnfields, typedef_field_list_count,
8668 nested_types_list_count>: Remove.
8669 (dwarf2_add_field, dwarf2_add_type_defn)
8670 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
8671 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
8672 (process_structure_scope): Update.
8673
484cf504
TT
86742018-03-11 Tom Tromey <tom@tromey.com>
8675
8676 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
8677 for use by std::sort.
8678 (build_type_psymtabs_1): Use std::vector.
8679
9bd8e0b0
EZ
86802018-03-09 Eli Zaretskii <eliz@gnu.org>
8681
8682 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
8683 and LIBMPFR in the printed configuration.
8684
5dc1a704
TT
86852018-03-08 Tom Tromey <tom@tromey.com>
8686
8687 * source.c (get_filename_and_charpos): Use scoped_fd.
8688 * nto-procfs.c (procfs_open_1): Use scoped_fd.
8689 (procfs_pidlist): Likewise.
8690 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
8691 (iterate_over_mappings): Likewise.
8692
fdf07f3a
TT
86932018-03-08 Tom Tromey <tom@tromey.com>
8694
8695 * infcall.c (struct call_return_meta_info)
8696 <stack_temporaries_enabled>: Remove.
8697 (get_call_return_value, call_function_by_hand_dummy): Update.
8698 * thread.c (disable_thread_stack_temporaries): Remove.
8699 (enable_thread_stack_temporaries): Remove.
8700 (thread_stack_temporaries_enabled_p): Return bool.
8701 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
8702 (get_last_thread_stack_temporary): Update.
8703 * eval.c (evaluate_subexp): Update.
8704 * gdbthread.h (class enable_thread_stack_temporaries): Now a
8705 class, not a function.
8706 (value_ptr, value_vec): Remove typedefs.
8707 (class thread_info) <stack_temporaries_enabled>: Now bool.
8708 <stack_temporaries>: Now a std::vector.
8709 (thread_stack_temporaries_enabled_p)
8710 (value_in_thread_stack_temporaries): Return bool.
8711
567a3e54
SM
87122018-03-08 Simon Marchi <simon.marchi@ericsson.com>
8713
8714 * remote.c (putpkt_binary): Fix omitted bytes reporting.
8715 (getpkt_or_notif_sane_1): Likewise.
8716
00b40057
SM
87172018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8718
8719 * build-id.c (build_id_to_debug_bfd): Use std::string.
8720
a8dbfd58
SM
87212018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8722
8723 * build-id.c (find_separate_debug_file_by_buildid): Return
8724 std::string.
8725 * build-id.h (find_separate_debug_file_by_buildid): Return
8726 std::string.
8727 * coffread.c (coff_symfile_read): Adjust to std::string.
8728 * elfread.c (elf_symfile_read): Adjust to std::string.
8729 * symfile.c (separate_debug_file_exists): Change parameter to
8730 std::string.
8731 (find_separate_debug_file): Return std::string.
8732 (find_separate_debug_file_by_debuglink): Return std::string.
8733 * symfile.h (find_separate_debug_file_by_debuglink): Return
8734 std::string.
8735
e6a58aa8
SM
87362018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
8737
8738 * common/xml-utils.c (xml_escape_text): Move code to...
8739 (xml_escape_text_append): ... this new function.
8740 * common/xml-utils.h (xml_escape_text_append): New declaration.
8741 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
8742 New function.
8743 (_initialize_xml_utils): register test_xml_escape_text_append as
8744 a selftest.
8745
4ef0bef6
AH
87462018-03-07 Alan Hayward <alan.hayward@arm.com>
8747
8748 * defs.h: Remove MAX_REGISTER_SIZE.
8749 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
8750 asserts.
8751 * python/py-unwind.c (pyuw_sniffer): Likewise.
8752
e0d3522b
TT
87532018-03-07 Tom Tromey <tom@tromey.com>
8754
8755 * linux-tdep.c (linux_info_proc): Update.
8756 * target.h (struct target_ops) <to_fileio_readlink>: Return
8757 optional<string>.
8758 (target_fileio_readlink): Return optional<string>.
8759 * remote.c (remote_hostio_readlink): Return optional<string>.
8760 * inf-child.c (inf_child_fileio_readlink): Return
8761 optional<string>.
8762 * target.c (target_fileio_readlink): Return optional<string>.
8763
ea005f31
AB
87642018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
8765
8766 * regcache.c (cooked_read_test): Add riscv to the list of
8767 architectures that have a save_reggroup.
8768
e95a97d4
AA
87692018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
8770
8771 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
8772 value is not a dynamic class object.
8773
d8344f3d
TT
87742018-03-06 Tom Tromey <tom@tromey.com>
8775
8776 * rust-exp.y: Formatting fixes.
8777
9add17f2
AB
87782018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8779
8780 * riscv-tdep.c (riscv_register_name): Remove target description
8781 support.
8782 (riscv_gdbarch_init): Remove target description check.
8783
c9486dfe
AB
87842018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8785
8786 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
8787 comment.
8788 * riscv-tdep.h: Likewise.
8789
d74aff3d
AB
87902018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8791
8792 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
8793 (riscv_pseudo_register_write): Delete.
8794 (riscv_gdbarch_init): Remove all use of pseudo registers.
8795
7ea78b59
SM
87962018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8797
8798 * record-btrace.c (btrace_print_lines): Replace cleanup
8799 parameter with RAII equivalents.
8800 (btrace_insn_history): Replace cleanup with RAII equivalents.
8801 * ui-out.h (make_cleanup_ui_out_list_begin_end,
8802 make_cleanup_ui_out_tuple_begin_end): Remove.
8803 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
8804 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
8805 make_cleanup_ui_out_list_begin_end): Remove.
8806
53127008
SM
88072018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8808
8809 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
8810 parameter types to std::vector. Use bool.
8811 (record_btrace_wait): Replace VEC(tp_t) with
8812 std::vector<thread_info *>.
8813 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
8814
228f1508
SM
88152018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
8816
8817 * record-btrace.c (record_btrace_disable_callback): Remove.
8818 (struct scoped_btrace_disable): New.
8819 (record_btrace_open): Use scoped_btrace_disable.
8820
b2970c23
AB
88212018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8822
8823 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
8824 reading values from registers.
8825
fb294655
AB
88262018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8827
8828 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
8829 where appropriate.
8830
cab5bb9d
AB
88312018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8832
8833 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
8834 change parameter type. Use GDB's print functions, and use
8835 core_addr_to_string where appropriate.
8836 (riscv_push_dummy_call): Use core_addr_to_string where
8837 appropriate, update call to riscv_print_arg_location, and reindent
8838 a few lines.
8839 (riscv_return_value): Update call to riscv_print_arg_location.
8840
dbbb1059
AB
88412018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8842 Tim Newsome <tim@sifive.com>
8843 Albert Ou <a0u@eecs.berkeley.edu>
8844 Darius Rad <darius@bluespec.com>
8845
8846 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
8847 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
8848 (ALLDEPFILES): Add riscv-tdep.c
8849 * configure.tgt: Add riscv support.
8850 * riscv-tdep.c: New file.
8851 * riscv-tdep.h: New file.
8852 * NEWS: Mention new target.
8853 * MAINTAINERS: Add entry for riscv.
8854
5dc43913
AB
88552018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
8856
8857 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
8858 fields within aggregates.
8859
3dea1ef7
SM
88602018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
8861
8862 * record-btrace.c (btrace_print_lines): Change type of flags to
8863 gdb_disassembly_flags.
8864
7efba073
JB
88652018-03-04 John Baldwin <jhb@FreeBSD.org>
8866
8867 * fbsd-nat.c: Include "inf-ptrace.h".
8868 (USE_SIGTRAP_SIGINFO): Conditionally define.
8869 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
8870 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
8871 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
8872 function.
8873 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
8874 Likewise.
8875 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
8876 Likewise.
8877 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
8878 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
8879 "supports_stopped_by_hw_breakpoint" target methods.
8880
386a8676
JB
88812018-03-04 John Baldwin <jhb@FreeBSD.org>
8882
8883 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
8884 * fbsd-nat.c (debug_fbsd_nat): New variable.
8885 (show_fbsd_nat_debug): New function.
8886 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
8887 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
8888
12279366
JB
88892018-03-04 John Baldwin <jhb@FreeBSD.org>
8890
8891 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
8892 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
8893 prototype.
8894 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
8895 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
8896 method.
8897
54693cf5
SM
88982018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8899
8900 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
8901 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
8902
ccb2231c
SM
89032018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8904
8905 * charset.c (struct charset_vector): New.
8906 (charsets): Change type to charset_vector.
8907 (find_charset_names): Adjust.
8908 (add_one): Adjust.
8909 (_initialize_charset): Adjust.
8910
6fb16ce6
SM
89112018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8912
8913 * progspace.h (struct program_space) <deleted_solibs>: Change
8914 type to std::vector<std::string>.
8915 * progspace.c (clear_program_space_solib_cache): Adjust.
8916 * breakpoint.c (print_solib_event): Adjust.
8917 (check_status_catch_solib): Adjust.
8918 * solib.c (update_solib_list): Adjust.
8919 * ui-out.h (class ui_out) <field_string>: New overload.
8920 * ui-out.c (ui_out::field_string): New overload.
8921
564b1e3f
SM
89222018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8923
8924 * progspace.h (struct program_space): Add constructor and
8925 destructor, initialize fields.
8926 (add_program_space): Remove.
8927 * progspace.c (add_program_space): Rename to...
8928 (program_space::program_space): ... this.
8929 (release_program_space): Rename to...
8930 (program_space::~program_space): ... this.
8931 (delete_program_space): Use delete to delete program_space.
8932 (initialize_progspace): Use new to allocate program_space.
8933 * inferior.c (add_inferior_with_spaces): Likewise.
8934 (clone_inferior_command): Likewise.
8935 * infrun.c (follow_fork_inferior): Likewise.
8936 (handle_vfork_child_exec_or_exit): Likewise.
8937
e80aaf61
SM
89382018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
8939
8940 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
8941 (delim_string_to_char_ptr_vec): Return std::vector of
8942 gdb::unique_xmalloc_ptr.
8943 (dirnames_to_char_ptr_vec_append): Take std::vector of
8944 gdb::unique_xmalloc_ptr.
8945 (dirnames_to_char_ptr_vec): Return std::vector of
8946 gdb::unique_xmalloc_ptr.
8947 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
8948 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
8949 (delim_string_to_char_ptr_vec): Return an std::vector of
8950 gdb::unique_xmalloc_ptr, adjust the code.
8951 (dirnames_to_char_ptr_vec_append): Take an std::vector of
8952 gdb::unique_xmalloc_ptr, adjust the code.
8953 (dirnames_to_char_ptr_vec): Return an std::vector of
8954 gdb::unique_xmalloc_ptr, adjust the code.
8955 * auto-load.c (auto_load_safe_path_vec): Change type to
8956 std::vector of gdb::unique_xmalloc_ptr.
8957 (auto_load_expand_dir_vars): Return an std::vector of
8958 gdb::unique_xmalloc_ptr, adjust the code.
8959 (auto_load_safe_path_vec_update): Adjust.
8960 (filename_is_in_auto_load_safe_path_vec): Adjust.
8961 (auto_load_objfile_script_1): Adjust.
8962 * build-id.c (build_id_to_debug_bfd): Adjust.
8963 * linux-thread-db.c (thread_db_load_search): Adjust.
8964 * source.c (add_path): Adjust.
8965 (openp): Adjust.
8966 * symfile.c (find_separate_debug_file): Adjust.
8967 * utils.c (do_free_char_ptr_vec): Remove.
8968 (make_cleanup_free_char_ptr_vec): Remove.
8969
ab818ade
SDJ
89702018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
8971
8972 PR gdb/22907
8973 * common/pathstuff.c: Conditionally include "<windows.h>".
8974
e1e6f073
GS
89752018-03-01 Georg Sauthoff <mail@georg.so>
8976
8977 PR gdb/22888
8978 * gcore.in: Quote variables and switch interpreter to bash.
8979
c7b15a66
TT
89802018-03-01 Tom Tromey <tom@tromey.com>
8981
8982 * dwarf2read.c (alloc_discriminant_info): Fix default_index
8983 assertion. Add assertion for discriminant_index.
8984 (quirk_rust_enum): Use correct base type name in univariant case.
8985
0cb7c7b0
SM
89862018-03-01 Simon Marchi <simon.marchi@ericsson.com>
8987
8988 * record.c (get_call_history_modifiers): Return a
8989 record_print_flags.
8990 (cmd_record_call_history): Adjust.
8991 * record-btrace.c (record_btrace_call_history): Adjust.
8992 (record_btrace_call_history_range): Adjust.
8993 (record_btrace_call_history_from): Adjust.
8994 * target-debug.h (target_debug_print_record_print_flags): New.
8995 * target-delegates.c: Re-generate.
8996 * target.c (target_call_history): Change flags type.
8997 (target_call_history_from): Likewise.
8998 (target_call_history_range): Likewise.
8999 * target.h (struct target_ops) <target_call_history>: Likewise.
9000 (target_call_history_from): Likewise.
9001 (target_call_history_range): Likewise.
9002
25e3c82c
SDJ
90032018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9004 Simon Marchi <simon.marchi@polymtl.ca>
9005
9006 * common/common-utils.c: Include "sys/stat.h".
9007 (is_regular_file): Move here from "source.c"; change return
9008 type to "bool".
9009 * common/common-utils.h (is_regular_file): New prototype.
9010 * common/pathstuff.c (contains_dir_separator): New function.
9011 * common/pathstuff.h (contains_dir_separator): New prototype.
9012 * source.c: Don't include "sys/stat.h".
9013 (is_regular_file): Move to "common/common-utils.c".
9014
b4987c95
SDJ
90152018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
9016
9017 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
9018 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
9019 * auto-load.c: Include "common/pathstuff.h".
9020 * common/common-def.h (current_directory): Move here.
9021 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
9022 function.
9023 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
9024 prototype.
9025 * common/pathstuff.c: New file.
9026 * common/pathstuff.h: New file.
9027 * compile/compile.c: Include "common/pathstuff.h".
9028 * defs.h (current_directory): Move to "common/common-defs.h".
9029 * dwarf2read.c: Include "common/pathstuff.h".
9030 * exec.c: Likewise.
9031 * guile/scm-safe-call.c: Likewise.
9032 * linux-thread-db.c: Likewise.
9033 * main.c: Likewise.
9034 * nto-tdep.c: Likewise.
9035 * objfiles.c: Likewise.
9036 * source.c: Likewise.
9037 * symtab.c: Likewise.
9038 * utils.c: Include "common/pathstuff.h".
9039 (gdb_realpath): Move to "common/pathstuff.c".
9040 (gdb_realpath_keepfile): Likewise.
9041 (gdb_abspath): Likewise.
9042 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
9043 (gdb_realpath_keepfile): Likewise.
9044 (gdb_abspath): Likewise.
9045
f169cfdc
JB
90462018-02-28 John Baldwin <jhb@FreeBSD.org>
9047
9048 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
9049 wildcard process pid for super_resume for kernels with a
9050 specific bug.
9051
e05cac70
PM
90522018-02-27 Phil Muldoon <pmuldoon@redhat.com>
9053
9054 * compile/compile.c (get_args): Add additional comments
9055 explaining function.
9056
55089490
TT
90572018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
9058 Tom Tromey <tom@tromey.com>
9059
9060 * target.h (memory_write_request_s): Remove typedef. Don't define
9061 VEC.
9062 (target_write_memory_blocks): Change argument to std::vector.
9063 (struct memory_write_request): Add constructor.
9064 * target-memory.c (compare_block_starting_address): Return bool.
9065 Change argument types.
9066 (claim_memory): Change arguments to use std::vector.
9067 (split_regular_and_flash_blocks, blocks_to_erase)
9068 (compute_garbled_blocks): Likewise.
9069 (cleanup_request_data, cleanup_write_requests_vector): Remove.
9070 (target_write_memory_blocks): Change argument to std::vector.
9071 * symfile.c (struct load_section_data): Add constructor and
9072 destructor. Use std::vector for "requests".
9073 (struct load_progress_data): Add initializers.
9074 (load_section_callback): Update. Use "new".
9075 (clear_memory_write_data): Remove.
9076 (generic_load): Update.
9077
0c305b61
AH
90782018-02-27 Alan Hayward <alan.hayward@arm.com>
9079
9080 * arch/aarch64.h: Use common/tdesc.h.
9081
c5196c92
MR
90822018-02-26 Maciej W. Rozycki <macro@mips.com>
9083
9084 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
9085 architecture with a 64-bit ABI.
9086
37c33887
MR
90872018-02-26 Maciej W. Rozycki <macro@mips.com>
9088
9089 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
9090 ahead of target description loading.
9091
d4dd3282
TT
90922018-02-26 Tom Tromey <tom@tromey.com>
9093
9094 * stack.c (backtrace_command_1): Update.
9095 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
9096 of "flags".
9097 * python/py-framefilter.c (py_print_frame)
9098 (gdbpy_apply_frame_filter): Change type of "flags".
9099 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
9100 of "flags".
9101 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
9102 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
9103 * extension.h (enum frame_filter_flag): Rename from
9104 frame_filter_flags.
9105 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
9106 (apply_ext_lang_frame_filter): Change type of "flags".
9107 * extension.c (apply_ext_lang_frame_filter): Change type of
9108 "flags".
9109 * extension-priv.h (struct extension_language_ops)
9110 <apply_frame_filter>: Change type of "flags".
9111
6893c19a
TT
91122018-02-26 Tom Tromey <tom@tromey.com>
9113
9114 PR python/16497:
9115 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
9116 off-by-one in py_end computation.
9117 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
9118 PRINT_MORE_FRAMES.
9119 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
9120 constant.
9121
2ddeaf8a
TT
91222018-02-26 Tom Tromey <tom@tromey.com>
9123
9124 * dwarf2read.c (struct variant_field): New.
9125 (struct nextfield) <variant>: New field.
9126 (dwarf2_add_field): Handle DW_TAG_variant_part.
9127 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
9128 discriminated union.
9129 (read_structure_type): Handle DW_TAG_variant_part.
9130 (handle_struct_member_die): New function, extracted from
9131 process_structure_scope. Handle DW_TAG_variant.
9132 (process_structure_scope): Handle discriminated unions. Call
9133 handle_struct_member_die.
9134
c9317f21
TT
91352018-02-26 Tom Tromey <tom@tromey.com>
9136
9137 * rust-lang.h (rust_last_path_segment): Declare.
9138 * rust-lang.c (rust_last_path_segment): Now public. Change
9139 contract.
9140 (struct disr_info): Remove.
9141 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
9142 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
9143 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
9144 (rust_enum_p, rust_enum_variant): New function.
9145 (rust_underscore_fields): Remove "offset" parameter.
9146 (rust_print_enum): New function.
9147 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
9148 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
9149 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
9150 enums.
9151 (rust_internal_print_type): New function, from rust_print_type.
9152 Remove enum code.
9153 (rust_print_type): Call rust_internal_print_type.
9154 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
9155 Update enum handling.
9156 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
9157 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
9158 (rust_union_quirks): New functions.
9159 (process_full_comp_unit, process_full_type_unit): Call
9160 rust_union_quirks.
9161 (process_structure_scope): Update rust_unions if necessary.
9162
7c22600a
TT
91632018-02-26 Tom Tromey <tom@tromey.com>
9164
9165 * value.h (value_union_variant): Declare.
9166 * valops.c (value_union_variant): New function.
9167 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
9168 (struct discriminant_info): New.
9169 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
9170 enumerator.
9171 (struct main_type) <flag_discriminated_union>: New field.
9172
15ce8941
TT
91732018-02-26 Tom Tromey <tom@tromey.com>
9174
9175 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9176 unittests/unpack-selftests.c.
9177 * unittests/unpack-selftests.c: New file.
9178 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
9179
48fbe735
YQ
91802018-02-26 Yao Qi <yao.qi@linaro.org>
9181
9182 * dwarf2read.c (struct partial_die_info) <read>: New method.
9183 (read_partial_die): Remove the declaration.
9184 (load_partial_dies): Update.
9185 (partial_die_info::partial_die_info):
9186 (read_partial_die): Change it to partial_die_info::read.
9187
52356b79
YQ
91882018-02-26 Yao Qi <yao.qi@linaro.org>
9189
9190 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
9191 (fixup_partial_die): Remove declaration.
9192 (scan_partial_symbols): Update.
9193 (partial_die_parent_scope): Likewise.
9194 (partial_die_full_name): Likewise.
9195 (fixup_partial_die): Change it to partial_die_info::fixup.
9196
35cc7ed7
YQ
91972018-02-26 Yao Qi <yao.qi@linaro.org>
9198
9199 * dwarf2read.c (read_partial_die): Update the declaration.
9200 (load_partial_dies): Caller update.
9201 (read_partial_die): Remove one argument abbrev_len.
9202
6f06d47b
YQ
92032018-02-26 Yao Qi <yao.qi@linaro.org>
9204
9205 * dwarf2read.c (struct partial_die_info): Add ctor, delete
9206 assignment operator.
9207 (load_partial_dies): Use ctor and copy ctor.
9208 (read_partial_die): Update.
9209 (dwarf2_cu::find_partial_die): Use ctor.
9210
d590ff25
YQ
92112018-02-26 Yao Qi <yao.qi@linaro.org>
9212
9213 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
9214 (find_partial_die_in_comp_unit): Change it to
9215 dwarf2_cu::find_partial_die.
9216 (find_partial_die): Update.
9217
fd0a254f
YQ
92182018-02-26 Yao Qi <yao.qi@linaro.org>
9219
9220 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
9221 is NULL.
9222
cd9983dd
YQ
92232018-02-26 Yao Qi <yao.qi@linaro.org>
9224
9225 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
9226
f46cd62a
AH
92272018-02-26 Alan Hayward <alan.hayward@arm.com>
9228
9229 * arch/amd64.h: Use common/tdesc.h.
9230 * arch/i386.c: Likewise.
9231 * arch/i386.h: Likewise.
9232 * arch/tic6x.c: Likewise.
9233 * arch/tdesc.h: Move file from here...
9234 * common/tdesc.h: ...to here.
9235 * features/aarch64-core.c: Regenerate.
9236 * features/aarch64-fpu.c: Regenerate.
9237 * features/i386/32bit-avx.c: Regenerate.
9238 * features/i386/32bit-avx512.c: Regenerate.
9239 * features/i386/32bit-core.c: Regenerate.
9240 * features/i386/32bit-linux.c: Regenerate.
9241 * features/i386/32bit-mpx.c: Regenerate.
9242 * features/i386/32bit-pkeys.c: Regenerate.
9243 * features/i386/32bit-sse.c: Regenerate.
9244 * features/i386/64bit-avx.c: Regenerate.
9245 * features/i386/64bit-avx512.c: Regenerate.
9246 * features/i386/64bit-core.c: Regenerate.
9247 * features/i386/64bit-linux.c: Regenerate.
9248 * features/i386/64bit-mpx.c: Regenerate.
9249 * features/i386/64bit-pkeys.c: Regenerate.
9250 * features/i386/64bit-segments.c: Regenerate.
9251 * features/i386/64bit-sse.c: Regenerate.
9252 * features/i386/x32-core.c: Regenerate.
9253 * features/tic6x-c6xp.c: Regenerate.
9254 * features/tic6x-core.c: Regenerate.
9255 * features/tic6x-gp.c: Regenerate.
9256 * target-descriptions.c: Use common/tdesc.h.
9257 * target-descriptions.h: Likewise.
9258
9b292f68
TT
92592018-02-24 Tom Tromey <tom@tromey.com>
9260
9261 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
9262 (try_thread_db_load_from_dir, thread_db_load_search): Use
9263 std::string.
9264 (info_auto_load_libthread_db_compare): Return bool. Change
9265 argument types.
9266 (info_auto_load_libthread_db): Use std::vector, std::string.
9267 Remove cleanups.
9268
281d762b
TT
92692018-02-24 Tom Tromey <tom@tromey.com>
9270
9271 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
9272 std::string.
9273 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
9274 std::string*.
9275 * gdbarch.c: Rebuild.
9276 * gdbarch.h: Rebuild.
9277 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
9278 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
9279 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
9280 std::string*.
9281
9d8780f0
SM
92822018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
9283
9284 * gdbtypes.h (sect_offset): Change type to uint64_t.
9285 (sect_offset_str): New function.
9286 * dwarf2read.c (create_addrmap_from_aranges): Use
9287 sect_offset_str.
9288 (error_check_comp_unit_head): Likewise.
9289 (create_debug_type_hash_table): Likewise.
9290 (read_cutu_die_from_dwo): Likewise.
9291 (init_cutu_and_read_dies): Likewise.
9292 (init_cutu_and_read_dies_no_follow): Likewise.
9293 (process_psymtab_comp_unit_reader): Likewise.
9294 (partial_die_parent_scope): Likewise.
9295 (peek_die_abbrev): Likewise.
9296 (process_queue): Likewise.
9297 (dwarf2_physname): Likewise.
9298 (read_namespace_alias): Likewise.
9299 (read_import_statement): Likewise.
9300 (create_dwo_cu_reader): Likewise.
9301 (create_cus_hash_table): Likewise.
9302 (lookup_dwo_cutu): Likewise.
9303 (inherit_abstract_dies): Likewise.
9304 (read_func_scope): Likewise.
9305 (read_call_site_scope): Likewise.
9306 (dwarf2_add_member_fn): Likewise.
9307 (read_common_block): Likewise.
9308 (read_module_type): Likewise.
9309 (read_typedef): Likewise.
9310 (read_subrange_type): Likewise.
9311 (load_partial_dies): Likewise.
9312 (read_partial_die): Likewise.
9313 (find_partial_die): Likewise.
9314 (read_str_index): Likewise.
9315 (dwarf2_string_attr): Likewise.
9316 (build_error_marker_type): Likewise.
9317 (lookup_die_type): Likewise.
9318 (dump_die_shallow): Likewise.
9319 (follow_die_ref): Likewise.
9320 (dwarf2_fetch_die_loc_sect_off): Likewise.
9321 (dwarf2_fetch_constant_bytes): Likewise.
9322 (follow_die_sig): Likewise.
9323 (get_signatured_type): Likewise.
9324 (get_DW_AT_signature_type): Likewise.
9325 (dwarf2_find_containing_comp_unit): Likewise.
9326 (set_die_type): Likewise.
9327
8ec57239
JB
93282018-02-21 John Baldwin <jhb@FreeBSD.org>
9329
9330 * arch/aarch64.c: Include "common-defs.h".
9331 * arch/amd64.c: Likewise.
9332 * arch/i386.c: Likewise.
9333
3eac2b65
TT
93342018-02-21 Tom Tromey <tom@tromey.com>
9335
9336 * value.h: (extract_field_op): Update.
9337 * eval.c (extract_field_op): Return a const char *.
9338 * expression.h (parse_expression_for_completion): Update.
9339 * completer.c (complete_expression): Update.
9340 (add_struct_fields): Make fieldname const.
9341 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
9342 (mark_completion_tag, parse_exp_in_context_1): Update.
9343 (parse_expression_for_completion): Change "name" to
9344 unique_xmalloc_ptr*.
9345
6ccb583f
TT
93462018-02-21 Tom Tromey <tom@tromey.com>
9347
9348 * infcall.c (call_function_by_hand_dummy): Use std::vector.
9349
c113ed0c
YQ
93502018-02-21 Yao Qi <yao.qi@linaro.org>
9351
9352 * avr-tdep.c (avr_read_pc): Change parameter type to
9353 readable_regcache.
9354 * gdbarch.sh (read_pc): Likewise.
9355 * gdbarch.c: Re-generated.
9356 * gdbarch.h: Re-generated.
9357 * hppa-tdep.c (hppa_read_pc): Change parameter type to
9358 readable_regcache.
9359 * ia64-tdep.c (ia64_read_pc): Likewise.
9360 * mips-tdep.c (mips_read_pc): Likewise.
9361 * spu-tdep.c (spu_read_pc): Likewise.
9362
4c74fe6b
YQ
93632018-02-21 Yao Qi <yao.qi@linaro.org>
9364
9365 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
9366 * regcache-dump.c: New file.
9367 * regcache.c: Move register_dump to regcache-dump.c.
9368 (maintenance_print_registers): Likewise.
9369 (maintenance_print_raw_registers): Likewise.
9370 (maintenance_print_cooked_registers): Likewise.
9371 (maintenance_print_register_groups): Likewise.
9372 (maintenance_print_remote_registers): Likewise.
9373 (_initialize_regcache): Likewise.
9374 * regcache.h (register_dump): Moved from regcache.c.
9375
796bb026
YQ
93762018-02-21 Yao Qi <yao.qi@linaro.org>
9377
9378 * regcache.c (regcache::regcache): Update.
9379 (regcache::invalidate): Move it to detached_regcache::invalidate.
9380 (get_thread_arch_aspace_regcache): Update.
9381 (regcache::raw_update): Update.
9382 (regcache::cooked_read): Remove some code.
9383 (regcache::cooked_read_value): Likewise.
9384 (regcache::raw_write): Remove assert on m_readonly_p.
9385 (regcache::raw_supply_integer): Move it to
9386 detached_regcache::raw_supply_integer.
9387 (regcache::raw_supply_zeroed): Likewise.
9388 * regcache.h (detached_regcache) <raw_supply_integer>: New
9389 declaration.
9390 <raw_supply_zeroed, invalidate>: Likewise.
9391 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
9392 <invalidate>: Likewise.
9393 <m_readonly_p>: Removed.
9394
215c69dc
YQ
93952018-02-21 Yao Qi <yao.qi@linaro.org>
9396
9397 * infcmd.c (get_return_value): Let stop_regs point to
9398 get_current_regcache.
9399 * regcache.c (regcache::regcache): Remove.
9400 (register_dump_reg_buffer): New class.
9401 (regcache_print): Adjust.
9402 * regcache.h (regcache): Remove constructors.
9403
f3384e66
YQ
94042018-02-21 Yao Qi <yao.qi@linaro.org>
9405
9406 * regcache.c (class register_dump): New class.
9407 (register_dump_regcache, register_dump_none): New class.
9408 (register_dump_remote, register_dump_groups): New class.
9409 (regcache_print): Update.
9410 * regcache.h (regcache_dump_what): Move it to regcache.c.
9411 (regcache) <dump>: Remove.
9412
c8ec2f33
YQ
94132018-02-21 Yao Qi <yao.qi@linaro.org>
9414
9415 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
9416 reg_buffer_rw *.
9417 (jit_unwind_reg_set_impl): Call raw_supply.
9418 (jit_frame_sniffer): Use reg_buffer_rw.
9419 * record-full.c (record_full_core_regbuf): Change its type.
9420 (record_full_core_open_1): Use reg_buffer_rw.
9421 (record_full_close): Likewise.
9422 (record_full_core_fetch_registers): Use regcache->raw_supply.
9423 (record_full_core_store_registers): Likewise.
9424 * regcache.c (regcache::get_register_status): Move it to
9425 reg_buffer.
9426 (regcache_raw_set_cached_value): Remove.
9427 (regcache::raw_set_cached_value): Remove.
9428 (regcache::raw_write): Call raw_supply.
9429 (regcache::raw_supply): Move it to reg_buffer_rw.
9430 * regcache.h (regcache_raw_set_cached_value): Remove.
9431 (reg_buffer_rw): New class.
9432
daf6667d
YQ
94332018-02-21 Yao Qi <yao.qi@linaro.org>
9434
9435 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
9436 readonly_detached_regcache.
9437 (dummy_frame_prev_register): Use regcache->cooked_read.
9438 * frame.c (frame_save_as_regcache): Change return type.
9439 (frame_pop): Update.
9440 * frame.h (frame_save_as_regcache): Update declaration.
9441 * inferior.h (get_infcall_suspend_state_regcache): Update
9442 declaration.
9443 * infrun.c (infcall_suspend_state) <registers>: use
9444 readonly_detached_regcache.
9445 (save_infcall_suspend_state): Don't use regcache_dup.
9446 (get_infcall_suspend_state_regcache): Change return type.
9447 * linux-fork.c (struct fork_info) <savedregs>: Change to
9448 readonly_detached_regcache.
9449 <pc>: New field.
9450 (fork_save_infrun_state): Don't use regcache_dup.
9451 (info_checkpoints_command): Adjust.
9452 * mi/mi-main.c (register_changed_p): Update declaration.
9453 (mi_cmd_data_list_changed_registers): Use
9454 readonly_detached_regcache.
9455 (register_changed_p): Change parameter type to
9456 readonly_detached_regcache.
9457 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
9458 readonly_detached_regcache.
9459 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
9460 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
9461 New.
9462 (regcache::save): Move it to reg_buffer.
9463 (regcache::restore): Change parameter type.
9464 (regcache_dup): Remove.
9465 * regcache.h (reg_buffer) <save>: New method.
9466 (readonly_detached_regcache): New class.
9467 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
9468 readonly_detached_regcache.
9469 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
9470
fc5b8736
YQ
94712018-02-21 Yao Qi <yao.qi@linaro.org>
9472
9473 * frame.c (frame_save_as_regcache): Use regcache method save.
9474 (frame_pop): Use regcache method restore.
9475 * infrun.c (restore_infcall_suspend_state): Likewise.
9476 * linux-fork.c (fork_load_infrun_state): Likewise.
9477 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
9478 save.
9479 * regcache.c (regcache_save): Remove.
9480 (regcache::restore): More asserts.
9481 (regcache_cpy): Remove.
9482 * regcache.h (regcache_save): Remove the declaration.
9483 (regcache::restore): Move from private to public.
9484 Remove the friend declaration of regcache_cpy.
9485 (regcache_cpy): Remove declaration.
9486
849d0ba8
YQ
94872018-02-21 Yao Qi <yao.qi@linaro.org>
9488
9489 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
9490 parameter type to 'readable_regcache *'.
9491 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
9492 * arm-tdep.c (arm_neon_quad_read): Likewise.
9493 (arm_pseudo_read): Likewise.
9494 * avr-tdep.c (avr_pseudo_register_read): Likewise.
9495 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
9496 * frv-tdep.c (frv_pseudo_register_read): Likewise.
9497 * gdbarch.c: Re-generated.
9498 * gdbarch.h: Re-generated.
9499 * gdbarch.sh (pseudo_register_read): Change parameter type to
9500 'readable_regcache *'.
9501 (pseudo_register_read_value): Likewise.
9502 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
9503 (h8300_pseudo_register_read): Likewise.
9504 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
9505 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
9506 (i386_pseudo_register_read_into_value): Likewise.
9507 (i386_pseudo_register_read_value): Likewise.
9508 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
9509 declaration.
9510 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
9511 * m32c-tdep.c (m32c_raw_read): Likewise.
9512 (m32c_read_flg): Likewise.
9513 (m32c_banked_register): Likewise.
9514 (m32c_banked_read): Likewise.
9515 (m32c_sb_read): Likewise.
9516 (m32c_part_read): Likewise.
9517 (m32c_cat_read): Likewise.
9518 (m32c_r3r2r1r0_read): Likewise.
9519 (m32c_pseudo_register_read): Likewise.
9520 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
9521 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
9522 (mep_pseudo_cr64_read): Likewise.
9523 (mep_pseudo_register_read): Likewise.
9524 * mips-tdep.c (mips_pseudo_register_read): Likewise.
9525 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
9526 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
9527 * regcache.c (regcache::raw_read): Move it to readable_regcache.
9528 (regcache::cooked_read): Likewise.
9529 (regcache::cooked_read_value): Likewise.
9530 (regcache_cooked_read_signed):
9531 (regcache::cooked_read): Likewise.
9532 * regcache.h (readable_regcache): New class.
9533 (regcache): Inherit readable_regcache. Move some methods to
9534 readable_regcache.
9535 * rl78-tdep.c (rl78_pseudo_register_read): Change
9536 parameter type to 'readable_regcache *'.
9537 * rs6000-tdep.c (do_regcache_raw_read): Remove.
9538 (e500_pseudo_register_read): Change parameter type to
9539 'readable_regcache *'.
9540 (dfp_pseudo_register_read): Likewise.
9541 (vsx_pseudo_register_read): Likewise.
9542 (efpr_pseudo_register_read): Likewise.
9543 * s390-tdep.c (s390_pseudo_register_read): Likewise.
9544 * sh-tdep.c (sh_pseudo_register_read): Likewise.
9545 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
9546 (sh64_pseudo_register_read): Likewise.
9547 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
9548 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
9549 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
9550 (spu_pseudo_register_read): Likewise.
9551 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
9552 (xtensa_pseudo_register_read): Likewise.
9553
31716595
YQ
95542018-02-21 Yao Qi <yao.qi@linaro.org>
9555
9556 * regcache.c (regcache::regcache): Call reg_buffer ctor.
9557 (regcache::arch): Move it to reg_buffer::arch.
9558 (regcache::register_buffer): Likewise.
9559 (regcache::assert_regnum): Likewise.
9560 (regcache::num_raw_registers): Likewise.
9561 * regcache.h (reg_buffer): New class.
9562 (regcache): Inherit reg_buffer.
9563
7104e59b
SM
95642018-02-20 Simon Marchi <simon.marchi@ericsson.com>
9565
9566 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
9567 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
9568
2d8adcbd
MM
95692018-02-20 Markus Metzger <markus.t.metzger@intel.com>
9570
9571 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
9572
b5884fa7
AH
95732018-02-19 Alan Hayward <alan.hayward@arm.com>
9574
9575 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
9576 (SFILES): Remove common/*.c files.
9577 (COMMON_OBS): Remove some *.o files built from common/*.c files.
9578 * common/common.host: Add common reference.
9579 * configure.ac: Likewise.
9580 * configure: Regenerate.
9581
fd90ace4
YQ
95822018-02-16 Yao Qi <yao.qi@linaro.org>
9583
9584 * block.c (block_namespace_info): Inherit allocate_on_obstack.
9585 (block_initialize_namespace): Use new.
9586 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
9587 (dwarf2_free_objfile): Use delete.
9588 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
9589 (copy_type_recursive): Use new.
9590 * gdb_obstack.h (allocate_on_obstack): New.
9591
85046ae2
YQ
95922018-02-15 Yao Qi <yao.qi@linaro.org>
9593
9594 PR gdb/22849
9595 * inferior.c (exit_inferior_1): Reset inf->control.
9596
355c559b
JB
95972018-02-15 Joel Brobecker <brobecker@adacore.com>
9598
9599 * ada-lang.c (ada_to_fixed_value_create): Delete advance
9600 declaration.
9601
980548fd
PA
96022018-02-14 Pedro Alves <palves@redhat.com>
9603
9604 * frame-unwind.c (frame_unwind_try_unwinder): Always call
9605 frame_cleanup_after_sniffer on exception.
9606
692d6f97
TT
96072018-02-14 Tom Tromey <tom@tromey.com>
9608
9609 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
9610 const.
9611 (solib_bfd_open): Make pathname const.
9612 * solib.c (solib_bfd_open): Make pathname const.
9613 * solib-spu.c (spu_bfd_fopen): Make name const.
9614 (spu_bfd_open): Make pathname const.
9615 * solib-darwin.c (darwin_bfd_open): Make pathname const.
9616 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
9617
e0cc99a6
TT
96182018-02-14 Tom Tromey <tom@tromey.com>
9619
9620 * symfile.c (symfile_bfd_open): Update.
9621 * source.h (openp, source_full_path_of, find_and_open_source):
9622 Change argument type to unique_xmalloc_ptr.
9623 * source.c (openp): Take a unique_xmalloc_ptr.
9624 (source_full_path_of, find_and_open_source): Likewise.
9625 (open_source_file, symtab_to_fullname): Update.
9626 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
9627 unique_xmalloc_ptr.
9628 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
9629 (exec_file_find): Update.
9630 * psymtab.c (psymtab_to_fullname): Update.
9631 * nto-tdep.h (nto_find_and_open_solib): Update.
9632 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
9633 unique_xmalloc_ptr.
9634 * exec.c (exec_file_attach): Update.
9635 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
9636 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
9637
b46a8d7c
TT
96382018-02-14 Tom Tromey <tom@tromey.com>
9639
9640 * solib.c: Include source.h.
9641 * nto-tdep.c: Include source.h.
9642 * mi/mi-cmd-env.c: Include source.h.
9643 * infcmd.c: Include source.h.
9644 * exec.c: Include source.h.
9645 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
9646 (add_path, directory_switch, source_path, init_source_path): Move
9647 declarations...
9648 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
9649 (add_path, directory_switch, source_path, init_source_path):
9650 ...here.
9651
797bc1cb
TT
96522018-02-14 Tom Tromey <tom@tromey.com>
9653
9654 * solist.h (exec_file_find, solib_find): Return
9655 unique_xmalloc_ptr.
9656 (solib_bfd_fopen): Take a const char *.
9657 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
9658 (exec_file_find, solib_find): Likewise.
9659 (solib_bfd_fopen): Do not take ownership of "pathname".
9660 (solib_bfd_open): Use unique_xmalloc_ptr.
9661 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
9662 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
9663 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
9664 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
9665
f98b2e33
JB
96662018-02-14 Joel Brobecker <brobecker@adacore.com>
9667
9668 * ada-lang.c (name_match_type_from_name): Remove reference to
9669 ada_name_for_lookup in function's documentation.
9670 * ada-lang.h (ada_name_for_lookup): Delete declaration.
9671
24b9144d
SM
96722018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9673
9674 * defs.h (enum openp_flags): New enum.
9675 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
9676 Move to enum openp_flags.
9677 (openp_flags): New enum flags.
9678 (openp): Change parameter type to openp_flags.
9679 * source.c (openp): Change parameter type to openp_flags.
9680 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
9681 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
9682
387cd15b
SM
96832018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
9684
9685 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
9686 per-command.
9687
b303c6f6
AB
96882018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
9689
9690 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
9691 into...
9692 (class dwarf2_queue_guard): ...the destructor of this new class.
9693 (dw2_do_instantiate_symtab): Create instance of the new class
9694 dwarf2_queue_guard, remove cleanup.
9695
9c3630e9
TT
96962018-02-09 Tom Tromey <tom@tromey.com>
9697
9698 * source.c (find_source_lines): Don't reference past the end of
9699 the vector.
9700
c4e12631
MM
97012018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9702
9703 * remote.c (remote_btrace_maybe_reopen): Change error message.
9704 * btrace.c (btrace_enable): Likewise.
9705 (parse_xml_btrace): Likewise.
9706 (parse_xml_btrace_conf): Likewise.
9707
88711fbf
MM
97082018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9709
9710 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
9711 (linux_enable_pt, linux_enable_bts): Call
9712 diagnose_perf_event_open_fail.
9713
17ad2a4f
MM
97142018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9715
9716 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
9717 Remove parameter and change return type. Update callers. Move it.
9718 (linux_enable_bts, linux_enable_pt): Improve error message.
9719 (linux_enable_pt): Remove zero buffer size check.
9720 (linux_enable_btrace): Improve error messages. Remove NULL return
9721 check.
9722
de6242d3
MM
97232018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9724
9725 * btrace.c (btrace_enable): Remove target_supports_btrace call.
9726 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
9727 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
9728 (linux_supports_pt, linux_supports_btrace): Remove.
9729 (linux_enable_bts): Call cpu_supports_bts.
9730 * nat/linux-btrace.h (linux_supports_btrace): Remove.
9731 * remote.c (remote_supports_btrace): Remove.
9732 (init_remote_ops): Remove remote_supports_btrace.
9733 * target-delegates.c: Regenerated.
9734 * target.c (target_supports_btrace): Remove.
9735 * target.h (target_ops) <to_supports_btrace>: Remove
9736 (target_supports_btrace): Remove.
9737 * x86-linux-nat.c (x86_linux_create_target): Remove
9738 linux_supports_btrace.
9739
9ee23a85
MM
97402018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9741
9742 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
9743 btrace failed.
9744 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
9745 exception and use message in own exception.
9746
5c3284c1
MM
97472018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9748
9749 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
9750 (perf_event_pt_event_type): Use gdb_file_up.
9751 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
9752 scoped_fd, and scoped_mmap.
9753
84696f37
MM
97542018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9755
9756 * common/scoped_mmap.h: New.
9757 * unittests/scoped_mmap-selftest.c: New.
9758 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9759 unittests/scoped_mmap-selftest.c.
9760
ea4a0888
MM
97612018-02-09 Markus Metzger <markus.t.metzger@intel.com>
9762
9763 * common/scoped_fd.h: New.
9764 * unittests/scoped_fd-selftest.c: New.
9765 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
9766 unittests/scoped_fd-selftest.c.
9767
869e8290
TT
97682018-02-09 Tom Tromey <tom@tromey.com>
9769
9770 * auto-load.c (auto_load_section_scripts): Use
9771 gdb::unique_xmalloc_ptr.
9772
a37a2ae7
TT
97732018-02-09 Tom Tromey <tom@tromey.com>
9774
9775 * auto-load.c (execute_script_contents): Use std::string.
9776
4e725347
JB
97772018-02-09 Joel Brobecker <brobecker@adacore.com>
9778
9779 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
9780 Python function, rather than a new command.
9781
9a897d43
TT
97822018-02-08 Tom Tromey <tom@tromey.com>
9783
9784 * solib.c (solib_find_1): Use std::string.
9785 (solib_bfd_fopen): Use unique_xmalloc_ptr.
9786
58ef3771
TT
97872018-02-08 Tom Tromey <tom@tromey.com>
9788
9789 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
9790
a9abc434
TT
97912018-02-08 Tom Tromey <tom@tromey.com>
9792
9793 * source.c (find_source_lines): Use gdb::def_vector.
9794
84f27c6f
TT
97952018-02-08 Tom Tromey <tom@tromey.com>
9796
9797 * macrocmd.c (struct temporary_macro_definition): New.
9798 (macro_define_command): Use temporary_macro_definition. Remove
9799 cleanups.
9800 (free_macro_definition_ptr): Remove.
9801
0354904b
TT
98022018-02-08 Tom Tromey <tom@tromey.com>
9803
9804 * macroexp.c (maybe_expand): Use std::string.
9805
1739cf24
TT
98062018-02-08 Tom Tromey <tom@tromey.com>
9807
9808 * macroexp.c (struct macro_buffer): Add initializers for some
9809 members.
9810 (init_buffer, init_shared_buffer, free_buffer)
9811 (free_buffer_return_text): Remove.
9812 (macro_buffer): New constructors.
9813 (~macro_buffer): New destructor.
9814 (macro_buffer::set_shared): New method.
9815 (macro_buffer::resize_buffer, macro_buffer::appendc)
9816 (macro_buffer::appendmem): Now methods, not free functions.
9817 (set_token, append_tokens_without_splicing, stringify)
9818 (macro_stringify): Update.
9819 (gather_arguments): Change return type. Remove argc_p argument,
9820 add args_ptr argument. Use std::vector.
9821 (substitute_args): Remove argc argument. Accept std::vector.
9822 (expand): Update. Use std::vector.
9823 (scan, macro_expand, macro_expand_next): Update.
9824
f6c2623e
TT
98252018-02-08 Tom Tromey <tom@tromey.com>
9826
9827 * symtab.c (default_collect_symbol_completion_matches_break_on):
9828 Use unique_xmalloc_ptr.
9829 * macroscope.h: (sal_macro_scope, user_macro_scope)
9830 (default_macro_scope): Return unique_xmalloc_ptr.
9831 * macroscope.c (sal_macro_scope, user_macro_scope)
9832 (default_macro_scope): Return unique_xmalloc_ptr.
9833 * macroexp.h (macro_expand, macro_expand_once): Return
9834 unique_xmalloc_ptr.
9835 * macroexp.c (macro_expand, macro_expand_once): Return
9836 unique_xmalloc_ptr.
9837 * macrocmd.c (macro_expand_command, macro_expand_once_command)
9838 (info_macro_command, info_macros_command): Use
9839 unique_xmalloc_ptr.
9840 * compile/compile-c-support.c (write_macro_definitions): Use
9841 unique_xmalloc_ptr.
9842 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
9843
c2e0e465
SM
98442018-02-07 Simon Marchi <simon.marchi@ericsson.com>
9845
9846 * value.c (value_static_field): Assign field type instead of
9847 containing type when returning an optimized out value.
9848
3f8c94b4
YQ
98492018-02-06 Yao Qi <yao.qi@linaro.org>
9850
9851 * ft32-tdep.c (ft32_read_pc): Remove.
9852 (ft32_write_pc): Remove.
9853 (ft32_gdbarch_init): Update.
9854 * m32r-tdep.c (m32r_read_pc): Remove.
9855 (m32r_gdbarch_init): Update.
9856 * mep-tdep.c (mep_read_pc): Remove.
9857 (mep_gdbarch_init): Update.
9858 * microblaze-tdep.c (microblaze_write_pc): Remove.
9859 (microblaze_gdbarch_init): Update.
9860 * mn10300-tdep.c (mn10300_read_pc): Remove.
9861 (mn10300_write_pc): Remove.
9862 (mn10300_gdbarch_init): Update.
9863 * moxie-tdep.c (moxie_read_pc): Remove.
9864 (moxie_write_pc): Remove.
9865 (moxie_gdbarch_init): Update.
9866
bca65a23
YQ
98672018-02-06 Yao Qi <yao.qi@linaro.org>
9868
9869 * expprint.c (print_subexp_standard): Handle
9870 OP_F77_UNDETERMINED_ARGLIST.
9871 (dump_subexp_body_standard): Likewise.
9872
583e3f90 98732018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 9874
583e3f90
YQ
9875 * target-descriptions.c (tdesc_element_visitor) Add empty
9876 implementations.
b8df6ca7
AH
9877 (tdesc_type): Move make_gdb_type from here.
9878 (tdesc_type_builtin): Likewise.
9879 (tdesc_type_vector): Likewise.
9880 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
9881 (make_gdb_type_struct): Move from tdesc_type_with_fields.
9882 (make_gdb_type_union): Likewise.
9883 (make_gdb_type_flags): Likewise.
9884 (make_gdb_type_enum): Likewise.
9885 (make_gdb_type): New function.
9886 (tdesc_register_type): Use static make_gdb_type.
9887
e813d34a
RK
98882018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
9889
9890 * infcmd.c (default_print_one_register_info): Align natural-format
9891 column values consistently one under another.
9892 (pad_to_column): New function.
9893
0eb876f5
JB
98942018-02-05 Joel Brobecker <brobecker@adacore.com>
9895
9896 * dwarf2read.c (dwarf2_physname): Move commment.
9897
0625771b
LS
98982018-02-01 Leszek Swirski <leszeks@google.com>
9899
9900 * varobj.c (varobj_formatted_print_options): Allow recursive
9901 pretty printing if pretty printing is enabled.
9902
59498c30
LS
99032018-02-01 Leszek Swirski <leszeks@google.com>
9904
9905 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
9906 names after a structop as a filename.
9907
2d9e6acb
YQ
99082018-02-01 Yao Qi <yao.qi@linaro.org>
9909
9910 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
9911 (arm_record_coproc_data_proc): Likewise.
9912
df95a9cf
YQ
99132018-02-01 Yao Qi <yao.qi@linaro.org>
9914
9915 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
9916
07e5f5cf
NP
99172018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
9918
9919 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
9920 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
9921
3045b475
PA
99222018-01-31 Pedro Alves <palves@redhat.com>
9923
9924 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
9925 * inflow.c (child_terminal_save_inferior): Wrap reference to
9926 tcgetpgrp in HAVE_TERMIOS_H.
9927 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
9928 _WIN32.
9929 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
9930 always iterate over all inferiors.
9931 (gdbsim_cntrl_c): Adjust.
9932 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
9933
929b5ad4
JB
99342018-01-31 Joel Brobecker <brobecker@adacore.com>
9935
9936 * gdbtypes.c (lookup_array_range_type): Make sure the array's
9937 index type is objfile-owned if the element type is as well.
9938
29236ca2
JB
99392018-01-31 Joel Brobecker <brobecker@adacore.com>
9940
9941 GDB 8.1 released.
9942
c81e8879
PR
99432018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
9944
9945 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
9946 "features/s390x-linux64.c".
9947 (_initialize_s390_linux_tdep): Remove initialization of tdescs
9948 s390_linux32 and s390x_linux64.
9949 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
9950 default tdesc.
9951 * s390-tdep.c: Include "features/s390-linux32.c" and
9952 "features/s390x-linux64.c".
9953 (s390_tdesc_valid): Add check for tdesc_has_registers.
9954 (s390_gdbarch_init): Make sure there is always a valid tdesc.
9955 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
9956 tdesc_s390x_linux64.
9957 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
9958 tdesc_s390x_linux64 to...
9959 * s390-tdep.h: ...here.
9960
e671cd59
PA
99612018-01-30 Pedro Alves <palves@redhat.com>
9962
9963 PR gdb/13211
9964 * config.in, configure: Regenerate.
9965 * configure.ac: Check for getpgid.
9966 * go32-nat.c (go32_pass_ctrlc): New.
9967 (go32_target): Install it.
9968 * inf-child.c (inf_child_target): Install
9969 child_terminal_save_inferior, child_pass_ctrlc and
9970 child_interrupt.
9971 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
9972 (inf_ptrace_target): No longer install it.
9973 * infcmd.c (interrupt_target_1): Adjust.
9974 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
9975 (child_interrupt): Declare.
9976 (inferior::terminal_state): New.
9977 * inflow.c (struct terminal_info): Update comments.
9978 (inferior_process_group): Delete.
9979 (terminal_is_ours): Delete.
9980 (gdb_tty_state): New.
9981 (child_terminal_init): Adjust.
9982 (is_gdb_terminal, sharing_input_terminal_1)
9983 (sharing_input_terminal): New functions.
9984 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
9985 Set the process's actual process group in the foreground if
9986 possible. Handle is_ours_for_output/is_ours distinction. Don't
9987 mark terminal as the inferior's if not sharing GDB's terminal.
9988 Don't check attach_flag.
9989 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
9990 pass down a target_terminal_state.
9991 (child_terminal_save_inferior): New, factored out from ...
9992 (child_terminal_ours_1): ... this. Handle
9993 target_terminal_state::is_ours_for_output.
9994 (child_interrupt, child_pass_ctrlc): New.
9995 (inflow_inferior_exit): Clear the inferior's terminal_state.
9996 (copy_terminal_info): Copy the inferior's terminal state.
9997 (_initialize_inflow): Remove reference to terminal_is_ours.
9998 * inflow.h (inferior_process_group): Delete.
9999 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
10000 * procfs.c (procfs_target): Don't install procfs_interrupt.
10001 (procfs_interrupt): Delete.
10002 * remote.c (remote_serial_quit_handler): Adjust.
10003 (remote_interrupt): Remove ptid parameter. Adjust.
10004 * target-delegates.c: Regenerate.
10005 * target.c: Include "terminal.h".
10006 (target_terminal::terminal_state): Rename to ...
10007 (target_terminal::m_terminal_state): ... this.
10008 (target_terminal::init): Adjust.
10009 (target_terminal::inferior): Adjust to per-inferior
10010 terminal_state.
10011 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
10012 (target_terminal::ours, target_terminal::ours_for_output): Use
10013 target_terminal_is_ours_kind.
10014 (target_interrupt): Remove ptid parameter. Adjust.
10015 (default_target_pass_ctrlc): Adjust.
10016 * target.h (target_ops::to_terminal_save_inferior): New field.
10017 (target_ops::to_interrupt): Remove ptid_t parameter.
10018 (target_interrupt): Remove ptid_t parameter. Update comment.
10019 (target_pass_ctrlc): Update comment.
10020 * target/target.h (target_terminal_state): New scoped enum,
10021 factored out of ...
10022 (target_terminal::terminal_state): ... here.
10023 (target_terminal::inferior): Update comments.
10024 (target_terminal::restore_inferior): New.
10025 (target_terminal::is_inferior, target_terminal::is_ours)
10026 (target_terminal::is_ours_for_output): Adjust.
10027 (target_terminal::scoped_restore_terminal_state): Adjust to
10028 rename, and call restore_inferior() instead of inferior().
10029 (target_terminal::scoped_restore_terminal_state::m_state): Change
10030 type.
10031 (target_terminal::terminal_state): Rename to ...
10032 (target_terminal::m_terminal_state): ... this and change type.
10033
9c3a5d93
PA
100342018-01-30 Pedro Alves <palves@redhat.com>
10035
10036 * linux-nat.c (wait_for_signal): New function.
10037 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
10038 directly.
10039 (async_terminal_is_ours)
10040 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
10041 (linux_nat_add_target): Don't override
10042 to_terminal_inferior/to_terminal_ours.
10043
69ab5edb
SDJ
100442018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
10045
10046 * remote.c (remote_follow_fork): Don't call "detach_inferior".
10047
fc8e7e75
SM
100482018-01-28 Simon Marchi <simon.marchi@ericsson.com>
10049
10050 * dwarf2read.c (free_dwo_files): Add forward-declaration.
10051 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
10052 dwarf2_per_objfile_free here.
10053 (dwarf2_per_objfile_free): Remove.
10054 (_initialize_dwarf2_read): Don't register
10055 dwarf2_per_objfile_free as a registry cleanup.
10056
b2a426e2
EZ
100572018-01-27 Eli Zaretskii <eliz@gnu.org>
10058
10059 Avoid compilation errors in MinGW native builds
10060
10061 The error is triggered by including python-internal.h, and the
10062 error message is:
10063
10064 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
10065 from build-gnulib/import/math.h:27,
10066 from d:/usr/Python26/include/pyport.h:235,
10067 from d:/usr/Python26/include/Python.h:58,
10068 from python/python-internal.h:94,
10069 from python/py-arch.c:24:
10070 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
10071 using ::hypot;
10072 ^~~~~
10073
10074 This happens because Python headers define 'hypot' to expand t
10075 '_hypot' in the Windows builds.
10076 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
10077 'hypoth'. This avoids a compilation error.
10078
0bdd8eac
AH
100792018-01-26 Alan Hayward <alan.hayward@arm.com>
10080
10081 * MAINTAINERS (Write After Approval): Fix ordering.
10082
56ae9dc3
AH
100832018-01-26 Alan Hayward <alan.hayward@arm.com>
10084
10085 * MAINTAINERS (Write After Approval): Add Alan Hayward.
10086
7433498b
AM
100872018-01-26 Alan Modra <amodra@gmail.com>
10088
10089 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
10090 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
10091 Remove nop. Make const. Comment.
10092 (powerpc32_plt_stub_so_2): New.
10093 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
10094 Correct count. Update uses.
10095 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
10096 Move common code reading PLT entry word. Correct
10097 powerpc32_plt_stub PLT address calculation.
10098 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
10099 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
10100 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
10101 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
10102 (ppc64_standard_linkage8): Likewise.
10103 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
10104 Correct insns description.
10105 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
10106
0f59d5fc
PA
101072018-01-24 Pedro Alves <palves@redhat.com>
10108
10109 GCC PR libstdc++/83906
10110 * gdbtypes.c (operator==(const dynamic_prop &,
10111 const dynamic_prop &)): New.
10112 (operator==(const range_bounds &, const range_bounds &)): New.
10113 (check_types_equal): Use them instead of memcmp.
10114 * gdbtypes.h (operator==(const dynamic_prop &,
10115 const dynamic_prop &)): Declare.
10116 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
10117 (operator==(const range_bounds &, const range_bounds &)): Declare.
10118 (operator!=(const range_bounds &, const range_bounds &)): Declare.
10119
ef8914a4
PR
101202018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10121
10122 * s390-linux-tdep.c (s390_record_address_mask)
10123 (s390_record_calc_disp_common, s390_record_calc_disp)
10124 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10125 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10126 (s390_process_record): Move to s390-tdep.c.
10127 (s390_linux_init_abi_any): Adjust.
10128 * s390-tdep.c (s390_record_address_mask)
10129 (s390_record_calc_disp_common, s390_record_calc_disp)
10130 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
10131 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
10132 (s390_process_record): Moved from s390-linux-tdep.c
10133 (s390_gdbarch_init): Adjust.
10134
d6e58945
PR
101352018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10136
10137 * s390-linux-nat.c (s390-tdep.h): New include.
10138 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
10139 (HFILES_NO_SRCDIR): Add s390-tdep.h.
10140 (ALLDEPFILES): Add s390-tdep.c.
10141 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
10142 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
10143 * s390-tdep.h: ...this. New file.
10144 * s390-linux-tdep.c (s390-tdep.h): New include.
10145 (_initialize_s390_tdep): Rename to...
10146 (_initialize_s390_linux_tdep): ...this and adjust.
10147 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
10148 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
10149 s390-tdep.h.
10150 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
10151 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
10152 (s390_is_partial_instruction, s390_software_single_step)
10153 (is_non_branch_ril, s390_displaced_step_copy_insn)
10154 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
10155 (s390_prologue_data, s390_addr, s390_store, s390_load)
10156 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
10157 (s390_register_call_saved, s390_guess_tracepoint_registers)
10158 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
10159 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
10160 (s390_pseudo_register_name, s390_pseudo_register_type)
10161 (s390_pseudo_register_read, s390_pseudo_register_write)
10162 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
10163 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
10164 (s390_addr_bits_remove, s390_address_class_type_flags)
10165 (s390_address_class_type_flags_to_name)
10166 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
10167 (s390_function_arg_float, s390_function_arg_vector)
10168 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
10169 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
10170 (s390_frame_align, s390_register_return_value, s390_return_value)
10171 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
10172 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
10173 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
10174 (s390_trad_frame_prev_register, s390_unwind_cache)
10175 (s390_prologue_frame_unwind_cache)
10176 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
10177 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
10178 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
10179 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
10180 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
10181 (s390_frame_base_address, s390_local_base_address)
10182 (s390_frame_base, s390_gcc_target_options)
10183 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
10184 (s390_validate_reg_range, s390_tdesc_valid)
10185 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
10186 * s390-tdep.c: ...this. New file.
10187
9c0b896e
PR
101882018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10189
10190 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
10191 (s390_process_record, s390_gdbarch_tdep_alloc)
10192 (s390_linux_init_abi_any): Use/set new hook.
10193
7042632b
PR
101942018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10195
10196 * s390-linux-tdep.c (osabi.h): New include.
10197 (s390_linux_init_abi_31, s390_linux_init_abi_64)
10198 (s390_linux_init_abi_any): New functions.
10199 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
10200
650f5e13
PR
102012018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10202
10203 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
10204 tdesc_has_registers check
10205
47c9317e
PR
102062018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10207
10208 * s390-linux-tdep.c (s390_tdesc_valid): New function.
10209 (s390_validate_reg_range): New macro.
10210 (s390_gdbarch_init): Adjust.
10211
095085d8
PR
102122018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10213
10214 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
10215 (s390_gdbarch_tdep_alloc): Adjust.
10216 (s390_gdbarch_init): Adjust.
10217
ab9bcc67
PR
102182018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10219
10220 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
10221 <have_tdb>: Change type to bool.
10222 (s390_gdbarch_tdep_alloc): Adjust.
10223 (s390_gdbarch_init): Adjust.
10224
21f6f5ff
PR
102252018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10226
10227 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
10228 (gdbarch_tdep) <have_upper, have_vx>: New fields.
10229 (s390_gdbarch_tdep_alloc): New function.
10230 (s390_gdbarch_init): Allocate tdep at start and use its fields
10231 instead of separate variables.
10232
0eb97953
PR
102332018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
10234
10235 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
10236 when looking for cached gdbarch and add comment for remaining.
10237
5c319bb2
PA
102382018-01-22 Pedro Alves <palves@redhat.com>
10239 Sergio Durigan Junior <sergiodj@redhat.com>
10240
10241 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
10242 case.
10243
d65ce302
MR
102442018-01-22 Maciej W. Rozycki <macro@mips.com>
10245
10246 * MAINTAINERS: Update my company e-mail address.
10247
ec7a5fcb
YQ
102482018-01-22 Yao Qi <yao.qi@linaro.org>
10249
10250 * regcache.c (cooked_write_test): New function.
10251 (_initialize_regcache): Register the test.
10252
11f57cb6
YQ
102532018-01-22 Yao Qi <yao.qi@linaro.org>
10254
10255 * ia64-tdep.c (ia64_pseudo_register_read): Call
10256 regcache->cooked_read instead of regcache_cooked_read_unsigned.
10257 * m32c-tdep.c (m32c_cat_read): Likewise.
10258 (m32c_r3r2r1r0_read): Likewise.
10259 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
10260 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
10261
03f50fc8
YQ
102622018-01-22 Yao Qi <yao.qi@linaro.org>
10263
10264 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
10265 method raw_read instead of regcache_raw_read.
10266 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
10267 * arm-tdep.c (arm_neon_quad_read): Likewise.
10268 * avr-tdep.c (avr_pseudo_register_read): Likewise.
10269 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
10270 * frv-tdep.c (frv_pseudo_register_read): Likewise.
10271 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
10272 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
10273 (i386_pseudo_register_read_into_value): Likewise.
10274 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
10275 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
10276 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
10277 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
10278 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
10279 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
10280 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
10281 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
10282 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
10283
dc711524
YQ
102842018-01-22 Yao Qi <yao.qi@linaro.org>
10285
10286 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
10287 * configure.tgt: Remove target mt.
10288 * mt-tdep.c: Remove.
10289 * regcache.c (cooked_read_test): Remove the check for mt.
10290
3f5a868b
YQ
102912018-01-22 Yao Qi <yao.qi@linaro.org>
10292
10293 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
10294 instead of gdbarch_pseudo_register_read_value.
10295
de4cb04a
JB
102962018-01-22 Joel Brobecker <brobecker@adacore.com>
10297
10298 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
10299 language is Ada.
10300
a9e40818
JB
103012018-01-22 Joel Brobecker <brobecker@adacore.com>
10302
10303 * linespec.c (create_sals_line_offset): Remove code that preserved
10304 the symtab_and_line's line number.
10305
e707fc44
AB
103062018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10307
10308 * varobj.c (varobj_create): Don't set valid_block when creating a
10309 floating varobj.
10310
03d0bf7b
AB
103112018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10312
10313 * varobj.c (varobj_create): Remove out of date comment.
10314
ae451627
AB
103152018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10316
10317 PR mi/20395
10318 * ada-exp.y (write_var_from_sym): Pass extra parameter when
10319 updating innermost block.
10320 * parse.c (innermost_block_tracker::update): Take extra type
10321 parameter, and check types match before updating innermost block.
10322 (write_dollar_variable): Update innermost block for registers.
10323 * parser-defs.h (enum innermost_block_tracker_type): New enum.
10324 (innermost_block_tracker::innermost_block_tracker): Initialise
10325 m_types member.
10326 (innermost_block_tracker::reset): Take type parameter.
10327 (innermost_block_tracker::update): Take type parameter, and pass
10328 type through as needed.
10329 (innermost_block_tracker::m_types): New member.
10330 * varobj.c (varobj_create): Pass type when reseting innermost
10331 block.
10332
aee1fcdf
AB
103332018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10334
10335 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
10336 * ada-lang.c (resolve_subexp): Likewise.
10337 * breakpoint.c (set_breakpoint_condition) Likewise.
10338 (watch_command_1) Likewise.
10339 * c-exp.y (variable): Likewise.
10340 * d-exp.y (PrimaryExpression): Likewise.
10341 * f-exp.y (variable): Likewise.
10342 * go-exp.y (variable): Likewise.
10343 * m2-exp.y (variable): Likewise.
10344 * objfiles.c (objfile::~objfile): Likewise.
10345 * p-exp.y (variable): Likewise.
10346 * parse.c (innermost_block): Change type.
10347 * parser-defs.h (class innermost_block_tracker): New.
10348 (innermost_block): Change to innermost_block_tracker.
10349 * printcmd.c (display_command): Switch to innermost_block API.
10350 (do_one_display): Likewise.
10351 * rust-exp.y (do_one_display): Likewise.
10352 * symfile.c (clear_symtab_users): Likewise.
10353 * varobj.c (varobj_create): Switch to innermost_block API, replace
10354 use of innermost_block with block stored on varobj object.
10355
396af9a1
AB
103562018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
10357
10358 * expression.h (innermost_block): Remove declaration.
10359 * varobj.c: Add 'parser-defs.h' include.
10360
fcfcc376
TT
103612018-01-19 Tom Tromey <tom@tromey.com>
10362
10363 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
10364 symbols in the static and global blocks.
10365
5a6c3296
JC
103662018-01-19 James Clarke <jrtc27@jrtc27.com>
10367
10368 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
10369 gdb_ptrace.h, and move including gdb_wait.h ...
10370 * nat/linux-ptrace.h: ... to here.
10371
bc09b0c1
SM
103722018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10373
10374 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
10375 inf_ptrace_detach_success.
10376 (inf_ptrace_detach_success): Add inferior parameter, use it
10377 instead of inferior_ptid, pass it to detach_inferior.
10378 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
10379 parameter.
10380 * inferior.c (detach_inferior): Add overload that takes an
10381 inferior object.
10382 * inferior.h (detach_inferior): Likewise.
10383 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
10384 use inferior_ptid, adjust call to inf_ptrace_detach_success.
10385 * linux-thread-db.c (thread_db_detach): Use inf parameter.
10386
6e1e1966
SM
103872018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10388
10389 * target.h (struct target_ops) <to_detach>: Add inferior
10390 parameter.
10391 (target_detach): Likewise.
10392 * target.c (dispose_inferior): Pass inferior down.
10393 (target_detach): Pass inferior down. Assert that it is equal to
10394 the current inferior.
10395 * aix-thread.c (aix_thread_detach): Pass inferior down.
10396 * corefile.c (core_file_command): Pass current_inferior() down.
10397 * corelow.c (core_detach): Add inferior parameter.
10398 * darwin-nat.c (darwin_detach): Likewise.
10399 * gnu-nat.c (gnu_detach): Likewise.
10400 * inf-ptrace.c (inf_ptrace_detach): Likewise.
10401 * infcmd.c (detach_command): Pass current_inferior() down to
10402 target_detach.
10403 * infrun.c (follow_fork_inferior): Pass parent_inf to
10404 target_detach.
10405 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
10406 target_detach.
10407 * linux-nat.c (linux_nat_detach): Add inferior parameter.
10408 * linux-thread-db.c (thread_db_detach): Likewise.
10409 * nto-procfs.c (procfs_detach): Likewise.
10410 * procfs.c (procfs_detach): Likewise.
10411 * record.c (record_detach): Likewise.
10412 * record.h (struct inferior): Forward-declare.
10413 (record_detach): Add inferior parameter.
10414 * remote-sim.c (gdbsim_detach): Likewise.
10415 * remote.c (remote_detach_1): Likewise.
10416 (remote_detach): Likewise.
10417 (extended_remote_detach): Likewise.
10418 * sol-thread.c (sol_thread_detach): Likewise.
10419 * target-debug.h (target_debug_print_inferior_p): New macro.
10420 * target-delegates.c: Re-generate.
10421 * top.c (kill_or_detach): Pass inferior down to target_detach.
10422 * windows-nat.c (windows_detach): Add inferior parameter.
10423
6bd6f3b6
SM
104242018-01-19 Simon Marchi <simon.marchi@ericsson.com>
10425
10426 * target.h (struct target_ops) <to_detach>: Remove args
10427 parameter.
10428 (target_detach): Likewise.
10429 * target.c (dispose_inferior): Adjust.
10430 (target_detach): Remove args parameter, adjust.
10431 * aix-thread.c (aix_thread_detach): Adjust.
10432 * corefile.c (core_file_command): Adjust.
10433 * corelow.c (core_detach): Adjust.
10434 * darwin-nat.c (darwin_detach): Adjust.
10435 * gnu-nat.c (gnu_detach): Adjust.
10436 * inf-ptrace.c (inf_ptrace_detach): Adjust.
10437 * infcmd.c (detach_command): Adjust
10438 * infrun.c (follow_fork_inferior): Adjust.
10439 (handle_vfork_child_exec_or_exit): Adjust.
10440 * linux-fork.c (linux_fork_detach): Remove args parameter.
10441 * linux-fork.h (linux_fork_detach): Likewise.
10442 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
10443 * linux-thread-db.c (thread_db_detach): Likewise.
10444 * nto-procfs.c (procfs_detach): Likewise.
10445 * procfs.c (procfs_detach): Likewise.
10446 (do_detach): Remove signo parameter.
10447 * record.c (record_detach): Remove args parameter.
10448 * record.h (record_detach): Likewise.
10449 * remote-sim.c (gdbsim_detach): Likewise.
10450 * remote.c (remote_detach_1): Likewise.
10451 (remote_detach): Likewise.
10452 (extended_remote_detach): Likewise.
10453 * sol-thread.c (sol_thread_detach): Likewise.
10454 * target-delegates.c: Re-generate.
10455 * top.c (struct qt_args) <args>: Remove field.
10456 (kill_or_detach): Don't pass args.
10457 (quit_force): Don't set args.
10458 * windows-nat.c (windows_detach): Remove args parameter.
10459
88af8ea8
YQ
104602018-01-19 Yao Qi <yao.qi@linaro.org>
10461
10462 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
10463 (arm_linux_init_abi): Install it.
10464
dea445b9
YQ
104652018-01-19 Yao Qi <yao.qi@linaro.org>
10466
10467 * osabi.c (gdb_osabi_names): Extend the regexp for
10468 arm-linux-gnueabihf.
10469
4a17f768
YQ
104702018-01-18 Yao Qi <yao.qi@linaro.org>
10471
10472 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
10473 m_abbrevs.
10474 (abbrev_table::add_abbrev): Update.
10475 (abbrev_table::lookup_abbrev): Update.
10476
d679c21a
YQ
104772018-01-18 Yao Qi <yao.qi@linaro.org>
10478
10479 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
10480
7d937cad
SDJ
104812018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
10482
10483 * compile/compile.c (compile_to_object): Convert "triplet_rx"
10484 to "std::string".
10485
9e14690d
TT
104862018-01-17 Tom Tromey <tom@tromey.com>
10487
10488 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
10489
50a82047
TT
104902018-01-17 Tom Tromey <tom@tromey.com>
10491
10492 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
10493 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
10494 (create_array_type_with_stride): Update.
10495 * dwarf2read.c (set_die_type): Update.
10496
c89b44cd
TT
104972018-01-17 Tom Tromey <tom@tromey.com>
10498
10499 * dwarf2read.c (delayed_method_info): Remove typedef.
10500 (dwarf2_cu::method_info): Now a std::vector.
10501 (add_to_method_list): Update.
10502 (free_delayed_list): Remove.
10503 (compute_delayed_physnames): Update.
10504 (process_full_comp_unit, process_full_type_unit): Clear the method
10505 list. Remove cleanups.
10506 (psymtab_include_file_name): Add name_holder parameter. Use
10507 unique_xmalloc_ptr.
10508 (dwarf_decode_lines): Update.
10509
fcd3b13d
SM
105102018-01-17 Tom Tromey <tom@tromey.com>
10511 Simon Marchi <simon.marchi@ericsson.com>
10512
10513 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
10514 (dwarf2_per_objfile::free_cached_comp_units)
10515 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10516 (init_cutu_and_read_dies_no_follow): Update.
10517 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
10518 (dwarf2_cu::~dwarf2_cu): New.
10519 (free_heap_comp_unit, free_stack_comp_unit): Remove.
10520 (age_cached_comp_units, free_one_cached_comp_unit): Update.
10521
685af9cd
TT
105222018-01-17 Tom Tromey <tom@tromey.com>
10523 Simon Marchi <simon.marchi@ericsson.com>
10524
10525 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
10526 (struct die_reader_specs) <abbrev_table>: New member.
10527 (struct abbrev_table): Add constructor.
10528 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
10529 <abbrev_obstack>: Now an auto_obstack.
10530 (abbrev_table_up): New typedef.
10531 (init_cu_die_reader): Add abbrev_table parameter.
10532 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
10533 Add result_dwo_abbrev_table.
10534 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
10535 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
10536 Update.
10537 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
10538 parameter.
10539 (skip_children): Update.
10540 (abbrev_table::alloc_abbrev): Rename from
10541 abbrev_table_alloc_abbrev.
10542 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
10543 (abbrev_table::lookup_abbrev): Rename from
10544 abbrev_table_lookup_abbrev.
10545 (abbrev_table_read_table): Return abbrev_table_up.
10546 (abbrev_table_free, abbrev_table_free_cleanup)
10547 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
10548 (load_partial_dies): Update.
10549
5e2db402
TT
105502018-01-17 Tom Tromey <tom@tromey.com>
10551
10552 * dwarf2read.c (dwarf2_compute_name): Update comment.
10553 (read_func_scope, read_variable): Update.
10554 (new_symbol): Remove.
10555 (new_symbol_full): Rename to new_symbol.
10556
ee7f689e 105572018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
10558
10559 PR gdb/16577
10560 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
10561 a warning instead of throwing an error, set section size to 0 and return
10562 NULL.
10563 * gdb_bfd.h (gdb_bfd_map_section): Update description.
10564
4d9b86e1
SM
105652018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10566
10567 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
10568 std::string.
10569 (linux_ptrace_attach_fail_reason_string): Likewise.
10570 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
10571 Likewise.
10572 (linux_ptrace_attach_fail_reason_string): Likewise.
10573 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
10574
a7b2d0fb
SM
105752018-01-17 Simon Marchi <simon.marchi@ericsson.com>
10576
10577 * linux-nat.c (linux_nat_attach): Remove xstrdup.
10578
f517c180
EA
105792018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
10580
10581 PR gdb/21559
10582 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
10583 checking for fs_base/gs_base fields in struct user_regs_struct.
10584 * configure: Regenerate.
10585
7045b1ca
YQ
105862018-01-17 Yao Qi <yao.qi@linaro.org>
10587
10588 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
10589 function.
10590 (aarch64_linux_init_abi): Install it to gdbarch hook
10591 gcc_target_options.
10592
db422fb2
PA
105932018-01-15 Pedro Alves <palves@redhat.com>
10594
10595 * common/signals-state-save-restore.c
10596 (save_original_signals_state): Fix typos.
10597
ba643918
SDJ
105982017-01-12 Tom Tromey <tom@tromey.com>
10599 Sergio Durigan Junior <sergiodj@redhat.com>
10600
10601 * Makefile.in (install-only): Install gdb-add-index.
10602
906b4aac
JB
106032018-01-12 John Baldwin <jhb@FreeBSD.org>
10604
10605 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
10606
bdf2a94a
AA
106072018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
10608
10609 * infrun.c (keep_going_pass_signal): Clear step-over info when
10610 insert_breakpoints fails.
10611
71d378ae
PA
106122018-01-11 Pedro Alves <palves@redhat.com>
10613
10614 PR gdb/22583
10615 * infrun.c (resume): Rename to ...
10616 (resume_1): ... this.
10617 (resume): Reimplement as wrapper around resume_1.
10618
3cada740
PA
106192018-01-11 Pedro Alves <palves@redhat.com>
10620
10621 PR remote/22597
10622 * remote.c (remote_parse_stop_reply): Default to the last-set
10623 general thread instead of to 'magic_null_ptid'.
10624
618daa93
PA
106252018-01-10 Pedro Alves <palves@redhat.com>
10626
10627 * language.h (language_get_symbol_name_matcher): Rename ...
10628 (get_symbol_name_matcher): ... this.
10629 * language.c (language_get_symbol_name_matcher): Ditto.
10630 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
10631 callers adjusted.
10632
c63d3e8d
PA
106332018-01-10 Pedro Alves <palves@redhat.com>
10634
10635 PR gdb/22670
10636 * dwarf2read.c
10637 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
10638 Adjust to use language_get_symbol_name_matcher instead of
10639 language_defn::la_get_symbol_name_matcher.
10640 * language.c (language_get_symbol_name_matcher): If in Ada mode
10641 and the lookup name is a verbatim match, return Ada's matcher.
10642 * language.h (language_get_symbol_name_matcher): Adjust comment.
10643 (ada_lookup_name_info::verbatim_p):: New method.
10644
d4c2a405
PA
106452018-01-10 Pedro Alves <palves@redhat.com>
10646
10647 PR gdb/22670
10648 * ada-lang.c (ada_collect_symbol_completion_matches): If the
10649 minsym's language is language_auto or language_cplus, pass down
10650 language_ada instead.
10651 * symtab.c (compare_symbol_name): Don't frob symbol language here.
10652
8825213e
PA
106532018-01-10 Pedro Alves <palves@redhat.com>
10654
10655 PR gdb/22670
10656 * minsyms.c (linkage_name_str): New function.
10657 (iterate_over_minimal_symbols): Use it.
10658
2d97a5d9
JB
106592018-01-09 John Baldwin <jhb@FreeBSD.org>
10660
10661 * NEWS: Document that 'info proc' now works on FreeBSD.
10662
92fce24d
JB
106632018-01-09 John Baldwin <jhb@FreeBSD.org>
10664
10665 * configure.ac: Check for kinfo_getfile in libutil.
10666 * configure: Regenerate.
10667 * config.in: Regenerate.
10668 * fbsd-nat.c: Include "fbsd-tdep.h".
10669 (fbsd_fetch_cmdline): New.
10670 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
10671 rather than calling error.
10672 (fbsd_info_proc): New.
10673 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
10674 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
10675 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
10676
262f62f5
JB
106772018-01-09 John Baldwin <jhb@FreeBSD.org>
10678
10679 * fbsd-nat.c (struct free_deleter): Remove.
10680 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
10681
b999e203
JB
106822018-01-09 John Baldwin <jhb@FreeBSD.org>
10683
10684 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
10685 NULL for an empty pathname.
10686
d2176225
JB
106872018-01-09 John Baldwin <jhb@FreeBSD.org>
10688
10689 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
10690 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
10691 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
10692 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
10693 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
10694 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
10695 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
10696 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
10697 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
10698 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
10699 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
10700 (fbsd_core_fetch_timeval, fbsd_print_sigset)
10701 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
10702 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
10703 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
10704
9c4ac400
ST
107052018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
10706
10707 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
10708 (gnu_xfer_auxv): New function.
10709 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
10710 TARGET_OBJECT_AUXV.
10711
1e5ded6c
YQ
107122018-01-08 Yao Qi <yao.qi@linaro.org>
10713 Simon Marchi <simon.marchi@ericsson.com>
10714
10715 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
10716 common/selftest.c.
10717 (COMMON_OBS): Remove selftest.o.
10718 * configure.ac: Append selftest-arch.c and common/selftest.c to
10719 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
10720 * configure: Re-generated.
10721 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
10722 GDB_SELF_TEST.
10723 (maintenance_info_selftests): Likewise.
10724
04bafb1e
XR
107252018-01-08 Xavier Roirand <roirand@adacore.com>
10726
10727 * ada-valprint.c (val_print_packed_array_elements): Use
10728 proper number of elements when printing an array indexed
10729 by an enumeration type.
10730
518817b3
SM
107312018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
10732
10733 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
10734 (dw2_get_file_names_reader): Adjust.
10735 (lookup_dwo_signatured_type): Adjust.
10736 (lookup_dwp_signatured_type): Adjust.
10737 (lookup_signatured_type): Adjust.
10738 (create_type_unit_group): Adjust.
10739 (get_type_unit_group): Adjust.
10740 (process_psymtab_comp_unit_reader): Adjust.
10741 (build_type_psymtabs_reader): Adjust.
10742 (scan_partial_symbols): Adjust.
10743 (add_partial_symbol): Adjust.
10744 (add_partial_subprogram): Adjust.
10745 (peek_die_abbrev): Adjust.
10746 (fixup_go_packaging): Adjust.
10747 (process_imported_unit_die): Adjust.
10748 (dwarf2_compute_name): Adjust.
10749 (dwarf2_physname): Adjust.
10750 (read_import_statement): Adjust.
10751 (handle_DW_AT_stmt_list): Adjust.
10752 (read_file_scope): Adjust.
10753 (read_func_scope): Adjust.
10754 (read_lexical_block_scope): Adjust.
10755 (read_call_site_scope): Adjust.
10756 (read_variable): Adjust.
10757 (dwarf2_rnglists_process): Adjust.
10758 (dwarf2_ranges_process): Adjust.
10759 (dwarf2_ranges_read): Adjust.
10760 (dwarf2_get_pc_bounds): Adjust.
10761 (dwarf2_record_block_ranges): Adjust.
10762 (dwarf2_add_field): Adjust.
10763 (dwarf2_add_member_fn): Adjust.
10764 (read_structure_type): Adjust.
10765 (process_structure_scope): Adjust.
10766 (read_enumeration_type): Adjust.
10767 (read_array_type): Adjust.
10768 (mark_common_block_symbol_computed): Adjust.
10769 (read_common_block): Adjust.
10770 (read_namespace_type): Adjust.
10771 (read_namespace): Adjust.
10772 (read_module_type): Adjust.
10773 (read_tag_pointer_type): Adjust.
10774 (read_tag_ptr_to_member_type): Adjust.
10775 (read_tag_string_type): Adjust.
10776 (read_subroutine_type): Adjust.
10777 (read_typedef): Adjust.
10778 (read_base_type): Adjust.
10779 (attr_to_dynamic_prop): Adjust.
10780 (read_subrange_type): Adjust.
10781 (read_unspecified_type): Adjust.
10782 (dwarf2_read_abbrevs): Adjust.
10783 (load_partial_dies): Adjust.
10784 (read_partial_die): Adjust.
10785 (find_partial_die): Adjust.
10786 (guess_partial_die_structure_name): Adjust.
10787 (fixup_partial_die): Adjust.
10788 (read_attribute_value): Adjust.
10789 (read_addr_index): Adjust.
10790 (read_addr_index_from_leb128): Adjust.
10791 (read_str_index): Adjust.
10792 (dwarf2_string_attr): Adjust.
10793 (get_debug_line_section): Adjust.
10794 (dwarf_decode_line_header): Adjust.
10795 (lnp_state_machine::check_line_address): Adjust.
10796 (dwarf_decode_lines_1): Adjust.
10797 (dwarf_decode_lines): Adjust.
10798 (dwarf2_start_symtab): Adjust.
10799 (var_decode_location): Adjust.
10800 (new_symbol_full): Adjust.
10801 (dwarf2_const_value_data): Adjust.
10802 (dwarf2_const_value_attr): Adjust.
10803 (dwarf2_const_value): Adjust.
10804 (die_type): Adjust.
10805 (die_containing_type): Adjust.
10806 (build_error_marker_type): Adjust.
10807 (lookup_die_type): Adjust.
10808 (guess_full_die_structure_name): Adjust.
10809 (anonymous_struct_prefix): Adjust.
10810 (determine_prefix): Adjust.
10811 (dwarf2_name): Adjust.
10812 (follow_die_ref_or_sig): Adjust.
10813 (follow_die_offset): Adjust.
10814 (follow_die_ref): Adjust.
10815 (follow_die_sig_1): Adjust.
10816 (follow_die_sig): Adjust.
10817 (get_signatured_type): Adjust.
10818 (get_DW_AT_signature_type): Adjust.
10819 (decode_locdesc): Adjust.
10820 (dwarf_decode_macros): Adjust.
10821 (cu_debug_loc_section): Adjust.
10822 (fill_in_loclist_baton): Adjust.
10823 (dwarf2_symbol_mark_computed): Adjust.
10824 (init_one_comp_unit): Don't assign
10825 dwarf2_cu::dwarf2_per_objfile.
10826 (set_die_type): Adjust.
10827
ed2dc618
SM
108282018-01-07 Simon Marchi <simon.marchi@ericsson.com>
10829
10830 * dwarf2read.c (struct mapped_debug_names): Add constructor.
10831 <dwarf2_per_objfile>: New field.
10832 (dwarf2_per_objfile): Remove global.
10833 (get_dwarf2_per_objfile): New function.
10834 (set_dwarf2_per_objfile): New function.
10835 (dwarf2_build_psymtabs_hard): Change objfile parameter to
10836 dwarf2_per_objfile.
10837 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10838 (read_abbrev_offset): Likewise.
10839 (read_indirect_string): Likewise.
10840 (read_indirect_line_string): Likewise.
10841 (read_indirect_string_at_offset): Likewise.
10842 (read_indirect_string_from_dwz): Likewise.
10843 (dwarf2_find_containing_comp_unit): Change objfile parameter to
10844 dwarf2_per_objfile.
10845 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
10846 (create_all_comp_units): Change objfile parameter to
10847 dwarf2_per_objfile.
10848 (create_all_type_units): Likewise.
10849 (process_queue): Add dwarf2_per_objfile parameter.
10850 (read_and_check_comp_unit_head): Likewise.
10851 (lookup_dwo_unit_in_dwp): Likewise.
10852 (get_dwp_file): Likewise.
10853 (process_cu_includes): Likewise.
10854 (struct free_dwo_file_cleanup_data): New struct.
10855 (dwarf2_has_info): Use get_dwarf2_per_objfile and
10856 set_dwarf2_per_objfile.
10857 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
10858 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
10859 context, adjust calls.
10860 (dw2_instantiate_symtab): Likewise.
10861 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
10862 (dw2_get_cu): Likewise.
10863 (create_cu_from_index_list): Change objfile parameter to
10864 dwarf2_per_objfile.
10865 (create_cus_from_index_list): Get dwarf2_per_objfile from
10866 context, adjust calls.
10867 (create_cus_from_index): Likewise.
10868 (create_signatured_type_table_from_index): Change objfile
10869 parameter to dwarf2_per_objfile.
10870 (create_signatured_type_table_from_debug_names): Change objfile
10871 parameter to dwarf2_per_objfile.
10872 (create_addrmap_from_index): Likewise.
10873 (create_addrmap_from_aranges): Likewise.
10874 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
10875 (dw2_setup): Remove.
10876 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
10877 context.
10878 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
10879 get_dwarf2_per_objfile.
10880 (dw2_forget_cached_source_info): Likewise.
10881 (dw2_map_symtabs_matching_filename): Likewise.
10882 (struct dw2_symtab_iterator) <index>: Remove.
10883 <dwarf2_per_objfile>: New field.
10884 (dw2_symtab_iter_init): Replace index parameter with
10885 dwarf2_per_objfile.
10886 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
10887 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
10888 (dw2_print_stats): Likewise.
10889 (dw2_dump): Likewise.
10890 (dw2_expand_symtabs_for_function): Likewise.
10891 (dw2_expand_all_symtabs): Likewise.
10892 (dw2_expand_symtabs_with_fullname): Likewise.
10893 (dw2_expand_marked_cus): Replace index and objfile parameters
10894 with dwarf2_per_objfile.
10895 (dw_expand_symtabs_matching_file_matcher): Add
10896 dwarf2_per_objfile parameter and adjust calls.
10897 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
10898 adjust calls.
10899 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
10900 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
10901 adjust calls.
10902 (create_cus_from_debug_names_list): Replace objfile parameter
10903 with dwarf2_per_objfile and adjust calls.
10904 (create_cus_from_debug_names): Likewise.
10905 (dwarf2_read_debug_names): Likewise.
10906 (mapped_debug_names::namei_to_name): Adjust call.
10907 (dw2_debug_names_iterator::next): Likewise.
10908 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
10909 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
10910 (dw2_debug_names_dump): Likewise.
10911 (dw2_debug_names_expand_symtabs_for_function): Likewise.
10912 (dw2_debug_names_expand_symtabs_matching): Likewise.
10913 (dwarf2_initialize_objfile): Likewise.
10914 (dwarf2_build_psymtabs): Likewise.
10915 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
10916 this_cu.
10917 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
10918 (read_and_check_comp_unit_head): Likewise.
10919 (read_abbrev_offset): Likewise.
10920 (create_debug_type_hash_table): Likewise.
10921 (create_debug_types_hash_table): Likewise.
10922 (create_all_type_units): Replace objfile parameter with
10923 dwarf2_per_objfile.
10924 (add_type_unit): Add dwarf2_per_objfile parameter.
10925 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
10926 with dwarf2_per_objfile.
10927 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
10928 (lookup_dwp_signatured_type): Likewise.
10929 (lookup_signatured_type): Likewise.
10930 (read_cutu_die_from_dwo): Likewise.
10931 (init_tu_and_read_dwo_dies): Likewise.
10932 (init_cutu_and_read_dies): Likewise.
10933 (init_cutu_and_read_dies_no_follow): Likewise.
10934 (allocate_type_unit_groups_table): Add objfile parameter.
10935 (create_type_unit_group): Use dwarf2_per_objfile from cu.
10936 (get_type_unit_group): Likewise.
10937 (process_psymtab_comp_unit): Update call.
10938 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
10939 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
10940 (print_tu_stats): Likewise.
10941 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
10942 in void* parameter.
10943 (build_type_psymtabs): Change objfile parameter to
10944 dwarf2_per_objfile.
10945 (process_skeletonless_type_unit): Use dwarf2_per_objfile
10946 passed in void* parameter.
10947 (process_skeletonless_type_units): Change objfile parameter to
10948 dwarf2_per_objfile.
10949 (set_partial_user): Likewise.
10950 (dwarf2_build_psymtabs_hard): Likewise.
10951 (read_comp_units_from_section): Likewise.
10952 (create_all_comp_units): Likewise.
10953 (scan_partial_symbols): Update calls.
10954 (add_partial_symbol): Likewise.
10955 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
10956 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
10957 (process_queue): Add dwarf2_per_objfile parameter.
10958 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
10959 (compute_compunit_symtab_includes): Likewise.
10960 (process_cu_includes): Add dwarf2_per_objfile parameter.
10961 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
10962 (process_full_type_unit): Likewise.
10963 (process_imported_unit_die): Update call.
10964 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
10965 (read_file_scope): Likewise.
10966 (allocate_dwo_file_hash_table): Add objfile parameter.
10967 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
10968 (create_cus_hash_table): Likewise.
10969 (create_dwp_hash_table): Likewise.
10970 (create_dwo_unit_in_dwp_v1): Likewise.
10971 (create_dwp_v2_section): Likewise.
10972 (create_dwo_unit_in_dwp_v2): Likewise.
10973 (lookup_dwo_unit_in_dwp): Likewise.
10974 (try_open_dwop_file): Likewise.
10975 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
10976 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
10977 cleanup to include a reference to dwarf2_per_objfile.
10978 (open_dwp_file): Add dwarf2_per_objfile parameter.
10979 (open_and_init_dwp_file): Likewise.
10980 (get_dwp_file): Likewise.
10981 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
10982 (queue_and_load_all_dwo_tus): Update call.
10983 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
10984 data.
10985 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
10986 (dwarf2_ranges_process): Likewise.
10987 (dwarf2_get_pc_bounds): Likewise.
10988 (mark_common_block_symbol_computed): Likewise.
10989 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
10990 (dwarf2_read_abbrevs): Update call.
10991 (read_partial_die): Use dwarf2_per_objfile from cu.
10992 (find_partial_die): Likewise.
10993 (fixup_partial_die): Likewise.
10994 (read_attribute_value): Likewise.
10995 (read_indirect_string_at_offset_from): Add objfile parameter.
10996 (read_indirect_string_at_offset): Add dwarf2_per_objfile
10997 parameter.
10998 (read_indirect_string_from_dwz): Add objfile parameter.
10999 (read_indirect_string): Add objfile parameter.
11000 (read_addr_index_1): Add dwarf2_per_objfile parameter.
11001 (read_addr_index): Use dwarf2_per_objfile from cu.
11002 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
11003 call dw2_setup.
11004 (read_str_index): Use dwarf2_per_objfile from cu.
11005 (get_debug_line_section): Likewise.
11006 (read_formatted_entries): Add dwarf2_per_objfile parameter.
11007 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
11008 (new_symbol_full): Use dwarf2_per_objfile from cu.
11009 (build_error_marker_type): Likewise.
11010 (lookup_die_type): Likewise.
11011 (determine_prefix): Likewise.
11012 (follow_die_offset): Likewise.
11013 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
11014 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
11015 (dwarf2_fetch_die_type_sect_off): Likewise.
11016 (dwarf2_get_die_type): Likewise.
11017 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
11018 (get_signatured_type): Likewise.
11019 (get_DW_AT_signature_type): Likewise.
11020 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
11021 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
11022 (cu_debug_loc_section): Likewise.
11023 (fill_in_loclist_baton): Likewise.
11024 (dwarf2_symbol_mark_computed): Likewise.
11025 (dwarf2_find_containing_comp_unit): Change objfile parameter to
11026 dwarf2_per_objfile.
11027 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
11028 parameter.
11029 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
11030 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
11031 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
11032 (set_die_type): Use dwarf2_free_objfile from cu.
11033 (get_die_type_at_offset): Likewise.
11034 (dwarf2_per_objfile_free): Don't assign global variable.
11035 (debug_names) <constructor>: Add dwarf2_per_objfile
11036 parameter, update m_debugstrlookup construction.
11037 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
11038 parameter.
11039 <m_dwarf2_per_objfile>: New field.
11040 <lookup>: Use m_dwarf2_per_objfile.
11041 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
11042 (psyms_seen_size): Likewise.
11043 (write_gdbindex): Replace objfile parameter with
11044 dwarf2_per_objfile.
11045 (write_debug_names): Likewise.
11046 (write_psymtabs_to_index): Likewise.
11047 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
11048 calls.
11049
e3b94546
SM
110502018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11051
11052 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
11053 <dwarf2_per_objfile>: New field.
11054 (struct dwarf2_per_cu_data) <objfile>: Remove.
11055 <dwarf2_per_objfile>: New field.
11056 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
11057 of objfile.
11058 (create_signatured_type_table_from_index): Likewise.
11059 (create_debug_type_hash_table): Likewise.
11060 (fill_in_sig_entry_from_dwo_entry): Likewise.
11061 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
11062 (create_type_unit_group): Assign dwarf2_per_objfile instead of
11063 objfile.
11064 (create_partial_symtab): Access objfile through
11065 dwarf2_per_objfile.
11066 (process_psymtab_comp_unit_reader): Likewise.
11067 (read_comp_units_from_section): Likewise.
11068 (scan_partial_symbols): Likewise.
11069 (add_partial_symbol): Likewise.
11070 (add_partial_subprogram): Likewise.
11071 (peek_die_abbrev): Likewise.
11072 (fixup_go_packaging): Likewise.
11073 (process_full_comp_unit): Likewise.
11074 (process_full_type_unit): Likewise.
11075 (process_imported_unit_die): Likewise.
11076 (dwarf2_compute_name): Likewise.
11077 (dwarf2_physname): Likewise.
11078 (read_import_statement): Likewise.
11079 (create_cus_hash_table): Assign dwarf2_physname instead of
11080 objfile.
11081 (read_func_scope): Access objfile through dwarf2_per_objfile.
11082 (read_lexical_block_scope): Likewise.
11083 (read_call_site_scope): Likewise.
11084 (read_variable): Likewise.
11085 (dwarf2_rnglists_process): Likewise.
11086 (dwarf2_ranges_process): Likewise.
11087 (dwarf2_ranges_read): Likewise.
11088 (dwarf2_record_block_ranges): Likewise.
11089 (dwarf2_add_field): Likewise.
11090 (dwarf2_add_member_fn): Likewise.
11091 (read_structure_type): Likewise.
11092 (process_structure_scope): Likewise.
11093 (read_enumeration_type): Likewise.
11094 (read_array_type): Likewise.
11095 (read_common_block): Likewise.
11096 (read_namespace_type): Likewise.
11097 (read_namespace): Likewise.
11098 (read_module_type): Likewise.
11099 (read_tag_pointer_type): Likewise.
11100 (read_tag_ptr_to_member_type): Likewise.
11101 (read_tag_string_type): Likewise.
11102 (read_subroutine_type): Likewise.
11103 (read_typedef): Likewise.
11104 (read_base_type): Likewise.
11105 (attr_to_dynamic_prop): Likewise.
11106 (read_subrange_type): Likewise.
11107 (read_unspecified_type): Likewise.
11108 (load_partial_dies): Likewise.
11109 (read_partial_die): Likewise.
11110 (find_partial_die): Likewise.
11111 (guess_partial_die_structure_name): Likewise.
11112 (fixup_partial_die): Likewise.
11113 (read_attribute_value): Likewise.
11114 (read_addr_index_from_leb128): Likewise.
11115 (dwarf2_read_addr_index): Likewise.
11116 (dwarf2_string_attr): Likewise.
11117 (lnp_state_machine::check_line_address): Likewise.
11118 (dwarf_decode_lines_1): Likewise.
11119 (dwarf_decode_lines): Likewise.
11120 (dwarf2_start_symtab): Likewise.
11121 (var_decode_location): Likewise.
11122 (new_symbol_full): Likewise.
11123 (dwarf2_const_value_data): Likewise.
11124 (dwarf2_const_value_attr): Likewise.
11125 (dwarf2_const_value): Likewise.
11126 (die_type): Likewise.
11127 (die_containing_type): Likewise.
11128 (lookup_die_type): Likewise.
11129 (guess_full_die_structure_name): Likewise.
11130 (anonymous_struct_prefix): Likewise.
11131 (dwarf2_name): Likewise.
11132 (follow_die_ref_or_sig): Likewise.
11133 (follow_die_offset): Likewise.
11134 (follow_die_ref): Likewise.
11135 (dwarf2_fetch_die_loc_sect_off): Likewise.
11136 (dwarf2_fetch_constant_bytes): Likewise.
11137 (dwarf2_fetch_die_type_sect_off): Likewise.
11138 (dwarf2_get_die_type): Likewise.
11139 (follow_die_sig): Likewise.
11140 (decode_locdesc): Likewise.
11141 (dwarf2_per_cu_objfile): Likewise.
11142 (dwarf2_per_cu_text_offset): Likewise.
11143 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
11144 objfile.
11145 (set_die_type): Access objfile through
11146 dwarf2_per_objfile.
11147
b01ba14d
SM
111482018-01-07 Simon Marchi <simon.marchi@ericsson.com>
11149
11150 * valprint.c (converted_character_d): Remove typedef.
11151 (DEF_VEC_O (converted_character_d)): Remove.
11152 (count_next_character): Use std::vector.
11153 (print_converted_chars_to_obstack): Likewise.
11154 (generic_printstr): Likewise.
11155
4d0fdd9b
SM
111562018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11157
11158 * xml-support.h (struct gdb_xml_value): Add constructor.
11159 <value>: Change type to unique_xmalloc_ptr.
11160 (gdb_xml_value_s): Remove typedef.
11161 (DEF_VEC_O (gdb_xml_value_s)): Remove.
11162 (gdb_xml_element_start_handler): Change parameter type to
11163 std::vector.
11164 (xml_find_attribute): Likewise.
11165 * xml-support.c (xml_find_attribute): Change parameter type to
11166 std::vector and adjust.
11167 (gdb_xml_values_cleanup): Remove.
11168 (gdb_xml_parser::start_element): Adjust to std::vector.
11169 (xinclude_start_include): Change paraeter type to std::vector
11170 and adjust.
11171 * btrace.c (check_xml_btrace_version): Likewise.
11172 (parse_xml_btrace_block): Likewise.
11173 (parse_xml_btrace_pt_config_cpu): Likewise.
11174 (parse_xml_btrace_pt): Likewise.
11175 (parse_xml_btrace_conf_bts): Likewise.
11176 (parse_xml_btrace_conf_pt): Likewise.
11177 * memory-map.c (memory_map_start_memory): Likewise.
11178 (memory_map_start_property): Likewise.
11179 * osdata.c (osdata_start_osdata): Likewise.
11180 (osdata_start_item): Likewise.
11181 (osdata_start_column): Likewise.
11182 * remote.c (start_thread): Likewise.
11183 * solib-aix.c (library_list_start_library): Likewise.
11184 (library_list_start_list): Likewise.
11185 * solib-svr4.c (library_list_start_library): Likewise.
11186 (svr4_library_list_start_list): Likewise.
11187 * solib-target.c (library_list_start_segment): Likewise.
11188 (library_list_start_section): Likewise.
11189 (library_list_start_library): Likewise.
11190 (library_list_start_list): Likewise.
11191 * tracepoint.c (traceframe_info_start_memory): Likewise.
11192 (traceframe_info_start_tvar): Likewise.
11193 * xml-syscall.c (syscall_start_syscall): Likewise.
11194 * xml-tdesc.c (tdesc_start_target): Likewise.
11195 (tdesc_start_feature): Likewise.
11196 (tdesc_start_reg): Likewise.
11197 (tdesc_start_union): Likewise.
11198 (tdesc_start_struct): Likewise.
11199 (tdesc_start_flags): Likewise.
11200 (tdesc_start_enum): Likewise.
11201 (tdesc_start_field): Likewise.
11202 (tdesc_start_enum_value): Likewise.
11203 (tdesc_start_vector): Likewise.
11204
f979c73f
SM
112052018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11206
11207 * extension.h (struct xmethod_worker) <clone>: Remove.
11208 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
11209 Remove.
11210 (python_xmethod_worker::clone): Remove.
11211 * valops.c (find_overload_match): Use std::move instead of
11212 clone.
11213
ba18742c
SM
112142018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
11215
11216 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
11217 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
11218 <free_xmethod_worker_data>: Remove.
11219 <get_matching_xmethod_workers>: Chance VEC to std::vector.
11220 <get_xmethod_arg_types>: Remove.
11221 <get_xmethod_result_type>: Remove.
11222 <invoke_xmethod>: Remove.
11223 * extension.c (new_xmethod_worker): Remove.
11224 (clone_xmethod_worker): Remove.
11225 (get_matching_xmethod_workers): Return void, pass std::vector by
11226 pointer.
11227 (get_xmethod_arg_types): Rename to...
11228 (xmethod_worker::get_arg_types): ... this, and adjust.
11229 (get_xmethod_result_type): Rename to...
11230 (xmethod_worker::get_result_type): ... this, and adjust.
11231 (invoke_xmethod): Remove.
11232 (free_xmethod_worker): Remove.
11233 (free_xmethod_worker_vec): Remove.
11234 * extension.h (enum ext_lang_rc): Move here from
11235 extension-priv.h.
11236 (struct xmethod_worker): Add constructor and destructor.
11237 <data>: Remove.
11238 <value>: Remove.
11239 <invoke, clone, do_get_result_type, do_get_arg_types>: New
11240 virtual pure methods.
11241 <get_arg_types, get_result_type>: New methods.
11242 (xmethod_worker_ptr): Remove typedef.
11243 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
11244 (xmethod_worker_vec): Remove typedef.
11245 (xmethod_worker_up): New typedef.
11246 (invoke_xmethod): Remove.
11247 (clone_xmethod_worker): Remove.
11248 (free_xmethod_worker): Remove.
11249 (free_xmethod_worker_vec): Remove.
11250 (get_xmethod_arg_types): Remove.
11251 (get_xmethod_result_type): Remove.
11252 * valops.c (find_method_list): Use std::vector, don't use
11253 intermediate vector.
11254 (value_find_oload_method_list): Use std::vector.
11255 (find_overload_match): Use std::vector.
11256 (find_oload_champ): Use std::vector.
11257 * value.c (value_free): Use operator delete.
11258 (value_of_xmethod): Rename to...
11259 (value_from_xmethod): ... this. Don't assign
11260 xmethod_worker::value, take rvalue-reference.
11261 (result_type_of_xmethod): Adjust.
11262 (call_xmethod): Adjust.
11263 * value.h: Include extension.h.
11264 (struct xmethod_worker): Don't forward-declare.
11265 (value_of_xmethod): Rename to...
11266 (value_from_xmethod): ... this, take rvalue-reference.
11267 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
11268 (struct python_xmethod_worker): ... this, add constructor and
11269 destructor.
11270 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
11271 (gdbpy_free_xmethod_worker_data): Rename to...
11272 (python_xmethod_worker::~python_xmethod_worker): ... this and
11273 adjust.
11274 (gdbpy_clone_xmethod_worker_data): Rename to...
11275 (python_xmethod_worker::clone): ... this and adjust.
11276 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
11277 temporary vector.
11278 (gdbpy_get_xmethod_arg_types): Rename to...
11279 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
11280 (gdbpy_get_xmethod_result_type): Rename to...
11281 (python_xmethod_worker::do_get_result_type): ... this and
11282 adjust.
11283 (gdbpy_invoke_xmethod): Rename to...
11284 (python_xmethod_worker::invoke): ... this and adjust.
11285 (new_python_xmethod_worker): Rename to...
11286 (python_xmethod_worker::python_xmethod_worker): ... this and
11287 adjust.
11288 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
11289 Remove.
11290 (gdbpy_free_xmethod_worker_data): Remove.
11291 (gdbpy_get_matching_xmethod_workers): Use std::vector.
11292 (gdbpy_get_xmethod_arg_types): Remove.
11293 (gdbpy_get_xmethod_result_type): Remove.
11294 (gdbpy_invoke_xmethod): Remove.
11295 * python/python.c (python_extension_ops): Remove obsolete
11296 callbacks.
11297
e379cee6
PA
112982018-01-05 Pedro Alves <palves@redhat.com>
11299
11300 PR gdb/18653
11301 * common/signals-state-save-restore.c
11302 (save_original_signals_state): New parameter 'quiet'. Warn if we
11303 find a custom handler preinstalled, instead of internal erroring.
11304 But only warn if !quiet.
11305 * common/signals-state-save-restore.h
11306 (save_original_signals_state): New parameter 'quiet'.
11307 * main.c (captured_main_1): Move save_original_signals_state call
11308 after option handling, and pass QUIET.
11309
a655456c
PA
113102018-01-05 Pedro Alves <palves@redhat.com>
11311
11312 * spu-tdep.c (spu_catch_start): Pass
11313 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
11314
de63c46b
PA
113152018-01-05 Pedro Alves <palves@redhat.com>
11316
11317 PR gdb/22670
11318 * ada-lang.c (literal_symbol_name_matcher): New function.
11319 (ada_get_symbol_name_matcher): Use it for
11320 symbol_name_match_type::SEARCH_NAME.
11321 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
11322 it down instead of assuming symbol_name_match_type::FULL.
11323 * block.h (block_lookup_symbol): New parameter 'match_type'.
11324 * c-valprint.c (print_unpacked_pointer): Use
11325 lookup_symbol_search_name instead of lookup_symbol.
11326 * compile/compile-object-load.c (get_out_value_type): Pass down
11327 symbol_name_match_type::SEARCH_NAME.
11328 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
11329 symbol_name_match_type::FULL.
11330 * cp-support.c (cp_get_symbol_name_matcher): Handle
11331 symbol_name_match_type::SEARCH_NAME.
11332 * infrun.c (insert_exception_resume_breakpoint): Use
11333 lookup_symbol_search_name.
11334 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
11335 * psymtab.c (maintenance_check_psymtabs): Use
11336 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
11337 * stack.c (print_frame_args): Use lookup_symbol_search_name and
11338 SYMBOL_SEARCH_NAME.
11339 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
11340 if symbol_name_match_type::SEARCH_NAME.
11341 (lookup_symbol_in_language): Pass down
11342 symbol_name_match_type::FULL.
11343 (lookup_symbol_search_name): New.
11344 (lookup_language_this): Pass down
11345 symbol_name_match_type::SEARCH_NAME.
11346 (lookup_symbol_aux, lookup_local_symbol): New parameter
11347 'match_type'. Pass it down.
11348 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
11349 (lookup_symbol_search_name): New declaration.
11350 (lookup_symbol_in_block): New 'match_type' parameter.
11351
f98fc17b
PA
113522018-01-05 Pedro Alves <palves@redhat.com>
11353
11354 PR gdb/22670
11355 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
11356 ada_lookup_symbol.
11357 (ada_lookup_symbol): Reimplement in terms of
11358 ada_lookup_symbol_list, bits factored out from
11359 ada_lookup_encoded_symbol.
11360
342f8240
JB
113612018-01-05 Joel Brobecker <brobecker@adacore.com>
11362
11363 * ada-exp.y (write_object_renaming): When subscripting an array
11364 using a symbol as the index, pass the block in call to
11365 ada_lookup_encoded_symbol when looking that symbol up.
11366
7150d33c
JG
113672018-01-05 Jerome Guitton <guitton@adacore.com>
11368
11369 * ada-lang.c (ada_array_length): Use ada_index_type instead of
11370 TYPE_INDEX_TYPE.
11371
cc0e770c
JB
113722018-01-05 Joel Brobecker <brobecker@adacore.com>
11373
11374 * ada-lang.c (ada_to_fixed_value_create): Add handling of
11375 the case where VALUE_LVAL (val0) is not lval_memory.
11376
f79da888 113772018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
11378
11379 * ada-valprint.c (print_optional_low_bound): Handle
11380 character-indexed array printing like boolean-indexed array
11381 printing.
11382
cd385f94
JB
113832018-01-05 Joel Brobecker <brobecker@adacore.com>
11384
11385 * NEWS: Create a new section for the next release branch.
11386 Rename the section of the current branch, now that it has
11387 been cut.
11388
09aca949
JB
113892018-01-05 Joel Brobecker <brobecker@adacore.com>
11390
11391 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
11392 * version.in: Bump version to 8.1.50.DATE-git.
11393
9f757bf7
XR
113942018-01-03 Xavier Roirand <roirand@adacore.com>
11395
11396 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
11397 Add field.
11398 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
11399 Add field.
11400 (default_exception_support_info) <catch_handlers_sym>: Add field.
11401 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
11402 (ada_exception_name_addr_1): Add "catch handlers" handling.
11403 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
11404 Update all callers.
11405 (create_excep_cond_exprs) <ex>: Add parameter.
11406 (re_set_exception): Update create_excep_cond_exprs call.
11407 (print_it_exception, print_one_exception, print_mention_exception)
11408 (print_recreate_exception): Add "catch handler" handling.
11409 (allocate_location_catch_handlers, re_set_catch_handlers)
11410 (check_status_catch_handlers, print_it_catch_handlers)
11411 (print_one_catch_handlers, print_mention_catch_handlers)
11412 (print_recreate_catch_handlers): New function.
11413 (catch_handlers_breakpoint_ops): New variable.
11414 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
11415 Add parameter. Add "catch handler" handling.
11416 (ada_exception_sym_name, ada_exception_breakpoint_ops):
11417 Add "catch handler" handling.
11418 (ada_exception_catchpoint_cond_string): Add "catch handler"
11419 handling.
11420 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
11421 call.
11422 (catch_ada_handlers_command): New function.
11423 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
11424 operations structure.
11425 (_initialize_ada_language): Add "catch handlers" command entry.
11426 * NEWS: Document "catch handlers" feature.
11427
9fe561ab
JB
114282018-01-02 Joel Brobecker <brobecker@adacore.com>
11429
11430 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
11431 account when creating the array type of the slice.
11432 (ada_value_slice): Likewise.
11433
a405673c
JB
114342018-01-02 Joel Brobecker <brobecker@adacore.com>
11435
11436 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
11437 New enum value.
11438 (create_array_type_with_stride): Add byte_stride_prop parameter.
11439 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
11440 New parameter. Update all callers in this file.
11441 (array_type_has_dynamic_stride): New function.
11442 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
11443 of arrays with dynamic byte strides.
11444 * dwarf2read.c (read_array_type): Add support for dynamic
11445 DW_AT_byte_stride attributes.
11446
74a2f8ff
JB
114472018-01-02 Joel Brobecker <brobecker@adacore.com>
11448
11449 * dwarf2read.c (read_unspecified_type): Treat
11450 DW_TAG_enumeration_type DIEs from Ada units as stubs.
11451
e2882c85
JB
114522018-01-01 Joel Brobecker <brobecker@adacore.com>
11453
11454 Update copyright year range in all GDB files.
11455
1690bb24
JB
114562018-01-01 Joel Brobecker <brobecker@adacore.com>
11457
11458 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
11459 and gdb/testsuite/gdb.base/step-line.c.
11460
0f0c98a8
JB
114612018-01-01 Joel Brobecker <brobecker@adacore.com>
11462
11463 * copyright.py (main): Dump the contents of
11464 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
11465 even if BY_HAND is empty.
11466
82e1e79a
JB
114672018-01-01 Joel Brobecker <brobecker@adacore.com>
11468
11469 * top.c (print_gdb_version): Update Copyright year in version
11470 message.
11471
053f54e5 114722018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 11473
053f54e5 11474 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 11475
053f54e5 11476For older changes see ChangeLog-2017.
c906108c
SS
11477\f
11478Local Variables:
11479mode: change-log
11480left-margin: 8
11481fill-column: 74
11482version-control: never
57da7796 11483coding: utf-8
c906108c 11484End:
This page took 2.677193 seconds and 4 git commands to generate.