[gdb] Add 'Concept Index' entry '&' for background execution
[deliverable/binutils-gdb.git] / gdb / ChangeLog
CommitLineData
5d9a0608
TV
12018-06-14 Tom de Vries <tdevries@suse.de>
2
3 PR cli/22573
4 * infcmd.c (print_return_value_1): Use get_user_print_options instead of
5 get_no_prettyformat_print_options.
6
ab89b5a5
SM
72018-06-13 Simon Marchi <simon.marchi@ericsson.com>
8
9 * sparc-nat.h: Include target.h.
10 * sparc64-linux-nat.c (class sparc64_linux_nat_target)
11 <fetch_registers>: Remove this argument in function call.
12 <store_registers>: Remove this argument in function call, remove
13 extra semicolon.
14 <low_forget_process>: Call sparc64_forget_process instead of
15 sparc_forget_process.
16
62c808ae
RO
172018-06-13 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
18
19 * procfs.c (_initialize_procfs): Use add_inf_child_target.
20 (procfs_target::make_corefile_notes): Adjust to new
21 target_read_alloc return type.
22
1840d81a
AB
232018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
24 Stephen Roberts <stephen.roberts@arm.com>
25
26 PR gdb/22882
27 * infrun.c (fetch_inferior_event): If GDB is not proceeding then
28 run INF_EXEC_COMPLETE handler, even when not calling normal_stop.
29 Move should_notify_stop local into more inner scope.
30
9516f85a
AB
312018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
32 Stephen Roberts <stephen.roberts@arm.com>
33
34 PR gdb/22882
35 * infrun.c (resume_1): Add call to mark_async_event_handler.
36
defd2172
AB
372018-06-12 Andrew Burgess <andrew.burgess@embecosm.com>
38
39 * infrun.c (do_target_wait): Change old version of $pc printed.
40
7b23e087
SM
412018-06-11 Simon Marchi <simon.marchi@ericsson.com>
42
43 * dwarf2read.c (read_index_from_section): Rename to...
44 (read_gdb_index_from_section): ... this, update all callers.
45 (dwarf2_read_index): Rename to...
46 (dwarf2_read_gdb_index): ... this, update all callers.
47
69c67a0b
JDA
482018-06-11 John David Anglin <danglin@gcc.gnu.org>
49
50 * gdb/hppa-linux-nat.c
51 (hppa_linux_nat_target::fetch_inferior_registers): Rename to
52 hppa_linux_nat_target::fetch_registers.
53
65d4cada
AH
542018-06-11 Alan Hayward <alan.hayward@arm.com>
55
56 * aarch64-tdep.c (aarch64_dwarf_reg_to_regnum): Add mappings.
57 * aarch64-tdep.h (AARCH64_DWARF_SVE_VG): Add define.
58 (AARCH64_DWARF_SVE_FFR): Likewise.
59 (AARCH64_DWARF_SVE_P0): Likewise.
60 (AARCH64_DWARF_SVE_Z0): Likewise.
61
f868386e
AH
622018-06-11 Alan Hayward <alan.hayward@arm.com>
63
64 * common/common-regcache.h (raw_compare): New function.
65 * regcache.c (regcache::raw_compare): Likewise.
66 * regcache.h (regcache::raw_compare): New declaration.
67
9c861883
AH
682018-06-11 Alan Hayward <alan.hayward@arm.com>
69
70 * common/common-regcache.h (reg_buffer_common): New structure.
71 * regcache.c (reg_buffer::invalidate): Move from detached_regcache.
72 (reg_buffer::raw_supply): Likewise.
73 (reg_buffer::raw_supply_integer): Likewise.
74 (reg_buffer::raw_supply_zeroed): Likewise.
75 (reg_buffer::raw_collect): Likewise.
76 (reg_buffer::raw_collect_integer): Likewise.
77 * regcache.h (reg_buffer::invalidate): Move from detached_regcache.
78 (reg_buffer::raw_supply): Likewise.
79 (reg_buffer::raw_supply_integer): Likewise.
80 (reg_buffer::raw_supply_zeroed): Likewise.
81 (reg_buffer::raw_collect): Likewise.
82 (reg_buffer::raw_collect_integer): Likewise.
83
953edf2b
TT
842018-06-10 Tom Tromey <tom@tromey.com>
85
86 * remote.c (stop_reply_p): Remove typedef. Don't declare queue.
87 (class remote_state) <stop_reply_queue>: Now std::vector.
88 (remote_state::~remote_state)
89 (remote_target::stop_reply_queue_length): Update.
90 (struct queue_iter_param, remove_child_of_pending_fork)
91 (struct check_pending_event_prevents_wildcard_vcont_callback_data)
92 (check_pending_event_prevents_wildcard_vcont_callback)
93 (remove_stop_reply_for_inferior)
94 (remove_stop_reply_of_remote_state)
95 (remote_notif_remove_once_on_match)
96 (stop_reply_match_ptid_and_ws)
97 (remote_kill_child_of_pending_fork): Remove.
98 (remote_target::remove_new_fork_children)
99 (remote_target::check_pending_events_prevent_wildcard_vcont)
100 (remote_target::discard_pending_stop_replies)
101 (remote_target::discard_pending_stop_replies_in_queue)
102 (remote_target::remote_notif_remove_queued_reply)
103 (remote_target::queued_stop_reply)
104 (remote_target::push_stop_reply, remote_target::peek_stop_reply)
105 (remote_target::wait, remote_target::kill_new_fork_children)
106 (remote_target::async): Update.
107
1ddbba9d
TT
1082018-06-10 Tom Tromey <tom@tromey.com>
109
110 * record-full.c (record_full_arch_list_cleanups): Remove.
111 (record_full_message): Use try/catch.
112 (record_full_wait_cleanups): Remove.
113 (record_full_wait_1): Use try/catch.
114 (record_full_restore): Likewise.
115
219605fd
TT
1162018-06-10 Tom Tromey <tom@tromey.com>
117
118 * record-full.c (record_full_breakpoint_p): Remove typedef. Don't
119 declare VEC. Add constructor.
120 <in_target_beneath>: Now bool.
121 (record_full_breakpoints): Now a std::vector, static.
122 (record_full_sync_record_breakpoints)
123 (record_full_init_record_breakpoints)
124 (record_full_target::insert_breakpoint)
125 (record_full_target::remove_breakpoint): Update. Don't use XNEW.
126
71b73764
SM
1272018-06-10 Simon Marchi <simon.marchi@polymtl.ca>
128
129 * dwarf2read.c (process_cu_includes): Remove struct keyword.
130 * serial.c (serial_interface_lookup): Remove struct keyword.
131
4360561f
TT
1322018-06-10 Tom Tromey <tom@tromey.com>
133
134 * procfs.c (procfs_target::xfer_partial): Use "beneath" as a
135 method.
136 * nto-procfs.c (nto_procfs_target::xfer_partial): Use "beneath" as
137 a method.
138 * go32-nat.c (go32_nat_target::xfer_partial): Use "beneath" as a
139 method.
140 * arm-linux-nat.c (arm_linux_nat_target::read_description): Use
141 "beneath" as a method.
142 * arm-fbsd-nat.c (arm_fbsd_nat_target::read_description):
143 Use "beneath" as a method.
144
d14b92bf
TT
1452018-06-10 Tom Tromey <tom@tromey.com>
146
147 * tracefile.c (struct trace_file_writer_deleter): New.
148 <operator()>: Rename from trace_file_writer_xfree.
149 (trace_file_writer_up): New typedef.
150 (tsave_command, trace_save_tfile, trace_save_ctf): Update.
151
835dcf92
SM
1522018-06-09 Simon Marchi <simon.marchi@ericsson.com>
153
154 * regcache.h (reg_buffer) <~reg_buffer>: Use default destructor.
155 <m_registers, m_register_status>: Change type to
156 std::unique_ptr.
157 * regcache.c (reg_buffer::reg_buffer): Use new instead of
158 XCNEWVEC.
159
aac0d564
SM
1602018-06-09 Simon Marchi <simon.marchi@ericsson.com>
161
162 * common/common-regcache.h (enum register_status): Add
163 underlying type "signed char".
164 * regcache.h (reg_buffer) <m_register_status>: Change type to
165 register_status *.
166 * regcache.c (reg_buffer::reg_buffer): Alocate arrays of
167 register_status instead of signed char.
168 (reg_buffer::save): Use REG_UNKNOWN instead of 0.
169 (reg_buffer::get_register_status): Remove cast.
170 (readable_regcache::raw_read): Remove cast.
171 (readable_regcache::cooked_read): Remove cast.
172
77ad7394
TT
1732018-06-09 Tom Tromey <tom@tromey.com>
174
175 * source.c (reverse_search_command, forward_search_command): Use
176 scoped_fd.
177
191cca63
TT
1782018-06-09 Tom Tromey <tom@tromey.com>
179
180 * serial.c (serial_ops_p): Remove typedef. Don't declare VEC.
181 (serial_ops_list): Now static, std::vector.
182 (serial_interface_lookup, serial_add_interface): Update.
183
c5d0225d
TT
1842018-06-09 Tom Tromey <tom@tromey.com>
185
186 * dwarf2read.c (process_cu_includes): Update.
187 (process_full_comp_unit): Update.
188 * dwarf2read.h (struct dwarf2_per_objfile) <just_read_cus>: Now a
189 std::vector.
190
aeab5128
PK
1912018-06-08 Paul Koning <paul_koning@dell.com>
192
193 PR gdb/23252
194
195 * python/python.c (do_start_initialization):
196 Avoid call to internal Python API.
197 (init__gdb_module): New function.
198
5045b3d7
GB
1992018-06-08 Gary Benson <gbenson@redhat.com>
200
201 * linux-thread-db.c (valprint.h): New include.
202 (struct check_thread_db_info): New structure.
203 (check_thread_db_on_load, tdb_testinfo): New static globals.
204 (check_thread_db, check_thread_db_callback): New functions.
205 (try_thread_db_load_1): Run integrity checks if requested.
206 (maintenance_check_libthread_db): New function.
207 (_initialize_thread_db): Register "maint check libthread-db"
208 and "maint set/show check-libthread-db".
209 * NEWS: Mention the above new commands.
210
2f4f025f
TT
2112018-06-08 Tom Tromey <tom@tromey.com>
212
213 * windows-nat.c (windows_nat_target::xfer_partial): "beneath" is
214 now a method.
215
343b0027
TT
2162018-06-08 Tom Tromey <tom@tromey.com>
217
218 * btrace.c (parse_xml_raw): Use gdb::unique_xmalloc_ptr.
219
8dcc53b3
TT
2202018-06-08 Tom Tromey <tom@tromey.com>
221
222 * common/btrace-common.h (struct btrace_data): Add constructor,
223 destructor, move assignment operator.
224 <empty, clear, fini>: New methods.
225 <format>: Initialize.
226 (btrace_data_init, btrace_data_fini, btrace_data_clear)
227 (btrace_data_empty): Don't declare.
228 * common/btrace-common.c (btrace_data_init): Remove.
229 (btrace_data::fini): Rename from btrace_data_fini.
230 (btrace_data::empty): Rename from btrace_data_empty.
231 (btrace_data::clear): Rename from btrace_data_clear. Return
232 bool.
233 * btrace.h (make_cleanup_btrace_data): Don't declare.
234 * btrace.c (btrace_add_pc, btrace_stitch_trace, btrace_clear)
235 (parse_xml_btrace): Update.
236 (do_btrace_data_cleanup, make_cleanup_btrace_data): Remove.
237 (maint_btrace_clear_packet_history_cmd): Update.
238
a1740ee1
PA
2392018-06-07 Pedro Alves <palves@redhat.com>
240
241 * target.h (target_ops) <beneath>: Now a method. All references
242 updated.
243 (class target_stack): New.
244 * target.c (g_target_stack): New.
245 (g_current_top_target): Delete.
246 (current_top_target): Get the top target out of g_target_stack.
247 (target_stack::push, target_stack::unpush): New.
248 (push_target, unpush_target): Reimplement.
249 (target_is_pushed): Reimplement in terms of g_target_stack.
250 (target_ops::beneath, target_stack::find_beneath): New.
251
d6ca69cd
PA
2522018-06-07 Pedro Alves <palves@redhat.com>
253
254 * target.h (find_target_beneath): Delete declaration.
255 * target.c (find_target_beneath): Delete definition.
256 * aix-thread.c: All callers of find_target_beneath adjusted to
257 call target_ops::beneath instead.
258 * bsd-uthread.c: Likewise.
259 * linux-thread-db.c: Likewise.
260 * ravenscar-thread.c: Likewise.
261 * sol-thread.c: Likewise.
262 * spu-multiarch.c: Likewise.
263
b6a8c27b
PA
2642018-06-07 Pedro Alves <palves@redhat.com>
265
266 * target.h (target_ops) <beneath>: Now a method. All references
267 updated.
268 (target_ops) <m_beneath>: New.
269 * target.c (target_ops::beneath): New.
270 * corelow.c: Adjust all references to target_ops::beneath.
271 * linux-thread-db.c: Likewise.
272 * make-target-delegates: Likewise.
273 * record-btrace.c: Likewise.
274 * record-full.c: Likewise.
275 * remote.c: Likewise.
276 * target.c: Likewise.
277 * target-delegates.c: Regenerate.
278
8b88a78e
PA
2792018-06-07 Pedro Alves <palves@redhat.com>
280
281 * target.h (target_stack): Delete.
282 (current_top_target): Declare function.
283 * target.c (target_stack): Delete.
284 (g_current_top_target): New.
285 (current_top_target): New function.
286 * auxv.c: Use current_top_target instead of target_stack
287 throughout.
288 * avr-tdep.c: Likewise.
289 * breakpoint.c: Likewise.
290 * corefile.c: Likewise.
291 * elfread.c: Likewise.
292 * eval.c: Likewise.
293 * exceptions.c: Likewise.
294 * frame.c: Likewise.
295 * gdbarch-selftests.c: Likewise.
296 * gnu-v3-abi.c: Likewise.
297 * ia64-tdep.c: Likewise.
298 * ia64-vms-tdep.c: Likewise.
299 * infcall.c: Likewise.
300 * infcmd.c: Likewise.
301 * infrun.c: Likewise.
302 * linespec.c: Likewise.
303 * linux-tdep.c: Likewise.
304 * minsyms.c: Likewise.
305 * ppc-linux-nat.c: Likewise.
306 * ppc-linux-tdep.c: Likewise.
307 * procfs.c: Likewise.
308 * regcache.c: Likewise.
309 * remote.c: Likewise.
310 * rs6000-tdep.c: Likewise.
311 * s390-linux-nat.c: Likewise.
312 * s390-tdep.c: Likewise.
313 * solib-aix.c: Likewise.
314 * solib-darwin.c: Likewise.
315 * solib-dsbt.c: Likewise.
316 * solib-spu.c: Likewise.
317 * solib-svr4.c: Likewise.
318 * solib-target.c: Likewise.
319 * sparc-tdep.c: Likewise.
320 * sparc64-tdep.c: Likewise.
321 * spu-tdep.c: Likewise.
322 * symfile.c: Likewise.
323 * symtab.c: Likewise.
324 * target-descriptions.c: Likewise.
325 * target-memory.c: Likewise.
326 * target.c: Likewise.
327 * target.h: Likewise.
328 * tracefile-tfile.c: Likewise.
329 * tracepoint.c: Likewise.
330 * valops.c: Likewise.
331 * valprint.c: Likewise.
332 * value.c: Likewise.
333 * windows-tdep.c: Likewise.
334 * mi/mi-main.c: Likewise.
335
c7110220
TT
3362018-06-07 Tom Tromey <tom@tromey.com>
337
338 * valprint.h (build_address_symbolic): Declare.
339 * printcmd.c (print_address_symbolic): Update.
340 (build_address_symbolic): Change "name" and "filename" to
341 std::string.
342 * disasm.c (gdb_pretty_print_disassembler::pretty_print_insn):
343 Update.
344 * defs.h (build_address_symbolic): Remove declaration.
345
63bad7b6
AH
3462018-06-07 Alan Hayward <alan.hayward@arm.com>
347
348 * aarch64-tdep.c (AARCH64_SVE_V0_REGNUM): Add define.
349 (aarch64_vnv_type): Add function.
350 (aarch64_pseudo_register_name): Add V regs for SVE.
351 (aarch64_pseudo_register_type): Likewise.
352 (aarch64_pseudo_register_reggroup_p): Likewise.
353 (aarch64_pseudo_read_value_2): Use V0 offset for SVE
354 (aarch64_pseudo_read_value): Add V regs for SVE.
355 (aarch64_pseudo_write_2): Use V0 offset for SVE
356 (aarch64_pseudo_write): Add V regs for SVE.
357 * aarch64-tdep.h (struct gdbarch_tdep): Add vnv_type.
358
13e3c608
SDJ
3592018-06-06 Sergio Durigan Junior <sergiodj@redhat.com>
360
361 * arch/aarch64.h (sve_vq_from_vl): Guard with #ifndef.
362 (sve_vl_from_vq): Likewise.
363
c61b06a1
TT
3642018-06-05 Tom Tromey <tom@tromey.com>
365
366 * cli/cli-cmds.c (show_version): Update.
367 * top.c (print_gdb_version): Add "interactive" parameter.
368 Update.
369 * main.c (captured_main_1): Update.
370 * top.h (print_gdb_version): Add "interactive" parameter and a
371 comment.
372
115f7325
DM
3732018-06-05 David Malcolm <dmalcolm@redhat.com>
374
375 * common/enum-flags.h: Add trailing semicolon to example in
376 comment.
377
eb6af809
TT
3782018-06-05 Tom Tromey <tom@tromey.com>
379
380 PR cli/12326:
381 * NEWS: Add entry about pager.
382 * utils.c (pagination_disabled_for_command): New global.
383 (prompt_for_continue): Allow "c" response to prompt.
384 (reinitialize_more_filter): Clear
385 pagination_disabled_for_command.
386 (fputs_maybe_filtered): Check pagination_disabled_for_command.
387
54d343a2
TT
3882018-06-04 Tom Tromey <tom@tromey.com>
389
390 * ada-lang.h (ada_lookup_symbol_list): Update.
391 * ada-lang.c (resolve_subexp): Update.
392 (symbols_are_identical_enums): Change type of syms. Remove nsyms
393 parameter.
394 (remove_extra_symbols, remove_irrelevant_renamings): Likewise.
395 (ada_lookup_symbol_list_worker, ada_lookup_symbol_list): Change
396 results parameter to std::vector.
397 (ada_iterate_over_symbols, ada_lookup_symbol, get_var_value):
398 Update.
399 * ada-exp.y (block_lookup): Update.
400 (select_possible_type_sym): Change type of syms. Remove nsyms
401 parameter.
402 (write_var_or_type, write_name_assoc): Update.
403
178d6a63
JB
4042018-06-04 Joel Brobecker <brobecker@adacore.com>
405
406 * windows-nat.c (windows_nat_target::xfer_partial): Return
407 TARGET_XFER_E_IO if we need to delegate to the target beneath
408 but BENEATH is NULL.
409
baf00c2d
SM
4102018-06-04 Simon Marchi <simon.marchi@ericsson.com>
411
412 * Makefile.in (config.status): Add configure.nat as a
413 dependency.
414
214b073c
TT
4152018-06-04 Tom Tromey <tom@tromey.com>
416
417 * cp-name-parser.y (cpname_state): Add method declarations.
418 (HANDLE_QUAL): Update.
419 (cpname_state::d_grab, cpname_state::fill_comp)
420 (cpname_state::make_operator, cpname_state::make_dtor)
421 (cpname_state::make_builtin_type, cpname_state::make_name)
422 (cpname_state::d_qualify, cpname_state::d_int_type)
423 (cpname_state::d_unary, cpname_state::d_binary): Now methods.
424 (%union): Move earlier.
425
62b74cb8
AH
4262018-06-04 Alan Hayward <alan.hayward@arm.com>
427
428 * elfread.c (elf_symfile_segments): Use ELF_SECTION_IN_SEGMENT.
429
3c5cd5c3
AH
4302018-06-04 Alan Hayward <alan.hayward@arm.com>
431
432 * aarch64-tdep.c (aarch64_pseudo_read_value_1): New helper func.
433 (aarch64_pseudo_write_1): Likewise.
434 (aarch64_pseudo_read_value): Use helper.
435 (aarch64_pseudo_write): Likewise.
436
59f413d5
PA
4372018-06-04 Pedro Alves <palves@redhat.com>
438
439 * darwin-nat.c (darwin_ops): Delete.
440 (darwin_attach_pid): Use get_native_target.
441
1332a140
AH
4422018-06-04 Alan Hayward <alan.hayward@arm.com>
443
444 * aarch64-tdep.c (aarch64_get_tdesc_vq): Use uint64_t for VQ.
445 * aarch64-tdep.h (struct gdbarch_tdep): Likewise.
446
ba2d2bb2
AH
4472018-06-04 Alan Hayward <alan.hayward@arm.com>
448
449 * aarch64-linux-nat.c (aarch64_linux_read_description): Support SVE.
450 * aarch64-tdep.c (aarch64_get_tdesc_vq): New function.
451 (aarch64_gdbarch_init): Check for SVE.
452 * aarch64-tdep.h (gdbarch_tdep::has_sve): New function.
453
4542018-06-04 Alan Hayward <alan.hayward@arm.com>
39bfb937
AH
455
456 * aarch64-tdep.c (aarch64_read_description): Use uint64_t for VQ.
457 * aarch64-tdep.h (aarch64_read_description): Likewise.
458 * arch/aarch64.c (aarch64_create_target_description): Likewise.
459 * arch/aarch64.h (aarch64_create_target_description): Likewise.
460 * features/aarch64-sve.c (create_feature_aarch64_sve): Likewise.
461 * nat/aarch64-sve-linux-ptrace.c(aarch64_sve_get_vq): Likewise.
462 * nat/aarch64-sve-linux-ptrace.h (aarch64_sve_get_vq): Likewise.
463
41c60b4b
SM
4642018-06-02 Simon Marchi <simon.marchi@ericsson.com>
465
466 * value.c (value_fetch_lazy_bitfield): New.
467 (value_fetch_lazy_memory): New.
468 (value_fetch_lazy_register): New.
469 (value_fetch_lazy): Factor out to smaller functions.
470
7b640f72
TT
4712018-06-01 Tom Tromey <tom@tromey.com>
472
473 * cp-name-parser.y (backslashable, represented): Now const.
474
98e69eb3
TT
4752018-06-01 Tom Tromey <tom@tromey.com>
476
477 * cp-name-parser.y: Include parser-defs.h.
478 (parser_fprintf): Remove declaration.
479
49265499
TT
4802018-06-01 Tom Tromey <tom@tromey.com>
481
482 * cp-name-parser.y: Use %pure-parser, %lex-param, and
483 %parse-param.
484 (lexptr, prev_lexptr, error_lexptr, global_errmsg, demangle_info)
485 (global_result): Remove globals.
486 (struct cpname_state): New.
487 (yyparse): Don't declare.
488 (yylex, yyerror): Move declarations after %union.
489 (d_grab, fill_comp, make_operator, make_dtor, make_builtin_type)
490 (make_name): Add state parameter.
491 Update all callers.
492 (d_qualify, d_int_type, d_unary, d_binary, parse_number) Add state
493 parameter.
494 (HANDLE_QUAL, HANDLE_SPECIAL, HANDLE_TOKEN2, HANDLE_TOKEN3):
495 Update.
496 (yylex): Add lvalp, state parameters.
497 (yyerror): Add state parameter.
498 (cp_demangled_name_to_comp): Update.
499
55b6c984
TT
5002018-06-01 Tom Tromey <tom@tromey.com>
501
502 * cp-name-parser.y (parser_fprintf): Declare.
503 (GDB_YY_REMAP_PREFIX): Define.
504 Include yy-remap.h. Don't redefine yy* identifiers.
505
3513a6bb
TT
5062018-06-01 Tom Tromey <tom@tromey.com>
507
508 * python/py-type.c (typy_legacy_template_argument): Update.
509 * cp-support.h (cp_demangled_name_to_comp): Update.
510 * cp-name-parser.y (cp_demangled_name_to_comp): Change errmsg
511 parameter to be a "std::string *".
512 (main): Update.
513
e9cb46ab
L
5142018-06-01 H.J. Lu <hongjiu.lu@intel.com>
515
516 * ada-lex.l: Include "diagnostics.h" instead of
517 "common/diagnostics.h".
518 * unittests/environ-selftests.c: Likewise.
519 * common/diagnostics.h: Moved to ../include.
520
8e817061
JB
5212018-06-01 Joel Brobecker <brobecker@adacore.com>
522
523 * breakpoint.c (breakpoint_re_set): Temporarily force language_mode
524 to language_mode_manual while calling breakpoint_re_set_one.
525
a737d952
TT
5262018-06-01 Tom Tromey <tom@tromey.com>
527
528 * valops.c (value_cast_structs, destructor_name_p): Update.
529 * symtab.c (gdb_mangle_name): Update.
530 * stabsread.c (define_symbol, read_cpp_abbrev, read_baseclasses):
531 Update.
532 * p-valprint.c (pascal_object_is_vtbl_ptr_type)
533 (pascal_object_print_value_fields, pascal_object_print_value):
534 Update.
535 * p-typeprint.c (pascal_type_print_derivation_info): Update.
536 * linespec.c (find_methods): Update.
537 * gdbtypes.h (type_name_no_tag): Remove.
538 (type_name_or_error): Rename from type_name_no_tag_or_error.
539 * gdbtypes.c (type_name_no_tag): Remove.
540 (type_name_or_error): Rename from type_name_no_tag_or_error.
541 (lookup_struct_elt_type, check_typedef): Update.
542 * expprint.c (print_subexp_standard): Update.
543 * dwarf2read.c (dwarf2_add_field, load_partial_dies): Update.
544 * d-namespace.c (d_lookup_nested_symbol): Update.
545 * cp-valprint.c (cp_is_vtbl_ptr_type, cp_print_value_fields)
546 (cp_print_class_member): Update.
547 * cp-namespace.c (cp_lookup_nested_symbol): Update.
548 * completer.c (add_struct_fields): Update.
549 * c-typeprint.c (cp_type_print_derivation_info)
550 (c_type_print_varspec_prefix, c_type_print_base_struct_union):
551 Update.
552 * ada-lang.c (parse_old_style_renaming, xget_renaming_scope)
553 (ada_prefer_type, ada_is_exception_sym): Update.
554
e86ca25f
TT
5552018-06-01 Tom Tromey <tom@tromey.com>
556
557 * valops.c (enum_constant_from_type, value_namespace_elt)
558 (value_maybe_namespace_elt): Update.
559 * valarith.c (find_size_for_pointer_math): Update.
560 * target-descriptions.c (make_gdb_type): Update.
561 * symmisc.c (print_symbol): Update.
562 * stabsread.c (define_symbol, read_type)
563 (complain_about_struct_wipeout, add_undefined_type)
564 (cleanup_undefined_types_1): Update.
565 * rust-lang.c (rust_tuple_type_p, rust_slice_type_p)
566 (rust_range_type_p, val_print_struct, rust_print_struct_def)
567 (rust_internal_print_type, rust_composite_type)
568 (rust_evaluate_funcall, rust_evaluate_subexp)
569 (rust_inclusive_range_type_p): Update.
570 * python/py-type.c (typy_get_tag): Update.
571 * p-typeprint.c (pascal_type_print_base): Update.
572 * mdebugread.c (parse_symbol, parse_type): Update.
573 * m2-typeprint.c (m2_long_set, m2_record_fields, m2_enum):
574 Update.
575 * guile/scm-type.c (gdbscm_type_tag): Update.
576 * go-lang.c (sixg_string_p): Update.
577 * gnu-v3-abi.c (build_gdb_vtable_type, build_std_type_info_type):
578 Update.
579 * gdbtypes.h (struct main_type) <tag_name>: Remove.
580 (TYPE_TAG_NAME): Remove.
581 * gdbtypes.c (type_name_no_tag): Simplify.
582 (check_typedef, check_types_equal, recursive_dump_type)
583 (copy_type_recursive, arch_composite_type): Update.
584 * f-typeprint.c (f_type_print_base): Update. Print "Type" prefix
585 in summary mode when needed.
586 * eval.c (evaluate_funcall): Update.
587 * dwarf2read.c (fixup_go_packaging, read_structure_type)
588 (process_structure_scope, read_enumeration_type)
589 (read_namespace_type, read_module_type, determine_prefix): Update.
590 * cp-support.c (inspect_type): Update.
591 * coffread.c (process_coff_symbol, decode_base_type): Update.
592 * c-varobj.c (c_is_path_expr_parent): Update.
593 * c-typeprint.c (c_type_print_base_struct_union): Update.
594 (c_type_print_base_1): Update. Print struct/class/union/enum in
595 summary when using C language.
596 * ax-gdb.c (gen_struct_ref, gen_namespace_elt)
597 (gen_maybe_namespace_elt): Update.
598 * ada-lang.c (ada_type_name): Simplify.
599 (empty_record, ada_template_to_fixed_record_type_1)
600 (template_to_static_fixed_type)
601 (to_record_with_fixed_variant_part, ada_check_typedef): Update.
602
c1ec8cea
TT
6032018-06-01 Tom Tromey <tom@tromey.com>
604
605 * dwarf2read.c (dwarf2_compute_name): Pass CU's language to
606 c_print_type.
607 * c-typeprint.c (c_print_type_1): Add "language" parameter.
608 (c_print_type): Update.
609 (c_print_type): New overload.
610 (c_type_print_varspec_prefix, c_type_print_args)
611 (c_type_print_varspec_suffix, c_print_type_no_offsets)
612 (c_type_print_base_struct_union, c_type_print_base_1)
613 (cp_type_print_method_args): Add "language" parameter.
614 (c_type_print_base): Update.
615 * c-lang.h (c_print_type): Add new overload.
616
bc8453a7
TT
6172018-06-01 Tom Tromey <tom@tromey.com>
618
619 * typeprint.h (c_type_print_varspec_suffix): Don't declare.
620 * c-typeprint.c (c_type_print_varspec_suffix): Now static.
621
739e8682
AH
6222018-06-01 Alan Hayward <alan.hayward@arm.com>
623
624 * aarch64-tdep.c (aarch64_sve_register_names): New const
625 var.
626 * arch/aarch64.h (enum aarch64_regnum): Add SVE entries.
627 (AARCH64_SVE_Z_REGS_NUM): New define.
628 (AARCH64_SVE_P_REGS_NUM): Likewise.
629 (AARCH64_SVE_NUM_REGS): Likewise.
630
8a60efe7
UB
6312018-05-31 Uros Bizjak <ubizjak@gmail.com>
632
633 * nat/linux-ptrace.h [__alpha__]
634 (GDB_ARCH_IS_TRAP_BRKPT, GDB_ARCH_IS_TRAP_HWBKPT): Remove
635 definitions.
636
4b2dfa9d
MR
6372018-05-31 Maciej W. Rozycki <macro@mips.com>
638
639 * arch-utils.c (gdbarch_info_fill): Set `default_byte_order' to
640 the endianness selected.
641 * NEWS: Document `set endian auto' mode operation update.
642
122394f1
AH
6432018-05-31 Alan Hayward <alan.hayward@arm.com>
644
645 * Makefile.in: Add new header.
646 * gdb/arch/aarch64.h (sve_vg_from_vl): New macro.
647 (sve_vl_from_vg): Likewise.
648 (sve_vq_from_vl): Likewise.
649 (sve_vl_from_vq): Likewise.
650 (sve_vq_from_vg): Likewise.
651 (sve_vg_from_vq): Likewise.
652 * configure.nat: Add new c file.
653 * nat/aarch64-sve-linux-ptrace.c: New file.
654 * nat/aarch64-sve-linux-ptrace.h: New file.
655
95228a0d
AH
6562018-05-31 Alan Hayward <alan.hayward@arm.com>
657
658 * aarch64-linux-nat.c (aarch64_linux_read_description):
659 Add parmeter zero.
660 * aarch64-linux-tdep.c (aarch64_linux_core_read_description):
661 Likewise.
662 * aarch64-tdep.c (tdesc_aarch64_list): Add.
663 (aarch64_read_description): Use VQ to index tdesc_aarch64_list.
664 (aarch64_gdbarch_init): Add parmeter zero.
665 * aarch64-tdep.h (aarch64_read_description): Add VQ parmeter.
666 * arch/aarch64.c (aarch64_create_target_description): Check VQ.
667 * arch/aarch64.h (aarch64_create_target_description): Add VQ.
668 parmeter.
669 * doc/gdb.texinfo: Describe SVE feature
670 * features/aarch64-sve.c: New file.
671
5969f0db
OJ
6722018-05-31 Omair Javaid <omair.javaid@linaro.org>
673
674 PR gdb/23210
675 * gdbarch.sh (significant_addr_bit): Default to zero when
676 not set by target architecture.
677 * gdbarch.c: Re-generated.
678 * utils.c (address_significant): Update.
679
61367c61
JB
6802018-05-30 Joel Brobecker <brobecker@adacore.com>
681
682 * stack.c (func_command): Remove trailing newline in call to error.
683
34a79281
SM
6842018-05-30 Simon Marchi <simon.marchi@ericsson.com>
685
686 * regcache.h (regcache_raw_collect): Remove, update callers to
687 use regcache::raw_collect.
688 * regcache.c (regcache_raw_collect): Remove.
689
73e1c03f
SM
6902018-05-30 Simon Marchi <simon.marchi@ericsson.com>
691
692 * regcache.h (regcache_raw_supply): Remove, update callers to
693 use detached_regcache::raw_supply.
694 * regcache.c (regcache_raw_supply): Remove.
695
e4c4a59b
SM
6962018-05-30 Simon Marchi <simon.marchi@ericsson.com>
697
698 * regcache.h (regcache_cooked_write_part): Remove, update
699 callers to use regcache::cooked_write_part.
700 * regcache.c (regcache_cooked_write_part): Remove.
701
73bb0000
SM
7022018-05-30 Simon Marchi <simon.marchi@ericsson.com>
703
704 * regcache.h (regcache_cooked_read_part): Remove, update callers
705 to use readable_regcache::cooked_read_part.
706 * regcache.c (regcache_cooked_read_part): Remove.
707
46a45e9d
SM
7082018-05-30 Simon Marchi <simon.marchi@ericsson.com>
709
710 * regcache.h (regcache_cooked_read_value): Remove, update
711 callers to use readable_regcache::cooked_read_value.
712 * regcache.c (regcache_cooked_read_value): Remove.
713
b66f5587
SM
7142018-05-30 Simon Marchi <simon.marchi@ericsson.com>
715
716 * regcache.h (regcache_cooked_write): Remove, update callers to
717 use regcache::cooked_write.
718 * regcache.c (regcache_cooked_write): Remove.
719
6aa7d724
SM
7202018-05-30 Simon Marchi <simon.marchi@ericsson.com>
721
722 * regcache.h (regcache_invalidate): Remove, update callers to
723 use detached_regcache::invalidate instead.
724 * regcache.c (regcache_invalidate): Remove.
725
4f0420fd
SM
7262018-05-30 Simon Marchi <simon.marchi@ericsson.com>
727
728 * regcache.h (regcache_raw_write_part): Remove, update callers
729 to use regcache::raw_write_part instead.
730 * regcache.c (regcache_raw_write_part): Remove.
731
502fe83e
SM
7322018-05-30 Simon Marchi <simon.marchi@ericsson.com>
733
734 * regcache.h (regcache_raw_read_part): Remove, update callers to
735 use readable_regcache::raw_read_part instead.
736 * regcache.c (regcache_raw_read_part): Remove.
737
dca08e1f
SM
7382018-05-30 Simon Marchi <simon.marchi@ericsson.com>
739
740 * regcache.h (regcache_cooked_read): Remove, update callers to
741 use readable_regcache::cooked_read instead.
742 * regcache.c (regcache_cooked_read): Remove.
743
10eaee5f
SM
7442018-05-30 Simon Marchi <simon.marchi@ericsson.com>
745
746 * regcache.h (regcache_raw_write): Remove, update callers to use
747 regcache::raw_write instead.
748 * regcache.c (regcache_raw_write): Remove.
749
0b883586
SM
7502018-05-30 Simon Marchi <simon.marchi@ericsson.com>
751
752 * regcache.h (regcache_raw_read): Remove, update callers to use
753 readable_regcache::raw_read instead.
754 * regcache.c (regcache_raw_read): Remove.
755
0b47d985
SM
7562018-05-30 Simon Marchi <simon.marchi@ericsson.com>
757
758 * regcache.h (regcache_raw_update): Remove, update callers to
759 use readable_regcache::raw_update instead.
760 * regcache.c (regcache_raw_update): Remove.
761
0ec9f114
SM
7622018-05-30 Simon Marchi <simon.marchi@ericsson.com>
763
764 * regcache.h (regcache_register_status): Remove, update callers
765 to use reg_buffer::get_register_status directly instead.
766 * regcache.c (regcache_register_status): Remove.
767
222312d3
SM
7682018-05-30 Simon Marchi <simon.marchi@ericsson.com>
769
770 * regcache.h (regcache_get_ptid): Remove, update all callers to
771 call regcache::ptid instead.
772 * regcache.c (regcache_get_ptid): Remove.
773
fdbe37e3
SM
7742018-05-30 Simon Marchi <simon.marchi@ericsson.com>
775
776 * Makefile.in (ALL_TARGET_OBS): Add or1k-tdep.o.
777
f7c6f423
PA
7782018-05-30 Pedro Alves <palves@redhat.com>
779
780 * common/common-exceptions.h (exception_rethrow): Use
781 ATTRIBUTE_NORETURN.
782
52941706
SM
7832018-05-29 Simon Marchi <simon.marchi@polymtl.ca>
784
785 * breakpoint.c (print_solib_event, check_status_catch_solib):
786 Remove struct keyword in range-based for loops.
787 * dbxread.c (find_corresponding_bincl_psymtab): Likewise.
788 * dwarf2read.c (compute_delayed_physnames, rust_union_quirks);
789 Likewise.
790 * linespec.c (find_superclass_methods, search_minsyms_for_name):
791 Likewise.
792 * symfile.c (addr_info_make_relative): Likewise.
793 * thread.c (value_in_thread_stack_temporaries): Likewise.
794
64cc34d8
WP
7952018-05-29 Weimin Pan <weimin.pan@oracle.com>
796
797 * minsyms.h (lookup_minimal_symbol_and_objfile): Remove declaration.
798 * minsyms.c (lookup_minimal_symbol_and_objfile): Remove definition.
799 * coff-pe-read.c (add_pe_forwarded_sym): Replace
800 lookup_minimal_symbol_and_objfile with lookup_bound_minimal_symbol.
801 * glibc-tdep.c (glibc_skip_solib_resolver): Likewise.
802 * jit.c (jit_breakpoint_re_set_internal): Likewise.
803 * printcmd.c (info_address_command): Likewise.
804
e7ec8713
TT
8052018-05-29 Tom Tromey <tom@tromey.com>
806
807 * windows-nat.c (handle_exception): Update fall-through comment.
808
bcb430e4
TT
8092018-05-29 Tom Tromey <tom@tromey.com>
810
811 * progspace.h (so_list_ptr): Remove typedef. Don't declare VEC.
812 (struct program_space) <added_solibs>: Now a std::vector.
813 * breakpoint.c (print_solib_event): Update.
814 (check_status_catch_solib): Update.
815 * progspace.c (clear_program_space_solib_cache): Update.
816 * solib.c (update_solib_list): Update.
817
894882e3
TT
8182018-05-29 Tom Tromey <tom@tromey.com>
819
820 * python/py-type.c (typy_richcompare): Update.
821 * guile/scm-type.c (tyscm_equal_p_type_smob): Update.
822 * gdbtypes.h (types_deeply_equal): Return bool.
823 (types_equal): Likewise.
824 * gdbtypes.c (type_equality_entry_d): Remove typedef. Don't
825 declare VEC.
826 (check_types_equal): Change worklist to std::vector. Return
827 bool.
828 (struct type_equality_entry): Add constructor.
829 (compare_maybe_null_strings): Return bool.
830 (check_types_worklist): Return bool. Change worklist to
831 std::vector.
832 (types_deeply_equal): Use std::vector.
833 (types_equal): Return bool.
834 (compare_maybe_null_strings): Simplify.
835
10b2ded4
TT
8362018-05-29 Tom Tromey <tom@tromey.com>
837
838 * record-btrace.c (tp_t): Remove typedef. Don't declare VEC.
839
4f7deebe
TT
8402018-05-29 Tom Tromey <tom@tromey.com>
841
842 * objc-lang.h: Don't include cp-support.h.
843 * common/gdb_vecs.h (const_char_ptr): Remove typedef. Don't
844 declare VEC.
845
b8283aea
TT
8462018-05-27 Tom Tromey <tom@tromey.com>
847
848 * Makefile.in (DEPFILES): Don't reference REMOTE_OBS.
849
41a883c8
TT
8502018-05-25 Tom Tromey <tom@tromey.com>
851
852 * value.c (value::location): Initialize.
853
bf259e25
TT
8542018-05-25 Tom Tromey <tom@tromey.com>
855
856 * dbxread.c (init_bincl_list): Remove.
857 (bincl_list): Now a std::vector.
858 (bincls_allocated, next_bincl): Remove.
859 (free_bincl_list, do_free_bincl_list_cleanup)
860 (make_cleanup_free_bincl_list): Remove.
861 (dbx_read_symtab, elfstab_build_psymtabs): Use scoped_restore,
862 unique_xmalloc_ptr.
863 (find_corresponding_bincl_psymtab, read_dbx_symtab): Update.
864 (struct header_file_location): Add constructor.
865 (add_bincl_to_list): Remove.
866
d525a99b
TT
8672018-05-25 Tom Tromey <tom@tromey.com>
868
869 * tui/tui.c (tui_enable): Update.
870 * mi/mi-interp.c (mi_interp::init): Update.
871 * interps.h (class interp) <name>: New method.
872 <m_name>: Rename from name.
873 (~scoped_restore_interp): Update.
874 * interps.c (interp::interp): Update.
875 (interp_add, interp_set, interp_lookup_existing)
876 (current_interp_named_p): Update.
877
da505cff
TT
8782018-05-25 Tom Tromey <tom@tromey.com>
879
880 * interps.c (interp_name): Remove.
881 * mi/mi-interp.c (mi_interp::init): Update.
882 * interps.h (interp_name): Remove.
883 (~scoped_restore_interp): Update.
884 * tui/tui.c (tui_enable): Update.
885
29f94340
TT
8862018-05-25 Tom Tromey <tom@tromey.com>
887
888 * utils.c (fputs_maybe_filtered): Update.
889 * linespec.c (decode_line_full): Update.
890 * mi/mi-interp.c (mi_on_normal_stop_1, mi_tsv_modified)
891 (mi_print_breakpoint_for_event, mi_solib_loaded)
892 (mi_solib_unloaded, mi_command_param_changed, mi_memory_changed)
893 (mi_user_selected_context_changed): Update.
894 * mi/mi-main.c (mi_execute_command): Update.
895 * cli/cli-script.c (execute_control_command): Update.
896 * python/python.c (execute_gdb_command): Update.
897 * solib.c (info_sharedlibrary_command): Update.
898 * interps.c (interp_ui_out): Remove.
899 * interps.h (interp_ui_out): Remove.
900
716b8bc5
TT
9012018-05-25 Tom Tromey <tom@tromey.com>
902
903 * tui/tui-interp.c (as_tui_interp): Use dynamic_cast.
904 * mi/mi-interp.c (as_mi_interp): Use dynamic_cast.
905 * cli/cli-interp.c (as_cli_interp): Use dynamic_cast.
906
753ff9bd
TT
9072018-05-25 Tom Tromey <tom@tromey.com>
908
909 * cli/cli-interp.c (safe_execute_command): Use scoped_restore.
910 * interps.c (interp_exec): Use scoped_restore.
911
5ca3b260
TT
9122018-05-25 Tom Tromey <tom@tromey.com>
913
914 * remote.c (remote_target::remote_file_get): Use
915 gdb::byte_vector.
916 (remote_target::remote_file_put): Likewise.
917
3173aa2f
TT
9182018-05-25 Tom Tromey <tom@tromey.com>
919
920 * coff-pe-read.c (struct read_pe_section_data) <section_name>: Now
921 a std::string.
922 (get_pe_section_index, add_pe_exported_sym): Update.
923 (read_pe_exported_syms): Use gdb::def_vector.
924
09a5e1b5
TT
9252018-05-25 Tom Tromey <tom@tromey.com>
926
927 * frame.c (remove_prev_frame): Remove.
928 (get_prev_frame_if_no_cycle): Use TRY/CATCH.
929
d8dab6c3
MR
9302018-05-25 Maciej W. Rozycki <macro@mips.com>
931
932 * mips-linux-tdep.h (mips_supply_fpregset, mips_fill_fpregset):
933 Remove prototypes.
934 * mips-linux-nat.c (supply_fpregset): Always call
935 `mips64_supply_fpregset' rather than `mips_supply_fpregset'.
936 (fill_fpregset): Always call `mips64_fill_fpregset' rather than
937 `mips_fill_fpregset'.
938 * mips-linux-tdep.c (mips_supply_fpregset)
939 (mips_supply_fpregset_wrapper, mips_fill_fpregset)
940 (mips_fill_fpregset_wrapper): Remove functions.
941 (mips64_supply_fpregset, mips64_fill_fpregset): Update comments.
942 (mips_linux_fpregset): Remove variable.
943 (mips_linux_iterate_over_regset_sections): Use
944 `mips64_linux_fpregset' in place of `mips_linux_fpregset'.
945 (mips_linux_o32_sigframe_init): Remove comment.
946
3c69da40
PA
9472018-05-25 Pedro Alves <palves@redhat.com>
948
949 * remote.c (struct vCont_action_support, MAXTHREADLISTRESULTS)
950 (struct readahead_cache, struct packet_reg, struct
951 remote_arch_state, class remote_state): Move higher up in the
952 file.
953 (remote_target::m_remote_state): Now an object instead of a pointer.
954 (remote_target::get_remote_state): Adjust.
955
39f0c204
AB
9562018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
957
958 * stack.c (select_and_print_frame): Delete.
959 (struct function_bounds): Move struct within function.
960 (func_command): Most content moved into new function
961 find_frame_for_function, use new function, print result, add
962 function comment.
963 (find_frame_for_function): New function, now returns a result.
964
d392224a
PW
9652018-05-24 Philippe Waroquiers <philippe.waroquiers@skynet.be>
966
967 * stack.c (iterate_over_block_arg_vars): Fix comment.
968 (print_frame_arg_vars): Pass stream in cb_data, not gdb_stdout.
969
45f25d6c
AB
9702018-05-24 Andrew Burgess <andrew.burgess@embecosm.com>
971
972 PR gdb/23203
973 * frame.c
974 (scoped_restore_selected_frame::scoped_restore_selected_frame):
975 Define.
976 (scoped_restore_selected_frame::~scoped_restore_selected_frame):
977 Define.
978 * frame.h (class scoped_restore_selected_frame): New class.
979 * stack.c (print_frame_local_vars): Remove catching and rethrowing
980 of any exception, use scoped_restore_selected_frame to restore the
981 frame instead.
982
da05d921
PA
9832018-05-24 Pedro Alves <palves@redhat.com>
984
985 * darwin-nat.h (darwin_nat_target::create_inferior): Mark with
986 override.
987
a8be540e
TT
9882018-05-23 Tom Tromey <tom@tromey.com>
989
990 * complaints.c (struct complaints): Remove.
991 (symfile_complaint_book): Remove.
992 (series): New global.
993 (complaint_internal): Update.
994 (clear_complaints): Update.
995
ff1cf532
TT
9962018-05-23 Tom Tromey <tom@tromey.com>
997
998 * complaints.c (counters): New global.
999 (struct complain): Remove.
1000 (struct complaints) <root>: Remove.
1001 (complaint_sentinel): Remove.
1002 (symfile_complaint_book): Update.
1003 (find_complaint) Remove.
1004 (complaint_internal, clear_complaints): Update.
1005
7ff88174
TT
10062018-05-23 Tom Tromey <tom@tromey.com>
1007
1008 * complaints.c (struct complain) <file, line>: Remove.
1009 (find_complaint): Remove file, line parameters.
1010 (complaint_internal): Update.
1011
de54e1a5
TT
10122018-05-23 Tom Tromey <tom@tromey.com>
1013
1014 * complaints.c (vcomplaint): Remove.
1015 (complaint_internal) Merge in contents of vcomplaint.
1016
2ac237e5
TT
10172018-05-23 Tom Tromey <tom@tromey.com>
1018
1019 * complaints.c (struct complaints) <explanation>: Remove.
1020 (symfile_explanations): Remove.
1021 (symfile_complaint_book): Update.
1022 (vcomplaint): Update.
1023 (struct explanation): Remove.
1024
b98664d3
TT
10252018-05-23 Tom Tromey <tom@tromey.com>
1026
1027 * complaints.c (symfile_complaints): Remove.
1028 (complaint_internal): Remove "complaints" parameter.
1029 (clear_complaints, vcomplaint): Remove "c" parameter.
1030 (get_complaints): Remove.
1031 * dwarf2read.c (dwarf2_statement_list_fits_in_line_number_section_complaint)
1032 (dwarf2_debug_line_missing_file_complaint)
1033 (dwarf2_debug_line_missing_end_sequence_complaint)
1034 (dwarf2_complex_location_expr_complaint)
1035 (dwarf2_const_value_length_mismatch_complaint)
1036 (dwarf2_section_buffer_overflow_complaint)
1037 (dwarf2_macro_malformed_definition_complaint)
1038 (dwarf2_invalid_attrib_class_complaint)
1039 (create_addrmap_from_index, dw2_symtab_iter_next)
1040 (dw2_expand_marked_cus)
1041 (dw2_debug_names_iterator::find_vec_in_debug_names)
1042 (dw2_debug_names_iterator::next, dw2_debug_names_iterator::next)
1043 (create_debug_type_hash_table, init_cutu_and_read_dies)
1044 (partial_die_parent_scope, add_partial_enumeration)
1045 (skip_one_die, fixup_go_packaging, quirk_rust_enum, process_die)
1046 (dwarf2_compute_name, dwarf2_physname, read_namespace_alias)
1047 (read_import_statement, read_file_scope, create_dwo_cu_reader)
1048 (create_cus_hash_table, create_dwp_hash_table)
1049 (inherit_abstract_dies, read_func_scope, read_call_site_scope)
1050 (dwarf2_rnglists_process, dwarf2_ranges_process)
1051 (dwarf2_add_type_defn, dwarf2_attach_fields_to_type)
1052 (dwarf2_add_member_fn, get_alignment, maybe_set_alignment)
1053 (handle_struct_member_die, process_structure_scope)
1054 (read_array_type, read_common_block, read_module_type)
1055 (read_tag_pointer_type, read_typedef, read_base_type)
1056 (read_subrange_type, load_partial_dies, partial_die_info::read)
1057 (partial_die_info::read, partial_die_info::read)
1058 (partial_die_info::read, read_checked_initial_length_and_offset)
1059 (dwarf2_string_attr, read_formatted_entries)
1060 (dwarf_decode_line_header)
1061 (lnp_state_machine::check_line_address, dwarf_decode_lines_1)
1062 (new_symbol, dwarf2_const_value_attr, lookup_die_type)
1063 (read_type_die_1, determine_prefix, dwarf2_get_ref_die_offset)
1064 (dwarf2_get_attr_constant_value, dwarf2_fetch_constant_bytes)
1065 (get_signatured_type, get_DW_AT_signature_type)
1066 (decode_locdesc, file_file_name, consume_improper_spaces)
1067 (skip_form_bytes, skip_unknown_opcode, dwarf_parse_macro_header)
1068 (dwarf_decode_macro_bytes, dwarf_decode_macros)
1069 (dwarf2_symbol_mark_computed, set_die_type)
1070 (read_attribute_value): Update.
1071 * stap-probe.c (handle_stap_probe, get_stap_base_address):
1072 Update.
1073 * dbxread.c (unknown_symtype_complaint)
1074 (lbrac_mismatch_complaint, repeated_header_complaint)
1075 (set_namestring, function_outside_compilation_unit_complaint)
1076 (read_dbx_symtab, process_one_symbol): Update.
1077 * gdbtypes.c (stub_noname_complaint): Update.
1078 * windows-nat.c (handle_unload_dll): Update.
1079 * coffread.c (coff_symtab_read, enter_linenos, decode_type)
1080 (decode_base_type): Update.
1081 * xcoffread.c (bf_notfound_complaint, ef_complaint)
1082 (eb_complaint, record_include_begin, record_include_end)
1083 (enter_line_range, xcoff_next_symbol_text, read_xcoff_symtab)
1084 (process_xcoff_symbol, read_symbol)
1085 (function_outside_compilation_unit_complaint)
1086 (scan_xcoff_symtab): Update.
1087 * machoread.c (macho_symtab_read, macho_add_oso_symfile): Update.
1088 * buildsym.c (finish_block_internal, make_blockvector)
1089 (end_symtab_get_static_block, augment_type_symtab): Update.
1090 * dtrace-probe.c (dtrace_process_dof)
1091 (dtrace_static_probe_ops::get_probes): Update.
1092 * complaints.h (struct complaint): Don't declare.
1093 (symfile_complaints): Remove.
1094 (complaint_internal): Remove "complaints" parameter.
1095 (complaint): Likewise.
1096 (clear_complaints): Likewise.
1097 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1098 (reread_symbols): Update.
1099 * dwarf2-frame.c (dwarf2_restore_rule, execute_cfa_program)
1100 (dwarf2_frame_cache, decode_frame_entry): Update.
1101 * dwarf2loc.c (dwarf_reg_to_regnum): Update.
1102 * objc-lang.c (lookup_objc_class, lookup_child_selector)
1103 (info_selectors_command): Update.
1104 * macrotab.c (macro_include, check_for_redefinition)
1105 (macro_undef): Update.
1106 * objfiles.c (filter_overlapping_sections): Update.
1107 * stabsread.c (invalid_cpp_abbrev_complaint)
1108 (reg_value_complaint, stabs_general_complaint, dbx_lookup_type)
1109 (define_symbol, error_type, read_type, rs6000_builtin_type)
1110 (stabs_method_name_from_physname, read_member_functions)
1111 (read_cpp_abbrev, read_baseclasses, read_tilde_fields)
1112 (attach_fields_to_type, complain_about_struct_wipeout)
1113 (read_range_type, read_args, common_block_start)
1114 (common_block_end, cleanup_undefined_types_1, scan_file_globals):
1115 Update.
1116 * mdebugread.c (index_complaint, unknown_ext_complaint)
1117 (basic_type_complaint, bad_tag_guess_complaint)
1118 (bad_rfd_entry_complaint, unexpected_type_code_complaint)
1119 (reg_value_complaint, parse_symbol, parse_type, upgrade_type)
1120 (parse_procedure, parse_lines)
1121 (function_outside_compilation_unit_complaint)
1122 (parse_partial_symbols, psymtab_to_symtab_1, cross_ref)
1123 (bad_tag_guess_complaint, reg_value_complaint): Update.
1124 * cp-support.c (demangled_name_complaint): Update.
1125 * macroscope.c (sal_macro_scope): Update.
1126 * dwarf-index-write.c (class debug_names): Update.
1127
4e9668d0
TT
11282018-05-23 Tom Tromey <tom@tromey.com>
1129
1130 * complaints.c (clear_complaints): Remove "noisy" parameter.
1131 * complaints.h (clear_complaints): Update.
1132 * symfile.c (syms_from_objfile_1, finish_new_objfile)
1133 (reread_symbols): Update.
1134
43ba33c7
TT
11352018-05-23 Tom Tromey <tom@tromey.com>
1136
1137 * complaints.c (enum complaint_series): Remove FIRST_MESSAGE,
1138 SUBSEQUENT_MESSAGE.
1139 (vcomplaint, clear_complaints): Update.
1140 (symfile_explanations): Remove some messages.
1141
2b9496b2
TT
11422018-05-23 Tom Tromey <tom@tromey.com>
1143
1144 * complaints.c (internal_complaint): Remove.
1145 * complaints.h (internal_complaint): Remove.
1146
35f1fea3
MR
11472018-05-22 Maciej W. Rozycki <macro@mips.com>
1148
1149 * i387-tdep.c (i387_collect_xsave): Make `i' unsigned.
1150
6b8edb51
PA
11512018-05-22 Pedro Alves <palves@redhat.com>
1152
1153 * remote-fileio.c (remote_fileio_reply, remote_fileio_ioerror)
1154 (remote_fileio_badfd, remote_fileio_return_errno)
1155 (remote_fileio_return_success, remote_fileio_func_open)
1156 (remote_fileio_func_open, remote_fileio_func_close)
1157 (remote_fileio_func_read, remote_fileio_func_write)
1158 (remote_fileio_func_lseek, remote_fileio_func_rename)
1159 (remote_fileio_func_unlink, remote_fileio_func_stat)
1160 (remote_fileio_func_fstat, remote_fileio_func_gettimeofday)
1161 (remote_fileio_func_isatty, remote_fileio_func_system): Add
1162 remote_target parameter.
1163 (remote_fio_func_map) <func>: Add remote_target parameter.
1164 (do_remote_fileio_request, remote_fileio_request):
1165 * remote-fileio.h (remote_fileio_request):
1166 * remote-notif.c (remote_notif_ack, remote_notif_parse, ): Add
1167 remote_target parameter.
1168 (remote_notif_process, handle_notification): Adjust to pass down
1169 the remote.
1170 (remote_notif_state_allocate): Add remote_target parameter. Save
1171 it.
1172 * remote-notif.h (struct remote_target): Forward declare.
1173 (struct notif_client) <parse, ack, can_get_pending_events>: Add
1174 remote_target parameter.
1175 (struct remote_notif_state) <remote>: New field.
1176 (remote_notif_ack, remote_notif_parse): Add remote_target
1177 parameter.
1178 (remote_notif_state_allocate, remote_notif_state_allocate): Add
1179 remote_target parameter.
1180 * remote.c (OPAQUETHREADBYTES, threadref, gdb_ext_thread_info)
1181 (threads_listing_context, rmt_thread_action, protocol_feature)
1182 (packet_reg, stop_reply, stop_reply_p, enum packet_support)
1183 (packet_result, struct threads_listing_context, remote_state):
1184 Move definitions and declarations higher up.
1185 (remote_target) <~remote_target>: Declare.
1186 (remote_download_command_source, remote_file_put, remote_file_get)
1187 (remote_file_delete, remote_hostio_pread, remote_hostio_pwrite)
1188 (remote_hostio_pread_vFile, remote_hostio_send_command)
1189 (remote_hostio_set_filesystem, remote_hostio_open)
1190 (remote_hostio_close, remote_hostio_unlink, remote_state)
1191 (get_remote_state, get_remote_packet_size, get_memory_packet_size)
1192 (get_memory_write_packet_size, get_memory_read_packet_size)
1193 (append_pending_thread_resumptions, remote_detach_1)
1194 (append_resumption, remote_resume_with_vcont)
1195 (add_current_inferior_and_thread, wait_ns, wait_as)
1196 (process_stop_reply, remote_notice_new_inferior)
1197 (process_initial_stop_replies, remote_add_thread)
1198 (btrace_sync_conf, remote_btrace_maybe_reopen)
1199 (remove_new_fork_children, kill_new_fork_children)
1200 (discard_pending_stop_replies, stop_reply_queue_length)
1201 (check_pending_events_prevent_wildcard_vcont)
1202 (discard_pending_stop_replies_in_queue, stop_reply)
1203 (remote_notif_remove_queued_reply, stop_reply *queued_stop_reply)
1204 (peek_stop_reply, remote_parse_stop_reply, remote_stop_ns)
1205 (remote_interrupt_as, remote_interrupt_ns)
1206 (remote_get_noisy_reply, remote_query_attached)
1207 (remote_add_inferior, remote_current_thread, get_current_thread)
1208 (set_thread, set_general_thread, set_continue_thread)
1209 (set_general_process, write_ptid)
1210 (remote_unpack_thread_info_response, remote_get_threadinfo)
1211 (parse_threadlist_response, remote_get_threadlist)
1212 (remote_threadlist_iterator, remote_get_threads_with_ql)
1213 (remote_get_threads_with_qxfer)
1214 (remote_get_threads_with_qthreadinfo, extended_remote_restart)
1215 (get_offsets, remote_check_symbols, remote_supported_packet)
1216 (remote_query_supported, remote_packet_size)
1217 (remote_serial_quit_handler, remote_detach_pid)
1218 (remote_vcont_probe, remote_resume_with_hc)
1219 (send_interrupt_sequence, interrupt_query)
1220 (remote_notif_get_pending_events, fetch_register_using_p)
1221 (send_g_packet, process_g_packet, fetch_registers_using_g)
1222 (store_register_using_P, store_registers_using_G)
1223 (set_remote_traceframe, check_binary_download)
1224 (remote_write_bytes_aux, remote_write_bytes, remote_read_bytes_1)
1225 (remote_xfer_live_readonly_partial, remote_read_bytes)
1226 (remote_send_printf, remote_flash_write, readchar)
1227 (remote_serial_write, putpkt, putpkt_binary, skip_frame)
1228 (read_frame, getpkt, getpkt_or_notif_sane_1, getpkt_sane)
1229 (getpkt_or_notif_sane, remote_vkill, remote_kill_k)
1230 (extended_remote_disable_randomization, extended_remote_run)
1231 (send_environment_packet, extended_remote_environment_support)
1232 (extended_remote_set_inferior_cwd, remote_write_qxfer)
1233 (remote_read_qxfer, push_stop_reply, vcont_r_supported)
1234 (packet_command): Now methods of ...
1235 (remote_target): ... this class.
1236 (m_remote_state) <remote_target>: New field.
1237 (struct remote_state) <stop_reply_queue,
1238 remote_async_inferior_event_token, wait_forever_enabled_p>: New
1239 fields.
1240 (remote_state::remote_state): Allocate stop_reply_queue.
1241 (remote_state): Delete global.
1242 (get_remote_state_raw): Delete.
1243 (remote_target::get_remote_state): Allocate m_remote_state on
1244 demand.
1245 (get_current_remote_target): New.
1246 (remote_ops, extended_remote_ops): Delete.
1247 (wait_forever_enabled_p, remote_async_inferior_event_token):
1248 Delete, moved to struct remote_state.
1249 (remote_target::close): Delete self. Destruction bits split to
1250 ...
1251 (remote_target::~remote_target): ... this.
1252 (show_memory_packet_size): Adjust to use
1253 get_current_remote_target.
1254 (struct protocol_feature) <func>: Add remote_target parameter.
1255 All callers adjusted.
1256 (curr_quit_handler_target): New.
1257 (remote_serial_quit_handler): Reimplement.
1258 (remote_target::open_1): Adjust to use get_current_remote_target.
1259 Heap-allocate remote_target/extended_remote_target instances.
1260 (vcont_builder::vcont_builder): Add remote_target parameter, and
1261 save it in m_remote. All callers adjusted.
1262 (vcont_builder::m_remote): New field.
1263 (vcont_builder::restart, vcont_builder::flush)
1264 (vcont_builder::push_action): Use it.
1265 (remote_target::commit_resume): Use it.
1266 (struct queue_iter_param) <remote>: New field.
1267 (remote_target::remove_new_fork_children): Fill in 'remote' field.
1268 (check_pending_event_prevents_wildcard_vcont_callback_data): New.
1269 (check_pending_event_prevents_wildcard_vcont_callback)
1270 (remote_target::check_pending_events_prevent_wildcard_vcont)
1271 (remote_target::discard_pending_stop_replies)
1272 (remote_target::discard_pending_stop_replies_in_queue)
1273 (remote_target::remote_notif_remove_queued_reply): Fill in
1274 'remote' field.
1275 (remote_notif_get_pending_events): New.
1276 (remote_target::readchar, remote_target::remote_serial_write):
1277 Save/restore curr_quit_handler_target.
1278 (putpkt): New.
1279 (kill_new_fork_children): Fill in 'remote' field.
1280 (packet_command): Use get_current_remote_target, defer to
1281 remote_target method of same name.
1282 (scoped_remote_fd::scoped_remote_fd): Add 'remote_target'
1283 parameter, and save it in m_remote. All callers adjusted.
1284 (scoped_remote_fd::release): Use m_remote.
1285 (scoped_remote_fd::m_remote): New field.
1286 (remote_file_put, remote_file_get, remote_file_delete): Use
1287 get_current_remote_target, defer to remote_target method of same
1288 name.
1289 (remote_btrace_reset): Add remote_state paremeter. Update all
1290 callers.
1291 (remote_async_inferior_event_handler). Pass down 'data'.
1292 (remote_new_objfile): Use get_current_remote_target.
1293 (remote_target::vcont_r_supported): New.
1294 (set_range_stepping): Use get_current_remote_target and
1295 remote_target::vcont_r_supported.
1296 (_initialize_remote): Don't allocate 'remote_state' and
1297 'stop_reply_queue' globals.
1298 * remote.h (struct remote_target): Forward declare.
1299 (getpkt, putpkt, remote_notif_get_pending_events): Add
1300 'remote_target' parameter.
1301
f5db4863
PA
13022018-05-22 Pedro Alves <palves@redhat.com>
1303
1304 * remote.c (vcont_builder): Now a class. Make all data members
1305 private.
1306 (vcont_builder) <vcont_builder, restart, flush, push_action>:
1307 Declare methods.
1308 (vcont_builder_restart): Rename to ...
1309 (vcont_builder::restart): ... this.
1310 (vcont_builder_flush): Rename to ...
1311 (vcont_builder::flush): ... this.
1312 (vcont_builder_push_action): Rename to ...
1313 (vcont_builder::push_action): ... this.
1314 (remote_target::commit_resume): Adjust.
1315
cc0be08f
PA
13162018-05-22 Pedro Alves <palves@redhat.com>
1317
1318 * remote.c (DEFAULT_MAX_MEMORY_PACKET_SIZE): Rename to ...
1319 (DEFAULT_MAX_MEMORY_PACKET_SIZE_FIXED): ... this.
1320 (get_fixed_memory_packet_size): New.
1321 (get_memory_packet_size): Use it.
1322 (set_memory_packet_size): Don't override the config size with
1323 DEFAULT_MAX_MEMORY_PACKET_SIZE.
1324 (show_memory_packet_size): Use get_fixed_memory_packet_size.
1325 Don't refer to get_memory_packet_size if not connected to a remote
1326 target. Show "(default)" if configured size is 0.
1327
9607784a
PA
13282018-05-22 Pedro Alves <palves@redhat.com>
1329
1330 * remote.c (remote_target::mourn_inferior): Move
1331 discard_pending_stop_replies call here from ...
1332 (_initialize_remote): ... here.
1333
0e9a6b2f
PA
13342018-05-22 Pedro Alves <palves@redhat.com>
1335
1336 * remote.c (compare_section_command): Remove set_general_process
1337 call.
1338
43c3a0e4
PA
13392018-05-22 Pedro Alves <palves@redhat.com>
1340
1341 * remote.c (struct packet_reg, struct remote_arch_state):
1342 Move higher up in the file.
1343 (remote_state) <m_arch_states>: Store remote_arch_state values
1344 instead of remote_arch_state pointers.
1345 (remote_state::get_remote_arch_state): Adjust.
1346
9d6eea31
PA
13472018-05-22 Pedro Alves <palves@redhat.com>
1348
1349 * remote.c: Include <unordered_map>.
1350 (remote_state): Now a class.
1351 (remote_state) <get_remote_arch_state>: Declare method.
1352 <get_remote_arch_state>: New field.
1353 (remote_arch_state) <remote_arch_state>: Declare ctor.
1354 <regs>: Now a unique_ptr.
1355 (remote_gdbarch_data_handle): Delete.
1356 (get_remote_arch_state): Delete.
1357 (remote_state::get_remote_arch_state): New.
1358 (get_remote_state): Adjust to call remote_state's
1359 get_remote_arch_state method.
1360 (init_remote_state): Delete, bits factored out to ...
1361 (remote_arch_state::remote_arch_state): ... this new method.
1362 (get_remote_packet_size, get_memory_packet_size)
1363 (process_g_packet, remote_target::fetch_registers)
1364 (remote_target::prepare_to_store, store_registers_using_G)
1365 (remote_target::store_registers, remote_target::get_trace_status):
1366 Adjust to call remote_state's method.
1367 (_initialize_remote): Remove reference to
1368 remote_gdbarch_data_handle.
1369
dd194f6b
PA
13702018-05-22 Pedro Alves <palves@redhat.com>
1371
1372 * remote.c (struct readahead_cache) <invalidate, invalidate_fd,
1373 pread>: New method declarations.
1374 (remote_target::open_1): Adjust.
1375 (readahead_cache_invalidate): Rename to ...
1376 (readahead_cache::invalidate): ... this, and adjust to be a class
1377 method.
1378 (readahead_cache_invalidate_fd): Rename to ...
1379 (readahead_cache::invalidate_fd): ... this, and adjust to be a
1380 class method.
1381 (remote_hostio_pwrite): Adjust.
1382 (remote_hostio_pread_from_cache): Rename to ...
1383 (readahead_cache::pread): ... this, and adjust to be a class
1384 method.
1385 (remote_hostio_close): Adjust.
1386
440b7aec
PA
13872018-05-22 Pedro Alves <palves@redhat.com>
1388
1389 * remote.c (remote_hostio_close_cleanup): Delete.
1390 (class scoped_remote_fd): New.
1391 (remote_file_put, remote_file_get): Use it.
1392
de44f5a7
PA
13932018-05-22 Pedro Alves <palves@redhat.com>
1394
1395 (struct vCont_action_support): Use bool and initialize all fields.
1396 (struct readahead_cache): Initialize all fields.
1397 (remote_state): Use bool and initialize all fields.
1398 (remote_state::remote_state, remote_state::~remote_state): New.
1399 (new_remote_state): Delete.
1400 (_initialize_remote): Use new to allocate remote_state.
1401
b1b60145
PA
14022018-05-22 Pedro Alves <palves@redhat.com>
1403 張俊芝 <zjz@zjz.name>
1404
1405 PR gdb/22973
1406 * c-exp.y: Include "c-support.h".
1407 (parse_number, c_parse_escape, lex_one_token): Use TOLOWER instead
1408 of tolower. Use c_ident_is_alpha to scan names.
1409 * c-lang.c: Include "c-support.h".
1410 (convert_ucn, convert_octal, convert_hex, convert_escape): Use
1411 ISXDIGIT instead of isxdigit and ISDIGIT instead of isdigit.
1412 * c-support.h: New file, with bits factored out from ...
1413 * cp-name-parser.y: ... this file.
1414 Include "c-support.h".
1415 (cp_ident_is_alpha, cp_ident_is_alnum): Deleted, moved to
1416 c-support.h and renamed.
1417 (symbol_end, yylex): Adjust.
1418
0ec848ad
PFC
14192018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1420
1421 * arch/ppc-linux-common.c (ppc_linux_has_isa205): Change the
1422 parameter type to CORE_ADDR.
1423 * arch/ppc-linux-common.h (ppc_linux_has_isa205): Change the
1424 parameter type in declaration to CORE_ADDR.
1425 * ppc-linux-tdep.c (ppc_linux_core_read_description): Call
1426 target_auxv_search to get AT_HWCAP and use the result to get the
1427 target description.
1428 * ppc-linux-nat.c (ppc_linux_get_hwcap): Change the return type
1429 to CORE_ADDR. Remove the cast of the return value to unsigned
1430 long. Fix error predicate of target_auxv_search.
1431 (ppc_linux_nat_target::read_description): Change the type of the
1432 hwcap variable to CORE_ADDR.
1433
0fb2aaa1
PFC
14342018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1435
1436 * rs6000-tdep.c (rs6000_gdbarch_init): Assign 1 to have_dfp only
1437 if the size of fpscr is larger than 32 bits.
1438
2c3305f6
PFC
14392018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1440
1441 * ppc-linux-tdep.c (ppc_linux_vsxregset): New function.
1442 (ppc32_linux_vsxregmap): New global.
1443 (ppc32_linux_vsxregset): Initialize with ppc32_linux_vsxregmap,
1444 regcache_supply_regset, and regcache_collect_regset.
1445 * ppc-linux-tdep.h (ppc_linux_vsxregset): Declare.
1446 * ppc-linux-nat.c (supply_vsxregset, fill_vsxregset): Remove.
1447 (fetch_vsx_register, store_vsx_register): Remove.
1448 (fetch_vsx_registers): Add regno parameter. Get regset using
1449 ppc_linux_vsxregset. Use regset to supply registers.
1450 (store_vsx_registers): Add regno parameter. Get regset using
1451 ppc_linux_vsxregset. Use regset to collect registers.
1452 (fetch_register): Call fetch_vsx_registers instead of
1453 fetch_vsx_register.
1454 (store_register): Call store_vsx_registers instead of
1455 store_vsx_register.
1456 (fetch_ppc_registers): Call fetch_vsx_registers with -1 for the
1457 new regno parameter.
1458 (store_ppc_registers): Call store_vsx_registers with -1 for the
1459 new regno parameter.
1460 * rs6000-tdep.c (ppc_vsx_support_p, ppc_supply_vsxreget)
1461 (ppc_collect_vsxregset): Remove.
1462
1d75a658
PFC
14632018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1464
1465 * ppc-tdep.h (struct ppc_reg_offsets): Remove vector register
1466 offset fields.
1467 * ppc-fbsd-tdep.c (ppc32_fbsd_reg_offsets): Remove initializers
1468 for vector register offset fields.
1469 (ppc64_fbsd_reg_offsets): Likewise.
1470 * ppc-nbsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
1471 to vector register offset fields.
1472 * ppc-obsd-tdep.c (_initialize_ppcnbsd_tdep): Remove assignment
1473 to vector register offset fields.
1474 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Remove assignment to
1475 vector register offset fields.
1476 * rs6000-aix-tdep.c (rs6000_aix32_reg_offsets): Remove
1477 initializers for vector register offset fields.
1478 (rs6000_aix64_reg_offsets): Likewise.
1479 * rs6000-tdep.c (ppc_vrreg_offset): Remove.
1480 (ppc_supply_vrregset): Remove.
1481 (ppc_collect_vrregset): Remove.
1482 * ppc-linux-tdep.c (ppc_linux_collect_vrregset): New function.
1483 (ppc_linux_vrregset) : New function.
1484 (ppc32_le_linux_vrregmap, ppc32_be_linux_vrregmap)
1485 (ppc32_le_linux_vrregset, ppc32_be_linux_vrregset): New globals.
1486 (ppc32_linux_vrregset): Remove.
1487 (ppc_linux_iterate_over_regset_sections): Call ppc_linux_vrregset
1488 and use result instead of ppc32_linux_vrregset.
1489 (ppc32_linux_reg_offsets): Remove initializers for vector register
1490 offset fields.
1491 (ppc64_linux_reg_offsets): Likewise.
1492 * ppc-linux-tdep.h (ppc_linux_vrregset): New declaration.
1493 * ppc-linux-nat.c: Include regset.h.
1494 (gdb_vrregset_t): Adjust comment to account for little-endian
1495 mode.
1496 (supply_vrregset, fill_vrregset): Remove.
1497 (fetch_altivec_register, store_altivec_register): Remove.
1498 (fetch_altivec_registers): Add regno parameter. Get regset using
1499 ppc_linux_vrregset. Use regset to supply registers.
1500 (store_altivec_registers): Add regno parameter. Get regset using
1501 ppc_linux_vrregset. Use regset to collect registers.
1502 (fetch_register): Call fetch_altivec_registers instead of
1503 fetch_altivec_register.
1504 (store_register): Call store_altivec_registers instead of
1505 store_altivec_register.
1506 (fetch_ppc_registers): Call fetch_altivec_registers with -1 for
1507 the new regno parameter.
1508 (store_ppc_registers): Call store_altivec_registers with -1 for
1509 the new regno parameter.
1510
d078308a
PFC
15112018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1512
1513 * arch/ppc-linux-common.h (PPC_LINUX_SIZEOF_VRREGSET)
1514 (PPC_LINUX_SIZEOF_VSXREGSET): Define.
1515 * ppc-linux-nat.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1516 (gdb_vrregset_t): Change array type size to
1517 PPC_LINUX_SIZEOF_VRREGSET.
1518 (gdb_vsxregset_t): Change array type size to
1519 PPC_LINUX_SIZEOF_VSXREGSET.
1520 * ppc-linux-tdep.c (ppc_linux_iterate_over_regset_sections):
1521 Change integer literals to PPC_LINUX_SIZEOF_VRREGSET and
1522 PPC_LINUX_SIZEOF_VSXREGSET.
1523
2e077f5e
PFC
15242018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1525
1526 * configure.nat <linux powerpc>: Add ppc-linux.o to NATDEPFILES.
1527 * ppc-linux-nat.c (ppc_linux_target_wordsize): Move to
1528 nat/ppc-linux.c.
1529 (ppc_linux_nat_target::auxv_parse): Get thread id tid. Call
1530 ppc_linux_target_wordsize with tid.
1531 (ppc_linux_nat_target::read_description): Call ppc_linux_target
1532 wordsize with tid.
1533 * nat/ppc-linux.c: Include nat/gdb_ptrace.h.
1534 (ppc64_64bit_inferior_p): Add static and inline specifiers.
1535 (ppc_linux_target_wordsize): Move here from ppc-linux-nat.c. Add
1536 tid parameter. Remove static specifier.
1537 * nat/ppc-linux.h (ppc64_64bit_inferior_p): Remove declaration.
1538 (ppc_linux_target_wordsize): New declaration.
1539
bd64614e
PFC
15402018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1541
1542 * arch/ppc-linux-common.c: New file.
1543 * arch/ppc-linux-common.h: New file.
1544 * arch/ppc-linux-tdesc.h: New file.
1545 * configure.tgt (powerpc*-*-linux*): Add arch/ppc-linux-common.o.
1546 * Makefile.in (ALL_TARGET_OBS): Add arch/ppc-linux-common.o.
1547 (HFILES_NO_SRCDIR): Add arch/ppc-linux-common.h and
1548 arch/ppc-linux-tdesc.h.
1549 * ppc-linux-nat.c: Include arch/ppc-linux-common.h and
1550 arch/ppc-linux-tdesc.h.
1551 (ppc_linux_nat_target::read_description): Remove target
1552 description matching code. Fill a ppc_linux_features struct and
1553 call ppc_linux_match_description with it. Move comment about ISA
1554 2.05 to ppc-linux-common.c.
1555 * ppc-linux-tdep.c: Include arch/ppc-linux-common.h and
1556 arch/ppc-linux-tdesc.h.
1557 (ppc_linux_core_read_description): Remove target description
1558 matching code. Fill a ppc_linux_features struct and call
1559 ppc_linux_match_description with it.
1560 * ppc-linux-tdep.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1561 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1562 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1563 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1564 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1565 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1566 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1567 (tdesc_powerpc_e500l): Remove.
1568
241db429
JB
15692018-05-22 Joel Brobecker <brobecker@adacore.com>
1570
1571 * ada-lang.c (catch_assert_command): Pass empty string instead
1572 of NULL for excep_string argument.
1573
75d74cca
MR
15742018-05-22 Maciej W. Rozycki <macro@mips.com>
1575
1576 * mips-linux-nat.c (mips64_linux_register_addr): Return -1 if
1577 the width of the requested register exceeds the width of the
1578 `ptrace' data type.
1579
122b53ea
TT
15802018-05-21 Tom Tromey <tom@tromey.com>
1581
1582 * printcmd.c (output_command): Remove.
1583 (output_command_const): Rename to output_command.
1584 * valprint.h (output_command): Rename from output_command_const.
1585 * tracepoint.c (trace_dump_actions): Call output_command.
1586
bc18fbb5
TT
15872018-05-21 Tom Tromey <tom@tromey.com>
1588
1589 * mi/mi-cmd-catch.c (mi_cmd_catch_assert)
1590 (mi_cmd_catch_exception, mi_cmd_catch_handlers): Update.
1591 * ada-lang.h (create_ada_exception_catchpoint): Update.
1592 * ada-lang.c (struct ada_catchpoint) <excep_string>: Now a
1593 std::string.
1594 (create_excep_cond_exprs, ~ada_catchpoint)
1595 (should_stop_exception, print_one_exception)
1596 (print_mention_exception, print_recreate_exception): Update.
1597 (ada_get_next_arg): Remove.
1598 (catch_ada_exception_command_split): Use std::string. Change type
1599 of "excep_string", "cond_string".
1600 (catch_ada_exception_command): Update.
1601 (create_ada_exception_catchpoint): Change type of excep_string.
1602 (ada_exception_sal): Remove excep_string parameter.
1603 (~ada_catchpoint): Remove.
1604
790217f6
TT
16052018-05-21 Tom Tromey <tom@tromey.com>
1606
1607 * ada-lang.c (ada_collect_symbol_completion_matches): Remove
1608 cleanup.
1609
6f46ac85
TT
16102018-05-21 Tom Tromey <tom@tromey.com>
1611
1612 * ada-lang.c (ada_exception_message_1, ada_exception_message):
1613 Return unique_xmalloc_ptr.
1614 (print_it_exception): Update.
1615
15b6611c
TT
16162018-05-21 Tom Tromey <tom@tromey.com>
1617
1618 * tracepoint.c (trace_dump_actions): Use std::string.
1619
c0c9f665
TT
16202018-05-21 Tom Tromey <tom@tromey.com>
1621
1622 * symfile.c (reread_symbols): Use std::string for original_name.
1623
22ca247e
TT
16242018-05-21 Tom Tromey <tom@tromey.com>
1625
1626 * dwarf2read.c (dwarf2_read_debug_names): Use std::unique_ptr.
1627 (mapped_index_base): Use DISABLE_COPY_AND_ASSIGN. Default
1628 constructor.
1629
184cde75
SM
16302018-05-20 Simon Marchi <simon.marchi@polymtl.ca>
1631
1632 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Rename the wrong
1633 instance to...
1634 (HAVE_IS_TRIVIALLY_CONSTRUCTIBLE): ... this.
1635 * objfiles.c (get_objfile_bfd_data): Allocate
1636 objfile_per_bfd_storage with obstack_new when allocating on
1637 obstack.
1638
e39db4db
SM
16392018-05-20 Simon Marchi <simon.marchi@ericsson.com>
1640
1641 * ada-lang.c (cache_symbol): Use XOBNEW and/or XOBNEWVEC and/or
1642 OBSTACK_ZALLOC.
1643 * dwarf2-frame.c (dwarf2_build_frame_info): Likewise.
1644 * hppa-tdep.c (hppa_init_objfile_priv_data): Likewise.
1645 * mdebugread.c (mdebug_build_psymtabs): Likewise.
1646 (add_pending): Likewise.
1647 (parse_symbol): Likewise.
1648 (parse_partial_symbols): Likewise.
1649 (psymtab_to_symtab_1): Likewise.
1650 (new_psymtab): Likewise.
1651 (elfmdebug_build_psymtabs): Likewise.
1652 * minsyms.c (terminate_minimal_symbol_table): Likewise.
1653 * objfiles.c (get_objfile_bfd_data): Likewise.
1654 (objfile_register_static_link): Likewise.
1655 * psymtab.c (allocate_psymtab): Likewise.
1656 * stabsread.c (read_member_functions): Likewise.
1657 * xcoffread.c (xcoff_end_psymtab): Likewise.
1658
284a0e3c
SM
16592018-05-20 Simon Marchi <simon.marchi@ericsson.com>
1660
1661 * common/traits.h (HAVE_IS_TRIVIALLY_COPYABLE): Define if
1662 compiler supports std::is_trivially_constructible.
1663 * common/poison.h: Include obstack.h.
1664 (IsMallocable): Define to is_trivially_constructible if the
1665 compiler supports it, define to true_type otherwise.
1666 (xobnew): New.
1667 (XOBNEW): Redefine.
1668 (xobnewvec): New.
1669 (XOBNEWVEC): Redefine.
1670 * gdb_obstack.h (obstack_zalloc): New.
1671 (OBSTACK_ZALLOC): Redefine.
1672 (obstack_calloc): New.
1673 (OBSTACK_CALLOC): Redefine.
1674 (obstack_new): New.
1675 * gdbarch.sh: Include gdb_obstack in gdbarch.h.
1676 (gdbarch_obstack): New declaration in gdbarch.h, definition in
1677 gdbarch.c.
1678 (GDBARCH_OBSTACK_CALLOC, GDBARCH_OBSTACK_ZALLOC): Use
1679 obstack_calloc/obstack_zalloc.
1680 (gdbarch_obstack_zalloc): Remove.
1681 * target-descriptions.c (tdesc_data_init): Use obstack_new.
1682
59f66be3
PW
16832018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1684
1685 * stack.c (backtrace_command_1): Remove useless variable int i.
1686
50c65c2d
PW
16872018-05-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
1688
1689 * stack.c (print_frame_info): Fix comment.
1690
7ff8cb8c
TT
16912018-05-18 Tom Tromey <tom@tromey.com>
1692
1693 * dwarf2read.c (struct dwz_file): Add constructor, initializers.
1694 <dwz_bfd>: Now a gdb_bfd_ref_ptr.
1695 (~dwarf2_per_objfile): Update
1696 (dwarf2_get_dwz_file): Use new.
1697 * dwarf2read.h (struct dwarf2_per_objfile) <dwz_file>: Now a
1698 unique_ptr.
1699
400174b1
TT
17002018-05-18 Tom Tromey <tom@tromey.com>
1701
1702 * dwarf2read.h (struct dwarf2_per_objfile) <dwp_file>: Now a
1703 unique_ptr.
1704 * dwarf2read.c (struct dwp_file): Add constructor and
1705 initializers.
1706 (open_and_init_dwp_file): Return a unique_ptr.
1707 (dwarf2_per_objfile, create_dwp_hash_table)
1708 (create_dwo_unit_in_dwp_v1, create_dwo_unit_in_dwp_v2)
1709 (lookup_dwo_unit_in_dwp): Update.
1710 (open_and_init_dwp_file, get_dwp_file): Update.
1711
3063847f
TT
17122018-05-18 Tom Tromey <tom@tromey.com>
1713
1714 * dwarf2read.c (dwarf2_per_objfile): Update.
1715 (struct mapped_index): Add initializers.
1716 (dwarf2_read_index): Use new.
1717 (dw2_symtab_iter_init): Update.
1718 * dwarf2read.h (struct dwarf2_per_objfile) <index_table>: Now a
1719 unique_ptr.
1720
d3d02dee
SM
17212018-05-18 Simon Marchi <simon.marchi@ericsson.com>
1722
1723 * dwarf2read.c (mapped_index) <total_size>: Remove.
1724
1d143c36
SM
17252018-05-18 Simon Marchi <simon.marchi@ericsson.com>
1726
1727 * unittests/format_pieces-selftests.c (test_format_specifier):
1728 Add ARI comments.
1729
ce1e8424
TT
17302018-05-18 Tom Tromey <tom@tromey.com>
1731
1732 * c-typeprint.c (maybe_print_hole): New function.
1733 (c_print_type_struct_field_offset): Update.
1734 (c_type_print_base_struct_union): Call maybe_print_hole.
1735
ddfe970e
KS
17362018-05-17 Keith Seitz <keiths@redhat.com>
1737
1738 * breakpoint.c (build_bpstat_chain): New function, moved from
1739 bpstat_stop_status.
1740 (bpstat_stop_status): Add optional parameter, `stop_chain'.
1741 If no stop chain is passed, call build_bpstat_chain to build it.
1742 * breakpoint.h (build_bpstat_chain): Declare.
1743 (bpstat_stop_status): Move documentation here from breakpoint.c.
1744 * infrun.c (handle_signal_stop): Before eliding inlined frames,
1745 build the stop chain and pass it to skip_inline_frames.
1746 Pass this stop chain to bpstat_stop_status.
1747 * inline-frame.c: Include breakpoint.h.
1748 (stopped_by_user_bp_inline_frame): New function.
1749 (skip_inline_frames): Add parameter `stop_chain'.
1750 Move documention to inline-frame.h.
1751 If non-NULL, use stopped_by_user_bp_inline_frame to determine
1752 whether the frame should be elided.
1753 * inline-frame.h (skip_inline_frames): Add parameter `stop_chain'.
1754 Add moved documentation and update for new parameter.
1755
b17992c1
SM
17562018-05-17 Simon Marchi <simon.marchi@ericsson.com>
1757
1758 PR cli/14975
1759 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
1760 unittests/format_pieces-selftests.c.
1761 * common/format.h (format_piece) <operator==>: New.
1762 (format_pieces) <operator[]>: Remove.
1763 * common/format.c (format_pieces::format_pieces): Handle \e.
1764 * unittests/format_pieces-selftests.c: New.
1765
58f0c718
TT
17662018-05-17 Tom Tromey <tom@tromey.com>
1767
1768 PR symtab/23010:
1769 * dwarf2read.c (load_cu, dw2_do_instantiate_symtab)
1770 (dw2_instantiate_symtab): Add skip_partial parameter.
1771 (dw2_find_last_source_symtab, dw2_map_expand_apply)
1772 (dw2_lookup_symbol, dw2_expand_symtabs_for_function)
1773 (dw2_expand_all_symtabs, dw2_expand_symtabs_with_fullname)
1774 (dw2_expand_symtabs_matching_one)
1775 (dw2_find_pc_sect_compunit_symtab)
1776 (dw2_debug_names_lookup_symbol)
1777 (dw2_debug_names_expand_symtabs_for_function): Update.
1778 (init_cutu_and_read_dies): Add skip_partial parameter.
1779 (process_psymtab_comp_unit, build_type_psymtabs_1)
1780 (process_skeletonless_type_unit, load_partial_comp_unit)
1781 (psymtab_to_symtab_1): Update.
1782 (load_full_comp_unit): Add skip_partial parameter.
1783 (process_imported_unit_die, dwarf2_read_addr_index)
1784 (follow_die_offset, dwarf2_fetch_die_loc_sect_off)
1785 (dwarf2_fetch_constant_bytes, dwarf2_fetch_die_type_sect_off)
1786 (read_signatured_type): Update.
1787
3e618834
SM
17882018-05-17 Simon Marchi <simon.marchi@ericsson.com>
1789
1790 * value.c (release_value): Remove unused variable.
1791 (record_latest_value): Likewise.
1792 (access_value_history): Likewise.
1793 (preserve_values): Likewise.
1794
fe10fe31
TT
17952018-05-17 Tom Tromey <tom@tromey.com>
1796
1797 * extension.h (struct ext_lang_type_printers) <py_type_printers>:
1798 Initialize.
1799
1d761124
MR
18002018-05-16 Maciej W. Rozycki <macro@mips.com>
1801
1802 PR gdb/22286
1803 * linux-nat-trad.c (linux_nat_trad_target::fetch_register):
1804 Also handle registers whose width is not a multiple of
1805 PTRACE_TYPE_RET.
1806 (linux_nat_trad_target::store_register): Likewise.
1807
06333fea
TT
18082018-05-16 Tom Tromey <tom@tromey.com>
1809
1810 * gdbcore.h (core_bfd): Redefine.
1811 * corelow.c (core_target::close): Update.
1812 (core_target_open): Update.
1813 * progspace.h (struct program_space) <cbfd>: Now a
1814 gdb_bfd_ref_ptr.
1815
921222e2
TT
18162018-05-16 Tom Tromey <tom@tromey.com>
1817
1818 PR cli/19551:
1819 * symfile-add-flags.h (enum symfile_add_flags)
1820 <SYMFILE_NOT_FILENAME>: New constant.
1821 * symfile.c (read_symbols): Use SYMFILE_NOT_FILENAME. Get
1822 objfile name from BFD.
1823 (symbol_file_add_with_addrs): Check SYMFILE_NOT_FILENAME.
1824 * minidebug.c (find_separate_debug_file_in_section): Put
1825 ".gnu_debugdata" into BFD's file name.
1826
3acb7083
SM
18272018-05-16 Simon Marchi <simon.marchi@ericsson.com>
1828
1829 * regcache.c (regcache_read_ftype, regcache_write_ftype):
1830 Remove.
1831
561a72d4
TC
18322018-05-15 Tamar Christina <tamar.christina@arm.com>
1833
1834 PR binutils/21446
1835 * aarch64-tdep.c (aarch64_analyze_prologue,
1836 aarch64_software_single_step, aarch64_displaced_step_copy_insn):
1837 Indicate not interested in errors.
1838
4e6ff0e1
MR
18392018-05-15 Maciej W. Rozycki <macro@mips.com>
1840
1841 * mips-linux-nat.c (mips_linux_nat_target::fetch_registers):
1842 Supply the MIPS_ZERO_REGNUM register.
1843
ea33cd92
MR
18442018-05-15 Maciej W. Rozycki <macro@mips.com>
1845
1846 * mips-tdep.c (mask_address_var): Make variable static.
1847
2d79090e
TT
18482018-05-14 Tom Tromey <tom@tromey.com>
1849
1850 * dwarf2read.c (rust_union_quirks): Clear rust_unions.
1851
cf4912ae
AB
18522018-05-11 Andrew Burgess <andrew.burgess@embecosm.com>
1853
1854 * i387-tdep.c (i387_collect_xsave): Use FXSAVE_MXCSR_ADDR not
1855 FXSAVE_ADDR for the mxcsr register.
1856
67e6f569
MF
18572018-05-11 Max Filippov <jcmvbkbc@gmail.com>
1858
1859 * configure.tgt (xtensa*-*-linux*): Drop gdb_target definition.
1860
15244507
PA
18612018-05-11 Pedro Alves <palves@redhat.com>
1862
1863 * corelow.c (core_target) <core_target>: No longer inline.
1864 Initialize m_core_gdbarch, m_core_vec and build the section table
1865 here.
1866 <~core_target>: New.
1867 <core_gdbarch, get_core_register_section>: New methods.
1868 <m_core_section_table, m_core_vec, m_core_gdbarch>: New fields,
1869 factored out from ...
1870 <core_data, core_vec, core_gdbarch>: ... these deleted globals.
1871 (core_ops): Delete.
1872 (sniff_core_bfd): Add gdbarch parameter.
1873 (core_close): Delete, merged into ...
1874 (core_target::close): ... here. Delete self.
1875 (core_close_cleanup): Delete.
1876 (core_target_open): Allocate a core_target on the heap. Use a
1877 unique_ptr instead of a cleanup. Bits moved into the core_target
1878 ctor. Adjust to use core_target methods instead of globals.
1879 (get_core_register_section): Rename to ...
1880 (core_target::get_core_register_section): ... this and adjust.
1881 (struct get_core_registers_cb_data): New.
1882 (get_core_registers_cb): Use it. Use bool.
1883 (core_target::fetch_registers, core_target::files_info)
1884 (core_target::xfer_partial, core_target::read_description)
1885 (core_target::pid_to, core_target::thread_name): Adjust to
1886 reference class fields instead of globals.
1887 * target.h (struct target_ops_deleter, target_ops_up): New.
1888
451953fa
PA
18892018-05-11 Pedro Alves <palves@redhat.com>
1890
1891 * corefile.c (core_file_command): Move to corelow.c.
1892 * corelow.c (the_core_target): Delete.
1893 (core_file_command): Moved from corefile.c. Check exec_bfd
1894 instead of the_core_target. Use target_detach instead of calling
1895 into the_core_target directly.
1896 (maybe_say_no_core_file_now): New.
1897 (core_target::detach): Use it.
1898 (_initialize_corelow): Remove references to the_core_target.
1899 * gdbcore.h (the_core_target): Delete.
1900
e540a5a2 19012018-05-11 Tom Tromey <tromey@redhat.com>
3afc23a6 1902 Pedro Alves <palves@redhat.com>
e540a5a2
TT
1903
1904 * corefile.c (core_bfd): Remove.
1905 * gdbcore.h (core_bfd): Now a macro.
1906 * progspace.h (struct program_space) <cbfd>: New field.
1907
633cf254
TT
19082018-05-11 Tom Tromey <tom@tromey.com>
1909
1910 * mdebugread.c (parse_partial_symbols, psymtab_to_symtab_1): Use
1911 gdb::def_vector.
1912
1a34f210
TT
19132018-05-10 Tom Tromey <tom@tromey.com>
1914
1915 * configure: Rebuild.
1916 * warning.m4 (AM_GDB_WARNINGS): Use -Wimplicit-fallthrough=3.
1917
190852c8
JB
19182018-05-10 Joel Brobecker <brobecker@adacore.com>
1919
1920 PR server/23158:
1921 * regformats/regdat.sh: Adjust script, following the addition
1922 of the new expedite_regs parameter to init_target_desc.
1923
8727de56
OJ
19242018-05-10 Omair Javaid <omair.javaid@linaro.org>
1925
1926 PR gdb/23127
1927 * aarch64-linux-tdep.c (aarch64_linux_init_abi): Add call to
1928 set_gdbarch_significant_addr_bit.
1929 * aarch64-tdep.c (aarch64_gdbarch_init): Remove call to
1930 set_gdbarch_significant_addr_bit.
1931 * utils.c (address_significant): Update to sign extend addr.
1932
37d9e062
MF
19332018-05-09 Max Filippov <jcmvbkbc@gmail.com>
1934
1935 * xtensa-linux-tdep.c (xtensa-tdep.h): New include.
1936 (xtensa_linux_init_abi): Limit tdep->num_regs by
1937 tdep->num_nopriv_regs.
1938 * xtensa-tdep.c (xtensa_derive_tdep): Calculate
1939 tdep->num_nopriv_regs and only copy it to tdep->num_regs if it's
1940 not initialized.
1941
7402fbca
SM
19422018-05-08 Simon Marchi <simon.marchi@ericsson.com>
1943
1944 * unittests/string_view-selftests.c: Define GNULIB_NAMESPACE.
1945
8ee22052
AB
19462018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1947
1948 * common/x86-xstate.h (I387_FCTRL_INIT_VAL): New constant.
1949 (I387_MXCSR_INIT_VAL): New constant.
1950 * amd64-tdep.c (amd64_supply_xsave): Only read state from xsave
1951 buffer if it was supplied by the inferior.
1952 * i387-tdep.c (i387_supply_fsave): Use I387_MXCSR_INIT_VAL.
1953 (i387_xsave_get_clear_bv): New function.
1954 (i387_supply_xsave): Only read x87 control registers from the
1955 xsave buffer if the feature is enabled, and the state will have
1956 been written, otherwise, provide a suitable default.
1957 (i387_collect_xsave): Pre-clear all registers in xsave buffer,
1958 including x87 control registers. Update control registers if they
1959 have changed from the default value, and mark features as enabled
1960 as required.
1961 * i387-tdep.h (i387_xsave_get_clear_bv): Declare.
1962
968ae51b
UW
19632018-05-08 Ulrich Weigand <uweigand@de.ibm.com>
1964
1965 * spu-tdep.c (info_spu_event_command): Fix output formatting.
1966
aff689d3
TT
19672018-05-07 Tom Tromey <tom@tromey.com>
1968
1969 * configure: Rebuild.
1970 * warning.m4 (AM_GDB_WARNINGS): Add -Wduplicated-cond.
1971
ce887586
TT
19722018-05-07 Tom Tromey <tom@tromey.com>
1973
1974 PR tdep/20362:
1975 * arm-tdep.c (arm_record_vfp_data_proc_insn): Properly mask off D
1976 bit. Use correct value for VDIV.
1977
85e26832
TT
19782018-05-04 Tom Tromey <tom@tromey.com>
1979
1980 * configure: Rebuild.
1981 * warning.m4 (AM_GDB_WARNINGS): Add -Wimplicit-fallthrough.
1982
449b1ac7
TT
19832018-05-04 Tom Tromey <tom@tromey.com>
1984
1985 * linux-record.c (record_linux_system_call) <case
1986 RECORD_SYS_RECVFROM>: Add "break".
1987
15c9ffd6
TT
19882018-05-04 Tom Tromey <tom@tromey.com>
1989
1990 * mi/mi-main.c (mi_cmd_trace_frame_collected) <REGISTERS_FORMAT>:
1991 Add missing "break".
1992 * mi/mi-cmd-stack.c (mi_cmd_stack_list_locals) <NO_FRAME_FILTERS>:
1993 Add missing "break".
1994
e3829d13
TT
19952018-05-04 Tom Tromey <tom@tromey.com>
1996
1997 * rs6000-tdep.c (ppc_process_record_op4)
1998 (ppc_process_record_op63): Add fall-through comment.
1999
da0e1563
TT
20002018-05-04 Tom Tromey <tom@tromey.com>
2001
2002 * i386-tdep.c (i386_process_record): Add fall-through comment.
2003
0019cd49
TT
20042018-05-04 Tom Tromey <tom@tromey.com>
2005
2006 * stabsread.c (define_symbol) <case 'p'>: Add fall-through
2007 comment.
2008
565e0eda
TT
20092018-05-04 Tom Tromey <tom@tromey.com>
2010
2011 * riscv-tdep.c (riscv_isa_xlen): Add fall-through comment.
2012 * utils.c (can_dump_core) <LIMIT_CUR>: Add fall-through comment.
2013 * eval.c (fetch_subexp_value) <MEMORY_ERROR>: Add fall-through
2014 comment.
2015 * d-valprint.c (d_val_print) <TYPE_CODE_STRUCT>: Add fall-through
2016 comment.
2017 * coffread.c (coff_symtab_read) <C_LABEL>: Add fall-through
2018 comment.
2019
621846f4
TT
20202018-05-04 Tom Tromey <tom@tromey.com>
2021
2022 * dwarf2loc.c (unimplemented): Add ATTRIBUTE_NORETURN.
2023
86a73007
TT
20242018-05-04 Tom Tromey <tom@tromey.com>
2025
2026 * s390-tdep.c (s390_process_record): Fix fall-through comments.
2027 * xcoffread.c (scan_xcoff_symtab): Move comment later.
2028 * symfile.c (section_is_mapped): Fix fall-through comment.
2029 * stabsread.c (define_symbol, read_member_functions): Fix
2030 fall-through comment.
2031 * s390-linux-tdep.c (s390_process_record): Fix fall-through
2032 comment.
2033 * remote.c (remote_wait_as): Fix fall-through comment.
2034 * p-exp.y (yylex): Fix fall-through comment.
2035 * nat/x86-dregs.c (x86_length_and_rw_bits): Fix fall-through
2036 comment.
2037 * msp430-tdep.c (msp430_gdbarch_init): Fix fall-through comment.
2038 * mdebugread.c (parse_partial_symbols): Fix fall-through comment.
2039 * jv-exp.y (yylex): Fix fall-through comment.
2040 * go-exp.y (lex_one_token): Fix fall-through comment.
2041 * gdbtypes.c (get_discrete_bounds, rank_one_type): Fix
2042 fall-through comment.
2043 * f-exp.y (yylex): Fix fall-through comment.
2044 * dwarf2read.c (process_die): Fix fall-through comments.
2045 * dbxread.c (process_one_symbol): Fix fall-through comment.
2046 * d-exp.y (lex_one_token): Fix fall-through comment.
2047 * cp-name-parser.y (yylex): Fix fall-through comment.
2048 * coffread.c (coff_symtab_read): Fix fall-through comment.
2049 * c-exp.y (lex_one_token): Fix fall-through comment.
2050 * arm-tdep.c (arm_decode_miscellaneous): Fix fall-through
2051 comment.
2052 * arch/arm.c (arm_instruction_changes_pc): Fix fall-through
2053 comment.
2054
56bcdbea
TT
20552018-05-04 Tom Tromey <tom@tromey.com>
2056
2057 PR python/22730:
2058 * NEWS: Mention gdb.execute change.
2059 * gdbcmd.h (execute_control_command): Don't declare.
2060 * python/python.c (execute_gdb_command): Use read_command_lines_1,
2061 execute_control_commands, execute_control_commands_to_string.
2062 * cli/cli-script.h (execute_control_commands)
2063 (execute_control_commands_to_string): Declare.
2064 (execute_control_command): Add from_tty parameter.
2065 * cli/cli-script.c (execute_control_commands)
2066 (execute_control_commands_to_string): New functions.
2067 (execute_user_command): Use execute_control_commands.
2068 (execute_control_command_1): Add "from_tty" parameter. Update.
2069 (execute_control_command): Likewise.
2070
a913fffb
TT
20712018-05-04 Tom Tromey <tom@tromey.com>
2072
2073 PR python/22731:
2074 * NEWS: Mention that breakpoint commands are writable.
2075 * python/py-breakpoint.c (bppy_set_commands): New function.
2076 (breakpoint_object_getset) <"commands">: Use it.
2077
60b3cef2
TT
20782018-05-04 Tom Tromey <tom@tromey.com>
2079
2080 * tracepoint.c (actions_command): Update.
2081 * mi/mi-cmd-break.c (mi_command_line_array)
2082 (mi_command_line_array_cnt, mi_command_line_array_ptr)
2083 (mi_read_next_line): Remove.
2084 (mi_cmd_break_commands): Update.
2085 * cli/cli-script.h (read_command_lines, read_command_lines_1): Use
2086 function_view.
2087 * cli/cli-script.c (get_command_line): Update.
2088 (process_next_line): Use function_view. Constify.
2089 (recurse_read_control_structure, read_command_lines)
2090 (read_command_lines_1): Change argument types to function_view.
2091 (do_define_command, document_command): Update.
2092 * breakpoint.h (check_tracepoint_command): Don't declare.
2093 * breakpoint.c (check_tracepoint_command): Remove.
2094 (commands_command_1, create_tracepoint_from_upload): Update.
2095
7a2c85f2
TT
20962018-05-04 Tom Tromey <tom@tromey.com>
2097
2098 PR gdb/11750:
2099 * cli/cli-script.h (enum command_control_type) <define_control>:
2100 New constant.
2101 * cli/cli-script.c (multi_line_command_p): Handle define_control.
2102 (build_command_line, execute_control_command_1)
2103 (process_next_line): Likewise.
2104 (do_define_command): New function, extracted from define_command.
2105 (define_command): Use it.
2106
295dc222
TT
21072018-05-04 Tom Tromey <tom@tromey.com>
2108
2109 * tracepoint.c (actions_command): Update.
2110 * cli/cli-script.h (read_command_lines): Update.
2111 * cli/cli-script.c (read_command_lines): Constify prompt_arg.
2112 (MAX_TMPBUF): Remove define.
2113 (define_command): Use string_printf.
2114 (document_command): Likewise.
2115 * breakpoint.c (commands_command_1): Update.
2116
1263a9d5
TT
21172018-05-04 Tom Tromey <tom@tromey.com>
2118
2119 * top.c (execute_command): Update.
2120 * cli/cli-script.h (print_command_lines): Now varargs.
2121 * cli/cli-script.c (print_command_lines): Now varargs.
2122 (execute_control_command_1) <case while_control, case if_control>:
2123 Update.
2124
12973681
TT
21252018-05-04 Tom Tromey <tom@tromey.com>
2126
2127 * tracepoint.c (all_tracepoint_actions): Rename from
2128 all_tracepoint_actions_and_cleanup. Change return type.
2129 (actions_command, encode_actions_1, encode_actions)
2130 (trace_dump_actions, tdump_command): Update.
2131 * remote.c (remote_download_command_source): Update.
2132 * python/python.c (gdbpy_eval_from_control_command)
2133 (python_command, python_interactive_command): Update.
2134 * mi/mi-cmd-break.c (mi_cmd_break_commands): Update.
2135 * guile/guile.c (guile_command)
2136 (gdbscm_eval_from_control_command, guile_command): Update.
2137 * compile/compile.c (compile_code_command)
2138 (compile_print_command, compile_to_object): Update.
2139 * cli/cli-script.h (struct command_lines_deleter): New.
2140 (counted_command_line): New typedef.
2141 (struct command_line): Add constructor, destructor.
2142 <body_list>: Remove.
2143 <body_list_0, body_list_1>: New members.
2144 (command_line_up): Remove typedef.
2145 (read_command_lines, read_command_lines_1, get_command_line):
2146 Update.
2147 (copy_command_lines): Don't declare.
2148 * cli/cli-script.c (build_command_line): Use "new".
2149 (get_command_line): Return counted_command_line.
2150 (print_command_lines, execute_user_command)
2151 (execute_control_command_1, while_command, if_command): Update.
2152 (realloc_body_list): Remove.
2153 (process_next_line, recurse_read_control_structure): Update.
2154 (read_command_lines, read_command_lines_1): Return counted_command_line.
2155 (free_command_lines): Use "delete".
2156 (copy_command_lines): Remove.
2157 (define_command, document_command, show_user_1): Update.
2158 * cli/cli-decode.h (struct cmd_list_element) <user_commands>: Now
2159 a counted_command_line.
2160 * breakpoint.h (counted_command_line): Remove typedef.
2161 (breakpoint_set_commands): Update.
2162 * breakpoint.c (check_no_tracepoint_commands)
2163 (validate_commands_for_breakpoint): Update.
2164 (breakpoint_set_commands): Change commands to be a
2165 counted_command_line.
2166 (commands_command_1, update_dprintf_command_list)
2167 (create_tracepoint_from_upload): Update.
2168
e2fc72e2
TT
21692018-05-04 Tom Tromey <tom@tromey.com>
2170
2171 * cli/cli-decode.h (cmd_list_element): New constructor.
2172 (~cmd_list_element): New destructor.
2173 (struct cmd_list_element): Add initializers.
2174 * cli/cli-decode.c (do_add_cmd): Use "new".
2175 (delete_cmd): Use "delete".
2176
a3b60e45
JK
21772018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
2178 Pedro Alves <palves@redhat.com>
2179
2180 PR breakpoints/19806 and support for PR external/20207.
2181 * NEWS: Mention Aarch64 watchpoint improvements.
2182 * aarch64-linux-nat.c (aarch64_linux_stopped_data_address): Fix missed
2183 watchpoints and PR external/20207 watchpoints.
2184 * nat/aarch64-linux-hw-point.c
2185 (kernel_supports_any_contiguous_range): New.
2186 (aarch64_watchpoint_offset): New.
2187 (aarch64_watchpoint_length): Support PR external/20207 watchpoints.
2188 (aarch64_point_encode_ctrl_reg): New parameter offset, new asserts.
2189 (aarch64_point_is_aligned): Support PR external/20207 watchpoints.
2190 (aarch64_align_watchpoint): New parameters aligned_offset_p and
2191 next_addr_orig_p. Support PR external/20207 watchpoints.
2192 (aarch64_downgrade_regs): New.
2193 (aarch64_dr_state_insert_one_point): New parameters offset and
2194 addr_orig.
2195 (aarch64_dr_state_remove_one_point): Likewise.
2196 (aarch64_handle_breakpoint): Update caller.
2197 (aarch64_handle_aligned_watchpoint): Likewise.
2198 (aarch64_handle_unaligned_watchpoint): Support addr_orig and
2199 aligned_offset.
2200 (aarch64_linux_set_debug_regs): Remove const from state. Call
2201 aarch64_downgrade_regs.
2202 (aarch64_show_debug_reg_state): Print also dr_addr_orig_wp.
2203 * nat/aarch64-linux-hw-point.h (DR_CONTROL_LENGTH): Rename to ...
2204 (DR_CONTROL_MASK): ... this.
2205 (struct aarch64_debug_reg_state): New field dr_addr_orig_wp.
2206 (unsigned int aarch64_watchpoint_offset): New prototype.
2207 (aarch64_linux_set_debug_regs): Remove const from state.
2208 * utils.c (align_up, align_down): Move to ...
2209 * common/common-utils.c (align_up, align_down): ... here.
2210 * utils.h (align_up, align_down): Move to ...
2211 * common/common-utils.h (align_up, align_down): ... here.
2212
05bc7456
JB
22132018-05-04 Joel Brobecker <brobecker@adacore.com>
2214
2215 * sparc-tdep.c (sparc_structure_return_p): Re-implement to
2216 match the ABI as summarized in GCC's gcc/config/sparc/sparc.c.
2217 (sparc_arg_by_memory_p): Renamed from sparc_arg_on_registers_p.
2218 Re-implement to match the ABI as summarized in GCC's
2219 gcc/config/sparc/sparc.c. All callers updated.
2220 (sparc32_store_arguments): Remove assertion.
2221
2f433492
TT
22222018-05-04 Tom Tromey <tom@tromey.com>
2223
2224 * printcmd.c: Don't include tui.h.
2225 (decode_format): Use skip_spaces.
2226
9be2ae8f
TT
22272018-05-04 Tom Tromey <tom@tromey.com>
2228
2229 PR gdb/22619:
2230 * printcmd.c (last_count): New global.
2231 (x_command): Use saved count when repeating.
2232
f0b3976b
TT
22332018-05-04 Tom Tromey <tom@tromey.com>
2234
2235 * nto-procfs.c (do_closedir_cleanup): Remove.
2236 (procfs_pidlist): Use gdb_dir_up.
2237 * procfs.c (do_closedir_cleanup): Remove.
2238 (proc_update_threads): Use gdb_dir_up.
2239 * common/filestuff.h (struct gdb_dir_deleter): New.
2240 (gdb_dir_up): New typedef.
2241
862d101a
TT
22422018-05-04 Tom Tromey <tom@tromey.com>
2243
2244 * ada-lang.c (print_mention_exception): Use std::string.
2245
cb7de75e
TT
22462018-05-04 Tom Tromey <tom@tromey.com>
2247
2248 * ada-lang.c (create_excep_cond_exprs): Update.
2249 (ada_exception_catchpoint_cond_string): Use std::string.
2250
49d83361
TT
22512018-05-04 Tom Tromey <tom@tromey.com>
2252
2253 * ada-lang.c (xget_renaming_scope): Return std::string.
2254 (old_renaming_is_invisible): Update.
2255
ade72a34
TT
22562018-05-04 Tom Tromey <tom@tromey.com>
2257
2258 * bfd-target.c (target_bfd::m_bfd): Now a gdb_bfd_ref_ptr.
2259 (target_bfd::target_bfd, target_bfd::~target_bfd): Update.
2260
2be4d7f0
UW
22612018-05-04 Ulrich Weigand <uweigand@de.ibm.com>
2262
2263 * spu-linux-nat.c (spu_linux_nat_target::wait): Fix syntax error.
2264
69b6ecb0
TT
22652018-05-04 Tom Tromey <tom@tromey.com>
2266
2267 * remote.c (remote_query_supported_append): Change type.
2268 (remote_check_symbols): Update.
2269
bf27f0e2
PP
22702018-05-04 Paul Pluzhnikov <ppluzhnikov@google.com>
2271
2272 PR gdb/11420
2273 * configure.ac: Prepend libpython.
2274 * python/python-config.py: Likewise.
2275 * configure: Regenerate.
2276
4ea17de8
SM
22772018-05-03 Simon Marchi <simon.marchi@ericsson.com>
2278
2279 * Makefile.in (%.c: %.l): Use -t instead of --stdout.
2280
bd732259
PA
22812018-05-03 Pedro Alves <palves@redhat.com>
2282
2283 * s390-linux-nat.c
2284 (s390_linux_nat_target::have_continuable_watchpoint): Mark with
2285 override. Write 'true' instead of '1'.
2286 (s390_linux_nat_target::watchpoint_addr_within_range): Remove
2287 declaration.
2288
d9f719f1
PA
22892018-05-02 Pedro Alves <palves@redhat.com>
2290
2291 * aarch64-fbsd-nat.c (_initialize_aarch64_fbsd_nat): Use
2292 add_inf_child_target.
2293 * aarch64-linux-nat.c (_initialize_aarch64_linux_nat): Use
2294 add_inf_child_target.
2295 * aix-thread.c (aix_thread_target_info): New.
2296 (aix_thread_target) <shortname, longname, doc>: Delete.
2297 <info>: New.
2298 * alpha-bsd-nat.c (_initialize_alphabsd_nat): Use
2299 add_inf_child_target.
2300 * alpha-linux-nat.c (_initialize_alpha_linux_nat): Use
2301 add_inf_child_target.
2302 * amd64-fbsd-nat.c (_initialize_amd64fbsd_nat): Use
2303 add_inf_child_target.
2304 * amd64-linux-nat.c (_initialize_amd64_linux_nat): Use
2305 add_inf_child_target.
2306 * amd64-nbsd-nat.c (_initialize_amd64nbsd_nat): Use
2307 add_inf_child_target.
2308 * amd64-obsd-nat.c (_initialize_amd64obsd_nat): Use
2309 add_inf_child_target.
2310 * arm-fbsd-nat.c (_initialize_arm_fbsd_nat): Use
2311 add_inf_child_target.
2312 * arm-linux-nat.c (_initialize_arm_linux_nat): Use
2313 add_inf_child_target.
2314 * arm-nbsd-nat.c (_initialize_arm_netbsd_nat): Use
2315 add_inf_child_target.
2316 * bfd-target.c (target_bfd_target_info): New.
2317 (target_bfd) <shortname, longname, doc>: Delete.
2318 <info>: New.
2319 * bsd-kvm.c (bsd_kvm_target_info): New.
2320 (bsd_kvm_target) <shortname, longname, doc>: Delete.
2321 <info>: New.
2322 (bsd_kvm_target::open): Rename to ...
2323 (bsd_kvm_target_open): ... this. Adjust.
2324 * bsd-uthread.c (bsd_uthread_target_info): New.
2325 (bsd_uthread_target) <shortname, longname, doc>: Delete.
2326 <info>: New.
2327 * corefile.c (core_file_command): Adjust.
2328 * corelow.c (core_target_info): New.
2329 (core_target) <shortname, longname, doc>: Delete.
2330 <info>: New.
2331 (core_target::open): Rename to ...
2332 (core_target_open): ... this. Adjust.
2333 * ctf.c (ctf_target_info): New.
2334 (ctf_target) <shortname, longname, doc>: Delete.
2335 <info>: New.
2336 (ctf_target::open): Rename to ...
2337 (ctf_target_open): ... this.
2338 (_initialize_ctf): Adjust.
2339 * exec.c (exec_target_info): New.
2340 (exec_target) <shortname, longname, doc>: Delete.
2341 <info>: New.
2342 (exec_target::open): Rename to ...
2343 (exec_target_open): ... this.
2344 * gdbcore.h (core_target_open): Declare.
2345 * go32-nat.c (_initialize_go32_nat): Use add_inf_child_target.
2346 * hppa-linux-nat.c (_initialize_hppa_linux_nat): Use
2347 add_inf_child_target.
2348 * hppa-nbsd-nat.c (_initialize_hppanbsd_nat): Use
2349 add_inf_child_target.
2350 * hppa-obsd-nat.c (_initialize_hppaobsd_nat): Use
2351 add_inf_child_target.
2352 * i386-darwin-nat.c (_initialize_i386_darwin_nat): Use
2353 add_inf_child_target.
2354 * i386-fbsd-nat.c (_initialize_i386fbsd_nat): Use
2355 add_inf_child_target.
2356 * i386-gnu-nat.c (_initialize_i386gnu_nat): Use
2357 add_inf_child_target.
2358 * i386-linux-nat.c (_initialize_i386_linux_nat): Use
2359 add_inf_child_target.
2360 * i386-nbsd-nat.c (_initialize_i386nbsd_nat): Use
2361 add_inf_child_target.
2362 * i386-obsd-nat.c (_initialize_i386obsd_nat): Use
2363 add_inf_child_target.
2364 * ia64-linux-nat.c (_initialize_ia64_linux_nat): Use
2365 add_inf_child_target.
2366 * inf-child.c (inf_child_target_info): New.
2367 (inf_child_target::info): New.
2368 (inf_child_open_target): Remove 'target' parameter. Use
2369 get_native_target instead.
2370 (inf_child_target::open): Delete.
2371 (add_inf_child_target): New.
2372 * inf-child.h (inf_child_target) <shortname, longname, doc, open>:
2373 Delete.
2374 <info>: New.
2375 (add_inf_child_target): Declare.
2376 (inf_child_open_target): Declare.
2377 * linux-thread-db.c (thread_db_target_info): New.
2378 (thread_db_target) <shortname, longname, doc>: Delete.
2379 <info>: New.
2380 * m32r-linux-nat.c (_initialize_m32r_linux_nat): Use
2381 add_inf_child_target.
2382 * m68k-bsd-nat.c (_initialize_m68kbsd_nat): Use
2383 add_inf_child_target.
2384 * m68k-linux-nat.c (_initialize_m68k_linux_nat): Use
2385 add_inf_child_target.
2386 * m88k-bsd-nat.c (_initialize_m88kbsd_nat): Use
2387 add_inf_child_target.
2388 * make-target-delegates (print_class): Adjust.
2389 * mips-fbsd-nat.c (_initialize_mips_fbsd_nat): Use
2390 add_inf_child_target.
2391 * mips-linux-nat.c (_initialize_mips_linux_nat): Use
2392 add_inf_child_target.
2393 * mips-nbsd-nat.c (_initialize_mipsnbsd_nat): Use
2394 add_inf_child_target.
2395 * mips64-obsd-nat.c (_initialize_mips64obsd_nat): Use
2396 add_inf_child_target.
2397 * nto-procfs.c (nto_native_target_info): New.
2398 (nto_procfs_target_native) <shortname, longname, doc>:
2399 Delete.
2400 <info>: New.
2401 (nto_procfs_target_info): New.
2402 (nto_procfs_target_procfs) <shortname, longname, doc>:
2403 Delete.
2404 <info>: New.
2405 (init_procfs_targets): Adjust.
2406 * ppc-fbsd-nat.c (_initialize_ppcfbsd_nat): Use
2407 add_inf_child_target.
2408 * ppc-linux-nat.c (_initialize_ppc_linux_nat): Use
2409 add_inf_child_target.
2410 * ppc-nbsd-nat.c (_initialize_ppcnbsd_nat): Use
2411 add_inf_child_target.
2412 * ppc-obsd-nat.c (_initialize_ppcobsd_nat): Use
2413 add_inf_child_target.
2414 * ravenscar-thread.c (ravenscar_target_info): New.
2415 (ravenscar_thread_target) <shortname, longname, doc>:
2416 Delete.
2417 <info>: New.
2418 * record-btrace.c (record_btrace_target_info):
2419 (record_btrace_target) <shortname, longname, doc>: Delete.
2420 <info>: New.
2421 (record_btrace_target::open): Rename to ...
2422 (record_btrace_target_open): ... this. Adjust.
2423 * record-full.c (record_longname, record_doc): New.
2424 (record_full_base_target) <shortname, longname, doc>: Delete.
2425 <info>: New.
2426 (record_full_target_info): New.
2427 (record_full_target): <shortname>: Delete.
2428 <info>: New.
2429 (record_full_core_open_1, record_full_open_1): Update comments.
2430 (record_full_base_target::open): Rename to ...
2431 (record_full_open): ... this.
2432 (cmd_record_full_restore): Update.
2433 (_initialize_record_full): Update.
2434 * remote-sim.c (remote_sim_target_info): New.
2435 (gdbsim_target) <shortname, longname, doc>: Delete.
2436 <info>: New.
2437 (gdbsim_target::open): Rename to ...
2438 (gdbsim_target_open): ... this.
2439 (_initialize_remote_sim): Adjust.
2440 * remote.c (remote_doc): New.
2441 (remote_target_info): New.
2442 (remote_target) <shortname, longname, doc>: Delete.
2443 <info>: New.
2444 (extended_remote_target_info): New.
2445 (extended_remote_target) <shortname, longname, doc>: Delete.
2446 <info>: New.
2447 (remote_target::open_1): Make static. Adjust.
2448 * rs6000-nat.c (_initialize_rs6000_nat): Use add_inf_child_target.
2449 * s390-linux-nat.c (_initialize_s390_nat): Use
2450 add_inf_child_target.
2451 * sh-nbsd-nat.c (_initialize_shnbsd_nat): Use
2452 add_inf_child_target.
2453 * sol-thread.c (thread_db_target_info): New.
2454 (sol_thread_target) <shortname, longname, doc>: Delete.
2455 <info>: New.
2456 * sparc-linux-nat.c (_initialize_sparc_linux_nat): Use
2457 add_inf_child_target.
2458 * sparc-nbsd-nat.c (_initialize_sparcnbsd_nat): Use
2459 add_inf_child_target.
2460 * sparc64-fbsd-nat.c (_initialize_sparc64fbsd_nat): Use
2461 add_inf_child_target.
2462 * sparc64-linux-nat.c (_initialize_sparc64_linux_nat): Use
2463 add_inf_child_target.
2464 * sparc64-nbsd-nat.c (_initialize_sparc64nbsd_nat): Use
2465 add_inf_child_target.
2466 * sparc64-obsd-nat.c (_initialize_sparc64obsd_nat): Use
2467 add_inf_child_target.
2468 * spu-linux-nat.c (_initialize_spu_nat): Use
2469 add_inf_child_target.
2470 * spu-multiarch.c (spu_multiarch_target_info): New.
2471 (spu_multiarch_target) <shortname, longname, doc>: Delete.
2472 <info>: New.
2473 * target-delegates.c: Regenerate.
2474 * target.c: Include <unordered_map>.
2475 (target_ops_p): Delete.
2476 (DEF_VEC_P(target_ops_p)): Delete.
2477 (target_factories): New.
2478 (test_target_info): New.
2479 (test_target_ops::info): New.
2480 (open_target): Adjust to use target_factories.
2481 (add_target_with_completer): Rename to ...
2482 (add_target): ... this. Change prototype. Register target_info
2483 and open callback in target_factories. Register target_info in
2484 command context instead of target_ops.
2485 (add_target): Delete old implementation.
2486 (add_deprecated_target_alias): Change prototype. Adjust.
2487 (the_native_target): New.
2488 (set_native_target, get_native_target): New.
2489 (find_default_run_target): Use the_native_target.
2490 (find_attach_target, find_run_target): Simplify.
2491 (target_ops::open): Delete.
2492 (dummy_target_info): New.
2493 (dummy_target::shortname, dummy_target::longname)
2494 (dummy_target::doc): Delete.
2495 (dummy_target::info): New.
2496 (debug_target::shortname, debug_target::longname)
2497 (debug_target::doc): Delete.
2498 (debug_target::info): New.
2499 * target.h (struct target_info): New.
2500 (target_ops::~target_ops): Add comment.
2501 (target_ops::info): New.
2502 (target_ops::shortname, target_ops::longname, target_ops::doc): No
2503 longer virtual. Implement in terms of target_info.
2504 (set_native_target, get_native_target): Declare.
2505 (target_open_ftype): New.
2506 (add_target, add_target_with_completer)
2507 (add_deprecated_target_alias): Change prototype.
2508 (test_target) <shortname, longname, doc>: Delete.
2509 <info>: New.
2510 * tilegx-linux-nat.c (_initialize_tile_linux_nat): Use
2511 add_inf_child_target.
2512 * tracefile-tfile.c (tfile_target_info): New.
2513 (tfile_target) <shortname, longname, doc>: Delete.
2514 <info>: New.
2515 (tfile_target::open): Rename to ...
2516 (tfile_target_open): ... this.
2517 (_initialize_tracefile_tfile): Adjust.
2518 * vax-bsd-nat.c (_initialize_vaxbsd_nat): Use
2519 add_inf_child_target.
2520 * windows-nat.c (_initialize_windows_nat): Use
2521 add_inf_child_target.
2522 * xtensa-linux-nat.c (_initialize_xtensa_linux_nat): Use
2523 add_inf_child_target.
2524
135340af
PA
25252018-05-02 Pedro Alves <palves@redhat.com>
2526
2527 * linux-nat.h (linux_nat_target) <low_new_thread,
2528 low_delete_thread, low_new_fork, low_forget_process,
2529 low_prepare_to_resume, low_siginfo_fixup, low_status_is_event>:
2530 New virtual methods.
2531 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
2532 (linux_nat_new_fork_ftype, linux_nat_set_new_fork)
2533 (linux_nat_forget_process_ftype, linux_nat_set_forget_process)
2534 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
2535 (linux_nat_set_prepare_to_resume, linux_nat_set_status_is_event):
2536 Delete.
2537 * linux-fork.c (delete_fork): Adjust to call low method.
2538 * linux-nat.c (linux_nat_new_thread, linux_nat_delete_thread)
2539 (linux_nat_new_fork, linux_nat_forget_process_hook)
2540 (linux_nat_prepare_to_resume, linux_nat_siginfo_fixup)
2541 (linux_nat_status_is_event):
2542 (linux_nat_target::follow_fork, lwp_free, add_lwp, detach_one_lwp)
2543 (linux_resume_one_lwp_throw, linux_handle_extended_wait): Adjust
2544 to call low method.
2545 (sigtrap_is_event): Rename to ...
2546 (linux_nat_target::low_status_is_event): ... this.
2547 (linux_nat_set_status_is_event): Delete.
2548 (save_stop_reason, linux_nat_wait_1)
2549 (linux_nat_target::mourn_inferior, siginfo_fixup): Adjust to call
2550 low methods.
2551 (linux_nat_set_new_thread, linux_nat_set_delete_thread)
2552 (linux_nat_set_new_fork, linux_nat_set_forget_process)
2553 (linux_nat_forget_process, linux_nat_set_siginfo_fixup)
2554 (linux_nat_set_prepare_to_resume): Delete.
2555 * aarch64-linux-nat.c: All linux_nat_set_* callbacks converted to
2556 low virtual methods.
2557 * amd64-linux-nat.c: Likewise.
2558 * arm-linux-nat.c: Likewise.
2559 * i386-linux-nat.c: Likewise.
2560 * ia64-linux-nat.c: Likewise.
2561 * mips-linux-nat.c: Likewise.
2562 * ppc-linux-nat.c: Likewise.
2563 * s390-linux-nat.c: Likewise.
2564 * sparc64-linux-nat.c: Likewise.
2565 * x86-linux-nat.c: Likewise.
2566 * x86-linux-nat.h: Include "nat/x86-linux.h".
2567 (x86_linux_nat_target) <low_new_fork, low_forget_process,
2568 low_prepare_to_resume, low_new_thread, low_delete_thread>:
2569 Override methods.
2570
57810aa7
PA
25712018-05-02 Pedro Alves <palves@redhat.com>
2572
2573 * target.h (target_ops)
2574 <stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
2575 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint,
2576 stopped_by_watchpoint, have_continuable_watchpoint,
2577 stopped_data_address, watchpoint_addr_within_range,
2578 can_accel_watchpoint_condition, can_run, thread_alive,
2579 has_all_memory, has_memory, has_stack, has_registers,
2580 has_execution, can_async_p, is_async_p, supports_non_stop,
2581 always_non_stop_p, can_execute_reverse, supports_multi_process,
2582 supports_enable_disable_tracepoint,
2583 supports_disable_randomization, supports_string_tracing,
2584 supports_evaluation_of_breakpoint_conditions,
2585 can_run_breakpoint_commands, filesystem_is_local,
2586 can_download_tracepoint, get_trace_state_variable_value,
2587 set_trace_notes, get_tib_address, use_agent, can_use_agent,
2588 record_is_replaying, record_will_replay,
2589 augmented_libraries_svr4_read>: Adjust to return bool.
2590 * aarch64-linux-nat.c: All implementations adjusted.
2591 * aix-thread.c: All implementations adjusted.
2592 * arm-linux-nat.c: All implementations adjusted.
2593 * breakpoint.c: All implementations adjusted.
2594 * bsd-kvm.c: All implementations adjusted.
2595 * bsd-uthread.c: All implementations adjusted.
2596 * corelow.c: All implementations adjusted.
2597 * ctf.c: All implementations adjusted.
2598 * darwin-nat.c: All implementations adjusted.
2599 * darwin-nat.h: All implementations adjusted.
2600 * exec.c: All implementations adjusted.
2601 * fbsd-nat.c: All implementations adjusted.
2602 * fbsd-nat.h: All implementations adjusted.
2603 * gnu-nat.c: All implementations adjusted.
2604 * gnu-nat.h: All implementations adjusted.
2605 * go32-nat.c: All implementations adjusted.
2606 * ia64-linux-nat.c: All implementations adjusted.
2607 * inf-child.c: All implementations adjusted.
2608 * inf-child.h: All implementations adjusted.
2609 * inf-ptrace.c: All implementations adjusted.
2610 * inf-ptrace.h: All implementations adjusted.
2611 * linux-nat.c: All implementations adjusted.
2612 * linux-nat.h: All implementations adjusted.
2613 * mips-linux-nat.c: All implementations adjusted.
2614 * nto-procfs.c: All implementations adjusted.
2615 * ppc-linux-nat.c: All implementations adjusted.
2616 * procfs.c: All implementations adjusted.
2617 * ravenscar-thread.c: All implementations adjusted.
2618 * record-btrace.c: All implementations adjusted.
2619 * record-full.c: All implementations adjusted.
2620 * remote-sim.c: All implementations adjusted.
2621 * remote.c: All implementations adjusted.
2622 * s390-linux-nat.c: All implementations adjusted.
2623 * sol-thread.c: All implementations adjusted.
2624 * spu-multiarch.c: All implementations adjusted.
2625 * target-delegates.c: All implementations adjusted.
2626 * target.c: All implementations adjusted.
2627 * target.h: All implementations adjusted.
2628 * tracefile-tfile.c: All implementations adjusted.
2629 * tracefile.c: All implementations adjusted.
2630 * tracefile.h: All implementations adjusted.
2631 * windows-nat.c: All implementations adjusted.
2632 * x86-linux-nat.h: All implementations adjusted.
2633 * x86-nat.h: All implementations adjusted.
2634
ad6a4e2d
PA
26352018-05-02 Pedro Alves <palves@redhat.com>
2636
2637 * make-target-delegates (scan_target_h): Don't trim lines here.
2638 Replace sequences of tabs and/or whitespace with a single
2639 whitespace.
2640 (top level, parsing methods): Trim each line before processing it
2641 here.
2642
f6ac5f3d
PA
26432018-05-02 Pedro Alves <palves@redhat.com>
2644 John Baldwin <jhb@freebsd.org>
2645
2646 * target.h (enum strata) <debug_stratum>: New.
2647 (struct target_ops) <all delegation methods>: Replace by C++
2648 virtual methods, and drop "to_" prefix. All references updated
2649 throughout.
2650 <to_shortname, to_longname, to_doc, to_data,
2651 to_have_steppable_watchpoint, to_have_continuable_watchpoint,
2652 to_has_thread_control, to_attach_no_wait>: Delete, replaced by
2653 virtual methods. All references updated throughout.
2654 <can_attach, supports_terminal_ours, can_create_inferior,
2655 get_thread_control_capabilities, attach_no_wait>: New
2656 virtual methods.
2657 <insert_breakpoint, remove_breakpoint>: Now
2658 TARGET_DEFAULT_NORETURN methods.
2659 <info_proc>: Now returns bool.
2660 <to_magic>: Delete.
2661 (OPS_MAGIC): Delete.
2662 (current_target): Delete. All references replaced by references
2663 to ...
2664 (target_stack): ... this. New.
2665 (target_shortname, target_longname): Adjust.
2666 (target_can_run): Now a function declaration.
2667 (default_child_has_all_memory, default_child_has_memory)
2668 (default_child_has_stack, default_child_has_registers)
2669 (default_child_has_execution): Remove target_ops parameter.
2670 (complete_target_initialization): Delete.
2671 (memory_breakpoint_target): New template class.
2672 (test_target_ops): Refactor as a C++ class with virtual methods.
2673 * make-target-delegates (NAME_PART): Tighten.
2674 (POINTER_PART, CP_SYMBOL): New.
2675 (SIMPLE_RETURN_PART): Reimplement.
2676 (VEC_RETURN_PART): Expect less.
2677 (RETURN_PART, VIRTUAL_PART): New.
2678 (METHOD): Adjust to C++ virtual methods.
2679 (scan_target_h): Remove reference to C99.
2680 (dname): Output "target_ops::" prefix.
2681 (write_function_header): Adjust to output a C++ class method.
2682 (write_declaration): New.
2683 (write_delegator): Adjust to output a C++ class method.
2684 (tdname): Output "dummy_target::" prefix.
2685 (write_tdefault, write_debugmethod): Adjust to output a C++ class
2686 method.
2687 (tdefault_names, debug_names): Delete.
2688 (return_types, tdefaults, styles, argtypes_array): New.
2689 (top level): All methods are delegators.
2690 (print_class): New.
2691 (top level): Print dummy_target and debug_target classes.
2692 * target-delegates.c: Regenerate.
2693 * target-debug.h (target_debug_print_enum_info_proc_what)
2694 (target_debug_print_thread_control_capabilities)
2695 (target_debug_print_thread_info_p): New.
2696 * target.c (dummy_target): Delete.
2697 (the_dummy_target, the_debug_target): New.
2698 (target_stack): Now extern.
2699 (set_targetdebug): Push/unpush debug target.
2700 (default_child_has_all_memory, default_child_has_memory)
2701 (default_child_has_stack, default_child_has_registers)
2702 (default_child_has_execution): Remove target_ops parameter.
2703 (complete_target_initialization): Delete.
2704 (add_target_with_completer): No longer call
2705 complete_target_initialization.
2706 (target_supports_terminal_ours): Use regular delegation.
2707 (update_current_target): Delete.
2708 (push_target): No longer check magic number. Don't call
2709 update_current_target.
2710 (unpush_target): Don't call update_current_target.
2711 (target_is_pushed): No longer check magic number.
2712 (target_require_runnable): Skip for all stratums over
2713 process_stratum.
2714 (target_ops::info_proc): New.
2715 (target_info_proc): Use find_target_at and
2716 find_default_run_target.
2717 (target_supports_disable_randomization): Use regular delegation.
2718 (target_get_osdata): Use find_target_at.
2719 (target_ops::open, target_ops::close, target_ops::can_attach)
2720 (target_ops::attach, target_ops::can_create_inferior)
2721 (target_ops::create_inferior, target_ops::can_run)
2722 (target_can_run): New.
2723 (default_fileio_target): Use regular delegation.
2724 (target_ops::fileio_open, target_ops::fileio_pwrite)
2725 (target_ops::fileio_pread, target_ops::fileio_fstat)
2726 (target_ops::fileio_close, target_ops::fileio_unlink)
2727 (target_ops::fileio_readlink): New.
2728 (target_fileio_open_1, target_fileio_unlink)
2729 (target_fileio_readlink): Always call the target method. Handle
2730 FILEIO_ENOSYS.
2731 (return_zero, return_zero_has_execution): Delete.
2732 (init_dummy_target): Delete.
2733 (dummy_target::dummy_target, dummy_target::shortname)
2734 (dummy_target::longname, dummy_target::doc)
2735 (debug_target::debug_target, debug_target::shortname)
2736 (debug_target::longname, debug_target::doc): New.
2737 (target_supports_delete_record): Use regular delegation.
2738 (setup_target_debug): Delete.
2739 (maintenance_print_target_stack): Skip debug_stratum.
2740 (initialize_targets): Instantiate the_dummy_target and
2741 the_debug_target.
2742 * auxv.c (target_auxv_parse): Remove 'ops' parameter. Adjust to
2743 use target_stack.
2744 (target_auxv_search, fprint_target_auxv): Adjust.
2745 (info_auxv_command): Adjust to use target_stack.
2746 * auxv.h (target_auxv_parse): Remove 'ops' parameter.
2747 * exceptions.c (print_flush): Handle a NULL target_stack.
2748 * regcache.c (target_ops_no_register): Refactor as class with
2749 virtual methods.
2750
2751 * exec.c (exec_target): New class.
2752 (exec_ops): Now an exec_target.
2753 (exec_open, exec_close_1, exec_get_section_table)
2754 (exec_xfer_partial, exec_files_info, exec_has_memory)
2755 (exec_make_note_section): Refactor as exec_target methods.
2756 (exec_file_clear, ignore, exec_remove_breakpoint, init_exec_ops):
2757 Delete.
2758 (exec_target::find_memory_regions): New.
2759 (_initialize_exec): Don't call init_exec_ops.
2760 * gdbcore.h (exec_file_clear): Delete.
2761
2762 * corefile.c (core_target): Delete.
2763 (core_file_command): Adjust.
2764 * corelow.c (core_target): New class.
2765 (the_core_target): New.
2766 (core_close): Remove target_ops parameter.
2767 (core_close_cleanup): Adjust.
2768 (core_target::close): New.
2769 (core_open, core_detach, get_core_registers, core_files_info)
2770 (core_xfer_partial, core_thread_alive, core_read_description)
2771 (core_pid_to_str, core_thread_name, core_has_memory)
2772 (core_has_stack, core_has_registers, core_info_proc): Rework as
2773 core_target methods.
2774 (ignore, core_remove_breakpoint, init_core_ops): Delete.
2775 (_initialize_corelow): Initialize the_core_target.
2776 * gdbcore.h (core_target): Delete.
2777 (the_core_target): New.
2778
2779 * ctf.c: (ctf_target): New class.
2780 (ctf_ops): Now a ctf_target.
2781 (ctf_open, ctf_close, ctf_files_info, ctf_fetch_registers)
2782 (ctf_xfer_partial, ctf_get_trace_state_variable_value)
2783 (ctf_trace_find, ctf_traceframe_info): Refactor as ctf_target
2784 methods.
2785 (init_ctf_ops): Delete.
2786 (_initialize_ctf): Don't call it.
2787 * tracefile-tfile.c (tfile_target): New class.
2788 (tfile_ops): Now a tfile_target.
2789 (tfile_open, tfile_close, tfile_files_info)
2790 (tfile_get_tracepoint_status, tfile_trace_find)
2791 (tfile_fetch_registers, tfile_xfer_partial)
2792 (tfile_get_trace_state_variable_value, tfile_traceframe_info):
2793 Refactor as tfile_target methods.
2794 (tfile_xfer_partial_features): Remove target_ops parameter.
2795 (init_tfile_ops): Delete.
2796 (_initialize_tracefile_tfile): Don't call it.
2797 * tracefile.c (tracefile_has_all_memory, tracefile_has_memory)
2798 (tracefile_has_stack, tracefile_has_registers)
2799 (tracefile_thread_alive, tracefile_get_trace_status): Refactor as
2800 tracefile_target methods.
2801 (init_tracefile_ops): Delete.
2802 (tracefile_target::tracefile_target): New.
2803 * tracefile.h: Include "target.h".
2804 (tracefile_target): New class.
2805 (init_tracefile_ops): Delete.
2806
2807 * spu-multiarch.c (spu_multiarch_target): New class.
2808 (spu_ops): Now a spu_multiarch_target.
2809 (spu_thread_architecture, spu_region_ok_for_hw_watchpoint)
2810 (spu_fetch_registers, spu_store_registers, spu_xfer_partial)
2811 (spu_search_memory, spu_mourn_inferior): Refactor as
2812 spu_multiarch_target methods.
2813 (init_spu_ops): Delete.
2814 (_initialize_spu_multiarch): Remove references to init_spu_ops,
2815 complete_target_initialization.
2816
2817 * ravenscar-thread.c (ravenscar_thread_target): New class.
2818 (ravenscar_ops): Now a ravenscar_thread_target.
2819 (ravenscar_resume, ravenscar_wait, ravenscar_update_thread_list)
2820 (ravenscar_thread_alive, ravenscar_pid_to_str)
2821 (ravenscar_fetch_registers, ravenscar_store_registers)
2822 (ravenscar_prepare_to_store, ravenscar_stopped_by_sw_breakpoint)
2823 (ravenscar_stopped_by_hw_breakpoint)
2824 (ravenscar_stopped_by_watchpoint, ravenscar_stopped_data_address)
2825 (ravenscar_mourn_inferior, ravenscar_core_of_thread)
2826 (ravenscar_get_ada_task_ptid): Refactor as ravenscar_thread_target
2827 methods.
2828 (init_ravenscar_thread_ops): Delete.
2829 (_initialize_ravenscar): Remove references to
2830 init_ravenscar_thread_ops and complete_target_initialization.
2831
2832 * bsd-uthread.c (bsd_uthread_ops_hack): Delete.
2833 (bsd_uthread_target): New class.
2834 (bsd_uthread_ops): Now a bsd_uthread_target.
2835 (bsd_uthread_activate): Adjust to refer to bsd_uthread_ops.
2836 (bsd_uthread_close, bsd_uthread_mourn_inferior)
2837 (bsd_uthread_fetch_registers, bsd_uthread_store_registers)
2838 (bsd_uthread_wait, bsd_uthread_resume, bsd_uthread_thread_alive)
2839 (bsd_uthread_update_thread_list, bsd_uthread_extra_thread_info)
2840 (bsd_uthread_pid_to_str): Refactor as bsd_uthread_target methods.
2841 (bsd_uthread_target): Delete function.
2842 (_initialize_bsd_uthread): Remove reference to
2843 complete_target_initialization.
2844
2845 * bfd-target.c (target_bfd_data): Delete. Fields folded into ...
2846 (target_bfd): ... this new class.
2847 (target_bfd_xfer_partial, target_bfd_get_section_table)
2848 (target_bfd_close): Refactor as target_bfd methods.
2849 (target_bfd::~target_bfd): New.
2850 (target_bfd_reopen): Adjust.
2851 (target_bfd::close): New.
2852
2853 * record-btrace.c (record_btrace_target): New class.
2854 (record_btrace_ops): Now a record_btrace_target.
2855 (record_btrace_open, record_btrace_stop_recording)
2856 (record_btrace_disconnect, record_btrace_close)
2857 (record_btrace_async, record_btrace_info)
2858 (record_btrace_insn_history, record_btrace_insn_history_range)
2859 (record_btrace_insn_history_from, record_btrace_call_history)
2860 (record_btrace_call_history_range)
2861 (record_btrace_call_history_from, record_btrace_record_method)
2862 (record_btrace_is_replaying, record_btrace_will_replay)
2863 (record_btrace_xfer_partial, record_btrace_insert_breakpoint)
2864 (record_btrace_remove_breakpoint, record_btrace_fetch_registers)
2865 (record_btrace_store_registers, record_btrace_prepare_to_store)
2866 (record_btrace_to_get_unwinder)
2867 (record_btrace_to_get_tailcall_unwinder, record_btrace_resume)
2868 (record_btrace_commit_resume, record_btrace_wait)
2869 (record_btrace_stop, record_btrace_can_execute_reverse)
2870 (record_btrace_stopped_by_sw_breakpoint)
2871 (record_btrace_supports_stopped_by_sw_breakpoint)
2872 (record_btrace_stopped_by_hw_breakpoint)
2873 (record_btrace_supports_stopped_by_hw_breakpoint)
2874 (record_btrace_update_thread_list, record_btrace_thread_alive)
2875 (record_btrace_goto_begin, record_btrace_goto_end)
2876 (record_btrace_goto, record_btrace_stop_replaying_all)
2877 (record_btrace_execution_direction)
2878 (record_btrace_prepare_to_generate_core)
2879 (record_btrace_done_generating_core): Refactor as
2880 record_btrace_target methods.
2881 (init_record_btrace_ops): Delete.
2882 (_initialize_record_btrace): Remove reference to
2883 init_record_btrace_ops.
2884 * record-full.c (RECORD_FULL_IS_REPLAY): Adjust to always refer to
2885 the execution_direction global.
2886 (record_full_base_target, record_full_target)
2887 (record_full_core_target): New classes.
2888 (record_full_ops): Now a record_full_target.
2889 (record_full_core_ops): Now a record_full_core_target.
2890 (record_full_target::detach, record_full_target::disconnect)
2891 (record_full_core_target::disconnect)
2892 (record_full_target::mourn_inferior, record_full_target::kill):
2893 New.
2894 (record_full_open, record_full_close, record_full_async): Refactor
2895 as methods of the record_full_base_target class.
2896 (record_full_resume, record_full_commit_resume): Refactor
2897 as methods of the record_full_target class.
2898 (record_full_wait, record_full_stopped_by_watchpoint)
2899 (record_full_stopped_data_address)
2900 (record_full_stopped_by_sw_breakpoint)
2901 (record_full_supports_stopped_by_sw_breakpoint)
2902 (record_full_stopped_by_hw_breakpoint)
2903 (record_full_supports_stopped_by_hw_breakpoint): Refactor as
2904 methods of the record_full_base_target class.
2905 (record_full_store_registers, record_full_xfer_partial)
2906 (record_full_insert_breakpoint, record_full_remove_breakpoint):
2907 Refactor as methods of the record_full_target class.
2908 (record_full_can_execute_reverse, record_full_get_bookmark)
2909 (record_full_goto_bookmark, record_full_execution_direction)
2910 (record_full_record_method, record_full_info, record_full_delete)
2911 (record_full_is_replaying, record_full_will_replay)
2912 (record_full_goto_begin, record_full_goto_end, record_full_goto)
2913 (record_full_stop_replaying): Refactor as methods of the
2914 record_full_base_target class.
2915 (record_full_core_resume, record_full_core_kill)
2916 (record_full_core_fetch_registers)
2917 (record_full_core_prepare_to_store)
2918 (record_full_core_store_registers, record_full_core_xfer_partial)
2919 (record_full_core_insert_breakpoint)
2920 (record_full_core_remove_breakpoint)
2921 (record_full_core_has_execution): Refactor
2922 as methods of the record_full_core_target class.
2923 (record_full_base_target::supports_delete_record): New.
2924 (init_record_full_ops): Delete.
2925 (init_record_full_core_ops): Delete.
2926 (record_full_save): Refactor as method of the
2927 record_full_base_target class.
2928 (_initialize_record_full): Remove references to
2929 init_record_full_ops and init_record_full_core_ops.
2930
2931 * remote.c (remote_target, extended_remote_target): New classes.
2932 (remote_ops): Now a remote_target.
2933 (extended_remote_ops): Now an extended_remote_target.
2934 (remote_insert_fork_catchpoint, remote_remove_fork_catchpoint)
2935 (remote_insert_vfork_catchpoint, remote_remove_vfork_catchpoint)
2936 (remote_insert_exec_catchpoint, remote_remove_exec_catchpoint)
2937 (remote_pass_signals, remote_set_syscall_catchpoint)
2938 (remote_program_signals, )
2939 (remote_thread_always_alive): Remove target_ops parameter.
2940 (remote_thread_alive, remote_thread_name)
2941 (remote_update_thread_list, remote_threads_extra_info)
2942 (remote_static_tracepoint_marker_at)
2943 (remote_static_tracepoint_markers_by_strid)
2944 (remote_get_ada_task_ptid, remote_close, remote_start_remote)
2945 (remote_open): Refactor as methods of remote_target.
2946 (extended_remote_open, extended_remote_detach)
2947 (extended_remote_attach, extended_remote_post_attach):
2948 (extended_remote_supports_disable_randomization)
2949 (extended_remote_create_inferior): : Refactor as method of
2950 extended_remote_target.
2951 (remote_set_permissions, remote_open_1, remote_detach)
2952 (remote_follow_fork, remote_follow_exec, remote_disconnect)
2953 (remote_resume, remote_commit_resume, remote_stop)
2954 (remote_interrupt, remote_pass_ctrlc, remote_terminal_inferior)
2955 (remote_terminal_ours, remote_wait, remote_fetch_registers)
2956 (remote_prepare_to_store, remote_store_registers)
2957 (remote_flash_erase, remote_flash_done, remote_files_info)
2958 (remote_kill, remote_mourn, remote_insert_breakpoint)
2959 (remote_remove_breakpoint, remote_insert_watchpoint)
2960 (remote_watchpoint_addr_within_range)
2961 (remote_remove_watchpoint, remote_region_ok_for_hw_watchpoint)
2962 (remote_check_watch_resources, remote_stopped_by_sw_breakpoint)
2963 (remote_supports_stopped_by_sw_breakpoint)
2964 (remote_stopped_by_hw_breakpoint)
2965 (remote_supports_stopped_by_hw_breakpoint)
2966 (remote_stopped_by_watchpoint, remote_stopped_data_address)
2967 (remote_insert_hw_breakpoint, remote_remove_hw_breakpoint)
2968 (remote_verify_memory): Refactor as methods of remote_target.
2969 (remote_write_qxfer, remote_read_qxfer): Remove target_ops
2970 parameter.
2971 (remote_xfer_partial, remote_get_memory_xfer_limit)
2972 (remote_search_memory, remote_rcmd, remote_memory_map)
2973 (remote_pid_to_str, remote_get_thread_local_address)
2974 (remote_get_tib_address, remote_read_description): Refactor as
2975 methods of remote_target.
2976 (remote_target::fileio_open, remote_target::fileio_pwrite)
2977 (remote_target::fileio_pread, remote_target::fileio_close): New.
2978 (remote_hostio_readlink, remote_hostio_fstat)
2979 (remote_filesystem_is_local, remote_can_execute_reverse)
2980 (remote_supports_non_stop, remote_supports_disable_randomization)
2981 (remote_supports_multi_process, remote_supports_cond_breakpoints)
2982 (remote_supports_enable_disable_tracepoint)
2983 (remote_supports_string_tracing)
2984 (remote_can_run_breakpoint_commands, remote_trace_init)
2985 (remote_download_tracepoint, remote_can_download_tracepoint)
2986 (remote_download_trace_state_variable, remote_enable_tracepoint)
2987 (remote_disable_tracepoint, remote_trace_set_readonly_regions)
2988 (remote_trace_start, remote_get_trace_status)
2989 (remote_get_tracepoint_status, remote_trace_stop)
2990 (remote_trace_find, remote_get_trace_state_variable_value)
2991 (remote_save_trace_data, remote_get_raw_trace_data)
2992 (remote_set_disconnected_tracing, remote_core_of_thread)
2993 (remote_set_circular_trace_buffer, remote_traceframe_info)
2994 (remote_get_min_fast_tracepoint_insn_len)
2995 (remote_set_trace_buffer_size, remote_set_trace_notes)
2996 (remote_use_agent, remote_can_use_agent, remote_enable_btrace)
2997 (remote_disable_btrace, remote_teardown_btrace)
2998 (remote_read_btrace, remote_btrace_conf)
2999 (remote_augmented_libraries_svr4_read, remote_load)
3000 (remote_pid_to_exec_file, remote_can_do_single_step)
3001 (remote_execution_direction, remote_thread_handle_to_thread_info):
3002 Refactor as methods of remote_target.
3003 (init_remote_ops, init_extended_remote_ops): Delete.
3004 (remote_can_async_p, remote_is_async_p, remote_async)
3005 (remote_thread_events, remote_upload_tracepoints)
3006 (remote_upload_trace_state_variables): Refactor as methods of
3007 remote_target.
3008 (_initialize_remote): Remove references to init_remote_ops and
3009 init_extended_remote_ops.
3010
3011 * remote-sim.c (gdbsim_target): New class.
3012 (gdbsim_fetch_register, gdbsim_store_register, gdbsim_kill)
3013 (gdbsim_load, gdbsim_create_inferior, gdbsim_open, gdbsim_close)
3014 (gdbsim_detach, gdbsim_resume, gdbsim_interrupt)
3015 (gdbsim_wait, gdbsim_prepare_to_store, gdbsim_xfer_partial)
3016 (gdbsim_files_info, gdbsim_mourn_inferior, gdbsim_thread_alive)
3017 (gdbsim_pid_to_str, gdbsim_has_all_memory, gdbsim_has_memory):
3018 Refactor as methods of gdbsim_target.
3019 (gdbsim_ops): Now a gdbsim_target.
3020 (init_gdbsim_ops): Delete.
3021 (gdbsim_cntrl_c): Adjust.
3022 (_initialize_remote_sim): Remove reference to init_gdbsim_ops.
3023
3024 * amd64-linux-nat.c (amd64_linux_nat_target): New class.
3025 (the_amd64_linux_nat_target): New.
3026 (amd64_linux_fetch_inferior_registers)
3027 (amd64_linux_store_inferior_registers): Refactor as methods of
3028 amd64_linux_nat_target.
3029 (_initialize_amd64_linux_nat): Adjust. Set linux_target.
3030 * i386-linux-nat.c: Don't include "linux-nat.h".
3031 (i386_linux_nat_target): New class.
3032 (the_i386_linux_nat_target): New.
3033 (i386_linux_fetch_inferior_registers)
3034 (i386_linux_store_inferior_registers, i386_linux_resume): Refactor
3035 as methods of i386_linux_nat_target.
3036 (_initialize_i386_linux_nat): Adjust. Set linux_target.
3037 * inf-child.c (inf_child_ops): Delete.
3038 (inf_child_fetch_inferior_registers)
3039 (inf_child_store_inferior_registers): Delete.
3040 (inf_child_post_attach, inf_child_prepare_to_store): Refactor as
3041 methods of inf_child_target.
3042 (inf_child_target::supports_terminal_ours)
3043 (inf_child_target::terminal_init)
3044 (inf_child_target::terminal_inferior)
3045 (inf_child_target::terminal_ours_for_output)
3046 (inf_child_target::terminal_ours, inf_child_target::interrupt)
3047 (inf_child_target::pass_ctrlc, inf_child_target::terminal_info):
3048 New.
3049 (inf_child_open, inf_child_disconnect, inf_child_close)
3050 (inf_child_mourn_inferior, inf_child_maybe_unpush_target)
3051 (inf_child_post_startup_inferior, inf_child_can_run)
3052 (inf_child_pid_to_exec_file): Refactor as methods of
3053 inf_child_target.
3054 (inf_child_follow_fork): Delete.
3055 (inf_child_target::can_create_inferior)
3056 (inf_child_target::can_attach): New.
3057 (inf_child_target::has_all_memory, inf_child_target::has_memory)
3058 (inf_child_target::has_stack, inf_child_target::has_registers)
3059 (inf_child_target::has_execution): New.
3060 (inf_child_fileio_open, inf_child_fileio_pwrite)
3061 (inf_child_fileio_pread, inf_child_fileio_fstat)
3062 (inf_child_fileio_close, inf_child_fileio_unlink)
3063 (inf_child_fileio_readlink, inf_child_use_agent)
3064 (inf_child_can_use_agent): Refactor as methods of
3065 inf_child_target.
3066 (return_zero, inf_child_target): Delete.
3067 (inf_child_target::inf_child_target): New.
3068 * inf-child.h: Include "target.h".
3069 (inf_child_target): Delete function prototype.
3070 (inf_child_target): New class.
3071 (inf_child_open_target, inf_child_mourn_inferior)
3072 (inf_child_maybe_unpush_target): Delete.
3073 * inf-ptrace.c (inf_ptrace_target::~inf_ptrace_target): New.
3074 (inf_ptrace_follow_fork, inf_ptrace_insert_fork_catchpoint)
3075 (inf_ptrace_remove_fork_catchpoint, inf_ptrace_create_inferior)
3076 (inf_ptrace_post_startup_inferior, inf_ptrace_mourn_inferior)
3077 (inf_ptrace_attach, inf_ptrace_post_attach, inf_ptrace_detach)
3078 (inf_ptrace_detach_success, inf_ptrace_kill, inf_ptrace_resume)
3079 (inf_ptrace_wait, inf_ptrace_xfer_partial)
3080 (inf_ptrace_thread_alive, inf_ptrace_files_info)
3081 (inf_ptrace_pid_to_str, inf_ptrace_auxv_parse): Refactor as
3082 methods of inf_ptrace_target.
3083 (inf_ptrace_target): Delete function.
3084 * inf-ptrace.h: Include "inf-child.h".
3085 (inf_ptrace_target): Delete function declaration.
3086 (inf_ptrace_target): New class.
3087 (inf_ptrace_trad_target, inf_ptrace_detach_success): Delete.
3088 * linux-nat.c (linux_target): New.
3089 (linux_ops, linux_ops_saved, super_xfer_partial): Delete.
3090 (linux_nat_target::~linux_nat_target): New.
3091 (linux_child_post_attach, linux_child_post_startup_inferior)
3092 (linux_child_follow_fork, linux_child_insert_fork_catchpoint)
3093 (linux_child_remove_fork_catchpoint)
3094 (linux_child_insert_vfork_catchpoint)
3095 (linux_child_remove_vfork_catchpoint)
3096 (linux_child_insert_exec_catchpoint)
3097 (linux_child_remove_exec_catchpoint)
3098 (linux_child_set_syscall_catchpoint, linux_nat_pass_signals)
3099 (linux_nat_create_inferior, linux_nat_attach, linux_nat_detach)
3100 (linux_nat_resume, linux_nat_stopped_by_watchpoint)
3101 (linux_nat_stopped_data_address)
3102 (linux_nat_stopped_by_sw_breakpoint)
3103 (linux_nat_supports_stopped_by_sw_breakpoint)
3104 (linux_nat_stopped_by_hw_breakpoint)
3105 (linux_nat_supports_stopped_by_hw_breakpoint, linux_nat_wait)
3106 (linux_nat_kill, linux_nat_mourn_inferior)
3107 (linux_nat_xfer_partial, linux_nat_thread_alive)
3108 (linux_nat_update_thread_list, linux_nat_pid_to_str)
3109 (linux_nat_thread_name, linux_child_pid_to_exec_file)
3110 (linux_child_static_tracepoint_markers_by_strid)
3111 (linux_nat_is_async_p, linux_nat_can_async_p)
3112 (linux_nat_supports_non_stop, linux_nat_always_non_stop_p)
3113 (linux_nat_supports_multi_process)
3114 (linux_nat_supports_disable_randomization, linux_nat_async)
3115 (linux_nat_stop, linux_nat_close, linux_nat_thread_address_space)
3116 (linux_nat_core_of_thread, linux_nat_filesystem_is_local)
3117 (linux_nat_fileio_open, linux_nat_fileio_readlink)
3118 (linux_nat_fileio_unlink, linux_nat_thread_events): Refactor as
3119 methods of linux_nat_target.
3120 (linux_nat_wait_1, linux_xfer_siginfo, linux_proc_xfer_partial)
3121 (linux_proc_xfer_spu, linux_nat_xfer_osdata): Remove target_ops
3122 parameter.
3123 (check_stopped_by_watchpoint): Adjust.
3124 (linux_xfer_partial): Delete.
3125 (linux_target_install_ops, linux_target, linux_nat_add_target):
3126 Delete.
3127 (linux_nat_target::linux_nat_target): New.
3128 * linux-nat.h: Include "inf-ptrace.h".
3129 (linux_nat_target): New.
3130 (linux_target, linux_target_install_ops, linux_nat_add_target):
3131 Delete function declarations.
3132 (linux_target): Declare global.
3133 * linux-thread-db.c (thread_db_target): New.
3134 (thread_db_target::thread_db_target): New.
3135 (thread_db_ops): Delete.
3136 (the_thread_db_target): New.
3137 (thread_db_detach, thread_db_wait, thread_db_mourn_inferior)
3138 (thread_db_update_thread_list, thread_db_pid_to_str)
3139 (thread_db_extra_thread_info)
3140 (thread_db_thread_handle_to_thread_info)
3141 (thread_db_get_thread_local_address, thread_db_get_ada_task_ptid)
3142 (thread_db_resume): Refactor as methods of thread_db_target.
3143 (init_thread_db_ops): Delete.
3144 (_initialize_thread_db): Remove reference to init_thread_db_ops.
3145 * x86-linux-nat.c: Don't include "linux-nat.h".
3146 (super_post_startup_inferior): Delete.
3147 (x86_linux_nat_target::~x86_linux_nat_target): New.
3148 (x86_linux_child_post_startup_inferior)
3149 (x86_linux_read_description, x86_linux_enable_btrace)
3150 (x86_linux_disable_btrace, x86_linux_teardown_btrace)
3151 (x86_linux_read_btrace, x86_linux_btrace_conf): Refactor as
3152 methods of x86_linux_nat_target.
3153 (x86_linux_create_target): Delete. Bits folded ...
3154 (x86_linux_add_target): ... here. Now takes a linux_nat_target
3155 pointer.
3156 * x86-linux-nat.h: Include "linux-nat.h" and "x86-nat.h".
3157 (x86_linux_nat_target): New class.
3158 (x86_linux_create_target): Delete.
3159 (x86_linux_add_target): Now takes a linux_nat_target pointer.
3160 * x86-nat.c (x86_insert_watchpoint, x86_remove_watchpoint)
3161 (x86_region_ok_for_watchpoint, x86_stopped_data_address)
3162 (x86_stopped_by_watchpoint, x86_insert_hw_breakpoint)
3163 (x86_remove_hw_breakpoint, x86_can_use_hw_breakpoint)
3164 (x86_stopped_by_hw_breakpoint): Remove target_ops parameter and
3165 make extern.
3166 (x86_use_watchpoints): Delete.
3167 * x86-nat.h: Include "breakpoint.h" and "target.h".
3168 (x86_use_watchpoints): Delete.
3169 (x86_can_use_hw_breakpoint, x86_region_ok_for_hw_watchpoint)
3170 (x86_stopped_by_watchpoint, x86_stopped_data_address)
3171 (x86_insert_watchpoint, x86_remove_watchpoint)
3172 (x86_insert_hw_breakpoint, x86_remove_hw_breakpoint)
3173 (x86_stopped_by_hw_breakpoint): New declarations.
3174 (x86_nat_target): New template class.
3175
3176 * ppc-linux-nat.c (ppc_linux_nat_target): New class.
3177 (the_ppc_linux_nat_target): New.
3178 (ppc_linux_fetch_inferior_registers)
3179 (ppc_linux_can_use_hw_breakpoint)
3180 (ppc_linux_region_ok_for_hw_watchpoint)
3181 (ppc_linux_ranged_break_num_registers)
3182 (ppc_linux_insert_hw_breakpoint, ppc_linux_remove_hw_breakpoint)
3183 (ppc_linux_insert_mask_watchpoint)
3184 (ppc_linux_remove_mask_watchpoint)
3185 (ppc_linux_can_accel_watchpoint_condition)
3186 (ppc_linux_insert_watchpoint, ppc_linux_remove_watchpoint)
3187 (ppc_linux_stopped_data_address, ppc_linux_stopped_by_watchpoint)
3188 (ppc_linux_watchpoint_addr_within_range)
3189 (ppc_linux_masked_watch_num_registers)
3190 (ppc_linux_store_inferior_registers, ppc_linux_auxv_parse)
3191 (ppc_linux_read_description): Refactor as methods of
3192 ppc_linux_nat_target.
3193 (_initialize_ppc_linux_nat): Adjust. Set linux_target.
3194
3195 * procfs.c (procfs_xfer_partial): Delete forward declaration.
3196 (procfs_target): New class.
3197 (the_procfs_target): New.
3198 (procfs_target): Delete function.
3199 (procfs_auxv_parse, procfs_attach, procfs_detach)
3200 (procfs_fetch_registers, procfs_store_registers, procfs_wait)
3201 (procfs_xfer_partial, procfs_resume, procfs_pass_signals)
3202 (procfs_files_info, procfs_kill_inferior, procfs_mourn_inferior)
3203 (procfs_create_inferior, procfs_update_thread_list)
3204 (procfs_thread_alive, procfs_pid_to_str)
3205 (procfs_can_use_hw_breakpoint, procfs_stopped_by_watchpoint)
3206 (procfs_stopped_data_address, procfs_insert_watchpoint)
3207 (procfs_remove_watchpoint, procfs_region_ok_for_hw_watchpoint)
3208 (proc_find_memory_regions, procfs_info_proc)
3209 (procfs_make_note_section): Refactor as methods of procfs_target.
3210 (_initialize_procfs): Adjust.
3211 * sol-thread.c (sol_thread_target): New class.
3212 (sol_thread_ops): Now a sol_thread_target.
3213 (sol_thread_detach, sol_thread_resume, sol_thread_wait)
3214 (sol_thread_fetch_registers, sol_thread_store_registers)
3215 (sol_thread_xfer_partial, sol_thread_mourn_inferior)
3216 (sol_thread_alive, solaris_pid_to_str, sol_update_thread_list)
3217 (sol_get_ada_task_ptid): Refactor as methods of sol_thread_target.
3218 (init_sol_thread_ops): Delete.
3219 (_initialize_sol_thread): Adjust. Remove references to
3220 init_sol_thread_ops and complete_target_initialization.
3221
3222 * windows-nat.c (windows_nat_target): New class.
3223 (windows_fetch_inferior_registers)
3224 (windows_store_inferior_registers, windows_resume, windows_wait)
3225 (windows_attach, windows_detach, windows_pid_to_exec_file)
3226 (windows_files_info, windows_create_inferior)
3227 (windows_mourn_inferior, windows_interrupt, windows_kill_inferior)
3228 (windows_close, windows_pid_to_str, windows_xfer_partial)
3229 (windows_get_tib_address, windows_get_ada_task_ptid)
3230 (windows_thread_name, windows_thread_alive): Refactor as
3231 windows_nat_target methods.
3232 (do_initial_windows_stuff): Adjust.
3233 (windows_target): Delete function.
3234 (_initialize_windows_nat): Adjust.
3235
3236 * darwin-nat.c (darwin_resume, darwin_wait_to, darwin_interrupt)
3237 (darwin_mourn_inferior, darwin_kill_inferior)
3238 (darwin_create_inferior, darwin_attach, darwin_detach)
3239 (darwin_pid_to_str, darwin_thread_alive, darwin_xfer_partial)
3240 (darwin_pid_to_exec_file, darwin_get_ada_task_ptid)
3241 (darwin_supports_multi_process): Refactor as darwin_nat_target
3242 methods.
3243 (darwin_resume_to, darwin_files_info): Delete.
3244 (_initialize_darwin_inferior): Rename to ...
3245 (_initialize_darwin_nat): ... this. Adjust to C++ification.
3246 * darwin-nat.h: Include "inf-child.h".
3247 (darwin_nat_target): New class.
3248 (darwin_complete_target): Delete.
3249 * i386-darwin-nat.c (i386_darwin_nat_target): New class.
3250 (darwin_target): New.
3251 (i386_darwin_fetch_inferior_registers)
3252 (i386_darwin_store_inferior_registers): Refactor as methods of
3253 darwin_nat_target.
3254 (darwin_complete_target): Delete, with ...
3255 (_initialize_i386_darwin_nat): ... bits factored out here.
3256
3257 * alpha-linux-nat.c (alpha_linux_nat_target): New class.
3258 (the_alpha_linux_nat_target): New.
3259 (alpha_linux_register_u_offset): Refactor as
3260 alpha_linux_nat_target method.
3261 (_initialize_alpha_linux_nat): Adjust.
3262 * linux-nat-trad.c (inf_ptrace_register_u_offset): Delete.
3263 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
3264 (inf_ptrace_store_register, inf_ptrace_store_registers): Refact as
3265 methods of linux_nat_trad_target.
3266 (linux_trad_target): Delete.
3267 * linux-nat-trad.h (linux_trad_target): Delete function.
3268 (linux_nat_trad_target): New class.
3269 * mips-linux-nat.c (mips_linux_nat_target): New class.
3270 (super_fetch_registers, super_store_registers, super_close):
3271 Delete.
3272 (the_mips_linux_nat_target): New.
3273 (mips64_linux_regsets_fetch_registers)
3274 (mips64_linux_regsets_store_registers)
3275 (mips64_linux_fetch_registers, mips64_linux_store_registers)
3276 (mips_linux_register_u_offset, mips_linux_read_description)
3277 (mips_linux_can_use_hw_breakpoint)
3278 (mips_linux_stopped_by_watchpoint)
3279 (mips_linux_stopped_data_address)
3280 (mips_linux_region_ok_for_hw_watchpoint)
3281 (mips_linux_insert_watchpoint, mips_linux_remove_watchpoint)
3282 (mips_linux_close): Refactor as methods of mips_linux_nat.
3283 (_initialize_mips_linux_nat): Adjust to C++ification.
3284
3285 * aix-thread.c (aix_thread_target): New class.
3286 (aix_thread_ops): Now an aix_thread_target.
3287 (aix_thread_detach, aix_thread_resume, aix_thread_wait)
3288 (aix_thread_fetch_registers, aix_thread_store_registers)
3289 (aix_thread_xfer_partial, aix_thread_mourn_inferior)
3290 (aix_thread_thread_alive, aix_thread_pid_to_str)
3291 (aix_thread_extra_thread_info, aix_thread_get_ada_task_ptid):
3292 Refactor as methods of aix_thread_target.
3293 (init_aix_thread_ops): Delete.
3294 (_initialize_aix_thread): Remove references to init_aix_thread_ops
3295 and complete_target_initialization.
3296 * rs6000-nat.c (rs6000_xfer_shared_libraries): Delete.
3297 (rs6000_nat_target): New class.
3298 (the_rs6000_nat_target): New.
3299 (rs6000_fetch_inferior_registers, rs6000_store_inferior_registers)
3300 (rs6000_xfer_partial, rs6000_wait, rs6000_create_inferior)
3301 (rs6000_xfer_shared_libraries): Refactor as rs6000_nat_target methods.
3302 (super_create_inferior): Delete.
3303 (_initialize_rs6000_nat): Adjust to C++ification.
3304
3305 * arm-linux-nat.c (arm_linux_nat_target): New class.
3306 (the_arm_linux_nat_target): New.
3307 (arm_linux_fetch_inferior_registers)
3308 (arm_linux_store_inferior_registers, arm_linux_read_description)
3309 (arm_linux_can_use_hw_breakpoint, arm_linux_insert_hw_breakpoint)
3310 (arm_linux_remove_hw_breakpoint)
3311 (arm_linux_region_ok_for_hw_watchpoint)
3312 (arm_linux_insert_watchpoint, arm_linux_remove_watchpoint)
3313 (arm_linux_stopped_data_address, arm_linux_stopped_by_watchpoint)
3314 (arm_linux_watchpoint_addr_within_range): Refactor as methods of
3315 arm_linux_nat_target.
3316 (_initialize_arm_linux_nat): Adjust to C++ification.
3317
3318 * aarch64-linux-nat.c (aarch64_linux_nat_target): New class.
3319 (the_aarch64_linux_nat_target): New.
3320 (aarch64_linux_fetch_inferior_registers)
3321 (aarch64_linux_store_inferior_registers)
3322 (aarch64_linux_child_post_startup_inferior)
3323 (aarch64_linux_read_description)
3324 (aarch64_linux_can_use_hw_breakpoint)
3325 (aarch64_linux_insert_hw_breakpoint)
3326 (aarch64_linux_remove_hw_breakpoint)
3327 (aarch64_linux_insert_watchpoint, aarch64_linux_remove_watchpoint)
3328 (aarch64_linux_region_ok_for_hw_watchpoint)
3329 (aarch64_linux_stopped_data_address)
3330 (aarch64_linux_stopped_by_watchpoint)
3331 (aarch64_linux_watchpoint_addr_within_range)
3332 (aarch64_linux_can_do_single_step): Refactor as methods of
3333 aarch64_linux_nat_target.
3334 (super_post_startup_inferior): Delete.
3335 (_initialize_aarch64_linux_nat): Adjust to C++ification.
3336
3337 * hppa-linux-nat.c (hppa_linux_nat_target): New class.
3338 (the_hppa_linux_nat_target): New.
3339 (hppa_linux_fetch_inferior_registers)
3340 (hppa_linux_store_inferior_registers): Refactor as methods of
3341 hppa_linux_nat_target.
3342 (_initialize_hppa_linux_nat): Adjust to C++ification.
3343
3344 * ia64-linux-nat.c (ia64_linux_nat_target): New class.
3345 (the_ia64_linux_nat_target): New.
3346 (ia64_linux_insert_watchpoint, ia64_linux_remove_watchpoint)
3347 (ia64_linux_stopped_data_address)
3348 (ia64_linux_stopped_by_watchpoint, ia64_linux_fetch_registers)
3349 (ia64_linux_store_registers, ia64_linux_xfer_partial): Refactor as
3350 ia64_linux_nat_target methods.
3351 (super_xfer_partial): Delete.
3352 (_initialize_ia64_linux_nat): Adjust to C++ification.
3353
3354 * m32r-linux-nat.c (m32r_linux_nat_target): New class.
3355 (the_m32r_linux_nat_target): New.
3356 (m32r_linux_fetch_inferior_registers)
3357 (m32r_linux_store_inferior_registers): Refactor as
3358 m32r_linux_nat_target methods.
3359 (_initialize_m32r_linux_nat): Adjust to C++ification.
3360
3361 * m68k-linux-nat.c (m68k_linux_nat_target): New class.
3362 (the_m68k_linux_nat_target): New.
3363 (m68k_linux_fetch_inferior_registers)
3364 (m68k_linux_store_inferior_registers): Refactor as
3365 m68k_linux_nat_target methods.
3366 (_initialize_m68k_linux_nat): Adjust to C++ification.
3367
3368 * s390-linux-nat.c (s390_linux_nat_target): New class.
3369 (the_s390_linux_nat_target): New.
3370 (s390_linux_fetch_inferior_registers)
3371 (s390_linux_store_inferior_registers, s390_stopped_by_watchpoint)
3372 (s390_insert_watchpoint, s390_remove_watchpoint)
3373 (s390_can_use_hw_breakpoint, s390_insert_hw_breakpoint)
3374 (s390_remove_hw_breakpoint, s390_region_ok_for_hw_watchpoint)
3375 (s390_auxv_parse, s390_read_description): Refactor as methods of
3376 s390_linux_nat_target.
3377 (_initialize_s390_nat): Adjust to C++ification.
3378
3379 * sparc-linux-nat.c (sparc_linux_nat_target): New class.
3380 (the_sparc_linux_nat_target): New.
3381 (_initialize_sparc_linux_nat): Adjust to C++ification.
3382 * sparc-nat.c (sparc_fetch_inferior_registers)
3383 (sparc_store_inferior_registers): Remove target_ops parameter.
3384 * sparc-nat.h (sparc_fetch_inferior_registers)
3385 (sparc_store_inferior_registers): Remove target_ops parameter.
3386 * sparc64-linux-nat.c (sparc64_linux_nat_target): New class.
3387 (the_sparc64_linux_nat_target): New.
3388 (_initialize_sparc64_linux_nat): Adjust to C++ification.
3389
3390 * spu-linux-nat.c (spu_linux_nat_target): New class.
3391 (the_spu_linux_nat_target): New.
3392 (spu_child_post_startup_inferior, spu_child_post_attach)
3393 (spu_child_wait, spu_fetch_inferior_registers)
3394 (spu_store_inferior_registers, spu_xfer_partial)
3395 (spu_can_use_hw_breakpoint): Refactor as spu_linux_nat_target
3396 methods.
3397 (_initialize_spu_nat): Adjust to C++ification.
3398
3399 * tilegx-linux-nat.c (tilegx_linux_nat_target): New class.
3400 (the_tilegx_linux_nat_target): New.
3401 (fetch_inferior_registers, store_inferior_registers):
3402 Refactor as methods.
3403 (_initialize_tile_linux_nat): Adjust to C++ification.
3404
3405 * xtensa-linux-nat.c (xtensa_linux_nat_target): New class.
3406 (the_xtensa_linux_nat_target): New.
3407 (xtensa_linux_fetch_inferior_registers)
3408 (xtensa_linux_store_inferior_registers): Refactor as
3409 xtensa_linux_nat_target methods.
3410 (_initialize_xtensa_linux_nat): Adjust to C++ification.
3411
3412 * fbsd-nat.c (USE_SIGTRAP_SIGINFO): Delete.
3413 (fbsd_pid_to_exec_file, fbsd_find_memory_regions)
3414 (fbsd_find_memory_regions, fbsd_info_proc, fbsd_xfer_partial)
3415 (fbsd_thread_alive, fbsd_pid_to_str, fbsd_thread_name)
3416 (fbsd_update_thread_list, fbsd_resume, fbsd_wait)
3417 (fbsd_stopped_by_sw_breakpoint)
3418 (fbsd_supports_stopped_by_sw_breakpoint, fbsd_follow_fork)
3419 (fbsd_insert_fork_catchpoint, fbsd_remove_fork_catchpoint)
3420 (fbsd_insert_vfork_catchpoint, fbsd_remove_vfork_catchpoint)
3421 (fbsd_post_startup_inferior, fbsd_post_attach)
3422 (fbsd_insert_exec_catchpoint, fbsd_remove_exec_catchpoint)
3423 (fbsd_set_syscall_catchpoint)
3424 (super_xfer_partial, super_resume, super_wait)
3425 (fbsd_supports_stopped_by_hw_breakpoint): Delete.
3426 (fbsd_handle_debug_trap): Remove target_ops parameter.
3427 (fbsd_nat_add_target): Delete.
3428 * fbsd-nat.h: Include "inf-ptrace.h".
3429 (fbsd_nat_add_target): Delete.
3430 (USE_SIGTRAP_SIGINFO): Define.
3431 (fbsd_nat_target): New class.
3432
3433 * amd64-bsd-nat.c (amd64bsd_fetch_inferior_registers)
3434 (amd64bsd_store_inferior_registers): Remove target_ops parameter.
3435 (amd64bsd_target): Delete.
3436 * amd64-bsd-nat.h: New file.
3437 * amd64-fbsd-nat.c: Include "amd64-bsd-nat.h" instead of
3438 "x86-bsd-nat.h".
3439 (amd64_fbsd_nat_target): New class.
3440 (the_amd64_fbsd_nat_target): New.
3441 (amd64fbsd_read_description): Refactor as method of
3442 amd64_fbsd_nat_target.
3443 (amd64_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
3444 (_initialize_amd64fbsd_nat): Adjust to C++ification.
3445 * amd64-nat.h (amd64bsd_target): Delete function declaration.
3446 * i386-bsd-nat.c (i386bsd_fetch_inferior_registers)
3447 (i386bsd_store_inferior_registers): Remove target_ops parameter.
3448 (i386bsd_target): Delete.
3449 * i386-bsd-nat.h (i386bsd_target): Delete function declaration.
3450 (i386bsd_fetch_inferior_registers)
3451 (i386bsd_store_inferior_registers): Declare.
3452 (i386_bsd_nat_target): New class.
3453 * i386-fbsd-nat.c (i386_fbsd_nat_target): New class.
3454 (the_i386_fbsd_nat_target): New.
3455 (i386fbsd_resume, i386fbsd_read_description): Refactor as
3456 i386_fbsd_nat_target methods.
3457 (i386_fbsd_nat_target::supports_stopped_by_hw_breakpoint): New.
3458 (_initialize_i386fbsd_nat): Adjust to C++ification.
3459 * x86-bsd-nat.c (super_mourn_inferior): Delete.
3460 (x86bsd_mourn_inferior, x86bsd_target): Delete.
3461 (_initialize_x86_bsd_nat): Adjust to C++ification.
3462 * x86-bsd-nat.h: Include "x86-nat.h".
3463 (x86bsd_target): Delete declaration.
3464 (x86bsd_nat_target): New class.
3465
3466 * aarch64-fbsd-nat.c (aarch64_fbsd_nat_target): New class.
3467 (the_aarch64_fbsd_nat_target): New.
3468 (aarch64_fbsd_fetch_inferior_registers)
3469 (aarch64_fbsd_store_inferior_registers): Refactor as methods of
3470 aarch64_fbsd_nat_target.
3471 (_initialize_aarch64_fbsd_nat): Adjust to C++ification.
3472 * alpha-bsd-nat.c (alpha_bsd_nat_target): New class.
3473 (the_alpha_bsd_nat_target): New.
3474 (alphabsd_fetch_inferior_registers)
3475 (alphabsd_store_inferior_registers): Refactor as
3476 alpha_bsd_nat_target methods.
3477 (_initialize_alphabsd_nat): Refactor as methods of
3478 alpha_bsd_nat_target.
3479 * amd64-nbsd-nat.c: Include "amd64-bsd-nat.h".
3480 (the_amd64_nbsd_nat_target): New.
3481 (_initialize_amd64nbsd_nat): Adjust to C++ification.
3482 * amd64-obsd-nat.c: Include "amd64-bsd-nat.h".
3483 (the_amd64_obsd_nat_target): New.
3484 (_initialize_amd64obsd_nat): Adjust to C++ification.
3485 * arm-fbsd-nat.c (arm_fbsd_nat_target): New.
3486 (the_arm_fbsd_nat_target): New.
3487 (arm_fbsd_fetch_inferior_registers)
3488 (arm_fbsd_store_inferior_registers, arm_fbsd_read_description):
3489 (_initialize_arm_fbsd_nat): Refactor as methods of
3490 arm_fbsd_nat_target.
3491 (_initialize_arm_fbsd_nat): Adjust to C++ification.
3492 * arm-nbsd-nat.c (arm_netbsd_nat_target): New class.
3493 (the_arm_netbsd_nat_target): New.
3494 (armnbsd_fetch_registers, armnbsd_store_registers): Refactor as
3495 arm_netbsd_nat_target.
3496 (_initialize_arm_netbsd_nat): Adjust to C++ification.
3497 * hppa-nbsd-nat.c (hppa_nbsd_nat_target): New class.
3498 (the_hppa_nbsd_nat_target): New.
3499 (hppanbsd_fetch_registers, hppanbsd_store_registers): Refactor as
3500 hppa_nbsd_nat_target methods.
3501 (_initialize_hppanbsd_nat): Adjust to C++ification.
3502 * hppa-obsd-nat.c (hppa_obsd_nat_target): New class.
3503 (the_hppa_obsd_nat_target): New.
3504 (hppaobsd_fetch_registers, hppaobsd_store_registers): Refactor as
3505 methods of hppa_obsd_nat_target.
3506 (_initialize_hppaobsd_nat): Adjust to C++ification. Use
3507 add_target.
3508 * i386-nbsd-nat.c (the_i386_nbsd_nat_target): New.
3509 (_initialize_i386nbsd_nat): Adjust to C++ification. Use
3510 add_target.
3511 * i386-obsd-nat.c (the_i386_obsd_nat_target): New.
3512 (_initialize_i386obsd_nat): Use add_target.
3513 * m68k-bsd-nat.c (m68k_bsd_nat_target): New class.
3514 (the_m68k_bsd_nat_target): New.
3515 (m68kbsd_fetch_inferior_registers)
3516 (m68kbsd_store_inferior_registers): Refactor as methods of
3517 m68k_bsd_nat_target.
3518 (_initialize_m68kbsd_nat): Adjust to C++ification.
3519 * mips-fbsd-nat.c (mips_fbsd_nat_target): New class.
3520 (the_mips_fbsd_nat_target): New.
3521 (mips_fbsd_fetch_inferior_registers)
3522 (mips_fbsd_store_inferior_registers): Refactor as methods of
3523 mips_fbsd_nat_target.
3524 (_initialize_mips_fbsd_nat): Adjust to C++ification. Use
3525 add_target.
3526 * mips-nbsd-nat.c (mips_nbsd_nat_target): New class.
3527 (the_mips_nbsd_nat_target): New.
3528 (mipsnbsd_fetch_inferior_registers)
3529 (mipsnbsd_store_inferior_registers): Refactor as methods of
3530 mips_nbsd_nat_target.
3531 (_initialize_mipsnbsd_nat): Adjust to C++ification.
3532 * mips64-obsd-nat.c (mips64_obsd_nat_target): New class.
3533 (the_mips64_obsd_nat_target): New.
3534 (mips64obsd_fetch_inferior_registers)
3535 (mips64obsd_store_inferior_registers): Refactor as methods of
3536 mips64_obsd_nat_target.
3537 (_initialize_mips64obsd_nat): Adjust to C++ification. Use
3538 add_target.
3539 * nbsd-nat.c (nbsd_pid_to_exec_file): Refactor as method of
3540 nbsd_nat_target.
3541 * nbsd-nat.h: Include "inf-ptrace.h".
3542 (nbsd_nat_target): New class.
3543 * obsd-nat.c (obsd_pid_to_str, obsd_update_thread_list)
3544 (obsd_wait): Refactor as methods of obsd_nat_target.
3545 (obsd_add_target): Delete.
3546 * obsd-nat.h: Include "inf-ptrace.h".
3547 (obsd_nat_target): New class.
3548 * ppc-fbsd-nat.c (ppc_fbsd_nat_target): New class.
3549 (the_ppc_fbsd_nat_target): New.
3550 (ppcfbsd_fetch_inferior_registers)
3551 (ppcfbsd_store_inferior_registers): Refactor as methods of
3552 ppc_fbsd_nat_target.
3553 (_initialize_ppcfbsd_nat): Adjust to C++ification. Use
3554 add_target.
3555 * ppc-nbsd-nat.c (ppc_nbsd_nat_target): New class.
3556 (the_ppc_nbsd_nat_target): New.
3557 (ppcnbsd_fetch_inferior_registers)
3558 (ppcnbsd_store_inferior_registers): Refactor as methods of
3559 ppc_nbsd_nat_target.
3560 (_initialize_ppcnbsd_nat): Adjust to C++ification.
3561 * ppc-obsd-nat.c (ppc_obsd_nat_target): New class.
3562 (the_ppc_obsd_nat_target): New.
3563 (ppcobsd_fetch_registers, ppcobsd_store_registers): Refactor as
3564 methods of ppc_obsd_nat_target.
3565 (_initialize_ppcobsd_nat): Adjust to C++ification. Use
3566 add_target.
3567 * sh-nbsd-nat.c (sh_nbsd_nat_target): New class.
3568 (the_sh_nbsd_nat_target): New.
3569 (shnbsd_fetch_inferior_registers)
3570 (shnbsd_store_inferior_registers): Refactor as methods of
3571 sh_nbsd_nat_target.
3572 (_initialize_shnbsd_nat): Adjust to C++ification.
3573 * sparc-nat.c (sparc_xfer_wcookie): Make extern.
3574 (inf_ptrace_xfer_partial): Delete.
3575 (sparc_xfer_partial, sparc_target): Delete.
3576 * sparc-nat.h (sparc_fetch_inferior_registers)
3577 (sparc_store_inferior_registers, sparc_xfer_wcookie): Declare.
3578 (sparc_target): Delete function declaration.
3579 (sparc_target): New template class.
3580 * sparc-nbsd-nat.c (the_sparc_nbsd_nat_target): New.
3581 (_initialize_sparcnbsd_nat): Adjust to C++ification.
3582 * sparc64-fbsd-nat.c (the_sparc64_fbsd_nat_target): New.
3583 (_initialize_sparc64fbsd_nat): Adjust to C++ification. Use
3584 add_target.
3585 * sparc64-nbsd-nat.c (the_sparc64_nbsd_nat_target): New.
3586 (_initialize_sparc64nbsd_nat): Adjust to C++ification.
3587 * sparc64-obsd-nat.c (the_sparc64_obsd_nat_target): New.
3588 (_initialize_sparc64obsd_nat): Adjust to C++ification. Use
3589 add_target.
3590 * vax-bsd-nat.c (vax_bsd_nat_target): New class.
3591 (the_vax_bsd_nat_target): New.
3592 (vaxbsd_fetch_inferior_registers)
3593 (vaxbsd_store_inferior_registers): Refactor as vax_bsd_nat_target
3594 methods.
3595 (_initialize_vaxbsd_nat): Adjust to C++ification.
3596
3597 * bsd-kvm.c (bsd_kvm_target): New class.
3598 (bsd_kvm_ops): Now a bsd_kvm_target.
3599 (bsd_kvm_open, bsd_kvm_close, bsd_kvm_xfer_partial)
3600 (bsd_kvm_files_info, bsd_kvm_fetch_registers)
3601 (bsd_kvm_thread_alive, bsd_kvm_pid_to_str): Refactor as methods of
3602 bsd_kvm_target.
3603 (bsd_kvm_return_one): Delete.
3604 (bsd_kvm_add_target): Adjust to C++ification.
3605
3606 * nto-procfs.c (nto_procfs_target, nto_procfs_target_native)
3607 (nto_procfs_target_procfs): New classes.
3608 (procfs_open_1, procfs_thread_alive, procfs_update_thread_list)
3609 (procfs_files_info, procfs_pid_to_exec_file, procfs_attach)
3610 (procfs_post_attach, procfs_wait, procfs_fetch_registers)
3611 (procfs_xfer_partial, procfs_detach, procfs_insert_breakpoint)
3612 (procfs_remove_breakpoint, procfs_insert_hw_breakpoint)
3613 (procfs_remove_hw_breakpoint, procfs_resume)
3614 (procfs_mourn_inferior, procfs_create_inferior, procfs_interrupt)
3615 (procfs_kill_inferior, procfs_store_registers)
3616 (procfs_pass_signals, procfs_pid_to_str, procfs_can_run): Refactor
3617 as methods of nto_procfs_target.
3618 (nto_procfs_ops): Now an nto_procfs_target_procfs.
3619 (nto_native_ops): Delete.
3620 (procfs_open, procfs_native_open): Delete.
3621 (nto_native_ops): Now an nto_procfs_target_native.
3622 (init_procfs_targets): Adjust to C++ification.
3623 (procfs_can_use_hw_breakpoint, procfs_remove_hw_watchpoint)
3624 (procfs_insert_hw_watchpoint, procfs_stopped_by_watchpoint):
3625 Refactor as methods of nto_procfs_target.
3626
3627 * go32-nat.c (go32_nat_target): New class.
3628 (the_go32_nat_target): New.
3629 (go32_attach, go32_resume, go32_wait, go32_fetch_registers)
3630 (go32_store_registers, go32_xfer_partial, go32_files_info)
3631 (go32_kill_inferior, go32_create_inferior, go32_mourn_inferior)
3632 (go32_terminal_init, go32_terminal_info, go32_terminal_inferior)
3633 (go32_terminal_ours, go32_pass_ctrlc, go32_thread_alive)
3634 (go32_pid_to_str): Refactor as methods of go32_nat_target.
3635 (go32_target): Delete.
3636 (_initialize_go32_nat): Adjust to C++ification.
3637
3638 * gnu-nat.c (gnu_wait, gnu_resume, gnu_kill_inferior)
3639 (gnu_mourn_inferior, gnu_create_inferior, gnu_attach, gnu_detach)
3640 (gnu_stop, gnu_thread_alive, gnu_xfer_partial)
3641 (gnu_find_memory_regions, gnu_pid_to_str): Refactor as methods of
3642 gnu_nat_target.
3643 (gnu_target): Delete.
3644 * gnu-nat.h (gnu_target): Delete.
3645 (gnu_nat_target): New class.
3646 * i386-gnu-nat.c (gnu_base_target): New.
3647 (i386_gnu_nat_target): New class.
3648 (the_i386_gnu_nat_target): New.
3649 (_initialize_i386gnu_nat): Adjust to C++ification.
3650
3fffc070
PA
36512018-05-02 Pedro Alves <palves@redhat.com>
3652
3653 * bfd-target.c (target_bfd_xclose): Rename to ...
3654 (target_bfd_close): ... this.
3655 (target_bfd_reopen): Adjust.
3656 * target.c (target_close): Remove references to to_xclose.
3657 * target.h (target_ops::to_xclose): Delete.
3658 (target_ops::to_close): Update comments.
3659
6798487f
PA
36602018-05-02 Pedro Alves <palves@redhat.com>
3661
3662 * alpha-linux-nat.c: Include "linux-nat-trad.h" instead of
3663 "linux-nat.h".
3664 * configure.nat (alpha-linux, linux-mips): Add linux-nat-trad.o.
3665 * inf-ptrace.c (inf_ptrace_register_u_offset)
3666 (inf_ptrace_fetch_register, inf_ptrace_fetch_registers)
3667 (inf_ptrace_store_register, inf_ptrace_store_registers)
3668 (inf_ptrace_trad_target): Move to ...
3669 * linux-nat-trad.c: ... this new file.
3670 * linux-nat-trad.h: New file.
3671 * linux-nat.c (linux_target_install_ops): Make extern.
3672 (linux_trad_target): Delete.
3673 * linux-nat.h (linux_trad_target): Delete declaration.
3674 (linux_target_install_ops): Declare.
3675 * mips-linux-nat.c: Include "linux-nat-trad.h" instead of
3676 "linux-nat.h".
3677
c1955e17
PA
36782018-05-02 Pedro Alves <palves@redhat.com>
3679
3680 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
3681 procfs_target/add_target here.
3682 * procfs.c (procfs_target): Make static.
3683 (_initialize_procfs): Call add_target here.
3684 * procfs.h (struct target_ops): Remove forward declaration.
3685 (procfs_target): Remove declaration.
3686 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Delete.
3687
b5c8fcb1
PA
36882018-05-02 Pedro Alves <palves@redhat.com>
3689
3690 * procfs.c (procfs_stopped_by_watchpoint)
3691 (procfs_insert_watchpoint, procfs_remove_watchpoint)
3692 (procfs_region_ok_for_hw_watchpoint, procfs_stopped_data_address):
3693 Forward declare.
3694 (procfs_use_watchpoints): Delete, move contents...
3695 (procfs_target): ... here.
3696 * procfs.h (procfs_use_watchpoints): Delete declaration.
3697 * i386-sol2-nat.c (_initialize_amd64_sol2_nat): Don't call
3698 procfs_use_watchpoints.
3699 * sparc-sol2-nat.c (_initialize_sparc_sol2_nat): Don't call
3700 procfs_use_watchpoints.
3701
0489430a
TT
37022018-05-02 Tom Tromey <tom@tromey.com>
3703
3704 PR python/20084:
3705 * python/python.c (gdbpy_parameter_value): Handle var_zuinteger
3706 and var_zuinteger_unlimited.
3707 * python/py-param.c (struct parm_constant): Add PARAM_ZUINTEGER
3708 and PARAM_ZUINTEGER_UNLIMITED.
3709 (set_parameter_value): Handle var_zuinteger and
3710 var_zuinteger_unlimited.
3711 (add_setshow_generic): Likewise.
3712 (parmpy_init): Likewise.
3713
1632f8ba
DR
37142018-04-28 Dan Robertson <danlrobertson89@gmail.com>
3715
3716 PR rust/23124
3717 * gdb/rust-exp.y (convert_params_to_types): Ensure that the params
3718 pointer is not null before dereferencing it.
3719
76761936
TT
37202018-04-30 Tom Tromey <tom@tromey.com>
3721
3722 * darwin-nat-info.c (darwin_debug_regions_recurse): Remove use of
3723 is_mi_like_p.
3724
2d33446d
TT
37252018-04-30 Tom Tromey <tom@tromey.com>
3726
3727 * breakpoint.c (mention): Remove use of is_mi_like_p.
3728 (print_mention_ranged_breakpoint): Likewise.
3729 * break-catch-throw.c (print_it_exception_catchpoint): Remove use
3730 of is_mi_like_p.
3731
f3c6abab
TT
37322018-04-30 Tom Tromey <tom@tromey.com>
3733
3734 * tracepoint.c (tvariables_info_1): Remove use of is_mi_like_p.
3735
40c03530
TT
37362018-04-30 Tom Tromey <tom@tromey.com>
3737
3738 * spu-tdep.c (info_spu_mailbox_list, info_spu_dma_cmdlist)
3739 (info_spu_event_command): Remove some uses of is_mi_like_p.
3740
2038b7fd
TT
37412018-04-30 Tom Tromey <tom@tromey.com>
3742
3743 * python/py-framefilter.c (py_print_single_arg)
3744 (enumerate_locals, py_print_args, py_print_frame): Remove some
3745 uses of is_mi_like_p.
3746
4904c3c6
TT
37472018-04-30 Tom Tromey <tom@tromey.com>
3748
3749 * ui-out.c: Update.
3750 * cli-out.h (cli_ui_out::do_is_mi_like_p): Update.
3751 * ui-out.h (ui_out::is_mi_like_p): Now const.
3752 (ui_out::do_is_mi_like_p): Now const.
3753 * mi/mi-out.h (mi_ui_out::do_is_mi_like_p): Update.
3754
7c66fffc
TT
37552018-04-30 Tom Tromey <tom@tromey.com>
3756
3757 * varobj.c (varobj_set_visualizer): Use new_reference.
3758 * python/python.c (gdbpy_decode_line): Use new_reference.
3759 * python/py-cmd.c (cmdpy_function, cmdpy_completer_helper): Use
3760 new_reference.
3761
bbfa6f00
TT
37622018-04-30 Tom Tromey <tom@tromey.com>
3763
3764 * varobj.c (install_new_value): Use new_reference.
3765 * value.h (value_incref): Return void. Swap intro comment with
3766 value_decref.
3767 * value.c (set_value_parent): Use new_reference.
3768 (value_incref): Return void. Update intro comment.
3769 (release_value): Use new_reference.
3770 * dwarf2loc.c (dwarf2_evaluate_loc_desc_full): Use new_reference.
3771
1831a9f9
TT
37722018-04-30 Tom Tromey <tom@tromey.com>
3773
3774 * symfile-mem.c (symbol_file_add_from_memory): Use new_reference.
3775 * gdb_bfd.h (new_bfd_ref): Remove.
3776 (gdb_bfd_open): Update comment.
3777 * gdb_bfd.c (gdb_bfd_open, gdb_bfd_fopen, gdb_bfd_openr)
3778 (gdb_bfd_openw, gdb_bfd_openr_iovec, gdb_bfd_record_inclusion)
3779 (gdb_bfd_fdopenr): Use new_reference.
3780 * exec.c (exec_file_attach): Use new_reference.
3781
7c1b5f3d
TT
37822018-04-30 Tom Tromey <tom@tromey.com>
3783
3784 * common/gdb_ref_ptr.h (ref_ptr::new_reference): New static
3785 method.
3786
e11fb955
TT
37872018-04-30 Tom Tromey <tom@tromey.com>
3788
3789 * jit.c (jit_read_code_entry): Use type_align.
3790 * i386-tdep.c (i386_gdbarch_init): Don't call
3791 set_gdbarch_long_long_align_bit.
3792 * gdbarch.sh: Remove long_long_align_bit.
3793 * gdbarch.c, gdbarch.h: Rebuild.
3794 * arc-tdep.c (arc_type_align): New function.
3795 (arc_gdbarch_init): Use arc_type_align. Don't call
3796 set_gdbarch_long_long_align_bit.
3797
2fff16dd
TT
37982018-04-30 Tom Tromey <tom@tromey.com>
3799
3800 * rust-lang.c (rust_type_alignment): Remove.
3801 (rust_composite_type): Use type_align.
3802
6d7bb824
TT
38032018-04-30 Tom Tromey <tom@tromey.com>
3804
3805 * NEWS: Mention Type.align.
3806 * python/py-type.c (typy_get_alignof): New function.
3807 (type_object_getset): Add "alignof".
3808
007e1530
TT
38092018-04-30 Tom Tromey <tom@tromey.com>
3810
3811 PR exp/17095:
3812 * NEWS: Update.
3813 * std-operator.def (UNOP_ALIGNOF): New operator.
3814 * expprint.c (dump_subexp_body_standard) <case UNOP_ALIGNOF>:
3815 New.
3816 * eval.c (evaluate_subexp_standard) <case UNOP_ALIGNOF>: New.
3817 * c-lang.c (c_op_print_tab): Add alignof.
3818 * c-exp.y (ALIGNOF): New token.
3819 (exp): Add "ALIGNOF" production.
3820 (ident_tokens): Add _Alignof and alignof.
3821
2b4424c3
TT
38222018-04-30 Tom Tromey <tom@tromey.com>
3823
3824 * i386-tdep.c (i386_type_align): New function.
3825 (i386_gdbarch_init): Update.
3826 * gdbarch.sh (type_align): New method.
3827 * gdbarch.c, gdbarch.h: Rebuild.
3828 * arch-utils.h (default_type_align): Declare.
3829 * arch-utils.c (default_type_align): New function.
3830 * gdbtypes.h (TYPE_ALIGN_BITS): New define.
3831 (struct type) <align_log2>: New field.
3832 <instance_flags>: Now a bitfield.
3833 (TYPE_RAW_ALIGN): New macro.
3834 (type_align, type_raw_align, set_type_align): Declare.
3835 * gdbtypes.c (type_align, type_raw_align, set_type_align): New
3836 functions.
3837 * dwarf2read.c (quirk_rust_enum): Set type alignment.
3838 (get_alignment, maybe_set_alignment): New functions.
3839 (read_structure_type, read_enumeration_type, read_array_type)
3840 (read_set_type, read_tag_pointer_type, read_tag_reference_type)
3841 (read_subrange_type, read_base_type): Set type alignment.
3842
d33bc52e
SM
38432018-04-30 Simon Marchi <simon.marchi@ericsson.com>
3844
3845 * dwarf2read.c (read_index_from_section): Use bool.
3846
e28b63a9
FG
38472018-04-29 Fabian Groffen <grobian@gentoo.org>
3848
3849 PR gdb/22950
3850 * proc-events.c (init_syscall_table): Guard usage os SYS_uuidsys
3851 with #ifdef.
3852
cd8c76e4
JR
38532018-04-29 John Reiser <jreiser@BitWagon.com>
3854
3855 PR build/22873
3856 * gdb/Makefile.in: (.c:.l, .c:.y): Write the target only in the
3857 last step, and do it atomically.
3858
476d250e
AO
38592018-04-27 Alexandre Oliva <aoliva@redhat.com>
3860
3861 * compile/compile-c-types.c (convert_int, convert_float):
3862 Update for C FE v1.
3863
6873858b
TT
38642018-04-27 Tom Tromey <tom@tromey.com>
3865
3866 PR rust/22545:
3867 * rust-lang.c (rust_inclusive_range_type_p): New function.
3868 (rust_range): Handle inclusive ranges.
3869 (rust_compute_range): Likewise.
3870 * rust-exp.y (struct rust_op) <inclusive>: New field.
3871 (DOTDOTEQ): New constant.
3872 (range_expr): Add "..=" productions.
3873 (operator_tokens): Add "..=" token.
3874 (ast_range): Add "inclusive" parameter.
3875 (convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
3876 ranges.
3877 * parse.c (operator_length_standard) <case OP_RANGE>: Handle new
3878 bounds values.
3879 * expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
3880 LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
3881 Update comments.
3882 * expprint.c (print_subexp_standard): Handle new bounds values.
3883 (dump_subexp_body_standard): Likewise.
3884
632e107b
TT
38852018-04-27 Tom Tromey <tom@tromey.com>
3886
3887 * configure: Rebuild.
3888 * warning.m4 (AM_GDB_WARNINGS): Add -Wsuggest-override.
3889 * dwarf2loc.c (class dwarf_evaluate_loc_desc): Use "override", not
3890 "OVERRIDE".
3891 (class symbol_needs_eval_context): Likewise.
3892 * dwarf2read.c (mock_mapped_index::symbol_name_count)
3893 (mock_mapped_index::symbol_name_at): Use "override". Remove
3894 "virtual".
3895 * dwarf2-frame.c (dwarf_expr_executor::get_addr_index): Use
3896 "override".
3897 (class dwarf_expr_executor): Use "override", not "OVERRIDE".
3898 * aarch64-tdep.c (instruction_reader::read): Use "override".
3899 (instruction_reader_test::read): Likewise.
3900 * arm-tdep.c (instruction_reader::read): Use "override".
3901 (instruction_reader_thumb::read): Likewise.
3902
b75abf5b
AK
39032018-04-26 Andrzej Kaczmarek <andrzej.kaczmarek@codecoup.pl>
3904
3905 PR remote/9665
3906 * remote.c (send_g_packet): Use putpkt/getpkt/packet_check_result
3907 instead of remote_send.
3908 (remote_send): Remove.
3909
79188d8d
PA
39102018-04-26 Pedro Alves <palves@redhat.com>
3911
3912 * elfread.c (elf_gnu_ifunc_resolver_return_stop): Use
3913 find_function_start_sal instead of find_pc_line.
3914
f50776aa
PA
39152018-04-26 Pedro Alves <palves@redhat.com>
3916
3917 * breakpoint.c (set_breakpoint_location_function): Handle
3918 mst_data_gnu_ifunc.
3919 * c-exp.y (variable production): Handle mst_data_gnu_ifunc.
3920 * elfread.c (elf_symtab_read): Give data symbols with
3921 BSF_GNU_INDIRECT_FUNCTION set mst_data_gnu_ifunc type.
3922 (elf_rel_plt_read): Update comment.
3923 * linespec.c (convert_linespec_to_sals): Handle
3924 mst_data_gnu_ifunc.
3925 (minsym_found): Handle mst_data_gnu_ifunc.
3926 * minsyms.c (msymbol_is_function, minimal_symbol_reader::record)
3927 (find_solib_trampoline_target): Handle mst_data_gnu_ifunc.
3928 * parse.c (find_minsym_type_and_address): Handle
3929 mst_data_gnu_ifunc.
3930 * symmisc.c (dump_msymbols): Handle mst_data_gnu_ifunc.
3931 * symtab.c (find_gnu_ifunc): Handle mst_data_gnu_ifunc.
3932 * symtab.h (minimal_symbol_type) <mst_text_gnu_ifunc>: Update
3933 comment.
3934 <mst_data_gnu_ifunc>: New enumerator.
3935
20944a6e
PA
39362018-04-26 Pedro Alves <palves@redhat.com>
3937
3938 * minsyms.c (lookup_minimal_symbol_by_pc_section_1): Rename to ...
3939 (lookup_minimal_symbol_by_pc_section): ... this. Replace
3940 'want_trampoline' parameter by a lookup_msym_prefer parameter.
3941 Handle it.
3942 (lookup_minimal_symbol_by_pc_section): Delete old implementation.
3943 (lookup_minimal_symbol_by_pc): Adjust.
3944 (in_gnu_ifunc_stub): Prefer GNU ifunc symbols.
3945 (lookup_solib_trampoline_symbol_by_pc): Adjust.
3946 * minsyms.h (lookup_msym_prefer): New enum.
3947 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
3948 parameter by a lookup_msym_prefer parameter.
3949
1adeb822
PA
39502018-04-26 Pedro Alves <palves@redhat.com>
3951
3952 * elfread.c (elf_gnu_ifunc_record_cache): Check if the symbol name
3953 ends in "@plt" instead of looking at the symbol's section.
3954
a0aca7b0
PA
39552018-04-26 Pedro Alves <palves@redhat.com>
3956
3957 * blockframe.c (cache_pc_function_is_gnu_ifunc): Delete. Remove
3958 all references.
3959 (find_pc_partial_function_gnu_ifunc): Rename to ...
3960 (find_pc_partial_function): ... this, and remove references to
3961 'is_gnu_ifunc_p'.
3962 (find_pc_partial_function): Delete old implementation.
3963 * symtab.h (find_pc_partial_function_gnu_ifunc): Delete.
3964
76af0f26
PA
39652018-04-26 Pedro Alves <palves@redhat.com>
3966
3967 * linespec.c (struct bound_minimal_symbol_search_key): New.
3968 (convert_linespec_to_sals): Sort minimal symbols earlier. Don't
3969 skip first line if we found a GNU ifunc minimal symbol by name.
3970 (compare_msymbols): Change parameters to work with a destructured
3971 lhs minsym.
3972 (compare_msymbols_for_qsort, compare_msymbols_for_bsearch): New
3973 functions.
3974
3467ec66
PA
39752018-04-26 Pedro Alves <palves@redhat.com>
3976
3977 * breakpoint.c (set_breakpoint_location_function): Don't resolve
3978 ifunc targets here. Instead, if we have an ifunc minsym, use its
3979 address/name.
3980 (add_location_to_breakpoint): Store the minsym and the objfile in
3981 the breakpoint location.
3982 * breakpoint.h (bp_location) <msymbol, objfile>: New fields.
3983 * linespec.c (minsym_found): Resolve GNU ifunc targets here.
3984 Record the minsym in the sal.
3985 * symtab.h (symtab_and_line) <msymbol>: New field.
3986
28f4fa4d
PA
39872018-04-26 Pedro Alves <palves@redhat.com>
3988
3989 * elfread.c (elf_gnu_ifunc_resolve_by_got): Don't write to *ADDR_P
3990 unless we actually resolved the ifunc.
3991
ca31ab1d
PA
39922018-04-26 Pedro Alves <palves@redhat.com>
3993
3994 * c-exp.y (variable production): Prefer ifunc minsyms over
3995 regular function symbols.
3996 * symtab.c (find_gnu_ifunc): New function.
3997 * minsyms.h (lookup_msym_prefer): New enum.
3998 (lookup_minimal_symbol_by_pc_section): Replace 'want_trampoline'
3999 parameter by a lookup_msym_prefer parameter.
4000 * symtab.h (find_gnu_ifunc): New declaration.
4001
8388016d
PA
40022018-04-26 Pedro Alves <palves@redhat.com>
4003
4004 * blockframe.c (find_gnu_ifunc_target_type): New function.
4005 (find_function_type): New.
4006 * eval.c (evaluate_var_msym_value): For GNU ifunc types, always
4007 return a value with a memory address.
4008 (eval_call): For calls to GNU ifunc functions, try to find the
4009 type of the target function from the type that the resolver
4010 returns.
4011 * gdbtypes.c (objfile_type): Don't install a return type for ifunc
4012 symbols.
4013 * infcall.c (find_function_return_type): Delete.
4014 (find_function_addr): Add 'function_type' parameter. For calls to
4015 GNU ifunc functions, try to find the type of the target function
4016 from the type that the resolver returns, and return it via
4017 FUNCTION_TYPE.
4018 (call_function_by_hand_dummy): Adjust to use the function type
4019 returned by find_function_addr.
4020 (find_function_addr): Add 'function_type' parameter and move
4021 description here.
4022 * symtab.h (find_function_type, find_gnu_ifunc_target_type): New
4023 declarations.
4024
a376e11d
PA
40252018-04-26 Pedro Alves <palves@redhat.com>
4026
4027 * c-exp.y (variable production): Skip finding an alias for ifunc
4028 symbols.
4029
02e169e2
PA
40302018-04-26 Pedro Alves <palves@redhat.com>
4031
4032 * elfread.c (elf_rel_plt_read): Look for relocations for .got.plt too.
4033
249b5733
PA
40342018-04-25 Pedro Alves <palves@redhat.com>
4035
4036 * infcmd.c (kill_command): Print the pid as string, not the whole
4037 thread's ptid. Add comment. s/has been killed/killed/ in output
4038 message.
4039 * remote.c (remote_detach_1): Print the pid as string, not the
4040 whole thread's ptid.
4041
f67c0c91
SDJ
40422018-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
4043 Sergio Durigan Junior <sergiodj@redhat.com>
4044 Pedro Alves <palves@redhat.com>
4045
4046 * infcmd.c (kill_command): Print message when inferior has
4047 been killed.
4048 * inferior.c (print_inferior_events): Remove 'static'. Set as
4049 '1'.
4050 (add_inferior): Improve message printed when
4051 'print_inferior_events' is on.
4052 (exit_inferior): Remove message printed when
4053 'print_inferior_events' is on.
4054 (detach_inferior): Improve message printed when
4055 'print_inferior_events' is on.
4056 (initialize_inferiors): Use 'add_inferior_silent' to set
4057 'current_inferior_'.
4058 * inferior.h (print_inferior_events): Declare here as
4059 'extern'.
4060 * infrun.c (follow_fork_inferior): Print '[Attaching...]' or
4061 '[Detaching...]' messages when 'print_inferior_events' is on.
4062 Use 'add_thread_silent' instead of 'add_thread'. Add '[' and ']'
4063 as prefix/suffix for messages. Remove periods. Fix erroneous
4064 'Detaching after fork from child...', replace it by '... from
4065 parent...'.
4066 (handle_vfork_child_exec_or_exit): Add '[' and ']' as
4067 prefix/suffix when printing 'Detaching...' messages. Print
4068 them when 'print_inferior_events' is on.
4069 * remote.c (remote_detach_1): Print message when detaching
4070 from inferior and '!is_fork_parent'.
4071
e427af18
TT
40722018-04-24 Tom Tromey <tom@tromey.com>
4073
4074 * cli-out.h: Reindent.
4075
05b1d8d6
TT
40762018-04-24 Tom Tromey <tom@tromey.com>
4077
4078 * cli-out.c (cli_ui_out::out_field_fmt): Remove.
4079 (cli_ui_out::do_field_string): Use fputs_filtered.
4080 * cli-out.h (class cli_ui_out) <out_field_fmt>: Remove.
4081
a95c7dab
TT
40822018-04-23 Tom Tromey <tom@tromey.com>
4083
4084 * guile/scm-frame.c (gdbscm_frame_read_var): Use
4085 gdb::unique_xmalloc_ptr.
4086
458412c3
TT
40872018-04-23 Tom Tromey <tom@tromey.com>
4088
4089 * configure: Rebuild.
4090
db86b02b
RS
40912018-04-22 Rajendra SY <rajendra.sy@gmail.com>
4092
4093 PR gdb/23095
4094 * gdb/testsuite/gdb.base/break-probes.exp: Pass shlib_load to
4095 prepare_for_testing. Set normal_bp to r_debug_state if target
4096 is bsd.
4097
00aecdcf
PA
40982018-04-21 Pedro Alves <palves@redhat.com>
4099 Rajendra SY <rajendra.sy@gmail.com>
4100
4101 * inf-ptrace.c (inf_ptrace_attach): Mark the thread as executing.
4102 * remote.c (extended_remote_attach): In all-stop mode, mark the
4103 thread as executing.
4104
224608c3
PW
41052018-04-19 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4106
4107 * thread.c (thread_apply_all_command): Fix comment.
4108 (thread_command): Fix comment.
4109
3b74854b
AH
41102018-04-10 Alan Hayward <alan.hayward@arm.com>
4111
4112 * common/tdesc.h (tdesc_create_feature): Remove xml filename
4113 parameter.
4114 * features/aarch64-core.c (create_feature_aarch64_core):
4115 Regenerate.
4116 * features/aarch64-fpu.c (create_feature_aarch64_fpu):
4117 Likewise.
4118 * features/i386/32bit-avx.c (create_feature_i386_32bit_avx):
4119 Likewise.
4120 * features/i386/32bit-avx512.c
4121 (create_feature_i386_32bit_avx512): Likewise.
4122 * features/i386/32bit-core.c (create_feature_i386_32bit_core):
4123 Likewise.
4124 * features/i386/32bit-linux.c (create_feature_i386_32bit_linux):
4125 Likewise.
4126 * features/i386/32bit-mpx.c (create_feature_i386_32bit_mpx):
4127 Likewise.
4128 * features/i386/32bit-pkeys.c (create_feature_i386_32bit_pkeys):
4129 Likewise.
4130 * features/i386/32bit-sse.c (create_feature_i386_32bit_sse):
4131 Likewise.
4132 * features/i386/64bit-avx.c (create_feature_i386_64bit_avx):
4133 Likewise.
4134 * features/i386/64bit-avx512.c
4135 (create_feature_i386_64bit_avx512): Likewise.
4136 * features/i386/64bit-core.c (create_feature_i386_64bit_core):
4137 Likewise.
4138 * features/i386/64bit-linux.c (create_feature_i386_64bit_linux):
4139 Likewise.
4140 * features/i386/64bit-mpx.c (create_feature_i386_64bit_mpx):
4141 Likewise.
4142 * features/i386/64bit-pkeys.c (create_feature_i386_64bit_pkeys):
4143 Likewise.
4144 * features/i386/64bit-segments.c
4145 (create_feature_i386_64bit_segments): Likewise.
4146 * features/i386/64bit-sse.c (create_feature_i386_64bit_sse):
4147 Likewise.
4148 * features/i386/x32-core.c
4149 (create_feature_i386_x32_core): Likewise.
4150 * features/tic6x-c6xp.c (create_feature_tic6x_c6xp): Likewise.
4151 * features/tic6x-core.c (create_feature_tic6x_core): Likewise.
4152 * features/tic6x-gp.c (create_feature_tic6x_gp): Likewise.
4153 * target-descriptions.c: In generated code, don't pass xml
4154 filename.
4155
e98577a9
AH
41562018-04-18 Alan Hayward <alan.hayward@arm.com>
4157
4158 * common/tdesc.c (print_xml_feature::visit_pre): Add xml parsing.
4159 (print_xml_feature::visit_post): Likewise.
4160 (print_xml_feature::visit): Likewise.
4161 * common/tdesc.h (tdesc_get_features_xml): Use const tdesc.
4162 (print_xml_feature): Add new class.
4163 * regformats/regdat.sh: Null xmltarget on feature targets.
4164 * target-descriptions.c (struct target_desc): Add xmltarget.
4165 (maintenance_check_tdesc_xml_convert): Add unittest function.
4166 (tdesc_get_features_xml): Add function to get xml.
4167 (maintenance_check_xml_descriptions): Test xml generation.
4168 * xml-tdesc.c (string_read_description_xml): Add function.
4169 * xml-tdesc.h (string_read_description_xml): Add declaration.
4170
ad7fc756
AH
41712018-04-18 Alan Hayward <alan.hayward@arm.com>
4172
4173 * features/Makefile: Add feature marker to targets with new style
4174 target descriptions.
4175 * regformats/aarch64.dat: Regenerate.
4176 * regformats/i386/amd64-avx-avx512-linux.dat: Likewise.
4177 * regformats/i386/amd64-avx-linux.dat: Likewise.
4178 * regformats/i386/amd64-avx-mpx-avx512-pku-linux.dat: Likewise.
4179 * regformats/i386/amd64-avx-mpx-linux.dat: Likewise.
4180 * regformats/i386/amd64-linux.dat: Likewise.
4181 * regformats/i386/amd64-mpx-linux.dat: Likewise.
4182 * regformats/i386/amd64.dat: Likewise.
4183 * regformats/i386/i386-avx-avx512-linux.dat: Likewise.
4184 * regformats/i386/i386-avx-linux.dat: Likewise.
4185 * regformats/i386/i386-avx-mpx-avx512-pku-linux.dat: Likewise.
4186 * regformats/i386/i386-avx-mpx-linux.dat: Likewise.
4187 * regformats/i386/i386-linux.dat: Likewise.
4188 * regformats/i386/i386-mmx-linux.dat: Likewise.
4189 * regformats/i386/i386-mpx-linux.dat: Likewise.
4190 * regformats/i386/i386.dat: Likewise.
4191 * regformats/i386/x32-avx-avx512-linux.dat: Likewise.
4192 * regformats/i386/x32-avx-linux.dat: Likewise.
4193 * regformats/i386/x32-linux.dat: Likewise.
4194 * regformats/tic6x-c62x-linux.dat: Likewise.
4195 * regformats/tic6x-c64x-linux.dat: Likewise.
4196 * regformats/tic6x-c64xp-linux.dat: Likewise.
4197 * regformats/regdat.sh: Parse feature marker.
4198
d278f585
AH
41992018-04-18 Alan Hayward <alan.hayward@arm.com>
4200
4201 * common/tdesc.h (tdesc_architecture_name): Add new declaration.
4202 (tdesc_osabi_name): Likewise.
4203 * target-descriptions.c (tdesc_architecture_name): Add new
4204 function.
4205 (tdesc_osabi_name): Likewise.
4206
eee8a18d
AH
42072018-04-18 Alan Hayward <alan.hayward@arm.com>
4208
4209 * common/tdesc.c (tdesc_predefined_type): Move to here.
4210 (tdesc_named_type): Likewise.
4211 (tdesc_create_vector): Likewise.
4212 (tdesc_create_struct): Likewise.
4213 (tdesc_set_struct_size): Likewise.
4214 (tdesc_create_union): Likewise.
4215 (tdesc_create_flags): Likewise.
4216 (tdesc_create_enum): Likewise.
4217 (tdesc_add_field): Likewise.
4218 (tdesc_add_typed_bitfield): Likewise.
4219 (tdesc_add_bitfield): Likewise.
4220 (tdesc_add_flag): Likewise.
4221 (tdesc_add_enum_value): Likewise.
4222 * common/tdesc.h (struct tdesc_type_builtin): Likewise.
4223 (struct tdesc_type_vector): Likewise.
4224 (struct tdesc_type_field): Likewise.
4225 (struct tdesc_type_with_fields): Likewise.
4226 (tdesc_create_enum): Add declaration.
4227 (tdesc_add_typed_bitfield): Likewise.
4228 (tdesc_add_enum_value): Likewise.
4229 * target-descriptions.c (tdesc_type_field): Move from here.
4230 (tdesc_type_builtin): Likewise.
4231 (tdesc_type_vector): Likewise.
4232 (tdesc_type_with_fields): Likewise.
4233 (tdesc_predefined_types): Likewise.
4234 (tdesc_named_type): Likewise.
4235 (tdesc_create_vector): Likewise.
4236 (tdesc_create_struct): Likewise.
4237 (tdesc_set_struct_size): Likewise.
4238 (tdesc_create_union): Likewise.
4239 (tdesc_create_flags): Likewise.
4240 (tdesc_create_enum): Likewise.
4241 (tdesc_add_field): Likewise.
4242 (tdesc_add_typed_bitfield): Likewise.
4243 (tdesc_add_bitfield): Likewise.
4244 (tdesc_add_flag): Likewise.
4245 (tdesc_add_enum_value): Likewise.
4246 * gdb/target-descriptions.h (tdesc_create_enum): Likewise.
4247 (tdesc_add_typed_bitfield): Likewise.
4248 (tdesc_add_enum_value): Likewise.
4249
82ec9bc7
AH
42502018-04-18 Alan Hayward <alan.hayward@arm.com>
4251
4252 * common/tdesc.c (tdesc_feature::accept): Move to here.
4253 (tdesc_feature::operator==): Likewise.
4254 (tdesc_create_reg): Likewise.
4255 * common/tdesc.h (tdesc_type_kind): Likewise.
4256 (struct tdesc_type): Likewise.
4257 (struct tdesc_feature): Likewise.
4258 * regformats/regdat.sh: Create a feature.
4259 * target-descriptions.c (tdesc_type_kind): Move from here.
4260 (tdesc_type): Likewise.
4261 (tdesc_type_up): Likewise.
4262 (tdesc_feature): Likewise.
4263 (tdesc_create_reg): Likewise.
4264
ea3e7d71
AH
42652018-04-18 Alan Hayward <alan.hayward@arm.com>
4266
4267 * Makefile.in: Add arch/tdesc.c
4268 * common/tdesc.c: New file.
4269 * common/tdesc.h (tdesc_element_visitor): Move to here.
4270 (tdesc_element): Likewise.
4271 (tdesc_reg): Likewise.
4272 (tdesc_reg_up): Likewise.
4273 * regformats/regdef.h (reg): Add offset to constructors.
4274 * target-descriptions.c (tdesc_element_visitor): Move from here.
4275 (tdesc_element): Likewise.
4276 (tdesc_reg): Likewise.
4277 (tdesc_reg_up): Likewise.
4278
bedda9ac
TT
42792018-04-17 Tom Tromey <tom@tromey.com>
4280
4281 * dwarf2read.c (quirk_rust_enum): Conditionally drop the
4282 discriminant field.
4283
a037790e
TT
42842018-04-17 Tom Tromey <tom@tromey.com>
4285
4286 * dwarf2read.c (quirk_rust_enum): Handle unions correctly.
4287
c7dcbf88
AA
42882018-04-17 Andreas Arnez <arnez@linux.vnet.ibm.com>
4289
4290 * symtab.c (print_symbol_info): Skip printing filename and line
4291 number when `last' is NULL.
4292 (symtab_symbol_info): Use empty string instead of NULL for first
4293 invocation of print_symbol_info.
4294 (rbreak_command): Pass NULL to `last' parameter of
4295 print_symbol_info.
4296
07d28c77
SM
42972018-04-16 Simon Marchi <simon.marchi@ericsson.com>
4298
4299 * linux-tdep.c (linux_spu_make_corefile_notes): Return note_data
4300 instead of nullptr.
4301
8a3de5e1
PA
43022018-04-16 Pedro Alves <palves@redhat.com>
4303
4304 * MAINTAINERS (sh): Remove.
4305 * Makefile.in (ALL_TARGET_OBS): Remove sh64-tdep.o.
4306 (HFILES_NO_SRCDIR): Remove sh64-tdep.h.
4307 (ALLDEPFILES): Remove sh64-tdep.c.
4308 * NEWS: Mentions that support for SH-5/SH64 is removed.
4309 * configure.tgt (sh*-*-linux*): Remove reference to sh64-tdep.o.
4310 (sh*-*-openbsd*): Ditto.
4311 (sh64-*-elf*): Remove.
4312 (sh*): Remove.
4313 * regcache.c (cooked_write_test): Remove bfd_mach_sh5 case.
4314 * sh-linux-tdep.c: Remove reference to bfd_mach_sh5.
4315 * sh-tdep.c: No longer include "sh64-tdep.h".
4316 (sh_gdbarch_init): Remove reference to bfd_mach_sh5.
4317 * sh64-tdep.c, sh64-tdep.h: Remove files.
4318
a2a79012
PA
43192018-04-16 Pedro Alves <palves@redhat.com>
4320
4321 * MAINTAINERS: Remove m88k.
4322 * Makefile.in (ALL_TARGET_OBS): Remove m88k-tdep.o.
4323 (HFILES_NO_SRCDIR): Remove m88k-tdep.h.
4324 (ALLDEPFILES): Remove m88k-bsd-nat.c and m88k-tdep.c.
4325 * NEWS: Mention that support for m88k was removed.
4326 * configure.host (m88*-*-*): Remove support.
4327 * configure.nat (m88k-*-*): Remove support.
4328 * configure.tgt (m88*-*-openbsd*): Remove.
4329 * m88k-bsd-nat.c, m88k-tdep.c, m88k-tdep.h: Delete.
4330
eda4efb1
SM
43312018-04-15 Simon Marchi <simon.marchi@polymtl.ca>
4332
4333 * configure.tgt (x86_tobjs): New variable.
4334 (amd64_tobjs, i386_tobjs): Use it.
4335
b744723f
AA
43362018-04-13 Andreas Arnez <arnez@linux.vnet.ibm.com>
4337
4338 * symtab.c (print_symbol_info): Precede the symbol definition by
4339 the line number when available.
4340 * NEWS: Advertise this enhancement.
4341
4a4495d6
MM
43422018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4343
4344 * NEWS (New options): announce set/show record btrace cpu.
4345 * btrace.c: Include record-btrace.h.
4346 (btrace_compute_ftrace_pt): Skip enabling errata workarounds if
4347 the vendor is unknown.
4348 (btrace_compute_ftrace_1): Add cpu parameter. Update callers.
4349 Maybe overwrite the btrace configuration's cpu.
4350 (btrace_compute_ftrace): Add cpu parameter. Update callers.
4351 (btrace_fetch): Add cpu parameter. Update callers.
4352 (btrace_maint_update_pt_packets): Call record_btrace_get_cpu.
4353 Maybe overwrite the btrace configuration's cpu. Skip enabling
4354 errata workarounds if the vendor is unknown.
4355 * python/py-record-btrace.c: Include record-btrace.h.
4356 (recpy_bt_begin, recpy_bt_end, recpy_bt_instruction_history)
4357 (recpy_bt_function_call_history): Call record_btrace_get_cpu.
4358 * record-btrace.c (record_btrace_cpu_state_kind): New.
4359 (record_btrace_cpu): New.
4360 (set_record_btrace_cpu_cmdlist): New.
4361 (record_btrace_get_cpu): New.
4362 (require_btrace_thread, record_btrace_info)
4363 (record_btrace_resume_thread): Call record_btrace_get_cpu.
4364 (cmd_set_record_btrace_cpu_none): New.
4365 (cmd_set_record_btrace_cpu_auto): New.
4366 (cmd_set_record_btrace_cpu): New.
4367 (cmd_show_record_btrace_cpu): New.
4368 (_initialize_record_btrace): Initialize set/show record btrace cpu
4369 commands.
4370 * record-btrace.h (record_btrace_get_cpu): New.
4371
69f90c75
MM
43722018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4373
4374 * record.c (set_record_command): Fix typo in message.
4375
b85310e1
MM
43762018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4377
4378 * record-btrace.c (cmd_set_record_btrace): Print sub-commands.
4379
1d509aa6
MM
43802018-04-13 Markus Metzger <markus.t.metzger@intel.com>
4381
4382 * infrun.c (process_event_stop_test): Call
4383 gdbarch_in_indirect_branch_thunk.
4384 * gdbarch.sh (in_indirect_branch_thunk): New.
4385 * gdbarch.c: Regenerated.
4386 * gdbarch.h: Regenerated.
4387 * x86-tdep.h: New.
4388 * x86-tdep.c: New.
4389 * Makefile.in (ALL_TARGET_OBS): Add x86-tdep.o.
4390 (HFILES_NO_SRCDIR): Add x86-tdep.h.
4391 (ALLDEPFILES): Add x86-tdep.c.
4392 * arch-utils.h (default_in_indirect_branch_thunk): New.
4393 * arch-utils.c (default_in_indirect_branch_thunk): New.
4394 * i386-tdep: Include x86-tdep.h.
4395 (i386_in_indirect_branch_thunk): New.
4396 (i386_elf_init_abi): Set in_indirect_branch_thunk gdbarch
4397 function.
4398 * amd64-tdep: Include x86-tdep.h.
4399 (amd64_in_indirect_branch_thunk): New.
4400 (amd64_init_abi): Set in_indirect_branch_thunk gdbarch function.
4401
b4be9bfd
JK
44022018-04-12 Jan Kratochvil <jan.kratochvil@redhat.com>
4403
4404 PR gdb/23053
4405 * dwarf-index-write.c (data_buf::grow) (write_one_signatured_type)
4406 (recursively_write_psymbols) (debug_names::recursively_write_psymbols)
4407 (debug_names::write_one_signatured_type): Fix -D_GLIBCXX_DEBUG
4408 regression.
4409
53d7df28
TT
44102018-04-12 Tom Tromey <tom@tromey.com>
4411
4412 * rust-lang.c (rust_print_struct_def): Remove univariant code.
4413 (rust_evaluate_subexp): Likewise.
4414
70b33f19
PA
44152018-04-12 Pedro Alves <palves@redhat.com>
4416
4417 * procfs.c (procfs_detach): Make forward declaration's prototype
4418 match definition's protototype.
4419 (proc_get_LDT_entry): Remove stale do_cleanups call.
4420
436411b1
PA
44212018-04-12 Pedro Alves <palves@redhat.com>
4422
4423 * target.h (target_ops::to_has_exited): Delete.
4424 (target_has_exited): Delete.
4425 * target-delegates.c: Regenerate.
4426
20db9c52
PA
44272018-04-11 Pedro Alves <palves@redhat.com>
4428
4429 * target.c (fileio_fh_t::t): Add comment.
4430 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
4431 (target_fileio_close): Handle a NULL target.
4432 (invalidate_fileio_fh): New.
4433 (target_close): Call it.
4434 * remote.c (remote_hostio_send_command): No longer check whether
4435 remote_desc is open.
4436
5ff79300
PA
44372018-04-11 Pedro Alves <palves@redhat.com>
4438
4439 * target.c (fileio_fh_t): Make it a named struct instead of a
4440 typedef.
4441 (fileio_fh_t::is_closed): New method.
4442 (DEF_VEC_O (fileio_fh_t)): Remove.
4443 (fileio_fhandles): Now a std::vector.
4444 (is_closed_fileio_fh): Delete.
4445 (acquire_fileio_fd): Adjust. Rename parameters.
4446 (release_fileio_fd): Adjust.
4447 (fileio_fd_to_fh): Reimplement as a function instead of a macro.
4448 (target_fileio_pwrite, target_fileio_pread, target_fileio_fstat)
4449 (target_fileio_close): Adjust.
4450
6e22e10d
SM
44512018-04-10 Simon Marchi <simon.marchi@ericsson.com>
4452
4453 * auto-load.c (auto_load_safe_path_vec_update): Iterate by
4454 index.
4455
731f534f
PA
44562018-04-10 Pedro Alves <palves@redhat.com>
4457
4458 * gdbthread.h (finish_thread_state_cleanup): Delete declaration.
4459 (scoped_finish_thread_state): New class.
4460 * infcmd.c (run_command_1): Use it instead of finish_thread_state
4461 cleanup.
4462 * infrun.c (proceed, prepare_for_detach, wait_for_inferior)
4463 (fetch_inferior_event, normal_stop): Likewise.
4464 * thread.c (finish_thread_state_cleanup): Delete.
4465
d5f4488f
SM
44662018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4467 Pedro Alves <palves@redhat.com>
4468
4469 * value.c: Include "selftest.h" and "common/array-view.h".
4470 (struct range) <operator ==>: New.
4471 (test_ranges_contain): New.
4472 (check_ranges_vector): New.
4473 (test_insert_into_bit_range_vector): New.
4474 (_initialize_values): Register selftests.
4475 * common/array-view.h (operator==, operator!=): New.
4476
b24531ed
SM
44772018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4478
4479 * common/gdb_vecs.h (unordered_remove): Add overload that takes
4480 an iterator.
4481 * inline-frame.c: Include <algorithm>.
4482 (struct inline_state): Add constructor.
4483 (inline_state_s): Remove.
4484 (DEF_VEC_O(inline_state_s)): Remove.
4485 (inline_states): Change type to std::vector.
4486 (find_inline_frame_state): Adjust to std::vector.
4487 (allocate_inline_frame_state): Remove.
4488 (clear_inline_frame_state): Adjust to std::vector.
4489 (skip_inline_frames): Adjust to std::vector.
4490
c252925c
SM
44912018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4492
4493 * tracepoint.h (struct trace_state_variable): Add constructor.
4494 <name>: Change type to std::string.
4495 * tracepoint.c (tsv_s): Remove.
4496 (DEF_VEC_O(tsv_s)): Remove.
4497 (tvariables): Change to std::vector.
4498 (create_trace_state_variable): Adjust to std::vector.
4499 (find_trace_state_variable): Likewise.
4500 (find_trace_state_variable_by_number): Likewise.
4501 (delete_trace_state_variable): Likewise.
4502 (trace_variable_command): Adjust to std::string.
4503 (delete_trace_variable_command): Likewise.
4504 (tvariables_info_1): Adjust to std::vector.
4505 (save_trace_state_variables): Likewise.
4506 (start_tracing): Likewise.
4507 (merge_uploaded_trace_state_variables): Adjust to std::vector
4508 and std::string.
4509 * target.h (struct target_ops)
4510 <to_download_trace_state_variable>: Pass reference to
4511 trace_state_variable.
4512 * target-debug.h (target_debug_print_const_trace_state_variable_r): New.
4513 * target-delegates.c: Re-generate.
4514 * mi/mi-interp.c (mi_tsv_created): Adjust to std::string.
4515 (mi_tsv_deleted): Likewise.
4516 * mi/mi-main.c (mi_cmd_trace_frame_collected): Likewise.
4517 * remote.c (remote_download_trace_state_variable): Change
4518 pointer to reference and adjust.
4519 * make-target-delegates (parse_argtypes): Handle references.
4520 (write_function_header): Likewise.
4521 (munge_type): Likewise.
4522
c9638d26
SM
45232018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4524
4525 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
4526 string_view-selftests.c.
4527 * unittests/basic_string_view/capacity/1.cc: Adapt to GDB
4528 testsuite.
4529 * unittests/basic_string_view/cons/char/1.cc: Likewise.
4530 * unittests/basic_string_view/cons/char/2.cc: Likewise.
4531 * unittests/basic_string_view/cons/char/3.cc: Likewise.
4532 * unittests/basic_string_view/element_access/char/1.cc:
4533 Likewise.
4534 * unittests/basic_string_view/element_access/char/empty.cc:
4535 Likewise.
4536 * unittests/basic_string_view/element_access/char/front_back.cc:
4537 Likewise.
4538 * unittests/basic_string_view/inserters/char/2.cc: Likewise.
4539 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc:
4540 Likewise.
4541 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc:
4542 Likewise.
4543 * unittests/basic_string_view/modifiers/swap/char/1.cc:
4544 Likewise.
4545 * unittests/basic_string_view/operations/compare/char/1.cc:
4546 Likewise.
4547 * unittests/basic_string_view/operations/compare/char/13650.cc:
4548 Likewise.
4549 * unittests/basic_string_view/operations/copy/char/1.cc:
4550 Likewise.
4551 * unittests/basic_string_view/operations/data/char/1.cc:
4552 Likewise.
4553 * unittests/basic_string_view/operations/find/char/1.cc:
4554 Likewise.
4555 * unittests/basic_string_view/operations/find/char/2.cc:
4556 Likewise.
4557 * unittests/basic_string_view/operations/find/char/3.cc:
4558 Likewise.
4559 * unittests/basic_string_view/operations/find/char/4.cc:
4560 Likewise.
4561 * unittests/basic_string_view/operations/rfind/char/1.cc:
4562 Likewise.
4563 * unittests/basic_string_view/operations/rfind/char/2.cc:
4564 Likewise.
4565 * unittests/basic_string_view/operations/rfind/char/3.cc:
4566 Likewise.
4567 * unittests/basic_string_view/operations/substr/char/1.cc:
4568 Likewise.
4569 * unittests/basic_string_view/operators/char/2.cc: Likewise.
4570 * unittests/string_view-selftests.c: New file.
4571
fdc11678
SM
45722018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4573
4574 * unittests/basic_string_view/capacity/1.cc: New file.
4575 * unittests/basic_string_view/capacity/empty_neg.cc: New file.
4576 * unittests/basic_string_view/cons/char/1.cc: New file.
4577 * unittests/basic_string_view/cons/char/2.cc: New file.
4578 * unittests/basic_string_view/cons/char/3.cc: New file.
4579 * unittests/basic_string_view/cons/wchar_t/1.cc: New file.
4580 * unittests/basic_string_view/cons/wchar_t/2.cc: New file.
4581 * unittests/basic_string_view/cons/wchar_t/3.cc: New file.
4582 * unittests/basic_string_view/element_access/char/1.cc: New file.
4583 * unittests/basic_string_view/element_access/char/2.cc: New file.
4584 * unittests/basic_string_view/element_access/char/empty.cc: New file.
4585 * unittests/basic_string_view/element_access/char/front_back.cc: New file.
4586 * unittests/basic_string_view/element_access/wchar_t/1.cc: New file.
4587 * unittests/basic_string_view/element_access/wchar_t/2.cc: New file.
4588 * unittests/basic_string_view/element_access/wchar_t/empty.cc: New file.
4589 * unittests/basic_string_view/element_access/wchar_t/front_back.cc: New file.
4590 * unittests/basic_string_view/include.cc: New file.
4591 * unittests/basic_string_view/inserters/char/1.cc: New file.
4592 * unittests/basic_string_view/inserters/char/2.cc: New file.
4593 * unittests/basic_string_view/inserters/char/3.cc: New file.
4594 * unittests/basic_string_view/inserters/pod/10081-out.cc: New file.
4595 * unittests/basic_string_view/inserters/wchar_t/1.cc: New file.
4596 * unittests/basic_string_view/inserters/wchar_t/2.cc: New file.
4597 * unittests/basic_string_view/inserters/wchar_t/3.cc: New file.
4598 * unittests/basic_string_view/literals/types.cc: New file.
4599 * unittests/basic_string_view/literals/values.cc: New file.
4600 * unittests/basic_string_view/modifiers/remove_prefix/char/1.cc: New file.
4601 * unittests/basic_string_view/modifiers/remove_prefix/wchar_t/1.cc: New file.
4602 * unittests/basic_string_view/modifiers/remove_suffix/char/1.cc: New file.
4603 * unittests/basic_string_view/modifiers/remove_suffix/wchar_t/1.cc: New file.
4604 * unittests/basic_string_view/modifiers/swap/char/1.cc: New file.
4605 * unittests/basic_string_view/modifiers/swap/wchar_t/1.cc: New file.
4606 * unittests/basic_string_view/operations/compare/char/1.cc: New file.
4607 * unittests/basic_string_view/operations/compare/char/13650.cc: New file.
4608 * unittests/basic_string_view/operations/compare/char/2.cc: New file.
4609 * unittests/basic_string_view/operations/compare/char/70483.cc: New file.
4610 * unittests/basic_string_view/operations/compare/wchar_t/1.cc: New file.
4611 * unittests/basic_string_view/operations/compare/wchar_t/13650.cc: New file.
4612 * unittests/basic_string_view/operations/compare/wchar_t/2.cc: New file.
4613 * unittests/basic_string_view/operations/copy/char/1.cc: New file.
4614 * unittests/basic_string_view/operations/copy/wchar_t/1.cc: New file.
4615 * unittests/basic_string_view/operations/data/char/1.cc: New file.
4616 * unittests/basic_string_view/operations/data/wchar_t/1.cc: New file.
4617 * unittests/basic_string_view/operations/find/char/1.cc: New file.
4618 * unittests/basic_string_view/operations/find/char/2.cc: New file.
4619 * unittests/basic_string_view/operations/find/char/3.cc: New file.
4620 * unittests/basic_string_view/operations/find/char/4.cc: New file.
4621 * unittests/basic_string_view/operations/find/wchar_t/1.cc: New file.
4622 * unittests/basic_string_view/operations/find/wchar_t/2.cc: New file.
4623 * unittests/basic_string_view/operations/find/wchar_t/3.cc: New file.
4624 * unittests/basic_string_view/operations/find/wchar_t/4.cc: New file.
4625 * unittests/basic_string_view/operations/rfind/char/1.cc: New file.
4626 * unittests/basic_string_view/operations/rfind/char/2.cc: New file.
4627 * unittests/basic_string_view/operations/rfind/char/3.cc: New file.
4628 * unittests/basic_string_view/operations/rfind/wchar_t/1.cc: New file.
4629 * unittests/basic_string_view/operations/rfind/wchar_t/2.cc: New file.
4630 * unittests/basic_string_view/operations/rfind/wchar_t/3.cc: New file.
4631 * unittests/basic_string_view/operations/string_conversion/1.cc: New file.
4632 * unittests/basic_string_view/operations/substr/char/1.cc: New file.
4633 * unittests/basic_string_view/operations/substr/wchar_t/1.cc: New file.
4634 * unittests/basic_string_view/operators/char/2.cc: New file.
4635 * unittests/basic_string_view/operators/wchar_t/2.cc: New file.
4636 * unittests/basic_string_view/range_access/char/1.cc: New file.
4637 * unittests/basic_string_view/range_access/wchar_t/1.cc: New file.
4638 * unittests/basic_string_view/requirements/explicit_instantiation/1.cc: New file.
4639 * unittests/basic_string_view/requirements/explicit_instantiation/char/1.cc: New file.
4640 * unittests/basic_string_view/requirements/explicit_instantiation/char16_t/1.cc: New file.
4641 * unittests/basic_string_view/requirements/explicit_instantiation/char32_t/1.cc: New file.
4642 * unittests/basic_string_view/requirements/explicit_instantiation/wchar_t/1.cc: New file.
4643 * unittests/basic_string_view/requirements/typedefs.cc: New file.
4644 * unittests/basic_string_view/typedefs.cc: New file.
4645 * unittests/basic_string_view/types/1.cc: New file.
4646
8345c4a2
SM
46472018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4648
4649 * common/gdb_string_view.h: Remove libstdc++ implementation
4650 details, adjust to gdb reality.
4651 * common/gdb_string_view.tcc: Likewise.
4652 * cli/cli-script.c (struct string_view): Remove.
4653 (user_args) <m_args>: Change element type to gdb::string_view.
4654 (user_args::insert_args): Adjust.
4655
7adcdf08
SM
46562018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4657
4658 * common/gdb_string_view.h: New file.
4659 * common/gdb_string_view.tcc: New file.
4660
41260ac2
SM
46612018-04-09 Simon Marchi <simon.marchi@polymtl.ca>
4662
4663 * ax_cxx_compile_stdcxx.m4: Sync with upstream.
4664 * configure: Re-generate.
4665
0bee6dd4
PA
46662018-04-09 Pedro Alves <palves@redhat.com>
4667
4668 * gdbarch.sh: Include "observable.h" instead of "observer.h".
4669 (set_target_gdbarch): Call
4670 gdb::observers::architecture_changed.notify instead of
4671 observer_notify_architecture_changed.
4672
6f14adc5
SM
46732018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4674
4675 * tracepoint.c (struct current_traceframe_cleanup): Remove.
4676 (do_restore_current_traceframe_cleanup): Remove.
4677 (restore_current_traceframe_cleanup_dtor): Remove.
4678 (make_cleanup_restore_current_traceframe): Remove.
4679 (scoped_restore_current_traceframe::scoped_restore_current_traceframe):
4680 New.
4681 * tracepoint.h (struct scoped_restore_current_traceframe): New.
4682 * infrun.c (fetch_inferior_event): Use
4683 scoped_restore_current_traceframe.
4684
b2bdb8cf
SM
46852018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4686
4687 * dwarf2read.h (struct dwarf2_per_objfile) <n_type_units>:
4688 Remove.
4689 <n_allocated_type_units>: Remove.
4690 <all_type_units>: Change to std::vector.
4691 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
4692 to std::vector change.
4693 (dwarf2_per_objfile::get_cutu): Likewise.
4694 (dwarf2_per_objfile::get_tu): Likewise.
4695 (create_signatured_type_table_from_index): Likewise.
4696 (create_signatured_type_table_from_debug_names): Likewise.
4697 (dw2_symtab_iter_next): Likewise.
4698 (dw2_print_stats): Likewise.
4699 (dw2_expand_all_symtabs): Likewise.
4700 (dw2_expand_marked_cus): Likewise.
4701 (dw2_debug_names_iterator::next): Likewise.
4702 (dwarf2_initialize_objfile): Likewise.
4703 (add_signatured_type_cu_to_table): Likewise.
4704 (create_all_type_units): Likewise.
4705 (add_type_unit): Likewise.
4706 (struct tu_abbrev_offset): Add constructor.
4707 (build_type_psymtabs_1): Adjust to std::vector change.
4708 (print_tu_stats): Likewise.
4709 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
4710 (write_debug_names): Likewise.
4711
b76e467d
SM
47122018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4713
4714 * dwarf2read.h (struct dwarf2_per_objfile) <all_comp_units>: Likewise.
4715 Make an std::vector.
4716 <n_comp_units>: Remove.
4717 * dwarf2read.c (dwarf2_per_objfile::~dwarf2_per_objfile): Adjust
4718 to std::vector change.
4719 (dwarf2_per_objfile::get_cutu): Likewise.
4720 (dwarf2_per_objfile::get_cu): Likewise.
4721 (create_cus_from_index): Likewise.
4722 (create_addrmap_from_index): Likewise.
4723 (create_addrmap_from_aranges): Likewise.
4724 (dwarf2_read_index): Likewise.
4725 (dw2_find_last_source_symtab): Likewise.
4726 (dw2_map_symtabs_matching_filename): Likewise.
4727 (dw2_symtab_iter_next): Likewise.
4728 (dw2_print_stats): Likewise.
4729 (dw2_expand_all_symtabs): Likewise.
4730 (dw2_expand_symtabs_with_fullname): Likewise.
4731 (dw2_expand_marked_cus): Likewise.
4732 (dw2_map_symbol_filenames): Likewise.
4733 (create_cus_from_debug_names): Likewise.
4734 (dwarf2_read_debug_names): Likewise.
4735 (dw2_debug_names_iterator::next): Likewise.
4736 (dwarf2_initialize_objfile): Likewise.
4737 (set_partial_user): Likewise.
4738 (dwarf2_build_psymtabs_hard): Likewise.
4739 (read_comp_units_from_section): Remove arguments, adjust to
4740 std::vector change.
4741 (create_all_comp_units): Adjust to std::vector and
4742 read_comp_units_from_section changes.
4743 (dwarf2_find_containing_comp_unit): Adjust to std::vector
4744 change.
4745 * dwarf-index-write.c (check_dwarf64_offsets): Likewise.
4746 (psyms_seen_size): Likewise.
4747 (write_gdbindex): Likewise.
4748 (write_debug_names): Likewise.
4749
12359b5e
SM
47502018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4751
4752 * dwarf2read.c (create_cus_from_index_list): Replace objfile arg
4753 with dwarf2_per_objfile.
4754 (create_cus_from_index): Likewise.
4755 (create_signatured_type_table_from_index): Likewise.
4756 (dwarf2_read_index): Likewise.
4757 (dwarf2_initialize_objfile): Likewise.
4758 (dwarf2_fetch_die_loc_sect_off): Get dwarf2_per_objfile from
4759 per_cu rather than get_dwarf2_per_objfile.
4760
ff4c9fec
SM
47612018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4762
4763 * dwarf2read.h (struct signatured_type): Forward declare.
4764 (struct dwarf2_per_objfile) <get_cutu, get_cu, get_tu>:
4765 New methods.
4766 * dwarf2read.c (dwarf2_per_objfile::get_cutu): Rename from...
4767 (dw2_get_cutu): ...this.
4768 (dwarf2_per_objfile::get_cu): Rename from...
4769 (dw2_get_cu): ...this.
4770 (dwarf2_per_objfile::get_tu): New.
4771 (create_addrmap_from_index): Adjust.
4772 (create_addrmap_from_aranges): Adjust.
4773 (dw2_find_last_source_symtab): Adjust.
4774 (dw2_map_symtabs_matching_filename): Adjust.
4775 (dw2_symtab_iter_next): Adjust.
4776 (dw2_print_stats): Adjust.
4777 (dw2_expand_all_symtabs): Adjust.
4778 (dw2_expand_symtabs_with_fullname): Adjust.
4779 (dw2_expand_marked_cus): Adjust.
4780 (dw_expand_symtabs_matching_file_matcher): Adjust.
4781 (dw2_map_symbol_filenames): Adjust.
4782 (dw2_debug_names_iterator::next): Adjust.
4783 (dwarf2_initialize_objfile): Adjust.
4784 (set_partial_user): Adjust.
4785 (dwarf2_build_psymtabs_hard): Adjust.
4786
5ca3fcb6
SM
47872018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4788
4789 * dwarf2read.c (create_signatured_type_table_from_debug_names):
4790 Remove unused variables.
4791 (dw2_map_symtabs_matching_filename): Likewise.
4792 (dwarf2_record_block_ranges): Likewise.
4793 (dwarf2_read_addr_index): Likewise.
4794 (follow_die_offset): Likewise.
4795
b2e586e8
SM
47962018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4797
4798 * progspace.c (clone_program_space): Pass SYMFILE_DEFER_BP_RESET
4799 to symbol_file_add_main.
4800
7c4e78cf
SM
48012018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4802
4803 PR mi/22299
4804 * mi/mi-console.c (do_fputc_async_safe): New.
4805 (mi_console_file::write_async_safe): New.
4806 (mi_console_file::flush): Adjust calls to fputstrn_unfiltered.
4807 * mi/mi-console.h (class mi_console_file) <write_async_safe>:
4808 New.
4809 * ui-file.c (ui_file::putstrn): Adjust call to
4810 fputstrn_unfiltered.
4811 * utils.c (printchar): Replace do_fputs and do_fprintf
4812 parameters by do_fputc.
4813 (fputstr_filtered): Adjust call to printchar.
4814 (fputstr_unfiltered): Likewise.
4815 (fputstrn_filtered): Likewise.
4816 (fputstrn_unfiltered): Add do_fputc parameter, pass to
4817 printchar.
4818 * utils.h (do_fputc_ftype): New typedef.
4819 (fputstrn_unfiltered): Add do_fputc parameter.
4820
5dc026d3
SM
48212018-04-07 Simon Marchi <simon.marchi@polymtl.ca>
4822
4823 * regformats/i386/i386-avx.dat: Remove.
4824
c912f608
SM
48252018-04-07 Simon Marchi <simon.marchi@ericsson.com>
4826
4827 PR gdb/22979
4828 * amd64-tdep.c (amd64_none_init_abi): New function.
4829 (amd64_x32_none_init_abi): New function.
4830 (_initialize_amd64_tdep): Register handlers for x86-64 and
4831 x64_32 with GDB_OSABI_NONE.
4832 * osabi.c (gdbarch_init_osabi): Allow running handlers for the
4833 GDB_OSABI_NONE osabi.
4834
26540402
SM
48352018-04-07 Simon Marchi <simon.marchi@ericsson.com>
4836
4837 PR gdb/22980
4838 * defs.h (enum gdb_osabi): Remove GDB_OSABI_UNINITIALIZED, add
4839 GDB_OSABI_NONE.
4840 * arch-utils.c (gdbarch_info_init): Don't set info->osabi.
4841 * osabi.c (gdb_osabi_names): Add "unknown" entry.
4842
9018be22
SM
48432018-04-07 Simon Marchi <simon.marchi@ericsson.com>
4844
4845 * common/byte-vector.h (char_vector): New type.
4846 * target.h (target_read_alloc): Return
4847 gdb::optional<byte_vector>.
4848 (target_read_stralloc): Return gdb::optional<char_vector>.
4849 (target_get_osdata): Return gdb::optional<char_vector>.
4850 * target.c (target_read_alloc_1): Templatize. Replacement
4851 manual memory management with vector.
4852 (target_read_alloc): Change return type, adjust.
4853 (target_read_stralloc): Change return type, adjust.
4854 (target_get_osdata): Change return type, adjust.
4855 * auxv.c (struct auxv_info) <length>: Remove.
4856 <data>: Change type to gdb::optional<byte_vector>.
4857 (auxv_inferior_data_cleanup): Free auxv_info with delete.
4858 (get_auxv_inferior_data): Allocate auxv_info with new, adjust.
4859 (target_auxv_search): Adjust.
4860 (fprint_target_auxv): Adjust.
4861 * avr-tdep.c (avr_io_reg_read_command): Adjust.
4862 * linux-tdep.c (linux_spu_make_corefile_notes): Adjust.
4863 (linux_make_corefile_notes): Adjust.
4864 * osdata.c (get_osdata): Adjust.
4865 * remote.c (remote_get_threads_with_qxfer): Adjust.
4866 (remote_memory_map): Adjust.
4867 (remote_traceframe_info): Adjust.
4868 (btrace_read_config): Adjust.
4869 (remote_read_btrace): Adjust.
4870 (remote_pid_to_exec_file): Adjust.
4871 * solib-aix.c (solib_aix_get_library_list): Adjust.
4872 * solib-dsbt.c (decode_loadmap): Don't free buf.
4873 (dsbt_get_initial_loadmaps): Adjust.
4874 * solib-svr4.c (svr4_current_sos_via_xfer_libraries): Adjust.
4875 * solib-target.c (solib_target_current_sos): Adjust.
4876 * tracepoint.c (sdata_make_value): Adjust.
4877 * xml-support.c (xinclude_start_include): Adjust.
4878 (xml_fetch_content_from_file): Adjust.
4879 * xml-support.h (xml_fetch_another): Change return type.
4880 (xml_fetch_content_from_file): Change return type.
4881 * xml-syscall.c (xml_init_syscalls_info): Adjust.
4882 * xml-tdesc.c (file_read_description_xml): Adjust.
4883 (fetch_available_features_from_target): Change return type.
4884 (target_fetch_description_xml): Adjust.
4885 (target_read_description_xml): Adjust.
4886
14c88955
TT
48872018-04-06 Tom Tromey <tom@tromey.com>
4888
4889 * value.c (~value): Update.
4890 (struct value) <contents>: Now unique_xmalloc_ptr.
4891 (value_contents_bits_eq, allocate_value_contents)
4892 (value_contents_raw, value_contents_all_raw)
4893 (value_contents_for_printing, value_contents_for_printing_const)
4894 (set_value_enclosing_type): Update.
4895
0c7e6dd8
TT
48962018-04-06 Tom Tromey <tom@tromey.com>
4897
4898 * value.c (range_s): Remove typedef, VEC.
4899 (struct range): Add operator<.
4900 (range_lessthan): Remove.
4901 (ranges_contain): Change type.
4902 (~value): Update.
4903 (struct value) <unavailable, optimized_out>: Now std::vector.
4904 (value_entirely_available)
4905 (value_entirely_covered_by_range_vector)
4906 (value_entirely_unavailable, value_entirely_optimized_out):
4907 Update.
4908 (insert_into_bit_range_vector): Change argument type.
4909 (find_first_range_overlap): Likewise.
4910 (struct ranges_and_idx, value_contents_bits_eq)
4911 (require_not_optimized_out, require_available): Update.
4912 (ranges_copy_adjusted): Change argument types.
4913 (value_optimized_out, value_copy, value_fetch_lazy): Update.
4914
2c8331b9
TT
49152018-04-06 Tom Tromey <tom@tromey.com>
4916
4917 * value.c (~value): Update.
4918 (struct value) <parent>: Now a value_ref_ptr.
4919 (value_parent, set_value_parent, value_address, value_copy):
4920 Update.
4921
466ce3ae
TT
49222018-04-06 Tom Tromey <tom@tromey.com>
4923
4924 * value.c (struct value): Add constructor, destructor, and member
4925 initializers.
4926 (allocate_value_lazy, value_decref): Update.
4927
062d818d
TT
49282018-04-06 Tom Tromey <tom@tromey.com>
4929
4930 * value.c (struct value) <released, next>: Remove.
4931 (all_values): Now a std::vector.
4932 (allocate_value_lazy): Update.
4933 (value_next): Remove.
4934 (value_mark, value_free_to_mark, release_value)
4935 (value_release_to_mark): Update.
4936
a6535de1
TT
49372018-04-06 Tom Tromey <tom@tromey.com>
4938
4939 * value.h (fetch_subexp_value, value_release_to_mark): Update.
4940 (free_value_chain): Remove.
4941 * value.c (free_value_chain): Remove.
4942 (value_release_to_mark): Return a std::vector.
4943 * ppc-linux-nat.c (num_memory_accesses): Change "chain" to a
4944 std::vector.
4945 (check_condition): Update.
4946 * eval.c (fetch_subexp_value): Change "val_chain" to a
4947 std::vector.
4948 * breakpoint.c (update_watchpoint): Update.
4949 (can_use_hardware_watchpoint): Change "vals" to a std::vector.
4950
b5621201
TT
49512018-04-06 Tom Tromey <tom@tromey.com>
4952
4953 * value.h (free_all_values): Remove.
4954 * value.c (free_all_values): Remove.
4955
4d0266a0
TT
49562018-04-06 Tom Tromey <tom@tromey.com>
4957
4958 * value.c (VALUE_HISTORY_CHUNK, struct value_history_chunk)
4959 (value_history_chain, value_history_count): Remove.
4960 (value_history): New global.
4961 (record_latest_value, access_value_history, show_values)
4962 (preserve_values): Update.
4963
b4d61099
TT
49642018-04-06 Tom Tromey <tom@tromey.com>
4965
4966 * varobj.h (struct varobj) <value>: Now a value_ref_ptr.
4967 * varobj.c (varobj_set_display_format, varobj_set_value)
4968 (install_default_visualizer, construct_visualizer)
4969 (install_new_value, ~varobj, varobj_get_value_type)
4970 (my_value_of_variable, varobj_editable_p): Update.
4971 * c-varobj.c (c_describe_child, c_value_of_variable)
4972 (cplus_number_of_children, cplus_describe_child): Update.
4973 * ada-varobj.c (ada_number_of_children, ada_name_of_child)
4974 (ada_path_expr_of_child, ada_value_of_child, ada_type_of_child)
4975 (ada_value_of_variable, ada_value_is_changeable_p): Update.
4976
9b558729
TT
49772018-04-06 Tom Tromey <tom@tromey.com>
4978
4979 * printcmd.c (last_examine_address): Change type to
4980 value_ref_ptr.
4981 (do_examine, x_command): Update.
4982
850645cf
TT
49832018-04-06 Tom Tromey <tom@tromey.com>
4984
4985 * value.c (release_value): Update.
4986 * breakpoint.h (struct watchpoint) <val>: Now a value_ref_ptr.
4987 (struct bpstats) <val>: Now a value_ref_ptr.
4988 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
4989 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
4990 (~watchpoint, print_it_watchpoint, watch_command_1)
4991 (invalidate_bp_value_on_memory_change): Update.
4992
22bc8444
TT
49932018-04-06 Tom Tromey <tom@tromey.com>
4994
4995 * varobj.c (varobj_clear_saved_item)
4996 (update_dynamic_varobj_children, install_new_value, ~varobj):
4997 Update.
4998 * value.h (value_incref): Move declaration earlier.
4999 (value_decref): Rename from value_free.
5000 (struct value_ref_policy): New.
5001 (value_ref_ptr): New typedef.
5002 (struct value_deleter): Remove.
5003 (gdb_value_up): Remove typedef.
5004 (release_value): Change return type.
5005 (release_value_or_incref): Remove.
5006 * value.c (set_value_parent): Update.
5007 (value_incref): Change return type.
5008 (value_decref): Rename from value_free.
5009 (value_free_to_mark, free_all_values, free_value_chain): Update.
5010 (release_value): Return value_ref_ptr.
5011 (release_value_or_incref): Remove.
5012 (record_latest_value, set_internalvar, clear_internalvar):
5013 Update.
5014 * stack.c (info_frame_command): Don't call value_free.
5015 * python/py-value.c (valpy_dealloc, valpy_new)
5016 (value_to_value_object): Update.
5017 * printcmd.c (do_examine): Update.
5018 * opencl-lang.c (lval_func_free_closure): Update.
5019 * mi/mi-main.c (register_changed_p): Don't call value_free.
5020 * mep-tdep.c (mep_frame_prev_register): Don't call value_free.
5021 * m88k-tdep.c (m88k_frame_prev_register): Don't call value_free.
5022 * m68hc11-tdep.c (m68hc11_frame_prev_register): Don't call
5023 value_free.
5024 * guile/scm-value.c (vlscm_free_value_smob)
5025 (vlscm_scm_from_value): Update.
5026 * frame.c (frame_register_unwind, frame_unwind_register_signed)
5027 (frame_unwind_register_unsigned, get_frame_register_bytes)
5028 (put_frame_register_bytes): Don't call value_free.
5029 * findvar.c (address_from_register): Don't call value_free.
5030 * dwarf2read.c (dwarf2_compute_name): Don't call value_free.
5031 * dwarf2loc.c (entry_data_value_free_closure)
5032 (value_of_dwarf_reg_entry, free_pieced_value_closure)
5033 (dwarf2_evaluate_loc_desc_full): Update.
5034 * breakpoint.c (update_watchpoint, breakpoint_init_inferior)
5035 (~bpstats, bpstats, bpstat_clear_actions, watchpoint_check)
5036 (~watchpoint, watch_command_1)
5037 (invalidate_bp_value_on_memory_change): Update.
5038 * alpha-tdep.c (alpha_register_to_value): Don't call value_free.
5039
7f8a5d38
SM
50402018-04-06 Simon Marchi <simon.marchi@polymtl.ca>
5041
5042 PR gdb/23022
5043 * warning.m4: Add -Wno-error=deprecated-register.
5044 * configure: Re-generate.
5045
8a76bd3b
TT
50462018-04-05 Tom Tromey <tom@tromey.com>
5047
5048 * linespec.h: Remove include of "vec.h".
5049
8e8d776e
TT
50502018-04-05 Tom Tromey <tom@tromey.com>
5051
5052 * linespec.c (typep): Remove typedef.
5053 (find_methods, find_superclass_methods): Take a std::vector.
5054 (find_method): Use std::vector.
5055
9b2f8581
TT
50562018-04-05 Tom Tromey <tom@tromey.com>
5057
5058 * utils.c (compare_strings): Remove.
5059 * utils.h (compare_strings): Remove.
5060 * objc-lang.h (find_imps): Update.
5061 * objc-lang.c (find_methods): Take a std::vector.
5062 (uniquify_strings, find_imps): Likewise.
5063 * linespec.c (find_methods): Take a std::vector.
5064 (decode_objc): Use std::vector.
5065 (add_all_symbol_names_from_pspace, find_superclass_methods): Take
5066 a std::vector.
5067 (find_method, find_function_symbols): Use std::vector.
5068
459a2e4c
TT
50692018-04-05 Tom Tromey <tom@tromey.com>
5070
5071 * completer.c (completion_tracker::completion_tracker): Remove
5072 cast.
5073 (completion_tracker::discard_completions): Likewise.
5074 * breakpoint.c (ambiguous_names_p): Remove cast.
5075 * ada-lang.c (_initialize_ada_language): Remove cast.
5076 * utils.h (streq): Update.
5077 (streq_hash): Add new declaration.
5078 * utils.c (streq): Return bool.
5079 (streq_hash): New function.
5080
9be2c17a
TT
50812018-04-05 Tom Tromey <tom@tromey.com>
5082
5083 * linespec.c (event_location_to_sals) <case ADDRESS_LOCATION>:
5084 Remove a string copy.
5085
f73c6ece
TT
50862018-04-05 Tom Tromey <tom@tromey.com>
5087
5088 * linespec.c (filter_results): Use std::vector.
5089 (decode_line_2, decode_line_full): Update.
5090
53a0f8a2
TT
50912018-04-05 Tom Tromey <tom@tromey.com>
5092
5093 * linespec.c (canonical_to_fullform): Return std::string.
5094 (filter_results): Update.
5095 (struct decode_line_2_item): Add constructor.
5096 <fullform, displayform>: Now std::string.
5097 (decode_line_2_compare_items): Now a std::sort comparator.
5098 (decode_line_2): Update.
5099
a5b5adf5
TT
51002018-04-05 Tom Tromey <tom@tromey.com>
5101
5102 * linespec.c (copy_token_string): Return a unique_xmalloc_ptr.
5103 (unexpected_linespec_error): Update.
5104 (linespec_parse_basic, parse_linespec): Update.
5105
6a307fc5
TT
51062018-04-05 Tom Tromey <tom@tromey.com>
5107
5108 * linespec.c (linespec_parse_basic): Reindent.
5109
41c1efc6
TT
51102018-04-05 Tom Tromey <tom@tromey.com>
5111
5112 * minsyms.h (iterate_over_minimal_symbols): Update.
5113 * minsyms.c (iterate_over_minimal_symbols): Take a
5114 gdb::function_view.
5115 * linespec.c (struct collect_minsyms): Remove.
5116 (compare_msyms): Now a std::sort comparator.
5117 (add_minsym): Add parameters.
5118 (search_minsyms_for_name): Update. Use std::vector.
5119
c5edbf3d
TT
51202018-04-03 Tom Tromey <tom@tromey.com>
5121
5122 * mipsread.c (read_alphacoff_dynamic_symtab): Use
5123 gdb::byte_vector.
5124
b39efc48
WP
51252018-04-02 Weimin Pan <weimin.pan@oracle.com>
5126
5127 * MAINTAINERS (Write After Approval): Add Weimin Pan.
5128
121ad66c 51292018-04-02 Weimin Pan <weimin.pan@oracle.com>
79f18731
WP
5130
5131 PR gdb/16959
5132 * cp-valprint.c: (cp_print_static_field) Fix infinite recursion when
5133 printing static type.
5134
09473be8
TT
51352018-04-01 Tom Tromey <tom@tromey.com>
5136
5137 * rs6000-nat.c (rs6000_ptrace_ldinfo): Return a byte_vector.
5138 (rs6000_xfer_shared_libraries): Update.
5139
ec1f2d91
SM
51402018-04-01 Simon Marchi <simon.marchi@polymtl.ca>
5141
5142 * common/gdb_vecs.h (char_ptr): Remove.
5143 * tracepoint.c (encode_actions_1): Remove usage of char_ptr.
5144
d8611974
SM
51452018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5146
5147 * guile/scm-utils.c (gdbscm_parse_function_args): Replace VEC
5148 with std::vector.
5149 * common/gdb_vecs.h (DEF_VEC_P (char_ptr)): Remove.
5150
a18ba4e4
SM
51512018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
5152
5153 * tracepoint.h (struct uploaded_tp): Initialize fields.
5154 <actions, step_actions, cmd_strings>: Change type to
5155 std::vector<char *>.
5156 * tracepoint.c (get_uploaded_tp): Allocate with new.
5157 (free_uploaded_tps): Free with delete.
5158 (parse_tracepoint_definition): Adjust to std::vector change.
5159 * breakpoint.c (read_uploaded_action): Likewise.
5160 (create_tracepoint_from_upload): Likewise.
5161 * ctf.c (ctf_write_uploaded_tp): Likewise.
5162 (SET_ARRAY_FIELD): Likewise.
5163 * tracefile-tfile.c (tfile_write_uploaded_tp): Likewise.
5164
a7961323
TT
51652018-03-30 Tom Tromey <tom@tromey.com>
5166
5167 * solib-svr4.c (lm_info_read): Use gdb::byte_vector. Return
5168 std::unique_ptr.
5169 (svr4_keep_data_in_core): Update.
5170 (svr4_read_so_list): Update.
5171
e83e4e24
TT
51722018-03-30 Tom Tromey <tom@tromey.com>
5173
5174 * windows-nat.c (handle_output_debug_string, handle_exception):
5175 Update.
5176 * target.h (target_read_string): Update.
5177 * target.c (target_read_string): Change "string" to
5178 unique_xmalloc_ptr.
5179 * solib-svr4.c (open_symbol_file_object, svr4_read_so_list):
5180 Update.
5181 * solib-frv.c (frv_current_sos): Update.
5182 * solib-dsbt.c (dsbt_current_sos): Update.
5183 * solib-darwin.c (darwin_current_sos): Update.
5184 * linux-thread-db.c (inferior_has_bug): Update.
5185 * expprint.c (print_subexp_standard) <case OP_OBJC_MSGCALL>:
5186 Update. Remove alloca.
5187 * ada-lang.c (ada_main_name): Update.
5188
263db9a1
TT
51892018-03-30 Tom Tromey <tom@tromey.com>
5190
5191 * dwarf2read.c (struct free_dwo_file_cleanup_data): Remove.
5192 (struct dwo_file_deleter): New.
5193 (dwo_file_up): New typedef.
5194 (open_and_init_dwo_file): Use dwo_file_up.
5195 (free_dwo_file_cleanup): Remove.
5196
5dafb3d1
TT
51972018-03-30 Tom Tromey <tom@tromey.com>
5198
5199 * dwarf2read.c (free_dwo_file): Remove "objfile" parameter.
5200 (free_dwo_file_cleanup, free_dwo_file_from_slot): Update.
5201
11ed8cad
TT
52022018-03-30 Tom Tromey <tom@tromey.com>
5203
5204 * dwarf2read.c (class free_cached_comp_units): New class.
5205 (dw2_instantiate_symtab, dwarf2_build_psymtabs_hard): Use it.
5206 (free_cached_comp_units): Remove function.
5207
9ae79dac
TT
52082018-03-30 Tom Tromey <tom@tromey.com>
5209
5210 * utils.h (make_cleanup_unpush_target): Remove.
5211 * inf-ptrace.c (struct target_unpusher): New.
5212 (target_unpush_up) New typedef.
5213 (inf_ptrace_create_inferior, inf_ptrace_attach): Use
5214 target_unpush_up.
5215 * utils.c (do_unpush_target, make_cleanup_unpush_target): Remove.
5216
5aa89276
TT
52172018-03-27 Tom Tromey <tom@tromey.com>
5218
5219 * utils.c (prompt_for_continue): Use unique_xmalloc_ptr.
5220
1dbeed45
TT
52212018-03-27 Pedro Alves <palves@redhat.com>
5222 Tom Tromey <tom@tromey.com>
5223
5224 * top.c (class gdb_readline_wrapper_cleanup): Add constructor,
5225 destructor. Now a class.
5226 (gdb_readline_wrapper_cleanup): Remove function.
5227 (gdb_readline_wrapper): Remove cleanups.
5228
c819b2c0
TT
52292018-03-27 Tom Tromey <tom@tromey.com>
5230
5231 * typeprint.h (struct type_print_options) <local_typedefs,
5232 global_typedefs>: Remove "struct" keyword.
5233 (class typedef_hash_table): New class.
5234 (recursively_update_typedef_hash, add_template_parameters)
5235 (create_typedef_hash, free_typedef_hash, copy_typedef_hash)
5236 (find_typedef_in_hash): Don't declare.
5237 * typeprint.c (struct typedef_hash_table): Move to typeprint.h.
5238 (typedef_hash_table::recursively_update): Rename from
5239 recursively_update_typedef_hash. Now a member.
5240 (typedef_hash_table::add_template_parameters): Rename from
5241 add_template_parameters. Now a member.
5242 (typedef_hash_table::typedef_hash_table): Now a constructor;
5243 rename from create_typedef_hash.
5244 (typedef_hash_table::~typedef_hash_table): Now a destructor;
5245 rename from free_typedef_hash.
5246 (do_free_typedef_hash, make_cleanup_free_typedef_hash)
5247 (do_free_global_table): Remove.
5248 (typedef_hash_table::typedef_hash_table): New constructor; renamed
5249 from copy_type_recursive.
5250 (create_global_typedef_table): Remove.
5251 (typedef_hash_table::find_global_typedef): Now a member of
5252 typedef_hash_table.
5253 (typedef_hash_table::find_typedef): Rename from
5254 find_typedef_in_hash; now a member.
5255 (whatis_exp): Update.
5256 * extension.h (struct ext_lang_type_printers): Add constructor and
5257 destructor.
5258 (start_ext_lang_type_printers, free_ext_lang_type_printers): Don't
5259 declare.
5260 * extension.c (ext_lang_type_printers::ext_lang_type_printers):
5261 Now a constructor; rename from start_ext_lang_type_printers.
5262 (ext_lang_type_printers): Now a destructor; rename from
5263 free_ext_lang_type_printers.
5264 * c-typeprint.c (find_typedef_for_canonicalize, c_print_type_1):
5265 Update.
5266 (c_type_print_base_struct_union): Update. Remove cleanups.
5267
608219fb
TT
52682018-03-27 Tom Tromey <tom@tromey.com>
5269
5270 * dwarf-index-write.c: Include <cmath>.
5271
3fcded8f
JB
52722018-03-27 Joel Brobecker <brobecker@adacore.com>
5273
5274 * NEWS: Add entry describing new "set|show varsize-limit" command.
5275 * ada-lang.c (_initialize_ada_language): Add "set/show varsize-limit"
5276 command.
5277 * printcmd.c (_initialize_printcmd): Add "set var" alias of
5278 "set variable".
5279
cd4fb1b2
SM
52802018-03-27 Simon Marchi <simon.marchi@ericsson.com>
5281
5282 * Makefile.in (COMMON_SFILES): Add dwarf-index-common.c and
5283 dwarf-index-write.c
5284 (HFILES_NO_SRCDIR): Add dwarf-index-common.h and dwarf2read.h.
5285 * dwarf-index-common.c: New file.
5286 * dwarf-index-common.h: New file.
5287 * dwarf-index-write.c: New file.
5288 * dwarf2read.c: Include dwarf2read.h and dwarf-index-common.h.
5289 (struct dwarf2_section_info): Move from here.
5290 (dwarf2_section_info_def): Likewise.
5291 (DEF_VEC_O (dwarf2_section_info_def)): Likewise.
5292 (offset_type): Likewise.
5293 (DW2_GDB_INDEX_SYMBOL_STATIC_SET_VALUE): Likewise.
5294 (DW2_GDB_INDEX_SYMBOL_KIND_SET_VALUE): Likewise.
5295 (DW2_GDB_INDEX_CU_SET_VALUE): Likewise.
5296 (byte_swap): Likewise.
5297 (MAYBE_SWAP): Likewise.
5298 (dwarf2_per_cu_ptr): Likewise.
5299 (DEF_VEC_P (dwarf2_per_cu_ptr)): Likewise.
5300 (struct tu_stats): Likewise.
5301 (struct dwarf2_per_objfile): Likewise.
5302 (struct dwarf2_per_cu_data): Likewise.
5303 (struct signatured_type): Likewise.
5304 (sig_type_ptr): Likewise.
5305 (DEF_VEC_P (sig_type_ptr)): Likewise.
5306 (INDEX4_SUFFIX): Likewise.
5307 (INDEX5_SUFFIX): Likewise.
5308 (DEBUG_STR_SUFFIX): Likewise.
5309 (dwarf2_read_section): Make non-static.
5310 (mapped_index_string_hash): Move from here.
5311 (dwarf5_djb_hash): Likewise.
5312 (file_write): Likewise.
5313 (class data_buf): Likewise.
5314 (struct symtab_index_entry): Likewise.
5315 (struct mapped_symtab): Likewise.
5316 (find_slot): Likewise.
5317 (hash_expand): Likewise.
5318 (add_index_entry): Likewise.
5319 (uniquify_cu_indices): Likewise.
5320 (class c_str_view): Likewise.
5321 (class c_str_view_hasher): Likewise.
5322 (class vector_hasher): Likewise.
5323 (write_hash_table): Likewise.
5324 (psym_index_map): Likewise.
5325 (struct addrmap_index_data): Likewise.
5326 (add_address_entry): Likewise.
5327 (add_address_entry_worker): Likewise.
5328 (write_address_map): Likewise.
5329 (symbol_kind): Likewise.
5330 (write_psymbols): Likewise.
5331 (struct signatured_type_index_data): Likewise.
5332 (write_one_signatured_type): Likewise.
5333 (recursively_count_psymbols): Likewise.
5334 (recursively_write_psymbols): Likewise.
5335 (class debug_names): Likewise.
5336 (check_dwarf64_offsets): Likewise.
5337 (psyms_seen_size): Likewise.
5338 (write_gdbindex): Likewise.
5339 (write_debug_names): Likewise.
5340 (assert_file_size): Likewise.
5341 (write_psymtabs_to_index): Likewise.
5342 (save_gdb_index_command): Likewise.
5343 (_initialize_dwarf2_read): Don't register the "save gdb-index"
5344 command.
5345 * dwarf2read.h: New file.
5346
59cc4834
JB
53472018-03-27 Joel Brobecker <brobecker@adacore.com>
5348
5349 PR gdb/22670
5350 * dwarf2read.c (dwarf2_physname): Do not return the demangled
5351 symbol name if the CU's language stores symbol names in linkage
5352 format.
5353 * language.h (struct language_defn)
5354 <la_store_sym_names_in_linkage_form_p>: New field. Adjust
5355 all instances of this struct.
5356
67501539
TT
53572018-03-26 Tom Tromey <tom@tromey.com>
5358
5359 * stack.c (backtrace_command_1): Remove verbose code.
5360
76c939ac
TT
53612018-03-26 Tom Tromey <tom@tromey.com>
5362
5363 * python/py-framefilter.c (py_print_type): Don't catch
5364 exceptions. Return void.
5365 (py_print_value): Likewise.
5366 (py_print_single_arg): Likewise.
5367 (enumerate_args): Don't catch exceptions.
5368 (py_print_args): Likewise.
5369 (py_print_frame): Likewise.
5370 (gdbpy_apply_frame_filter): Catch exceptions here.
5371
9507b29c
TT
53722018-03-26 Tom Tromey <tom@tromey.com>
5373
5374 * stack.c (_initialize_stack): Remove trailing newlines from help
5375 text. Add "Usage" line to "backtrace" help.
5376
eb68e487
TT
53772018-03-26 Tom Tromey <tom@tromey.com>
5378
5379 PR python/16486:
5380 * python/py-framefilter.c (py_print_args): Call wrap_hint.
5381
1f111921
TT
53822018-03-26 Tom Tromey <tom@tromey.com>
5383
5384 * python/py-framefilter.c (py_print_single_arg): Return
5385 EXT_LANG_BT_ERROR from catch.
5386
fb7eb8b5
TT
53872018-03-26 Tom Tromey <tom@tromey.com>
5388
5389 PR backtrace/15584:
5390 * stack.c (backtrace_command_1): Move some code into no-filters
5391 "if".
5392
4ca59a9f
TT
53932018-03-26 Tom Tromey <tom@tromey.com>
5394
5395 * python/py-framefilter.c (throw_quit_or_print_exception): New
5396 function.
5397 (gdbpy_apply_frame_filter): Use it.
5398
92256134
TT
53992018-03-26 Tom Tromey <tom@tromey.com>
5400
5401 PR cli/17716:
5402 * python/py-framefilter.c (py_print_type, py_print_value)
5403 (enumerate_args, py_print_args, gdbpy_apply_frame_filter): Use
5404 RETURN_MASK_ERROR.
5405
7a630bc2
TT
54062018-03-26 Tom Tromey <tom@tromey.com>
5407
5408 * python/py-framefilter.c (enumerate_args): Use
5409 gdb::unique_xmalloc_ptr.
5410
63283d4a
TT
54112018-03-26 Tom Tromey <tom@tromey.com>
5412
5413 * python/py-framefilter.c (py_print_frame): Return
5414 EXT_LANG_BT_OK.
5415 (gdbpy_apply_frame_filter): Update comment.
5416 * extension.h (enum ext_lang_bt_status) <EXT_LANG_BT_COMPLETED>:
5417 Remove.
5418 <EXT_LANG_BT_NO_FILTERS>: Change value.
5419
978d6c75
TT
54202018-03-26 Tom Tromey <tom@tromey.com>
5421
5422 PR backtrace/15582:
5423 * stack.c (backtrace_command): Parse "hide" argument.
5424 * python/py-framefilter.c (py_print_frame): Handle PRINT_HIDE.
5425 * extension.h (enum frame_filter_flags) <PRINT_HIDE>: New
5426 constant.
5427
1cf7e640
TT
54282018-03-26 Tom Tromey <tom@tromey.com>
5429
5430 * stack.c (backtrace_command_1): Remove "show_locals" parameter,
5431 add "flags".
5432 (backtrace_command): Remove "fulltrace", add "flags".
5433
ea3b0687
TT
54342018-03-26 Tom Tromey <tom@tromey.com>
5435
5436 * stack.c (backtrace_command): Rewrite command line parsing.
5437
9f034d75
SM
54382018-03-26 Simon Marchi <simon.marchi@ericsson.com>
5439
5440 * dwarf2read.c (DEF_VEC_I(offset_type)): Remove.
5441
ce1459e5
SM
54422018-03-26 Simon Marchi <simon.marchi@ericsson.com>
5443
5444 * filename-seen-cache.h: Add include guard.
5445
4f7ae6f5
KS
54462018-03-26 Keith Seitz <keiths@redhat.com>
5447
5448 * symfile.c (place_section): Remove "struct" from section_addr_info
5449 in comment.
5450 * windows-nat.c (struct safe_symbol_file_add_args) <addrs>: Remove
5451 "struct" keyword from section_addr_info.
5452
5cd3e386
AH
54532018-03-26 Alan Hayward <alan.hayward@arm.com>
5454
5455 * regformats/regdef.h (reg): Add constructors.
5456
3e5ef9a4
PA
54572018-03-25 Pedro Alves <palves@redhat.com>
5458
5459 * eval.c (evaluate_funcall): Swap OP_VAR_MSYM_VALUE/OP_VAR_VALUE
5460 if then/else bodies in var_func_name extraction.
5461
c88d2fcc 54622018-03-23 Weimin Pan <weimin.pan@oracle.com>
bce02d88
WP
5463
5464 * minsyms.c (lookup_minimal_symbol_and_objfile): Use
5465 lookup_minimal_symbol() to find symbol entry.
5466 * minsyms.h (lookup_minimal_symbol_and_objfile): Update comment.
5467
b7fee5a3
KS
54682018-03-23 Keith Seitz <keiths@redhat.com>
5469
5470 PR c++/22968
5471 * dwarf2read.c (scan_partial_symbols): Scan structs/classes for
5472 nested type definitions for C++, too.
5473
2cc9b304
TT
54742018-03-23 Tom Tromey <tom@tromey.com>
5475
5476 * machoread.c (struct oso_el): Add a constructor. Don't define as
5477 a typedef.
5478 (macho_register_oso): Remove.
5479 (macho_symtab_read): Take a std::vector.
5480 (oso_el_compare_name): Now a std::sort comparator.
5481 (macho_symfile_read_all_oso): Take a std::vector.
5482 (macho_symfile_read): Use std::vector. Remove cleanups.
5483
a2b2bc12
TT
54842018-03-22 Tom Tromey <tom@tromey.com>
5485
5486 * record-full.c (record_full_exec_insn): Use gdb::byte_vector.
5487 (record_full_goto_bookmark): Use std::string.
5488
7a8f494c
PFC
54892018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5490
5491 PR tdep/18295
5492 * rs6000-tdep.c (skip_prologue): Match both stwux and stdux
5493 a single mask.
5494
dd6d677f
PFC
54952018-03-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5496
5497 * rs6000-tdep.c (store_insn_p): New function.
5498 (skip_prologue): New variable alloca_reg_offset. Set lr_reg
5499 and cr_reg to their unshifted values. Use store_insn_p to
5500 match LR saves using either R1 or fdata->alloca_reg. Use
5501 store_insn_p to match CR saves. Set alloca_reg_offset
5502 when alloca_reg and framep are set. Remove lr_reg shift
5503 when assigning to fdata->lr_register.
5504
26d6cec4
AA
55052018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
5506
5507 * linux-tdep.c (linux_info_proc): For "info proc cmdline", print
5508 command line args instead of emitting a warning.
5509
5d9310c4
SM
55102018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
5511
5512 * tracepoint.h (struct static_tracepoint_marker): Initialize
5513 fields, define default constructor, move constructor and move
5514 assignment, disable the rest.
5515 <str_id, extra>: Make std::string.
5516 (release_static_tracepoint_marker): Remove.
5517 (free_current_marker): Remove.
5518 * tracepoint.c (free_current_marker): Remove.
5519 (parse_static_tracepoint_marker_definition): Adjust to
5520 std::string, use new hex2str overload.
5521 (release_static_tracepoint_marker): Remove.
5522 (print_one_static_tracepoint_marker): Get marker by reference
5523 and adjust to std::string.
5524 (info_static_tracepoint_markers_command): Adjust to std::vector
5525 changes
5526 * target.h (static_tracepoint_marker_p): Remove typedef.
5527 (DEF_VEC_P(static_tracepoint_marker_p)): Remove.
5528 (struct target_ops) <to_static_tracepoint_marker_at>: Return
5529 bool.
5530 <to_static_tracepoint_markers_by_strid>: Return std::vector.
5531 * target-debug.h
5532 (target_debug_print_VEC_static_tracepoint_marker_p_p): Remove.
5533 (target_debug_print_std_vector_static_tracepoint_marker): New.
5534 (target_debug_print_struct_static_tracepoint_marker_p): Rename
5535 to...
5536 (target_debug_print_static_tracepoint_marker_p): ... this.
5537 * target-delegates.c: Re-generate.
5538 * breakpoint.h (struct tracepoint) <static_trace_marker_id>:
5539 Make std::string.
5540 * breakpoint.c (init_breakpoint_sal): Adjust to std::string.
5541 (decode_static_tracepoint_spec): Adjust to std::vector.
5542 (tracepoint_print_one_detail): Adjust to std::string.
5543 (strace_marker_decode_location): Adjust to std::string.
5544 (update_static_tracepoint): Adjust to std::string, remove call
5545 to release_static_tracepoint_marker.
5546 * linux-nat.c (linux_child_static_tracepoint_markers_by_strid):
5547 Adjust to std::vector.
5548 * remote.c (remote_static_tracepoint_marker_at): Return bool.
5549 (remote_static_tracepoint_markers_by_strid): Adjust to
5550 std::vector.
5551 * common/rsp-low.h (hex2str): New overload with explicit count
5552 of bytes.
5553 * common/rsp-low.c (hex2str): New overload with explicit count
5554 of bytes.
5555 * unittests/rsp-low-selftests.c (test_hex2str): New function.
5556 (_initialize_rsp_low_selftests): Add test_hex2str test.
5557 * unittests/tracepoint-selftests.c
5558 (test_parse_static_tracepoint_marker_definition): Adjust to
5559 std::string.
5560
62c222b6
SM
55612018-03-22 Simon Marchi <simon.marchi@polymtl.ca>
5562
5563 * tracepoint.c (parse_static_tracepoint_marker_definition):
5564 Consider case where the definition is followed by more
5565 definitions.
5566 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5567 tracepoint-selftests.c.
5568 * unittests/tracepoint-selftests.c: New.
5569
7eb2418f
PFC
55702018-03-21 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
5571
5572 * MAINTAINERS (Write After Approval): Add Pedro Franco de
5573 Carvalho.
5574
7cbe16e9
SR
55752018-03-20 Stephen Roberts <stephen.roberts@arm.com>
5576
3d6b3b82 5577 * symtab.c (find_pc_sect_line): fixed indentation.
7cbe16e9 5578
4ee89e90
SR
55792018-03-20 Stephen Roberts <stephen.roberts@arm.com>
5580
3d6b3b82 5581 * symtab.c (find_pc_sect_line): now uses binary search.
4ee89e90 5582
92630041
TT
55832018-03-19 Tom Tromey <tom@tromey.com>
5584
5585 * rust-exp.y (struct_expr_tail, struct_expr_list): Add plain
5586 "IDENT" production.
5587
76727919
TT
55882018-03-19 Pedro Alves <palves@redhat.com>
5589 Tom Tromey <tom@tromey.com>
5590
5591 * unittests/observable-selftests.c: New file.
5592 * common/observable.h: New file.
5593 * observable.h: New file.
5594 * ada-lang.c, ada-tasks.c, agent.c, aix-thread.c, annotate.c,
5595 arm-tdep.c, auto-load.c, auxv.c, break-catch-syscall.c,
5596 breakpoint.c, bsd-uthread.c, cli/cli-interp.c, cli/cli-setshow.c,
5597 corefile.c, dummy-frame.c, event-loop.c, event-top.c, exec.c,
5598 extension.c, frame.c, gdbarch.c, guile/scm-breakpoint.c,
5599 infcall.c, infcmd.c, inferior.c, inflow.c, infrun.c, jit.c,
5600 linux-tdep.c, linux-thread-db.c, m68klinux-tdep.c,
5601 mi/mi-cmd-break.c, mi/mi-interp.c, mi/mi-main.c, objfiles.c,
5602 ppc-linux-nat.c, ppc-linux-tdep.c, printcmd.c, procfs.c,
5603 python/py-breakpoint.c, python/py-finishbreakpoint.c,
5604 python/py-inferior.c, python/py-unwind.c, ravenscar-thread.c,
5605 record-btrace.c, record-full.c, record.c, regcache.c, remote.c,
5606 riscv-tdep.c, sol-thread.c, solib-aix.c, solib-spu.c, solib.c,
5607 spu-multiarch.c, spu-tdep.c, stack.c, symfile-mem.c, symfile.c,
5608 symtab.c, thread.c, top.c, tracepoint.c, tui/tui-hooks.c,
5609 tui/tui-interp.c, valops.c: Update all users.
5610 * tui/tui-hooks.c (tui_bp_created_observer)
5611 (tui_bp_deleted_observer, tui_bp_modified_observer)
5612 (tui_inferior_exit_observer, tui_before_prompt_observer)
5613 (tui_normal_stop_observer, tui_register_changed_observer):
5614 Remove.
5615 (tui_observers_token): New global.
5616 (attach_or_detach, tui_attach_detach_observers): New functions.
5617 (tui_install_hooks, tui_remove_hooks): Use
5618 tui_attach_detach_observers.
5619 * record-btrace.c (record_btrace_thread_observer): Remove.
5620 (record_btrace_thread_observer_token): New global.
5621 * observer.sh: Remove.
5622 * observer.c: Rename to observable.c.
5623 * observable.c (namespace gdb_observers): Define new objects.
5624 (observer_debug): Move into gdb_observers namespace.
5625 (struct observer, struct observer_list, xalloc_observer_list_node)
5626 (xfree_observer_list_node, generic_observer_attach)
5627 (generic_observer_detach, generic_observer_notify): Remove.
5628 (_initialize_observer): Update.
5629 Don't include observer.inc.
5630 * Makefile.in (generated_files): Remove observer.h, observer.inc.
5631 (clean mostlyclean): Likewise.
5632 (observer.h, observer.inc): Remove targets.
5633 (SUBDIR_UNITTESTS_SRCS): Add observable-selftests.c.
5634 (COMMON_SFILES): Use observable.c, not observer.c.
5635 * .gitignore: Remove observer.h.
5636
1cb1f3da
TT
56372018-03-18 Tom Tromey <tom@tromey.com>
5638
5639 * solib.c (gdb_bfd_lookup_symbol_from_symtab): Use
5640 gdb::def_vector.
5641 (bfd_lookup_symbol_from_dyn_symtab): Likewise.
5642
a06ab151
TT
56432018-03-17 Tom Tromey <tom@tromey.com>
5644
5645 * auto-load.c (auto_load_objfile_script_1): Use std::string.
5646
770623f7
TT
56472018-03-17 Tom Tromey <tom@tromey.com>
5648
5649 * target.c (class scoped_target_fd): New.
5650 (target_fileio_close_cleanup): Remove.
5651 (target_fileio_read_alloc_1): Use scoped_target_fd.
5652
39be3c7e
SM
56532018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
5654
5655 * silent-rules.mk: New.
5656 * Makefile.in: Include silent-rules.mk
5657 (srcdir, VPATH, top_srcdir): Move up.
5658 (COMPILE): Add ECHO_CXX.
5659 (test-cp-name-parser$(EXEEXT)): Add ECHO_CXXLD.
5660 (init.c): Add ECHO_INIT_C.
5661 (gdb$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
5662 (version.c): Add ECHO_GEN.
5663 (printcmd.o): Add ECHO_CXX.
5664 (target-float.o): Add ECHO_CXX.
5665 (ada-exp.o): Add ECHO_CXX.
5666 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN.
5667 (insight$(EXEEXT)): Add ECHO_CXXLD.
5668 * gnulib/configure.ac: Add AM_SILENT_RULES.
5669 * gnulib/aclocal.m4: Re-generate.
5670 * gnulib/configure: Re-generate.
5671 * gnulib/import/Makefile.in: Re-generate.
5672
37e136b1
TT
56732018-03-16 Tom Tromey <tom@tromey.com>
5674
5675 * xcoffread.c (xcoff_symfile_offsets): Change type of "addrs".
5676 * utils.h (make_cleanup_free_section_addr_info): Don't declare.
5677 * utils.c (do_free_section_addr_info)
5678 (make_cleanup_free_section_addr_info): Remove.
5679 * symfile.h (struct other_sections): Add constructor.
5680 (struct section_addr_info): Remove.
5681 (section_addr_info): New typedef.
5682 (struct sym_fns) <sym_offsets>: Change type of parameter.
5683 (build_section_addr_info_from_objfile)
5684 (relative_addr_info_to_section_offsets, addr_info_make_relative)
5685 (default_symfile_offsets, symbol_file_add)
5686 (symbol_file_add_from_bfd)
5687 (build_section_addr_info_from_section_table): Update.
5688 (alloc_section_addr_info, free_section_addr_info): Don't declare.
5689 * symfile.c (alloc_section_addr_info): Remove.
5690 (build_section_addr_info_from_section_table): Change return type.
5691 Update.
5692 (build_section_addr_info_from_bfd)
5693 (build_section_addr_info_from_objfile): Likewise.
5694 (free_section_addr_info): Remove.
5695 (relative_addr_info_to_section_offsets): Change type of "addrs".
5696 (addrs_section_compar): Now a std::sort comparator.
5697 (addrs_section_sort): Change return type.
5698 (addr_info_make_relative): Change type of "addrs". Update.
5699 (default_symfile_offsets, syms_from_objfile_1)
5700 (syms_from_objfile, symbol_file_add_with_addrs): Likewise.
5701 (symbol_file_add_separate): Update.
5702 (symbol_file_add): Change type of "addrs". Update.
5703 (add_symbol_file_command): Update. Remove cleanups.
5704 * symfile-mem.c (symbol_file_add_from_memory): Update. Remove
5705 cleanups.
5706 * symfile-debug.c (debug_sym_offsets): Change type of "info".
5707 * solib.c (solib_read_symbols): Update.
5708 * objfiles.c (objfile_relocate): Update. Remove cleanups.
5709 * machoread.c (macho_symfile_offsets): Update.
5710 * jit.c (jit_bfd_try_read_symtab): Update.
5711
03afa6ef
SM
57122018-03-15 Simon Marchi <simon.marchi@polymtl.ca>
5713
5714 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
5715 unittests/utils-selftests.c.
5716 * unittests/utils-selftests.c: New file.
5717
3ae9ce5d
TT
57182018-03-14 Tom Tromey <tom@tromey.com>
5719
5720 PR cli/14977:
5721 * printcmd.c (printf_c_string, printf_wide_c_string): Special case
5722 for NULL.
5723
b8c2339b
TT
57242018-03-14 Tom Tromey <tom@tromey.com>
5725
5726 PR cli/19918:
5727 * printcmd.c (printf_pointer): Allow "-" in format.
5728
80ae639d
TT
57292018-03-14 Tom Tromey <tom@tromey.com>
5730
5731 * printcmd.c (_initialize_printcmd): Add usage to printf.
5732
0d671d99
YQ
57332018-03-14 Yao Qi <qiyao@sourceware.org>
5734
5735 * MAINTAINERS: Update my email address.
5736
b577b6af
TT
57372018-03-13 Tom Tromey <tom@tromey.com>
5738
5739 * machoread.c (macho_check_dsym): Change filenamep to a
5740 std::string*.
5741 (macho_symfile_read): Update.
5742 * symfile.c (load_command): Use std::string.
5743
89a3b63e
AB
57442018-03-12 Andrew Burgess <andrew.burgess@embecosm.com>
5745
5746 * riscv-tdep.c (riscv_sw_breakpoint_from_kind): Add localization
5747 to error message string.
5748 (riscv_register_name): Use xsnprintf instead of sprintf.
5749 (riscv_insn::fetch_instruction): Use gdb_assert instead of
5750 internal_error.
5751 (riscv_print_arg_location): Use gdb_assert_not_reached instead of
5752 error.
5753 (riscv_push_dummy_call): Likewise.
5754
984c7238
TT
57552018-03-12 Tom Tromey <tom@tromey.com>
5756
5757 * rs6000-aix-tdep.c (rs6000_aix_core_xfer_shared_libraries_aix):
5758 Use gdb::byte_vector.
5759 * arm-tdep.c (arm_exidx_new_objfile): Use gdb::byte_vector.
5760
933522d1
YQ
57612018-03-12 Yao Qi <yao.qi@linaro.org>
5762
5763 * ia64-libunwind-tdep.c (libunwind_get_reg_special): Change
5764 parameter type to readable_regcache.
5765 * ia64-libunwind-tdep.h (libunwind_get_reg_special): Update
5766 the declaration.
5767
be2daae6
TT
57682018-03-11 Tom Tromey <tom@tromey.com>
5769
5770 * dwarf2read.c (struct nextfield): Add initializers.
5771 (struct nextfnfield): Remove.
5772 (struct fnfieldlist): Add initializers. Remove "length" and
5773 "head", use std::vector.
5774 (struct decl_field_list): Remove.
5775 (struct field_info): Add initializers.
5776 <fields, baseclasses>: Now std::vector.
5777 <nbaseclasses, nfnfields, typedef_field_list_count,
5778 nested_types_list_count>: Remove.
5779 (dwarf2_add_field, dwarf2_add_type_defn)
5780 (dwarf2_attach_fields_to_type, dwarf2_add_member_fn)
5781 (dwarf2_attach_fn_fields_to_type, handle_struct_member_die)
5782 (process_structure_scope): Update.
5783
484cf504
TT
57842018-03-11 Tom Tromey <tom@tromey.com>
5785
5786 * dwarf2read.c (sort_tu_by_abbrev_offset): Change to be suitable
5787 for use by std::sort.
5788 (build_type_psymtabs_1): Use std::vector.
5789
9bd8e0b0
EZ
57902018-03-09 Eli Zaretskii <eliz@gnu.org>
5791
5792 * top.c (print_gdb_configuration): Reflect LIBIPT, LIBMEMCHECK,
5793 and LIBMPFR in the printed configuration.
5794
5dc1a704
TT
57952018-03-08 Tom Tromey <tom@tromey.com>
5796
5797 * source.c (get_filename_and_charpos): Use scoped_fd.
5798 * nto-procfs.c (procfs_open_1): Use scoped_fd.
5799 (procfs_pidlist): Likewise.
5800 * procfs.c (proc_get_LDT_entry): Use scoped_fd.
5801 (iterate_over_mappings): Likewise.
5802
fdf07f3a
TT
58032018-03-08 Tom Tromey <tom@tromey.com>
5804
5805 * infcall.c (struct call_return_meta_info)
5806 <stack_temporaries_enabled>: Remove.
5807 (get_call_return_value, call_function_by_hand_dummy): Update.
5808 * thread.c (disable_thread_stack_temporaries): Remove.
5809 (enable_thread_stack_temporaries): Remove.
5810 (thread_stack_temporaries_enabled_p): Return bool.
5811 (push_thread_stack_temporary, value_in_thread_stack_temporaries)
5812 (get_last_thread_stack_temporary): Update.
5813 * eval.c (evaluate_subexp): Update.
5814 * gdbthread.h (class enable_thread_stack_temporaries): Now a
5815 class, not a function.
5816 (value_ptr, value_vec): Remove typedefs.
5817 (class thread_info) <stack_temporaries_enabled>: Now bool.
5818 <stack_temporaries>: Now a std::vector.
5819 (thread_stack_temporaries_enabled_p)
5820 (value_in_thread_stack_temporaries): Return bool.
5821
567a3e54
SM
58222018-03-08 Simon Marchi <simon.marchi@ericsson.com>
5823
5824 * remote.c (putpkt_binary): Fix omitted bytes reporting.
5825 (getpkt_or_notif_sane_1): Likewise.
5826
00b40057
SM
58272018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5828
5829 * build-id.c (build_id_to_debug_bfd): Use std::string.
5830
a8dbfd58
SM
58312018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5832
5833 * build-id.c (find_separate_debug_file_by_buildid): Return
5834 std::string.
5835 * build-id.h (find_separate_debug_file_by_buildid): Return
5836 std::string.
5837 * coffread.c (coff_symfile_read): Adjust to std::string.
5838 * elfread.c (elf_symfile_read): Adjust to std::string.
5839 * symfile.c (separate_debug_file_exists): Change parameter to
5840 std::string.
5841 (find_separate_debug_file): Return std::string.
5842 (find_separate_debug_file_by_debuglink): Return std::string.
5843 * symfile.h (find_separate_debug_file_by_debuglink): Return
5844 std::string.
5845
e6a58aa8
SM
58462018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
5847
5848 * common/xml-utils.c (xml_escape_text): Move code to...
5849 (xml_escape_text_append): ... this new function.
5850 * common/xml-utils.h (xml_escape_text_append): New declaration.
5851 * unittests/xml-utils-selftests.c (test_xml_escape_text_append):
5852 New function.
5853 (_initialize_xml_utils): register test_xml_escape_text_append as
5854 a selftest.
5855
4ef0bef6
AH
58562018-03-07 Alan Hayward <alan.hayward@arm.com>
5857
5858 * defs.h: Remove MAX_REGISTER_SIZE.
5859 * regcache.c (init_regcache_descr): Remove MAX_REGISTER_SIZE
5860 asserts.
5861 * python/py-unwind.c (pyuw_sniffer): Likewise.
5862
e0d3522b
TT
58632018-03-07 Tom Tromey <tom@tromey.com>
5864
5865 * linux-tdep.c (linux_info_proc): Update.
5866 * target.h (struct target_ops) <to_fileio_readlink>: Return
5867 optional<string>.
5868 (target_fileio_readlink): Return optional<string>.
5869 * remote.c (remote_hostio_readlink): Return optional<string>.
5870 * inf-child.c (inf_child_fileio_readlink): Return
5871 optional<string>.
5872 * target.c (target_fileio_readlink): Return optional<string>.
5873
ea005f31
AB
58742018-03-07 Andrew Burgess <andrew.burgess@embecosm.com>
5875
5876 * regcache.c (cooked_read_test): Add riscv to the list of
5877 architectures that have a save_reggroup.
5878
e95a97d4
AA
58792018-03-07 Andreas Arnez <arnez@linux.vnet.ibm.com>
5880
5881 * gnu-v3-abi.c (gnuv3_rtti_type): Add early exit if the given
5882 value is not a dynamic class object.
5883
d8344f3d
TT
58842018-03-06 Tom Tromey <tom@tromey.com>
5885
5886 * rust-exp.y: Formatting fixes.
5887
9add17f2
AB
58882018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5889
5890 * riscv-tdep.c (riscv_register_name): Remove target description
5891 support.
5892 (riscv_gdbarch_init): Remove target description check.
5893
c9486dfe
AB
58942018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5895
5896 * riscv-tdep.c: Remove 'Contributed by ...' lines from header
5897 comment.
5898 * riscv-tdep.h: Likewise.
5899
d74aff3d
AB
59002018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5901
5902 * riscv-tdep.c (riscv_pseudo_register_read): Delete.
5903 (riscv_pseudo_register_write): Delete.
5904 (riscv_gdbarch_init): Remove all use of pseudo registers.
5905
7ea78b59
SM
59062018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
5907
5908 * record-btrace.c (btrace_print_lines): Replace cleanup
5909 parameter with RAII equivalents.
5910 (btrace_insn_history): Replace cleanup with RAII equivalents.
5911 * ui-out.h (make_cleanup_ui_out_list_begin_end,
5912 make_cleanup_ui_out_tuple_begin_end): Remove.
5913 * ui-out.c (struct ui_out_end_cleanup_data, do_cleanup_end,
5914 make_cleanup_ui_out_end, make_cleanup_ui_out_tuple_begin_end,
5915 make_cleanup_ui_out_list_begin_end): Remove.
5916
53127008
SM
59172018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
5918
5919 * record-btrace.c (record_btrace_maybe_mark_async_event): Change
5920 parameter types to std::vector. Use bool.
5921 (record_btrace_wait): Replace VEC(tp_t) with
5922 std::vector<thread_info *>.
5923 * common/gdb_vecs.h (unordered_remove, ordered_remove): New.
5924
228f1508
SM
59252018-03-06 Simon Marchi <simon.marchi@polymtl.ca>
5926
5927 * record-btrace.c (record_btrace_disable_callback): Remove.
5928 (struct scoped_btrace_disable): New.
5929 (record_btrace_open): Use scoped_btrace_disable.
5930
b2970c23
AB
59312018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5932
5933 * riscv-tdep.c (riscv_return_value): Change type to ULONGEST for
5934 reading values from registers.
5935
fb294655
AB
59362018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5937
5938 * riscv-tdep.c (riscv_push_dummy_call): Use core_addr_to_string_nz
5939 where appropriate.
5940
cab5bb9d
AB
59412018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5942
5943 * riscv-tdep.c (riscv_print_arg_location): Add header comment,
5944 change parameter type. Use GDB's print functions, and use
5945 core_addr_to_string where appropriate.
5946 (riscv_push_dummy_call): Use core_addr_to_string where
5947 appropriate, update call to riscv_print_arg_location, and reindent
5948 a few lines.
5949 (riscv_return_value): Update call to riscv_print_arg_location.
5950
dbbb1059
AB
59512018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5952 Tim Newsome <tim@sifive.com>
5953 Albert Ou <a0u@eecs.berkeley.edu>
5954 Darius Rad <darius@bluespec.com>
5955
5956 * Makefile.in (ALL_TARGET_OBS): Add riscv-tdep.o
5957 (HFILES_NO_SRCDIR): Add riscv-tdep.h.
5958 (ALLDEPFILES): Add riscv-tdep.c
5959 * configure.tgt: Add riscv support.
5960 * riscv-tdep.c: New file.
5961 * riscv-tdep.h: New file.
5962 * NEWS: Mention new target.
5963 * MAINTAINERS: Add entry for riscv.
5964
5dc43913
AB
59652018-03-06 Andrew Burgess <andrew.burgess@embecosm.com>
5966
5967 * amd64-tdep.c (amd64_classify_aggregate): Ignore zero sized
5968 fields within aggregates.
5969
3dea1ef7
SM
59702018-03-04 Simon Marchi <simon.marchi@polymtl.ca>
5971
5972 * record-btrace.c (btrace_print_lines): Change type of flags to
5973 gdb_disassembly_flags.
5974
7efba073
JB
59752018-03-04 John Baldwin <jhb@FreeBSD.org>
5976
5977 * fbsd-nat.c: Include "inf-ptrace.h".
5978 (USE_SIGTRAP_SIGINFO): Conditionally define.
5979 [USE_SIGTRAP_SIGINFO] (fbsd_handle_debug_trap): New function.
5980 (fbsd_wait) [USE_SIGTRAP_SIGINFO]: Call "fbsd_handle_debug_trap".
5981 [USE_SIGTRAP_SIGINFO] (fbsd_stopped_by_sw_breakpoint): New
5982 function.
5983 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_sw_breakpoint):
5984 Likewise.
5985 [USE_SIGTRAP_SIGINFO] (fbsd_supports_stopped_by_hw_breakpoint):
5986 Likewise.
5987 (fbsd_nat_add_target) [USE_SIGTRAP_SIGINFO]: Set
5988 "stopped_by_sw_breakpoint", "supports_stopped_by_sw_breakpoint",
5989 "supports_stopped_by_hw_breakpoint" target methods.
5990
386a8676
JB
59912018-03-04 John Baldwin <jhb@FreeBSD.org>
5992
5993 * NEWS (Changes since GDB 8.1): Add "set/show debug fbsd-nat".
5994 * fbsd-nat.c (debug_fbsd_nat): New variable.
5995 (show_fbsd_nat_debug): New function.
5996 (fbsd_wait): Log LWP info if "debug_fbsd_nat" is enabled.
5997 (_initialize_fbsd_nat): Add "fbsd-nat" debug boolean command.
5998
12279366
JB
59992018-03-04 John Baldwin <jhb@FreeBSD.org>
6000
6001 * nat/x86-dregs.c (x86_dr_stopped_by_hw_breakpoint): New function.
6002 * nat/x86-dregs.h (x86_dr_stopped_by_hw_breakpoint): New
6003 prototype.
6004 * x86-nat.c (x86_stopped_by_hw_breakpoint): New function.
6005 (x86_use_watchpoints): Set "stopped_by_hw_breakpoint" target
6006 method.
6007
54693cf5
SM
60082018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6009
6010 * common/gdb_vecs.c (free_char_ptr_vec): Remove.
6011 * common/gdb_vecs.h (free_char_ptr_vec): Remove.
6012
ccb2231c
SM
60132018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6014
6015 * charset.c (struct charset_vector): New.
6016 (charsets): Change type to charset_vector.
6017 (find_charset_names): Adjust.
6018 (add_one): Adjust.
6019 (_initialize_charset): Adjust.
6020
6fb16ce6
SM
60212018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6022
6023 * progspace.h (struct program_space) <deleted_solibs>: Change
6024 type to std::vector<std::string>.
6025 * progspace.c (clear_program_space_solib_cache): Adjust.
6026 * breakpoint.c (print_solib_event): Adjust.
6027 (check_status_catch_solib): Adjust.
6028 * solib.c (update_solib_list): Adjust.
6029 * ui-out.h (class ui_out) <field_string>: New overload.
6030 * ui-out.c (ui_out::field_string): New overload.
6031
564b1e3f
SM
60322018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6033
6034 * progspace.h (struct program_space): Add constructor and
6035 destructor, initialize fields.
6036 (add_program_space): Remove.
6037 * progspace.c (add_program_space): Rename to...
6038 (program_space::program_space): ... this.
6039 (release_program_space): Rename to...
6040 (program_space::~program_space): ... this.
6041 (delete_program_space): Use delete to delete program_space.
6042 (initialize_progspace): Use new to allocate program_space.
6043 * inferior.c (add_inferior_with_spaces): Likewise.
6044 (clone_inferior_command): Likewise.
6045 * infrun.c (follow_fork_inferior): Likewise.
6046 (handle_vfork_child_exec_or_exit): Likewise.
6047
e80aaf61
SM
60482018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
6049
6050 * common/gdb_vecs.h (make_cleanup_free_char_ptr_vec): Remove.
6051 (delim_string_to_char_ptr_vec): Return std::vector of
6052 gdb::unique_xmalloc_ptr.
6053 (dirnames_to_char_ptr_vec_append): Take std::vector of
6054 gdb::unique_xmalloc_ptr.
6055 (dirnames_to_char_ptr_vec): Return std::vector of
6056 gdb::unique_xmalloc_ptr.
6057 * common/gdb_vecs.c (delim_string_to_char_ptr_vec_append):
6058 Take std::vector of gdb::unique_xmalloc_ptr, adjust the code.
6059 (delim_string_to_char_ptr_vec): Return an std::vector of
6060 gdb::unique_xmalloc_ptr, adjust the code.
6061 (dirnames_to_char_ptr_vec_append): Take an std::vector of
6062 gdb::unique_xmalloc_ptr, adjust the code.
6063 (dirnames_to_char_ptr_vec): Return an std::vector of
6064 gdb::unique_xmalloc_ptr, adjust the code.
6065 * auto-load.c (auto_load_safe_path_vec): Change type to
6066 std::vector of gdb::unique_xmalloc_ptr.
6067 (auto_load_expand_dir_vars): Return an std::vector of
6068 gdb::unique_xmalloc_ptr, adjust the code.
6069 (auto_load_safe_path_vec_update): Adjust.
6070 (filename_is_in_auto_load_safe_path_vec): Adjust.
6071 (auto_load_objfile_script_1): Adjust.
6072 * build-id.c (build_id_to_debug_bfd): Adjust.
6073 * linux-thread-db.c (thread_db_load_search): Adjust.
6074 * source.c (add_path): Adjust.
6075 (openp): Adjust.
6076 * symfile.c (find_separate_debug_file): Adjust.
6077 * utils.c (do_free_char_ptr_vec): Remove.
6078 (make_cleanup_free_char_ptr_vec): Remove.
6079
ab818ade
SDJ
60802018-03-01 Sergio Durigan Junior <sergiodj@redhat.com>
6081
6082 PR gdb/22907
6083 * common/pathstuff.c: Conditionally include "<windows.h>".
6084
e1e6f073
GS
60852018-03-01 Georg Sauthoff <mail@georg.so>
6086
6087 PR gdb/22888
6088 * gcore.in: Quote variables and switch interpreter to bash.
6089
c7b15a66
TT
60902018-03-01 Tom Tromey <tom@tromey.com>
6091
6092 * dwarf2read.c (alloc_discriminant_info): Fix default_index
6093 assertion. Add assertion for discriminant_index.
6094 (quirk_rust_enum): Use correct base type name in univariant case.
6095
0cb7c7b0
SM
60962018-03-01 Simon Marchi <simon.marchi@ericsson.com>
6097
6098 * record.c (get_call_history_modifiers): Return a
6099 record_print_flags.
6100 (cmd_record_call_history): Adjust.
6101 * record-btrace.c (record_btrace_call_history): Adjust.
6102 (record_btrace_call_history_range): Adjust.
6103 (record_btrace_call_history_from): Adjust.
6104 * target-debug.h (target_debug_print_record_print_flags): New.
6105 * target-delegates.c: Re-generate.
6106 * target.c (target_call_history): Change flags type.
6107 (target_call_history_from): Likewise.
6108 (target_call_history_range): Likewise.
6109 * target.h (struct target_ops) <target_call_history>: Likewise.
6110 (target_call_history_from): Likewise.
6111 (target_call_history_range): Likewise.
6112
25e3c82c
SDJ
61132018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6114 Simon Marchi <simon.marchi@polymtl.ca>
6115
6116 * common/common-utils.c: Include "sys/stat.h".
6117 (is_regular_file): Move here from "source.c"; change return
6118 type to "bool".
6119 * common/common-utils.h (is_regular_file): New prototype.
6120 * common/pathstuff.c (contains_dir_separator): New function.
6121 * common/pathstuff.h (contains_dir_separator): New prototype.
6122 * source.c: Don't include "sys/stat.h".
6123 (is_regular_file): Move to "common/common-utils.c".
6124
b4987c95
SDJ
61252018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
6126
6127 * Makefile.in (COMMON_SFILES): Add "common/pathstuff.c".
6128 (HFILES_NO_SRCDIR): Add "common/pathstuff.h".
6129 * auto-load.c: Include "common/pathstuff.h".
6130 * common/common-def.h (current_directory): Move here.
6131 * common/gdb_tilde_expand.c (gdb_tilde_expand_up): New
6132 function.
6133 * common/gdb_tilde_expand.h (gdb_tilde_expand_up): New
6134 prototype.
6135 * common/pathstuff.c: New file.
6136 * common/pathstuff.h: New file.
6137 * compile/compile.c: Include "common/pathstuff.h".
6138 * defs.h (current_directory): Move to "common/common-defs.h".
6139 * dwarf2read.c: Include "common/pathstuff.h".
6140 * exec.c: Likewise.
6141 * guile/scm-safe-call.c: Likewise.
6142 * linux-thread-db.c: Likewise.
6143 * main.c: Likewise.
6144 * nto-tdep.c: Likewise.
6145 * objfiles.c: Likewise.
6146 * source.c: Likewise.
6147 * symtab.c: Likewise.
6148 * utils.c: Include "common/pathstuff.h".
6149 (gdb_realpath): Move to "common/pathstuff.c".
6150 (gdb_realpath_keepfile): Likewise.
6151 (gdb_abspath): Likewise.
6152 * utils.h (gdb_realpath): Move to "common/pathstuff.h".
6153 (gdb_realpath_keepfile): Likewise.
6154 (gdb_abspath): Likewise.
6155
f169cfdc
JB
61562018-02-28 John Baldwin <jhb@FreeBSD.org>
6157
6158 * fbsd-nat.c (fbsd_resume): Use PT_SETSTEP for stepping and a
6159 wildcard process pid for super_resume for kernels with a
6160 specific bug.
6161
e05cac70
PM
61622018-02-27 Phil Muldoon <pmuldoon@redhat.com>
6163
6164 * compile/compile.c (get_args): Add additional comments
6165 explaining function.
6166
55089490
TT
61672018-02-27 Simon Marchi <simon.marchi@polymtl.ca>
6168 Tom Tromey <tom@tromey.com>
6169
6170 * target.h (memory_write_request_s): Remove typedef. Don't define
6171 VEC.
6172 (target_write_memory_blocks): Change argument to std::vector.
6173 (struct memory_write_request): Add constructor.
6174 * target-memory.c (compare_block_starting_address): Return bool.
6175 Change argument types.
6176 (claim_memory): Change arguments to use std::vector.
6177 (split_regular_and_flash_blocks, blocks_to_erase)
6178 (compute_garbled_blocks): Likewise.
6179 (cleanup_request_data, cleanup_write_requests_vector): Remove.
6180 (target_write_memory_blocks): Change argument to std::vector.
6181 * symfile.c (struct load_section_data): Add constructor and
6182 destructor. Use std::vector for "requests".
6183 (struct load_progress_data): Add initializers.
6184 (load_section_callback): Update. Use "new".
6185 (clear_memory_write_data): Remove.
6186 (generic_load): Update.
6187
0c305b61
AH
61882018-02-27 Alan Hayward <alan.hayward@arm.com>
6189
6190 * arch/aarch64.h: Use common/tdesc.h.
6191
c5196c92
MR
61922018-02-26 Maciej W. Rozycki <macro@mips.com>
6193
6194 * mips-tdep.c (mips_gdbarch_init): Don't use a 32-bit BFD
6195 architecture with a 64-bit ABI.
6196
37c33887
MR
61972018-02-26 Maciej W. Rozycki <macro@mips.com>
6198
6199 * gdb/mips-tdep.c (mips_gdbarch_init): Reorder ABI determination
6200 ahead of target description loading.
6201
d4dd3282
TT
62022018-02-26 Tom Tromey <tom@tromey.com>
6203
6204 * stack.c (backtrace_command_1): Update.
6205 * python/python-internal.h (gdbpy_apply_frame_filter): Change type
6206 of "flags".
6207 * python/py-framefilter.c (py_print_frame)
6208 (gdbpy_apply_frame_filter): Change type of "flags".
6209 * mi/mi-cmd-stack.c (mi_apply_ext_lang_frame_filter): Change type
6210 of "flags".
6211 (mi_cmd_stack_list_frames, mi_cmd_stack_list_locals)
6212 (mi_cmd_stack_list_args, mi_cmd_stack_list_variables): Update.
6213 * extension.h (enum frame_filter_flag): Rename from
6214 frame_filter_flags.
6215 (frame_filter_flags): Define using DEF_ENUM_FLAGS_TYPE.
6216 (apply_ext_lang_frame_filter): Change type of "flags".
6217 * extension.c (apply_ext_lang_frame_filter): Change type of
6218 "flags".
6219 * extension-priv.h (struct extension_language_ops)
6220 <apply_frame_filter>: Change type of "flags".
6221
6893c19a
TT
62222018-02-26 Tom Tromey <tom@tromey.com>
6223
6224 PR python/16497:
6225 * stack.c (backtrace_command_1): Set PRINT_MORE_FRAMES flag. Fix
6226 off-by-one in py_end computation.
6227 * python/py-framefilter.c (gdbpy_apply_frame_filter): Handle
6228 PRINT_MORE_FRAMES.
6229 * extension.h (enum frame_filter_flags) <PRINT_MORE_FRAMES>: New
6230 constant.
6231
2ddeaf8a
TT
62322018-02-26 Tom Tromey <tom@tromey.com>
6233
6234 * dwarf2read.c (struct variant_field): New.
6235 (struct nextfield) <variant>: New field.
6236 (dwarf2_add_field): Handle DW_TAG_variant_part.
6237 (dwarf2_attach_fields_to_type): Attach a discriminant_info to a
6238 discriminated union.
6239 (read_structure_type): Handle DW_TAG_variant_part.
6240 (handle_struct_member_die): New function, extracted from
6241 process_structure_scope. Handle DW_TAG_variant.
6242 (process_structure_scope): Handle discriminated unions. Call
6243 handle_struct_member_die.
6244
c9317f21
TT
62452018-02-26 Tom Tromey <tom@tromey.com>
6246
6247 * rust-lang.h (rust_last_path_segment): Declare.
6248 * rust-lang.c (rust_last_path_segment): Now public. Change
6249 contract.
6250 (struct disr_info): Remove.
6251 (RUST_ENUM_PREFIX, RUST_ENCODED_ENUM_REAL)
6252 (RUST_ENCODED_ENUM_HIDDEN, rust_union_is_untagged)
6253 (rust_get_disr_info, rust_tuple_variant_type_p): Remove.
6254 (rust_enum_p, rust_enum_variant): New function.
6255 (rust_underscore_fields): Remove "offset" parameter.
6256 (rust_print_enum): New function.
6257 (rust_val_print) <TYPE_CODE_UNION>: Remove enum code.
6258 <TYPE_CODE_STRUCT>: Call rust_print_enum when appropriate.
6259 (rust_print_struct_def): Add "for_rust_enum" parameter. Handle
6260 enums.
6261 (rust_internal_print_type): New function, from rust_print_type.
6262 Remove enum code.
6263 (rust_print_type): Call rust_internal_print_type.
6264 (rust_evaluate_subexp) <STRUCTOP_ANONYMOUS, STRUCTOP_STRUCT>:
6265 Update enum handling.
6266 * dwarf2read.c (struct dwarf2_cu) <rust_unions>: New field.
6267 (rust_fully_qualify, alloc_discriminant_info, quirk_rust_enum)
6268 (rust_union_quirks): New functions.
6269 (process_full_comp_unit, process_full_type_unit): Call
6270 rust_union_quirks.
6271 (process_structure_scope): Update rust_unions if necessary.
6272
7c22600a
TT
62732018-02-26 Tom Tromey <tom@tromey.com>
6274
6275 * value.h (value_union_variant): Declare.
6276 * valops.c (value_union_variant): New function.
6277 * gdbtypes.h (TYPE_FLAG_DISCRIMINATED_UNION): New macro.
6278 (struct discriminant_info): New.
6279 (enum dynamic_prop_node_kind) <DYN_PROP_DISCRIMINATED>: New
6280 enumerator.
6281 (struct main_type) <flag_discriminated_union>: New field.
6282
15ce8941
TT
62832018-02-26 Tom Tromey <tom@tromey.com>
6284
6285 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6286 unittests/unpack-selftests.c.
6287 * unittests/unpack-selftests.c: New file.
6288 * value.c (unpack_bits_as_long): Fix bugs in non-bitfield cases.
6289
48fbe735
YQ
62902018-02-26 Yao Qi <yao.qi@linaro.org>
6291
6292 * dwarf2read.c (struct partial_die_info) <read>: New method.
6293 (read_partial_die): Remove the declaration.
6294 (load_partial_dies): Update.
6295 (partial_die_info::partial_die_info):
6296 (read_partial_die): Change it to partial_die_info::read.
6297
52356b79
YQ
62982018-02-26 Yao Qi <yao.qi@linaro.org>
6299
6300 * dwarf2read.c (struct partial_die_info) <fixup>: New method.
6301 (fixup_partial_die): Remove declaration.
6302 (scan_partial_symbols): Update.
6303 (partial_die_parent_scope): Likewise.
6304 (partial_die_full_name): Likewise.
6305 (fixup_partial_die): Change it to partial_die_info::fixup.
6306
35cc7ed7
YQ
63072018-02-26 Yao Qi <yao.qi@linaro.org>
6308
6309 * dwarf2read.c (read_partial_die): Update the declaration.
6310 (load_partial_dies): Caller update.
6311 (read_partial_die): Remove one argument abbrev_len.
6312
6f06d47b
YQ
63132018-02-26 Yao Qi <yao.qi@linaro.org>
6314
6315 * dwarf2read.c (struct partial_die_info): Add ctor, delete
6316 assignment operator.
6317 (load_partial_dies): Use ctor and copy ctor.
6318 (read_partial_die): Update.
6319 (dwarf2_cu::find_partial_die): Use ctor.
6320
d590ff25
YQ
63212018-02-26 Yao Qi <yao.qi@linaro.org>
6322
6323 * dwarf2read.c (struct dwarf2_cu) <find_partial_die>: New method.
6324 (find_partial_die_in_comp_unit): Change it to
6325 dwarf2_cu::find_partial_die.
6326 (find_partial_die): Update.
6327
fd0a254f
YQ
63282018-02-26 Yao Qi <yao.qi@linaro.org>
6329
6330 * dwarf2read.c (read_partial_die): Remove the code checking abbrev
6331 is NULL.
6332
cd9983dd
YQ
63332018-02-26 Yao Qi <yao.qi@linaro.org>
6334
6335 * dwarf2read.c (load_partial_dies): Move the location of XOBNEW.
6336
f46cd62a
AH
63372018-02-26 Alan Hayward <alan.hayward@arm.com>
6338
6339 * arch/amd64.h: Use common/tdesc.h.
6340 * arch/i386.c: Likewise.
6341 * arch/i386.h: Likewise.
6342 * arch/tic6x.c: Likewise.
6343 * arch/tdesc.h: Move file from here...
6344 * common/tdesc.h: ...to here.
6345 * features/aarch64-core.c: Regenerate.
6346 * features/aarch64-fpu.c: Regenerate.
6347 * features/i386/32bit-avx.c: Regenerate.
6348 * features/i386/32bit-avx512.c: Regenerate.
6349 * features/i386/32bit-core.c: Regenerate.
6350 * features/i386/32bit-linux.c: Regenerate.
6351 * features/i386/32bit-mpx.c: Regenerate.
6352 * features/i386/32bit-pkeys.c: Regenerate.
6353 * features/i386/32bit-sse.c: Regenerate.
6354 * features/i386/64bit-avx.c: Regenerate.
6355 * features/i386/64bit-avx512.c: Regenerate.
6356 * features/i386/64bit-core.c: Regenerate.
6357 * features/i386/64bit-linux.c: Regenerate.
6358 * features/i386/64bit-mpx.c: Regenerate.
6359 * features/i386/64bit-pkeys.c: Regenerate.
6360 * features/i386/64bit-segments.c: Regenerate.
6361 * features/i386/64bit-sse.c: Regenerate.
6362 * features/i386/x32-core.c: Regenerate.
6363 * features/tic6x-c6xp.c: Regenerate.
6364 * features/tic6x-core.c: Regenerate.
6365 * features/tic6x-gp.c: Regenerate.
6366 * target-descriptions.c: Use common/tdesc.h.
6367 * target-descriptions.h: Likewise.
6368
9b292f68
TT
63692018-02-24 Tom Tromey <tom@tromey.com>
6370
6371 * linux-thread-db.c (try_thread_db_load_from_pdir_1)
6372 (try_thread_db_load_from_dir, thread_db_load_search): Use
6373 std::string.
6374 (info_auto_load_libthread_db_compare): Return bool. Change
6375 argument types.
6376 (info_auto_load_libthread_db): Use std::vector, std::string.
6377 Remove cleanups.
6378
281d762b
TT
63792018-02-24 Tom Tromey <tom@tromey.com>
6380
6381 * i386-tdep.c (i386_fast_tracepoint_valid_at): "msg" now a
6382 std::string.
6383 * gdbarch.sh (fast_tracepoint_valid_at): Change "msg" to a
6384 std::string*.
6385 * gdbarch.c: Rebuild.
6386 * gdbarch.h: Rebuild.
6387 * breakpoint.c (check_fast_tracepoint_sals): Use std::string.
6388 * arch-utils.h (default_fast_tracepoint_valid_at): Update.
6389 * arch-utils.c (default_fast_tracepoint_valid_at): "msg" now a
6390 std::string*.
6391
9d8780f0
SM
63922018-02-23 Simon Marchi <simon.marchi@polymtl.ca>
6393
6394 * gdbtypes.h (sect_offset): Change type to uint64_t.
6395 (sect_offset_str): New function.
6396 * dwarf2read.c (create_addrmap_from_aranges): Use
6397 sect_offset_str.
6398 (error_check_comp_unit_head): Likewise.
6399 (create_debug_type_hash_table): Likewise.
6400 (read_cutu_die_from_dwo): Likewise.
6401 (init_cutu_and_read_dies): Likewise.
6402 (init_cutu_and_read_dies_no_follow): Likewise.
6403 (process_psymtab_comp_unit_reader): Likewise.
6404 (partial_die_parent_scope): Likewise.
6405 (peek_die_abbrev): Likewise.
6406 (process_queue): Likewise.
6407 (dwarf2_physname): Likewise.
6408 (read_namespace_alias): Likewise.
6409 (read_import_statement): Likewise.
6410 (create_dwo_cu_reader): Likewise.
6411 (create_cus_hash_table): Likewise.
6412 (lookup_dwo_cutu): Likewise.
6413 (inherit_abstract_dies): Likewise.
6414 (read_func_scope): Likewise.
6415 (read_call_site_scope): Likewise.
6416 (dwarf2_add_member_fn): Likewise.
6417 (read_common_block): Likewise.
6418 (read_module_type): Likewise.
6419 (read_typedef): Likewise.
6420 (read_subrange_type): Likewise.
6421 (load_partial_dies): Likewise.
6422 (read_partial_die): Likewise.
6423 (find_partial_die): Likewise.
6424 (read_str_index): Likewise.
6425 (dwarf2_string_attr): Likewise.
6426 (build_error_marker_type): Likewise.
6427 (lookup_die_type): Likewise.
6428 (dump_die_shallow): Likewise.
6429 (follow_die_ref): Likewise.
6430 (dwarf2_fetch_die_loc_sect_off): Likewise.
6431 (dwarf2_fetch_constant_bytes): Likewise.
6432 (follow_die_sig): Likewise.
6433 (get_signatured_type): Likewise.
6434 (get_DW_AT_signature_type): Likewise.
6435 (dwarf2_find_containing_comp_unit): Likewise.
6436 (set_die_type): Likewise.
6437
8ec57239
JB
64382018-02-21 John Baldwin <jhb@FreeBSD.org>
6439
6440 * arch/aarch64.c: Include "common-defs.h".
6441 * arch/amd64.c: Likewise.
6442 * arch/i386.c: Likewise.
6443
3eac2b65
TT
64442018-02-21 Tom Tromey <tom@tromey.com>
6445
6446 * value.h: (extract_field_op): Update.
6447 * eval.c (extract_field_op): Return a const char *.
6448 * expression.h (parse_expression_for_completion): Update.
6449 * completer.c (complete_expression): Update.
6450 (add_struct_fields): Make fieldname const.
6451 * parse.c (expout_completion_name): Now a unique_xmalloc_ptr.
6452 (mark_completion_tag, parse_exp_in_context_1): Update.
6453 (parse_expression_for_completion): Change "name" to
6454 unique_xmalloc_ptr*.
6455
6ccb583f
TT
64562018-02-21 Tom Tromey <tom@tromey.com>
6457
6458 * infcall.c (call_function_by_hand_dummy): Use std::vector.
6459
c113ed0c
YQ
64602018-02-21 Yao Qi <yao.qi@linaro.org>
6461
6462 * avr-tdep.c (avr_read_pc): Change parameter type to
6463 readable_regcache.
6464 * gdbarch.sh (read_pc): Likewise.
6465 * gdbarch.c: Re-generated.
6466 * gdbarch.h: Re-generated.
6467 * hppa-tdep.c (hppa_read_pc): Change parameter type to
6468 readable_regcache.
6469 * ia64-tdep.c (ia64_read_pc): Likewise.
6470 * mips-tdep.c (mips_read_pc): Likewise.
6471 * spu-tdep.c (spu_read_pc): Likewise.
6472
4c74fe6b
YQ
64732018-02-21 Yao Qi <yao.qi@linaro.org>
6474
6475 * Makefile.in (COMMON_SFILES): Add regcache-dump.c
6476 * regcache-dump.c: New file.
6477 * regcache.c: Move register_dump to regcache-dump.c.
6478 (maintenance_print_registers): Likewise.
6479 (maintenance_print_raw_registers): Likewise.
6480 (maintenance_print_cooked_registers): Likewise.
6481 (maintenance_print_register_groups): Likewise.
6482 (maintenance_print_remote_registers): Likewise.
6483 (_initialize_regcache): Likewise.
6484 * regcache.h (register_dump): Moved from regcache.c.
6485
796bb026
YQ
64862018-02-21 Yao Qi <yao.qi@linaro.org>
6487
6488 * regcache.c (regcache::regcache): Update.
6489 (regcache::invalidate): Move it to detached_regcache::invalidate.
6490 (get_thread_arch_aspace_regcache): Update.
6491 (regcache::raw_update): Update.
6492 (regcache::cooked_read): Remove some code.
6493 (regcache::cooked_read_value): Likewise.
6494 (regcache::raw_write): Remove assert on m_readonly_p.
6495 (regcache::raw_supply_integer): Move it to
6496 detached_regcache::raw_supply_integer.
6497 (regcache::raw_supply_zeroed): Likewise.
6498 * regcache.h (detached_regcache) <raw_supply_integer>: New
6499 declaration.
6500 <raw_supply_zeroed, invalidate>: Likewise.
6501 (regcache) <raw_supply_integer, raw_supply_zeroed>: Removed.
6502 <invalidate>: Likewise.
6503 <m_readonly_p>: Removed.
6504
215c69dc
YQ
65052018-02-21 Yao Qi <yao.qi@linaro.org>
6506
6507 * infcmd.c (get_return_value): Let stop_regs point to
6508 get_current_regcache.
6509 * regcache.c (regcache::regcache): Remove.
6510 (register_dump_reg_buffer): New class.
6511 (regcache_print): Adjust.
6512 * regcache.h (regcache): Remove constructors.
6513
f3384e66
YQ
65142018-02-21 Yao Qi <yao.qi@linaro.org>
6515
6516 * regcache.c (class register_dump): New class.
6517 (register_dump_regcache, register_dump_none): New class.
6518 (register_dump_remote, register_dump_groups): New class.
6519 (regcache_print): Update.
6520 * regcache.h (regcache_dump_what): Move it to regcache.c.
6521 (regcache) <dump>: Remove.
6522
c8ec2f33
YQ
65232018-02-21 Yao Qi <yao.qi@linaro.org>
6524
6525 * jit.c (struct jit_unwind_private) <regcache>: Change its type to
6526 reg_buffer_rw *.
6527 (jit_unwind_reg_set_impl): Call raw_supply.
6528 (jit_frame_sniffer): Use reg_buffer_rw.
6529 * record-full.c (record_full_core_regbuf): Change its type.
6530 (record_full_core_open_1): Use reg_buffer_rw.
6531 (record_full_close): Likewise.
6532 (record_full_core_fetch_registers): Use regcache->raw_supply.
6533 (record_full_core_store_registers): Likewise.
6534 * regcache.c (regcache::get_register_status): Move it to
6535 reg_buffer.
6536 (regcache_raw_set_cached_value): Remove.
6537 (regcache::raw_set_cached_value): Remove.
6538 (regcache::raw_write): Call raw_supply.
6539 (regcache::raw_supply): Move it to reg_buffer_rw.
6540 * regcache.h (regcache_raw_set_cached_value): Remove.
6541 (reg_buffer_rw): New class.
6542
daf6667d
YQ
65432018-02-21 Yao Qi <yao.qi@linaro.org>
6544
6545 * dummy-frame.c (dummy_frame_cache) <prev_regcache>: Use
6546 readonly_detached_regcache.
6547 (dummy_frame_prev_register): Use regcache->cooked_read.
6548 * frame.c (frame_save_as_regcache): Change return type.
6549 (frame_pop): Update.
6550 * frame.h (frame_save_as_regcache): Update declaration.
6551 * inferior.h (get_infcall_suspend_state_regcache): Update
6552 declaration.
6553 * infrun.c (infcall_suspend_state) <registers>: use
6554 readonly_detached_regcache.
6555 (save_infcall_suspend_state): Don't use regcache_dup.
6556 (get_infcall_suspend_state_regcache): Change return type.
6557 * linux-fork.c (struct fork_info) <savedregs>: Change to
6558 readonly_detached_regcache.
6559 <pc>: New field.
6560 (fork_save_infrun_state): Don't use regcache_dup.
6561 (info_checkpoints_command): Adjust.
6562 * mi/mi-main.c (register_changed_p): Update declaration.
6563 (mi_cmd_data_list_changed_registers): Use
6564 readonly_detached_regcache.
6565 (register_changed_p): Change parameter type to
6566 readonly_detached_regcache.
6567 * ppc-linux-tdep.c (ppu2spu_cache) <regcache>: Use
6568 readonly_detached_regcache.
6569 (ppu2spu_sniffer): Construct a new readonly_detached_regcache.
6570 * regcache.c (readonly_detached_regcache::readonly_detached_regcache):
6571 New.
6572 (regcache::save): Move it to reg_buffer.
6573 (regcache::restore): Change parameter type.
6574 (regcache_dup): Remove.
6575 * regcache.h (reg_buffer) <save>: New method.
6576 (readonly_detached_regcache): New class.
6577 * spu-tdep.c (spu2ppu_cache) <regcache>: Use
6578 readonly_detached_regcache.
6579 (spu2ppu_sniffer): Construct a new readonly_detached_regcache.
6580
fc5b8736
YQ
65812018-02-21 Yao Qi <yao.qi@linaro.org>
6582
6583 * frame.c (frame_save_as_regcache): Use regcache method save.
6584 (frame_pop): Use regcache method restore.
6585 * infrun.c (restore_infcall_suspend_state): Likewise.
6586 * linux-fork.c (fork_load_infrun_state): Likewise.
6587 * ppc-linux-tdep.c (ppu2spu_sniffer): User regcache method
6588 save.
6589 * regcache.c (regcache_save): Remove.
6590 (regcache::restore): More asserts.
6591 (regcache_cpy): Remove.
6592 * regcache.h (regcache_save): Remove the declaration.
6593 (regcache::restore): Move from private to public.
6594 Remove the friend declaration of regcache_cpy.
6595 (regcache_cpy): Remove declaration.
6596
849d0ba8
YQ
65972018-02-21 Yao Qi <yao.qi@linaro.org>
6598
6599 * aarch64-tdep.c (aarch64_pseudo_register_read_value): Change
6600 parameter type to 'readable_regcache *'.
6601 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
6602 * arm-tdep.c (arm_neon_quad_read): Likewise.
6603 (arm_pseudo_read): Likewise.
6604 * avr-tdep.c (avr_pseudo_register_read): Likewise.
6605 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
6606 * frv-tdep.c (frv_pseudo_register_read): Likewise.
6607 * gdbarch.c: Re-generated.
6608 * gdbarch.h: Re-generated.
6609 * gdbarch.sh (pseudo_register_read): Change parameter type to
6610 'readable_regcache *'.
6611 (pseudo_register_read_value): Likewise.
6612 * h8300-tdep.c (pseudo_from_raw_register): Likewise.
6613 (h8300_pseudo_register_read): Likewise.
6614 * hppa-tdep.c (hppa_pseudo_register_read): Likewise.
6615 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
6616 (i386_pseudo_register_read_into_value): Likewise.
6617 (i386_pseudo_register_read_value): Likewise.
6618 * i386-tdep.h (i386_pseudo_register_read_into_value): Update
6619 declaration.
6620 * ia64-tdep.c (ia64_pseudo_register_read): Likewise.
6621 * m32c-tdep.c (m32c_raw_read): Likewise.
6622 (m32c_read_flg): Likewise.
6623 (m32c_banked_register): Likewise.
6624 (m32c_banked_read): Likewise.
6625 (m32c_sb_read): Likewise.
6626 (m32c_part_read): Likewise.
6627 (m32c_cat_read): Likewise.
6628 (m32c_r3r2r1r0_read): Likewise.
6629 (m32c_pseudo_register_read): Likewise.
6630 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
6631 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
6632 (mep_pseudo_cr64_read): Likewise.
6633 (mep_pseudo_register_read): Likewise.
6634 * mips-tdep.c (mips_pseudo_register_read): Likewise.
6635 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
6636 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
6637 * regcache.c (regcache::raw_read): Move it to readable_regcache.
6638 (regcache::cooked_read): Likewise.
6639 (regcache::cooked_read_value): Likewise.
6640 (regcache_cooked_read_signed):
6641 (regcache::cooked_read): Likewise.
6642 * regcache.h (readable_regcache): New class.
6643 (regcache): Inherit readable_regcache. Move some methods to
6644 readable_regcache.
6645 * rl78-tdep.c (rl78_pseudo_register_read): Change
6646 parameter type to 'readable_regcache *'.
6647 * rs6000-tdep.c (do_regcache_raw_read): Remove.
6648 (e500_pseudo_register_read): Change parameter type to
6649 'readable_regcache *'.
6650 (dfp_pseudo_register_read): Likewise.
6651 (vsx_pseudo_register_read): Likewise.
6652 (efpr_pseudo_register_read): Likewise.
6653 * s390-tdep.c (s390_pseudo_register_read): Likewise.
6654 * sh-tdep.c (sh_pseudo_register_read): Likewise.
6655 * sh64-tdep.c (pseudo_register_read_portions): Likewise.
6656 (sh64_pseudo_register_read): Likewise.
6657 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
6658 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
6659 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
6660 (spu_pseudo_register_read): Likewise.
6661 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
6662 (xtensa_pseudo_register_read): Likewise.
6663
31716595
YQ
66642018-02-21 Yao Qi <yao.qi@linaro.org>
6665
6666 * regcache.c (regcache::regcache): Call reg_buffer ctor.
6667 (regcache::arch): Move it to reg_buffer::arch.
6668 (regcache::register_buffer): Likewise.
6669 (regcache::assert_regnum): Likewise.
6670 (regcache::num_raw_registers): Likewise.
6671 * regcache.h (reg_buffer): New class.
6672 (regcache): Inherit reg_buffer.
6673
7104e59b
SM
66742018-02-20 Simon Marchi <simon.marchi@ericsson.com>
6675
6676 * remote-sim.c (gdb_os_printf_filtered, gdb_os_vprintf_filtered,
6677 gdb_os_evprintf_filtered, gdb_os_error): Add ATTRIBUTE_PRINTF.
6678
2d8adcbd
MM
66792018-02-20 Markus Metzger <markus.t.metzger@intel.com>
6680
6681 * gnulib/update-gnulib.sh (IMPORTED_GNULIB_MODULES): Add mkstemp.
6682
b5884fa7
AH
66832018-02-19 Alan Hayward <alan.hayward@arm.com>
6684
6685 * Makefile.in: (COMMON_SFILES): Add common/*.c files.
6686 (SFILES): Remove common/*.c files.
6687 (COMMON_OBS): Remove some *.o files built from common/*.c files.
6688 * common/common.host: Add common reference.
6689 * configure.ac: Likewise.
6690 * configure: Regenerate.
6691
fd90ace4
YQ
66922018-02-16 Yao Qi <yao.qi@linaro.org>
6693
6694 * block.c (block_namespace_info): Inherit allocate_on_obstack.
6695 (block_initialize_namespace): Use new.
6696 * dwarf2read.c (dwarf2_per_objfile): Inherit allocate_on_obstack.
6697 (dwarf2_free_objfile): Use delete.
6698 * gdbtypes.c (type_pair): Inherit allocate_on_obstack.
6699 (copy_type_recursive): Use new.
6700 * gdb_obstack.h (allocate_on_obstack): New.
6701
85046ae2
YQ
67022018-02-15 Yao Qi <yao.qi@linaro.org>
6703
6704 PR gdb/22849
6705 * inferior.c (exit_inferior_1): Reset inf->control.
6706
355c559b
JB
67072018-02-15 Joel Brobecker <brobecker@adacore.com>
6708
6709 * ada-lang.c (ada_to_fixed_value_create): Delete advance
6710 declaration.
6711
980548fd
PA
67122018-02-14 Pedro Alves <palves@redhat.com>
6713
6714 * frame-unwind.c (frame_unwind_try_unwinder): Always call
6715 frame_cleanup_after_sniffer on exception.
6716
692d6f97
TT
67172018-02-14 Tom Tromey <tom@tromey.com>
6718
6719 * solist.h (struct target_so_ops) <bfd_open>: Make pathname
6720 const.
6721 (solib_bfd_open): Make pathname const.
6722 * solib.c (solib_bfd_open): Make pathname const.
6723 * solib-spu.c (spu_bfd_fopen): Make name const.
6724 (spu_bfd_open): Make pathname const.
6725 * solib-darwin.c (darwin_bfd_open): Make pathname const.
6726 * solib-aix.c (solib_aix_bfd_open): Make pathname const.
6727
e0cc99a6
TT
67282018-02-14 Tom Tromey <tom@tromey.com>
6729
6730 * symfile.c (symfile_bfd_open): Update.
6731 * source.h (openp, source_full_path_of, find_and_open_source):
6732 Change argument type to unique_xmalloc_ptr.
6733 * source.c (openp): Take a unique_xmalloc_ptr.
6734 (source_full_path_of, find_and_open_source): Likewise.
6735 (open_source_file, symtab_to_fullname): Update.
6736 * solist.h (struct target_so_ops) <find_and_open_solib>: Take a
6737 unique_xmalloc_ptr.
6738 * solib.c (solib_find_1): Use unique_xmalloc_ptr.
6739 (exec_file_find): Update.
6740 * psymtab.c (psymtab_to_fullname): Update.
6741 * nto-tdep.h (nto_find_and_open_solib): Update.
6742 * nto-tdep.c (nto_find_and_open_solib): Change temp_path to a
6743 unique_xmalloc_ptr.
6744 * exec.c (exec_file_attach): Update.
6745 * dwarf2read.c (try_open_dwop_file): Use unique_xmalloc_ptr.
6746 * cli/cli-cmds.c (find_and_open_script): Use unique_xmalloc_ptr.
6747
b46a8d7c
TT
67482018-02-14 Tom Tromey <tom@tromey.com>
6749
6750 * solib.c: Include source.h.
6751 * nto-tdep.c: Include source.h.
6752 * mi/mi-cmd-env.c: Include source.h.
6753 * infcmd.c: Include source.h.
6754 * exec.c: Include source.h.
6755 * defs.h (enum openp_flag, openp, source_full_path_of, mod_path)
6756 (add_path, directory_switch, source_path, init_source_path): Move
6757 declarations...
6758 * source.h (enum openp_flag, openp, source_full_path_of, mod_path)
6759 (add_path, directory_switch, source_path, init_source_path):
6760 ...here.
6761
797bc1cb
TT
67622018-02-14 Tom Tromey <tom@tromey.com>
6763
6764 * solist.h (exec_file_find, solib_find): Return
6765 unique_xmalloc_ptr.
6766 (solib_bfd_fopen): Take a const char *.
6767 * solib.c (solib_find_1): Return unique_xmalloc_ptr.
6768 (exec_file_find, solib_find): Likewise.
6769 (solib_bfd_fopen): Do not take ownership of "pathname".
6770 (solib_bfd_open): Use unique_xmalloc_ptr.
6771 * solib-darwin.c (darwin_bfd_open): Use unique_xmalloc_ptr.
6772 * solib-aix.c (solib_aix_bfd_open): Use unique_xmalloc_ptr.
6773 * infrun.c (follow_exec): Use unique_xmalloc_ptr.
6774 * exec.c (exec_file_locate_attach): Use unique_xmalloc_ptr.
6775
f98b2e33
JB
67762018-02-14 Joel Brobecker <brobecker@adacore.com>
6777
6778 * ada-lang.c (name_match_type_from_name): Remove reference to
6779 ada_name_for_lookup in function's documentation.
6780 * ada-lang.h (ada_name_for_lookup): Delete declaration.
6781
24b9144d
SM
67822018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
6783
6784 * defs.h (enum openp_flags): New enum.
6785 (OPF_TRY_CWD_FIRST, OPF_SEARCH_IN_PATH, OPF_RETURN_REALPATH):
6786 Move to enum openp_flags.
6787 (openp_flags): New enum flags.
6788 (openp): Change parameter type to openp_flags.
6789 * source.c (openp): Change parameter type to openp_flags.
6790 * cli/cli-cmds.c (find_and_open_script): Use openp_flags.
6791 * dwarf2read.c (try_open_dwop_file): Use openp_flags.
6792
387cd15b
SM
67932018-02-13 Simon Marchi <simon.marchi@polymtl.ca>
6794
6795 * maint.c (_initialize_maint_cmds): Fix prefix of maint set/show
6796 per-command.
6797
b303c6f6
AB
67982018-02-12 Andrew Burgess <andrew.burgess@embecosm.com>
6799
6800 * dwarf2read.c (dwarf2_release_queue): Delete function, move body
6801 into...
6802 (class dwarf2_queue_guard): ...the destructor of this new class.
6803 (dw2_do_instantiate_symtab): Create instance of the new class
6804 dwarf2_queue_guard, remove cleanup.
6805
9c3630e9
TT
68062018-02-09 Tom Tromey <tom@tromey.com>
6807
6808 * source.c (find_source_lines): Don't reference past the end of
6809 the vector.
6810
c4e12631
MM
68112018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6812
6813 * remote.c (remote_btrace_maybe_reopen): Change error message.
6814 * btrace.c (btrace_enable): Likewise.
6815 (parse_xml_btrace): Likewise.
6816 (parse_xml_btrace_conf): Likewise.
6817
88711fbf
MM
68182018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6819
6820 * nat/linux-btrace.c (diagnose_perf_event_open_fail): New.
6821 (linux_enable_pt, linux_enable_bts): Call
6822 diagnose_perf_event_open_fail.
6823
17ad2a4f
MM
68242018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6825
6826 * nat/linux-btrace.c (perf_event_pt_event_type): Improve error message.
6827 Remove parameter and change return type. Update callers. Move it.
6828 (linux_enable_bts, linux_enable_pt): Improve error message.
6829 (linux_enable_pt): Remove zero buffer size check.
6830 (linux_enable_btrace): Improve error messages. Remove NULL return
6831 check.
6832
de6242d3
MM
68332018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6834
6835 * btrace.c (btrace_enable): Remove target_supports_btrace call.
6836 * nat/linux-btrace.c (perf_event_pt_event_type): Move.
6837 (kernel_supports_bts, kernel_supports_pt, linux_supports_bts)
6838 (linux_supports_pt, linux_supports_btrace): Remove.
6839 (linux_enable_bts): Call cpu_supports_bts.
6840 * nat/linux-btrace.h (linux_supports_btrace): Remove.
6841 * remote.c (remote_supports_btrace): Remove.
6842 (init_remote_ops): Remove remote_supports_btrace.
6843 * target-delegates.c: Regenerated.
6844 * target.c (target_supports_btrace): Remove.
6845 * target.h (target_ops) <to_supports_btrace>: Remove
6846 (target_supports_btrace): Remove.
6847 * x86-linux-nat.c (x86_linux_create_target): Remove
6848 linux_supports_btrace.
6849
9ee23a85
MM
68502018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6851
6852 * nat/linux-btrace.c (linux_enable_btrace): Throw exception if enabling
6853 btrace failed.
6854 * x86-linux-nat.c (x86_linux_enable_btrace): Catch btrace enabling
6855 exception and use message in own exception.
6856
5c3284c1
MM
68572018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6858
6859 * nat/linux-btrace.c: Include scoped_fd.h and scoped_mmap.h.
6860 (perf_event_pt_event_type): Use gdb_file_up.
6861 (linux_enable_bts, linux_enable_pt): Use gdb::unique_xmalloc_ptr,
6862 scoped_fd, and scoped_mmap.
6863
84696f37
MM
68642018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6865
6866 * common/scoped_mmap.h: New.
6867 * unittests/scoped_mmap-selftest.c: New.
6868 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6869 unittests/scoped_mmap-selftest.c.
6870
ea4a0888
MM
68712018-02-09 Markus Metzger <markus.t.metzger@intel.com>
6872
6873 * common/scoped_fd.h: New.
6874 * unittests/scoped_fd-selftest.c: New.
6875 * Makefile.in (SUBDIR_UNITTESTS_SRCS): Add
6876 unittests/scoped_fd-selftest.c.
6877
869e8290
TT
68782018-02-09 Tom Tromey <tom@tromey.com>
6879
6880 * auto-load.c (auto_load_section_scripts): Use
6881 gdb::unique_xmalloc_ptr.
6882
a37a2ae7
TT
68832018-02-09 Tom Tromey <tom@tromey.com>
6884
6885 * auto-load.c (execute_script_contents): Use std::string.
6886
4e725347
JB
68872018-02-09 Joel Brobecker <brobecker@adacore.com>
6888
6889 * NEWS <Changes in GDB 8.1>: Clarify that "rbreak" is a new
6890 Python function, rather than a new command.
6891
9a897d43
TT
68922018-02-08 Tom Tromey <tom@tromey.com>
6893
6894 * solib.c (solib_find_1): Use std::string.
6895 (solib_bfd_fopen): Use unique_xmalloc_ptr.
6896
58ef3771
TT
68972018-02-08 Tom Tromey <tom@tromey.com>
6898
6899 * build-id.c (build_id_to_debug_bfd): Use unique_xmalloc_ptr.
6900
a9abc434
TT
69012018-02-08 Tom Tromey <tom@tromey.com>
6902
6903 * source.c (find_source_lines): Use gdb::def_vector.
6904
84f27c6f
TT
69052018-02-08 Tom Tromey <tom@tromey.com>
6906
6907 * macrocmd.c (struct temporary_macro_definition): New.
6908 (macro_define_command): Use temporary_macro_definition. Remove
6909 cleanups.
6910 (free_macro_definition_ptr): Remove.
6911
0354904b
TT
69122018-02-08 Tom Tromey <tom@tromey.com>
6913
6914 * macroexp.c (maybe_expand): Use std::string.
6915
1739cf24
TT
69162018-02-08 Tom Tromey <tom@tromey.com>
6917
6918 * macroexp.c (struct macro_buffer): Add initializers for some
6919 members.
6920 (init_buffer, init_shared_buffer, free_buffer)
6921 (free_buffer_return_text): Remove.
6922 (macro_buffer): New constructors.
6923 (~macro_buffer): New destructor.
6924 (macro_buffer::set_shared): New method.
6925 (macro_buffer::resize_buffer, macro_buffer::appendc)
6926 (macro_buffer::appendmem): Now methods, not free functions.
6927 (set_token, append_tokens_without_splicing, stringify)
6928 (macro_stringify): Update.
6929 (gather_arguments): Change return type. Remove argc_p argument,
6930 add args_ptr argument. Use std::vector.
6931 (substitute_args): Remove argc argument. Accept std::vector.
6932 (expand): Update. Use std::vector.
6933 (scan, macro_expand, macro_expand_next): Update.
6934
f6c2623e
TT
69352018-02-08 Tom Tromey <tom@tromey.com>
6936
6937 * symtab.c (default_collect_symbol_completion_matches_break_on):
6938 Use unique_xmalloc_ptr.
6939 * macroscope.h: (sal_macro_scope, user_macro_scope)
6940 (default_macro_scope): Return unique_xmalloc_ptr.
6941 * macroscope.c (sal_macro_scope, user_macro_scope)
6942 (default_macro_scope): Return unique_xmalloc_ptr.
6943 * macroexp.h (macro_expand, macro_expand_once): Return
6944 unique_xmalloc_ptr.
6945 * macroexp.c (macro_expand, macro_expand_once): Return
6946 unique_xmalloc_ptr.
6947 * macrocmd.c (macro_expand_command, macro_expand_once_command)
6948 (info_macro_command, info_macros_command): Use
6949 unique_xmalloc_ptr.
6950 * compile/compile-c-support.c (write_macro_definitions): Use
6951 unique_xmalloc_ptr.
6952 * c-exp.y (c_parse): Use unique_xmalloc_ptr.
6953
c2e0e465
SM
69542018-02-07 Simon Marchi <simon.marchi@ericsson.com>
6955
6956 * value.c (value_static_field): Assign field type instead of
6957 containing type when returning an optimized out value.
6958
3f8c94b4
YQ
69592018-02-06 Yao Qi <yao.qi@linaro.org>
6960
6961 * ft32-tdep.c (ft32_read_pc): Remove.
6962 (ft32_write_pc): Remove.
6963 (ft32_gdbarch_init): Update.
6964 * m32r-tdep.c (m32r_read_pc): Remove.
6965 (m32r_gdbarch_init): Update.
6966 * mep-tdep.c (mep_read_pc): Remove.
6967 (mep_gdbarch_init): Update.
6968 * microblaze-tdep.c (microblaze_write_pc): Remove.
6969 (microblaze_gdbarch_init): Update.
6970 * mn10300-tdep.c (mn10300_read_pc): Remove.
6971 (mn10300_write_pc): Remove.
6972 (mn10300_gdbarch_init): Update.
6973 * moxie-tdep.c (moxie_read_pc): Remove.
6974 (moxie_write_pc): Remove.
6975 (moxie_gdbarch_init): Update.
6976
bca65a23
YQ
69772018-02-06 Yao Qi <yao.qi@linaro.org>
6978
6979 * expprint.c (print_subexp_standard): Handle
6980 OP_F77_UNDETERMINED_ARGLIST.
6981 (dump_subexp_body_standard): Likewise.
6982
583e3f90 69832018-02-05 Alan Hayward <alan.hayward@arm.com>
b8df6ca7 6984
583e3f90
YQ
6985 * target-descriptions.c (tdesc_element_visitor) Add empty
6986 implementations.
b8df6ca7
AH
6987 (tdesc_type): Move make_gdb_type from here.
6988 (tdesc_type_builtin): Likewise.
6989 (tdesc_type_vector): Likewise.
6990 (tdesc_type_with_fields): Move make_gdb_type_ functions from here.
6991 (make_gdb_type_struct): Move from tdesc_type_with_fields.
6992 (make_gdb_type_union): Likewise.
6993 (make_gdb_type_flags): Likewise.
6994 (make_gdb_type_enum): Likewise.
6995 (make_gdb_type): New function.
6996 (tdesc_register_type): Use static make_gdb_type.
6997
e813d34a
RK
69982018-02-05 Ruslan Kabatsayev <b7.10110111@gmail.com>
6999
7000 * infcmd.c (default_print_one_register_info): Align natural-format
7001 column values consistently one under another.
7002 (pad_to_column): New function.
7003
0eb876f5
JB
70042018-02-05 Joel Brobecker <brobecker@adacore.com>
7005
7006 * dwarf2read.c (dwarf2_physname): Move commment.
7007
0625771b
LS
70082018-02-01 Leszek Swirski <leszeks@google.com>
7009
7010 * varobj.c (varobj_formatted_print_options): Allow recursive
7011 pretty printing if pretty printing is enabled.
7012
59498c30
LS
70132018-02-01 Leszek Swirski <leszeks@google.com>
7014
7015 * c-exp.y (lex_one_token, classify_name, yylex): Don't classify
7016 names after a structop as a filename.
7017
2d9e6acb
YQ
70182018-02-01 Yao Qi <yao.qi@linaro.org>
7019
7020 * arm-tdep.c (arm_record_data_proc_misc_ld_str): Rewrite it.
7021 (arm_record_coproc_data_proc): Likewise.
7022
df95a9cf
YQ
70232018-02-01 Yao Qi <yao.qi@linaro.org>
7024
7025 * arm-tdep.c (arm_record_extension_space): Change ret to signed.
7026
07e5f5cf
NP
70272018-01-31 Nikola Prica <nikola.prica@rt-rk.com>
7028
7029 * rs6000-tdep.c (skip_prologue): Remove shifting for lr_reg and
7030 assign shifted lr_reg to fdata->lr_register when lr_reg is set.
7031
3045b475
PA
70322018-01-31 Pedro Alves <palves@redhat.com>
7033
7034 * darwin-nat.c (darwin_interrupt): Remove ptid_t parameter.
7035 * inflow.c (child_terminal_save_inferior): Wrap reference to
7036 tcgetpgrp in HAVE_TERMIOS_H.
7037 (child_interrupt, child_pass_ctrlc): Wrap references to signal in
7038 _WIN32.
7039 * remote-sim.c (gdbsim_interrupt): Remove ptid_t parameter and
7040 always iterate over all inferiors.
7041 (gdbsim_cntrl_c): Adjust.
7042 * windows-nat.c (windows_interrupt): Remove 'ptid_t' parameter.
7043
929b5ad4
JB
70442018-01-31 Joel Brobecker <brobecker@adacore.com>
7045
7046 * gdbtypes.c (lookup_array_range_type): Make sure the array's
7047 index type is objfile-owned if the element type is as well.
7048
29236ca2
JB
70492018-01-31 Joel Brobecker <brobecker@adacore.com>
7050
7051 GDB 8.1 released.
7052
c81e8879
PR
70532018-01-30 Philipp Rudo <prudo@linux.vnet.ibm.com>
7054
7055 * s390-linux-tdep.c: Remove includes "features/s390-linux32.c" and
7056 "features/s390x-linux64.c".
7057 (_initialize_s390_linux_tdep): Remove initialization of tdescs
7058 s390_linux32 and s390x_linux64.
7059 (s390_linux_init_abi_31, s390_linux_init_abi_64): Don't set
7060 default tdesc.
7061 * s390-tdep.c: Include "features/s390-linux32.c" and
7062 "features/s390x-linux64.c".
7063 (s390_tdesc_valid): Add check for tdesc_has_registers.
7064 (s390_gdbarch_init): Make sure there is always a valid tdesc.
7065 (_initialize_s390_tdep): Initialize tdesc_s390_linux32 and
7066 tdesc_s390x_linux64.
7067 * s390-linux-tdep.h: Move export of tdesc_s390_linux32 and
7068 tdesc_s390x_linux64 to...
7069 * s390-tdep.h: ...here.
7070
e671cd59
PA
70712018-01-30 Pedro Alves <palves@redhat.com>
7072
7073 PR gdb/13211
7074 * config.in, configure: Regenerate.
7075 * configure.ac: Check for getpgid.
7076 * go32-nat.c (go32_pass_ctrlc): New.
7077 (go32_target): Install it.
7078 * inf-child.c (inf_child_target): Install
7079 child_terminal_save_inferior, child_pass_ctrlc and
7080 child_interrupt.
7081 * inf-ptrace.c (inf_ptrace_interrupt): Delete.
7082 (inf_ptrace_target): No longer install it.
7083 * infcmd.c (interrupt_target_1): Adjust.
7084 * inferior.h (child_terminal_save_inferior, child_pass_ctrlc)
7085 (child_interrupt): Declare.
7086 (inferior::terminal_state): New.
7087 * inflow.c (struct terminal_info): Update comments.
7088 (inferior_process_group): Delete.
7089 (terminal_is_ours): Delete.
7090 (gdb_tty_state): New.
7091 (child_terminal_init): Adjust.
7092 (is_gdb_terminal, sharing_input_terminal_1)
7093 (sharing_input_terminal): New functions.
7094 (child_terminal_inferior): Adjust. Use sharing_input_terminal.
7095 Set the process's actual process group in the foreground if
7096 possible. Handle is_ours_for_output/is_ours distinction. Don't
7097 mark terminal as the inferior's if not sharing GDB's terminal.
7098 Don't check attach_flag.
7099 (child_terminal_ours_for_output, child_terminal_ours): Adjust to
7100 pass down a target_terminal_state.
7101 (child_terminal_save_inferior): New, factored out from ...
7102 (child_terminal_ours_1): ... this. Handle
7103 target_terminal_state::is_ours_for_output.
7104 (child_interrupt, child_pass_ctrlc): New.
7105 (inflow_inferior_exit): Clear the inferior's terminal_state.
7106 (copy_terminal_info): Copy the inferior's terminal state.
7107 (_initialize_inflow): Remove reference to terminal_is_ours.
7108 * inflow.h (inferior_process_group): Delete.
7109 * nto-procfs.c (nto_handle_sigint, procfs_interrupt): Adjust.
7110 * procfs.c (procfs_target): Don't install procfs_interrupt.
7111 (procfs_interrupt): Delete.
7112 * remote.c (remote_serial_quit_handler): Adjust.
7113 (remote_interrupt): Remove ptid parameter. Adjust.
7114 * target-delegates.c: Regenerate.
7115 * target.c: Include "terminal.h".
7116 (target_terminal::terminal_state): Rename to ...
7117 (target_terminal::m_terminal_state): ... this.
7118 (target_terminal::init): Adjust.
7119 (target_terminal::inferior): Adjust to per-inferior
7120 terminal_state.
7121 (target_terminal::restore_inferior, target_terminal_is_ours_kind): New.
7122 (target_terminal::ours, target_terminal::ours_for_output): Use
7123 target_terminal_is_ours_kind.
7124 (target_interrupt): Remove ptid parameter. Adjust.
7125 (default_target_pass_ctrlc): Adjust.
7126 * target.h (target_ops::to_terminal_save_inferior): New field.
7127 (target_ops::to_interrupt): Remove ptid_t parameter.
7128 (target_interrupt): Remove ptid_t parameter. Update comment.
7129 (target_pass_ctrlc): Update comment.
7130 * target/target.h (target_terminal_state): New scoped enum,
7131 factored out of ...
7132 (target_terminal::terminal_state): ... here.
7133 (target_terminal::inferior): Update comments.
7134 (target_terminal::restore_inferior): New.
7135 (target_terminal::is_inferior, target_terminal::is_ours)
7136 (target_terminal::is_ours_for_output): Adjust.
7137 (target_terminal::scoped_restore_terminal_state): Adjust to
7138 rename, and call restore_inferior() instead of inferior().
7139 (target_terminal::scoped_restore_terminal_state::m_state): Change
7140 type.
7141 (target_terminal::terminal_state): Rename to ...
7142 (target_terminal::m_terminal_state): ... this and change type.
7143
9c3a5d93
PA
71442018-01-30 Pedro Alves <palves@redhat.com>
7145
7146 * linux-nat.c (wait_for_signal): New function.
7147 (wait_lwp, linux_nat_wait_1): Use it instead of calling sigsuspend
7148 directly.
7149 (async_terminal_is_ours)
7150 (linux_nat_terminal_inferior, linux_nat_terminal_ours): Delete.
7151 (linux_nat_add_target): Don't override
7152 to_terminal_inferior/to_terminal_ours.
7153
69ab5edb
SDJ
71542018-01-29 Sergio Durigan Junior <sergiodj@redhat.com>
7155
7156 * remote.c (remote_follow_fork): Don't call "detach_inferior".
7157
fc8e7e75
SM
71582018-01-28 Simon Marchi <simon.marchi@ericsson.com>
7159
7160 * dwarf2read.c (free_dwo_files): Add forward-declaration.
7161 (dwarf2_per_objfile::~dwarf2_per_objfile): Move content from
7162 dwarf2_per_objfile_free here.
7163 (dwarf2_per_objfile_free): Remove.
7164 (_initialize_dwarf2_read): Don't register
7165 dwarf2_per_objfile_free as a registry cleanup.
7166
b2a426e2
EZ
71672018-01-27 Eli Zaretskii <eliz@gnu.org>
7168
7169 Avoid compilation errors in MinGW native builds
7170
7171 The error is triggered by including python-internal.h, and the
7172 error message is:
7173
7174 In file included from d:\usr\lib\gcc\mingw32\6.3.0\include\c++\math.h:36:0,
7175 from build-gnulib/import/math.h:27,
7176 from d:/usr/Python26/include/pyport.h:235,
7177 from d:/usr/Python26/include/Python.h:58,
7178 from python/python-internal.h:94,
7179 from python/py-arch.c:24:
7180 d:\usr\lib\gcc\mingw32\6.3.0\include\c++\cmath:1157:11: error: '::hypot' has not been declared
7181 using ::hypot;
7182 ^~~~~
7183
7184 This happens because Python headers define 'hypot' to expand t
7185 '_hypot' in the Windows builds.
7186 * python/python-internal.h (_hypot) [__MINGW32__]: Define back to
7187 'hypoth'. This avoids a compilation error.
7188
0bdd8eac
AH
71892018-01-26 Alan Hayward <alan.hayward@arm.com>
7190
7191 * MAINTAINERS (Write After Approval): Fix ordering.
7192
56ae9dc3
AH
71932018-01-26 Alan Hayward <alan.hayward@arm.com>
7194
7195 * MAINTAINERS (Write After Approval): Add Alan Hayward.
7196
7433498b
AM
71972018-01-26 Alan Modra <amodra@gmail.com>
7198
7199 * ppc-linux-tdep.c (powerpc32_plt_stub): Make const.
7200 (powerpc32_plt_stub_so_1): Rename from powerpc32_plt_stub_so.
7201 Remove nop. Make const. Comment.
7202 (powerpc32_plt_stub_so_2): New.
7203 (POWERPC32_PLT_CHECK_LEN): Rename from POWERPC32_PLT_STUB_LEN.
7204 Correct count. Update uses.
7205 (ppc_skip_trampoline_code): Match powerpc32_plt_stub_so_2 too.
7206 Move common code reading PLT entry word. Correct
7207 powerpc32_plt_stub PLT address calculation.
7208 * ppc64-tdep.c (ppc64_standard_linkage1): Make const.
7209 (ppc64_standard_linkage2, ppc64_standard_linkage3): Likewise.
7210 (ppc64_standard_linkage4, ppc64_standard_linkage5): Likewise.
7211 (ppc64_standard_linkage6, ppc64_standard_linkage7): Likewise.
7212 (ppc64_standard_linkage8): Likewise.
7213 * rs6000-tdep.c (ppc_insns_match_pattern): Make pattern const.
7214 Correct insns description.
7215 * ppc-tdep.h (ppc_insns_match_pattern): Update prototype.
7216
0f59d5fc
PA
72172018-01-24 Pedro Alves <palves@redhat.com>
7218
7219 GCC PR libstdc++/83906
7220 * gdbtypes.c (operator==(const dynamic_prop &,
7221 const dynamic_prop &)): New.
7222 (operator==(const range_bounds &, const range_bounds &)): New.
7223 (check_types_equal): Use them instead of memcmp.
7224 * gdbtypes.h (operator==(const dynamic_prop &,
7225 const dynamic_prop &)): Declare.
7226 (operator!=(const dynamic_prop &, const dynamic_prop &)): Declare.
7227 (operator==(const range_bounds &, const range_bounds &)): Declare.
7228 (operator!=(const range_bounds &, const range_bounds &)): Declare.
7229
ef8914a4
PR
72302018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7231
7232 * s390-linux-tdep.c (s390_record_address_mask)
7233 (s390_record_calc_disp_common, s390_record_calc_disp)
7234 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
7235 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
7236 (s390_process_record): Move to s390-tdep.c.
7237 (s390_linux_init_abi_any): Adjust.
7238 * s390-tdep.c (s390_record_address_mask)
7239 (s390_record_calc_disp_common, s390_record_calc_disp)
7240 (s390_record_calc_disp_vsce, s390_record_calc_rl, s390_popcnt)
7241 (s390_record_gpr_g, s390_record_gpr_h, s390_record_vr)
7242 (s390_process_record): Moved from s390-linux-tdep.c
7243 (s390_gdbarch_init): Adjust.
7244
d6e58945
PR
72452018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7246
7247 * s390-linux-nat.c (s390-tdep.h): New include.
7248 * Makefile.in (ALL_TARGET_OBS): Add s390-tdep.o.
7249 (HFILES_NO_SRCDIR): Add s390-tdep.h.
7250 (ALLDEPFILES): Add s390-tdep.c.
7251 * configure.tgt (s390*-*-linux*): Add s390-tdep.o.
7252 * s390-linux-tdep.h (HWCAP_S390_*, S390_*_REGNUM): Move to...
7253 * s390-tdep.h: ...this. New file.
7254 * s390-linux-tdep.c (s390-tdep.h): New include.
7255 (_initialize_s390_tdep): Rename to...
7256 (_initialize_s390_linux_tdep): ...this and adjust.
7257 (s390_abi_kind, s390_vector_abi_kind, gdbarch_tdep)
7258 (enum named opcodes, S390_NUM_GPRS, S390_NUM_FPRS): Move to
7259 s390-tdep.h.
7260 (s390_break_insn, s390_breakpoint, s390_readinstruction, is_ri)
7261 (is_ril, is_rr, is_rre, is_rs, is_rsy, is_rx, is_rxy)
7262 (s390_is_partial_instruction, s390_software_single_step)
7263 (is_non_branch_ril, s390_displaced_step_copy_insn)
7264 (s390_displaced_step_fixup, s390_displaced_step_hw_singlestep)
7265 (s390_prologue_data, s390_addr, s390_store, s390_load)
7266 (s390_check_for_saved, s390_analyze_prologue, s390_skip_prologue)
7267 (s390_register_call_saved, s390_guess_tracepoint_registers)
7268 (s390_register_name, s390_dwarf_regmap, s390_dwarf_reg_to_regnum)
7269 (regnum_is_gpr_full, regnum_is_vxr_full, s390_value_from_register)
7270 (s390_pseudo_register_name, s390_pseudo_register_type)
7271 (s390_pseudo_register_read, s390_pseudo_register_write)
7272 (s390_pseudo_register_reggroup_p, s390_ax_pseudo_register_collect)
7273 (s390_ax_pseudo_register_push_stack, s390_gen_return_address)
7274 (s390_addr_bits_remove, s390_address_class_type_flags)
7275 (s390_address_class_type_flags_to_name)
7276 (s390_address_class_name_to_type_flags, s390_effective_inner_type)
7277 (s390_function_arg_float, s390_function_arg_vector)
7278 (is_power_of_two, s390_function_arg_integer, s390_arg_state)
7279 (s390_handle_arg, s390_push_dummy_call, s390_dummy_id)
7280 (s390_frame_align, s390_register_return_value, s390_return_value)
7281 (s390_stack_frame_destroyed_p, s390_unwind_pc, s390_unwind_sp)
7282 (s390_unwind_pseudo_register, s390_adjust_frame_regnum)
7283 (s390_dwarf2_prev_register, s390_dwarf2_frame_init_reg)
7284 (s390_trad_frame_prev_register, s390_unwind_cache)
7285 (s390_prologue_frame_unwind_cache)
7286 (s390_backchain_frame_unwind_cache, s390_frame_unwind_cache)
7287 (s390_frame_this_id, s390_frame_prev_register, s390_frame_unwind)
7288 (s390_stub_unwind_cache, s390_stub_frame_unwind_cache)
7289 (s390_stub_frame_this_id, s390_stub_frame_prev_register)
7290 (s390_stub_frame_sniffer, s390_stub_frame_unwind)
7291 (s390_frame_base_address, s390_local_base_address)
7292 (s390_frame_base, s390_gcc_target_options)
7293 (s390_gnu_triplet_regexp, s390_stap_is_single_operand)
7294 (s390_validate_reg_range, s390_tdesc_valid)
7295 (s390_gdbarch_tdep_alloc, s390_gdbarch_init): Move to...
7296 * s390-tdep.c: ...this. New file.
7297
9c0b896e
PR
72982018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7299
7300 * s390-linux-tdep.c (gdbarch_tdep.s390_syscall_record): New hook.
7301 (s390_process_record, s390_gdbarch_tdep_alloc)
7302 (s390_linux_init_abi_any): Use/set new hook.
7303
7042632b
PR
73042018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7305
7306 * s390-linux-tdep.c (osabi.h): New include.
7307 (s390_linux_init_abi_31, s390_linux_init_abi_64)
7308 (s390_linux_init_abi_any): New functions.
7309 (s390_gdbarch_init, _initialize_s390_tdep): Adjust.
7310
650f5e13
PR
73112018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7312
7313 * s390-linux-tdep.c (s390_gdbarch_init): Use gdb_assert for
7314 tdesc_has_registers check
7315
47c9317e
PR
73162018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7317
7318 * s390-linux-tdep.c (s390_tdesc_valid): New function.
7319 (s390_validate_reg_range): New macro.
7320 (s390_gdbarch_init): Adjust.
7321
095085d8
PR
73222018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7323
7324 * s390-linux-tdep.c (gdbarch_tdep) <tdesc>: New field.
7325 (s390_gdbarch_tdep_alloc): Adjust.
7326 (s390_gdbarch_init): Adjust.
7327
ab9bcc67
PR
73282018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7329
7330 * s390-linux-tdep.c (gdbarch_tdep) <have_linux_v1, have_linux_v2>
7331 <have_tdb>: Change type to bool.
7332 (s390_gdbarch_tdep_alloc): Adjust.
7333 (s390_gdbarch_init): Adjust.
7334
21f6f5ff
PR
73352018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7336
7337 * s390-linux-tdep (s390_abi_kind) <ABI_NONE>: New default field.
7338 (gdbarch_tdep) <have_upper, have_vx>: New fields.
7339 (s390_gdbarch_tdep_alloc): New function.
7340 (s390_gdbarch_init): Allocate tdep at start and use its fields
7341 instead of separate variables.
7342
0eb97953
PR
73432018-01-23 Philipp Rudo <prudo@linux.vnet.ibm.com>
7344
7345 * s390-linux-tdep.c (s390_gdbarch_init): Remove duplicate checks
7346 when looking for cached gdbarch and add comment for remaining.
7347
5c319bb2
PA
73482018-01-22 Pedro Alves <palves@redhat.com>
7349 Sergio Durigan Junior <sergiodj@redhat.com>
7350
7351 * typeprint.c (whatis_exp): Initialize "val" in the "whatis type"
7352 case.
7353
d65ce302
MR
73542018-01-22 Maciej W. Rozycki <macro@mips.com>
7355
7356 * MAINTAINERS: Update my company e-mail address.
7357
ec7a5fcb
YQ
73582018-01-22 Yao Qi <yao.qi@linaro.org>
7359
7360 * regcache.c (cooked_write_test): New function.
7361 (_initialize_regcache): Register the test.
7362
11f57cb6
YQ
73632018-01-22 Yao Qi <yao.qi@linaro.org>
7364
7365 * ia64-tdep.c (ia64_pseudo_register_read): Call
7366 regcache->cooked_read instead of regcache_cooked_read_unsigned.
7367 * m32c-tdep.c (m32c_cat_read): Likewise.
7368 (m32c_r3r2r1r0_read): Likewise.
7369 * m68hc11-tdep.c (m68hc11_pseudo_register_read): Likewise.
7370 * xtensa-tdep.c (xtensa_register_read_masked): Likewise.
7371
03f50fc8
YQ
73722018-01-22 Yao Qi <yao.qi@linaro.org>
7373
7374 * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
7375 method raw_read instead of regcache_raw_read.
7376 * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
7377 * arm-tdep.c (arm_neon_quad_read): Likewise.
7378 * avr-tdep.c (avr_pseudo_register_read): Likewise.
7379 * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
7380 * frv-tdep.c (frv_pseudo_register_read): Likewise.
7381 * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
7382 * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
7383 (i386_pseudo_register_read_into_value): Likewise.
7384 * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
7385 * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
7386 * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
7387 * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
7388 * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
7389 * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
7390 * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
7391 * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
7392 * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
7393
dc711524
YQ
73942018-01-22 Yao Qi <yao.qi@linaro.org>
7395
7396 * Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
7397 * configure.tgt: Remove target mt.
7398 * mt-tdep.c: Remove.
7399 * regcache.c (cooked_read_test): Remove the check for mt.
7400
3f5a868b
YQ
74012018-01-22 Yao Qi <yao.qi@linaro.org>
7402
7403 * jit.c (jit_frame_prev_register): Call regcache::cooked_read
7404 instead of gdbarch_pseudo_register_read_value.
7405
de4cb04a
JB
74062018-01-22 Joel Brobecker <brobecker@adacore.com>
7407
7408 * dwarf2read.c (need_gnat_info): Return nonzero if the cu's
7409 language is Ada.
7410
a9e40818
JB
74112018-01-22 Joel Brobecker <brobecker@adacore.com>
7412
7413 * linespec.c (create_sals_line_offset): Remove code that preserved
7414 the symtab_and_line's line number.
7415
e707fc44
AB
74162018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7417
7418 * varobj.c (varobj_create): Don't set valid_block when creating a
7419 floating varobj.
7420
03d0bf7b
AB
74212018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7422
7423 * varobj.c (varobj_create): Remove out of date comment.
7424
ae451627
AB
74252018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7426
7427 PR mi/20395
7428 * ada-exp.y (write_var_from_sym): Pass extra parameter when
7429 updating innermost block.
7430 * parse.c (innermost_block_tracker::update): Take extra type
7431 parameter, and check types match before updating innermost block.
7432 (write_dollar_variable): Update innermost block for registers.
7433 * parser-defs.h (enum innermost_block_tracker_type): New enum.
7434 (innermost_block_tracker::innermost_block_tracker): Initialise
7435 m_types member.
7436 (innermost_block_tracker::reset): Take type parameter.
7437 (innermost_block_tracker::update): Take type parameter, and pass
7438 type through as needed.
7439 (innermost_block_tracker::m_types): New member.
7440 * varobj.c (varobj_create): Pass type when reseting innermost
7441 block.
7442
aee1fcdf
AB
74432018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7444
7445 * ada-exp.y (write_var_from_sym): Switch to innermost_block API.
7446 * ada-lang.c (resolve_subexp): Likewise.
7447 * breakpoint.c (set_breakpoint_condition) Likewise.
7448 (watch_command_1) Likewise.
7449 * c-exp.y (variable): Likewise.
7450 * d-exp.y (PrimaryExpression): Likewise.
7451 * f-exp.y (variable): Likewise.
7452 * go-exp.y (variable): Likewise.
7453 * m2-exp.y (variable): Likewise.
7454 * objfiles.c (objfile::~objfile): Likewise.
7455 * p-exp.y (variable): Likewise.
7456 * parse.c (innermost_block): Change type.
7457 * parser-defs.h (class innermost_block_tracker): New.
7458 (innermost_block): Change to innermost_block_tracker.
7459 * printcmd.c (display_command): Switch to innermost_block API.
7460 (do_one_display): Likewise.
7461 * rust-exp.y (do_one_display): Likewise.
7462 * symfile.c (clear_symtab_users): Likewise.
7463 * varobj.c (varobj_create): Switch to innermost_block API, replace
7464 use of innermost_block with block stored on varobj object.
7465
396af9a1
AB
74662018-01-21 Andrew Burgess <andrew.burgess@embecosm.com>
7467
7468 * expression.h (innermost_block): Remove declaration.
7469 * varobj.c: Add 'parser-defs.h' include.
7470
fcfcc376
TT
74712018-01-19 Tom Tromey <tom@tromey.com>
7472
7473 * rust-lang.c (rust_lookup_symbol_nonlocal): Look up qualified
7474 symbols in the static and global blocks.
7475
5a6c3296
JC
74762018-01-19 James Clarke <jrtc27@jrtc27.com>
7477
7478 * nat/linux-ptrace.c: Remove unnecessary reinclusion of
7479 gdb_ptrace.h, and move including gdb_wait.h ...
7480 * nat/linux-ptrace.h: ... to here.
7481
bc09b0c1
SM
74822018-01-19 Simon Marchi <simon.marchi@ericsson.com>
7483
7484 * inf-ptrace.c (inf_ptrace_detach): Adjust call to
7485 inf_ptrace_detach_success.
7486 (inf_ptrace_detach_success): Add inferior parameter, use it
7487 instead of inferior_ptid, pass it to detach_inferior.
7488 * inf-ptrace.h (inf_ptrace_detach_success): Add inferior
7489 parameter.
7490 * inferior.c (detach_inferior): Add overload that takes an
7491 inferior object.
7492 * inferior.h (detach_inferior): Likewise.
7493 * linux-nat.c (linux_nat_detach): Use the inf parameter, don't
7494 use inferior_ptid, adjust call to inf_ptrace_detach_success.
7495 * linux-thread-db.c (thread_db_detach): Use inf parameter.
7496
6e1e1966
SM
74972018-01-19 Simon Marchi <simon.marchi@ericsson.com>
7498
7499 * target.h (struct target_ops) <to_detach>: Add inferior
7500 parameter.
7501 (target_detach): Likewise.
7502 * target.c (dispose_inferior): Pass inferior down.
7503 (target_detach): Pass inferior down. Assert that it is equal to
7504 the current inferior.
7505 * aix-thread.c (aix_thread_detach): Pass inferior down.
7506 * corefile.c (core_file_command): Pass current_inferior() down.
7507 * corelow.c (core_detach): Add inferior parameter.
7508 * darwin-nat.c (darwin_detach): Likewise.
7509 * gnu-nat.c (gnu_detach): Likewise.
7510 * inf-ptrace.c (inf_ptrace_detach): Likewise.
7511 * infcmd.c (detach_command): Pass current_inferior() down to
7512 target_detach.
7513 * infrun.c (follow_fork_inferior): Pass parent_inf to
7514 target_detach.
7515 (handle_vfork_child_exec_or_exit): Pass inf->vfork_parent to
7516 target_detach.
7517 * linux-nat.c (linux_nat_detach): Add inferior parameter.
7518 * linux-thread-db.c (thread_db_detach): Likewise.
7519 * nto-procfs.c (procfs_detach): Likewise.
7520 * procfs.c (procfs_detach): Likewise.
7521 * record.c (record_detach): Likewise.
7522 * record.h (struct inferior): Forward-declare.
7523 (record_detach): Add inferior parameter.
7524 * remote-sim.c (gdbsim_detach): Likewise.
7525 * remote.c (remote_detach_1): Likewise.
7526 (remote_detach): Likewise.
7527 (extended_remote_detach): Likewise.
7528 * sol-thread.c (sol_thread_detach): Likewise.
7529 * target-debug.h (target_debug_print_inferior_p): New macro.
7530 * target-delegates.c: Re-generate.
7531 * top.c (kill_or_detach): Pass inferior down to target_detach.
7532 * windows-nat.c (windows_detach): Add inferior parameter.
7533
6bd6f3b6
SM
75342018-01-19 Simon Marchi <simon.marchi@ericsson.com>
7535
7536 * target.h (struct target_ops) <to_detach>: Remove args
7537 parameter.
7538 (target_detach): Likewise.
7539 * target.c (dispose_inferior): Adjust.
7540 (target_detach): Remove args parameter, adjust.
7541 * aix-thread.c (aix_thread_detach): Adjust.
7542 * corefile.c (core_file_command): Adjust.
7543 * corelow.c (core_detach): Adjust.
7544 * darwin-nat.c (darwin_detach): Adjust.
7545 * gnu-nat.c (gnu_detach): Adjust.
7546 * inf-ptrace.c (inf_ptrace_detach): Adjust.
7547 * infcmd.c (detach_command): Adjust
7548 * infrun.c (follow_fork_inferior): Adjust.
7549 (handle_vfork_child_exec_or_exit): Adjust.
7550 * linux-fork.c (linux_fork_detach): Remove args parameter.
7551 * linux-fork.h (linux_fork_detach): Likewise.
7552 * linux-nat.c (linux_nat_detach): Likewise, and adjust.
7553 * linux-thread-db.c (thread_db_detach): Likewise.
7554 * nto-procfs.c (procfs_detach): Likewise.
7555 * procfs.c (procfs_detach): Likewise.
7556 (do_detach): Remove signo parameter.
7557 * record.c (record_detach): Remove args parameter.
7558 * record.h (record_detach): Likewise.
7559 * remote-sim.c (gdbsim_detach): Likewise.
7560 * remote.c (remote_detach_1): Likewise.
7561 (remote_detach): Likewise.
7562 (extended_remote_detach): Likewise.
7563 * sol-thread.c (sol_thread_detach): Likewise.
7564 * target-delegates.c: Re-generate.
7565 * top.c (struct qt_args) <args>: Remove field.
7566 (kill_or_detach): Don't pass args.
7567 (quit_force): Don't set args.
7568 * windows-nat.c (windows_detach): Remove args parameter.
7569
88af8ea8
YQ
75702018-01-19 Yao Qi <yao.qi@linaro.org>
7571
7572 * arm-linux-tdep.c (arm_linux_gcc_target_options): New function.
7573 (arm_linux_init_abi): Install it.
7574
dea445b9
YQ
75752018-01-19 Yao Qi <yao.qi@linaro.org>
7576
7577 * osabi.c (gdb_osabi_names): Extend the regexp for
7578 arm-linux-gnueabihf.
7579
4a17f768
YQ
75802018-01-18 Yao Qi <yao.qi@linaro.org>
7581
7582 * dwarf2read.c (abbrev_table) <abbrevs>: Rename it to
7583 m_abbrevs.
7584 (abbrev_table::add_abbrev): Update.
7585 (abbrev_table::lookup_abbrev): Update.
7586
d679c21a
YQ
75872018-01-18 Yao Qi <yao.qi@linaro.org>
7588
7589 * ppc-linux-tdep.c (ppu2spu_prev_register): Call cooked_read.
7590
7d937cad
SDJ
75912018-01-17 Sergio Durigan Junior <sergiodj@redhat.com>
7592
7593 * compile/compile.c (compile_to_object): Convert "triplet_rx"
7594 to "std::string".
7595
9e14690d
TT
75962018-01-17 Tom Tromey <tom@tromey.com>
7597
7598 * dwarf2read.c (symbolp): Remove typedef. Don't instantiate VEC.
7599
50a82047
TT
76002018-01-17 Tom Tromey <tom@tromey.com>
7601
7602 * gdbtypes.h (add_dyn_prop): Remove objfile parameter.
7603 * gdbtypes.c (add_dyn_prop): Remove objfile parameter.
7604 (create_array_type_with_stride): Update.
7605 * dwarf2read.c (set_die_type): Update.
7606
c89b44cd
TT
76072018-01-17 Tom Tromey <tom@tromey.com>
7608
7609 * dwarf2read.c (delayed_method_info): Remove typedef.
7610 (dwarf2_cu::method_info): Now a std::vector.
7611 (add_to_method_list): Update.
7612 (free_delayed_list): Remove.
7613 (compute_delayed_physnames): Update.
7614 (process_full_comp_unit, process_full_type_unit): Clear the method
7615 list. Remove cleanups.
7616 (psymtab_include_file_name): Add name_holder parameter. Use
7617 unique_xmalloc_ptr.
7618 (dwarf_decode_lines): Update.
7619
fcd3b13d
SM
76202018-01-17 Tom Tromey <tom@tromey.com>
7621 Simon Marchi <simon.marchi@ericsson.com>
7622
7623 * dwarf2read.c (struct dwarf2_cu): Add constructor, destructor.
7624 (dwarf2_per_objfile::free_cached_comp_units)
7625 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
7626 (init_cutu_and_read_dies_no_follow): Update.
7627 (dwarf2_cu::dwarf2_cu): Rename from init_one_comp_unit.
7628 (dwarf2_cu::~dwarf2_cu): New.
7629 (free_heap_comp_unit, free_stack_comp_unit): Remove.
7630 (age_cached_comp_units, free_one_cached_comp_unit): Update.
7631
685af9cd
TT
76322018-01-17 Tom Tromey <tom@tromey.com>
7633 Simon Marchi <simon.marchi@ericsson.com>
7634
7635 * dwarf2read.c (struct dwarf2_cu) <abbrev_table>: Remove.
7636 (struct die_reader_specs) <abbrev_table>: New member.
7637 (struct abbrev_table): Add constructor.
7638 <alloc_abbrev, add_abbrev, lookup_abbrev>: Declare.
7639 <abbrev_obstack>: Now an auto_obstack.
7640 (abbrev_table_up): New typedef.
7641 (init_cu_die_reader): Add abbrev_table parameter.
7642 (read_cutu_die_from_dwo): Remove abbrev_table_provided parameter.
7643 Add result_dwo_abbrev_table.
7644 (init_tu_and_read_dwo_dies, init_cutu_and_read_dies)
7645 (init_cutu_and_read_dies_no_follow, build_type_psymtabs_1):
7646 Update.
7647 (peek_die_abbrev): Take die_reader_specs, not dwarf_cu as
7648 parameter.
7649 (skip_children): Update.
7650 (abbrev_table::alloc_abbrev): Rename from
7651 abbrev_table_alloc_abbrev.
7652 (abbrev_table::add_abbrev): Rename from abbrev_table_add_abbrev.
7653 (abbrev_table::lookup_abbrev): Rename from
7654 abbrev_table_lookup_abbrev.
7655 (abbrev_table_read_table): Return abbrev_table_up.
7656 (abbrev_table_free, abbrev_table_free_cleanup)
7657 (dwarf2_read_abbrevs, dwarf2_free_abbrev_table): Remove.
7658 (load_partial_dies): Update.
7659
5e2db402
TT
76602018-01-17 Tom Tromey <tom@tromey.com>
7661
7662 * dwarf2read.c (dwarf2_compute_name): Update comment.
7663 (read_func_scope, read_variable): Update.
7664 (new_symbol): Remove.
7665 (new_symbol_full): Rename to new_symbol.
7666
ee7f689e 76672018-01-17 Mike Gulick <mgulick@mathworks.com>
41667530
MG
7668
7669 PR gdb/16577
7670 * gdb_bfd.c (gdb_bfd_map_section): If unable to read object file, issue
7671 a warning instead of throwing an error, set section size to 0 and return
7672 NULL.
7673 * gdb_bfd.h (gdb_bfd_map_section): Update description.
7674
4d9b86e1
SM
76752018-01-17 Simon Marchi <simon.marchi@ericsson.com>
7676
7677 * nat/linux-ptrace.h (linux_ptrace_attach_fail_reason): Return
7678 std::string.
7679 (linux_ptrace_attach_fail_reason_string): Likewise.
7680 * nat/linux-ptrace.c (linux_ptrace_attach_fail_reason):
7681 Likewise.
7682 (linux_ptrace_attach_fail_reason_string): Likewise.
7683 * linux-nat.c (attach_proc_task_lwp_callback): Adjust.
7684
a7b2d0fb
SM
76852018-01-17 Simon Marchi <simon.marchi@ericsson.com>
7686
7687 * linux-nat.c (linux_nat_attach): Remove xstrdup.
7688
f517c180
EA
76892018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
7690
7691 PR gdb/21559
7692 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
7693 checking for fs_base/gs_base fields in struct user_regs_struct.
7694 * configure: Regenerate.
7695
7045b1ca
YQ
76962018-01-17 Yao Qi <yao.qi@linaro.org>
7697
7698 * aarch64-linux-tdep.c (aarch64_linux_gcc_target_options): New
7699 function.
7700 (aarch64_linux_init_abi): Install it to gdbarch hook
7701 gcc_target_options.
7702
db422fb2
PA
77032018-01-15 Pedro Alves <palves@redhat.com>
7704
7705 * common/signals-state-save-restore.c
7706 (save_original_signals_state): Fix typos.
7707
ba643918
SDJ
77082017-01-12 Tom Tromey <tom@tromey.com>
7709 Sergio Durigan Junior <sergiodj@redhat.com>
7710
7711 * Makefile.in (install-only): Install gdb-add-index.
7712
906b4aac
JB
77132018-01-12 John Baldwin <jhb@FreeBSD.org>
7714
7715 * fbsd-tdep.c (KVE_PROTECTION): Correct value.
7716
bdf2a94a
AA
77172018-01-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7718
7719 * infrun.c (keep_going_pass_signal): Clear step-over info when
7720 insert_breakpoints fails.
7721
71d378ae
PA
77222018-01-11 Pedro Alves <palves@redhat.com>
7723
7724 PR gdb/22583
7725 * infrun.c (resume): Rename to ...
7726 (resume_1): ... this.
7727 (resume): Reimplement as wrapper around resume_1.
7728
3cada740
PA
77292018-01-11 Pedro Alves <palves@redhat.com>
7730
7731 PR remote/22597
7732 * remote.c (remote_parse_stop_reply): Default to the last-set
7733 general thread instead of to 'magic_null_ptid'.
7734
618daa93
PA
77352018-01-10 Pedro Alves <palves@redhat.com>
7736
7737 * language.h (language_get_symbol_name_matcher): Rename ...
7738 (get_symbol_name_matcher): ... this.
7739 * language.c (language_get_symbol_name_matcher): Ditto.
7740 * dictionary.c, linespec.c, minsyms.c, psymtab.c, symtab.c: All
7741 callers adjusted.
7742
c63d3e8d
PA
77432018-01-10 Pedro Alves <palves@redhat.com>
7744
7745 PR gdb/22670
7746 * dwarf2read.c
7747 (gdb_index_symbol_name_matcher::gdb_index_symbol_name_matcher):
7748 Adjust to use language_get_symbol_name_matcher instead of
7749 language_defn::la_get_symbol_name_matcher.
7750 * language.c (language_get_symbol_name_matcher): If in Ada mode
7751 and the lookup name is a verbatim match, return Ada's matcher.
7752 * language.h (language_get_symbol_name_matcher): Adjust comment.
7753 (ada_lookup_name_info::verbatim_p):: New method.
7754
d4c2a405
PA
77552018-01-10 Pedro Alves <palves@redhat.com>
7756
7757 PR gdb/22670
7758 * ada-lang.c (ada_collect_symbol_completion_matches): If the
7759 minsym's language is language_auto or language_cplus, pass down
7760 language_ada instead.
7761 * symtab.c (compare_symbol_name): Don't frob symbol language here.
7762
8825213e
PA
77632018-01-10 Pedro Alves <palves@redhat.com>
7764
7765 PR gdb/22670
7766 * minsyms.c (linkage_name_str): New function.
7767 (iterate_over_minimal_symbols): Use it.
7768
2d97a5d9
JB
77692018-01-09 John Baldwin <jhb@FreeBSD.org>
7770
7771 * NEWS: Document that 'info proc' now works on FreeBSD.
7772
92fce24d
JB
77732018-01-09 John Baldwin <jhb@FreeBSD.org>
7774
7775 * configure.ac: Check for kinfo_getfile in libutil.
7776 * configure: Regenerate.
7777 * config.in: Regenerate.
7778 * fbsd-nat.c: Include "fbsd-tdep.h".
7779 (fbsd_fetch_cmdline): New.
7780 (fbsd_fetch_kinfo_proc): Move earlier and change to return a bool
7781 rather than calling error.
7782 (fbsd_info_proc): New.
7783 (fbsd_thread_name): Report error if fbsd_fetch_kinfo_proc fails.
7784 (fbsd_wait): Report warning if fbsd_fetch_kinfo_proc fails.
7785 (fbsd_nat_add_target): Set "to_info_proc" to "fbsd_info_proc".
7786
262f62f5
JB
77872018-01-09 John Baldwin <jhb@FreeBSD.org>
7788
7789 * fbsd-nat.c (struct free_deleter): Remove.
7790 (fbsd_find_memory_regions): Use gdb::unique_xmalloc_ptr<>.
7791
b999e203
JB
77922018-01-09 John Baldwin <jhb@FreeBSD.org>
7793
7794 * fbsd-nat.c (fbsd_pid_to_exec_file) [KERN_PROC_PATHNAME]: Return
7795 NULL for an empty pathname.
7796
d2176225
JB
77972018-01-09 John Baldwin <jhb@FreeBSD.org>
7798
7799 * fbsd-tdep.c (KVE_STRUCTSIZE, KVE_START, KVE_END, KVE_OFFSET)
7800 (KVE_FLAGS, KVE_PROTECTION, KVE_PATH, KINFO_VME_PROT_READ)
7801 (KINFO_VME_PROT_WRITE, KINFO_VME_PROT_EXEC, KINFO_VME_FLAG_COW)
7802 (KINFO_VME_FLAG_NEEDS_COPY, KINFO_VME_FLAG_NOCOREDUMP)
7803 (KINFO_VME_FLAG_SUPER, KINFO_VME_FLAG_GROWS_UP)
7804 (KINFO_VME_FLAG_GROWS_DOWN, KF_STRUCTSIZE, KF_TYPE, KF_FD)
7805 (KF_PATH, KINFO_FILE_TYPE_VNODE, KINFO_FILE_FD_TYPE_CWD)
7806 (KINFO_FILE_FD_TYPE_TEXT, SIG_WORDS, struct kinfo_proc_layout)
7807 (kinfo_proc_layout_32, kinfo_proc_layout_i386)
7808 (kinfo_proc_layout_64, fbsd_vm_map_entry_flags)
7809 (fbsd_core_info_proc_mappings, fbsd_core_vnode_path)
7810 (fbsd_core_fetch_timeval, fbsd_print_sigset)
7811 (fbsd_core_info_proc_status, fbsd_core_info_proc): New.
7812 (fbsd_init_abi): Install gdbarch "core_info_proc" method.
7813 * fbsd-tdep.h (fbsd_vm_map_entry_flags): New.
7814
9c4ac400
ST
78152018-01-08 Samuel Thibault <samuel.thibault@ens-lyon.org>
7816
7817 * gdb/gnu-nat.c: Include <elf.h> and <link.h>.
7818 (gnu_xfer_auxv): New function.
7819 (gnu_xfer_partial): Call gnu_xfer_auxv when `object' is
7820 TARGET_OBJECT_AUXV.
7821
1e5ded6c
YQ
78222018-01-08 Yao Qi <yao.qi@linaro.org>
7823 Simon Marchi <simon.marchi@ericsson.com>
7824
7825 * Makefile.in (COMMON_SFILES): Remove selftest-arch.c and
7826 common/selftest.c.
7827 (COMMON_OBS): Remove selftest.o.
7828 * configure.ac: Append selftest-arch.c and common/selftest.c to
7829 CONFIG_SRCS. Append selftest-arch.o and selftest.o to COMMON_OBS.
7830 * configure: Re-generated.
7831 * maint.c (maintenance_selftest): Wrap selftests::run_tests with
7832 GDB_SELF_TEST.
7833 (maintenance_info_selftests): Likewise.
7834
04bafb1e
XR
78352018-01-08 Xavier Roirand <roirand@adacore.com>
7836
7837 * ada-valprint.c (val_print_packed_array_elements): Use
7838 proper number of elements when printing an array indexed
7839 by an enumeration type.
7840
518817b3
SM
78412018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
7842
7843 * dwarf2read.c (struct dwarf2_cu) <dwarf2_per_objfile>: Remove.
7844 (dw2_get_file_names_reader): Adjust.
7845 (lookup_dwo_signatured_type): Adjust.
7846 (lookup_dwp_signatured_type): Adjust.
7847 (lookup_signatured_type): Adjust.
7848 (create_type_unit_group): Adjust.
7849 (get_type_unit_group): Adjust.
7850 (process_psymtab_comp_unit_reader): Adjust.
7851 (build_type_psymtabs_reader): Adjust.
7852 (scan_partial_symbols): Adjust.
7853 (add_partial_symbol): Adjust.
7854 (add_partial_subprogram): Adjust.
7855 (peek_die_abbrev): Adjust.
7856 (fixup_go_packaging): Adjust.
7857 (process_imported_unit_die): Adjust.
7858 (dwarf2_compute_name): Adjust.
7859 (dwarf2_physname): Adjust.
7860 (read_import_statement): Adjust.
7861 (handle_DW_AT_stmt_list): Adjust.
7862 (read_file_scope): Adjust.
7863 (read_func_scope): Adjust.
7864 (read_lexical_block_scope): Adjust.
7865 (read_call_site_scope): Adjust.
7866 (read_variable): Adjust.
7867 (dwarf2_rnglists_process): Adjust.
7868 (dwarf2_ranges_process): Adjust.
7869 (dwarf2_ranges_read): Adjust.
7870 (dwarf2_get_pc_bounds): Adjust.
7871 (dwarf2_record_block_ranges): Adjust.
7872 (dwarf2_add_field): Adjust.
7873 (dwarf2_add_member_fn): Adjust.
7874 (read_structure_type): Adjust.
7875 (process_structure_scope): Adjust.
7876 (read_enumeration_type): Adjust.
7877 (read_array_type): Adjust.
7878 (mark_common_block_symbol_computed): Adjust.
7879 (read_common_block): Adjust.
7880 (read_namespace_type): Adjust.
7881 (read_namespace): Adjust.
7882 (read_module_type): Adjust.
7883 (read_tag_pointer_type): Adjust.
7884 (read_tag_ptr_to_member_type): Adjust.
7885 (read_tag_string_type): Adjust.
7886 (read_subroutine_type): Adjust.
7887 (read_typedef): Adjust.
7888 (read_base_type): Adjust.
7889 (attr_to_dynamic_prop): Adjust.
7890 (read_subrange_type): Adjust.
7891 (read_unspecified_type): Adjust.
7892 (dwarf2_read_abbrevs): Adjust.
7893 (load_partial_dies): Adjust.
7894 (read_partial_die): Adjust.
7895 (find_partial_die): Adjust.
7896 (guess_partial_die_structure_name): Adjust.
7897 (fixup_partial_die): Adjust.
7898 (read_attribute_value): Adjust.
7899 (read_addr_index): Adjust.
7900 (read_addr_index_from_leb128): Adjust.
7901 (read_str_index): Adjust.
7902 (dwarf2_string_attr): Adjust.
7903 (get_debug_line_section): Adjust.
7904 (dwarf_decode_line_header): Adjust.
7905 (lnp_state_machine::check_line_address): Adjust.
7906 (dwarf_decode_lines_1): Adjust.
7907 (dwarf_decode_lines): Adjust.
7908 (dwarf2_start_symtab): Adjust.
7909 (var_decode_location): Adjust.
7910 (new_symbol_full): Adjust.
7911 (dwarf2_const_value_data): Adjust.
7912 (dwarf2_const_value_attr): Adjust.
7913 (dwarf2_const_value): Adjust.
7914 (die_type): Adjust.
7915 (die_containing_type): Adjust.
7916 (build_error_marker_type): Adjust.
7917 (lookup_die_type): Adjust.
7918 (guess_full_die_structure_name): Adjust.
7919 (anonymous_struct_prefix): Adjust.
7920 (determine_prefix): Adjust.
7921 (dwarf2_name): Adjust.
7922 (follow_die_ref_or_sig): Adjust.
7923 (follow_die_offset): Adjust.
7924 (follow_die_ref): Adjust.
7925 (follow_die_sig_1): Adjust.
7926 (follow_die_sig): Adjust.
7927 (get_signatured_type): Adjust.
7928 (get_DW_AT_signature_type): Adjust.
7929 (decode_locdesc): Adjust.
7930 (dwarf_decode_macros): Adjust.
7931 (cu_debug_loc_section): Adjust.
7932 (fill_in_loclist_baton): Adjust.
7933 (dwarf2_symbol_mark_computed): Adjust.
7934 (init_one_comp_unit): Don't assign
7935 dwarf2_cu::dwarf2_per_objfile.
7936 (set_die_type): Adjust.
7937
ed2dc618
SM
79382018-01-07 Simon Marchi <simon.marchi@ericsson.com>
7939
7940 * dwarf2read.c (struct mapped_debug_names): Add constructor.
7941 <dwarf2_per_objfile>: New field.
7942 (dwarf2_per_objfile): Remove global.
7943 (get_dwarf2_per_objfile): New function.
7944 (set_dwarf2_per_objfile): New function.
7945 (dwarf2_build_psymtabs_hard): Change objfile parameter to
7946 dwarf2_per_objfile.
7947 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
7948 (read_abbrev_offset): Likewise.
7949 (read_indirect_string): Likewise.
7950 (read_indirect_line_string): Likewise.
7951 (read_indirect_string_at_offset): Likewise.
7952 (read_indirect_string_from_dwz): Likewise.
7953 (dwarf2_find_containing_comp_unit): Change objfile parameter to
7954 dwarf2_per_objfile.
7955 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
7956 (create_all_comp_units): Change objfile parameter to
7957 dwarf2_per_objfile.
7958 (create_all_type_units): Likewise.
7959 (process_queue): Add dwarf2_per_objfile parameter.
7960 (read_and_check_comp_unit_head): Likewise.
7961 (lookup_dwo_unit_in_dwp): Likewise.
7962 (get_dwp_file): Likewise.
7963 (process_cu_includes): Likewise.
7964 (struct free_dwo_file_cleanup_data): New struct.
7965 (dwarf2_has_info): Use get_dwarf2_per_objfile and
7966 set_dwarf2_per_objfile.
7967 (dwarf2_get_dwz_file): Add dwarf2_per_objfile parameter.
7968 (dw2_do_instantiate_symtab): Get dwarf2_per_objfile from
7969 context, adjust calls.
7970 (dw2_instantiate_symtab): Likewise.
7971 (dw2_get_cutu): Add dwarf2_per_objfile parameter.
7972 (dw2_get_cu): Likewise.
7973 (create_cu_from_index_list): Change objfile parameter to
7974 dwarf2_per_objfile.
7975 (create_cus_from_index_list): Get dwarf2_per_objfile from
7976 context, adjust calls.
7977 (create_cus_from_index): Likewise.
7978 (create_signatured_type_table_from_index): Change objfile
7979 parameter to dwarf2_per_objfile.
7980 (create_signatured_type_table_from_debug_names): Change objfile
7981 parameter to dwarf2_per_objfile.
7982 (create_addrmap_from_index): Likewise.
7983 (create_addrmap_from_aranges): Likewise.
7984 (dwarf2_read_index): Use get_dwarf2_per_objfile, adjust calls.
7985 (dw2_setup): Remove.
7986 (dw2_get_file_names_reader): Get dwarf2_per_objfile from
7987 context.
7988 (dw2_find_last_source_symtab): Get dwarf2_per_objfile using
7989 get_dwarf2_per_objfile.
7990 (dw2_forget_cached_source_info): Likewise.
7991 (dw2_map_symtabs_matching_filename): Likewise.
7992 (struct dw2_symtab_iterator) <index>: Remove.
7993 <dwarf2_per_objfile>: New field.
7994 (dw2_symtab_iter_init): Replace index parameter with
7995 dwarf2_per_objfile.
7996 (dw2_symtab_iter_next): Use dwarf2_per_objfile from iter.
7997 (dw2_lookup_symbol): Use get_dwarf2_per_objfile and adjust.
7998 (dw2_print_stats): Likewise.
7999 (dw2_dump): Likewise.
8000 (dw2_expand_symtabs_for_function): Likewise.
8001 (dw2_expand_all_symtabs): Likewise.
8002 (dw2_expand_symtabs_with_fullname): Likewise.
8003 (dw2_expand_marked_cus): Replace index and objfile parameters
8004 with dwarf2_per_objfile.
8005 (dw_expand_symtabs_matching_file_matcher): Add
8006 dwarf2_per_objfile parameter and adjust calls.
8007 (dw2_expand_symtabs_matching): Use get_dwarf2_per_objfile and
8008 adjust calls.
8009 (dw2_find_pc_sect_compunit_symtab): Don't call dw2_setup.
8010 (dw2_map_symbol_filenames): Use get_dwarf2_per_objfile and
8011 adjust calls.
8012 (create_cus_from_debug_names_list): Replace objfile parameter
8013 with dwarf2_per_objfile and adjust calls.
8014 (create_cus_from_debug_names): Likewise.
8015 (dwarf2_read_debug_names): Likewise.
8016 (mapped_debug_names::namei_to_name): Adjust call.
8017 (dw2_debug_names_iterator::next): Likewise.
8018 (dw2_debug_names_iterator::find_vec_in_debug_names): Likewise.
8019 (dw2_debug_names_lookup_symbol): Use get_dwarf2_per_objfile.
8020 (dw2_debug_names_dump): Likewise.
8021 (dw2_debug_names_expand_symtabs_for_function): Likewise.
8022 (dw2_debug_names_expand_symtabs_matching): Likewise.
8023 (dwarf2_initialize_objfile): Likewise.
8024 (dwarf2_build_psymtabs): Likewise.
8025 (get_abbrev_section_for_cu): Get dwarf2_per_objfile from
8026 this_cu.
8027 (error_check_comp_unit_head): Add dwarf2_per_objfile parameter.
8028 (read_and_check_comp_unit_head): Likewise.
8029 (read_abbrev_offset): Likewise.
8030 (create_debug_type_hash_table): Likewise.
8031 (create_debug_types_hash_table): Likewise.
8032 (create_all_type_units): Replace objfile parameter with
8033 dwarf2_per_objfile.
8034 (add_type_unit): Add dwarf2_per_objfile parameter.
8035 (fill_in_sig_entry_from_dwo_entry): Replace objfile parameter
8036 with dwarf2_per_objfile.
8037 (lookup_dwo_signatured_type): Get dwarf2_per_objfile from cu.
8038 (lookup_dwp_signatured_type): Likewise.
8039 (lookup_signatured_type): Likewise.
8040 (read_cutu_die_from_dwo): Likewise.
8041 (init_tu_and_read_dwo_dies): Likewise.
8042 (init_cutu_and_read_dies): Likewise.
8043 (init_cutu_and_read_dies_no_follow): Likewise.
8044 (allocate_type_unit_groups_table): Add objfile parameter.
8045 (create_type_unit_group): Use dwarf2_per_objfile from cu.
8046 (get_type_unit_group): Likewise.
8047 (process_psymtab_comp_unit): Update call.
8048 (build_type_psymtabs_reader): Use dwarf2_per_objfile from cu.
8049 (build_type_psymtabs_1): Add dwarf2_per_objfile parameter.
8050 (print_tu_stats): Likewise.
8051 (build_type_psymtab_dependencies): Use dwarf2_per_objfile passed
8052 in void* parameter.
8053 (build_type_psymtabs): Change objfile parameter to
8054 dwarf2_per_objfile.
8055 (process_skeletonless_type_unit): Use dwarf2_per_objfile
8056 passed in void* parameter.
8057 (process_skeletonless_type_units): Change objfile parameter to
8058 dwarf2_per_objfile.
8059 (set_partial_user): Likewise.
8060 (dwarf2_build_psymtabs_hard): Likewise.
8061 (read_comp_units_from_section): Likewise.
8062 (create_all_comp_units): Likewise.
8063 (scan_partial_symbols): Update calls.
8064 (add_partial_symbol): Likewise.
8065 (dwarf2_read_symtab): Use get_dwarf2_per_objfile.
8066 (maybe_queue_comp_unit): Use dwarf2_read_symtab from cu.
8067 (process_queue): Add dwarf2_per_objfile parameter.
8068 (get_compunit_symtab): Use dwarf2_per_objfile from cu.
8069 (compute_compunit_symtab_includes): Likewise.
8070 (process_cu_includes): Add dwarf2_per_objfile parameter.
8071 (process_full_comp_unit): Use dwarf2_per_objfile from cu.
8072 (process_full_type_unit): Likewise.
8073 (process_imported_unit_die): Update call.
8074 (handle_DW_AT_stmt_list): Use dwarf2_per_objfile from cu.
8075 (read_file_scope): Likewise.
8076 (allocate_dwo_file_hash_table): Add objfile parameter.
8077 (lookup_dwo_file_slot): Add dwarf2_per_objfile parameter.
8078 (create_cus_hash_table): Likewise.
8079 (create_dwp_hash_table): Likewise.
8080 (create_dwo_unit_in_dwp_v1): Likewise.
8081 (create_dwp_v2_section): Likewise.
8082 (create_dwo_unit_in_dwp_v2): Likewise.
8083 (lookup_dwo_unit_in_dwp): Likewise.
8084 (try_open_dwop_file): Likewise.
8085 (open_dwo_file): Likewise. Use dwarf2_per_objfile from cu.
8086 (open_and_init_dwo_file): Use dwarf2_per_objfile from cu, update
8087 cleanup to include a reference to dwarf2_per_objfile.
8088 (open_dwp_file): Add dwarf2_per_objfile parameter.
8089 (open_and_init_dwp_file): Likewise.
8090 (get_dwp_file): Likewise.
8091 (lookup_dwo_cutu): Use dwarf2_per_objfile from cu.
8092 (queue_and_load_all_dwo_tus): Update call.
8093 (free_dwo_file_cleanup): Use dwarf2_per_objfile from cleanup
8094 data.
8095 (dwarf2_rnglists_process): Use dwarf2_per_objfile from cu.
8096 (dwarf2_ranges_process): Likewise.
8097 (dwarf2_get_pc_bounds): Likewise.
8098 (mark_common_block_symbol_computed): Likewise.
8099 (abbrev_table_read_table): Add dwarf2_per_objfile parameter.
8100 (dwarf2_read_abbrevs): Update call.
8101 (read_partial_die): Use dwarf2_per_objfile from cu.
8102 (find_partial_die): Likewise.
8103 (fixup_partial_die): Likewise.
8104 (read_attribute_value): Likewise.
8105 (read_indirect_string_at_offset_from): Add objfile parameter.
8106 (read_indirect_string_at_offset): Add dwarf2_per_objfile
8107 parameter.
8108 (read_indirect_string_from_dwz): Add objfile parameter.
8109 (read_indirect_string): Add objfile parameter.
8110 (read_addr_index_1): Add dwarf2_per_objfile parameter.
8111 (read_addr_index): Use dwarf2_per_objfile from cu.
8112 (dwarf2_read_addr_index): Use dwarf2_per_objfile from cu, don't
8113 call dw2_setup.
8114 (read_str_index): Use dwarf2_per_objfile from cu.
8115 (get_debug_line_section): Likewise.
8116 (read_formatted_entries): Add dwarf2_per_objfile parameter.
8117 (dwarf_decode_line_header): Use dwarf2_per_objfile from cu.
8118 (new_symbol_full): Use dwarf2_per_objfile from cu.
8119 (build_error_marker_type): Likewise.
8120 (lookup_die_type): Likewise.
8121 (determine_prefix): Likewise.
8122 (follow_die_offset): Likewise.
8123 (dwarf2_fetch_die_loc_sect_off): Use get_dwarf2_per_objfile.
8124 (dwarf2_fetch_constant_bytes): Don't call dw2_setup.
8125 (dwarf2_fetch_die_type_sect_off): Likewise.
8126 (dwarf2_get_die_type): Likewise.
8127 (follow_die_sig_1): Use dwarf2_per_objfile from cu.
8128 (get_signatured_type): Likewise.
8129 (get_DW_AT_signature_type): Likewise.
8130 (dwarf_decode_macro_bytes): Add dwarf2_per_objfile parameter.
8131 (dwarf_decode_macros): Use dwarf2_per_objfile from cu.
8132 (cu_debug_loc_section): Likewise.
8133 (fill_in_loclist_baton): Likewise.
8134 (dwarf2_symbol_mark_computed): Likewise.
8135 (dwarf2_find_containing_comp_unit): Change objfile parameter to
8136 dwarf2_per_objfile.
8137 (free_cached_comp_units): Use dwarf2_per_objfile passed in void*
8138 parameter.
8139 (age_cached_comp_units): Add dwarf2_per_objfile parameter.
8140 (free_one_cached_comp_unit): Use dwarf2_per_objfile from cu.
8141 (dwarf2_free_objfile): Use get_dwarf2_per_objfile.
8142 (set_die_type): Use dwarf2_free_objfile from cu.
8143 (get_die_type_at_offset): Likewise.
8144 (dwarf2_per_objfile_free): Don't assign global variable.
8145 (debug_names) <constructor>: Add dwarf2_per_objfile
8146 parameter, update m_debugstrlookup construction.
8147 (debug_names::debug_str_lookup): Add dwarf2_per_objfile
8148 parameter.
8149 <m_dwarf2_per_objfile>: New field.
8150 <lookup>: Use m_dwarf2_per_objfile.
8151 (check_dwarf64_offsets): Add dwarf2_per_objfile parameter.
8152 (psyms_seen_size): Likewise.
8153 (write_gdbindex): Replace objfile parameter with
8154 dwarf2_per_objfile.
8155 (write_debug_names): Likewise.
8156 (write_psymtabs_to_index): Likewise.
8157 (save_gdb_index_command): Use get_dwarf2_per_objfile, update
8158 calls.
8159
e3b94546
SM
81602018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8161
8162 * dwarf2read.c (struct dwarf2_cu) <objfile>: Remove.
8163 <dwarf2_per_objfile>: New field.
8164 (struct dwarf2_per_cu_data) <objfile>: Remove.
8165 <dwarf2_per_objfile>: New field.
8166 (create_cu_from_index_list): Assign dwarf2_per_objfile instead
8167 of objfile.
8168 (create_signatured_type_table_from_index): Likewise.
8169 (create_debug_type_hash_table): Likewise.
8170 (fill_in_sig_entry_from_dwo_entry): Likewise.
8171 (lookup_dwo_unit): Access objfile through dwarf2_per_objfile.
8172 (create_type_unit_group): Assign dwarf2_per_objfile instead of
8173 objfile.
8174 (create_partial_symtab): Access objfile through
8175 dwarf2_per_objfile.
8176 (process_psymtab_comp_unit_reader): Likewise.
8177 (read_comp_units_from_section): Likewise.
8178 (scan_partial_symbols): Likewise.
8179 (add_partial_symbol): Likewise.
8180 (add_partial_subprogram): Likewise.
8181 (peek_die_abbrev): Likewise.
8182 (fixup_go_packaging): Likewise.
8183 (process_full_comp_unit): Likewise.
8184 (process_full_type_unit): Likewise.
8185 (process_imported_unit_die): Likewise.
8186 (dwarf2_compute_name): Likewise.
8187 (dwarf2_physname): Likewise.
8188 (read_import_statement): Likewise.
8189 (create_cus_hash_table): Assign dwarf2_physname instead of
8190 objfile.
8191 (read_func_scope): Access objfile through dwarf2_per_objfile.
8192 (read_lexical_block_scope): Likewise.
8193 (read_call_site_scope): Likewise.
8194 (read_variable): Likewise.
8195 (dwarf2_rnglists_process): Likewise.
8196 (dwarf2_ranges_process): Likewise.
8197 (dwarf2_ranges_read): Likewise.
8198 (dwarf2_record_block_ranges): Likewise.
8199 (dwarf2_add_field): Likewise.
8200 (dwarf2_add_member_fn): Likewise.
8201 (read_structure_type): Likewise.
8202 (process_structure_scope): Likewise.
8203 (read_enumeration_type): Likewise.
8204 (read_array_type): Likewise.
8205 (read_common_block): Likewise.
8206 (read_namespace_type): Likewise.
8207 (read_namespace): Likewise.
8208 (read_module_type): Likewise.
8209 (read_tag_pointer_type): Likewise.
8210 (read_tag_ptr_to_member_type): Likewise.
8211 (read_tag_string_type): Likewise.
8212 (read_subroutine_type): Likewise.
8213 (read_typedef): Likewise.
8214 (read_base_type): Likewise.
8215 (attr_to_dynamic_prop): Likewise.
8216 (read_subrange_type): Likewise.
8217 (read_unspecified_type): Likewise.
8218 (load_partial_dies): Likewise.
8219 (read_partial_die): Likewise.
8220 (find_partial_die): Likewise.
8221 (guess_partial_die_structure_name): Likewise.
8222 (fixup_partial_die): Likewise.
8223 (read_attribute_value): Likewise.
8224 (read_addr_index_from_leb128): Likewise.
8225 (dwarf2_read_addr_index): Likewise.
8226 (dwarf2_string_attr): Likewise.
8227 (lnp_state_machine::check_line_address): Likewise.
8228 (dwarf_decode_lines_1): Likewise.
8229 (dwarf_decode_lines): Likewise.
8230 (dwarf2_start_symtab): Likewise.
8231 (var_decode_location): Likewise.
8232 (new_symbol_full): Likewise.
8233 (dwarf2_const_value_data): Likewise.
8234 (dwarf2_const_value_attr): Likewise.
8235 (dwarf2_const_value): Likewise.
8236 (die_type): Likewise.
8237 (die_containing_type): Likewise.
8238 (lookup_die_type): Likewise.
8239 (guess_full_die_structure_name): Likewise.
8240 (anonymous_struct_prefix): Likewise.
8241 (dwarf2_name): Likewise.
8242 (follow_die_ref_or_sig): Likewise.
8243 (follow_die_offset): Likewise.
8244 (follow_die_ref): Likewise.
8245 (dwarf2_fetch_die_loc_sect_off): Likewise.
8246 (dwarf2_fetch_constant_bytes): Likewise.
8247 (dwarf2_fetch_die_type_sect_off): Likewise.
8248 (dwarf2_get_die_type): Likewise.
8249 (follow_die_sig): Likewise.
8250 (decode_locdesc): Likewise.
8251 (dwarf2_per_cu_objfile): Likewise.
8252 (dwarf2_per_cu_text_offset): Likewise.
8253 (init_one_comp_unit): Assign dwarf2_per_objfile instead of
8254 objfile.
8255 (set_die_type): Access objfile through
8256 dwarf2_per_objfile.
8257
b01ba14d
SM
82582018-01-07 Simon Marchi <simon.marchi@ericsson.com>
8259
8260 * valprint.c (converted_character_d): Remove typedef.
8261 (DEF_VEC_O (converted_character_d)): Remove.
8262 (count_next_character): Use std::vector.
8263 (print_converted_chars_to_obstack): Likewise.
8264 (generic_printstr): Likewise.
8265
4d0fdd9b
SM
82662018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8267
8268 * xml-support.h (struct gdb_xml_value): Add constructor.
8269 <value>: Change type to unique_xmalloc_ptr.
8270 (gdb_xml_value_s): Remove typedef.
8271 (DEF_VEC_O (gdb_xml_value_s)): Remove.
8272 (gdb_xml_element_start_handler): Change parameter type to
8273 std::vector.
8274 (xml_find_attribute): Likewise.
8275 * xml-support.c (xml_find_attribute): Change parameter type to
8276 std::vector and adjust.
8277 (gdb_xml_values_cleanup): Remove.
8278 (gdb_xml_parser::start_element): Adjust to std::vector.
8279 (xinclude_start_include): Change paraeter type to std::vector
8280 and adjust.
8281 * btrace.c (check_xml_btrace_version): Likewise.
8282 (parse_xml_btrace_block): Likewise.
8283 (parse_xml_btrace_pt_config_cpu): Likewise.
8284 (parse_xml_btrace_pt): Likewise.
8285 (parse_xml_btrace_conf_bts): Likewise.
8286 (parse_xml_btrace_conf_pt): Likewise.
8287 * memory-map.c (memory_map_start_memory): Likewise.
8288 (memory_map_start_property): Likewise.
8289 * osdata.c (osdata_start_osdata): Likewise.
8290 (osdata_start_item): Likewise.
8291 (osdata_start_column): Likewise.
8292 * remote.c (start_thread): Likewise.
8293 * solib-aix.c (library_list_start_library): Likewise.
8294 (library_list_start_list): Likewise.
8295 * solib-svr4.c (library_list_start_library): Likewise.
8296 (svr4_library_list_start_list): Likewise.
8297 * solib-target.c (library_list_start_segment): Likewise.
8298 (library_list_start_section): Likewise.
8299 (library_list_start_library): Likewise.
8300 (library_list_start_list): Likewise.
8301 * tracepoint.c (traceframe_info_start_memory): Likewise.
8302 (traceframe_info_start_tvar): Likewise.
8303 * xml-syscall.c (syscall_start_syscall): Likewise.
8304 * xml-tdesc.c (tdesc_start_target): Likewise.
8305 (tdesc_start_feature): Likewise.
8306 (tdesc_start_reg): Likewise.
8307 (tdesc_start_union): Likewise.
8308 (tdesc_start_struct): Likewise.
8309 (tdesc_start_flags): Likewise.
8310 (tdesc_start_enum): Likewise.
8311 (tdesc_start_field): Likewise.
8312 (tdesc_start_enum_value): Likewise.
8313 (tdesc_start_vector): Likewise.
8314
f979c73f
SM
83152018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8316
8317 * extension.h (struct xmethod_worker) <clone>: Remove.
8318 * python/py-xmethods.c (struct python_xmethod_worker) <clone>:
8319 Remove.
8320 (python_xmethod_worker::clone): Remove.
8321 * valops.c (find_overload_match): Use std::move instead of
8322 clone.
8323
ba18742c
SM
83242018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
8325
8326 * extension-priv.h (enum ext_lang_rc): Remove, move to extension.h.
8327 (struct extension_language_ops) <clone_xmethod_worker_data>: Remove.
8328 <free_xmethod_worker_data>: Remove.
8329 <get_matching_xmethod_workers>: Chance VEC to std::vector.
8330 <get_xmethod_arg_types>: Remove.
8331 <get_xmethod_result_type>: Remove.
8332 <invoke_xmethod>: Remove.
8333 * extension.c (new_xmethod_worker): Remove.
8334 (clone_xmethod_worker): Remove.
8335 (get_matching_xmethod_workers): Return void, pass std::vector by
8336 pointer.
8337 (get_xmethod_arg_types): Rename to...
8338 (xmethod_worker::get_arg_types): ... this, and adjust.
8339 (get_xmethod_result_type): Rename to...
8340 (xmethod_worker::get_result_type): ... this, and adjust.
8341 (invoke_xmethod): Remove.
8342 (free_xmethod_worker): Remove.
8343 (free_xmethod_worker_vec): Remove.
8344 * extension.h (enum ext_lang_rc): Move here from
8345 extension-priv.h.
8346 (struct xmethod_worker): Add constructor and destructor.
8347 <data>: Remove.
8348 <value>: Remove.
8349 <invoke, clone, do_get_result_type, do_get_arg_types>: New
8350 virtual pure methods.
8351 <get_arg_types, get_result_type>: New methods.
8352 (xmethod_worker_ptr): Remove typedef.
8353 (DEF_VEC_P (xmethod_worker_ptr)): Remove.
8354 (xmethod_worker_vec): Remove typedef.
8355 (xmethod_worker_up): New typedef.
8356 (invoke_xmethod): Remove.
8357 (clone_xmethod_worker): Remove.
8358 (free_xmethod_worker): Remove.
8359 (free_xmethod_worker_vec): Remove.
8360 (get_xmethod_arg_types): Remove.
8361 (get_xmethod_result_type): Remove.
8362 * valops.c (find_method_list): Use std::vector, don't use
8363 intermediate vector.
8364 (value_find_oload_method_list): Use std::vector.
8365 (find_overload_match): Use std::vector.
8366 (find_oload_champ): Use std::vector.
8367 * value.c (value_free): Use operator delete.
8368 (value_of_xmethod): Rename to...
8369 (value_from_xmethod): ... this. Don't assign
8370 xmethod_worker::value, take rvalue-reference.
8371 (result_type_of_xmethod): Adjust.
8372 (call_xmethod): Adjust.
8373 * value.h: Include extension.h.
8374 (struct xmethod_worker): Don't forward-declare.
8375 (value_of_xmethod): Rename to...
8376 (value_from_xmethod): ... this, take rvalue-reference.
8377 * python/py-xmethods.c (struct gdbpy_worker_data): Rename to...
8378 (struct python_xmethod_worker): ... this, add constructor and
8379 destructor.
8380 <invoke, clone, do_get_arg_types, do_get_result_type>: Implement.
8381 (gdbpy_free_xmethod_worker_data): Rename to...
8382 (python_xmethod_worker::~python_xmethod_worker): ... this and
8383 adjust.
8384 (gdbpy_clone_xmethod_worker_data): Rename to...
8385 (python_xmethod_worker::clone): ... this and adjust.
8386 (gdbpy_get_matching_xmethod_workers): Use std::vector, don't use
8387 temporary vector.
8388 (gdbpy_get_xmethod_arg_types): Rename to...
8389 (python_xmethod_worker::do_get_arg_types): ... this and adjust.
8390 (gdbpy_get_xmethod_result_type): Rename to...
8391 (python_xmethod_worker::do_get_result_type): ... this and
8392 adjust.
8393 (gdbpy_invoke_xmethod): Rename to...
8394 (python_xmethod_worker::invoke): ... this and adjust.
8395 (new_python_xmethod_worker): Rename to...
8396 (python_xmethod_worker::python_xmethod_worker): ... this and
8397 adjust.
8398 * python/python-internal.h (gdbpy_clone_xmethod_worker_data):
8399 Remove.
8400 (gdbpy_free_xmethod_worker_data): Remove.
8401 (gdbpy_get_matching_xmethod_workers): Use std::vector.
8402 (gdbpy_get_xmethod_arg_types): Remove.
8403 (gdbpy_get_xmethod_result_type): Remove.
8404 (gdbpy_invoke_xmethod): Remove.
8405 * python/python.c (python_extension_ops): Remove obsolete
8406 callbacks.
8407
e379cee6
PA
84082018-01-05 Pedro Alves <palves@redhat.com>
8409
8410 PR gdb/18653
8411 * common/signals-state-save-restore.c
8412 (save_original_signals_state): New parameter 'quiet'. Warn if we
8413 find a custom handler preinstalled, instead of internal erroring.
8414 But only warn if !quiet.
8415 * common/signals-state-save-restore.h
8416 (save_original_signals_state): New parameter 'quiet'.
8417 * main.c (captured_main_1): Move save_original_signals_state call
8418 after option handling, and pass QUIET.
8419
a655456c
PA
84202018-01-05 Pedro Alves <palves@redhat.com>
8421
8422 * spu-tdep.c (spu_catch_start): Pass
8423 symbol_name_match_type::SEARCH_NAME to block_lookup_symbol.
8424
de63c46b
PA
84252018-01-05 Pedro Alves <palves@redhat.com>
8426
8427 PR gdb/22670
8428 * ada-lang.c (literal_symbol_name_matcher): New function.
8429 (ada_get_symbol_name_matcher): Use it for
8430 symbol_name_match_type::SEARCH_NAME.
8431 * block.c (block_lookup_symbol): New parameter 'match_type'. Pass
8432 it down instead of assuming symbol_name_match_type::FULL.
8433 * block.h (block_lookup_symbol): New parameter 'match_type'.
8434 * c-valprint.c (print_unpacked_pointer): Use
8435 lookup_symbol_search_name instead of lookup_symbol.
8436 * compile/compile-object-load.c (get_out_value_type): Pass down
8437 symbol_name_match_type::SEARCH_NAME.
8438 * cp-namespace.c (cp_basic_lookup_symbol): Pass down
8439 symbol_name_match_type::FULL.
8440 * cp-support.c (cp_get_symbol_name_matcher): Handle
8441 symbol_name_match_type::SEARCH_NAME.
8442 * infrun.c (insert_exception_resume_breakpoint): Use
8443 lookup_symbol_search_name.
8444 * p-valprint.c (pascal_val_print): Use lookup_symbol_search_name.
8445 * psymtab.c (maintenance_check_psymtabs): Use
8446 symbol_name_match_type::SEARCH_NAME and SYMBOL_SEARCH_NAME.
8447 * stack.c (print_frame_args): Use lookup_symbol_search_name and
8448 SYMBOL_SEARCH_NAME.
8449 * symtab.c (lookup_local_symbol): Don't demangle the lookup name
8450 if symbol_name_match_type::SEARCH_NAME.
8451 (lookup_symbol_in_language): Pass down
8452 symbol_name_match_type::FULL.
8453 (lookup_symbol_search_name): New.
8454 (lookup_language_this): Pass down
8455 symbol_name_match_type::SEARCH_NAME.
8456 (lookup_symbol_aux, lookup_local_symbol): New parameter
8457 'match_type'. Pass it down.
8458 * symtab.h (symbol_name_match_type::SEARCH_NAME): New enumerator.
8459 (lookup_symbol_search_name): New declaration.
8460 (lookup_symbol_in_block): New 'match_type' parameter.
8461
f98fc17b
PA
84622018-01-05 Pedro Alves <palves@redhat.com>
8463
8464 PR gdb/22670
8465 * ada-lang.c (ada_lookup_encoded_symbol): Reimplement in terms of
8466 ada_lookup_symbol.
8467 (ada_lookup_symbol): Reimplement in terms of
8468 ada_lookup_symbol_list, bits factored out from
8469 ada_lookup_encoded_symbol.
8470
342f8240
JB
84712018-01-05 Joel Brobecker <brobecker@adacore.com>
8472
8473 * ada-exp.y (write_object_renaming): When subscripting an array
8474 using a symbol as the index, pass the block in call to
8475 ada_lookup_encoded_symbol when looking that symbol up.
8476
7150d33c
JG
84772018-01-05 Jerome Guitton <guitton@adacore.com>
8478
8479 * ada-lang.c (ada_array_length): Use ada_index_type instead of
8480 TYPE_INDEX_TYPE.
8481
cc0e770c
JB
84822018-01-05 Joel Brobecker <brobecker@adacore.com>
8483
8484 * ada-lang.c (ada_to_fixed_value_create): Add handling of
8485 the case where VALUE_LVAL (val0) is not lval_memory.
8486
f79da888 84872018-01-05 Xavier Roirand <roirand@adacore.com>
e3861a03
XR
8488
8489 * ada-valprint.c (print_optional_low_bound): Handle
8490 character-indexed array printing like boolean-indexed array
8491 printing.
8492
cd385f94
JB
84932018-01-05 Joel Brobecker <brobecker@adacore.com>
8494
8495 * NEWS: Create a new section for the next release branch.
8496 Rename the section of the current branch, now that it has
8497 been cut.
8498
09aca949
JB
84992018-01-05 Joel Brobecker <brobecker@adacore.com>
8500
8501 GDB 8.1 branch created (5219ac6237c272b938c28517bf371429260c71e7):
8502 * version.in: Bump version to 8.1.50.DATE-git.
8503
9f757bf7
XR
85042018-01-03 Xavier Roirand <roirand@adacore.com>
8505
8506 * ada-lang.h (ada_exception_catchpoint_kind) <ada_catch_handlers>:
8507 Add field.
8508 * ada-lang.c (struct exception_support_info) <catch_handlers_sym>:
8509 Add field.
8510 (default_exception_support_info) <catch_handlers_sym>: Add field.
8511 (exception_support_info_fallback) <catch_handlers_sym>: Add field.
8512 (ada_exception_name_addr_1): Add "catch handlers" handling.
8513 (ada_exception_catchpoint_cond_string) <ex>: New parameter.
8514 Update all callers.
8515 (create_excep_cond_exprs) <ex>: Add parameter.
8516 (re_set_exception): Update create_excep_cond_exprs call.
8517 (print_it_exception, print_one_exception, print_mention_exception)
8518 (print_recreate_exception): Add "catch handler" handling.
8519 (allocate_location_catch_handlers, re_set_catch_handlers)
8520 (check_status_catch_handlers, print_it_catch_handlers)
8521 (print_one_catch_handlers, print_mention_catch_handlers)
8522 (print_recreate_catch_handlers): New function.
8523 (catch_handlers_breakpoint_ops): New variable.
8524 (catch_ada_exception_command_split) <is_catch_handlers_cmd>:
8525 Add parameter. Add "catch handler" handling.
8526 (ada_exception_sym_name, ada_exception_breakpoint_ops):
8527 Add "catch handler" handling.
8528 (ada_exception_catchpoint_cond_string): Add "catch handler"
8529 handling.
8530 (create_ada_exception_catchpoint): Update create_excep_cond_exprs
8531 call.
8532 (catch_ada_handlers_command): New function.
8533 (initialize_ada_catchpoint_ops): Initialize "catch handlers"
8534 operations structure.
8535 (_initialize_ada_language): Add "catch handlers" command entry.
8536 * NEWS: Document "catch handlers" feature.
8537
9fe561ab
JB
85382018-01-02 Joel Brobecker <brobecker@adacore.com>
8539
8540 * ada-lang.c (ada_value_slice_from_ptr): Take array stride into
8541 account when creating the array type of the slice.
8542 (ada_value_slice): Likewise.
8543
a405673c
JB
85442018-01-02 Joel Brobecker <brobecker@adacore.com>
8545
8546 * gdbtypes.h (enum dynamic_prop_node_kind) <DYN_PROP_BYTE_STRIDE>:
8547 New enum value.
8548 (create_array_type_with_stride): Add byte_stride_prop parameter.
8549 * gdbtypes.c (create_array_type_with_stride) <byte_stride_prop>:
8550 New parameter. Update all callers in this file.
8551 (array_type_has_dynamic_stride): New function.
8552 (is_dynamic_type_internal, resolve_dynamic_array): Add handling
8553 of arrays with dynamic byte strides.
8554 * dwarf2read.c (read_array_type): Add support for dynamic
8555 DW_AT_byte_stride attributes.
8556
74a2f8ff
JB
85572018-01-02 Joel Brobecker <brobecker@adacore.com>
8558
8559 * dwarf2read.c (read_unspecified_type): Treat
8560 DW_TAG_enumeration_type DIEs from Ada units as stubs.
8561
e2882c85
JB
85622018-01-01 Joel Brobecker <brobecker@adacore.com>
8563
8564 Update copyright year range in all GDB files.
8565
1690bb24
JB
85662018-01-01 Joel Brobecker <brobecker@adacore.com>
8567
8568 * copyright.py (BY_HAND): Remove gdb/testsuite/gdb.base/step-line.inp
8569 and gdb/testsuite/gdb.base/step-line.c.
8570
0f0c98a8
JB
85712018-01-01 Joel Brobecker <brobecker@adacore.com>
8572
8573 * copyright.py (main): Dump the contents of
8574 MULTIPLE_COPYRIGHT_HEADERS (separately) from BY_HAND,
8575 even if BY_HAND is empty.
8576
82e1e79a
JB
85772018-01-01 Joel Brobecker <brobecker@adacore.com>
8578
8579 * top.c (print_gdb_version): Update Copyright year in version
8580 message.
8581
053f54e5 85822018-01-01 Joel Brobecker <brobecker@adacore.com>
47fea877 8583
053f54e5 8584 * config/djgpp/fnchange.lst: Add entry for gdb/ChangeLog-2017.
47fea877 8585
053f54e5 8586For older changes see ChangeLog-2017.
c906108c
SS
8587\f
8588Local Variables:
8589mode: change-log
8590left-margin: 8
8591fill-column: 74
8592version-control: never
57da7796 8593coding: utf-8
c906108c 8594End:
This page took 2.584512 seconds and 4 git commands to generate.